1 2018-07-16 Tom Tromey <tom@tromey.com>
3 * buildsym.h (push_subfile, pop_subfile): Update declarations.
4 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
6 (struct subfile_stack): Remove.
7 (subfile_stack): Remove.
8 (push_subfile, pop_subfile, buildsym_init): Update.
10 2018-07-16 Tom Tromey <tom@tromey.com>
12 * buildsym.c (push_subfile): Use gdb_assert.
13 (pop_subfile): Use gdb_assert.
15 2018-07-16 Tom Tromey <tom@tromey.com>
17 * buildsym.h (merge_symbol_lists): Remove.
18 * buildsym.c (merge_symbol_lists): Remove.
20 2018-07-16 Tom Tromey <tom@tromey.com>
22 * stabsread.c (scan_file_globals): Update comment.
23 * stabsread.h (scan_file_globals): Move from buildsym.h.
24 * buildsym.h (scan_file_globals): Move to stabsread.h.
26 2018-07-16 Tom Tromey <tom@tromey.com>
28 * xcoffread.c (xcoff_new_init): Update.
29 * mipsread.c (mipscoff_new_init): Update.
30 * mdebugread.c (mdebug_build_psymtabs): Update.
31 * elfread.c (elf_new_init): Update.
32 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
33 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
34 * buildsym.h (buildsym_new_init): Don't declare.
35 * buildsym.c (buildsym_new_init): Remove.
37 2018-07-16 Tom Tromey <tom@tromey.com>
39 * stabsread.h (within_function): Move from buildsym.h.
40 * stabsread.c (start_stabs): Clear within_function.
41 * coffread.c (coff_start_symtab): Clear within_function.
42 * buildsym.h (within_function): Move to stabsread.h.
43 * buildsym.c (prepare_for_building): Update.
45 2018-07-16 Tom Tromey <tom@tromey.com>
47 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
48 * dwarf2read.c (dwarf2_start_symtab): Don't set
49 processing_gcc_compilation.
50 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
52 2018-07-16 Tom Tromey <tom@tromey.com>
54 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
55 (next_symbol_text_func): Move from buildsym.h.
56 * stabsread.c (hashname): Move from buildsym.c.
57 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
58 (next_symbol_text_func, hashname): Move to stabsread.h.
59 * buildsym.c: Don't include bcache.h
60 (hashname): Move to stasbread.c.
62 2018-07-16 Tom Tromey <tom@tromey.com>
64 * buildsym.h (context_stack_size): Don't declare.
65 * buildsym.c (context_stack_size): New global.
67 2018-07-16 Tom Tromey <tom@tromey.com>
69 * dbxread.c (processing_acc_compilation): New global.
70 * buildsym.h (processing_acc_compilation): Don't declare.
72 2018-07-16 Tom Tromey <tom@tromey.com>
74 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
75 * dbxread.c (read_ofile_symtab): Update.
76 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
77 * buildsym.h (last_source_start_addr): Remove.
78 (set_last_source_start_addr, get_last_source_start_addr):
80 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
82 (struct buildsym_compunit) <m_last_source_start_addr>: New
84 (prepare_for_building): Remove start_addr parameter.
85 (start_symtab, restart_symtab, end_symtab_get_static_block)
86 (end_symtab_with_blockvector): Update.
87 (set_last_source_start_addr, get_last_source_start_addr): New
90 2018-07-16 Tom Tromey <tom@tromey.com>
92 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
94 (have_line_numbers): Remove.
95 (record_line, prepare_for_building, end_symtab_get_static_block)
96 (augment_type_symtab): Update.
98 2018-07-16 Tom Tromey <tom@tromey.com>
100 * buildsym.c (~buildsym_compunit): Free the macro table.
101 (struct buildsym_compunit) <get_macro_table, release_macros>: New
103 <m_pending_macros>: New member.
104 (pending_macros): Remove.
105 (~scoped_free_pendings, get_macro_table, prepare_for_building)
106 (reset_symtab_globals, end_symtab_get_static_block)
107 (end_symtab_with_blockvector, augment_type_symtab)
108 (buildsym_init): Update.
110 2018-07-16 Tom Tromey <tom@tromey.com>
112 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
114 (buildsym_compunit::set_last_source_file): New method.
115 <m_last_source_file>: New member.
116 (prepare_for_building): Remove "name" parameter.
117 (start_symtab, restart_symtab, reset_symtab_globals): Update.
118 (last_source_file): Remove.
119 (set_last_source_file, get_last_source_file): Update.
121 2018-07-16 Tom Tromey <tom@tromey.com>
123 * buildsym.c (prepare_for_building): Add assert.
125 2018-07-16 Tom Tromey <tom@tromey.com>
127 * buildsym.c (~buildsym_compunit): Update.
128 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
129 (start_subfile, patch_subfile_names)
130 (end_symtab_with_blockvector): Update.
132 2018-07-16 Tom Tromey <tom@tromey.com>
134 * buildsym.c (struct buildsym_compunit): Add constructor,
135 destructor, initializers.
136 (start_buildsym_compunit): Remove.
137 (free_buildsym_compunit): Use "delete".
138 (start_symtab, restart_symtab): Use "new".
140 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
142 * symfile.c (set_objfile_default_section_offset): Remove struct
145 2018-07-14 Stafford Horne <shorne@gmail.com>
147 * (Responsible Maintainers): Add myself as or1k maintainer.
149 2018-07-13 Tom Tromey <tom@tromey.com>
151 * symfile.c (set_objfile_default_section_offset): Use extra braces
154 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
156 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
159 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
161 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
162 unittests/cli-utils-selftests.c
163 * unittests/cli-utils-selftests.c: New file.
165 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
167 * NEWS: Mention new commands. Mention change to 'thread apply'.
169 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
171 * thread.c (thr_try_catch_cmd): New function.
172 (thread_apply_all_command): Handle qcs flags.
173 (thread_apply_command): Handle qcs flags.
174 (taas_command): New function.
175 (tfaas_command): New function.
176 (_initialize_thread): Update to setup the new commands 'taas
177 and 'tfaas'. Change doc string for 'thread apply'.
179 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
181 * stack.c: (trailing_outermost_frame): New function, mostly
182 extracted from backtrace_command_1.
183 (leading_innermost_frame): New function.
184 (backtrace_command_1): Update to call trailing_outermost_frame.
185 (frame_apply_command_count): New function.
186 (frame_apply_level_command): New function.
187 (frame_apply_all_command): New function.
188 (frame_apply_command): New function.
189 (faas_command): New function.
190 (frame_cmd_list): New variable.
191 (_initialize_stack): Update to setup the new commands 'frame apply'
194 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
196 * cli-utils.c (number_or_range_parser::get_number): Only handle
197 numbers or convenience var as numbers.
198 (parse_flags): New function.
199 (parse_flags_qcs): New function.
200 (number_or_range_parser::finished): Ensure parsing end is detected
201 before end of string.
202 * cli-utils.h (parse_flags): New function.
203 (parse_flags_qcs): New function.
204 (number_or_range_parser): Remove m_finished bool.
205 (number_or_range_parser::skip_range): Set m_in_range to false.
207 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
209 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
212 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
213 Jan Kratochvil <jan.kratochvil@redhat.com>
214 Paul Fertser <fercerpav@gmail.com>
215 Tsutomu Seki <sekiriki@gmail.com>
216 Pedro Alves <palves@redhat.com>
218 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
219 'unittests/parse-connection-spec-selftests.c'.
220 (COMMON_SFILES): Add 'common/netstuff.c'.
221 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
222 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
223 * common/netstuff.c: New file.
224 * common/netstuff.h: New file.
225 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
226 (wait_for_connect): Update comment. New parameter
227 'gdb::optional<int> sock' instead of 'struct serial *scb'.
228 Use 'sock' directly instead of 'scb->fd'.
229 (try_connect): New function, with code from 'net_open'.
230 (net_open): Rewrite main loop to deal with multiple
231 sockets/addresses. Handle IPv6-style hostnames; implement
232 support for IPv6 connections.
233 * unittests/parse-connection-spec-selftests.c: New file.
235 2018-07-11 Pedro Alves <palves@redhat.com>
238 * remote.c (remote_target::remote_detach_pid): Call
241 2018-07-11 Pedro Alves <palves@redhat.com>
243 * h8300-tdep.c (h8300_gdbarch_init): Remove
244 set_gdbarch_ecoff_reg_to_regnum calls.
246 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
249 * c-typeprint.c (c_type_print_base_struct_union): Don't print
250 offsets/sizes for static members of a class/struct.
252 2018-07-11 Alan Hayward <alan.hayward@arm.com>
254 * target-descriptions.c (tdesc_register_bitsize): Rename.
255 * target-descriptions.h (tdesc_register_bitsize): Likewise.
256 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
257 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
259 2018-07-10 Tom Tromey <tom@tromey.com>
261 * breakpoint.c (moribund_locations): Now static and a
263 (breakpoint_init_inferior, moribund_breakpoint_here_p)
264 (build_bpstat_chain, update_global_location_list)
265 (breakpoint_retire_moribund): Update.
266 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
269 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
271 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
272 (riscv_register_reggroup_p): Use new function, remove unneeded
274 (riscv_push_dummy_call): Extend assert to compare against xlen or
275 flen based on register type.
277 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
279 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
281 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
283 * remote.c (show_hardware_watchpoint_limit): New function.
284 (show_hardware_watchpoint_length_limit): New function.
285 (show_hardware_breakpoint_limit): New function.
286 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
287 where appropriate, update help text.
289 2018-07-09 Tom Tromey <tom@tromey.com>
291 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
292 (CLIBS): Don't mention NAT_CLIBS.
294 2018-07-09 Tom Tromey <tom@tromey.com>
296 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
297 (LIBGDB_OBS, clean mostlyclean): Update.
298 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
300 2018-07-09 Tom Tromey <tom@tromey.com>
302 * Makefile.in (%.c: %.y): Use ECHO_YACC.
303 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
304 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
306 2018-07-09 Tom Tromey <tom@tromey.com>
308 * Makefile.in (ALLDEPFILES): Remove exec.c.
309 (COMMON_OBS): Remove exec.o.
310 (COMMON_SFILES): Add exec.c.
312 2018-07-09 Tom Tromey <tom@tromey.com>
314 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
316 2018-07-09 Tom Tromey <tom@tromey.com>
318 * Makefile.in (clean mostlyclean): Remove stamp-version.
319 (version.c): Depend on stamp-version.
320 (stamp-version): New rule, from version.c rule.
322 2018-07-09 Tom Tromey <tom@tromey.com>
324 * Makefile.in (init.c): Depend on stamp-init.
325 (stamp-init): New rule, from init.c rule.
326 (clean mostlyclean): Remove stamp-init.
328 2018-07-09 Tom Tromey <tom@tromey.com>
330 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
331 SUBDIR_GCC_COMPILE_SRCS.
333 2018-07-09 Tom Tromey <tom@tromey.com>
335 * Makefile.in (init.c): Remove some unused sed rules.
337 2018-07-09 Tom Tromey <tom@tromey.com>
339 * Makefile.in (TSOBS): Remove.
340 (INIT_FILES): Update.
341 (LIBGDB_OBS): Update.
342 (COMMON_SFILES): Add inflow.c.
343 (SFILES): Remove inflow.c.
345 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
347 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
349 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
351 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
352 get_saveloc_name, is_signal_frame_name, step_name,
353 init_remote_name, create_addr_space_name,
354 destroy_addr_space_name, search_unwind_table_name,
355 find_dyn_list_name): Constify.
357 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
359 * darwin-nat.c (darwin_pthread_kill): New function.
360 (darwin_resume_thread): Use darwin_pthread_kill.
362 2018-07-05 Tom de Vries <tdevries@suse.de>
364 * macroexp.c (macro_buffer) <operator=>: New member function.
366 2018-07-04 Tom Tromey <tom@tromey.com>
368 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
370 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
372 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
373 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
377 2018-07-04 Joel Brobecker <brobecker@adacore.com>
379 * NEWS: Create a new section for the next release branch.
380 Rename the section of the current branch, now that it has
383 2018-07-04 Joel Brobecker <brobecker@adacore.com>
385 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
386 * version.in: Bump version to 8.2.50.DATE-git.
388 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
389 Pedro Alves <palves@redhat.com>
391 * linux-nat.c (linux_init_ptrace): Rename to ...
392 (linux_init_ptrace_procfs): ... this. Call
393 linux_proc_init_warnings.
394 (linux_nat_target::post_attach)
395 (linux_nat_target::post_startup_inferior): Adjust.
396 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
397 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
399 2018-07-04 Tom de Vries <tdevries@suse.de>
401 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
403 (read_comp_unit_head): ... here.
405 2018-07-03 Tom Tromey <tom@tromey.com>
407 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
408 (stop_tracing, tstatus_command)
409 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
410 (print_one_static_tracepoint_marker): Update.
411 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
413 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
415 (all_tracepoints, static_tracepoints_here): Return std::vector.
417 2018-07-03 Tom Tromey <tom@tromey.com>
419 * common/ptid.c (ptid_equal): Remove.
420 * common/ptid.h (ptid_equal): Don't declare.
421 * ada-tasks.c: Update.
422 * breakpoint.c: Update.
423 * common/agent.c: Update.
425 * darwin-nat-info.c: Update.
426 * darwin-nat.c: Update.
428 * dtrace-probe.c: Update.
429 * dummy-frame.c: Update.
430 * fbsd-nat.c: Update.
432 * gdbthread.h: Update.
434 * go32-nat.c: Update.
435 * inf-loop.c: Update.
436 * inf-ptrace.c: Update.
441 * linux-fork.c: Update.
442 * linux-nat.c: Update.
443 * linux-thread-db.c: Update.
444 * mi/mi-cmd-var.c: Update.
445 * mi/mi-interp.c: Update.
446 * mi/mi-main.c: Update.
447 * nto-procfs.c: Update.
448 * ppc-linux-tdep.c: Update.
450 * python/py-inferior.c: Update.
451 * python/py-record-btrace.c: Update.
452 * python/py-record.c: Update.
453 * ravenscar-thread.c: Update.
454 * regcache.c: Update.
455 * remote-sim.c: Update.
457 * sol-thread.c: Update.
460 * tui/tui-stack.c: Update.
462 * windows-nat.c: Update.
463 * windows-tdep.c: Update.
465 2018-07-03 Tom Tromey <tom@tromey.com>
467 * common/ptid.c (ptid_match): Remove.
468 * common/ptid.h (ptid_match): Don't declare.
469 * fbsd-nat.c: Update.
472 * linux-nat.c: Update.
473 * record-btrace.c: Update.
474 * regcache.c: Update.
477 2018-07-03 Tom Tromey <tom@tromey.com>
479 * common/ptid.c (ptid_tid_p): Remove.
480 * common/ptid.h (ptid_tid_p): Don't declare.
481 * sol-thread.c: Update.
483 2018-07-03 Tom Tromey <tom@tromey.com>
485 * common/ptid.c (ptid_lwp_p): Remove.
486 * common/ptid.h (ptid_lwp_p): Don't declare.
487 * fbsd-nat.c: Update.
488 * linux-nat.c: Update.
489 * nat/linux-procfs.c: Update.
490 * nat/x86-linux-dregs.c: Update.
491 * sol-thread.c: Update.
493 2018-07-03 Tom Tromey <tom@tromey.com>
495 * common/ptid.c (ptid_is_pid): Remove.
496 * common/ptid.h (ptid_is_pid): Don't declare.
498 * linux-nat.c: Update.
499 * mi/mi-interp.c: Update.
503 2018-07-03 Tom Tromey <tom@tromey.com>
505 * common/ptid.c (ptid_get_tid): Remove.
506 * common/ptid.h (ptid_get_tid): Don't declare.
507 * ada-tasks.c: Update.
508 * aix-thread.c: Update.
509 * bsd-uthread.c: Update.
510 * darwin-nat.c: Update.
511 * fbsd-nat.c: Update.
512 * i386-darwin-nat.c: Update.
514 * linux-tdep.c: Update.
515 * nto-procfs.c: Update.
516 * ppc-ravenscar-thread.c: Update.
517 * python/py-infthread.c: Update.
518 * ravenscar-thread.c: Update.
519 * sol-thread.c: Update.
520 * sparc-ravenscar-thread.c: Update.
521 * windows-nat.c: Update.
523 2018-07-03 Tom Tromey <tom@tromey.com>
525 * common/ptid.c (ptid_get_lwp): Remove.
526 * common/ptid.h (ptid_get_lwp): Don't declare.
527 * aarch64-linux-nat.c: Update.
528 * ada-tasks.c: Update.
529 * aix-thread.c: Update.
530 * amd64-linux-nat.c: Update.
531 * arm-linux-nat.c: Update.
533 * fbsd-nat.c: Update.
534 * fbsd-tdep.c: Update.
536 * i386-cygwin-tdep.c: Update.
537 * i386-gnu-nat.c: Update.
538 * i386-linux-nat.c: Update.
539 * ia64-linux-nat.c: Update.
540 * inf-ptrace.c: Update.
542 * linux-fork.c: Update.
543 * linux-nat.c: Update.
544 * linux-tdep.c: Update.
545 * linux-thread-db.c: Update.
546 * mips-linux-nat.c: Update.
547 * nat/aarch64-linux-hw-point.c: Update.
548 * nat/aarch64-linux.c: Update.
549 * nat/linux-btrace.c: Update.
550 * nat/linux-osdata.c: Update.
551 * nat/linux-procfs.c: Update.
552 * nat/x86-linux-dregs.c: Update.
553 * obsd-nat.c: Update.
554 * ppc-fbsd-nat.c: Update.
555 * ppc-linux-nat.c: Update.
557 * python/py-infthread.c: Update.
558 * ravenscar-thread.c: Update.
560 * s390-linux-nat.c: Update.
561 * sol-thread.c: Update.
562 * sol2-tdep.c: Update.
563 * spu-linux-nat.c: Update.
564 * x86-linux-nat.c: Update.
565 * xtensa-linux-nat.c: Update.
567 2018-07-03 Tom Tromey <tom@tromey.com>
569 * common/ptid.c (ptid_get_pid): Remove.
570 * common/ptid.h (ptid_get_pid): Don't declare.
571 * aarch64-linux-nat.c: Update.
572 * ada-lang.c: Update.
573 * aix-thread.c: Update.
574 * alpha-bsd-nat.c: Update.
575 * amd64-fbsd-nat.c: Update.
576 * amd64-linux-nat.c: Update.
577 * arm-linux-nat.c: Update.
578 * arm-nbsd-nat.c: Update.
580 * break-catch-syscall.c: Update.
581 * breakpoint.c: Update.
582 * bsd-uthread.c: Update.
585 * darwin-nat.c: Update.
586 * fbsd-nat.c: Update.
587 * fbsd-tdep.c: Update.
590 * hppa-nbsd-nat.c: Update.
591 * hppa-obsd-nat.c: Update.
592 * i386-fbsd-nat.c: Update.
593 * ia64-linux-nat.c: Update.
594 * inf-ptrace.c: Update.
596 * inferior.c: Update.
597 * inferior.h: Update.
600 * linux-fork.c: Update.
601 * linux-nat.c: Update.
602 * linux-tdep.c: Update.
603 * linux-thread-db.c: Update.
604 * m68k-bsd-nat.c: Update.
605 * mi/mi-interp.c: Update.
606 * mi/mi-main.c: Update.
607 * mips-linux-nat.c: Update.
608 * mips-nbsd-nat.c: Update.
609 * mips64-obsd-nat.c: Update.
610 * nat/aarch64-linux-hw-point.c: Update.
611 * nat/aarch64-linux.c: Update.
612 * nat/linux-btrace.c: Update.
613 * nat/linux-osdata.c: Update.
614 * nat/linux-procfs.c: Update.
615 * nat/x86-linux-dregs.c: Update.
616 * nto-procfs.c: Update.
617 * obsd-nat.c: Update.
618 * ppc-linux-nat.c: Update.
619 * ppc-nbsd-nat.c: Update.
620 * ppc-obsd-nat.c: Update.
621 * proc-service.c: Update.
623 * python/py-inferior.c: Update.
624 * python/py-infthread.c: Update.
625 * ravenscar-thread.c: Update.
627 * remote-sim.c: Update.
629 * rs6000-nat.c: Update.
630 * s390-linux-nat.c: Update.
631 * sh-nbsd-nat.c: Update.
632 * sol-thread.c: Update.
633 * sparc-nat.c: Update.
634 * sparc64-tdep.c: Update.
635 * spu-linux-nat.c: Update.
636 * spu-tdep.c: Update.
637 * target-debug.h: Update.
640 * tid-parse.c: Update.
641 * tracefile-tfile.c: Update.
642 * vax-bsd-nat.c: Update.
643 * windows-nat.c: Update.
644 * x86-linux-nat.c: Update.
647 2018-07-03 Tom Tromey <tom@tromey.com>
649 * common/ptid.c (pid_to_ptid): Remove.
650 * common/ptid.h (pid_to_ptid): Don't declare.
651 * aix-thread.c: Update.
652 * arm-linux-nat.c: Update.
653 * common/ptid.c: Update.
654 * common/ptid.h: Update.
657 * darwin-nat.c: Update.
658 * fbsd-nat.c: Update.
659 * fork-child.c: Update.
661 * go32-nat.c: Update.
662 * inf-ptrace.c: Update.
664 * inferior.c: Update.
666 * linux-fork.c: Update.
667 * linux-nat.c: Update.
668 * nat/aarch64-linux-hw-point.c: Update.
669 * nat/fork-inferior.c: Update.
670 * nat/x86-linux-dregs.c: Update.
671 * nto-procfs.c: Update.
672 * obsd-nat.c: Update.
674 * progspace.c: Update.
676 * rs6000-nat.c: Update.
677 * s390-linux-nat.c: Update.
678 * sol-thread.c: Update.
679 * spu-linux-nat.c: Update.
682 * tracefile-tfile.c: Update.
683 * windows-nat.c: Update.
685 2018-07-03 Tom Tromey <tom@tromey.com>
687 * common/ptid.h (ptid_build): Don't declare.
688 * common/ptid.c (ptid_build): Remove.
689 * aix-thread.c: Update.
691 * bsd-uthread.c: Update.
692 * common/agent.c: Update.
693 * common/ptid.c: Update.
694 * common/ptid.h: Update.
696 * darwin-nat.c: Update.
697 * fbsd-nat.c: Update.
699 * linux-fork.c: Update.
700 * linux-nat.c: Update.
701 * linux-thread-db.c: Update.
702 * nat/linux-osdata.c: Update.
703 * nat/linux-procfs.c: Update.
704 * nto-procfs.c: Update.
705 * obsd-nat.c: Update.
706 * proc-service.c: Update.
708 * ravenscar-thread.c: Update.
709 * remote-sim.c: Update.
711 * sol-thread.c: Update.
713 * windows-nat.c: Update.
715 2018-07-03 Tom Tromey <tom@tromey.com>
717 * infrun.c (follow_exec): Use exit_inferior_silent.
718 * inferior.c (exit_inferior_num_silent): Remove.
719 * inferior.h (exit_inferior_num_silent): Don't declare.
721 2018-07-03 Tom Tromey <tom@tromey.com>
724 * darwin-nat.c (darwin_attach_pid): Reset inferior and
725 inferior_ptid on error.
727 2018-07-02 Maciej W. Rozycki <macro@mips.com>
728 Simon Marchi <simon.marchi@polymtl.ca>
731 * disasm.h (gdb_disassembler): Add
732 `m_disassembler_options_holder'. member
733 * disasm.c (get_all_disassembler_options): New function.
734 (gdb_disassembler::gdb_disassembler): Use it.
735 (gdb_buffered_insn_length_init_dis): Likewise.
736 (gdb_buffered_insn_length): Adjust accordingly.
737 (set_disassembler_options): Handle options with arguments.
738 (show_disassembler_options_sfunc): Likewise. Add a leading new
739 line if showing options with descriptions.
740 (disassembler_options_completer): Adapt to using the
741 `disasm_options_and_args_t' structure.
742 * mips-tdep.c (mips_disassembler_options): New variable.
743 (mips_disassembler_options_o32): Likewise.
744 (mips_disassembler_options_n32): Likewise.
745 (mips_disassembler_options_n64): Likewise.
746 (gdb_print_insn_mips): Don't set `disassembler_options'.
747 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
749 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
750 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
751 `gdbarch_disassembler_options_implicit' and
752 `gdbarch_valid_disassembler_options'.
753 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
754 `disasm_options_and_args_t' structure.
755 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
757 (valid_disassembler_options): Switch from `disasm_options_t' to
758 the `disasm_options_and_args_t' structure.
759 * NEWS: Document `set disassembler-options' support for the MIPS
761 * gdbarch.h: Regenerate.
762 * gdbarch.c: Regenerate.
764 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
766 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
768 2018-06-29 Joel Brobecker <brobecker@adacore.com>
770 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
771 parameter in call to amd64_target_description.
772 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
773 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
774 (amd64fbsd_init_abi): Likewise.
775 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
776 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
777 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
778 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
780 2018-06-29 Pedro Alves <palves@redhat.com>
782 * gdb/amd64-tdep.h (amd64_create_target_description): Add
783 "segments" parameter.
784 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
785 (_initialize_amd64_tdep): Update call to
786 amd64_create_target_description.
787 (amd64_target_description): Add "segments" parameter. Adjust
788 the implementation to use it.
789 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
790 call to amd64_create_target_description.
791 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
792 * gdb/arch/amd64.h (amd64_create_target_description): Add
794 * gdb/arch/amd64.c (amd64_create_target_description): Add
795 "segments" parameter. Call create_feature_i386_64bit_segments
796 only if SEGMENTS is true.
797 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
798 call to amd64_create_target_description.
800 2018-06-29 Pedro Alves <palves@redhat.com>
802 * thread.c (thread_target_id_str): New, factored out from ...
803 (print_thread_info_1): ... here. Use it to compute the max
804 "Target Id" column width.
806 2018-06-29 Pedro Alves <palves@redhat.com>
808 * remote.c (remote_target::extra_thread_info): Delete
809 'display_buf' and 'n' locals. from the cache, regardless of
810 packet mechanims is in use. Use cache for qThreadExtra and qP
813 2018-06-29 Pedro Alves <palves@redhat.com>
815 * blockframe.c (find_pc_sect_containing_function): New function.
816 * breakpoint.c (print_breakpoint_location): Don't call
817 find_pc_sect_function.
818 * linespec.c (create_sals_line_offset): Record the location's
820 * linespec.c (convert_address_location_to_sals): Fill in sal's
821 symbol with find_pc_sect_containing_function.
822 * symtab.c (find_function_start_sal): Rename to ...
823 (find_function_start_sal_1): ... this.
824 (find_function_start_sal): Reimplement as wrapper around
825 find_function_start_sal_1, and use
826 find_pc_sect_containing_function to fill in the sal's symbol.
827 (find_function_start_sal(symbol*, bool)): Adjust.
828 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
830 (find_pc_sect_containing_function): Declare.
832 2018-06-29 Pedro Alves <palves@redhat.com>
834 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
835 true if the the location has no symbol.
837 2018-06-28 Tom Tromey <tom@tromey.com>
839 * NEWS: Mention --enable-codesign.
840 * silent-rules.mk (ECHO_SIGN): New variable.
841 * configure.ac: Add --enable-codesign.
842 * configure: Rebuild.
843 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
844 (gdb$(EXEEXT)): Optionally invoke codesign.
846 2018-06-28 Pedro Alves <palves@redhat.com>
848 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
850 (switch_to_thread_no_regs): Adjust comment.
851 * infcmd.c (stop_pc): Delete.
852 (post_create_inferior, info_program_command): Replace references
853 to stop_pc with references to thread_info->suspend.stop_pc.
854 * inferior.h (stop_pc): Delete declaration.
855 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
856 (handle_inferior_event_1, handle_signal_stop)
857 (process_event_stop_test, keep_going_stepped_thread)
858 (handle_step_into_function, handle_step_into_function_backward)
859 (print_stop_location): Replace references to stop_pc with
860 references to thread_info->suspend.stop_pc.
861 (struct infcall_suspend_state) <stop_pc>: Delete field.
862 (save_infcall_suspend_state, restore_infcall_suspend_state):
863 Remove references to inf_stat->stop_pc.
864 * linux-fork.c (fork_load_infrun_state): Likewise.
865 * record-btrace.c (record_btrace_set_replay): Likewise.
866 * record-full.c (record_full_goto_entry): Likewise.
867 * remote.c (print_one_stopped_thread): Likewise.
868 * target.c (target_resume): Extend comment.
869 * thread.c (set_executing_thread): New.
870 (set_executing): Use it.
871 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
872 Remove references to stop_pc.
874 2018-06-28 Pedro Alves <palves@redhat.com>
876 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
877 Moving fetching stop_pc until after ecs->event_thread is refreshed.
879 2018-06-28 Tom Tromey <tom@tromey.com>
881 * coffread.c (coff_symfile_finish): Update.
882 * xcoffread.c (xcoff_symfile_finish): Update.
883 * elfread.c (elf_symfile_finish): Update.
884 * symfile.h (dwarf2_free_objfile): Don't declare.
885 * dwarf2read.c (_initialize_dwarf2_read): Use
886 register_objfile_data_with_cleanup.
887 (dwarf2_free_objfile): Now static. Change signature.
889 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
891 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
892 option "-o" to add-symbol-file-load to add an offset to each
893 section's load address.
894 * symfile.c (set_objfile_default_section_offset): New function.
896 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
898 * symfile.c (add_symbol_file_command): Make sure that sections
899 with the same name are sorted in the same order.
901 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
903 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
904 require the second argument. If omitted, load sections at the
905 addresses specified in the file.
907 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
909 * symfile.c (symbol_file_command, symbol_file_add_main_1)
910 (_initialize_symfile): Add option "-o" to symbol-file to add an
911 offset to each section of the symbol file.
913 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
915 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
917 2018-06-27 Tom Tromey <tom@tromey.com>
919 * stack.c (_initialize_stack): Update "func" help text.
921 2018-06-27 Tom Tromey <tom@tromey.com>
923 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
925 (unwind_infopy_str, pyuw_create_unwind_info)
926 (unwind_infopy_add_saved_register, pyuw_sniffer)
927 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
929 (struct saved_reg): Add constructor.
930 <value>: Now a gdbpy_ref<>.
932 2018-06-27 Tom Tromey <tom@tromey.com>
934 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
936 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
938 * gdb-gdb.py.in: Format using autopep8.
940 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
942 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
943 (type_lookup_function): Recognize CORE_ADDR values.
945 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
947 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
950 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
952 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
955 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
957 * gdb-gdb.py: Move to...
958 * gdb-gdb.py.in: ... here.
959 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
960 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
962 (distclean): Remove gdb-gdb.py when cleaning.
963 (gdb-gdb.py, gdb-gdb.gdb): New rules.
964 * configure: Re-generate.
966 2018-06-27 Pedro Alves <palves@redhat.com>
968 * proc-service.c (get_ps_regcache): New.
969 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
970 (ps_lsetfpregs): Use it.
972 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
975 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
976 (dwarf_decode_lines_1): Adjust.
978 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
980 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
982 <info_proc>: Likewise.
984 2018-06-26 Joel Brobecker <brobecker@adacore.com>
986 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
987 to windows_fetch_one_register, and only handle the case of
988 fetching one register. Move the code that reloads the context
989 and iterates over all registers if R is negative to...
990 (windows_nat_target::fetch_registers): ... here.
991 (do_windows_store_inferior_registers): Rename to
992 windows_store_one_register, and only handle the case of storing
993 one register. Move the code that handles the case where r is
995 (windows_nat_target::store_registers) ... here.
997 2018-06-26 Tom Tromey <tom@tromey.com>
1000 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
1001 * rust-lang.c (rust_print_struct_def): Add podata parameter.
1003 (rust_internal_print_type): Add podata parameter.
1004 (rust_print_type): Update.
1006 2018-06-26 Tom Tromey <tom@tromey.com>
1008 * typeprint.h (struct print_offset_data) <update, finish,
1009 maybe_print_hole>: New methods.
1010 <indentation>: New constant.
1011 * typeprint.c (print_offset_data::indentation): Define.
1012 (print_offset_data::maybe_print_hole, print_offset_data::update)
1013 (print_offset_data::finish): Move from c-typeprint.c and rename.
1014 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
1015 (print_spaces_filtered_with_print_options): Update.
1016 (c_print_type_union_field_offset, maybe_print_hole)
1017 (c_print_type_struct_field_offset): Move to typeprint.c and
1019 (c_type_print_base_struct_union): Update.
1021 2018-06-25 Pedro Alves <palves@redhat.com>
1023 * gdbthread.h (thread_info_ref, delete_thread)
1024 (delete_thread_silent, first_thread_of_inferior)
1025 (any_thread_of_inferior, switch_to_thread)
1026 (enable_thread_stack_temporaries)
1027 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1028 (get_last_thread_stack_temporary)
1029 (value_in_thread_stack_temporaries, can_access_registers_thread):
1030 Spell out "struct thread_info" instead of just "thread_info".
1031 * inferior.h (notice_new_inferior): Likewise.
1033 2018-06-25 Pedro Alves <palves@redhat.com>
1035 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1036 pass thread_info pointer to delete_thread.
1037 (windows_nat_target::detach): Pass inferior pointer to
1039 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
1041 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
1042 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
1043 and pass a thread_info pointer to delete_thread.
1044 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
1045 pass thread_info pointer to delete_thread.
1046 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
1047 delete_thread_silent call.
1048 * procfs.c (procfs_target::detach): Pass inferior pointer to
1050 (procfs_target::wait): Pass thread_info pointer to delete_thread.
1051 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
1052 delete_thread_silent call.
1053 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
1054 pass thread_info pointer to delete_thread.
1055 (windows_nat_target::detach): Pass inferior pointer to
1058 2018-06-22 Alan Hayward <alan.hayward@arm.com>
1060 * regcache.c (readable_regcache::read_part): Fix asserts.
1061 (reg_buffer::raw_collect_part): New function.
1062 (regcache::write_part): Fix asserts.
1063 (reg_buffer::raw_supply_part): New function.
1064 (regcache::transfer_regset_register): New helper function.
1065 (regcache::transfer_regset): Call new functions.
1066 (regcache_supply_regset): Use gdb_byte*.
1067 (regcache::supply_regset): Likewise.
1068 (regcache_collect_regset): Likewise.
1069 (regcache::collect_regset): Likewise.
1070 * regcache.h (reg_buffer::raw_collect_part): New declaration.
1071 (reg_buffer::raw_supply_part): Likewise.
1072 (regcache::transfer_regset_register): Likewise.
1073 (regcache::transfer_regset): Use gdb_byte*.
1075 2018-06-22 Alan Hayward <alan.hayward@arm.com>
1077 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
1079 2018-06-21 Pedro Alves <palves@redhat.com>
1081 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
1082 instead of a ptid_t. All callers adjusted.
1083 * ada-tasks.c (ada_get_task_number): Likewise. All callers
1085 (print_ada_task_info, display_current_task_id, task_command_1):
1087 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
1089 (breakpoint_kind): Adjust.
1090 (remove_breakpoints_pid): Rename to ...
1091 (remove_breakpoints_inf): ... this. Adjust to take an inferior
1092 pointer. All callers adjusted.
1093 (bpstat_clear_actions): Use inferior_thread.
1094 (get_bpstat_thread): New.
1095 (bpstat_do_actions): Use it.
1096 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
1097 to take a thread_info pointer. All callers adjusted.
1098 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
1099 (breakpoint_re_set_thread): Use inferior_thread.
1100 * breakpoint.h (struct inferior): Forward declare.
1101 (bpstat_stop_status): Update.
1102 (remove_breakpoints_pid): Delete.
1103 (remove_breakpoints_inf): New.
1104 * bsd-uthread.c (bsd_uthread_target::wait)
1105 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
1106 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
1107 (maint_btrace_packet_history_cmd)
1108 (maint_btrace_clear_packet_history_cmd): Adjust.
1109 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
1111 * cli/cli-interp.c: Include "inferior.h".
1112 * common/refcounted-object.h (struct
1113 refcounted_object_ref_policy): New.
1114 * compile/compile-object-load.c: Include gdbthread.h.
1115 (store_regs): Use inferior_thread.
1116 * corelow.c (core_target::close): Use current_inferior.
1117 (core_target_open): Adjust to use first_thread_of_inferior and use
1118 the current inferior.
1119 * ctf.c (ctf_target::close): Adjust to use current_inferior.
1120 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
1121 <thread>: ... this new field. All references adjusted.
1122 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
1123 Take a thread_info pointer instead of a ptid_t.
1124 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
1125 (dummy_frame_discard, register_dummy_frame_dtor): Take a
1126 thread_info pointer instead of a ptid_t.
1127 * elfread.c: Include "inferior.h".
1128 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
1129 Use inferior_thread.
1130 * eval.c (evaluate_subexp): Likewise.
1131 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
1133 * gdb_proc_service.h (struct thread_info): Forward declare.
1134 (struct ps_prochandle) <ptid>: Delete, replaced by ...
1135 <thread>: ... this new field. All references adjusted.
1136 * gdbarch.h, gdbarch.c: Regenerate.
1137 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
1138 'thread' parameter. All implementations and callers adjusted.
1139 * gdbthread.h (thread_info) <set_running>: New method.
1140 (delete_thread, delete_thread_silent): Take a thread_info pointer
1142 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
1143 (first_thread_of_process): Delete, replaced by ...
1144 (first_thread_of_inferior): ... this new function. All callers
1146 (any_live_thread_of_process): Delete, replaced by ...
1147 (any_live_thread_of_inferior): ... this new function. All callers
1149 (switch_to_thread, switch_to_no_thread): Declare.
1150 (is_executing): Delete.
1151 (enable_thread_stack_temporaries): Update comment.
1152 <enable_thread_stack_temporaries>: Take a thread_info pointer
1153 instead of a ptid_t. Incref the thread.
1154 <~enable_thread_stack_temporaries>: Decref the thread.
1157 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1158 (get_last_thread_stack_temporary)
1159 (value_in_thread_stack_temporaries, can_access_registers_thread):
1160 Take a thread_info pointer instead of a ptid_t. All callers
1162 * infcall.c (get_call_return_value): Use inferior_thread.
1163 (run_inferior_call): Work with thread pointers instead of ptid_t.
1164 (call_function_by_hand_dummy): Work with thread pointers instead
1165 of ptid_t. Use thread_info_ref.
1166 * infcmd.c (proceed_thread_callback): Access thread's state
1168 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
1169 access thread's state directly.
1170 (continue_command): Use inferior_thread.
1171 (info_program_command): Use find_thread_ptid and access thread
1173 (proceed_after_attach_callback): Use thread state directly.
1174 (notice_new_inferior): Take a thread_info pointer instead of a
1175 ptid_t. All callers adjusted.
1176 (exit_inferior): Take an inferior pointer instead of a pid. All
1178 (exit_inferior_silent): New.
1179 (detach_inferior): Delete.
1180 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
1181 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
1182 (detach_inferior_command, kill_inferior_command): Use
1183 find_inferior_id instead of valid_gdb_inferior_id and
1184 gdb_inferior_id_to_pid.
1185 (inferior_command): Use inferior and thread pointers.
1186 * inferior.h (struct thread_info): Forward declare.
1187 (notice_new_inferior): Take a thread_info pointer instead of a
1188 ptid_t. All callers adjusted.
1189 (detach_inferior): Delete declaration.
1190 (exit_inferior, exit_inferior_silent): Take an inferior pointer
1191 instead of a pid. All callers adjusted.
1192 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
1193 (valid_gdb_inferior_id): Delete.
1194 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
1195 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
1196 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
1198 <inf>: ... this new field.
1199 <step_ptid>: Delete, replaced by ...
1200 <step_thread>: ... this new field.
1201 (get_displaced_stepping_state): Take an inferior pointer instead
1202 of a pid. All callers adjusted.
1203 (displaced_step_in_progress_any_inferior): Adjust.
1204 (displaced_step_in_progress_thread): Take a thread pointer instead
1205 of a ptid_t. All callers adjusted.
1206 (displaced_step_in_progress, add_displaced_stepping_state): Take
1207 an inferior pointer instead of a pid. All callers adjusted.
1208 (get_displaced_step_closure_by_addr): Adjust.
1209 (remove_displaced_stepping_state): Take an inferior pointer
1210 instead of a pid. All callers adjusted.
1211 (displaced_step_prepare_throw, displaced_step_prepare)
1212 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
1213 All callers adjusted.
1214 (start_step_over): Adjust.
1215 (infrun_thread_ptid_changed): Remove bit updating ptids in the
1216 displaced step queue.
1217 (do_target_resume): Adjust.
1218 (fetch_inferior_event): Use inferior_thread.
1219 (context_switch, get_inferior_stop_soon): Take an
1220 execution_control_state pointer instead of a ptid_t. All callers
1222 (switch_to_thread_cleanup): Delete.
1223 (stop_all_threads): Use scoped_restore_current_thread.
1224 * inline-frame.c: Include "gdbthread.h".
1225 (inline_state) <inline_state>: Take a thread pointer instead of a
1226 ptid_t. All callers adjusted.
1227 <ptid>: Delete, replaced by ...
1228 <thread>: ... this new field.
1229 (find_inline_frame_state): Take a thread pointer instead of a
1230 ptid_t. All callers adjusted.
1231 (skip_inline_frames, step_into_inline_frame)
1232 (inline_skipped_frames, inline_skipped_symbol): Take a thread
1233 pointer instead of a ptid_t. All callers adjusted.
1234 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
1235 (inline_skipped_frames, inline_skipped_symbol): Likewise.
1236 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
1238 * linux-nat.c (get_detach_signal): Likewise.
1239 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
1240 (thread_db_notice_clone): Adjust.
1241 (thread_db_find_new_threads_silently)
1242 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
1243 a thread pointer instead of a ptid_t. All callers adjusted.
1244 * mi/mi-cmd-var.c: Include "inferior.h".
1245 (mi_cmd_var_update_iter): Update to use thread pointers.
1246 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
1248 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
1250 (mi_output_running): ... this new function.
1251 (mi_on_resume_1): Adjust to use it.
1252 (mi_user_selected_context_changed): Adjust to use inferior_thread.
1253 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
1255 (interrupt_thread_callback): : Adjust to use thread and inferior
1257 * proc-service.c: Include "gdbthread.h".
1258 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
1259 * progspace-and-thread.c: Include "inferior.h".
1260 * progspace.c: Include "inferior.h".
1261 * python/py-exitedevent.c (create_exited_event_object): Adjust to
1262 hold a reference to an inferior_object.
1263 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
1265 * python/py-inferior.c (struct inferior_object): Give the type a
1266 tag name instead of a typedef.
1267 (python_on_normal_stop): No need to check if the current thread is
1269 (inferior_to_inferior_object): Change return type to
1270 inferior_object. All callers adjusted.
1271 (find_thread_object): Delete, bits factored out to ...
1272 (thread_to_thread_object): ... this new function.
1273 * python/py-infthread.c (create_thread_object): Use
1274 inferior_to_inferior_object.
1275 (thpy_is_stopped): Use thread pointer directly.
1276 (gdbpy_selected_thread): Use inferior_thread.
1277 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
1278 field, replaced with ...
1279 <thread>: ... this new field. All users adjusted.
1280 (btpy_insn_or_gap_new): Drop const.
1281 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
1283 * python/py-record.c: Include "gdbthread.h".
1284 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1285 a ptid_t. All callers adjusted.
1286 (gdbpy_current_recording): Use inferior_thread.
1287 * python/py-record.h (recpy_record_object) <ptid>: Delete
1288 field, replaced with ...
1289 <thread>: ... this new field. All users adjusted.
1290 (recpy_element_object) <ptid>: Delete
1291 field, replaced with ...
1292 <thread>: ... this new field. All users adjusted.
1293 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
1294 a ptid_t. All callers adjusted.
1295 * python/py-threadevent.c: Include "gdbthread.h".
1296 (get_event_thread): Use thread_to_thread_object.
1297 * python/python-internal.h (struct inferior_object): Forward
1299 (find_thread_object, find_inferior_object): Delete declarations.
1300 (thread_to_thread_object, inferior_to_inferior_object): New
1302 * record-btrace.c: Include "inferior.h".
1303 (require_btrace_thread): Use inferior_thread.
1304 (record_btrace_frame_sniffer)
1305 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
1306 (get_thread_current_frame): Use scoped_restore_current_thread and
1308 (get_thread_current_frame): Use thread pointer directly.
1309 (record_btrace_replay_at_breakpoint): Use thread's inferior
1311 * record-full.c: Include "inferior.h".
1312 * regcache.c: Include "gdbthread.h".
1313 (get_thread_arch_regcache): Use the inferior's address space
1315 (get_thread_regcache, registers_changed_thread): New.
1316 * regcache.h (get_thread_regcache(thread_info *thread)): New
1318 (registers_changed_thread): New.
1319 (remote_target) <remote_detach_1>: Swap order of parameters.
1320 (remote_add_thread): <remote_add_thread>: Return the new thread.
1321 (get_remote_thread_info(ptid_t)): New overload.
1322 (remote_target::remote_notice_new_inferior): Use thread pointers
1324 (remote_target::process_initial_stop_replies): Use
1325 thread_info::set_running.
1326 (remote_target::remote_detach_1, remote_target::detach)
1327 (extended_remote_target::detach): Adjust.
1328 * stack.c (frame_show_address): Use inferior_thread.
1329 * target-debug.h (target_debug_print_thread_info_pp): New.
1330 * target-delegates.c: Regenerate.
1331 * target.c (default_thread_address_space): Delete.
1332 (memory_xfer_partial_1): Use current_inferior.
1333 (target_detach): Use current_inferior.
1334 (target_thread_address_space): Delete.
1335 (generic_mourn_inferior): Use current_inferior.
1336 * target.h (struct target_ops) <thread_address_space>: Delete.
1337 (target_thread_address_space): Delete.
1338 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
1340 (delete_thread_1, delete_thread, delete_thread_silent): Take a
1341 thread pointer instead of a ptid_t. Adjust all callers.
1342 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
1343 (first_thread_of_process): Delete, replaced by ...
1344 (first_thread_of_inferior): ... this new function. All callers
1346 (any_thread_of_process): Rename to ...
1347 (any_thread_of_inferior): ... this, and take an inferior pointer.
1348 (any_live_thread_of_process): Rename to ...
1349 (any_live_thread_of_inferior): ... this, and take an inferior
1351 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
1352 (value_in_thread_stack_temporaries)
1353 (get_last_thread_stack_temporary): Take a thread pointer instead
1354 of a ptid_t. Adjust all callers.
1355 (thread_info::set_running): New.
1356 (validate_registers_access): Use inferior_thread.
1357 (can_access_registers_ptid): Rename to ...
1358 (can_access_registers_thread): ... this, and take a thread
1360 (print_thread_info_1): Adjust to compare thread pointers instead
1362 (switch_to_no_thread, switch_to_thread): Make extern.
1363 (scoped_restore_current_thread::~scoped_restore_current_thread):
1364 Use m_thread pointer directly.
1365 (scoped_restore_current_thread::scoped_restore_current_thread):
1366 Use inferior_thread.
1367 (thread_command): Use thread pointer directly.
1368 (thread_num_make_value_helper): Use inferior_thread.
1369 * top.c (execute_command): Use inferior_thread.
1370 * tui/tui-interp.c: Include "inferior.h".
1371 * varobj.c (varobj_create): Use inferior_thread.
1372 (value_of_root_1): Use find_thread_global_id instead of
1373 global_thread_id_to_ptid.
1375 2018-06-21 Alan Hayward <alan.hayward@arm.com>
1377 * regcache.c (readable_regcache::read_part): Avoid memcpy when
1379 (regcache::write_part): Likewise.
1380 (readable_regcache::cooked_read_part): Update comment.
1381 (readable_regcache::cooked_write_part): Likewise.
1382 * regcache.h: (readable_regcache::read_part): Likewise.
1383 (regcache::write_part): Likewise.
1385 2018-06-21 Richard Bunt <richard.bunt@arm.com>
1386 Dirk Schubert <dirk.schubert@arm.com>
1388 * aarch64-linux-nat.c (post_attach): New.
1389 (aarch64_linux_nat_target::post_attach): Override post_attach to
1390 record the number of hardware debug registers.
1392 2018-06-20 Tom Tromey <tom@tromey.com>
1394 * python/py-param.c (add_setshow_generic): Make parameters const.
1395 (parmpy_init): Update.
1397 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1399 * regcache.h (regcache_cooked_read_ftype): Rename to...
1400 (register_read_ftype): ...this, change type to function_view.
1401 (class reg_buffer) <save>: Remove src parameter.
1402 (readonly_detached_regcache) <readonly_detached_regcache>: Make
1403 parameter non-const in first overload. Remove src parameter in
1405 * regcache.c (do_cooked_read): Remove.
1406 (readonly_detached_regcache::readonly_detached_regcache): Make
1407 parameter non-const, adjust call to other constructor.
1408 (reg_buffer::save): Remove src parameter.
1409 * frame.c (do_frame_register_read): Remove.
1410 (frame_save_as_regcache): Use lambda function.
1411 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
1412 parameter to ppu2spu_data *.
1413 (ppu2spu_sniffer): Use lambda function.
1415 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
1417 * record-full.c (record_full_target::insert_breakpoint): Remove
1418 "struct" keyword, add const.
1420 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1422 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
1423 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
1424 * configure.ac: Remove AC_PREREQ, add missing quoting.
1425 * gnulib/configure.ac: Modernize usage of
1426 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
1427 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
1428 (AUTOMAKE_VERSION): Bump to 1.15.1.
1429 * configure: Re-generate.
1430 * config.in: Re-generate.
1431 * aclocal.m4: Re-generate.
1432 * gnulib/aclocal.m4: Re-generate.
1433 * gnulib/config.in: Re-generate.
1434 * gnulib/configure: Re-generate.
1435 * gnulib/import/Makefile.in: Re-generate.
1437 2018-06-19 Pedro Alves <palves@redhat.com>
1439 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
1440 (lookup_minimal_symbol_by_pc_section): ... here with
1441 gdb_assert_not_reached added.
1443 2018-06-19 Pedro Alves <palves@redhat.com>
1445 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
1446 parameter with a block parameter. Compare location's block symbol
1447 with the frame's block instead of addresses.
1448 (skip_inline_frames): Pass the current block instead of the
1449 frame's address. Break out as soon as we determine the frame
1450 should not be skipped.
1452 2018-06-18 Tom Tromey <tom@tromey.com>
1454 * solib-aix.c (solib_aix_get_section_offsets): Return
1456 (solib_aix_solib_create_inferior_hook): Update.
1458 2018-06-18 Tom Tromey <tom@tromey.com>
1460 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
1462 2018-06-18 Tom Tromey <tom@tromey.com>
1464 * solib-frv.c (frv_relocate_main_executable): Use
1466 * solib-dsbt.c (dsbt_relocate_main_executable): Use
1469 2018-06-18 Tom Tromey <tom@tromey.com>
1471 * objfiles.h (inhibit_section_map_updates): Update.
1472 (resume_section_map_updates, resume_section_map_updates_cleanup):
1474 * solib-svr4.c (svr4_handle_solib_event): Update.
1475 * objfiles.c (inhibit_section_map_updates): Return
1476 scoped_restore_tmpl<int>.
1477 (resume_section_map_updates, resume_section_map_updates_cleanup):
1480 2018-06-18 Tom Tromey <tom@tromey.com>
1482 * valprint.h (read_string): Update.
1483 * valprint.c (read_string): Change type of "buffer".
1484 (val_print_string): Update.
1485 * python/py-value.c (valpy_string): Update.
1486 * language.h (struct language_defn) <la_get_string>: Change
1488 (default_get_string, c_get_string): Update.
1489 * language.c (default_get_string): Change type of "buffer".
1490 * guile/scm-value.c (gdbscm_value_to_string): Update.
1491 * c-lang.c (c_get_string): Change type of "buffer".
1493 2018-06-18 Tom Tromey <tom@tromey.com>
1495 * ser-mingw.c (struct pipe_state_destroyer): New.
1496 (pipe_state_up): New typedef.
1497 (cleanup_pipe_state): Remove.
1498 (pipe_windows_open): Use pipe_state_up. Don't release argv.
1500 2018-06-18 Tom Tromey <tom@tromey.com>
1502 * rust-lang.h (rust_yyerror): Don't declare.
1503 * rust-lang.c (rust_language_defn): Update.
1504 * rust-exp.y (yyerror): Now static.
1505 * parse.c (parse_exp_in_context_1): Update.
1506 * p-lang.h (p_yyerror): Don't declare.
1507 * p-lang.c (p_language_defn): Update.
1508 * p-exp.y (yyerror): Now static.
1509 * opencl-lang.c (opencl_language_defn): Update.
1510 * objc-lang.c (objc_language_defn): Update.
1511 * m2-lang.h (m2_yyerror): Don't declare.
1512 * m2-lang.c (m2_language_defn): Update.
1513 * m2-exp.y (yyerror): Now static.
1514 * language.h (struct language_defn) <la_error>: Remove.
1515 * language.c (unk_lang_error): Remove.
1516 (unknown_language_defn, auto_language_defn): Remove.
1517 * go-lang.h (go_yyerror): Don't declare.
1518 * go-lang.c (go_language_defn): Update.
1519 * go-exp.y (yyerror): Now static.
1520 * f-lang.h (f_yyerror): Don't declare.
1521 * f-lang.c (f_language_defn): Update.
1522 * f-exp.y (yyerror): Now static.
1523 * d-lang.h (d_yyerror): Don't declare.
1524 * d-lang.c (d_language_defn): Update.
1525 * d-exp.y (yyerror): Now static.
1526 * c-lang.h (c_yyerror): Don't declare.
1527 * c-lang.c (c_language_defn, cplus_language_defn)
1528 (asm_language_defn, minimal_language_defn): Update.
1529 * c-exp.y (yyerror): Now static.
1530 * ada-lang.h (ada_yyerror): Don't declare.
1531 * ada-lang.c (ada_language_defn): Update.
1532 * ada-exp.y (yyerror): Now static.
1534 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1536 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
1537 (store_sveregs_to_thread): Likewise.
1538 (aarch64_linux_fetch_inferior_registers): Check for SVE.
1539 (aarch64_linux_store_inferior_registers): Likewise.
1540 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
1542 (aarch64_sve_regs_copy_to_regcache): Likewise.
1543 (aarch64_sve_regs_copy_from_regcache): Likewise.
1544 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
1546 (aarch64_sve_regs_copy_to_regcache): Likewise.
1547 (aarch64_sve_regs_copy_from_regcache): Likewise.
1548 (sve_context): Structure from Linux headers.
1549 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
1550 (SVE_SIG_ZREG_SIZE): Likewise.
1551 (SVE_SIG_PREG_SIZE): Likewise.
1552 (SVE_SIG_FFR_SIZE): Likewise.
1553 (SVE_SIG_REGS_OFFSET): Likewise.
1554 (SVE_SIG_ZREGS_OFFSET): Likewise.
1555 (SVE_SIG_ZREG_OFFSET): Likewise.
1556 (SVE_SIG_ZREGS_SIZE): Likewise.
1557 (SVE_SIG_PREGS_OFFSET): Likewise.
1558 (SVE_SIG_PREG_OFFSET): Likewise.
1559 (SVE_SIG_PREGS_SIZE): Likewise.
1560 (SVE_SIG_FFR_OFFSET): Likewise.
1561 (SVE_SIG_REGS_SIZE): Likewise.
1562 (SVE_SIG_CONTEXT_SIZE): Likewise.
1563 (SVE_PT_REGS_MASK): Likewise.
1564 (SVE_PT_REGS_FPSIMD): Likewise.
1565 (SVE_PT_REGS_SVE): Likewise.
1566 (SVE_PT_VL_INHERIT): Likewise.
1567 (SVE_PT_VL_ONEXEC): Likewise.
1568 (SVE_PT_REGS_OFFSET): Likewise.
1569 (SVE_PT_FPSIMD_OFFSET): Likewise.
1570 (SVE_PT_FPSIMD_SIZE): Likewise.
1571 (SVE_PT_SVE_ZREG_SIZE): Likewise.
1572 (SVE_PT_SVE_PREG_SIZE): Likewise.
1573 (SVE_PT_SVE_FFR_SIZE): Likewise.
1574 (SVE_PT_SVE_FPSR_SIZE): Likewise.
1575 (SVE_PT_SVE_FPCR_SIZE): Likewise.
1576 (__SVE_SIG_TO_PT): Likewise.
1577 (SVE_PT_SVE_OFFSET): Likewise.
1578 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
1579 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
1580 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
1581 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
1582 (SVE_PT_SVE_PREG_OFFSET): Likewise.
1583 (SVE_PT_SVE_PREGS_SIZE): Likewise.
1584 (SVE_PT_SVE_FFR_OFFSET): Likewise.
1585 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
1586 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
1587 (SVE_PT_SVE_SIZE): Likewise.
1588 (SVE_PT_SIZE): Likewise.
1589 (HAS_SVE_STATE): New define.
1591 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1593 * nat/aarch64-sve-linux-sigcontext.h: New file.
1594 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
1596 (SVE_VQ_MIN): Likewise.
1597 (SVE_VQ_MAX): Likewise.
1598 (SVE_VL_MIN): Likewise.
1599 (SVE_VL_MAX): Likewise.
1600 (SVE_NUM_ZREGS): Likewise.
1601 (SVE_NUM_PREGS): Likewise.
1602 (sve_vl_valid): Likewise.
1603 (struct user_sve_header): Likewise.
1605 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
1606 Richard Bunt <Richard.Bunt@arm.com>
1608 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
1609 was requested by GDB.
1611 2018-06-15 Tom de Vries <tdevries@suse.de>
1613 * MAINTAINERS (Write After Approval): Add Tom de Vries.
1615 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
1617 * gnulib/update-gnulib.sh: Print expected versions of
1620 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
1622 * arch-utils.c (default_type_align): Use type_length_units.
1623 * gdbtypes.c (type_align): Use type_length_units.
1625 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1627 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
1628 of 'define' command.
1630 2018-06-14 Tom de Vries <tdevries@suse.de>
1633 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
1634 get_no_prettyformat_print_options.
1636 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
1638 * sparc-nat.h: Include target.h.
1639 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
1640 <fetch_registers>: Remove this argument in function call.
1641 <store_registers>: Remove this argument in function call, remove
1643 <low_forget_process>: Call sparc64_forget_process instead of
1644 sparc_forget_process.
1646 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1648 * procfs.c (_initialize_procfs): Use add_inf_child_target.
1649 (procfs_target::make_corefile_notes): Adjust to new
1650 target_read_alloc return type.
1652 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1653 Stephen Roberts <stephen.roberts@arm.com>
1656 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
1657 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
1658 Move should_notify_stop local into more inner scope.
1660 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1661 Stephen Roberts <stephen.roberts@arm.com>
1664 * infrun.c (resume_1): Add call to mark_async_event_handler.
1666 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
1668 * infrun.c (do_target_wait): Change old version of $pc printed.
1670 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
1672 * dwarf2read.c (read_index_from_section): Rename to...
1673 (read_gdb_index_from_section): ... this, update all callers.
1674 (dwarf2_read_index): Rename to...
1675 (dwarf2_read_gdb_index): ... this, update all callers.
1677 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
1679 * gdb/hppa-linux-nat.c
1680 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
1681 hppa_linux_nat_target::fetch_registers.
1683 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1685 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
1686 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
1687 (AARCH64_DWARF_SVE_FFR): Likewise.
1688 (AARCH64_DWARF_SVE_P0): Likewise.
1689 (AARCH64_DWARF_SVE_Z0): Likewise.
1691 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1693 * common/common-regcache.h (raw_compare): New function.
1694 * regcache.c (regcache::raw_compare): Likewise.
1695 * regcache.h (regcache::raw_compare): New declaration.
1697 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1699 * common/common-regcache.h (reg_buffer_common): New structure.
1700 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
1701 (reg_buffer::raw_supply): Likewise.
1702 (reg_buffer::raw_supply_integer): Likewise.
1703 (reg_buffer::raw_supply_zeroed): Likewise.
1704 (reg_buffer::raw_collect): Likewise.
1705 (reg_buffer::raw_collect_integer): Likewise.
1706 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
1707 (reg_buffer::raw_supply): Likewise.
1708 (reg_buffer::raw_supply_integer): Likewise.
1709 (reg_buffer::raw_supply_zeroed): Likewise.
1710 (reg_buffer::raw_collect): Likewise.
1711 (reg_buffer::raw_collect_integer): Likewise.
1713 2018-06-10 Tom Tromey <tom@tromey.com>
1715 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
1716 (class remote_state) <stop_reply_queue>: Now std::vector.
1717 (remote_state::~remote_state)
1718 (remote_target::stop_reply_queue_length): Update.
1719 (struct queue_iter_param, remove_child_of_pending_fork)
1720 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
1721 (check_pending_event_prevents_wildcard_vcont_callback)
1722 (remove_stop_reply_for_inferior)
1723 (remove_stop_reply_of_remote_state)
1724 (remote_notif_remove_once_on_match)
1725 (stop_reply_match_ptid_and_ws)
1726 (remote_kill_child_of_pending_fork): Remove.
1727 (remote_target::remove_new_fork_children)
1728 (remote_target::check_pending_events_prevent_wildcard_vcont)
1729 (remote_target::discard_pending_stop_replies)
1730 (remote_target::discard_pending_stop_replies_in_queue)
1731 (remote_target::remote_notif_remove_queued_reply)
1732 (remote_target::queued_stop_reply)
1733 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
1734 (remote_target::wait, remote_target::kill_new_fork_children)
1735 (remote_target::async): Update.
1737 2018-06-10 Tom Tromey <tom@tromey.com>
1739 * record-full.c (record_full_arch_list_cleanups): Remove.
1740 (record_full_message): Use try/catch.
1741 (record_full_wait_cleanups): Remove.
1742 (record_full_wait_1): Use try/catch.
1743 (record_full_restore): Likewise.
1745 2018-06-10 Tom Tromey <tom@tromey.com>
1747 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
1748 declare VEC. Add constructor.
1749 <in_target_beneath>: Now bool.
1750 (record_full_breakpoints): Now a std::vector, static.
1751 (record_full_sync_record_breakpoints)
1752 (record_full_init_record_breakpoints)
1753 (record_full_target::insert_breakpoint)
1754 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
1756 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
1758 * dwarf2read.c (process_cu_includes): Remove struct keyword.
1759 * serial.c (serial_interface_lookup): Remove struct keyword.
1761 2018-06-10 Tom Tromey <tom@tromey.com>
1763 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
1765 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
1767 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
1769 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
1770 "beneath" as a method.
1771 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
1772 Use "beneath" as a method.
1774 2018-06-10 Tom Tromey <tom@tromey.com>
1776 * tracefile.c (struct trace_file_writer_deleter): New.
1777 <operator()>: Rename from trace_file_writer_xfree.
1778 (trace_file_writer_up): New typedef.
1779 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
1781 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1783 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
1784 <m_registers, m_register_status>: Change type to
1786 * regcache.c (reg_buffer::reg_buffer): Use new instead of
1789 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
1791 * common/common-regcache.h (enum register_status): Add
1792 underlying type "signed char".
1793 * regcache.h (reg_buffer) <m_register_status>: Change type to
1795 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
1796 register_status instead of signed char.
1797 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
1798 (reg_buffer::get_register_status): Remove cast.
1799 (readable_regcache::raw_read): Remove cast.
1800 (readable_regcache::cooked_read): Remove cast.
1802 2018-06-09 Tom Tromey <tom@tromey.com>
1804 * source.c (reverse_search_command, forward_search_command): Use
1807 2018-06-09 Tom Tromey <tom@tromey.com>
1809 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
1810 (serial_ops_list): Now static, std::vector.
1811 (serial_interface_lookup, serial_add_interface): Update.
1813 2018-06-09 Tom Tromey <tom@tromey.com>
1815 * dwarf2read.c (process_cu_includes): Update.
1816 (process_full_comp_unit): Update.
1817 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
1820 2018-06-08 Paul Koning <paul_koning@dell.com>
1824 * python/python.c (do_start_initialization):
1825 Avoid call to internal Python API.
1826 (init__gdb_module): New function.
1828 2018-06-08 Gary Benson <gbenson@redhat.com>
1830 * linux-thread-db.c (valprint.h): New include.
1831 (struct check_thread_db_info): New structure.
1832 (check_thread_db_on_load, tdb_testinfo): New static globals.
1833 (check_thread_db, check_thread_db_callback): New functions.
1834 (try_thread_db_load_1): Run integrity checks if requested.
1835 (maintenance_check_libthread_db): New function.
1836 (_initialize_thread_db): Register "maint check libthread-db"
1837 and "maint set/show check-libthread-db".
1838 * NEWS: Mention the above new commands.
1840 2018-06-08 Tom Tromey <tom@tromey.com>
1842 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
1845 2018-06-08 Tom Tromey <tom@tromey.com>
1847 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
1849 2018-06-08 Tom Tromey <tom@tromey.com>
1851 * common/btrace-common.h (struct btrace_data): Add constructor,
1852 destructor, move assignment operator.
1853 <empty, clear, fini>: New methods.
1854 <format>: Initialize.
1855 (btrace_data_init, btrace_data_fini, btrace_data_clear)
1856 (btrace_data_empty): Don't declare.
1857 * common/btrace-common.c (btrace_data_init): Remove.
1858 (btrace_data::fini): Rename from btrace_data_fini.
1859 (btrace_data::empty): Rename from btrace_data_empty.
1860 (btrace_data::clear): Rename from btrace_data_clear. Return
1862 * btrace.h (make_cleanup_btrace_data): Don't declare.
1863 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
1864 (parse_xml_btrace): Update.
1865 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
1866 (maint_btrace_clear_packet_history_cmd): Update.
1868 2018-06-07 Pedro Alves <palves@redhat.com>
1870 * target.h (target_ops) <beneath>: Now a method. All references
1872 (class target_stack): New.
1873 * target.c (g_target_stack): New.
1874 (g_current_top_target): Delete.
1875 (current_top_target): Get the top target out of g_target_stack.
1876 (target_stack::push, target_stack::unpush): New.
1877 (push_target, unpush_target): Reimplement.
1878 (target_is_pushed): Reimplement in terms of g_target_stack.
1879 (target_ops::beneath, target_stack::find_beneath): New.
1881 2018-06-07 Pedro Alves <palves@redhat.com>
1883 * target.h (find_target_beneath): Delete declaration.
1884 * target.c (find_target_beneath): Delete definition.
1885 * aix-thread.c: All callers of find_target_beneath adjusted to
1886 call target_ops::beneath instead.
1887 * bsd-uthread.c: Likewise.
1888 * linux-thread-db.c: Likewise.
1889 * ravenscar-thread.c: Likewise.
1890 * sol-thread.c: Likewise.
1891 * spu-multiarch.c: Likewise.
1893 2018-06-07 Pedro Alves <palves@redhat.com>
1895 * target.h (target_ops) <beneath>: Now a method. All references
1897 (target_ops) <m_beneath>: New.
1898 * target.c (target_ops::beneath): New.
1899 * corelow.c: Adjust all references to target_ops::beneath.
1900 * linux-thread-db.c: Likewise.
1901 * make-target-delegates: Likewise.
1902 * record-btrace.c: Likewise.
1903 * record-full.c: Likewise.
1904 * remote.c: Likewise.
1905 * target.c: Likewise.
1906 * target-delegates.c: Regenerate.
1908 2018-06-07 Pedro Alves <palves@redhat.com>
1910 * target.h (target_stack): Delete.
1911 (current_top_target): Declare function.
1912 * target.c (target_stack): Delete.
1913 (g_current_top_target): New.
1914 (current_top_target): New function.
1915 * auxv.c: Use current_top_target instead of target_stack
1917 * avr-tdep.c: Likewise.
1918 * breakpoint.c: Likewise.
1919 * corefile.c: Likewise.
1920 * elfread.c: Likewise.
1922 * exceptions.c: Likewise.
1923 * frame.c: Likewise.
1924 * gdbarch-selftests.c: Likewise.
1925 * gnu-v3-abi.c: Likewise.
1926 * ia64-tdep.c: Likewise.
1927 * ia64-vms-tdep.c: Likewise.
1928 * infcall.c: Likewise.
1929 * infcmd.c: Likewise.
1930 * infrun.c: Likewise.
1931 * linespec.c: Likewise.
1932 * linux-tdep.c: Likewise.
1933 * minsyms.c: Likewise.
1934 * ppc-linux-nat.c: Likewise.
1935 * ppc-linux-tdep.c: Likewise.
1936 * procfs.c: Likewise.
1937 * regcache.c: Likewise.
1938 * remote.c: Likewise.
1939 * rs6000-tdep.c: Likewise.
1940 * s390-linux-nat.c: Likewise.
1941 * s390-tdep.c: Likewise.
1942 * solib-aix.c: Likewise.
1943 * solib-darwin.c: Likewise.
1944 * solib-dsbt.c: Likewise.
1945 * solib-spu.c: Likewise.
1946 * solib-svr4.c: Likewise.
1947 * solib-target.c: Likewise.
1948 * sparc-tdep.c: Likewise.
1949 * sparc64-tdep.c: Likewise.
1950 * spu-tdep.c: Likewise.
1951 * symfile.c: Likewise.
1952 * symtab.c: Likewise.
1953 * target-descriptions.c: Likewise.
1954 * target-memory.c: Likewise.
1955 * target.c: Likewise.
1956 * target.h: Likewise.
1957 * tracefile-tfile.c: Likewise.
1958 * tracepoint.c: Likewise.
1959 * valops.c: Likewise.
1960 * valprint.c: Likewise.
1961 * value.c: Likewise.
1962 * windows-tdep.c: Likewise.
1963 * mi/mi-main.c: Likewise.
1965 2018-06-07 Tom Tromey <tom@tromey.com>
1967 * valprint.h (build_address_symbolic): Declare.
1968 * printcmd.c (print_address_symbolic): Update.
1969 (build_address_symbolic): Change "name" and "filename" to
1971 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
1973 * defs.h (build_address_symbolic): Remove declaration.
1975 2018-06-07 Alan Hayward <alan.hayward@arm.com>
1977 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
1978 (aarch64_vnv_type): Add function.
1979 (aarch64_pseudo_register_name): Add V regs for SVE.
1980 (aarch64_pseudo_register_type): Likewise.
1981 (aarch64_pseudo_register_reggroup_p): Likewise.
1982 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
1983 (aarch64_pseudo_read_value): Add V regs for SVE.
1984 (aarch64_pseudo_write_2): Use V0 offset for SVE
1985 (aarch64_pseudo_write): Add V regs for SVE.
1986 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
1988 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
1990 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
1991 (sve_vl_from_vq): Likewise.
1993 2018-06-05 Tom Tromey <tom@tromey.com>
1995 * cli/cli-cmds.c (show_version): Update.
1996 * top.c (print_gdb_version): Add "interactive" parameter.
1998 * main.c (captured_main_1): Update.
1999 * top.h (print_gdb_version): Add "interactive" parameter and a
2002 2018-06-05 David Malcolm <dmalcolm@redhat.com>
2004 * common/enum-flags.h: Add trailing semicolon to example in
2007 2018-06-05 Tom Tromey <tom@tromey.com>
2010 * NEWS: Add entry about pager.
2011 * utils.c (pagination_disabled_for_command): New global.
2012 (prompt_for_continue): Allow "c" response to prompt.
2013 (reinitialize_more_filter): Clear
2014 pagination_disabled_for_command.
2015 (fputs_maybe_filtered): Check pagination_disabled_for_command.
2017 2018-06-04 Tom Tromey <tom@tromey.com>
2019 * ada-lang.h (ada_lookup_symbol_list): Update.
2020 * ada-lang.c (resolve_subexp): Update.
2021 (symbols_are_identical_enums): Change type of syms. Remove nsyms
2023 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
2024 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
2025 results parameter to std::vector.
2026 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
2028 * ada-exp.y (block_lookup): Update.
2029 (select_possible_type_sym): Change type of syms. Remove nsyms
2031 (write_var_or_type, write_name_assoc): Update.
2033 2018-06-04 Joel Brobecker <brobecker@adacore.com>
2035 * windows-nat.c (windows_nat_target::xfer_partial): Return
2036 TARGET_XFER_E_IO if we need to delegate to the target beneath
2037 but BENEATH is NULL.
2039 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
2041 * Makefile.in (config.status): Add configure.nat as a
2044 2018-06-04 Tom Tromey <tom@tromey.com>
2046 * cp-name-parser.y (cpname_state): Add method declarations.
2047 (HANDLE_QUAL): Update.
2048 (cpname_state::d_grab, cpname_state::fill_comp)
2049 (cpname_state::make_operator, cpname_state::make_dtor)
2050 (cpname_state::make_builtin_type, cpname_state::make_name)
2051 (cpname_state::d_qualify, cpname_state::d_int_type)
2052 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
2053 (%union): Move earlier.
2055 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2057 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
2059 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2061 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
2062 (aarch64_pseudo_write_1): Likewise.
2063 (aarch64_pseudo_read_value): Use helper.
2064 (aarch64_pseudo_write): Likewise.
2066 2018-06-04 Pedro Alves <palves@redhat.com>
2068 * darwin-nat.c (darwin_ops): Delete.
2069 (darwin_attach_pid): Use get_native_target.
2071 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2073 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
2074 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
2076 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2078 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
2079 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
2080 (aarch64_gdbarch_init): Check for SVE.
2081 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
2083 2018-06-04 Alan Hayward <alan.hayward@arm.com>
2085 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
2086 * aarch64-tdep.h (aarch64_read_description): Likewise.
2087 * arch/aarch64.c (aarch64_create_target_description): Likewise.
2088 * arch/aarch64.h (aarch64_create_target_description): Likewise.
2089 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
2090 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
2091 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
2093 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
2095 * value.c (value_fetch_lazy_bitfield): New.
2096 (value_fetch_lazy_memory): New.
2097 (value_fetch_lazy_register): New.
2098 (value_fetch_lazy): Factor out to smaller functions.
2100 2018-06-01 Tom Tromey <tom@tromey.com>
2102 * cp-name-parser.y (backslashable, represented): Now const.
2104 2018-06-01 Tom Tromey <tom@tromey.com>
2106 * cp-name-parser.y: Include parser-defs.h.
2107 (parser_fprintf): Remove declaration.
2109 2018-06-01 Tom Tromey <tom@tromey.com>
2111 * cp-name-parser.y: Use %pure-parser, %lex-param, and
2113 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
2114 (global_result): Remove globals.
2115 (struct cpname_state): New.
2116 (yyparse): Don't declare.
2117 (yylex, yyerror): Move declarations after %union.
2118 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
2119 (make_name): Add state parameter.
2121 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
2123 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
2125 (yylex): Add lvalp, state parameters.
2126 (yyerror): Add state parameter.
2127 (cp_demangled_name_to_comp): Update.
2129 2018-06-01 Tom Tromey <tom@tromey.com>
2131 * cp-name-parser.y (parser_fprintf): Declare.
2132 (GDB_YY_REMAP_PREFIX): Define.
2133 Include yy-remap.h. Don't redefine yy* identifiers.
2135 2018-06-01 Tom Tromey <tom@tromey.com>
2137 * python/py-type.c (typy_legacy_template_argument): Update.
2138 * cp-support.h (cp_demangled_name_to_comp): Update.
2139 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
2140 parameter to be a "std::string *".
2143 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
2145 * ada-lex.l: Include "diagnostics.h" instead of
2146 "common/diagnostics.h".
2147 * unittests/environ-selftests.c: Likewise.
2148 * common/diagnostics.h: Moved to ../include.
2150 2018-06-01 Joel Brobecker <brobecker@adacore.com>
2152 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
2153 to language_mode_manual while calling breakpoint_re_set_one.
2155 2018-06-01 Tom Tromey <tom@tromey.com>
2157 * valops.c (value_cast_structs, destructor_name_p): Update.
2158 * symtab.c (gdb_mangle_name): Update.
2159 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
2161 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
2162 (pascal_object_print_value_fields, pascal_object_print_value):
2164 * p-typeprint.c (pascal_type_print_derivation_info): Update.
2165 * linespec.c (find_methods): Update.
2166 * gdbtypes.h (type_name_no_tag): Remove.
2167 (type_name_or_error): Rename from type_name_no_tag_or_error.
2168 * gdbtypes.c (type_name_no_tag): Remove.
2169 (type_name_or_error): Rename from type_name_no_tag_or_error.
2170 (lookup_struct_elt_type, check_typedef): Update.
2171 * expprint.c (print_subexp_standard): Update.
2172 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
2173 * d-namespace.c (d_lookup_nested_symbol): Update.
2174 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
2175 (cp_print_class_member): Update.
2176 * cp-namespace.c (cp_lookup_nested_symbol): Update.
2177 * completer.c (add_struct_fields): Update.
2178 * c-typeprint.c (cp_type_print_derivation_info)
2179 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
2181 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
2182 (ada_prefer_type, ada_is_exception_sym): Update.
2184 2018-06-01 Tom Tromey <tom@tromey.com>
2186 * valops.c (enum_constant_from_type, value_namespace_elt)
2187 (value_maybe_namespace_elt): Update.
2188 * valarith.c (find_size_for_pointer_math): Update.
2189 * target-descriptions.c (make_gdb_type): Update.
2190 * symmisc.c (print_symbol): Update.
2191 * stabsread.c (define_symbol, read_type)
2192 (complain_about_struct_wipeout, add_undefined_type)
2193 (cleanup_undefined_types_1): Update.
2194 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
2195 (rust_range_type_p, val_print_struct, rust_print_struct_def)
2196 (rust_internal_print_type, rust_composite_type)
2197 (rust_evaluate_funcall, rust_evaluate_subexp)
2198 (rust_inclusive_range_type_p): Update.
2199 * python/py-type.c (typy_get_tag): Update.
2200 * p-typeprint.c (pascal_type_print_base): Update.
2201 * mdebugread.c (parse_symbol, parse_type): Update.
2202 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
2204 * guile/scm-type.c (gdbscm_type_tag): Update.
2205 * go-lang.c (sixg_string_p): Update.
2206 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
2208 * gdbtypes.h (struct main_type) <tag_name>: Remove.
2209 (TYPE_TAG_NAME): Remove.
2210 * gdbtypes.c (type_name_no_tag): Simplify.
2211 (check_typedef, check_types_equal, recursive_dump_type)
2212 (copy_type_recursive, arch_composite_type): Update.
2213 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
2214 in summary mode when needed.
2215 * eval.c (evaluate_funcall): Update.
2216 * dwarf2read.c (fixup_go_packaging, read_structure_type)
2217 (process_structure_scope, read_enumeration_type)
2218 (read_namespace_type, read_module_type, determine_prefix): Update.
2219 * cp-support.c (inspect_type): Update.
2220 * coffread.c (process_coff_symbol, decode_base_type): Update.
2221 * c-varobj.c (c_is_path_expr_parent): Update.
2222 * c-typeprint.c (c_type_print_base_struct_union): Update.
2223 (c_type_print_base_1): Update. Print struct/class/union/enum in
2224 summary when using C language.
2225 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
2226 (gen_maybe_namespace_elt): Update.
2227 * ada-lang.c (ada_type_name): Simplify.
2228 (empty_record, ada_template_to_fixed_record_type_1)
2229 (template_to_static_fixed_type)
2230 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
2232 2018-06-01 Tom Tromey <tom@tromey.com>
2234 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
2236 * c-typeprint.c (c_print_type_1): Add "language" parameter.
2237 (c_print_type): Update.
2238 (c_print_type): New overload.
2239 (c_type_print_varspec_prefix, c_type_print_args)
2240 (c_type_print_varspec_suffix, c_print_type_no_offsets)
2241 (c_type_print_base_struct_union, c_type_print_base_1)
2242 (cp_type_print_method_args): Add "language" parameter.
2243 (c_type_print_base): Update.
2244 * c-lang.h (c_print_type): Add new overload.
2246 2018-06-01 Tom Tromey <tom@tromey.com>
2248 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
2249 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
2251 2018-06-01 Alan Hayward <alan.hayward@arm.com>
2253 * aarch64-tdep.c (aarch64_sve_register_names): New const
2255 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
2256 (AARCH64_SVE_Z_REGS_NUM): New define.
2257 (AARCH64_SVE_P_REGS_NUM): Likewise.
2258 (AARCH64_SVE_NUM_REGS): Likewise.
2260 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
2262 * nat/linux-ptrace.h [__alpha__]
2263 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
2266 2018-05-31 Maciej W. Rozycki <macro@mips.com>
2268 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
2269 the endianness selected.
2270 * NEWS: Document `set endian auto' mode operation update.
2272 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2274 * Makefile.in: Add new header.
2275 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
2276 (sve_vl_from_vg): Likewise.
2277 (sve_vq_from_vl): Likewise.
2278 (sve_vl_from_vq): Likewise.
2279 (sve_vq_from_vg): Likewise.
2280 (sve_vg_from_vq): Likewise.
2281 * configure.nat: Add new c file.
2282 * nat/aarch64-sve-linux-ptrace.c: New file.
2283 * nat/aarch64-sve-linux-ptrace.h: New file.
2285 2018-05-31 Alan Hayward <alan.hayward@arm.com>
2287 * aarch64-linux-nat.c (aarch64_linux_read_description):
2289 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
2291 * aarch64-tdep.c (tdesc_aarch64_list): Add.
2292 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
2293 (aarch64_gdbarch_init): Add parmeter zero.
2294 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
2295 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
2296 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
2298 * doc/gdb.texinfo: Describe SVE feature
2299 * features/aarch64-sve.c: New file.
2301 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
2304 * gdbarch.sh (significant_addr_bit): Default to zero when
2305 not set by target architecture.
2306 * gdbarch.c: Re-generated.
2307 * utils.c (address_significant): Update.
2309 2018-05-30 Joel Brobecker <brobecker@adacore.com>
2311 * stack.c (func_command): Remove trailing newline in call to error.
2313 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2315 * regcache.h (regcache_raw_collect): Remove, update callers to
2316 use regcache::raw_collect.
2317 * regcache.c (regcache_raw_collect): Remove.
2319 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2321 * regcache.h (regcache_raw_supply): Remove, update callers to
2322 use detached_regcache::raw_supply.
2323 * regcache.c (regcache_raw_supply): Remove.
2325 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2327 * regcache.h (regcache_cooked_write_part): Remove, update
2328 callers to use regcache::cooked_write_part.
2329 * regcache.c (regcache_cooked_write_part): Remove.
2331 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2333 * regcache.h (regcache_cooked_read_part): Remove, update callers
2334 to use readable_regcache::cooked_read_part.
2335 * regcache.c (regcache_cooked_read_part): Remove.
2337 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2339 * regcache.h (regcache_cooked_read_value): Remove, update
2340 callers to use readable_regcache::cooked_read_value.
2341 * regcache.c (regcache_cooked_read_value): Remove.
2343 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2345 * regcache.h (regcache_cooked_write): Remove, update callers to
2346 use regcache::cooked_write.
2347 * regcache.c (regcache_cooked_write): Remove.
2349 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2351 * regcache.h (regcache_invalidate): Remove, update callers to
2352 use detached_regcache::invalidate instead.
2353 * regcache.c (regcache_invalidate): Remove.
2355 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2357 * regcache.h (regcache_raw_write_part): Remove, update callers
2358 to use regcache::raw_write_part instead.
2359 * regcache.c (regcache_raw_write_part): Remove.
2361 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2363 * regcache.h (regcache_raw_read_part): Remove, update callers to
2364 use readable_regcache::raw_read_part instead.
2365 * regcache.c (regcache_raw_read_part): Remove.
2367 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2369 * regcache.h (regcache_cooked_read): Remove, update callers to
2370 use readable_regcache::cooked_read instead.
2371 * regcache.c (regcache_cooked_read): Remove.
2373 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2375 * regcache.h (regcache_raw_write): Remove, update callers to use
2376 regcache::raw_write instead.
2377 * regcache.c (regcache_raw_write): Remove.
2379 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2381 * regcache.h (regcache_raw_read): Remove, update callers to use
2382 readable_regcache::raw_read instead.
2383 * regcache.c (regcache_raw_read): Remove.
2385 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2387 * regcache.h (regcache_raw_update): Remove, update callers to
2388 use readable_regcache::raw_update instead.
2389 * regcache.c (regcache_raw_update): Remove.
2391 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2393 * regcache.h (regcache_register_status): Remove, update callers
2394 to use reg_buffer::get_register_status directly instead.
2395 * regcache.c (regcache_register_status): Remove.
2397 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2399 * regcache.h (regcache_get_ptid): Remove, update all callers to
2400 call regcache::ptid instead.
2401 * regcache.c (regcache_get_ptid): Remove.
2403 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
2405 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
2407 2018-05-30 Pedro Alves <palves@redhat.com>
2409 * common/common-exceptions.h (exception_rethrow): Use
2412 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
2414 * breakpoint.c (print_solib_event, check_status_catch_solib):
2415 Remove struct keyword in range-based for loops.
2416 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
2417 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
2419 * linespec.c (find_superclass_methods, search_minsyms_for_name):
2421 * symfile.c (addr_info_make_relative): Likewise.
2422 * thread.c (value_in_thread_stack_temporaries): Likewise.
2424 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
2427 * valops.c (value_struct_elt_for_reference): Call check_typedef on
2428 aggregate type to get its real type before accessing it.
2430 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
2432 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
2433 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
2434 * coff-pe-read.c (add_pe_forwarded_sym): Replace
2435 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
2436 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
2437 * jit.c (jit_breakpoint_re_set_internal): Likewise.
2438 * printcmd.c (info_address_command): Likewise.
2440 2018-05-29 Tom Tromey <tom@tromey.com>
2442 * windows-nat.c (handle_exception): Update fall-through comment.
2444 2018-05-29 Tom Tromey <tom@tromey.com>
2446 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
2447 (struct program_space) <added_solibs>: Now a std::vector.
2448 * breakpoint.c (print_solib_event): Update.
2449 (check_status_catch_solib): Update.
2450 * progspace.c (clear_program_space_solib_cache): Update.
2451 * solib.c (update_solib_list): Update.
2453 2018-05-29 Tom Tromey <tom@tromey.com>
2455 * python/py-type.c (typy_richcompare): Update.
2456 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
2457 * gdbtypes.h (types_deeply_equal): Return bool.
2458 (types_equal): Likewise.
2459 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
2461 (check_types_equal): Change worklist to std::vector. Return
2463 (struct type_equality_entry): Add constructor.
2464 (compare_maybe_null_strings): Return bool.
2465 (check_types_worklist): Return bool. Change worklist to
2467 (types_deeply_equal): Use std::vector.
2468 (types_equal): Return bool.
2469 (compare_maybe_null_strings): Simplify.
2471 2018-05-29 Tom Tromey <tom@tromey.com>
2473 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
2475 2018-05-29 Tom Tromey <tom@tromey.com>
2477 * objc-lang.h: Don't include cp-support.h.
2478 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
2481 2018-05-27 Tom Tromey <tom@tromey.com>
2483 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
2485 2018-05-25 Tom Tromey <tom@tromey.com>
2487 * value.c (value::location): Initialize.
2489 2018-05-25 Tom Tromey <tom@tromey.com>
2491 * dbxread.c (init_bincl_list): Remove.
2492 (bincl_list): Now a std::vector.
2493 (bincls_allocated, next_bincl): Remove.
2494 (free_bincl_list, do_free_bincl_list_cleanup)
2495 (make_cleanup_free_bincl_list): Remove.
2496 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
2498 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
2499 (struct header_file_location): Add constructor.
2500 (add_bincl_to_list): Remove.
2502 2018-05-25 Tom Tromey <tom@tromey.com>
2504 * tui/tui.c (tui_enable): Update.
2505 * mi/mi-interp.c (mi_interp::init): Update.
2506 * interps.h (class interp) <name>: New method.
2507 <m_name>: Rename from name.
2508 (~scoped_restore_interp): Update.
2509 * interps.c (interp::interp): Update.
2510 (interp_add, interp_set, interp_lookup_existing)
2511 (current_interp_named_p): Update.
2513 2018-05-25 Tom Tromey <tom@tromey.com>
2515 * interps.c (interp_name): Remove.
2516 * mi/mi-interp.c (mi_interp::init): Update.
2517 * interps.h (interp_name): Remove.
2518 (~scoped_restore_interp): Update.
2519 * tui/tui.c (tui_enable): Update.
2521 2018-05-25 Tom Tromey <tom@tromey.com>
2523 * utils.c (fputs_maybe_filtered): Update.
2524 * linespec.c (decode_line_full): Update.
2525 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
2526 (mi_print_breakpoint_for_event, mi_solib_loaded)
2527 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
2528 (mi_user_selected_context_changed): Update.
2529 * mi/mi-main.c (mi_execute_command): Update.
2530 * cli/cli-script.c (execute_control_command): Update.
2531 * python/python.c (execute_gdb_command): Update.
2532 * solib.c (info_sharedlibrary_command): Update.
2533 * interps.c (interp_ui_out): Remove.
2534 * interps.h (interp_ui_out): Remove.
2536 2018-05-25 Tom Tromey <tom@tromey.com>
2538 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
2539 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
2540 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
2542 2018-05-25 Tom Tromey <tom@tromey.com>
2544 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
2545 * interps.c (interp_exec): Use scoped_restore.
2547 2018-05-25 Tom Tromey <tom@tromey.com>
2549 * remote.c (remote_target::remote_file_get): Use
2551 (remote_target::remote_file_put): Likewise.
2553 2018-05-25 Tom Tromey <tom@tromey.com>
2555 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
2557 (get_pe_section_index, add_pe_exported_sym): Update.
2558 (read_pe_exported_syms): Use gdb::def_vector.
2560 2018-05-25 Tom Tromey <tom@tromey.com>
2562 * frame.c (remove_prev_frame): Remove.
2563 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
2565 2018-05-25 Maciej W. Rozycki <macro@mips.com>
2567 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
2569 * mips-linux-nat.c (supply_fpregset): Always call
2570 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
2571 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
2572 `mips_fill_fpregset'.
2573 * mips-linux-tdep.c (mips_supply_fpregset)
2574 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
2575 (mips_fill_fpregset_wrapper): Remove functions.
2576 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
2577 (mips_linux_fpregset): Remove variable.
2578 (mips_linux_iterate_over_regset_sections): Use
2579 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
2580 (mips_linux_o32_sigframe_init): Remove comment.
2582 2018-05-25 Pedro Alves <palves@redhat.com>
2584 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
2585 (struct readahead_cache, struct packet_reg, struct
2586 remote_arch_state, class remote_state): Move higher up in the
2588 (remote_target::m_remote_state): Now an object instead of a pointer.
2589 (remote_target::get_remote_state): Adjust.
2591 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2593 * stack.c (select_and_print_frame): Delete.
2594 (struct function_bounds): Move struct within function.
2595 (func_command): Most content moved into new function
2596 find_frame_for_function, use new function, print result, add
2598 (find_frame_for_function): New function, now returns a result.
2600 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2602 * stack.c (iterate_over_block_arg_vars): Fix comment.
2603 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
2605 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
2609 (scoped_restore_selected_frame::scoped_restore_selected_frame):
2611 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
2613 * frame.h (class scoped_restore_selected_frame): New class.
2614 * stack.c (print_frame_local_vars): Remove catching and rethrowing
2615 of any exception, use scoped_restore_selected_frame to restore the
2618 2018-05-24 Pedro Alves <palves@redhat.com>
2620 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
2623 2018-05-23 Tom Tromey <tom@tromey.com>
2625 * complaints.c (struct complaints): Remove.
2626 (symfile_complaint_book): Remove.
2627 (series): New global.
2628 (complaint_internal): Update.
2629 (clear_complaints): Update.
2631 2018-05-23 Tom Tromey <tom@tromey.com>
2633 * complaints.c (counters): New global.
2634 (struct complain): Remove.
2635 (struct complaints) <root>: Remove.
2636 (complaint_sentinel): Remove.
2637 (symfile_complaint_book): Update.
2638 (find_complaint) Remove.
2639 (complaint_internal, clear_complaints): Update.
2641 2018-05-23 Tom Tromey <tom@tromey.com>
2643 * complaints.c (struct complain) <file, line>: Remove.
2644 (find_complaint): Remove file, line parameters.
2645 (complaint_internal): Update.
2647 2018-05-23 Tom Tromey <tom@tromey.com>
2649 * complaints.c (vcomplaint): Remove.
2650 (complaint_internal) Merge in contents of vcomplaint.
2652 2018-05-23 Tom Tromey <tom@tromey.com>
2654 * complaints.c (struct complaints) <explanation>: Remove.
2655 (symfile_explanations): Remove.
2656 (symfile_complaint_book): Update.
2657 (vcomplaint): Update.
2658 (struct explanation): Remove.
2660 2018-05-23 Tom Tromey <tom@tromey.com>
2662 * complaints.c (symfile_complaints): Remove.
2663 (complaint_internal): Remove "complaints" parameter.
2664 (clear_complaints, vcomplaint): Remove "c" parameter.
2665 (get_complaints): Remove.
2666 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
2667 (dwarf2_debug_line_missing_file_complaint)
2668 (dwarf2_debug_line_missing_end_sequence_complaint)
2669 (dwarf2_complex_location_expr_complaint)
2670 (dwarf2_const_value_length_mismatch_complaint)
2671 (dwarf2_section_buffer_overflow_complaint)
2672 (dwarf2_macro_malformed_definition_complaint)
2673 (dwarf2_invalid_attrib_class_complaint)
2674 (create_addrmap_from_index, dw2_symtab_iter_next)
2675 (dw2_expand_marked_cus)
2676 (dw2_debug_names_iterator::find_vec_in_debug_names)
2677 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
2678 (create_debug_type_hash_table, init_cutu_and_read_dies)
2679 (partial_die_parent_scope, add_partial_enumeration)
2680 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
2681 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
2682 (read_import_statement, read_file_scope, create_dwo_cu_reader)
2683 (create_cus_hash_table, create_dwp_hash_table)
2684 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
2685 (dwarf2_rnglists_process, dwarf2_ranges_process)
2686 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
2687 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
2688 (handle_struct_member_die, process_structure_scope)
2689 (read_array_type, read_common_block, read_module_type)
2690 (read_tag_pointer_type, read_typedef, read_base_type)
2691 (read_subrange_type, load_partial_dies, partial_die_info::read)
2692 (partial_die_info::read, partial_die_info::read)
2693 (partial_die_info::read, read_checked_initial_length_and_offset)
2694 (dwarf2_string_attr, read_formatted_entries)
2695 (dwarf_decode_line_header)
2696 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2697 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
2698 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
2699 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2700 (get_signatured_type, get_DW_AT_signature_type)
2701 (decode_locdesc, file_file_name, consume_improper_spaces)
2702 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
2703 (dwarf_decode_macro_bytes, dwarf_decode_macros)
2704 (dwarf2_symbol_mark_computed, set_die_type)
2705 (read_attribute_value): Update.
2706 * stap-probe.c (handle_stap_probe, get_stap_base_address):
2708 * dbxread.c (unknown_symtype_complaint)
2709 (lbrac_mismatch_complaint, repeated_header_complaint)
2710 (set_namestring, function_outside_compilation_unit_complaint)
2711 (read_dbx_symtab, process_one_symbol): Update.
2712 * gdbtypes.c (stub_noname_complaint): Update.
2713 * windows-nat.c (handle_unload_dll): Update.
2714 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
2715 (decode_base_type): Update.
2716 * xcoffread.c (bf_notfound_complaint, ef_complaint)
2717 (eb_complaint, record_include_begin, record_include_end)
2718 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
2719 (process_xcoff_symbol, read_symbol)
2720 (function_outside_compilation_unit_complaint)
2721 (scan_xcoff_symtab): Update.
2722 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
2723 * buildsym.c (finish_block_internal, make_blockvector)
2724 (end_symtab_get_static_block, augment_type_symtab): Update.
2725 * dtrace-probe.c (dtrace_process_dof)
2726 (dtrace_static_probe_ops::get_probes): Update.
2727 * complaints.h (struct complaint): Don't declare.
2728 (symfile_complaints): Remove.
2729 (complaint_internal): Remove "complaints" parameter.
2730 (complaint): Likewise.
2731 (clear_complaints): Likewise.
2732 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2733 (reread_symbols): Update.
2734 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2735 (dwarf2_frame_cache, decode_frame_entry): Update.
2736 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
2737 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2738 (info_selectors_command): Update.
2739 * macrotab.c (macro_include, check_for_redefinition)
2740 (macro_undef): Update.
2741 * objfiles.c (filter_overlapping_sections): Update.
2742 * stabsread.c (invalid_cpp_abbrev_complaint)
2743 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
2744 (define_symbol, error_type, read_type, rs6000_builtin_type)
2745 (stabs_method_name_from_physname, read_member_functions)
2746 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
2747 (attach_fields_to_type, complain_about_struct_wipeout)
2748 (read_range_type, read_args, common_block_start)
2749 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
2751 * mdebugread.c (index_complaint, unknown_ext_complaint)
2752 (basic_type_complaint, bad_tag_guess_complaint)
2753 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
2754 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
2755 (parse_procedure, parse_lines)
2756 (function_outside_compilation_unit_complaint)
2757 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
2758 (bad_tag_guess_complaint, reg_value_complaint): Update.
2759 * cp-support.c (demangled_name_complaint): Update.
2760 * macroscope.c (sal_macro_scope): Update.
2761 * dwarf-index-write.c (class debug_names): Update.
2763 2018-05-23 Tom Tromey <tom@tromey.com>
2765 * complaints.c (clear_complaints): Remove "noisy" parameter.
2766 * complaints.h (clear_complaints): Update.
2767 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2768 (reread_symbols): Update.
2770 2018-05-23 Tom Tromey <tom@tromey.com>
2772 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
2774 (vcomplaint, clear_complaints): Update.
2775 (symfile_explanations): Remove some messages.
2777 2018-05-23 Tom Tromey <tom@tromey.com>
2779 * complaints.c (internal_complaint): Remove.
2780 * complaints.h (internal_complaint): Remove.
2782 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2784 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
2786 2018-05-22 Pedro Alves <palves@redhat.com>
2788 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
2789 (remote_fileio_badfd, remote_fileio_return_errno)
2790 (remote_fileio_return_success, remote_fileio_func_open)
2791 (remote_fileio_func_open, remote_fileio_func_close)
2792 (remote_fileio_func_read, remote_fileio_func_write)
2793 (remote_fileio_func_lseek, remote_fileio_func_rename)
2794 (remote_fileio_func_unlink, remote_fileio_func_stat)
2795 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
2796 (remote_fileio_func_isatty, remote_fileio_func_system): Add
2797 remote_target parameter.
2798 (remote_fio_func_map) <func>: Add remote_target parameter.
2799 (do_remote_fileio_request, remote_fileio_request):
2800 * remote-fileio.h (remote_fileio_request):
2801 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
2802 remote_target parameter.
2803 (remote_notif_process, handle_notification): Adjust to pass down
2805 (remote_notif_state_allocate): Add remote_target parameter. Save
2807 * remote-notif.h (struct remote_target): Forward declare.
2808 (struct notif_client) <parse, ack, can_get_pending_events>: Add
2809 remote_target parameter.
2810 (struct remote_notif_state) <remote>: New field.
2811 (remote_notif_ack, remote_notif_parse): Add remote_target
2813 (remote_notif_state_allocate, remote_notif_state_allocate): Add
2814 remote_target parameter.
2815 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
2816 (threads_listing_context, rmt_thread_action, protocol_feature)
2817 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
2818 (packet_result, struct threads_listing_context, remote_state):
2819 Move definitions and declarations higher up.
2820 (remote_target) <~remote_target>: Declare.
2821 (remote_download_command_source, remote_file_put, remote_file_get)
2822 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
2823 (remote_hostio_pread_vFile, remote_hostio_send_command)
2824 (remote_hostio_set_filesystem, remote_hostio_open)
2825 (remote_hostio_close, remote_hostio_unlink, remote_state)
2826 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
2827 (get_memory_write_packet_size, get_memory_read_packet_size)
2828 (append_pending_thread_resumptions, remote_detach_1)
2829 (append_resumption, remote_resume_with_vcont)
2830 (add_current_inferior_and_thread, wait_ns, wait_as)
2831 (process_stop_reply, remote_notice_new_inferior)
2832 (process_initial_stop_replies, remote_add_thread)
2833 (btrace_sync_conf, remote_btrace_maybe_reopen)
2834 (remove_new_fork_children, kill_new_fork_children)
2835 (discard_pending_stop_replies, stop_reply_queue_length)
2836 (check_pending_events_prevent_wildcard_vcont)
2837 (discard_pending_stop_replies_in_queue, stop_reply)
2838 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
2839 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
2840 (remote_interrupt_as, remote_interrupt_ns)
2841 (remote_get_noisy_reply, remote_query_attached)
2842 (remote_add_inferior, remote_current_thread, get_current_thread)
2843 (set_thread, set_general_thread, set_continue_thread)
2844 (set_general_process, write_ptid)
2845 (remote_unpack_thread_info_response, remote_get_threadinfo)
2846 (parse_threadlist_response, remote_get_threadlist)
2847 (remote_threadlist_iterator, remote_get_threads_with_ql)
2848 (remote_get_threads_with_qxfer)
2849 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
2850 (get_offsets, remote_check_symbols, remote_supported_packet)
2851 (remote_query_supported, remote_packet_size)
2852 (remote_serial_quit_handler, remote_detach_pid)
2853 (remote_vcont_probe, remote_resume_with_hc)
2854 (send_interrupt_sequence, interrupt_query)
2855 (remote_notif_get_pending_events, fetch_register_using_p)
2856 (send_g_packet, process_g_packet, fetch_registers_using_g)
2857 (store_register_using_P, store_registers_using_G)
2858 (set_remote_traceframe, check_binary_download)
2859 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
2860 (remote_xfer_live_readonly_partial, remote_read_bytes)
2861 (remote_send_printf, remote_flash_write, readchar)
2862 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
2863 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
2864 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
2865 (extended_remote_disable_randomization, extended_remote_run)
2866 (send_environment_packet, extended_remote_environment_support)
2867 (extended_remote_set_inferior_cwd, remote_write_qxfer)
2868 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
2869 (packet_command): Now methods of ...
2870 (remote_target): ... this class.
2871 (m_remote_state) <remote_target>: New field.
2872 (struct remote_state) <stop_reply_queue,
2873 remote_async_inferior_event_token, wait_forever_enabled_p>: New
2875 (remote_state::remote_state): Allocate stop_reply_queue.
2876 (remote_state): Delete global.
2877 (get_remote_state_raw): Delete.
2878 (remote_target::get_remote_state): Allocate m_remote_state on
2880 (get_current_remote_target): New.
2881 (remote_ops, extended_remote_ops): Delete.
2882 (wait_forever_enabled_p, remote_async_inferior_event_token):
2883 Delete, moved to struct remote_state.
2884 (remote_target::close): Delete self. Destruction bits split to
2886 (remote_target::~remote_target): ... this.
2887 (show_memory_packet_size): Adjust to use
2888 get_current_remote_target.
2889 (struct protocol_feature) <func>: Add remote_target parameter.
2890 All callers adjusted.
2891 (curr_quit_handler_target): New.
2892 (remote_serial_quit_handler): Reimplement.
2893 (remote_target::open_1): Adjust to use get_current_remote_target.
2894 Heap-allocate remote_target/extended_remote_target instances.
2895 (vcont_builder::vcont_builder): Add remote_target parameter, and
2896 save it in m_remote. All callers adjusted.
2897 (vcont_builder::m_remote): New field.
2898 (vcont_builder::restart, vcont_builder::flush)
2899 (vcont_builder::push_action): Use it.
2900 (remote_target::commit_resume): Use it.
2901 (struct queue_iter_param) <remote>: New field.
2902 (remote_target::remove_new_fork_children): Fill in 'remote' field.
2903 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
2904 (check_pending_event_prevents_wildcard_vcont_callback)
2905 (remote_target::check_pending_events_prevent_wildcard_vcont)
2906 (remote_target::discard_pending_stop_replies)
2907 (remote_target::discard_pending_stop_replies_in_queue)
2908 (remote_target::remote_notif_remove_queued_reply): Fill in
2910 (remote_notif_get_pending_events): New.
2911 (remote_target::readchar, remote_target::remote_serial_write):
2912 Save/restore curr_quit_handler_target.
2914 (kill_new_fork_children): Fill in 'remote' field.
2915 (packet_command): Use get_current_remote_target, defer to
2916 remote_target method of same name.
2917 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
2918 parameter, and save it in m_remote. All callers adjusted.
2919 (scoped_remote_fd::release): Use m_remote.
2920 (scoped_remote_fd::m_remote): New field.
2921 (remote_file_put, remote_file_get, remote_file_delete): Use
2922 get_current_remote_target, defer to remote_target method of same
2924 (remote_btrace_reset): Add remote_state paremeter. Update all
2926 (remote_async_inferior_event_handler). Pass down 'data'.
2927 (remote_new_objfile): Use get_current_remote_target.
2928 (remote_target::vcont_r_supported): New.
2929 (set_range_stepping): Use get_current_remote_target and
2930 remote_target::vcont_r_supported.
2931 (_initialize_remote): Don't allocate 'remote_state' and
2932 'stop_reply_queue' globals.
2933 * remote.h (struct remote_target): Forward declare.
2934 (getpkt, putpkt, remote_notif_get_pending_events): Add
2935 'remote_target' parameter.
2937 2018-05-22 Pedro Alves <palves@redhat.com>
2939 * remote.c (vcont_builder): Now a class. Make all data members
2941 (vcont_builder) <vcont_builder, restart, flush, push_action>:
2943 (vcont_builder_restart): Rename to ...
2944 (vcont_builder::restart): ... this.
2945 (vcont_builder_flush): Rename to ...
2946 (vcont_builder::flush): ... this.
2947 (vcont_builder_push_action): Rename to ...
2948 (vcont_builder::push_action): ... this.
2949 (remote_target::commit_resume): Adjust.
2951 2018-05-22 Pedro Alves <palves@redhat.com>
2953 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
2954 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
2955 (get_fixed_memory_packet_size): New.
2956 (get_memory_packet_size): Use it.
2957 (set_memory_packet_size): Don't override the config size with
2958 DEFAULT_MAX_MEMORY_PACKET_SIZE.
2959 (show_memory_packet_size): Use get_fixed_memory_packet_size.
2960 Don't refer to get_memory_packet_size if not connected to a remote
2961 target. Show "(default)" if configured size is 0.
2963 2018-05-22 Pedro Alves <palves@redhat.com>
2965 * remote.c (remote_target::mourn_inferior): Move
2966 discard_pending_stop_replies call here from ...
2967 (_initialize_remote): ... here.
2969 2018-05-22 Pedro Alves <palves@redhat.com>
2971 * remote.c (compare_section_command): Remove set_general_process
2974 2018-05-22 Pedro Alves <palves@redhat.com>
2976 * remote.c (struct packet_reg, struct remote_arch_state):
2977 Move higher up in the file.
2978 (remote_state) <m_arch_states>: Store remote_arch_state values
2979 instead of remote_arch_state pointers.
2980 (remote_state::get_remote_arch_state): Adjust.
2982 2018-05-22 Pedro Alves <palves@redhat.com>
2984 * remote.c: Include <unordered_map>.
2985 (remote_state): Now a class.
2986 (remote_state) <get_remote_arch_state>: Declare method.
2987 <get_remote_arch_state>: New field.
2988 (remote_arch_state) <remote_arch_state>: Declare ctor.
2989 <regs>: Now a unique_ptr.
2990 (remote_gdbarch_data_handle): Delete.
2991 (get_remote_arch_state): Delete.
2992 (remote_state::get_remote_arch_state): New.
2993 (get_remote_state): Adjust to call remote_state's
2994 get_remote_arch_state method.
2995 (init_remote_state): Delete, bits factored out to ...
2996 (remote_arch_state::remote_arch_state): ... this new method.
2997 (get_remote_packet_size, get_memory_packet_size)
2998 (process_g_packet, remote_target::fetch_registers)
2999 (remote_target::prepare_to_store, store_registers_using_G)
3000 (remote_target::store_registers, remote_target::get_trace_status):
3001 Adjust to call remote_state's method.
3002 (_initialize_remote): Remove reference to
3003 remote_gdbarch_data_handle.
3005 2018-05-22 Pedro Alves <palves@redhat.com>
3007 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
3008 pread>: New method declarations.
3009 (remote_target::open_1): Adjust.
3010 (readahead_cache_invalidate): Rename to ...
3011 (readahead_cache::invalidate): ... this, and adjust to be a class
3013 (readahead_cache_invalidate_fd): Rename to ...
3014 (readahead_cache::invalidate_fd): ... this, and adjust to be a
3016 (remote_hostio_pwrite): Adjust.
3017 (remote_hostio_pread_from_cache): Rename to ...
3018 (readahead_cache::pread): ... this, and adjust to be a class
3020 (remote_hostio_close): Adjust.
3022 2018-05-22 Pedro Alves <palves@redhat.com>
3024 * remote.c (remote_hostio_close_cleanup): Delete.
3025 (class scoped_remote_fd): New.
3026 (remote_file_put, remote_file_get): Use it.
3028 2018-05-22 Pedro Alves <palves@redhat.com>
3030 (struct vCont_action_support): Use bool and initialize all fields.
3031 (struct readahead_cache): Initialize all fields.
3032 (remote_state): Use bool and initialize all fields.
3033 (remote_state::remote_state, remote_state::~remote_state): New.
3034 (new_remote_state): Delete.
3035 (_initialize_remote): Use new to allocate remote_state.
3037 2018-05-22 Pedro Alves <palves@redhat.com>
3041 * c-exp.y: Include "c-support.h".
3042 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
3043 of tolower. Use c_ident_is_alpha to scan names.
3044 * c-lang.c: Include "c-support.h".
3045 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
3046 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
3047 * c-support.h: New file, with bits factored out from ...
3048 * cp-name-parser.y: ... this file.
3049 Include "c-support.h".
3050 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
3051 c-support.h and renamed.
3052 (symbol_end, yylex): Adjust.
3054 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3056 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
3057 parameter type to CORE_ADDR.
3058 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
3059 parameter type in declaration to CORE_ADDR.
3060 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
3061 target_auxv_search to get AT_HWCAP and use the result to get the
3063 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
3064 to CORE_ADDR. Remove the cast of the return value to unsigned
3065 long. Fix error predicate of target_auxv_search.
3066 (ppc_linux_nat_target::read_description): Change the type of the
3067 hwcap variable to CORE_ADDR.
3069 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3071 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
3072 if the size of fpscr is larger than 32 bits.
3074 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3076 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
3077 (ppc32_linux_vsxregmap): New global.
3078 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
3079 regcache_supply_regset, and regcache_collect_regset.
3080 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
3081 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
3082 (fetch_vsx_register, store_vsx_register): Remove.
3083 (fetch_vsx_registers): Add regno parameter. Get regset using
3084 ppc_linux_vsxregset. Use regset to supply registers.
3085 (store_vsx_registers): Add regno parameter. Get regset using
3086 ppc_linux_vsxregset. Use regset to collect registers.
3087 (fetch_register): Call fetch_vsx_registers instead of
3089 (store_register): Call store_vsx_registers instead of
3091 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
3092 new regno parameter.
3093 (store_ppc_registers): Call store_vsx_registers with -1 for the
3094 new regno parameter.
3095 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
3096 (ppc_collect_vsxregset): Remove.
3098 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3100 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
3102 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
3103 for vector register offset fields.
3104 (ppc64_fbsd_reg_offsets): Likewise.
3105 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3106 to vector register offset fields.
3107 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
3108 to vector register offset fields.
3109 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
3110 vector register offset fields.
3111 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
3112 initializers for vector register offset fields.
3113 (rs6000_aix64_reg_offsets): Likewise.
3114 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
3115 (ppc_supply_vrregset): Remove.
3116 (ppc_collect_vrregset): Remove.
3117 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
3118 (ppc_linux_vrregset) : New function.
3119 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
3120 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
3121 (ppc32_linux_vrregset): Remove.
3122 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
3123 and use result instead of ppc32_linux_vrregset.
3124 (ppc32_linux_reg_offsets): Remove initializers for vector register
3126 (ppc64_linux_reg_offsets): Likewise.
3127 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
3128 * ppc-linux-nat.c: Include regset.h.
3129 (gdb_vrregset_t): Adjust comment to account for little-endian
3131 (supply_vrregset, fill_vrregset): Remove.
3132 (fetch_altivec_register, store_altivec_register): Remove.
3133 (fetch_altivec_registers): Add regno parameter. Get regset using
3134 ppc_linux_vrregset. Use regset to supply registers.
3135 (store_altivec_registers): Add regno parameter. Get regset using
3136 ppc_linux_vrregset. Use regset to collect registers.
3137 (fetch_register): Call fetch_altivec_registers instead of
3138 fetch_altivec_register.
3139 (store_register): Call store_altivec_registers instead of
3140 store_altivec_register.
3141 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
3142 the new regno parameter.
3143 (store_ppc_registers): Call store_altivec_registers with -1 for
3144 the new regno parameter.
3146 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3148 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
3149 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
3150 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
3151 (gdb_vrregset_t): Change array type size to
3152 PPC_LINUX_SIZEOF_VRREGSET.
3153 (gdb_vsxregset_t): Change array type size to
3154 PPC_LINUX_SIZEOF_VSXREGSET.
3155 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
3156 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
3157 PPC_LINUX_SIZEOF_VSXREGSET.
3159 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3161 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
3162 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
3164 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
3165 ppc_linux_target_wordsize with tid.
3166 (ppc_linux_nat_target::read_description): Call ppc_linux_target
3168 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
3169 (ppc64_64bit_inferior_p): Add static and inline specifiers.
3170 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
3171 tid parameter. Remove static specifier.
3172 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
3173 (ppc_linux_target_wordsize): New declaration.
3175 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
3177 * arch/ppc-linux-common.c: New file.
3178 * arch/ppc-linux-common.h: New file.
3179 * arch/ppc-linux-tdesc.h: New file.
3180 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
3181 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
3182 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
3183 arch/ppc-linux-tdesc.h.
3184 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
3185 arch/ppc-linux-tdesc.h.
3186 (ppc_linux_nat_target::read_description): Remove target
3187 description matching code. Fill a ppc_linux_features struct and
3188 call ppc_linux_match_description with it. Move comment about ISA
3189 2.05 to ppc-linux-common.c.
3190 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
3191 arch/ppc-linux-tdesc.h.
3192 (ppc_linux_core_read_description): Remove target description
3193 matching code. Fill a ppc_linux_features struct and call
3194 ppc_linux_match_description with it.
3195 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
3196 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
3197 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
3198 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
3199 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
3200 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
3201 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
3202 (tdesc_powerpc_e500l): Remove.
3204 2018-05-22 Joel Brobecker <brobecker@adacore.com>
3206 * ada-lang.c (catch_assert_command): Pass empty string instead
3207 of NULL for excep_string argument.
3209 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3211 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
3212 the width of the requested register exceeds the width of the
3215 2018-05-21 Tom Tromey <tom@tromey.com>
3217 * printcmd.c (output_command): Remove.
3218 (output_command_const): Rename to output_command.
3219 * valprint.h (output_command): Rename from output_command_const.
3220 * tracepoint.c (trace_dump_actions): Call output_command.
3222 2018-05-21 Tom Tromey <tom@tromey.com>
3224 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3225 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
3226 * ada-lang.h (create_ada_exception_catchpoint): Update.
3227 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
3229 (create_excep_cond_exprs, ~ada_catchpoint)
3230 (should_stop_exception, print_one_exception)
3231 (print_mention_exception, print_recreate_exception): Update.
3232 (ada_get_next_arg): Remove.
3233 (catch_ada_exception_command_split): Use std::string. Change type
3234 of "excep_string", "cond_string".
3235 (catch_ada_exception_command): Update.
3236 (create_ada_exception_catchpoint): Change type of excep_string.
3237 (ada_exception_sal): Remove excep_string parameter.
3238 (~ada_catchpoint): Remove.
3240 2018-05-21 Tom Tromey <tom@tromey.com>
3242 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
3245 2018-05-21 Tom Tromey <tom@tromey.com>
3247 * ada-lang.c (ada_exception_message_1, ada_exception_message):
3248 Return unique_xmalloc_ptr.
3249 (print_it_exception): Update.
3251 2018-05-21 Tom Tromey <tom@tromey.com>
3253 * tracepoint.c (trace_dump_actions): Use std::string.
3255 2018-05-21 Tom Tromey <tom@tromey.com>
3257 * symfile.c (reread_symbols): Use std::string for original_name.
3259 2018-05-21 Tom Tromey <tom@tromey.com>
3261 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
3262 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
3265 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
3267 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
3269 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
3270 * objfiles.c (get_objfile_bfd_data): Allocate
3271 objfile_per_bfd_storage with obstack_new when allocating on
3274 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3276 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
3278 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
3279 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
3280 * mdebugread.c (mdebug_build_psymtabs): Likewise.
3281 (add_pending): Likewise.
3282 (parse_symbol): Likewise.
3283 (parse_partial_symbols): Likewise.
3284 (psymtab_to_symtab_1): Likewise.
3285 (new_psymtab): Likewise.
3286 (elfmdebug_build_psymtabs): Likewise.
3287 * minsyms.c (terminate_minimal_symbol_table): Likewise.
3288 * objfiles.c (get_objfile_bfd_data): Likewise.
3289 (objfile_register_static_link): Likewise.
3290 * psymtab.c (allocate_psymtab): Likewise.
3291 * stabsread.c (read_member_functions): Likewise.
3292 * xcoffread.c (xcoff_end_psymtab): Likewise.
3294 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
3296 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
3297 compiler supports std::is_trivially_constructible.
3298 * common/poison.h: Include obstack.h.
3299 (IsMallocable): Define to is_trivially_constructible if the
3300 compiler supports it, define to true_type otherwise.
3304 (XOBNEWVEC): Redefine.
3305 * gdb_obstack.h (obstack_zalloc): New.
3306 (OBSTACK_ZALLOC): Redefine.
3307 (obstack_calloc): New.
3308 (OBSTACK_CALLOC): Redefine.
3310 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
3311 (gdbarch_obstack): New declaration in gdbarch.h, definition in
3313 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
3314 obstack_calloc/obstack_zalloc.
3315 (gdbarch_obstack_zalloc): Remove.
3316 * target-descriptions.c (tdesc_data_init): Use obstack_new.
3318 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3320 * stack.c (backtrace_command_1): Remove useless variable int i.
3322 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3324 * stack.c (print_frame_info): Fix comment.
3326 2018-05-18 Tom Tromey <tom@tromey.com>
3328 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
3329 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
3330 (~dwarf2_per_objfile): Update
3331 (dwarf2_get_dwz_file): Use new.
3332 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
3335 2018-05-18 Tom Tromey <tom@tromey.com>
3337 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
3339 * dwarf2read.c (struct dwp_file): Add constructor and
3341 (open_and_init_dwp_file): Return a unique_ptr.
3342 (dwarf2_per_objfile, create_dwp_hash_table)
3343 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
3344 (lookup_dwo_unit_in_dwp): Update.
3345 (open_and_init_dwp_file, get_dwp_file): Update.
3347 2018-05-18 Tom Tromey <tom@tromey.com>
3349 * dwarf2read.c (dwarf2_per_objfile): Update.
3350 (struct mapped_index): Add initializers.
3351 (dwarf2_read_index): Use new.
3352 (dw2_symtab_iter_init): Update.
3353 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
3356 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3358 * dwarf2read.c (mapped_index) <total_size>: Remove.
3360 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
3362 * unittests/format_pieces-selftests.c (test_format_specifier):
3365 2018-05-18 Tom Tromey <tom@tromey.com>
3367 * c-typeprint.c (maybe_print_hole): New function.
3368 (c_print_type_struct_field_offset): Update.
3369 (c_type_print_base_struct_union): Call maybe_print_hole.
3371 2018-05-17 Keith Seitz <keiths@redhat.com>
3373 * breakpoint.c (build_bpstat_chain): New function, moved from
3375 (bpstat_stop_status): Add optional parameter, `stop_chain'.
3376 If no stop chain is passed, call build_bpstat_chain to build it.
3377 * breakpoint.h (build_bpstat_chain): Declare.
3378 (bpstat_stop_status): Move documentation here from breakpoint.c.
3379 * infrun.c (handle_signal_stop): Before eliding inlined frames,
3380 build the stop chain and pass it to skip_inline_frames.
3381 Pass this stop chain to bpstat_stop_status.
3382 * inline-frame.c: Include breakpoint.h.
3383 (stopped_by_user_bp_inline_frame): New function.
3384 (skip_inline_frames): Add parameter `stop_chain'.
3385 Move documention to inline-frame.h.
3386 If non-NULL, use stopped_by_user_bp_inline_frame to determine
3387 whether the frame should be elided.
3388 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
3389 Add moved documentation and update for new parameter.
3391 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3394 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3395 unittests/format_pieces-selftests.c.
3396 * common/format.h (format_piece) <operator==>: New.
3397 (format_pieces) <operator[]>: Remove.
3398 * common/format.c (format_pieces::format_pieces): Handle \e.
3399 * unittests/format_pieces-selftests.c: New.
3401 2018-05-17 Tom Tromey <tom@tromey.com>
3404 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
3405 (dw2_instantiate_symtab): Add skip_partial parameter.
3406 (dw2_find_last_source_symtab, dw2_map_expand_apply)
3407 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
3408 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
3409 (dw2_expand_symtabs_matching_one)
3410 (dw2_find_pc_sect_compunit_symtab)
3411 (dw2_debug_names_lookup_symbol)
3412 (dw2_debug_names_expand_symtabs_for_function): Update.
3413 (init_cutu_and_read_dies): Add skip_partial parameter.
3414 (process_psymtab_comp_unit, build_type_psymtabs_1)
3415 (process_skeletonless_type_unit, load_partial_comp_unit)
3416 (psymtab_to_symtab_1): Update.
3417 (load_full_comp_unit): Add skip_partial parameter.
3418 (process_imported_unit_die, dwarf2_read_addr_index)
3419 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
3420 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
3421 (read_signatured_type): Update.
3423 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
3425 * value.c (release_value): Remove unused variable.
3426 (record_latest_value): Likewise.
3427 (access_value_history): Likewise.
3428 (preserve_values): Likewise.
3430 2018-05-17 Tom Tromey <tom@tromey.com>
3432 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
3435 2018-05-16 Maciej W. Rozycki <macro@mips.com>
3438 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
3439 Also handle registers whose width is not a multiple of
3441 (linux_nat_trad_target::store_register): Likewise.
3443 2018-05-16 Tom Tromey <tom@tromey.com>
3445 * gdbcore.h (core_bfd): Redefine.
3446 * corelow.c (core_target::close): Update.
3447 (core_target_open): Update.
3448 * progspace.h (struct program_space) <cbfd>: Now a
3451 2018-05-16 Tom Tromey <tom@tromey.com>
3454 * symfile-add-flags.h (enum symfile_add_flags)
3455 <SYMFILE_NOT_FILENAME>: New constant.
3456 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
3457 objfile name from BFD.
3458 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
3459 * minidebug.c (find_separate_debug_file_in_section): Put
3460 ".gnu_debugdata" into BFD's file name.
3462 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
3464 * regcache.c (regcache_read_ftype, regcache_write_ftype):
3467 2018-05-15 Tamar Christina <tamar.christina@arm.com>
3470 * aarch64-tdep.c (aarch64_analyze_prologue,
3471 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
3472 Indicate not interested in errors.
3474 2018-05-15 Maciej W. Rozycki <macro@mips.com>
3476 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
3477 Supply the MIPS_ZERO_REGNUM register.
3479 2018-05-15 Maciej W. Rozycki <macro@mips.com>
3481 * mips-tdep.c (mask_address_var): Make variable static.
3483 2018-05-14 Tom Tromey <tom@tromey.com>
3485 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
3487 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
3489 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
3490 FXSAVE_ADDR for the mxcsr register.
3492 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
3494 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
3496 2018-05-11 Pedro Alves <palves@redhat.com>
3498 * corelow.c (core_target) <core_target>: No longer inline.
3499 Initialize m_core_gdbarch, m_core_vec and build the section table
3501 <~core_target>: New.
3502 <core_gdbarch, get_core_register_section>: New methods.
3503 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
3504 factored out from ...
3505 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
3507 (sniff_core_bfd): Add gdbarch parameter.
3508 (core_close): Delete, merged into ...
3509 (core_target::close): ... here. Delete self.
3510 (core_close_cleanup): Delete.
3511 (core_target_open): Allocate a core_target on the heap. Use a
3512 unique_ptr instead of a cleanup. Bits moved into the core_target
3513 ctor. Adjust to use core_target methods instead of globals.
3514 (get_core_register_section): Rename to ...
3515 (core_target::get_core_register_section): ... this and adjust.
3516 (struct get_core_registers_cb_data): New.
3517 (get_core_registers_cb): Use it. Use bool.
3518 (core_target::fetch_registers, core_target::files_info)
3519 (core_target::xfer_partial, core_target::read_description)
3520 (core_target::pid_to, core_target::thread_name): Adjust to
3521 reference class fields instead of globals.
3522 * target.h (struct target_ops_deleter, target_ops_up): New.
3524 2018-05-11 Pedro Alves <palves@redhat.com>
3526 * corefile.c (core_file_command): Move to corelow.c.
3527 * corelow.c (the_core_target): Delete.
3528 (core_file_command): Moved from corefile.c. Check exec_bfd
3529 instead of the_core_target. Use target_detach instead of calling
3530 into the_core_target directly.
3531 (maybe_say_no_core_file_now): New.
3532 (core_target::detach): Use it.
3533 (_initialize_corelow): Remove references to the_core_target.
3534 * gdbcore.h (the_core_target): Delete.
3536 2018-05-11 Tom Tromey <tromey@redhat.com>
3537 Pedro Alves <palves@redhat.com>
3539 * corefile.c (core_bfd): Remove.
3540 * gdbcore.h (core_bfd): Now a macro.
3541 * progspace.h (struct program_space) <cbfd>: New field.
3543 2018-05-11 Tom Tromey <tom@tromey.com>
3545 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
3548 2018-05-10 Tom Tromey <tom@tromey.com>
3550 * configure: Rebuild.
3551 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
3553 2018-05-10 Joel Brobecker <brobecker@adacore.com>
3556 * regformats/regdat.sh: Adjust script, following the addition
3557 of the new expedite_regs parameter to init_target_desc.
3559 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
3562 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
3563 set_gdbarch_significant_addr_bit.
3564 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
3565 set_gdbarch_significant_addr_bit.
3566 * utils.c (address_significant): Update to sign extend addr.
3568 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
3570 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
3571 (xtensa_linux_init_abi): Limit tdep->num_regs by
3572 tdep->num_nopriv_regs.
3573 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
3574 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
3577 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
3579 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
3581 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
3583 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
3584 (I387_MXCSR_INIT_VAL): New constant.
3585 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
3586 buffer if it was supplied by the inferior.
3587 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
3588 (i387_xsave_get_clear_bv): New function.
3589 (i387_supply_xsave): Only read x87 control registers from the
3590 xsave buffer if the feature is enabled, and the state will have
3591 been written, otherwise, provide a suitable default.
3592 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
3593 including x87 control registers. Update control registers if they
3594 have changed from the default value, and mark features as enabled
3596 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
3598 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
3600 * spu-tdep.c (info_spu_event_command): Fix output formatting.
3602 2018-05-07 Tom Tromey <tom@tromey.com>
3604 * configure: Rebuild.
3605 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
3607 2018-05-07 Tom Tromey <tom@tromey.com>
3610 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
3611 bit. Use correct value for VDIV.
3613 2018-05-04 Tom Tromey <tom@tromey.com>
3615 * configure: Rebuild.
3616 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
3618 2018-05-04 Tom Tromey <tom@tromey.com>
3620 * linux-record.c (record_linux_system_call) <case
3621 RECORD_SYS_RECVFROM>: Add "break".
3623 2018-05-04 Tom Tromey <tom@tromey.com>
3625 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
3626 Add missing "break".
3627 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
3628 Add missing "break".
3630 2018-05-04 Tom Tromey <tom@tromey.com>
3632 * rs6000-tdep.c (ppc_process_record_op4)
3633 (ppc_process_record_op63): Add fall-through comment.
3635 2018-05-04 Tom Tromey <tom@tromey.com>
3637 * i386-tdep.c (i386_process_record): Add fall-through comment.
3639 2018-05-04 Tom Tromey <tom@tromey.com>
3641 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
3644 2018-05-04 Tom Tromey <tom@tromey.com>
3646 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
3647 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
3648 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
3650 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
3652 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
3655 2018-05-04 Tom Tromey <tom@tromey.com>
3657 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
3659 2018-05-04 Tom Tromey <tom@tromey.com>
3661 * s390-tdep.c (s390_process_record): Fix fall-through comments.
3662 * xcoffread.c (scan_xcoff_symtab): Move comment later.
3663 * symfile.c (section_is_mapped): Fix fall-through comment.
3664 * stabsread.c (define_symbol, read_member_functions): Fix
3665 fall-through comment.
3666 * s390-linux-tdep.c (s390_process_record): Fix fall-through
3668 * remote.c (remote_wait_as): Fix fall-through comment.
3669 * p-exp.y (yylex): Fix fall-through comment.
3670 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
3672 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
3673 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
3674 * jv-exp.y (yylex): Fix fall-through comment.
3675 * go-exp.y (lex_one_token): Fix fall-through comment.
3676 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
3677 fall-through comment.
3678 * f-exp.y (yylex): Fix fall-through comment.
3679 * dwarf2read.c (process_die): Fix fall-through comments.
3680 * dbxread.c (process_one_symbol): Fix fall-through comment.
3681 * d-exp.y (lex_one_token): Fix fall-through comment.
3682 * cp-name-parser.y (yylex): Fix fall-through comment.
3683 * coffread.c (coff_symtab_read): Fix fall-through comment.
3684 * c-exp.y (lex_one_token): Fix fall-through comment.
3685 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
3687 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
3690 2018-05-04 Tom Tromey <tom@tromey.com>
3693 * NEWS: Mention gdb.execute change.
3694 * gdbcmd.h (execute_control_command): Don't declare.
3695 * python/python.c (execute_gdb_command): Use read_command_lines_1,
3696 execute_control_commands, execute_control_commands_to_string.
3697 * cli/cli-script.h (execute_control_commands)
3698 (execute_control_commands_to_string): Declare.
3699 (execute_control_command): Add from_tty parameter.
3700 * cli/cli-script.c (execute_control_commands)
3701 (execute_control_commands_to_string): New functions.
3702 (execute_user_command): Use execute_control_commands.
3703 (execute_control_command_1): Add "from_tty" parameter. Update.
3704 (execute_control_command): Likewise.
3706 2018-05-04 Tom Tromey <tom@tromey.com>
3709 * NEWS: Mention that breakpoint commands are writable.
3710 * python/py-breakpoint.c (bppy_set_commands): New function.
3711 (breakpoint_object_getset) <"commands">: Use it.
3713 2018-05-04 Tom Tromey <tom@tromey.com>
3715 * tracepoint.c (actions_command): Update.
3716 * mi/mi-cmd-break.c (mi_command_line_array)
3717 (mi_command_line_array_cnt, mi_command_line_array_ptr)
3718 (mi_read_next_line): Remove.
3719 (mi_cmd_break_commands): Update.
3720 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
3722 * cli/cli-script.c (get_command_line): Update.
3723 (process_next_line): Use function_view. Constify.
3724 (recurse_read_control_structure, read_command_lines)
3725 (read_command_lines_1): Change argument types to function_view.
3726 (do_define_command, document_command): Update.
3727 * breakpoint.h (check_tracepoint_command): Don't declare.
3728 * breakpoint.c (check_tracepoint_command): Remove.
3729 (commands_command_1, create_tracepoint_from_upload): Update.
3731 2018-05-04 Tom Tromey <tom@tromey.com>
3734 * cli/cli-script.h (enum command_control_type) <define_control>:
3736 * cli/cli-script.c (multi_line_command_p): Handle define_control.
3737 (build_command_line, execute_control_command_1)
3738 (process_next_line): Likewise.
3739 (do_define_command): New function, extracted from define_command.
3740 (define_command): Use it.
3742 2018-05-04 Tom Tromey <tom@tromey.com>
3744 * tracepoint.c (actions_command): Update.
3745 * cli/cli-script.h (read_command_lines): Update.
3746 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
3747 (MAX_TMPBUF): Remove define.
3748 (define_command): Use string_printf.
3749 (document_command): Likewise.
3750 * breakpoint.c (commands_command_1): Update.
3752 2018-05-04 Tom Tromey <tom@tromey.com>
3754 * top.c (execute_command): Update.
3755 * cli/cli-script.h (print_command_lines): Now varargs.
3756 * cli/cli-script.c (print_command_lines): Now varargs.
3757 (execute_control_command_1) <case while_control, case if_control>:
3760 2018-05-04 Tom Tromey <tom@tromey.com>
3762 * tracepoint.c (all_tracepoint_actions): Rename from
3763 all_tracepoint_actions_and_cleanup. Change return type.
3764 (actions_command, encode_actions_1, encode_actions)
3765 (trace_dump_actions, tdump_command): Update.
3766 * remote.c (remote_download_command_source): Update.
3767 * python/python.c (gdbpy_eval_from_control_command)
3768 (python_command, python_interactive_command): Update.
3769 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
3770 * guile/guile.c (guile_command)
3771 (gdbscm_eval_from_control_command, guile_command): Update.
3772 * compile/compile.c (compile_code_command)
3773 (compile_print_command, compile_to_object): Update.
3774 * cli/cli-script.h (struct command_lines_deleter): New.
3775 (counted_command_line): New typedef.
3776 (struct command_line): Add constructor, destructor.
3777 <body_list>: Remove.
3778 <body_list_0, body_list_1>: New members.
3779 (command_line_up): Remove typedef.
3780 (read_command_lines, read_command_lines_1, get_command_line):
3782 (copy_command_lines): Don't declare.
3783 * cli/cli-script.c (build_command_line): Use "new".
3784 (get_command_line): Return counted_command_line.
3785 (print_command_lines, execute_user_command)
3786 (execute_control_command_1, while_command, if_command): Update.
3787 (realloc_body_list): Remove.
3788 (process_next_line, recurse_read_control_structure): Update.
3789 (read_command_lines, read_command_lines_1): Return counted_command_line.
3790 (free_command_lines): Use "delete".
3791 (copy_command_lines): Remove.
3792 (define_command, document_command, show_user_1): Update.
3793 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
3794 a counted_command_line.
3795 * breakpoint.h (counted_command_line): Remove typedef.
3796 (breakpoint_set_commands): Update.
3797 * breakpoint.c (check_no_tracepoint_commands)
3798 (validate_commands_for_breakpoint): Update.
3799 (breakpoint_set_commands): Change commands to be a
3800 counted_command_line.
3801 (commands_command_1, update_dprintf_command_list)
3802 (create_tracepoint_from_upload): Update.
3804 2018-05-04 Tom Tromey <tom@tromey.com>
3806 * cli/cli-decode.h (cmd_list_element): New constructor.
3807 (~cmd_list_element): New destructor.
3808 (struct cmd_list_element): Add initializers.
3809 * cli/cli-decode.c (do_add_cmd): Use "new".
3810 (delete_cmd): Use "delete".
3812 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
3813 Pedro Alves <palves@redhat.com>
3815 PR breakpoints/19806 and support for PR external/20207.
3816 * NEWS: Mention Aarch64 watchpoint improvements.
3817 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
3818 watchpoints and PR external/20207 watchpoints.
3819 * nat/aarch64-linux-hw-point.c
3820 (kernel_supports_any_contiguous_range): New.
3821 (aarch64_watchpoint_offset): New.
3822 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
3823 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
3824 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
3825 (aarch64_align_watchpoint): New parameters aligned_offset_p and
3826 next_addr_orig_p. Support PR external/20207 watchpoints.
3827 (aarch64_downgrade_regs): New.
3828 (aarch64_dr_state_insert_one_point): New parameters offset and
3830 (aarch64_dr_state_remove_one_point): Likewise.
3831 (aarch64_handle_breakpoint): Update caller.
3832 (aarch64_handle_aligned_watchpoint): Likewise.
3833 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
3835 (aarch64_linux_set_debug_regs): Remove const from state. Call
3836 aarch64_downgrade_regs.
3837 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
3838 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
3839 (DR_CONTROL_MASK): ... this.
3840 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
3841 (unsigned int aarch64_watchpoint_offset): New prototype.
3842 (aarch64_linux_set_debug_regs): Remove const from state.
3843 * utils.c (align_up, align_down): Move to ...
3844 * common/common-utils.c (align_up, align_down): ... here.
3845 * utils.h (align_up, align_down): Move to ...
3846 * common/common-utils.h (align_up, align_down): ... here.
3848 2018-05-04 Joel Brobecker <brobecker@adacore.com>
3850 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
3851 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
3852 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
3853 Re-implement to match the ABI as summarized in GCC's
3854 gcc/config/sparc/sparc.c. All callers updated.
3855 (sparc32_store_arguments): Remove assertion.
3857 2018-05-04 Tom Tromey <tom@tromey.com>
3859 * printcmd.c: Don't include tui.h.
3860 (decode_format): Use skip_spaces.
3862 2018-05-04 Tom Tromey <tom@tromey.com>
3865 * printcmd.c (last_count): New global.
3866 (x_command): Use saved count when repeating.
3868 2018-05-04 Tom Tromey <tom@tromey.com>
3870 * nto-procfs.c (do_closedir_cleanup): Remove.
3871 (procfs_pidlist): Use gdb_dir_up.
3872 * procfs.c (do_closedir_cleanup): Remove.
3873 (proc_update_threads): Use gdb_dir_up.
3874 * common/filestuff.h (struct gdb_dir_deleter): New.
3875 (gdb_dir_up): New typedef.
3877 2018-05-04 Tom Tromey <tom@tromey.com>
3879 * ada-lang.c (print_mention_exception): Use std::string.
3881 2018-05-04 Tom Tromey <tom@tromey.com>
3883 * ada-lang.c (create_excep_cond_exprs): Update.
3884 (ada_exception_catchpoint_cond_string): Use std::string.
3886 2018-05-04 Tom Tromey <tom@tromey.com>
3888 * ada-lang.c (xget_renaming_scope): Return std::string.
3889 (old_renaming_is_invisible): Update.
3891 2018-05-04 Tom Tromey <tom@tromey.com>
3893 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
3894 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
3896 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
3898 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
3900 2018-05-04 Tom Tromey <tom@tromey.com>
3902 * remote.c (remote_query_supported_append): Change type.
3903 (remote_check_symbols): Update.
3905 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
3908 * configure.ac: Prepend libpython.
3909 * python/python-config.py: Likewise.
3910 * configure: Regenerate.
3912 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
3914 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
3916 2018-05-03 Pedro Alves <palves@redhat.com>
3919 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
3920 override. Write 'true' instead of '1'.
3921 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
3924 2018-05-02 Pedro Alves <palves@redhat.com>
3926 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
3927 add_inf_child_target.
3928 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
3929 add_inf_child_target.
3930 * aix-thread.c (aix_thread_target_info): New.
3931 (aix_thread_target) <shortname, longname, doc>: Delete.
3933 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
3934 add_inf_child_target.
3935 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
3936 add_inf_child_target.
3937 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
3938 add_inf_child_target.
3939 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
3940 add_inf_child_target.
3941 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
3942 add_inf_child_target.
3943 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
3944 add_inf_child_target.
3945 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
3946 add_inf_child_target.
3947 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
3948 add_inf_child_target.
3949 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
3950 add_inf_child_target.
3951 * bfd-target.c (target_bfd_target_info): New.
3952 (target_bfd) <shortname, longname, doc>: Delete.
3954 * bsd-kvm.c (bsd_kvm_target_info): New.
3955 (bsd_kvm_target) <shortname, longname, doc>: Delete.
3957 (bsd_kvm_target::open): Rename to ...
3958 (bsd_kvm_target_open): ... this. Adjust.
3959 * bsd-uthread.c (bsd_uthread_target_info): New.
3960 (bsd_uthread_target) <shortname, longname, doc>: Delete.
3962 * corefile.c (core_file_command): Adjust.
3963 * corelow.c (core_target_info): New.
3964 (core_target) <shortname, longname, doc>: Delete.
3966 (core_target::open): Rename to ...
3967 (core_target_open): ... this. Adjust.
3968 * ctf.c (ctf_target_info): New.
3969 (ctf_target) <shortname, longname, doc>: Delete.
3971 (ctf_target::open): Rename to ...
3972 (ctf_target_open): ... this.
3973 (_initialize_ctf): Adjust.
3974 * exec.c (exec_target_info): New.
3975 (exec_target) <shortname, longname, doc>: Delete.
3977 (exec_target::open): Rename to ...
3978 (exec_target_open): ... this.
3979 * gdbcore.h (core_target_open): Declare.
3980 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
3981 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
3982 add_inf_child_target.
3983 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
3984 add_inf_child_target.
3985 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
3986 add_inf_child_target.
3987 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
3988 add_inf_child_target.
3989 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
3990 add_inf_child_target.
3991 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
3992 add_inf_child_target.
3993 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
3994 add_inf_child_target.
3995 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
3996 add_inf_child_target.
3997 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
3998 add_inf_child_target.
3999 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
4000 add_inf_child_target.
4001 * inf-child.c (inf_child_target_info): New.
4002 (inf_child_target::info): New.
4003 (inf_child_open_target): Remove 'target' parameter. Use
4004 get_native_target instead.
4005 (inf_child_target::open): Delete.
4006 (add_inf_child_target): New.
4007 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
4010 (add_inf_child_target): Declare.
4011 (inf_child_open_target): Declare.
4012 * linux-thread-db.c (thread_db_target_info): New.
4013 (thread_db_target) <shortname, longname, doc>: Delete.
4015 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
4016 add_inf_child_target.
4017 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
4018 add_inf_child_target.
4019 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
4020 add_inf_child_target.
4021 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
4022 add_inf_child_target.
4023 * make-target-delegates (print_class): Adjust.
4024 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
4025 add_inf_child_target.
4026 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
4027 add_inf_child_target.
4028 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
4029 add_inf_child_target.
4030 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
4031 add_inf_child_target.
4032 * nto-procfs.c (nto_native_target_info): New.
4033 (nto_procfs_target_native) <shortname, longname, doc>:
4036 (nto_procfs_target_info): New.
4037 (nto_procfs_target_procfs) <shortname, longname, doc>:
4040 (init_procfs_targets): Adjust.
4041 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
4042 add_inf_child_target.
4043 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
4044 add_inf_child_target.
4045 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
4046 add_inf_child_target.
4047 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
4048 add_inf_child_target.
4049 * ravenscar-thread.c (ravenscar_target_info): New.
4050 (ravenscar_thread_target) <shortname, longname, doc>:
4053 * record-btrace.c (record_btrace_target_info):
4054 (record_btrace_target) <shortname, longname, doc>: Delete.
4056 (record_btrace_target::open): Rename to ...
4057 (record_btrace_target_open): ... this. Adjust.
4058 * record-full.c (record_longname, record_doc): New.
4059 (record_full_base_target) <shortname, longname, doc>: Delete.
4061 (record_full_target_info): New.
4062 (record_full_target): <shortname>: Delete.
4064 (record_full_core_open_1, record_full_open_1): Update comments.
4065 (record_full_base_target::open): Rename to ...
4066 (record_full_open): ... this.
4067 (cmd_record_full_restore): Update.
4068 (_initialize_record_full): Update.
4069 * remote-sim.c (remote_sim_target_info): New.
4070 (gdbsim_target) <shortname, longname, doc>: Delete.
4072 (gdbsim_target::open): Rename to ...
4073 (gdbsim_target_open): ... this.
4074 (_initialize_remote_sim): Adjust.
4075 * remote.c (remote_doc): New.
4076 (remote_target_info): New.
4077 (remote_target) <shortname, longname, doc>: Delete.
4079 (extended_remote_target_info): New.
4080 (extended_remote_target) <shortname, longname, doc>: Delete.
4082 (remote_target::open_1): Make static. Adjust.
4083 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
4084 * s390-linux-nat.c (_initialize_s390_nat): Use
4085 add_inf_child_target.
4086 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
4087 add_inf_child_target.
4088 * sol-thread.c (thread_db_target_info): New.
4089 (sol_thread_target) <shortname, longname, doc>: Delete.
4091 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
4092 add_inf_child_target.
4093 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
4094 add_inf_child_target.
4095 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
4096 add_inf_child_target.
4097 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
4098 add_inf_child_target.
4099 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
4100 add_inf_child_target.
4101 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
4102 add_inf_child_target.
4103 * spu-linux-nat.c (_initialize_spu_nat): Use
4104 add_inf_child_target.
4105 * spu-multiarch.c (spu_multiarch_target_info): New.
4106 (spu_multiarch_target) <shortname, longname, doc>: Delete.
4108 * target-delegates.c: Regenerate.
4109 * target.c: Include <unordered_map>.
4110 (target_ops_p): Delete.
4111 (DEF_VEC_P(target_ops_p)): Delete.
4112 (target_factories): New.
4113 (test_target_info): New.
4114 (test_target_ops::info): New.
4115 (open_target): Adjust to use target_factories.
4116 (add_target_with_completer): Rename to ...
4117 (add_target): ... this. Change prototype. Register target_info
4118 and open callback in target_factories. Register target_info in
4119 command context instead of target_ops.
4120 (add_target): Delete old implementation.
4121 (add_deprecated_target_alias): Change prototype. Adjust.
4122 (the_native_target): New.
4123 (set_native_target, get_native_target): New.
4124 (find_default_run_target): Use the_native_target.
4125 (find_attach_target, find_run_target): Simplify.
4126 (target_ops::open): Delete.
4127 (dummy_target_info): New.
4128 (dummy_target::shortname, dummy_target::longname)
4129 (dummy_target::doc): Delete.
4130 (dummy_target::info): New.
4131 (debug_target::shortname, debug_target::longname)
4132 (debug_target::doc): Delete.
4133 (debug_target::info): New.
4134 * target.h (struct target_info): New.
4135 (target_ops::~target_ops): Add comment.
4136 (target_ops::info): New.
4137 (target_ops::shortname, target_ops::longname, target_ops::doc): No
4138 longer virtual. Implement in terms of target_info.
4139 (set_native_target, get_native_target): Declare.
4140 (target_open_ftype): New.
4141 (add_target, add_target_with_completer)
4142 (add_deprecated_target_alias): Change prototype.
4143 (test_target) <shortname, longname, doc>: Delete.
4145 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
4146 add_inf_child_target.
4147 * tracefile-tfile.c (tfile_target_info): New.
4148 (tfile_target) <shortname, longname, doc>: Delete.
4150 (tfile_target::open): Rename to ...
4151 (tfile_target_open): ... this.
4152 (_initialize_tracefile_tfile): Adjust.
4153 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
4154 add_inf_child_target.
4155 * windows-nat.c (_initialize_windows_nat): Use
4156 add_inf_child_target.
4157 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
4158 add_inf_child_target.
4160 2018-05-02 Pedro Alves <palves@redhat.com>
4162 * linux-nat.h (linux_nat_target) <low_new_thread,
4163 low_delete_thread, low_new_fork, low_forget_process,
4164 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
4165 New virtual methods.
4166 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4167 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
4168 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
4169 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4170 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
4172 * linux-fork.c (delete_fork): Adjust to call low method.
4173 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
4174 (linux_nat_new_fork, linux_nat_forget_process_hook)
4175 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
4176 (linux_nat_status_is_event):
4177 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
4178 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
4180 (sigtrap_is_event): Rename to ...
4181 (linux_nat_target::low_status_is_event): ... this.
4182 (linux_nat_set_status_is_event): Delete.
4183 (save_stop_reason, linux_nat_wait_1)
4184 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
4186 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
4187 (linux_nat_set_new_fork, linux_nat_set_forget_process)
4188 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
4189 (linux_nat_set_prepare_to_resume): Delete.
4190 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
4191 low virtual methods.
4192 * amd64-linux-nat.c: Likewise.
4193 * arm-linux-nat.c: Likewise.
4194 * i386-linux-nat.c: Likewise.
4195 * ia64-linux-nat.c: Likewise.
4196 * mips-linux-nat.c: Likewise.
4197 * ppc-linux-nat.c: Likewise.
4198 * s390-linux-nat.c: Likewise.
4199 * sparc64-linux-nat.c: Likewise.
4200 * x86-linux-nat.c: Likewise.
4201 * x86-linux-nat.h: Include "nat/x86-linux.h".
4202 (x86_linux_nat_target) <low_new_fork, low_forget_process,
4203 low_prepare_to_resume, low_new_thread, low_delete_thread>:
4206 2018-05-02 Pedro Alves <palves@redhat.com>
4208 * target.h (target_ops)
4209 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
4210 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
4211 stopped_by_watchpoint, have_continuable_watchpoint,
4212 stopped_data_address, watchpoint_addr_within_range,
4213 can_accel_watchpoint_condition, can_run, thread_alive,
4214 has_all_memory, has_memory, has_stack, has_registers,
4215 has_execution, can_async_p, is_async_p, supports_non_stop,
4216 always_non_stop_p, can_execute_reverse, supports_multi_process,
4217 supports_enable_disable_tracepoint,
4218 supports_disable_randomization, supports_string_tracing,
4219 supports_evaluation_of_breakpoint_conditions,
4220 can_run_breakpoint_commands, filesystem_is_local,
4221 can_download_tracepoint, get_trace_state_variable_value,
4222 set_trace_notes, get_tib_address, use_agent, can_use_agent,
4223 record_is_replaying, record_will_replay,
4224 augmented_libraries_svr4_read>: Adjust to return bool.
4225 * aarch64-linux-nat.c: All implementations adjusted.
4226 * aix-thread.c: All implementations adjusted.
4227 * arm-linux-nat.c: All implementations adjusted.
4228 * breakpoint.c: All implementations adjusted.
4229 * bsd-kvm.c: All implementations adjusted.
4230 * bsd-uthread.c: All implementations adjusted.
4231 * corelow.c: All implementations adjusted.
4232 * ctf.c: All implementations adjusted.
4233 * darwin-nat.c: All implementations adjusted.
4234 * darwin-nat.h: All implementations adjusted.
4235 * exec.c: All implementations adjusted.
4236 * fbsd-nat.c: All implementations adjusted.
4237 * fbsd-nat.h: All implementations adjusted.
4238 * gnu-nat.c: All implementations adjusted.
4239 * gnu-nat.h: All implementations adjusted.
4240 * go32-nat.c: All implementations adjusted.
4241 * ia64-linux-nat.c: All implementations adjusted.
4242 * inf-child.c: All implementations adjusted.
4243 * inf-child.h: All implementations adjusted.
4244 * inf-ptrace.c: All implementations adjusted.
4245 * inf-ptrace.h: All implementations adjusted.
4246 * linux-nat.c: All implementations adjusted.
4247 * linux-nat.h: All implementations adjusted.
4248 * mips-linux-nat.c: All implementations adjusted.
4249 * nto-procfs.c: All implementations adjusted.
4250 * ppc-linux-nat.c: All implementations adjusted.
4251 * procfs.c: All implementations adjusted.
4252 * ravenscar-thread.c: All implementations adjusted.
4253 * record-btrace.c: All implementations adjusted.
4254 * record-full.c: All implementations adjusted.
4255 * remote-sim.c: All implementations adjusted.
4256 * remote.c: All implementations adjusted.
4257 * s390-linux-nat.c: All implementations adjusted.
4258 * sol-thread.c: All implementations adjusted.
4259 * spu-multiarch.c: All implementations adjusted.
4260 * target-delegates.c: All implementations adjusted.
4261 * target.c: All implementations adjusted.
4262 * target.h: All implementations adjusted.
4263 * tracefile-tfile.c: All implementations adjusted.
4264 * tracefile.c: All implementations adjusted.
4265 * tracefile.h: All implementations adjusted.
4266 * windows-nat.c: All implementations adjusted.
4267 * x86-linux-nat.h: All implementations adjusted.
4268 * x86-nat.h: All implementations adjusted.
4270 2018-05-02 Pedro Alves <palves@redhat.com>
4272 * make-target-delegates (scan_target_h): Don't trim lines here.
4273 Replace sequences of tabs and/or whitespace with a single
4275 (top level, parsing methods): Trim each line before processing it
4278 2018-05-02 Pedro Alves <palves@redhat.com>
4279 John Baldwin <jhb@freebsd.org>
4281 * target.h (enum strata) <debug_stratum>: New.
4282 (struct target_ops) <all delegation methods>: Replace by C++
4283 virtual methods, and drop "to_" prefix. All references updated
4285 <to_shortname, to_longname, to_doc, to_data,
4286 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
4287 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
4288 virtual methods. All references updated throughout.
4289 <can_attach, supports_terminal_ours, can_create_inferior,
4290 get_thread_control_capabilities, attach_no_wait>: New
4292 <insert_breakpoint, remove_breakpoint>: Now
4293 TARGET_DEFAULT_NORETURN methods.
4294 <info_proc>: Now returns bool.
4296 (OPS_MAGIC): Delete.
4297 (current_target): Delete. All references replaced by references
4299 (target_stack): ... this. New.
4300 (target_shortname, target_longname): Adjust.
4301 (target_can_run): Now a function declaration.
4302 (default_child_has_all_memory, default_child_has_memory)
4303 (default_child_has_stack, default_child_has_registers)
4304 (default_child_has_execution): Remove target_ops parameter.
4305 (complete_target_initialization): Delete.
4306 (memory_breakpoint_target): New template class.
4307 (test_target_ops): Refactor as a C++ class with virtual methods.
4308 * make-target-delegates (NAME_PART): Tighten.
4309 (POINTER_PART, CP_SYMBOL): New.
4310 (SIMPLE_RETURN_PART): Reimplement.
4311 (VEC_RETURN_PART): Expect less.
4312 (RETURN_PART, VIRTUAL_PART): New.
4313 (METHOD): Adjust to C++ virtual methods.
4314 (scan_target_h): Remove reference to C99.
4315 (dname): Output "target_ops::" prefix.
4316 (write_function_header): Adjust to output a C++ class method.
4317 (write_declaration): New.
4318 (write_delegator): Adjust to output a C++ class method.
4319 (tdname): Output "dummy_target::" prefix.
4320 (write_tdefault, write_debugmethod): Adjust to output a C++ class
4322 (tdefault_names, debug_names): Delete.
4323 (return_types, tdefaults, styles, argtypes_array): New.
4324 (top level): All methods are delegators.
4326 (top level): Print dummy_target and debug_target classes.
4327 * target-delegates.c: Regenerate.
4328 * target-debug.h (target_debug_print_enum_info_proc_what)
4329 (target_debug_print_thread_control_capabilities)
4330 (target_debug_print_thread_info_p): New.
4331 * target.c (dummy_target): Delete.
4332 (the_dummy_target, the_debug_target): New.
4333 (target_stack): Now extern.
4334 (set_targetdebug): Push/unpush debug target.
4335 (default_child_has_all_memory, default_child_has_memory)
4336 (default_child_has_stack, default_child_has_registers)
4337 (default_child_has_execution): Remove target_ops parameter.
4338 (complete_target_initialization): Delete.
4339 (add_target_with_completer): No longer call
4340 complete_target_initialization.
4341 (target_supports_terminal_ours): Use regular delegation.
4342 (update_current_target): Delete.
4343 (push_target): No longer check magic number. Don't call
4344 update_current_target.
4345 (unpush_target): Don't call update_current_target.
4346 (target_is_pushed): No longer check magic number.
4347 (target_require_runnable): Skip for all stratums over
4349 (target_ops::info_proc): New.
4350 (target_info_proc): Use find_target_at and
4351 find_default_run_target.
4352 (target_supports_disable_randomization): Use regular delegation.
4353 (target_get_osdata): Use find_target_at.
4354 (target_ops::open, target_ops::close, target_ops::can_attach)
4355 (target_ops::attach, target_ops::can_create_inferior)
4356 (target_ops::create_inferior, target_ops::can_run)
4357 (target_can_run): New.
4358 (default_fileio_target): Use regular delegation.
4359 (target_ops::fileio_open, target_ops::fileio_pwrite)
4360 (target_ops::fileio_pread, target_ops::fileio_fstat)
4361 (target_ops::fileio_close, target_ops::fileio_unlink)
4362 (target_ops::fileio_readlink): New.
4363 (target_fileio_open_1, target_fileio_unlink)
4364 (target_fileio_readlink): Always call the target method. Handle
4366 (return_zero, return_zero_has_execution): Delete.
4367 (init_dummy_target): Delete.
4368 (dummy_target::dummy_target, dummy_target::shortname)
4369 (dummy_target::longname, dummy_target::doc)
4370 (debug_target::debug_target, debug_target::shortname)
4371 (debug_target::longname, debug_target::doc): New.
4372 (target_supports_delete_record): Use regular delegation.
4373 (setup_target_debug): Delete.
4374 (maintenance_print_target_stack): Skip debug_stratum.
4375 (initialize_targets): Instantiate the_dummy_target and
4377 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
4379 (target_auxv_search, fprint_target_auxv): Adjust.
4380 (info_auxv_command): Adjust to use target_stack.
4381 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
4382 * exceptions.c (print_flush): Handle a NULL target_stack.
4383 * regcache.c (target_ops_no_register): Refactor as class with
4386 * exec.c (exec_target): New class.
4387 (exec_ops): Now an exec_target.
4388 (exec_open, exec_close_1, exec_get_section_table)
4389 (exec_xfer_partial, exec_files_info, exec_has_memory)
4390 (exec_make_note_section): Refactor as exec_target methods.
4391 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
4393 (exec_target::find_memory_regions): New.
4394 (_initialize_exec): Don't call init_exec_ops.
4395 * gdbcore.h (exec_file_clear): Delete.
4397 * corefile.c (core_target): Delete.
4398 (core_file_command): Adjust.
4399 * corelow.c (core_target): New class.
4400 (the_core_target): New.
4401 (core_close): Remove target_ops parameter.
4402 (core_close_cleanup): Adjust.
4403 (core_target::close): New.
4404 (core_open, core_detach, get_core_registers, core_files_info)
4405 (core_xfer_partial, core_thread_alive, core_read_description)
4406 (core_pid_to_str, core_thread_name, core_has_memory)
4407 (core_has_stack, core_has_registers, core_info_proc): Rework as
4408 core_target methods.
4409 (ignore, core_remove_breakpoint, init_core_ops): Delete.
4410 (_initialize_corelow): Initialize the_core_target.
4411 * gdbcore.h (core_target): Delete.
4412 (the_core_target): New.
4414 * ctf.c: (ctf_target): New class.
4415 (ctf_ops): Now a ctf_target.
4416 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
4417 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
4418 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
4420 (init_ctf_ops): Delete.
4421 (_initialize_ctf): Don't call it.
4422 * tracefile-tfile.c (tfile_target): New class.
4423 (tfile_ops): Now a tfile_target.
4424 (tfile_open, tfile_close, tfile_files_info)
4425 (tfile_get_tracepoint_status, tfile_trace_find)
4426 (tfile_fetch_registers, tfile_xfer_partial)
4427 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
4428 Refactor as tfile_target methods.
4429 (tfile_xfer_partial_features): Remove target_ops parameter.
4430 (init_tfile_ops): Delete.
4431 (_initialize_tracefile_tfile): Don't call it.
4432 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
4433 (tracefile_has_stack, tracefile_has_registers)
4434 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
4435 tracefile_target methods.
4436 (init_tracefile_ops): Delete.
4437 (tracefile_target::tracefile_target): New.
4438 * tracefile.h: Include "target.h".
4439 (tracefile_target): New class.
4440 (init_tracefile_ops): Delete.
4442 * spu-multiarch.c (spu_multiarch_target): New class.
4443 (spu_ops): Now a spu_multiarch_target.
4444 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
4445 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
4446 (spu_search_memory, spu_mourn_inferior): Refactor as
4447 spu_multiarch_target methods.
4448 (init_spu_ops): Delete.
4449 (_initialize_spu_multiarch): Remove references to init_spu_ops,
4450 complete_target_initialization.
4452 * ravenscar-thread.c (ravenscar_thread_target): New class.
4453 (ravenscar_ops): Now a ravenscar_thread_target.
4454 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
4455 (ravenscar_thread_alive, ravenscar_pid_to_str)
4456 (ravenscar_fetch_registers, ravenscar_store_registers)
4457 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
4458 (ravenscar_stopped_by_hw_breakpoint)
4459 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
4460 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
4461 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
4463 (init_ravenscar_thread_ops): Delete.
4464 (_initialize_ravenscar): Remove references to
4465 init_ravenscar_thread_ops and complete_target_initialization.
4467 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
4468 (bsd_uthread_target): New class.
4469 (bsd_uthread_ops): Now a bsd_uthread_target.
4470 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
4471 (bsd_uthread_close, bsd_uthread_mourn_inferior)
4472 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
4473 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
4474 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
4475 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
4476 (bsd_uthread_target): Delete function.
4477 (_initialize_bsd_uthread): Remove reference to
4478 complete_target_initialization.
4480 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
4481 (target_bfd): ... this new class.
4482 (target_bfd_xfer_partial, target_bfd_get_section_table)
4483 (target_bfd_close): Refactor as target_bfd methods.
4484 (target_bfd::~target_bfd): New.
4485 (target_bfd_reopen): Adjust.
4486 (target_bfd::close): New.
4488 * record-btrace.c (record_btrace_target): New class.
4489 (record_btrace_ops): Now a record_btrace_target.
4490 (record_btrace_open, record_btrace_stop_recording)
4491 (record_btrace_disconnect, record_btrace_close)
4492 (record_btrace_async, record_btrace_info)
4493 (record_btrace_insn_history, record_btrace_insn_history_range)
4494 (record_btrace_insn_history_from, record_btrace_call_history)
4495 (record_btrace_call_history_range)
4496 (record_btrace_call_history_from, record_btrace_record_method)
4497 (record_btrace_is_replaying, record_btrace_will_replay)
4498 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
4499 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
4500 (record_btrace_store_registers, record_btrace_prepare_to_store)
4501 (record_btrace_to_get_unwinder)
4502 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
4503 (record_btrace_commit_resume, record_btrace_wait)
4504 (record_btrace_stop, record_btrace_can_execute_reverse)
4505 (record_btrace_stopped_by_sw_breakpoint)
4506 (record_btrace_supports_stopped_by_sw_breakpoint)
4507 (record_btrace_stopped_by_hw_breakpoint)
4508 (record_btrace_supports_stopped_by_hw_breakpoint)
4509 (record_btrace_update_thread_list, record_btrace_thread_alive)
4510 (record_btrace_goto_begin, record_btrace_goto_end)
4511 (record_btrace_goto, record_btrace_stop_replaying_all)
4512 (record_btrace_execution_direction)
4513 (record_btrace_prepare_to_generate_core)
4514 (record_btrace_done_generating_core): Refactor as
4515 record_btrace_target methods.
4516 (init_record_btrace_ops): Delete.
4517 (_initialize_record_btrace): Remove reference to
4518 init_record_btrace_ops.
4519 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
4520 the execution_direction global.
4521 (record_full_base_target, record_full_target)
4522 (record_full_core_target): New classes.
4523 (record_full_ops): Now a record_full_target.
4524 (record_full_core_ops): Now a record_full_core_target.
4525 (record_full_target::detach, record_full_target::disconnect)
4526 (record_full_core_target::disconnect)
4527 (record_full_target::mourn_inferior, record_full_target::kill):
4529 (record_full_open, record_full_close, record_full_async): Refactor
4530 as methods of the record_full_base_target class.
4531 (record_full_resume, record_full_commit_resume): Refactor
4532 as methods of the record_full_target class.
4533 (record_full_wait, record_full_stopped_by_watchpoint)
4534 (record_full_stopped_data_address)
4535 (record_full_stopped_by_sw_breakpoint)
4536 (record_full_supports_stopped_by_sw_breakpoint)
4537 (record_full_stopped_by_hw_breakpoint)
4538 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
4539 methods of the record_full_base_target class.
4540 (record_full_store_registers, record_full_xfer_partial)
4541 (record_full_insert_breakpoint, record_full_remove_breakpoint):
4542 Refactor as methods of the record_full_target class.
4543 (record_full_can_execute_reverse, record_full_get_bookmark)
4544 (record_full_goto_bookmark, record_full_execution_direction)
4545 (record_full_record_method, record_full_info, record_full_delete)
4546 (record_full_is_replaying, record_full_will_replay)
4547 (record_full_goto_begin, record_full_goto_end, record_full_goto)
4548 (record_full_stop_replaying): Refactor as methods of the
4549 record_full_base_target class.
4550 (record_full_core_resume, record_full_core_kill)
4551 (record_full_core_fetch_registers)
4552 (record_full_core_prepare_to_store)
4553 (record_full_core_store_registers, record_full_core_xfer_partial)
4554 (record_full_core_insert_breakpoint)
4555 (record_full_core_remove_breakpoint)
4556 (record_full_core_has_execution): Refactor
4557 as methods of the record_full_core_target class.
4558 (record_full_base_target::supports_delete_record): New.
4559 (init_record_full_ops): Delete.
4560 (init_record_full_core_ops): Delete.
4561 (record_full_save): Refactor as method of the
4562 record_full_base_target class.
4563 (_initialize_record_full): Remove references to
4564 init_record_full_ops and init_record_full_core_ops.
4566 * remote.c (remote_target, extended_remote_target): New classes.
4567 (remote_ops): Now a remote_target.
4568 (extended_remote_ops): Now an extended_remote_target.
4569 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
4570 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
4571 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
4572 (remote_pass_signals, remote_set_syscall_catchpoint)
4573 (remote_program_signals, )
4574 (remote_thread_always_alive): Remove target_ops parameter.
4575 (remote_thread_alive, remote_thread_name)
4576 (remote_update_thread_list, remote_threads_extra_info)
4577 (remote_static_tracepoint_marker_at)
4578 (remote_static_tracepoint_markers_by_strid)
4579 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
4580 (remote_open): Refactor as methods of remote_target.
4581 (extended_remote_open, extended_remote_detach)
4582 (extended_remote_attach, extended_remote_post_attach):
4583 (extended_remote_supports_disable_randomization)
4584 (extended_remote_create_inferior): : Refactor as method of
4585 extended_remote_target.
4586 (remote_set_permissions, remote_open_1, remote_detach)
4587 (remote_follow_fork, remote_follow_exec, remote_disconnect)
4588 (remote_resume, remote_commit_resume, remote_stop)
4589 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
4590 (remote_terminal_ours, remote_wait, remote_fetch_registers)
4591 (remote_prepare_to_store, remote_store_registers)
4592 (remote_flash_erase, remote_flash_done, remote_files_info)
4593 (remote_kill, remote_mourn, remote_insert_breakpoint)
4594 (remote_remove_breakpoint, remote_insert_watchpoint)
4595 (remote_watchpoint_addr_within_range)
4596 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
4597 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
4598 (remote_supports_stopped_by_sw_breakpoint)
4599 (remote_stopped_by_hw_breakpoint)
4600 (remote_supports_stopped_by_hw_breakpoint)
4601 (remote_stopped_by_watchpoint, remote_stopped_data_address)
4602 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
4603 (remote_verify_memory): Refactor as methods of remote_target.
4604 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
4606 (remote_xfer_partial, remote_get_memory_xfer_limit)
4607 (remote_search_memory, remote_rcmd, remote_memory_map)
4608 (remote_pid_to_str, remote_get_thread_local_address)
4609 (remote_get_tib_address, remote_read_description): Refactor as
4610 methods of remote_target.
4611 (remote_target::fileio_open, remote_target::fileio_pwrite)
4612 (remote_target::fileio_pread, remote_target::fileio_close): New.
4613 (remote_hostio_readlink, remote_hostio_fstat)
4614 (remote_filesystem_is_local, remote_can_execute_reverse)
4615 (remote_supports_non_stop, remote_supports_disable_randomization)
4616 (remote_supports_multi_process, remote_supports_cond_breakpoints)
4617 (remote_supports_enable_disable_tracepoint)
4618 (remote_supports_string_tracing)
4619 (remote_can_run_breakpoint_commands, remote_trace_init)
4620 (remote_download_tracepoint, remote_can_download_tracepoint)
4621 (remote_download_trace_state_variable, remote_enable_tracepoint)
4622 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
4623 (remote_trace_start, remote_get_trace_status)
4624 (remote_get_tracepoint_status, remote_trace_stop)
4625 (remote_trace_find, remote_get_trace_state_variable_value)
4626 (remote_save_trace_data, remote_get_raw_trace_data)
4627 (remote_set_disconnected_tracing, remote_core_of_thread)
4628 (remote_set_circular_trace_buffer, remote_traceframe_info)
4629 (remote_get_min_fast_tracepoint_insn_len)
4630 (remote_set_trace_buffer_size, remote_set_trace_notes)
4631 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
4632 (remote_disable_btrace, remote_teardown_btrace)
4633 (remote_read_btrace, remote_btrace_conf)
4634 (remote_augmented_libraries_svr4_read, remote_load)
4635 (remote_pid_to_exec_file, remote_can_do_single_step)
4636 (remote_execution_direction, remote_thread_handle_to_thread_info):
4637 Refactor as methods of remote_target.
4638 (init_remote_ops, init_extended_remote_ops): Delete.
4639 (remote_can_async_p, remote_is_async_p, remote_async)
4640 (remote_thread_events, remote_upload_tracepoints)
4641 (remote_upload_trace_state_variables): Refactor as methods of
4643 (_initialize_remote): Remove references to init_remote_ops and
4644 init_extended_remote_ops.
4646 * remote-sim.c (gdbsim_target): New class.
4647 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
4648 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
4649 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
4650 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
4651 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
4652 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
4653 Refactor as methods of gdbsim_target.
4654 (gdbsim_ops): Now a gdbsim_target.
4655 (init_gdbsim_ops): Delete.
4656 (gdbsim_cntrl_c): Adjust.
4657 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
4659 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
4660 (the_amd64_linux_nat_target): New.
4661 (amd64_linux_fetch_inferior_registers)
4662 (amd64_linux_store_inferior_registers): Refactor as methods of
4663 amd64_linux_nat_target.
4664 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
4665 * i386-linux-nat.c: Don't include "linux-nat.h".
4666 (i386_linux_nat_target): New class.
4667 (the_i386_linux_nat_target): New.
4668 (i386_linux_fetch_inferior_registers)
4669 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
4670 as methods of i386_linux_nat_target.
4671 (_initialize_i386_linux_nat): Adjust. Set linux_target.
4672 * inf-child.c (inf_child_ops): Delete.
4673 (inf_child_fetch_inferior_registers)
4674 (inf_child_store_inferior_registers): Delete.
4675 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
4676 methods of inf_child_target.
4677 (inf_child_target::supports_terminal_ours)
4678 (inf_child_target::terminal_init)
4679 (inf_child_target::terminal_inferior)
4680 (inf_child_target::terminal_ours_for_output)
4681 (inf_child_target::terminal_ours, inf_child_target::interrupt)
4682 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
4684 (inf_child_open, inf_child_disconnect, inf_child_close)
4685 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
4686 (inf_child_post_startup_inferior, inf_child_can_run)
4687 (inf_child_pid_to_exec_file): Refactor as methods of
4689 (inf_child_follow_fork): Delete.
4690 (inf_child_target::can_create_inferior)
4691 (inf_child_target::can_attach): New.
4692 (inf_child_target::has_all_memory, inf_child_target::has_memory)
4693 (inf_child_target::has_stack, inf_child_target::has_registers)
4694 (inf_child_target::has_execution): New.
4695 (inf_child_fileio_open, inf_child_fileio_pwrite)
4696 (inf_child_fileio_pread, inf_child_fileio_fstat)
4697 (inf_child_fileio_close, inf_child_fileio_unlink)
4698 (inf_child_fileio_readlink, inf_child_use_agent)
4699 (inf_child_can_use_agent): Refactor as methods of
4701 (return_zero, inf_child_target): Delete.
4702 (inf_child_target::inf_child_target): New.
4703 * inf-child.h: Include "target.h".
4704 (inf_child_target): Delete function prototype.
4705 (inf_child_target): New class.
4706 (inf_child_open_target, inf_child_mourn_inferior)
4707 (inf_child_maybe_unpush_target): Delete.
4708 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
4709 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
4710 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
4711 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
4712 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
4713 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
4714 (inf_ptrace_wait, inf_ptrace_xfer_partial)
4715 (inf_ptrace_thread_alive, inf_ptrace_files_info)
4716 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
4717 methods of inf_ptrace_target.
4718 (inf_ptrace_target): Delete function.
4719 * inf-ptrace.h: Include "inf-child.h".
4720 (inf_ptrace_target): Delete function declaration.
4721 (inf_ptrace_target): New class.
4722 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
4723 * linux-nat.c (linux_target): New.
4724 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
4725 (linux_nat_target::~linux_nat_target): New.
4726 (linux_child_post_attach, linux_child_post_startup_inferior)
4727 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
4728 (linux_child_remove_fork_catchpoint)
4729 (linux_child_insert_vfork_catchpoint)
4730 (linux_child_remove_vfork_catchpoint)
4731 (linux_child_insert_exec_catchpoint)
4732 (linux_child_remove_exec_catchpoint)
4733 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
4734 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
4735 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
4736 (linux_nat_stopped_data_address)
4737 (linux_nat_stopped_by_sw_breakpoint)
4738 (linux_nat_supports_stopped_by_sw_breakpoint)
4739 (linux_nat_stopped_by_hw_breakpoint)
4740 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
4741 (linux_nat_kill, linux_nat_mourn_inferior)
4742 (linux_nat_xfer_partial, linux_nat_thread_alive)
4743 (linux_nat_update_thread_list, linux_nat_pid_to_str)
4744 (linux_nat_thread_name, linux_child_pid_to_exec_file)
4745 (linux_child_static_tracepoint_markers_by_strid)
4746 (linux_nat_is_async_p, linux_nat_can_async_p)
4747 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
4748 (linux_nat_supports_multi_process)
4749 (linux_nat_supports_disable_randomization, linux_nat_async)
4750 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
4751 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
4752 (linux_nat_fileio_open, linux_nat_fileio_readlink)
4753 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
4754 methods of linux_nat_target.
4755 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
4756 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
4758 (check_stopped_by_watchpoint): Adjust.
4759 (linux_xfer_partial): Delete.
4760 (linux_target_install_ops, linux_target, linux_nat_add_target):
4762 (linux_nat_target::linux_nat_target): New.
4763 * linux-nat.h: Include "inf-ptrace.h".
4764 (linux_nat_target): New.
4765 (linux_target, linux_target_install_ops, linux_nat_add_target):
4766 Delete function declarations.
4767 (linux_target): Declare global.
4768 * linux-thread-db.c (thread_db_target): New.
4769 (thread_db_target::thread_db_target): New.
4770 (thread_db_ops): Delete.
4771 (the_thread_db_target): New.
4772 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
4773 (thread_db_update_thread_list, thread_db_pid_to_str)
4774 (thread_db_extra_thread_info)
4775 (thread_db_thread_handle_to_thread_info)
4776 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
4777 (thread_db_resume): Refactor as methods of thread_db_target.
4778 (init_thread_db_ops): Delete.
4779 (_initialize_thread_db): Remove reference to init_thread_db_ops.
4780 * x86-linux-nat.c: Don't include "linux-nat.h".
4781 (super_post_startup_inferior): Delete.
4782 (x86_linux_nat_target::~x86_linux_nat_target): New.
4783 (x86_linux_child_post_startup_inferior)
4784 (x86_linux_read_description, x86_linux_enable_btrace)
4785 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
4786 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
4787 methods of x86_linux_nat_target.
4788 (x86_linux_create_target): Delete. Bits folded ...
4789 (x86_linux_add_target): ... here. Now takes a linux_nat_target
4791 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
4792 (x86_linux_nat_target): New class.
4793 (x86_linux_create_target): Delete.
4794 (x86_linux_add_target): Now takes a linux_nat_target pointer.
4795 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
4796 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
4797 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
4798 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
4799 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
4801 (x86_use_watchpoints): Delete.
4802 * x86-nat.h: Include "breakpoint.h" and "target.h".
4803 (x86_use_watchpoints): Delete.
4804 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
4805 (x86_stopped_by_watchpoint, x86_stopped_data_address)
4806 (x86_insert_watchpoint, x86_remove_watchpoint)
4807 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
4808 (x86_stopped_by_hw_breakpoint): New declarations.
4809 (x86_nat_target): New template class.
4811 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
4812 (the_ppc_linux_nat_target): New.
4813 (ppc_linux_fetch_inferior_registers)
4814 (ppc_linux_can_use_hw_breakpoint)
4815 (ppc_linux_region_ok_for_hw_watchpoint)
4816 (ppc_linux_ranged_break_num_registers)
4817 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
4818 (ppc_linux_insert_mask_watchpoint)
4819 (ppc_linux_remove_mask_watchpoint)
4820 (ppc_linux_can_accel_watchpoint_condition)
4821 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
4822 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
4823 (ppc_linux_watchpoint_addr_within_range)
4824 (ppc_linux_masked_watch_num_registers)
4825 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
4826 (ppc_linux_read_description): Refactor as methods of
4827 ppc_linux_nat_target.
4828 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
4830 * procfs.c (procfs_xfer_partial): Delete forward declaration.
4831 (procfs_target): New class.
4832 (the_procfs_target): New.
4833 (procfs_target): Delete function.
4834 (procfs_auxv_parse, procfs_attach, procfs_detach)
4835 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
4836 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
4837 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
4838 (procfs_create_inferior, procfs_update_thread_list)
4839 (procfs_thread_alive, procfs_pid_to_str)
4840 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
4841 (procfs_stopped_data_address, procfs_insert_watchpoint)
4842 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
4843 (proc_find_memory_regions, procfs_info_proc)
4844 (procfs_make_note_section): Refactor as methods of procfs_target.
4845 (_initialize_procfs): Adjust.
4846 * sol-thread.c (sol_thread_target): New class.
4847 (sol_thread_ops): Now a sol_thread_target.
4848 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
4849 (sol_thread_fetch_registers, sol_thread_store_registers)
4850 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
4851 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
4852 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
4853 (init_sol_thread_ops): Delete.
4854 (_initialize_sol_thread): Adjust. Remove references to
4855 init_sol_thread_ops and complete_target_initialization.
4857 * windows-nat.c (windows_nat_target): New class.
4858 (windows_fetch_inferior_registers)
4859 (windows_store_inferior_registers, windows_resume, windows_wait)
4860 (windows_attach, windows_detach, windows_pid_to_exec_file)
4861 (windows_files_info, windows_create_inferior)
4862 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
4863 (windows_close, windows_pid_to_str, windows_xfer_partial)
4864 (windows_get_tib_address, windows_get_ada_task_ptid)
4865 (windows_thread_name, windows_thread_alive): Refactor as
4866 windows_nat_target methods.
4867 (do_initial_windows_stuff): Adjust.
4868 (windows_target): Delete function.
4869 (_initialize_windows_nat): Adjust.
4871 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
4872 (darwin_mourn_inferior, darwin_kill_inferior)
4873 (darwin_create_inferior, darwin_attach, darwin_detach)
4874 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
4875 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
4876 (darwin_supports_multi_process): Refactor as darwin_nat_target
4878 (darwin_resume_to, darwin_files_info): Delete.
4879 (_initialize_darwin_inferior): Rename to ...
4880 (_initialize_darwin_nat): ... this. Adjust to C++ification.
4881 * darwin-nat.h: Include "inf-child.h".
4882 (darwin_nat_target): New class.
4883 (darwin_complete_target): Delete.
4884 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
4885 (darwin_target): New.
4886 (i386_darwin_fetch_inferior_registers)
4887 (i386_darwin_store_inferior_registers): Refactor as methods of
4889 (darwin_complete_target): Delete, with ...
4890 (_initialize_i386_darwin_nat): ... bits factored out here.
4892 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
4893 (the_alpha_linux_nat_target): New.
4894 (alpha_linux_register_u_offset): Refactor as
4895 alpha_linux_nat_target method.
4896 (_initialize_alpha_linux_nat): Adjust.
4897 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
4898 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4899 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
4900 methods of linux_nat_trad_target.
4901 (linux_trad_target): Delete.
4902 * linux-nat-trad.h (linux_trad_target): Delete function.
4903 (linux_nat_trad_target): New class.
4904 * mips-linux-nat.c (mips_linux_nat_target): New class.
4905 (super_fetch_registers, super_store_registers, super_close):
4907 (the_mips_linux_nat_target): New.
4908 (mips64_linux_regsets_fetch_registers)
4909 (mips64_linux_regsets_store_registers)
4910 (mips64_linux_fetch_registers, mips64_linux_store_registers)
4911 (mips_linux_register_u_offset, mips_linux_read_description)
4912 (mips_linux_can_use_hw_breakpoint)
4913 (mips_linux_stopped_by_watchpoint)
4914 (mips_linux_stopped_data_address)
4915 (mips_linux_region_ok_for_hw_watchpoint)
4916 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
4917 (mips_linux_close): Refactor as methods of mips_linux_nat.
4918 (_initialize_mips_linux_nat): Adjust to C++ification.
4920 * aix-thread.c (aix_thread_target): New class.
4921 (aix_thread_ops): Now an aix_thread_target.
4922 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
4923 (aix_thread_fetch_registers, aix_thread_store_registers)
4924 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
4925 (aix_thread_thread_alive, aix_thread_pid_to_str)
4926 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
4927 Refactor as methods of aix_thread_target.
4928 (init_aix_thread_ops): Delete.
4929 (_initialize_aix_thread): Remove references to init_aix_thread_ops
4930 and complete_target_initialization.
4931 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
4932 (rs6000_nat_target): New class.
4933 (the_rs6000_nat_target): New.
4934 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
4935 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
4936 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
4937 (super_create_inferior): Delete.
4938 (_initialize_rs6000_nat): Adjust to C++ification.
4940 * arm-linux-nat.c (arm_linux_nat_target): New class.
4941 (the_arm_linux_nat_target): New.
4942 (arm_linux_fetch_inferior_registers)
4943 (arm_linux_store_inferior_registers, arm_linux_read_description)
4944 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
4945 (arm_linux_remove_hw_breakpoint)
4946 (arm_linux_region_ok_for_hw_watchpoint)
4947 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
4948 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
4949 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
4950 arm_linux_nat_target.
4951 (_initialize_arm_linux_nat): Adjust to C++ification.
4953 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
4954 (the_aarch64_linux_nat_target): New.
4955 (aarch64_linux_fetch_inferior_registers)
4956 (aarch64_linux_store_inferior_registers)
4957 (aarch64_linux_child_post_startup_inferior)
4958 (aarch64_linux_read_description)
4959 (aarch64_linux_can_use_hw_breakpoint)
4960 (aarch64_linux_insert_hw_breakpoint)
4961 (aarch64_linux_remove_hw_breakpoint)
4962 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
4963 (aarch64_linux_region_ok_for_hw_watchpoint)
4964 (aarch64_linux_stopped_data_address)
4965 (aarch64_linux_stopped_by_watchpoint)
4966 (aarch64_linux_watchpoint_addr_within_range)
4967 (aarch64_linux_can_do_single_step): Refactor as methods of
4968 aarch64_linux_nat_target.
4969 (super_post_startup_inferior): Delete.
4970 (_initialize_aarch64_linux_nat): Adjust to C++ification.
4972 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
4973 (the_hppa_linux_nat_target): New.
4974 (hppa_linux_fetch_inferior_registers)
4975 (hppa_linux_store_inferior_registers): Refactor as methods of
4976 hppa_linux_nat_target.
4977 (_initialize_hppa_linux_nat): Adjust to C++ification.
4979 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
4980 (the_ia64_linux_nat_target): New.
4981 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
4982 (ia64_linux_stopped_data_address)
4983 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
4984 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
4985 ia64_linux_nat_target methods.
4986 (super_xfer_partial): Delete.
4987 (_initialize_ia64_linux_nat): Adjust to C++ification.
4989 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
4990 (the_m32r_linux_nat_target): New.
4991 (m32r_linux_fetch_inferior_registers)
4992 (m32r_linux_store_inferior_registers): Refactor as
4993 m32r_linux_nat_target methods.
4994 (_initialize_m32r_linux_nat): Adjust to C++ification.
4996 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
4997 (the_m68k_linux_nat_target): New.
4998 (m68k_linux_fetch_inferior_registers)
4999 (m68k_linux_store_inferior_registers): Refactor as
5000 m68k_linux_nat_target methods.
5001 (_initialize_m68k_linux_nat): Adjust to C++ification.
5003 * s390-linux-nat.c (s390_linux_nat_target): New class.
5004 (the_s390_linux_nat_target): New.
5005 (s390_linux_fetch_inferior_registers)
5006 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
5007 (s390_insert_watchpoint, s390_remove_watchpoint)
5008 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
5009 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
5010 (s390_auxv_parse, s390_read_description): Refactor as methods of
5011 s390_linux_nat_target.
5012 (_initialize_s390_nat): Adjust to C++ification.
5014 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
5015 (the_sparc_linux_nat_target): New.
5016 (_initialize_sparc_linux_nat): Adjust to C++ification.
5017 * sparc-nat.c (sparc_fetch_inferior_registers)
5018 (sparc_store_inferior_registers): Remove target_ops parameter.
5019 * sparc-nat.h (sparc_fetch_inferior_registers)
5020 (sparc_store_inferior_registers): Remove target_ops parameter.
5021 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
5022 (the_sparc64_linux_nat_target): New.
5023 (_initialize_sparc64_linux_nat): Adjust to C++ification.
5025 * spu-linux-nat.c (spu_linux_nat_target): New class.
5026 (the_spu_linux_nat_target): New.
5027 (spu_child_post_startup_inferior, spu_child_post_attach)
5028 (spu_child_wait, spu_fetch_inferior_registers)
5029 (spu_store_inferior_registers, spu_xfer_partial)
5030 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
5032 (_initialize_spu_nat): Adjust to C++ification.
5034 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
5035 (the_tilegx_linux_nat_target): New.
5036 (fetch_inferior_registers, store_inferior_registers):
5037 Refactor as methods.
5038 (_initialize_tile_linux_nat): Adjust to C++ification.
5040 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
5041 (the_xtensa_linux_nat_target): New.
5042 (xtensa_linux_fetch_inferior_registers)
5043 (xtensa_linux_store_inferior_registers): Refactor as
5044 xtensa_linux_nat_target methods.
5045 (_initialize_xtensa_linux_nat): Adjust to C++ification.
5047 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
5048 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
5049 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
5050 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
5051 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
5052 (fbsd_stopped_by_sw_breakpoint)
5053 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
5054 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
5055 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
5056 (fbsd_post_startup_inferior, fbsd_post_attach)
5057 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
5058 (fbsd_set_syscall_catchpoint)
5059 (super_xfer_partial, super_resume, super_wait)
5060 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
5061 (fbsd_handle_debug_trap): Remove target_ops parameter.
5062 (fbsd_nat_add_target): Delete.
5063 * fbsd-nat.h: Include "inf-ptrace.h".
5064 (fbsd_nat_add_target): Delete.
5065 (USE_SIGTRAP_SIGINFO): Define.
5066 (fbsd_nat_target): New class.
5068 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
5069 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
5070 (amd64bsd_target): Delete.
5071 * amd64-bsd-nat.h: New file.
5072 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
5074 (amd64_fbsd_nat_target): New class.
5075 (the_amd64_fbsd_nat_target): New.
5076 (amd64fbsd_read_description): Refactor as method of
5077 amd64_fbsd_nat_target.
5078 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5079 (_initialize_amd64fbsd_nat): Adjust to C++ification.
5080 * amd64-nat.h (amd64bsd_target): Delete function declaration.
5081 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
5082 (i386bsd_store_inferior_registers): Remove target_ops parameter.
5083 (i386bsd_target): Delete.
5084 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
5085 (i386bsd_fetch_inferior_registers)
5086 (i386bsd_store_inferior_registers): Declare.
5087 (i386_bsd_nat_target): New class.
5088 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
5089 (the_i386_fbsd_nat_target): New.
5090 (i386fbsd_resume, i386fbsd_read_description): Refactor as
5091 i386_fbsd_nat_target methods.
5092 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
5093 (_initialize_i386fbsd_nat): Adjust to C++ification.
5094 * x86-bsd-nat.c (super_mourn_inferior): Delete.
5095 (x86bsd_mourn_inferior, x86bsd_target): Delete.
5096 (_initialize_x86_bsd_nat): Adjust to C++ification.
5097 * x86-bsd-nat.h: Include "x86-nat.h".
5098 (x86bsd_target): Delete declaration.
5099 (x86bsd_nat_target): New class.
5101 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
5102 (the_aarch64_fbsd_nat_target): New.
5103 (aarch64_fbsd_fetch_inferior_registers)
5104 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
5105 aarch64_fbsd_nat_target.
5106 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
5107 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
5108 (the_alpha_bsd_nat_target): New.
5109 (alphabsd_fetch_inferior_registers)
5110 (alphabsd_store_inferior_registers): Refactor as
5111 alpha_bsd_nat_target methods.
5112 (_initialize_alphabsd_nat): Refactor as methods of
5113 alpha_bsd_nat_target.
5114 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
5115 (the_amd64_nbsd_nat_target): New.
5116 (_initialize_amd64nbsd_nat): Adjust to C++ification.
5117 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
5118 (the_amd64_obsd_nat_target): New.
5119 (_initialize_amd64obsd_nat): Adjust to C++ification.
5120 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
5121 (the_arm_fbsd_nat_target): New.
5122 (arm_fbsd_fetch_inferior_registers)
5123 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
5124 (_initialize_arm_fbsd_nat): Refactor as methods of
5125 arm_fbsd_nat_target.
5126 (_initialize_arm_fbsd_nat): Adjust to C++ification.
5127 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
5128 (the_arm_netbsd_nat_target): New.
5129 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
5130 arm_netbsd_nat_target.
5131 (_initialize_arm_netbsd_nat): Adjust to C++ification.
5132 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
5133 (the_hppa_nbsd_nat_target): New.
5134 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
5135 hppa_nbsd_nat_target methods.
5136 (_initialize_hppanbsd_nat): Adjust to C++ification.
5137 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
5138 (the_hppa_obsd_nat_target): New.
5139 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
5140 methods of hppa_obsd_nat_target.
5141 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
5143 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
5144 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
5146 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
5147 (_initialize_i386obsd_nat): Use add_target.
5148 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
5149 (the_m68k_bsd_nat_target): New.
5150 (m68kbsd_fetch_inferior_registers)
5151 (m68kbsd_store_inferior_registers): Refactor as methods of
5152 m68k_bsd_nat_target.
5153 (_initialize_m68kbsd_nat): Adjust to C++ification.
5154 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
5155 (the_mips_fbsd_nat_target): New.
5156 (mips_fbsd_fetch_inferior_registers)
5157 (mips_fbsd_store_inferior_registers): Refactor as methods of
5158 mips_fbsd_nat_target.
5159 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
5161 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
5162 (the_mips_nbsd_nat_target): New.
5163 (mipsnbsd_fetch_inferior_registers)
5164 (mipsnbsd_store_inferior_registers): Refactor as methods of
5165 mips_nbsd_nat_target.
5166 (_initialize_mipsnbsd_nat): Adjust to C++ification.
5167 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
5168 (the_mips64_obsd_nat_target): New.
5169 (mips64obsd_fetch_inferior_registers)
5170 (mips64obsd_store_inferior_registers): Refactor as methods of
5171 mips64_obsd_nat_target.
5172 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
5174 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
5176 * nbsd-nat.h: Include "inf-ptrace.h".
5177 (nbsd_nat_target): New class.
5178 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
5179 (obsd_wait): Refactor as methods of obsd_nat_target.
5180 (obsd_add_target): Delete.
5181 * obsd-nat.h: Include "inf-ptrace.h".
5182 (obsd_nat_target): New class.
5183 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
5184 (the_ppc_fbsd_nat_target): New.
5185 (ppcfbsd_fetch_inferior_registers)
5186 (ppcfbsd_store_inferior_registers): Refactor as methods of
5187 ppc_fbsd_nat_target.
5188 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
5190 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
5191 (the_ppc_nbsd_nat_target): New.
5192 (ppcnbsd_fetch_inferior_registers)
5193 (ppcnbsd_store_inferior_registers): Refactor as methods of
5194 ppc_nbsd_nat_target.
5195 (_initialize_ppcnbsd_nat): Adjust to C++ification.
5196 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
5197 (the_ppc_obsd_nat_target): New.
5198 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
5199 methods of ppc_obsd_nat_target.
5200 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
5202 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
5203 (the_sh_nbsd_nat_target): New.
5204 (shnbsd_fetch_inferior_registers)
5205 (shnbsd_store_inferior_registers): Refactor as methods of
5207 (_initialize_shnbsd_nat): Adjust to C++ification.
5208 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
5209 (inf_ptrace_xfer_partial): Delete.
5210 (sparc_xfer_partial, sparc_target): Delete.
5211 * sparc-nat.h (sparc_fetch_inferior_registers)
5212 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
5213 (sparc_target): Delete function declaration.
5214 (sparc_target): New template class.
5215 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
5216 (_initialize_sparcnbsd_nat): Adjust to C++ification.
5217 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
5218 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
5220 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
5221 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
5222 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
5223 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
5225 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
5226 (the_vax_bsd_nat_target): New.
5227 (vaxbsd_fetch_inferior_registers)
5228 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
5230 (_initialize_vaxbsd_nat): Adjust to C++ification.
5232 * bsd-kvm.c (bsd_kvm_target): New class.
5233 (bsd_kvm_ops): Now a bsd_kvm_target.
5234 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
5235 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
5236 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
5238 (bsd_kvm_return_one): Delete.
5239 (bsd_kvm_add_target): Adjust to C++ification.
5241 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
5242 (nto_procfs_target_procfs): New classes.
5243 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
5244 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
5245 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
5246 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
5247 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
5248 (procfs_remove_hw_breakpoint, procfs_resume)
5249 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
5250 (procfs_kill_inferior, procfs_store_registers)
5251 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
5252 as methods of nto_procfs_target.
5253 (nto_procfs_ops): Now an nto_procfs_target_procfs.
5254 (nto_native_ops): Delete.
5255 (procfs_open, procfs_native_open): Delete.
5256 (nto_native_ops): Now an nto_procfs_target_native.
5257 (init_procfs_targets): Adjust to C++ification.
5258 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
5259 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
5260 Refactor as methods of nto_procfs_target.
5262 * go32-nat.c (go32_nat_target): New class.
5263 (the_go32_nat_target): New.
5264 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
5265 (go32_store_registers, go32_xfer_partial, go32_files_info)
5266 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
5267 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
5268 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
5269 (go32_pid_to_str): Refactor as methods of go32_nat_target.
5270 (go32_target): Delete.
5271 (_initialize_go32_nat): Adjust to C++ification.
5273 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
5274 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
5275 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
5276 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
5278 (gnu_target): Delete.
5279 * gnu-nat.h (gnu_target): Delete.
5280 (gnu_nat_target): New class.
5281 * i386-gnu-nat.c (gnu_base_target): New.
5282 (i386_gnu_nat_target): New class.
5283 (the_i386_gnu_nat_target): New.
5284 (_initialize_i386gnu_nat): Adjust to C++ification.
5286 2018-05-02 Pedro Alves <palves@redhat.com>
5288 * bfd-target.c (target_bfd_xclose): Rename to ...
5289 (target_bfd_close): ... this.
5290 (target_bfd_reopen): Adjust.
5291 * target.c (target_close): Remove references to to_xclose.
5292 * target.h (target_ops::to_xclose): Delete.
5293 (target_ops::to_close): Update comments.
5295 2018-05-02 Pedro Alves <palves@redhat.com>
5297 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
5299 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
5300 * inf-ptrace.c (inf_ptrace_register_u_offset)
5301 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
5302 (inf_ptrace_store_register, inf_ptrace_store_registers)
5303 (inf_ptrace_trad_target): Move to ...
5304 * linux-nat-trad.c: ... this new file.
5305 * linux-nat-trad.h: New file.
5306 * linux-nat.c (linux_target_install_ops): Make extern.
5307 (linux_trad_target): Delete.
5308 * linux-nat.h (linux_trad_target): Delete declaration.
5309 (linux_target_install_ops): Declare.
5310 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
5313 2018-05-02 Pedro Alves <palves@redhat.com>
5315 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5316 procfs_target/add_target here.
5317 * procfs.c (procfs_target): Make static.
5318 (_initialize_procfs): Call add_target here.
5319 * procfs.h (struct target_ops): Remove forward declaration.
5320 (procfs_target): Remove declaration.
5321 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
5323 2018-05-02 Pedro Alves <palves@redhat.com>
5325 * procfs.c (procfs_stopped_by_watchpoint)
5326 (procfs_insert_watchpoint, procfs_remove_watchpoint)
5327 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
5329 (procfs_use_watchpoints): Delete, move contents...
5330 (procfs_target): ... here.
5331 * procfs.h (procfs_use_watchpoints): Delete declaration.
5332 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
5333 procfs_use_watchpoints.
5334 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
5335 procfs_use_watchpoints.
5337 2018-05-02 Tom Tromey <tom@tromey.com>
5340 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
5341 and var_zuinteger_unlimited.
5342 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
5343 and PARAM_ZUINTEGER_UNLIMITED.
5344 (set_parameter_value): Handle var_zuinteger and
5345 var_zuinteger_unlimited.
5346 (add_setshow_generic): Likewise.
5347 (parmpy_init): Likewise.
5349 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
5352 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
5353 pointer is not null before dereferencing it.
5355 2018-04-30 Tom Tromey <tom@tromey.com>
5357 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
5360 2018-04-30 Tom Tromey <tom@tromey.com>
5362 * breakpoint.c (mention): Remove use of is_mi_like_p.
5363 (print_mention_ranged_breakpoint): Likewise.
5364 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
5367 2018-04-30 Tom Tromey <tom@tromey.com>
5369 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
5371 2018-04-30 Tom Tromey <tom@tromey.com>
5373 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
5374 (info_spu_event_command): Remove some uses of is_mi_like_p.
5376 2018-04-30 Tom Tromey <tom@tromey.com>
5378 * python/py-framefilter.c (py_print_single_arg)
5379 (enumerate_locals, py_print_args, py_print_frame): Remove some
5380 uses of is_mi_like_p.
5382 2018-04-30 Tom Tromey <tom@tromey.com>
5385 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
5386 * ui-out.h (ui_out::is_mi_like_p): Now const.
5387 (ui_out::do_is_mi_like_p): Now const.
5388 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
5390 2018-04-30 Tom Tromey <tom@tromey.com>
5392 * varobj.c (varobj_set_visualizer): Use new_reference.
5393 * python/python.c (gdbpy_decode_line): Use new_reference.
5394 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
5397 2018-04-30 Tom Tromey <tom@tromey.com>
5399 * varobj.c (install_new_value): Use new_reference.
5400 * value.h (value_incref): Return void. Swap intro comment with
5402 * value.c (set_value_parent): Use new_reference.
5403 (value_incref): Return void. Update intro comment.
5404 (release_value): Use new_reference.
5405 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
5407 2018-04-30 Tom Tromey <tom@tromey.com>
5409 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
5410 * gdb_bfd.h (new_bfd_ref): Remove.
5411 (gdb_bfd_open): Update comment.
5412 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
5413 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
5414 (gdb_bfd_fdopenr): Use new_reference.
5415 * exec.c (exec_file_attach): Use new_reference.
5417 2018-04-30 Tom Tromey <tom@tromey.com>
5419 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
5422 2018-04-30 Tom Tromey <tom@tromey.com>
5424 * jit.c (jit_read_code_entry): Use type_align.
5425 * i386-tdep.c (i386_gdbarch_init): Don't call
5426 set_gdbarch_long_long_align_bit.
5427 * gdbarch.sh: Remove long_long_align_bit.
5428 * gdbarch.c, gdbarch.h: Rebuild.
5429 * arc-tdep.c (arc_type_align): New function.
5430 (arc_gdbarch_init): Use arc_type_align. Don't call
5431 set_gdbarch_long_long_align_bit.
5433 2018-04-30 Tom Tromey <tom@tromey.com>
5435 * rust-lang.c (rust_type_alignment): Remove.
5436 (rust_composite_type): Use type_align.
5438 2018-04-30 Tom Tromey <tom@tromey.com>
5440 * NEWS: Mention Type.align.
5441 * python/py-type.c (typy_get_alignof): New function.
5442 (type_object_getset): Add "alignof".
5444 2018-04-30 Tom Tromey <tom@tromey.com>
5448 * std-operator.def (UNOP_ALIGNOF): New operator.
5449 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
5451 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
5452 * c-lang.c (c_op_print_tab): Add alignof.
5453 * c-exp.y (ALIGNOF): New token.
5454 (exp): Add "ALIGNOF" production.
5455 (ident_tokens): Add _Alignof and alignof.
5457 2018-04-30 Tom Tromey <tom@tromey.com>
5459 * i386-tdep.c (i386_type_align): New function.
5460 (i386_gdbarch_init): Update.
5461 * gdbarch.sh (type_align): New method.
5462 * gdbarch.c, gdbarch.h: Rebuild.
5463 * arch-utils.h (default_type_align): Declare.
5464 * arch-utils.c (default_type_align): New function.
5465 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
5466 (struct type) <align_log2>: New field.
5467 <instance_flags>: Now a bitfield.
5468 (TYPE_RAW_ALIGN): New macro.
5469 (type_align, type_raw_align, set_type_align): Declare.
5470 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
5472 * dwarf2read.c (quirk_rust_enum): Set type alignment.
5473 (get_alignment, maybe_set_alignment): New functions.
5474 (read_structure_type, read_enumeration_type, read_array_type)
5475 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
5476 (read_subrange_type, read_base_type): Set type alignment.
5478 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
5480 * dwarf2read.c (read_index_from_section): Use bool.
5482 2018-04-29 Fabian Groffen <grobian@gentoo.org>
5485 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
5488 2018-04-29 John Reiser <jreiser@BitWagon.com>
5491 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
5492 last step, and do it atomically.
5494 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
5496 * compile/compile-c-types.c (convert_int, convert_float):
5499 2018-04-27 Tom Tromey <tom@tromey.com>
5502 * rust-lang.c (rust_inclusive_range_type_p): New function.
5503 (rust_range): Handle inclusive ranges.
5504 (rust_compute_range): Likewise.
5505 * rust-exp.y (struct rust_op) <inclusive>: New field.
5506 (DOTDOTEQ): New constant.
5507 (range_expr): Add "..=" productions.
5508 (operator_tokens): Add "..=" token.
5509 (ast_range): Add "inclusive" parameter.
5510 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
5512 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
5514 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
5515 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
5517 * expprint.c (print_subexp_standard): Handle new bounds values.
5518 (dump_subexp_body_standard): Likewise.
5520 2018-04-27 Tom Tromey <tom@tromey.com>
5522 * configure: Rebuild.
5523 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
5524 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
5526 (class symbol_needs_eval_context): Likewise.
5527 * dwarf2read.c (mock_mapped_index::symbol_name_count)
5528 (mock_mapped_index::symbol_name_at): Use "override". Remove
5530 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
5532 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
5533 * aarch64-tdep.c (instruction_reader::read): Use "override".
5534 (instruction_reader_test::read): Likewise.
5535 * arm-tdep.c (instruction_reader::read): Use "override".
5536 (instruction_reader_thumb::read): Likewise.
5538 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
5541 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
5542 instead of remote_send.
5543 (remote_send): Remove.
5545 2018-04-26 Pedro Alves <palves@redhat.com>
5547 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
5548 find_function_start_sal instead of find_pc_line.
5550 2018-04-26 Pedro Alves <palves@redhat.com>
5552 * breakpoint.c (set_breakpoint_location_function): Handle
5554 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
5555 * elfread.c (elf_symtab_read): Give data symbols with
5556 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
5557 (elf_rel_plt_read): Update comment.
5558 * linespec.c (convert_linespec_to_sals): Handle
5560 (minsym_found): Handle mst_data_gnu_ifunc.
5561 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
5562 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
5563 * parse.c (find_minsym_type_and_address): Handle
5565 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
5566 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
5567 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
5569 <mst_data_gnu_ifunc>: New enumerator.
5571 2018-04-26 Pedro Alves <palves@redhat.com>
5573 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
5574 (lookup_minimal_symbol_by_pc_section): ... this. Replace
5575 'want_trampoline' parameter by a lookup_msym_prefer parameter.
5577 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
5578 (lookup_minimal_symbol_by_pc): Adjust.
5579 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
5580 (lookup_solib_trampoline_symbol_by_pc): Adjust.
5581 * minsyms.h (lookup_msym_prefer): New enum.
5582 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5583 parameter by a lookup_msym_prefer parameter.
5585 2018-04-26 Pedro Alves <palves@redhat.com>
5587 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
5588 ends in "@plt" instead of looking at the symbol's section.
5590 2018-04-26 Pedro Alves <palves@redhat.com>
5592 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
5594 (find_pc_partial_function_gnu_ifunc): Rename to ...
5595 (find_pc_partial_function): ... this, and remove references to
5597 (find_pc_partial_function): Delete old implementation.
5598 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
5600 2018-04-26 Pedro Alves <palves@redhat.com>
5602 * linespec.c (struct bound_minimal_symbol_search_key): New.
5603 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
5604 skip first line if we found a GNU ifunc minimal symbol by name.
5605 (compare_msymbols): Change parameters to work with a destructured
5607 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
5610 2018-04-26 Pedro Alves <palves@redhat.com>
5612 * breakpoint.c (set_breakpoint_location_function): Don't resolve
5613 ifunc targets here. Instead, if we have an ifunc minsym, use its
5615 (add_location_to_breakpoint): Store the minsym and the objfile in
5616 the breakpoint location.
5617 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
5618 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
5619 Record the minsym in the sal.
5620 * symtab.h (symtab_and_line) <msymbol>: New field.
5622 2018-04-26 Pedro Alves <palves@redhat.com>
5624 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
5625 unless we actually resolved the ifunc.
5627 2018-04-26 Pedro Alves <palves@redhat.com>
5629 * c-exp.y (variable production): Prefer ifunc minsyms over
5630 regular function symbols.
5631 * symtab.c (find_gnu_ifunc): New function.
5632 * minsyms.h (lookup_msym_prefer): New enum.
5633 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
5634 parameter by a lookup_msym_prefer parameter.
5635 * symtab.h (find_gnu_ifunc): New declaration.
5637 2018-04-26 Pedro Alves <palves@redhat.com>
5639 * blockframe.c (find_gnu_ifunc_target_type): New function.
5640 (find_function_type): New.
5641 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
5642 return a value with a memory address.
5643 (eval_call): For calls to GNU ifunc functions, try to find the
5644 type of the target function from the type that the resolver
5646 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
5648 * infcall.c (find_function_return_type): Delete.
5649 (find_function_addr): Add 'function_type' parameter. For calls to
5650 GNU ifunc functions, try to find the type of the target function
5651 from the type that the resolver returns, and return it via
5653 (call_function_by_hand_dummy): Adjust to use the function type
5654 returned by find_function_addr.
5655 (find_function_addr): Add 'function_type' parameter and move
5657 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
5660 2018-04-26 Pedro Alves <palves@redhat.com>
5662 * c-exp.y (variable production): Skip finding an alias for ifunc
5665 2018-04-26 Pedro Alves <palves@redhat.com>
5667 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
5669 2018-04-25 Pedro Alves <palves@redhat.com>
5671 * infcmd.c (kill_command): Print the pid as string, not the whole
5672 thread's ptid. Add comment. s/has been killed/killed/ in output
5674 * remote.c (remote_detach_1): Print the pid as string, not the
5675 whole thread's ptid.
5677 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5678 Sergio Durigan Junior <sergiodj@redhat.com>
5679 Pedro Alves <palves@redhat.com>
5681 * infcmd.c (kill_command): Print message when inferior has
5683 * inferior.c (print_inferior_events): Remove 'static'. Set as
5685 (add_inferior): Improve message printed when
5686 'print_inferior_events' is on.
5687 (exit_inferior): Remove message printed when
5688 'print_inferior_events' is on.
5689 (detach_inferior): Improve message printed when
5690 'print_inferior_events' is on.
5691 (initialize_inferiors): Use 'add_inferior_silent' to set
5692 'current_inferior_'.
5693 * inferior.h (print_inferior_events): Declare here as
5695 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
5696 '[Detaching...]' messages when 'print_inferior_events' is on.
5697 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
5698 as prefix/suffix for messages. Remove periods. Fix erroneous
5699 'Detaching after fork from child...', replace it by '... from
5701 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
5702 prefix/suffix when printing 'Detaching...' messages. Print
5703 them when 'print_inferior_events' is on.
5704 * remote.c (remote_detach_1): Print message when detaching
5705 from inferior and '!is_fork_parent'.
5707 2018-04-24 Tom Tromey <tom@tromey.com>
5709 * cli-out.h: Reindent.
5711 2018-04-24 Tom Tromey <tom@tromey.com>
5713 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
5714 (cli_ui_out::do_field_string): Use fputs_filtered.
5715 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
5717 2018-04-23 Tom Tromey <tom@tromey.com>
5719 * guile/scm-frame.c (gdbscm_frame_read_var): Use
5720 gdb::unique_xmalloc_ptr.
5722 2018-04-23 Tom Tromey <tom@tromey.com>
5724 * configure: Rebuild.
5726 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
5729 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
5730 prepare_for_testing. Set normal_bp to r_debug_state if target
5733 2018-04-21 Pedro Alves <palves@redhat.com>
5734 Rajendra SY <rajendra.sy@gmail.com>
5736 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
5737 * remote.c (extended_remote_attach): In all-stop mode, mark the
5738 thread as executing.
5740 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5742 * thread.c (thread_apply_all_command): Fix comment.
5743 (thread_command): Fix comment.
5745 2018-04-10 Alan Hayward <alan.hayward@arm.com>
5747 * common/tdesc.h (tdesc_create_feature): Remove xml filename
5749 * features/aarch64-core.c (create_feature_aarch64_core):
5751 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
5753 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
5755 * features/i386/32bit-avx512.c
5756 (create_feature_i386_32bit_avx512): Likewise.
5757 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
5759 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
5761 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
5763 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
5765 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
5767 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
5769 * features/i386/64bit-avx512.c
5770 (create_feature_i386_64bit_avx512): Likewise.
5771 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
5773 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
5775 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
5777 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
5779 * features/i386/64bit-segments.c
5780 (create_feature_i386_64bit_segments): Likewise.
5781 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
5783 * features/i386/x32-core.c
5784 (create_feature_i386_x32_core): Likewise.
5785 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
5786 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
5787 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
5788 * target-descriptions.c: In generated code, don't pass xml
5791 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5793 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
5794 (print_xml_feature::visit_post): Likewise.
5795 (print_xml_feature::visit): Likewise.
5796 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
5797 (print_xml_feature): Add new class.
5798 * regformats/regdat.sh: Null xmltarget on feature targets.
5799 * target-descriptions.c (struct target_desc): Add xmltarget.
5800 (maintenance_check_tdesc_xml_convert): Add unittest function.
5801 (tdesc_get_features_xml): Add function to get xml.
5802 (maintenance_check_xml_descriptions): Test xml generation.
5803 * xml-tdesc.c (string_read_description_xml): Add function.
5804 * xml-tdesc.h (string_read_description_xml): Add declaration.
5806 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5808 * features/Makefile: Add feature marker to targets with new style
5809 target descriptions.
5810 * regformats/aarch64.dat: Regenerate.
5811 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
5812 * regformats/i386/amd64-avx-linux.dat: Likewise.
5813 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
5814 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
5815 * regformats/i386/amd64-linux.dat: Likewise.
5816 * regformats/i386/amd64-mpx-linux.dat: Likewise.
5817 * regformats/i386/amd64.dat: Likewise.
5818 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
5819 * regformats/i386/i386-avx-linux.dat: Likewise.
5820 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
5821 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
5822 * regformats/i386/i386-linux.dat: Likewise.
5823 * regformats/i386/i386-mmx-linux.dat: Likewise.
5824 * regformats/i386/i386-mpx-linux.dat: Likewise.
5825 * regformats/i386/i386.dat: Likewise.
5826 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
5827 * regformats/i386/x32-avx-linux.dat: Likewise.
5828 * regformats/i386/x32-linux.dat: Likewise.
5829 * regformats/tic6x-c62x-linux.dat: Likewise.
5830 * regformats/tic6x-c64x-linux.dat: Likewise.
5831 * regformats/tic6x-c64xp-linux.dat: Likewise.
5832 * regformats/regdat.sh: Parse feature marker.
5834 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5836 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
5837 (tdesc_osabi_name): Likewise.
5838 * target-descriptions.c (tdesc_architecture_name): Add new
5840 (tdesc_osabi_name): Likewise.
5842 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5844 * common/tdesc.c (tdesc_predefined_type): Move to here.
5845 (tdesc_named_type): Likewise.
5846 (tdesc_create_vector): Likewise.
5847 (tdesc_create_struct): Likewise.
5848 (tdesc_set_struct_size): Likewise.
5849 (tdesc_create_union): Likewise.
5850 (tdesc_create_flags): Likewise.
5851 (tdesc_create_enum): Likewise.
5852 (tdesc_add_field): Likewise.
5853 (tdesc_add_typed_bitfield): Likewise.
5854 (tdesc_add_bitfield): Likewise.
5855 (tdesc_add_flag): Likewise.
5856 (tdesc_add_enum_value): Likewise.
5857 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
5858 (struct tdesc_type_vector): Likewise.
5859 (struct tdesc_type_field): Likewise.
5860 (struct tdesc_type_with_fields): Likewise.
5861 (tdesc_create_enum): Add declaration.
5862 (tdesc_add_typed_bitfield): Likewise.
5863 (tdesc_add_enum_value): Likewise.
5864 * target-descriptions.c (tdesc_type_field): Move from here.
5865 (tdesc_type_builtin): Likewise.
5866 (tdesc_type_vector): Likewise.
5867 (tdesc_type_with_fields): Likewise.
5868 (tdesc_predefined_types): Likewise.
5869 (tdesc_named_type): Likewise.
5870 (tdesc_create_vector): Likewise.
5871 (tdesc_create_struct): Likewise.
5872 (tdesc_set_struct_size): Likewise.
5873 (tdesc_create_union): Likewise.
5874 (tdesc_create_flags): Likewise.
5875 (tdesc_create_enum): Likewise.
5876 (tdesc_add_field): Likewise.
5877 (tdesc_add_typed_bitfield): Likewise.
5878 (tdesc_add_bitfield): Likewise.
5879 (tdesc_add_flag): Likewise.
5880 (tdesc_add_enum_value): Likewise.
5881 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
5882 (tdesc_add_typed_bitfield): Likewise.
5883 (tdesc_add_enum_value): Likewise.
5885 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5887 * common/tdesc.c (tdesc_feature::accept): Move to here.
5888 (tdesc_feature::operator==): Likewise.
5889 (tdesc_create_reg): Likewise.
5890 * common/tdesc.h (tdesc_type_kind): Likewise.
5891 (struct tdesc_type): Likewise.
5892 (struct tdesc_feature): Likewise.
5893 * regformats/regdat.sh: Create a feature.
5894 * target-descriptions.c (tdesc_type_kind): Move from here.
5895 (tdesc_type): Likewise.
5896 (tdesc_type_up): Likewise.
5897 (tdesc_feature): Likewise.
5898 (tdesc_create_reg): Likewise.
5900 2018-04-18 Alan Hayward <alan.hayward@arm.com>
5902 * Makefile.in: Add arch/tdesc.c
5903 * common/tdesc.c: New file.
5904 * common/tdesc.h (tdesc_element_visitor): Move to here.
5905 (tdesc_element): Likewise.
5906 (tdesc_reg): Likewise.
5907 (tdesc_reg_up): Likewise.
5908 * regformats/regdef.h (reg): Add offset to constructors.
5909 * target-descriptions.c (tdesc_element_visitor): Move from here.
5910 (tdesc_element): Likewise.
5911 (tdesc_reg): Likewise.
5912 (tdesc_reg_up): Likewise.
5914 2018-04-17 Tom Tromey <tom@tromey.com>
5916 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
5919 2018-04-17 Tom Tromey <tom@tromey.com>
5921 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
5923 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
5925 * symtab.c (print_symbol_info): Skip printing filename and line
5926 number when `last' is NULL.
5927 (symtab_symbol_info): Use empty string instead of NULL for first
5928 invocation of print_symbol_info.
5929 (rbreak_command): Pass NULL to `last' parameter of
5932 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
5934 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
5937 2018-04-16 Pedro Alves <palves@redhat.com>
5939 * MAINTAINERS (sh): Remove.
5940 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
5941 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
5942 (ALLDEPFILES): Remove sh64-tdep.c.
5943 * NEWS: Mentions that support for SH-5/SH64 is removed.
5944 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
5945 (sh*-*-openbsd*): Ditto.
5946 (sh64-*-elf*): Remove.
5948 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
5949 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
5950 * sh-tdep.c: No longer include "sh64-tdep.h".
5951 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
5952 * sh64-tdep.c, sh64-tdep.h: Remove files.
5954 2018-04-16 Pedro Alves <palves@redhat.com>
5956 * MAINTAINERS: Remove m88k.
5957 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
5958 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
5959 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
5960 * NEWS: Mention that support for m88k was removed.
5961 * configure.host (m88*-*-*): Remove support.
5962 * configure.nat (m88k-*-*): Remove support.
5963 * configure.tgt (m88*-*-openbsd*): Remove.
5964 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
5966 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
5968 * configure.tgt (x86_tobjs): New variable.
5969 (amd64_tobjs, i386_tobjs): Use it.
5971 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5973 * symtab.c (print_symbol_info): Precede the symbol definition by
5974 the line number when available.
5975 * NEWS: Advertise this enhancement.
5977 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
5979 * NEWS (New options): announce set/show record btrace cpu.
5980 * btrace.c: Include record-btrace.h.
5981 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
5982 the vendor is unknown.
5983 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
5984 Maybe overwrite the btrace configuration's cpu.
5985 (btrace_compute_ftrace): Add cpu parameter. Update callers.
5986 (btrace_fetch): Add cpu parameter. Update callers.
5987 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
5988 Maybe overwrite the btrace configuration's cpu. Skip enabling
5989 errata workarounds if the vendor is unknown.
5990 * python/py-record-btrace.c: Include record-btrace.h.
5991 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
5992 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
5993 * record-btrace.c (record_btrace_cpu_state_kind): New.
5994 (record_btrace_cpu): New.
5995 (set_record_btrace_cpu_cmdlist): New.
5996 (record_btrace_get_cpu): New.
5997 (require_btrace_thread, record_btrace_info)
5998 (record_btrace_resume_thread): Call record_btrace_get_cpu.
5999 (cmd_set_record_btrace_cpu_none): New.
6000 (cmd_set_record_btrace_cpu_auto): New.
6001 (cmd_set_record_btrace_cpu): New.
6002 (cmd_show_record_btrace_cpu): New.
6003 (_initialize_record_btrace): Initialize set/show record btrace cpu
6005 * record-btrace.h (record_btrace_get_cpu): New.
6007 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6009 * record.c (set_record_command): Fix typo in message.
6011 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6013 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
6015 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
6017 * infrun.c (process_event_stop_test): Call
6018 gdbarch_in_indirect_branch_thunk.
6019 * gdbarch.sh (in_indirect_branch_thunk): New.
6020 * gdbarch.c: Regenerated.
6021 * gdbarch.h: Regenerated.
6024 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
6025 (HFILES_NO_SRCDIR): Add x86-tdep.h.
6026 (ALLDEPFILES): Add x86-tdep.c.
6027 * arch-utils.h (default_in_indirect_branch_thunk): New.
6028 * arch-utils.c (default_in_indirect_branch_thunk): New.
6029 * i386-tdep: Include x86-tdep.h.
6030 (i386_in_indirect_branch_thunk): New.
6031 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
6033 * amd64-tdep: Include x86-tdep.h.
6034 (amd64_in_indirect_branch_thunk): New.
6035 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
6037 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6040 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
6041 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
6042 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
6045 2018-04-12 Tom Tromey <tom@tromey.com>
6047 * rust-lang.c (rust_print_struct_def): Remove univariant code.
6048 (rust_evaluate_subexp): Likewise.
6050 2018-04-12 Pedro Alves <palves@redhat.com>
6052 * procfs.c (procfs_detach): Make forward declaration's prototype
6053 match definition's protototype.
6054 (proc_get_LDT_entry): Remove stale do_cleanups call.
6056 2018-04-12 Pedro Alves <palves@redhat.com>
6058 * target.h (target_ops::to_has_exited): Delete.
6059 (target_has_exited): Delete.
6060 * target-delegates.c: Regenerate.
6062 2018-04-11 Pedro Alves <palves@redhat.com>
6064 * target.c (fileio_fh_t::t): Add comment.
6065 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6066 (target_fileio_close): Handle a NULL target.
6067 (invalidate_fileio_fh): New.
6068 (target_close): Call it.
6069 * remote.c (remote_hostio_send_command): No longer check whether
6070 remote_desc is open.
6072 2018-04-11 Pedro Alves <palves@redhat.com>
6074 * target.c (fileio_fh_t): Make it a named struct instead of a
6076 (fileio_fh_t::is_closed): New method.
6077 (DEF_VEC_O (fileio_fh_t)): Remove.
6078 (fileio_fhandles): Now a std::vector.
6079 (is_closed_fileio_fh): Delete.
6080 (acquire_fileio_fd): Adjust. Rename parameters.
6081 (release_fileio_fd): Adjust.
6082 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
6083 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
6084 (target_fileio_close): Adjust.
6086 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
6088 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
6091 2018-04-10 Pedro Alves <palves@redhat.com>
6093 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
6094 (scoped_finish_thread_state): New class.
6095 * infcmd.c (run_command_1): Use it instead of finish_thread_state
6097 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
6098 (fetch_inferior_event, normal_stop): Likewise.
6099 * thread.c (finish_thread_state_cleanup): Delete.
6101 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6102 Pedro Alves <palves@redhat.com>
6104 * value.c: Include "selftest.h" and "common/array-view.h".
6105 (struct range) <operator ==>: New.
6106 (test_ranges_contain): New.
6107 (check_ranges_vector): New.
6108 (test_insert_into_bit_range_vector): New.
6109 (_initialize_values): Register selftests.
6110 * common/array-view.h (operator==, operator!=): New.
6112 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6114 * common/gdb_vecs.h (unordered_remove): Add overload that takes
6116 * inline-frame.c: Include <algorithm>.
6117 (struct inline_state): Add constructor.
6118 (inline_state_s): Remove.
6119 (DEF_VEC_O(inline_state_s)): Remove.
6120 (inline_states): Change type to std::vector.
6121 (find_inline_frame_state): Adjust to std::vector.
6122 (allocate_inline_frame_state): Remove.
6123 (clear_inline_frame_state): Adjust to std::vector.
6124 (skip_inline_frames): Adjust to std::vector.
6126 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6128 * tracepoint.h (struct trace_state_variable): Add constructor.
6129 <name>: Change type to std::string.
6130 * tracepoint.c (tsv_s): Remove.
6131 (DEF_VEC_O(tsv_s)): Remove.
6132 (tvariables): Change to std::vector.
6133 (create_trace_state_variable): Adjust to std::vector.
6134 (find_trace_state_variable): Likewise.
6135 (find_trace_state_variable_by_number): Likewise.
6136 (delete_trace_state_variable): Likewise.
6137 (trace_variable_command): Adjust to std::string.
6138 (delete_trace_variable_command): Likewise.
6139 (tvariables_info_1): Adjust to std::vector.
6140 (save_trace_state_variables): Likewise.
6141 (start_tracing): Likewise.
6142 (merge_uploaded_trace_state_variables): Adjust to std::vector
6144 * target.h (struct target_ops)
6145 <to_download_trace_state_variable>: Pass reference to
6146 trace_state_variable.
6147 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
6148 * target-delegates.c: Re-generate.
6149 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
6150 (mi_tsv_deleted): Likewise.
6151 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
6152 * remote.c (remote_download_trace_state_variable): Change
6153 pointer to reference and adjust.
6154 * make-target-delegates (parse_argtypes): Handle references.
6155 (write_function_header): Likewise.
6156 (munge_type): Likewise.
6158 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6160 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6161 string_view-selftests.c.
6162 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
6164 * unittests/basic_string_view/cons/char/1.cc: Likewise.
6165 * unittests/basic_string_view/cons/char/2.cc: Likewise.
6166 * unittests/basic_string_view/cons/char/3.cc: Likewise.
6167 * unittests/basic_string_view/element_access/char/1.cc:
6169 * unittests/basic_string_view/element_access/char/empty.cc:
6171 * unittests/basic_string_view/element_access/char/front_back.cc:
6173 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
6174 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
6176 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
6178 * unittests/basic_string_view/modifiers/swap/char/1.cc:
6180 * unittests/basic_string_view/operations/compare/char/1.cc:
6182 * unittests/basic_string_view/operations/compare/char/13650.cc:
6184 * unittests/basic_string_view/operations/copy/char/1.cc:
6186 * unittests/basic_string_view/operations/data/char/1.cc:
6188 * unittests/basic_string_view/operations/find/char/1.cc:
6190 * unittests/basic_string_view/operations/find/char/2.cc:
6192 * unittests/basic_string_view/operations/find/char/3.cc:
6194 * unittests/basic_string_view/operations/find/char/4.cc:
6196 * unittests/basic_string_view/operations/rfind/char/1.cc:
6198 * unittests/basic_string_view/operations/rfind/char/2.cc:
6200 * unittests/basic_string_view/operations/rfind/char/3.cc:
6202 * unittests/basic_string_view/operations/substr/char/1.cc:
6204 * unittests/basic_string_view/operators/char/2.cc: Likewise.
6205 * unittests/string_view-selftests.c: New file.
6207 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6209 * unittests/basic_string_view/capacity/1.cc: New file.
6210 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
6211 * unittests/basic_string_view/cons/char/1.cc: New file.
6212 * unittests/basic_string_view/cons/char/2.cc: New file.
6213 * unittests/basic_string_view/cons/char/3.cc: New file.
6214 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
6215 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
6216 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
6217 * unittests/basic_string_view/element_access/char/1.cc: New file.
6218 * unittests/basic_string_view/element_access/char/2.cc: New file.
6219 * unittests/basic_string_view/element_access/char/empty.cc: New file.
6220 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
6221 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
6222 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
6223 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
6224 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
6225 * unittests/basic_string_view/include.cc: New file.
6226 * unittests/basic_string_view/inserters/char/1.cc: New file.
6227 * unittests/basic_string_view/inserters/char/2.cc: New file.
6228 * unittests/basic_string_view/inserters/char/3.cc: New file.
6229 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
6230 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
6231 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
6232 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
6233 * unittests/basic_string_view/literals/types.cc: New file.
6234 * unittests/basic_string_view/literals/values.cc: New file.
6235 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
6236 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
6237 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
6238 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
6239 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
6240 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
6241 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
6242 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
6243 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
6244 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
6245 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
6246 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
6247 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
6248 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
6249 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
6250 * unittests/basic_string_view/operations/data/char/1.cc: New file.
6251 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
6252 * unittests/basic_string_view/operations/find/char/1.cc: New file.
6253 * unittests/basic_string_view/operations/find/char/2.cc: New file.
6254 * unittests/basic_string_view/operations/find/char/3.cc: New file.
6255 * unittests/basic_string_view/operations/find/char/4.cc: New file.
6256 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
6257 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
6258 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
6259 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
6260 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
6261 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
6262 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
6263 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
6264 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
6265 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
6266 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
6267 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
6268 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
6269 * unittests/basic_string_view/operators/char/2.cc: New file.
6270 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
6271 * unittests/basic_string_view/range_access/char/1.cc: New file.
6272 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
6273 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
6274 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
6275 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
6276 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
6277 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
6278 * unittests/basic_string_view/requirements/typedefs.cc: New file.
6279 * unittests/basic_string_view/typedefs.cc: New file.
6280 * unittests/basic_string_view/types/1.cc: New file.
6282 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6284 * common/gdb_string_view.h: Remove libstdc++ implementation
6285 details, adjust to gdb reality.
6286 * common/gdb_string_view.tcc: Likewise.
6287 * cli/cli-script.c (struct string_view): Remove.
6288 (user_args) <m_args>: Change element type to gdb::string_view.
6289 (user_args::insert_args): Adjust.
6291 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6293 * common/gdb_string_view.h: New file.
6294 * common/gdb_string_view.tcc: New file.
6296 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6298 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
6299 * configure: Re-generate.
6301 2018-04-09 Pedro Alves <palves@redhat.com>
6303 * gdbarch.sh: Include "observable.h" instead of "observer.h".
6304 (set_target_gdbarch): Call
6305 gdb::observers::architecture_changed.notify instead of
6306 observer_notify_architecture_changed.
6308 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6310 * tracepoint.c (struct current_traceframe_cleanup): Remove.
6311 (do_restore_current_traceframe_cleanup): Remove.
6312 (restore_current_traceframe_cleanup_dtor): Remove.
6313 (make_cleanup_restore_current_traceframe): Remove.
6314 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
6316 * tracepoint.h (struct scoped_restore_current_traceframe): New.
6317 * infrun.c (fetch_inferior_event): Use
6318 scoped_restore_current_traceframe.
6320 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6322 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
6324 <n_allocated_type_units>: Remove.
6325 <all_type_units>: Change to std::vector.
6326 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6327 to std::vector change.
6328 (dwarf2_per_objfile::get_cutu): Likewise.
6329 (dwarf2_per_objfile::get_tu): Likewise.
6330 (create_signatured_type_table_from_index): Likewise.
6331 (create_signatured_type_table_from_debug_names): Likewise.
6332 (dw2_symtab_iter_next): Likewise.
6333 (dw2_print_stats): Likewise.
6334 (dw2_expand_all_symtabs): Likewise.
6335 (dw2_expand_marked_cus): Likewise.
6336 (dw2_debug_names_iterator::next): Likewise.
6337 (dwarf2_initialize_objfile): Likewise.
6338 (add_signatured_type_cu_to_table): Likewise.
6339 (create_all_type_units): Likewise.
6340 (add_type_unit): Likewise.
6341 (struct tu_abbrev_offset): Add constructor.
6342 (build_type_psymtabs_1): Adjust to std::vector change.
6343 (print_tu_stats): Likewise.
6344 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6345 (write_debug_names): Likewise.
6347 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6349 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
6350 Make an std::vector.
6351 <n_comp_units>: Remove.
6352 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
6353 to std::vector change.
6354 (dwarf2_per_objfile::get_cutu): Likewise.
6355 (dwarf2_per_objfile::get_cu): Likewise.
6356 (create_cus_from_index): Likewise.
6357 (create_addrmap_from_index): Likewise.
6358 (create_addrmap_from_aranges): Likewise.
6359 (dwarf2_read_index): Likewise.
6360 (dw2_find_last_source_symtab): Likewise.
6361 (dw2_map_symtabs_matching_filename): Likewise.
6362 (dw2_symtab_iter_next): Likewise.
6363 (dw2_print_stats): Likewise.
6364 (dw2_expand_all_symtabs): Likewise.
6365 (dw2_expand_symtabs_with_fullname): Likewise.
6366 (dw2_expand_marked_cus): Likewise.
6367 (dw2_map_symbol_filenames): Likewise.
6368 (create_cus_from_debug_names): Likewise.
6369 (dwarf2_read_debug_names): Likewise.
6370 (dw2_debug_names_iterator::next): Likewise.
6371 (dwarf2_initialize_objfile): Likewise.
6372 (set_partial_user): Likewise.
6373 (dwarf2_build_psymtabs_hard): Likewise.
6374 (read_comp_units_from_section): Remove arguments, adjust to
6376 (create_all_comp_units): Adjust to std::vector and
6377 read_comp_units_from_section changes.
6378 (dwarf2_find_containing_comp_unit): Adjust to std::vector
6380 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
6381 (psyms_seen_size): Likewise.
6382 (write_gdbindex): Likewise.
6383 (write_debug_names): Likewise.
6385 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6387 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
6388 with dwarf2_per_objfile.
6389 (create_cus_from_index): Likewise.
6390 (create_signatured_type_table_from_index): Likewise.
6391 (dwarf2_read_index): Likewise.
6392 (dwarf2_initialize_objfile): Likewise.
6393 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
6394 per_cu rather than get_dwarf2_per_objfile.
6396 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6398 * dwarf2read.h (struct signatured_type): Forward declare.
6399 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
6401 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
6402 (dw2_get_cutu): ...this.
6403 (dwarf2_per_objfile::get_cu): Rename from...
6404 (dw2_get_cu): ...this.
6405 (dwarf2_per_objfile::get_tu): New.
6406 (create_addrmap_from_index): Adjust.
6407 (create_addrmap_from_aranges): Adjust.
6408 (dw2_find_last_source_symtab): Adjust.
6409 (dw2_map_symtabs_matching_filename): Adjust.
6410 (dw2_symtab_iter_next): Adjust.
6411 (dw2_print_stats): Adjust.
6412 (dw2_expand_all_symtabs): Adjust.
6413 (dw2_expand_symtabs_with_fullname): Adjust.
6414 (dw2_expand_marked_cus): Adjust.
6415 (dw_expand_symtabs_matching_file_matcher): Adjust.
6416 (dw2_map_symbol_filenames): Adjust.
6417 (dw2_debug_names_iterator::next): Adjust.
6418 (dwarf2_initialize_objfile): Adjust.
6419 (set_partial_user): Adjust.
6420 (dwarf2_build_psymtabs_hard): Adjust.
6422 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6424 * dwarf2read.c (create_signatured_type_table_from_debug_names):
6425 Remove unused variables.
6426 (dw2_map_symtabs_matching_filename): Likewise.
6427 (dwarf2_record_block_ranges): Likewise.
6428 (dwarf2_read_addr_index): Likewise.
6429 (follow_die_offset): Likewise.
6431 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6433 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
6434 to symbol_file_add_main.
6436 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6439 * mi/mi-console.c (do_fputc_async_safe): New.
6440 (mi_console_file::write_async_safe): New.
6441 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
6442 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
6444 * ui-file.c (ui_file::putstrn): Adjust call to
6445 fputstrn_unfiltered.
6446 * utils.c (printchar): Replace do_fputs and do_fprintf
6447 parameters by do_fputc.
6448 (fputstr_filtered): Adjust call to printchar.
6449 (fputstr_unfiltered): Likewise.
6450 (fputstrn_filtered): Likewise.
6451 (fputstrn_unfiltered): Add do_fputc parameter, pass to
6453 * utils.h (do_fputc_ftype): New typedef.
6454 (fputstrn_unfiltered): Add do_fputc parameter.
6456 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6458 * regformats/i386/i386-avx.dat: Remove.
6460 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6463 * amd64-tdep.c (amd64_none_init_abi): New function.
6464 (amd64_x32_none_init_abi): New function.
6465 (_initialize_amd64_tdep): Register handlers for x86-64 and
6466 x64_32 with GDB_OSABI_NONE.
6467 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
6468 GDB_OSABI_NONE osabi.
6470 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6473 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
6475 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
6476 * osabi.c (gdb_osabi_names): Add "unknown" entry.
6478 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
6480 * common/byte-vector.h (char_vector): New type.
6481 * target.h (target_read_alloc): Return
6482 gdb::optional<byte_vector>.
6483 (target_read_stralloc): Return gdb::optional<char_vector>.
6484 (target_get_osdata): Return gdb::optional<char_vector>.
6485 * target.c (target_read_alloc_1): Templatize. Replacement
6486 manual memory management with vector.
6487 (target_read_alloc): Change return type, adjust.
6488 (target_read_stralloc): Change return type, adjust.
6489 (target_get_osdata): Change return type, adjust.
6490 * auxv.c (struct auxv_info) <length>: Remove.
6491 <data>: Change type to gdb::optional<byte_vector>.
6492 (auxv_inferior_data_cleanup): Free auxv_info with delete.
6493 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
6494 (target_auxv_search): Adjust.
6495 (fprint_target_auxv): Adjust.
6496 * avr-tdep.c (avr_io_reg_read_command): Adjust.
6497 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
6498 (linux_make_corefile_notes): Adjust.
6499 * osdata.c (get_osdata): Adjust.
6500 * remote.c (remote_get_threads_with_qxfer): Adjust.
6501 (remote_memory_map): Adjust.
6502 (remote_traceframe_info): Adjust.
6503 (btrace_read_config): Adjust.
6504 (remote_read_btrace): Adjust.
6505 (remote_pid_to_exec_file): Adjust.
6506 * solib-aix.c (solib_aix_get_library_list): Adjust.
6507 * solib-dsbt.c (decode_loadmap): Don't free buf.
6508 (dsbt_get_initial_loadmaps): Adjust.
6509 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
6510 * solib-target.c (solib_target_current_sos): Adjust.
6511 * tracepoint.c (sdata_make_value): Adjust.
6512 * xml-support.c (xinclude_start_include): Adjust.
6513 (xml_fetch_content_from_file): Adjust.
6514 * xml-support.h (xml_fetch_another): Change return type.
6515 (xml_fetch_content_from_file): Change return type.
6516 * xml-syscall.c (xml_init_syscalls_info): Adjust.
6517 * xml-tdesc.c (file_read_description_xml): Adjust.
6518 (fetch_available_features_from_target): Change return type.
6519 (target_fetch_description_xml): Adjust.
6520 (target_read_description_xml): Adjust.
6522 2018-04-06 Tom Tromey <tom@tromey.com>
6524 * value.c (~value): Update.
6525 (struct value) <contents>: Now unique_xmalloc_ptr.
6526 (value_contents_bits_eq, allocate_value_contents)
6527 (value_contents_raw, value_contents_all_raw)
6528 (value_contents_for_printing, value_contents_for_printing_const)
6529 (set_value_enclosing_type): Update.
6531 2018-04-06 Tom Tromey <tom@tromey.com>
6533 * value.c (range_s): Remove typedef, VEC.
6534 (struct range): Add operator<.
6535 (range_lessthan): Remove.
6536 (ranges_contain): Change type.
6538 (struct value) <unavailable, optimized_out>: Now std::vector.
6539 (value_entirely_available)
6540 (value_entirely_covered_by_range_vector)
6541 (value_entirely_unavailable, value_entirely_optimized_out):
6543 (insert_into_bit_range_vector): Change argument type.
6544 (find_first_range_overlap): Likewise.
6545 (struct ranges_and_idx, value_contents_bits_eq)
6546 (require_not_optimized_out, require_available): Update.
6547 (ranges_copy_adjusted): Change argument types.
6548 (value_optimized_out, value_copy, value_fetch_lazy): Update.
6550 2018-04-06 Tom Tromey <tom@tromey.com>
6552 * value.c (~value): Update.
6553 (struct value) <parent>: Now a value_ref_ptr.
6554 (value_parent, set_value_parent, value_address, value_copy):
6557 2018-04-06 Tom Tromey <tom@tromey.com>
6559 * value.c (struct value): Add constructor, destructor, and member
6561 (allocate_value_lazy, value_decref): Update.
6563 2018-04-06 Tom Tromey <tom@tromey.com>
6565 * value.c (struct value) <released, next>: Remove.
6566 (all_values): Now a std::vector.
6567 (allocate_value_lazy): Update.
6568 (value_next): Remove.
6569 (value_mark, value_free_to_mark, release_value)
6570 (value_release_to_mark): Update.
6572 2018-04-06 Tom Tromey <tom@tromey.com>
6574 * value.h (fetch_subexp_value, value_release_to_mark): Update.
6575 (free_value_chain): Remove.
6576 * value.c (free_value_chain): Remove.
6577 (value_release_to_mark): Return a std::vector.
6578 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
6580 (check_condition): Update.
6581 * eval.c (fetch_subexp_value): Change "val_chain" to a
6583 * breakpoint.c (update_watchpoint): Update.
6584 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
6586 2018-04-06 Tom Tromey <tom@tromey.com>
6588 * value.h (free_all_values): Remove.
6589 * value.c (free_all_values): Remove.
6591 2018-04-06 Tom Tromey <tom@tromey.com>
6593 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
6594 (value_history_chain, value_history_count): Remove.
6595 (value_history): New global.
6596 (record_latest_value, access_value_history, show_values)
6597 (preserve_values): Update.
6599 2018-04-06 Tom Tromey <tom@tromey.com>
6601 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
6602 * varobj.c (varobj_set_display_format, varobj_set_value)
6603 (install_default_visualizer, construct_visualizer)
6604 (install_new_value, ~varobj, varobj_get_value_type)
6605 (my_value_of_variable, varobj_editable_p): Update.
6606 * c-varobj.c (c_describe_child, c_value_of_variable)
6607 (cplus_number_of_children, cplus_describe_child): Update.
6608 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
6609 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
6610 (ada_value_of_variable, ada_value_is_changeable_p): Update.
6612 2018-04-06 Tom Tromey <tom@tromey.com>
6614 * printcmd.c (last_examine_address): Change type to
6616 (do_examine, x_command): Update.
6618 2018-04-06 Tom Tromey <tom@tromey.com>
6620 * value.c (release_value): Update.
6621 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
6622 (struct bpstats) <val>: Now a value_ref_ptr.
6623 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6624 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6625 (~watchpoint, print_it_watchpoint, watch_command_1)
6626 (invalidate_bp_value_on_memory_change): Update.
6628 2018-04-06 Tom Tromey <tom@tromey.com>
6630 * varobj.c (varobj_clear_saved_item)
6631 (update_dynamic_varobj_children, install_new_value, ~varobj):
6633 * value.h (value_incref): Move declaration earlier.
6634 (value_decref): Rename from value_free.
6635 (struct value_ref_policy): New.
6636 (value_ref_ptr): New typedef.
6637 (struct value_deleter): Remove.
6638 (gdb_value_up): Remove typedef.
6639 (release_value): Change return type.
6640 (release_value_or_incref): Remove.
6641 * value.c (set_value_parent): Update.
6642 (value_incref): Change return type.
6643 (value_decref): Rename from value_free.
6644 (value_free_to_mark, free_all_values, free_value_chain): Update.
6645 (release_value): Return value_ref_ptr.
6646 (release_value_or_incref): Remove.
6647 (record_latest_value, set_internalvar, clear_internalvar):
6649 * stack.c (info_frame_command): Don't call value_free.
6650 * python/py-value.c (valpy_dealloc, valpy_new)
6651 (value_to_value_object): Update.
6652 * printcmd.c (do_examine): Update.
6653 * opencl-lang.c (lval_func_free_closure): Update.
6654 * mi/mi-main.c (register_changed_p): Don't call value_free.
6655 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
6656 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
6657 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
6659 * guile/scm-value.c (vlscm_free_value_smob)
6660 (vlscm_scm_from_value): Update.
6661 * frame.c (frame_register_unwind, frame_unwind_register_signed)
6662 (frame_unwind_register_unsigned, get_frame_register_bytes)
6663 (put_frame_register_bytes): Don't call value_free.
6664 * findvar.c (address_from_register): Don't call value_free.
6665 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
6666 * dwarf2loc.c (entry_data_value_free_closure)
6667 (value_of_dwarf_reg_entry, free_pieced_value_closure)
6668 (dwarf2_evaluate_loc_desc_full): Update.
6669 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
6670 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
6671 (~watchpoint, watch_command_1)
6672 (invalidate_bp_value_on_memory_change): Update.
6673 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
6675 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
6678 * warning.m4: Add -Wno-error=deprecated-register.
6679 * configure: Re-generate.
6681 2018-04-05 Tom Tromey <tom@tromey.com>
6683 * linespec.h: Remove include of "vec.h".
6685 2018-04-05 Tom Tromey <tom@tromey.com>
6687 * linespec.c (typep): Remove typedef.
6688 (find_methods, find_superclass_methods): Take a std::vector.
6689 (find_method): Use std::vector.
6691 2018-04-05 Tom Tromey <tom@tromey.com>
6693 * utils.c (compare_strings): Remove.
6694 * utils.h (compare_strings): Remove.
6695 * objc-lang.h (find_imps): Update.
6696 * objc-lang.c (find_methods): Take a std::vector.
6697 (uniquify_strings, find_imps): Likewise.
6698 * linespec.c (find_methods): Take a std::vector.
6699 (decode_objc): Use std::vector.
6700 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
6702 (find_method, find_function_symbols): Use std::vector.
6704 2018-04-05 Tom Tromey <tom@tromey.com>
6706 * completer.c (completion_tracker::completion_tracker): Remove
6708 (completion_tracker::discard_completions): Likewise.
6709 * breakpoint.c (ambiguous_names_p): Remove cast.
6710 * ada-lang.c (_initialize_ada_language): Remove cast.
6711 * utils.h (streq): Update.
6712 (streq_hash): Add new declaration.
6713 * utils.c (streq): Return bool.
6714 (streq_hash): New function.
6716 2018-04-05 Tom Tromey <tom@tromey.com>
6718 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
6719 Remove a string copy.
6721 2018-04-05 Tom Tromey <tom@tromey.com>
6723 * linespec.c (filter_results): Use std::vector.
6724 (decode_line_2, decode_line_full): Update.
6726 2018-04-05 Tom Tromey <tom@tromey.com>
6728 * linespec.c (canonical_to_fullform): Return std::string.
6729 (filter_results): Update.
6730 (struct decode_line_2_item): Add constructor.
6731 <fullform, displayform>: Now std::string.
6732 (decode_line_2_compare_items): Now a std::sort comparator.
6733 (decode_line_2): Update.
6735 2018-04-05 Tom Tromey <tom@tromey.com>
6737 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
6738 (unexpected_linespec_error): Update.
6739 (linespec_parse_basic, parse_linespec): Update.
6741 2018-04-05 Tom Tromey <tom@tromey.com>
6743 * linespec.c (linespec_parse_basic): Reindent.
6745 2018-04-05 Tom Tromey <tom@tromey.com>
6747 * minsyms.h (iterate_over_minimal_symbols): Update.
6748 * minsyms.c (iterate_over_minimal_symbols): Take a
6750 * linespec.c (struct collect_minsyms): Remove.
6751 (compare_msyms): Now a std::sort comparator.
6752 (add_minsym): Add parameters.
6753 (search_minsyms_for_name): Update. Use std::vector.
6755 2018-04-03 Tom Tromey <tom@tromey.com>
6757 * mipsread.c (read_alphacoff_dynamic_symtab): Use
6760 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
6762 * MAINTAINERS (Write After Approval): Add Weimin Pan.
6764 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
6767 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
6768 printing static type.
6770 2018-04-01 Tom Tromey <tom@tromey.com>
6772 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
6773 (rs6000_xfer_shared_libraries): Update.
6775 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6777 * common/gdb_vecs.h (char_ptr): Remove.
6778 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
6780 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6782 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
6784 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
6786 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
6788 * tracepoint.h (struct uploaded_tp): Initialize fields.
6789 <actions, step_actions, cmd_strings>: Change type to
6790 std::vector<char *>.
6791 * tracepoint.c (get_uploaded_tp): Allocate with new.
6792 (free_uploaded_tps): Free with delete.
6793 (parse_tracepoint_definition): Adjust to std::vector change.
6794 * breakpoint.c (read_uploaded_action): Likewise.
6795 (create_tracepoint_from_upload): Likewise.
6796 * ctf.c (ctf_write_uploaded_tp): Likewise.
6797 (SET_ARRAY_FIELD): Likewise.
6798 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
6800 2018-03-30 Tom Tromey <tom@tromey.com>
6802 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
6804 (svr4_keep_data_in_core): Update.
6805 (svr4_read_so_list): Update.
6807 2018-03-30 Tom Tromey <tom@tromey.com>
6809 * windows-nat.c (handle_output_debug_string, handle_exception):
6811 * target.h (target_read_string): Update.
6812 * target.c (target_read_string): Change "string" to
6814 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
6816 * solib-frv.c (frv_current_sos): Update.
6817 * solib-dsbt.c (dsbt_current_sos): Update.
6818 * solib-darwin.c (darwin_current_sos): Update.
6819 * linux-thread-db.c (inferior_has_bug): Update.
6820 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
6821 Update. Remove alloca.
6822 * ada-lang.c (ada_main_name): Update.
6824 2018-03-30 Tom Tromey <tom@tromey.com>
6826 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
6827 (struct dwo_file_deleter): New.
6828 (dwo_file_up): New typedef.
6829 (open_and_init_dwo_file): Use dwo_file_up.
6830 (free_dwo_file_cleanup): Remove.
6832 2018-03-30 Tom Tromey <tom@tromey.com>
6834 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
6835 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
6837 2018-03-30 Tom Tromey <tom@tromey.com>
6839 * dwarf2read.c (class free_cached_comp_units): New class.
6840 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
6841 (free_cached_comp_units): Remove function.
6843 2018-03-30 Tom Tromey <tom@tromey.com>
6845 * utils.h (make_cleanup_unpush_target): Remove.
6846 * inf-ptrace.c (struct target_unpusher): New.
6847 (target_unpush_up) New typedef.
6848 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
6850 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
6852 2018-03-27 Tom Tromey <tom@tromey.com>
6854 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
6856 2018-03-27 Pedro Alves <palves@redhat.com>
6857 Tom Tromey <tom@tromey.com>
6859 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
6860 destructor. Now a class.
6861 (gdb_readline_wrapper_cleanup): Remove function.
6862 (gdb_readline_wrapper): Remove cleanups.
6864 2018-03-27 Tom Tromey <tom@tromey.com>
6866 * typeprint.h (struct type_print_options) <local_typedefs,
6867 global_typedefs>: Remove "struct" keyword.
6868 (class typedef_hash_table): New class.
6869 (recursively_update_typedef_hash, add_template_parameters)
6870 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
6871 (find_typedef_in_hash): Don't declare.
6872 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
6873 (typedef_hash_table::recursively_update): Rename from
6874 recursively_update_typedef_hash. Now a member.
6875 (typedef_hash_table::add_template_parameters): Rename from
6876 add_template_parameters. Now a member.
6877 (typedef_hash_table::typedef_hash_table): Now a constructor;
6878 rename from create_typedef_hash.
6879 (typedef_hash_table::~typedef_hash_table): Now a destructor;
6880 rename from free_typedef_hash.
6881 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
6882 (do_free_global_table): Remove.
6883 (typedef_hash_table::typedef_hash_table): New constructor; renamed
6884 from copy_type_recursive.
6885 (create_global_typedef_table): Remove.
6886 (typedef_hash_table::find_global_typedef): Now a member of
6888 (typedef_hash_table::find_typedef): Rename from
6889 find_typedef_in_hash; now a member.
6890 (whatis_exp): Update.
6891 * extension.h (struct ext_lang_type_printers): Add constructor and
6893 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
6895 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
6896 Now a constructor; rename from start_ext_lang_type_printers.
6897 (ext_lang_type_printers): Now a destructor; rename from
6898 free_ext_lang_type_printers.
6899 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
6901 (c_type_print_base_struct_union): Update. Remove cleanups.
6903 2018-03-27 Tom Tromey <tom@tromey.com>
6905 * dwarf-index-write.c: Include <cmath>.
6907 2018-03-27 Joel Brobecker <brobecker@adacore.com>
6909 * NEWS: Add entry describing new "set|show varsize-limit" command.
6910 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
6912 * printcmd.c (_initialize_printcmd): Add "set var" alias of
6915 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
6917 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
6919 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
6920 * dwarf-index-common.c: New file.
6921 * dwarf-index-common.h: New file.
6922 * dwarf-index-write.c: New file.
6923 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
6924 (struct dwarf2_section_info): Move from here.
6925 (dwarf2_section_info_def): Likewise.
6926 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
6927 (offset_type): Likewise.
6928 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
6929 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
6930 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
6931 (byte_swap): Likewise.
6932 (MAYBE_SWAP): Likewise.
6933 (dwarf2_per_cu_ptr): Likewise.
6934 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
6935 (struct tu_stats): Likewise.
6936 (struct dwarf2_per_objfile): Likewise.
6937 (struct dwarf2_per_cu_data): Likewise.
6938 (struct signatured_type): Likewise.
6939 (sig_type_ptr): Likewise.
6940 (DEF_VEC_P (sig_type_ptr)): Likewise.
6941 (INDEX4_SUFFIX): Likewise.
6942 (INDEX5_SUFFIX): Likewise.
6943 (DEBUG_STR_SUFFIX): Likewise.
6944 (dwarf2_read_section): Make non-static.
6945 (mapped_index_string_hash): Move from here.
6946 (dwarf5_djb_hash): Likewise.
6947 (file_write): Likewise.
6948 (class data_buf): Likewise.
6949 (struct symtab_index_entry): Likewise.
6950 (struct mapped_symtab): Likewise.
6951 (find_slot): Likewise.
6952 (hash_expand): Likewise.
6953 (add_index_entry): Likewise.
6954 (uniquify_cu_indices): Likewise.
6955 (class c_str_view): Likewise.
6956 (class c_str_view_hasher): Likewise.
6957 (class vector_hasher): Likewise.
6958 (write_hash_table): Likewise.
6959 (psym_index_map): Likewise.
6960 (struct addrmap_index_data): Likewise.
6961 (add_address_entry): Likewise.
6962 (add_address_entry_worker): Likewise.
6963 (write_address_map): Likewise.
6964 (symbol_kind): Likewise.
6965 (write_psymbols): Likewise.
6966 (struct signatured_type_index_data): Likewise.
6967 (write_one_signatured_type): Likewise.
6968 (recursively_count_psymbols): Likewise.
6969 (recursively_write_psymbols): Likewise.
6970 (class debug_names): Likewise.
6971 (check_dwarf64_offsets): Likewise.
6972 (psyms_seen_size): Likewise.
6973 (write_gdbindex): Likewise.
6974 (write_debug_names): Likewise.
6975 (assert_file_size): Likewise.
6976 (write_psymtabs_to_index): Likewise.
6977 (save_gdb_index_command): Likewise.
6978 (_initialize_dwarf2_read): Don't register the "save gdb-index"
6980 * dwarf2read.h: New file.
6982 2018-03-27 Joel Brobecker <brobecker@adacore.com>
6985 * dwarf2read.c (dwarf2_physname): Do not return the demangled
6986 symbol name if the CU's language stores symbol names in linkage
6988 * language.h (struct language_defn)
6989 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
6990 all instances of this struct.
6992 2018-03-26 Tom Tromey <tom@tromey.com>
6994 * stack.c (backtrace_command_1): Remove verbose code.
6996 2018-03-26 Tom Tromey <tom@tromey.com>
6998 * python/py-framefilter.c (py_print_type): Don't catch
6999 exceptions. Return void.
7000 (py_print_value): Likewise.
7001 (py_print_single_arg): Likewise.
7002 (enumerate_args): Don't catch exceptions.
7003 (py_print_args): Likewise.
7004 (py_print_frame): Likewise.
7005 (gdbpy_apply_frame_filter): Catch exceptions here.
7007 2018-03-26 Tom Tromey <tom@tromey.com>
7009 * stack.c (_initialize_stack): Remove trailing newlines from help
7010 text. Add "Usage" line to "backtrace" help.
7012 2018-03-26 Tom Tromey <tom@tromey.com>
7015 * python/py-framefilter.c (py_print_args): Call wrap_hint.
7017 2018-03-26 Tom Tromey <tom@tromey.com>
7019 * python/py-framefilter.c (py_print_single_arg): Return
7020 EXT_LANG_BT_ERROR from catch.
7022 2018-03-26 Tom Tromey <tom@tromey.com>
7025 * stack.c (backtrace_command_1): Move some code into no-filters
7028 2018-03-26 Tom Tromey <tom@tromey.com>
7030 * python/py-framefilter.c (throw_quit_or_print_exception): New
7032 (gdbpy_apply_frame_filter): Use it.
7034 2018-03-26 Tom Tromey <tom@tromey.com>
7037 * python/py-framefilter.c (py_print_type, py_print_value)
7038 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
7041 2018-03-26 Tom Tromey <tom@tromey.com>
7043 * python/py-framefilter.c (enumerate_args): Use
7044 gdb::unique_xmalloc_ptr.
7046 2018-03-26 Tom Tromey <tom@tromey.com>
7048 * python/py-framefilter.c (py_print_frame): Return
7050 (gdbpy_apply_frame_filter): Update comment.
7051 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
7053 <EXT_LANG_BT_NO_FILTERS>: Change value.
7055 2018-03-26 Tom Tromey <tom@tromey.com>
7058 * stack.c (backtrace_command): Parse "hide" argument.
7059 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
7060 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
7063 2018-03-26 Tom Tromey <tom@tromey.com>
7065 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
7067 (backtrace_command): Remove "fulltrace", add "flags".
7069 2018-03-26 Tom Tromey <tom@tromey.com>
7071 * stack.c (backtrace_command): Rewrite command line parsing.
7073 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7075 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
7077 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
7079 * filename-seen-cache.h: Add include guard.
7081 2018-03-26 Keith Seitz <keiths@redhat.com>
7083 * symfile.c (place_section): Remove "struct" from section_addr_info
7085 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
7086 "struct" keyword from section_addr_info.
7088 2018-03-26 Alan Hayward <alan.hayward@arm.com>
7090 * regformats/regdef.h (reg): Add constructors.
7092 2018-03-25 Pedro Alves <palves@redhat.com>
7094 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
7095 if then/else bodies in var_func_name extraction.
7097 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
7099 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
7100 lookup_minimal_symbol() to find symbol entry.
7101 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
7103 2018-03-23 Keith Seitz <keiths@redhat.com>
7106 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
7107 nested type definitions for C++, too.
7109 2018-03-23 Tom Tromey <tom@tromey.com>
7111 * machoread.c (struct oso_el): Add a constructor. Don't define as
7113 (macho_register_oso): Remove.
7114 (macho_symtab_read): Take a std::vector.
7115 (oso_el_compare_name): Now a std::sort comparator.
7116 (macho_symfile_read_all_oso): Take a std::vector.
7117 (macho_symfile_read): Use std::vector. Remove cleanups.
7119 2018-03-22 Tom Tromey <tom@tromey.com>
7121 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
7122 (record_full_goto_bookmark): Use std::string.
7124 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7127 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
7130 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7132 * rs6000-tdep.c (store_insn_p): New function.
7133 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
7134 and cr_reg to their unshifted values. Use store_insn_p to
7135 match LR saves using either R1 or fdata->alloca_reg. Use
7136 store_insn_p to match CR saves. Set alloca_reg_offset
7137 when alloca_reg and framep are set. Remove lr_reg shift
7138 when assigning to fdata->lr_register.
7140 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
7142 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
7143 command line args instead of emitting a warning.
7145 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7147 * tracepoint.h (struct static_tracepoint_marker): Initialize
7148 fields, define default constructor, move constructor and move
7149 assignment, disable the rest.
7150 <str_id, extra>: Make std::string.
7151 (release_static_tracepoint_marker): Remove.
7152 (free_current_marker): Remove.
7153 * tracepoint.c (free_current_marker): Remove.
7154 (parse_static_tracepoint_marker_definition): Adjust to
7155 std::string, use new hex2str overload.
7156 (release_static_tracepoint_marker): Remove.
7157 (print_one_static_tracepoint_marker): Get marker by reference
7158 and adjust to std::string.
7159 (info_static_tracepoint_markers_command): Adjust to std::vector
7161 * target.h (static_tracepoint_marker_p): Remove typedef.
7162 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
7163 (struct target_ops) <to_static_tracepoint_marker_at>: Return
7165 <to_static_tracepoint_markers_by_strid>: Return std::vector.
7167 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
7168 (target_debug_print_std_vector_static_tracepoint_marker): New.
7169 (target_debug_print_struct_static_tracepoint_marker_p): Rename
7171 (target_debug_print_static_tracepoint_marker_p): ... this.
7172 * target-delegates.c: Re-generate.
7173 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
7175 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
7176 (decode_static_tracepoint_spec): Adjust to std::vector.
7177 (tracepoint_print_one_detail): Adjust to std::string.
7178 (strace_marker_decode_location): Adjust to std::string.
7179 (update_static_tracepoint): Adjust to std::string, remove call
7180 to release_static_tracepoint_marker.
7181 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
7182 Adjust to std::vector.
7183 * remote.c (remote_static_tracepoint_marker_at): Return bool.
7184 (remote_static_tracepoint_markers_by_strid): Adjust to
7186 * common/rsp-low.h (hex2str): New overload with explicit count
7188 * common/rsp-low.c (hex2str): New overload with explicit count
7190 * unittests/rsp-low-selftests.c (test_hex2str): New function.
7191 (_initialize_rsp_low_selftests): Add test_hex2str test.
7192 * unittests/tracepoint-selftests.c
7193 (test_parse_static_tracepoint_marker_definition): Adjust to
7196 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7198 * tracepoint.c (parse_static_tracepoint_marker_definition):
7199 Consider case where the definition is followed by more
7201 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7202 tracepoint-selftests.c.
7203 * unittests/tracepoint-selftests.c: New.
7205 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7207 * MAINTAINERS (Write After Approval): Add Pedro Franco de
7210 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7212 * symtab.c (find_pc_sect_line): fixed indentation.
7214 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
7216 * symtab.c (find_pc_sect_line): now uses binary search.
7218 2018-03-19 Tom Tromey <tom@tromey.com>
7220 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
7223 2018-03-19 Pedro Alves <palves@redhat.com>
7224 Tom Tromey <tom@tromey.com>
7226 * unittests/observable-selftests.c: New file.
7227 * common/observable.h: New file.
7228 * observable.h: New file.
7229 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
7230 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
7231 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
7232 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
7233 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
7234 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
7235 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
7236 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
7237 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
7238 python/py-breakpoint.c, python/py-finishbreakpoint.c,
7239 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
7240 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
7241 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
7242 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
7243 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
7244 tui/tui-interp.c, valops.c: Update all users.
7245 * tui/tui-hooks.c (tui_bp_created_observer)
7246 (tui_bp_deleted_observer, tui_bp_modified_observer)
7247 (tui_inferior_exit_observer, tui_before_prompt_observer)
7248 (tui_normal_stop_observer, tui_register_changed_observer):
7250 (tui_observers_token): New global.
7251 (attach_or_detach, tui_attach_detach_observers): New functions.
7252 (tui_install_hooks, tui_remove_hooks): Use
7253 tui_attach_detach_observers.
7254 * record-btrace.c (record_btrace_thread_observer): Remove.
7255 (record_btrace_thread_observer_token): New global.
7256 * observer.sh: Remove.
7257 * observer.c: Rename to observable.c.
7258 * observable.c (namespace gdb_observers): Define new objects.
7259 (observer_debug): Move into gdb_observers namespace.
7260 (struct observer, struct observer_list, xalloc_observer_list_node)
7261 (xfree_observer_list_node, generic_observer_attach)
7262 (generic_observer_detach, generic_observer_notify): Remove.
7263 (_initialize_observer): Update.
7264 Don't include observer.inc.
7265 * Makefile.in (generated_files): Remove observer.h, observer.inc.
7266 (clean mostlyclean): Likewise.
7267 (observer.h, observer.inc): Remove targets.
7268 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
7269 (COMMON_SFILES): Use observable.c, not observer.c.
7270 * .gitignore: Remove observer.h.
7272 2018-03-18 Tom Tromey <tom@tromey.com>
7274 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
7276 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
7278 2018-03-17 Tom Tromey <tom@tromey.com>
7280 * auto-load.c (auto_load_objfile_script_1): Use std::string.
7282 2018-03-17 Tom Tromey <tom@tromey.com>
7284 * target.c (class scoped_target_fd): New.
7285 (target_fileio_close_cleanup): Remove.
7286 (target_fileio_read_alloc_1): Use scoped_target_fd.
7288 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
7290 * silent-rules.mk: New.
7291 * Makefile.in: Include silent-rules.mk
7292 (srcdir, VPATH, top_srcdir): Move up.
7293 (COMPILE): Add ECHO_CXX.
7294 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
7295 (init.c): Add ECHO_INIT_C.
7296 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
7297 (version.c): Add ECHO_GEN.
7298 (printcmd.o): Add ECHO_CXX.
7299 (target-float.o): Add ECHO_CXX.
7300 (ada-exp.o): Add ECHO_CXX.
7301 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
7302 (insight$(EXEEXT)): Add ECHO_CXXLD.
7303 * gnulib/configure.ac: Add AM_SILENT_RULES.
7304 * gnulib/aclocal.m4: Re-generate.
7305 * gnulib/configure: Re-generate.
7306 * gnulib/import/Makefile.in: Re-generate.
7308 2018-03-16 Tom Tromey <tom@tromey.com>
7310 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
7311 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
7312 * utils.c (do_free_section_addr_info)
7313 (make_cleanup_free_section_addr_info): Remove.
7314 * symfile.h (struct other_sections): Add constructor.
7315 (struct section_addr_info): Remove.
7316 (section_addr_info): New typedef.
7317 (struct sym_fns) <sym_offsets>: Change type of parameter.
7318 (build_section_addr_info_from_objfile)
7319 (relative_addr_info_to_section_offsets, addr_info_make_relative)
7320 (default_symfile_offsets, symbol_file_add)
7321 (symbol_file_add_from_bfd)
7322 (build_section_addr_info_from_section_table): Update.
7323 (alloc_section_addr_info, free_section_addr_info): Don't declare.
7324 * symfile.c (alloc_section_addr_info): Remove.
7325 (build_section_addr_info_from_section_table): Change return type.
7327 (build_section_addr_info_from_bfd)
7328 (build_section_addr_info_from_objfile): Likewise.
7329 (free_section_addr_info): Remove.
7330 (relative_addr_info_to_section_offsets): Change type of "addrs".
7331 (addrs_section_compar): Now a std::sort comparator.
7332 (addrs_section_sort): Change return type.
7333 (addr_info_make_relative): Change type of "addrs". Update.
7334 (default_symfile_offsets, syms_from_objfile_1)
7335 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
7336 (symbol_file_add_separate): Update.
7337 (symbol_file_add): Change type of "addrs". Update.
7338 (add_symbol_file_command): Update. Remove cleanups.
7339 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
7341 * symfile-debug.c (debug_sym_offsets): Change type of "info".
7342 * solib.c (solib_read_symbols): Update.
7343 * objfiles.c (objfile_relocate): Update. Remove cleanups.
7344 * machoread.c (macho_symfile_offsets): Update.
7345 * jit.c (jit_bfd_try_read_symtab): Update.
7347 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
7349 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7350 unittests/utils-selftests.c.
7351 * unittests/utils-selftests.c: New file.
7353 2018-03-14 Tom Tromey <tom@tromey.com>
7356 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
7359 2018-03-14 Tom Tromey <tom@tromey.com>
7362 * printcmd.c (printf_pointer): Allow "-" in format.
7364 2018-03-14 Tom Tromey <tom@tromey.com>
7366 * printcmd.c (_initialize_printcmd): Add usage to printf.
7368 2018-03-14 Yao Qi <qiyao@sourceware.org>
7370 * MAINTAINERS: Update my email address.
7372 2018-03-13 Tom Tromey <tom@tromey.com>
7374 * machoread.c (macho_check_dsym): Change filenamep to a
7376 (macho_symfile_read): Update.
7377 * symfile.c (load_command): Use std::string.
7379 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
7381 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
7382 to error message string.
7383 (riscv_register_name): Use xsnprintf instead of sprintf.
7384 (riscv_insn::fetch_instruction): Use gdb_assert instead of
7386 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
7388 (riscv_push_dummy_call): Likewise.
7390 2018-03-12 Tom Tromey <tom@tromey.com>
7392 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
7393 Use gdb::byte_vector.
7394 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
7396 2018-03-12 Yao Qi <yao.qi@linaro.org>
7398 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
7399 parameter type to readable_regcache.
7400 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
7403 2018-03-11 Tom Tromey <tom@tromey.com>
7405 * dwarf2read.c (struct nextfield): Add initializers.
7406 (struct nextfnfield): Remove.
7407 (struct fnfieldlist): Add initializers. Remove "length" and
7408 "head", use std::vector.
7409 (struct decl_field_list): Remove.
7410 (struct field_info): Add initializers.
7411 <fields, baseclasses>: Now std::vector.
7412 <nbaseclasses, nfnfields, typedef_field_list_count,
7413 nested_types_list_count>: Remove.
7414 (dwarf2_add_field, dwarf2_add_type_defn)
7415 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
7416 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
7417 (process_structure_scope): Update.
7419 2018-03-11 Tom Tromey <tom@tromey.com>
7421 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
7422 for use by std::sort.
7423 (build_type_psymtabs_1): Use std::vector.
7425 2018-03-09 Eli Zaretskii <eliz@gnu.org>
7427 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
7428 and LIBMPFR in the printed configuration.
7430 2018-03-08 Tom Tromey <tom@tromey.com>
7432 * source.c (get_filename_and_charpos): Use scoped_fd.
7433 * nto-procfs.c (procfs_open_1): Use scoped_fd.
7434 (procfs_pidlist): Likewise.
7435 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
7436 (iterate_over_mappings): Likewise.
7438 2018-03-08 Tom Tromey <tom@tromey.com>
7440 * infcall.c (struct call_return_meta_info)
7441 <stack_temporaries_enabled>: Remove.
7442 (get_call_return_value, call_function_by_hand_dummy): Update.
7443 * thread.c (disable_thread_stack_temporaries): Remove.
7444 (enable_thread_stack_temporaries): Remove.
7445 (thread_stack_temporaries_enabled_p): Return bool.
7446 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
7447 (get_last_thread_stack_temporary): Update.
7448 * eval.c (evaluate_subexp): Update.
7449 * gdbthread.h (class enable_thread_stack_temporaries): Now a
7450 class, not a function.
7451 (value_ptr, value_vec): Remove typedefs.
7452 (class thread_info) <stack_temporaries_enabled>: Now bool.
7453 <stack_temporaries>: Now a std::vector.
7454 (thread_stack_temporaries_enabled_p)
7455 (value_in_thread_stack_temporaries): Return bool.
7457 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
7459 * remote.c (putpkt_binary): Fix omitted bytes reporting.
7460 (getpkt_or_notif_sane_1): Likewise.
7462 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7464 * build-id.c (build_id_to_debug_bfd): Use std::string.
7466 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7468 * build-id.c (find_separate_debug_file_by_buildid): Return
7470 * build-id.h (find_separate_debug_file_by_buildid): Return
7472 * coffread.c (coff_symfile_read): Adjust to std::string.
7473 * elfread.c (elf_symfile_read): Adjust to std::string.
7474 * symfile.c (separate_debug_file_exists): Change parameter to
7476 (find_separate_debug_file): Return std::string.
7477 (find_separate_debug_file_by_debuglink): Return std::string.
7478 * symfile.h (find_separate_debug_file_by_debuglink): Return
7481 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
7483 * common/xml-utils.c (xml_escape_text): Move code to...
7484 (xml_escape_text_append): ... this new function.
7485 * common/xml-utils.h (xml_escape_text_append): New declaration.
7486 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
7488 (_initialize_xml_utils): register test_xml_escape_text_append as
7491 2018-03-07 Alan Hayward <alan.hayward@arm.com>
7493 * defs.h: Remove MAX_REGISTER_SIZE.
7494 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
7496 * python/py-unwind.c (pyuw_sniffer): Likewise.
7498 2018-03-07 Tom Tromey <tom@tromey.com>
7500 * linux-tdep.c (linux_info_proc): Update.
7501 * target.h (struct target_ops) <to_fileio_readlink>: Return
7503 (target_fileio_readlink): Return optional<string>.
7504 * remote.c (remote_hostio_readlink): Return optional<string>.
7505 * inf-child.c (inf_child_fileio_readlink): Return
7507 * target.c (target_fileio_readlink): Return optional<string>.
7509 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
7511 * regcache.c (cooked_read_test): Add riscv to the list of
7512 architectures that have a save_reggroup.
7514 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
7516 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
7517 value is not a dynamic class object.
7519 2018-03-06 Tom Tromey <tom@tromey.com>
7521 * rust-exp.y: Formatting fixes.
7523 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7525 * riscv-tdep.c (riscv_register_name): Remove target description
7527 (riscv_gdbarch_init): Remove target description check.
7529 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7531 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
7533 * riscv-tdep.h: Likewise.
7535 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7537 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
7538 (riscv_pseudo_register_write): Delete.
7539 (riscv_gdbarch_init): Remove all use of pseudo registers.
7541 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7543 * record-btrace.c (btrace_print_lines): Replace cleanup
7544 parameter with RAII equivalents.
7545 (btrace_insn_history): Replace cleanup with RAII equivalents.
7546 * ui-out.h (make_cleanup_ui_out_list_begin_end,
7547 make_cleanup_ui_out_tuple_begin_end): Remove.
7548 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
7549 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
7550 make_cleanup_ui_out_list_begin_end): Remove.
7552 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7554 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
7555 parameter types to std::vector. Use bool.
7556 (record_btrace_wait): Replace VEC(tp_t) with
7557 std::vector<thread_info *>.
7558 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
7560 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7562 * record-btrace.c (record_btrace_disable_callback): Remove.
7563 (struct scoped_btrace_disable): New.
7564 (record_btrace_open): Use scoped_btrace_disable.
7566 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7568 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
7569 reading values from registers.
7571 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7573 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
7576 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7578 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
7579 change parameter type. Use GDB's print functions, and use
7580 core_addr_to_string where appropriate.
7581 (riscv_push_dummy_call): Use core_addr_to_string where
7582 appropriate, update call to riscv_print_arg_location, and reindent
7584 (riscv_return_value): Update call to riscv_print_arg_location.
7586 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7587 Tim Newsome <tim@sifive.com>
7588 Albert Ou <a0u@eecs.berkeley.edu>
7589 Darius Rad <darius@bluespec.com>
7591 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
7592 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
7593 (ALLDEPFILES): Add riscv-tdep.c
7594 * configure.tgt: Add riscv support.
7595 * riscv-tdep.c: New file.
7596 * riscv-tdep.h: New file.
7597 * NEWS: Mention new target.
7598 * MAINTAINERS: Add entry for riscv.
7600 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7602 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
7603 fields within aggregates.
7605 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
7607 * record-btrace.c (btrace_print_lines): Change type of flags to
7608 gdb_disassembly_flags.
7610 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7612 * fbsd-nat.c: Include "inf-ptrace.h".
7613 (USE_SIGTRAP_SIGINFO): Conditionally define.
7614 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
7615 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
7616 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
7618 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
7620 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
7622 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
7623 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
7624 "supports_stopped_by_hw_breakpoint" target methods.
7626 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7628 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
7629 * fbsd-nat.c (debug_fbsd_nat): New variable.
7630 (show_fbsd_nat_debug): New function.
7631 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
7632 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
7634 2018-03-04 John Baldwin <jhb@FreeBSD.org>
7636 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
7637 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
7639 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
7640 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
7643 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7645 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
7646 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
7648 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7650 * charset.c (struct charset_vector): New.
7651 (charsets): Change type to charset_vector.
7652 (find_charset_names): Adjust.
7654 (_initialize_charset): Adjust.
7656 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7658 * progspace.h (struct program_space) <deleted_solibs>: Change
7659 type to std::vector<std::string>.
7660 * progspace.c (clear_program_space_solib_cache): Adjust.
7661 * breakpoint.c (print_solib_event): Adjust.
7662 (check_status_catch_solib): Adjust.
7663 * solib.c (update_solib_list): Adjust.
7664 * ui-out.h (class ui_out) <field_string>: New overload.
7665 * ui-out.c (ui_out::field_string): New overload.
7667 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7669 * progspace.h (struct program_space): Add constructor and
7670 destructor, initialize fields.
7671 (add_program_space): Remove.
7672 * progspace.c (add_program_space): Rename to...
7673 (program_space::program_space): ... this.
7674 (release_program_space): Rename to...
7675 (program_space::~program_space): ... this.
7676 (delete_program_space): Use delete to delete program_space.
7677 (initialize_progspace): Use new to allocate program_space.
7678 * inferior.c (add_inferior_with_spaces): Likewise.
7679 (clone_inferior_command): Likewise.
7680 * infrun.c (follow_fork_inferior): Likewise.
7681 (handle_vfork_child_exec_or_exit): Likewise.
7683 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7685 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
7686 (delim_string_to_char_ptr_vec): Return std::vector of
7687 gdb::unique_xmalloc_ptr.
7688 (dirnames_to_char_ptr_vec_append): Take std::vector of
7689 gdb::unique_xmalloc_ptr.
7690 (dirnames_to_char_ptr_vec): Return std::vector of
7691 gdb::unique_xmalloc_ptr.
7692 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
7693 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
7694 (delim_string_to_char_ptr_vec): Return an std::vector of
7695 gdb::unique_xmalloc_ptr, adjust the code.
7696 (dirnames_to_char_ptr_vec_append): Take an std::vector of
7697 gdb::unique_xmalloc_ptr, adjust the code.
7698 (dirnames_to_char_ptr_vec): Return an std::vector of
7699 gdb::unique_xmalloc_ptr, adjust the code.
7700 * auto-load.c (auto_load_safe_path_vec): Change type to
7701 std::vector of gdb::unique_xmalloc_ptr.
7702 (auto_load_expand_dir_vars): Return an std::vector of
7703 gdb::unique_xmalloc_ptr, adjust the code.
7704 (auto_load_safe_path_vec_update): Adjust.
7705 (filename_is_in_auto_load_safe_path_vec): Adjust.
7706 (auto_load_objfile_script_1): Adjust.
7707 * build-id.c (build_id_to_debug_bfd): Adjust.
7708 * linux-thread-db.c (thread_db_load_search): Adjust.
7709 * source.c (add_path): Adjust.
7711 * symfile.c (find_separate_debug_file): Adjust.
7712 * utils.c (do_free_char_ptr_vec): Remove.
7713 (make_cleanup_free_char_ptr_vec): Remove.
7715 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
7718 * common/pathstuff.c: Conditionally include "<windows.h>".
7720 2018-03-01 Georg Sauthoff <mail@georg.so>
7723 * gcore.in: Quote variables and switch interpreter to bash.
7725 2018-03-01 Tom Tromey <tom@tromey.com>
7727 * dwarf2read.c (alloc_discriminant_info): Fix default_index
7728 assertion. Add assertion for discriminant_index.
7729 (quirk_rust_enum): Use correct base type name in univariant case.
7731 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
7733 * record.c (get_call_history_modifiers): Return a
7735 (cmd_record_call_history): Adjust.
7736 * record-btrace.c (record_btrace_call_history): Adjust.
7737 (record_btrace_call_history_range): Adjust.
7738 (record_btrace_call_history_from): Adjust.
7739 * target-debug.h (target_debug_print_record_print_flags): New.
7740 * target-delegates.c: Re-generate.
7741 * target.c (target_call_history): Change flags type.
7742 (target_call_history_from): Likewise.
7743 (target_call_history_range): Likewise.
7744 * target.h (struct target_ops) <target_call_history>: Likewise.
7745 (target_call_history_from): Likewise.
7746 (target_call_history_range): Likewise.
7748 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7749 Simon Marchi <simon.marchi@polymtl.ca>
7751 * common/common-utils.c: Include "sys/stat.h".
7752 (is_regular_file): Move here from "source.c"; change return
7754 * common/common-utils.h (is_regular_file): New prototype.
7755 * common/pathstuff.c (contains_dir_separator): New function.
7756 * common/pathstuff.h (contains_dir_separator): New prototype.
7757 * source.c: Don't include "sys/stat.h".
7758 (is_regular_file): Move to "common/common-utils.c".
7760 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
7762 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
7763 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
7764 * auto-load.c: Include "common/pathstuff.h".
7765 * common/common-def.h (current_directory): Move here.
7766 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
7768 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
7770 * common/pathstuff.c: New file.
7771 * common/pathstuff.h: New file.
7772 * compile/compile.c: Include "common/pathstuff.h".
7773 * defs.h (current_directory): Move to "common/common-defs.h".
7774 * dwarf2read.c: Include "common/pathstuff.h".
7776 * guile/scm-safe-call.c: Likewise.
7777 * linux-thread-db.c: Likewise.
7779 * nto-tdep.c: Likewise.
7780 * objfiles.c: Likewise.
7781 * source.c: Likewise.
7782 * symtab.c: Likewise.
7783 * utils.c: Include "common/pathstuff.h".
7784 (gdb_realpath): Move to "common/pathstuff.c".
7785 (gdb_realpath_keepfile): Likewise.
7786 (gdb_abspath): Likewise.
7787 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
7788 (gdb_realpath_keepfile): Likewise.
7789 (gdb_abspath): Likewise.
7791 2018-02-28 John Baldwin <jhb@FreeBSD.org>
7793 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
7794 wildcard process pid for super_resume for kernels with a
7797 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
7799 * compile/compile.c (get_args): Add additional comments
7800 explaining function.
7802 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
7803 Tom Tromey <tom@tromey.com>
7805 * target.h (memory_write_request_s): Remove typedef. Don't define
7807 (target_write_memory_blocks): Change argument to std::vector.
7808 (struct memory_write_request): Add constructor.
7809 * target-memory.c (compare_block_starting_address): Return bool.
7810 Change argument types.
7811 (claim_memory): Change arguments to use std::vector.
7812 (split_regular_and_flash_blocks, blocks_to_erase)
7813 (compute_garbled_blocks): Likewise.
7814 (cleanup_request_data, cleanup_write_requests_vector): Remove.
7815 (target_write_memory_blocks): Change argument to std::vector.
7816 * symfile.c (struct load_section_data): Add constructor and
7817 destructor. Use std::vector for "requests".
7818 (struct load_progress_data): Add initializers.
7819 (load_section_callback): Update. Use "new".
7820 (clear_memory_write_data): Remove.
7821 (generic_load): Update.
7823 2018-02-27 Alan Hayward <alan.hayward@arm.com>
7825 * arch/aarch64.h: Use common/tdesc.h.
7827 2018-02-26 Maciej W. Rozycki <macro@mips.com>
7829 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
7830 architecture with a 64-bit ABI.
7832 2018-02-26 Maciej W. Rozycki <macro@mips.com>
7834 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
7835 ahead of target description loading.
7837 2018-02-26 Tom Tromey <tom@tromey.com>
7839 * stack.c (backtrace_command_1): Update.
7840 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
7842 * python/py-framefilter.c (py_print_frame)
7843 (gdbpy_apply_frame_filter): Change type of "flags".
7844 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
7846 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
7847 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
7848 * extension.h (enum frame_filter_flag): Rename from
7850 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
7851 (apply_ext_lang_frame_filter): Change type of "flags".
7852 * extension.c (apply_ext_lang_frame_filter): Change type of
7854 * extension-priv.h (struct extension_language_ops)
7855 <apply_frame_filter>: Change type of "flags".
7857 2018-02-26 Tom Tromey <tom@tromey.com>
7860 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
7861 off-by-one in py_end computation.
7862 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
7864 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
7867 2018-02-26 Tom Tromey <tom@tromey.com>
7869 * dwarf2read.c (struct variant_field): New.
7870 (struct nextfield) <variant>: New field.
7871 (dwarf2_add_field): Handle DW_TAG_variant_part.
7872 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
7873 discriminated union.
7874 (read_structure_type): Handle DW_TAG_variant_part.
7875 (handle_struct_member_die): New function, extracted from
7876 process_structure_scope. Handle DW_TAG_variant.
7877 (process_structure_scope): Handle discriminated unions. Call
7878 handle_struct_member_die.
7880 2018-02-26 Tom Tromey <tom@tromey.com>
7882 * rust-lang.h (rust_last_path_segment): Declare.
7883 * rust-lang.c (rust_last_path_segment): Now public. Change
7885 (struct disr_info): Remove.
7886 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
7887 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
7888 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
7889 (rust_enum_p, rust_enum_variant): New function.
7890 (rust_underscore_fields): Remove "offset" parameter.
7891 (rust_print_enum): New function.
7892 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
7893 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
7894 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
7896 (rust_internal_print_type): New function, from rust_print_type.
7898 (rust_print_type): Call rust_internal_print_type.
7899 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
7900 Update enum handling.
7901 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
7902 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
7903 (rust_union_quirks): New functions.
7904 (process_full_comp_unit, process_full_type_unit): Call
7906 (process_structure_scope): Update rust_unions if necessary.
7908 2018-02-26 Tom Tromey <tom@tromey.com>
7910 * value.h (value_union_variant): Declare.
7911 * valops.c (value_union_variant): New function.
7912 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
7913 (struct discriminant_info): New.
7914 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
7916 (struct main_type) <flag_discriminated_union>: New field.
7918 2018-02-26 Tom Tromey <tom@tromey.com>
7920 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7921 unittests/unpack-selftests.c.
7922 * unittests/unpack-selftests.c: New file.
7923 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
7925 2018-02-26 Yao Qi <yao.qi@linaro.org>
7927 * dwarf2read.c (struct partial_die_info) <read>: New method.
7928 (read_partial_die): Remove the declaration.
7929 (load_partial_dies): Update.
7930 (partial_die_info::partial_die_info):
7931 (read_partial_die): Change it to partial_die_info::read.
7933 2018-02-26 Yao Qi <yao.qi@linaro.org>
7935 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
7936 (fixup_partial_die): Remove declaration.
7937 (scan_partial_symbols): Update.
7938 (partial_die_parent_scope): Likewise.
7939 (partial_die_full_name): Likewise.
7940 (fixup_partial_die): Change it to partial_die_info::fixup.
7942 2018-02-26 Yao Qi <yao.qi@linaro.org>
7944 * dwarf2read.c (read_partial_die): Update the declaration.
7945 (load_partial_dies): Caller update.
7946 (read_partial_die): Remove one argument abbrev_len.
7948 2018-02-26 Yao Qi <yao.qi@linaro.org>
7950 * dwarf2read.c (struct partial_die_info): Add ctor, delete
7951 assignment operator.
7952 (load_partial_dies): Use ctor and copy ctor.
7953 (read_partial_die): Update.
7954 (dwarf2_cu::find_partial_die): Use ctor.
7956 2018-02-26 Yao Qi <yao.qi@linaro.org>
7958 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
7959 (find_partial_die_in_comp_unit): Change it to
7960 dwarf2_cu::find_partial_die.
7961 (find_partial_die): Update.
7963 2018-02-26 Yao Qi <yao.qi@linaro.org>
7965 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
7968 2018-02-26 Yao Qi <yao.qi@linaro.org>
7970 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
7972 2018-02-26 Alan Hayward <alan.hayward@arm.com>
7974 * arch/amd64.h: Use common/tdesc.h.
7975 * arch/i386.c: Likewise.
7976 * arch/i386.h: Likewise.
7977 * arch/tic6x.c: Likewise.
7978 * arch/tdesc.h: Move file from here...
7979 * common/tdesc.h: ...to here.
7980 * features/aarch64-core.c: Regenerate.
7981 * features/aarch64-fpu.c: Regenerate.
7982 * features/i386/32bit-avx.c: Regenerate.
7983 * features/i386/32bit-avx512.c: Regenerate.
7984 * features/i386/32bit-core.c: Regenerate.
7985 * features/i386/32bit-linux.c: Regenerate.
7986 * features/i386/32bit-mpx.c: Regenerate.
7987 * features/i386/32bit-pkeys.c: Regenerate.
7988 * features/i386/32bit-sse.c: Regenerate.
7989 * features/i386/64bit-avx.c: Regenerate.
7990 * features/i386/64bit-avx512.c: Regenerate.
7991 * features/i386/64bit-core.c: Regenerate.
7992 * features/i386/64bit-linux.c: Regenerate.
7993 * features/i386/64bit-mpx.c: Regenerate.
7994 * features/i386/64bit-pkeys.c: Regenerate.
7995 * features/i386/64bit-segments.c: Regenerate.
7996 * features/i386/64bit-sse.c: Regenerate.
7997 * features/i386/x32-core.c: Regenerate.
7998 * features/tic6x-c6xp.c: Regenerate.
7999 * features/tic6x-core.c: Regenerate.
8000 * features/tic6x-gp.c: Regenerate.
8001 * target-descriptions.c: Use common/tdesc.h.
8002 * target-descriptions.h: Likewise.
8004 2018-02-24 Tom Tromey <tom@tromey.com>
8006 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
8007 (try_thread_db_load_from_dir, thread_db_load_search): Use
8009 (info_auto_load_libthread_db_compare): Return bool. Change
8011 (info_auto_load_libthread_db): Use std::vector, std::string.
8014 2018-02-24 Tom Tromey <tom@tromey.com>
8016 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
8018 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
8020 * gdbarch.c: Rebuild.
8021 * gdbarch.h: Rebuild.
8022 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
8023 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
8024 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
8027 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
8029 * gdbtypes.h (sect_offset): Change type to uint64_t.
8030 (sect_offset_str): New function.
8031 * dwarf2read.c (create_addrmap_from_aranges): Use
8033 (error_check_comp_unit_head): Likewise.
8034 (create_debug_type_hash_table): Likewise.
8035 (read_cutu_die_from_dwo): Likewise.
8036 (init_cutu_and_read_dies): Likewise.
8037 (init_cutu_and_read_dies_no_follow): Likewise.
8038 (process_psymtab_comp_unit_reader): Likewise.
8039 (partial_die_parent_scope): Likewise.
8040 (peek_die_abbrev): Likewise.
8041 (process_queue): Likewise.
8042 (dwarf2_physname): Likewise.
8043 (read_namespace_alias): Likewise.
8044 (read_import_statement): Likewise.
8045 (create_dwo_cu_reader): Likewise.
8046 (create_cus_hash_table): Likewise.
8047 (lookup_dwo_cutu): Likewise.
8048 (inherit_abstract_dies): Likewise.
8049 (read_func_scope): Likewise.
8050 (read_call_site_scope): Likewise.
8051 (dwarf2_add_member_fn): Likewise.
8052 (read_common_block): Likewise.
8053 (read_module_type): Likewise.
8054 (read_typedef): Likewise.
8055 (read_subrange_type): Likewise.
8056 (load_partial_dies): Likewise.
8057 (read_partial_die): Likewise.
8058 (find_partial_die): Likewise.
8059 (read_str_index): Likewise.
8060 (dwarf2_string_attr): Likewise.
8061 (build_error_marker_type): Likewise.
8062 (lookup_die_type): Likewise.
8063 (dump_die_shallow): Likewise.
8064 (follow_die_ref): Likewise.
8065 (dwarf2_fetch_die_loc_sect_off): Likewise.
8066 (dwarf2_fetch_constant_bytes): Likewise.
8067 (follow_die_sig): Likewise.
8068 (get_signatured_type): Likewise.
8069 (get_DW_AT_signature_type): Likewise.
8070 (dwarf2_find_containing_comp_unit): Likewise.
8071 (set_die_type): Likewise.
8073 2018-02-21 John Baldwin <jhb@FreeBSD.org>
8075 * arch/aarch64.c: Include "common-defs.h".
8076 * arch/amd64.c: Likewise.
8077 * arch/i386.c: Likewise.
8079 2018-02-21 Tom Tromey <tom@tromey.com>
8081 * value.h: (extract_field_op): Update.
8082 * eval.c (extract_field_op): Return a const char *.
8083 * expression.h (parse_expression_for_completion): Update.
8084 * completer.c (complete_expression): Update.
8085 (add_struct_fields): Make fieldname const.
8086 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
8087 (mark_completion_tag, parse_exp_in_context_1): Update.
8088 (parse_expression_for_completion): Change "name" to
8089 unique_xmalloc_ptr*.
8091 2018-02-21 Tom Tromey <tom@tromey.com>
8093 * infcall.c (call_function_by_hand_dummy): Use std::vector.
8095 2018-02-21 Yao Qi <yao.qi@linaro.org>
8097 * avr-tdep.c (avr_read_pc): Change parameter type to
8099 * gdbarch.sh (read_pc): Likewise.
8100 * gdbarch.c: Re-generated.
8101 * gdbarch.h: Re-generated.
8102 * hppa-tdep.c (hppa_read_pc): Change parameter type to
8104 * ia64-tdep.c (ia64_read_pc): Likewise.
8105 * mips-tdep.c (mips_read_pc): Likewise.
8106 * spu-tdep.c (spu_read_pc): Likewise.
8108 2018-02-21 Yao Qi <yao.qi@linaro.org>
8110 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
8111 * regcache-dump.c: New file.
8112 * regcache.c: Move register_dump to regcache-dump.c.
8113 (maintenance_print_registers): Likewise.
8114 (maintenance_print_raw_registers): Likewise.
8115 (maintenance_print_cooked_registers): Likewise.
8116 (maintenance_print_register_groups): Likewise.
8117 (maintenance_print_remote_registers): Likewise.
8118 (_initialize_regcache): Likewise.
8119 * regcache.h (register_dump): Moved from regcache.c.
8121 2018-02-21 Yao Qi <yao.qi@linaro.org>
8123 * regcache.c (regcache::regcache): Update.
8124 (regcache::invalidate): Move it to detached_regcache::invalidate.
8125 (get_thread_arch_aspace_regcache): Update.
8126 (regcache::raw_update): Update.
8127 (regcache::cooked_read): Remove some code.
8128 (regcache::cooked_read_value): Likewise.
8129 (regcache::raw_write): Remove assert on m_readonly_p.
8130 (regcache::raw_supply_integer): Move it to
8131 detached_regcache::raw_supply_integer.
8132 (regcache::raw_supply_zeroed): Likewise.
8133 * regcache.h (detached_regcache) <raw_supply_integer>: New
8135 <raw_supply_zeroed, invalidate>: Likewise.
8136 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
8137 <invalidate>: Likewise.
8138 <m_readonly_p>: Removed.
8140 2018-02-21 Yao Qi <yao.qi@linaro.org>
8142 * infcmd.c (get_return_value): Let stop_regs point to
8143 get_current_regcache.
8144 * regcache.c (regcache::regcache): Remove.
8145 (register_dump_reg_buffer): New class.
8146 (regcache_print): Adjust.
8147 * regcache.h (regcache): Remove constructors.
8149 2018-02-21 Yao Qi <yao.qi@linaro.org>
8151 * regcache.c (class register_dump): New class.
8152 (register_dump_regcache, register_dump_none): New class.
8153 (register_dump_remote, register_dump_groups): New class.
8154 (regcache_print): Update.
8155 * regcache.h (regcache_dump_what): Move it to regcache.c.
8156 (regcache) <dump>: Remove.
8158 2018-02-21 Yao Qi <yao.qi@linaro.org>
8160 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
8162 (jit_unwind_reg_set_impl): Call raw_supply.
8163 (jit_frame_sniffer): Use reg_buffer_rw.
8164 * record-full.c (record_full_core_regbuf): Change its type.
8165 (record_full_core_open_1): Use reg_buffer_rw.
8166 (record_full_close): Likewise.
8167 (record_full_core_fetch_registers): Use regcache->raw_supply.
8168 (record_full_core_store_registers): Likewise.
8169 * regcache.c (regcache::get_register_status): Move it to
8171 (regcache_raw_set_cached_value): Remove.
8172 (regcache::raw_set_cached_value): Remove.
8173 (regcache::raw_write): Call raw_supply.
8174 (regcache::raw_supply): Move it to reg_buffer_rw.
8175 * regcache.h (regcache_raw_set_cached_value): Remove.
8176 (reg_buffer_rw): New class.
8178 2018-02-21 Yao Qi <yao.qi@linaro.org>
8180 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
8181 readonly_detached_regcache.
8182 (dummy_frame_prev_register): Use regcache->cooked_read.
8183 * frame.c (frame_save_as_regcache): Change return type.
8184 (frame_pop): Update.
8185 * frame.h (frame_save_as_regcache): Update declaration.
8186 * inferior.h (get_infcall_suspend_state_regcache): Update
8188 * infrun.c (infcall_suspend_state) <registers>: use
8189 readonly_detached_regcache.
8190 (save_infcall_suspend_state): Don't use regcache_dup.
8191 (get_infcall_suspend_state_regcache): Change return type.
8192 * linux-fork.c (struct fork_info) <savedregs>: Change to
8193 readonly_detached_regcache.
8195 (fork_save_infrun_state): Don't use regcache_dup.
8196 (info_checkpoints_command): Adjust.
8197 * mi/mi-main.c (register_changed_p): Update declaration.
8198 (mi_cmd_data_list_changed_registers): Use
8199 readonly_detached_regcache.
8200 (register_changed_p): Change parameter type to
8201 readonly_detached_regcache.
8202 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
8203 readonly_detached_regcache.
8204 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
8205 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
8207 (regcache::save): Move it to reg_buffer.
8208 (regcache::restore): Change parameter type.
8209 (regcache_dup): Remove.
8210 * regcache.h (reg_buffer) <save>: New method.
8211 (readonly_detached_regcache): New class.
8212 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
8213 readonly_detached_regcache.
8214 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
8216 2018-02-21 Yao Qi <yao.qi@linaro.org>
8218 * frame.c (frame_save_as_regcache): Use regcache method save.
8219 (frame_pop): Use regcache method restore.
8220 * infrun.c (restore_infcall_suspend_state): Likewise.
8221 * linux-fork.c (fork_load_infrun_state): Likewise.
8222 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
8224 * regcache.c (regcache_save): Remove.
8225 (regcache::restore): More asserts.
8226 (regcache_cpy): Remove.
8227 * regcache.h (regcache_save): Remove the declaration.
8228 (regcache::restore): Move from private to public.
8229 Remove the friend declaration of regcache_cpy.
8230 (regcache_cpy): Remove declaration.
8232 2018-02-21 Yao Qi <yao.qi@linaro.org>
8234 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
8235 parameter type to 'readable_regcache *'.
8236 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
8237 * arm-tdep.c (arm_neon_quad_read): Likewise.
8238 (arm_pseudo_read): Likewise.
8239 * avr-tdep.c (avr_pseudo_register_read): Likewise.
8240 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
8241 * frv-tdep.c (frv_pseudo_register_read): Likewise.
8242 * gdbarch.c: Re-generated.
8243 * gdbarch.h: Re-generated.
8244 * gdbarch.sh (pseudo_register_read): Change parameter type to
8245 'readable_regcache *'.
8246 (pseudo_register_read_value): Likewise.
8247 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
8248 (h8300_pseudo_register_read): Likewise.
8249 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
8250 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
8251 (i386_pseudo_register_read_into_value): Likewise.
8252 (i386_pseudo_register_read_value): Likewise.
8253 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
8255 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
8256 * m32c-tdep.c (m32c_raw_read): Likewise.
8257 (m32c_read_flg): Likewise.
8258 (m32c_banked_register): Likewise.
8259 (m32c_banked_read): Likewise.
8260 (m32c_sb_read): Likewise.
8261 (m32c_part_read): Likewise.
8262 (m32c_cat_read): Likewise.
8263 (m32c_r3r2r1r0_read): Likewise.
8264 (m32c_pseudo_register_read): Likewise.
8265 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
8266 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
8267 (mep_pseudo_cr64_read): Likewise.
8268 (mep_pseudo_register_read): Likewise.
8269 * mips-tdep.c (mips_pseudo_register_read): Likewise.
8270 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
8271 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
8272 * regcache.c (regcache::raw_read): Move it to readable_regcache.
8273 (regcache::cooked_read): Likewise.
8274 (regcache::cooked_read_value): Likewise.
8275 (regcache_cooked_read_signed):
8276 (regcache::cooked_read): Likewise.
8277 * regcache.h (readable_regcache): New class.
8278 (regcache): Inherit readable_regcache. Move some methods to
8280 * rl78-tdep.c (rl78_pseudo_register_read): Change
8281 parameter type to 'readable_regcache *'.
8282 * rs6000-tdep.c (do_regcache_raw_read): Remove.
8283 (e500_pseudo_register_read): Change parameter type to
8284 'readable_regcache *'.
8285 (dfp_pseudo_register_read): Likewise.
8286 (vsx_pseudo_register_read): Likewise.
8287 (efpr_pseudo_register_read): Likewise.
8288 * s390-tdep.c (s390_pseudo_register_read): Likewise.
8289 * sh-tdep.c (sh_pseudo_register_read): Likewise.
8290 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
8291 (sh64_pseudo_register_read): Likewise.
8292 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
8293 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
8294 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
8295 (spu_pseudo_register_read): Likewise.
8296 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
8297 (xtensa_pseudo_register_read): Likewise.
8299 2018-02-21 Yao Qi <yao.qi@linaro.org>
8301 * regcache.c (regcache::regcache): Call reg_buffer ctor.
8302 (regcache::arch): Move it to reg_buffer::arch.
8303 (regcache::register_buffer): Likewise.
8304 (regcache::assert_regnum): Likewise.
8305 (regcache::num_raw_registers): Likewise.
8306 * regcache.h (reg_buffer): New class.
8307 (regcache): Inherit reg_buffer.
8309 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
8311 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
8312 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
8314 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
8316 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
8318 2018-02-19 Alan Hayward <alan.hayward@arm.com>
8320 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
8321 (SFILES): Remove common/*.c files.
8322 (COMMON_OBS): Remove some *.o files built from common/*.c files.
8323 * common/common.host: Add common reference.
8324 * configure.ac: Likewise.
8325 * configure: Regenerate.
8327 2018-02-16 Yao Qi <yao.qi@linaro.org>
8329 * block.c (block_namespace_info): Inherit allocate_on_obstack.
8330 (block_initialize_namespace): Use new.
8331 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
8332 (dwarf2_free_objfile): Use delete.
8333 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
8334 (copy_type_recursive): Use new.
8335 * gdb_obstack.h (allocate_on_obstack): New.
8337 2018-02-15 Yao Qi <yao.qi@linaro.org>
8340 * inferior.c (exit_inferior_1): Reset inf->control.
8342 2018-02-15 Joel Brobecker <brobecker@adacore.com>
8344 * ada-lang.c (ada_to_fixed_value_create): Delete advance
8347 2018-02-14 Pedro Alves <palves@redhat.com>
8349 * frame-unwind.c (frame_unwind_try_unwinder): Always call
8350 frame_cleanup_after_sniffer on exception.
8352 2018-02-14 Tom Tromey <tom@tromey.com>
8354 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
8356 (solib_bfd_open): Make pathname const.
8357 * solib.c (solib_bfd_open): Make pathname const.
8358 * solib-spu.c (spu_bfd_fopen): Make name const.
8359 (spu_bfd_open): Make pathname const.
8360 * solib-darwin.c (darwin_bfd_open): Make pathname const.
8361 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
8363 2018-02-14 Tom Tromey <tom@tromey.com>
8365 * symfile.c (symfile_bfd_open): Update.
8366 * source.h (openp, source_full_path_of, find_and_open_source):
8367 Change argument type to unique_xmalloc_ptr.
8368 * source.c (openp): Take a unique_xmalloc_ptr.
8369 (source_full_path_of, find_and_open_source): Likewise.
8370 (open_source_file, symtab_to_fullname): Update.
8371 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
8373 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
8374 (exec_file_find): Update.
8375 * psymtab.c (psymtab_to_fullname): Update.
8376 * nto-tdep.h (nto_find_and_open_solib): Update.
8377 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
8379 * exec.c (exec_file_attach): Update.
8380 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
8381 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
8383 2018-02-14 Tom Tromey <tom@tromey.com>
8385 * solib.c: Include source.h.
8386 * nto-tdep.c: Include source.h.
8387 * mi/mi-cmd-env.c: Include source.h.
8388 * infcmd.c: Include source.h.
8389 * exec.c: Include source.h.
8390 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
8391 (add_path, directory_switch, source_path, init_source_path): Move
8393 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
8394 (add_path, directory_switch, source_path, init_source_path):
8397 2018-02-14 Tom Tromey <tom@tromey.com>
8399 * solist.h (exec_file_find, solib_find): Return
8401 (solib_bfd_fopen): Take a const char *.
8402 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
8403 (exec_file_find, solib_find): Likewise.
8404 (solib_bfd_fopen): Do not take ownership of "pathname".
8405 (solib_bfd_open): Use unique_xmalloc_ptr.
8406 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
8407 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
8408 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
8409 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
8411 2018-02-14 Joel Brobecker <brobecker@adacore.com>
8413 * ada-lang.c (name_match_type_from_name): Remove reference to
8414 ada_name_for_lookup in function's documentation.
8415 * ada-lang.h (ada_name_for_lookup): Delete declaration.
8417 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8419 * defs.h (enum openp_flags): New enum.
8420 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
8421 Move to enum openp_flags.
8422 (openp_flags): New enum flags.
8423 (openp): Change parameter type to openp_flags.
8424 * source.c (openp): Change parameter type to openp_flags.
8425 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
8426 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
8428 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
8430 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
8433 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
8435 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
8437 (class dwarf2_queue_guard): ...the destructor of this new class.
8438 (dw2_do_instantiate_symtab): Create instance of the new class
8439 dwarf2_queue_guard, remove cleanup.
8441 2018-02-09 Tom Tromey <tom@tromey.com>
8443 * source.c (find_source_lines): Don't reference past the end of
8446 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8448 * remote.c (remote_btrace_maybe_reopen): Change error message.
8449 * btrace.c (btrace_enable): Likewise.
8450 (parse_xml_btrace): Likewise.
8451 (parse_xml_btrace_conf): Likewise.
8453 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8455 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
8456 (linux_enable_pt, linux_enable_bts): Call
8457 diagnose_perf_event_open_fail.
8459 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8461 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
8462 Remove parameter and change return type. Update callers. Move it.
8463 (linux_enable_bts, linux_enable_pt): Improve error message.
8464 (linux_enable_pt): Remove zero buffer size check.
8465 (linux_enable_btrace): Improve error messages. Remove NULL return
8468 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8470 * btrace.c (btrace_enable): Remove target_supports_btrace call.
8471 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
8472 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
8473 (linux_supports_pt, linux_supports_btrace): Remove.
8474 (linux_enable_bts): Call cpu_supports_bts.
8475 * nat/linux-btrace.h (linux_supports_btrace): Remove.
8476 * remote.c (remote_supports_btrace): Remove.
8477 (init_remote_ops): Remove remote_supports_btrace.
8478 * target-delegates.c: Regenerated.
8479 * target.c (target_supports_btrace): Remove.
8480 * target.h (target_ops) <to_supports_btrace>: Remove
8481 (target_supports_btrace): Remove.
8482 * x86-linux-nat.c (x86_linux_create_target): Remove
8483 linux_supports_btrace.
8485 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8487 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
8489 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
8490 exception and use message in own exception.
8492 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8494 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
8495 (perf_event_pt_event_type): Use gdb_file_up.
8496 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
8497 scoped_fd, and scoped_mmap.
8499 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8501 * common/scoped_mmap.h: New.
8502 * unittests/scoped_mmap-selftest.c: New.
8503 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8504 unittests/scoped_mmap-selftest.c.
8506 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
8508 * common/scoped_fd.h: New.
8509 * unittests/scoped_fd-selftest.c: New.
8510 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8511 unittests/scoped_fd-selftest.c.
8513 2018-02-09 Tom Tromey <tom@tromey.com>
8515 * auto-load.c (auto_load_section_scripts): Use
8516 gdb::unique_xmalloc_ptr.
8518 2018-02-09 Tom Tromey <tom@tromey.com>
8520 * auto-load.c (execute_script_contents): Use std::string.
8522 2018-02-09 Joel Brobecker <brobecker@adacore.com>
8524 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
8525 Python function, rather than a new command.
8527 2018-02-08 Tom Tromey <tom@tromey.com>
8529 * solib.c (solib_find_1): Use std::string.
8530 (solib_bfd_fopen): Use unique_xmalloc_ptr.
8532 2018-02-08 Tom Tromey <tom@tromey.com>
8534 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
8536 2018-02-08 Tom Tromey <tom@tromey.com>
8538 * source.c (find_source_lines): Use gdb::def_vector.
8540 2018-02-08 Tom Tromey <tom@tromey.com>
8542 * macrocmd.c (struct temporary_macro_definition): New.
8543 (macro_define_command): Use temporary_macro_definition. Remove
8545 (free_macro_definition_ptr): Remove.
8547 2018-02-08 Tom Tromey <tom@tromey.com>
8549 * macroexp.c (maybe_expand): Use std::string.
8551 2018-02-08 Tom Tromey <tom@tromey.com>
8553 * macroexp.c (struct macro_buffer): Add initializers for some
8555 (init_buffer, init_shared_buffer, free_buffer)
8556 (free_buffer_return_text): Remove.
8557 (macro_buffer): New constructors.
8558 (~macro_buffer): New destructor.
8559 (macro_buffer::set_shared): New method.
8560 (macro_buffer::resize_buffer, macro_buffer::appendc)
8561 (macro_buffer::appendmem): Now methods, not free functions.
8562 (set_token, append_tokens_without_splicing, stringify)
8563 (macro_stringify): Update.
8564 (gather_arguments): Change return type. Remove argc_p argument,
8565 add args_ptr argument. Use std::vector.
8566 (substitute_args): Remove argc argument. Accept std::vector.
8567 (expand): Update. Use std::vector.
8568 (scan, macro_expand, macro_expand_next): Update.
8570 2018-02-08 Tom Tromey <tom@tromey.com>
8572 * symtab.c (default_collect_symbol_completion_matches_break_on):
8573 Use unique_xmalloc_ptr.
8574 * macroscope.h: (sal_macro_scope, user_macro_scope)
8575 (default_macro_scope): Return unique_xmalloc_ptr.
8576 * macroscope.c (sal_macro_scope, user_macro_scope)
8577 (default_macro_scope): Return unique_xmalloc_ptr.
8578 * macroexp.h (macro_expand, macro_expand_once): Return
8580 * macroexp.c (macro_expand, macro_expand_once): Return
8582 * macrocmd.c (macro_expand_command, macro_expand_once_command)
8583 (info_macro_command, info_macros_command): Use
8585 * compile/compile-c-support.c (write_macro_definitions): Use
8587 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
8589 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
8591 * value.c (value_static_field): Assign field type instead of
8592 containing type when returning an optimized out value.
8594 2018-02-06 Yao Qi <yao.qi@linaro.org>
8596 * ft32-tdep.c (ft32_read_pc): Remove.
8597 (ft32_write_pc): Remove.
8598 (ft32_gdbarch_init): Update.
8599 * m32r-tdep.c (m32r_read_pc): Remove.
8600 (m32r_gdbarch_init): Update.
8601 * mep-tdep.c (mep_read_pc): Remove.
8602 (mep_gdbarch_init): Update.
8603 * microblaze-tdep.c (microblaze_write_pc): Remove.
8604 (microblaze_gdbarch_init): Update.
8605 * mn10300-tdep.c (mn10300_read_pc): Remove.
8606 (mn10300_write_pc): Remove.
8607 (mn10300_gdbarch_init): Update.
8608 * moxie-tdep.c (moxie_read_pc): Remove.
8609 (moxie_write_pc): Remove.
8610 (moxie_gdbarch_init): Update.
8612 2018-02-06 Yao Qi <yao.qi@linaro.org>
8614 * expprint.c (print_subexp_standard): Handle
8615 OP_F77_UNDETERMINED_ARGLIST.
8616 (dump_subexp_body_standard): Likewise.
8618 2018-02-05 Alan Hayward <alan.hayward@arm.com>
8620 * target-descriptions.c (tdesc_element_visitor) Add empty
8622 (tdesc_type): Move make_gdb_type from here.
8623 (tdesc_type_builtin): Likewise.
8624 (tdesc_type_vector): Likewise.
8625 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
8626 (make_gdb_type_struct): Move from tdesc_type_with_fields.
8627 (make_gdb_type_union): Likewise.
8628 (make_gdb_type_flags): Likewise.
8629 (make_gdb_type_enum): Likewise.
8630 (make_gdb_type): New function.
8631 (tdesc_register_type): Use static make_gdb_type.
8633 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
8635 * infcmd.c (default_print_one_register_info): Align natural-format
8636 column values consistently one under another.
8637 (pad_to_column): New function.
8639 2018-02-05 Joel Brobecker <brobecker@adacore.com>
8641 * dwarf2read.c (dwarf2_physname): Move commment.
8643 2018-02-01 Leszek Swirski <leszeks@google.com>
8645 * varobj.c (varobj_formatted_print_options): Allow recursive
8646 pretty printing if pretty printing is enabled.
8648 2018-02-01 Leszek Swirski <leszeks@google.com>
8650 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
8651 names after a structop as a filename.
8653 2018-02-01 Yao Qi <yao.qi@linaro.org>
8655 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
8656 (arm_record_coproc_data_proc): Likewise.
8658 2018-02-01 Yao Qi <yao.qi@linaro.org>
8660 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
8662 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
8664 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
8665 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
8667 2018-01-31 Pedro Alves <palves@redhat.com>
8669 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
8670 * inflow.c (child_terminal_save_inferior): Wrap reference to
8671 tcgetpgrp in HAVE_TERMIOS_H.
8672 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
8674 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
8675 always iterate over all inferiors.
8676 (gdbsim_cntrl_c): Adjust.
8677 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
8679 2018-01-31 Joel Brobecker <brobecker@adacore.com>
8681 * gdbtypes.c (lookup_array_range_type): Make sure the array's
8682 index type is objfile-owned if the element type is as well.
8684 2018-01-31 Joel Brobecker <brobecker@adacore.com>
8688 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
8690 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
8691 "features/s390x-linux64.c".
8692 (_initialize_s390_linux_tdep): Remove initialization of tdescs
8693 s390_linux32 and s390x_linux64.
8694 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
8696 * s390-tdep.c: Include "features/s390-linux32.c" and
8697 "features/s390x-linux64.c".
8698 (s390_tdesc_valid): Add check for tdesc_has_registers.
8699 (s390_gdbarch_init): Make sure there is always a valid tdesc.
8700 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
8701 tdesc_s390x_linux64.
8702 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
8703 tdesc_s390x_linux64 to...
8704 * s390-tdep.h: ...here.
8706 2018-01-30 Pedro Alves <palves@redhat.com>
8709 * config.in, configure: Regenerate.
8710 * configure.ac: Check for getpgid.
8711 * go32-nat.c (go32_pass_ctrlc): New.
8712 (go32_target): Install it.
8713 * inf-child.c (inf_child_target): Install
8714 child_terminal_save_inferior, child_pass_ctrlc and
8716 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
8717 (inf_ptrace_target): No longer install it.
8718 * infcmd.c (interrupt_target_1): Adjust.
8719 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
8720 (child_interrupt): Declare.
8721 (inferior::terminal_state): New.
8722 * inflow.c (struct terminal_info): Update comments.
8723 (inferior_process_group): Delete.
8724 (terminal_is_ours): Delete.
8725 (gdb_tty_state): New.
8726 (child_terminal_init): Adjust.
8727 (is_gdb_terminal, sharing_input_terminal_1)
8728 (sharing_input_terminal): New functions.
8729 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
8730 Set the process's actual process group in the foreground if
8731 possible. Handle is_ours_for_output/is_ours distinction. Don't
8732 mark terminal as the inferior's if not sharing GDB's terminal.
8733 Don't check attach_flag.
8734 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
8735 pass down a target_terminal_state.
8736 (child_terminal_save_inferior): New, factored out from ...
8737 (child_terminal_ours_1): ... this. Handle
8738 target_terminal_state::is_ours_for_output.
8739 (child_interrupt, child_pass_ctrlc): New.
8740 (inflow_inferior_exit): Clear the inferior's terminal_state.
8741 (copy_terminal_info): Copy the inferior's terminal state.
8742 (_initialize_inflow): Remove reference to terminal_is_ours.
8743 * inflow.h (inferior_process_group): Delete.
8744 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
8745 * procfs.c (procfs_target): Don't install procfs_interrupt.
8746 (procfs_interrupt): Delete.
8747 * remote.c (remote_serial_quit_handler): Adjust.
8748 (remote_interrupt): Remove ptid parameter. Adjust.
8749 * target-delegates.c: Regenerate.
8750 * target.c: Include "terminal.h".
8751 (target_terminal::terminal_state): Rename to ...
8752 (target_terminal::m_terminal_state): ... this.
8753 (target_terminal::init): Adjust.
8754 (target_terminal::inferior): Adjust to per-inferior
8756 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
8757 (target_terminal::ours, target_terminal::ours_for_output): Use
8758 target_terminal_is_ours_kind.
8759 (target_interrupt): Remove ptid parameter. Adjust.
8760 (default_target_pass_ctrlc): Adjust.
8761 * target.h (target_ops::to_terminal_save_inferior): New field.
8762 (target_ops::to_interrupt): Remove ptid_t parameter.
8763 (target_interrupt): Remove ptid_t parameter. Update comment.
8764 (target_pass_ctrlc): Update comment.
8765 * target/target.h (target_terminal_state): New scoped enum,
8767 (target_terminal::terminal_state): ... here.
8768 (target_terminal::inferior): Update comments.
8769 (target_terminal::restore_inferior): New.
8770 (target_terminal::is_inferior, target_terminal::is_ours)
8771 (target_terminal::is_ours_for_output): Adjust.
8772 (target_terminal::scoped_restore_terminal_state): Adjust to
8773 rename, and call restore_inferior() instead of inferior().
8774 (target_terminal::scoped_restore_terminal_state::m_state): Change
8776 (target_terminal::terminal_state): Rename to ...
8777 (target_terminal::m_terminal_state): ... this and change type.
8779 2018-01-30 Pedro Alves <palves@redhat.com>
8781 * linux-nat.c (wait_for_signal): New function.
8782 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
8784 (async_terminal_is_ours)
8785 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
8786 (linux_nat_add_target): Don't override
8787 to_terminal_inferior/to_terminal_ours.
8789 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
8791 * remote.c (remote_follow_fork): Don't call "detach_inferior".
8793 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
8795 * dwarf2read.c (free_dwo_files): Add forward-declaration.
8796 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
8797 dwarf2_per_objfile_free here.
8798 (dwarf2_per_objfile_free): Remove.
8799 (_initialize_dwarf2_read): Don't register
8800 dwarf2_per_objfile_free as a registry cleanup.
8802 2018-01-27 Eli Zaretskii <eliz@gnu.org>
8804 Avoid compilation errors in MinGW native builds
8806 The error is triggered by including python-internal.h, and the
8809 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
8810 from build-gnulib/import/math.h:27,
8811 from d:/usr/Python26/include/pyport.h:235,
8812 from d:/usr/Python26/include/Python.h:58,
8813 from python/python-internal.h:94,
8814 from python/py-arch.c:24:
8815 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
8819 This happens because Python headers define 'hypot' to expand t
8820 '_hypot' in the Windows builds.
8821 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
8822 'hypoth'. This avoids a compilation error.
8824 2018-01-26 Alan Hayward <alan.hayward@arm.com>
8826 * MAINTAINERS (Write After Approval): Fix ordering.
8828 2018-01-26 Alan Hayward <alan.hayward@arm.com>
8830 * MAINTAINERS (Write After Approval): Add Alan Hayward.
8832 2018-01-26 Alan Modra <amodra@gmail.com>
8834 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
8835 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
8836 Remove nop. Make const. Comment.
8837 (powerpc32_plt_stub_so_2): New.
8838 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
8839 Correct count. Update uses.
8840 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
8841 Move common code reading PLT entry word. Correct
8842 powerpc32_plt_stub PLT address calculation.
8843 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
8844 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
8845 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
8846 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
8847 (ppc64_standard_linkage8): Likewise.
8848 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
8849 Correct insns description.
8850 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
8852 2018-01-24 Pedro Alves <palves@redhat.com>
8854 GCC PR libstdc++/83906
8855 * gdbtypes.c (operator==(const dynamic_prop &,
8856 const dynamic_prop &)): New.
8857 (operator==(const range_bounds &, const range_bounds &)): New.
8858 (check_types_equal): Use them instead of memcmp.
8859 * gdbtypes.h (operator==(const dynamic_prop &,
8860 const dynamic_prop &)): Declare.
8861 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
8862 (operator==(const range_bounds &, const range_bounds &)): Declare.
8863 (operator!=(const range_bounds &, const range_bounds &)): Declare.
8865 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8867 * s390-linux-tdep.c (s390_record_address_mask)
8868 (s390_record_calc_disp_common, s390_record_calc_disp)
8869 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8870 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8871 (s390_process_record): Move to s390-tdep.c.
8872 (s390_linux_init_abi_any): Adjust.
8873 * s390-tdep.c (s390_record_address_mask)
8874 (s390_record_calc_disp_common, s390_record_calc_disp)
8875 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
8876 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
8877 (s390_process_record): Moved from s390-linux-tdep.c
8878 (s390_gdbarch_init): Adjust.
8880 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8882 * s390-linux-nat.c (s390-tdep.h): New include.
8883 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
8884 (HFILES_NO_SRCDIR): Add s390-tdep.h.
8885 (ALLDEPFILES): Add s390-tdep.c.
8886 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
8887 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
8888 * s390-tdep.h: ...this. New file.
8889 * s390-linux-tdep.c (s390-tdep.h): New include.
8890 (_initialize_s390_tdep): Rename to...
8891 (_initialize_s390_linux_tdep): ...this and adjust.
8892 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
8893 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
8895 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
8896 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
8897 (s390_is_partial_instruction, s390_software_single_step)
8898 (is_non_branch_ril, s390_displaced_step_copy_insn)
8899 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
8900 (s390_prologue_data, s390_addr, s390_store, s390_load)
8901 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
8902 (s390_register_call_saved, s390_guess_tracepoint_registers)
8903 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
8904 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
8905 (s390_pseudo_register_name, s390_pseudo_register_type)
8906 (s390_pseudo_register_read, s390_pseudo_register_write)
8907 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
8908 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
8909 (s390_addr_bits_remove, s390_address_class_type_flags)
8910 (s390_address_class_type_flags_to_name)
8911 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
8912 (s390_function_arg_float, s390_function_arg_vector)
8913 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
8914 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
8915 (s390_frame_align, s390_register_return_value, s390_return_value)
8916 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
8917 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
8918 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
8919 (s390_trad_frame_prev_register, s390_unwind_cache)
8920 (s390_prologue_frame_unwind_cache)
8921 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
8922 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
8923 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
8924 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
8925 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
8926 (s390_frame_base_address, s390_local_base_address)
8927 (s390_frame_base, s390_gcc_target_options)
8928 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
8929 (s390_validate_reg_range, s390_tdesc_valid)
8930 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
8931 * s390-tdep.c: ...this. New file.
8933 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8935 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
8936 (s390_process_record, s390_gdbarch_tdep_alloc)
8937 (s390_linux_init_abi_any): Use/set new hook.
8939 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8941 * s390-linux-tdep.c (osabi.h): New include.
8942 (s390_linux_init_abi_31, s390_linux_init_abi_64)
8943 (s390_linux_init_abi_any): New functions.
8944 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
8946 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8948 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
8949 tdesc_has_registers check
8951 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8953 * s390-linux-tdep.c (s390_tdesc_valid): New function.
8954 (s390_validate_reg_range): New macro.
8955 (s390_gdbarch_init): Adjust.
8957 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8959 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
8960 (s390_gdbarch_tdep_alloc): Adjust.
8961 (s390_gdbarch_init): Adjust.
8963 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8965 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
8966 <have_tdb>: Change type to bool.
8967 (s390_gdbarch_tdep_alloc): Adjust.
8968 (s390_gdbarch_init): Adjust.
8970 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8972 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
8973 (gdbarch_tdep) <have_upper, have_vx>: New fields.
8974 (s390_gdbarch_tdep_alloc): New function.
8975 (s390_gdbarch_init): Allocate tdep at start and use its fields
8976 instead of separate variables.
8978 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8980 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
8981 when looking for cached gdbarch and add comment for remaining.
8983 2018-01-22 Pedro Alves <palves@redhat.com>
8984 Sergio Durigan Junior <sergiodj@redhat.com>
8986 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
8989 2018-01-22 Maciej W. Rozycki <macro@mips.com>
8991 * MAINTAINERS: Update my company e-mail address.
8993 2018-01-22 Yao Qi <yao.qi@linaro.org>
8995 * regcache.c (cooked_write_test): New function.
8996 (_initialize_regcache): Register the test.
8998 2018-01-22 Yao Qi <yao.qi@linaro.org>
9000 * ia64-tdep.c (ia64_pseudo_register_read): Call
9001 regcache->cooked_read instead of regcache_cooked_read_unsigned.
9002 * m32c-tdep.c (m32c_cat_read): Likewise.
9003 (m32c_r3r2r1r0_read): Likewise.
9004 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9005 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9007 2018-01-22 Yao Qi <yao.qi@linaro.org>
9009 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
9010 method raw_read instead of regcache_raw_read.
9011 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9012 * arm-tdep.c (arm_neon_quad_read): Likewise.
9013 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9014 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9015 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9016 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
9017 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9018 (i386_pseudo_register_read_into_value): Likewise.
9019 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9020 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9021 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9022 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
9023 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
9024 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9025 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9026 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9027 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
9029 2018-01-22 Yao Qi <yao.qi@linaro.org>
9031 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
9032 * configure.tgt: Remove target mt.
9033 * mt-tdep.c: Remove.
9034 * regcache.c (cooked_read_test): Remove the check for mt.
9036 2018-01-22 Yao Qi <yao.qi@linaro.org>
9038 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
9039 instead of gdbarch_pseudo_register_read_value.
9041 2018-01-22 Joel Brobecker <brobecker@adacore.com>
9043 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
9046 2018-01-22 Joel Brobecker <brobecker@adacore.com>
9048 * linespec.c (create_sals_line_offset): Remove code that preserved
9049 the symtab_and_line's line number.
9051 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9053 * varobj.c (varobj_create): Don't set valid_block when creating a
9056 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9058 * varobj.c (varobj_create): Remove out of date comment.
9060 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9063 * ada-exp.y (write_var_from_sym): Pass extra parameter when
9064 updating innermost block.
9065 * parse.c (innermost_block_tracker::update): Take extra type
9066 parameter, and check types match before updating innermost block.
9067 (write_dollar_variable): Update innermost block for registers.
9068 * parser-defs.h (enum innermost_block_tracker_type): New enum.
9069 (innermost_block_tracker::innermost_block_tracker): Initialise
9071 (innermost_block_tracker::reset): Take type parameter.
9072 (innermost_block_tracker::update): Take type parameter, and pass
9073 type through as needed.
9074 (innermost_block_tracker::m_types): New member.
9075 * varobj.c (varobj_create): Pass type when reseting innermost
9078 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9080 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
9081 * ada-lang.c (resolve_subexp): Likewise.
9082 * breakpoint.c (set_breakpoint_condition) Likewise.
9083 (watch_command_1) Likewise.
9084 * c-exp.y (variable): Likewise.
9085 * d-exp.y (PrimaryExpression): Likewise.
9086 * f-exp.y (variable): Likewise.
9087 * go-exp.y (variable): Likewise.
9088 * m2-exp.y (variable): Likewise.
9089 * objfiles.c (objfile::~objfile): Likewise.
9090 * p-exp.y (variable): Likewise.
9091 * parse.c (innermost_block): Change type.
9092 * parser-defs.h (class innermost_block_tracker): New.
9093 (innermost_block): Change to innermost_block_tracker.
9094 * printcmd.c (display_command): Switch to innermost_block API.
9095 (do_one_display): Likewise.
9096 * rust-exp.y (do_one_display): Likewise.
9097 * symfile.c (clear_symtab_users): Likewise.
9098 * varobj.c (varobj_create): Switch to innermost_block API, replace
9099 use of innermost_block with block stored on varobj object.
9101 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
9103 * expression.h (innermost_block): Remove declaration.
9104 * varobj.c: Add 'parser-defs.h' include.
9106 2018-01-19 Tom Tromey <tom@tromey.com>
9108 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
9109 symbols in the static and global blocks.
9111 2018-01-19 James Clarke <jrtc27@jrtc27.com>
9113 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
9114 gdb_ptrace.h, and move including gdb_wait.h ...
9115 * nat/linux-ptrace.h: ... to here.
9117 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9119 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
9120 inf_ptrace_detach_success.
9121 (inf_ptrace_detach_success): Add inferior parameter, use it
9122 instead of inferior_ptid, pass it to detach_inferior.
9123 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
9125 * inferior.c (detach_inferior): Add overload that takes an
9127 * inferior.h (detach_inferior): Likewise.
9128 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
9129 use inferior_ptid, adjust call to inf_ptrace_detach_success.
9130 * linux-thread-db.c (thread_db_detach): Use inf parameter.
9132 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9134 * target.h (struct target_ops) <to_detach>: Add inferior
9136 (target_detach): Likewise.
9137 * target.c (dispose_inferior): Pass inferior down.
9138 (target_detach): Pass inferior down. Assert that it is equal to
9139 the current inferior.
9140 * aix-thread.c (aix_thread_detach): Pass inferior down.
9141 * corefile.c (core_file_command): Pass current_inferior() down.
9142 * corelow.c (core_detach): Add inferior parameter.
9143 * darwin-nat.c (darwin_detach): Likewise.
9144 * gnu-nat.c (gnu_detach): Likewise.
9145 * inf-ptrace.c (inf_ptrace_detach): Likewise.
9146 * infcmd.c (detach_command): Pass current_inferior() down to
9148 * infrun.c (follow_fork_inferior): Pass parent_inf to
9150 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
9152 * linux-nat.c (linux_nat_detach): Add inferior parameter.
9153 * linux-thread-db.c (thread_db_detach): Likewise.
9154 * nto-procfs.c (procfs_detach): Likewise.
9155 * procfs.c (procfs_detach): Likewise.
9156 * record.c (record_detach): Likewise.
9157 * record.h (struct inferior): Forward-declare.
9158 (record_detach): Add inferior parameter.
9159 * remote-sim.c (gdbsim_detach): Likewise.
9160 * remote.c (remote_detach_1): Likewise.
9161 (remote_detach): Likewise.
9162 (extended_remote_detach): Likewise.
9163 * sol-thread.c (sol_thread_detach): Likewise.
9164 * target-debug.h (target_debug_print_inferior_p): New macro.
9165 * target-delegates.c: Re-generate.
9166 * top.c (kill_or_detach): Pass inferior down to target_detach.
9167 * windows-nat.c (windows_detach): Add inferior parameter.
9169 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
9171 * target.h (struct target_ops) <to_detach>: Remove args
9173 (target_detach): Likewise.
9174 * target.c (dispose_inferior): Adjust.
9175 (target_detach): Remove args parameter, adjust.
9176 * aix-thread.c (aix_thread_detach): Adjust.
9177 * corefile.c (core_file_command): Adjust.
9178 * corelow.c (core_detach): Adjust.
9179 * darwin-nat.c (darwin_detach): Adjust.
9180 * gnu-nat.c (gnu_detach): Adjust.
9181 * inf-ptrace.c (inf_ptrace_detach): Adjust.
9182 * infcmd.c (detach_command): Adjust
9183 * infrun.c (follow_fork_inferior): Adjust.
9184 (handle_vfork_child_exec_or_exit): Adjust.
9185 * linux-fork.c (linux_fork_detach): Remove args parameter.
9186 * linux-fork.h (linux_fork_detach): Likewise.
9187 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
9188 * linux-thread-db.c (thread_db_detach): Likewise.
9189 * nto-procfs.c (procfs_detach): Likewise.
9190 * procfs.c (procfs_detach): Likewise.
9191 (do_detach): Remove signo parameter.
9192 * record.c (record_detach): Remove args parameter.
9193 * record.h (record_detach): Likewise.
9194 * remote-sim.c (gdbsim_detach): Likewise.
9195 * remote.c (remote_detach_1): Likewise.
9196 (remote_detach): Likewise.
9197 (extended_remote_detach): Likewise.
9198 * sol-thread.c (sol_thread_detach): Likewise.
9199 * target-delegates.c: Re-generate.
9200 * top.c (struct qt_args) <args>: Remove field.
9201 (kill_or_detach): Don't pass args.
9202 (quit_force): Don't set args.
9203 * windows-nat.c (windows_detach): Remove args parameter.
9205 2018-01-19 Yao Qi <yao.qi@linaro.org>
9207 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
9208 (arm_linux_init_abi): Install it.
9210 2018-01-19 Yao Qi <yao.qi@linaro.org>
9212 * osabi.c (gdb_osabi_names): Extend the regexp for
9213 arm-linux-gnueabihf.
9215 2018-01-18 Yao Qi <yao.qi@linaro.org>
9217 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
9219 (abbrev_table::add_abbrev): Update.
9220 (abbrev_table::lookup_abbrev): Update.
9222 2018-01-18 Yao Qi <yao.qi@linaro.org>
9224 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
9226 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
9228 * compile/compile.c (compile_to_object): Convert "triplet_rx"
9231 2018-01-17 Tom Tromey <tom@tromey.com>
9233 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
9235 2018-01-17 Tom Tromey <tom@tromey.com>
9237 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
9238 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
9239 (create_array_type_with_stride): Update.
9240 * dwarf2read.c (set_die_type): Update.
9242 2018-01-17 Tom Tromey <tom@tromey.com>
9244 * dwarf2read.c (delayed_method_info): Remove typedef.
9245 (dwarf2_cu::method_info): Now a std::vector.
9246 (add_to_method_list): Update.
9247 (free_delayed_list): Remove.
9248 (compute_delayed_physnames): Update.
9249 (process_full_comp_unit, process_full_type_unit): Clear the method
9250 list. Remove cleanups.
9251 (psymtab_include_file_name): Add name_holder parameter. Use
9253 (dwarf_decode_lines): Update.
9255 2018-01-17 Tom Tromey <tom@tromey.com>
9256 Simon Marchi <simon.marchi@ericsson.com>
9258 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
9259 (dwarf2_per_objfile::free_cached_comp_units)
9260 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9261 (init_cutu_and_read_dies_no_follow): Update.
9262 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
9263 (dwarf2_cu::~dwarf2_cu): New.
9264 (free_heap_comp_unit, free_stack_comp_unit): Remove.
9265 (age_cached_comp_units, free_one_cached_comp_unit): Update.
9267 2018-01-17 Tom Tromey <tom@tromey.com>
9268 Simon Marchi <simon.marchi@ericsson.com>
9270 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
9271 (struct die_reader_specs) <abbrev_table>: New member.
9272 (struct abbrev_table): Add constructor.
9273 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
9274 <abbrev_obstack>: Now an auto_obstack.
9275 (abbrev_table_up): New typedef.
9276 (init_cu_die_reader): Add abbrev_table parameter.
9277 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
9278 Add result_dwo_abbrev_table.
9279 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
9280 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
9282 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
9284 (skip_children): Update.
9285 (abbrev_table::alloc_abbrev): Rename from
9286 abbrev_table_alloc_abbrev.
9287 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
9288 (abbrev_table::lookup_abbrev): Rename from
9289 abbrev_table_lookup_abbrev.
9290 (abbrev_table_read_table): Return abbrev_table_up.
9291 (abbrev_table_free, abbrev_table_free_cleanup)
9292 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
9293 (load_partial_dies): Update.
9295 2018-01-17 Tom Tromey <tom@tromey.com>
9297 * dwarf2read.c (dwarf2_compute_name): Update comment.
9298 (read_func_scope, read_variable): Update.
9299 (new_symbol): Remove.
9300 (new_symbol_full): Rename to new_symbol.
9302 2018-01-17 Mike Gulick <mgulick@mathworks.com>
9305 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
9306 a warning instead of throwing an error, set section size to 0 and return
9308 * gdb_bfd.h (gdb_bfd_map_section): Update description.
9310 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9312 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
9314 (linux_ptrace_attach_fail_reason_string): Likewise.
9315 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
9317 (linux_ptrace_attach_fail_reason_string): Likewise.
9318 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
9320 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
9322 * linux-nat.c (linux_nat_attach): Remove xstrdup.
9324 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
9327 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
9328 checking for fs_base/gs_base fields in struct user_regs_struct.
9329 * configure: Regenerate.
9331 2018-01-17 Yao Qi <yao.qi@linaro.org>
9333 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
9335 (aarch64_linux_init_abi): Install it to gdbarch hook
9338 2018-01-15 Pedro Alves <palves@redhat.com>
9340 * common/signals-state-save-restore.c
9341 (save_original_signals_state): Fix typos.
9343 2017-01-12 Tom Tromey <tom@tromey.com>
9344 Sergio Durigan Junior <sergiodj@redhat.com>
9346 * Makefile.in (install-only): Install gdb-add-index.
9348 2018-01-12 John Baldwin <jhb@FreeBSD.org>
9350 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
9352 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
9354 * infrun.c (keep_going_pass_signal): Clear step-over info when
9355 insert_breakpoints fails.
9357 2018-01-11 Pedro Alves <palves@redhat.com>
9360 * infrun.c (resume): Rename to ...
9361 (resume_1): ... this.
9362 (resume): Reimplement as wrapper around resume_1.
9364 2018-01-11 Pedro Alves <palves@redhat.com>
9367 * remote.c (remote_parse_stop_reply): Default to the last-set
9368 general thread instead of to 'magic_null_ptid'.
9370 2018-01-10 Pedro Alves <palves@redhat.com>
9372 * language.h (language_get_symbol_name_matcher): Rename ...
9373 (get_symbol_name_matcher): ... this.
9374 * language.c (language_get_symbol_name_matcher): Ditto.
9375 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
9378 2018-01-10 Pedro Alves <palves@redhat.com>
9382 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
9383 Adjust to use language_get_symbol_name_matcher instead of
9384 language_defn::la_get_symbol_name_matcher.
9385 * language.c (language_get_symbol_name_matcher): If in Ada mode
9386 and the lookup name is a verbatim match, return Ada's matcher.
9387 * language.h (language_get_symbol_name_matcher): Adjust comment.
9388 (ada_lookup_name_info::verbatim_p):: New method.
9390 2018-01-10 Pedro Alves <palves@redhat.com>
9393 * ada-lang.c (ada_collect_symbol_completion_matches): If the
9394 minsym's language is language_auto or language_cplus, pass down
9395 language_ada instead.
9396 * symtab.c (compare_symbol_name): Don't frob symbol language here.
9398 2018-01-10 Pedro Alves <palves@redhat.com>
9401 * minsyms.c (linkage_name_str): New function.
9402 (iterate_over_minimal_symbols): Use it.
9404 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9406 * NEWS: Document that 'info proc' now works on FreeBSD.
9408 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9410 * configure.ac: Check for kinfo_getfile in libutil.
9411 * configure: Regenerate.
9412 * config.in: Regenerate.
9413 * fbsd-nat.c: Include "fbsd-tdep.h".
9414 (fbsd_fetch_cmdline): New.
9415 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
9416 rather than calling error.
9417 (fbsd_info_proc): New.
9418 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
9419 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
9420 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
9422 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9424 * fbsd-nat.c (struct free_deleter): Remove.
9425 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
9427 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9429 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
9430 NULL for an empty pathname.
9432 2018-01-09 John Baldwin <jhb@FreeBSD.org>
9434 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
9435 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
9436 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
9437 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
9438 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
9439 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
9440 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
9441 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
9442 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
9443 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
9444 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
9445 (fbsd_core_fetch_timeval, fbsd_print_sigset)
9446 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
9447 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
9448 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
9450 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
9452 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
9453 (gnu_xfer_auxv): New function.
9454 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
9457 2018-01-08 Yao Qi <yao.qi@linaro.org>
9458 Simon Marchi <simon.marchi@ericsson.com>
9460 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
9462 (COMMON_OBS): Remove selftest.o.
9463 * configure.ac: Append selftest-arch.c and common/selftest.c to
9464 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
9465 * configure: Re-generated.
9466 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
9468 (maintenance_info_selftests): Likewise.
9470 2018-01-08 Xavier Roirand <roirand@adacore.com>
9472 * ada-valprint.c (val_print_packed_array_elements): Use
9473 proper number of elements when printing an array indexed
9474 by an enumeration type.
9476 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9478 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
9479 (dw2_get_file_names_reader): Adjust.
9480 (lookup_dwo_signatured_type): Adjust.
9481 (lookup_dwp_signatured_type): Adjust.
9482 (lookup_signatured_type): Adjust.
9483 (create_type_unit_group): Adjust.
9484 (get_type_unit_group): Adjust.
9485 (process_psymtab_comp_unit_reader): Adjust.
9486 (build_type_psymtabs_reader): Adjust.
9487 (scan_partial_symbols): Adjust.
9488 (add_partial_symbol): Adjust.
9489 (add_partial_subprogram): Adjust.
9490 (peek_die_abbrev): Adjust.
9491 (fixup_go_packaging): Adjust.
9492 (process_imported_unit_die): Adjust.
9493 (dwarf2_compute_name): Adjust.
9494 (dwarf2_physname): Adjust.
9495 (read_import_statement): Adjust.
9496 (handle_DW_AT_stmt_list): Adjust.
9497 (read_file_scope): Adjust.
9498 (read_func_scope): Adjust.
9499 (read_lexical_block_scope): Adjust.
9500 (read_call_site_scope): Adjust.
9501 (read_variable): Adjust.
9502 (dwarf2_rnglists_process): Adjust.
9503 (dwarf2_ranges_process): Adjust.
9504 (dwarf2_ranges_read): Adjust.
9505 (dwarf2_get_pc_bounds): Adjust.
9506 (dwarf2_record_block_ranges): Adjust.
9507 (dwarf2_add_field): Adjust.
9508 (dwarf2_add_member_fn): Adjust.
9509 (read_structure_type): Adjust.
9510 (process_structure_scope): Adjust.
9511 (read_enumeration_type): Adjust.
9512 (read_array_type): Adjust.
9513 (mark_common_block_symbol_computed): Adjust.
9514 (read_common_block): Adjust.
9515 (read_namespace_type): Adjust.
9516 (read_namespace): Adjust.
9517 (read_module_type): Adjust.
9518 (read_tag_pointer_type): Adjust.
9519 (read_tag_ptr_to_member_type): Adjust.
9520 (read_tag_string_type): Adjust.
9521 (read_subroutine_type): Adjust.
9522 (read_typedef): Adjust.
9523 (read_base_type): Adjust.
9524 (attr_to_dynamic_prop): Adjust.
9525 (read_subrange_type): Adjust.
9526 (read_unspecified_type): Adjust.
9527 (dwarf2_read_abbrevs): Adjust.
9528 (load_partial_dies): Adjust.
9529 (read_partial_die): Adjust.
9530 (find_partial_die): Adjust.
9531 (guess_partial_die_structure_name): Adjust.
9532 (fixup_partial_die): Adjust.
9533 (read_attribute_value): Adjust.
9534 (read_addr_index): Adjust.
9535 (read_addr_index_from_leb128): Adjust.
9536 (read_str_index): Adjust.
9537 (dwarf2_string_attr): Adjust.
9538 (get_debug_line_section): Adjust.
9539 (dwarf_decode_line_header): Adjust.
9540 (lnp_state_machine::check_line_address): Adjust.
9541 (dwarf_decode_lines_1): Adjust.
9542 (dwarf_decode_lines): Adjust.
9543 (dwarf2_start_symtab): Adjust.
9544 (var_decode_location): Adjust.
9545 (new_symbol_full): Adjust.
9546 (dwarf2_const_value_data): Adjust.
9547 (dwarf2_const_value_attr): Adjust.
9548 (dwarf2_const_value): Adjust.
9550 (die_containing_type): Adjust.
9551 (build_error_marker_type): Adjust.
9552 (lookup_die_type): Adjust.
9553 (guess_full_die_structure_name): Adjust.
9554 (anonymous_struct_prefix): Adjust.
9555 (determine_prefix): Adjust.
9556 (dwarf2_name): Adjust.
9557 (follow_die_ref_or_sig): Adjust.
9558 (follow_die_offset): Adjust.
9559 (follow_die_ref): Adjust.
9560 (follow_die_sig_1): Adjust.
9561 (follow_die_sig): Adjust.
9562 (get_signatured_type): Adjust.
9563 (get_DW_AT_signature_type): Adjust.
9564 (decode_locdesc): Adjust.
9565 (dwarf_decode_macros): Adjust.
9566 (cu_debug_loc_section): Adjust.
9567 (fill_in_loclist_baton): Adjust.
9568 (dwarf2_symbol_mark_computed): Adjust.
9569 (init_one_comp_unit): Don't assign
9570 dwarf2_cu::dwarf2_per_objfile.
9571 (set_die_type): Adjust.
9573 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9575 * dwarf2read.c (struct mapped_debug_names): Add constructor.
9576 <dwarf2_per_objfile>: New field.
9577 (dwarf2_per_objfile): Remove global.
9578 (get_dwarf2_per_objfile): New function.
9579 (set_dwarf2_per_objfile): New function.
9580 (dwarf2_build_psymtabs_hard): Change objfile parameter to
9582 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9583 (read_abbrev_offset): Likewise.
9584 (read_indirect_string): Likewise.
9585 (read_indirect_line_string): Likewise.
9586 (read_indirect_string_at_offset): Likewise.
9587 (read_indirect_string_from_dwz): Likewise.
9588 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9590 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9591 (create_all_comp_units): Change objfile parameter to
9593 (create_all_type_units): Likewise.
9594 (process_queue): Add dwarf2_per_objfile parameter.
9595 (read_and_check_comp_unit_head): Likewise.
9596 (lookup_dwo_unit_in_dwp): Likewise.
9597 (get_dwp_file): Likewise.
9598 (process_cu_includes): Likewise.
9599 (struct free_dwo_file_cleanup_data): New struct.
9600 (dwarf2_has_info): Use get_dwarf2_per_objfile and
9601 set_dwarf2_per_objfile.
9602 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
9603 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
9604 context, adjust calls.
9605 (dw2_instantiate_symtab): Likewise.
9606 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
9607 (dw2_get_cu): Likewise.
9608 (create_cu_from_index_list): Change objfile parameter to
9610 (create_cus_from_index_list): Get dwarf2_per_objfile from
9611 context, adjust calls.
9612 (create_cus_from_index): Likewise.
9613 (create_signatured_type_table_from_index): Change objfile
9614 parameter to dwarf2_per_objfile.
9615 (create_signatured_type_table_from_debug_names): Change objfile
9616 parameter to dwarf2_per_objfile.
9617 (create_addrmap_from_index): Likewise.
9618 (create_addrmap_from_aranges): Likewise.
9619 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
9620 (dw2_setup): Remove.
9621 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
9623 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
9624 get_dwarf2_per_objfile.
9625 (dw2_forget_cached_source_info): Likewise.
9626 (dw2_map_symtabs_matching_filename): Likewise.
9627 (struct dw2_symtab_iterator) <index>: Remove.
9628 <dwarf2_per_objfile>: New field.
9629 (dw2_symtab_iter_init): Replace index parameter with
9631 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
9632 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
9633 (dw2_print_stats): Likewise.
9634 (dw2_dump): Likewise.
9635 (dw2_expand_symtabs_for_function): Likewise.
9636 (dw2_expand_all_symtabs): Likewise.
9637 (dw2_expand_symtabs_with_fullname): Likewise.
9638 (dw2_expand_marked_cus): Replace index and objfile parameters
9639 with dwarf2_per_objfile.
9640 (dw_expand_symtabs_matching_file_matcher): Add
9641 dwarf2_per_objfile parameter and adjust calls.
9642 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
9644 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
9645 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
9647 (create_cus_from_debug_names_list): Replace objfile parameter
9648 with dwarf2_per_objfile and adjust calls.
9649 (create_cus_from_debug_names): Likewise.
9650 (dwarf2_read_debug_names): Likewise.
9651 (mapped_debug_names::namei_to_name): Adjust call.
9652 (dw2_debug_names_iterator::next): Likewise.
9653 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
9654 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
9655 (dw2_debug_names_dump): Likewise.
9656 (dw2_debug_names_expand_symtabs_for_function): Likewise.
9657 (dw2_debug_names_expand_symtabs_matching): Likewise.
9658 (dwarf2_initialize_objfile): Likewise.
9659 (dwarf2_build_psymtabs): Likewise.
9660 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
9662 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
9663 (read_and_check_comp_unit_head): Likewise.
9664 (read_abbrev_offset): Likewise.
9665 (create_debug_type_hash_table): Likewise.
9666 (create_debug_types_hash_table): Likewise.
9667 (create_all_type_units): Replace objfile parameter with
9669 (add_type_unit): Add dwarf2_per_objfile parameter.
9670 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
9671 with dwarf2_per_objfile.
9672 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
9673 (lookup_dwp_signatured_type): Likewise.
9674 (lookup_signatured_type): Likewise.
9675 (read_cutu_die_from_dwo): Likewise.
9676 (init_tu_and_read_dwo_dies): Likewise.
9677 (init_cutu_and_read_dies): Likewise.
9678 (init_cutu_and_read_dies_no_follow): Likewise.
9679 (allocate_type_unit_groups_table): Add objfile parameter.
9680 (create_type_unit_group): Use dwarf2_per_objfile from cu.
9681 (get_type_unit_group): Likewise.
9682 (process_psymtab_comp_unit): Update call.
9683 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
9684 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
9685 (print_tu_stats): Likewise.
9686 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
9688 (build_type_psymtabs): Change objfile parameter to
9690 (process_skeletonless_type_unit): Use dwarf2_per_objfile
9691 passed in void* parameter.
9692 (process_skeletonless_type_units): Change objfile parameter to
9694 (set_partial_user): Likewise.
9695 (dwarf2_build_psymtabs_hard): Likewise.
9696 (read_comp_units_from_section): Likewise.
9697 (create_all_comp_units): Likewise.
9698 (scan_partial_symbols): Update calls.
9699 (add_partial_symbol): Likewise.
9700 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
9701 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
9702 (process_queue): Add dwarf2_per_objfile parameter.
9703 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
9704 (compute_compunit_symtab_includes): Likewise.
9705 (process_cu_includes): Add dwarf2_per_objfile parameter.
9706 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
9707 (process_full_type_unit): Likewise.
9708 (process_imported_unit_die): Update call.
9709 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
9710 (read_file_scope): Likewise.
9711 (allocate_dwo_file_hash_table): Add objfile parameter.
9712 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
9713 (create_cus_hash_table): Likewise.
9714 (create_dwp_hash_table): Likewise.
9715 (create_dwo_unit_in_dwp_v1): Likewise.
9716 (create_dwp_v2_section): Likewise.
9717 (create_dwo_unit_in_dwp_v2): Likewise.
9718 (lookup_dwo_unit_in_dwp): Likewise.
9719 (try_open_dwop_file): Likewise.
9720 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
9721 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
9722 cleanup to include a reference to dwarf2_per_objfile.
9723 (open_dwp_file): Add dwarf2_per_objfile parameter.
9724 (open_and_init_dwp_file): Likewise.
9725 (get_dwp_file): Likewise.
9726 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
9727 (queue_and_load_all_dwo_tus): Update call.
9728 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
9730 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
9731 (dwarf2_ranges_process): Likewise.
9732 (dwarf2_get_pc_bounds): Likewise.
9733 (mark_common_block_symbol_computed): Likewise.
9734 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
9735 (dwarf2_read_abbrevs): Update call.
9736 (read_partial_die): Use dwarf2_per_objfile from cu.
9737 (find_partial_die): Likewise.
9738 (fixup_partial_die): Likewise.
9739 (read_attribute_value): Likewise.
9740 (read_indirect_string_at_offset_from): Add objfile parameter.
9741 (read_indirect_string_at_offset): Add dwarf2_per_objfile
9743 (read_indirect_string_from_dwz): Add objfile parameter.
9744 (read_indirect_string): Add objfile parameter.
9745 (read_addr_index_1): Add dwarf2_per_objfile parameter.
9746 (read_addr_index): Use dwarf2_per_objfile from cu.
9747 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
9749 (read_str_index): Use dwarf2_per_objfile from cu.
9750 (get_debug_line_section): Likewise.
9751 (read_formatted_entries): Add dwarf2_per_objfile parameter.
9752 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
9753 (new_symbol_full): Use dwarf2_per_objfile from cu.
9754 (build_error_marker_type): Likewise.
9755 (lookup_die_type): Likewise.
9756 (determine_prefix): Likewise.
9757 (follow_die_offset): Likewise.
9758 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
9759 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
9760 (dwarf2_fetch_die_type_sect_off): Likewise.
9761 (dwarf2_get_die_type): Likewise.
9762 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
9763 (get_signatured_type): Likewise.
9764 (get_DW_AT_signature_type): Likewise.
9765 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
9766 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
9767 (cu_debug_loc_section): Likewise.
9768 (fill_in_loclist_baton): Likewise.
9769 (dwarf2_symbol_mark_computed): Likewise.
9770 (dwarf2_find_containing_comp_unit): Change objfile parameter to
9772 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
9774 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
9775 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
9776 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
9777 (set_die_type): Use dwarf2_free_objfile from cu.
9778 (get_die_type_at_offset): Likewise.
9779 (dwarf2_per_objfile_free): Don't assign global variable.
9780 (debug_names) <constructor>: Add dwarf2_per_objfile
9781 parameter, update m_debugstrlookup construction.
9782 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
9784 <m_dwarf2_per_objfile>: New field.
9785 <lookup>: Use m_dwarf2_per_objfile.
9786 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
9787 (psyms_seen_size): Likewise.
9788 (write_gdbindex): Replace objfile parameter with
9790 (write_debug_names): Likewise.
9791 (write_psymtabs_to_index): Likewise.
9792 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
9795 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9797 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
9798 <dwarf2_per_objfile>: New field.
9799 (struct dwarf2_per_cu_data) <objfile>: Remove.
9800 <dwarf2_per_objfile>: New field.
9801 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
9803 (create_signatured_type_table_from_index): Likewise.
9804 (create_debug_type_hash_table): Likewise.
9805 (fill_in_sig_entry_from_dwo_entry): Likewise.
9806 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
9807 (create_type_unit_group): Assign dwarf2_per_objfile instead of
9809 (create_partial_symtab): Access objfile through
9811 (process_psymtab_comp_unit_reader): Likewise.
9812 (read_comp_units_from_section): Likewise.
9813 (scan_partial_symbols): Likewise.
9814 (add_partial_symbol): Likewise.
9815 (add_partial_subprogram): Likewise.
9816 (peek_die_abbrev): Likewise.
9817 (fixup_go_packaging): Likewise.
9818 (process_full_comp_unit): Likewise.
9819 (process_full_type_unit): Likewise.
9820 (process_imported_unit_die): Likewise.
9821 (dwarf2_compute_name): Likewise.
9822 (dwarf2_physname): Likewise.
9823 (read_import_statement): Likewise.
9824 (create_cus_hash_table): Assign dwarf2_physname instead of
9826 (read_func_scope): Access objfile through dwarf2_per_objfile.
9827 (read_lexical_block_scope): Likewise.
9828 (read_call_site_scope): Likewise.
9829 (read_variable): Likewise.
9830 (dwarf2_rnglists_process): Likewise.
9831 (dwarf2_ranges_process): Likewise.
9832 (dwarf2_ranges_read): Likewise.
9833 (dwarf2_record_block_ranges): Likewise.
9834 (dwarf2_add_field): Likewise.
9835 (dwarf2_add_member_fn): Likewise.
9836 (read_structure_type): Likewise.
9837 (process_structure_scope): Likewise.
9838 (read_enumeration_type): Likewise.
9839 (read_array_type): Likewise.
9840 (read_common_block): Likewise.
9841 (read_namespace_type): Likewise.
9842 (read_namespace): Likewise.
9843 (read_module_type): Likewise.
9844 (read_tag_pointer_type): Likewise.
9845 (read_tag_ptr_to_member_type): Likewise.
9846 (read_tag_string_type): Likewise.
9847 (read_subroutine_type): Likewise.
9848 (read_typedef): Likewise.
9849 (read_base_type): Likewise.
9850 (attr_to_dynamic_prop): Likewise.
9851 (read_subrange_type): Likewise.
9852 (read_unspecified_type): Likewise.
9853 (load_partial_dies): Likewise.
9854 (read_partial_die): Likewise.
9855 (find_partial_die): Likewise.
9856 (guess_partial_die_structure_name): Likewise.
9857 (fixup_partial_die): Likewise.
9858 (read_attribute_value): Likewise.
9859 (read_addr_index_from_leb128): Likewise.
9860 (dwarf2_read_addr_index): Likewise.
9861 (dwarf2_string_attr): Likewise.
9862 (lnp_state_machine::check_line_address): Likewise.
9863 (dwarf_decode_lines_1): Likewise.
9864 (dwarf_decode_lines): Likewise.
9865 (dwarf2_start_symtab): Likewise.
9866 (var_decode_location): Likewise.
9867 (new_symbol_full): Likewise.
9868 (dwarf2_const_value_data): Likewise.
9869 (dwarf2_const_value_attr): Likewise.
9870 (dwarf2_const_value): Likewise.
9871 (die_type): Likewise.
9872 (die_containing_type): Likewise.
9873 (lookup_die_type): Likewise.
9874 (guess_full_die_structure_name): Likewise.
9875 (anonymous_struct_prefix): Likewise.
9876 (dwarf2_name): Likewise.
9877 (follow_die_ref_or_sig): Likewise.
9878 (follow_die_offset): Likewise.
9879 (follow_die_ref): Likewise.
9880 (dwarf2_fetch_die_loc_sect_off): Likewise.
9881 (dwarf2_fetch_constant_bytes): Likewise.
9882 (dwarf2_fetch_die_type_sect_off): Likewise.
9883 (dwarf2_get_die_type): Likewise.
9884 (follow_die_sig): Likewise.
9885 (decode_locdesc): Likewise.
9886 (dwarf2_per_cu_objfile): Likewise.
9887 (dwarf2_per_cu_text_offset): Likewise.
9888 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
9890 (set_die_type): Access objfile through
9893 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
9895 * valprint.c (converted_character_d): Remove typedef.
9896 (DEF_VEC_O (converted_character_d)): Remove.
9897 (count_next_character): Use std::vector.
9898 (print_converted_chars_to_obstack): Likewise.
9899 (generic_printstr): Likewise.
9901 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9903 * xml-support.h (struct gdb_xml_value): Add constructor.
9904 <value>: Change type to unique_xmalloc_ptr.
9905 (gdb_xml_value_s): Remove typedef.
9906 (DEF_VEC_O (gdb_xml_value_s)): Remove.
9907 (gdb_xml_element_start_handler): Change parameter type to
9909 (xml_find_attribute): Likewise.
9910 * xml-support.c (xml_find_attribute): Change parameter type to
9911 std::vector and adjust.
9912 (gdb_xml_values_cleanup): Remove.
9913 (gdb_xml_parser::start_element): Adjust to std::vector.
9914 (xinclude_start_include): Change paraeter type to std::vector
9916 * btrace.c (check_xml_btrace_version): Likewise.
9917 (parse_xml_btrace_block): Likewise.
9918 (parse_xml_btrace_pt_config_cpu): Likewise.
9919 (parse_xml_btrace_pt): Likewise.
9920 (parse_xml_btrace_conf_bts): Likewise.
9921 (parse_xml_btrace_conf_pt): Likewise.
9922 * memory-map.c (memory_map_start_memory): Likewise.
9923 (memory_map_start_property): Likewise.
9924 * osdata.c (osdata_start_osdata): Likewise.
9925 (osdata_start_item): Likewise.
9926 (osdata_start_column): Likewise.
9927 * remote.c (start_thread): Likewise.
9928 * solib-aix.c (library_list_start_library): Likewise.
9929 (library_list_start_list): Likewise.
9930 * solib-svr4.c (library_list_start_library): Likewise.
9931 (svr4_library_list_start_list): Likewise.
9932 * solib-target.c (library_list_start_segment): Likewise.
9933 (library_list_start_section): Likewise.
9934 (library_list_start_library): Likewise.
9935 (library_list_start_list): Likewise.
9936 * tracepoint.c (traceframe_info_start_memory): Likewise.
9937 (traceframe_info_start_tvar): Likewise.
9938 * xml-syscall.c (syscall_start_syscall): Likewise.
9939 * xml-tdesc.c (tdesc_start_target): Likewise.
9940 (tdesc_start_feature): Likewise.
9941 (tdesc_start_reg): Likewise.
9942 (tdesc_start_union): Likewise.
9943 (tdesc_start_struct): Likewise.
9944 (tdesc_start_flags): Likewise.
9945 (tdesc_start_enum): Likewise.
9946 (tdesc_start_field): Likewise.
9947 (tdesc_start_enum_value): Likewise.
9948 (tdesc_start_vector): Likewise.
9950 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9952 * extension.h (struct xmethod_worker) <clone>: Remove.
9953 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
9955 (python_xmethod_worker::clone): Remove.
9956 * valops.c (find_overload_match): Use std::move instead of
9959 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9961 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
9962 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
9963 <free_xmethod_worker_data>: Remove.
9964 <get_matching_xmethod_workers>: Chance VEC to std::vector.
9965 <get_xmethod_arg_types>: Remove.
9966 <get_xmethod_result_type>: Remove.
9967 <invoke_xmethod>: Remove.
9968 * extension.c (new_xmethod_worker): Remove.
9969 (clone_xmethod_worker): Remove.
9970 (get_matching_xmethod_workers): Return void, pass std::vector by
9972 (get_xmethod_arg_types): Rename to...
9973 (xmethod_worker::get_arg_types): ... this, and adjust.
9974 (get_xmethod_result_type): Rename to...
9975 (xmethod_worker::get_result_type): ... this, and adjust.
9976 (invoke_xmethod): Remove.
9977 (free_xmethod_worker): Remove.
9978 (free_xmethod_worker_vec): Remove.
9979 * extension.h (enum ext_lang_rc): Move here from
9981 (struct xmethod_worker): Add constructor and destructor.
9984 <invoke, clone, do_get_result_type, do_get_arg_types>: New
9985 virtual pure methods.
9986 <get_arg_types, get_result_type>: New methods.
9987 (xmethod_worker_ptr): Remove typedef.
9988 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
9989 (xmethod_worker_vec): Remove typedef.
9990 (xmethod_worker_up): New typedef.
9991 (invoke_xmethod): Remove.
9992 (clone_xmethod_worker): Remove.
9993 (free_xmethod_worker): Remove.
9994 (free_xmethod_worker_vec): Remove.
9995 (get_xmethod_arg_types): Remove.
9996 (get_xmethod_result_type): Remove.
9997 * valops.c (find_method_list): Use std::vector, don't use
9998 intermediate vector.
9999 (value_find_oload_method_list): Use std::vector.
10000 (find_overload_match): Use std::vector.
10001 (find_oload_champ): Use std::vector.
10002 * value.c (value_free): Use operator delete.
10003 (value_of_xmethod): Rename to...
10004 (value_from_xmethod): ... this. Don't assign
10005 xmethod_worker::value, take rvalue-reference.
10006 (result_type_of_xmethod): Adjust.
10007 (call_xmethod): Adjust.
10008 * value.h: Include extension.h.
10009 (struct xmethod_worker): Don't forward-declare.
10010 (value_of_xmethod): Rename to...
10011 (value_from_xmethod): ... this, take rvalue-reference.
10012 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
10013 (struct python_xmethod_worker): ... this, add constructor and
10015 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
10016 (gdbpy_free_xmethod_worker_data): Rename to...
10017 (python_xmethod_worker::~python_xmethod_worker): ... this and
10019 (gdbpy_clone_xmethod_worker_data): Rename to...
10020 (python_xmethod_worker::clone): ... this and adjust.
10021 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
10023 (gdbpy_get_xmethod_arg_types): Rename to...
10024 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
10025 (gdbpy_get_xmethod_result_type): Rename to...
10026 (python_xmethod_worker::do_get_result_type): ... this and
10028 (gdbpy_invoke_xmethod): Rename to...
10029 (python_xmethod_worker::invoke): ... this and adjust.
10030 (new_python_xmethod_worker): Rename to...
10031 (python_xmethod_worker::python_xmethod_worker): ... this and
10033 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
10035 (gdbpy_free_xmethod_worker_data): Remove.
10036 (gdbpy_get_matching_xmethod_workers): Use std::vector.
10037 (gdbpy_get_xmethod_arg_types): Remove.
10038 (gdbpy_get_xmethod_result_type): Remove.
10039 (gdbpy_invoke_xmethod): Remove.
10040 * python/python.c (python_extension_ops): Remove obsolete
10043 2018-01-05 Pedro Alves <palves@redhat.com>
10046 * common/signals-state-save-restore.c
10047 (save_original_signals_state): New parameter 'quiet'. Warn if we
10048 find a custom handler preinstalled, instead of internal erroring.
10049 But only warn if !quiet.
10050 * common/signals-state-save-restore.h
10051 (save_original_signals_state): New parameter 'quiet'.
10052 * main.c (captured_main_1): Move save_original_signals_state call
10053 after option handling, and pass QUIET.
10055 2018-01-05 Pedro Alves <palves@redhat.com>
10057 * spu-tdep.c (spu_catch_start): Pass
10058 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
10060 2018-01-05 Pedro Alves <palves@redhat.com>
10063 * ada-lang.c (literal_symbol_name_matcher): New function.
10064 (ada_get_symbol_name_matcher): Use it for
10065 symbol_name_match_type::SEARCH_NAME.
10066 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
10067 it down instead of assuming symbol_name_match_type::FULL.
10068 * block.h (block_lookup_symbol): New parameter 'match_type'.
10069 * c-valprint.c (print_unpacked_pointer): Use
10070 lookup_symbol_search_name instead of lookup_symbol.
10071 * compile/compile-object-load.c (get_out_value_type): Pass down
10072 symbol_name_match_type::SEARCH_NAME.
10073 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
10074 symbol_name_match_type::FULL.
10075 * cp-support.c (cp_get_symbol_name_matcher): Handle
10076 symbol_name_match_type::SEARCH_NAME.
10077 * infrun.c (insert_exception_resume_breakpoint): Use
10078 lookup_symbol_search_name.
10079 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
10080 * psymtab.c (maintenance_check_psymtabs): Use
10081 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
10082 * stack.c (print_frame_args): Use lookup_symbol_search_name and
10083 SYMBOL_SEARCH_NAME.
10084 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
10085 if symbol_name_match_type::SEARCH_NAME.
10086 (lookup_symbol_in_language): Pass down
10087 symbol_name_match_type::FULL.
10088 (lookup_symbol_search_name): New.
10089 (lookup_language_this): Pass down
10090 symbol_name_match_type::SEARCH_NAME.
10091 (lookup_symbol_aux, lookup_local_symbol): New parameter
10092 'match_type'. Pass it down.
10093 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
10094 (lookup_symbol_search_name): New declaration.
10095 (lookup_symbol_in_block): New 'match_type' parameter.
10097 2018-01-05 Pedro Alves <palves@redhat.com>
10100 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
10102 (ada_lookup_symbol): Reimplement in terms of
10103 ada_lookup_symbol_list, bits factored out from
10104 ada_lookup_encoded_symbol.
10106 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10108 * ada-exp.y (write_object_renaming): When subscripting an array
10109 using a symbol as the index, pass the block in call to
10110 ada_lookup_encoded_symbol when looking that symbol up.
10112 2018-01-05 Jerome Guitton <guitton@adacore.com>
10114 * ada-lang.c (ada_array_length): Use ada_index_type instead of
10117 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10119 * ada-lang.c (ada_to_fixed_value_create): Add handling of
10120 the case where VALUE_LVAL (val0) is not lval_memory.
10122 2018-01-05 Xavier Roirand <roirand@adacore.com>
10124 * ada-valprint.c (print_optional_low_bound): Handle
10125 character-indexed array printing like boolean-indexed array
10128 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10130 * NEWS: Create a new section for the next release branch.
10131 Rename the section of the current branch, now that it has
10134 2018-01-05 Joel Brobecker <brobecker@adacore.com>
10136 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
10137 * version.in: Bump version to 8.1.50.DATE-git.
10139 2018-01-03 Xavier Roirand <roirand@adacore.com>
10141 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
10143 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
10145 (default_exception_support_info) <catch_handlers_sym>: Add field.
10146 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
10147 (ada_exception_name_addr_1): Add "catch handlers" handling.
10148 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
10149 Update all callers.
10150 (create_excep_cond_exprs) <ex>: Add parameter.
10151 (re_set_exception): Update create_excep_cond_exprs call.
10152 (print_it_exception, print_one_exception, print_mention_exception)
10153 (print_recreate_exception): Add "catch handler" handling.
10154 (allocate_location_catch_handlers, re_set_catch_handlers)
10155 (check_status_catch_handlers, print_it_catch_handlers)
10156 (print_one_catch_handlers, print_mention_catch_handlers)
10157 (print_recreate_catch_handlers): New function.
10158 (catch_handlers_breakpoint_ops): New variable.
10159 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
10160 Add parameter. Add "catch handler" handling.
10161 (ada_exception_sym_name, ada_exception_breakpoint_ops):
10162 Add "catch handler" handling.
10163 (ada_exception_catchpoint_cond_string): Add "catch handler"
10165 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
10167 (catch_ada_handlers_command): New function.
10168 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
10169 operations structure.
10170 (_initialize_ada_language): Add "catch handlers" command entry.
10171 * NEWS: Document "catch handlers" feature.
10173 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10175 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
10176 account when creating the array type of the slice.
10177 (ada_value_slice): Likewise.
10179 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10181 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
10183 (create_array_type_with_stride): Add byte_stride_prop parameter.
10184 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
10185 New parameter. Update all callers in this file.
10186 (array_type_has_dynamic_stride): New function.
10187 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
10188 of arrays with dynamic byte strides.
10189 * dwarf2read.c (read_array_type): Add support for dynamic
10190 DW_AT_byte_stride attributes.
10192 2018-01-02 Joel Brobecker <brobecker@adacore.com>
10194 * dwarf2read.c (read_unspecified_type): Treat
10195 DW_TAG_enumeration_type DIEs from Ada units as stubs.
10197 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10199 Update copyright year range in all GDB files.
10201 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10203 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
10204 and gdb/testsuite/gdb.base/step-line.c.
10206 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10208 * copyright.py (main): Dump the contents of
10209 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
10210 even if BY_HAND is empty.
10212 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10214 * top.c (print_gdb_version): Update Copyright year in version
10217 2018-01-01 Joel Brobecker <brobecker@adacore.com>
10219 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
10221 For older changes see ChangeLog-2017.
10227 version-control: never