1 2018-11-04 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3 * source.c (open_source_file): Fix leak by transferring the
4 current s->fullname to the unique_xmalloc_ptr fullname given
5 to find_and_open_source.
7 2018-11-04 Tom Tromey <tom@tromey.com>
9 * varobj.c (install_default_visualizer): Update.
10 * python/python-internal.h (gdbpy_get_varobj_pretty_printer):
12 * python/py-prettyprint.c (search_pp_list): Return gdbpy_ref.
13 (find_pretty_printer_from_progspace)
14 (find_pretty_printer_from_gdb, find_pretty_printer)
15 (gdbpy_get_varobj_pretty_printer): Return gdbpy_ref.
16 (gdbpy_get_varobj_pretty_printer, gdbpy_default_visualizer):
19 2018-11-04 Tom Tromey <tom@tromey.com>
21 * python/python.c (gdbpy_parameter_value): Update.
22 * python/python-internal.h (python_string_to_unicode)
23 (python_string_to_target_python_string)
24 (host_string_to_python_string): Return gdbpy_ref.
25 * python/py-utils.c (python_string_to_unicode)
26 (unicode_to_encoded_python_string)
27 (unicode_to_target_python_string)
28 (python_string_to_target_string)
29 (python_string_to_target_python_string): Return gdbpy_ref.
30 (python_string_to_host_string): Update.
31 (host_string_to_python_string): Return gdbpy_ref.
32 * python/py-symtab.c (stpy_get_filename, stpy_get_producer)
33 (stpy_fullname): Update.
34 * python/py-progspace.c (pspy_get_filename, pspy_solib_name):
36 * python/py-prettyprint.c (print_string_repr): Update.
37 * python/py-objfile.c (objfpy_get_filename, objfpy_get_username)
38 (objfpy_get_build_id): Update.
39 * python/py-breakpoint.c (bppy_get_location)
40 (bppy_get_expression, bppy_get_condition, bppy_get_commands):
43 2018-11-04 Tom Tromey <tom@tromey.com>
45 * python/python-internal.h (gdb_py_object_from_longest)
46 (gdb_py_object_from_ulongest): Return gdbpy_ref.
47 * python/py-value.c (valpy_int): Update.
48 * python/py-utils.c (gdb_py_object_from_longest): Return
50 (gdb_py_object_from_ulongest): Likewise.
51 * python/py-type.c (typy_get_alignof): Update.
52 * python/py-linetable.c (ltpy_get_all_source_lines)
53 (ltpy_entry_get_line, ltpy_entry_get_pc): Update.
54 * python/py-block.c (blpy_get_start, blpy_get_end): Update.
56 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
58 * ada-lang.c (_initialize_ada_language): Fix typo.
60 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
62 * language.c (type): Remove.
63 (_initialize_language): Remove assignment to type.
65 2018-11-02 Joel Brobecker <brobecker@adacore.com>
67 * aarch64-ravenscar-thread.h, aarch64-ravenscar-thread.c: New files.
68 * aarch64-tdep.c: #include "aarch64-ravenscar-thread.h".
69 (aarch64_gdbarch_init): Add call to register_aarch64_ravenscar_ops.
70 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-ravenscar-thread.o.
71 (HFILES_NO_SRCDIR): Add aarch64-ravenscar-thread.h.
72 (ALLDEPFILES): Add aarch64-ravenscar-thread.c.
73 * configure.tgt (cpu_obs) [aarch64*-*-*]: Add ravenscar-thread.o
74 and aarch64-ravenscar-thread.o.
75 * NEWS: Add entry documenting Ravenscar tasking support
78 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
80 * symtab.c (info_functions_command): Initialize quiet flag.
81 * stack.c (info_args_command): Likewise.
83 2018-11-01 Jim Wilson <jimw@sifive.com>
85 * riscv-tdep.c (riscv_breakpoint_kind_from_pc): New local unaligned_p.
86 Set if pcptr if unaligned. Return 2 if unaligned_p true. Update
89 2018-11-01 Joel Brobecker <brobecker@adacore.com>
91 * ada-lang.c (ada_watch_location_expression): New function.
92 (ada_language_defn): Set la_watch_location_expression to
93 ada_watch_location_expression.
95 2018-11-01 Joel Brobecker <brobecker@adacore.com>
97 * print-utils.c (int_string): Remove unnecessary trailing spaces.
99 2018-11-01 Joel Brobecker <brobecker@adacore.com>
101 * rs6000-tdep.c (skip_prologue): Fix potential negative left
104 2018-11-01 Jerome Guitton <guitton@adacore.com>
105 Joel Brobecker <brobecker@adacore.com>
107 * defs.h (enum gdb_osabi): Add GDB_OSABI_PIKEOS.
108 * osabi.c (gdb_osabi_names): Add name for GDB_OSABI_PIKEOS.
109 * arm-pikeos-tdep.c: New file.
110 * configure.tgt: Add arm-pikeos-tdep.o to the case of ARM
112 * Makefile.in (ALL_TARGET_OBS): Add arm-pikeos-tdep.o.
114 2018-11-01 Simon Marchi <simon.marchi@ericsson.com>
116 * common/pathstuff.c (get_standard_temp_dir): New.
117 * common/pathstuff.h (get_standard_temp_dir): New.
118 * config.in: Re-generate.
119 * configure: Re-generate.
120 * configure.ac: Don't check for mkdtemp.
121 * gnulib/aclocal-m4-deps.mk: Re-generate.
122 * gnulib/aclocal.m4: Re-generate.
123 * gnulib/config.in: Re-generate.
124 * gnulib/configure: Re-generate.
125 * gnulib/import/Makefile.am: Re-generate.
126 * gnulib/import/Makefile.in: Re-generate.
127 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
128 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
129 * gnulib/import/m4/mkdtemp.m4: New file.
130 * gnulib/import/mkdtemp.c: New file.
131 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES):
133 * unittests/mkdir-recursive-selftests.c (test): Use
134 get_standard_temp_dir.
135 (_initialize_mkdir_recursive_selftests): Remove HAVE_MKDTEMP
137 * compile/compile.c (get_compile_file_tempdir): Likewise.
139 2018-11-01 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
141 * rs6000-aix-tdep.c: Include "trad-frame.h" and "frame-unwind.h".
142 (SIG_FRAME_LR_OFFSET64): New define.
143 (SIG_FRAME_FP_OFFSET64): New define.
144 (aix_sighandle_frame_cache): New Function.
145 (aix_sighandle_frame_this_id): New Function.
146 (aix_sighandle_frame_prev_register): New Function.
147 (aix_sighandle_frame_sniffer): New Function.
148 (aix_sighandle_frame_unwind): New global variable.
149 (rs6000_aix_init_osabi): Install new frame unwinder.
151 2018-10-31 Sergio Durigan Junior <sergiodj@redhat.com>
154 * common/common-defs.h: Don't redefine _FORTIFY_SOURCE if it's
157 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
159 * ppc-linux-nat.c: Include nat/linux-ptrace.h.
161 2018-10-31 Andrew Burgess <andrew.burgess@embecosm.com>
163 * dwarf2read.c (struct dwarf2_cu): Add producer_is_icc field.
164 (producer_is_icc): New function.
165 (check_producer): Set producer_is_icc field on dwarf2_cu.
166 (dwarf2_init_integer_type): New function.
167 (read_base_type): Call dwarf2_init_integer_type instead of
168 init_integer_type in all cases.
169 (dwarf2_cu::dwarf2_cu): Initialise producer_is_icc field.
170 * valprint.c (maybe_negate_by_bytes): Add an assertion that the
171 LEN is greater than 0.
173 2018-10-30 Tom Tromey <tom@tromey.com>
175 * main.c (captured_main_1): Check return value of bfd_init.
177 2018-10-29 Sergio Durigan Junior <sergiodj@redhat.com>
179 * common/offset-type.h (DEFINE_OFFSET_REL_OP): Delete.
182 2018-10-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
184 * procfs.c: Include common/pathstuff.h.
186 2018-10-28 Andrew Burgess <andrew.burgess@embecosm.com>
188 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
189 Add missing braces. No functional change.
191 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
193 * macrocmd.c (info_macro_command): Use report_unrecognized_option_error
194 to report a bad option and fix indentation.
195 * demangle.c (demangle_command): Use report_unrecognized_option_error
196 to report a bad option and correctly report the bad option.
198 2018-10-27 Tom Tromey <tom@tromey.com>
201 * darwin-nat.c (copied_shell): New global.
202 (may_have_sip): Rename from should_disable_startup_with_shell.
203 (copy_shell_to_cache, maybe_cache_shell): New functions.
204 (darwin_nat_target::create_inferior): Update. Use
207 2018-10-27 Tom Tromey <tom@tromey.com>
209 * unittests/scoped_fd-selftests.c (test_to_file): New function.
210 (run_tests): Call test_to_file.
211 * dwarf-index-write.c (write_psymtabs_to_index): Do not reopen
213 * common/scoped_fd.h (scoped_fd::to_file): New method.
215 2018-10-27 Tom Tromey <tom@tromey.com>
217 * unittests/scoped_mmap-selftests.c (test_normal): Use
218 gdb_mkostemp_cloexec.
219 * unittests/scoped_fd-selftests.c (test_destroy, test_release):
220 Use gdb_mkostemp_cloexec.
221 * gnulib/aclocal-m4-deps.mk, gnulib/aclocal.m4,
222 gnulib/config.in, gnulib/configure,
223 gnulib/import/Makefile.am, gnulib/import/Makefile.in,
224 gnulib/import/m4/gnulib-cache.m4,
225 gnulib/import/m4/gnulib-comp.m4: Update.
226 * gnulib/import/m4/mkostemp.m4: New file.
227 * gnulib/import/m4/mkstemp.m4: Remove.
228 * gnulib/import/mkostemp.c: New file.
229 * gnulib/import/mkstemp.m4: Remove.
230 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Remove
231 mkstemp, add mkostemp. Apply new patch.
232 * gnulib/import/stdlib.in.h: Apply patch.
233 * gnulib/patches/0002-mkostemp-mkostemps-Fix-compilation-error-in-C-mode-o.patch:
235 * dwarf-index-write.c (write_psymtabs_to_index): Use
236 gdb_mkostemp_cloexec.
237 * common/filestuff.h (gdb_mkostemp_cloexec): New function.
239 2018-10-27 Tom Tromey <tom@tromey.com>
241 * unittests/mkdir-recursive-selftests.c: New file.
242 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
243 unittests/mkdir-recursive-selftests.c.
244 * dwarf-index-cache.c (mkdir_recursive): Move to
246 (index_cache::store): Check return value of mkdir_recursive.
247 (create_dir_and_check, test_mkdir_recursive): Move to new file.
248 (_initialize_index_cache): Don't register test.
249 * common/filestuff.h (mkdir_recursive): Declare.
250 * common/filestuff.c (mkdir_recursive): Move from
251 dwarf-index-cache.c. Return bool.
253 2018-10-27 Tom Tromey <tom@tromey.com>
255 * dwarf-index-write.c (write_psymtabs_to_index): Move
256 make_temp_filename to common/pathstuff.c.
257 * common/pathstuff.h (make_temp_filename): Declare.
258 * common/pathstuff.c (make_temp_filename): New function, moved
259 from dwarf-index-write.c.
261 2018-10-27 Tom Tromey <tom@tromey.com>
263 * procfs.c (procfs_target::create_inferior): Use get_shell.
264 * cli/cli-cmds.c (shell_escape): Use get_shell.
265 * windows-nat.c (windows_nat_target::create_inferior): Use
267 * common/pathstuff.c (get_shell): New function.
268 * nat/fork-inferior.c (SHELL_FILE, get_startup_shell): Remove.
269 (fork_inferior): Use get_shell.
270 * common/pathstuff.h (get_shell): Declare.
272 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
274 * NEWS: Mention changes to 'info [args|functions|locals|variables]'
276 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
278 * stack.c (print_variable_and_value_data): Add preg and treg.
279 (print_frame_local_vars): Add quiet, regexp and t_regexp arguments,
281 (print_frame_arg_vars): Likewise.
282 (prepare_reg): New function.
283 (info_locals_command): Extract info print args and use them.
284 (info_args_command): Likewise.
285 (_initialize_stack): Modify on-line help.
286 * symtab.c (treg_matches_sym_type_name): New function.
287 (search_symbols): New arg t_regexp.
288 (symtab_symbol_info): New args quiet, regexp, t_regexp.
289 (info_variables_command): Extract info print args and use them.
290 (info_functions_command): Likewise.
291 (info_types_command): Update call to symtab_symbol_info.
292 (_initialize_symtab): Modify on-line help.
293 * symtab.h (treg_matches_sym_type_name): New function.
294 (search_symbols): New t_regexp arg.
296 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
298 * cli-utils.c (extract_arg_maybe_quoted): New function.
299 (extract_info_print_args): New function.
300 (info_print_args_help): New function.
301 (report_unrecognized_option_error): New function.
302 * cli-utils.h (extract_arg_maybe_quoted): New function.
303 (extract_info_print_args): New function.
304 (info_print_args_help): New function.
305 (report_unrecognized_option_error): New function.
307 2018-10-26 Tom Tromey <tom@tromey.com>
309 * dwarf2read.c (recursively_compute_inclusions): Use std::vector.
310 (compute_compunit_symtab_includes): Update.
311 * symtab.h: (symtab_ptr): Remove typedef. Don't define a VEC.
312 (compunit_symtab_ptr): Likewise.
314 2018-10-26 John Baldwin <jhb@FreeBSD.org>
316 * fbsd-tdep.c (fbsd_print_auxv_entry): Only use
317 default_print_auxv_entry for specific tag values.
319 2018-10-26 John Baldwin <jhb@FreeBSD.org>
321 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_HWCAP2.
323 2018-10-26 Jim Wilson <jimw@sifive.com>
325 * riscv-linux-tdep.c: Include tramp-frame.h and trad-frame.h.
326 (riscv_linux_sigframe_init): Declare.
327 (RISCV_INST_LI_A7_SIGRETURN, RISCV_INT_ECALL): New.
328 (riscv_linux_sigframe): New.
329 (SIGFRAME_SIGINFO_SIZE, UCONTEXT_MCONTEXT_OFFSET): New.
330 (riscv_linux_sigframe_init): Define.
331 (riscv_linux_init_abi): Call tramp_frame_prepend_unwinder.
333 * riscv-tdep.c (riscv_isa_xlen): Refer to riscv-tdep.h comment.
334 (riscv_isa_flen): Likewise. Drop static.
335 * riscv-tdep.h (riscv_isa_xlen): Move riscv-tdep.c comment to here.
336 (riscv_isa_flen): Likewise. Declare.
338 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
339 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
341 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_htm_vsx32l)
342 (tdesc_powerpc_isa207_htm_vsx64l): Declare.
343 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TM_SPRREGSET)
344 (PPC32_LINUX_SIZEOF_CGPRREGSET, PPC64_LINUX_SIZEOF_CGPRREGSET)
345 (PPC_LINUX_SIZEOF_CFPRREGSET, PPC_LINUX_SIZEOF_CVMXREGSET)
346 (PPC_LINUX_SIZEOF_CVSXREGSET, PPC_LINUX_SIZEOF_CPPRREGSET)
347 (PPC_LINUX_SIZEOF_CDSCRREGSET, PPC_LINUX_SIZEOF_CTARREGSET):
349 (struct ppc_linux_features) <htm>: New field.
350 (ppc_linux_no_features): Add initializer for htm field.
351 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
353 * nat/ppc-linux.h (PPC_FEATURE2_HTM, NT_PPC_TM_CGPR)
354 (NT_PPC_TM_CFPR, NT_PPC_TM_CVMX, NT_PPC_TM_CVSX)
355 (NT_PPC_TM_SPR, NT_PPC_TM_CTAR, NT_PPC_TM_CPPR, NT_PPC_TM_CDSCR):
356 Define if not already defined.
357 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-htm-vsx32l
358 and rs6000/powerpc-isa207-htm-vsx64l.
359 (XMLTOC): Add rs6000/powerpc-isa207-htm-vsx32l.xml and
360 rs6000/powerpc-isa207-htm-vsx64l.xml.
361 * features/rs6000/power-htm-spr.xml: New file.
362 * features/rs6000/power-htm-core.xml: New file.
363 * features/rs6000/power64-htm-core.xml: New file.
364 * features/rs6000/power-htm-fpu.xml: New file.
365 * features/rs6000/power-htm-altivec.xml: New file.
366 * features/rs6000/power-htm-vsx.xml: New file.
367 * features/rs6000/power-htm-ppr.xml: New file.
368 * features/rs6000/power-htm-dscr.xml: New file.
369 * features/rs6000/power-htm-tar.xml: New file.
370 * features/rs6000/powerpc-isa207-htm-vsx32l.xml: New file.
371 * features/rs6000/powerpc-isa207-htm-vsx64l.xml: New file.
372 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Generate.
373 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Generate.
374 * regformats/rs6000/powerpc-isa207-htm-vsx32l.dat: Generate.
375 * regformats/rs6000/powerpc-isa207-htm-vsx64l.dat: Generate.
376 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
377 fetch_regset with HTM regsets.
378 (store_register, store_ppc_registers): Call store_regset with HTM
380 (ppc_linux_nat_target::read_description): Set htm field in the
381 features struct if needed.
382 * ppc-linux-tdep.c: Include
383 features/rs6000/powerpc-isa207-htm-vsx32l.c and
384 features/rs6000/powerpc-isa207-htm-vsx64l.c.
385 (ppc32_regmap_tm_spr, ppc32_regmap_cgpr, ppc64_le_regmap_cgpr)
386 (ppc64_be_regmap_cgpr, ppc32_regmap_cfpr, ppc32_le_regmap_cvmx)
387 (ppc32_be_regmap_cvmx, ppc32_regmap_cvsx, ppc32_regmap_cppr)
388 (ppc32_regmap_cdscr, ppc32_regmap_ctar): New globals.
389 (ppc32_linux_tm_sprregset, ppc32_linux_cgprregset)
390 (ppc64_be_linux_cgprregset, ppc64_le_linux_cgprregset)
391 (ppc32_linux_cfprregset, ppc32_le_linux_cvmxregset)
392 (ppc32_be_linux_cvmxregset, ppc32_linux_cvsxregset)
393 (ppc32_linux_cpprregset, ppc32_linux_cdscrregset)
394 (ppc32_linux_ctarregset): New globals.
395 (ppc_linux_cgprregset, ppc_linux_cvmxregset): New functions.
396 (ppc_linux_collect_core_cpgrregset): New function.
397 (ppc_linux_iterate_over_regset_sections): Call back with the htm
399 (ppc_linux_core_read_description): Check if the tm spr section is
400 present and set htm in the features struct.
401 (_initialize_ppc_linux_tdep): Call
402 initialize_tdesc_powerpc_isa207_htm_vsx32l and
403 initialize_tdesc_powerpc_isa207_htm_vsx64l.
404 * ppc-linux-tdep.h (ppc_linux_cgprregset, ppc_linux_cvmxregset):
406 (ppc32_linux_tm_sprregset, ppc32_linux_cfprregset)
407 (ppc32_linux_cvsxregset, ppc32_linux_cpprregset)
408 (ppc32_linux_cdscrregset, ppc32_linux_ctarregset): Declare.
409 * ppc-tdep.h (struct gdbarch_tdep) <have_htm_spr, have_htm_core>:
411 <have_htm_fpu, have_htm_altivec, have_htm_vsx>:
413 <ppc_cppr_regnum, ppc_cdscr_regnum, ppc_ctar_regnum>: Likewise.
414 <ppc_cdl0_regnum, ppc_cvsr0_regnum, ppc_cefpr0_regnum>: Likewise.
415 (enum) <PPC_TFHAR_REGNUM, PPC_TEXASR_REGNUM, PPC_TFIAR_REGNUM>:
417 <PPC_CR0_REGNUM, PPC_CCR_REGNUM, PPC_CXER_REGNUM>: Likewise.
418 <PPC_CLR_REGNUM, PPC_CCTR_REGNUM, PPC_CF0_REGNUM>: Likewise.
419 <PPC_CFPSCR_REGNUM, PPC_CVR0_REGNUM, PPC_CVSCR_REGNUM>: Likewise.
420 <PPC_CVRSAVE_REGNUM, PPC_CVSR0_UPPER_REGNUM>: Likewise.
421 <PPC_CPPR_REGNUM, PPC_CDSCR_REGNUM>: Likewise.
422 <PPC_CTAR_REGNUM>: Likewise.
423 (PPC_IS_TMSPR_REGNUM, PPC_IS_CKPTGP_REGNUM, PPC_IS_CKPTFP_REGNUM)
424 (PPC_IS_CKPTVMX_REGNUM, PPC_IS_CKPTVSX_REGNUM): Define.
425 * rs6000-tdep.c (IS_CDFP_PSEUDOREG, IS_CVSX_PSEUDOREG)
426 (IS_CEFP_PSEUDOREG): Define.
427 (rs6000_register_name): Hide the upper halves of checkpointed VSX
428 registers. Return names for the checkpointed DFP, VSX, and EFP
430 (rs6000_pseudo_register_type): Remove initial assert and raise an
431 internal error in the else clause instead. Return types for the
432 checkpointed DFP, VSX, and EFP pseudo registers.
433 (dfp_pseudo_register_read, dfp_pseudo_register_write): Handle
434 checkpointed DFP pseudo registers.
435 (vsx_pseudo_register_read, vsx_pseudo_register_write): Handle
436 checkpointed VSX pseudo registers.
437 (efp_pseudo_register_read, efp_pseudo_register_write): Rename
438 from efpr_pseudo_register_read and
439 efpr_pseudo_register_write. Handle checkpointed EFP pseudo
441 (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
442 Handle checkpointed DFP, VSX, and EFP registers.
443 (dfp_ax_pseudo_register_collect, vsx_ax_pseudo_register_collect)
444 (efp_ax_pseudo_register_collect): New functions.
445 (rs6000_ax_pseudo_register_collect): Move DFP, VSX and EFP pseudo
446 register logic to new functions. Handle checkpointed DFP, VSX,
447 and EFP pseudo registers.
448 (rs6000_gdbarch_init): Look for and validate the htm features.
449 Include checkpointed DFP, VSX and EFP pseudo-registers.
450 * NEWS: Mention access to PPR, DSCR, TAR, EBB/PMU registers and
453 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
455 * rs6000-tdep.c (rs6000_gdbarch_init): Reject tdescs with vsx but
456 without altivec or fpu.
458 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
459 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
461 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
462 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
463 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
464 Define if not already defined.
465 * features/rs6000/power-ebb.xml: New file.
466 * features/rs6000/power-linux-pmu.xml: New file.
467 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
469 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
470 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
471 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
472 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
473 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
474 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
475 fetch_regset with ebb and pmu regsets.
476 (store_register, store_ppc_registers): Call store_regset with ebb
478 (ppc_linux_nat_target::read_description): Set isa207 field in the
479 features struct if ebb and pmu are avaiable.
480 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
481 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
482 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
484 (ppc_linux_core_read_description): Check if the pmu section is
485 present and set isa207 in the features struct.
486 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
487 (ppc32_linux_pmuregset): Declare.
488 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
489 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
490 <ppc_sier_regnum>: New field.
491 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
493 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
495 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
496 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
497 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
498 ebb and pmu features.
500 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
501 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
503 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
504 (tdesc_powerpc_isa207_vsx64l): Declare.
505 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
506 (struct ppc_linux_features) <isa207>: New field.
507 (ppc_linux_no_features): Add initializer for isa207 field.
508 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
510 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
511 (NT_PPC_TAR): Define if not already defined.
512 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
513 rs6000/powerpc-isa207-vsx64l.
514 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
515 rs6000/powerpc-isa207-vsx64l.xml.
516 * features/rs6000/power-tar.xml: New file.
517 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
518 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
519 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
520 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
521 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
522 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
523 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
524 fetch_regset with the TAR regset.
525 (store_register, store_ppc_registers): Call store_regset with the
527 (ppc_linux_nat_target::read_description): Set isa207 field in the
528 features struct if needed.
529 * ppc-linux-tdep.c: Include
530 features/rs6000/powerpc-isa207-vsx32l.c and
531 features/rs6000/powerpc-isa207-vsx64l.c.
532 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
533 (ppc_linux_iterate_over_regset_sections): Call back with the tar
535 (ppc_linux_core_read_description): Check if the tar section is
536 present and set isa207 in the features struct.
537 (_initialize_ppc_linux_tdep): Call
538 initialize_tdesc_powerpc_isa207_vsx32l and
539 initialize_tdesc_powerpc_isa207_vsx64l.
540 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
541 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
542 (enum) <PPC_TAR_REGNUM>: New enum value.
543 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
545 (ppc_process_record_op31): Record changes to TAR.
547 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
548 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
550 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
551 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
552 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
553 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
554 (struct ppc_linux_features) <ppr_dscr>: New field.
555 (ppc_linux_no_features): Add initializer for ppr_dscr field.
556 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
558 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
559 Define if not already defined.
560 * features/Makefile (WHICH): Add
561 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
562 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
563 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
564 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
565 * features/rs6000/power-dscr.xml: New file.
566 * features/rs6000/power-ppr.xml: New file.
567 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
568 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
569 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
570 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
571 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
572 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
573 * ppc-linux-nat.c: Include <sys/uio.h>.
574 (fetch_regset, store_regset, check_regset): New functions.
575 (fetch_register, fetch_ppc_registers): Call fetch_regset with
576 DSCR and PPR regsets.
577 (store_register, store_ppc_registers): Call store_regset with
578 DSCR and PPR regsets.
579 (ppc_linux_get_hwcap2): New function.
580 (ppc_linux_nat_target::read_description): Call
581 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
582 features struct if needed.
583 * ppc-linux-tdep.c: Include
584 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
585 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
586 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
587 (ppc32_linux_dscrregset): New globals.
588 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
590 (ppc_linux_core_read_description): Check if the ppr and dscr
591 sections are present and set ppr_dscr in the features struct.
592 (_initialize_ppc_linux_tdep): Call
593 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
594 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
595 * ppc-linux-tdep.h (ppc32_linux_pprregset)
596 (ppc32_linux_dscrregset): Declare.
597 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
598 <ppc_dscr_regnum>: New field.
599 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
600 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
602 (ppc_process_record_op31): Record changes to PPR and DSCR.
604 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
606 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
607 second initializer line for the have_* variables. Initialize
608 have_fpu to 0 instead of 1.
610 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
612 * arch/ppc-linux-common.c (ppc_linux_match_description):
613 Parenthesize tdesc assignements and indent them properly.
615 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
617 * ppc-linux-nat.c (fetch_register): Change if statement to else
619 (store_register): Likewise.
621 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
623 * rs6000-tdep.c: Remove reggroups.h include.
624 (rs6000_pseudo_register_reggroup_p): Remove.
625 (rs6000_gdbarch_init): Remove call to
626 set_tdesc_pseudo_register_reggroup_p.
628 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
630 * reggroups.c (default_register_reggroup_p): Return true for
631 decfloat registers and float_reggroup.
633 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
635 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
636 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
637 ppc_linux_collect_vrregset by regcache_collect_regset.
639 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
641 * linux-tdep.c (linux_collect_regset_section_cb): Use
642 std::vector<gdb_byte> instead of char * and malloc for buf.
645 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
647 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
648 symtab_start instead of always using language_unknown.
650 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
652 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
653 READ_P parameter, catch and ignore register access errors from
654 either the old or new MISA location.
655 (riscv_has_feature): Update call to riscv_read_misa_reg.
657 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
659 * python/py-function.c (convert_values_to_python): Return
660 gdbpy_ref<>. Add header comment.
663 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
665 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
666 (cmdpy_completer_handle_brkchars): Adjust.
667 (cmdpy_completer): Adjust.
669 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
671 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
672 Pass correct regnum to raw_supply_zeroed.
674 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
676 * regcache.c (cooked_read_test): Add CSKY to the list of
677 architectures with a save_reggroup
679 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
682 * infrun.c (follow_exec): In the follow_exec_mode_new case,
683 transfer terminal state from old new new inferior.
684 * terminal.h (swap_terminal_info): New function.
685 * inflow.c (swap_terminal_info): New function.
687 2018-10-23 Tom Tromey <tom@tromey.com>
689 * record-btrace.c (get_thread_current_frame_id): Rename from
690 get_thread_current_frame. Return a frame_id.
691 (record_btrace_start_replaying): Update.
693 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
695 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
698 2018-10-23 Joel Brobecker <brobecker@adacore.com>
700 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
701 have_nonsteppable_watchpoint attribute to 1.
703 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
705 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
707 (struct register_alias): Rename to...
708 (struct riscv_register_alias): ...this, and update comment.
709 (riscv_register_aliases): Update type, and alias names. Remove
710 CSR names from this list.
711 (riscv_register_name): Use riscv_gdb_reg_names for int and float
712 register names. Add an extra assertion.
713 (riscv_is_regnum_a_named_csr): New function.
714 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
716 2018-10-22 Jim Wilson <jimw@sifive.com>
718 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
719 FP reg smaller than FP reg size, and fill with -1 instead of 0.
721 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
722 (riscv_register_type): Use them.
723 (riscv_print_one_register_info): Handle union of floats same as float.
724 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
725 riscv_fpreg_q_type fields.
727 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
729 * gdbarch.sh (gdbarch_num_cooked_regs): New.
730 * gdbarch.h: Re-generate.
731 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
732 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
733 * eval.c (evaluate_subexp_standard): Likewise.
734 * findvar.c (value_of_register): Likewise.
735 (value_of_register_lazy): Likewise.
736 (address_from_register): Likewise.
737 * frame.c (get_frame_register_bytes): Likewise.
738 * gdbarch-selftests.c (register_to_value_test): Likewise.
739 * h8300-tdep.c (h8300_register_type): Likewise.
740 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
741 (i386_svr4_reg_to_regnum): Likewise.
742 * infcmd.c (default_print_registers_info): Likewise.
743 (registers_info): Likewise.
744 (print_vector_info): Likewise.
745 (default_print_float_info): Likewise.
746 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
747 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
748 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
749 (mi_cmd_data_list_changed_registers): Likewise.
750 (mi_cmd_data_list_register_values): Likewise.
751 (mi_cmd_data_write_register_values): Likewise.
752 (mi_cmd_trace_frame_collected): Likewise.
753 * mips-tdep.c (print_gp_register_row): Likewise.
754 (mips_print_registers_info): Likewise.
755 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
756 * regcache.c (init_regcache_descr): Likewise.
757 (register_size): Likewise.
758 (register_dump::dump): Likewise.
759 (cooked_read_test): Likewise.
760 (cooked_write_test): Likewise.
761 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
762 (rs6000_gdbarch_init): Likewise.
763 * stabsread.c (stab_reg_to_regnum): Likewise.
764 * stack.c (info_frame_command): Likewise.
765 * target-descriptions.c (tdesc_register_name): Likewise.
766 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
767 * tui/tui-regs.c (tui_show_register_group): Likewise.
768 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
769 (user_reg_map_regnum_to_name): Likewise.
770 (value_of_user_reg): Likewise.
771 (maintenance_print_user_registers): Likewise.
772 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
773 (xtensa_register_name): Likewise.
774 (xtensa_register_type): Likewise.
775 (xtensa_reg_to_regnum): Likewise.
776 (xtensa_pseudo_register_read): Likewise.
777 (xtensa_pseudo_register_write): Likewise.
779 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
781 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
782 correctly-sized buffer with raw_read.
783 (amd64_pseudo_register_write): Use correctly-sized buffer for
786 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
788 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
789 in add_prefix_cmd of set print type.
791 2018-10-19 Tom Tromey <tom@tromey.com>
794 * NEWS: Mention tabset deprecation.
795 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
796 (update_tab_width): New function.
797 (tui_set_tab_width, tui_show_tab_width): New functions.
798 (tui_set_tab_width_command): Use update_tab_width.
799 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
800 Add new "set tui tab-width" command.
801 * tui/tui-source.c (tui_set_source_content): Update.
802 * tui/tui-disasm.c (tui_set_disassem_content): Update.
803 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
805 (tui_tab_width): Declare.
806 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
807 (tui_set_default_tab_len): Remove.
809 2018-10-19 Tom Tromey <tom@tromey.com>
811 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
812 (key_is_backspace, tui_getc): Don't declare.
813 * tui/tui-io.c (key_is_start_sequence): Now static.
814 (key_is_end_sequence, key_is_backspace): Remove.
815 (tui_getc): Now static.
817 2018-10-19 Tom Tromey <tom@tromey.com>
819 * symfile.c (reread_symbols): Clear "static_links".
821 2018-10-19 Alan Hayward <alan.hayward@arm.com>
823 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
825 (aarch64_linux_sigframe_init): Extra boundary checks.
827 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
829 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
830 the possibly non-existent tdesc type 'vec128', but the type of raw
831 register v16 instead.
833 2018-10-19 Gary Benson <gbenson@redhat.com>
835 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
837 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
840 * cli/cli-dump.c (restore_binary_file): Check if "file" is
843 2018-10-17 Paul Koning <paul_koning@dell.com>
845 * charset.c (convert_between_encodings): Fix unsigned overflow.
847 2018-10-17 John Baldwin <jhb@FreeBSD.org>
849 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
850 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
851 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
852 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
854 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
855 and fbsd_info_proc_mappings_header.
856 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
857 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
860 2018-10-17 Joel Brobecker <brobecker@adacore.com>
862 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
865 2018-10-15 Tom Tromey <tom@tromey.com>
867 * tui/tui.c (strcat_to_buf): Remove casts.
868 * tui/tui-winsource.c (tui_show_source_line)
869 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
870 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
871 * tui/tui-windata.c (tui_first_data_item_displayed)
872 (tui_delete_data_content_windows, tui_erase_data_content)
873 (tui_display_all_data, tui_display_data_from)
874 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
875 * tui/tui-win.c (tui_set_win_height)
876 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
878 * tui/tui-win.c (tui_resize_all): Remove casts.
879 (tui_scroll_backward_command, tui_set_focus)
880 (tui_set_tab_width_command): Likewise.
881 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
882 * tui/tui-regs.c (tui_show_register_group): Remove cast.
883 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
884 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
885 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
888 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
890 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
891 AArch64/ARM maintainer.
893 2018-10-11 Gary Benson <gbenson@redhat.com>
895 * interps.h (interp::m_name): Make private and mutable.
896 * interps.c (interp::~interp): Free m_name.
898 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
899 Simon Marchi <simark@simark.ca>
901 * README (`configure' options): Add documentation for new
902 "--enable-unit-tests" option.
903 * acinclude.m4: Include "selftest.m4".
904 * configure: Regenerate.
905 * configure.ac: Use "GDB_AC_SELFTEST".
906 * maint.c (maintenance_selftest): Update message informing
907 that selftests have been disabled.
908 (maintenance_info_selftests): Likewise.
909 * selftest.m4: New file.
911 2018-10-10 Gary Benson <gbenson@redhat.com>
913 * remote.c (remote_target::remote_send_printf): Add
914 missing va_end found by Coverity.
916 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
918 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
920 2018-10-09 Tom Tromey <tom@tromey.com>
922 * configure: Rebuild.
923 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
924 * NEWS: Update --enable-ubsan documentation.
926 2018-10-09 Gary Benson <gbenson@redhat.com>
928 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
931 2018-10-08 Tom Tromey <tom@tromey.com>
933 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
935 (riscv_fbsd_init_abi): Likewise.
937 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
938 * valops.c (value_struct_elt_for_reference): Rename local variable
939 to work around the shadowing a previous local warning.
941 2018-10-08 John Baldwin <jhb@FreeBSD.org>
943 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
944 * NEWS: Mention new FreeBSD/riscv native configuration.
945 * configure.host: Add riscv*-*-freebsd*.
946 * configure.nat: Likewise.
947 * riscv-fbsd-nat.c: New file.
949 2018-10-08 John Baldwin <jhb@FreeBSD.org>
951 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
952 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
953 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
954 * NEWS: Mention new FreeBSD/riscv target.
955 * configure.tgt: Add riscv*-*-freebsd*.
956 * riscv-fbsd-tdep.c: New file.
957 * riscv-fbsd-tdep.h: New file.
959 2018-10-08 John Baldwin <jhb@FreeBSD.org>
961 * regcache.h (struct regcache_map_entry): Note that this type can
962 be used with traditional frame caches.
963 * trad-frame.c (trad_frame_set_reg_regmap): New.
964 * trad-frame.h (trad_frame_set_reg_regmap): New.
966 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
969 * valops.c (get_virtual_base_offset): New function.
970 (value_struct_elt_for_reference): Use it to get virtual base offset
971 and add it in calculating class member address.
973 2018-10-08 John Darrington <john@darrington.wattle.id.au>
975 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
976 (check_producer): Check if the producer is codewarrior.
977 (producer_is_codewarrior): New function.
978 (lnp_state_machine::record_line): Ignore is_stmt flag for records
979 produced by codewarrior.
980 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
982 2018-10-06 Tom Tromey <tom@tromey.com>
985 * python/py-inferior.c: Add "architecture" entry.
986 (infpy_architecture): New function.
988 2018-10-06 Tom Tromey <tom@tromey.com>
991 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
992 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
993 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
994 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
996 2018-10-06 Tom Tromey <tom@tromey.com>
999 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
1000 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
1001 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
1004 2018-10-06 Tom Tromey <tom@tromey.com>
1006 * python/py-breakpoint.c (bppy_get_location): Handle a
1007 bp_breakpoint without a location.
1009 2018-10-06 Tom Tromey <tom@tromey.com>
1011 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
1012 (_RegEx): Reformat help text.
1013 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
1014 (AnyCallerIs, AnyCallerMatches): Reformat help text.
1015 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
1017 * python/lib/gdb/command/xmethods.py (InfoXMethod)
1018 (EnableXMethod, DisableXMethod): Remove help indentation.
1019 Capitalize meta-syntactic variables.
1020 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
1021 (EnableUnwinder, DisableUnwinder): Remove help indentation.
1022 Capitalize meta-syntactic variables.
1023 * python/lib/gdb/command/explore.py (ExploreCommand)
1024 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
1025 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
1026 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
1027 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
1028 Remove help indentation.
1029 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
1030 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
1031 (DisableFrameFilter, SetFrameFilterPriority)
1032 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
1034 2018-10-06 Tom Tromey <tom@tromey.com>
1037 * tui/tui-io.c (gdb_wgetch): New function.
1038 (tui_mld_getc, tui_getc): Use it.
1040 2018-10-05 Tom Tromey <tom@tromey.com>
1042 * sol-thread.c (sol_thread_target::wait): Rename inner
1045 2018-10-04 Tom Tromey <tom@tromey.com>
1047 * configure: Rebuild.
1048 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
1050 2018-10-04 Tom Tromey <tom@tromey.com>
1052 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
1053 declaration of "block".
1055 2018-10-04 Tom Tromey <tom@tromey.com>
1057 * common/filestuff.c (fdwalk): Remove inner declaration of
1060 2018-10-04 Tom Tromey <tom@tromey.com>
1062 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
1063 "structs_addr" and hoist declaration.
1065 2018-10-04 Tom Tromey <tom@tromey.com>
1067 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
1070 2018-10-04 Tom Tromey <tom@tromey.com>
1072 * mdebugread.c (parse_partial_symbols): Use std::string.
1074 2018-10-04 Tom Tromey <tom@tromey.com>
1076 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
1077 * p-valprint.c (pascal_val_print): Split inner "i" variable.
1078 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
1080 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
1082 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
1083 * varobj.c (varobj_update): Rename inner "newobj",
1085 * valprint.c (generic_emit_char): Rename inner "buf".
1086 * valops.c (find_overload_match): Rename inner "temp".
1087 (value_struct_elt_for_reference): Declare "v" in more inner
1089 * v850-tdep.c (v850_push_dummy_call): Rename "len".
1090 * unittests/array-view-selftests.c (run_tests): Rename inner
1092 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
1094 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
1095 "tsv" in more inner scope.
1096 (print_one_static_tracepoint_marker): Rename inner
1098 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
1099 (tic6x_push_dummy_call): Don't redeclare "addr".
1100 * target-float.c: Declare "dto" lower.
1101 * symtab.c (lookup_local_symbol): Rename inner "sym".
1102 (find_pc_sect_line): Rename inner "pc".
1103 * stack.c (print_frame): Don't redeclare "gdbarch".
1104 (return_command): Rename inner "gdbarch".
1105 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
1107 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
1109 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
1110 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
1112 * remote.c (remote_target::update_thread_list): Don't redeclare
1114 (remote_target::process_initial_stop_replies): Rename inner
1116 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
1117 (remote_target::wait_as): Don't redeclare "stop_reply".
1118 (remote_target::get_thread_local_address): Rename inner
1120 (remote_target::get_tib_address): Likewise.
1122 * regcache.c (cooked_read_test): Rename "regnum".
1123 * record-btrace.c (cmd_record_btrace_start): Rename inner
1125 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
1127 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
1129 (ppu2spu_sniffer): Rename inner "buf".
1130 * parse.c (operator_check_standard): Rename inner "type",
1132 * p-valprint.c (pascal_val_print): Introduce new scope for
1133 "low_bound", "high_bound".
1134 * p-exp.y (yylex): Declare "i" in loop header.
1135 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
1136 Lower declaration of "s".
1137 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
1139 (nios2_push_dummy_call): Rename "len".
1140 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
1142 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
1143 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
1144 (linux_xfer_osdata_modules): Likewise.
1145 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
1146 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
1147 (mips_o64_push_dummy_call): Likewise.
1148 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
1150 * mi/mi-main.c (list_available_thread_groups): Rename inner
1152 (mi_cmd_data_read_memory): Rename inner "opts".
1153 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
1155 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
1156 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
1158 (parse_partial_symbols): Rename inner "pst", "p", "name"
1159 * main.c (captured_main_1): Rename inner "i"s.
1160 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
1162 * linux-tdep.c (linux_info_proc): Rename inner "filename".
1163 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
1164 * infrun.c (handle_no_resumed): Don't redeclare "thread".
1165 (handle_signal_stop): Rename inner "gdbarch".
1166 (handle_command): Declare "signum" in loop header.
1167 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
1169 (examine_prologue): Rename inner "sol" and "sof".
1170 (ia64_extract_return_value): Rename inner "val". Declare another
1171 "val" in a more inner scope.
1172 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
1174 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
1176 * findvar.c (default_read_var_value): Don't redeclare "addr".
1177 * f-exp.y (yylex): Declare "i" in loop header.
1178 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
1179 Rename inner "type", "expect_type".
1180 (evaluate_subexp_for_sizeof): Rename inner "pc".
1181 * elfread.c (elf_symfile_read): Rename inner "abfd".
1182 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
1184 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
1185 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
1186 (dwarf_decode_line_header): Rename inner "lh".
1187 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
1188 "offset". Declare "i" in loop header.
1189 (disassemble_dwarf_expression): Rename inner "addr_size".
1190 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
1192 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
1193 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
1194 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
1195 "inner_list_emitter".
1196 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
1197 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
1198 declaration in a block.
1199 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
1200 * cp-valprint.c (cp_print_value_fields): Don't redeclare
1201 "obstack_final_size".
1202 * cp-support.c (inspect_type): Declare "i" in loop header.
1203 * compile/compile.c (compile_instance::insert_symbol_error):
1205 * common/agent.c (agent_run_command): Remove inner "ret"
1207 * coffread.c (coff_symfile_read): Rename inner "name".
1208 (coff_symfile_read): Rename inner "abfd".
1209 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
1210 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
1212 * c-exp.y (lex_one_token): Move "len" declaration lower.
1213 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
1215 (create_exception_master_breakpoint): Likewise. Don't redeclare
1217 (watch_command_1): Declare "mark" later.
1218 (clear_command): Don't shadow "a" or "b".
1219 (delete_command): Rename inner "b".
1220 (delete_trace_command): Likewise.
1221 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
1223 (arm_gdbarch_init): Remove inner "e_flags".
1224 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
1225 "offset" in inner blocks.
1227 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
1229 * dwarf-index-write.c (file_write): Don't write if the vector is
1232 2018-10-05 Tom de Vries <tdevries@suse.de>
1234 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
1235 PyArg_ParseTuple call.
1237 2018-10-05 Tom de Vries <tdevries@suse.de>
1239 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
1240 PyArg_ParseTuple call.
1242 2018-10-04 Joel Brobecker <brobecker@adacore.com>
1244 * psymtab.c (recursively_search_psymtabs): Reformat parameters
1245 to avoid exceeding 80 characters per line limit.
1247 2018-10-04 Tom Tromey <tom@tromey.com>
1249 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1250 (reread_symbols): Update.
1251 * complaints.h (clear_complaints): Remove argument.
1252 * complaints.c (enum complaint_series): Remove.
1253 (series): Remove global.
1254 (complaint_internal): Update.
1255 (clear_complaints): Remove argument.
1257 2018-10-04 Tom Tromey <tom@tromey.com>
1259 * symfile.c (symbol_file_add_with_addrs): Do not print "no
1260 debugging symbols" message if there is a separate debug objfile.
1262 2018-10-04 Tom Tromey <tom@tromey.com>
1265 * symfile.c (symbol_file_add_with_addrs): Update output.
1266 * psymtab.c (require_partial_symbols): Update output.
1268 2018-10-04 Tom Tromey <tom@tromey.com>
1271 * complaints.c: Emit \n.
1273 2018-10-04 Tom Tromey <tom@tromey.com>
1275 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
1276 (separate_debug_file_exists, find_separate_debug_file)
1277 (add_symbol_file_command, reread_symbols, allocate_symtab)
1278 (allocate_compunit_symtab): Use filtered printing, not
1280 * psymtab.c (require_partial_symbols, dump_psymtab)
1281 (allocate_psymtab): Use filtered printing, not unfiltered.
1283 2018-10-04 Tom Tromey <tom@tromey.com>
1285 * complaints.c (complaint_internal): Correctly check complaint
1288 2018-10-04 Tom Tromey <tom@tromey.com>
1290 * complaints.h (struct complaints): Remove declaration.
1291 * complaints.c (clear_complaints): Remove an unused variable.
1293 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1295 * MAINTAINERS (Write After Approval): Add self.
1297 2018-10-03 Tom Tromey <tom@tromey.com>
1299 * guile/scm-value.c (gdbscm_value_to_string): Initialize
1301 * coffread.c (coff_symtab_read): Initialize "newobj".
1303 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
1305 * dwarf2read.c (read_func_scope): Remove struct keyword in
1308 2018-10-03 Tom Tromey <tom@tromey.com>
1310 * README: Mention --enable-ubsan.
1311 * NEWS: Mention --enable-ubsan.
1312 * acinclude.m4: Include sanitize.m4.
1313 * configure: Rebuild.
1314 * configure.ac: Call AM_GDB_UBSAN.
1315 * sanitize.m4: New file.
1317 2018-10-03 Tom Tromey <tom@tromey.com>
1319 * expression.h (enum exp_opcode): Use uint8_t as base type.
1320 * expprint.c (op_name): Handle invalid opcodes.
1322 2018-10-03 Tom Tromey <tom@tromey.com>
1324 * parse.c (prefixify_expression): Add assert.
1325 (parse_exp_in_context_1): Throw exception if the expression is
1328 2018-10-03 Tom Tromey <tom@tromey.com>
1330 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
1332 2018-10-03 Tom Tromey <tom@tromey.com>
1334 * c-exp.y (parse_number): Work in unsigned. Remove casts.
1336 2018-10-03 Tom Tromey <tom@tromey.com>
1338 * dwarf2read.c (read_subrange_type): Make "negative_mask"
1341 2018-10-03 Tom Tromey <tom@tromey.com>
1343 * findvar.c (extract_integer): Do work in an unsigned type.
1345 2018-10-03 Tom Tromey <tom@tromey.com>
1347 * common/enum-flags.h (enum_flags::operator~): Add static assert.
1348 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
1350 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
1351 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
1353 * c-lang.h (enum c_string_type_values): Use unsigned as base
1355 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
1357 2018-10-03 Tom Tromey <tom@tromey.com>
1359 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
1360 <~dwarf2_frame_state_reg_info>: Update.
1361 <dwarf2_frame_state_reg_info>: Update.
1362 <alloc_regs>: Add assertion. Update.
1363 <reg>: Now a std::vector.
1366 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
1367 (execute_cfa_program_test, dwarf2_frame_cache): Update.
1369 2018-10-03 Tom Tromey <tom@tromey.com>
1371 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
1373 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1375 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
1377 2018-10-02 Tom Tromey <tom@tromey.com>
1379 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
1381 2018-10-02 John Darrington <john@darrington.wattle.id.au>
1383 * NEWS: Mention changed commands.
1384 * ser-uds.c: New file.
1385 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
1386 * configure: Regenerate.
1387 * Makefile.in: Add new file.
1388 * serial.c (serial_open): Check if filename is a socket
1389 and lookup the appropriate interface accordingly.
1391 2018-10-01 Alan Hayward <alan.hayward@arm.com>
1393 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
1395 (AARCH64_EXTRA_MAGIC): Likewise.
1396 (AARCH64_FPSIMD_MAGIC): Likewise.
1397 (AARCH64_SVE_MAGIC): Likewise.
1398 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
1399 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
1400 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
1401 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
1402 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
1403 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
1404 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
1405 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
1406 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
1407 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
1408 (read_aarch64_ctx): Add function.
1409 (aarch64_linux_sigframe_init): Detect FP registers.
1411 2018-10-01 Alan Hayward <alan.hayward@arm.com>
1413 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
1414 (AARCH64_D0_REGNUM): Likewise.
1415 (AARCH64_S0_REGNUM): Likewise.
1416 (AARCH64_H0_REGNUM): Likewise.
1417 (AARCH64_B0_REGNUM): Likewise.
1418 (AARCH64_SVE_V0_REGNUM): Likewise.
1419 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
1420 (AARCH64_D0_REGNUM): Likewise.
1421 (AARCH64_S0_REGNUM): Likewise.
1422 (AARCH64_H0_REGNUM): Likewise.
1423 (AARCH64_B0_REGNUM): Likewise.
1424 (AARCH64_SVE_V0_REGNUM): Likewise.
1426 2018-10-01 Gary Benson <gbenson@redhat.com>
1428 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
1429 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
1430 prfpregset_t instead of gdb_prfpregset_t.
1431 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
1432 * configure, config.in: Rebuild.
1434 2018-10-01 Gary Benson <gbenson@redhat.com>
1436 * common/gdb_proc_service.h: New file, factored out from...
1437 * gdb_proc_service.h: Moved common code to the above file.
1438 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
1440 2018-10-01 Gary Benson <gbenson@redhat.com>
1442 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
1443 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
1445 2018-10-01 Gary Benson <gbenson@redhat.com>
1447 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
1448 (AC_CHECK_HEADERS): Check for linux/elf.h.
1449 * configure, config.in: Rebuild.
1450 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
1451 doesn't define elf_fpregset_t.
1453 2018-10-01 Gary Benson <gbenson@redhat.com>
1455 * gdb_proc_service.h: Whitespace change.
1457 2018-10-01 Tom Tromey <tom@tromey.com>
1459 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
1460 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
1461 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
1463 2018-10-01 Tom Tromey <tom@tromey.com>
1465 * README: Minor change.
1467 2018-09-30 Pedro Alves <palves@redhat.com>
1469 * darwin-nat-info.c (darwin_debug_regions_recurse)
1470 (info_mach_exceptions_command): Remove unused local variables.
1471 * darwin-nat.c (darwin_decode_notify_message)
1472 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
1473 (darwin_stop_inferior, darwin_setup_exceptions)
1474 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
1475 (darwin_nat_target::attach, darwin_nat_target::detach)
1476 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
1478 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
1481 2018-09-29 Tom Tromey <tom@tromey.com>
1483 * README: Remove some leftover text.
1485 2018-09-29 Tom Tromey <tom@tromey.com>
1487 * PROBLEMS: Rewrite.
1490 2018-09-28 John Baldwin <jhb@FreeBSD.org>
1492 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
1493 case with explicit breakpoint kind.
1494 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
1495 'additional_info' and related logic.
1496 (riscv_debug_breakpoints): New variable.
1497 (riscv_breakpoint_kind_from_pc): Use the length of the existing
1498 instruction to determine the breakpoint kind.
1499 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
1500 flag. Update description of 'set/show riscv
1501 use-compressed-breakpoints' flag.
1503 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
1505 (NEWS): Mention changes to frame related commands.
1506 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
1507 (add_prefix_cmd_suppress_notification): New function.
1508 (add_com_suppress_notification): Call
1509 add_cmd_suppress_notification.
1510 * command.h (add_cmd_suppress_notification): Declare.
1511 (add_prefix_cmd_suppress_notification): Declare.
1512 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
1513 (parse_frame_specification): Moved from stack.c, with
1514 simplification to handle a single argument.
1515 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
1516 switch to the selected frame. Add a header comment.
1517 * stack.c: Remove 'safe-ctype.h' include.
1518 (find_frame_for_function): Add declaration.
1519 (find_frame_for_address): New function.
1520 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
1521 (frame_selection_by_function_completer): New function.
1522 (info_frame_command): Rename to...
1523 (info_frame_command_core): ...this, and update parameter types.
1524 (select_frame_command): Rename to...
1525 (select_frame_command_core): ...this, and update parameter types.
1526 (frame_command): Rename to...
1527 (frame_command_core): ...this, and update parameter types.
1528 (class frame_command_helper): New class to wrap implementations of
1529 frame related sub-commands.
1530 (frame_apply_cmd_list): New static global.
1531 (frame_cmd_list): Make static.
1532 (select_frame_cmd_list): New global for sub-commands.
1533 (info_frame_cmd_list): New global for sub-commands.
1534 (_initialize_stack): Register sub-commands for 'frame',
1535 'select-frame', and 'info frame'. Update 'frame apply' commands
1536 to use frame_apply_cmd_list. Move function local static
1537 frame_apply_list to file static frame_apply_cmd_list for
1539 * stack.h (select_frame_command): Delete declarationn.
1540 (select_frame_for_mi): Declare new function.
1542 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
1544 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
1545 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
1548 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
1550 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
1552 2018-09-26 Tom Tromey <tom@tromey.com>
1554 * valops.c (auto_abandon): Remove dead code.
1556 2018-09-26 Tom Tromey <tom@tromey.com>
1558 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
1560 2018-09-24 Tom Tromey <tom@tromey.com>
1562 * common/pathstuff.c (get_standard_cache_dir): Make
1563 "xdg_cache_home" and "home" const.
1564 * top.c (init_history): Make "tmpenv" const.
1565 * main.c (get_init_files): Make "homedir" const.
1567 2018-09-23 Tom Tromey <tom@tromey.com>
1570 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
1572 2018-09-23 Tom Tromey <tom@tromey.com>
1574 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
1575 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
1576 * python/python-internal.h (gdbpy_handle_exception): Declare.
1577 * python/py-utils.c (gdbpy_handle_exception): New function.
1579 2018-09-23 Tom Tromey <tom@tromey.com>
1582 * python/py-type.c (typy_template_argument): Check for negative
1585 2018-09-23 Tom Tromey <tom@tromey.com>
1588 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
1590 2018-09-23 Tom Tromey <tom@tromey.com>
1593 * python/py-value.c (valpy_int): Allow conversion from pointer
1596 2018-09-23 Tom Tromey <tom@tromey.com>
1599 * python/py-value.c (valpy_int): Respect type sign.
1601 2018-09-23 Tom Tromey <tom@tromey.com>
1604 * python/py-value.c (valpy_float): Allow conversions from int or
1606 (valpy_int, valpy_long): Allow conversions from float.
1608 2018-09-23 Tom Tromey <tom@tromey.com>
1610 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
1611 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
1613 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1615 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
1617 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
1619 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
1621 * windows-nat.c (windows_nat_target::wait): Remove a spurious
1622 target_terminal::ours().
1624 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
1626 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
1629 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
1631 * breakpoint.c (update_inserted_breakpoint_locations): Remove
1632 redundant condition.
1634 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1636 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
1638 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
1639 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
1640 * sol-thread.c (ps_pdmodel): Don't guard definition.
1642 * procfs.c: Fix formatting.
1644 * procfs.c (sysset_t_alloc): Remove.
1645 (create_procinfo): Use XNEW instead of sysset_t_alloc.
1646 (procfs_debug_inferior): Likewise.
1647 (procfs_set_exec_trap): Likewise.
1648 (proc_set_traced_sysentry): Don't allocate argp dynamically.
1649 (proc_set_traced_sysexit): Likewise.
1651 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
1652 (dead_procinfo): Likewise.
1653 (proc_warn): Likewise.
1654 (proc_error): Likewise.
1655 (proc_get_LDT_entry): Likewise.
1656 (do_attach): Likewise.
1657 (procfs_target::pid_to_str): Likewise.
1658 (iterate_over_mappings): Likewise.
1660 * procfs.c (create_procinfo): Fix ARI warning.
1661 (proc_get_status): Likewise.
1662 (proc_stop_process): Likewise.
1663 (proc_run_process): Likewise.
1664 (proc_kill): Likewise.
1665 (proc_get_LDT_entry): Likewise.
1666 (procfs_find_LDT_entry): Likewise.
1667 (proc_update_threads): Likewise.
1668 (proc_iterate_over_threads): Likewise.
1669 (do_attach): Likewise.
1670 (procfs_xfer_memory): Likewise.
1671 (invalidate_cache): Likewise.
1672 (procfs_target::resume): Likewise.
1673 (procfs_init_inferior): Likewise.
1674 (procfs_set_exec_trap): Likewise.
1675 (procfs_target::thread_alive): Likewise.
1676 (procfs_target::pid_to_exec_file): Likewise.
1677 (iterate_over_mappings): Likewise.
1678 (procfs_target::make_corefile_notes): Likewise.
1679 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
1681 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
1682 (procfs_find_LDT_entry): Likewise.
1683 * sol-thread.c (ps_lgetLDT): Likewise.
1685 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1688 * procfs.c (procfs_target): Declare pid_to_exec_file.
1689 (procfs_target::pid_to_exec_file): New.
1691 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1693 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
1695 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
1696 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
1698 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1700 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
1701 (supply_fpregset, fill_fpregset): Move ...
1702 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
1703 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
1704 Remove references to ioctl-based procfs.
1705 Include <sys/reg.h>.
1706 Remove PR_MODEL_NATIVE guards.
1707 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
1708 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
1710 2018-09-19 Xavier Roirand <roirand@adacore.com>
1713 * solib-darwin.c (darwin_get_dyld_bfd): New function.
1714 (darwin_solib_get_all_image_info_addr_at_init): Update call.
1715 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
1717 2018-09-19 John Baldwin <jhb@FreeBSD.org>
1719 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
1720 (fbsd_print_sockaddr_in6): Likewise.
1722 2018-09-19 Richard Bunt <richard.bunt@arm.com>
1723 Chris January <chris.january@arm.com>
1725 * eval.c (skip_undetermined_arglist): Skip argument list helper.
1726 (evaluate_subexp_standard): Return a dummy type when
1727 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
1728 OP_F77_UNDETERMINED_ARGLIST case.
1729 * expression.h (enum noside): Update comment.
1731 2018-09-19 George Vasick <george.vasick@oracle.com>
1733 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
1735 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
1736 April Chin <april.chin@oracle.com>
1737 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1739 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
1741 (create_procinfo): Print pids in /proc without leading zeros.
1743 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
1745 * nios2-tdep.c (nios2_gcc_target_options): New.
1746 (nios2_gdb_arch_init): Install new hook.
1748 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
1750 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
1752 * update-gnulib.sh: Apply patch.
1753 * configure: Re-generate.
1755 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1757 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
1758 description. Make "info proc" command descriptions more
1761 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1763 * NEWS: Mention 'info proc files' command.
1765 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1767 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
1768 descriptors for IP_FILES and IP_ALL.
1770 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1772 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
1773 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
1774 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
1775 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
1776 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
1777 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
1778 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
1779 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
1780 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
1781 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
1782 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
1783 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
1784 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
1785 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
1786 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
1787 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
1788 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
1789 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
1790 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
1791 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
1792 (struct fbsd_sockaddr_un): New types.
1793 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
1794 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
1795 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
1796 (fbsd_core_info_proc_files): New functions.
1797 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
1799 * fbsd-tdep.h (fbsd_info_proc_files_header)
1800 (fbsd_info_proc_files_entry): New.
1802 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1804 * defs.h (enum info_proc_what) [IP_FILES]: New value.
1805 * infcmd.c (info_proc_cmd_files): New function.
1806 (_initialize_infcmd): Register 'info proc files' command.
1808 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1810 * gnulib/aclocal-m4-deps.mk: Re-generate.
1811 * gnulib/aclocal.m4: Re-generate.
1812 * gnulib/config.in: Re-generate.
1813 * gnulib/configure: Re-generate.
1814 * gnulib/import/Makefile.am: Re-generate.
1815 * gnulib/import/Makefile.in: Re-generate.
1816 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1817 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1818 * gnulib/import/arpa_inet.in.h: New file.
1819 * gnulib/import/inet_ntop.c: New file.
1820 * gnulib/import/m4/arpa_inet_h.m4: New file.
1821 * gnulib/import/m4/inet_ntop.m4: New file.
1822 * gnulib/import/m4/netinet_in_h.m4: New file.
1823 * gnulib/import/m4/socklen.m4: New file.
1824 * gnulib/import/m4/sockpfaf.m4: New file.
1825 * gnulib/import/m4/stdalign.m4: New file.
1826 * gnulib/import/m4/sys_uio_h.m4: New file.
1827 * gnulib/import/netinet_in.in.h: New file.
1828 * gnulib/import/stdalign.in.h: New file.
1829 * gnulib/import/sys_socket.c: New file.
1830 * gnulib/import/sys_socket.in.h: New file.
1831 * gnulib/import/sys_uio.in.h: New file.
1832 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
1835 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1837 * gnulib/aclocal-m4-deps.mk: New file.
1838 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
1841 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1843 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
1846 2018-09-18 Tom Tromey <tom@tromey.com>
1848 * compile/compile-object-load.c (struct
1849 link_hash_table_cleanup_data): Add constructor and destructor.
1850 Use DISABLE_COPY_AND_ASSIGN.
1851 (~link_hash_table_cleanup_data): Rename from
1852 link_hash_table_free. Now a destructor.
1853 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
1855 2018-09-18 Tom Tromey <tom@tromey.com>
1857 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1858 * compile/compile-object-load.c (struct munmap_list): Move to
1860 (munmap_list::add): Rename from munmap_list_add; rewrite.
1861 (munmap_list::~munmap_list): Rename from munmap_list_free.
1862 (munmap_listp_free_cleanup): Remove.
1863 (compile_object_load): Update.
1864 * compile/compile-object-load.h (struct munmap_list): Move from
1865 compile-object-load.c. Rewrite.
1867 2018-09-18 Alan Hayward <alan.hayward@arm.com>
1869 * aarch64-tdep.c (pass_in_v): Use register size.
1870 (aarch64_extract_return_value): Likewise.
1871 (aarch64_store_return_value): Likewise.
1873 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1875 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
1878 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1880 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
1881 Fix short help line.
1883 2018-09-17 Tom Tromey <tom@tromey.com>
1886 * configure: Rebuild.
1887 * configure.ac: Conditionally use -DNDEBUG for Python.
1889 2018-09-17 Tom Tromey <tom@tromey.com>
1891 * configure: Rebuild.
1892 * configure.ac: Use gmp as a library dependency when checking for
1895 2018-09-17 Pedro Alves <palves@redhat.com>
1897 * python/py-inferior.c (find_inferior_object): Delete.
1899 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
1901 * compile/compile-cplus-types.c
1902 (compile_cplus_instance::enter_scope): Don't use new_scope after
1905 2018-09-17 Tom Tromey <tom@tromey.com>
1907 * common/pathstuff.c (get_standard_cache_dir): Use
1908 ~/Library/Caches on macOS.
1909 * common/pathstuff.h (get_standard_cache_dir): Update comment.
1911 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
1914 * breakpoint.c (commands_cmd_element): New.
1915 (_initialize_breakpoint): Assign commands_cmd_element.
1916 * breakpoint.h (commands_cmd_element): New.
1917 * cli/cli-script.c (while_cmd_element, if_command,
1918 define_cmd_element): New.
1919 (command_name_equals): Remove.
1920 (process_next_line): Compare commands by pointer, not by name.
1921 (_initialize_cli_script): Assign the various cmd_list_element
1923 * compile/compile.c (compile_cmd_element): New.
1924 (_initialize_compile): Assign compile_cmd_element.
1925 * compile/compile.h (compile_cmd_element): New.
1926 * guile/guile.c (guile_cmd_element): New.
1927 (install_gdb_commands): Assign guile_cmd_element.
1928 * guile/guile.h (guile_cmd_element): New.
1929 * python/python.c (python_cmd_element): New.
1930 (_initialize_python): Assign python_cmd_element.
1931 * python/python.h (python_cmd_element): New.
1932 * tracepoint.c (while_stepping_cmd_element): New.
1933 (_initialize_tracepoint): Assign while_stepping_cmd_element.
1934 * tracepoint.h (while_stepping_cmd_element): New.
1936 2018-09-17 Tom Tromey <tom@tromey.com>
1938 * infrun.c (save_infcall_suspend_state): Return
1939 infcall_suspend_state_up.
1940 (save_infcall_control_state): Return infcall_control_state_up.
1941 * inferior.h (save_infcall_suspend_state)
1942 (save_infcall_control_state): Declare later. Return unique
1945 2018-09-17 Tom Tromey <tom@tromey.com>
1947 * infrun.c (struct stop_context): Declare constructor,
1948 destructor, "changed" method.
1949 (stop_context::stop_context): Rename from save_stop_context.
1950 (stop_context::~stop_context): Rename from
1951 release_stop_context_cleanup.
1952 (normal_stop): Update.
1953 (stop_context::changed): Rename from stop_context_changed. Return
1956 2018-09-17 Tom Tromey <tom@tromey.com>
1958 * inferior.h (struct infcall_suspend_state_deleter): New.
1959 (infcall_suspend_state_up): New typedef.
1960 (struct infcall_control_state_deleter): New.
1961 (infcall_control_state_up): New typedef.
1962 (make_cleanup_restore_infcall_suspend_state)
1963 (make_cleanup_restore_infcall_control_state): Don't declare.
1964 * infcall.c (call_function_by_hand_dummy): Update.
1965 * infrun.c (do_restore_infcall_suspend_state_cleanup)
1966 (make_cleanup_restore_infcall_suspend_state): Remove.
1967 (do_restore_infcall_control_state_cleanup)
1968 (make_cleanup_restore_infcall_control_state): Remove.
1970 2018-09-17 Tom Tromey <tom@tromey.com>
1972 * gdbthread.h (struct thread_control_state): Add initializer.
1973 (class thread_info) <control>: Remove initializer.
1974 * inferior.h (struct inferior_control_state): Add initializer.
1975 (class inferior) <control>: Remove initializer.
1976 (exit_inferior_1): Update.
1977 * infrun.c (struct infcall_control_state): Add constructors.
1978 (save_infcall_control_state): Use new.
1979 (restore_infcall_control_state, discard_infcall_control_state):
1982 2018-09-17 Tom Tromey <tom@tromey.com>
1984 * infrun.c (struct infcall_suspend_state) <registers>: Now a
1986 <siginfo_data>: Now a unique_xmalloc_ptr.
1987 (save_infcall_suspend_state, restore_infcall_suspend_state)
1988 (discard_infcall_suspend_state)
1989 (get_infcall_suspend_state_regcache): Update.
1991 2018-09-17 Tom Tromey <tom@tromey.com>
1993 * gdbthread.h (struct thread_suspend_state): Add initializers.
1994 (class thread_info) <suspend>: Remove initializer.
1995 * infrun.c (struct infcall_suspend_state): Add initializers.
1996 (save_infcall_suspend_state): Use new.
1997 (discard_infcall_suspend_state): Use delete.
1999 2018-09-16 Tom Tromey <tom@tromey.com>
2001 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
2003 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
2004 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
2005 (py_varobj_iter_new): Likewise.
2006 (py_varobj_get_iterator): Use gdbpy_ref.
2008 2018-09-16 Tom Tromey <tom@tromey.com>
2010 * python/py-threadevent.c (py_get_event_thread): Simplify.
2011 * python/py-inferior.c (infpy_thread_from_thread_handle):
2012 Return immediately after calling thread_to_thread_object. Use
2014 (thread_to_thread_object): Set the exception on a NULL return.
2016 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2018 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
2020 2018-09-16 Tom Tromey <tom@tromey.com>
2022 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
2025 2018-09-16 Tom Tromey <tom@tromey.com>
2027 * python/python-internal.h (thread_to_thread_object): Change
2029 * python/py-inferior.c (thread_to_thread_object): Return a new
2031 (infpy_thread_from_thread_handle): Update.
2032 * python/py-infthread.c (gdbpy_selected_thread): Update.
2033 * python/py-stopevent.c (create_stop_event_object): Update.
2034 * python/py-threadevent.c (py_get_event_thread): Return a new
2036 (py_get_event_thread): Update.
2037 * python/py-event.h (py_get_event_thread): Change return type.
2038 * python/py-continueevent.c (create_continue_event_object):
2041 2018-09-16 Tom Tromey <tom@tromey.com>
2043 * python/py-progspace.c (pspy_get_objfiles): Update.
2044 * python/python-internal.h (objfile_to_objfile_object): Change
2046 * python/py-newobjfileevent.c (create_new_objfile_event_object):
2048 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
2050 * python/python.c (gdbpy_get_current_objfile): Update.
2051 (gdbpy_objfiles): Update.
2052 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
2054 (objfile_to_objfile_object): Return a new reference.
2055 * python/py-symtab.c (stpy_get_objfile): Update.
2056 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
2059 2018-09-16 Tom Tromey <tom@tromey.com>
2061 * python/py-inferior.c (infpy_get_progspace): Update.
2062 * python/python-internal.h (pspace_to_pspace_object): Change
2064 * python/py-newobjfileevent.c
2065 (create_clear_objfiles_event_object): Update.
2066 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
2068 * python/python.c (gdbpy_get_current_progspace): Update.
2069 (gdbpy_progspaces): Update.
2070 * python/py-progspace.c (pspace_to_pspace_object): Return a new
2072 * python/py-objfile.c (objfpy_get_progspace): Update.
2073 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
2076 2018-09-16 Tom Tromey <tom@tromey.com>
2078 * python/lib/gdb/__init__.py (current_progspace, objfiles)
2079 (solib_name, block_for_pc, find_pc_line): New functions.
2080 (execute_unwinders): Update.
2081 * python/py-block.c (gdbpy_block_for_pc): Remove.
2082 * python/py-inferior.c (infpy_get_progspace): New function.
2083 (inferior_object_getset) <progspace>: Add.
2084 * python/py-progspace.c (pspy_objfiles): Rewrite.
2085 (pspy_solib_name, pspy_block_for_pc)
2086 (pspy_find_pc_line, pspy_is_valid): New functions.
2087 (progspace_object_methods): Add entries for solib_name,
2088 block_for_pc, find_pc_line, is_valid.
2089 * python/python-internal.h (gdbpy_block_for_pc)
2090 (build_objfiles_list): Don't declare.
2091 * python/python.c: Don't include solib.h.
2092 (gdbpy_solib_name, gdbpy_find_pc_line)
2093 (gdbpy_get_current_progspace, build_objfiles_list)
2094 (gdbpy_objfiles): Remove.
2095 (GdbMethods) <current_progspace, objfiles, block_for_pc,
2096 solib_name, find_pc_line>: Remove entries.
2098 2018-09-16 Tom Tromey <tom@tromey.com>
2100 * top.c (new_ui_command): Use GNU style for metasyntactic
2102 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
2104 * maint.c (maintenance_translate_address): Remove "<>" around
2106 * interps.c (interpreter_exec_cmd): Use GNU style for
2107 metasyntactic variables.
2108 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
2109 metasyntactic variables.
2110 * tracepoint.c (tfind_range_command): Use GNU style for
2111 metasyntactic variables.
2112 (tfind_outside_command): Likewise.
2113 (_initialize_tracepoint): Likewise.
2114 * remote.c (extended_remote_target::create_inferior): Use GNU
2115 style for metasyntactic variables.
2116 * sparc64-tdep.c (adi_examine_command): Use GNU style for
2117 metasyntactic variables.
2118 (adi_assign_command): Likewise.
2120 2018-09-16 Tom Tromey <tom@tromey.com>
2122 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
2123 metasyntactic variables. Print message if no disassembler options
2126 2018-09-15 Tom Tromey <tom@tromey.com>
2128 * infcmd.c (get_inferior_args): Return const char *.
2129 * inferior.h (get_inferior_args): Return type now const.
2130 * linux-tdep.c (linux_fill_prpsinfo): Update.
2131 * procfs.c (procfs_target::make_corefile_notes): Update.
2133 2018-09-07 Tom Tromey <tom@tromey.com>
2135 * python/python.c (execute_gdb_command): Call bpstat_do_actions
2138 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
2140 * nios2-tdep.c (nios2_type_align): New.
2141 (nios2_gdb_arch_init): Install type_align hook.
2143 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
2145 * eval.c (fake_method::fake_method): Call xzalloc directly for a
2146 type that is neither object file owned, nor gdbarch owned.
2147 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
2148 gdbarch is non-NULL.
2149 (alloc_type_instance): Allocate non-objfile owned types on the
2151 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
2152 using TYPE_ALLOC to ensure memory is allocated on the correct
2154 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
2155 obstack, or the gdbarch obstack.
2156 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
2158 2018-09-14 Tom Tromey <tom@tromey.com>
2160 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
2163 2018-09-14 Tom Tromey <tom@tromey.com>
2165 * nat/fork-inferior.c (get_startup_shell): Remove "static".
2167 2018-09-13 Tom Tromey <tom@tromey.com>
2169 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
2172 2018-09-13 Tom Tromey <tom@tromey.com>
2174 * exec.c (try_open_exec_file): Use std::string.
2176 2018-09-13 Tom Tromey <tom@tromey.com>
2178 * utils.h (gdb_bfd_errmsg): Return std::string.
2179 * exec.c (exec_file_attach): Update.
2180 * compile/compile-object-load.c (compile_object_load): Update.
2181 * utils.c (gdb_bfd_errmsg): Return std::string.
2183 2018-09-13 Tom Tromey <tom@tromey.com>
2185 * procfs.c (struct procinfo_deleter): New.
2186 (procinfo_up): New typedef.
2187 (do_destroy_procinfo_cleanup): Remove.
2188 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
2190 2018-09-13 Tom Tromey <tom@tromey.com>
2192 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
2194 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
2195 2018-09-13 Tom Tromey <tom@tromey.com>
2197 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
2198 (pspy_get_objfiles): New function.
2199 (progspace_object_methods): New.
2200 (pspace_object_type): Add tp_methods callback.
2201 * python/python-internal.h (build_objfiles_list): New
2203 * python/python.c (build_objfiles_list): New function.
2204 (gdbpy_objfiles): Implement using build_objfiles_list.
2205 * NEWS: Mention the Progspace.objfiles method.
2207 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
2209 * python/py-inferior.c (infpy_get_progspace): New function.
2210 (inferior_object_getset): Add progspace property.
2211 * NEWS: Mention the new property.
2213 2018-09-13 Tom Tromey <tom@tromey.com>
2216 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
2218 2018-09-13 Tom Tromey <tom@tromey.com>
2221 * rust-lang.c (rust_enum_variant): Now static.
2222 (rust_empty_enum_p): New function.
2223 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
2226 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
2228 * python/py-inferior.c (infpy_repr): New.
2229 (inferior_object_type): Register infpy_repr.
2230 * python/py-objfile.c (objfpy_repr): New.
2231 (objfile_object_type): Register objfpy_repr.
2233 2018-09-12 John Baldwin <jhb@FreeBSD.org>
2235 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
2237 2018-09-12 John Baldwin <jhb@FreeBSD.org>
2239 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
2242 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
2244 * common/common-utils.c: Don't include '<sys/stat.h>'.
2245 (is_regular_file): Move to...
2246 * common/filestuff.c (is_regular_file): ... here.
2247 * common/common-utils.h (is_regular_file): Move to...
2248 * common/filestuff.h (is_regular_file): ... here.
2250 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
2252 * skip.c (debug_skip): New variable.
2253 (skiplist_entry::do_skip_file_p): Add debug output.
2254 (skiplist_entry::do_skip_gfile_p): Likewise.
2255 (skiplist_entry::skip_function_p): Likewise.
2256 (_initialize_step_skip): Create debug command.
2257 * NEWS: Mention set/show debug skip.
2259 2018-09-11 Xavier Roirand <roirand@adacore.com>
2261 * darwin-nat.c (should_disable_startup_with_shell):
2263 (darwin_nat_target::create_inferior): Add call.
2265 2018-09-11 Xavier Roirand <roirand@adacore.com>
2267 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
2268 inf_port, msg_state>: Initialize.
2269 (struct darwin_thread_info) <signaled, single_step>: Change
2270 type and initialize.
2271 (struct darwin_thread_info) <event>: Initialize.
2273 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2277 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
2280 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2283 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
2287 * gnulib/aclocal.m4: Regenerate.
2288 * gnulib/config.in: Regenerate.
2289 * gnulib/configure: Regenerate.
2290 * gnulib/import/Makefile.am: Update.
2291 * gnulib/import/Makefile.in: Update.
2292 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
2293 * gnulib/import/_Noreturn.h: ... this.
2294 * gnulib/import/alloca.in.h: Update.
2295 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
2296 * gnulib/import/arg-nonnull.h: ... this.
2297 * gnulib/import/assure.h: Update.
2298 * gnulib/import/at-func.c: Update.
2299 * gnulib/import/basename-lgpl.c: Update.
2300 * gnulib/import/extra/snippet/c++defs.h: Rename to...
2301 * gnulib/import/c++defs.h: ... this.
2302 * gnulib/import/canonicalize-lgpl.c: Update.
2303 * gnulib/import/cdefs.h: Update.
2304 * gnulib/import/chdir-long.c: Update.
2305 * gnulib/import/chdir-long.h: Update.
2306 * gnulib/import/cloexec.c: Update.
2307 * gnulib/import/cloexec.h: Update.
2308 * gnulib/import/close.c: Update.
2309 * gnulib/import/closedir.c: Update.
2310 * gnulib/import/config.charset: Update.
2311 * gnulib/import/dirent-private.h: Update.
2312 * gnulib/import/dirent.in.h: Update.
2313 * gnulib/import/dirfd.c: Update.
2314 * gnulib/import/dirname-lgpl.c: Update.
2315 * gnulib/import/dirname.h: Update.
2316 * gnulib/import/dosname.h: Update.
2317 * gnulib/import/dup-safer-flag.c: Update.
2318 * gnulib/import/dup-safer.c: Update.
2319 * gnulib/import/dup.c: Update.
2320 * gnulib/import/dup2.c: Update.
2321 * gnulib/import/errno.in.h: Update.
2322 * gnulib/import/error.c: Update.
2323 * gnulib/import/error.h: Update.
2324 * gnulib/import/exitfail.c: Update.
2325 * gnulib/import/exitfail.h: Update.
2326 * gnulib/import/extra/update-copyright: Update.
2327 * gnulib/import/fchdir.c: Update.
2328 * gnulib/import/fcntl.c: Update.
2329 * gnulib/import/fcntl.in.h: Update.
2330 * gnulib/import/fd-hook.c: Update.
2331 * gnulib/import/fd-hook.h: Update.
2332 * gnulib/import/fd-safer-flag.c: Update.
2333 * gnulib/import/fd-safer.c: Update.
2334 * gnulib/import/fdopendir.c: Update.
2335 * gnulib/import/filename.h: Update.
2336 * gnulib/import/filenamecat-lgpl.c: Update.
2337 * gnulib/import/filenamecat.h: Update.
2338 * gnulib/import/flexmember.h: Update.
2339 * gnulib/import/float+.h: Update.
2340 * gnulib/import/float.c: Update.
2341 * gnulib/import/float.in.h: Update.
2342 * gnulib/import/fnmatch.c: Update.
2343 * gnulib/import/fnmatch.in.h: Update.
2344 * gnulib/import/fnmatch_loop.c: Update.
2345 * gnulib/import/fpucw.h: Update.
2346 * gnulib/import/frexp.c: Update.
2347 * gnulib/import/frexpl.c: Update.
2348 * gnulib/import/fstat.c: Update.
2349 * gnulib/import/fstatat.c: Update.
2350 * gnulib/import/getcwd-lgpl.c: Update.
2351 * gnulib/import/getcwd.c: Update.
2352 * gnulib/import/getdtablesize.c: Update.
2353 * gnulib/import/getlogin_r.c: Update.
2354 * gnulib/import/getprogname.c: Update.
2355 * gnulib/import/getprogname.h: Update.
2356 * gnulib/import/gettext.h: Update.
2357 * gnulib/import/gettimeofday.c: Update.
2358 * gnulib/import/glob-libc.h: Update.
2359 * gnulib/import/glob.c: Update.
2360 * gnulib/import/glob.in.h: Update.
2361 * gnulib/import/glob_internal.h: Update.
2362 * gnulib/import/glob_pattern_p.c: Update.
2363 * gnulib/import/globfree.c: Update.
2364 * gnulib/import/hard-locale.c: Update.
2365 * gnulib/import/hard-locale.h: Update.
2366 * gnulib/import/intprops.h: Update.
2367 * gnulib/import/inttypes.in.h: Update.
2368 * gnulib/import/isnan.c: Update.
2369 * gnulib/import/isnand-nolibm.h: Update.
2370 * gnulib/import/isnand.c: Update.
2371 * gnulib/import/isnanl-nolibm.h: Update.
2372 * gnulib/import/isnanl.c: Update.
2373 * gnulib/import/itold.c: Update.
2374 * gnulib/import/libc-config.h: Update.
2375 * gnulib/import/limits.in.h: Update.
2376 * gnulib/import/localcharset.c: Update.
2377 * gnulib/import/localcharset.h: Update.
2378 * gnulib/import/localtime-buffer.c: Update.
2379 * gnulib/import/localtime-buffer.h: Update.
2380 * gnulib/import/lstat.c: Update.
2381 * gnulib/import/m4/00gnulib.m4: Update.
2382 * gnulib/import/m4/__inline.m4: Update.
2383 * gnulib/import/m4/absolute-header.m4: Update.
2384 * gnulib/import/m4/alloca.m4: Update.
2385 * gnulib/import/m4/builtin-expect.m4: Update.
2386 * gnulib/import/m4/canonicalize.m4: Update.
2387 * gnulib/import/m4/chdir-long.m4: Update.
2388 * gnulib/import/m4/close.m4: Update.
2389 * gnulib/import/m4/closedir.m4: Update.
2390 * gnulib/import/m4/configmake.m4: Update.
2391 * gnulib/import/m4/d-ino.m4: Update.
2392 * gnulib/import/m4/d-type.m4: Update.
2393 * gnulib/import/m4/dirent_h.m4: Update.
2394 * gnulib/import/m4/dirfd.m4: Update.
2395 * gnulib/import/m4/dirname.m4: Update.
2396 * gnulib/import/m4/double-slash-root.m4: Update.
2397 * gnulib/import/m4/dup.m4: Update.
2398 * gnulib/import/m4/dup2.m4: Update.
2399 * gnulib/import/m4/eealloc.m4: Update.
2400 * gnulib/import/m4/environ.m4: Update.
2401 * gnulib/import/m4/errno_h.m4: Update.
2402 * gnulib/import/m4/error.m4: Update.
2403 * gnulib/import/m4/exponentd.m4: Update.
2404 * gnulib/import/m4/exponentl.m4: Update.
2405 * gnulib/import/m4/extensions.m4: Update.
2406 * gnulib/import/m4/extern-inline.m4: Update.
2407 * gnulib/import/m4/fchdir.m4: Update.
2408 * gnulib/import/m4/fcntl-o.m4: Update.
2409 * gnulib/import/m4/fcntl.m4: Update.
2410 * gnulib/import/m4/fcntl_h.m4: Update.
2411 * gnulib/import/m4/fdopendir.m4: Update.
2412 * gnulib/import/m4/filenamecat.m4: Update.
2413 * gnulib/import/m4/flexmember.m4: Update.
2414 * gnulib/import/m4/float_h.m4: Update.
2415 * gnulib/import/m4/fnmatch.m4: Update.
2416 * gnulib/import/m4/fnmatch_h.m4: Update.
2417 * gnulib/import/m4/fpieee.m4: Update.
2418 * gnulib/import/m4/frexp.m4: Update.
2419 * gnulib/import/m4/frexpl.m4: Update.
2420 * gnulib/import/m4/fstat.m4: Update.
2421 * gnulib/import/m4/fstatat.m4: Update.
2422 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
2423 * gnulib/import/m4/getcwd-path-max.m4: Update.
2424 * gnulib/import/m4/getcwd.m4: Update.
2425 * gnulib/import/m4/getdtablesize.m4: Update.
2426 * gnulib/import/m4/getlogin.m4: Update.
2427 * gnulib/import/m4/getlogin_r.m4: Update.
2428 * gnulib/import/m4/getpagesize.m4: Update.
2429 * gnulib/import/m4/getprogname.m4: Update.
2430 * gnulib/import/m4/gettimeofday.m4: Update.
2431 * gnulib/import/m4/glibc21.m4: Update.
2432 * gnulib/import/m4/glob.m4: Update.
2433 * gnulib/import/m4/glob_h.m4: Update.
2434 * gnulib/import/m4/gnulib-cache.m4: Update.
2435 * gnulib/import/m4/gnulib-common.m4: Update.
2436 * gnulib/import/m4/gnulib-comp.m4: Update.
2437 * gnulib/import/m4/gnulib-tool.m4: Update.
2438 * gnulib/import/m4/hard-locale.m4: Update.
2439 * gnulib/import/m4/include_next.m4: Update.
2440 * gnulib/import/m4/inttypes-pri.m4: Update.
2441 * gnulib/import/m4/inttypes.m4: Update.
2442 * gnulib/import/m4/isnand.m4: Update.
2443 * gnulib/import/m4/isnanl.m4: Update.
2444 * gnulib/import/m4/largefile.m4: Update.
2445 * gnulib/import/m4/limits-h.m4: Update.
2446 * gnulib/import/m4/localcharset.m4: Update.
2447 * gnulib/import/m4/locale-fr.m4: Update.
2448 * gnulib/import/m4/locale-ja.m4: Update.
2449 * gnulib/import/m4/locale-zh.m4: Update.
2450 * gnulib/import/m4/localtime-buffer.m4: Update.
2451 * gnulib/import/m4/longlong.m4: Update.
2452 * gnulib/import/m4/lstat.m4: Update.
2453 * gnulib/import/m4/malloc.m4: Update.
2454 * gnulib/import/m4/malloca.m4: Update.
2455 * gnulib/import/m4/math_h.m4: Update.
2456 * gnulib/import/m4/mbrtowc.m4: Update.
2457 * gnulib/import/m4/mbsinit.m4: Update.
2458 * gnulib/import/m4/mbsrtowcs.m4: Update.
2459 * gnulib/import/m4/mbstate_t.m4: Update.
2460 * gnulib/import/m4/memchr.m4: Update.
2461 * gnulib/import/m4/memmem.m4: Update.
2462 * gnulib/import/m4/mempcpy.m4: Update.
2463 * gnulib/import/m4/memrchr.m4: Update.
2464 * gnulib/import/m4/mkdir.m4: Update.
2465 * gnulib/import/m4/mkstemp.m4: Update.
2466 * gnulib/import/m4/mmap-anon.m4: Update.
2467 * gnulib/import/m4/mode_t.m4: Update.
2468 * gnulib/import/m4/msvc-inval.m4: Update.
2469 * gnulib/import/m4/msvc-nothrow.m4: Update.
2470 * gnulib/import/m4/multiarch.m4: Update.
2471 * gnulib/import/m4/nocrash.m4: Update.
2472 * gnulib/import/m4/off_t.m4: Update.
2473 * gnulib/import/m4/onceonly.m4: Update.
2474 * gnulib/import/m4/open-cloexec.m4: Update.
2475 * gnulib/import/m4/open.m4: Update.
2476 * gnulib/import/m4/openat.m4: Update.
2477 * gnulib/import/m4/opendir.m4: Update.
2478 * gnulib/import/m4/pathmax.m4: Update.
2479 * gnulib/import/m4/rawmemchr.m4: Update.
2480 * gnulib/import/m4/readdir.m4: Update.
2481 * gnulib/import/m4/readlink.m4: Update.
2482 * gnulib/import/m4/realloc.m4: Update.
2483 * gnulib/import/m4/rename.m4: Update.
2484 * gnulib/import/m4/rewinddir.m4: Update.
2485 * gnulib/import/m4/rmdir.m4: Update.
2486 * gnulib/import/m4/save-cwd.m4: Update.
2487 * gnulib/import/m4/secure_getenv.m4: Update.
2488 * gnulib/import/m4/setenv.m4: Update.
2489 * gnulib/import/m4/signal_h.m4: Update.
2490 * gnulib/import/m4/ssize_t.m4: Update.
2491 * gnulib/import/m4/stat-time.m4: Update.
2492 * gnulib/import/m4/stat.m4: Update.
2493 * gnulib/import/m4/std-gnu11.m4: Update.
2494 * gnulib/import/m4/stdbool.m4: Update.
2495 * gnulib/import/m4/stddef_h.m4: Update.
2496 * gnulib/import/m4/stdint.m4: Update.
2497 * gnulib/import/m4/stdio_h.m4: Update.
2498 * gnulib/import/m4/stdlib_h.m4: Update.
2499 * gnulib/import/m4/strchrnul.m4: Update.
2500 * gnulib/import/m4/strdup.m4: Update.
2501 * gnulib/import/m4/strerror.m4: Update.
2502 * gnulib/import/m4/string_h.m4: Update.
2503 * gnulib/import/m4/strstr.m4: Update.
2504 * gnulib/import/m4/strtok_r.m4: Update.
2505 * gnulib/import/m4/sys_socket_h.m4: Update.
2506 * gnulib/import/m4/sys_stat_h.m4: Update.
2507 * gnulib/import/m4/sys_time_h.m4: Update.
2508 * gnulib/import/m4/sys_types_h.m4: Update.
2509 * gnulib/import/m4/tempname.m4: Update.
2510 * gnulib/import/m4/time_h.m4: Update.
2511 * gnulib/import/m4/unistd-safer.m4: Update.
2512 * gnulib/import/m4/unistd_h.m4: Update.
2513 * gnulib/import/m4/warn-on-use.m4: Update.
2514 * gnulib/import/m4/wchar_h.m4: Update.
2515 * gnulib/import/m4/wchar_t.m4: Update.
2516 * gnulib/import/m4/wctype_h.m4: Update.
2517 * gnulib/import/m4/wint_t.m4: Update.
2518 * gnulib/import/malloc.c: Update.
2519 * gnulib/import/malloc/scratch_buffer.h: Update.
2520 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
2521 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
2522 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
2523 * gnulib/import/malloca.c: Update.
2524 * gnulib/import/malloca.h: Update.
2525 * gnulib/import/malloca.valgrind: Update.
2526 * gnulib/import/math.in.h: Update.
2527 * gnulib/import/mbrtowc.c: Update.
2528 * gnulib/import/mbsinit.c: Update.
2529 * gnulib/import/mbsrtowcs-impl.h: Update.
2530 * gnulib/import/mbsrtowcs-state.c: Update.
2531 * gnulib/import/mbsrtowcs.c: Update.
2532 * gnulib/import/memchr.c: Update.
2533 * gnulib/import/memmem.c: Update.
2534 * gnulib/import/mempcpy.c: Update.
2535 * gnulib/import/memrchr.c: Update.
2536 * gnulib/import/mkdir.c: Update.
2537 * gnulib/import/mkstemp.c: Update.
2538 * gnulib/import/msvc-inval.c: Update.
2539 * gnulib/import/msvc-inval.h: Update.
2540 * gnulib/import/msvc-nothrow.c: Update.
2541 * gnulib/import/msvc-nothrow.h: Update.
2542 * gnulib/import/open.c: Update.
2543 * gnulib/import/openat-die.c: Update.
2544 * gnulib/import/openat-priv.h: Update.
2545 * gnulib/import/openat-proc.c: Update.
2546 * gnulib/import/openat.c: Update.
2547 * gnulib/import/openat.h: Update.
2548 * gnulib/import/opendir.c: Update.
2549 * gnulib/import/pathmax.h: Update.
2550 * gnulib/import/pipe-safer.c: Update.
2551 * gnulib/import/rawmemchr.c: Update.
2552 * gnulib/import/readdir.c: Update.
2553 * gnulib/import/readlink.c: Update.
2554 * gnulib/import/realloc.c: Update.
2555 * gnulib/import/ref-add.sin: Update.
2556 * gnulib/import/ref-del.sin: Update.
2557 * gnulib/import/rename.c: Update.
2558 * gnulib/import/rewinddir.c: Update.
2559 * gnulib/import/rmdir.c: Update.
2560 * gnulib/import/same-inode.h: Update.
2561 * gnulib/import/save-cwd.c: Update.
2562 * gnulib/import/save-cwd.h: Update.
2563 * gnulib/import/scratch_buffer.h: Update.
2564 * gnulib/import/secure_getenv.c: Update.
2565 * gnulib/import/setenv.c: Update.
2566 * gnulib/import/signal.in.h: Update.
2567 * gnulib/import/stat-time.c: Update.
2568 * gnulib/import/stat-time.h: Update.
2569 * gnulib/import/stat-w32.c: Update.
2570 * gnulib/import/stat-w32.h: Update.
2571 * gnulib/import/stat.c: Update.
2572 * gnulib/import/stdbool.in.h: Update.
2573 * gnulib/import/stddef.in.h: Update.
2574 * gnulib/import/stdint.in.h: Update.
2575 * gnulib/import/stdio.in.h: Update.
2576 * gnulib/import/stdlib.in.h: Update.
2577 * gnulib/import/str-two-way.h: Update.
2578 * gnulib/import/strchrnul.c: Update.
2579 * gnulib/import/strdup.c: Update.
2580 * gnulib/import/streq.h: Update.
2581 * gnulib/import/strerror-override.c: Update.
2582 * gnulib/import/strerror-override.h: Update.
2583 * gnulib/import/strerror.c: Update.
2584 * gnulib/import/string.in.h: Update.
2585 * gnulib/import/stripslash.c: Update.
2586 * gnulib/import/strnlen1.c: Update.
2587 * gnulib/import/strnlen1.h: Update.
2588 * gnulib/import/strstr.c: Update.
2589 * gnulib/import/strtok_r.c: Update.
2590 * gnulib/import/sys_stat.in.h: Update.
2591 * gnulib/import/sys_time.in.h: Update.
2592 * gnulib/import/sys_types.in.h: Update.
2593 * gnulib/import/tempname.c: Update.
2594 * gnulib/import/tempname.h: Update.
2595 * gnulib/import/time.in.h: Update.
2596 * gnulib/import/unistd--.h: Update.
2597 * gnulib/import/unistd-safer.h: Update.
2598 * gnulib/import/unistd.in.h: Update.
2599 * gnulib/import/unsetenv.c: Update.
2600 * gnulib/import/verify.h: Update.
2601 * gnulib/import/extra/snippet/warn-on-use.h: Update.
2602 * gnulib/import/wchar.in.h: Update.
2603 * gnulib/import/wctype.in.h: Update.
2604 * gnulib/import/xalloc-oversized.h: Update.
2605 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
2606 "53e2c179f26a890fa6685af4b6c1397ee370433b".
2608 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
2610 * record-btrace.c (get_thread_current_frame): Remove
2613 2018-09-10 Jerome Guitton <guitton@adacore.com>
2615 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
2616 with check_tag to 1 if and only if the type is tagged and the
2617 component being searched cannot been found in the current
2618 view. Otherwise, always call ada_to_fixed_type with
2621 2018-09-10 Xavier Roirand <roirand@adacore.com>
2623 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
2625 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
2626 * ada-varobj.c (ada_varobj_get_number_of_children,
2627 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
2629 2018-09-10 Xavier Roirand <roirand@adacore.com>
2631 * ada-valprint.c (ada_value_print): Use type instead of
2634 2018-09-10 Xavier Roirand <roirand@adacore.com>
2636 * ada-lang.c (ada_value_subscript): Handle case when parameter is
2637 an array of access to unconstrained array.
2639 2018-09-10 Xavier Roirand <roirand@adacore.com>
2641 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
2642 (ada_check_typedef): Use it.
2644 2018-09-10 Xavier Roirand <roirand@adacore.com>
2646 * ada-varobj.c (ada_varobj_describe_struct_child)
2647 (ada_varobj_describe_child): Handle union case like struct one.
2649 2018-09-10 Tom Tromey <tom@tromey.com>
2652 * python/python.c (_initialize_python): Make example in "python"
2653 help work in Python 3.
2655 2018-09-10 Eli Zaretskii <eliz@gnu.org>
2657 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
2658 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
2659 $(EXEEXT) to the script, as it is not a program.
2661 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
2663 * python/py-prettyprint.c (pretty_print_one_value): Return
2665 (print_string_repr): Adjust.
2666 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
2667 * python/python-internal.h (apply_varobj_pretty_printer): Return
2669 * varobj.c (varobj_value_get_print_value): Adjust.
2671 2018-09-08 Tom Tromey <tom@tromey.com>
2674 * python/py-prettyprint.c (pretty_print_one_value): Check for
2677 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2679 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
2680 replace_operator_with_call.
2682 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2684 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
2686 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2688 * ada-typeprint.c (print_range): Print the bounds using TYPE
2689 rather than its TYPE_TARGET_TYPE.
2691 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2693 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
2694 call to ada_to_fixed_value_create.
2696 2018-09-08 Jerome Guitton <guitton@adacore.com>
2698 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
2700 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2702 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
2705 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2707 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
2708 Move update of loop variable "fi".
2710 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2712 * ada-lang.c (value_assign_to_component): In the case of
2713 big-endian targets, extract the bits of the given VAL
2714 using an src_offset of zero if container is not a scalar.
2716 2018-09-06 Simon Ser <contact@emersion.fr>
2719 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
2720 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
2721 * fbsd-tdep.c (fbsd_make_note_desc): New.
2722 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
2723 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
2724 * target.h (enum target_object) Add FreeBSD-specific
2725 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
2727 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
2729 * compile/compile-c.h (generate_c_for_variable_locations):
2730 Change reference to pointer.
2731 * compile/compile-c-support.c (compile_program) <compute>:
2733 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
2734 (generate_c_for_for_one_variable): Likewise
2735 (generate_c_for_variable_locations): Likewise
2736 * compile/compile-c-types.c (compile_c_instance::convert_type):
2738 * compile/compile-cplus-symbols.c (convert_one_symbol):
2739 std::move the scope passed to enter_scope.
2740 * compile/compile-cplus-types.c
2741 (compile_cplus_instance::enter_scope): Make parameter
2743 (compile_cplus_instance::new_scope): Change reference to
2745 (compile_cplus_instance::convert_type): Likewise
2746 (compile_cplus_convert_typedef): std::move the scope passed to
2748 (compile_cplus_convert_struct_or_union): Likewise.
2749 (compile_cplus_convert_enum): Likewise.
2750 (compile_cplus_convert_namespace): Likewise.
2751 * compile/compile-cplus.h (compile_cplus_instance)
2752 <enter_scope>: Make parameter rvalue-reference.
2753 * compile/compile-internal.h (compile_instance)
2754 <get_cached_type>: Likewise
2755 * compile/compile-loc2c.c (push): Likewise
2759 (print_label): Likewise
2760 (pushf_register_address): Likewise
2761 (pushf_register): Likewise
2762 (do_compile_dwarf_expr_to_c): Likewise
2763 (compile_dwarf_expr_to_c): Likewise
2764 (compile_dwarf_bounds_to_c): Likewise
2765 * compile/compile.c (compile_instance::get_cached_type):
2767 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
2768 (compile_dwarf_bounds_to_c): Likewise
2769 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
2770 (dwarf2_compile_property_to_c): Likewise
2771 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
2772 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
2775 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
2777 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
2778 * tui/tui-data.c (init_content_element): Don't initialize it.
2780 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
2782 * tui/tui-data.h (struct tui_win_info)
2783 <detail::opaque>: Remove.
2784 * tui/tui-data.c (init_win_info): Remove assignment.
2786 2018-09-05 Tom Tromey <tom@tromey.com>
2788 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
2789 -Wformat-nonliteral.
2790 * target-float.c (host_float_ops<T>::to_string)
2791 (host_float_ops<T>::from_string): Use
2792 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
2793 * configure: Rebuild.
2795 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
2797 * printcmd.c (printf_c_string): Use
2798 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
2799 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
2801 2018-09-05 Tom Tromey <tom@tromey.com>
2803 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
2805 2018-09-05 Tom de Vries <tdevries@suse.de>
2807 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
2808 with resolve_abstract_p == true.
2809 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
2810 defaulting to false. Propagate resolve_abstract_p to
2811 dwarf2_fetch_die_loc_sect_off.
2812 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
2813 parameter, defaulting to false.
2814 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
2815 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
2817 * dwarf2read.h (struct die_info): Forward-declare.
2818 (die_info_ptr): New typedef.
2819 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
2821 2018-09-05 Joel Brobecker <brobecker@adacore.com>
2825 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
2826 Pedro Alves <palves@redhat.com>
2828 * gnulib/Makefile.in (aclocal_m4_deps): Move to
2829 "aclocal-m4-deps.mk". Include file here.
2830 $(srcdir)/aclocal.m4: Add "configure.ac".
2831 * gnulib/aclocal-m4-deps.mk: New file.
2832 * gnulib/update-gnulib.sh: Automatically update
2833 "aclocal-m4-deps.mk".
2835 2018-09-04 Tom Tromey <tom@tromey.com>
2837 * configure: Rebuild.
2838 * configure.ac: Remove multi-ice code.
2840 2018-09-04 Tom Tromey <tom@tromey.com>
2842 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
2843 (ada-exp.o): Update.
2845 2018-09-04 Tom Tromey <tom@tromey.com>
2847 * Makefile.in (printcmd.o, target-float.o): Remove.
2848 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
2850 2018-09-04 Tom Tromey <tom@tromey.com>
2852 * gnulib/Makefile.in: Remove obsolete comment.
2853 * Makefile.in: Remove obsolete comment.
2855 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
2857 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
2860 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
2862 * riscv-tdep.c: Add 'prologue-value.h' include.
2863 (struct riscv_unwind_cache): New struct.
2864 (riscv_debug_unwinder): New global.
2865 (riscv_scan_prologue): Update arguments, capture register details
2867 (riscv_skip_prologue): Reformat arguments line, move end of
2868 prologue calculation into riscv_scan_prologue.
2869 (riscv_frame_cache): Update return type, create
2870 riscv_unwind_cache, scan the prologue, and fill in remaining cache
2872 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
2873 (riscv_frame_prev_register): Use the trad_frame within the
2875 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
2878 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
2880 * trad-frame.h (trad_frame_set_realreg): Declare.
2881 (trad_frame_set_addr): Declare.
2882 * trad-frame.c (trad_frame_set_realreg): Define new function.
2883 (trad_frame_set_addr): Define new function.
2884 (trad_frame_set_reg_realreg): Use new function.
2885 (trad_frame_set_reg_addr): Use new function.
2887 2018-09-01 Keith Seitz <keiths@redhat.com>
2889 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
2890 pulongest instead of "%lld".
2891 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
2894 2018-08-31 Tom Tromey <tom@tromey.com>
2896 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
2899 2018-08-31 Pedro Alves <palves@redhat.com>
2901 * gdbarch.h: Regenerate.
2903 2018-08-31 Pedro Alves <palves@redhat.com>
2905 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
2906 * target.h (Hardware watchpoint interfaces): Describe
2907 continuable/steppable/non-steppable watchpoints.
2908 * gdbarch.h, gdbarch.c: Regenerate.
2910 2018-08-31 Pedro Alves <palves@redhat.com>
2912 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
2915 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
2916 * target.h (target_ops::have_continuable_watchpoint): Delete.
2917 (target_have_continuable_watchpoint): Delete.
2918 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
2919 * target-delegates.c: Regenerate.
2921 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2923 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
2924 the files present in "gnulib/import/m4/".
2926 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2928 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
2929 c.sw, c.swsp, and c.sdsp.
2931 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2933 * riscv-tdep.c (struct riscv_inferior_data): Delete.
2934 (riscv_read_misa_reg): Don't cache value read into inferior data.
2935 (riscv_new_inferior_data): Delete.
2936 (riscv_inferior_data_cleanup): Delete.
2937 (riscv_inferior_data): Delete.
2938 (riscv_invalidate_inferior_data): Delete.
2939 (_initialize_riscv_tdep): Remove initialisation of inferior data.
2941 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
2943 * compile/compile-cplus-types.c
2944 (compile_cplus_instance::leave_scope): Take the address of scope
2946 (compile_cplus_instance::convert_qualified_base): Compare quals
2949 2018-08-30 Keith Seitz <keiths@redhat.com>
2951 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
2952 Use "%s" and host_address_to_string instead of "%p" in printf.
2954 2018-08-29 Keith Seitz <keiths@redhat.com>
2956 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
2957 and compile-cplus-types.c.
2958 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
2959 * c-lang.c (cplus_language_defn): Set C++ compile functions.
2960 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
2962 * compile/compile-c-support.c: Include compile-cplus.h.
2963 (load_libcompile): Templatize.
2964 (get_compile_context): "New" function.
2965 (c_get_compile_context): Use get_compile_context.
2966 (cplus_get_compile_context): New function.
2967 (cplus_push_user_expression, cplus_pop_user_expression)
2968 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
2969 (cplus_compute_program): Define new structs/functions.
2970 * compile/compile-cplus-symmbols.c: New file.
2971 * compile/compile-cplus-types.c: New file.
2972 * compile/compile-cplus.h: New file.
2973 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
2975 * compile/compile-object-load.c (get_out_value_type): Use
2976 strncmp_iw when comparing symbol names.
2977 (compile_object_load): Add mst_bss and mst_data.
2978 * compile/compile.c (_initialize_compile): Remove
2979 -Wno-implicit-function-declaration from `compile_args'.
2980 * compile/gcc-cp-plugin.h: New file.
2981 * NEWS: Mention C++ compile support and new debug options.
2983 2018-08-29 Keith Seitz <keiths@redhat.com>
2985 * linespec.c (collect_info::add_symbol): Make virtual.
2986 (struct symbol_searcher_collect_info): New struct.
2987 (symbol_searcher::find_all_symbols): New method.
2988 * symtab.h (class symbol_searcher): New class.
2990 2018-08-29 Keith Seitz <keiths@redhat.com>
2992 * linespec.c (struct linespec) <function_symbols, label_symbols>:
2993 Change to vector of block_symbol. Update all users.
2994 (struct collect_info) <symbols>: Likewise.
2995 (collect_info::add_symbol): Take block_symbol as argument.
2997 (decode_compound_collector) <m_symbols>: Change type to vector
2998 of block_symbol. Update all users.
2999 (decode_compound_collector::operator ()): Change parameter type
3001 (find_method, find_function_symbols, find_linespec_symbols)
3002 (find_label_symbols_in_block, find_label_symbols): Change symbol
3003 vectors to block_symbol vectors.
3004 * symtab.h (symbol_found_callback_ftype): Change parameter type to
3007 2018-08-29 Keith Seitz <keiths@redhat.com>
3009 * linespec.c (symbolp): Remove typedef and VEC definitions.
3010 (bound_minimal_symbol_d): Likewise.
3012 2018-08-29 Keith Seitz <keiths@redhat.com>
3014 * linespec.c (decode_compound_collector::decode_compound_collector):
3015 Remove initialization for `m_symtabs'.
3016 (decode_compound_collector::release_symbols): Change return type
3017 to std::vector. Update all callers.
3018 (class decode_compound_collector) <m_symbols>: Change type to
3020 (lookup_prefix_sym): Change return type to std::vector. Update all
3022 (compare_symbols): Remove.
3023 (std_compare_symbols): Rename to `compare_symbols'.
3024 (find_method): Change `sym_classes' parameter to std::vector.
3025 Update all callers. Use std::sort to sort sym_classes.
3026 (find_linespec_symbols): Remove cleanup.
3028 2018-08-29 Keith Seitz <keiths@redhat.com>
3030 * linespec.c (struct linespec) <minimal_symbols>: Change type to
3031 std::vector. Update all users.
3032 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
3033 (struct collect_info) <minimal_symbols>: Likewise.
3034 (compare_msymbols): Return bool. Change parameters to const
3035 bound_minimal_symbol references.
3036 (find_method, find_function_symbols, find_linespec_symbols): Change
3037 `minsyms' parameter to std::vector. Update all callers.
3039 2018-08-29 Keith Seitz <keiths@redhat.com>
3041 * linespec.c (struct linespec) <label_symbols>: Change type to
3042 std::vector. Update all users.
3043 (find_label_symbols_in_block): Change `result' parameter to
3044 std::vector. Update all callers.
3045 (find_label_symbols): Return std::vector. Update all callers.
3047 2018-08-29 Keith Seitz <keiths@redhat.com>
3049 * linespec.c (struct linespec) <function_symbols>: Change type to
3050 std::vector. Update all users.
3051 (struct collect_info) <function_symbols>: Likewise.
3052 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
3053 (std_compare_symbols): New function.
3054 (find_method, find_function_symbols, find_linespec_symbols)
3055 (find_label_symbols_in_block): Change `symbols' parameter to
3056 std::vector. Update all callers.
3057 (find_label_symbols): Likewise for `function_symbols' and
3060 2018-08-29 Keith Seitz <keiths@redhat.com>
3062 * linespec.c (symtab_vector_up): Define.
3063 (struct linespec) <file_symtabs>: Change type to std::vector *.
3065 (struct collect_info) <file_symtabs>: Likewise.
3066 (collect_symtabs_from_filename): Return symtab_vector_up.
3068 (decode_objc): Remove cleanup.
3069 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
3070 (symtab_collector::release_symtabs): Return symtab_vector_up.
3072 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
3074 (collect_symtabs_from_filename, symtabs_from_filename): Return
3075 symtab_vector_up. Update all callers.
3077 2018-08-29 Tom Tromey <tom@tromey.com>
3079 * csky-tdep.c (csky_analyze_prologue): Use
3080 core_addr_to_string_nz.
3082 2018-08-29 Tom Tromey <tom@tromey.com>
3084 * windows-nat.c (struct xlate_exception) <them>: Change type to
3086 (xlate): Fix formatting. Remove last entry.
3087 (struct xlate_exception, xlate): Comment out.
3088 (windows_nat_target::resume): Use ranged for.
3090 2018-08-29 Jim Wilson <jimw@sifive.com>
3092 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
3093 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
3095 (riscv_linux_nat_target::store_registers): Likewise.
3097 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
3101 * gnulib/aclocal.m4: Regenerate.
3102 * gnulib/config.in: Regenerate.
3103 * gnulib/configure: Regenerate.
3104 * gnulib/import/Makefile.am: Update.
3105 * gnulib/import/Makefile.in: Update.
3106 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
3107 * gnulib/import/_Noreturn.h: ... this.
3108 * gnulib/import/alloca.in.h: Update.
3109 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
3110 * gnulib/import/arg-nonnull.h: ... this.
3111 * gnulib/import/assure.h: Update.
3112 * gnulib/import/at-func.c: Update.
3113 * gnulib/import/basename-lgpl.c: Update.
3114 * gnulib/import/extra/snippet/c++defs.h: Rename to...
3115 * gnulib/import/c++defs.h: ... this.
3116 * gnulib/import/canonicalize-lgpl.c: Update.
3117 * gnulib/import/cdefs.h: Update.
3118 * gnulib/import/chdir-long.c: Update.
3119 * gnulib/import/chdir-long.h: Update.
3120 * gnulib/import/cloexec.c: Update.
3121 * gnulib/import/cloexec.h: Update.
3122 * gnulib/import/close.c: Update.
3123 * gnulib/import/closedir.c: Update.
3124 * gnulib/import/config.charset: Update.
3125 * gnulib/import/dirent-private.h: Update.
3126 * gnulib/import/dirent.in.h: Update.
3127 * gnulib/import/dirfd.c: Update.
3128 * gnulib/import/dirname-lgpl.c: Update.
3129 * gnulib/import/dirname.h: Update.
3130 * gnulib/import/dosname.h: Update.
3131 * gnulib/import/dup-safer-flag.c: Update.
3132 * gnulib/import/dup-safer.c: Update.
3133 * gnulib/import/dup.c: Update.
3134 * gnulib/import/dup2.c: Update.
3135 * gnulib/import/errno.in.h: Update.
3136 * gnulib/import/error.c: Update.
3137 * gnulib/import/error.h: Update.
3138 * gnulib/import/exitfail.c: Update.
3139 * gnulib/import/exitfail.h: Update.
3140 * gnulib/import/extra/update-copyright: Update.
3141 * gnulib/import/fchdir.c: Update.
3142 * gnulib/import/fcntl.c: Update.
3143 * gnulib/import/fcntl.in.h: Update.
3144 * gnulib/import/fd-hook.c: Update.
3145 * gnulib/import/fd-hook.h: Update.
3146 * gnulib/import/fd-safer-flag.c: Update.
3147 * gnulib/import/fd-safer.c: Update.
3148 * gnulib/import/fdopendir.c: Update.
3149 * gnulib/import/filename.h: Update.
3150 * gnulib/import/filenamecat-lgpl.c: Update.
3151 * gnulib/import/filenamecat.h: Update.
3152 * gnulib/import/flexmember.h: Update.
3153 * gnulib/import/float+.h: Update.
3154 * gnulib/import/float.c: Update.
3155 * gnulib/import/float.in.h: Update.
3156 * gnulib/import/fnmatch.c: Update.
3157 * gnulib/import/fnmatch.in.h: Update.
3158 * gnulib/import/fnmatch_loop.c: Update.
3159 * gnulib/import/fpucw.h: Update.
3160 * gnulib/import/frexp.c: Update.
3161 * gnulib/import/frexpl.c: Update.
3162 * gnulib/import/fstat.c: Update.
3163 * gnulib/import/fstatat.c: Update.
3164 * gnulib/import/getcwd-lgpl.c: Update.
3165 * gnulib/import/getcwd.c: Update.
3166 * gnulib/import/getdtablesize.c: Update.
3167 * gnulib/import/getlogin_r.c: Update.
3168 * gnulib/import/getprogname.c: Update.
3169 * gnulib/import/getprogname.h: Update.
3170 * gnulib/import/gettext.h: Update.
3171 * gnulib/import/gettimeofday.c: Update.
3172 * gnulib/import/glob-libc.h: Update.
3173 * gnulib/import/glob.c: Update.
3174 * gnulib/import/glob.in.h: Update.
3175 * gnulib/import/glob_internal.h: Update.
3176 * gnulib/import/glob_pattern_p.c: Update.
3177 * gnulib/import/globfree.c: Update.
3178 * gnulib/import/hard-locale.c: Update.
3179 * gnulib/import/hard-locale.h: Update.
3180 * gnulib/import/intprops.h: Update.
3181 * gnulib/import/inttypes.in.h: Update.
3182 * gnulib/import/isnan.c: Update.
3183 * gnulib/import/isnand-nolibm.h: Update.
3184 * gnulib/import/isnand.c: Update.
3185 * gnulib/import/isnanl-nolibm.h: Update.
3186 * gnulib/import/isnanl.c: Update.
3187 * gnulib/import/itold.c: Update.
3188 * gnulib/import/libc-config.h: Update.
3189 * gnulib/import/limits.in.h: Update.
3190 * gnulib/import/localcharset.c: Update.
3191 * gnulib/import/localcharset.h: Update.
3192 * gnulib/import/localtime-buffer.c: Update.
3193 * gnulib/import/localtime-buffer.h: Update.
3194 * gnulib/import/lstat.c: Update.
3195 * gnulib/import/m4/00gnulib.m4: Update.
3196 * gnulib/import/m4/__inline.m4: Update.
3197 * gnulib/import/m4/absolute-header.m4: Update.
3198 * gnulib/import/m4/alloca.m4: Update.
3199 * gnulib/import/m4/builtin-expect.m4: Update.
3200 * gnulib/import/m4/canonicalize.m4: Update.
3201 * gnulib/import/m4/chdir-long.m4: Update.
3202 * gnulib/import/m4/close.m4: Update.
3203 * gnulib/import/m4/closedir.m4: Update.
3204 * gnulib/import/m4/configmake.m4: Update.
3205 * gnulib/import/m4/d-ino.m4: Update.
3206 * gnulib/import/m4/d-type.m4: Update.
3207 * gnulib/import/m4/dirent_h.m4: Update.
3208 * gnulib/import/m4/dirfd.m4: Update.
3209 * gnulib/import/m4/dirname.m4: Update.
3210 * gnulib/import/m4/double-slash-root.m4: Update.
3211 * gnulib/import/m4/dup.m4: Update.
3212 * gnulib/import/m4/dup2.m4: Update.
3213 * gnulib/import/m4/eealloc.m4: Update.
3214 * gnulib/import/m4/environ.m4: Update.
3215 * gnulib/import/m4/errno_h.m4: Update.
3216 * gnulib/import/m4/error.m4: Update.
3217 * gnulib/import/m4/exponentd.m4: Update.
3218 * gnulib/import/m4/exponentl.m4: Update.
3219 * gnulib/import/m4/extensions.m4: Update.
3220 * gnulib/import/m4/extern-inline.m4: Update.
3221 * gnulib/import/m4/fchdir.m4: Update.
3222 * gnulib/import/m4/fcntl-o.m4: Update.
3223 * gnulib/import/m4/fcntl.m4: Update.
3224 * gnulib/import/m4/fcntl_h.m4: Update.
3225 * gnulib/import/m4/fdopendir.m4: Update.
3226 * gnulib/import/m4/filenamecat.m4: Update.
3227 * gnulib/import/m4/flexmember.m4: Update.
3228 * gnulib/import/m4/float_h.m4: Update.
3229 * gnulib/import/m4/fnmatch.m4: Update.
3230 * gnulib/import/m4/fnmatch_h.m4: Update.
3231 * gnulib/import/m4/fpieee.m4: Update.
3232 * gnulib/import/m4/frexp.m4: Update.
3233 * gnulib/import/m4/frexpl.m4: Update.
3234 * gnulib/import/m4/fstat.m4: Update.
3235 * gnulib/import/m4/fstatat.m4: Update.
3236 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
3237 * gnulib/import/m4/getcwd-path-max.m4: Update.
3238 * gnulib/import/m4/getcwd.m4: Update.
3239 * gnulib/import/m4/getdtablesize.m4: Update.
3240 * gnulib/import/m4/getlogin.m4: Update.
3241 * gnulib/import/m4/getlogin_r.m4: Update.
3242 * gnulib/import/m4/getpagesize.m4: Update.
3243 * gnulib/import/m4/getprogname.m4: Update.
3244 * gnulib/import/m4/gettimeofday.m4: Update.
3245 * gnulib/import/m4/glibc21.m4: Update.
3246 * gnulib/import/m4/glob.m4: Update.
3247 * gnulib/import/m4/glob_h.m4: Update.
3248 * gnulib/import/m4/gnulib-cache.m4: Update.
3249 * gnulib/import/m4/gnulib-common.m4: Update.
3250 * gnulib/import/m4/gnulib-comp.m4: Update.
3251 * gnulib/import/m4/gnulib-tool.m4: Update.
3252 * gnulib/import/m4/hard-locale.m4: Update.
3253 * gnulib/import/m4/include_next.m4: Update.
3254 * gnulib/import/m4/inttypes-pri.m4: Update.
3255 * gnulib/import/m4/inttypes.m4: Update.
3256 * gnulib/import/m4/isnand.m4: Update.
3257 * gnulib/import/m4/isnanl.m4: Update.
3258 * gnulib/import/m4/largefile.m4: Update.
3259 * gnulib/import/m4/limits-h.m4: Update.
3260 * gnulib/import/m4/localcharset.m4: Update.
3261 * gnulib/import/m4/locale-fr.m4: Update.
3262 * gnulib/import/m4/locale-ja.m4: Update.
3263 * gnulib/import/m4/locale-zh.m4: Update.
3264 * gnulib/import/m4/localtime-buffer.m4: Update.
3265 * gnulib/import/m4/longlong.m4: Update.
3266 * gnulib/import/m4/lstat.m4: Update.
3267 * gnulib/import/m4/malloc.m4: Update.
3268 * gnulib/import/m4/malloca.m4: Update.
3269 * gnulib/import/m4/math_h.m4: Update.
3270 * gnulib/import/m4/mbrtowc.m4: Update.
3271 * gnulib/import/m4/mbsinit.m4: Update.
3272 * gnulib/import/m4/mbsrtowcs.m4: Update.
3273 * gnulib/import/m4/mbstate_t.m4: Update.
3274 * gnulib/import/m4/memchr.m4: Update.
3275 * gnulib/import/m4/memmem.m4: Update.
3276 * gnulib/import/m4/mempcpy.m4: Update.
3277 * gnulib/import/m4/memrchr.m4: Update.
3278 * gnulib/import/m4/mkdir.m4: Update.
3279 * gnulib/import/m4/mkstemp.m4: Update.
3280 * gnulib/import/m4/mmap-anon.m4: Update.
3281 * gnulib/import/m4/mode_t.m4: Update.
3282 * gnulib/import/m4/msvc-inval.m4: Update.
3283 * gnulib/import/m4/msvc-nothrow.m4: Update.
3284 * gnulib/import/m4/multiarch.m4: Update.
3285 * gnulib/import/m4/nocrash.m4: Update.
3286 * gnulib/import/m4/off_t.m4: Update.
3287 * gnulib/import/m4/onceonly.m4: Update.
3288 * gnulib/import/m4/open-cloexec.m4: Update.
3289 * gnulib/import/m4/open.m4: Update.
3290 * gnulib/import/m4/openat.m4: Update.
3291 * gnulib/import/m4/opendir.m4: Update.
3292 * gnulib/import/m4/pathmax.m4: Update.
3293 * gnulib/import/m4/rawmemchr.m4: Update.
3294 * gnulib/import/m4/readdir.m4: Update.
3295 * gnulib/import/m4/readlink.m4: Update.
3296 * gnulib/import/m4/realloc.m4: Update.
3297 * gnulib/import/m4/rename.m4: Update.
3298 * gnulib/import/m4/rewinddir.m4: Update.
3299 * gnulib/import/m4/rmdir.m4: Update.
3300 * gnulib/import/m4/save-cwd.m4: Update.
3301 * gnulib/import/m4/secure_getenv.m4: Update.
3302 * gnulib/import/m4/setenv.m4: Update.
3303 * gnulib/import/m4/signal_h.m4: Update.
3304 * gnulib/import/m4/ssize_t.m4: Update.
3305 * gnulib/import/m4/stat-time.m4: Update.
3306 * gnulib/import/m4/stat.m4: Update.
3307 * gnulib/import/m4/std-gnu11.m4: Update.
3308 * gnulib/import/m4/stdbool.m4: Update.
3309 * gnulib/import/m4/stddef_h.m4: Update.
3310 * gnulib/import/m4/stdint.m4: Update.
3311 * gnulib/import/m4/stdio_h.m4: Update.
3312 * gnulib/import/m4/stdlib_h.m4: Update.
3313 * gnulib/import/m4/strchrnul.m4: Update.
3314 * gnulib/import/m4/strdup.m4: Update.
3315 * gnulib/import/m4/strerror.m4: Update.
3316 * gnulib/import/m4/string_h.m4: Update.
3317 * gnulib/import/m4/strstr.m4: Update.
3318 * gnulib/import/m4/strtok_r.m4: Update.
3319 * gnulib/import/m4/sys_socket_h.m4: Update.
3320 * gnulib/import/m4/sys_stat_h.m4: Update.
3321 * gnulib/import/m4/sys_time_h.m4: Update.
3322 * gnulib/import/m4/sys_types_h.m4: Update.
3323 * gnulib/import/m4/tempname.m4: Update.
3324 * gnulib/import/m4/time_h.m4: Update.
3325 * gnulib/import/m4/unistd-safer.m4: Update.
3326 * gnulib/import/m4/unistd_h.m4: Update.
3327 * gnulib/import/m4/warn-on-use.m4: Update.
3328 * gnulib/import/m4/wchar_h.m4: Update.
3329 * gnulib/import/m4/wchar_t.m4: Update.
3330 * gnulib/import/m4/wctype_h.m4: Update.
3331 * gnulib/import/m4/wint_t.m4: Update.
3332 * gnulib/import/malloc.c: Update.
3333 * gnulib/import/malloc/scratch_buffer.h: Update.
3334 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
3335 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
3336 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
3337 * gnulib/import/malloca.c: Update.
3338 * gnulib/import/malloca.h: Update.
3339 * gnulib/import/malloca.valgrind: Update.
3340 * gnulib/import/math.in.h: Update.
3341 * gnulib/import/mbrtowc.c: Update.
3342 * gnulib/import/mbsinit.c: Update.
3343 * gnulib/import/mbsrtowcs-impl.h: Update.
3344 * gnulib/import/mbsrtowcs-state.c: Update.
3345 * gnulib/import/mbsrtowcs.c: Update.
3346 * gnulib/import/memchr.c: Update.
3347 * gnulib/import/memmem.c: Update.
3348 * gnulib/import/mempcpy.c: Update.
3349 * gnulib/import/memrchr.c: Update.
3350 * gnulib/import/mkdir.c: Update.
3351 * gnulib/import/mkstemp.c: Update.
3352 * gnulib/import/msvc-inval.c: Update.
3353 * gnulib/import/msvc-inval.h: Update.
3354 * gnulib/import/msvc-nothrow.c: Update.
3355 * gnulib/import/msvc-nothrow.h: Update.
3356 * gnulib/import/open.c: Update.
3357 * gnulib/import/openat-die.c: Update.
3358 * gnulib/import/openat-priv.h: Update.
3359 * gnulib/import/openat-proc.c: Update.
3360 * gnulib/import/openat.c: Update.
3361 * gnulib/import/openat.h: Update.
3362 * gnulib/import/opendir.c: Update.
3363 * gnulib/import/pathmax.h: Update.
3364 * gnulib/import/pipe-safer.c: Update.
3365 * gnulib/import/rawmemchr.c: Update.
3366 * gnulib/import/readdir.c: Update.
3367 * gnulib/import/readlink.c: Update.
3368 * gnulib/import/realloc.c: Update.
3369 * gnulib/import/ref-add.sin: Update.
3370 * gnulib/import/ref-del.sin: Update.
3371 * gnulib/import/rename.c: Update.
3372 * gnulib/import/rewinddir.c: Update.
3373 * gnulib/import/rmdir.c: Update.
3374 * gnulib/import/same-inode.h: Update.
3375 * gnulib/import/save-cwd.c: Update.
3376 * gnulib/import/save-cwd.h: Update.
3377 * gnulib/import/scratch_buffer.h: Update.
3378 * gnulib/import/secure_getenv.c: Update.
3379 * gnulib/import/setenv.c: Update.
3380 * gnulib/import/signal.in.h: Update.
3381 * gnulib/import/stat-time.c: Update.
3382 * gnulib/import/stat-time.h: Update.
3383 * gnulib/import/stat-w32.c: Update.
3384 * gnulib/import/stat-w32.h: Update.
3385 * gnulib/import/stat.c: Update.
3386 * gnulib/import/stdbool.in.h: Update.
3387 * gnulib/import/stddef.in.h: Update.
3388 * gnulib/import/stdint.in.h: Update.
3389 * gnulib/import/stdio.in.h: Update.
3390 * gnulib/import/stdlib.in.h: Update.
3391 * gnulib/import/str-two-way.h: Update.
3392 * gnulib/import/strchrnul.c: Update.
3393 * gnulib/import/strdup.c: Update.
3394 * gnulib/import/streq.h: Update.
3395 * gnulib/import/strerror-override.c: Update.
3396 * gnulib/import/strerror-override.h: Update.
3397 * gnulib/import/strerror.c: Update.
3398 * gnulib/import/string.in.h: Update.
3399 * gnulib/import/stripslash.c: Update.
3400 * gnulib/import/strnlen1.c: Update.
3401 * gnulib/import/strnlen1.h: Update.
3402 * gnulib/import/strstr.c: Update.
3403 * gnulib/import/strtok_r.c: Update.
3404 * gnulib/import/sys_stat.in.h: Update.
3405 * gnulib/import/sys_time.in.h: Update.
3406 * gnulib/import/sys_types.in.h: Update.
3407 * gnulib/import/tempname.c: Update.
3408 * gnulib/import/tempname.h: Update.
3409 * gnulib/import/time.in.h: Update.
3410 * gnulib/import/unistd--.h: Update.
3411 * gnulib/import/unistd-safer.h: Update.
3412 * gnulib/import/unistd.in.h: Update.
3413 * gnulib/import/unsetenv.c: Update.
3414 * gnulib/import/verify.h: Update.
3415 * gnulib/import/extra/snippet/warn-on-use.h: Update.
3416 * gnulib/import/wchar.in.h: Update.
3417 * gnulib/import/wctype.in.h: Update.
3418 * gnulib/import/xalloc-oversized.h: Update.
3419 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
3420 "53e2c179f26a890fa6685af4b6c1397ee370433b".
3422 2018-08-16 Gary Benson <gbenson@redhat.com>
3425 * gdb/main.c (captured_main_1): Exit with nonzero status
3426 in batch mode if the last command to be executed failed.
3427 * NEWS: Mention the above.
3429 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
3431 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
3432 end of warning message.
3434 2018-08-29 Alan Hayward <alan.hayward@arm.com>
3437 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
3438 (aarch64_extract_return_value): Use
3439 aapcs_is_vfp_call_or_return_candidate.
3440 (aarch64_return_in_memory): Likewise.
3441 (aarch64_store_return_value): Likewise.
3443 2018-08-29 Alan Hayward <alan.hayward@arm.com>
3446 (aapcs_is_vfp_call_or_return_candidate): Make static
3447 (pass_in_v_or_stack): Remove function.
3448 (pass_in_v_vfp_candidate): New function.
3449 (aarch64_push_dummy_call): Check for float register candidates.
3451 2018-08-29 Alan Hayward <alan.hayward@arm.com>
3453 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
3454 (aapcs_is_vfp_call_or_return_candidate_1): New function.
3455 (aapcs_is_vfp_call_or_return_candidate): Likewise.
3457 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
3460 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
3461 (struct ipa_sym_addresses): Rename to...
3462 (struct ipa_sym_addresses_common): ... this.
3463 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
3465 2018-08-28 Tom Tromey <tom@tromey.com>
3467 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
3468 (token_fifo): Now a std::vector.
3469 (yylex, c_parse): Update.
3470 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
3471 (token_fifo): Now a std::vector.
3472 (yylex, d_parse): Update.
3473 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
3474 (token_fifo): Now a std::vector.
3475 (yylex, go_parse): Update.
3477 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
3479 * parser-defs.h (struct type_stack) <elements>: Change type to
3480 std::vector<union type_stack_elt>.
3481 <depth, size>: Remove.
3482 * parse.c (parse_exp_in_context_1): Adjust.
3483 (type_stack_reserve): Remove.
3484 (check_type_stack_depth): Remove.
3485 (insert_into_type_stack): Adjust to std::vector.
3486 (insert_type): Likewise.
3487 (push_type): Likewise.
3488 (push_type_int): Likewise.
3489 (insert_type_address_space): Likewise.
3490 (pop_type): Likewise.
3491 (pop_type_int): Likewise.
3492 (pop_typelist): Likewise.
3493 (pop_type_stack): Likewise.
3494 (append_type_stack): Likewise.
3495 (push_type_stack): Likewise.
3496 (get_type_stack): Likewise.
3497 (type_stack_cleanup): Likewise.
3498 (push_typelist): Likewise.
3499 (follow_types): Likewise.
3500 (_initialize_parse): Likewise.
3502 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
3504 * NEWS: Mention csky target.
3506 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
3507 Hafiz Abid Qadeer <abidh@codesourcery.com>
3508 Don Breazeal <donb@codesourcery.com>
3510 * csky-linux-tdep.c: New file.
3511 * csky-tdep.c: Likewise.
3512 * csky-tdep.h: Likewise.
3513 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
3515 (HFILES_NO_SRCDIR): Add csky-tdep.h.
3516 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
3517 * configure.tgt: Add csky support.
3519 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
3521 * python/py-framefilter.c (py_print_frame): Print frame architecture
3522 when printing on an MI output.
3524 2018-08-27 Tom Tromey <tom@tromey.com>
3527 * configure: Rebuild.
3528 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
3530 2018-08-27 Tom Tromey <tom@tromey.com>
3532 * aarch64-linux-tdep.c
3533 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
3536 2018-08-27 Tom Tromey <tom@tromey.com>
3538 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
3540 (ppc64_standard_linkage1, ppc64_standard_linkage2)
3541 (ppc64_standard_linkage3, ppc64_standard_linkage4)
3542 (ppc64_standard_linkage5, ppc64_standard_linkage6)
3543 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
3546 2018-08-27 Tom Tromey <tom@tromey.com>
3548 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
3549 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
3551 2018-08-27 Tom Tromey <tom@tromey.com>
3553 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
3554 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
3556 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
3558 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
3560 * sparc-linux-tdep.c (sparc32_linux_sigframe)
3561 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
3562 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
3564 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
3565 (ppc64_linux_sigaction_tramp_frame)
3566 (ppc32_linux_sighandler_tramp_frame)
3567 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
3568 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
3569 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
3570 * mn10300-linux-tdep.c (am33_linux_sigframe)
3571 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
3572 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
3573 * mips-linux-tdep.c (mips_linux_o32_sigframe)
3574 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
3575 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
3576 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
3577 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
3578 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
3579 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
3580 * microblaze-linux-tdep.c
3581 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
3582 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
3583 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
3584 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
3585 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
3586 * common/common-types.h (ULONGEST_MAX): New define.
3587 (CORE_ADDR_MAX): Fix formatting.
3588 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
3589 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
3590 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
3591 (arm_linux_rt_sigreturn_tramp_frame)
3592 (arm_eabi_linux_sigreturn_tramp_frame)
3593 (arm_eabi_linux_rt_sigreturn_tramp_frame)
3594 (thumb2_eabi_linux_sigreturn_tramp_frame)
3595 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
3596 (arm_linux_restart_syscall_tramp_frame)
3597 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
3598 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
3599 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
3601 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
3603 2018-08-27 Tom Tromey <tom@tromey.com>
3605 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
3607 * mips-tdep.c (mips_deal_with_atomic_sequence)
3608 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
3609 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
3610 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
3611 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
3613 * aarch64-tdep.c (aarch64_software_single_step): Use
3616 2018-08-27 Tom Tromey <tom@tromey.com>
3618 * linespec.c (complete_linespec_component): Add cast to "char".
3619 * completer.c (completion_tracker::build_completion_result): Add
3622 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
3624 * solist.h (struct solist, struct target_so_ops): Fix
3627 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
3629 * ada-tasks.c (ada_task_info_s): Remove typedef.
3630 (DEF_VEC_O(ada_task_info_s)): Remove.
3631 (struct ada_tasks_inferior_data): Initialize fields.
3632 <task_list>: Make an std::vector.
3633 (get_ada_tasks_inferior_data): Allocate with new.
3634 (ada_get_task_number): Adjust.
3635 (get_task_number_from_id): Likewise.
3636 (valid_task_id): Likewise.
3637 (ada_get_task_info_from_ptid): Likewise.
3638 (iterate_over_live_ada_tasks): Likewise.
3639 (add_ada_task): Likewise.
3640 (read_known_tasks): Likewise.
3641 (ada_build_task_list): Likewise.
3642 (print_ada_task_info): Likewise.
3643 (info_task): Likewise.
3644 (task_command_1): Likewise.
3646 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
3648 * ada-lang.c (add_angle_brackets): Return std::string.
3650 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
3652 * python/py-threadevent.c (py_get_event_thread): Initialize
3655 2018-08-24 Pedro Alves <palves@redhat.com>
3657 * python/py-bpevent.c (create_breakpoint_event_object): Use
3658 copy-initialization.
3659 * python/py-continueevent.c (emit_continue_event): Use
3660 copy-initialization.
3661 * python/py-exitedevent.c (create_exited_event_object): Return a
3663 (emit_exited_event): Use copy-initialization.
3664 * python/py-inferior.c (python_new_inferior)
3665 (python_inferior_deleted, add_thread_object): Use
3666 copy-initialization.
3667 * python/py-infevents.c (create_inferior_call_event_object)
3668 (create_register_changed_event_object)
3669 (create_memory_changed_event_object): Return a gdbpy_ref<>.
3670 (emit_inferior_call_event, emit_memory_changed_event)
3671 (emit_register_changed_event): Use copy-initialization.
3672 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3673 Return a gdbpy_ref<>.
3674 (emit_new_objfile_event): Use copy-initialization.
3675 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
3676 (emit_clear_objfiles_event): Use copy-initialization.
3677 * python/py-signalevent.c (create_signal_event_object): Use
3678 copy-initialization.
3679 * python/py-threadevent.c (create_thread_event_object): Use
3680 copy-initialization.
3682 2018-08-24 Pedro Alves <palves@redhat.com>
3683 Simon Marchi <simon.marchi@ericsson.com>
3686 * python/py-continueevent.c: Include "gdbthread.h".
3687 (create_continue_event_object): Add intro comment. Add 'ptid'
3688 parameter. Use it to find thread to pass to
3689 create_thread_event_object.
3690 (emit_continue_event): Pass PTID down to
3691 create_continue_event_object.
3692 * python/py-event.h (py_get_event_thread): Declare.
3693 (create_thread_event_object): Remove default from 'thread'
3695 * python/py-stopevent.c (create_stop_event_object): Use
3696 py_get_event_thread.
3697 * python/py-threadevent.c (get_event_thread): Rename to ...
3698 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
3699 and use it to find the thread.
3700 (create_thread_event_object): Assert that THREAD isn't null.
3701 Don't find the event thread here.
3703 2018-08-23 Kevin Buettner <kevinb@redhat.com>
3705 * block.h (blockrange, blockranges): New struct declarations.
3706 (struct block): Add new field named `ranges'.
3707 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
3708 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
3709 macros for accessing ranges in struct block.
3710 (make_blockranges): New declaration.
3711 block.c (make_blockranges): New function.
3712 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
3714 * symtab.h (find_pc_partial_function): Add new parameter `block'.
3715 * blockframe.c (cache_pc_function_block): New static global.
3716 (clear_pc_function_cache): Clear cache_pc_function_block.
3717 (find_pc_partial_function): Move comment to symtab.h. Add
3718 support for non-contiguous blocks.
3719 * cli/cli-cmds.c (block.h): Include.
3720 (print_disassembly): Handle printing of non-contiguous blocks.
3721 (disassemble_current_function): Likewise.
3722 (disassemble_command): Likewise.
3724 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
3726 * blockframe.c (get_pc_function_start): Likewise.
3727 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
3728 (gcc_symbol_address): Likewise.
3729 * compile/compile-object-run.c (compile_object_run): Likewise.
3730 * compile/compile.c (get_expr_block_and_pc): Likewise.
3731 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
3732 (func_addr_to_tail_call_list): Likewise.
3733 * findvar.c (default_read_var_value): Likewise.
3734 * inline-frame.c (inline_frame_this_id): Likewise.
3735 (skip-inline_frames): Likewise.
3736 * infcmd.c (until_next_command): Likewise.
3737 * linespec.c (convert_linespec_to_sals): Likewise.
3738 * parse.c (parse_exp_in_context_1): Likewise.
3739 * printcmd.c (build_address_symbolic): likewise.
3740 (info_address_command): Likewise.
3741 symtab.c (find_function_start_sal): Likewise.
3742 (skip_prologue_sal): Likewise.
3743 (find_function_alias_target): Likewise.
3744 (find_gnu_ifunc): Likewise.
3745 * stack.c (find_frame_funname): Likewise.
3746 * symtab.c (fixup_symbol_section): Likewise.
3747 (find_function_start_sal): Likewise.
3748 (skip_prologue_sal): Likewsie.
3749 (find_function_alias_target): Likewise.
3750 (find_gnu_ifunc): Likewise.
3751 * tracepoint.c (info_scope_command): Likewise.
3752 * value.c (value_fn_field): Likewise.
3754 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
3755 in place of find_pc_partial_function.
3756 * blockframe.c (find_function_entry_range_from_pc): New function.
3757 * symtab.h (find_function_entry_range_from_pc): Declare and document.
3758 * objfiles.c (objfile_relocate1): Relocate start and end addresses
3759 for each range in a block.
3762 2018-08-23 Xavier Roirand <roirand@adacore.com>
3764 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
3767 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3769 * solib-svr4.c (read_program_headers_from_bfd): Return
3770 gdb::optional<gdb::byte_vector>.
3771 (svr4_exec_displacement): Adjust.
3773 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3775 * solib-svr4.c (read_program_header): Return
3776 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
3777 (find_program_interpreter): Return
3778 gdb::optional<gdb::byte_vector>.
3779 (scan_dyntag_auxv): Adjust.
3780 (enable_break): Adjust.
3781 (svr4_exec_displacement): Adjust.
3783 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3785 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
3786 * inf-child.c (inf_child_target::terminal_save_inferior): New.
3788 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3790 * guile/scm-string.c (gdbscm_scm_from_printf): Use
3792 * guile/scm-utils.c (gdbscm_printf): Likewise.
3793 * serial.c (serial_printf): Likewise.
3794 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
3796 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
3798 * stack.c (print_frame): Print frame architecture when printing on
3800 * NEWS: Mention new "arch" attribute in frame output.
3802 2018-08-21 Alan Hayward <alan.hayward@arm.com>
3804 * arch/aarch64.h (aarch64_regnum): Update comment.
3806 2018-08-21 Alan Hayward <alan.hayward@arm.com>
3808 * NEWS: Add SVE to 8.2 section.
3810 2018-08-21 Pedro Alves <palves@redhat.com>
3812 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
3813 out from gdbscm_parse_function_args.
3814 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
3815 gdbscm_parse_function_args_1.
3817 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
3820 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
3823 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
3825 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
3827 2018-08-19 Michael Spang <spang@google.com>
3830 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
3831 for PT_TLS segments.
3833 2018-08-18 Kevin Buettner <kevinb@redhat.com>
3835 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
3836 dwarf_variable_value.
3837 * dwarf2-frame.c (class dwarf_expr_executor):
3838 Add override for dwarf_variable_value.
3839 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
3840 (class symbol_needs_eval_context): Likewise.
3841 (indirect_synthetic_pointer): Add forward declaration.
3842 (sect_variable_value): New function.
3843 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
3844 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
3845 for DW_OP_GNU_variable_value.
3847 2018-08-16 Tom Tromey <tom@tromey.com>
3849 * top.c (read_command_file): Update.
3850 (command_line_input): Remove "repeat" argument.
3851 * ada-lang.c (get_selections): Update.
3852 * linespec.c (decode_line_2): Update.
3853 * defs.h (command_line_input): Remove argument.
3854 * cli/cli-script.c (read_next_line): Update.
3855 * python/py-gdb-readline.c: Update.
3857 2018-08-17 Tom Tromey <tom@tromey.com>
3859 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
3862 2018-08-15 Tom Tromey <tom@tromey.com>
3864 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
3866 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
3868 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
3869 If used, use find_pc_partial_function to find address range
3871 * mi/mi-main.c (mi_cmd_list_features): Report
3872 "data-disassemble-a-option" feature.
3873 * NEWS: Mention new -data-disassemble option -a.
3875 2018-08-13 Tom Tromey <tom@tromey.com>
3877 * common/common-defs.h (_FORTIFY_SOURCE): Define.
3879 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3881 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
3882 (aarch64_linux_collect_sve_regset): Likewise.
3883 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
3884 * regcache.h (regcache_map_entry_size): New function.
3886 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3888 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
3889 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
3890 (SVE_HEADER_VL_LENGTH): Likewise.
3891 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
3892 (SVE_HEADER_FLAGS_LENGTH): Likewise.
3893 (SVE_HEADER_RESERVED_LENGTH): Likewise.
3894 (SVE_HEADER_SIZE_OFFSET): Likewise.
3895 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
3896 (SVE_HEADER_VL_OFFSET): Likewise.
3897 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
3898 (SVE_HEADER_FLAGS_OFFSET): Likewise.
3899 (SVE_HEADER_RESERVED_OFFSET): Likewise.
3900 (SVE_HEADER_SIZE): Likewise.
3901 (aarch64_linux_core_read_vq): Add function.
3902 (aarch64_linux_core_read_description): Check for SVE section.
3904 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3906 * aarch64-fbsd-tdep.c
3907 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
3909 * aarch64-linux-tdep.c
3910 (aarch64_linux_iterate_over_regset_sections): Likewise.
3911 * alpha-linux-tdep.c
3912 (alpha_linux_iterate_over_regset_sections):
3914 (alphanbsd_iterate_over_regset_sections): Likewise.
3916 (amd64fbsd_iterate_over_regset_sections): Likewise.
3917 * amd64-linux-tdep.c
3918 (amd64_linux_iterate_over_regset_sections): Likewise.
3920 (armbsd_iterate_over_regset_sections): Likewise.
3922 (arm_fbsd_iterate_over_regset_sections): Likewise.
3924 (arm_linux_iterate_over_regset_sections): Likewise.
3925 * corelow.c (get_core_registers_cb): Likewise.
3926 (core_target::fetch_registers): Likewise.
3927 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
3928 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
3929 * gdbarch.h (void): Regenerate.
3930 * gdbarch.sh: Add supply_size and collect_size.
3931 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
3932 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
3933 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
3934 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
3935 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
3936 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
3937 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
3938 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
3939 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
3940 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
3941 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
3942 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
3943 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
3944 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
3945 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
3946 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
3947 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
3948 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
3949 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
3950 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
3951 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
3952 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
3953 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
3954 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
3955 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
3956 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
3957 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
3958 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
3959 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
3960 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
3962 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
3964 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
3967 2018-08-10 Keith Seitz <keiths@redhat.com>
3969 * compile/compile-c-support.c (add_code_header, add_code_footer):
3970 Move into policy class.
3971 (c_push_user_expression, pop_user_expression_nop)
3972 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
3973 (compile_program): New host class.
3974 (c_compile_program): New typedef.
3975 (c_compute_porgram): Use c_compile_program.
3977 2018-08-10 Keith Seitz <keiths@redhat.com>
3979 * compile/compile-internal.h (compile_instance::~compile_instance):
3980 Remove calls to htab_delete.
3981 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
3982 * compile.c (compile_instance::compile_instance): Initialize
3983 htab unique pointers.
3984 (compile_instance::get_cached_type, compile_instance::insert_type)
3985 (compile_instance::error_symbol_once): Update for unique_ptr.
3987 2018-08-10 Keith Seitz <keiths@redhat.com>
3989 * compile/compile-c-symbols.c (struct symbol_error)
3990 (hash_symbol_error, eq_symbol_error, del_symbol_error)
3991 (compile_instance::insert_symbol_error)
3992 (compile_instance::error_symbol_once): Move to ...
3993 * compile/compile.c: ... here.
3995 2018-08-10 Keith Seitz <keiths@redhat.com>
3997 * compile/compile-c-support.c (c_get_compile_context): Use `new'
3998 instead of `new_compile_instance'.
3999 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
4001 If the symbol error map is not initialized, create it.
4002 (generate_c_for_for_one_symbol): Do not check/initialize
4003 the symbol error map.
4004 * compile/compile-c-types.c (compile_c_instance): Make a class.
4006 (compile_instance::compile_instance): Initialize the type cache.
4007 (get_cached_type): New function.
4008 (insert_type): Update description.
4009 (compile_c_instance::m_default_cflags): Define.
4010 (convert_type): Update description. Use get_cached_type.
4011 (delete_instance): Moved to destructor.
4012 (new_compile_instance): Moved to constructor.
4013 * compile/compile-c.h (compile_c_instance): Make class inheriting
4014 from compile_instance.
4015 <base>: Remove field.
4016 <type_map, symbol_err_map>: Move to base class.
4017 <c_plugin>: Rename to `m_plugin' and remove pointer type.
4018 * compile/compile-internal.h (compile_instance): Make class.
4019 <type_map_t, symbol_err_map_t>: Define.
4020 <fe>: Rename to `m_gcc_fe'.
4021 <scope, block, gcc_target_options>: Add `m_' prefix.
4022 <m_type_map, m_symbol_err_map>: New fields, moved from
4025 (convert_type, new_compile_instance): Remove.
4026 * compile/compile.c (cleanup_compile_instance): Remove.
4027 (compile_to_object): Use unique_ptr to eliminate cleanups.
4028 (compile_instance::set_print_callback, compile_instance::version)
4029 (compile_instance::set_verbose)
4030 (compile_instance::set_driver_filename)
4031 (compile_instance::set_triplet_regexp)
4032 (compile_instance::set_arguments)
4033 (compile_instance::set_source_file)
4034 (compile_instance::compile): Define.
4036 2018-08-10 Keith Seitz <keiths@redhat.com>
4038 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
4039 * compile/compile-c-types.c: Define GCC_METHODN macros and include
4040 gcc-c-fe.def to define C plugin.
4041 (delete_instance): Delete `c_plugin'.
4042 (new_compile_instance): Initialize `c_plugin'.
4043 * compile/compile-c.h: Include gcc_c_plugin.h.
4044 (struct compile_c_instance) <c_plugin>: New member.
4045 * gcc-c-plugin.h: New file.
4046 Update all callers with API change.
4048 2018-08-10 Keith Seitz <keiths@redhat.com>
4050 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
4051 (HFILES_NO_SRCDIR): ... to here.
4052 Add compile-internal.h and compile-c.h.
4053 * compile/compile-c-support.c: Include compile-c.h.
4054 * compile/compile-c-symbols.c: Include compile-c.h.
4055 (generate_c_for_variable_locations): Update comment.
4056 * compile/compile-c-types.c: Include compile-c.h.
4057 * compile/compile-c.h: New file -- moved C language declarations
4058 from other files here.
4059 * compile/compile-internal.h: Do not include hashtab.h or
4060 common/enum-flags.h.
4061 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
4062 (gcc_convert_symbol, gcc_symbol_address)
4063 (generate_c_for_variable_locations, c_get_mode_for_size)
4064 (c_get_range_decl_name): Definitions moved to compile-c.h.
4065 * compile/compile-loc2c.c: Include compile-c.h.
4067 2018-08-10 Keith Seitz <keiths@redhat.com>
4069 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
4070 (c_symbol_substitution_name): ... this.
4073 2018-08-10 Keith Seitz <keiths@redhat.com>
4075 * compile/compile-c-support.c (c_compute_program): Use
4076 unique_xmalloc_ptr to eliminate cleanup.
4077 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
4078 Return a unique_xmalloc_ptr and eliminate cleanup.
4079 * compile/compile-internal.h (generate_c_for_variable_locations):
4080 Return unique_xmalloc_ptr and update description.
4082 2018-08-10 Alan Hayward <alan.hayward@arm.com>
4084 * corelow.c (core_target::get_core_register_section): Rename
4085 min_size to section_min_size.
4087 2018-08-09 Jim Wilson <jimw@sifive.com>
4089 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
4090 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
4091 * NEWS: Mention new GNU/Linux RISC-V target.
4092 * configure.host: Add riscv*-*-linux*.
4093 * configure.nat: Add riscv*.
4094 * configure.tgt: Add riscv*-*-linux*.
4095 * riscv-linux-nat.c: New file.
4096 * riscv-linux-tdep.c: New file.
4098 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
4100 * infrun.c (resume): Make static, add forward declaration.
4101 (proceed): Update header comment.
4102 * infrun.h (resume): Delete declaration.
4104 2018-08-09 Tom Tromey <tom@tromey.com>
4106 * riscv-tdep.h: Minor formatting fixes.
4108 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
4110 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
4111 * dwarf-index-cache.c (create_dir_and_check): Likewise.
4112 (test_mkdir_recursive): Likewise.
4113 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
4115 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
4117 * valarith.c (value_subscripted_rvalue): If an array is not in
4118 memory, and we don't know the upper bound, then we can't know that
4119 the requested element exists or not.
4121 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
4123 * target.c (str_comma_list_concat_elem): Fix typo in comment.
4124 (target_options_to_string): Add comment.
4126 2018-08-08 Tom Tromey <tom@tromey.com>
4128 * unittests/scoped_mmap-selftests.c: Check result of "write".
4130 2018-08-08 Jim Wilson <jimw@sifive.com>
4132 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
4133 (decode_register_index_short): New.
4134 (decode_j_type_insn, decode_cj_type_insn): New.
4135 (decode_b_type_insn, decode_cb_type_insn): New.
4136 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
4137 local xlen. Check xlen when decoding ambiguous compressed insns. In
4138 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
4139 is_c_sw_insn instead of is_sw_insn.
4140 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
4141 (riscv_software_single_step): New.
4142 * riscv-tdep.h (riscv_software_single_step): Declare.
4144 * riscv-tdep.c (riscv_isa_xlen): Drop static.
4145 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
4147 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
4150 * target.c (dispose_inferior): Don't dispose of inferiors that are
4153 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
4155 * remote.c (remote_target::download_tracepoint): Change char* to
4158 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
4160 * target.h (target_options_to_string): Return an std::string.
4161 * target.c (str_comma_list_concat_elem): Return void, use
4163 (do_option): Likewise.
4164 (target_options_to_string): Return an std::string.
4165 * linux-nat.c (linux_nat_target::wait): Adjust.
4166 * target-debug.h (target_debug_print_options): Adjust.
4168 2018-08-07 Tom Tromey <tom@tromey.com>
4170 * Makefile.in (CPPFLAGS): New variable.
4171 (INTERNAL_CPPFLAGS): Use it.
4173 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
4175 * NEWS: Mention the index cache.
4177 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
4179 * common/pathstuff.h (get_standard_cache_dir): New.
4180 * common/pathstuff.c (get_standard_cache_dir): New.
4181 * build-id.h (build_id_to_string): New.
4182 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
4183 DEBUG_STR_SUFFIX): Move to here.
4184 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
4185 DEBUG_STR_SUFFIX): Move from there.
4186 (write_psymtabs_to_index): Make non-static, add basename
4187 parameter. Write to temporary files, rename when done.
4188 (save_gdb_index_command): Adjust call to
4189 write_psymtabs_to_index.
4190 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
4192 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
4193 (get_gdb_index_contents_from_cache): New.
4194 (get_gdb_index_contents_from_cache_dwz): New.
4195 (dwarf2_initialize_objfile): Read index from cache.
4196 (dwarf2_build_psymtabs): Save to index.
4197 * dwarf-index-cache.h: New file.
4198 * dwarf-index-cache.c: New file.
4199 * dwarf-index-write.h: New file.
4201 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
4203 * gnulib/aclocal.m4: Re-generate.
4204 * gnulib/config.in: Re-generate.
4205 * gnulib/configure: Re-generate.
4206 * gnulib/import/Makefile.am: Re-generate.
4207 * gnulib/import/Makefile.in: Re-generate.
4208 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
4209 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
4210 * gnulib/import/m4/mkdir.m4: New file.
4211 * gnulib/import/mkdir.c: New file.
4212 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
4215 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
4217 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
4218 * common/scoped_mmap.c: New file.
4219 * common/scoped_mmap.h (destroy): New method.
4220 (~scoped_mmap, reset): Use destroy.
4221 (scoped_mmap): New move constructor.
4222 (mmap_file): New declaration.
4223 * unittests/scoped_mmap-selftests.c (test_normal,
4224 test_invalid_filename, run_tests): New functions.
4225 (_initialize_scoped_mmap_selftests): Register selftest.
4227 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
4229 * dwarf2read.c (read_gdb_index_from_section): Rename to...
4230 (read_gdb_index_from_buffer): ... this. Remove section
4231 parameter, add buffer parameter.
4232 (get_gdb_index_contents_ftype,
4233 get_gdb_index_contents_dwz_ftype): New typedefs.
4234 (dwarf2_read_gdb_index): Add callback parameters to get the
4236 (get_gdb_index_contents_from_section): New.
4237 (dwarf2_initialize_objfile): Update call to
4238 dwarf2_read_gdb_index.
4240 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
4242 * common/filestuff.h (gdb_fopen_cloexec): New overload.
4243 (gdb_open_cloexec): Likewise.
4244 * nat/linux-osdata.c (command_from_pid): Use string_printf.
4245 (commandline_from_pid): Likewise.
4246 (linux_xfer_osdata_threads): Likewise.
4247 (linux_xfer_osdata_fds): Likewise.
4248 * ada-lang.c (is_package_name): Likewise.
4249 * auxv.c (procfs_xfer_auxv): Likewise.
4250 * breakpoint.c (print_one_breakpoint_location): Use
4252 (print_one_catch_solib): Use string_printf.
4253 * coff-pe-read.c (add_pe_exported_sym): Likewise.
4254 (add_pe_forwarded_sym): Likewise.
4255 * dwarf2read.c (create_type_unit_group): Likewise.
4256 (build_error_marker_type): Likewise.
4257 * infcall.c (get_function_name): Likewise.
4258 * valprint.c (print_converted_chars_to_obstack): Likewise.
4259 * xtensa-tdep.c (xtensa_register_type): Likewise.
4261 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
4263 * remote.c (remote_target::download_tracepoint): Fix format
4266 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4268 * tracefile.c: Include common/byte-vector.h.
4269 (trace_save): Change type of buf to gdb::byte_vector. Initialize
4270 with trace_regblock_size if needed. Update uses of buf.
4272 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4274 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
4275 std::vector<unsigned char>.
4276 * tracepoint.c (collection_list::collection_list): Remove
4277 m_regs_mask initializer from initializer list. Resize
4278 m_regs_mask using the largest remote register number.
4279 (collection_list::add_remote_register): Remove size check on
4280 m_regs_mask. Use at to access element.
4281 (collection_list::stringify): Change type of temp_buf to
4282 gdb::char_vector. Update uses of temp_buf. Resize if needed to
4283 stringify the register mask. Use pack_hex_byte for the register
4286 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4288 * tracepoint.h (class collection_list) <add_register>: Remove.
4289 <add_remote_register, add_ax_registers, add_local_register>:
4291 <add_memrange>: Add scope parameter.
4292 * tracepoint.c (encode_actions_1): Likewise.
4293 (collection_list::add_register): Rename to ...
4294 (collection_list::add_remote_register): ... this. Update
4296 (collection_list::add_ax_registers, add_local_register): New
4298 (collection_list::add_memrange): Add scope parameter. Call
4299 add_local_register instead of add_register.
4300 (finalize_tracepoint_aexpr): New function.
4301 (collection_list::collect_symbol): Update calls to add_memrange.
4302 Call add_local_register instead of add_register. Call
4303 add_ax_registers. Call finalize_tracepoint_aexpr.
4304 (encode_actions_1): Get remote regnos for $reg action. Call
4305 add_remote_register, add_ax_registers, and add_local_register.
4306 Update call to add_memrange. Call finalize_tracepoint_aexpr.
4307 (validate_actionline): Call finalize_tracepoint_aexpr.
4309 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4311 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
4312 Replace array buf with gdb::char_vector buf, of size
4313 get_remote_packet_size (). Replace references to buf and
4314 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
4315 and xsnprintf with snprintf. Raise errors if the buffer is too
4318 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4320 * remote.c (remote_target::download_tracepoint): Fix the has_more
4321 predicate in the QTDP action list iteration.
4323 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
4325 * remote.c (remote_target::download_tracepoint): Fix indentation
4328 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4330 * proc-api.c (_initialize_proc_api): Remove c, unused.
4331 * procfs.c (procfs_init_inferior): Remove signals, unused.
4332 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
4335 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
4336 Andrew Burgess <andrew.burgess@embecosm.com>
4338 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
4339 'W_STOPCODE (0)' as this could be ambiguous.
4341 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
4343 * ser-tcp.c (net_open): Fix thinko when deciding whether to
4344 disable TCP's Nagle algorithm (use "ai_protocol" instead of
4347 2018-08-02 Tom Tromey <tom@tromey.com>
4350 * dwarf2read.c (read_func_scope): Set symtab on template parameter
4352 (process_structure_scope): Likewise.
4354 2018-08-02 Xavier Roirand <roirand@adacore.com>
4357 * darwin-nat.c (darwin_kill_inferior): Fix handling of
4360 2018-08-02 Tom Tromey <tom@tromey.com>
4362 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
4363 (darwin_suspend_inferior, darwin_resume_inferior)
4364 (darwin_decode_notify_message, darwin_resume_inferior_threads)
4365 (darwin_check_new_threads): Check result of get_darwin_inferior.
4367 2018-07-31 Joel Brobecker <brobecker@adacore.com>
4371 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
4373 * varobj.c (varobj_get_path_expr_parent): Report an error if
4374 parent is a dynamic varobj.
4376 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
4378 * gnulib/aclocal.m4: Re-generate.
4379 * gnulib/config.in: Re-generate.
4380 * gnulib/configure: Re-generate.
4381 * gnulib/import/Makefile.in: Re-generate.
4382 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
4383 * gnulib/import/m4/onceonly.m4: Re-generate.
4385 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
4387 * target-descriptions.c (struct xml_test_tdesc): New.
4388 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
4389 (record_xml_tdesc): Update.
4390 (maintenance_check_xml_descriptions): Update.
4391 * target-descriptions.h (record_xml_tdesc): Update comment.
4393 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
4395 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
4396 checking array bounds are defined.
4398 2018-07-30 Tom Tromey <tom@tromey.com>
4400 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
4401 irreflexivity violation.
4403 2018-07-30 Tom Tromey <tom@tromey.com>
4405 * cli/cli-decode.c (lookup_cmd): Remove lint code.
4406 * value.c (unpack_long): Remove lint code.
4407 * valops.c (value_ind): Remove lint code.
4408 * valarith.c (value_x_binop, value_x_unop, value_equal)
4409 (value_pos): Remove lint code.
4411 2018-07-28 Tom de Vries <tdevries@suse.de>
4413 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
4414 with undefined upper bound as <optimized out>.
4416 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
4418 * gcore.in: Rename variable "name" to "prefix". Expand
4421 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
4423 * windows-nat.c (windows_nat_target::create_inferior): Update to
4424 call close() in global namespace.
4426 2018-07-26 Tom Tromey <tom@tromey.com>
4428 * dwarf-index-write.c (add_address_entry): Don't add objfile
4430 * dbxread.c (find_stab_function): Rename from
4431 find_stab_function_addr. Return a bound_minimal_symbol.
4432 (read_dbx_symtab): Use raw_text_low, raw_text_high.
4433 Don't add objfile offsets.
4434 (end_psymtab): Use raw_text_low, raw_text_high,
4435 MSYMBOL_VALUE_RAW_ADDRESS.
4436 (read_ofile_symtab): Update.
4437 (process_one_symbol): Update.
4438 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
4440 (dw2_relocate): Remove.
4441 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
4443 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
4445 (process_psymtab_comp_unit_reader, add_partial_symbol)
4446 (add_partial_subprogram, dwarf2_ranges_read): Update.
4447 (load_partial_dies): Update.
4448 (add_address_entry): Don't add objfile offsets.
4449 (dwarf2_build_include_psymtabs): Update.
4450 (create_addrmap_from_aranges): Don't add objfile offsets.
4451 (dw2_find_pc_sect_compunit_symtab): Update.
4452 * mdebugread.c (parse_symbol): Don't add objfile offsets.
4453 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
4455 (parse_partial_symbols): Don't add objfile offsets. Use
4456 raw_text_low, raw_text_high. Update.
4457 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
4458 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
4459 or call 'relocate' quick function. Clear psymbol_map.
4460 * psympriv.h (struct partial_symbol) <address>: Add section
4462 <set_unrelocated_address>: Rename from set_address.
4463 <raw_text_low, raw_text_high>: New methods.
4464 <text_low, text_high>: Add objfile parameter.
4465 (add_psymbol_to_bcache): Add 'section' parameter. Call
4466 set_unrelocated_address.
4467 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
4468 (find_pc_psymbol): Update.
4469 (fixup_psymbol_section, relocate_psymtabs): Remove.
4470 (dump_psymtab, psym_functions): Update.
4471 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
4473 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
4474 (start_psymtab_common): Update.
4475 * symfile-debug.c (debug_qf_relocate): Remove.
4476 (debug_sym_quick_functions): Update.
4477 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
4478 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
4481 2018-07-26 Tom Tromey <tromey@redhat.com>
4483 * dbxread.c (end_psymtab): Use text_high_valid and
4485 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
4486 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
4487 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
4489 <text_low_valid, text_high_valid>: New fields.
4490 <set_text_low, set_text_high>: Update.
4491 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
4493 2018-07-26 Tom Tromey <tom@tromey.com>
4495 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
4497 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
4498 textlow and texthigh fields.
4499 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
4501 * mdebugread.c (parse_lines, parse_partial_symbols)
4502 (psymtab_to_symtab_1): Update.
4503 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
4504 Rename fields. Update comment. Now private.
4505 <text_low, text_high, set_text_low, set_text_high>: New methods.
4506 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
4507 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
4508 (start_psymtab_common, maintenance_info_psymtabs)
4509 (maintenance_check_psymtabs): Update.
4510 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
4512 (scan_xcoff_symtab): Update.
4514 2018-07-26 Tom Tromey <tromey@redhat.com>
4516 * psympriv.h (struct partial_symbol) <unrelocated_address,
4517 address, set_address>: New methods.
4518 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
4519 (fixup_psymbol_section, relocate_psymtabs): Update.
4520 (print_partial_symbols): Add 'objfile' parameter. Update.
4521 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
4524 2018-07-26 Tom Tromey <tom@tromey.com>
4526 * dwarf-index-write.c (write_psymbols, debug_names::insert)
4527 (debug_names::write_psymbols): Update.
4528 * psympriv.h (struct partial_symbol): Derive from
4529 general_symbol_info.
4530 <obj_section>: New method.
4531 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
4532 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
4533 (find_pc_sect_psymbol, fixup_psymbol_section)
4534 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
4535 (print_partial_symbols, recursively_search_psymtabs)
4536 (compare_psymbols, psymbol_hash, psymbol_compare)
4537 (add_psymbol_to_bcache, maintenance_check_psymtabs)
4538 (psymbol_name_matches, psym_fill_psymbol_map): Update.
4540 2018-07-26 Tom Tromey <tromey@redhat.com>
4542 * dbxread.c (end_psymtab): Remove dead code.
4544 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
4546 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
4547 DWARF unwinders are disabled.
4548 * dwarf2-frame.c: Add dwarf2read.h include.
4549 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
4551 (dwarf2_frame_unwinders_enabled_p): Define.
4552 (show_dwarf_unwinders_enabled_p): New function.
4553 (_initialize_dwarf2_frame): Register switch to control DWARF
4555 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
4556 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
4557 (show_dwarf_cmdlist): Remove static keyword.
4558 * dwarf2read.h (set_dwarf_cmdlist): Declare.
4559 (show_dwarf_cmdlist): Declare.
4560 * NEWS: Document new feature.
4562 2018-07-26 Tom de Vries <tdevries@suse.de>
4564 PR breakpoints/23366
4565 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
4567 2018-07-26 Tom de Vries <tdevries@suse.de>
4569 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
4570 DW_AT_count can't be translated to a dynamic prop.
4572 2018-07-25 Tom de Vries <tdevries@suse.de>
4574 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
4577 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
4579 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
4581 2018-07-25 Joel Brobecker <brobecker@adacore.com>
4583 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
4585 2018-07-24 Keith Seitz <keiths@redhat.comt
4588 * dwarf2read.c (dw2_add_symbol_to_list): New function.
4589 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
4590 instead of add_symbol_to_list.
4591 (read_file_scope): Call prepare_one_comp_unit before reading
4594 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
4596 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
4598 2018-07-24 Tom Tromey <tom@tromey.com>
4600 * utils.c (malloc, realloc, free): Don't declare.
4601 * configure, config.in: Rebuild.
4602 * configure.ac: Don't check for declarations of free, malloc, or
4605 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4607 * aarch64-linux-nat.c
4608 (aarch64_linux_nat_target::stopped_data_address): Remove unused
4610 * arm-linux-nat.c (fetch_regs): Likewise.
4611 (store_regs): Likewise.
4612 (fetch_vfp_regs): Likewise.
4613 (store_vfp_regs): Likewise.
4614 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
4615 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
4616 (arm_linux_nat_target::insert_watchpoint): Likewise.
4617 (arm_linux_nat_target::remove_watchpoint): Likewise.
4618 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
4620 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
4622 * ppc-linux-nat.c (fetch_register): Likewise.
4623 (fetch_all_gp_regs): Likewise.
4624 (fetch_ppc_registers): Likewise.
4625 (store_all_gp_regs): Likewise.
4626 (store_ppc_registers): Likewise.
4627 (hwdebug_insert_point): Likewise.
4628 (can_use_watchpoint_cond_accel): Likewise.
4629 * remote-sim.c (gdb_os_write_stdout): Likewise.
4631 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4632 Tom Tromey <tom@tromey.com>
4634 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
4636 * configure: Rebuild.
4638 2018-07-22 Tom Tromey <tom@tromey.com>
4640 * regformats/regdat.sh: Define xmltarget_${name} inside
4641 #ifndef IN_PROCESS_AGENT.
4643 2018-07-22 Tom Tromey <tom@tromey.com>
4645 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
4647 2018-07-22 Tom Tromey <tom@tromey.com>
4649 * symfile.c (reread_symbols): Notify iter, not objfile.
4651 2018-07-22 Tom Tromey <tom@tromey.com>
4653 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
4655 (ravenscar_thread_target::prepare_to_store): Likewise.
4657 2018-07-22 Tom Tromey <tom@tromey.com>
4659 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
4660 unused variable. Call value_fetch_lazy when needed.
4661 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
4662 Remove unused variable. Call value_fetch_lazy when needed.
4664 2018-07-22 Tom Tromey <tom@tromey.com>
4666 * m32c-tdep.c (mark_dma): Return void.
4667 (make_regs): Remove unused declarations.
4669 2018-07-22 Tom Tromey <tom@tromey.com>
4671 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
4672 cmdscm_get_valid_command_smob_arg_unsafe for effect.
4673 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
4674 bkscm_get_valid_block_smob_arg_unsafe for effect.
4676 2018-07-22 Tom Tromey <tom@tromey.com>
4678 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
4681 2018-07-22 Tom Tromey <tom@tromey.com>
4683 * windows-nat.c (saved_context): Conditionally define.
4684 * remote.c (remote_target::remote_btrace_maybe_reopen):
4685 Conditionally declare "warned".
4686 * inflow.c (sigquit_ours): Conditionally define.
4687 (new_tty): Move "tty" declaration inside #if.
4688 * guile/guile.c (guile_datadir): Conditionally define.
4689 * charset.c (set_be_le_names): Move some declarations inside #if.
4690 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
4692 (parse_xml_btrace_conf): Likewise.
4694 2018-07-22 Tom Tromey <tom@tromey.com>
4696 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
4698 2018-07-22 Tom Tromey <tom@tromey.com>
4700 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
4701 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
4702 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
4703 * buildsym-legacy.c (get_macro_table): Remove unused variable.
4704 * stack.c (frame_apply_level_command): Remove unused variable.
4705 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
4706 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
4707 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
4709 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
4710 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
4711 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
4713 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
4714 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
4716 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
4717 Remove unused variable.
4718 * cli/cli-script.c (recurse_read_control_structure): Remove unused
4720 * common/tdesc.c (print_xml_feature::visit): Remove unused
4722 * compile/compile-object-load.c (store_regs): Remove unused
4724 * complaints.c (clear_complaints): Remove unused variable.
4725 * corelow.c (core_target_open): Remove unused variable.
4726 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
4728 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
4730 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
4732 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
4734 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
4736 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
4738 * ia64-tdep.c (examine_prologue): Remove unused variable.
4739 * infcall.c (run_inferior_call): Remove unused variable.
4740 * inferior.c (exit_inferior): Remove unused variable.
4741 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
4742 * linespec.c (decode_line_2): Remove unused variable.
4743 * linux-nat.c (super_close): Remove.
4744 * linux-tdep.c (linux_info_proc): Remove unused variable.
4745 * mi/mi-main.c (mi_execute_command): Remove unused variable.
4746 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
4747 Remove unused variable.
4748 * parse.c (find_minsym_type_and_address): Remove unused variable.
4749 * printcmd.c (info_symbol_command, printf_floating): Remove unused
4751 * python/py-breakpoint.c (bppy_set_commands): Remove unused
4753 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
4755 * record-btrace.c (record_btrace_target::store_registers): Remove
4757 (cmd_show_record_btrace_cpu): Remove unused variable.
4758 * riscv-tdep.c (riscv_register_reggroup_p)
4759 (riscv_push_dummy_call, riscv_return_value): Remove unused
4761 * rust-exp.y (literal): Remove unused variable.
4762 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
4764 <STRUCTOP_ANONYMOUS>: Likewise.
4765 * s390-linux-tdep.c (s390_linux_init_abi_31)
4766 (s390_linux_init_abi_64): Remove unused variable.
4767 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
4768 (file_select_thread, net_windows_open, _initialize_ser_windows):
4769 Remove unused variables.
4770 * symtab.c (find_pc_sect_line): Remove unused variable.
4771 * target-memory.c (compute_garbled_blocks): Remove unused
4773 (target_write_memory_blocks): Remove unused variable.
4774 * target.c (target_stack::unpush): Remove unused variables.
4775 * tracepoint.c (start_tracing, all_tracepoint_actions)
4776 (merge_uploaded_trace_state_variables)
4777 (print_one_static_tracepoint_marker): Remove unused variable.
4778 * unittests/basic_string_view/element_access/char/1.cc (test01):
4779 Remove unused variable.
4780 * windows-nat.c (windows_continue, windows_add_all_dlls)
4781 (do_initial_windows_stuff, windows_nat_target::create_inferior):
4782 Remove unused variables.
4784 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
4786 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
4787 attr_profile in HAVE_ELF.
4788 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
4791 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
4793 * frame.c (frame_register_unwind): Change parameter name.
4794 (frame_unwind_register): Likewise.
4795 (frame_unwind_register_value): Likewise.
4796 (frame_unwind_register_signed): Likewise.
4797 (frame_unwind_register_unsigned): Likewise.
4798 * frame.h (frame_register_unwind): Likewise.
4799 (frame_unwind_register): Likewise.
4800 (frame_unwind_register_value): Likewise.
4801 (frame_unwind_register_signed): Likewise.
4802 (frame_unwind_register_unsigned): Likewise.
4803 (frame_unwind_arch): Likewise.
4805 2018-07-20 Maciej W. Rozycki <macro@mips.com>
4807 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
4810 2018-07-20 Maciej W. Rozycki <macro@mips.com>
4812 * mips-linux-nat.c (mips_linux_nat_target::read_description):
4813 Call `get_ptrace_pid' rather than extracting the ptrace PID by
4816 2018-07-20 Keith Seitz <keiths@redhat.com>
4818 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
4819 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
4820 m_compunit_symtab, m_language>: Add "m_" prefix.
4822 * buildsym.c: Update all uses.
4824 2018-07-20 Tom Tromey <tom@tromey.com>
4826 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
4827 * buildsym.h (record_line_ftype): Remove typedef.
4829 2018-07-20 Tom Tromey <tom@tromey.com>
4831 * buildsym-legacy.h (augment_type_symtab): Don't declare.
4832 (end_expandable_symtab): Likewise.
4833 (end_symtab_get_static_block): Likewise.
4834 (end_symtab_from_static_block): Likewise.
4835 * buildsym-legacy.c (augment_type_symtab): Remove.
4836 (end_expandable_symtab): Remove.
4837 (end_symtab_get_static_block): Remove.
4838 (end_symtab_from_static_block): Remove.
4840 2018-07-20 Tom Tromey <tom@tromey.com>
4842 * dwarf2read.c: Include buildsym.h.
4843 (struct dwarf2_cu) <builder>: New method.
4844 (fixup_go_packaging): Update.
4845 (process_full_comp_unit, process_full_type_unit): Update. Don't
4846 use scoped_free_pendings.
4847 (using_directives): Add "cu" parameter, remove "language".
4848 (read_import_statement, setup_type_unit_groups, )
4849 (read_func_scope, read_lexical_block_scope)
4850 (dwarf2_record_block_ranges, read_namespace): Update.
4851 (lnp_state_machine::lnp_state_machine): Add cu parameter.
4852 (lnp_state_machine::handle_end_sequence): Update.
4853 (class lnp_state_machine) <m_cu>: New member.
4854 <m_record_line_callback>: Remove.
4855 <m_currently_recording_lines>: New member.
4856 (lnp_state_machine::handle_set_file): Update.
4857 (noop_record_line): Remove.
4858 (dwarf_record_line_p): Add cu parameter.
4859 (dwarf_record_line_1, dwarf_finish_line): Likewise.
4860 (lnp_state_machine::record_line)
4861 (lnp_state_machine::lnp_state_machine)
4862 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4863 (dwarf_decode_lines): Update.
4864 (dwarf2_start_subfile): Add cu parameter.
4865 (dwarf2_start_symtab, new_symbol): Update.
4866 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
4867 Remove dwarf2_per_objfile parameter.
4868 (dwarf_decode_macros): Update.
4870 2018-07-20 Tom Tromey <tom@tromey.com>
4872 * stabsread.c (define_symbol): Update.
4873 * buildsym-legacy.h (get_buildsym_compunit): Declare.
4874 * dwarf2read.c (new_symbol): Update.
4875 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
4876 * cp-namespace.c: Include buildsym.h.
4877 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
4878 * buildsym-legacy.c (get_buildsym_compunit): New function.
4880 2018-07-20 Tom Tromey <tom@tromey.com>
4882 * xcoffread.c: Include buildsym-legacy.h.
4883 * windows-nat.c: Include buildsym-legacy.h.
4884 * stabsread.c: Include buildsym-legacy.h.
4885 * mdebugread.c: Include buildsym-legacy.h.
4886 * buildsym-legacy.h: New file.
4887 * buildsym-legacy.c: New file, from buildsym.c.
4888 * go32-nat.c: Include buildsym-legacy.h.
4889 * dwarf2read.c: Include buildsym-legacy.h.
4890 * dbxread.c: Include buildsym-legacy.h.
4891 * cp-namespace.c: Include buildsym-legacy.h.
4892 * coffread.c: Include buildsym-legacy.h.
4893 * buildsym.h: Move some contents to buildsym-legacy.h.
4894 * buildsym.c: Include buildsym-legacy.h. Move many functions to
4896 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
4898 2018-07-20 Tom Tromey <tom@tromey.com>
4900 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
4901 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
4902 (buildsym_compunit::buildsym_compunit)
4903 (buildsym_compunit::~buildsym_compunit)
4904 (buildsym_compunit::get_macro_table): Define.
4906 2018-07-20 Tom Tromey <tom@tromey.com>
4908 * buildsym.c (reset_symtab_globals): Remove.
4909 (buildsym_compunit::end_symtab_from_static_block): Update.
4910 (buildsym_compunit::augment_type_symtab): Update.
4911 (end_symtab_from_static_block): Call free_buildsym_compunit.
4912 (augment_type_symtab, end_symtab, end_expandable_symtab):
4915 2018-07-20 Tom Tromey <tom@tromey.com>
4917 * arch-utils.c: Do not include buildsym.h.
4918 * mipsread.c: Do not include buildsym.h.
4919 * machoread.c: Do not include buildsym.h.
4920 * elfread.c: Do not include buildsym.h.
4922 2018-07-20 Tom Tromey <tom@tromey.com>
4924 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
4926 (buildsym_compunit): Add new constructor.
4927 (struct buildsym_compunit) <get_last_source_file, finish_block,
4928 record_block_range, start_subfile, patch_subfile_names,
4929 push_subfile, pop_subfile, record_line, get_compunit_symtab,
4930 set_last_source_start_addr, get_last_source_start_addr,
4931 get_local_using_directives, set_local_using_directives,
4932 get_global_using_directives, outermost_context_p,
4933 get_current_context_stack, get_context_stack_depth,
4934 get_current_subfile, get_local_symbols, get_file_symbols,
4935 get_global_symbols, record_debugformat, record_producer,
4936 push_context, pop_context, end_symtab_get_static_block,
4937 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
4939 <record_pending_block, finish_block_internal, make_blockvector,
4940 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
4944 2018-05-22 Tom Tromey <tom@tromey.com>
4946 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4948 (finish_block_internal): Update.
4950 2018-07-20 Tom Tromey <tom@tromey.com>
4952 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4954 (finish_block_internal): Update.
4956 2018-07-20 Tom Tromey <tom@tromey.com>
4958 * buildsym.h (EXTERN): Don't define or undef.
4959 * buildsym.c (EXTERN): Don't define.
4961 2018-07-20 Tom Tromey <tom@tromey.com>
4963 * buildsym.c: Remove TODO comment.
4965 2018-07-20 Tom Tromey <tom@tromey.com>
4967 * coffread.c (coff_symtab_read): Update.
4968 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
4969 (xcoff_new_init): Update.
4970 * mipsread.c (mipscoff_new_init): Update.
4971 * mdebugread.c (mdebug_build_psymtabs): Update.
4972 * elfread.c (elf_new_init): Update.
4973 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
4975 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
4976 (coffstab_build_psymtabs, elfstab_build_psymtabs)
4977 (stabsect_build_psymtabs): Update.
4978 * buildsym.h (buildsym_init): Don't declare.
4979 * buildsym.c: Update comment.
4980 (prepare_for_building): Remove.
4981 (start_symtab, restart_symtab): Update.
4982 (reset_symtab_globals): Update comment.
4983 (buildsym_init): Remove.
4985 2018-07-20 Tom Tromey <tom@tromey.com>
4987 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
4988 * stabsread.c (patch_block_stabs, define_symbol, read_type)
4989 (read_enum_type, common_block_start, common_block_end)
4990 (cleanup_undefined_types_1, finish_global_stabs): Update.
4991 * mdebugread.c (psymtab_to_symtab_1): Update.
4992 * dwarf2read.c (fixup_go_packaging, read_func_scope)
4993 (read_lexical_block_scope, new_symbol): Update.
4994 * dbxread.c (process_one_symbol): Update.
4995 * coffread.c (coff_symtab_read, process_coff_symbol)
4996 (coff_read_enum_type): Update.
4997 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
4999 (get_local_symbols, get_file_symbols, get_global_symbols): New
5001 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
5003 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
5004 (~scoped_free_pendings): Update.
5005 (finish_block, prepare_for_building, reset_symtab_globals)
5006 (end_symtab_get_static_block, end_symtab_with_blockvector)
5007 (augment_type_symtab, push_context): Update.
5008 (get_local_symbols, get_file_symbols, get_global_symbols): New
5010 (buildsym_init): Update.
5012 2018-07-20 Tom Tromey <tom@tromey.com>
5014 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
5015 (process_full_type_unit): Likewise.
5016 (dwarf2_start_symtab): Set list_in_scope.
5018 2018-07-20 Tom Tromey <tom@tromey.com>
5020 * dwarf2read.c (process_psymtab_comp_unit_reader)
5021 (build_type_psymtabs_reader): Do not set list_in_scope.
5023 2018-07-20 Tom Tromey <tom@tromey.com>
5025 * buildsym.c (free_pendings): Remove.
5026 (add_symbol_to_list, scoped_free_pendings)
5027 (finish_block_internal, buildsym_init): Update.
5029 2018-07-20 Tom Tromey <tom@tromey.com>
5031 * xcoffread.c (read_xcoff_symtab): Update.
5032 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
5034 * dbxread.c (process_one_symbol): Update.
5035 * coffread.c (coff_symtab_read): Update.
5036 * buildsym.h (finish_block): Update.
5037 * buildsym.c (finish_block): Remove "listhead" argument.
5038 (end_symtab_get_static_block): Update.
5040 2018-07-20 Tom Tromey <tom@tromey.com>
5042 * buildsym.h (class scoped_free_pendings): Remove constructor.
5043 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
5045 <m_pending_block_obstack, m_pending_blocks>: New members.
5046 (pending_block_obstack, pending_blocks): Remove.
5047 (scoped_free_pendings::scoped_free_pendings): Default.
5048 (~scoped_free_pendings): Update.
5049 (free_pending_blocks): Remove.
5050 (finish_block_internal, record_pending_block, make_blockvector)
5051 (end_symtab_get_static_block, augment_type_symtab, push_context)
5052 (buildsym_init): Update.
5054 2018-07-20 Tom Tromey <tom@tromey.com>
5056 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
5057 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
5059 (pending_addrmap, pending_addrmap_obstack)
5060 (pending_addrmap_interesting): Remove.
5061 (scoped_free_pendings, record_block_range, make_blockvector)
5062 (prepare_for_building, reset_symtab_globals, buildsym_init):
5065 2018-07-20 Tom Tromey <tom@tromey.com>
5067 * xcoffread.c (process_linenos): Update.
5068 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
5069 * mdebugread.c (psymtab_to_symtab_1): Update.
5070 * dwarf2read.c (setup_type_unit_groups)
5071 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
5072 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
5073 * dbxread.c (process_one_symbol): Update.
5074 * coffread.c (coff_symtab_read, enter_linenos)
5075 (process_coff_symbol): Update.
5076 * buildsym.h (current_subfile): Don't declare.
5077 (get_current_subfile): Declare.
5078 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
5080 (start_subfile, free_buildsym_compunit, push_subfile)
5081 (prepare_for_building, start_symtab): Update.
5082 (get_current_subfile): New function.
5084 2018-07-20 Tom Tromey <tom@tromey.com>
5086 * coffread.c (coff_symtab_read): Update.
5087 * xcoffread.c (read_xcoff_symtab): Update.
5088 * dwarf2read.c (new_symbol): Update.
5089 (read_func_scope, read_lexical_block_scope): Update.
5090 * dbxread.c (process_one_symbol): Update.
5091 * buildsym.h (context_stack, context_stack_depth): Don't declare.
5092 (outermost_context_p): Remove macro.
5093 (outermost_context_p, get_current_context_stack)
5094 (get_context_stack_depth): Declare.
5095 (pop_context): Return struct context_stack.
5096 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
5098 (context_stack_size): Remove.
5099 (INITIAL_CONTEXT_STACK_SIZE): Remove.
5100 (prepare_for_building, end_symtab_get_static_block)
5101 (augment_type_symtab, push_context): Update.
5102 (pop_context): Return struct context_stack.
5103 (outermost_context_p, get_current_context_stack)
5104 (get_context_stack_depth): New functions.
5105 (buildsym_init): Update.
5107 2018-07-20 Tom Tromey <tom@tromey.com>
5109 * rust-exp.y: Now a pure parser. Update all rules.
5110 (%union): Move earlier.
5111 (current_parser, work_obstack): Remove globals.
5112 (rust_parser, ~rust_parser): Update.
5113 (class rust_parser) <copy_name, concat3, crate_name, super_name,
5114 lex_character, lex_number, lex_string, lex_identifier,
5115 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
5116 convert_name, convert_params_to_expression,
5117 convert_ast_to_expression, ast_basic_type, ast_operation,
5118 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
5119 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
5120 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
5121 ast_array_type, ast_slice_type, ast_reference_type,
5122 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
5123 (rust_parse): Update.
5124 (rustyyerror, rustyylex): Add parser parameter.
5125 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
5126 (rust_lex_stringish_test, rust_lex_test_sequence)
5127 (rust_lex_test_trailing_dot, rust_lex_test_completion)
5128 (rust_lex_test_push_back, rust_lex_tests): Update.
5130 2018-07-19 Pedro Alves <palves@redhat.com>
5132 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
5133 gdb::unique_xmalloc_ptr.
5134 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
5135 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
5136 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
5137 copy-initialization.
5138 * guile/scm-pretty-print.c (ppscm_print_children): Use
5139 gdb::unique_xmalloc_ptr instead of cleanups.
5140 (gdbscm_apply_val_pretty_printer): Remove cleanups.
5141 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
5142 gdb::unique_xmalloc_ptr.
5143 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
5144 Adjust to use gdb::unique_xmalloc_ptr.
5145 * guile/scm-utils.c (extract_arg): Adjust.
5146 * guile/scm-value.c (gdbscm_value_field): Adjust to use
5147 gdb::unique_xmalloc_ptr instead of a cleanup.
5149 2018-07-19 Tom Tromey <tom@tromey.com>
5151 * utils.c (do_value_free_to_mark)
5152 (make_cleanup_value_free_to_mark): Remove.
5153 * utils.h (make_cleanup_value_free_to_mark): Remove.
5155 2018-07-19 Pedro Alves <palves@redhat.com>
5157 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
5158 forwarding reference.
5160 2018-07-18 Pedro Alves <palves@redhat.com>
5162 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
5163 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
5166 2018-07-18 Pedro Alves <palves@redhat.com>
5168 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
5170 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
5172 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
5173 directly instead of a cleanup.
5174 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
5175 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
5176 (vlscm_binop_gdbthrow): New, factored out from ...
5177 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
5178 (vlscm_rich_compare): Use gdbscm_wrap.
5179 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
5180 instead of a cleanup.
5181 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
5183 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
5184 Use xfree directly instead of a cleanup.
5185 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
5186 Adjust to use gdbscm_wrap and scoped_value_mark.
5187 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
5188 (gdbscm_value_address, gdbscm_value_dereference)
5189 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
5191 (gdbscm_value_dynamic_type): Use scoped_value_mark.
5192 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
5194 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
5195 gdbscm_wrap and scoped_value_mark.
5196 (gdbscm_value_to_string): Use xfree directly instead of a
5197 cleanup. Move 'buffer' unique_ptr to TRY scope.
5198 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
5199 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
5201 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
5202 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
5204 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
5207 2018-07-18 Tom de Vries <tdevries@suse.de>
5209 * findvar.c (default_read_var_value): Also resolve dynamic type for
5210 LOC_OPTIMIZED_OUT vars.
5212 2018-07-18 Maciej W. Rozycki <macro@mips.com>
5214 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
5217 2018-07-17 Tom Tromey <tom@tromey.com>
5219 * guile/scm-param.c (pascm_set_func, pascm_show_func)
5220 (compute_enum_list, pascm_set_param_value_x)
5221 (gdbscm_parameter_value): Update.
5222 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
5223 (gdbscm_scm_to_host_string): Update.
5224 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
5226 * guile/scm-cmd.c (cmdscm_add_completion): Update.
5227 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
5228 * guile/scm-string.c (gdbscm_scm_to_string): Return
5230 (gdbscm_scm_to_host_string): Likewise.
5232 2018-07-17 Tom Tromey <tom@tromey.com>
5234 * guile/guile.c (gdbscm_eval_from_control_command): Update.
5235 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
5236 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
5237 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
5240 2018-07-17 Tom Tromey <tom@tromey.com>
5242 * guile/scm-param.c (pascm_signal_setshow_error): Update.
5243 * guile/guile-internal.h (gdbscm_exception_message_to_string):
5245 * guile/scm-cmd.c (cmdscm_function): Update.
5246 * guile/scm-pretty-print.c
5247 (ppscm_print_exception_unless_memory_error): Update.
5248 * guile/scm-exception.c (gdbscm_exception_message_to_string):
5249 Return unique_xmalloc_ptr.
5251 2018-07-17 Tom Tromey <tom@tromey.com>
5253 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
5256 2018-07-17 Jim Wilson <jimw@sifive.com>
5258 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
5259 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
5260 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
5261 unecessary braces after EF_RISCV_RVC test. Delete call to
5262 set_gdbarch_decr_pc_after_break.
5264 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
5265 RISCV_LAST_FP_REGNUM + 1.
5266 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
5268 2018-07-17 Tom Tromey <tom@tromey.com>
5270 * configure.ac: Remove --disable-gdbcli.
5271 * configure: Rebuild.
5272 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
5273 (SUBDIR_CLI_CFLAGS): Remove.
5274 (SFILES): Use SUBDIR_CLI_SRCS.
5275 (COMMON_OBS): Use SUBDIR_CLI_OBS.
5277 2018-07-17 Tom Tromey <tom@tromey.com>
5280 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
5282 2018-07-16 Jim Wilson <jimw@sifive.com>
5284 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
5286 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
5288 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
5290 (libunwind_frame_sniffer): Likewise.
5291 (libunwind_frame_prev_register): Likewise.
5292 (libunwind_sigtramp_frame_sniffer): Likewise.
5293 * ia64-tdep.c (ia64_access_reg): Likewise.
5294 (ia64_access_rse_reg): Likewise.
5295 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
5296 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
5298 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
5300 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
5302 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
5304 * remote-sim.c (gdbsim_target::close,
5305 gdbsim_target::mourn_inferior): Remove unused variables.
5307 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
5309 * ia64-tdep.c (ktab_buf): New global.
5310 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
5311 (get_kernel_table): Adjust.
5313 2018-07-16 Tom Tromey <tom@tromey.com>
5315 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
5316 * dwarf2read.c (using_directives, new_symbol): Use
5317 outermost_context_p.
5318 * dbxread.c (process_one_symbol): Use outermost_context_p.
5319 * coffread.c (coff_symtab_read): Use outermost_context_p.
5321 2018-07-16 Tom Tromey <tom@tromey.com>
5323 * dwarf2read.c (using_directives, read_func_scope)
5324 (read_lexical_block_scope): Update.
5325 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
5326 * buildsym.h (local_using_directives, global_using_directives):
5328 (get_local_using_directives, set_local_using_directives)
5329 (get_global_using_directives): Declare.
5330 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
5331 m_global_using_directives>: New members.
5332 (finish_block_internal, prepare_for_building)
5333 (reset_symtab_globals, end_symtab_get_static_block)
5334 (push_context): Update.
5335 (get_local_using_directives, set_local_using_directives)
5336 (get_global_using_directives): New functions.
5337 (buildsym_init): Update.
5339 2018-07-16 Tom Tromey <tom@tromey.com>
5341 * xcoffread.c (xcoff_initial_scan): Don't call
5342 free_pending_blocks.
5343 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
5344 * buildsym.h (class scoped_free_pendings): Add constructor.
5345 (free_pending_blocks): Don't declare.
5346 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
5347 (free_pending_blocks): Now static.
5349 2018-07-16 Tom Tromey <tom@tromey.com>
5351 * buildsym.h (push_subfile, pop_subfile): Update declarations.
5352 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
5354 (struct subfile_stack): Remove.
5355 (subfile_stack): Remove.
5356 (push_subfile, pop_subfile, buildsym_init): Update.
5358 2018-07-16 Tom Tromey <tom@tromey.com>
5360 * buildsym.c (push_subfile): Use gdb_assert.
5361 (pop_subfile): Use gdb_assert.
5363 2018-07-16 Tom Tromey <tom@tromey.com>
5365 * buildsym.h (merge_symbol_lists): Remove.
5366 * buildsym.c (merge_symbol_lists): Remove.
5368 2018-07-16 Tom Tromey <tom@tromey.com>
5370 * stabsread.c (scan_file_globals): Update comment.
5371 * stabsread.h (scan_file_globals): Move from buildsym.h.
5372 * buildsym.h (scan_file_globals): Move to stabsread.h.
5374 2018-07-16 Tom Tromey <tom@tromey.com>
5376 * xcoffread.c (xcoff_new_init): Update.
5377 * mipsread.c (mipscoff_new_init): Update.
5378 * mdebugread.c (mdebug_build_psymtabs): Update.
5379 * elfread.c (elf_new_init): Update.
5380 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
5381 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
5382 * buildsym.h (buildsym_new_init): Don't declare.
5383 * buildsym.c (buildsym_new_init): Remove.
5385 2018-07-16 Tom Tromey <tom@tromey.com>
5387 * stabsread.h (within_function): Move from buildsym.h.
5388 * stabsread.c (start_stabs): Clear within_function.
5389 * coffread.c (coff_start_symtab): Clear within_function.
5390 * buildsym.h (within_function): Move to stabsread.h.
5391 * buildsym.c (prepare_for_building): Update.
5393 2018-07-16 Tom Tromey <tom@tromey.com>
5395 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
5396 * dwarf2read.c (dwarf2_start_symtab): Don't set
5397 processing_gcc_compilation.
5398 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
5400 2018-07-16 Tom Tromey <tom@tromey.com>
5402 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
5403 (next_symbol_text_func): Move from buildsym.h.
5404 * stabsread.c (hashname): Move from buildsym.c.
5405 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
5406 (next_symbol_text_func, hashname): Move to stabsread.h.
5407 * buildsym.c: Don't include bcache.h
5408 (hashname): Move to stasbread.c.
5410 2018-07-16 Tom Tromey <tom@tromey.com>
5412 * buildsym.h (context_stack_size): Don't declare.
5413 * buildsym.c (context_stack_size): New global.
5415 2018-07-16 Tom Tromey <tom@tromey.com>
5417 * dbxread.c (processing_acc_compilation): New global.
5418 * buildsym.h (processing_acc_compilation): Don't declare.
5420 2018-07-16 Tom Tromey <tom@tromey.com>
5422 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
5423 * dbxread.c (read_ofile_symtab): Update.
5424 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
5425 * buildsym.h (last_source_start_addr): Remove.
5426 (set_last_source_start_addr, get_last_source_start_addr):
5428 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
5430 (struct buildsym_compunit) <m_last_source_start_addr>: New
5432 (prepare_for_building): Remove start_addr parameter.
5433 (start_symtab, restart_symtab, end_symtab_get_static_block)
5434 (end_symtab_with_blockvector): Update.
5435 (set_last_source_start_addr, get_last_source_start_addr): New
5438 2018-07-16 Tom Tromey <tom@tromey.com>
5440 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
5442 (have_line_numbers): Remove.
5443 (record_line, prepare_for_building, end_symtab_get_static_block)
5444 (augment_type_symtab): Update.
5446 2018-07-16 Tom Tromey <tom@tromey.com>
5448 * buildsym.c (~buildsym_compunit): Free the macro table.
5449 (struct buildsym_compunit) <get_macro_table, release_macros>: New
5451 <m_pending_macros>: New member.
5452 (pending_macros): Remove.
5453 (~scoped_free_pendings, get_macro_table, prepare_for_building)
5454 (reset_symtab_globals, end_symtab_get_static_block)
5455 (end_symtab_with_blockvector, augment_type_symtab)
5456 (buildsym_init): Update.
5458 2018-07-16 Tom Tromey <tom@tromey.com>
5460 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
5462 (buildsym_compunit::set_last_source_file): New method.
5463 <m_last_source_file>: New member.
5464 (prepare_for_building): Remove "name" parameter.
5465 (start_symtab, restart_symtab, reset_symtab_globals): Update.
5466 (last_source_file): Remove.
5467 (set_last_source_file, get_last_source_file): Update.
5469 2018-07-16 Tom Tromey <tom@tromey.com>
5471 * buildsym.c (prepare_for_building): Add assert.
5473 2018-07-16 Tom Tromey <tom@tromey.com>
5475 * buildsym.c (~buildsym_compunit): Update.
5476 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
5477 (start_subfile, patch_subfile_names)
5478 (end_symtab_with_blockvector): Update.
5480 2018-07-16 Tom Tromey <tom@tromey.com>
5482 * buildsym.c (struct buildsym_compunit): Add constructor,
5483 destructor, initializers.
5484 (start_buildsym_compunit): Remove.
5485 (free_buildsym_compunit): Use "delete".
5486 (start_symtab, restart_symtab): Use "new".
5488 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
5490 * symfile.c (set_objfile_default_section_offset): Remove struct
5493 2018-07-14 Stafford Horne <shorne@gmail.com>
5495 * (Responsible Maintainers): Add myself as or1k maintainer.
5497 2018-07-13 Tom Tromey <tom@tromey.com>
5499 * symfile.c (set_objfile_default_section_offset): Use extra braces
5502 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5504 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
5507 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5509 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5510 unittests/cli-utils-selftests.c
5511 * unittests/cli-utils-selftests.c: New file.
5513 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5515 * NEWS: Mention new commands. Mention change to 'thread apply'.
5517 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5519 * thread.c (thr_try_catch_cmd): New function.
5520 (thread_apply_all_command): Handle qcs flags.
5521 (thread_apply_command): Handle qcs flags.
5522 (taas_command): New function.
5523 (tfaas_command): New function.
5524 (_initialize_thread): Update to setup the new commands 'taas
5525 and 'tfaas'. Change doc string for 'thread apply'.
5527 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5529 * stack.c: (trailing_outermost_frame): New function, mostly
5530 extracted from backtrace_command_1.
5531 (leading_innermost_frame): New function.
5532 (backtrace_command_1): Update to call trailing_outermost_frame.
5533 (frame_apply_command_count): New function.
5534 (frame_apply_level_command): New function.
5535 (frame_apply_all_command): New function.
5536 (frame_apply_command): New function.
5537 (faas_command): New function.
5538 (frame_cmd_list): New variable.
5539 (_initialize_stack): Update to setup the new commands 'frame apply'
5542 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5544 * cli-utils.c (number_or_range_parser::get_number): Only handle
5545 numbers or convenience var as numbers.
5546 (parse_flags): New function.
5547 (parse_flags_qcs): New function.
5548 (number_or_range_parser::finished): Ensure parsing end is detected
5549 before end of string.
5550 * cli-utils.h (parse_flags): New function.
5551 (parse_flags_qcs): New function.
5552 (number_or_range_parser): Remove m_finished bool.
5553 (number_or_range_parser::skip_range): Set m_in_range to false.
5555 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
5557 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
5560 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5561 Jan Kratochvil <jan.kratochvil@redhat.com>
5562 Paul Fertser <fercerpav@gmail.com>
5563 Tsutomu Seki <sekiriki@gmail.com>
5564 Pedro Alves <palves@redhat.com>
5566 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5567 'unittests/parse-connection-spec-selftests.c'.
5568 (COMMON_SFILES): Add 'common/netstuff.c'.
5569 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
5570 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
5571 * common/netstuff.c: New file.
5572 * common/netstuff.h: New file.
5573 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
5574 (wait_for_connect): Update comment. New parameter
5575 'gdb::optional<int> sock' instead of 'struct serial *scb'.
5576 Use 'sock' directly instead of 'scb->fd'.
5577 (try_connect): New function, with code from 'net_open'.
5578 (net_open): Rewrite main loop to deal with multiple
5579 sockets/addresses. Handle IPv6-style hostnames; implement
5580 support for IPv6 connections.
5581 * unittests/parse-connection-spec-selftests.c: New file.
5583 2018-07-11 Pedro Alves <palves@redhat.com>
5586 * remote.c (remote_target::remote_detach_pid): Call
5587 set_current_process.
5589 2018-07-11 Pedro Alves <palves@redhat.com>
5591 * h8300-tdep.c (h8300_gdbarch_init): Remove
5592 set_gdbarch_ecoff_reg_to_regnum calls.
5594 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5597 * c-typeprint.c (c_type_print_base_struct_union): Don't print
5598 offsets/sizes for static members of a class/struct.
5600 2018-07-11 Alan Hayward <alan.hayward@arm.com>
5602 * target-descriptions.c (tdesc_register_bitsize): Rename.
5603 * target-descriptions.h (tdesc_register_bitsize): Likewise.
5604 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
5605 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
5607 2018-07-10 Tom Tromey <tom@tromey.com>
5609 * breakpoint.c (moribund_locations): Now static and a
5611 (breakpoint_init_inferior, moribund_breakpoint_here_p)
5612 (build_bpstat_chain, update_global_location_list)
5613 (breakpoint_retire_moribund): Update.
5614 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
5617 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
5619 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
5620 (riscv_register_reggroup_p): Use new function, remove unneeded
5622 (riscv_push_dummy_call): Extend assert to compare against xlen or
5623 flen based on register type.
5625 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
5627 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
5629 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
5631 * remote.c (show_hardware_watchpoint_limit): New function.
5632 (show_hardware_watchpoint_length_limit): New function.
5633 (show_hardware_breakpoint_limit): New function.
5634 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
5635 where appropriate, update help text.
5637 2018-07-09 Tom Tromey <tom@tromey.com>
5639 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
5640 (CLIBS): Don't mention NAT_CLIBS.
5642 2018-07-09 Tom Tromey <tom@tromey.com>
5644 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
5645 (LIBGDB_OBS, clean mostlyclean): Update.
5646 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
5648 2018-07-09 Tom Tromey <tom@tromey.com>
5650 * Makefile.in (%.c: %.y): Use ECHO_YACC.
5651 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
5652 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
5654 2018-07-09 Tom Tromey <tom@tromey.com>
5656 * Makefile.in (ALLDEPFILES): Remove exec.c.
5657 (COMMON_OBS): Remove exec.o.
5658 (COMMON_SFILES): Add exec.c.
5660 2018-07-09 Tom Tromey <tom@tromey.com>
5662 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
5664 2018-07-09 Tom Tromey <tom@tromey.com>
5666 * Makefile.in (clean mostlyclean): Remove stamp-version.
5667 (version.c): Depend on stamp-version.
5668 (stamp-version): New rule, from version.c rule.
5670 2018-07-09 Tom Tromey <tom@tromey.com>
5672 * Makefile.in (init.c): Depend on stamp-init.
5673 (stamp-init): New rule, from init.c rule.
5674 (clean mostlyclean): Remove stamp-init.
5676 2018-07-09 Tom Tromey <tom@tromey.com>
5678 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
5679 SUBDIR_GCC_COMPILE_SRCS.
5681 2018-07-09 Tom Tromey <tom@tromey.com>
5683 * Makefile.in (init.c): Remove some unused sed rules.
5685 2018-07-09 Tom Tromey <tom@tromey.com>
5687 * Makefile.in (TSOBS): Remove.
5688 (INIT_FILES): Update.
5689 (LIBGDB_OBS): Update.
5690 (COMMON_SFILES): Add inflow.c.
5691 (SFILES): Remove inflow.c.
5693 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
5695 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
5697 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
5699 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
5700 get_saveloc_name, is_signal_frame_name, step_name,
5701 init_remote_name, create_addr_space_name,
5702 destroy_addr_space_name, search_unwind_table_name,
5703 find_dyn_list_name): Constify.
5705 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
5707 * darwin-nat.c (darwin_pthread_kill): New function.
5708 (darwin_resume_thread): Use darwin_pthread_kill.
5710 2018-07-05 Tom de Vries <tdevries@suse.de>
5712 * macroexp.c (macro_buffer) <operator=>: New member function.
5714 2018-07-04 Tom Tromey <tom@tromey.com>
5716 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
5718 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
5720 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
5721 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
5722 * maint.c: Likewise.
5725 2018-07-04 Joel Brobecker <brobecker@adacore.com>
5727 * NEWS: Create a new section for the next release branch.
5728 Rename the section of the current branch, now that it has
5731 2018-07-04 Joel Brobecker <brobecker@adacore.com>
5733 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
5734 * version.in: Bump version to 8.2.50.DATE-git.
5736 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5737 Pedro Alves <palves@redhat.com>
5739 * linux-nat.c (linux_init_ptrace): Rename to ...
5740 (linux_init_ptrace_procfs): ... this. Call
5741 linux_proc_init_warnings.
5742 (linux_nat_target::post_attach)
5743 (linux_nat_target::post_startup_inferior): Adjust.
5744 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
5745 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
5747 2018-07-04 Tom de Vries <tdevries@suse.de>
5749 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
5751 (read_comp_unit_head): ... here.
5753 2018-07-03 Tom Tromey <tom@tromey.com>
5755 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
5756 (stop_tracing, tstatus_command)
5757 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
5758 (print_one_static_tracepoint_marker): Update.
5759 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
5761 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
5763 (all_tracepoints, static_tracepoints_here): Return std::vector.
5765 2018-07-03 Tom Tromey <tom@tromey.com>
5767 * common/ptid.c (ptid_equal): Remove.
5768 * common/ptid.h (ptid_equal): Don't declare.
5769 * ada-tasks.c: Update.
5770 * breakpoint.c: Update.
5771 * common/agent.c: Update.
5772 * corelow.c: Update.
5773 * darwin-nat-info.c: Update.
5774 * darwin-nat.c: Update.
5776 * dtrace-probe.c: Update.
5777 * dummy-frame.c: Update.
5778 * fbsd-nat.c: Update.
5780 * gdbthread.h: Update.
5781 * gnu-nat.c: Update.
5782 * go32-nat.c: Update.
5783 * inf-loop.c: Update.
5784 * inf-ptrace.c: Update.
5785 * infcall.c: Update.
5789 * linux-fork.c: Update.
5790 * linux-nat.c: Update.
5791 * linux-thread-db.c: Update.
5792 * mi/mi-cmd-var.c: Update.
5793 * mi/mi-interp.c: Update.
5794 * mi/mi-main.c: Update.
5795 * nto-procfs.c: Update.
5796 * ppc-linux-tdep.c: Update.
5798 * python/py-inferior.c: Update.
5799 * python/py-record-btrace.c: Update.
5800 * python/py-record.c: Update.
5801 * ravenscar-thread.c: Update.
5802 * regcache.c: Update.
5803 * remote-sim.c: Update.
5805 * sol-thread.c: Update.
5808 * tui/tui-stack.c: Update.
5810 * windows-nat.c: Update.
5811 * windows-tdep.c: Update.
5813 2018-07-03 Tom Tromey <tom@tromey.com>
5815 * common/ptid.c (ptid_match): Remove.
5816 * common/ptid.h (ptid_match): Don't declare.
5817 * fbsd-nat.c: Update.
5820 * linux-nat.c: Update.
5821 * record-btrace.c: Update.
5822 * regcache.c: Update.
5825 2018-07-03 Tom Tromey <tom@tromey.com>
5827 * common/ptid.c (ptid_tid_p): Remove.
5828 * common/ptid.h (ptid_tid_p): Don't declare.
5829 * sol-thread.c: Update.
5831 2018-07-03 Tom Tromey <tom@tromey.com>
5833 * common/ptid.c (ptid_lwp_p): Remove.
5834 * common/ptid.h (ptid_lwp_p): Don't declare.
5835 * fbsd-nat.c: Update.
5836 * linux-nat.c: Update.
5837 * nat/linux-procfs.c: Update.
5838 * nat/x86-linux-dregs.c: Update.
5839 * sol-thread.c: Update.
5841 2018-07-03 Tom Tromey <tom@tromey.com>
5843 * common/ptid.c (ptid_is_pid): Remove.
5844 * common/ptid.h (ptid_is_pid): Don't declare.
5846 * linux-nat.c: Update.
5847 * mi/mi-interp.c: Update.
5851 2018-07-03 Tom Tromey <tom@tromey.com>
5853 * common/ptid.c (ptid_get_tid): Remove.
5854 * common/ptid.h (ptid_get_tid): Don't declare.
5855 * ada-tasks.c: Update.
5856 * aix-thread.c: Update.
5857 * bsd-uthread.c: Update.
5858 * darwin-nat.c: Update.
5859 * fbsd-nat.c: Update.
5860 * i386-darwin-nat.c: Update.
5862 * linux-tdep.c: Update.
5863 * nto-procfs.c: Update.
5864 * ppc-ravenscar-thread.c: Update.
5865 * python/py-infthread.c: Update.
5866 * ravenscar-thread.c: Update.
5867 * sol-thread.c: Update.
5868 * sparc-ravenscar-thread.c: Update.
5869 * windows-nat.c: Update.
5871 2018-07-03 Tom Tromey <tom@tromey.com>
5873 * common/ptid.c (ptid_get_lwp): Remove.
5874 * common/ptid.h (ptid_get_lwp): Don't declare.
5875 * aarch64-linux-nat.c: Update.
5876 * ada-tasks.c: Update.
5877 * aix-thread.c: Update.
5878 * amd64-linux-nat.c: Update.
5879 * arm-linux-nat.c: Update.
5880 * corelow.c: Update.
5881 * fbsd-nat.c: Update.
5882 * fbsd-tdep.c: Update.
5883 * gnu-nat.c: Update.
5884 * i386-cygwin-tdep.c: Update.
5885 * i386-gnu-nat.c: Update.
5886 * i386-linux-nat.c: Update.
5887 * ia64-linux-nat.c: Update.
5888 * inf-ptrace.c: Update.
5890 * linux-fork.c: Update.
5891 * linux-nat.c: Update.
5892 * linux-tdep.c: Update.
5893 * linux-thread-db.c: Update.
5894 * mips-linux-nat.c: Update.
5895 * nat/aarch64-linux-hw-point.c: Update.
5896 * nat/aarch64-linux.c: Update.
5897 * nat/linux-btrace.c: Update.
5898 * nat/linux-osdata.c: Update.
5899 * nat/linux-procfs.c: Update.
5900 * nat/x86-linux-dregs.c: Update.
5901 * obsd-nat.c: Update.
5902 * ppc-fbsd-nat.c: Update.
5903 * ppc-linux-nat.c: Update.
5905 * python/py-infthread.c: Update.
5906 * ravenscar-thread.c: Update.
5908 * s390-linux-nat.c: Update.
5909 * sol-thread.c: Update.
5910 * sol2-tdep.c: Update.
5911 * spu-linux-nat.c: Update.
5912 * x86-linux-nat.c: Update.
5913 * xtensa-linux-nat.c: Update.
5915 2018-07-03 Tom Tromey <tom@tromey.com>
5917 * common/ptid.c (ptid_get_pid): Remove.
5918 * common/ptid.h (ptid_get_pid): Don't declare.
5919 * aarch64-linux-nat.c: Update.
5920 * ada-lang.c: Update.
5921 * aix-thread.c: Update.
5922 * alpha-bsd-nat.c: Update.
5923 * amd64-fbsd-nat.c: Update.
5924 * amd64-linux-nat.c: Update.
5925 * arm-linux-nat.c: Update.
5926 * arm-nbsd-nat.c: Update.
5928 * break-catch-syscall.c: Update.
5929 * breakpoint.c: Update.
5930 * bsd-uthread.c: Update.
5931 * corelow.c: Update.
5933 * darwin-nat.c: Update.
5934 * fbsd-nat.c: Update.
5935 * fbsd-tdep.c: Update.
5937 * gnu-nat.c: Update.
5938 * hppa-nbsd-nat.c: Update.
5939 * hppa-obsd-nat.c: Update.
5940 * i386-fbsd-nat.c: Update.
5941 * ia64-linux-nat.c: Update.
5942 * inf-ptrace.c: Update.
5944 * inferior.c: Update.
5945 * inferior.h: Update.
5948 * linux-fork.c: Update.
5949 * linux-nat.c: Update.
5950 * linux-tdep.c: Update.
5951 * linux-thread-db.c: Update.
5952 * m68k-bsd-nat.c: Update.
5953 * mi/mi-interp.c: Update.
5954 * mi/mi-main.c: Update.
5955 * mips-linux-nat.c: Update.
5956 * mips-nbsd-nat.c: Update.
5957 * mips64-obsd-nat.c: Update.
5958 * nat/aarch64-linux-hw-point.c: Update.
5959 * nat/aarch64-linux.c: Update.
5960 * nat/linux-btrace.c: Update.
5961 * nat/linux-osdata.c: Update.
5962 * nat/linux-procfs.c: Update.
5963 * nat/x86-linux-dregs.c: Update.
5964 * nto-procfs.c: Update.
5965 * obsd-nat.c: Update.
5966 * ppc-linux-nat.c: Update.
5967 * ppc-nbsd-nat.c: Update.
5968 * ppc-obsd-nat.c: Update.
5969 * proc-service.c: Update.
5971 * python/py-inferior.c: Update.
5972 * python/py-infthread.c: Update.
5973 * ravenscar-thread.c: Update.
5975 * remote-sim.c: Update.
5977 * rs6000-nat.c: Update.
5978 * s390-linux-nat.c: Update.
5979 * sh-nbsd-nat.c: Update.
5980 * sol-thread.c: Update.
5981 * sparc-nat.c: Update.
5982 * sparc64-tdep.c: Update.
5983 * spu-linux-nat.c: Update.
5984 * spu-tdep.c: Update.
5985 * target-debug.h: Update.
5988 * tid-parse.c: Update.
5989 * tracefile-tfile.c: Update.
5990 * vax-bsd-nat.c: Update.
5991 * windows-nat.c: Update.
5992 * x86-linux-nat.c: Update.
5993 * x86-nat.c: Update.
5995 2018-07-03 Tom Tromey <tom@tromey.com>
5997 * common/ptid.c (pid_to_ptid): Remove.
5998 * common/ptid.h (pid_to_ptid): Don't declare.
5999 * aix-thread.c: Update.
6000 * arm-linux-nat.c: Update.
6001 * common/ptid.c: Update.
6002 * common/ptid.h: Update.
6003 * corelow.c: Update.
6005 * darwin-nat.c: Update.
6006 * fbsd-nat.c: Update.
6007 * fork-child.c: Update.
6008 * gnu-nat.c: Update.
6009 * go32-nat.c: Update.
6010 * inf-ptrace.c: Update.
6012 * inferior.c: Update.
6014 * linux-fork.c: Update.
6015 * linux-nat.c: Update.
6016 * nat/aarch64-linux-hw-point.c: Update.
6017 * nat/fork-inferior.c: Update.
6018 * nat/x86-linux-dregs.c: Update.
6019 * nto-procfs.c: Update.
6020 * obsd-nat.c: Update.
6022 * progspace.c: Update.
6024 * rs6000-nat.c: Update.
6025 * s390-linux-nat.c: Update.
6026 * sol-thread.c: Update.
6027 * spu-linux-nat.c: Update.
6030 * tracefile-tfile.c: Update.
6031 * windows-nat.c: Update.
6033 2018-07-03 Tom Tromey <tom@tromey.com>
6035 * common/ptid.h (ptid_build): Don't declare.
6036 * common/ptid.c (ptid_build): Remove.
6037 * aix-thread.c: Update.
6038 * bsd-kvm.c: Update.
6039 * bsd-uthread.c: Update.
6040 * common/agent.c: Update.
6041 * common/ptid.c: Update.
6042 * common/ptid.h: Update.
6043 * corelow.c: Update.
6044 * darwin-nat.c: Update.
6045 * fbsd-nat.c: Update.
6046 * gnu-nat.c: Update.
6047 * linux-fork.c: Update.
6048 * linux-nat.c: Update.
6049 * linux-thread-db.c: Update.
6050 * nat/linux-osdata.c: Update.
6051 * nat/linux-procfs.c: Update.
6052 * nto-procfs.c: Update.
6053 * obsd-nat.c: Update.
6054 * proc-service.c: Update.
6056 * ravenscar-thread.c: Update.
6057 * remote-sim.c: Update.
6059 * sol-thread.c: Update.
6061 * windows-nat.c: Update.
6063 2018-07-03 Tom Tromey <tom@tromey.com>
6065 * infrun.c (follow_exec): Use exit_inferior_silent.
6066 * inferior.c (exit_inferior_num_silent): Remove.
6067 * inferior.h (exit_inferior_num_silent): Don't declare.
6069 2018-07-03 Tom Tromey <tom@tromey.com>
6072 * darwin-nat.c (darwin_attach_pid): Reset inferior and
6073 inferior_ptid on error.
6075 2018-07-02 Maciej W. Rozycki <macro@mips.com>
6076 Simon Marchi <simon.marchi@polymtl.ca>
6079 * disasm.h (gdb_disassembler): Add
6080 `m_disassembler_options_holder'. member
6081 * disasm.c (get_all_disassembler_options): New function.
6082 (gdb_disassembler::gdb_disassembler): Use it.
6083 (gdb_buffered_insn_length_init_dis): Likewise.
6084 (gdb_buffered_insn_length): Adjust accordingly.
6085 (set_disassembler_options): Handle options with arguments.
6086 (show_disassembler_options_sfunc): Likewise. Add a leading new
6087 line if showing options with descriptions.
6088 (disassembler_options_completer): Adapt to using the
6089 `disasm_options_and_args_t' structure.
6090 * mips-tdep.c (mips_disassembler_options): New variable.
6091 (mips_disassembler_options_o32): Likewise.
6092 (mips_disassembler_options_n32): Likewise.
6093 (mips_disassembler_options_n64): Likewise.
6094 (gdb_print_insn_mips): Don't set `disassembler_options'.
6095 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
6097 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
6098 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
6099 `gdbarch_disassembler_options_implicit' and
6100 `gdbarch_valid_disassembler_options'.
6101 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
6102 `disasm_options_and_args_t' structure.
6103 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
6105 (valid_disassembler_options): Switch from `disasm_options_t' to
6106 the `disasm_options_and_args_t' structure.
6107 * NEWS: Document `set disassembler-options' support for the MIPS
6109 * gdbarch.h: Regenerate.
6110 * gdbarch.c: Regenerate.
6112 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
6114 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
6116 2018-06-29 Joel Brobecker <brobecker@adacore.com>
6118 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
6119 parameter in call to amd64_target_description.
6120 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
6121 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
6122 (amd64fbsd_init_abi): Likewise.
6123 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
6124 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
6125 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
6126 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
6128 2018-06-29 Pedro Alves <palves@redhat.com>
6130 * gdb/amd64-tdep.h (amd64_create_target_description): Add
6131 "segments" parameter.
6132 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
6133 (_initialize_amd64_tdep): Update call to
6134 amd64_create_target_description.
6135 (amd64_target_description): Add "segments" parameter. Adjust
6136 the implementation to use it.
6137 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
6138 call to amd64_create_target_description.
6139 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
6140 * gdb/arch/amd64.h (amd64_create_target_description): Add
6141 "segments" register.
6142 * gdb/arch/amd64.c (amd64_create_target_description): Add
6143 "segments" parameter. Call create_feature_i386_64bit_segments
6144 only if SEGMENTS is true.
6145 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
6146 call to amd64_create_target_description.
6148 2018-06-29 Pedro Alves <palves@redhat.com>
6150 * thread.c (thread_target_id_str): New, factored out from ...
6151 (print_thread_info_1): ... here. Use it to compute the max
6152 "Target Id" column width.
6154 2018-06-29 Pedro Alves <palves@redhat.com>
6156 * remote.c (remote_target::extra_thread_info): Delete
6157 'display_buf' and 'n' locals. from the cache, regardless of
6158 packet mechanims is in use. Use cache for qThreadExtra and qP
6161 2018-06-29 Pedro Alves <palves@redhat.com>
6163 * blockframe.c (find_pc_sect_containing_function): New function.
6164 * breakpoint.c (print_breakpoint_location): Don't call
6165 find_pc_sect_function.
6166 * linespec.c (create_sals_line_offset): Record the location's
6168 * linespec.c (convert_address_location_to_sals): Fill in sal's
6169 symbol with find_pc_sect_containing_function.
6170 * symtab.c (find_function_start_sal): Rename to ...
6171 (find_function_start_sal_1): ... this.
6172 (find_function_start_sal): Reimplement as wrapper around
6173 find_function_start_sal_1, and use
6174 find_pc_sect_containing_function to fill in the sal's symbol.
6175 (find_function_start_sal(symbol*, bool)): Adjust.
6176 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
6178 (find_pc_sect_containing_function): Declare.
6180 2018-06-29 Pedro Alves <palves@redhat.com>
6182 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
6183 true if the the location has no symbol.
6185 2018-06-28 Tom Tromey <tom@tromey.com>
6187 * NEWS: Mention --enable-codesign.
6188 * silent-rules.mk (ECHO_SIGN): New variable.
6189 * configure.ac: Add --enable-codesign.
6190 * configure: Rebuild.
6191 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
6192 (gdb$(EXEEXT)): Optionally invoke codesign.
6194 2018-06-28 Pedro Alves <palves@redhat.com>
6196 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
6198 (switch_to_thread_no_regs): Adjust comment.
6199 * infcmd.c (stop_pc): Delete.
6200 (post_create_inferior, info_program_command): Replace references
6201 to stop_pc with references to thread_info->suspend.stop_pc.
6202 * inferior.h (stop_pc): Delete declaration.
6203 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
6204 (handle_inferior_event_1, handle_signal_stop)
6205 (process_event_stop_test, keep_going_stepped_thread)
6206 (handle_step_into_function, handle_step_into_function_backward)
6207 (print_stop_location): Replace references to stop_pc with
6208 references to thread_info->suspend.stop_pc.
6209 (struct infcall_suspend_state) <stop_pc>: Delete field.
6210 (save_infcall_suspend_state, restore_infcall_suspend_state):
6211 Remove references to inf_stat->stop_pc.
6212 * linux-fork.c (fork_load_infrun_state): Likewise.
6213 * record-btrace.c (record_btrace_set_replay): Likewise.
6214 * record-full.c (record_full_goto_entry): Likewise.
6215 * remote.c (print_one_stopped_thread): Likewise.
6216 * target.c (target_resume): Extend comment.
6217 * thread.c (set_executing_thread): New.
6218 (set_executing): Use it.
6219 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
6220 Remove references to stop_pc.
6222 2018-06-28 Pedro Alves <palves@redhat.com>
6224 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
6225 Moving fetching stop_pc until after ecs->event_thread is refreshed.
6227 2018-06-28 Tom Tromey <tom@tromey.com>
6229 * coffread.c (coff_symfile_finish): Update.
6230 * xcoffread.c (xcoff_symfile_finish): Update.
6231 * elfread.c (elf_symfile_finish): Update.
6232 * symfile.h (dwarf2_free_objfile): Don't declare.
6233 * dwarf2read.c (_initialize_dwarf2_read): Use
6234 register_objfile_data_with_cleanup.
6235 (dwarf2_free_objfile): Now static. Change signature.
6237 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
6239 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
6240 option "-o" to add-symbol-file-load to add an offset to each
6241 section's load address.
6242 * symfile.c (set_objfile_default_section_offset): New function.
6244 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
6246 * symfile.c (add_symbol_file_command): Make sure that sections
6247 with the same name are sorted in the same order.
6249 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
6251 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
6252 require the second argument. If omitted, load sections at the
6253 addresses specified in the file.
6255 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
6257 * symfile.c (symbol_file_command, symbol_file_add_main_1)
6258 (_initialize_symfile): Add option "-o" to symbol-file to add an
6259 offset to each section of the symbol file.
6261 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
6263 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
6265 2018-06-27 Tom Tromey <tom@tromey.com>
6267 * stack.c (_initialize_stack): Update "func" help text.
6269 2018-06-27 Tom Tromey <tom@tromey.com>
6271 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
6273 (unwind_infopy_str, pyuw_create_unwind_info)
6274 (unwind_infopy_add_saved_register, pyuw_sniffer)
6275 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
6277 (struct saved_reg): Add constructor.
6278 <value>: Now a gdbpy_ref<>.
6280 2018-06-27 Tom Tromey <tom@tromey.com>
6282 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
6284 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
6286 * gdb-gdb.py.in: Format using autopep8.
6288 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
6290 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
6291 (type_lookup_function): Recognize CORE_ADDR values.
6293 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
6295 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
6298 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
6300 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
6303 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
6305 * gdb-gdb.py: Move to...
6306 * gdb-gdb.py.in: ... here.
6307 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
6308 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
6310 (distclean): Remove gdb-gdb.py when cleaning.
6311 (gdb-gdb.py, gdb-gdb.gdb): New rules.
6312 * configure: Re-generate.
6314 2018-06-27 Pedro Alves <palves@redhat.com>
6316 * proc-service.c (get_ps_regcache): New.
6317 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6318 (ps_lsetfpregs): Use it.
6320 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
6323 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
6324 (dwarf_decode_lines_1): Adjust.
6326 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
6328 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
6330 <info_proc>: Likewise.
6332 2018-06-26 Joel Brobecker <brobecker@adacore.com>
6334 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
6335 to windows_fetch_one_register, and only handle the case of
6336 fetching one register. Move the code that reloads the context
6337 and iterates over all registers if R is negative to...
6338 (windows_nat_target::fetch_registers): ... here.
6339 (do_windows_store_inferior_registers): Rename to
6340 windows_store_one_register, and only handle the case of storing
6341 one register. Move the code that handles the case where r is
6343 (windows_nat_target::store_registers) ... here.
6345 2018-06-26 Tom Tromey <tom@tromey.com>
6348 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
6349 * rust-lang.c (rust_print_struct_def): Add podata parameter.
6351 (rust_internal_print_type): Add podata parameter.
6352 (rust_print_type): Update.
6354 2018-06-26 Tom Tromey <tom@tromey.com>
6356 * typeprint.h (struct print_offset_data) <update, finish,
6357 maybe_print_hole>: New methods.
6358 <indentation>: New constant.
6359 * typeprint.c (print_offset_data::indentation): Define.
6360 (print_offset_data::maybe_print_hole, print_offset_data::update)
6361 (print_offset_data::finish): Move from c-typeprint.c and rename.
6362 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
6363 (print_spaces_filtered_with_print_options): Update.
6364 (c_print_type_union_field_offset, maybe_print_hole)
6365 (c_print_type_struct_field_offset): Move to typeprint.c and
6367 (c_type_print_base_struct_union): Update.
6369 2018-06-25 Pedro Alves <palves@redhat.com>
6371 * gdbthread.h (thread_info_ref, delete_thread)
6372 (delete_thread_silent, first_thread_of_inferior)
6373 (any_thread_of_inferior, switch_to_thread)
6374 (enable_thread_stack_temporaries)
6375 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
6376 (get_last_thread_stack_temporary)
6377 (value_in_thread_stack_temporaries, can_access_registers_thread):
6378 Spell out "struct thread_info" instead of just "thread_info".
6379 * inferior.h (notice_new_inferior): Likewise.
6381 2018-06-25 Pedro Alves <palves@redhat.com>
6383 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
6384 pass thread_info pointer to delete_thread.
6385 (windows_nat_target::detach): Pass inferior pointer to
6387 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
6389 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
6390 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
6391 and pass a thread_info pointer to delete_thread.
6392 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
6393 pass thread_info pointer to delete_thread.
6394 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
6395 delete_thread_silent call.
6396 * procfs.c (procfs_target::detach): Pass inferior pointer to
6398 (procfs_target::wait): Pass thread_info pointer to delete_thread.
6399 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
6400 delete_thread_silent call.
6401 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
6402 pass thread_info pointer to delete_thread.
6403 (windows_nat_target::detach): Pass inferior pointer to
6406 2018-06-22 Alan Hayward <alan.hayward@arm.com>
6408 * regcache.c (readable_regcache::read_part): Fix asserts.
6409 (reg_buffer::raw_collect_part): New function.
6410 (regcache::write_part): Fix asserts.
6411 (reg_buffer::raw_supply_part): New function.
6412 (regcache::transfer_regset_register): New helper function.
6413 (regcache::transfer_regset): Call new functions.
6414 (regcache_supply_regset): Use gdb_byte*.
6415 (regcache::supply_regset): Likewise.
6416 (regcache_collect_regset): Likewise.
6417 (regcache::collect_regset): Likewise.
6418 * regcache.h (reg_buffer::raw_collect_part): New declaration.
6419 (reg_buffer::raw_supply_part): Likewise.
6420 (regcache::transfer_regset_register): Likewise.
6421 (regcache::transfer_regset): Use gdb_byte*.
6423 2018-06-22 Alan Hayward <alan.hayward@arm.com>
6425 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
6427 2018-06-21 Pedro Alves <palves@redhat.com>
6429 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
6430 instead of a ptid_t. All callers adjusted.
6431 * ada-tasks.c (ada_get_task_number): Likewise. All callers
6433 (print_ada_task_info, display_current_task_id, task_command_1):
6435 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
6437 (breakpoint_kind): Adjust.
6438 (remove_breakpoints_pid): Rename to ...
6439 (remove_breakpoints_inf): ... this. Adjust to take an inferior
6440 pointer. All callers adjusted.
6441 (bpstat_clear_actions): Use inferior_thread.
6442 (get_bpstat_thread): New.
6443 (bpstat_do_actions): Use it.
6444 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
6445 to take a thread_info pointer. All callers adjusted.
6446 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
6447 (breakpoint_re_set_thread): Use inferior_thread.
6448 * breakpoint.h (struct inferior): Forward declare.
6449 (bpstat_stop_status): Update.
6450 (remove_breakpoints_pid): Delete.
6451 (remove_breakpoints_inf): New.
6452 * bsd-uthread.c (bsd_uthread_target::wait)
6453 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
6454 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
6455 (maint_btrace_packet_history_cmd)
6456 (maint_btrace_clear_packet_history_cmd): Adjust.
6457 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
6459 * cli/cli-interp.c: Include "inferior.h".
6460 * common/refcounted-object.h (struct
6461 refcounted_object_ref_policy): New.
6462 * compile/compile-object-load.c: Include gdbthread.h.
6463 (store_regs): Use inferior_thread.
6464 * corelow.c (core_target::close): Use current_inferior.
6465 (core_target_open): Adjust to use first_thread_of_inferior and use
6466 the current inferior.
6467 * ctf.c (ctf_target::close): Adjust to use current_inferior.
6468 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
6469 <thread>: ... this new field. All references adjusted.
6470 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
6471 Take a thread_info pointer instead of a ptid_t.
6472 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
6473 (dummy_frame_discard, register_dummy_frame_dtor): Take a
6474 thread_info pointer instead of a ptid_t.
6475 * elfread.c: Include "inferior.h".
6476 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
6477 Use inferior_thread.
6478 * eval.c (evaluate_subexp): Likewise.
6479 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
6481 * gdb_proc_service.h (struct thread_info): Forward declare.
6482 (struct ps_prochandle) <ptid>: Delete, replaced by ...
6483 <thread>: ... this new field. All references adjusted.
6484 * gdbarch.h, gdbarch.c: Regenerate.
6485 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
6486 'thread' parameter. All implementations and callers adjusted.
6487 * gdbthread.h (thread_info) <set_running>: New method.
6488 (delete_thread, delete_thread_silent): Take a thread_info pointer
6490 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
6491 (first_thread_of_process): Delete, replaced by ...
6492 (first_thread_of_inferior): ... this new function. All callers
6494 (any_live_thread_of_process): Delete, replaced by ...
6495 (any_live_thread_of_inferior): ... this new function. All callers
6497 (switch_to_thread, switch_to_no_thread): Declare.
6498 (is_executing): Delete.
6499 (enable_thread_stack_temporaries): Update comment.
6500 <enable_thread_stack_temporaries>: Take a thread_info pointer
6501 instead of a ptid_t. Incref the thread.
6502 <~enable_thread_stack_temporaries>: Decref the thread.
6505 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
6506 (get_last_thread_stack_temporary)
6507 (value_in_thread_stack_temporaries, can_access_registers_thread):
6508 Take a thread_info pointer instead of a ptid_t. All callers
6510 * infcall.c (get_call_return_value): Use inferior_thread.
6511 (run_inferior_call): Work with thread pointers instead of ptid_t.
6512 (call_function_by_hand_dummy): Work with thread pointers instead
6513 of ptid_t. Use thread_info_ref.
6514 * infcmd.c (proceed_thread_callback): Access thread's state
6516 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
6517 access thread's state directly.
6518 (continue_command): Use inferior_thread.
6519 (info_program_command): Use find_thread_ptid and access thread
6521 (proceed_after_attach_callback): Use thread state directly.
6522 (notice_new_inferior): Take a thread_info pointer instead of a
6523 ptid_t. All callers adjusted.
6524 (exit_inferior): Take an inferior pointer instead of a pid. All
6526 (exit_inferior_silent): New.
6527 (detach_inferior): Delete.
6528 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
6529 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
6530 (detach_inferior_command, kill_inferior_command): Use
6531 find_inferior_id instead of valid_gdb_inferior_id and
6532 gdb_inferior_id_to_pid.
6533 (inferior_command): Use inferior and thread pointers.
6534 * inferior.h (struct thread_info): Forward declare.
6535 (notice_new_inferior): Take a thread_info pointer instead of a
6536 ptid_t. All callers adjusted.
6537 (detach_inferior): Delete declaration.
6538 (exit_inferior, exit_inferior_silent): Take an inferior pointer
6539 instead of a pid. All callers adjusted.
6540 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
6541 (valid_gdb_inferior_id): Delete.
6542 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
6543 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
6544 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
6546 <inf>: ... this new field.
6547 <step_ptid>: Delete, replaced by ...
6548 <step_thread>: ... this new field.
6549 (get_displaced_stepping_state): Take an inferior pointer instead
6550 of a pid. All callers adjusted.
6551 (displaced_step_in_progress_any_inferior): Adjust.
6552 (displaced_step_in_progress_thread): Take a thread pointer instead
6553 of a ptid_t. All callers adjusted.
6554 (displaced_step_in_progress, add_displaced_stepping_state): Take
6555 an inferior pointer instead of a pid. All callers adjusted.
6556 (get_displaced_step_closure_by_addr): Adjust.
6557 (remove_displaced_stepping_state): Take an inferior pointer
6558 instead of a pid. All callers adjusted.
6559 (displaced_step_prepare_throw, displaced_step_prepare)
6560 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
6561 All callers adjusted.
6562 (start_step_over): Adjust.
6563 (infrun_thread_ptid_changed): Remove bit updating ptids in the
6564 displaced step queue.
6565 (do_target_resume): Adjust.
6566 (fetch_inferior_event): Use inferior_thread.
6567 (context_switch, get_inferior_stop_soon): Take an
6568 execution_control_state pointer instead of a ptid_t. All callers
6570 (switch_to_thread_cleanup): Delete.
6571 (stop_all_threads): Use scoped_restore_current_thread.
6572 * inline-frame.c: Include "gdbthread.h".
6573 (inline_state) <inline_state>: Take a thread pointer instead of a
6574 ptid_t. All callers adjusted.
6575 <ptid>: Delete, replaced by ...
6576 <thread>: ... this new field.
6577 (find_inline_frame_state): Take a thread pointer instead of a
6578 ptid_t. All callers adjusted.
6579 (skip_inline_frames, step_into_inline_frame)
6580 (inline_skipped_frames, inline_skipped_symbol): Take a thread
6581 pointer instead of a ptid_t. All callers adjusted.
6582 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
6583 (inline_skipped_frames, inline_skipped_symbol): Likewise.
6584 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
6586 * linux-nat.c (get_detach_signal): Likewise.
6587 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
6588 (thread_db_notice_clone): Adjust.
6589 (thread_db_find_new_threads_silently)
6590 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
6591 a thread pointer instead of a ptid_t. All callers adjusted.
6592 * mi/mi-cmd-var.c: Include "inferior.h".
6593 (mi_cmd_var_update_iter): Update to use thread pointers.
6594 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
6596 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
6598 (mi_output_running): ... this new function.
6599 (mi_on_resume_1): Adjust to use it.
6600 (mi_user_selected_context_changed): Adjust to use inferior_thread.
6601 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
6603 (interrupt_thread_callback): : Adjust to use thread and inferior
6605 * proc-service.c: Include "gdbthread.h".
6606 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
6607 * progspace-and-thread.c: Include "inferior.h".
6608 * progspace.c: Include "inferior.h".
6609 * python/py-exitedevent.c (create_exited_event_object): Adjust to
6610 hold a reference to an inferior_object.
6611 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
6613 * python/py-inferior.c (struct inferior_object): Give the type a
6614 tag name instead of a typedef.
6615 (python_on_normal_stop): No need to check if the current thread is
6617 (inferior_to_inferior_object): Change return type to
6618 inferior_object. All callers adjusted.
6619 (find_thread_object): Delete, bits factored out to ...
6620 (thread_to_thread_object): ... this new function.
6621 * python/py-infthread.c (create_thread_object): Use
6622 inferior_to_inferior_object.
6623 (thpy_is_stopped): Use thread pointer directly.
6624 (gdbpy_selected_thread): Use inferior_thread.
6625 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
6626 field, replaced with ...
6627 <thread>: ... this new field. All users adjusted.
6628 (btpy_insn_or_gap_new): Drop const.
6629 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
6631 * python/py-record.c: Include "gdbthread.h".
6632 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
6633 a ptid_t. All callers adjusted.
6634 (gdbpy_current_recording): Use inferior_thread.
6635 * python/py-record.h (recpy_record_object) <ptid>: Delete
6636 field, replaced with ...
6637 <thread>: ... this new field. All users adjusted.
6638 (recpy_element_object) <ptid>: Delete
6639 field, replaced with ...
6640 <thread>: ... this new field. All users adjusted.
6641 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
6642 a ptid_t. All callers adjusted.
6643 * python/py-threadevent.c: Include "gdbthread.h".
6644 (get_event_thread): Use thread_to_thread_object.
6645 * python/python-internal.h (struct inferior_object): Forward
6647 (find_thread_object, find_inferior_object): Delete declarations.
6648 (thread_to_thread_object, inferior_to_inferior_object): New
6650 * record-btrace.c: Include "inferior.h".
6651 (require_btrace_thread): Use inferior_thread.
6652 (record_btrace_frame_sniffer)
6653 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
6654 (get_thread_current_frame): Use scoped_restore_current_thread and
6656 (get_thread_current_frame): Use thread pointer directly.
6657 (record_btrace_replay_at_breakpoint): Use thread's inferior
6659 * record-full.c: Include "inferior.h".
6660 * regcache.c: Include "gdbthread.h".
6661 (get_thread_arch_regcache): Use the inferior's address space
6663 (get_thread_regcache, registers_changed_thread): New.
6664 * regcache.h (get_thread_regcache(thread_info *thread)): New
6666 (registers_changed_thread): New.
6667 (remote_target) <remote_detach_1>: Swap order of parameters.
6668 (remote_add_thread): <remote_add_thread>: Return the new thread.
6669 (get_remote_thread_info(ptid_t)): New overload.
6670 (remote_target::remote_notice_new_inferior): Use thread pointers
6672 (remote_target::process_initial_stop_replies): Use
6673 thread_info::set_running.
6674 (remote_target::remote_detach_1, remote_target::detach)
6675 (extended_remote_target::detach): Adjust.
6676 * stack.c (frame_show_address): Use inferior_thread.
6677 * target-debug.h (target_debug_print_thread_info_pp): New.
6678 * target-delegates.c: Regenerate.
6679 * target.c (default_thread_address_space): Delete.
6680 (memory_xfer_partial_1): Use current_inferior.
6681 (target_detach): Use current_inferior.
6682 (target_thread_address_space): Delete.
6683 (generic_mourn_inferior): Use current_inferior.
6684 * target.h (struct target_ops) <thread_address_space>: Delete.
6685 (target_thread_address_space): Delete.
6686 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
6688 (delete_thread_1, delete_thread, delete_thread_silent): Take a
6689 thread pointer instead of a ptid_t. Adjust all callers.
6690 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
6691 (first_thread_of_process): Delete, replaced by ...
6692 (first_thread_of_inferior): ... this new function. All callers
6694 (any_thread_of_process): Rename to ...
6695 (any_thread_of_inferior): ... this, and take an inferior pointer.
6696 (any_live_thread_of_process): Rename to ...
6697 (any_live_thread_of_inferior): ... this, and take an inferior
6699 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
6700 (value_in_thread_stack_temporaries)
6701 (get_last_thread_stack_temporary): Take a thread pointer instead
6702 of a ptid_t. Adjust all callers.
6703 (thread_info::set_running): New.
6704 (validate_registers_access): Use inferior_thread.
6705 (can_access_registers_ptid): Rename to ...
6706 (can_access_registers_thread): ... this, and take a thread
6708 (print_thread_info_1): Adjust to compare thread pointers instead
6710 (switch_to_no_thread, switch_to_thread): Make extern.
6711 (scoped_restore_current_thread::~scoped_restore_current_thread):
6712 Use m_thread pointer directly.
6713 (scoped_restore_current_thread::scoped_restore_current_thread):
6714 Use inferior_thread.
6715 (thread_command): Use thread pointer directly.
6716 (thread_num_make_value_helper): Use inferior_thread.
6717 * top.c (execute_command): Use inferior_thread.
6718 * tui/tui-interp.c: Include "inferior.h".
6719 * varobj.c (varobj_create): Use inferior_thread.
6720 (value_of_root_1): Use find_thread_global_id instead of
6721 global_thread_id_to_ptid.
6723 2018-06-21 Alan Hayward <alan.hayward@arm.com>
6725 * regcache.c (readable_regcache::read_part): Avoid memcpy when
6727 (regcache::write_part): Likewise.
6728 (readable_regcache::cooked_read_part): Update comment.
6729 (readable_regcache::cooked_write_part): Likewise.
6730 * regcache.h: (readable_regcache::read_part): Likewise.
6731 (regcache::write_part): Likewise.
6733 2018-06-21 Richard Bunt <richard.bunt@arm.com>
6734 Dirk Schubert <dirk.schubert@arm.com>
6736 * aarch64-linux-nat.c (post_attach): New.
6737 (aarch64_linux_nat_target::post_attach): Override post_attach to
6738 record the number of hardware debug registers.
6740 2018-06-20 Tom Tromey <tom@tromey.com>
6742 * python/py-param.c (add_setshow_generic): Make parameters const.
6743 (parmpy_init): Update.
6745 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
6747 * regcache.h (regcache_cooked_read_ftype): Rename to...
6748 (register_read_ftype): ...this, change type to function_view.
6749 (class reg_buffer) <save>: Remove src parameter.
6750 (readonly_detached_regcache) <readonly_detached_regcache>: Make
6751 parameter non-const in first overload. Remove src parameter in
6753 * regcache.c (do_cooked_read): Remove.
6754 (readonly_detached_regcache::readonly_detached_regcache): Make
6755 parameter non-const, adjust call to other constructor.
6756 (reg_buffer::save): Remove src parameter.
6757 * frame.c (do_frame_register_read): Remove.
6758 (frame_save_as_regcache): Use lambda function.
6759 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
6760 parameter to ppu2spu_data *.
6761 (ppu2spu_sniffer): Use lambda function.
6763 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
6765 * record-full.c (record_full_target::insert_breakpoint): Remove
6766 "struct" keyword, add const.
6768 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
6770 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
6771 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
6772 * configure.ac: Remove AC_PREREQ, add missing quoting.
6773 * gnulib/configure.ac: Modernize usage of
6774 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
6775 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
6776 (AUTOMAKE_VERSION): Bump to 1.15.1.
6777 * configure: Re-generate.
6778 * config.in: Re-generate.
6779 * aclocal.m4: Re-generate.
6780 * gnulib/aclocal.m4: Re-generate.
6781 * gnulib/config.in: Re-generate.
6782 * gnulib/configure: Re-generate.
6783 * gnulib/import/Makefile.in: Re-generate.
6785 2018-06-19 Pedro Alves <palves@redhat.com>
6787 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
6788 (lookup_minimal_symbol_by_pc_section): ... here with
6789 gdb_assert_not_reached added.
6791 2018-06-19 Pedro Alves <palves@redhat.com>
6793 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
6794 parameter with a block parameter. Compare location's block symbol
6795 with the frame's block instead of addresses.
6796 (skip_inline_frames): Pass the current block instead of the
6797 frame's address. Break out as soon as we determine the frame
6798 should not be skipped.
6800 2018-06-18 Tom Tromey <tom@tromey.com>
6802 * solib-aix.c (solib_aix_get_section_offsets): Return
6804 (solib_aix_solib_create_inferior_hook): Update.
6806 2018-06-18 Tom Tromey <tom@tromey.com>
6808 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
6810 2018-06-18 Tom Tromey <tom@tromey.com>
6812 * solib-frv.c (frv_relocate_main_executable): Use
6814 * solib-dsbt.c (dsbt_relocate_main_executable): Use
6817 2018-06-18 Tom Tromey <tom@tromey.com>
6819 * objfiles.h (inhibit_section_map_updates): Update.
6820 (resume_section_map_updates, resume_section_map_updates_cleanup):
6822 * solib-svr4.c (svr4_handle_solib_event): Update.
6823 * objfiles.c (inhibit_section_map_updates): Return
6824 scoped_restore_tmpl<int>.
6825 (resume_section_map_updates, resume_section_map_updates_cleanup):
6828 2018-06-18 Tom Tromey <tom@tromey.com>
6830 * valprint.h (read_string): Update.
6831 * valprint.c (read_string): Change type of "buffer".
6832 (val_print_string): Update.
6833 * python/py-value.c (valpy_string): Update.
6834 * language.h (struct language_defn) <la_get_string>: Change
6836 (default_get_string, c_get_string): Update.
6837 * language.c (default_get_string): Change type of "buffer".
6838 * guile/scm-value.c (gdbscm_value_to_string): Update.
6839 * c-lang.c (c_get_string): Change type of "buffer".
6841 2018-06-18 Tom Tromey <tom@tromey.com>
6843 * ser-mingw.c (struct pipe_state_destroyer): New.
6844 (pipe_state_up): New typedef.
6845 (cleanup_pipe_state): Remove.
6846 (pipe_windows_open): Use pipe_state_up. Don't release argv.
6848 2018-06-18 Tom Tromey <tom@tromey.com>
6850 * rust-lang.h (rust_yyerror): Don't declare.
6851 * rust-lang.c (rust_language_defn): Update.
6852 * rust-exp.y (yyerror): Now static.
6853 * parse.c (parse_exp_in_context_1): Update.
6854 * p-lang.h (p_yyerror): Don't declare.
6855 * p-lang.c (p_language_defn): Update.
6856 * p-exp.y (yyerror): Now static.
6857 * opencl-lang.c (opencl_language_defn): Update.
6858 * objc-lang.c (objc_language_defn): Update.
6859 * m2-lang.h (m2_yyerror): Don't declare.
6860 * m2-lang.c (m2_language_defn): Update.
6861 * m2-exp.y (yyerror): Now static.
6862 * language.h (struct language_defn) <la_error>: Remove.
6863 * language.c (unk_lang_error): Remove.
6864 (unknown_language_defn, auto_language_defn): Remove.
6865 * go-lang.h (go_yyerror): Don't declare.
6866 * go-lang.c (go_language_defn): Update.
6867 * go-exp.y (yyerror): Now static.
6868 * f-lang.h (f_yyerror): Don't declare.
6869 * f-lang.c (f_language_defn): Update.
6870 * f-exp.y (yyerror): Now static.
6871 * d-lang.h (d_yyerror): Don't declare.
6872 * d-lang.c (d_language_defn): Update.
6873 * d-exp.y (yyerror): Now static.
6874 * c-lang.h (c_yyerror): Don't declare.
6875 * c-lang.c (c_language_defn, cplus_language_defn)
6876 (asm_language_defn, minimal_language_defn): Update.
6877 * c-exp.y (yyerror): Now static.
6878 * ada-lang.h (ada_yyerror): Don't declare.
6879 * ada-lang.c (ada_language_defn): Update.
6880 * ada-exp.y (yyerror): Now static.
6882 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6884 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
6885 (store_sveregs_to_thread): Likewise.
6886 (aarch64_linux_fetch_inferior_registers): Check for SVE.
6887 (aarch64_linux_store_inferior_registers): Likewise.
6888 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
6890 (aarch64_sve_regs_copy_to_regcache): Likewise.
6891 (aarch64_sve_regs_copy_from_regcache): Likewise.
6892 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
6894 (aarch64_sve_regs_copy_to_regcache): Likewise.
6895 (aarch64_sve_regs_copy_from_regcache): Likewise.
6896 (sve_context): Structure from Linux headers.
6897 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
6898 (SVE_SIG_ZREG_SIZE): Likewise.
6899 (SVE_SIG_PREG_SIZE): Likewise.
6900 (SVE_SIG_FFR_SIZE): Likewise.
6901 (SVE_SIG_REGS_OFFSET): Likewise.
6902 (SVE_SIG_ZREGS_OFFSET): Likewise.
6903 (SVE_SIG_ZREG_OFFSET): Likewise.
6904 (SVE_SIG_ZREGS_SIZE): Likewise.
6905 (SVE_SIG_PREGS_OFFSET): Likewise.
6906 (SVE_SIG_PREG_OFFSET): Likewise.
6907 (SVE_SIG_PREGS_SIZE): Likewise.
6908 (SVE_SIG_FFR_OFFSET): Likewise.
6909 (SVE_SIG_REGS_SIZE): Likewise.
6910 (SVE_SIG_CONTEXT_SIZE): Likewise.
6911 (SVE_PT_REGS_MASK): Likewise.
6912 (SVE_PT_REGS_FPSIMD): Likewise.
6913 (SVE_PT_REGS_SVE): Likewise.
6914 (SVE_PT_VL_INHERIT): Likewise.
6915 (SVE_PT_VL_ONEXEC): Likewise.
6916 (SVE_PT_REGS_OFFSET): Likewise.
6917 (SVE_PT_FPSIMD_OFFSET): Likewise.
6918 (SVE_PT_FPSIMD_SIZE): Likewise.
6919 (SVE_PT_SVE_ZREG_SIZE): Likewise.
6920 (SVE_PT_SVE_PREG_SIZE): Likewise.
6921 (SVE_PT_SVE_FFR_SIZE): Likewise.
6922 (SVE_PT_SVE_FPSR_SIZE): Likewise.
6923 (SVE_PT_SVE_FPCR_SIZE): Likewise.
6924 (__SVE_SIG_TO_PT): Likewise.
6925 (SVE_PT_SVE_OFFSET): Likewise.
6926 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
6927 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
6928 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
6929 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
6930 (SVE_PT_SVE_PREG_OFFSET): Likewise.
6931 (SVE_PT_SVE_PREGS_SIZE): Likewise.
6932 (SVE_PT_SVE_FFR_OFFSET): Likewise.
6933 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
6934 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
6935 (SVE_PT_SVE_SIZE): Likewise.
6936 (SVE_PT_SIZE): Likewise.
6937 (HAS_SVE_STATE): New define.
6939 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6941 * nat/aarch64-sve-linux-sigcontext.h: New file.
6942 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
6944 (SVE_VQ_MIN): Likewise.
6945 (SVE_VQ_MAX): Likewise.
6946 (SVE_VL_MIN): Likewise.
6947 (SVE_VL_MAX): Likewise.
6948 (SVE_NUM_ZREGS): Likewise.
6949 (SVE_NUM_PREGS): Likewise.
6950 (sve_vl_valid): Likewise.
6951 (struct user_sve_header): Likewise.
6953 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
6954 Richard Bunt <Richard.Bunt@arm.com>
6956 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
6957 was requested by GDB.
6959 2018-06-15 Tom de Vries <tdevries@suse.de>
6961 * MAINTAINERS (Write After Approval): Add Tom de Vries.
6963 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
6965 * gnulib/update-gnulib.sh: Print expected versions of
6968 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
6970 * arch-utils.c (default_type_align): Use type_length_units.
6971 * gdbtypes.c (type_align): Use type_length_units.
6973 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6975 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
6976 of 'define' command.
6978 2018-06-14 Tom de Vries <tdevries@suse.de>
6981 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
6982 get_no_prettyformat_print_options.
6984 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
6986 * sparc-nat.h: Include target.h.
6987 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
6988 <fetch_registers>: Remove this argument in function call.
6989 <store_registers>: Remove this argument in function call, remove
6991 <low_forget_process>: Call sparc64_forget_process instead of
6992 sparc_forget_process.
6994 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6996 * procfs.c (_initialize_procfs): Use add_inf_child_target.
6997 (procfs_target::make_corefile_notes): Adjust to new
6998 target_read_alloc return type.
7000 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
7001 Stephen Roberts <stephen.roberts@arm.com>
7004 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
7005 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
7006 Move should_notify_stop local into more inner scope.
7008 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
7009 Stephen Roberts <stephen.roberts@arm.com>
7012 * infrun.c (resume_1): Add call to mark_async_event_handler.
7014 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
7016 * infrun.c (do_target_wait): Change old version of $pc printed.
7018 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
7020 * dwarf2read.c (read_index_from_section): Rename to...
7021 (read_gdb_index_from_section): ... this, update all callers.
7022 (dwarf2_read_index): Rename to...
7023 (dwarf2_read_gdb_index): ... this, update all callers.
7025 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
7027 * gdb/hppa-linux-nat.c
7028 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
7029 hppa_linux_nat_target::fetch_registers.
7031 2018-06-11 Alan Hayward <alan.hayward@arm.com>
7033 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
7034 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
7035 (AARCH64_DWARF_SVE_FFR): Likewise.
7036 (AARCH64_DWARF_SVE_P0): Likewise.
7037 (AARCH64_DWARF_SVE_Z0): Likewise.
7039 2018-06-11 Alan Hayward <alan.hayward@arm.com>
7041 * common/common-regcache.h (raw_compare): New function.
7042 * regcache.c (regcache::raw_compare): Likewise.
7043 * regcache.h (regcache::raw_compare): New declaration.
7045 2018-06-11 Alan Hayward <alan.hayward@arm.com>
7047 * common/common-regcache.h (reg_buffer_common): New structure.
7048 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
7049 (reg_buffer::raw_supply): Likewise.
7050 (reg_buffer::raw_supply_integer): Likewise.
7051 (reg_buffer::raw_supply_zeroed): Likewise.
7052 (reg_buffer::raw_collect): Likewise.
7053 (reg_buffer::raw_collect_integer): Likewise.
7054 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
7055 (reg_buffer::raw_supply): Likewise.
7056 (reg_buffer::raw_supply_integer): Likewise.
7057 (reg_buffer::raw_supply_zeroed): Likewise.
7058 (reg_buffer::raw_collect): Likewise.
7059 (reg_buffer::raw_collect_integer): Likewise.
7061 2018-06-10 Tom Tromey <tom@tromey.com>
7063 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
7064 (class remote_state) <stop_reply_queue>: Now std::vector.
7065 (remote_state::~remote_state)
7066 (remote_target::stop_reply_queue_length): Update.
7067 (struct queue_iter_param, remove_child_of_pending_fork)
7068 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
7069 (check_pending_event_prevents_wildcard_vcont_callback)
7070 (remove_stop_reply_for_inferior)
7071 (remove_stop_reply_of_remote_state)
7072 (remote_notif_remove_once_on_match)
7073 (stop_reply_match_ptid_and_ws)
7074 (remote_kill_child_of_pending_fork): Remove.
7075 (remote_target::remove_new_fork_children)
7076 (remote_target::check_pending_events_prevent_wildcard_vcont)
7077 (remote_target::discard_pending_stop_replies)
7078 (remote_target::discard_pending_stop_replies_in_queue)
7079 (remote_target::remote_notif_remove_queued_reply)
7080 (remote_target::queued_stop_reply)
7081 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
7082 (remote_target::wait, remote_target::kill_new_fork_children)
7083 (remote_target::async): Update.
7085 2018-06-10 Tom Tromey <tom@tromey.com>
7087 * record-full.c (record_full_arch_list_cleanups): Remove.
7088 (record_full_message): Use try/catch.
7089 (record_full_wait_cleanups): Remove.
7090 (record_full_wait_1): Use try/catch.
7091 (record_full_restore): Likewise.
7093 2018-06-10 Tom Tromey <tom@tromey.com>
7095 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
7096 declare VEC. Add constructor.
7097 <in_target_beneath>: Now bool.
7098 (record_full_breakpoints): Now a std::vector, static.
7099 (record_full_sync_record_breakpoints)
7100 (record_full_init_record_breakpoints)
7101 (record_full_target::insert_breakpoint)
7102 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
7104 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
7106 * dwarf2read.c (process_cu_includes): Remove struct keyword.
7107 * serial.c (serial_interface_lookup): Remove struct keyword.
7109 2018-06-10 Tom Tromey <tom@tromey.com>
7111 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
7113 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
7115 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
7117 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
7118 "beneath" as a method.
7119 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
7120 Use "beneath" as a method.
7122 2018-06-10 Tom Tromey <tom@tromey.com>
7124 * tracefile.c (struct trace_file_writer_deleter): New.
7125 <operator()>: Rename from trace_file_writer_xfree.
7126 (trace_file_writer_up): New typedef.
7127 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
7129 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
7131 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
7132 <m_registers, m_register_status>: Change type to
7134 * regcache.c (reg_buffer::reg_buffer): Use new instead of
7137 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
7139 * common/common-regcache.h (enum register_status): Add
7140 underlying type "signed char".
7141 * regcache.h (reg_buffer) <m_register_status>: Change type to
7143 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
7144 register_status instead of signed char.
7145 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
7146 (reg_buffer::get_register_status): Remove cast.
7147 (readable_regcache::raw_read): Remove cast.
7148 (readable_regcache::cooked_read): Remove cast.
7150 2018-06-09 Tom Tromey <tom@tromey.com>
7152 * source.c (reverse_search_command, forward_search_command): Use
7155 2018-06-09 Tom Tromey <tom@tromey.com>
7157 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
7158 (serial_ops_list): Now static, std::vector.
7159 (serial_interface_lookup, serial_add_interface): Update.
7161 2018-06-09 Tom Tromey <tom@tromey.com>
7163 * dwarf2read.c (process_cu_includes): Update.
7164 (process_full_comp_unit): Update.
7165 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
7168 2018-06-08 Paul Koning <paul_koning@dell.com>
7172 * python/python.c (do_start_initialization):
7173 Avoid call to internal Python API.
7174 (init__gdb_module): New function.
7176 2018-06-08 Gary Benson <gbenson@redhat.com>
7178 * linux-thread-db.c (valprint.h): New include.
7179 (struct check_thread_db_info): New structure.
7180 (check_thread_db_on_load, tdb_testinfo): New static globals.
7181 (check_thread_db, check_thread_db_callback): New functions.
7182 (try_thread_db_load_1): Run integrity checks if requested.
7183 (maintenance_check_libthread_db): New function.
7184 (_initialize_thread_db): Register "maint check libthread-db"
7185 and "maint set/show check-libthread-db".
7186 * NEWS: Mention the above new commands.
7188 2018-06-08 Tom Tromey <tom@tromey.com>
7190 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
7193 2018-06-08 Tom Tromey <tom@tromey.com>
7195 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
7197 2018-06-08 Tom Tromey <tom@tromey.com>
7199 * common/btrace-common.h (struct btrace_data): Add constructor,
7200 destructor, move assignment operator.
7201 <empty, clear, fini>: New methods.
7202 <format>: Initialize.
7203 (btrace_data_init, btrace_data_fini, btrace_data_clear)
7204 (btrace_data_empty): Don't declare.
7205 * common/btrace-common.c (btrace_data_init): Remove.
7206 (btrace_data::fini): Rename from btrace_data_fini.
7207 (btrace_data::empty): Rename from btrace_data_empty.
7208 (btrace_data::clear): Rename from btrace_data_clear. Return
7210 * btrace.h (make_cleanup_btrace_data): Don't declare.
7211 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
7212 (parse_xml_btrace): Update.
7213 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
7214 (maint_btrace_clear_packet_history_cmd): Update.
7216 2018-06-07 Pedro Alves <palves@redhat.com>
7218 * target.h (target_ops) <beneath>: Now a method. All references
7220 (class target_stack): New.
7221 * target.c (g_target_stack): New.
7222 (g_current_top_target): Delete.
7223 (current_top_target): Get the top target out of g_target_stack.
7224 (target_stack::push, target_stack::unpush): New.
7225 (push_target, unpush_target): Reimplement.
7226 (target_is_pushed): Reimplement in terms of g_target_stack.
7227 (target_ops::beneath, target_stack::find_beneath): New.
7229 2018-06-07 Pedro Alves <palves@redhat.com>
7231 * target.h (find_target_beneath): Delete declaration.
7232 * target.c (find_target_beneath): Delete definition.
7233 * aix-thread.c: All callers of find_target_beneath adjusted to
7234 call target_ops::beneath instead.
7235 * bsd-uthread.c: Likewise.
7236 * linux-thread-db.c: Likewise.
7237 * ravenscar-thread.c: Likewise.
7238 * sol-thread.c: Likewise.
7239 * spu-multiarch.c: Likewise.
7241 2018-06-07 Pedro Alves <palves@redhat.com>
7243 * target.h (target_ops) <beneath>: Now a method. All references
7245 (target_ops) <m_beneath>: New.
7246 * target.c (target_ops::beneath): New.
7247 * corelow.c: Adjust all references to target_ops::beneath.
7248 * linux-thread-db.c: Likewise.
7249 * make-target-delegates: Likewise.
7250 * record-btrace.c: Likewise.
7251 * record-full.c: Likewise.
7252 * remote.c: Likewise.
7253 * target.c: Likewise.
7254 * target-delegates.c: Regenerate.
7256 2018-06-07 Pedro Alves <palves@redhat.com>
7258 * target.h (target_stack): Delete.
7259 (current_top_target): Declare function.
7260 * target.c (target_stack): Delete.
7261 (g_current_top_target): New.
7262 (current_top_target): New function.
7263 * auxv.c: Use current_top_target instead of target_stack
7265 * avr-tdep.c: Likewise.
7266 * breakpoint.c: Likewise.
7267 * corefile.c: Likewise.
7268 * elfread.c: Likewise.
7270 * exceptions.c: Likewise.
7271 * frame.c: Likewise.
7272 * gdbarch-selftests.c: Likewise.
7273 * gnu-v3-abi.c: Likewise.
7274 * ia64-tdep.c: Likewise.
7275 * ia64-vms-tdep.c: Likewise.
7276 * infcall.c: Likewise.
7277 * infcmd.c: Likewise.
7278 * infrun.c: Likewise.
7279 * linespec.c: Likewise.
7280 * linux-tdep.c: Likewise.
7281 * minsyms.c: Likewise.
7282 * ppc-linux-nat.c: Likewise.
7283 * ppc-linux-tdep.c: Likewise.
7284 * procfs.c: Likewise.
7285 * regcache.c: Likewise.
7286 * remote.c: Likewise.
7287 * rs6000-tdep.c: Likewise.
7288 * s390-linux-nat.c: Likewise.
7289 * s390-tdep.c: Likewise.
7290 * solib-aix.c: Likewise.
7291 * solib-darwin.c: Likewise.
7292 * solib-dsbt.c: Likewise.
7293 * solib-spu.c: Likewise.
7294 * solib-svr4.c: Likewise.
7295 * solib-target.c: Likewise.
7296 * sparc-tdep.c: Likewise.
7297 * sparc64-tdep.c: Likewise.
7298 * spu-tdep.c: Likewise.
7299 * symfile.c: Likewise.
7300 * symtab.c: Likewise.
7301 * target-descriptions.c: Likewise.
7302 * target-memory.c: Likewise.
7303 * target.c: Likewise.
7304 * target.h: Likewise.
7305 * tracefile-tfile.c: Likewise.
7306 * tracepoint.c: Likewise.
7307 * valops.c: Likewise.
7308 * valprint.c: Likewise.
7309 * value.c: Likewise.
7310 * windows-tdep.c: Likewise.
7311 * mi/mi-main.c: Likewise.
7313 2018-06-07 Tom Tromey <tom@tromey.com>
7315 * valprint.h (build_address_symbolic): Declare.
7316 * printcmd.c (print_address_symbolic): Update.
7317 (build_address_symbolic): Change "name" and "filename" to
7319 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
7321 * defs.h (build_address_symbolic): Remove declaration.
7323 2018-06-07 Alan Hayward <alan.hayward@arm.com>
7325 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
7326 (aarch64_vnv_type): Add function.
7327 (aarch64_pseudo_register_name): Add V regs for SVE.
7328 (aarch64_pseudo_register_type): Likewise.
7329 (aarch64_pseudo_register_reggroup_p): Likewise.
7330 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
7331 (aarch64_pseudo_read_value): Add V regs for SVE.
7332 (aarch64_pseudo_write_2): Use V0 offset for SVE
7333 (aarch64_pseudo_write): Add V regs for SVE.
7334 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
7336 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
7338 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
7339 (sve_vl_from_vq): Likewise.
7341 2018-06-05 Tom Tromey <tom@tromey.com>
7343 * cli/cli-cmds.c (show_version): Update.
7344 * top.c (print_gdb_version): Add "interactive" parameter.
7346 * main.c (captured_main_1): Update.
7347 * top.h (print_gdb_version): Add "interactive" parameter and a
7350 2018-06-05 David Malcolm <dmalcolm@redhat.com>
7352 * common/enum-flags.h: Add trailing semicolon to example in
7355 2018-06-05 Tom Tromey <tom@tromey.com>
7358 * NEWS: Add entry about pager.
7359 * utils.c (pagination_disabled_for_command): New global.
7360 (prompt_for_continue): Allow "c" response to prompt.
7361 (reinitialize_more_filter): Clear
7362 pagination_disabled_for_command.
7363 (fputs_maybe_filtered): Check pagination_disabled_for_command.
7365 2018-06-04 Tom Tromey <tom@tromey.com>
7367 * ada-lang.h (ada_lookup_symbol_list): Update.
7368 * ada-lang.c (resolve_subexp): Update.
7369 (symbols_are_identical_enums): Change type of syms. Remove nsyms
7371 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
7372 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
7373 results parameter to std::vector.
7374 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
7376 * ada-exp.y (block_lookup): Update.
7377 (select_possible_type_sym): Change type of syms. Remove nsyms
7379 (write_var_or_type, write_name_assoc): Update.
7381 2018-06-04 Joel Brobecker <brobecker@adacore.com>
7383 * windows-nat.c (windows_nat_target::xfer_partial): Return
7384 TARGET_XFER_E_IO if we need to delegate to the target beneath
7385 but BENEATH is NULL.
7387 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
7389 * Makefile.in (config.status): Add configure.nat as a
7392 2018-06-04 Tom Tromey <tom@tromey.com>
7394 * cp-name-parser.y (cpname_state): Add method declarations.
7395 (HANDLE_QUAL): Update.
7396 (cpname_state::d_grab, cpname_state::fill_comp)
7397 (cpname_state::make_operator, cpname_state::make_dtor)
7398 (cpname_state::make_builtin_type, cpname_state::make_name)
7399 (cpname_state::d_qualify, cpname_state::d_int_type)
7400 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
7401 (%union): Move earlier.
7403 2018-06-04 Alan Hayward <alan.hayward@arm.com>
7405 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
7407 2018-06-04 Alan Hayward <alan.hayward@arm.com>
7409 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
7410 (aarch64_pseudo_write_1): Likewise.
7411 (aarch64_pseudo_read_value): Use helper.
7412 (aarch64_pseudo_write): Likewise.
7414 2018-06-04 Pedro Alves <palves@redhat.com>
7416 * darwin-nat.c (darwin_ops): Delete.
7417 (darwin_attach_pid): Use get_native_target.
7419 2018-06-04 Alan Hayward <alan.hayward@arm.com>
7421 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
7422 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
7424 2018-06-04 Alan Hayward <alan.hayward@arm.com>
7426 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
7427 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
7428 (aarch64_gdbarch_init): Check for SVE.
7429 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
7431 2018-06-04 Alan Hayward <alan.hayward@arm.com>
7433 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
7434 * aarch64-tdep.h (aarch64_read_description): Likewise.
7435 * arch/aarch64.c (aarch64_create_target_description): Likewise.
7436 * arch/aarch64.h (aarch64_create_target_description): Likewise.
7437 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
7438 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
7439 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
7441 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
7443 * value.c (value_fetch_lazy_bitfield): New.
7444 (value_fetch_lazy_memory): New.
7445 (value_fetch_lazy_register): New.
7446 (value_fetch_lazy): Factor out to smaller functions.
7448 2018-06-01 Tom Tromey <tom@tromey.com>
7450 * cp-name-parser.y (backslashable, represented): Now const.
7452 2018-06-01 Tom Tromey <tom@tromey.com>
7454 * cp-name-parser.y: Include parser-defs.h.
7455 (parser_fprintf): Remove declaration.
7457 2018-06-01 Tom Tromey <tom@tromey.com>
7459 * cp-name-parser.y: Use %pure-parser, %lex-param, and
7461 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
7462 (global_result): Remove globals.
7463 (struct cpname_state): New.
7464 (yyparse): Don't declare.
7465 (yylex, yyerror): Move declarations after %union.
7466 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
7467 (make_name): Add state parameter.
7469 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
7471 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
7473 (yylex): Add lvalp, state parameters.
7474 (yyerror): Add state parameter.
7475 (cp_demangled_name_to_comp): Update.
7477 2018-06-01 Tom Tromey <tom@tromey.com>
7479 * cp-name-parser.y (parser_fprintf): Declare.
7480 (GDB_YY_REMAP_PREFIX): Define.
7481 Include yy-remap.h. Don't redefine yy* identifiers.
7483 2018-06-01 Tom Tromey <tom@tromey.com>
7485 * python/py-type.c (typy_legacy_template_argument): Update.
7486 * cp-support.h (cp_demangled_name_to_comp): Update.
7487 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
7488 parameter to be a "std::string *".
7491 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
7493 * ada-lex.l: Include "diagnostics.h" instead of
7494 "common/diagnostics.h".
7495 * unittests/environ-selftests.c: Likewise.
7496 * common/diagnostics.h: Moved to ../include.
7498 2018-06-01 Joel Brobecker <brobecker@adacore.com>
7500 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
7501 to language_mode_manual while calling breakpoint_re_set_one.
7503 2018-06-01 Tom Tromey <tom@tromey.com>
7505 * valops.c (value_cast_structs, destructor_name_p): Update.
7506 * symtab.c (gdb_mangle_name): Update.
7507 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
7509 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
7510 (pascal_object_print_value_fields, pascal_object_print_value):
7512 * p-typeprint.c (pascal_type_print_derivation_info): Update.
7513 * linespec.c (find_methods): Update.
7514 * gdbtypes.h (type_name_no_tag): Remove.
7515 (type_name_or_error): Rename from type_name_no_tag_or_error.
7516 * gdbtypes.c (type_name_no_tag): Remove.
7517 (type_name_or_error): Rename from type_name_no_tag_or_error.
7518 (lookup_struct_elt_type, check_typedef): Update.
7519 * expprint.c (print_subexp_standard): Update.
7520 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
7521 * d-namespace.c (d_lookup_nested_symbol): Update.
7522 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
7523 (cp_print_class_member): Update.
7524 * cp-namespace.c (cp_lookup_nested_symbol): Update.
7525 * completer.c (add_struct_fields): Update.
7526 * c-typeprint.c (cp_type_print_derivation_info)
7527 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
7529 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
7530 (ada_prefer_type, ada_is_exception_sym): Update.
7532 2018-06-01 Tom Tromey <tom@tromey.com>
7534 * valops.c (enum_constant_from_type, value_namespace_elt)
7535 (value_maybe_namespace_elt): Update.
7536 * valarith.c (find_size_for_pointer_math): Update.
7537 * target-descriptions.c (make_gdb_type): Update.
7538 * symmisc.c (print_symbol): Update.
7539 * stabsread.c (define_symbol, read_type)
7540 (complain_about_struct_wipeout, add_undefined_type)
7541 (cleanup_undefined_types_1): Update.
7542 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
7543 (rust_range_type_p, val_print_struct, rust_print_struct_def)
7544 (rust_internal_print_type, rust_composite_type)
7545 (rust_evaluate_funcall, rust_evaluate_subexp)
7546 (rust_inclusive_range_type_p): Update.
7547 * python/py-type.c (typy_get_tag): Update.
7548 * p-typeprint.c (pascal_type_print_base): Update.
7549 * mdebugread.c (parse_symbol, parse_type): Update.
7550 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
7552 * guile/scm-type.c (gdbscm_type_tag): Update.
7553 * go-lang.c (sixg_string_p): Update.
7554 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
7556 * gdbtypes.h (struct main_type) <tag_name>: Remove.
7557 (TYPE_TAG_NAME): Remove.
7558 * gdbtypes.c (type_name_no_tag): Simplify.
7559 (check_typedef, check_types_equal, recursive_dump_type)
7560 (copy_type_recursive, arch_composite_type): Update.
7561 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
7562 in summary mode when needed.
7563 * eval.c (evaluate_funcall): Update.
7564 * dwarf2read.c (fixup_go_packaging, read_structure_type)
7565 (process_structure_scope, read_enumeration_type)
7566 (read_namespace_type, read_module_type, determine_prefix): Update.
7567 * cp-support.c (inspect_type): Update.
7568 * coffread.c (process_coff_symbol, decode_base_type): Update.
7569 * c-varobj.c (c_is_path_expr_parent): Update.
7570 * c-typeprint.c (c_type_print_base_struct_union): Update.
7571 (c_type_print_base_1): Update. Print struct/class/union/enum in
7572 summary when using C language.
7573 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
7574 (gen_maybe_namespace_elt): Update.
7575 * ada-lang.c (ada_type_name): Simplify.
7576 (empty_record, ada_template_to_fixed_record_type_1)
7577 (template_to_static_fixed_type)
7578 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
7580 2018-06-01 Tom Tromey <tom@tromey.com>
7582 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
7584 * c-typeprint.c (c_print_type_1): Add "language" parameter.
7585 (c_print_type): Update.
7586 (c_print_type): New overload.
7587 (c_type_print_varspec_prefix, c_type_print_args)
7588 (c_type_print_varspec_suffix, c_print_type_no_offsets)
7589 (c_type_print_base_struct_union, c_type_print_base_1)
7590 (cp_type_print_method_args): Add "language" parameter.
7591 (c_type_print_base): Update.
7592 * c-lang.h (c_print_type): Add new overload.
7594 2018-06-01 Tom Tromey <tom@tromey.com>
7596 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
7597 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
7599 2018-06-01 Alan Hayward <alan.hayward@arm.com>
7601 * aarch64-tdep.c (aarch64_sve_register_names): New const
7603 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
7604 (AARCH64_SVE_Z_REGS_NUM): New define.
7605 (AARCH64_SVE_P_REGS_NUM): Likewise.
7606 (AARCH64_SVE_NUM_REGS): Likewise.
7608 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
7610 * nat/linux-ptrace.h [__alpha__]
7611 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
7614 2018-05-31 Maciej W. Rozycki <macro@mips.com>
7616 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
7617 the endianness selected.
7618 * NEWS: Document `set endian auto' mode operation update.
7620 2018-05-31 Alan Hayward <alan.hayward@arm.com>
7622 * Makefile.in: Add new header.
7623 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
7624 (sve_vl_from_vg): Likewise.
7625 (sve_vq_from_vl): Likewise.
7626 (sve_vl_from_vq): Likewise.
7627 (sve_vq_from_vg): Likewise.
7628 (sve_vg_from_vq): Likewise.
7629 * configure.nat: Add new c file.
7630 * nat/aarch64-sve-linux-ptrace.c: New file.
7631 * nat/aarch64-sve-linux-ptrace.h: New file.
7633 2018-05-31 Alan Hayward <alan.hayward@arm.com>
7635 * aarch64-linux-nat.c (aarch64_linux_read_description):
7637 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
7639 * aarch64-tdep.c (tdesc_aarch64_list): Add.
7640 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
7641 (aarch64_gdbarch_init): Add parmeter zero.
7642 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
7643 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
7644 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
7646 * doc/gdb.texinfo: Describe SVE feature
7647 * features/aarch64-sve.c: New file.
7649 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
7652 * gdbarch.sh (significant_addr_bit): Default to zero when
7653 not set by target architecture.
7654 * gdbarch.c: Re-generated.
7655 * utils.c (address_significant): Update.
7657 2018-05-30 Joel Brobecker <brobecker@adacore.com>
7659 * stack.c (func_command): Remove trailing newline in call to error.
7661 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7663 * regcache.h (regcache_raw_collect): Remove, update callers to
7664 use regcache::raw_collect.
7665 * regcache.c (regcache_raw_collect): Remove.
7667 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7669 * regcache.h (regcache_raw_supply): Remove, update callers to
7670 use detached_regcache::raw_supply.
7671 * regcache.c (regcache_raw_supply): Remove.
7673 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7675 * regcache.h (regcache_cooked_write_part): Remove, update
7676 callers to use regcache::cooked_write_part.
7677 * regcache.c (regcache_cooked_write_part): Remove.
7679 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7681 * regcache.h (regcache_cooked_read_part): Remove, update callers
7682 to use readable_regcache::cooked_read_part.
7683 * regcache.c (regcache_cooked_read_part): Remove.
7685 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7687 * regcache.h (regcache_cooked_read_value): Remove, update
7688 callers to use readable_regcache::cooked_read_value.
7689 * regcache.c (regcache_cooked_read_value): Remove.
7691 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7693 * regcache.h (regcache_cooked_write): Remove, update callers to
7694 use regcache::cooked_write.
7695 * regcache.c (regcache_cooked_write): Remove.
7697 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7699 * regcache.h (regcache_invalidate): Remove, update callers to
7700 use detached_regcache::invalidate instead.
7701 * regcache.c (regcache_invalidate): Remove.
7703 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7705 * regcache.h (regcache_raw_write_part): Remove, update callers
7706 to use regcache::raw_write_part instead.
7707 * regcache.c (regcache_raw_write_part): Remove.
7709 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7711 * regcache.h (regcache_raw_read_part): Remove, update callers to
7712 use readable_regcache::raw_read_part instead.
7713 * regcache.c (regcache_raw_read_part): Remove.
7715 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7717 * regcache.h (regcache_cooked_read): Remove, update callers to
7718 use readable_regcache::cooked_read instead.
7719 * regcache.c (regcache_cooked_read): Remove.
7721 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7723 * regcache.h (regcache_raw_write): Remove, update callers to use
7724 regcache::raw_write instead.
7725 * regcache.c (regcache_raw_write): Remove.
7727 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7729 * regcache.h (regcache_raw_read): Remove, update callers to use
7730 readable_regcache::raw_read instead.
7731 * regcache.c (regcache_raw_read): Remove.
7733 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7735 * regcache.h (regcache_raw_update): Remove, update callers to
7736 use readable_regcache::raw_update instead.
7737 * regcache.c (regcache_raw_update): Remove.
7739 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7741 * regcache.h (regcache_register_status): Remove, update callers
7742 to use reg_buffer::get_register_status directly instead.
7743 * regcache.c (regcache_register_status): Remove.
7745 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7747 * regcache.h (regcache_get_ptid): Remove, update all callers to
7748 call regcache::ptid instead.
7749 * regcache.c (regcache_get_ptid): Remove.
7751 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7753 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
7755 2018-05-30 Pedro Alves <palves@redhat.com>
7757 * common/common-exceptions.h (exception_rethrow): Use
7760 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
7762 * breakpoint.c (print_solib_event, check_status_catch_solib):
7763 Remove struct keyword in range-based for loops.
7764 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
7765 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
7767 * linespec.c (find_superclass_methods, search_minsyms_for_name):
7769 * symfile.c (addr_info_make_relative): Likewise.
7770 * thread.c (value_in_thread_stack_temporaries): Likewise.
7772 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
7775 * valops.c (value_struct_elt_for_reference): Call check_typedef on
7776 aggregate type to get its real type before accessing it.
7778 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
7780 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
7781 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
7782 * coff-pe-read.c (add_pe_forwarded_sym): Replace
7783 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
7784 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
7785 * jit.c (jit_breakpoint_re_set_internal): Likewise.
7786 * printcmd.c (info_address_command): Likewise.
7788 2018-05-29 Tom Tromey <tom@tromey.com>
7790 * windows-nat.c (handle_exception): Update fall-through comment.
7792 2018-05-29 Tom Tromey <tom@tromey.com>
7794 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
7795 (struct program_space) <added_solibs>: Now a std::vector.
7796 * breakpoint.c (print_solib_event): Update.
7797 (check_status_catch_solib): Update.
7798 * progspace.c (clear_program_space_solib_cache): Update.
7799 * solib.c (update_solib_list): Update.
7801 2018-05-29 Tom Tromey <tom@tromey.com>
7803 * python/py-type.c (typy_richcompare): Update.
7804 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
7805 * gdbtypes.h (types_deeply_equal): Return bool.
7806 (types_equal): Likewise.
7807 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
7809 (check_types_equal): Change worklist to std::vector. Return
7811 (struct type_equality_entry): Add constructor.
7812 (compare_maybe_null_strings): Return bool.
7813 (check_types_worklist): Return bool. Change worklist to
7815 (types_deeply_equal): Use std::vector.
7816 (types_equal): Return bool.
7817 (compare_maybe_null_strings): Simplify.
7819 2018-05-29 Tom Tromey <tom@tromey.com>
7821 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
7823 2018-05-29 Tom Tromey <tom@tromey.com>
7825 * objc-lang.h: Don't include cp-support.h.
7826 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
7829 2018-05-27 Tom Tromey <tom@tromey.com>
7831 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
7833 2018-05-25 Tom Tromey <tom@tromey.com>
7835 * value.c (value::location): Initialize.
7837 2018-05-25 Tom Tromey <tom@tromey.com>
7839 * dbxread.c (init_bincl_list): Remove.
7840 (bincl_list): Now a std::vector.
7841 (bincls_allocated, next_bincl): Remove.
7842 (free_bincl_list, do_free_bincl_list_cleanup)
7843 (make_cleanup_free_bincl_list): Remove.
7844 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
7846 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
7847 (struct header_file_location): Add constructor.
7848 (add_bincl_to_list): Remove.
7850 2018-05-25 Tom Tromey <tom@tromey.com>
7852 * tui/tui.c (tui_enable): Update.
7853 * mi/mi-interp.c (mi_interp::init): Update.
7854 * interps.h (class interp) <name>: New method.
7855 <m_name>: Rename from name.
7856 (~scoped_restore_interp): Update.
7857 * interps.c (interp::interp): Update.
7858 (interp_add, interp_set, interp_lookup_existing)
7859 (current_interp_named_p): Update.
7861 2018-05-25 Tom Tromey <tom@tromey.com>
7863 * interps.c (interp_name): Remove.
7864 * mi/mi-interp.c (mi_interp::init): Update.
7865 * interps.h (interp_name): Remove.
7866 (~scoped_restore_interp): Update.
7867 * tui/tui.c (tui_enable): Update.
7869 2018-05-25 Tom Tromey <tom@tromey.com>
7871 * utils.c (fputs_maybe_filtered): Update.
7872 * linespec.c (decode_line_full): Update.
7873 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
7874 (mi_print_breakpoint_for_event, mi_solib_loaded)
7875 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7876 (mi_user_selected_context_changed): Update.
7877 * mi/mi-main.c (mi_execute_command): Update.
7878 * cli/cli-script.c (execute_control_command): Update.
7879 * python/python.c (execute_gdb_command): Update.
7880 * solib.c (info_sharedlibrary_command): Update.
7881 * interps.c (interp_ui_out): Remove.
7882 * interps.h (interp_ui_out): Remove.
7884 2018-05-25 Tom Tromey <tom@tromey.com>
7886 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
7887 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
7888 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
7890 2018-05-25 Tom Tromey <tom@tromey.com>
7892 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
7893 * interps.c (interp_exec): Use scoped_restore.
7895 2018-05-25 Tom Tromey <tom@tromey.com>
7897 * remote.c (remote_target::remote_file_get): Use
7899 (remote_target::remote_file_put): Likewise.
7901 2018-05-25 Tom Tromey <tom@tromey.com>
7903 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
7905 (get_pe_section_index, add_pe_exported_sym): Update.
7906 (read_pe_exported_syms): Use gdb::def_vector.
7908 2018-05-25 Tom Tromey <tom@tromey.com>
7910 * frame.c (remove_prev_frame): Remove.
7911 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
7913 2018-05-25 Maciej W. Rozycki <macro@mips.com>
7915 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
7917 * mips-linux-nat.c (supply_fpregset): Always call
7918 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
7919 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
7920 `mips_fill_fpregset'.
7921 * mips-linux-tdep.c (mips_supply_fpregset)
7922 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
7923 (mips_fill_fpregset_wrapper): Remove functions.
7924 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
7925 (mips_linux_fpregset): Remove variable.
7926 (mips_linux_iterate_over_regset_sections): Use
7927 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
7928 (mips_linux_o32_sigframe_init): Remove comment.
7930 2018-05-25 Pedro Alves <palves@redhat.com>
7932 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
7933 (struct readahead_cache, struct packet_reg, struct
7934 remote_arch_state, class remote_state): Move higher up in the
7936 (remote_target::m_remote_state): Now an object instead of a pointer.
7937 (remote_target::get_remote_state): Adjust.
7939 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7941 * stack.c (select_and_print_frame): Delete.
7942 (struct function_bounds): Move struct within function.
7943 (func_command): Most content moved into new function
7944 find_frame_for_function, use new function, print result, add
7946 (find_frame_for_function): New function, now returns a result.
7948 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7950 * stack.c (iterate_over_block_arg_vars): Fix comment.
7951 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
7953 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7957 (scoped_restore_selected_frame::scoped_restore_selected_frame):
7959 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
7961 * frame.h (class scoped_restore_selected_frame): New class.
7962 * stack.c (print_frame_local_vars): Remove catching and rethrowing
7963 of any exception, use scoped_restore_selected_frame to restore the
7966 2018-05-24 Pedro Alves <palves@redhat.com>
7968 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
7971 2018-05-23 Tom Tromey <tom@tromey.com>
7973 * complaints.c (struct complaints): Remove.
7974 (symfile_complaint_book): Remove.
7975 (series): New global.
7976 (complaint_internal): Update.
7977 (clear_complaints): Update.
7979 2018-05-23 Tom Tromey <tom@tromey.com>
7981 * complaints.c (counters): New global.
7982 (struct complain): Remove.
7983 (struct complaints) <root>: Remove.
7984 (complaint_sentinel): Remove.
7985 (symfile_complaint_book): Update.
7986 (find_complaint) Remove.
7987 (complaint_internal, clear_complaints): Update.
7989 2018-05-23 Tom Tromey <tom@tromey.com>
7991 * complaints.c (struct complain) <file, line>: Remove.
7992 (find_complaint): Remove file, line parameters.
7993 (complaint_internal): Update.
7995 2018-05-23 Tom Tromey <tom@tromey.com>
7997 * complaints.c (vcomplaint): Remove.
7998 (complaint_internal) Merge in contents of vcomplaint.
8000 2018-05-23 Tom Tromey <tom@tromey.com>
8002 * complaints.c (struct complaints) <explanation>: Remove.
8003 (symfile_explanations): Remove.
8004 (symfile_complaint_book): Update.
8005 (vcomplaint): Update.
8006 (struct explanation): Remove.
8008 2018-05-23 Tom Tromey <tom@tromey.com>
8010 * complaints.c (symfile_complaints): Remove.
8011 (complaint_internal): Remove "complaints" parameter.
8012 (clear_complaints, vcomplaint): Remove "c" parameter.
8013 (get_complaints): Remove.
8014 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
8015 (dwarf2_debug_line_missing_file_complaint)
8016 (dwarf2_debug_line_missing_end_sequence_complaint)
8017 (dwarf2_complex_location_expr_complaint)
8018 (dwarf2_const_value_length_mismatch_complaint)
8019 (dwarf2_section_buffer_overflow_complaint)
8020 (dwarf2_macro_malformed_definition_complaint)
8021 (dwarf2_invalid_attrib_class_complaint)
8022 (create_addrmap_from_index, dw2_symtab_iter_next)
8023 (dw2_expand_marked_cus)
8024 (dw2_debug_names_iterator::find_vec_in_debug_names)
8025 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
8026 (create_debug_type_hash_table, init_cutu_and_read_dies)
8027 (partial_die_parent_scope, add_partial_enumeration)
8028 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
8029 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
8030 (read_import_statement, read_file_scope, create_dwo_cu_reader)
8031 (create_cus_hash_table, create_dwp_hash_table)
8032 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
8033 (dwarf2_rnglists_process, dwarf2_ranges_process)
8034 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
8035 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
8036 (handle_struct_member_die, process_structure_scope)
8037 (read_array_type, read_common_block, read_module_type)
8038 (read_tag_pointer_type, read_typedef, read_base_type)
8039 (read_subrange_type, load_partial_dies, partial_die_info::read)
8040 (partial_die_info::read, partial_die_info::read)
8041 (partial_die_info::read, read_checked_initial_length_and_offset)
8042 (dwarf2_string_attr, read_formatted_entries)
8043 (dwarf_decode_line_header)
8044 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
8045 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
8046 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
8047 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8048 (get_signatured_type, get_DW_AT_signature_type)
8049 (decode_locdesc, file_file_name, consume_improper_spaces)
8050 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
8051 (dwarf_decode_macro_bytes, dwarf_decode_macros)
8052 (dwarf2_symbol_mark_computed, set_die_type)
8053 (read_attribute_value): Update.
8054 * stap-probe.c (handle_stap_probe, get_stap_base_address):
8056 * dbxread.c (unknown_symtype_complaint)
8057 (lbrac_mismatch_complaint, repeated_header_complaint)
8058 (set_namestring, function_outside_compilation_unit_complaint)
8059 (read_dbx_symtab, process_one_symbol): Update.
8060 * gdbtypes.c (stub_noname_complaint): Update.
8061 * windows-nat.c (handle_unload_dll): Update.
8062 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
8063 (decode_base_type): Update.
8064 * xcoffread.c (bf_notfound_complaint, ef_complaint)
8065 (eb_complaint, record_include_begin, record_include_end)
8066 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
8067 (process_xcoff_symbol, read_symbol)
8068 (function_outside_compilation_unit_complaint)
8069 (scan_xcoff_symtab): Update.
8070 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
8071 * buildsym.c (finish_block_internal, make_blockvector)
8072 (end_symtab_get_static_block, augment_type_symtab): Update.
8073 * dtrace-probe.c (dtrace_process_dof)
8074 (dtrace_static_probe_ops::get_probes): Update.
8075 * complaints.h (struct complaint): Don't declare.
8076 (symfile_complaints): Remove.
8077 (complaint_internal): Remove "complaints" parameter.
8078 (complaint): Likewise.
8079 (clear_complaints): Likewise.
8080 * symfile.c (syms_from_objfile_1, finish_new_objfile)
8081 (reread_symbols): Update.
8082 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
8083 (dwarf2_frame_cache, decode_frame_entry): Update.
8084 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
8085 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8086 (info_selectors_command): Update.
8087 * macrotab.c (macro_include, check_for_redefinition)
8088 (macro_undef): Update.
8089 * objfiles.c (filter_overlapping_sections): Update.
8090 * stabsread.c (invalid_cpp_abbrev_complaint)
8091 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
8092 (define_symbol, error_type, read_type, rs6000_builtin_type)
8093 (stabs_method_name_from_physname, read_member_functions)
8094 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
8095 (attach_fields_to_type, complain_about_struct_wipeout)
8096 (read_range_type, read_args, common_block_start)
8097 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
8099 * mdebugread.c (index_complaint, unknown_ext_complaint)
8100 (basic_type_complaint, bad_tag_guess_complaint)
8101 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
8102 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
8103 (parse_procedure, parse_lines)
8104 (function_outside_compilation_unit_complaint)
8105 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
8106 (bad_tag_guess_complaint, reg_value_complaint): Update.
8107 * cp-support.c (demangled_name_complaint): Update.
8108 * macroscope.c (sal_macro_scope): Update.
8109 * dwarf-index-write.c (class debug_names): Update.
8111 2018-05-23 Tom Tromey <tom@tromey.com>
8113 * complaints.c (clear_complaints): Remove "noisy" parameter.
8114 * complaints.h (clear_complaints): Update.
8115 * symfile.c (syms_from_objfile_1, finish_new_objfile)
8116 (reread_symbols): Update.
8118 2018-05-23 Tom Tromey <tom@tromey.com>
8120 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
8122 (vcomplaint, clear_complaints): Update.
8123 (symfile_explanations): Remove some messages.
8125 2018-05-23 Tom Tromey <tom@tromey.com>
8127 * complaints.c (internal_complaint): Remove.
8128 * complaints.h (internal_complaint): Remove.
8130 2018-05-22 Maciej W. Rozycki <macro@mips.com>
8132 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
8134 2018-05-22 Pedro Alves <palves@redhat.com>
8136 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
8137 (remote_fileio_badfd, remote_fileio_return_errno)
8138 (remote_fileio_return_success, remote_fileio_func_open)
8139 (remote_fileio_func_open, remote_fileio_func_close)
8140 (remote_fileio_func_read, remote_fileio_func_write)
8141 (remote_fileio_func_lseek, remote_fileio_func_rename)
8142 (remote_fileio_func_unlink, remote_fileio_func_stat)
8143 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
8144 (remote_fileio_func_isatty, remote_fileio_func_system): Add
8145 remote_target parameter.
8146 (remote_fio_func_map) <func>: Add remote_target parameter.
8147 (do_remote_fileio_request, remote_fileio_request):
8148 * remote-fileio.h (remote_fileio_request):
8149 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
8150 remote_target parameter.
8151 (remote_notif_process, handle_notification): Adjust to pass down
8153 (remote_notif_state_allocate): Add remote_target parameter. Save
8155 * remote-notif.h (struct remote_target): Forward declare.
8156 (struct notif_client) <parse, ack, can_get_pending_events>: Add
8157 remote_target parameter.
8158 (struct remote_notif_state) <remote>: New field.
8159 (remote_notif_ack, remote_notif_parse): Add remote_target
8161 (remote_notif_state_allocate, remote_notif_state_allocate): Add
8162 remote_target parameter.
8163 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
8164 (threads_listing_context, rmt_thread_action, protocol_feature)
8165 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
8166 (packet_result, struct threads_listing_context, remote_state):
8167 Move definitions and declarations higher up.
8168 (remote_target) <~remote_target>: Declare.
8169 (remote_download_command_source, remote_file_put, remote_file_get)
8170 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
8171 (remote_hostio_pread_vFile, remote_hostio_send_command)
8172 (remote_hostio_set_filesystem, remote_hostio_open)
8173 (remote_hostio_close, remote_hostio_unlink, remote_state)
8174 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
8175 (get_memory_write_packet_size, get_memory_read_packet_size)
8176 (append_pending_thread_resumptions, remote_detach_1)
8177 (append_resumption, remote_resume_with_vcont)
8178 (add_current_inferior_and_thread, wait_ns, wait_as)
8179 (process_stop_reply, remote_notice_new_inferior)
8180 (process_initial_stop_replies, remote_add_thread)
8181 (btrace_sync_conf, remote_btrace_maybe_reopen)
8182 (remove_new_fork_children, kill_new_fork_children)
8183 (discard_pending_stop_replies, stop_reply_queue_length)
8184 (check_pending_events_prevent_wildcard_vcont)
8185 (discard_pending_stop_replies_in_queue, stop_reply)
8186 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
8187 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
8188 (remote_interrupt_as, remote_interrupt_ns)
8189 (remote_get_noisy_reply, remote_query_attached)
8190 (remote_add_inferior, remote_current_thread, get_current_thread)
8191 (set_thread, set_general_thread, set_continue_thread)
8192 (set_general_process, write_ptid)
8193 (remote_unpack_thread_info_response, remote_get_threadinfo)
8194 (parse_threadlist_response, remote_get_threadlist)
8195 (remote_threadlist_iterator, remote_get_threads_with_ql)
8196 (remote_get_threads_with_qxfer)
8197 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
8198 (get_offsets, remote_check_symbols, remote_supported_packet)
8199 (remote_query_supported, remote_packet_size)
8200 (remote_serial_quit_handler, remote_detach_pid)
8201 (remote_vcont_probe, remote_resume_with_hc)
8202 (send_interrupt_sequence, interrupt_query)
8203 (remote_notif_get_pending_events, fetch_register_using_p)
8204 (send_g_packet, process_g_packet, fetch_registers_using_g)
8205 (store_register_using_P, store_registers_using_G)
8206 (set_remote_traceframe, check_binary_download)
8207 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
8208 (remote_xfer_live_readonly_partial, remote_read_bytes)
8209 (remote_send_printf, remote_flash_write, readchar)
8210 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
8211 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
8212 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
8213 (extended_remote_disable_randomization, extended_remote_run)
8214 (send_environment_packet, extended_remote_environment_support)
8215 (extended_remote_set_inferior_cwd, remote_write_qxfer)
8216 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
8217 (packet_command): Now methods of ...
8218 (remote_target): ... this class.
8219 (m_remote_state) <remote_target>: New field.
8220 (struct remote_state) <stop_reply_queue,
8221 remote_async_inferior_event_token, wait_forever_enabled_p>: New
8223 (remote_state::remote_state): Allocate stop_reply_queue.
8224 (remote_state): Delete global.
8225 (get_remote_state_raw): Delete.
8226 (remote_target::get_remote_state): Allocate m_remote_state on
8228 (get_current_remote_target): New.
8229 (remote_ops, extended_remote_ops): Delete.
8230 (wait_forever_enabled_p, remote_async_inferior_event_token):
8231 Delete, moved to struct remote_state.
8232 (remote_target::close): Delete self. Destruction bits split to
8234 (remote_target::~remote_target): ... this.
8235 (show_memory_packet_size): Adjust to use
8236 get_current_remote_target.
8237 (struct protocol_feature) <func>: Add remote_target parameter.
8238 All callers adjusted.
8239 (curr_quit_handler_target): New.
8240 (remote_serial_quit_handler): Reimplement.
8241 (remote_target::open_1): Adjust to use get_current_remote_target.
8242 Heap-allocate remote_target/extended_remote_target instances.
8243 (vcont_builder::vcont_builder): Add remote_target parameter, and
8244 save it in m_remote. All callers adjusted.
8245 (vcont_builder::m_remote): New field.
8246 (vcont_builder::restart, vcont_builder::flush)
8247 (vcont_builder::push_action): Use it.
8248 (remote_target::commit_resume): Use it.
8249 (struct queue_iter_param) <remote>: New field.
8250 (remote_target::remove_new_fork_children): Fill in 'remote' field.
8251 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
8252 (check_pending_event_prevents_wildcard_vcont_callback)
8253 (remote_target::check_pending_events_prevent_wildcard_vcont)
8254 (remote_target::discard_pending_stop_replies)
8255 (remote_target::discard_pending_stop_replies_in_queue)
8256 (remote_target::remote_notif_remove_queued_reply): Fill in
8258 (remote_notif_get_pending_events): New.
8259 (remote_target::readchar, remote_target::remote_serial_write):
8260 Save/restore curr_quit_handler_target.
8262 (kill_new_fork_children): Fill in 'remote' field.
8263 (packet_command): Use get_current_remote_target, defer to
8264 remote_target method of same name.
8265 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
8266 parameter, and save it in m_remote. All callers adjusted.
8267 (scoped_remote_fd::release): Use m_remote.
8268 (scoped_remote_fd::m_remote): New field.
8269 (remote_file_put, remote_file_get, remote_file_delete): Use
8270 get_current_remote_target, defer to remote_target method of same
8272 (remote_btrace_reset): Add remote_state paremeter. Update all
8274 (remote_async_inferior_event_handler). Pass down 'data'.
8275 (remote_new_objfile): Use get_current_remote_target.
8276 (remote_target::vcont_r_supported): New.
8277 (set_range_stepping): Use get_current_remote_target and
8278 remote_target::vcont_r_supported.
8279 (_initialize_remote): Don't allocate 'remote_state' and
8280 'stop_reply_queue' globals.
8281 * remote.h (struct remote_target): Forward declare.
8282 (getpkt, putpkt, remote_notif_get_pending_events): Add
8283 'remote_target' parameter.
8285 2018-05-22 Pedro Alves <palves@redhat.com>
8287 * remote.c (vcont_builder): Now a class. Make all data members
8289 (vcont_builder) <vcont_builder, restart, flush, push_action>:
8291 (vcont_builder_restart): Rename to ...
8292 (vcont_builder::restart): ... this.
8293 (vcont_builder_flush): Rename to ...
8294 (vcont_builder::flush): ... this.
8295 (vcont_builder_push_action): Rename to ...
8296 (vcont_builder::push_action): ... this.
8297 (remote_target::commit_resume): Adjust.
8299 2018-05-22 Pedro Alves <palves@redhat.com>
8301 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
8302 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
8303 (get_fixed_memory_packet_size): New.
8304 (get_memory_packet_size): Use it.
8305 (set_memory_packet_size): Don't override the config size with
8306 DEFAULT_MAX_MEMORY_PACKET_SIZE.
8307 (show_memory_packet_size): Use get_fixed_memory_packet_size.
8308 Don't refer to get_memory_packet_size if not connected to a remote
8309 target. Show "(default)" if configured size is 0.
8311 2018-05-22 Pedro Alves <palves@redhat.com>
8313 * remote.c (remote_target::mourn_inferior): Move
8314 discard_pending_stop_replies call here from ...
8315 (_initialize_remote): ... here.
8317 2018-05-22 Pedro Alves <palves@redhat.com>
8319 * remote.c (compare_section_command): Remove set_general_process
8322 2018-05-22 Pedro Alves <palves@redhat.com>
8324 * remote.c (struct packet_reg, struct remote_arch_state):
8325 Move higher up in the file.
8326 (remote_state) <m_arch_states>: Store remote_arch_state values
8327 instead of remote_arch_state pointers.
8328 (remote_state::get_remote_arch_state): Adjust.
8330 2018-05-22 Pedro Alves <palves@redhat.com>
8332 * remote.c: Include <unordered_map>.
8333 (remote_state): Now a class.
8334 (remote_state) <get_remote_arch_state>: Declare method.
8335 <get_remote_arch_state>: New field.
8336 (remote_arch_state) <remote_arch_state>: Declare ctor.
8337 <regs>: Now a unique_ptr.
8338 (remote_gdbarch_data_handle): Delete.
8339 (get_remote_arch_state): Delete.
8340 (remote_state::get_remote_arch_state): New.
8341 (get_remote_state): Adjust to call remote_state's
8342 get_remote_arch_state method.
8343 (init_remote_state): Delete, bits factored out to ...
8344 (remote_arch_state::remote_arch_state): ... this new method.
8345 (get_remote_packet_size, get_memory_packet_size)
8346 (process_g_packet, remote_target::fetch_registers)
8347 (remote_target::prepare_to_store, store_registers_using_G)
8348 (remote_target::store_registers, remote_target::get_trace_status):
8349 Adjust to call remote_state's method.
8350 (_initialize_remote): Remove reference to
8351 remote_gdbarch_data_handle.
8353 2018-05-22 Pedro Alves <palves@redhat.com>
8355 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
8356 pread>: New method declarations.
8357 (remote_target::open_1): Adjust.
8358 (readahead_cache_invalidate): Rename to ...
8359 (readahead_cache::invalidate): ... this, and adjust to be a class
8361 (readahead_cache_invalidate_fd): Rename to ...
8362 (readahead_cache::invalidate_fd): ... this, and adjust to be a
8364 (remote_hostio_pwrite): Adjust.
8365 (remote_hostio_pread_from_cache): Rename to ...
8366 (readahead_cache::pread): ... this, and adjust to be a class
8368 (remote_hostio_close): Adjust.
8370 2018-05-22 Pedro Alves <palves@redhat.com>
8372 * remote.c (remote_hostio_close_cleanup): Delete.
8373 (class scoped_remote_fd): New.
8374 (remote_file_put, remote_file_get): Use it.
8376 2018-05-22 Pedro Alves <palves@redhat.com>
8378 (struct vCont_action_support): Use bool and initialize all fields.
8379 (struct readahead_cache): Initialize all fields.
8380 (remote_state): Use bool and initialize all fields.
8381 (remote_state::remote_state, remote_state::~remote_state): New.
8382 (new_remote_state): Delete.
8383 (_initialize_remote): Use new to allocate remote_state.
8385 2018-05-22 Pedro Alves <palves@redhat.com>
8389 * c-exp.y: Include "c-support.h".
8390 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
8391 of tolower. Use c_ident_is_alpha to scan names.
8392 * c-lang.c: Include "c-support.h".
8393 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
8394 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
8395 * c-support.h: New file, with bits factored out from ...
8396 * cp-name-parser.y: ... this file.
8397 Include "c-support.h".
8398 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
8399 c-support.h and renamed.
8400 (symbol_end, yylex): Adjust.
8402 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8404 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
8405 parameter type to CORE_ADDR.
8406 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
8407 parameter type in declaration to CORE_ADDR.
8408 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
8409 target_auxv_search to get AT_HWCAP and use the result to get the
8411 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
8412 to CORE_ADDR. Remove the cast of the return value to unsigned
8413 long. Fix error predicate of target_auxv_search.
8414 (ppc_linux_nat_target::read_description): Change the type of the
8415 hwcap variable to CORE_ADDR.
8417 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8419 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
8420 if the size of fpscr is larger than 32 bits.
8422 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8424 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
8425 (ppc32_linux_vsxregmap): New global.
8426 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
8427 regcache_supply_regset, and regcache_collect_regset.
8428 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
8429 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
8430 (fetch_vsx_register, store_vsx_register): Remove.
8431 (fetch_vsx_registers): Add regno parameter. Get regset using
8432 ppc_linux_vsxregset. Use regset to supply registers.
8433 (store_vsx_registers): Add regno parameter. Get regset using
8434 ppc_linux_vsxregset. Use regset to collect registers.
8435 (fetch_register): Call fetch_vsx_registers instead of
8437 (store_register): Call store_vsx_registers instead of
8439 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
8440 new regno parameter.
8441 (store_ppc_registers): Call store_vsx_registers with -1 for the
8442 new regno parameter.
8443 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
8444 (ppc_collect_vsxregset): Remove.
8446 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8448 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
8450 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
8451 for vector register offset fields.
8452 (ppc64_fbsd_reg_offsets): Likewise.
8453 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
8454 to vector register offset fields.
8455 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
8456 to vector register offset fields.
8457 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
8458 vector register offset fields.
8459 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
8460 initializers for vector register offset fields.
8461 (rs6000_aix64_reg_offsets): Likewise.
8462 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
8463 (ppc_supply_vrregset): Remove.
8464 (ppc_collect_vrregset): Remove.
8465 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
8466 (ppc_linux_vrregset) : New function.
8467 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
8468 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
8469 (ppc32_linux_vrregset): Remove.
8470 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
8471 and use result instead of ppc32_linux_vrregset.
8472 (ppc32_linux_reg_offsets): Remove initializers for vector register
8474 (ppc64_linux_reg_offsets): Likewise.
8475 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
8476 * ppc-linux-nat.c: Include regset.h.
8477 (gdb_vrregset_t): Adjust comment to account for little-endian
8479 (supply_vrregset, fill_vrregset): Remove.
8480 (fetch_altivec_register, store_altivec_register): Remove.
8481 (fetch_altivec_registers): Add regno parameter. Get regset using
8482 ppc_linux_vrregset. Use regset to supply registers.
8483 (store_altivec_registers): Add regno parameter. Get regset using
8484 ppc_linux_vrregset. Use regset to collect registers.
8485 (fetch_register): Call fetch_altivec_registers instead of
8486 fetch_altivec_register.
8487 (store_register): Call store_altivec_registers instead of
8488 store_altivec_register.
8489 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
8490 the new regno parameter.
8491 (store_ppc_registers): Call store_altivec_registers with -1 for
8492 the new regno parameter.
8494 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8496 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
8497 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
8498 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
8499 (gdb_vrregset_t): Change array type size to
8500 PPC_LINUX_SIZEOF_VRREGSET.
8501 (gdb_vsxregset_t): Change array type size to
8502 PPC_LINUX_SIZEOF_VSXREGSET.
8503 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
8504 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
8505 PPC_LINUX_SIZEOF_VSXREGSET.
8507 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8509 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
8510 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
8512 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
8513 ppc_linux_target_wordsize with tid.
8514 (ppc_linux_nat_target::read_description): Call ppc_linux_target
8516 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
8517 (ppc64_64bit_inferior_p): Add static and inline specifiers.
8518 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
8519 tid parameter. Remove static specifier.
8520 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
8521 (ppc_linux_target_wordsize): New declaration.
8523 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8525 * arch/ppc-linux-common.c: New file.
8526 * arch/ppc-linux-common.h: New file.
8527 * arch/ppc-linux-tdesc.h: New file.
8528 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
8529 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
8530 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
8531 arch/ppc-linux-tdesc.h.
8532 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
8533 arch/ppc-linux-tdesc.h.
8534 (ppc_linux_nat_target::read_description): Remove target
8535 description matching code. Fill a ppc_linux_features struct and
8536 call ppc_linux_match_description with it. Move comment about ISA
8537 2.05 to ppc-linux-common.c.
8538 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
8539 arch/ppc-linux-tdesc.h.
8540 (ppc_linux_core_read_description): Remove target description
8541 matching code. Fill a ppc_linux_features struct and call
8542 ppc_linux_match_description with it.
8543 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
8544 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
8545 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
8546 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
8547 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
8548 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
8549 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
8550 (tdesc_powerpc_e500l): Remove.
8552 2018-05-22 Joel Brobecker <brobecker@adacore.com>
8554 * ada-lang.c (catch_assert_command): Pass empty string instead
8555 of NULL for excep_string argument.
8557 2018-05-22 Maciej W. Rozycki <macro@mips.com>
8559 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
8560 the width of the requested register exceeds the width of the
8563 2018-05-21 Tom Tromey <tom@tromey.com>
8565 * printcmd.c (output_command): Remove.
8566 (output_command_const): Rename to output_command.
8567 * valprint.h (output_command): Rename from output_command_const.
8568 * tracepoint.c (trace_dump_actions): Call output_command.
8570 2018-05-21 Tom Tromey <tom@tromey.com>
8572 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
8573 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
8574 * ada-lang.h (create_ada_exception_catchpoint): Update.
8575 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
8577 (create_excep_cond_exprs, ~ada_catchpoint)
8578 (should_stop_exception, print_one_exception)
8579 (print_mention_exception, print_recreate_exception): Update.
8580 (ada_get_next_arg): Remove.
8581 (catch_ada_exception_command_split): Use std::string. Change type
8582 of "excep_string", "cond_string".
8583 (catch_ada_exception_command): Update.
8584 (create_ada_exception_catchpoint): Change type of excep_string.
8585 (ada_exception_sal): Remove excep_string parameter.
8586 (~ada_catchpoint): Remove.
8588 2018-05-21 Tom Tromey <tom@tromey.com>
8590 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
8593 2018-05-21 Tom Tromey <tom@tromey.com>
8595 * ada-lang.c (ada_exception_message_1, ada_exception_message):
8596 Return unique_xmalloc_ptr.
8597 (print_it_exception): Update.
8599 2018-05-21 Tom Tromey <tom@tromey.com>
8601 * tracepoint.c (trace_dump_actions): Use std::string.
8603 2018-05-21 Tom Tromey <tom@tromey.com>
8605 * symfile.c (reread_symbols): Use std::string for original_name.
8607 2018-05-21 Tom Tromey <tom@tromey.com>
8609 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
8610 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
8613 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
8615 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
8617 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
8618 * objfiles.c (get_objfile_bfd_data): Allocate
8619 objfile_per_bfd_storage with obstack_new when allocating on
8622 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
8624 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
8626 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
8627 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
8628 * mdebugread.c (mdebug_build_psymtabs): Likewise.
8629 (add_pending): Likewise.
8630 (parse_symbol): Likewise.
8631 (parse_partial_symbols): Likewise.
8632 (psymtab_to_symtab_1): Likewise.
8633 (new_psymtab): Likewise.
8634 (elfmdebug_build_psymtabs): Likewise.
8635 * minsyms.c (terminate_minimal_symbol_table): Likewise.
8636 * objfiles.c (get_objfile_bfd_data): Likewise.
8637 (objfile_register_static_link): Likewise.
8638 * psymtab.c (allocate_psymtab): Likewise.
8639 * stabsread.c (read_member_functions): Likewise.
8640 * xcoffread.c (xcoff_end_psymtab): Likewise.
8642 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
8644 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
8645 compiler supports std::is_trivially_constructible.
8646 * common/poison.h: Include obstack.h.
8647 (IsMallocable): Define to is_trivially_constructible if the
8648 compiler supports it, define to true_type otherwise.
8652 (XOBNEWVEC): Redefine.
8653 * gdb_obstack.h (obstack_zalloc): New.
8654 (OBSTACK_ZALLOC): Redefine.
8655 (obstack_calloc): New.
8656 (OBSTACK_CALLOC): Redefine.
8658 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
8659 (gdbarch_obstack): New declaration in gdbarch.h, definition in
8661 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
8662 obstack_calloc/obstack_zalloc.
8663 (gdbarch_obstack_zalloc): Remove.
8664 * target-descriptions.c (tdesc_data_init): Use obstack_new.
8666 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8668 * stack.c (backtrace_command_1): Remove useless variable int i.
8670 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8672 * stack.c (print_frame_info): Fix comment.
8674 2018-05-18 Tom Tromey <tom@tromey.com>
8676 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
8677 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
8678 (~dwarf2_per_objfile): Update
8679 (dwarf2_get_dwz_file): Use new.
8680 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
8683 2018-05-18 Tom Tromey <tom@tromey.com>
8685 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
8687 * dwarf2read.c (struct dwp_file): Add constructor and
8689 (open_and_init_dwp_file): Return a unique_ptr.
8690 (dwarf2_per_objfile, create_dwp_hash_table)
8691 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
8692 (lookup_dwo_unit_in_dwp): Update.
8693 (open_and_init_dwp_file, get_dwp_file): Update.
8695 2018-05-18 Tom Tromey <tom@tromey.com>
8697 * dwarf2read.c (dwarf2_per_objfile): Update.
8698 (struct mapped_index): Add initializers.
8699 (dwarf2_read_index): Use new.
8700 (dw2_symtab_iter_init): Update.
8701 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
8704 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
8706 * dwarf2read.c (mapped_index) <total_size>: Remove.
8708 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
8710 * unittests/format_pieces-selftests.c (test_format_specifier):
8713 2018-05-18 Tom Tromey <tom@tromey.com>
8715 * c-typeprint.c (maybe_print_hole): New function.
8716 (c_print_type_struct_field_offset): Update.
8717 (c_type_print_base_struct_union): Call maybe_print_hole.
8719 2018-05-17 Keith Seitz <keiths@redhat.com>
8721 * breakpoint.c (build_bpstat_chain): New function, moved from
8723 (bpstat_stop_status): Add optional parameter, `stop_chain'.
8724 If no stop chain is passed, call build_bpstat_chain to build it.
8725 * breakpoint.h (build_bpstat_chain): Declare.
8726 (bpstat_stop_status): Move documentation here from breakpoint.c.
8727 * infrun.c (handle_signal_stop): Before eliding inlined frames,
8728 build the stop chain and pass it to skip_inline_frames.
8729 Pass this stop chain to bpstat_stop_status.
8730 * inline-frame.c: Include breakpoint.h.
8731 (stopped_by_user_bp_inline_frame): New function.
8732 (skip_inline_frames): Add parameter `stop_chain'.
8733 Move documention to inline-frame.h.
8734 If non-NULL, use stopped_by_user_bp_inline_frame to determine
8735 whether the frame should be elided.
8736 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
8737 Add moved documentation and update for new parameter.
8739 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
8742 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8743 unittests/format_pieces-selftests.c.
8744 * common/format.h (format_piece) <operator==>: New.
8745 (format_pieces) <operator[]>: Remove.
8746 * common/format.c (format_pieces::format_pieces): Handle \e.
8747 * unittests/format_pieces-selftests.c: New.
8749 2018-05-17 Tom Tromey <tom@tromey.com>
8752 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
8753 (dw2_instantiate_symtab): Add skip_partial parameter.
8754 (dw2_find_last_source_symtab, dw2_map_expand_apply)
8755 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
8756 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
8757 (dw2_expand_symtabs_matching_one)
8758 (dw2_find_pc_sect_compunit_symtab)
8759 (dw2_debug_names_lookup_symbol)
8760 (dw2_debug_names_expand_symtabs_for_function): Update.
8761 (init_cutu_and_read_dies): Add skip_partial parameter.
8762 (process_psymtab_comp_unit, build_type_psymtabs_1)
8763 (process_skeletonless_type_unit, load_partial_comp_unit)
8764 (psymtab_to_symtab_1): Update.
8765 (load_full_comp_unit): Add skip_partial parameter.
8766 (process_imported_unit_die, dwarf2_read_addr_index)
8767 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
8768 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
8769 (read_signatured_type): Update.
8771 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
8773 * value.c (release_value): Remove unused variable.
8774 (record_latest_value): Likewise.
8775 (access_value_history): Likewise.
8776 (preserve_values): Likewise.
8778 2018-05-17 Tom Tromey <tom@tromey.com>
8780 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
8783 2018-05-16 Maciej W. Rozycki <macro@mips.com>
8786 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
8787 Also handle registers whose width is not a multiple of
8789 (linux_nat_trad_target::store_register): Likewise.
8791 2018-05-16 Tom Tromey <tom@tromey.com>
8793 * gdbcore.h (core_bfd): Redefine.
8794 * corelow.c (core_target::close): Update.
8795 (core_target_open): Update.
8796 * progspace.h (struct program_space) <cbfd>: Now a
8799 2018-05-16 Tom Tromey <tom@tromey.com>
8802 * symfile-add-flags.h (enum symfile_add_flags)
8803 <SYMFILE_NOT_FILENAME>: New constant.
8804 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
8805 objfile name from BFD.
8806 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
8807 * minidebug.c (find_separate_debug_file_in_section): Put
8808 ".gnu_debugdata" into BFD's file name.
8810 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
8812 * regcache.c (regcache_read_ftype, regcache_write_ftype):
8815 2018-05-15 Tamar Christina <tamar.christina@arm.com>
8818 * aarch64-tdep.c (aarch64_analyze_prologue,
8819 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
8820 Indicate not interested in errors.
8822 2018-05-15 Maciej W. Rozycki <macro@mips.com>
8824 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
8825 Supply the MIPS_ZERO_REGNUM register.
8827 2018-05-15 Maciej W. Rozycki <macro@mips.com>
8829 * mips-tdep.c (mask_address_var): Make variable static.
8831 2018-05-14 Tom Tromey <tom@tromey.com>
8833 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
8835 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
8837 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
8838 FXSAVE_ADDR for the mxcsr register.
8840 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
8842 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
8844 2018-05-11 Pedro Alves <palves@redhat.com>
8846 * corelow.c (core_target) <core_target>: No longer inline.
8847 Initialize m_core_gdbarch, m_core_vec and build the section table
8849 <~core_target>: New.
8850 <core_gdbarch, get_core_register_section>: New methods.
8851 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
8852 factored out from ...
8853 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
8855 (sniff_core_bfd): Add gdbarch parameter.
8856 (core_close): Delete, merged into ...
8857 (core_target::close): ... here. Delete self.
8858 (core_close_cleanup): Delete.
8859 (core_target_open): Allocate a core_target on the heap. Use a
8860 unique_ptr instead of a cleanup. Bits moved into the core_target
8861 ctor. Adjust to use core_target methods instead of globals.
8862 (get_core_register_section): Rename to ...
8863 (core_target::get_core_register_section): ... this and adjust.
8864 (struct get_core_registers_cb_data): New.
8865 (get_core_registers_cb): Use it. Use bool.
8866 (core_target::fetch_registers, core_target::files_info)
8867 (core_target::xfer_partial, core_target::read_description)
8868 (core_target::pid_to, core_target::thread_name): Adjust to
8869 reference class fields instead of globals.
8870 * target.h (struct target_ops_deleter, target_ops_up): New.
8872 2018-05-11 Pedro Alves <palves@redhat.com>
8874 * corefile.c (core_file_command): Move to corelow.c.
8875 * corelow.c (the_core_target): Delete.
8876 (core_file_command): Moved from corefile.c. Check exec_bfd
8877 instead of the_core_target. Use target_detach instead of calling
8878 into the_core_target directly.
8879 (maybe_say_no_core_file_now): New.
8880 (core_target::detach): Use it.
8881 (_initialize_corelow): Remove references to the_core_target.
8882 * gdbcore.h (the_core_target): Delete.
8884 2018-05-11 Tom Tromey <tromey@redhat.com>
8885 Pedro Alves <palves@redhat.com>
8887 * corefile.c (core_bfd): Remove.
8888 * gdbcore.h (core_bfd): Now a macro.
8889 * progspace.h (struct program_space) <cbfd>: New field.
8891 2018-05-11 Tom Tromey <tom@tromey.com>
8893 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
8896 2018-05-10 Tom Tromey <tom@tromey.com>
8898 * configure: Rebuild.
8899 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
8901 2018-05-10 Joel Brobecker <brobecker@adacore.com>
8904 * regformats/regdat.sh: Adjust script, following the addition
8905 of the new expedite_regs parameter to init_target_desc.
8907 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
8910 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
8911 set_gdbarch_significant_addr_bit.
8912 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
8913 set_gdbarch_significant_addr_bit.
8914 * utils.c (address_significant): Update to sign extend addr.
8916 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
8918 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
8919 (xtensa_linux_init_abi): Limit tdep->num_regs by
8920 tdep->num_nopriv_regs.
8921 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
8922 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
8925 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
8927 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
8929 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
8931 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
8932 (I387_MXCSR_INIT_VAL): New constant.
8933 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
8934 buffer if it was supplied by the inferior.
8935 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
8936 (i387_xsave_get_clear_bv): New function.
8937 (i387_supply_xsave): Only read x87 control registers from the
8938 xsave buffer if the feature is enabled, and the state will have
8939 been written, otherwise, provide a suitable default.
8940 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
8941 including x87 control registers. Update control registers if they
8942 have changed from the default value, and mark features as enabled
8944 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
8946 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
8948 * spu-tdep.c (info_spu_event_command): Fix output formatting.
8950 2018-05-07 Tom Tromey <tom@tromey.com>
8952 * configure: Rebuild.
8953 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
8955 2018-05-07 Tom Tromey <tom@tromey.com>
8958 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
8959 bit. Use correct value for VDIV.
8961 2018-05-04 Tom Tromey <tom@tromey.com>
8963 * configure: Rebuild.
8964 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
8966 2018-05-04 Tom Tromey <tom@tromey.com>
8968 * linux-record.c (record_linux_system_call) <case
8969 RECORD_SYS_RECVFROM>: Add "break".
8971 2018-05-04 Tom Tromey <tom@tromey.com>
8973 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
8974 Add missing "break".
8975 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
8976 Add missing "break".
8978 2018-05-04 Tom Tromey <tom@tromey.com>
8980 * rs6000-tdep.c (ppc_process_record_op4)
8981 (ppc_process_record_op63): Add fall-through comment.
8983 2018-05-04 Tom Tromey <tom@tromey.com>
8985 * i386-tdep.c (i386_process_record): Add fall-through comment.
8987 2018-05-04 Tom Tromey <tom@tromey.com>
8989 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
8992 2018-05-04 Tom Tromey <tom@tromey.com>
8994 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
8995 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
8996 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
8998 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
9000 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
9003 2018-05-04 Tom Tromey <tom@tromey.com>
9005 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
9007 2018-05-04 Tom Tromey <tom@tromey.com>
9009 * s390-tdep.c (s390_process_record): Fix fall-through comments.
9010 * xcoffread.c (scan_xcoff_symtab): Move comment later.
9011 * symfile.c (section_is_mapped): Fix fall-through comment.
9012 * stabsread.c (define_symbol, read_member_functions): Fix
9013 fall-through comment.
9014 * s390-linux-tdep.c (s390_process_record): Fix fall-through
9016 * remote.c (remote_wait_as): Fix fall-through comment.
9017 * p-exp.y (yylex): Fix fall-through comment.
9018 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
9020 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
9021 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
9022 * jv-exp.y (yylex): Fix fall-through comment.
9023 * go-exp.y (lex_one_token): Fix fall-through comment.
9024 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
9025 fall-through comment.
9026 * f-exp.y (yylex): Fix fall-through comment.
9027 * dwarf2read.c (process_die): Fix fall-through comments.
9028 * dbxread.c (process_one_symbol): Fix fall-through comment.
9029 * d-exp.y (lex_one_token): Fix fall-through comment.
9030 * cp-name-parser.y (yylex): Fix fall-through comment.
9031 * coffread.c (coff_symtab_read): Fix fall-through comment.
9032 * c-exp.y (lex_one_token): Fix fall-through comment.
9033 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
9035 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
9038 2018-05-04 Tom Tromey <tom@tromey.com>
9041 * NEWS: Mention gdb.execute change.
9042 * gdbcmd.h (execute_control_command): Don't declare.
9043 * python/python.c (execute_gdb_command): Use read_command_lines_1,
9044 execute_control_commands, execute_control_commands_to_string.
9045 * cli/cli-script.h (execute_control_commands)
9046 (execute_control_commands_to_string): Declare.
9047 (execute_control_command): Add from_tty parameter.
9048 * cli/cli-script.c (execute_control_commands)
9049 (execute_control_commands_to_string): New functions.
9050 (execute_user_command): Use execute_control_commands.
9051 (execute_control_command_1): Add "from_tty" parameter. Update.
9052 (execute_control_command): Likewise.
9054 2018-05-04 Tom Tromey <tom@tromey.com>
9057 * NEWS: Mention that breakpoint commands are writable.
9058 * python/py-breakpoint.c (bppy_set_commands): New function.
9059 (breakpoint_object_getset) <"commands">: Use it.
9061 2018-05-04 Tom Tromey <tom@tromey.com>
9063 * tracepoint.c (actions_command): Update.
9064 * mi/mi-cmd-break.c (mi_command_line_array)
9065 (mi_command_line_array_cnt, mi_command_line_array_ptr)
9066 (mi_read_next_line): Remove.
9067 (mi_cmd_break_commands): Update.
9068 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
9070 * cli/cli-script.c (get_command_line): Update.
9071 (process_next_line): Use function_view. Constify.
9072 (recurse_read_control_structure, read_command_lines)
9073 (read_command_lines_1): Change argument types to function_view.
9074 (do_define_command, document_command): Update.
9075 * breakpoint.h (check_tracepoint_command): Don't declare.
9076 * breakpoint.c (check_tracepoint_command): Remove.
9077 (commands_command_1, create_tracepoint_from_upload): Update.
9079 2018-05-04 Tom Tromey <tom@tromey.com>
9082 * cli/cli-script.h (enum command_control_type) <define_control>:
9084 * cli/cli-script.c (multi_line_command_p): Handle define_control.
9085 (build_command_line, execute_control_command_1)
9086 (process_next_line): Likewise.
9087 (do_define_command): New function, extracted from define_command.
9088 (define_command): Use it.
9090 2018-05-04 Tom Tromey <tom@tromey.com>
9092 * tracepoint.c (actions_command): Update.
9093 * cli/cli-script.h (read_command_lines): Update.
9094 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
9095 (MAX_TMPBUF): Remove define.
9096 (define_command): Use string_printf.
9097 (document_command): Likewise.
9098 * breakpoint.c (commands_command_1): Update.
9100 2018-05-04 Tom Tromey <tom@tromey.com>
9102 * top.c (execute_command): Update.
9103 * cli/cli-script.h (print_command_lines): Now varargs.
9104 * cli/cli-script.c (print_command_lines): Now varargs.
9105 (execute_control_command_1) <case while_control, case if_control>:
9108 2018-05-04 Tom Tromey <tom@tromey.com>
9110 * tracepoint.c (all_tracepoint_actions): Rename from
9111 all_tracepoint_actions_and_cleanup. Change return type.
9112 (actions_command, encode_actions_1, encode_actions)
9113 (trace_dump_actions, tdump_command): Update.
9114 * remote.c (remote_download_command_source): Update.
9115 * python/python.c (gdbpy_eval_from_control_command)
9116 (python_command, python_interactive_command): Update.
9117 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
9118 * guile/guile.c (guile_command)
9119 (gdbscm_eval_from_control_command, guile_command): Update.
9120 * compile/compile.c (compile_code_command)
9121 (compile_print_command, compile_to_object): Update.
9122 * cli/cli-script.h (struct command_lines_deleter): New.
9123 (counted_command_line): New typedef.
9124 (struct command_line): Add constructor, destructor.
9125 <body_list>: Remove.
9126 <body_list_0, body_list_1>: New members.
9127 (command_line_up): Remove typedef.
9128 (read_command_lines, read_command_lines_1, get_command_line):
9130 (copy_command_lines): Don't declare.
9131 * cli/cli-script.c (build_command_line): Use "new".
9132 (get_command_line): Return counted_command_line.
9133 (print_command_lines, execute_user_command)
9134 (execute_control_command_1, while_command, if_command): Update.
9135 (realloc_body_list): Remove.
9136 (process_next_line, recurse_read_control_structure): Update.
9137 (read_command_lines, read_command_lines_1): Return counted_command_line.
9138 (free_command_lines): Use "delete".
9139 (copy_command_lines): Remove.
9140 (define_command, document_command, show_user_1): Update.
9141 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
9142 a counted_command_line.
9143 * breakpoint.h (counted_command_line): Remove typedef.
9144 (breakpoint_set_commands): Update.
9145 * breakpoint.c (check_no_tracepoint_commands)
9146 (validate_commands_for_breakpoint): Update.
9147 (breakpoint_set_commands): Change commands to be a
9148 counted_command_line.
9149 (commands_command_1, update_dprintf_command_list)
9150 (create_tracepoint_from_upload): Update.
9152 2018-05-04 Tom Tromey <tom@tromey.com>
9154 * cli/cli-decode.h (cmd_list_element): New constructor.
9155 (~cmd_list_element): New destructor.
9156 (struct cmd_list_element): Add initializers.
9157 * cli/cli-decode.c (do_add_cmd): Use "new".
9158 (delete_cmd): Use "delete".
9160 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
9161 Pedro Alves <palves@redhat.com>
9163 PR breakpoints/19806 and support for PR external/20207.
9164 * NEWS: Mention Aarch64 watchpoint improvements.
9165 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
9166 watchpoints and PR external/20207 watchpoints.
9167 * nat/aarch64-linux-hw-point.c
9168 (kernel_supports_any_contiguous_range): New.
9169 (aarch64_watchpoint_offset): New.
9170 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
9171 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
9172 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
9173 (aarch64_align_watchpoint): New parameters aligned_offset_p and
9174 next_addr_orig_p. Support PR external/20207 watchpoints.
9175 (aarch64_downgrade_regs): New.
9176 (aarch64_dr_state_insert_one_point): New parameters offset and
9178 (aarch64_dr_state_remove_one_point): Likewise.
9179 (aarch64_handle_breakpoint): Update caller.
9180 (aarch64_handle_aligned_watchpoint): Likewise.
9181 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
9183 (aarch64_linux_set_debug_regs): Remove const from state. Call
9184 aarch64_downgrade_regs.
9185 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
9186 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
9187 (DR_CONTROL_MASK): ... this.
9188 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
9189 (unsigned int aarch64_watchpoint_offset): New prototype.
9190 (aarch64_linux_set_debug_regs): Remove const from state.
9191 * utils.c (align_up, align_down): Move to ...
9192 * common/common-utils.c (align_up, align_down): ... here.
9193 * utils.h (align_up, align_down): Move to ...
9194 * common/common-utils.h (align_up, align_down): ... here.
9196 2018-05-04 Joel Brobecker <brobecker@adacore.com>
9198 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
9199 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
9200 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
9201 Re-implement to match the ABI as summarized in GCC's
9202 gcc/config/sparc/sparc.c. All callers updated.
9203 (sparc32_store_arguments): Remove assertion.
9205 2018-05-04 Tom Tromey <tom@tromey.com>
9207 * printcmd.c: Don't include tui.h.
9208 (decode_format): Use skip_spaces.
9210 2018-05-04 Tom Tromey <tom@tromey.com>
9213 * printcmd.c (last_count): New global.
9214 (x_command): Use saved count when repeating.
9216 2018-05-04 Tom Tromey <tom@tromey.com>
9218 * nto-procfs.c (do_closedir_cleanup): Remove.
9219 (procfs_pidlist): Use gdb_dir_up.
9220 * procfs.c (do_closedir_cleanup): Remove.
9221 (proc_update_threads): Use gdb_dir_up.
9222 * common/filestuff.h (struct gdb_dir_deleter): New.
9223 (gdb_dir_up): New typedef.
9225 2018-05-04 Tom Tromey <tom@tromey.com>
9227 * ada-lang.c (print_mention_exception): Use std::string.
9229 2018-05-04 Tom Tromey <tom@tromey.com>
9231 * ada-lang.c (create_excep_cond_exprs): Update.
9232 (ada_exception_catchpoint_cond_string): Use std::string.
9234 2018-05-04 Tom Tromey <tom@tromey.com>
9236 * ada-lang.c (xget_renaming_scope): Return std::string.
9237 (old_renaming_is_invisible): Update.
9239 2018-05-04 Tom Tromey <tom@tromey.com>
9241 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
9242 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
9244 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
9246 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
9248 2018-05-04 Tom Tromey <tom@tromey.com>
9250 * remote.c (remote_query_supported_append): Change type.
9251 (remote_check_symbols): Update.
9253 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
9256 * configure.ac: Prepend libpython.
9257 * python/python-config.py: Likewise.
9258 * configure: Regenerate.
9260 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
9262 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
9264 2018-05-03 Pedro Alves <palves@redhat.com>
9267 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
9268 override. Write 'true' instead of '1'.
9269 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
9272 2018-05-02 Pedro Alves <palves@redhat.com>
9274 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
9275 add_inf_child_target.
9276 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
9277 add_inf_child_target.
9278 * aix-thread.c (aix_thread_target_info): New.
9279 (aix_thread_target) <shortname, longname, doc>: Delete.
9281 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
9282 add_inf_child_target.
9283 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
9284 add_inf_child_target.
9285 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
9286 add_inf_child_target.
9287 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
9288 add_inf_child_target.
9289 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
9290 add_inf_child_target.
9291 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
9292 add_inf_child_target.
9293 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
9294 add_inf_child_target.
9295 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
9296 add_inf_child_target.
9297 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
9298 add_inf_child_target.
9299 * bfd-target.c (target_bfd_target_info): New.
9300 (target_bfd) <shortname, longname, doc>: Delete.
9302 * bsd-kvm.c (bsd_kvm_target_info): New.
9303 (bsd_kvm_target) <shortname, longname, doc>: Delete.
9305 (bsd_kvm_target::open): Rename to ...
9306 (bsd_kvm_target_open): ... this. Adjust.
9307 * bsd-uthread.c (bsd_uthread_target_info): New.
9308 (bsd_uthread_target) <shortname, longname, doc>: Delete.
9310 * corefile.c (core_file_command): Adjust.
9311 * corelow.c (core_target_info): New.
9312 (core_target) <shortname, longname, doc>: Delete.
9314 (core_target::open): Rename to ...
9315 (core_target_open): ... this. Adjust.
9316 * ctf.c (ctf_target_info): New.
9317 (ctf_target) <shortname, longname, doc>: Delete.
9319 (ctf_target::open): Rename to ...
9320 (ctf_target_open): ... this.
9321 (_initialize_ctf): Adjust.
9322 * exec.c (exec_target_info): New.
9323 (exec_target) <shortname, longname, doc>: Delete.
9325 (exec_target::open): Rename to ...
9326 (exec_target_open): ... this.
9327 * gdbcore.h (core_target_open): Declare.
9328 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
9329 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
9330 add_inf_child_target.
9331 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
9332 add_inf_child_target.
9333 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
9334 add_inf_child_target.
9335 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
9336 add_inf_child_target.
9337 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
9338 add_inf_child_target.
9339 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
9340 add_inf_child_target.
9341 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
9342 add_inf_child_target.
9343 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
9344 add_inf_child_target.
9345 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
9346 add_inf_child_target.
9347 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
9348 add_inf_child_target.
9349 * inf-child.c (inf_child_target_info): New.
9350 (inf_child_target::info): New.
9351 (inf_child_open_target): Remove 'target' parameter. Use
9352 get_native_target instead.
9353 (inf_child_target::open): Delete.
9354 (add_inf_child_target): New.
9355 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
9358 (add_inf_child_target): Declare.
9359 (inf_child_open_target): Declare.
9360 * linux-thread-db.c (thread_db_target_info): New.
9361 (thread_db_target) <shortname, longname, doc>: Delete.
9363 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
9364 add_inf_child_target.
9365 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
9366 add_inf_child_target.
9367 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
9368 add_inf_child_target.
9369 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
9370 add_inf_child_target.
9371 * make-target-delegates (print_class): Adjust.
9372 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
9373 add_inf_child_target.
9374 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
9375 add_inf_child_target.
9376 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
9377 add_inf_child_target.
9378 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
9379 add_inf_child_target.
9380 * nto-procfs.c (nto_native_target_info): New.
9381 (nto_procfs_target_native) <shortname, longname, doc>:
9384 (nto_procfs_target_info): New.
9385 (nto_procfs_target_procfs) <shortname, longname, doc>:
9388 (init_procfs_targets): Adjust.
9389 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
9390 add_inf_child_target.
9391 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
9392 add_inf_child_target.
9393 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
9394 add_inf_child_target.
9395 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
9396 add_inf_child_target.
9397 * ravenscar-thread.c (ravenscar_target_info): New.
9398 (ravenscar_thread_target) <shortname, longname, doc>:
9401 * record-btrace.c (record_btrace_target_info):
9402 (record_btrace_target) <shortname, longname, doc>: Delete.
9404 (record_btrace_target::open): Rename to ...
9405 (record_btrace_target_open): ... this. Adjust.
9406 * record-full.c (record_longname, record_doc): New.
9407 (record_full_base_target) <shortname, longname, doc>: Delete.
9409 (record_full_target_info): New.
9410 (record_full_target): <shortname>: Delete.
9412 (record_full_core_open_1, record_full_open_1): Update comments.
9413 (record_full_base_target::open): Rename to ...
9414 (record_full_open): ... this.
9415 (cmd_record_full_restore): Update.
9416 (_initialize_record_full): Update.
9417 * remote-sim.c (remote_sim_target_info): New.
9418 (gdbsim_target) <shortname, longname, doc>: Delete.
9420 (gdbsim_target::open): Rename to ...
9421 (gdbsim_target_open): ... this.
9422 (_initialize_remote_sim): Adjust.
9423 * remote.c (remote_doc): New.
9424 (remote_target_info): New.
9425 (remote_target) <shortname, longname, doc>: Delete.
9427 (extended_remote_target_info): New.
9428 (extended_remote_target) <shortname, longname, doc>: Delete.
9430 (remote_target::open_1): Make static. Adjust.
9431 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
9432 * s390-linux-nat.c (_initialize_s390_nat): Use
9433 add_inf_child_target.
9434 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
9435 add_inf_child_target.
9436 * sol-thread.c (thread_db_target_info): New.
9437 (sol_thread_target) <shortname, longname, doc>: Delete.
9439 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
9440 add_inf_child_target.
9441 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
9442 add_inf_child_target.
9443 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
9444 add_inf_child_target.
9445 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
9446 add_inf_child_target.
9447 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
9448 add_inf_child_target.
9449 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
9450 add_inf_child_target.
9451 * spu-linux-nat.c (_initialize_spu_nat): Use
9452 add_inf_child_target.
9453 * spu-multiarch.c (spu_multiarch_target_info): New.
9454 (spu_multiarch_target) <shortname, longname, doc>: Delete.
9456 * target-delegates.c: Regenerate.
9457 * target.c: Include <unordered_map>.
9458 (target_ops_p): Delete.
9459 (DEF_VEC_P(target_ops_p)): Delete.
9460 (target_factories): New.
9461 (test_target_info): New.
9462 (test_target_ops::info): New.
9463 (open_target): Adjust to use target_factories.
9464 (add_target_with_completer): Rename to ...
9465 (add_target): ... this. Change prototype. Register target_info
9466 and open callback in target_factories. Register target_info in
9467 command context instead of target_ops.
9468 (add_target): Delete old implementation.
9469 (add_deprecated_target_alias): Change prototype. Adjust.
9470 (the_native_target): New.
9471 (set_native_target, get_native_target): New.
9472 (find_default_run_target): Use the_native_target.
9473 (find_attach_target, find_run_target): Simplify.
9474 (target_ops::open): Delete.
9475 (dummy_target_info): New.
9476 (dummy_target::shortname, dummy_target::longname)
9477 (dummy_target::doc): Delete.
9478 (dummy_target::info): New.
9479 (debug_target::shortname, debug_target::longname)
9480 (debug_target::doc): Delete.
9481 (debug_target::info): New.
9482 * target.h (struct target_info): New.
9483 (target_ops::~target_ops): Add comment.
9484 (target_ops::info): New.
9485 (target_ops::shortname, target_ops::longname, target_ops::doc): No
9486 longer virtual. Implement in terms of target_info.
9487 (set_native_target, get_native_target): Declare.
9488 (target_open_ftype): New.
9489 (add_target, add_target_with_completer)
9490 (add_deprecated_target_alias): Change prototype.
9491 (test_target) <shortname, longname, doc>: Delete.
9493 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
9494 add_inf_child_target.
9495 * tracefile-tfile.c (tfile_target_info): New.
9496 (tfile_target) <shortname, longname, doc>: Delete.
9498 (tfile_target::open): Rename to ...
9499 (tfile_target_open): ... this.
9500 (_initialize_tracefile_tfile): Adjust.
9501 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
9502 add_inf_child_target.
9503 * windows-nat.c (_initialize_windows_nat): Use
9504 add_inf_child_target.
9505 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
9506 add_inf_child_target.
9508 2018-05-02 Pedro Alves <palves@redhat.com>
9510 * linux-nat.h (linux_nat_target) <low_new_thread,
9511 low_delete_thread, low_new_fork, low_forget_process,
9512 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
9513 New virtual methods.
9514 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
9515 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
9516 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
9517 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
9518 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
9520 * linux-fork.c (delete_fork): Adjust to call low method.
9521 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
9522 (linux_nat_new_fork, linux_nat_forget_process_hook)
9523 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
9524 (linux_nat_status_is_event):
9525 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
9526 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
9528 (sigtrap_is_event): Rename to ...
9529 (linux_nat_target::low_status_is_event): ... this.
9530 (linux_nat_set_status_is_event): Delete.
9531 (save_stop_reason, linux_nat_wait_1)
9532 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
9534 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
9535 (linux_nat_set_new_fork, linux_nat_set_forget_process)
9536 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
9537 (linux_nat_set_prepare_to_resume): Delete.
9538 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
9539 low virtual methods.
9540 * amd64-linux-nat.c: Likewise.
9541 * arm-linux-nat.c: Likewise.
9542 * i386-linux-nat.c: Likewise.
9543 * ia64-linux-nat.c: Likewise.
9544 * mips-linux-nat.c: Likewise.
9545 * ppc-linux-nat.c: Likewise.
9546 * s390-linux-nat.c: Likewise.
9547 * sparc64-linux-nat.c: Likewise.
9548 * x86-linux-nat.c: Likewise.
9549 * x86-linux-nat.h: Include "nat/x86-linux.h".
9550 (x86_linux_nat_target) <low_new_fork, low_forget_process,
9551 low_prepare_to_resume, low_new_thread, low_delete_thread>:
9554 2018-05-02 Pedro Alves <palves@redhat.com>
9556 * target.h (target_ops)
9557 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9558 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
9559 stopped_by_watchpoint, have_continuable_watchpoint,
9560 stopped_data_address, watchpoint_addr_within_range,
9561 can_accel_watchpoint_condition, can_run, thread_alive,
9562 has_all_memory, has_memory, has_stack, has_registers,
9563 has_execution, can_async_p, is_async_p, supports_non_stop,
9564 always_non_stop_p, can_execute_reverse, supports_multi_process,
9565 supports_enable_disable_tracepoint,
9566 supports_disable_randomization, supports_string_tracing,
9567 supports_evaluation_of_breakpoint_conditions,
9568 can_run_breakpoint_commands, filesystem_is_local,
9569 can_download_tracepoint, get_trace_state_variable_value,
9570 set_trace_notes, get_tib_address, use_agent, can_use_agent,
9571 record_is_replaying, record_will_replay,
9572 augmented_libraries_svr4_read>: Adjust to return bool.
9573 * aarch64-linux-nat.c: All implementations adjusted.
9574 * aix-thread.c: All implementations adjusted.
9575 * arm-linux-nat.c: All implementations adjusted.
9576 * breakpoint.c: All implementations adjusted.
9577 * bsd-kvm.c: All implementations adjusted.
9578 * bsd-uthread.c: All implementations adjusted.
9579 * corelow.c: All implementations adjusted.
9580 * ctf.c: All implementations adjusted.
9581 * darwin-nat.c: All implementations adjusted.
9582 * darwin-nat.h: All implementations adjusted.
9583 * exec.c: All implementations adjusted.
9584 * fbsd-nat.c: All implementations adjusted.
9585 * fbsd-nat.h: All implementations adjusted.
9586 * gnu-nat.c: All implementations adjusted.
9587 * gnu-nat.h: All implementations adjusted.
9588 * go32-nat.c: All implementations adjusted.
9589 * ia64-linux-nat.c: All implementations adjusted.
9590 * inf-child.c: All implementations adjusted.
9591 * inf-child.h: All implementations adjusted.
9592 * inf-ptrace.c: All implementations adjusted.
9593 * inf-ptrace.h: All implementations adjusted.
9594 * linux-nat.c: All implementations adjusted.
9595 * linux-nat.h: All implementations adjusted.
9596 * mips-linux-nat.c: All implementations adjusted.
9597 * nto-procfs.c: All implementations adjusted.
9598 * ppc-linux-nat.c: All implementations adjusted.
9599 * procfs.c: All implementations adjusted.
9600 * ravenscar-thread.c: All implementations adjusted.
9601 * record-btrace.c: All implementations adjusted.
9602 * record-full.c: All implementations adjusted.
9603 * remote-sim.c: All implementations adjusted.
9604 * remote.c: All implementations adjusted.
9605 * s390-linux-nat.c: All implementations adjusted.
9606 * sol-thread.c: All implementations adjusted.
9607 * spu-multiarch.c: All implementations adjusted.
9608 * target-delegates.c: All implementations adjusted.
9609 * target.c: All implementations adjusted.
9610 * target.h: All implementations adjusted.
9611 * tracefile-tfile.c: All implementations adjusted.
9612 * tracefile.c: All implementations adjusted.
9613 * tracefile.h: All implementations adjusted.
9614 * windows-nat.c: All implementations adjusted.
9615 * x86-linux-nat.h: All implementations adjusted.
9616 * x86-nat.h: All implementations adjusted.
9618 2018-05-02 Pedro Alves <palves@redhat.com>
9620 * make-target-delegates (scan_target_h): Don't trim lines here.
9621 Replace sequences of tabs and/or whitespace with a single
9623 (top level, parsing methods): Trim each line before processing it
9626 2018-05-02 Pedro Alves <palves@redhat.com>
9627 John Baldwin <jhb@freebsd.org>
9629 * target.h (enum strata) <debug_stratum>: New.
9630 (struct target_ops) <all delegation methods>: Replace by C++
9631 virtual methods, and drop "to_" prefix. All references updated
9633 <to_shortname, to_longname, to_doc, to_data,
9634 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
9635 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
9636 virtual methods. All references updated throughout.
9637 <can_attach, supports_terminal_ours, can_create_inferior,
9638 get_thread_control_capabilities, attach_no_wait>: New
9640 <insert_breakpoint, remove_breakpoint>: Now
9641 TARGET_DEFAULT_NORETURN methods.
9642 <info_proc>: Now returns bool.
9644 (OPS_MAGIC): Delete.
9645 (current_target): Delete. All references replaced by references
9647 (target_stack): ... this. New.
9648 (target_shortname, target_longname): Adjust.
9649 (target_can_run): Now a function declaration.
9650 (default_child_has_all_memory, default_child_has_memory)
9651 (default_child_has_stack, default_child_has_registers)
9652 (default_child_has_execution): Remove target_ops parameter.
9653 (complete_target_initialization): Delete.
9654 (memory_breakpoint_target): New template class.
9655 (test_target_ops): Refactor as a C++ class with virtual methods.
9656 * make-target-delegates (NAME_PART): Tighten.
9657 (POINTER_PART, CP_SYMBOL): New.
9658 (SIMPLE_RETURN_PART): Reimplement.
9659 (VEC_RETURN_PART): Expect less.
9660 (RETURN_PART, VIRTUAL_PART): New.
9661 (METHOD): Adjust to C++ virtual methods.
9662 (scan_target_h): Remove reference to C99.
9663 (dname): Output "target_ops::" prefix.
9664 (write_function_header): Adjust to output a C++ class method.
9665 (write_declaration): New.
9666 (write_delegator): Adjust to output a C++ class method.
9667 (tdname): Output "dummy_target::" prefix.
9668 (write_tdefault, write_debugmethod): Adjust to output a C++ class
9670 (tdefault_names, debug_names): Delete.
9671 (return_types, tdefaults, styles, argtypes_array): New.
9672 (top level): All methods are delegators.
9674 (top level): Print dummy_target and debug_target classes.
9675 * target-delegates.c: Regenerate.
9676 * target-debug.h (target_debug_print_enum_info_proc_what)
9677 (target_debug_print_thread_control_capabilities)
9678 (target_debug_print_thread_info_p): New.
9679 * target.c (dummy_target): Delete.
9680 (the_dummy_target, the_debug_target): New.
9681 (target_stack): Now extern.
9682 (set_targetdebug): Push/unpush debug target.
9683 (default_child_has_all_memory, default_child_has_memory)
9684 (default_child_has_stack, default_child_has_registers)
9685 (default_child_has_execution): Remove target_ops parameter.
9686 (complete_target_initialization): Delete.
9687 (add_target_with_completer): No longer call
9688 complete_target_initialization.
9689 (target_supports_terminal_ours): Use regular delegation.
9690 (update_current_target): Delete.
9691 (push_target): No longer check magic number. Don't call
9692 update_current_target.
9693 (unpush_target): Don't call update_current_target.
9694 (target_is_pushed): No longer check magic number.
9695 (target_require_runnable): Skip for all stratums over
9697 (target_ops::info_proc): New.
9698 (target_info_proc): Use find_target_at and
9699 find_default_run_target.
9700 (target_supports_disable_randomization): Use regular delegation.
9701 (target_get_osdata): Use find_target_at.
9702 (target_ops::open, target_ops::close, target_ops::can_attach)
9703 (target_ops::attach, target_ops::can_create_inferior)
9704 (target_ops::create_inferior, target_ops::can_run)
9705 (target_can_run): New.
9706 (default_fileio_target): Use regular delegation.
9707 (target_ops::fileio_open, target_ops::fileio_pwrite)
9708 (target_ops::fileio_pread, target_ops::fileio_fstat)
9709 (target_ops::fileio_close, target_ops::fileio_unlink)
9710 (target_ops::fileio_readlink): New.
9711 (target_fileio_open_1, target_fileio_unlink)
9712 (target_fileio_readlink): Always call the target method. Handle
9714 (return_zero, return_zero_has_execution): Delete.
9715 (init_dummy_target): Delete.
9716 (dummy_target::dummy_target, dummy_target::shortname)
9717 (dummy_target::longname, dummy_target::doc)
9718 (debug_target::debug_target, debug_target::shortname)
9719 (debug_target::longname, debug_target::doc): New.
9720 (target_supports_delete_record): Use regular delegation.
9721 (setup_target_debug): Delete.
9722 (maintenance_print_target_stack): Skip debug_stratum.
9723 (initialize_targets): Instantiate the_dummy_target and
9725 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
9727 (target_auxv_search, fprint_target_auxv): Adjust.
9728 (info_auxv_command): Adjust to use target_stack.
9729 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
9730 * exceptions.c (print_flush): Handle a NULL target_stack.
9731 * regcache.c (target_ops_no_register): Refactor as class with
9734 * exec.c (exec_target): New class.
9735 (exec_ops): Now an exec_target.
9736 (exec_open, exec_close_1, exec_get_section_table)
9737 (exec_xfer_partial, exec_files_info, exec_has_memory)
9738 (exec_make_note_section): Refactor as exec_target methods.
9739 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
9741 (exec_target::find_memory_regions): New.
9742 (_initialize_exec): Don't call init_exec_ops.
9743 * gdbcore.h (exec_file_clear): Delete.
9745 * corefile.c (core_target): Delete.
9746 (core_file_command): Adjust.
9747 * corelow.c (core_target): New class.
9748 (the_core_target): New.
9749 (core_close): Remove target_ops parameter.
9750 (core_close_cleanup): Adjust.
9751 (core_target::close): New.
9752 (core_open, core_detach, get_core_registers, core_files_info)
9753 (core_xfer_partial, core_thread_alive, core_read_description)
9754 (core_pid_to_str, core_thread_name, core_has_memory)
9755 (core_has_stack, core_has_registers, core_info_proc): Rework as
9756 core_target methods.
9757 (ignore, core_remove_breakpoint, init_core_ops): Delete.
9758 (_initialize_corelow): Initialize the_core_target.
9759 * gdbcore.h (core_target): Delete.
9760 (the_core_target): New.
9762 * ctf.c: (ctf_target): New class.
9763 (ctf_ops): Now a ctf_target.
9764 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
9765 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
9766 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
9768 (init_ctf_ops): Delete.
9769 (_initialize_ctf): Don't call it.
9770 * tracefile-tfile.c (tfile_target): New class.
9771 (tfile_ops): Now a tfile_target.
9772 (tfile_open, tfile_close, tfile_files_info)
9773 (tfile_get_tracepoint_status, tfile_trace_find)
9774 (tfile_fetch_registers, tfile_xfer_partial)
9775 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
9776 Refactor as tfile_target methods.
9777 (tfile_xfer_partial_features): Remove target_ops parameter.
9778 (init_tfile_ops): Delete.
9779 (_initialize_tracefile_tfile): Don't call it.
9780 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
9781 (tracefile_has_stack, tracefile_has_registers)
9782 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
9783 tracefile_target methods.
9784 (init_tracefile_ops): Delete.
9785 (tracefile_target::tracefile_target): New.
9786 * tracefile.h: Include "target.h".
9787 (tracefile_target): New class.
9788 (init_tracefile_ops): Delete.
9790 * spu-multiarch.c (spu_multiarch_target): New class.
9791 (spu_ops): Now a spu_multiarch_target.
9792 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
9793 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
9794 (spu_search_memory, spu_mourn_inferior): Refactor as
9795 spu_multiarch_target methods.
9796 (init_spu_ops): Delete.
9797 (_initialize_spu_multiarch): Remove references to init_spu_ops,
9798 complete_target_initialization.
9800 * ravenscar-thread.c (ravenscar_thread_target): New class.
9801 (ravenscar_ops): Now a ravenscar_thread_target.
9802 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
9803 (ravenscar_thread_alive, ravenscar_pid_to_str)
9804 (ravenscar_fetch_registers, ravenscar_store_registers)
9805 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
9806 (ravenscar_stopped_by_hw_breakpoint)
9807 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
9808 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
9809 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
9811 (init_ravenscar_thread_ops): Delete.
9812 (_initialize_ravenscar): Remove references to
9813 init_ravenscar_thread_ops and complete_target_initialization.
9815 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
9816 (bsd_uthread_target): New class.
9817 (bsd_uthread_ops): Now a bsd_uthread_target.
9818 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
9819 (bsd_uthread_close, bsd_uthread_mourn_inferior)
9820 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
9821 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
9822 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
9823 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
9824 (bsd_uthread_target): Delete function.
9825 (_initialize_bsd_uthread): Remove reference to
9826 complete_target_initialization.
9828 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
9829 (target_bfd): ... this new class.
9830 (target_bfd_xfer_partial, target_bfd_get_section_table)
9831 (target_bfd_close): Refactor as target_bfd methods.
9832 (target_bfd::~target_bfd): New.
9833 (target_bfd_reopen): Adjust.
9834 (target_bfd::close): New.
9836 * record-btrace.c (record_btrace_target): New class.
9837 (record_btrace_ops): Now a record_btrace_target.
9838 (record_btrace_open, record_btrace_stop_recording)
9839 (record_btrace_disconnect, record_btrace_close)
9840 (record_btrace_async, record_btrace_info)
9841 (record_btrace_insn_history, record_btrace_insn_history_range)
9842 (record_btrace_insn_history_from, record_btrace_call_history)
9843 (record_btrace_call_history_range)
9844 (record_btrace_call_history_from, record_btrace_record_method)
9845 (record_btrace_is_replaying, record_btrace_will_replay)
9846 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
9847 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
9848 (record_btrace_store_registers, record_btrace_prepare_to_store)
9849 (record_btrace_to_get_unwinder)
9850 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
9851 (record_btrace_commit_resume, record_btrace_wait)
9852 (record_btrace_stop, record_btrace_can_execute_reverse)
9853 (record_btrace_stopped_by_sw_breakpoint)
9854 (record_btrace_supports_stopped_by_sw_breakpoint)
9855 (record_btrace_stopped_by_hw_breakpoint)
9856 (record_btrace_supports_stopped_by_hw_breakpoint)
9857 (record_btrace_update_thread_list, record_btrace_thread_alive)
9858 (record_btrace_goto_begin, record_btrace_goto_end)
9859 (record_btrace_goto, record_btrace_stop_replaying_all)
9860 (record_btrace_execution_direction)
9861 (record_btrace_prepare_to_generate_core)
9862 (record_btrace_done_generating_core): Refactor as
9863 record_btrace_target methods.
9864 (init_record_btrace_ops): Delete.
9865 (_initialize_record_btrace): Remove reference to
9866 init_record_btrace_ops.
9867 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
9868 the execution_direction global.
9869 (record_full_base_target, record_full_target)
9870 (record_full_core_target): New classes.
9871 (record_full_ops): Now a record_full_target.
9872 (record_full_core_ops): Now a record_full_core_target.
9873 (record_full_target::detach, record_full_target::disconnect)
9874 (record_full_core_target::disconnect)
9875 (record_full_target::mourn_inferior, record_full_target::kill):
9877 (record_full_open, record_full_close, record_full_async): Refactor
9878 as methods of the record_full_base_target class.
9879 (record_full_resume, record_full_commit_resume): Refactor
9880 as methods of the record_full_target class.
9881 (record_full_wait, record_full_stopped_by_watchpoint)
9882 (record_full_stopped_data_address)
9883 (record_full_stopped_by_sw_breakpoint)
9884 (record_full_supports_stopped_by_sw_breakpoint)
9885 (record_full_stopped_by_hw_breakpoint)
9886 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
9887 methods of the record_full_base_target class.
9888 (record_full_store_registers, record_full_xfer_partial)
9889 (record_full_insert_breakpoint, record_full_remove_breakpoint):
9890 Refactor as methods of the record_full_target class.
9891 (record_full_can_execute_reverse, record_full_get_bookmark)
9892 (record_full_goto_bookmark, record_full_execution_direction)
9893 (record_full_record_method, record_full_info, record_full_delete)
9894 (record_full_is_replaying, record_full_will_replay)
9895 (record_full_goto_begin, record_full_goto_end, record_full_goto)
9896 (record_full_stop_replaying): Refactor as methods of the
9897 record_full_base_target class.
9898 (record_full_core_resume, record_full_core_kill)
9899 (record_full_core_fetch_registers)
9900 (record_full_core_prepare_to_store)
9901 (record_full_core_store_registers, record_full_core_xfer_partial)
9902 (record_full_core_insert_breakpoint)
9903 (record_full_core_remove_breakpoint)
9904 (record_full_core_has_execution): Refactor
9905 as methods of the record_full_core_target class.
9906 (record_full_base_target::supports_delete_record): New.
9907 (init_record_full_ops): Delete.
9908 (init_record_full_core_ops): Delete.
9909 (record_full_save): Refactor as method of the
9910 record_full_base_target class.
9911 (_initialize_record_full): Remove references to
9912 init_record_full_ops and init_record_full_core_ops.
9914 * remote.c (remote_target, extended_remote_target): New classes.
9915 (remote_ops): Now a remote_target.
9916 (extended_remote_ops): Now an extended_remote_target.
9917 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
9918 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
9919 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
9920 (remote_pass_signals, remote_set_syscall_catchpoint)
9921 (remote_program_signals, )
9922 (remote_thread_always_alive): Remove target_ops parameter.
9923 (remote_thread_alive, remote_thread_name)
9924 (remote_update_thread_list, remote_threads_extra_info)
9925 (remote_static_tracepoint_marker_at)
9926 (remote_static_tracepoint_markers_by_strid)
9927 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
9928 (remote_open): Refactor as methods of remote_target.
9929 (extended_remote_open, extended_remote_detach)
9930 (extended_remote_attach, extended_remote_post_attach):
9931 (extended_remote_supports_disable_randomization)
9932 (extended_remote_create_inferior): : Refactor as method of
9933 extended_remote_target.
9934 (remote_set_permissions, remote_open_1, remote_detach)
9935 (remote_follow_fork, remote_follow_exec, remote_disconnect)
9936 (remote_resume, remote_commit_resume, remote_stop)
9937 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
9938 (remote_terminal_ours, remote_wait, remote_fetch_registers)
9939 (remote_prepare_to_store, remote_store_registers)
9940 (remote_flash_erase, remote_flash_done, remote_files_info)
9941 (remote_kill, remote_mourn, remote_insert_breakpoint)
9942 (remote_remove_breakpoint, remote_insert_watchpoint)
9943 (remote_watchpoint_addr_within_range)
9944 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
9945 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
9946 (remote_supports_stopped_by_sw_breakpoint)
9947 (remote_stopped_by_hw_breakpoint)
9948 (remote_supports_stopped_by_hw_breakpoint)
9949 (remote_stopped_by_watchpoint, remote_stopped_data_address)
9950 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
9951 (remote_verify_memory): Refactor as methods of remote_target.
9952 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
9954 (remote_xfer_partial, remote_get_memory_xfer_limit)
9955 (remote_search_memory, remote_rcmd, remote_memory_map)
9956 (remote_pid_to_str, remote_get_thread_local_address)
9957 (remote_get_tib_address, remote_read_description): Refactor as
9958 methods of remote_target.
9959 (remote_target::fileio_open, remote_target::fileio_pwrite)
9960 (remote_target::fileio_pread, remote_target::fileio_close): New.
9961 (remote_hostio_readlink, remote_hostio_fstat)
9962 (remote_filesystem_is_local, remote_can_execute_reverse)
9963 (remote_supports_non_stop, remote_supports_disable_randomization)
9964 (remote_supports_multi_process, remote_supports_cond_breakpoints)
9965 (remote_supports_enable_disable_tracepoint)
9966 (remote_supports_string_tracing)
9967 (remote_can_run_breakpoint_commands, remote_trace_init)
9968 (remote_download_tracepoint, remote_can_download_tracepoint)
9969 (remote_download_trace_state_variable, remote_enable_tracepoint)
9970 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
9971 (remote_trace_start, remote_get_trace_status)
9972 (remote_get_tracepoint_status, remote_trace_stop)
9973 (remote_trace_find, remote_get_trace_state_variable_value)
9974 (remote_save_trace_data, remote_get_raw_trace_data)
9975 (remote_set_disconnected_tracing, remote_core_of_thread)
9976 (remote_set_circular_trace_buffer, remote_traceframe_info)
9977 (remote_get_min_fast_tracepoint_insn_len)
9978 (remote_set_trace_buffer_size, remote_set_trace_notes)
9979 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
9980 (remote_disable_btrace, remote_teardown_btrace)
9981 (remote_read_btrace, remote_btrace_conf)
9982 (remote_augmented_libraries_svr4_read, remote_load)
9983 (remote_pid_to_exec_file, remote_can_do_single_step)
9984 (remote_execution_direction, remote_thread_handle_to_thread_info):
9985 Refactor as methods of remote_target.
9986 (init_remote_ops, init_extended_remote_ops): Delete.
9987 (remote_can_async_p, remote_is_async_p, remote_async)
9988 (remote_thread_events, remote_upload_tracepoints)
9989 (remote_upload_trace_state_variables): Refactor as methods of
9991 (_initialize_remote): Remove references to init_remote_ops and
9992 init_extended_remote_ops.
9994 * remote-sim.c (gdbsim_target): New class.
9995 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
9996 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
9997 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
9998 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
9999 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
10000 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
10001 Refactor as methods of gdbsim_target.
10002 (gdbsim_ops): Now a gdbsim_target.
10003 (init_gdbsim_ops): Delete.
10004 (gdbsim_cntrl_c): Adjust.
10005 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
10007 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
10008 (the_amd64_linux_nat_target): New.
10009 (amd64_linux_fetch_inferior_registers)
10010 (amd64_linux_store_inferior_registers): Refactor as methods of
10011 amd64_linux_nat_target.
10012 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
10013 * i386-linux-nat.c: Don't include "linux-nat.h".
10014 (i386_linux_nat_target): New class.
10015 (the_i386_linux_nat_target): New.
10016 (i386_linux_fetch_inferior_registers)
10017 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
10018 as methods of i386_linux_nat_target.
10019 (_initialize_i386_linux_nat): Adjust. Set linux_target.
10020 * inf-child.c (inf_child_ops): Delete.
10021 (inf_child_fetch_inferior_registers)
10022 (inf_child_store_inferior_registers): Delete.
10023 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
10024 methods of inf_child_target.
10025 (inf_child_target::supports_terminal_ours)
10026 (inf_child_target::terminal_init)
10027 (inf_child_target::terminal_inferior)
10028 (inf_child_target::terminal_ours_for_output)
10029 (inf_child_target::terminal_ours, inf_child_target::interrupt)
10030 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
10032 (inf_child_open, inf_child_disconnect, inf_child_close)
10033 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
10034 (inf_child_post_startup_inferior, inf_child_can_run)
10035 (inf_child_pid_to_exec_file): Refactor as methods of
10037 (inf_child_follow_fork): Delete.
10038 (inf_child_target::can_create_inferior)
10039 (inf_child_target::can_attach): New.
10040 (inf_child_target::has_all_memory, inf_child_target::has_memory)
10041 (inf_child_target::has_stack, inf_child_target::has_registers)
10042 (inf_child_target::has_execution): New.
10043 (inf_child_fileio_open, inf_child_fileio_pwrite)
10044 (inf_child_fileio_pread, inf_child_fileio_fstat)
10045 (inf_child_fileio_close, inf_child_fileio_unlink)
10046 (inf_child_fileio_readlink, inf_child_use_agent)
10047 (inf_child_can_use_agent): Refactor as methods of
10049 (return_zero, inf_child_target): Delete.
10050 (inf_child_target::inf_child_target): New.
10051 * inf-child.h: Include "target.h".
10052 (inf_child_target): Delete function prototype.
10053 (inf_child_target): New class.
10054 (inf_child_open_target, inf_child_mourn_inferior)
10055 (inf_child_maybe_unpush_target): Delete.
10056 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
10057 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
10058 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
10059 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
10060 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
10061 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
10062 (inf_ptrace_wait, inf_ptrace_xfer_partial)
10063 (inf_ptrace_thread_alive, inf_ptrace_files_info)
10064 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
10065 methods of inf_ptrace_target.
10066 (inf_ptrace_target): Delete function.
10067 * inf-ptrace.h: Include "inf-child.h".
10068 (inf_ptrace_target): Delete function declaration.
10069 (inf_ptrace_target): New class.
10070 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
10071 * linux-nat.c (linux_target): New.
10072 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
10073 (linux_nat_target::~linux_nat_target): New.
10074 (linux_child_post_attach, linux_child_post_startup_inferior)
10075 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
10076 (linux_child_remove_fork_catchpoint)
10077 (linux_child_insert_vfork_catchpoint)
10078 (linux_child_remove_vfork_catchpoint)
10079 (linux_child_insert_exec_catchpoint)
10080 (linux_child_remove_exec_catchpoint)
10081 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
10082 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
10083 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
10084 (linux_nat_stopped_data_address)
10085 (linux_nat_stopped_by_sw_breakpoint)
10086 (linux_nat_supports_stopped_by_sw_breakpoint)
10087 (linux_nat_stopped_by_hw_breakpoint)
10088 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
10089 (linux_nat_kill, linux_nat_mourn_inferior)
10090 (linux_nat_xfer_partial, linux_nat_thread_alive)
10091 (linux_nat_update_thread_list, linux_nat_pid_to_str)
10092 (linux_nat_thread_name, linux_child_pid_to_exec_file)
10093 (linux_child_static_tracepoint_markers_by_strid)
10094 (linux_nat_is_async_p, linux_nat_can_async_p)
10095 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
10096 (linux_nat_supports_multi_process)
10097 (linux_nat_supports_disable_randomization, linux_nat_async)
10098 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
10099 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
10100 (linux_nat_fileio_open, linux_nat_fileio_readlink)
10101 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
10102 methods of linux_nat_target.
10103 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
10104 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
10106 (check_stopped_by_watchpoint): Adjust.
10107 (linux_xfer_partial): Delete.
10108 (linux_target_install_ops, linux_target, linux_nat_add_target):
10110 (linux_nat_target::linux_nat_target): New.
10111 * linux-nat.h: Include "inf-ptrace.h".
10112 (linux_nat_target): New.
10113 (linux_target, linux_target_install_ops, linux_nat_add_target):
10114 Delete function declarations.
10115 (linux_target): Declare global.
10116 * linux-thread-db.c (thread_db_target): New.
10117 (thread_db_target::thread_db_target): New.
10118 (thread_db_ops): Delete.
10119 (the_thread_db_target): New.
10120 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
10121 (thread_db_update_thread_list, thread_db_pid_to_str)
10122 (thread_db_extra_thread_info)
10123 (thread_db_thread_handle_to_thread_info)
10124 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
10125 (thread_db_resume): Refactor as methods of thread_db_target.
10126 (init_thread_db_ops): Delete.
10127 (_initialize_thread_db): Remove reference to init_thread_db_ops.
10128 * x86-linux-nat.c: Don't include "linux-nat.h".
10129 (super_post_startup_inferior): Delete.
10130 (x86_linux_nat_target::~x86_linux_nat_target): New.
10131 (x86_linux_child_post_startup_inferior)
10132 (x86_linux_read_description, x86_linux_enable_btrace)
10133 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
10134 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
10135 methods of x86_linux_nat_target.
10136 (x86_linux_create_target): Delete. Bits folded ...
10137 (x86_linux_add_target): ... here. Now takes a linux_nat_target
10139 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
10140 (x86_linux_nat_target): New class.
10141 (x86_linux_create_target): Delete.
10142 (x86_linux_add_target): Now takes a linux_nat_target pointer.
10143 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
10144 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
10145 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
10146 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
10147 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
10149 (x86_use_watchpoints): Delete.
10150 * x86-nat.h: Include "breakpoint.h" and "target.h".
10151 (x86_use_watchpoints): Delete.
10152 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
10153 (x86_stopped_by_watchpoint, x86_stopped_data_address)
10154 (x86_insert_watchpoint, x86_remove_watchpoint)
10155 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
10156 (x86_stopped_by_hw_breakpoint): New declarations.
10157 (x86_nat_target): New template class.
10159 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
10160 (the_ppc_linux_nat_target): New.
10161 (ppc_linux_fetch_inferior_registers)
10162 (ppc_linux_can_use_hw_breakpoint)
10163 (ppc_linux_region_ok_for_hw_watchpoint)
10164 (ppc_linux_ranged_break_num_registers)
10165 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
10166 (ppc_linux_insert_mask_watchpoint)
10167 (ppc_linux_remove_mask_watchpoint)
10168 (ppc_linux_can_accel_watchpoint_condition)
10169 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
10170 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
10171 (ppc_linux_watchpoint_addr_within_range)
10172 (ppc_linux_masked_watch_num_registers)
10173 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
10174 (ppc_linux_read_description): Refactor as methods of
10175 ppc_linux_nat_target.
10176 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
10178 * procfs.c (procfs_xfer_partial): Delete forward declaration.
10179 (procfs_target): New class.
10180 (the_procfs_target): New.
10181 (procfs_target): Delete function.
10182 (procfs_auxv_parse, procfs_attach, procfs_detach)
10183 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
10184 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
10185 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
10186 (procfs_create_inferior, procfs_update_thread_list)
10187 (procfs_thread_alive, procfs_pid_to_str)
10188 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
10189 (procfs_stopped_data_address, procfs_insert_watchpoint)
10190 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
10191 (proc_find_memory_regions, procfs_info_proc)
10192 (procfs_make_note_section): Refactor as methods of procfs_target.
10193 (_initialize_procfs): Adjust.
10194 * sol-thread.c (sol_thread_target): New class.
10195 (sol_thread_ops): Now a sol_thread_target.
10196 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
10197 (sol_thread_fetch_registers, sol_thread_store_registers)
10198 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
10199 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
10200 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
10201 (init_sol_thread_ops): Delete.
10202 (_initialize_sol_thread): Adjust. Remove references to
10203 init_sol_thread_ops and complete_target_initialization.
10205 * windows-nat.c (windows_nat_target): New class.
10206 (windows_fetch_inferior_registers)
10207 (windows_store_inferior_registers, windows_resume, windows_wait)
10208 (windows_attach, windows_detach, windows_pid_to_exec_file)
10209 (windows_files_info, windows_create_inferior)
10210 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
10211 (windows_close, windows_pid_to_str, windows_xfer_partial)
10212 (windows_get_tib_address, windows_get_ada_task_ptid)
10213 (windows_thread_name, windows_thread_alive): Refactor as
10214 windows_nat_target methods.
10215 (do_initial_windows_stuff): Adjust.
10216 (windows_target): Delete function.
10217 (_initialize_windows_nat): Adjust.
10219 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
10220 (darwin_mourn_inferior, darwin_kill_inferior)
10221 (darwin_create_inferior, darwin_attach, darwin_detach)
10222 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
10223 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
10224 (darwin_supports_multi_process): Refactor as darwin_nat_target
10226 (darwin_resume_to, darwin_files_info): Delete.
10227 (_initialize_darwin_inferior): Rename to ...
10228 (_initialize_darwin_nat): ... this. Adjust to C++ification.
10229 * darwin-nat.h: Include "inf-child.h".
10230 (darwin_nat_target): New class.
10231 (darwin_complete_target): Delete.
10232 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
10233 (darwin_target): New.
10234 (i386_darwin_fetch_inferior_registers)
10235 (i386_darwin_store_inferior_registers): Refactor as methods of
10237 (darwin_complete_target): Delete, with ...
10238 (_initialize_i386_darwin_nat): ... bits factored out here.
10240 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
10241 (the_alpha_linux_nat_target): New.
10242 (alpha_linux_register_u_offset): Refactor as
10243 alpha_linux_nat_target method.
10244 (_initialize_alpha_linux_nat): Adjust.
10245 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
10246 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
10247 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
10248 methods of linux_nat_trad_target.
10249 (linux_trad_target): Delete.
10250 * linux-nat-trad.h (linux_trad_target): Delete function.
10251 (linux_nat_trad_target): New class.
10252 * mips-linux-nat.c (mips_linux_nat_target): New class.
10253 (super_fetch_registers, super_store_registers, super_close):
10255 (the_mips_linux_nat_target): New.
10256 (mips64_linux_regsets_fetch_registers)
10257 (mips64_linux_regsets_store_registers)
10258 (mips64_linux_fetch_registers, mips64_linux_store_registers)
10259 (mips_linux_register_u_offset, mips_linux_read_description)
10260 (mips_linux_can_use_hw_breakpoint)
10261 (mips_linux_stopped_by_watchpoint)
10262 (mips_linux_stopped_data_address)
10263 (mips_linux_region_ok_for_hw_watchpoint)
10264 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
10265 (mips_linux_close): Refactor as methods of mips_linux_nat.
10266 (_initialize_mips_linux_nat): Adjust to C++ification.
10268 * aix-thread.c (aix_thread_target): New class.
10269 (aix_thread_ops): Now an aix_thread_target.
10270 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
10271 (aix_thread_fetch_registers, aix_thread_store_registers)
10272 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
10273 (aix_thread_thread_alive, aix_thread_pid_to_str)
10274 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
10275 Refactor as methods of aix_thread_target.
10276 (init_aix_thread_ops): Delete.
10277 (_initialize_aix_thread): Remove references to init_aix_thread_ops
10278 and complete_target_initialization.
10279 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
10280 (rs6000_nat_target): New class.
10281 (the_rs6000_nat_target): New.
10282 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
10283 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
10284 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
10285 (super_create_inferior): Delete.
10286 (_initialize_rs6000_nat): Adjust to C++ification.
10288 * arm-linux-nat.c (arm_linux_nat_target): New class.
10289 (the_arm_linux_nat_target): New.
10290 (arm_linux_fetch_inferior_registers)
10291 (arm_linux_store_inferior_registers, arm_linux_read_description)
10292 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
10293 (arm_linux_remove_hw_breakpoint)
10294 (arm_linux_region_ok_for_hw_watchpoint)
10295 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
10296 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
10297 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
10298 arm_linux_nat_target.
10299 (_initialize_arm_linux_nat): Adjust to C++ification.
10301 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
10302 (the_aarch64_linux_nat_target): New.
10303 (aarch64_linux_fetch_inferior_registers)
10304 (aarch64_linux_store_inferior_registers)
10305 (aarch64_linux_child_post_startup_inferior)
10306 (aarch64_linux_read_description)
10307 (aarch64_linux_can_use_hw_breakpoint)
10308 (aarch64_linux_insert_hw_breakpoint)
10309 (aarch64_linux_remove_hw_breakpoint)
10310 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
10311 (aarch64_linux_region_ok_for_hw_watchpoint)
10312 (aarch64_linux_stopped_data_address)
10313 (aarch64_linux_stopped_by_watchpoint)
10314 (aarch64_linux_watchpoint_addr_within_range)
10315 (aarch64_linux_can_do_single_step): Refactor as methods of
10316 aarch64_linux_nat_target.
10317 (super_post_startup_inferior): Delete.
10318 (_initialize_aarch64_linux_nat): Adjust to C++ification.
10320 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
10321 (the_hppa_linux_nat_target): New.
10322 (hppa_linux_fetch_inferior_registers)
10323 (hppa_linux_store_inferior_registers): Refactor as methods of
10324 hppa_linux_nat_target.
10325 (_initialize_hppa_linux_nat): Adjust to C++ification.
10327 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
10328 (the_ia64_linux_nat_target): New.
10329 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
10330 (ia64_linux_stopped_data_address)
10331 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
10332 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
10333 ia64_linux_nat_target methods.
10334 (super_xfer_partial): Delete.
10335 (_initialize_ia64_linux_nat): Adjust to C++ification.
10337 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
10338 (the_m32r_linux_nat_target): New.
10339 (m32r_linux_fetch_inferior_registers)
10340 (m32r_linux_store_inferior_registers): Refactor as
10341 m32r_linux_nat_target methods.
10342 (_initialize_m32r_linux_nat): Adjust to C++ification.
10344 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
10345 (the_m68k_linux_nat_target): New.
10346 (m68k_linux_fetch_inferior_registers)
10347 (m68k_linux_store_inferior_registers): Refactor as
10348 m68k_linux_nat_target methods.
10349 (_initialize_m68k_linux_nat): Adjust to C++ification.
10351 * s390-linux-nat.c (s390_linux_nat_target): New class.
10352 (the_s390_linux_nat_target): New.
10353 (s390_linux_fetch_inferior_registers)
10354 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
10355 (s390_insert_watchpoint, s390_remove_watchpoint)
10356 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
10357 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
10358 (s390_auxv_parse, s390_read_description): Refactor as methods of
10359 s390_linux_nat_target.
10360 (_initialize_s390_nat): Adjust to C++ification.
10362 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
10363 (the_sparc_linux_nat_target): New.
10364 (_initialize_sparc_linux_nat): Adjust to C++ification.
10365 * sparc-nat.c (sparc_fetch_inferior_registers)
10366 (sparc_store_inferior_registers): Remove target_ops parameter.
10367 * sparc-nat.h (sparc_fetch_inferior_registers)
10368 (sparc_store_inferior_registers): Remove target_ops parameter.
10369 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
10370 (the_sparc64_linux_nat_target): New.
10371 (_initialize_sparc64_linux_nat): Adjust to C++ification.
10373 * spu-linux-nat.c (spu_linux_nat_target): New class.
10374 (the_spu_linux_nat_target): New.
10375 (spu_child_post_startup_inferior, spu_child_post_attach)
10376 (spu_child_wait, spu_fetch_inferior_registers)
10377 (spu_store_inferior_registers, spu_xfer_partial)
10378 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
10380 (_initialize_spu_nat): Adjust to C++ification.
10382 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
10383 (the_tilegx_linux_nat_target): New.
10384 (fetch_inferior_registers, store_inferior_registers):
10385 Refactor as methods.
10386 (_initialize_tile_linux_nat): Adjust to C++ification.
10388 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
10389 (the_xtensa_linux_nat_target): New.
10390 (xtensa_linux_fetch_inferior_registers)
10391 (xtensa_linux_store_inferior_registers): Refactor as
10392 xtensa_linux_nat_target methods.
10393 (_initialize_xtensa_linux_nat): Adjust to C++ification.
10395 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
10396 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
10397 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
10398 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
10399 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
10400 (fbsd_stopped_by_sw_breakpoint)
10401 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
10402 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
10403 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
10404 (fbsd_post_startup_inferior, fbsd_post_attach)
10405 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
10406 (fbsd_set_syscall_catchpoint)
10407 (super_xfer_partial, super_resume, super_wait)
10408 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
10409 (fbsd_handle_debug_trap): Remove target_ops parameter.
10410 (fbsd_nat_add_target): Delete.
10411 * fbsd-nat.h: Include "inf-ptrace.h".
10412 (fbsd_nat_add_target): Delete.
10413 (USE_SIGTRAP_SIGINFO): Define.
10414 (fbsd_nat_target): New class.
10416 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
10417 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
10418 (amd64bsd_target): Delete.
10419 * amd64-bsd-nat.h: New file.
10420 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
10422 (amd64_fbsd_nat_target): New class.
10423 (the_amd64_fbsd_nat_target): New.
10424 (amd64fbsd_read_description): Refactor as method of
10425 amd64_fbsd_nat_target.
10426 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
10427 (_initialize_amd64fbsd_nat): Adjust to C++ification.
10428 * amd64-nat.h (amd64bsd_target): Delete function declaration.
10429 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
10430 (i386bsd_store_inferior_registers): Remove target_ops parameter.
10431 (i386bsd_target): Delete.
10432 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
10433 (i386bsd_fetch_inferior_registers)
10434 (i386bsd_store_inferior_registers): Declare.
10435 (i386_bsd_nat_target): New class.
10436 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
10437 (the_i386_fbsd_nat_target): New.
10438 (i386fbsd_resume, i386fbsd_read_description): Refactor as
10439 i386_fbsd_nat_target methods.
10440 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
10441 (_initialize_i386fbsd_nat): Adjust to C++ification.
10442 * x86-bsd-nat.c (super_mourn_inferior): Delete.
10443 (x86bsd_mourn_inferior, x86bsd_target): Delete.
10444 (_initialize_x86_bsd_nat): Adjust to C++ification.
10445 * x86-bsd-nat.h: Include "x86-nat.h".
10446 (x86bsd_target): Delete declaration.
10447 (x86bsd_nat_target): New class.
10449 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
10450 (the_aarch64_fbsd_nat_target): New.
10451 (aarch64_fbsd_fetch_inferior_registers)
10452 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
10453 aarch64_fbsd_nat_target.
10454 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
10455 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
10456 (the_alpha_bsd_nat_target): New.
10457 (alphabsd_fetch_inferior_registers)
10458 (alphabsd_store_inferior_registers): Refactor as
10459 alpha_bsd_nat_target methods.
10460 (_initialize_alphabsd_nat): Refactor as methods of
10461 alpha_bsd_nat_target.
10462 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
10463 (the_amd64_nbsd_nat_target): New.
10464 (_initialize_amd64nbsd_nat): Adjust to C++ification.
10465 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
10466 (the_amd64_obsd_nat_target): New.
10467 (_initialize_amd64obsd_nat): Adjust to C++ification.
10468 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
10469 (the_arm_fbsd_nat_target): New.
10470 (arm_fbsd_fetch_inferior_registers)
10471 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
10472 (_initialize_arm_fbsd_nat): Refactor as methods of
10473 arm_fbsd_nat_target.
10474 (_initialize_arm_fbsd_nat): Adjust to C++ification.
10475 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
10476 (the_arm_netbsd_nat_target): New.
10477 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
10478 arm_netbsd_nat_target.
10479 (_initialize_arm_netbsd_nat): Adjust to C++ification.
10480 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
10481 (the_hppa_nbsd_nat_target): New.
10482 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
10483 hppa_nbsd_nat_target methods.
10484 (_initialize_hppanbsd_nat): Adjust to C++ification.
10485 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
10486 (the_hppa_obsd_nat_target): New.
10487 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
10488 methods of hppa_obsd_nat_target.
10489 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
10491 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
10492 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
10494 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
10495 (_initialize_i386obsd_nat): Use add_target.
10496 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
10497 (the_m68k_bsd_nat_target): New.
10498 (m68kbsd_fetch_inferior_registers)
10499 (m68kbsd_store_inferior_registers): Refactor as methods of
10500 m68k_bsd_nat_target.
10501 (_initialize_m68kbsd_nat): Adjust to C++ification.
10502 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
10503 (the_mips_fbsd_nat_target): New.
10504 (mips_fbsd_fetch_inferior_registers)
10505 (mips_fbsd_store_inferior_registers): Refactor as methods of
10506 mips_fbsd_nat_target.
10507 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
10509 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
10510 (the_mips_nbsd_nat_target): New.
10511 (mipsnbsd_fetch_inferior_registers)
10512 (mipsnbsd_store_inferior_registers): Refactor as methods of
10513 mips_nbsd_nat_target.
10514 (_initialize_mipsnbsd_nat): Adjust to C++ification.
10515 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
10516 (the_mips64_obsd_nat_target): New.
10517 (mips64obsd_fetch_inferior_registers)
10518 (mips64obsd_store_inferior_registers): Refactor as methods of
10519 mips64_obsd_nat_target.
10520 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
10522 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
10524 * nbsd-nat.h: Include "inf-ptrace.h".
10525 (nbsd_nat_target): New class.
10526 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
10527 (obsd_wait): Refactor as methods of obsd_nat_target.
10528 (obsd_add_target): Delete.
10529 * obsd-nat.h: Include "inf-ptrace.h".
10530 (obsd_nat_target): New class.
10531 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
10532 (the_ppc_fbsd_nat_target): New.
10533 (ppcfbsd_fetch_inferior_registers)
10534 (ppcfbsd_store_inferior_registers): Refactor as methods of
10535 ppc_fbsd_nat_target.
10536 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
10538 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
10539 (the_ppc_nbsd_nat_target): New.
10540 (ppcnbsd_fetch_inferior_registers)
10541 (ppcnbsd_store_inferior_registers): Refactor as methods of
10542 ppc_nbsd_nat_target.
10543 (_initialize_ppcnbsd_nat): Adjust to C++ification.
10544 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
10545 (the_ppc_obsd_nat_target): New.
10546 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
10547 methods of ppc_obsd_nat_target.
10548 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
10550 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
10551 (the_sh_nbsd_nat_target): New.
10552 (shnbsd_fetch_inferior_registers)
10553 (shnbsd_store_inferior_registers): Refactor as methods of
10554 sh_nbsd_nat_target.
10555 (_initialize_shnbsd_nat): Adjust to C++ification.
10556 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
10557 (inf_ptrace_xfer_partial): Delete.
10558 (sparc_xfer_partial, sparc_target): Delete.
10559 * sparc-nat.h (sparc_fetch_inferior_registers)
10560 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
10561 (sparc_target): Delete function declaration.
10562 (sparc_target): New template class.
10563 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
10564 (_initialize_sparcnbsd_nat): Adjust to C++ification.
10565 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
10566 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
10568 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
10569 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
10570 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
10571 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
10573 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
10574 (the_vax_bsd_nat_target): New.
10575 (vaxbsd_fetch_inferior_registers)
10576 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
10578 (_initialize_vaxbsd_nat): Adjust to C++ification.
10580 * bsd-kvm.c (bsd_kvm_target): New class.
10581 (bsd_kvm_ops): Now a bsd_kvm_target.
10582 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
10583 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
10584 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
10586 (bsd_kvm_return_one): Delete.
10587 (bsd_kvm_add_target): Adjust to C++ification.
10589 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
10590 (nto_procfs_target_procfs): New classes.
10591 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
10592 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
10593 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
10594 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
10595 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
10596 (procfs_remove_hw_breakpoint, procfs_resume)
10597 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
10598 (procfs_kill_inferior, procfs_store_registers)
10599 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
10600 as methods of nto_procfs_target.
10601 (nto_procfs_ops): Now an nto_procfs_target_procfs.
10602 (nto_native_ops): Delete.
10603 (procfs_open, procfs_native_open): Delete.
10604 (nto_native_ops): Now an nto_procfs_target_native.
10605 (init_procfs_targets): Adjust to C++ification.
10606 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
10607 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
10608 Refactor as methods of nto_procfs_target.
10610 * go32-nat.c (go32_nat_target): New class.
10611 (the_go32_nat_target): New.
10612 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
10613 (go32_store_registers, go32_xfer_partial, go32_files_info)
10614 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
10615 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
10616 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
10617 (go32_pid_to_str): Refactor as methods of go32_nat_target.
10618 (go32_target): Delete.
10619 (_initialize_go32_nat): Adjust to C++ification.
10621 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
10622 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
10623 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
10624 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
10626 (gnu_target): Delete.
10627 * gnu-nat.h (gnu_target): Delete.
10628 (gnu_nat_target): New class.
10629 * i386-gnu-nat.c (gnu_base_target): New.
10630 (i386_gnu_nat_target): New class.
10631 (the_i386_gnu_nat_target): New.
10632 (_initialize_i386gnu_nat): Adjust to C++ification.
10634 2018-05-02 Pedro Alves <palves@redhat.com>
10636 * bfd-target.c (target_bfd_xclose): Rename to ...
10637 (target_bfd_close): ... this.
10638 (target_bfd_reopen): Adjust.
10639 * target.c (target_close): Remove references to to_xclose.
10640 * target.h (target_ops::to_xclose): Delete.
10641 (target_ops::to_close): Update comments.
10643 2018-05-02 Pedro Alves <palves@redhat.com>
10645 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
10647 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
10648 * inf-ptrace.c (inf_ptrace_register_u_offset)
10649 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
10650 (inf_ptrace_store_register, inf_ptrace_store_registers)
10651 (inf_ptrace_trad_target): Move to ...
10652 * linux-nat-trad.c: ... this new file.
10653 * linux-nat-trad.h: New file.
10654 * linux-nat.c (linux_target_install_ops): Make extern.
10655 (linux_trad_target): Delete.
10656 * linux-nat.h (linux_trad_target): Delete declaration.
10657 (linux_target_install_ops): Declare.
10658 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
10661 2018-05-02 Pedro Alves <palves@redhat.com>
10663 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
10664 procfs_target/add_target here.
10665 * procfs.c (procfs_target): Make static.
10666 (_initialize_procfs): Call add_target here.
10667 * procfs.h (struct target_ops): Remove forward declaration.
10668 (procfs_target): Remove declaration.
10669 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
10671 2018-05-02 Pedro Alves <palves@redhat.com>
10673 * procfs.c (procfs_stopped_by_watchpoint)
10674 (procfs_insert_watchpoint, procfs_remove_watchpoint)
10675 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
10677 (procfs_use_watchpoints): Delete, move contents...
10678 (procfs_target): ... here.
10679 * procfs.h (procfs_use_watchpoints): Delete declaration.
10680 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
10681 procfs_use_watchpoints.
10682 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
10683 procfs_use_watchpoints.
10685 2018-05-02 Tom Tromey <tom@tromey.com>
10688 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
10689 and var_zuinteger_unlimited.
10690 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
10691 and PARAM_ZUINTEGER_UNLIMITED.
10692 (set_parameter_value): Handle var_zuinteger and
10693 var_zuinteger_unlimited.
10694 (add_setshow_generic): Likewise.
10695 (parmpy_init): Likewise.
10697 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
10700 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
10701 pointer is not null before dereferencing it.
10703 2018-04-30 Tom Tromey <tom@tromey.com>
10705 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
10708 2018-04-30 Tom Tromey <tom@tromey.com>
10710 * breakpoint.c (mention): Remove use of is_mi_like_p.
10711 (print_mention_ranged_breakpoint): Likewise.
10712 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
10715 2018-04-30 Tom Tromey <tom@tromey.com>
10717 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
10719 2018-04-30 Tom Tromey <tom@tromey.com>
10721 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
10722 (info_spu_event_command): Remove some uses of is_mi_like_p.
10724 2018-04-30 Tom Tromey <tom@tromey.com>
10726 * python/py-framefilter.c (py_print_single_arg)
10727 (enumerate_locals, py_print_args, py_print_frame): Remove some
10728 uses of is_mi_like_p.
10730 2018-04-30 Tom Tromey <tom@tromey.com>
10732 * ui-out.c: Update.
10733 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
10734 * ui-out.h (ui_out::is_mi_like_p): Now const.
10735 (ui_out::do_is_mi_like_p): Now const.
10736 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
10738 2018-04-30 Tom Tromey <tom@tromey.com>
10740 * varobj.c (varobj_set_visualizer): Use new_reference.
10741 * python/python.c (gdbpy_decode_line): Use new_reference.
10742 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
10745 2018-04-30 Tom Tromey <tom@tromey.com>
10747 * varobj.c (install_new_value): Use new_reference.
10748 * value.h (value_incref): Return void. Swap intro comment with
10750 * value.c (set_value_parent): Use new_reference.
10751 (value_incref): Return void. Update intro comment.
10752 (release_value): Use new_reference.
10753 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
10755 2018-04-30 Tom Tromey <tom@tromey.com>
10757 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
10758 * gdb_bfd.h (new_bfd_ref): Remove.
10759 (gdb_bfd_open): Update comment.
10760 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
10761 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
10762 (gdb_bfd_fdopenr): Use new_reference.
10763 * exec.c (exec_file_attach): Use new_reference.
10765 2018-04-30 Tom Tromey <tom@tromey.com>
10767 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
10770 2018-04-30 Tom Tromey <tom@tromey.com>
10772 * jit.c (jit_read_code_entry): Use type_align.
10773 * i386-tdep.c (i386_gdbarch_init): Don't call
10774 set_gdbarch_long_long_align_bit.
10775 * gdbarch.sh: Remove long_long_align_bit.
10776 * gdbarch.c, gdbarch.h: Rebuild.
10777 * arc-tdep.c (arc_type_align): New function.
10778 (arc_gdbarch_init): Use arc_type_align. Don't call
10779 set_gdbarch_long_long_align_bit.
10781 2018-04-30 Tom Tromey <tom@tromey.com>
10783 * rust-lang.c (rust_type_alignment): Remove.
10784 (rust_composite_type): Use type_align.
10786 2018-04-30 Tom Tromey <tom@tromey.com>
10788 * NEWS: Mention Type.align.
10789 * python/py-type.c (typy_get_alignof): New function.
10790 (type_object_getset): Add "alignof".
10792 2018-04-30 Tom Tromey <tom@tromey.com>
10796 * std-operator.def (UNOP_ALIGNOF): New operator.
10797 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
10799 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
10800 * c-lang.c (c_op_print_tab): Add alignof.
10801 * c-exp.y (ALIGNOF): New token.
10802 (exp): Add "ALIGNOF" production.
10803 (ident_tokens): Add _Alignof and alignof.
10805 2018-04-30 Tom Tromey <tom@tromey.com>
10807 * i386-tdep.c (i386_type_align): New function.
10808 (i386_gdbarch_init): Update.
10809 * gdbarch.sh (type_align): New method.
10810 * gdbarch.c, gdbarch.h: Rebuild.
10811 * arch-utils.h (default_type_align): Declare.
10812 * arch-utils.c (default_type_align): New function.
10813 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
10814 (struct type) <align_log2>: New field.
10815 <instance_flags>: Now a bitfield.
10816 (TYPE_RAW_ALIGN): New macro.
10817 (type_align, type_raw_align, set_type_align): Declare.
10818 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
10820 * dwarf2read.c (quirk_rust_enum): Set type alignment.
10821 (get_alignment, maybe_set_alignment): New functions.
10822 (read_structure_type, read_enumeration_type, read_array_type)
10823 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
10824 (read_subrange_type, read_base_type): Set type alignment.
10826 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
10828 * dwarf2read.c (read_index_from_section): Use bool.
10830 2018-04-29 Fabian Groffen <grobian@gentoo.org>
10833 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
10836 2018-04-29 John Reiser <jreiser@BitWagon.com>
10839 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
10840 last step, and do it atomically.
10842 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
10844 * compile/compile-c-types.c (convert_int, convert_float):
10845 Update for C FE v1.
10847 2018-04-27 Tom Tromey <tom@tromey.com>
10850 * rust-lang.c (rust_inclusive_range_type_p): New function.
10851 (rust_range): Handle inclusive ranges.
10852 (rust_compute_range): Likewise.
10853 * rust-exp.y (struct rust_op) <inclusive>: New field.
10854 (DOTDOTEQ): New constant.
10855 (range_expr): Add "..=" productions.
10856 (operator_tokens): Add "..=" token.
10857 (ast_range): Add "inclusive" parameter.
10858 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
10860 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
10862 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
10863 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
10865 * expprint.c (print_subexp_standard): Handle new bounds values.
10866 (dump_subexp_body_standard): Likewise.
10868 2018-04-27 Tom Tromey <tom@tromey.com>
10870 * configure: Rebuild.
10871 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
10872 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
10874 (class symbol_needs_eval_context): Likewise.
10875 * dwarf2read.c (mock_mapped_index::symbol_name_count)
10876 (mock_mapped_index::symbol_name_at): Use "override". Remove
10878 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
10880 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
10881 * aarch64-tdep.c (instruction_reader::read): Use "override".
10882 (instruction_reader_test::read): Likewise.
10883 * arm-tdep.c (instruction_reader::read): Use "override".
10884 (instruction_reader_thumb::read): Likewise.
10886 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
10889 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
10890 instead of remote_send.
10891 (remote_send): Remove.
10893 2018-04-26 Pedro Alves <palves@redhat.com>
10895 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
10896 find_function_start_sal instead of find_pc_line.
10898 2018-04-26 Pedro Alves <palves@redhat.com>
10900 * breakpoint.c (set_breakpoint_location_function): Handle
10901 mst_data_gnu_ifunc.
10902 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
10903 * elfread.c (elf_symtab_read): Give data symbols with
10904 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
10905 (elf_rel_plt_read): Update comment.
10906 * linespec.c (convert_linespec_to_sals): Handle
10907 mst_data_gnu_ifunc.
10908 (minsym_found): Handle mst_data_gnu_ifunc.
10909 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
10910 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
10911 * parse.c (find_minsym_type_and_address): Handle
10912 mst_data_gnu_ifunc.
10913 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
10914 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
10915 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
10917 <mst_data_gnu_ifunc>: New enumerator.
10919 2018-04-26 Pedro Alves <palves@redhat.com>
10921 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
10922 (lookup_minimal_symbol_by_pc_section): ... this. Replace
10923 'want_trampoline' parameter by a lookup_msym_prefer parameter.
10925 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
10926 (lookup_minimal_symbol_by_pc): Adjust.
10927 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
10928 (lookup_solib_trampoline_symbol_by_pc): Adjust.
10929 * minsyms.h (lookup_msym_prefer): New enum.
10930 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10931 parameter by a lookup_msym_prefer parameter.
10933 2018-04-26 Pedro Alves <palves@redhat.com>
10935 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
10936 ends in "@plt" instead of looking at the symbol's section.
10938 2018-04-26 Pedro Alves <palves@redhat.com>
10940 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
10942 (find_pc_partial_function_gnu_ifunc): Rename to ...
10943 (find_pc_partial_function): ... this, and remove references to
10945 (find_pc_partial_function): Delete old implementation.
10946 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
10948 2018-04-26 Pedro Alves <palves@redhat.com>
10950 * linespec.c (struct bound_minimal_symbol_search_key): New.
10951 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
10952 skip first line if we found a GNU ifunc minimal symbol by name.
10953 (compare_msymbols): Change parameters to work with a destructured
10955 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
10958 2018-04-26 Pedro Alves <palves@redhat.com>
10960 * breakpoint.c (set_breakpoint_location_function): Don't resolve
10961 ifunc targets here. Instead, if we have an ifunc minsym, use its
10963 (add_location_to_breakpoint): Store the minsym and the objfile in
10964 the breakpoint location.
10965 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
10966 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
10967 Record the minsym in the sal.
10968 * symtab.h (symtab_and_line) <msymbol>: New field.
10970 2018-04-26 Pedro Alves <palves@redhat.com>
10972 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
10973 unless we actually resolved the ifunc.
10975 2018-04-26 Pedro Alves <palves@redhat.com>
10977 * c-exp.y (variable production): Prefer ifunc minsyms over
10978 regular function symbols.
10979 * symtab.c (find_gnu_ifunc): New function.
10980 * minsyms.h (lookup_msym_prefer): New enum.
10981 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10982 parameter by a lookup_msym_prefer parameter.
10983 * symtab.h (find_gnu_ifunc): New declaration.
10985 2018-04-26 Pedro Alves <palves@redhat.com>
10987 * blockframe.c (find_gnu_ifunc_target_type): New function.
10988 (find_function_type): New.
10989 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
10990 return a value with a memory address.
10991 (eval_call): For calls to GNU ifunc functions, try to find the
10992 type of the target function from the type that the resolver
10994 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
10996 * infcall.c (find_function_return_type): Delete.
10997 (find_function_addr): Add 'function_type' parameter. For calls to
10998 GNU ifunc functions, try to find the type of the target function
10999 from the type that the resolver returns, and return it via
11001 (call_function_by_hand_dummy): Adjust to use the function type
11002 returned by find_function_addr.
11003 (find_function_addr): Add 'function_type' parameter and move
11005 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
11008 2018-04-26 Pedro Alves <palves@redhat.com>
11010 * c-exp.y (variable production): Skip finding an alias for ifunc
11013 2018-04-26 Pedro Alves <palves@redhat.com>
11015 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
11017 2018-04-25 Pedro Alves <palves@redhat.com>
11019 * infcmd.c (kill_command): Print the pid as string, not the whole
11020 thread's ptid. Add comment. s/has been killed/killed/ in output
11022 * remote.c (remote_detach_1): Print the pid as string, not the
11023 whole thread's ptid.
11025 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11026 Sergio Durigan Junior <sergiodj@redhat.com>
11027 Pedro Alves <palves@redhat.com>
11029 * infcmd.c (kill_command): Print message when inferior has
11031 * inferior.c (print_inferior_events): Remove 'static'. Set as
11033 (add_inferior): Improve message printed when
11034 'print_inferior_events' is on.
11035 (exit_inferior): Remove message printed when
11036 'print_inferior_events' is on.
11037 (detach_inferior): Improve message printed when
11038 'print_inferior_events' is on.
11039 (initialize_inferiors): Use 'add_inferior_silent' to set
11040 'current_inferior_'.
11041 * inferior.h (print_inferior_events): Declare here as
11043 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
11044 '[Detaching...]' messages when 'print_inferior_events' is on.
11045 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
11046 as prefix/suffix for messages. Remove periods. Fix erroneous
11047 'Detaching after fork from child...', replace it by '... from
11049 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
11050 prefix/suffix when printing 'Detaching...' messages. Print
11051 them when 'print_inferior_events' is on.
11052 * remote.c (remote_detach_1): Print message when detaching
11053 from inferior and '!is_fork_parent'.
11055 2018-04-24 Tom Tromey <tom@tromey.com>
11057 * cli-out.h: Reindent.
11059 2018-04-24 Tom Tromey <tom@tromey.com>
11061 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
11062 (cli_ui_out::do_field_string): Use fputs_filtered.
11063 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
11065 2018-04-23 Tom Tromey <tom@tromey.com>
11067 * guile/scm-frame.c (gdbscm_frame_read_var): Use
11068 gdb::unique_xmalloc_ptr.
11070 2018-04-23 Tom Tromey <tom@tromey.com>
11072 * configure: Rebuild.
11074 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
11077 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
11078 prepare_for_testing. Set normal_bp to r_debug_state if target
11081 2018-04-21 Pedro Alves <palves@redhat.com>
11082 Rajendra SY <rajendra.sy@gmail.com>
11084 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
11085 * remote.c (extended_remote_attach): In all-stop mode, mark the
11086 thread as executing.
11088 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
11090 * thread.c (thread_apply_all_command): Fix comment.
11091 (thread_command): Fix comment.
11093 2018-04-10 Alan Hayward <alan.hayward@arm.com>
11095 * common/tdesc.h (tdesc_create_feature): Remove xml filename
11097 * features/aarch64-core.c (create_feature_aarch64_core):
11099 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
11101 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
11103 * features/i386/32bit-avx512.c
11104 (create_feature_i386_32bit_avx512): Likewise.
11105 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
11107 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
11109 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
11111 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
11113 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
11115 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
11117 * features/i386/64bit-avx512.c
11118 (create_feature_i386_64bit_avx512): Likewise.
11119 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
11121 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
11123 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
11125 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
11127 * features/i386/64bit-segments.c
11128 (create_feature_i386_64bit_segments): Likewise.
11129 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
11131 * features/i386/x32-core.c
11132 (create_feature_i386_x32_core): Likewise.
11133 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
11134 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
11135 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
11136 * target-descriptions.c: In generated code, don't pass xml
11139 2018-04-18 Alan Hayward <alan.hayward@arm.com>
11141 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
11142 (print_xml_feature::visit_post): Likewise.
11143 (print_xml_feature::visit): Likewise.
11144 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
11145 (print_xml_feature): Add new class.
11146 * regformats/regdat.sh: Null xmltarget on feature targets.
11147 * target-descriptions.c (struct target_desc): Add xmltarget.
11148 (maintenance_check_tdesc_xml_convert): Add unittest function.
11149 (tdesc_get_features_xml): Add function to get xml.
11150 (maintenance_check_xml_descriptions): Test xml generation.
11151 * xml-tdesc.c (string_read_description_xml): Add function.
11152 * xml-tdesc.h (string_read_description_xml): Add declaration.
11154 2018-04-18 Alan Hayward <alan.hayward@arm.com>
11156 * features/Makefile: Add feature marker to targets with new style
11157 target descriptions.
11158 * regformats/aarch64.dat: Regenerate.
11159 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
11160 * regformats/i386/amd64-avx-linux.dat: Likewise.
11161 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
11162 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
11163 * regformats/i386/amd64-linux.dat: Likewise.
11164 * regformats/i386/amd64-mpx-linux.dat: Likewise.
11165 * regformats/i386/amd64.dat: Likewise.
11166 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
11167 * regformats/i386/i386-avx-linux.dat: Likewise.
11168 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
11169 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
11170 * regformats/i386/i386-linux.dat: Likewise.
11171 * regformats/i386/i386-mmx-linux.dat: Likewise.
11172 * regformats/i386/i386-mpx-linux.dat: Likewise.
11173 * regformats/i386/i386.dat: Likewise.
11174 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
11175 * regformats/i386/x32-avx-linux.dat: Likewise.
11176 * regformats/i386/x32-linux.dat: Likewise.
11177 * regformats/tic6x-c62x-linux.dat: Likewise.
11178 * regformats/tic6x-c64x-linux.dat: Likewise.
11179 * regformats/tic6x-c64xp-linux.dat: Likewise.
11180 * regformats/regdat.sh: Parse feature marker.
11182 2018-04-18 Alan Hayward <alan.hayward@arm.com>
11184 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
11185 (tdesc_osabi_name): Likewise.
11186 * target-descriptions.c (tdesc_architecture_name): Add new
11188 (tdesc_osabi_name): Likewise.
11190 2018-04-18 Alan Hayward <alan.hayward@arm.com>
11192 * common/tdesc.c (tdesc_predefined_type): Move to here.
11193 (tdesc_named_type): Likewise.
11194 (tdesc_create_vector): Likewise.
11195 (tdesc_create_struct): Likewise.
11196 (tdesc_set_struct_size): Likewise.
11197 (tdesc_create_union): Likewise.
11198 (tdesc_create_flags): Likewise.
11199 (tdesc_create_enum): Likewise.
11200 (tdesc_add_field): Likewise.
11201 (tdesc_add_typed_bitfield): Likewise.
11202 (tdesc_add_bitfield): Likewise.
11203 (tdesc_add_flag): Likewise.
11204 (tdesc_add_enum_value): Likewise.
11205 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
11206 (struct tdesc_type_vector): Likewise.
11207 (struct tdesc_type_field): Likewise.
11208 (struct tdesc_type_with_fields): Likewise.
11209 (tdesc_create_enum): Add declaration.
11210 (tdesc_add_typed_bitfield): Likewise.
11211 (tdesc_add_enum_value): Likewise.
11212 * target-descriptions.c (tdesc_type_field): Move from here.
11213 (tdesc_type_builtin): Likewise.
11214 (tdesc_type_vector): Likewise.
11215 (tdesc_type_with_fields): Likewise.
11216 (tdesc_predefined_types): Likewise.
11217 (tdesc_named_type): Likewise.
11218 (tdesc_create_vector): Likewise.
11219 (tdesc_create_struct): Likewise.
11220 (tdesc_set_struct_size): Likewise.
11221 (tdesc_create_union): Likewise.
11222 (tdesc_create_flags): Likewise.
11223 (tdesc_create_enum): Likewise.
11224 (tdesc_add_field): Likewise.
11225 (tdesc_add_typed_bitfield): Likewise.
11226 (tdesc_add_bitfield): Likewise.
11227 (tdesc_add_flag): Likewise.
11228 (tdesc_add_enum_value): Likewise.
11229 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
11230 (tdesc_add_typed_bitfield): Likewise.
11231 (tdesc_add_enum_value): Likewise.
11233 2018-04-18 Alan Hayward <alan.hayward@arm.com>
11235 * common/tdesc.c (tdesc_feature::accept): Move to here.
11236 (tdesc_feature::operator==): Likewise.
11237 (tdesc_create_reg): Likewise.
11238 * common/tdesc.h (tdesc_type_kind): Likewise.
11239 (struct tdesc_type): Likewise.
11240 (struct tdesc_feature): Likewise.
11241 * regformats/regdat.sh: Create a feature.
11242 * target-descriptions.c (tdesc_type_kind): Move from here.
11243 (tdesc_type): Likewise.
11244 (tdesc_type_up): Likewise.
11245 (tdesc_feature): Likewise.
11246 (tdesc_create_reg): Likewise.
11248 2018-04-18 Alan Hayward <alan.hayward@arm.com>
11250 * Makefile.in: Add arch/tdesc.c
11251 * common/tdesc.c: New file.
11252 * common/tdesc.h (tdesc_element_visitor): Move to here.
11253 (tdesc_element): Likewise.
11254 (tdesc_reg): Likewise.
11255 (tdesc_reg_up): Likewise.
11256 * regformats/regdef.h (reg): Add offset to constructors.
11257 * target-descriptions.c (tdesc_element_visitor): Move from here.
11258 (tdesc_element): Likewise.
11259 (tdesc_reg): Likewise.
11260 (tdesc_reg_up): Likewise.
11262 2018-04-17 Tom Tromey <tom@tromey.com>
11264 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
11265 discriminant field.
11267 2018-04-17 Tom Tromey <tom@tromey.com>
11269 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
11271 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
11273 * symtab.c (print_symbol_info): Skip printing filename and line
11274 number when `last' is NULL.
11275 (symtab_symbol_info): Use empty string instead of NULL for first
11276 invocation of print_symbol_info.
11277 (rbreak_command): Pass NULL to `last' parameter of
11280 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
11282 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
11283 instead of nullptr.
11285 2018-04-16 Pedro Alves <palves@redhat.com>
11287 * MAINTAINERS (sh): Remove.
11288 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
11289 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
11290 (ALLDEPFILES): Remove sh64-tdep.c.
11291 * NEWS: Mentions that support for SH-5/SH64 is removed.
11292 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
11293 (sh*-*-openbsd*): Ditto.
11294 (sh64-*-elf*): Remove.
11296 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
11297 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
11298 * sh-tdep.c: No longer include "sh64-tdep.h".
11299 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
11300 * sh64-tdep.c, sh64-tdep.h: Remove files.
11302 2018-04-16 Pedro Alves <palves@redhat.com>
11304 * MAINTAINERS: Remove m88k.
11305 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
11306 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
11307 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
11308 * NEWS: Mention that support for m88k was removed.
11309 * configure.host (m88*-*-*): Remove support.
11310 * configure.nat (m88k-*-*): Remove support.
11311 * configure.tgt (m88*-*-openbsd*): Remove.
11312 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
11314 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
11316 * configure.tgt (x86_tobjs): New variable.
11317 (amd64_tobjs, i386_tobjs): Use it.
11319 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11321 * symtab.c (print_symbol_info): Precede the symbol definition by
11322 the line number when available.
11323 * NEWS: Advertise this enhancement.
11325 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
11327 * NEWS (New options): announce set/show record btrace cpu.
11328 * btrace.c: Include record-btrace.h.
11329 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
11330 the vendor is unknown.
11331 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
11332 Maybe overwrite the btrace configuration's cpu.
11333 (btrace_compute_ftrace): Add cpu parameter. Update callers.
11334 (btrace_fetch): Add cpu parameter. Update callers.
11335 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
11336 Maybe overwrite the btrace configuration's cpu. Skip enabling
11337 errata workarounds if the vendor is unknown.
11338 * python/py-record-btrace.c: Include record-btrace.h.
11339 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
11340 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
11341 * record-btrace.c (record_btrace_cpu_state_kind): New.
11342 (record_btrace_cpu): New.
11343 (set_record_btrace_cpu_cmdlist): New.
11344 (record_btrace_get_cpu): New.
11345 (require_btrace_thread, record_btrace_info)
11346 (record_btrace_resume_thread): Call record_btrace_get_cpu.
11347 (cmd_set_record_btrace_cpu_none): New.
11348 (cmd_set_record_btrace_cpu_auto): New.
11349 (cmd_set_record_btrace_cpu): New.
11350 (cmd_show_record_btrace_cpu): New.
11351 (_initialize_record_btrace): Initialize set/show record btrace cpu
11353 * record-btrace.h (record_btrace_get_cpu): New.
11355 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
11357 * record.c (set_record_command): Fix typo in message.
11359 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
11361 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
11363 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
11365 * infrun.c (process_event_stop_test): Call
11366 gdbarch_in_indirect_branch_thunk.
11367 * gdbarch.sh (in_indirect_branch_thunk): New.
11368 * gdbarch.c: Regenerated.
11369 * gdbarch.h: Regenerated.
11372 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
11373 (HFILES_NO_SRCDIR): Add x86-tdep.h.
11374 (ALLDEPFILES): Add x86-tdep.c.
11375 * arch-utils.h (default_in_indirect_branch_thunk): New.
11376 * arch-utils.c (default_in_indirect_branch_thunk): New.
11377 * i386-tdep: Include x86-tdep.h.
11378 (i386_in_indirect_branch_thunk): New.
11379 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
11381 * amd64-tdep: Include x86-tdep.h.
11382 (amd64_in_indirect_branch_thunk): New.
11383 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
11385 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11388 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
11389 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
11390 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
11393 2018-04-12 Tom Tromey <tom@tromey.com>
11395 * rust-lang.c (rust_print_struct_def): Remove univariant code.
11396 (rust_evaluate_subexp): Likewise.
11398 2018-04-12 Pedro Alves <palves@redhat.com>
11400 * procfs.c (procfs_detach): Make forward declaration's prototype
11401 match definition's protototype.
11402 (proc_get_LDT_entry): Remove stale do_cleanups call.
11404 2018-04-12 Pedro Alves <palves@redhat.com>
11406 * target.h (target_ops::to_has_exited): Delete.
11407 (target_has_exited): Delete.
11408 * target-delegates.c: Regenerate.
11410 2018-04-11 Pedro Alves <palves@redhat.com>
11412 * target.c (fileio_fh_t::t): Add comment.
11413 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
11414 (target_fileio_close): Handle a NULL target.
11415 (invalidate_fileio_fh): New.
11416 (target_close): Call it.
11417 * remote.c (remote_hostio_send_command): No longer check whether
11418 remote_desc is open.
11420 2018-04-11 Pedro Alves <palves@redhat.com>
11422 * target.c (fileio_fh_t): Make it a named struct instead of a
11424 (fileio_fh_t::is_closed): New method.
11425 (DEF_VEC_O (fileio_fh_t)): Remove.
11426 (fileio_fhandles): Now a std::vector.
11427 (is_closed_fileio_fh): Delete.
11428 (acquire_fileio_fd): Adjust. Rename parameters.
11429 (release_fileio_fd): Adjust.
11430 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
11431 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
11432 (target_fileio_close): Adjust.
11434 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
11436 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
11439 2018-04-10 Pedro Alves <palves@redhat.com>
11441 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
11442 (scoped_finish_thread_state): New class.
11443 * infcmd.c (run_command_1): Use it instead of finish_thread_state
11445 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
11446 (fetch_inferior_event, normal_stop): Likewise.
11447 * thread.c (finish_thread_state_cleanup): Delete.
11449 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11450 Pedro Alves <palves@redhat.com>
11452 * value.c: Include "selftest.h" and "common/array-view.h".
11453 (struct range) <operator ==>: New.
11454 (test_ranges_contain): New.
11455 (check_ranges_vector): New.
11456 (test_insert_into_bit_range_vector): New.
11457 (_initialize_values): Register selftests.
11458 * common/array-view.h (operator==, operator!=): New.
11460 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11462 * common/gdb_vecs.h (unordered_remove): Add overload that takes
11464 * inline-frame.c: Include <algorithm>.
11465 (struct inline_state): Add constructor.
11466 (inline_state_s): Remove.
11467 (DEF_VEC_O(inline_state_s)): Remove.
11468 (inline_states): Change type to std::vector.
11469 (find_inline_frame_state): Adjust to std::vector.
11470 (allocate_inline_frame_state): Remove.
11471 (clear_inline_frame_state): Adjust to std::vector.
11472 (skip_inline_frames): Adjust to std::vector.
11474 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11476 * tracepoint.h (struct trace_state_variable): Add constructor.
11477 <name>: Change type to std::string.
11478 * tracepoint.c (tsv_s): Remove.
11479 (DEF_VEC_O(tsv_s)): Remove.
11480 (tvariables): Change to std::vector.
11481 (create_trace_state_variable): Adjust to std::vector.
11482 (find_trace_state_variable): Likewise.
11483 (find_trace_state_variable_by_number): Likewise.
11484 (delete_trace_state_variable): Likewise.
11485 (trace_variable_command): Adjust to std::string.
11486 (delete_trace_variable_command): Likewise.
11487 (tvariables_info_1): Adjust to std::vector.
11488 (save_trace_state_variables): Likewise.
11489 (start_tracing): Likewise.
11490 (merge_uploaded_trace_state_variables): Adjust to std::vector
11492 * target.h (struct target_ops)
11493 <to_download_trace_state_variable>: Pass reference to
11494 trace_state_variable.
11495 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
11496 * target-delegates.c: Re-generate.
11497 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
11498 (mi_tsv_deleted): Likewise.
11499 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
11500 * remote.c (remote_download_trace_state_variable): Change
11501 pointer to reference and adjust.
11502 * make-target-delegates (parse_argtypes): Handle references.
11503 (write_function_header): Likewise.
11504 (munge_type): Likewise.
11506 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11508 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11509 string_view-selftests.c.
11510 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
11512 * unittests/basic_string_view/cons/char/1.cc: Likewise.
11513 * unittests/basic_string_view/cons/char/2.cc: Likewise.
11514 * unittests/basic_string_view/cons/char/3.cc: Likewise.
11515 * unittests/basic_string_view/element_access/char/1.cc:
11517 * unittests/basic_string_view/element_access/char/empty.cc:
11519 * unittests/basic_string_view/element_access/char/front_back.cc:
11521 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
11522 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
11524 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
11526 * unittests/basic_string_view/modifiers/swap/char/1.cc:
11528 * unittests/basic_string_view/operations/compare/char/1.cc:
11530 * unittests/basic_string_view/operations/compare/char/13650.cc:
11532 * unittests/basic_string_view/operations/copy/char/1.cc:
11534 * unittests/basic_string_view/operations/data/char/1.cc:
11536 * unittests/basic_string_view/operations/find/char/1.cc:
11538 * unittests/basic_string_view/operations/find/char/2.cc:
11540 * unittests/basic_string_view/operations/find/char/3.cc:
11542 * unittests/basic_string_view/operations/find/char/4.cc:
11544 * unittests/basic_string_view/operations/rfind/char/1.cc:
11546 * unittests/basic_string_view/operations/rfind/char/2.cc:
11548 * unittests/basic_string_view/operations/rfind/char/3.cc:
11550 * unittests/basic_string_view/operations/substr/char/1.cc:
11552 * unittests/basic_string_view/operators/char/2.cc: Likewise.
11553 * unittests/string_view-selftests.c: New file.
11555 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11557 * unittests/basic_string_view/capacity/1.cc: New file.
11558 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
11559 * unittests/basic_string_view/cons/char/1.cc: New file.
11560 * unittests/basic_string_view/cons/char/2.cc: New file.
11561 * unittests/basic_string_view/cons/char/3.cc: New file.
11562 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
11563 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
11564 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
11565 * unittests/basic_string_view/element_access/char/1.cc: New file.
11566 * unittests/basic_string_view/element_access/char/2.cc: New file.
11567 * unittests/basic_string_view/element_access/char/empty.cc: New file.
11568 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
11569 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
11570 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
11571 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
11572 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
11573 * unittests/basic_string_view/include.cc: New file.
11574 * unittests/basic_string_view/inserters/char/1.cc: New file.
11575 * unittests/basic_string_view/inserters/char/2.cc: New file.
11576 * unittests/basic_string_view/inserters/char/3.cc: New file.
11577 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
11578 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
11579 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
11580 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
11581 * unittests/basic_string_view/literals/types.cc: New file.
11582 * unittests/basic_string_view/literals/values.cc: New file.
11583 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
11584 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
11585 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
11586 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
11587 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
11588 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
11589 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
11590 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
11591 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
11592 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
11593 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
11594 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
11595 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
11596 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
11597 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
11598 * unittests/basic_string_view/operations/data/char/1.cc: New file.
11599 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
11600 * unittests/basic_string_view/operations/find/char/1.cc: New file.
11601 * unittests/basic_string_view/operations/find/char/2.cc: New file.
11602 * unittests/basic_string_view/operations/find/char/3.cc: New file.
11603 * unittests/basic_string_view/operations/find/char/4.cc: New file.
11604 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
11605 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
11606 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
11607 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
11608 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
11609 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
11610 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
11611 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
11612 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
11613 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
11614 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
11615 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
11616 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
11617 * unittests/basic_string_view/operators/char/2.cc: New file.
11618 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
11619 * unittests/basic_string_view/range_access/char/1.cc: New file.
11620 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
11621 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
11622 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
11623 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
11624 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
11625 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
11626 * unittests/basic_string_view/requirements/typedefs.cc: New file.
11627 * unittests/basic_string_view/typedefs.cc: New file.
11628 * unittests/basic_string_view/types/1.cc: New file.
11630 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11632 * common/gdb_string_view.h: Remove libstdc++ implementation
11633 details, adjust to gdb reality.
11634 * common/gdb_string_view.tcc: Likewise.
11635 * cli/cli-script.c (struct string_view): Remove.
11636 (user_args) <m_args>: Change element type to gdb::string_view.
11637 (user_args::insert_args): Adjust.
11639 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11641 * common/gdb_string_view.h: New file.
11642 * common/gdb_string_view.tcc: New file.
11644 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11646 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
11647 * configure: Re-generate.
11649 2018-04-09 Pedro Alves <palves@redhat.com>
11651 * gdbarch.sh: Include "observable.h" instead of "observer.h".
11652 (set_target_gdbarch): Call
11653 gdb::observers::architecture_changed.notify instead of
11654 observer_notify_architecture_changed.
11656 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11658 * tracepoint.c (struct current_traceframe_cleanup): Remove.
11659 (do_restore_current_traceframe_cleanup): Remove.
11660 (restore_current_traceframe_cleanup_dtor): Remove.
11661 (make_cleanup_restore_current_traceframe): Remove.
11662 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
11664 * tracepoint.h (struct scoped_restore_current_traceframe): New.
11665 * infrun.c (fetch_inferior_event): Use
11666 scoped_restore_current_traceframe.
11668 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11670 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
11672 <n_allocated_type_units>: Remove.
11673 <all_type_units>: Change to std::vector.
11674 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
11675 to std::vector change.
11676 (dwarf2_per_objfile::get_cutu): Likewise.
11677 (dwarf2_per_objfile::get_tu): Likewise.
11678 (create_signatured_type_table_from_index): Likewise.
11679 (create_signatured_type_table_from_debug_names): Likewise.
11680 (dw2_symtab_iter_next): Likewise.
11681 (dw2_print_stats): Likewise.
11682 (dw2_expand_all_symtabs): Likewise.
11683 (dw2_expand_marked_cus): Likewise.
11684 (dw2_debug_names_iterator::next): Likewise.
11685 (dwarf2_initialize_objfile): Likewise.
11686 (add_signatured_type_cu_to_table): Likewise.
11687 (create_all_type_units): Likewise.
11688 (add_type_unit): Likewise.
11689 (struct tu_abbrev_offset): Add constructor.
11690 (build_type_psymtabs_1): Adjust to std::vector change.
11691 (print_tu_stats): Likewise.
11692 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
11693 (write_debug_names): Likewise.
11695 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11697 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
11698 Make an std::vector.
11699 <n_comp_units>: Remove.
11700 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
11701 to std::vector change.
11702 (dwarf2_per_objfile::get_cutu): Likewise.
11703 (dwarf2_per_objfile::get_cu): Likewise.
11704 (create_cus_from_index): Likewise.
11705 (create_addrmap_from_index): Likewise.
11706 (create_addrmap_from_aranges): Likewise.
11707 (dwarf2_read_index): Likewise.
11708 (dw2_find_last_source_symtab): Likewise.
11709 (dw2_map_symtabs_matching_filename): Likewise.
11710 (dw2_symtab_iter_next): Likewise.
11711 (dw2_print_stats): Likewise.
11712 (dw2_expand_all_symtabs): Likewise.
11713 (dw2_expand_symtabs_with_fullname): Likewise.
11714 (dw2_expand_marked_cus): Likewise.
11715 (dw2_map_symbol_filenames): Likewise.
11716 (create_cus_from_debug_names): Likewise.
11717 (dwarf2_read_debug_names): Likewise.
11718 (dw2_debug_names_iterator::next): Likewise.
11719 (dwarf2_initialize_objfile): Likewise.
11720 (set_partial_user): Likewise.
11721 (dwarf2_build_psymtabs_hard): Likewise.
11722 (read_comp_units_from_section): Remove arguments, adjust to
11723 std::vector change.
11724 (create_all_comp_units): Adjust to std::vector and
11725 read_comp_units_from_section changes.
11726 (dwarf2_find_containing_comp_unit): Adjust to std::vector
11728 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
11729 (psyms_seen_size): Likewise.
11730 (write_gdbindex): Likewise.
11731 (write_debug_names): Likewise.
11733 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11735 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
11736 with dwarf2_per_objfile.
11737 (create_cus_from_index): Likewise.
11738 (create_signatured_type_table_from_index): Likewise.
11739 (dwarf2_read_index): Likewise.
11740 (dwarf2_initialize_objfile): Likewise.
11741 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
11742 per_cu rather than get_dwarf2_per_objfile.
11744 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11746 * dwarf2read.h (struct signatured_type): Forward declare.
11747 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
11749 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
11750 (dw2_get_cutu): ...this.
11751 (dwarf2_per_objfile::get_cu): Rename from...
11752 (dw2_get_cu): ...this.
11753 (dwarf2_per_objfile::get_tu): New.
11754 (create_addrmap_from_index): Adjust.
11755 (create_addrmap_from_aranges): Adjust.
11756 (dw2_find_last_source_symtab): Adjust.
11757 (dw2_map_symtabs_matching_filename): Adjust.
11758 (dw2_symtab_iter_next): Adjust.
11759 (dw2_print_stats): Adjust.
11760 (dw2_expand_all_symtabs): Adjust.
11761 (dw2_expand_symtabs_with_fullname): Adjust.
11762 (dw2_expand_marked_cus): Adjust.
11763 (dw_expand_symtabs_matching_file_matcher): Adjust.
11764 (dw2_map_symbol_filenames): Adjust.
11765 (dw2_debug_names_iterator::next): Adjust.
11766 (dwarf2_initialize_objfile): Adjust.
11767 (set_partial_user): Adjust.
11768 (dwarf2_build_psymtabs_hard): Adjust.
11770 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11772 * dwarf2read.c (create_signatured_type_table_from_debug_names):
11773 Remove unused variables.
11774 (dw2_map_symtabs_matching_filename): Likewise.
11775 (dwarf2_record_block_ranges): Likewise.
11776 (dwarf2_read_addr_index): Likewise.
11777 (follow_die_offset): Likewise.
11779 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11781 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
11782 to symbol_file_add_main.
11784 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11787 * mi/mi-console.c (do_fputc_async_safe): New.
11788 (mi_console_file::write_async_safe): New.
11789 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
11790 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
11792 * ui-file.c (ui_file::putstrn): Adjust call to
11793 fputstrn_unfiltered.
11794 * utils.c (printchar): Replace do_fputs and do_fprintf
11795 parameters by do_fputc.
11796 (fputstr_filtered): Adjust call to printchar.
11797 (fputstr_unfiltered): Likewise.
11798 (fputstrn_filtered): Likewise.
11799 (fputstrn_unfiltered): Add do_fputc parameter, pass to
11801 * utils.h (do_fputc_ftype): New typedef.
11802 (fputstrn_unfiltered): Add do_fputc parameter.
11804 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11806 * regformats/i386/i386-avx.dat: Remove.
11808 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
11811 * amd64-tdep.c (amd64_none_init_abi): New function.
11812 (amd64_x32_none_init_abi): New function.
11813 (_initialize_amd64_tdep): Register handlers for x86-64 and
11814 x64_32 with GDB_OSABI_NONE.
11815 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
11816 GDB_OSABI_NONE osabi.
11818 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
11821 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
11823 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
11824 * osabi.c (gdb_osabi_names): Add "unknown" entry.
11826 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
11828 * common/byte-vector.h (char_vector): New type.
11829 * target.h (target_read_alloc): Return
11830 gdb::optional<byte_vector>.
11831 (target_read_stralloc): Return gdb::optional<char_vector>.
11832 (target_get_osdata): Return gdb::optional<char_vector>.
11833 * target.c (target_read_alloc_1): Templatize. Replacement
11834 manual memory management with vector.
11835 (target_read_alloc): Change return type, adjust.
11836 (target_read_stralloc): Change return type, adjust.
11837 (target_get_osdata): Change return type, adjust.
11838 * auxv.c (struct auxv_info) <length>: Remove.
11839 <data>: Change type to gdb::optional<byte_vector>.
11840 (auxv_inferior_data_cleanup): Free auxv_info with delete.
11841 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
11842 (target_auxv_search): Adjust.
11843 (fprint_target_auxv): Adjust.
11844 * avr-tdep.c (avr_io_reg_read_command): Adjust.
11845 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
11846 (linux_make_corefile_notes): Adjust.
11847 * osdata.c (get_osdata): Adjust.
11848 * remote.c (remote_get_threads_with_qxfer): Adjust.
11849 (remote_memory_map): Adjust.
11850 (remote_traceframe_info): Adjust.
11851 (btrace_read_config): Adjust.
11852 (remote_read_btrace): Adjust.
11853 (remote_pid_to_exec_file): Adjust.
11854 * solib-aix.c (solib_aix_get_library_list): Adjust.
11855 * solib-dsbt.c (decode_loadmap): Don't free buf.
11856 (dsbt_get_initial_loadmaps): Adjust.
11857 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
11858 * solib-target.c (solib_target_current_sos): Adjust.
11859 * tracepoint.c (sdata_make_value): Adjust.
11860 * xml-support.c (xinclude_start_include): Adjust.
11861 (xml_fetch_content_from_file): Adjust.
11862 * xml-support.h (xml_fetch_another): Change return type.
11863 (xml_fetch_content_from_file): Change return type.
11864 * xml-syscall.c (xml_init_syscalls_info): Adjust.
11865 * xml-tdesc.c (file_read_description_xml): Adjust.
11866 (fetch_available_features_from_target): Change return type.
11867 (target_fetch_description_xml): Adjust.
11868 (target_read_description_xml): Adjust.
11870 2018-04-06 Tom Tromey <tom@tromey.com>
11872 * value.c (~value): Update.
11873 (struct value) <contents>: Now unique_xmalloc_ptr.
11874 (value_contents_bits_eq, allocate_value_contents)
11875 (value_contents_raw, value_contents_all_raw)
11876 (value_contents_for_printing, value_contents_for_printing_const)
11877 (set_value_enclosing_type): Update.
11879 2018-04-06 Tom Tromey <tom@tromey.com>
11881 * value.c (range_s): Remove typedef, VEC.
11882 (struct range): Add operator<.
11883 (range_lessthan): Remove.
11884 (ranges_contain): Change type.
11886 (struct value) <unavailable, optimized_out>: Now std::vector.
11887 (value_entirely_available)
11888 (value_entirely_covered_by_range_vector)
11889 (value_entirely_unavailable, value_entirely_optimized_out):
11891 (insert_into_bit_range_vector): Change argument type.
11892 (find_first_range_overlap): Likewise.
11893 (struct ranges_and_idx, value_contents_bits_eq)
11894 (require_not_optimized_out, require_available): Update.
11895 (ranges_copy_adjusted): Change argument types.
11896 (value_optimized_out, value_copy, value_fetch_lazy): Update.
11898 2018-04-06 Tom Tromey <tom@tromey.com>
11900 * value.c (~value): Update.
11901 (struct value) <parent>: Now a value_ref_ptr.
11902 (value_parent, set_value_parent, value_address, value_copy):
11905 2018-04-06 Tom Tromey <tom@tromey.com>
11907 * value.c (struct value): Add constructor, destructor, and member
11909 (allocate_value_lazy, value_decref): Update.
11911 2018-04-06 Tom Tromey <tom@tromey.com>
11913 * value.c (struct value) <released, next>: Remove.
11914 (all_values): Now a std::vector.
11915 (allocate_value_lazy): Update.
11916 (value_next): Remove.
11917 (value_mark, value_free_to_mark, release_value)
11918 (value_release_to_mark): Update.
11920 2018-04-06 Tom Tromey <tom@tromey.com>
11922 * value.h (fetch_subexp_value, value_release_to_mark): Update.
11923 (free_value_chain): Remove.
11924 * value.c (free_value_chain): Remove.
11925 (value_release_to_mark): Return a std::vector.
11926 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
11928 (check_condition): Update.
11929 * eval.c (fetch_subexp_value): Change "val_chain" to a
11931 * breakpoint.c (update_watchpoint): Update.
11932 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
11934 2018-04-06 Tom Tromey <tom@tromey.com>
11936 * value.h (free_all_values): Remove.
11937 * value.c (free_all_values): Remove.
11939 2018-04-06 Tom Tromey <tom@tromey.com>
11941 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
11942 (value_history_chain, value_history_count): Remove.
11943 (value_history): New global.
11944 (record_latest_value, access_value_history, show_values)
11945 (preserve_values): Update.
11947 2018-04-06 Tom Tromey <tom@tromey.com>
11949 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
11950 * varobj.c (varobj_set_display_format, varobj_set_value)
11951 (install_default_visualizer, construct_visualizer)
11952 (install_new_value, ~varobj, varobj_get_value_type)
11953 (my_value_of_variable, varobj_editable_p): Update.
11954 * c-varobj.c (c_describe_child, c_value_of_variable)
11955 (cplus_number_of_children, cplus_describe_child): Update.
11956 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
11957 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
11958 (ada_value_of_variable, ada_value_is_changeable_p): Update.
11960 2018-04-06 Tom Tromey <tom@tromey.com>
11962 * printcmd.c (last_examine_address): Change type to
11964 (do_examine, x_command): Update.
11966 2018-04-06 Tom Tromey <tom@tromey.com>
11968 * value.c (release_value): Update.
11969 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
11970 (struct bpstats) <val>: Now a value_ref_ptr.
11971 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11972 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11973 (~watchpoint, print_it_watchpoint, watch_command_1)
11974 (invalidate_bp_value_on_memory_change): Update.
11976 2018-04-06 Tom Tromey <tom@tromey.com>
11978 * varobj.c (varobj_clear_saved_item)
11979 (update_dynamic_varobj_children, install_new_value, ~varobj):
11981 * value.h (value_incref): Move declaration earlier.
11982 (value_decref): Rename from value_free.
11983 (struct value_ref_policy): New.
11984 (value_ref_ptr): New typedef.
11985 (struct value_deleter): Remove.
11986 (gdb_value_up): Remove typedef.
11987 (release_value): Change return type.
11988 (release_value_or_incref): Remove.
11989 * value.c (set_value_parent): Update.
11990 (value_incref): Change return type.
11991 (value_decref): Rename from value_free.
11992 (value_free_to_mark, free_all_values, free_value_chain): Update.
11993 (release_value): Return value_ref_ptr.
11994 (release_value_or_incref): Remove.
11995 (record_latest_value, set_internalvar, clear_internalvar):
11997 * stack.c (info_frame_command): Don't call value_free.
11998 * python/py-value.c (valpy_dealloc, valpy_new)
11999 (value_to_value_object): Update.
12000 * printcmd.c (do_examine): Update.
12001 * opencl-lang.c (lval_func_free_closure): Update.
12002 * mi/mi-main.c (register_changed_p): Don't call value_free.
12003 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
12004 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
12005 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
12007 * guile/scm-value.c (vlscm_free_value_smob)
12008 (vlscm_scm_from_value): Update.
12009 * frame.c (frame_register_unwind, frame_unwind_register_signed)
12010 (frame_unwind_register_unsigned, get_frame_register_bytes)
12011 (put_frame_register_bytes): Don't call value_free.
12012 * findvar.c (address_from_register): Don't call value_free.
12013 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
12014 * dwarf2loc.c (entry_data_value_free_closure)
12015 (value_of_dwarf_reg_entry, free_pieced_value_closure)
12016 (dwarf2_evaluate_loc_desc_full): Update.
12017 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
12018 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
12019 (~watchpoint, watch_command_1)
12020 (invalidate_bp_value_on_memory_change): Update.
12021 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
12023 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
12026 * warning.m4: Add -Wno-error=deprecated-register.
12027 * configure: Re-generate.
12029 2018-04-05 Tom Tromey <tom@tromey.com>
12031 * linespec.h: Remove include of "vec.h".
12033 2018-04-05 Tom Tromey <tom@tromey.com>
12035 * linespec.c (typep): Remove typedef.
12036 (find_methods, find_superclass_methods): Take a std::vector.
12037 (find_method): Use std::vector.
12039 2018-04-05 Tom Tromey <tom@tromey.com>
12041 * utils.c (compare_strings): Remove.
12042 * utils.h (compare_strings): Remove.
12043 * objc-lang.h (find_imps): Update.
12044 * objc-lang.c (find_methods): Take a std::vector.
12045 (uniquify_strings, find_imps): Likewise.
12046 * linespec.c (find_methods): Take a std::vector.
12047 (decode_objc): Use std::vector.
12048 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
12050 (find_method, find_function_symbols): Use std::vector.
12052 2018-04-05 Tom Tromey <tom@tromey.com>
12054 * completer.c (completion_tracker::completion_tracker): Remove
12056 (completion_tracker::discard_completions): Likewise.
12057 * breakpoint.c (ambiguous_names_p): Remove cast.
12058 * ada-lang.c (_initialize_ada_language): Remove cast.
12059 * utils.h (streq): Update.
12060 (streq_hash): Add new declaration.
12061 * utils.c (streq): Return bool.
12062 (streq_hash): New function.
12064 2018-04-05 Tom Tromey <tom@tromey.com>
12066 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
12067 Remove a string copy.
12069 2018-04-05 Tom Tromey <tom@tromey.com>
12071 * linespec.c (filter_results): Use std::vector.
12072 (decode_line_2, decode_line_full): Update.
12074 2018-04-05 Tom Tromey <tom@tromey.com>
12076 * linespec.c (canonical_to_fullform): Return std::string.
12077 (filter_results): Update.
12078 (struct decode_line_2_item): Add constructor.
12079 <fullform, displayform>: Now std::string.
12080 (decode_line_2_compare_items): Now a std::sort comparator.
12081 (decode_line_2): Update.
12083 2018-04-05 Tom Tromey <tom@tromey.com>
12085 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
12086 (unexpected_linespec_error): Update.
12087 (linespec_parse_basic, parse_linespec): Update.
12089 2018-04-05 Tom Tromey <tom@tromey.com>
12091 * linespec.c (linespec_parse_basic): Reindent.
12093 2018-04-05 Tom Tromey <tom@tromey.com>
12095 * minsyms.h (iterate_over_minimal_symbols): Update.
12096 * minsyms.c (iterate_over_minimal_symbols): Take a
12097 gdb::function_view.
12098 * linespec.c (struct collect_minsyms): Remove.
12099 (compare_msyms): Now a std::sort comparator.
12100 (add_minsym): Add parameters.
12101 (search_minsyms_for_name): Update. Use std::vector.
12103 2018-04-03 Tom Tromey <tom@tromey.com>
12105 * mipsread.c (read_alphacoff_dynamic_symtab): Use
12108 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
12110 * MAINTAINERS (Write After Approval): Add Weimin Pan.
12112 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
12115 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
12116 printing static type.
12118 2018-04-01 Tom Tromey <tom@tromey.com>
12120 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
12121 (rs6000_xfer_shared_libraries): Update.
12123 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
12125 * common/gdb_vecs.h (char_ptr): Remove.
12126 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
12128 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
12130 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
12132 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
12134 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
12136 * tracepoint.h (struct uploaded_tp): Initialize fields.
12137 <actions, step_actions, cmd_strings>: Change type to
12138 std::vector<char *>.
12139 * tracepoint.c (get_uploaded_tp): Allocate with new.
12140 (free_uploaded_tps): Free with delete.
12141 (parse_tracepoint_definition): Adjust to std::vector change.
12142 * breakpoint.c (read_uploaded_action): Likewise.
12143 (create_tracepoint_from_upload): Likewise.
12144 * ctf.c (ctf_write_uploaded_tp): Likewise.
12145 (SET_ARRAY_FIELD): Likewise.
12146 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
12148 2018-03-30 Tom Tromey <tom@tromey.com>
12150 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
12152 (svr4_keep_data_in_core): Update.
12153 (svr4_read_so_list): Update.
12155 2018-03-30 Tom Tromey <tom@tromey.com>
12157 * windows-nat.c (handle_output_debug_string, handle_exception):
12159 * target.h (target_read_string): Update.
12160 * target.c (target_read_string): Change "string" to
12161 unique_xmalloc_ptr.
12162 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
12164 * solib-frv.c (frv_current_sos): Update.
12165 * solib-dsbt.c (dsbt_current_sos): Update.
12166 * solib-darwin.c (darwin_current_sos): Update.
12167 * linux-thread-db.c (inferior_has_bug): Update.
12168 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
12169 Update. Remove alloca.
12170 * ada-lang.c (ada_main_name): Update.
12172 2018-03-30 Tom Tromey <tom@tromey.com>
12174 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
12175 (struct dwo_file_deleter): New.
12176 (dwo_file_up): New typedef.
12177 (open_and_init_dwo_file): Use dwo_file_up.
12178 (free_dwo_file_cleanup): Remove.
12180 2018-03-30 Tom Tromey <tom@tromey.com>
12182 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
12183 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
12185 2018-03-30 Tom Tromey <tom@tromey.com>
12187 * dwarf2read.c (class free_cached_comp_units): New class.
12188 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
12189 (free_cached_comp_units): Remove function.
12191 2018-03-30 Tom Tromey <tom@tromey.com>
12193 * utils.h (make_cleanup_unpush_target): Remove.
12194 * inf-ptrace.c (struct target_unpusher): New.
12195 (target_unpush_up) New typedef.
12196 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
12198 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
12200 2018-03-27 Tom Tromey <tom@tromey.com>
12202 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
12204 2018-03-27 Pedro Alves <palves@redhat.com>
12205 Tom Tromey <tom@tromey.com>
12207 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
12208 destructor. Now a class.
12209 (gdb_readline_wrapper_cleanup): Remove function.
12210 (gdb_readline_wrapper): Remove cleanups.
12212 2018-03-27 Tom Tromey <tom@tromey.com>
12214 * typeprint.h (struct type_print_options) <local_typedefs,
12215 global_typedefs>: Remove "struct" keyword.
12216 (class typedef_hash_table): New class.
12217 (recursively_update_typedef_hash, add_template_parameters)
12218 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
12219 (find_typedef_in_hash): Don't declare.
12220 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
12221 (typedef_hash_table::recursively_update): Rename from
12222 recursively_update_typedef_hash. Now a member.
12223 (typedef_hash_table::add_template_parameters): Rename from
12224 add_template_parameters. Now a member.
12225 (typedef_hash_table::typedef_hash_table): Now a constructor;
12226 rename from create_typedef_hash.
12227 (typedef_hash_table::~typedef_hash_table): Now a destructor;
12228 rename from free_typedef_hash.
12229 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
12230 (do_free_global_table): Remove.
12231 (typedef_hash_table::typedef_hash_table): New constructor; renamed
12232 from copy_type_recursive.
12233 (create_global_typedef_table): Remove.
12234 (typedef_hash_table::find_global_typedef): Now a member of
12235 typedef_hash_table.
12236 (typedef_hash_table::find_typedef): Rename from
12237 find_typedef_in_hash; now a member.
12238 (whatis_exp): Update.
12239 * extension.h (struct ext_lang_type_printers): Add constructor and
12241 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
12243 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
12244 Now a constructor; rename from start_ext_lang_type_printers.
12245 (ext_lang_type_printers): Now a destructor; rename from
12246 free_ext_lang_type_printers.
12247 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
12249 (c_type_print_base_struct_union): Update. Remove cleanups.
12251 2018-03-27 Tom Tromey <tom@tromey.com>
12253 * dwarf-index-write.c: Include <cmath>.
12255 2018-03-27 Joel Brobecker <brobecker@adacore.com>
12257 * NEWS: Add entry describing new "set|show varsize-limit" command.
12258 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
12260 * printcmd.c (_initialize_printcmd): Add "set var" alias of
12263 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
12265 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
12266 dwarf-index-write.c
12267 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
12268 * dwarf-index-common.c: New file.
12269 * dwarf-index-common.h: New file.
12270 * dwarf-index-write.c: New file.
12271 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
12272 (struct dwarf2_section_info): Move from here.
12273 (dwarf2_section_info_def): Likewise.
12274 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
12275 (offset_type): Likewise.
12276 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
12277 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
12278 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
12279 (byte_swap): Likewise.
12280 (MAYBE_SWAP): Likewise.
12281 (dwarf2_per_cu_ptr): Likewise.
12282 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
12283 (struct tu_stats): Likewise.
12284 (struct dwarf2_per_objfile): Likewise.
12285 (struct dwarf2_per_cu_data): Likewise.
12286 (struct signatured_type): Likewise.
12287 (sig_type_ptr): Likewise.
12288 (DEF_VEC_P (sig_type_ptr)): Likewise.
12289 (INDEX4_SUFFIX): Likewise.
12290 (INDEX5_SUFFIX): Likewise.
12291 (DEBUG_STR_SUFFIX): Likewise.
12292 (dwarf2_read_section): Make non-static.
12293 (mapped_index_string_hash): Move from here.
12294 (dwarf5_djb_hash): Likewise.
12295 (file_write): Likewise.
12296 (class data_buf): Likewise.
12297 (struct symtab_index_entry): Likewise.
12298 (struct mapped_symtab): Likewise.
12299 (find_slot): Likewise.
12300 (hash_expand): Likewise.
12301 (add_index_entry): Likewise.
12302 (uniquify_cu_indices): Likewise.
12303 (class c_str_view): Likewise.
12304 (class c_str_view_hasher): Likewise.
12305 (class vector_hasher): Likewise.
12306 (write_hash_table): Likewise.
12307 (psym_index_map): Likewise.
12308 (struct addrmap_index_data): Likewise.
12309 (add_address_entry): Likewise.
12310 (add_address_entry_worker): Likewise.
12311 (write_address_map): Likewise.
12312 (symbol_kind): Likewise.
12313 (write_psymbols): Likewise.
12314 (struct signatured_type_index_data): Likewise.
12315 (write_one_signatured_type): Likewise.
12316 (recursively_count_psymbols): Likewise.
12317 (recursively_write_psymbols): Likewise.
12318 (class debug_names): Likewise.
12319 (check_dwarf64_offsets): Likewise.
12320 (psyms_seen_size): Likewise.
12321 (write_gdbindex): Likewise.
12322 (write_debug_names): Likewise.
12323 (assert_file_size): Likewise.
12324 (write_psymtabs_to_index): Likewise.
12325 (save_gdb_index_command): Likewise.
12326 (_initialize_dwarf2_read): Don't register the "save gdb-index"
12328 * dwarf2read.h: New file.
12330 2018-03-27 Joel Brobecker <brobecker@adacore.com>
12333 * dwarf2read.c (dwarf2_physname): Do not return the demangled
12334 symbol name if the CU's language stores symbol names in linkage
12336 * language.h (struct language_defn)
12337 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
12338 all instances of this struct.
12340 2018-03-26 Tom Tromey <tom@tromey.com>
12342 * stack.c (backtrace_command_1): Remove verbose code.
12344 2018-03-26 Tom Tromey <tom@tromey.com>
12346 * python/py-framefilter.c (py_print_type): Don't catch
12347 exceptions. Return void.
12348 (py_print_value): Likewise.
12349 (py_print_single_arg): Likewise.
12350 (enumerate_args): Don't catch exceptions.
12351 (py_print_args): Likewise.
12352 (py_print_frame): Likewise.
12353 (gdbpy_apply_frame_filter): Catch exceptions here.
12355 2018-03-26 Tom Tromey <tom@tromey.com>
12357 * stack.c (_initialize_stack): Remove trailing newlines from help
12358 text. Add "Usage" line to "backtrace" help.
12360 2018-03-26 Tom Tromey <tom@tromey.com>
12363 * python/py-framefilter.c (py_print_args): Call wrap_hint.
12365 2018-03-26 Tom Tromey <tom@tromey.com>
12367 * python/py-framefilter.c (py_print_single_arg): Return
12368 EXT_LANG_BT_ERROR from catch.
12370 2018-03-26 Tom Tromey <tom@tromey.com>
12372 PR backtrace/15584:
12373 * stack.c (backtrace_command_1): Move some code into no-filters
12376 2018-03-26 Tom Tromey <tom@tromey.com>
12378 * python/py-framefilter.c (throw_quit_or_print_exception): New
12380 (gdbpy_apply_frame_filter): Use it.
12382 2018-03-26 Tom Tromey <tom@tromey.com>
12385 * python/py-framefilter.c (py_print_type, py_print_value)
12386 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
12389 2018-03-26 Tom Tromey <tom@tromey.com>
12391 * python/py-framefilter.c (enumerate_args): Use
12392 gdb::unique_xmalloc_ptr.
12394 2018-03-26 Tom Tromey <tom@tromey.com>
12396 * python/py-framefilter.c (py_print_frame): Return
12398 (gdbpy_apply_frame_filter): Update comment.
12399 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
12401 <EXT_LANG_BT_NO_FILTERS>: Change value.
12403 2018-03-26 Tom Tromey <tom@tromey.com>
12405 PR backtrace/15582:
12406 * stack.c (backtrace_command): Parse "hide" argument.
12407 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
12408 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
12411 2018-03-26 Tom Tromey <tom@tromey.com>
12413 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
12415 (backtrace_command): Remove "fulltrace", add "flags".
12417 2018-03-26 Tom Tromey <tom@tromey.com>
12419 * stack.c (backtrace_command): Rewrite command line parsing.
12421 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
12423 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
12425 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
12427 * filename-seen-cache.h: Add include guard.
12429 2018-03-26 Keith Seitz <keiths@redhat.com>
12431 * symfile.c (place_section): Remove "struct" from section_addr_info
12433 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
12434 "struct" keyword from section_addr_info.
12436 2018-03-26 Alan Hayward <alan.hayward@arm.com>
12438 * regformats/regdef.h (reg): Add constructors.
12440 2018-03-25 Pedro Alves <palves@redhat.com>
12442 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
12443 if then/else bodies in var_func_name extraction.
12445 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
12447 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
12448 lookup_minimal_symbol() to find symbol entry.
12449 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
12451 2018-03-23 Keith Seitz <keiths@redhat.com>
12454 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
12455 nested type definitions for C++, too.
12457 2018-03-23 Tom Tromey <tom@tromey.com>
12459 * machoread.c (struct oso_el): Add a constructor. Don't define as
12461 (macho_register_oso): Remove.
12462 (macho_symtab_read): Take a std::vector.
12463 (oso_el_compare_name): Now a std::sort comparator.
12464 (macho_symfile_read_all_oso): Take a std::vector.
12465 (macho_symfile_read): Use std::vector. Remove cleanups.
12467 2018-03-22 Tom Tromey <tom@tromey.com>
12469 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
12470 (record_full_goto_bookmark): Use std::string.
12472 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12475 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
12478 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12480 * rs6000-tdep.c (store_insn_p): New function.
12481 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
12482 and cr_reg to their unshifted values. Use store_insn_p to
12483 match LR saves using either R1 or fdata->alloca_reg. Use
12484 store_insn_p to match CR saves. Set alloca_reg_offset
12485 when alloca_reg and framep are set. Remove lr_reg shift
12486 when assigning to fdata->lr_register.
12488 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
12490 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
12491 command line args instead of emitting a warning.
12493 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12495 * tracepoint.h (struct static_tracepoint_marker): Initialize
12496 fields, define default constructor, move constructor and move
12497 assignment, disable the rest.
12498 <str_id, extra>: Make std::string.
12499 (release_static_tracepoint_marker): Remove.
12500 (free_current_marker): Remove.
12501 * tracepoint.c (free_current_marker): Remove.
12502 (parse_static_tracepoint_marker_definition): Adjust to
12503 std::string, use new hex2str overload.
12504 (release_static_tracepoint_marker): Remove.
12505 (print_one_static_tracepoint_marker): Get marker by reference
12506 and adjust to std::string.
12507 (info_static_tracepoint_markers_command): Adjust to std::vector
12509 * target.h (static_tracepoint_marker_p): Remove typedef.
12510 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
12511 (struct target_ops) <to_static_tracepoint_marker_at>: Return
12513 <to_static_tracepoint_markers_by_strid>: Return std::vector.
12515 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
12516 (target_debug_print_std_vector_static_tracepoint_marker): New.
12517 (target_debug_print_struct_static_tracepoint_marker_p): Rename
12519 (target_debug_print_static_tracepoint_marker_p): ... this.
12520 * target-delegates.c: Re-generate.
12521 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
12523 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
12524 (decode_static_tracepoint_spec): Adjust to std::vector.
12525 (tracepoint_print_one_detail): Adjust to std::string.
12526 (strace_marker_decode_location): Adjust to std::string.
12527 (update_static_tracepoint): Adjust to std::string, remove call
12528 to release_static_tracepoint_marker.
12529 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
12530 Adjust to std::vector.
12531 * remote.c (remote_static_tracepoint_marker_at): Return bool.
12532 (remote_static_tracepoint_markers_by_strid): Adjust to
12534 * common/rsp-low.h (hex2str): New overload with explicit count
12536 * common/rsp-low.c (hex2str): New overload with explicit count
12538 * unittests/rsp-low-selftests.c (test_hex2str): New function.
12539 (_initialize_rsp_low_selftests): Add test_hex2str test.
12540 * unittests/tracepoint-selftests.c
12541 (test_parse_static_tracepoint_marker_definition): Adjust to
12544 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12546 * tracepoint.c (parse_static_tracepoint_marker_definition):
12547 Consider case where the definition is followed by more
12549 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12550 tracepoint-selftests.c.
12551 * unittests/tracepoint-selftests.c: New.
12553 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12555 * MAINTAINERS (Write After Approval): Add Pedro Franco de
12558 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
12560 * symtab.c (find_pc_sect_line): fixed indentation.
12562 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
12564 * symtab.c (find_pc_sect_line): now uses binary search.
12566 2018-03-19 Tom Tromey <tom@tromey.com>
12568 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
12569 "IDENT" production.
12571 2018-03-19 Pedro Alves <palves@redhat.com>
12572 Tom Tromey <tom@tromey.com>
12574 * unittests/observable-selftests.c: New file.
12575 * common/observable.h: New file.
12576 * observable.h: New file.
12577 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
12578 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
12579 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
12580 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
12581 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
12582 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
12583 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
12584 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
12585 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
12586 python/py-breakpoint.c, python/py-finishbreakpoint.c,
12587 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
12588 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
12589 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
12590 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
12591 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
12592 tui/tui-interp.c, valops.c: Update all users.
12593 * tui/tui-hooks.c (tui_bp_created_observer)
12594 (tui_bp_deleted_observer, tui_bp_modified_observer)
12595 (tui_inferior_exit_observer, tui_before_prompt_observer)
12596 (tui_normal_stop_observer, tui_register_changed_observer):
12598 (tui_observers_token): New global.
12599 (attach_or_detach, tui_attach_detach_observers): New functions.
12600 (tui_install_hooks, tui_remove_hooks): Use
12601 tui_attach_detach_observers.
12602 * record-btrace.c (record_btrace_thread_observer): Remove.
12603 (record_btrace_thread_observer_token): New global.
12604 * observer.sh: Remove.
12605 * observer.c: Rename to observable.c.
12606 * observable.c (namespace gdb_observers): Define new objects.
12607 (observer_debug): Move into gdb_observers namespace.
12608 (struct observer, struct observer_list, xalloc_observer_list_node)
12609 (xfree_observer_list_node, generic_observer_attach)
12610 (generic_observer_detach, generic_observer_notify): Remove.
12611 (_initialize_observer): Update.
12612 Don't include observer.inc.
12613 * Makefile.in (generated_files): Remove observer.h, observer.inc.
12614 (clean mostlyclean): Likewise.
12615 (observer.h, observer.inc): Remove targets.
12616 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
12617 (COMMON_SFILES): Use observable.c, not observer.c.
12618 * .gitignore: Remove observer.h.
12620 2018-03-18 Tom Tromey <tom@tromey.com>
12622 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
12624 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
12626 2018-03-17 Tom Tromey <tom@tromey.com>
12628 * auto-load.c (auto_load_objfile_script_1): Use std::string.
12630 2018-03-17 Tom Tromey <tom@tromey.com>
12632 * target.c (class scoped_target_fd): New.
12633 (target_fileio_close_cleanup): Remove.
12634 (target_fileio_read_alloc_1): Use scoped_target_fd.
12636 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
12638 * silent-rules.mk: New.
12639 * Makefile.in: Include silent-rules.mk
12640 (srcdir, VPATH, top_srcdir): Move up.
12641 (COMPILE): Add ECHO_CXX.
12642 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
12643 (init.c): Add ECHO_INIT_C.
12644 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
12645 (version.c): Add ECHO_GEN.
12646 (printcmd.o): Add ECHO_CXX.
12647 (target-float.o): Add ECHO_CXX.
12648 (ada-exp.o): Add ECHO_CXX.
12649 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
12650 (insight$(EXEEXT)): Add ECHO_CXXLD.
12651 * gnulib/configure.ac: Add AM_SILENT_RULES.
12652 * gnulib/aclocal.m4: Re-generate.
12653 * gnulib/configure: Re-generate.
12654 * gnulib/import/Makefile.in: Re-generate.
12656 2018-03-16 Tom Tromey <tom@tromey.com>
12658 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
12659 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
12660 * utils.c (do_free_section_addr_info)
12661 (make_cleanup_free_section_addr_info): Remove.
12662 * symfile.h (struct other_sections): Add constructor.
12663 (struct section_addr_info): Remove.
12664 (section_addr_info): New typedef.
12665 (struct sym_fns) <sym_offsets>: Change type of parameter.
12666 (build_section_addr_info_from_objfile)
12667 (relative_addr_info_to_section_offsets, addr_info_make_relative)
12668 (default_symfile_offsets, symbol_file_add)
12669 (symbol_file_add_from_bfd)
12670 (build_section_addr_info_from_section_table): Update.
12671 (alloc_section_addr_info, free_section_addr_info): Don't declare.
12672 * symfile.c (alloc_section_addr_info): Remove.
12673 (build_section_addr_info_from_section_table): Change return type.
12675 (build_section_addr_info_from_bfd)
12676 (build_section_addr_info_from_objfile): Likewise.
12677 (free_section_addr_info): Remove.
12678 (relative_addr_info_to_section_offsets): Change type of "addrs".
12679 (addrs_section_compar): Now a std::sort comparator.
12680 (addrs_section_sort): Change return type.
12681 (addr_info_make_relative): Change type of "addrs". Update.
12682 (default_symfile_offsets, syms_from_objfile_1)
12683 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
12684 (symbol_file_add_separate): Update.
12685 (symbol_file_add): Change type of "addrs". Update.
12686 (add_symbol_file_command): Update. Remove cleanups.
12687 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
12689 * symfile-debug.c (debug_sym_offsets): Change type of "info".
12690 * solib.c (solib_read_symbols): Update.
12691 * objfiles.c (objfile_relocate): Update. Remove cleanups.
12692 * machoread.c (macho_symfile_offsets): Update.
12693 * jit.c (jit_bfd_try_read_symtab): Update.
12695 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
12697 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12698 unittests/utils-selftests.c.
12699 * unittests/utils-selftests.c: New file.
12701 2018-03-14 Tom Tromey <tom@tromey.com>
12704 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
12707 2018-03-14 Tom Tromey <tom@tromey.com>
12710 * printcmd.c (printf_pointer): Allow "-" in format.
12712 2018-03-14 Tom Tromey <tom@tromey.com>
12714 * printcmd.c (_initialize_printcmd): Add usage to printf.
12716 2018-03-14 Yao Qi <qiyao@sourceware.org>
12718 * MAINTAINERS: Update my email address.
12720 2018-03-13 Tom Tromey <tom@tromey.com>
12722 * machoread.c (macho_check_dsym): Change filenamep to a
12724 (macho_symfile_read): Update.
12725 * symfile.c (load_command): Use std::string.
12727 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
12729 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
12730 to error message string.
12731 (riscv_register_name): Use xsnprintf instead of sprintf.
12732 (riscv_insn::fetch_instruction): Use gdb_assert instead of
12734 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
12736 (riscv_push_dummy_call): Likewise.
12738 2018-03-12 Tom Tromey <tom@tromey.com>
12740 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
12741 Use gdb::byte_vector.
12742 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
12744 2018-03-12 Yao Qi <yao.qi@linaro.org>
12746 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
12747 parameter type to readable_regcache.
12748 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
12751 2018-03-11 Tom Tromey <tom@tromey.com>
12753 * dwarf2read.c (struct nextfield): Add initializers.
12754 (struct nextfnfield): Remove.
12755 (struct fnfieldlist): Add initializers. Remove "length" and
12756 "head", use std::vector.
12757 (struct decl_field_list): Remove.
12758 (struct field_info): Add initializers.
12759 <fields, baseclasses>: Now std::vector.
12760 <nbaseclasses, nfnfields, typedef_field_list_count,
12761 nested_types_list_count>: Remove.
12762 (dwarf2_add_field, dwarf2_add_type_defn)
12763 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
12764 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
12765 (process_structure_scope): Update.
12767 2018-03-11 Tom Tromey <tom@tromey.com>
12769 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
12770 for use by std::sort.
12771 (build_type_psymtabs_1): Use std::vector.
12773 2018-03-09 Eli Zaretskii <eliz@gnu.org>
12775 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
12776 and LIBMPFR in the printed configuration.
12778 2018-03-08 Tom Tromey <tom@tromey.com>
12780 * source.c (get_filename_and_charpos): Use scoped_fd.
12781 * nto-procfs.c (procfs_open_1): Use scoped_fd.
12782 (procfs_pidlist): Likewise.
12783 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
12784 (iterate_over_mappings): Likewise.
12786 2018-03-08 Tom Tromey <tom@tromey.com>
12788 * infcall.c (struct call_return_meta_info)
12789 <stack_temporaries_enabled>: Remove.
12790 (get_call_return_value, call_function_by_hand_dummy): Update.
12791 * thread.c (disable_thread_stack_temporaries): Remove.
12792 (enable_thread_stack_temporaries): Remove.
12793 (thread_stack_temporaries_enabled_p): Return bool.
12794 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
12795 (get_last_thread_stack_temporary): Update.
12796 * eval.c (evaluate_subexp): Update.
12797 * gdbthread.h (class enable_thread_stack_temporaries): Now a
12798 class, not a function.
12799 (value_ptr, value_vec): Remove typedefs.
12800 (class thread_info) <stack_temporaries_enabled>: Now bool.
12801 <stack_temporaries>: Now a std::vector.
12802 (thread_stack_temporaries_enabled_p)
12803 (value_in_thread_stack_temporaries): Return bool.
12805 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
12807 * remote.c (putpkt_binary): Fix omitted bytes reporting.
12808 (getpkt_or_notif_sane_1): Likewise.
12810 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
12812 * build-id.c (build_id_to_debug_bfd): Use std::string.
12814 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
12816 * build-id.c (find_separate_debug_file_by_buildid): Return
12818 * build-id.h (find_separate_debug_file_by_buildid): Return
12820 * coffread.c (coff_symfile_read): Adjust to std::string.
12821 * elfread.c (elf_symfile_read): Adjust to std::string.
12822 * symfile.c (separate_debug_file_exists): Change parameter to
12824 (find_separate_debug_file): Return std::string.
12825 (find_separate_debug_file_by_debuglink): Return std::string.
12826 * symfile.h (find_separate_debug_file_by_debuglink): Return
12829 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
12831 * common/xml-utils.c (xml_escape_text): Move code to...
12832 (xml_escape_text_append): ... this new function.
12833 * common/xml-utils.h (xml_escape_text_append): New declaration.
12834 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
12836 (_initialize_xml_utils): register test_xml_escape_text_append as
12839 2018-03-07 Alan Hayward <alan.hayward@arm.com>
12841 * defs.h: Remove MAX_REGISTER_SIZE.
12842 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
12844 * python/py-unwind.c (pyuw_sniffer): Likewise.
12846 2018-03-07 Tom Tromey <tom@tromey.com>
12848 * linux-tdep.c (linux_info_proc): Update.
12849 * target.h (struct target_ops) <to_fileio_readlink>: Return
12851 (target_fileio_readlink): Return optional<string>.
12852 * remote.c (remote_hostio_readlink): Return optional<string>.
12853 * inf-child.c (inf_child_fileio_readlink): Return
12855 * target.c (target_fileio_readlink): Return optional<string>.
12857 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
12859 * regcache.c (cooked_read_test): Add riscv to the list of
12860 architectures that have a save_reggroup.
12862 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
12864 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
12865 value is not a dynamic class object.
12867 2018-03-06 Tom Tromey <tom@tromey.com>
12869 * rust-exp.y: Formatting fixes.
12871 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12873 * riscv-tdep.c (riscv_register_name): Remove target description
12875 (riscv_gdbarch_init): Remove target description check.
12877 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12879 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
12881 * riscv-tdep.h: Likewise.
12883 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12885 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
12886 (riscv_pseudo_register_write): Delete.
12887 (riscv_gdbarch_init): Remove all use of pseudo registers.
12889 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12891 * record-btrace.c (btrace_print_lines): Replace cleanup
12892 parameter with RAII equivalents.
12893 (btrace_insn_history): Replace cleanup with RAII equivalents.
12894 * ui-out.h (make_cleanup_ui_out_list_begin_end,
12895 make_cleanup_ui_out_tuple_begin_end): Remove.
12896 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
12897 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
12898 make_cleanup_ui_out_list_begin_end): Remove.
12900 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12902 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
12903 parameter types to std::vector. Use bool.
12904 (record_btrace_wait): Replace VEC(tp_t) with
12905 std::vector<thread_info *>.
12906 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
12908 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12910 * record-btrace.c (record_btrace_disable_callback): Remove.
12911 (struct scoped_btrace_disable): New.
12912 (record_btrace_open): Use scoped_btrace_disable.
12914 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12916 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
12917 reading values from registers.
12919 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12921 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
12924 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12926 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
12927 change parameter type. Use GDB's print functions, and use
12928 core_addr_to_string where appropriate.
12929 (riscv_push_dummy_call): Use core_addr_to_string where
12930 appropriate, update call to riscv_print_arg_location, and reindent
12932 (riscv_return_value): Update call to riscv_print_arg_location.
12934 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12935 Tim Newsome <tim@sifive.com>
12936 Albert Ou <a0u@eecs.berkeley.edu>
12937 Darius Rad <darius@bluespec.com>
12939 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
12940 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
12941 (ALLDEPFILES): Add riscv-tdep.c
12942 * configure.tgt: Add riscv support.
12943 * riscv-tdep.c: New file.
12944 * riscv-tdep.h: New file.
12945 * NEWS: Mention new target.
12946 * MAINTAINERS: Add entry for riscv.
12948 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12950 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
12951 fields within aggregates.
12953 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
12955 * record-btrace.c (btrace_print_lines): Change type of flags to
12956 gdb_disassembly_flags.
12958 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12960 * fbsd-nat.c: Include "inf-ptrace.h".
12961 (USE_SIGTRAP_SIGINFO): Conditionally define.
12962 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
12963 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
12964 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
12966 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
12968 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
12970 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
12971 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
12972 "supports_stopped_by_hw_breakpoint" target methods.
12974 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12976 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
12977 * fbsd-nat.c (debug_fbsd_nat): New variable.
12978 (show_fbsd_nat_debug): New function.
12979 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
12980 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
12982 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12984 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
12985 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
12987 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
12988 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
12991 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12993 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
12994 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
12996 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12998 * charset.c (struct charset_vector): New.
12999 (charsets): Change type to charset_vector.
13000 (find_charset_names): Adjust.
13002 (_initialize_charset): Adjust.
13004 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13006 * progspace.h (struct program_space) <deleted_solibs>: Change
13007 type to std::vector<std::string>.
13008 * progspace.c (clear_program_space_solib_cache): Adjust.
13009 * breakpoint.c (print_solib_event): Adjust.
13010 (check_status_catch_solib): Adjust.
13011 * solib.c (update_solib_list): Adjust.
13012 * ui-out.h (class ui_out) <field_string>: New overload.
13013 * ui-out.c (ui_out::field_string): New overload.
13015 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13017 * progspace.h (struct program_space): Add constructor and
13018 destructor, initialize fields.
13019 (add_program_space): Remove.
13020 * progspace.c (add_program_space): Rename to...
13021 (program_space::program_space): ... this.
13022 (release_program_space): Rename to...
13023 (program_space::~program_space): ... this.
13024 (delete_program_space): Use delete to delete program_space.
13025 (initialize_progspace): Use new to allocate program_space.
13026 * inferior.c (add_inferior_with_spaces): Likewise.
13027 (clone_inferior_command): Likewise.
13028 * infrun.c (follow_fork_inferior): Likewise.
13029 (handle_vfork_child_exec_or_exit): Likewise.
13031 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13033 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
13034 (delim_string_to_char_ptr_vec): Return std::vector of
13035 gdb::unique_xmalloc_ptr.
13036 (dirnames_to_char_ptr_vec_append): Take std::vector of
13037 gdb::unique_xmalloc_ptr.
13038 (dirnames_to_char_ptr_vec): Return std::vector of
13039 gdb::unique_xmalloc_ptr.
13040 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
13041 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
13042 (delim_string_to_char_ptr_vec): Return an std::vector of
13043 gdb::unique_xmalloc_ptr, adjust the code.
13044 (dirnames_to_char_ptr_vec_append): Take an std::vector of
13045 gdb::unique_xmalloc_ptr, adjust the code.
13046 (dirnames_to_char_ptr_vec): Return an std::vector of
13047 gdb::unique_xmalloc_ptr, adjust the code.
13048 * auto-load.c (auto_load_safe_path_vec): Change type to
13049 std::vector of gdb::unique_xmalloc_ptr.
13050 (auto_load_expand_dir_vars): Return an std::vector of
13051 gdb::unique_xmalloc_ptr, adjust the code.
13052 (auto_load_safe_path_vec_update): Adjust.
13053 (filename_is_in_auto_load_safe_path_vec): Adjust.
13054 (auto_load_objfile_script_1): Adjust.
13055 * build-id.c (build_id_to_debug_bfd): Adjust.
13056 * linux-thread-db.c (thread_db_load_search): Adjust.
13057 * source.c (add_path): Adjust.
13059 * symfile.c (find_separate_debug_file): Adjust.
13060 * utils.c (do_free_char_ptr_vec): Remove.
13061 (make_cleanup_free_char_ptr_vec): Remove.
13063 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
13066 * common/pathstuff.c: Conditionally include "<windows.h>".
13068 2018-03-01 Georg Sauthoff <mail@georg.so>
13071 * gcore.in: Quote variables and switch interpreter to bash.
13073 2018-03-01 Tom Tromey <tom@tromey.com>
13075 * dwarf2read.c (alloc_discriminant_info): Fix default_index
13076 assertion. Add assertion for discriminant_index.
13077 (quirk_rust_enum): Use correct base type name in univariant case.
13079 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
13081 * record.c (get_call_history_modifiers): Return a
13082 record_print_flags.
13083 (cmd_record_call_history): Adjust.
13084 * record-btrace.c (record_btrace_call_history): Adjust.
13085 (record_btrace_call_history_range): Adjust.
13086 (record_btrace_call_history_from): Adjust.
13087 * target-debug.h (target_debug_print_record_print_flags): New.
13088 * target-delegates.c: Re-generate.
13089 * target.c (target_call_history): Change flags type.
13090 (target_call_history_from): Likewise.
13091 (target_call_history_range): Likewise.
13092 * target.h (struct target_ops) <target_call_history>: Likewise.
13093 (target_call_history_from): Likewise.
13094 (target_call_history_range): Likewise.
13096 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
13097 Simon Marchi <simon.marchi@polymtl.ca>
13099 * common/common-utils.c: Include "sys/stat.h".
13100 (is_regular_file): Move here from "source.c"; change return
13102 * common/common-utils.h (is_regular_file): New prototype.
13103 * common/pathstuff.c (contains_dir_separator): New function.
13104 * common/pathstuff.h (contains_dir_separator): New prototype.
13105 * source.c: Don't include "sys/stat.h".
13106 (is_regular_file): Move to "common/common-utils.c".
13108 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
13110 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
13111 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
13112 * auto-load.c: Include "common/pathstuff.h".
13113 * common/common-def.h (current_directory): Move here.
13114 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
13116 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
13118 * common/pathstuff.c: New file.
13119 * common/pathstuff.h: New file.
13120 * compile/compile.c: Include "common/pathstuff.h".
13121 * defs.h (current_directory): Move to "common/common-defs.h".
13122 * dwarf2read.c: Include "common/pathstuff.h".
13123 * exec.c: Likewise.
13124 * guile/scm-safe-call.c: Likewise.
13125 * linux-thread-db.c: Likewise.
13126 * main.c: Likewise.
13127 * nto-tdep.c: Likewise.
13128 * objfiles.c: Likewise.
13129 * source.c: Likewise.
13130 * symtab.c: Likewise.
13131 * utils.c: Include "common/pathstuff.h".
13132 (gdb_realpath): Move to "common/pathstuff.c".
13133 (gdb_realpath_keepfile): Likewise.
13134 (gdb_abspath): Likewise.
13135 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
13136 (gdb_realpath_keepfile): Likewise.
13137 (gdb_abspath): Likewise.
13139 2018-02-28 John Baldwin <jhb@FreeBSD.org>
13141 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
13142 wildcard process pid for super_resume for kernels with a
13145 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
13147 * compile/compile.c (get_args): Add additional comments
13148 explaining function.
13150 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
13151 Tom Tromey <tom@tromey.com>
13153 * target.h (memory_write_request_s): Remove typedef. Don't define
13155 (target_write_memory_blocks): Change argument to std::vector.
13156 (struct memory_write_request): Add constructor.
13157 * target-memory.c (compare_block_starting_address): Return bool.
13158 Change argument types.
13159 (claim_memory): Change arguments to use std::vector.
13160 (split_regular_and_flash_blocks, blocks_to_erase)
13161 (compute_garbled_blocks): Likewise.
13162 (cleanup_request_data, cleanup_write_requests_vector): Remove.
13163 (target_write_memory_blocks): Change argument to std::vector.
13164 * symfile.c (struct load_section_data): Add constructor and
13165 destructor. Use std::vector for "requests".
13166 (struct load_progress_data): Add initializers.
13167 (load_section_callback): Update. Use "new".
13168 (clear_memory_write_data): Remove.
13169 (generic_load): Update.
13171 2018-02-27 Alan Hayward <alan.hayward@arm.com>
13173 * arch/aarch64.h: Use common/tdesc.h.
13175 2018-02-26 Maciej W. Rozycki <macro@mips.com>
13177 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
13178 architecture with a 64-bit ABI.
13180 2018-02-26 Maciej W. Rozycki <macro@mips.com>
13182 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
13183 ahead of target description loading.
13185 2018-02-26 Tom Tromey <tom@tromey.com>
13187 * stack.c (backtrace_command_1): Update.
13188 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
13190 * python/py-framefilter.c (py_print_frame)
13191 (gdbpy_apply_frame_filter): Change type of "flags".
13192 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
13194 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
13195 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
13196 * extension.h (enum frame_filter_flag): Rename from
13197 frame_filter_flags.
13198 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
13199 (apply_ext_lang_frame_filter): Change type of "flags".
13200 * extension.c (apply_ext_lang_frame_filter): Change type of
13202 * extension-priv.h (struct extension_language_ops)
13203 <apply_frame_filter>: Change type of "flags".
13205 2018-02-26 Tom Tromey <tom@tromey.com>
13208 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
13209 off-by-one in py_end computation.
13210 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
13212 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
13215 2018-02-26 Tom Tromey <tom@tromey.com>
13217 * dwarf2read.c (struct variant_field): New.
13218 (struct nextfield) <variant>: New field.
13219 (dwarf2_add_field): Handle DW_TAG_variant_part.
13220 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
13221 discriminated union.
13222 (read_structure_type): Handle DW_TAG_variant_part.
13223 (handle_struct_member_die): New function, extracted from
13224 process_structure_scope. Handle DW_TAG_variant.
13225 (process_structure_scope): Handle discriminated unions. Call
13226 handle_struct_member_die.
13228 2018-02-26 Tom Tromey <tom@tromey.com>
13230 * rust-lang.h (rust_last_path_segment): Declare.
13231 * rust-lang.c (rust_last_path_segment): Now public. Change
13233 (struct disr_info): Remove.
13234 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
13235 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
13236 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
13237 (rust_enum_p, rust_enum_variant): New function.
13238 (rust_underscore_fields): Remove "offset" parameter.
13239 (rust_print_enum): New function.
13240 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
13241 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
13242 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
13244 (rust_internal_print_type): New function, from rust_print_type.
13246 (rust_print_type): Call rust_internal_print_type.
13247 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
13248 Update enum handling.
13249 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
13250 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
13251 (rust_union_quirks): New functions.
13252 (process_full_comp_unit, process_full_type_unit): Call
13254 (process_structure_scope): Update rust_unions if necessary.
13256 2018-02-26 Tom Tromey <tom@tromey.com>
13258 * value.h (value_union_variant): Declare.
13259 * valops.c (value_union_variant): New function.
13260 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
13261 (struct discriminant_info): New.
13262 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
13264 (struct main_type) <flag_discriminated_union>: New field.
13266 2018-02-26 Tom Tromey <tom@tromey.com>
13268 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13269 unittests/unpack-selftests.c.
13270 * unittests/unpack-selftests.c: New file.
13271 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
13273 2018-02-26 Yao Qi <yao.qi@linaro.org>
13275 * dwarf2read.c (struct partial_die_info) <read>: New method.
13276 (read_partial_die): Remove the declaration.
13277 (load_partial_dies): Update.
13278 (partial_die_info::partial_die_info):
13279 (read_partial_die): Change it to partial_die_info::read.
13281 2018-02-26 Yao Qi <yao.qi@linaro.org>
13283 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
13284 (fixup_partial_die): Remove declaration.
13285 (scan_partial_symbols): Update.
13286 (partial_die_parent_scope): Likewise.
13287 (partial_die_full_name): Likewise.
13288 (fixup_partial_die): Change it to partial_die_info::fixup.
13290 2018-02-26 Yao Qi <yao.qi@linaro.org>
13292 * dwarf2read.c (read_partial_die): Update the declaration.
13293 (load_partial_dies): Caller update.
13294 (read_partial_die): Remove one argument abbrev_len.
13296 2018-02-26 Yao Qi <yao.qi@linaro.org>
13298 * dwarf2read.c (struct partial_die_info): Add ctor, delete
13299 assignment operator.
13300 (load_partial_dies): Use ctor and copy ctor.
13301 (read_partial_die): Update.
13302 (dwarf2_cu::find_partial_die): Use ctor.
13304 2018-02-26 Yao Qi <yao.qi@linaro.org>
13306 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
13307 (find_partial_die_in_comp_unit): Change it to
13308 dwarf2_cu::find_partial_die.
13309 (find_partial_die): Update.
13311 2018-02-26 Yao Qi <yao.qi@linaro.org>
13313 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
13316 2018-02-26 Yao Qi <yao.qi@linaro.org>
13318 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
13320 2018-02-26 Alan Hayward <alan.hayward@arm.com>
13322 * arch/amd64.h: Use common/tdesc.h.
13323 * arch/i386.c: Likewise.
13324 * arch/i386.h: Likewise.
13325 * arch/tic6x.c: Likewise.
13326 * arch/tdesc.h: Move file from here...
13327 * common/tdesc.h: ...to here.
13328 * features/aarch64-core.c: Regenerate.
13329 * features/aarch64-fpu.c: Regenerate.
13330 * features/i386/32bit-avx.c: Regenerate.
13331 * features/i386/32bit-avx512.c: Regenerate.
13332 * features/i386/32bit-core.c: Regenerate.
13333 * features/i386/32bit-linux.c: Regenerate.
13334 * features/i386/32bit-mpx.c: Regenerate.
13335 * features/i386/32bit-pkeys.c: Regenerate.
13336 * features/i386/32bit-sse.c: Regenerate.
13337 * features/i386/64bit-avx.c: Regenerate.
13338 * features/i386/64bit-avx512.c: Regenerate.
13339 * features/i386/64bit-core.c: Regenerate.
13340 * features/i386/64bit-linux.c: Regenerate.
13341 * features/i386/64bit-mpx.c: Regenerate.
13342 * features/i386/64bit-pkeys.c: Regenerate.
13343 * features/i386/64bit-segments.c: Regenerate.
13344 * features/i386/64bit-sse.c: Regenerate.
13345 * features/i386/x32-core.c: Regenerate.
13346 * features/tic6x-c6xp.c: Regenerate.
13347 * features/tic6x-core.c: Regenerate.
13348 * features/tic6x-gp.c: Regenerate.
13349 * target-descriptions.c: Use common/tdesc.h.
13350 * target-descriptions.h: Likewise.
13352 2018-02-24 Tom Tromey <tom@tromey.com>
13354 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
13355 (try_thread_db_load_from_dir, thread_db_load_search): Use
13357 (info_auto_load_libthread_db_compare): Return bool. Change
13359 (info_auto_load_libthread_db): Use std::vector, std::string.
13362 2018-02-24 Tom Tromey <tom@tromey.com>
13364 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
13366 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
13368 * gdbarch.c: Rebuild.
13369 * gdbarch.h: Rebuild.
13370 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
13371 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
13372 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
13375 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
13377 * gdbtypes.h (sect_offset): Change type to uint64_t.
13378 (sect_offset_str): New function.
13379 * dwarf2read.c (create_addrmap_from_aranges): Use
13381 (error_check_comp_unit_head): Likewise.
13382 (create_debug_type_hash_table): Likewise.
13383 (read_cutu_die_from_dwo): Likewise.
13384 (init_cutu_and_read_dies): Likewise.
13385 (init_cutu_and_read_dies_no_follow): Likewise.
13386 (process_psymtab_comp_unit_reader): Likewise.
13387 (partial_die_parent_scope): Likewise.
13388 (peek_die_abbrev): Likewise.
13389 (process_queue): Likewise.
13390 (dwarf2_physname): Likewise.
13391 (read_namespace_alias): Likewise.
13392 (read_import_statement): Likewise.
13393 (create_dwo_cu_reader): Likewise.
13394 (create_cus_hash_table): Likewise.
13395 (lookup_dwo_cutu): Likewise.
13396 (inherit_abstract_dies): Likewise.
13397 (read_func_scope): Likewise.
13398 (read_call_site_scope): Likewise.
13399 (dwarf2_add_member_fn): Likewise.
13400 (read_common_block): Likewise.
13401 (read_module_type): Likewise.
13402 (read_typedef): Likewise.
13403 (read_subrange_type): Likewise.
13404 (load_partial_dies): Likewise.
13405 (read_partial_die): Likewise.
13406 (find_partial_die): Likewise.
13407 (read_str_index): Likewise.
13408 (dwarf2_string_attr): Likewise.
13409 (build_error_marker_type): Likewise.
13410 (lookup_die_type): Likewise.
13411 (dump_die_shallow): Likewise.
13412 (follow_die_ref): Likewise.
13413 (dwarf2_fetch_die_loc_sect_off): Likewise.
13414 (dwarf2_fetch_constant_bytes): Likewise.
13415 (follow_die_sig): Likewise.
13416 (get_signatured_type): Likewise.
13417 (get_DW_AT_signature_type): Likewise.
13418 (dwarf2_find_containing_comp_unit): Likewise.
13419 (set_die_type): Likewise.
13421 2018-02-21 John Baldwin <jhb@FreeBSD.org>
13423 * arch/aarch64.c: Include "common-defs.h".
13424 * arch/amd64.c: Likewise.
13425 * arch/i386.c: Likewise.
13427 2018-02-21 Tom Tromey <tom@tromey.com>
13429 * value.h: (extract_field_op): Update.
13430 * eval.c (extract_field_op): Return a const char *.
13431 * expression.h (parse_expression_for_completion): Update.
13432 * completer.c (complete_expression): Update.
13433 (add_struct_fields): Make fieldname const.
13434 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
13435 (mark_completion_tag, parse_exp_in_context_1): Update.
13436 (parse_expression_for_completion): Change "name" to
13437 unique_xmalloc_ptr*.
13439 2018-02-21 Tom Tromey <tom@tromey.com>
13441 * infcall.c (call_function_by_hand_dummy): Use std::vector.
13443 2018-02-21 Yao Qi <yao.qi@linaro.org>
13445 * avr-tdep.c (avr_read_pc): Change parameter type to
13447 * gdbarch.sh (read_pc): Likewise.
13448 * gdbarch.c: Re-generated.
13449 * gdbarch.h: Re-generated.
13450 * hppa-tdep.c (hppa_read_pc): Change parameter type to
13452 * ia64-tdep.c (ia64_read_pc): Likewise.
13453 * mips-tdep.c (mips_read_pc): Likewise.
13454 * spu-tdep.c (spu_read_pc): Likewise.
13456 2018-02-21 Yao Qi <yao.qi@linaro.org>
13458 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
13459 * regcache-dump.c: New file.
13460 * regcache.c: Move register_dump to regcache-dump.c.
13461 (maintenance_print_registers): Likewise.
13462 (maintenance_print_raw_registers): Likewise.
13463 (maintenance_print_cooked_registers): Likewise.
13464 (maintenance_print_register_groups): Likewise.
13465 (maintenance_print_remote_registers): Likewise.
13466 (_initialize_regcache): Likewise.
13467 * regcache.h (register_dump): Moved from regcache.c.
13469 2018-02-21 Yao Qi <yao.qi@linaro.org>
13471 * regcache.c (regcache::regcache): Update.
13472 (regcache::invalidate): Move it to detached_regcache::invalidate.
13473 (get_thread_arch_aspace_regcache): Update.
13474 (regcache::raw_update): Update.
13475 (regcache::cooked_read): Remove some code.
13476 (regcache::cooked_read_value): Likewise.
13477 (regcache::raw_write): Remove assert on m_readonly_p.
13478 (regcache::raw_supply_integer): Move it to
13479 detached_regcache::raw_supply_integer.
13480 (regcache::raw_supply_zeroed): Likewise.
13481 * regcache.h (detached_regcache) <raw_supply_integer>: New
13483 <raw_supply_zeroed, invalidate>: Likewise.
13484 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
13485 <invalidate>: Likewise.
13486 <m_readonly_p>: Removed.
13488 2018-02-21 Yao Qi <yao.qi@linaro.org>
13490 * infcmd.c (get_return_value): Let stop_regs point to
13491 get_current_regcache.
13492 * regcache.c (regcache::regcache): Remove.
13493 (register_dump_reg_buffer): New class.
13494 (regcache_print): Adjust.
13495 * regcache.h (regcache): Remove constructors.
13497 2018-02-21 Yao Qi <yao.qi@linaro.org>
13499 * regcache.c (class register_dump): New class.
13500 (register_dump_regcache, register_dump_none): New class.
13501 (register_dump_remote, register_dump_groups): New class.
13502 (regcache_print): Update.
13503 * regcache.h (regcache_dump_what): Move it to regcache.c.
13504 (regcache) <dump>: Remove.
13506 2018-02-21 Yao Qi <yao.qi@linaro.org>
13508 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
13510 (jit_unwind_reg_set_impl): Call raw_supply.
13511 (jit_frame_sniffer): Use reg_buffer_rw.
13512 * record-full.c (record_full_core_regbuf): Change its type.
13513 (record_full_core_open_1): Use reg_buffer_rw.
13514 (record_full_close): Likewise.
13515 (record_full_core_fetch_registers): Use regcache->raw_supply.
13516 (record_full_core_store_registers): Likewise.
13517 * regcache.c (regcache::get_register_status): Move it to
13519 (regcache_raw_set_cached_value): Remove.
13520 (regcache::raw_set_cached_value): Remove.
13521 (regcache::raw_write): Call raw_supply.
13522 (regcache::raw_supply): Move it to reg_buffer_rw.
13523 * regcache.h (regcache_raw_set_cached_value): Remove.
13524 (reg_buffer_rw): New class.
13526 2018-02-21 Yao Qi <yao.qi@linaro.org>
13528 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
13529 readonly_detached_regcache.
13530 (dummy_frame_prev_register): Use regcache->cooked_read.
13531 * frame.c (frame_save_as_regcache): Change return type.
13532 (frame_pop): Update.
13533 * frame.h (frame_save_as_regcache): Update declaration.
13534 * inferior.h (get_infcall_suspend_state_regcache): Update
13536 * infrun.c (infcall_suspend_state) <registers>: use
13537 readonly_detached_regcache.
13538 (save_infcall_suspend_state): Don't use regcache_dup.
13539 (get_infcall_suspend_state_regcache): Change return type.
13540 * linux-fork.c (struct fork_info) <savedregs>: Change to
13541 readonly_detached_regcache.
13543 (fork_save_infrun_state): Don't use regcache_dup.
13544 (info_checkpoints_command): Adjust.
13545 * mi/mi-main.c (register_changed_p): Update declaration.
13546 (mi_cmd_data_list_changed_registers): Use
13547 readonly_detached_regcache.
13548 (register_changed_p): Change parameter type to
13549 readonly_detached_regcache.
13550 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
13551 readonly_detached_regcache.
13552 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
13553 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
13555 (regcache::save): Move it to reg_buffer.
13556 (regcache::restore): Change parameter type.
13557 (regcache_dup): Remove.
13558 * regcache.h (reg_buffer) <save>: New method.
13559 (readonly_detached_regcache): New class.
13560 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
13561 readonly_detached_regcache.
13562 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
13564 2018-02-21 Yao Qi <yao.qi@linaro.org>
13566 * frame.c (frame_save_as_regcache): Use regcache method save.
13567 (frame_pop): Use regcache method restore.
13568 * infrun.c (restore_infcall_suspend_state): Likewise.
13569 * linux-fork.c (fork_load_infrun_state): Likewise.
13570 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
13572 * regcache.c (regcache_save): Remove.
13573 (regcache::restore): More asserts.
13574 (regcache_cpy): Remove.
13575 * regcache.h (regcache_save): Remove the declaration.
13576 (regcache::restore): Move from private to public.
13577 Remove the friend declaration of regcache_cpy.
13578 (regcache_cpy): Remove declaration.
13580 2018-02-21 Yao Qi <yao.qi@linaro.org>
13582 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
13583 parameter type to 'readable_regcache *'.
13584 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
13585 * arm-tdep.c (arm_neon_quad_read): Likewise.
13586 (arm_pseudo_read): Likewise.
13587 * avr-tdep.c (avr_pseudo_register_read): Likewise.
13588 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
13589 * frv-tdep.c (frv_pseudo_register_read): Likewise.
13590 * gdbarch.c: Re-generated.
13591 * gdbarch.h: Re-generated.
13592 * gdbarch.sh (pseudo_register_read): Change parameter type to
13593 'readable_regcache *'.
13594 (pseudo_register_read_value): Likewise.
13595 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
13596 (h8300_pseudo_register_read): Likewise.
13597 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
13598 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
13599 (i386_pseudo_register_read_into_value): Likewise.
13600 (i386_pseudo_register_read_value): Likewise.
13601 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
13603 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
13604 * m32c-tdep.c (m32c_raw_read): Likewise.
13605 (m32c_read_flg): Likewise.
13606 (m32c_banked_register): Likewise.
13607 (m32c_banked_read): Likewise.
13608 (m32c_sb_read): Likewise.
13609 (m32c_part_read): Likewise.
13610 (m32c_cat_read): Likewise.
13611 (m32c_r3r2r1r0_read): Likewise.
13612 (m32c_pseudo_register_read): Likewise.
13613 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
13614 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
13615 (mep_pseudo_cr64_read): Likewise.
13616 (mep_pseudo_register_read): Likewise.
13617 * mips-tdep.c (mips_pseudo_register_read): Likewise.
13618 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
13619 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
13620 * regcache.c (regcache::raw_read): Move it to readable_regcache.
13621 (regcache::cooked_read): Likewise.
13622 (regcache::cooked_read_value): Likewise.
13623 (regcache_cooked_read_signed):
13624 (regcache::cooked_read): Likewise.
13625 * regcache.h (readable_regcache): New class.
13626 (regcache): Inherit readable_regcache. Move some methods to
13628 * rl78-tdep.c (rl78_pseudo_register_read): Change
13629 parameter type to 'readable_regcache *'.
13630 * rs6000-tdep.c (do_regcache_raw_read): Remove.
13631 (e500_pseudo_register_read): Change parameter type to
13632 'readable_regcache *'.
13633 (dfp_pseudo_register_read): Likewise.
13634 (vsx_pseudo_register_read): Likewise.
13635 (efpr_pseudo_register_read): Likewise.
13636 * s390-tdep.c (s390_pseudo_register_read): Likewise.
13637 * sh-tdep.c (sh_pseudo_register_read): Likewise.
13638 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
13639 (sh64_pseudo_register_read): Likewise.
13640 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
13641 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
13642 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
13643 (spu_pseudo_register_read): Likewise.
13644 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
13645 (xtensa_pseudo_register_read): Likewise.
13647 2018-02-21 Yao Qi <yao.qi@linaro.org>
13649 * regcache.c (regcache::regcache): Call reg_buffer ctor.
13650 (regcache::arch): Move it to reg_buffer::arch.
13651 (regcache::register_buffer): Likewise.
13652 (regcache::assert_regnum): Likewise.
13653 (regcache::num_raw_registers): Likewise.
13654 * regcache.h (reg_buffer): New class.
13655 (regcache): Inherit reg_buffer.
13657 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
13659 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
13660 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
13662 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
13664 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
13666 2018-02-19 Alan Hayward <alan.hayward@arm.com>
13668 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
13669 (SFILES): Remove common/*.c files.
13670 (COMMON_OBS): Remove some *.o files built from common/*.c files.
13671 * common/common.host: Add common reference.
13672 * configure.ac: Likewise.
13673 * configure: Regenerate.
13675 2018-02-16 Yao Qi <yao.qi@linaro.org>
13677 * block.c (block_namespace_info): Inherit allocate_on_obstack.
13678 (block_initialize_namespace): Use new.
13679 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
13680 (dwarf2_free_objfile): Use delete.
13681 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
13682 (copy_type_recursive): Use new.
13683 * gdb_obstack.h (allocate_on_obstack): New.
13685 2018-02-15 Yao Qi <yao.qi@linaro.org>
13688 * inferior.c (exit_inferior_1): Reset inf->control.
13690 2018-02-15 Joel Brobecker <brobecker@adacore.com>
13692 * ada-lang.c (ada_to_fixed_value_create): Delete advance
13695 2018-02-14 Pedro Alves <palves@redhat.com>
13697 * frame-unwind.c (frame_unwind_try_unwinder): Always call
13698 frame_cleanup_after_sniffer on exception.
13700 2018-02-14 Tom Tromey <tom@tromey.com>
13702 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
13704 (solib_bfd_open): Make pathname const.
13705 * solib.c (solib_bfd_open): Make pathname const.
13706 * solib-spu.c (spu_bfd_fopen): Make name const.
13707 (spu_bfd_open): Make pathname const.
13708 * solib-darwin.c (darwin_bfd_open): Make pathname const.
13709 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
13711 2018-02-14 Tom Tromey <tom@tromey.com>
13713 * symfile.c (symfile_bfd_open): Update.
13714 * source.h (openp, source_full_path_of, find_and_open_source):
13715 Change argument type to unique_xmalloc_ptr.
13716 * source.c (openp): Take a unique_xmalloc_ptr.
13717 (source_full_path_of, find_and_open_source): Likewise.
13718 (open_source_file, symtab_to_fullname): Update.
13719 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
13720 unique_xmalloc_ptr.
13721 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
13722 (exec_file_find): Update.
13723 * psymtab.c (psymtab_to_fullname): Update.
13724 * nto-tdep.h (nto_find_and_open_solib): Update.
13725 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
13726 unique_xmalloc_ptr.
13727 * exec.c (exec_file_attach): Update.
13728 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
13729 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
13731 2018-02-14 Tom Tromey <tom@tromey.com>
13733 * solib.c: Include source.h.
13734 * nto-tdep.c: Include source.h.
13735 * mi/mi-cmd-env.c: Include source.h.
13736 * infcmd.c: Include source.h.
13737 * exec.c: Include source.h.
13738 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
13739 (add_path, directory_switch, source_path, init_source_path): Move
13741 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
13742 (add_path, directory_switch, source_path, init_source_path):
13745 2018-02-14 Tom Tromey <tom@tromey.com>
13747 * solist.h (exec_file_find, solib_find): Return
13748 unique_xmalloc_ptr.
13749 (solib_bfd_fopen): Take a const char *.
13750 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
13751 (exec_file_find, solib_find): Likewise.
13752 (solib_bfd_fopen): Do not take ownership of "pathname".
13753 (solib_bfd_open): Use unique_xmalloc_ptr.
13754 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
13755 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
13756 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
13757 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
13759 2018-02-14 Joel Brobecker <brobecker@adacore.com>
13761 * ada-lang.c (name_match_type_from_name): Remove reference to
13762 ada_name_for_lookup in function's documentation.
13763 * ada-lang.h (ada_name_for_lookup): Delete declaration.
13765 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
13767 * defs.h (enum openp_flags): New enum.
13768 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
13769 Move to enum openp_flags.
13770 (openp_flags): New enum flags.
13771 (openp): Change parameter type to openp_flags.
13772 * source.c (openp): Change parameter type to openp_flags.
13773 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
13774 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
13776 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
13778 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
13781 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
13783 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
13785 (class dwarf2_queue_guard): ...the destructor of this new class.
13786 (dw2_do_instantiate_symtab): Create instance of the new class
13787 dwarf2_queue_guard, remove cleanup.
13789 2018-02-09 Tom Tromey <tom@tromey.com>
13791 * source.c (find_source_lines): Don't reference past the end of
13794 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13796 * remote.c (remote_btrace_maybe_reopen): Change error message.
13797 * btrace.c (btrace_enable): Likewise.
13798 (parse_xml_btrace): Likewise.
13799 (parse_xml_btrace_conf): Likewise.
13801 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13803 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
13804 (linux_enable_pt, linux_enable_bts): Call
13805 diagnose_perf_event_open_fail.
13807 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13809 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
13810 Remove parameter and change return type. Update callers. Move it.
13811 (linux_enable_bts, linux_enable_pt): Improve error message.
13812 (linux_enable_pt): Remove zero buffer size check.
13813 (linux_enable_btrace): Improve error messages. Remove NULL return
13816 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13818 * btrace.c (btrace_enable): Remove target_supports_btrace call.
13819 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
13820 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
13821 (linux_supports_pt, linux_supports_btrace): Remove.
13822 (linux_enable_bts): Call cpu_supports_bts.
13823 * nat/linux-btrace.h (linux_supports_btrace): Remove.
13824 * remote.c (remote_supports_btrace): Remove.
13825 (init_remote_ops): Remove remote_supports_btrace.
13826 * target-delegates.c: Regenerated.
13827 * target.c (target_supports_btrace): Remove.
13828 * target.h (target_ops) <to_supports_btrace>: Remove
13829 (target_supports_btrace): Remove.
13830 * x86-linux-nat.c (x86_linux_create_target): Remove
13831 linux_supports_btrace.
13833 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13835 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
13837 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
13838 exception and use message in own exception.
13840 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13842 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
13843 (perf_event_pt_event_type): Use gdb_file_up.
13844 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
13845 scoped_fd, and scoped_mmap.
13847 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13849 * common/scoped_mmap.h: New.
13850 * unittests/scoped_mmap-selftest.c: New.
13851 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13852 unittests/scoped_mmap-selftest.c.
13854 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13856 * common/scoped_fd.h: New.
13857 * unittests/scoped_fd-selftest.c: New.
13858 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13859 unittests/scoped_fd-selftest.c.
13861 2018-02-09 Tom Tromey <tom@tromey.com>
13863 * auto-load.c (auto_load_section_scripts): Use
13864 gdb::unique_xmalloc_ptr.
13866 2018-02-09 Tom Tromey <tom@tromey.com>
13868 * auto-load.c (execute_script_contents): Use std::string.
13870 2018-02-09 Joel Brobecker <brobecker@adacore.com>
13872 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
13873 Python function, rather than a new command.
13875 2018-02-08 Tom Tromey <tom@tromey.com>
13877 * solib.c (solib_find_1): Use std::string.
13878 (solib_bfd_fopen): Use unique_xmalloc_ptr.
13880 2018-02-08 Tom Tromey <tom@tromey.com>
13882 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
13884 2018-02-08 Tom Tromey <tom@tromey.com>
13886 * source.c (find_source_lines): Use gdb::def_vector.
13888 2018-02-08 Tom Tromey <tom@tromey.com>
13890 * macrocmd.c (struct temporary_macro_definition): New.
13891 (macro_define_command): Use temporary_macro_definition. Remove
13893 (free_macro_definition_ptr): Remove.
13895 2018-02-08 Tom Tromey <tom@tromey.com>
13897 * macroexp.c (maybe_expand): Use std::string.
13899 2018-02-08 Tom Tromey <tom@tromey.com>
13901 * macroexp.c (struct macro_buffer): Add initializers for some
13903 (init_buffer, init_shared_buffer, free_buffer)
13904 (free_buffer_return_text): Remove.
13905 (macro_buffer): New constructors.
13906 (~macro_buffer): New destructor.
13907 (macro_buffer::set_shared): New method.
13908 (macro_buffer::resize_buffer, macro_buffer::appendc)
13909 (macro_buffer::appendmem): Now methods, not free functions.
13910 (set_token, append_tokens_without_splicing, stringify)
13911 (macro_stringify): Update.
13912 (gather_arguments): Change return type. Remove argc_p argument,
13913 add args_ptr argument. Use std::vector.
13914 (substitute_args): Remove argc argument. Accept std::vector.
13915 (expand): Update. Use std::vector.
13916 (scan, macro_expand, macro_expand_next): Update.
13918 2018-02-08 Tom Tromey <tom@tromey.com>
13920 * symtab.c (default_collect_symbol_completion_matches_break_on):
13921 Use unique_xmalloc_ptr.
13922 * macroscope.h: (sal_macro_scope, user_macro_scope)
13923 (default_macro_scope): Return unique_xmalloc_ptr.
13924 * macroscope.c (sal_macro_scope, user_macro_scope)
13925 (default_macro_scope): Return unique_xmalloc_ptr.
13926 * macroexp.h (macro_expand, macro_expand_once): Return
13927 unique_xmalloc_ptr.
13928 * macroexp.c (macro_expand, macro_expand_once): Return
13929 unique_xmalloc_ptr.
13930 * macrocmd.c (macro_expand_command, macro_expand_once_command)
13931 (info_macro_command, info_macros_command): Use
13932 unique_xmalloc_ptr.
13933 * compile/compile-c-support.c (write_macro_definitions): Use
13934 unique_xmalloc_ptr.
13935 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
13937 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
13939 * value.c (value_static_field): Assign field type instead of
13940 containing type when returning an optimized out value.
13942 2018-02-06 Yao Qi <yao.qi@linaro.org>
13944 * ft32-tdep.c (ft32_read_pc): Remove.
13945 (ft32_write_pc): Remove.
13946 (ft32_gdbarch_init): Update.
13947 * m32r-tdep.c (m32r_read_pc): Remove.
13948 (m32r_gdbarch_init): Update.
13949 * mep-tdep.c (mep_read_pc): Remove.
13950 (mep_gdbarch_init): Update.
13951 * microblaze-tdep.c (microblaze_write_pc): Remove.
13952 (microblaze_gdbarch_init): Update.
13953 * mn10300-tdep.c (mn10300_read_pc): Remove.
13954 (mn10300_write_pc): Remove.
13955 (mn10300_gdbarch_init): Update.
13956 * moxie-tdep.c (moxie_read_pc): Remove.
13957 (moxie_write_pc): Remove.
13958 (moxie_gdbarch_init): Update.
13960 2018-02-06 Yao Qi <yao.qi@linaro.org>
13962 * expprint.c (print_subexp_standard): Handle
13963 OP_F77_UNDETERMINED_ARGLIST.
13964 (dump_subexp_body_standard): Likewise.
13966 2018-02-05 Alan Hayward <alan.hayward@arm.com>
13968 * target-descriptions.c (tdesc_element_visitor) Add empty
13970 (tdesc_type): Move make_gdb_type from here.
13971 (tdesc_type_builtin): Likewise.
13972 (tdesc_type_vector): Likewise.
13973 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
13974 (make_gdb_type_struct): Move from tdesc_type_with_fields.
13975 (make_gdb_type_union): Likewise.
13976 (make_gdb_type_flags): Likewise.
13977 (make_gdb_type_enum): Likewise.
13978 (make_gdb_type): New function.
13979 (tdesc_register_type): Use static make_gdb_type.
13981 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
13983 * infcmd.c (default_print_one_register_info): Align natural-format
13984 column values consistently one under another.
13985 (pad_to_column): New function.
13987 2018-02-05 Joel Brobecker <brobecker@adacore.com>
13989 * dwarf2read.c (dwarf2_physname): Move commment.
13991 2018-02-01 Leszek Swirski <leszeks@google.com>
13993 * varobj.c (varobj_formatted_print_options): Allow recursive
13994 pretty printing if pretty printing is enabled.
13996 2018-02-01 Leszek Swirski <leszeks@google.com>
13998 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
13999 names after a structop as a filename.
14001 2018-02-01 Yao Qi <yao.qi@linaro.org>
14003 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
14004 (arm_record_coproc_data_proc): Likewise.
14006 2018-02-01 Yao Qi <yao.qi@linaro.org>
14008 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
14010 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
14012 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
14013 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
14015 2018-01-31 Pedro Alves <palves@redhat.com>
14017 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
14018 * inflow.c (child_terminal_save_inferior): Wrap reference to
14019 tcgetpgrp in HAVE_TERMIOS_H.
14020 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
14022 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
14023 always iterate over all inferiors.
14024 (gdbsim_cntrl_c): Adjust.
14025 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
14027 2018-01-31 Joel Brobecker <brobecker@adacore.com>
14029 * gdbtypes.c (lookup_array_range_type): Make sure the array's
14030 index type is objfile-owned if the element type is as well.
14032 2018-01-31 Joel Brobecker <brobecker@adacore.com>
14036 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
14038 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
14039 "features/s390x-linux64.c".
14040 (_initialize_s390_linux_tdep): Remove initialization of tdescs
14041 s390_linux32 and s390x_linux64.
14042 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
14044 * s390-tdep.c: Include "features/s390-linux32.c" and
14045 "features/s390x-linux64.c".
14046 (s390_tdesc_valid): Add check for tdesc_has_registers.
14047 (s390_gdbarch_init): Make sure there is always a valid tdesc.
14048 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
14049 tdesc_s390x_linux64.
14050 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
14051 tdesc_s390x_linux64 to...
14052 * s390-tdep.h: ...here.
14054 2018-01-30 Pedro Alves <palves@redhat.com>
14057 * config.in, configure: Regenerate.
14058 * configure.ac: Check for getpgid.
14059 * go32-nat.c (go32_pass_ctrlc): New.
14060 (go32_target): Install it.
14061 * inf-child.c (inf_child_target): Install
14062 child_terminal_save_inferior, child_pass_ctrlc and
14064 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
14065 (inf_ptrace_target): No longer install it.
14066 * infcmd.c (interrupt_target_1): Adjust.
14067 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
14068 (child_interrupt): Declare.
14069 (inferior::terminal_state): New.
14070 * inflow.c (struct terminal_info): Update comments.
14071 (inferior_process_group): Delete.
14072 (terminal_is_ours): Delete.
14073 (gdb_tty_state): New.
14074 (child_terminal_init): Adjust.
14075 (is_gdb_terminal, sharing_input_terminal_1)
14076 (sharing_input_terminal): New functions.
14077 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
14078 Set the process's actual process group in the foreground if
14079 possible. Handle is_ours_for_output/is_ours distinction. Don't
14080 mark terminal as the inferior's if not sharing GDB's terminal.
14081 Don't check attach_flag.
14082 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
14083 pass down a target_terminal_state.
14084 (child_terminal_save_inferior): New, factored out from ...
14085 (child_terminal_ours_1): ... this. Handle
14086 target_terminal_state::is_ours_for_output.
14087 (child_interrupt, child_pass_ctrlc): New.
14088 (inflow_inferior_exit): Clear the inferior's terminal_state.
14089 (copy_terminal_info): Copy the inferior's terminal state.
14090 (_initialize_inflow): Remove reference to terminal_is_ours.
14091 * inflow.h (inferior_process_group): Delete.
14092 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
14093 * procfs.c (procfs_target): Don't install procfs_interrupt.
14094 (procfs_interrupt): Delete.
14095 * remote.c (remote_serial_quit_handler): Adjust.
14096 (remote_interrupt): Remove ptid parameter. Adjust.
14097 * target-delegates.c: Regenerate.
14098 * target.c: Include "terminal.h".
14099 (target_terminal::terminal_state): Rename to ...
14100 (target_terminal::m_terminal_state): ... this.
14101 (target_terminal::init): Adjust.
14102 (target_terminal::inferior): Adjust to per-inferior
14104 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
14105 (target_terminal::ours, target_terminal::ours_for_output): Use
14106 target_terminal_is_ours_kind.
14107 (target_interrupt): Remove ptid parameter. Adjust.
14108 (default_target_pass_ctrlc): Adjust.
14109 * target.h (target_ops::to_terminal_save_inferior): New field.
14110 (target_ops::to_interrupt): Remove ptid_t parameter.
14111 (target_interrupt): Remove ptid_t parameter. Update comment.
14112 (target_pass_ctrlc): Update comment.
14113 * target/target.h (target_terminal_state): New scoped enum,
14114 factored out of ...
14115 (target_terminal::terminal_state): ... here.
14116 (target_terminal::inferior): Update comments.
14117 (target_terminal::restore_inferior): New.
14118 (target_terminal::is_inferior, target_terminal::is_ours)
14119 (target_terminal::is_ours_for_output): Adjust.
14120 (target_terminal::scoped_restore_terminal_state): Adjust to
14121 rename, and call restore_inferior() instead of inferior().
14122 (target_terminal::scoped_restore_terminal_state::m_state): Change
14124 (target_terminal::terminal_state): Rename to ...
14125 (target_terminal::m_terminal_state): ... this and change type.
14127 2018-01-30 Pedro Alves <palves@redhat.com>
14129 * linux-nat.c (wait_for_signal): New function.
14130 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
14132 (async_terminal_is_ours)
14133 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
14134 (linux_nat_add_target): Don't override
14135 to_terminal_inferior/to_terminal_ours.
14137 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
14139 * remote.c (remote_follow_fork): Don't call "detach_inferior".
14141 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
14143 * dwarf2read.c (free_dwo_files): Add forward-declaration.
14144 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
14145 dwarf2_per_objfile_free here.
14146 (dwarf2_per_objfile_free): Remove.
14147 (_initialize_dwarf2_read): Don't register
14148 dwarf2_per_objfile_free as a registry cleanup.
14150 2018-01-27 Eli Zaretskii <eliz@gnu.org>
14152 Avoid compilation errors in MinGW native builds
14154 The error is triggered by including python-internal.h, and the
14157 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
14158 from build-gnulib/import/math.h:27,
14159 from d:/usr/Python26/include/pyport.h:235,
14160 from d:/usr/Python26/include/Python.h:58,
14161 from python/python-internal.h:94,
14162 from python/py-arch.c:24:
14163 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
14167 This happens because Python headers define 'hypot' to expand t
14168 '_hypot' in the Windows builds.
14169 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
14170 'hypoth'. This avoids a compilation error.
14172 2018-01-26 Alan Hayward <alan.hayward@arm.com>
14174 * MAINTAINERS (Write After Approval): Fix ordering.
14176 2018-01-26 Alan Hayward <alan.hayward@arm.com>
14178 * MAINTAINERS (Write After Approval): Add Alan Hayward.
14180 2018-01-26 Alan Modra <amodra@gmail.com>
14182 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
14183 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
14184 Remove nop. Make const. Comment.
14185 (powerpc32_plt_stub_so_2): New.
14186 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
14187 Correct count. Update uses.
14188 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
14189 Move common code reading PLT entry word. Correct
14190 powerpc32_plt_stub PLT address calculation.
14191 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
14192 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
14193 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
14194 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
14195 (ppc64_standard_linkage8): Likewise.
14196 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
14197 Correct insns description.
14198 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
14200 2018-01-24 Pedro Alves <palves@redhat.com>
14202 GCC PR libstdc++/83906
14203 * gdbtypes.c (operator==(const dynamic_prop &,
14204 const dynamic_prop &)): New.
14205 (operator==(const range_bounds &, const range_bounds &)): New.
14206 (check_types_equal): Use them instead of memcmp.
14207 * gdbtypes.h (operator==(const dynamic_prop &,
14208 const dynamic_prop &)): Declare.
14209 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
14210 (operator==(const range_bounds &, const range_bounds &)): Declare.
14211 (operator!=(const range_bounds &, const range_bounds &)): Declare.
14213 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14215 * s390-linux-tdep.c (s390_record_address_mask)
14216 (s390_record_calc_disp_common, s390_record_calc_disp)
14217 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
14218 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
14219 (s390_process_record): Move to s390-tdep.c.
14220 (s390_linux_init_abi_any): Adjust.
14221 * s390-tdep.c (s390_record_address_mask)
14222 (s390_record_calc_disp_common, s390_record_calc_disp)
14223 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
14224 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
14225 (s390_process_record): Moved from s390-linux-tdep.c
14226 (s390_gdbarch_init): Adjust.
14228 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14230 * s390-linux-nat.c (s390-tdep.h): New include.
14231 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
14232 (HFILES_NO_SRCDIR): Add s390-tdep.h.
14233 (ALLDEPFILES): Add s390-tdep.c.
14234 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
14235 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
14236 * s390-tdep.h: ...this. New file.
14237 * s390-linux-tdep.c (s390-tdep.h): New include.
14238 (_initialize_s390_tdep): Rename to...
14239 (_initialize_s390_linux_tdep): ...this and adjust.
14240 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
14241 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
14243 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
14244 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
14245 (s390_is_partial_instruction, s390_software_single_step)
14246 (is_non_branch_ril, s390_displaced_step_copy_insn)
14247 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
14248 (s390_prologue_data, s390_addr, s390_store, s390_load)
14249 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
14250 (s390_register_call_saved, s390_guess_tracepoint_registers)
14251 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
14252 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
14253 (s390_pseudo_register_name, s390_pseudo_register_type)
14254 (s390_pseudo_register_read, s390_pseudo_register_write)
14255 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
14256 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
14257 (s390_addr_bits_remove, s390_address_class_type_flags)
14258 (s390_address_class_type_flags_to_name)
14259 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
14260 (s390_function_arg_float, s390_function_arg_vector)
14261 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
14262 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
14263 (s390_frame_align, s390_register_return_value, s390_return_value)
14264 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
14265 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
14266 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
14267 (s390_trad_frame_prev_register, s390_unwind_cache)
14268 (s390_prologue_frame_unwind_cache)
14269 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
14270 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
14271 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
14272 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
14273 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
14274 (s390_frame_base_address, s390_local_base_address)
14275 (s390_frame_base, s390_gcc_target_options)
14276 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
14277 (s390_validate_reg_range, s390_tdesc_valid)
14278 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
14279 * s390-tdep.c: ...this. New file.
14281 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14283 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
14284 (s390_process_record, s390_gdbarch_tdep_alloc)
14285 (s390_linux_init_abi_any): Use/set new hook.
14287 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14289 * s390-linux-tdep.c (osabi.h): New include.
14290 (s390_linux_init_abi_31, s390_linux_init_abi_64)
14291 (s390_linux_init_abi_any): New functions.
14292 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
14294 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14296 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
14297 tdesc_has_registers check
14299 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14301 * s390-linux-tdep.c (s390_tdesc_valid): New function.
14302 (s390_validate_reg_range): New macro.
14303 (s390_gdbarch_init): Adjust.
14305 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14307 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
14308 (s390_gdbarch_tdep_alloc): Adjust.
14309 (s390_gdbarch_init): Adjust.
14311 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14313 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
14314 <have_tdb>: Change type to bool.
14315 (s390_gdbarch_tdep_alloc): Adjust.
14316 (s390_gdbarch_init): Adjust.
14318 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14320 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
14321 (gdbarch_tdep) <have_upper, have_vx>: New fields.
14322 (s390_gdbarch_tdep_alloc): New function.
14323 (s390_gdbarch_init): Allocate tdep at start and use its fields
14324 instead of separate variables.
14326 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14328 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
14329 when looking for cached gdbarch and add comment for remaining.
14331 2018-01-22 Pedro Alves <palves@redhat.com>
14332 Sergio Durigan Junior <sergiodj@redhat.com>
14334 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
14337 2018-01-22 Maciej W. Rozycki <macro@mips.com>
14339 * MAINTAINERS: Update my company e-mail address.
14341 2018-01-22 Yao Qi <yao.qi@linaro.org>
14343 * regcache.c (cooked_write_test): New function.
14344 (_initialize_regcache): Register the test.
14346 2018-01-22 Yao Qi <yao.qi@linaro.org>
14348 * ia64-tdep.c (ia64_pseudo_register_read): Call
14349 regcache->cooked_read instead of regcache_cooked_read_unsigned.
14350 * m32c-tdep.c (m32c_cat_read): Likewise.
14351 (m32c_r3r2r1r0_read): Likewise.
14352 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
14353 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
14355 2018-01-22 Yao Qi <yao.qi@linaro.org>
14357 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
14358 method raw_read instead of regcache_raw_read.
14359 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
14360 * arm-tdep.c (arm_neon_quad_read): Likewise.
14361 * avr-tdep.c (avr_pseudo_register_read): Likewise.
14362 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
14363 * frv-tdep.c (frv_pseudo_register_read): Likewise.
14364 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
14365 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
14366 (i386_pseudo_register_read_into_value): Likewise.
14367 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
14368 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
14369 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
14370 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
14371 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
14372 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
14373 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
14374 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
14375 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
14377 2018-01-22 Yao Qi <yao.qi@linaro.org>
14379 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
14380 * configure.tgt: Remove target mt.
14381 * mt-tdep.c: Remove.
14382 * regcache.c (cooked_read_test): Remove the check for mt.
14384 2018-01-22 Yao Qi <yao.qi@linaro.org>
14386 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
14387 instead of gdbarch_pseudo_register_read_value.
14389 2018-01-22 Joel Brobecker <brobecker@adacore.com>
14391 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
14394 2018-01-22 Joel Brobecker <brobecker@adacore.com>
14396 * linespec.c (create_sals_line_offset): Remove code that preserved
14397 the symtab_and_line's line number.
14399 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
14401 * varobj.c (varobj_create): Don't set valid_block when creating a
14404 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
14406 * varobj.c (varobj_create): Remove out of date comment.
14408 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
14411 * ada-exp.y (write_var_from_sym): Pass extra parameter when
14412 updating innermost block.
14413 * parse.c (innermost_block_tracker::update): Take extra type
14414 parameter, and check types match before updating innermost block.
14415 (write_dollar_variable): Update innermost block for registers.
14416 * parser-defs.h (enum innermost_block_tracker_type): New enum.
14417 (innermost_block_tracker::innermost_block_tracker): Initialise
14419 (innermost_block_tracker::reset): Take type parameter.
14420 (innermost_block_tracker::update): Take type parameter, and pass
14421 type through as needed.
14422 (innermost_block_tracker::m_types): New member.
14423 * varobj.c (varobj_create): Pass type when reseting innermost
14426 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
14428 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
14429 * ada-lang.c (resolve_subexp): Likewise.
14430 * breakpoint.c (set_breakpoint_condition) Likewise.
14431 (watch_command_1) Likewise.
14432 * c-exp.y (variable): Likewise.
14433 * d-exp.y (PrimaryExpression): Likewise.
14434 * f-exp.y (variable): Likewise.
14435 * go-exp.y (variable): Likewise.
14436 * m2-exp.y (variable): Likewise.
14437 * objfiles.c (objfile::~objfile): Likewise.
14438 * p-exp.y (variable): Likewise.
14439 * parse.c (innermost_block): Change type.
14440 * parser-defs.h (class innermost_block_tracker): New.
14441 (innermost_block): Change to innermost_block_tracker.
14442 * printcmd.c (display_command): Switch to innermost_block API.
14443 (do_one_display): Likewise.
14444 * rust-exp.y (do_one_display): Likewise.
14445 * symfile.c (clear_symtab_users): Likewise.
14446 * varobj.c (varobj_create): Switch to innermost_block API, replace
14447 use of innermost_block with block stored on varobj object.
14449 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
14451 * expression.h (innermost_block): Remove declaration.
14452 * varobj.c: Add 'parser-defs.h' include.
14454 2018-01-19 Tom Tromey <tom@tromey.com>
14456 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
14457 symbols in the static and global blocks.
14459 2018-01-19 James Clarke <jrtc27@jrtc27.com>
14461 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
14462 gdb_ptrace.h, and move including gdb_wait.h ...
14463 * nat/linux-ptrace.h: ... to here.
14465 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
14467 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
14468 inf_ptrace_detach_success.
14469 (inf_ptrace_detach_success): Add inferior parameter, use it
14470 instead of inferior_ptid, pass it to detach_inferior.
14471 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
14473 * inferior.c (detach_inferior): Add overload that takes an
14475 * inferior.h (detach_inferior): Likewise.
14476 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
14477 use inferior_ptid, adjust call to inf_ptrace_detach_success.
14478 * linux-thread-db.c (thread_db_detach): Use inf parameter.
14480 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
14482 * target.h (struct target_ops) <to_detach>: Add inferior
14484 (target_detach): Likewise.
14485 * target.c (dispose_inferior): Pass inferior down.
14486 (target_detach): Pass inferior down. Assert that it is equal to
14487 the current inferior.
14488 * aix-thread.c (aix_thread_detach): Pass inferior down.
14489 * corefile.c (core_file_command): Pass current_inferior() down.
14490 * corelow.c (core_detach): Add inferior parameter.
14491 * darwin-nat.c (darwin_detach): Likewise.
14492 * gnu-nat.c (gnu_detach): Likewise.
14493 * inf-ptrace.c (inf_ptrace_detach): Likewise.
14494 * infcmd.c (detach_command): Pass current_inferior() down to
14496 * infrun.c (follow_fork_inferior): Pass parent_inf to
14498 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
14500 * linux-nat.c (linux_nat_detach): Add inferior parameter.
14501 * linux-thread-db.c (thread_db_detach): Likewise.
14502 * nto-procfs.c (procfs_detach): Likewise.
14503 * procfs.c (procfs_detach): Likewise.
14504 * record.c (record_detach): Likewise.
14505 * record.h (struct inferior): Forward-declare.
14506 (record_detach): Add inferior parameter.
14507 * remote-sim.c (gdbsim_detach): Likewise.
14508 * remote.c (remote_detach_1): Likewise.
14509 (remote_detach): Likewise.
14510 (extended_remote_detach): Likewise.
14511 * sol-thread.c (sol_thread_detach): Likewise.
14512 * target-debug.h (target_debug_print_inferior_p): New macro.
14513 * target-delegates.c: Re-generate.
14514 * top.c (kill_or_detach): Pass inferior down to target_detach.
14515 * windows-nat.c (windows_detach): Add inferior parameter.
14517 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
14519 * target.h (struct target_ops) <to_detach>: Remove args
14521 (target_detach): Likewise.
14522 * target.c (dispose_inferior): Adjust.
14523 (target_detach): Remove args parameter, adjust.
14524 * aix-thread.c (aix_thread_detach): Adjust.
14525 * corefile.c (core_file_command): Adjust.
14526 * corelow.c (core_detach): Adjust.
14527 * darwin-nat.c (darwin_detach): Adjust.
14528 * gnu-nat.c (gnu_detach): Adjust.
14529 * inf-ptrace.c (inf_ptrace_detach): Adjust.
14530 * infcmd.c (detach_command): Adjust
14531 * infrun.c (follow_fork_inferior): Adjust.
14532 (handle_vfork_child_exec_or_exit): Adjust.
14533 * linux-fork.c (linux_fork_detach): Remove args parameter.
14534 * linux-fork.h (linux_fork_detach): Likewise.
14535 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
14536 * linux-thread-db.c (thread_db_detach): Likewise.
14537 * nto-procfs.c (procfs_detach): Likewise.
14538 * procfs.c (procfs_detach): Likewise.
14539 (do_detach): Remove signo parameter.
14540 * record.c (record_detach): Remove args parameter.
14541 * record.h (record_detach): Likewise.
14542 * remote-sim.c (gdbsim_detach): Likewise.
14543 * remote.c (remote_detach_1): Likewise.
14544 (remote_detach): Likewise.
14545 (extended_remote_detach): Likewise.
14546 * sol-thread.c (sol_thread_detach): Likewise.
14547 * target-delegates.c: Re-generate.
14548 * top.c (struct qt_args) <args>: Remove field.
14549 (kill_or_detach): Don't pass args.
14550 (quit_force): Don't set args.
14551 * windows-nat.c (windows_detach): Remove args parameter.
14553 2018-01-19 Yao Qi <yao.qi@linaro.org>
14555 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
14556 (arm_linux_init_abi): Install it.
14558 2018-01-19 Yao Qi <yao.qi@linaro.org>
14560 * osabi.c (gdb_osabi_names): Extend the regexp for
14561 arm-linux-gnueabihf.
14563 2018-01-18 Yao Qi <yao.qi@linaro.org>
14565 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
14567 (abbrev_table::add_abbrev): Update.
14568 (abbrev_table::lookup_abbrev): Update.
14570 2018-01-18 Yao Qi <yao.qi@linaro.org>
14572 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
14574 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
14576 * compile/compile.c (compile_to_object): Convert "triplet_rx"
14579 2018-01-17 Tom Tromey <tom@tromey.com>
14581 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
14583 2018-01-17 Tom Tromey <tom@tromey.com>
14585 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
14586 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
14587 (create_array_type_with_stride): Update.
14588 * dwarf2read.c (set_die_type): Update.
14590 2018-01-17 Tom Tromey <tom@tromey.com>
14592 * dwarf2read.c (delayed_method_info): Remove typedef.
14593 (dwarf2_cu::method_info): Now a std::vector.
14594 (add_to_method_list): Update.
14595 (free_delayed_list): Remove.
14596 (compute_delayed_physnames): Update.
14597 (process_full_comp_unit, process_full_type_unit): Clear the method
14598 list. Remove cleanups.
14599 (psymtab_include_file_name): Add name_holder parameter. Use
14600 unique_xmalloc_ptr.
14601 (dwarf_decode_lines): Update.
14603 2018-01-17 Tom Tromey <tom@tromey.com>
14604 Simon Marchi <simon.marchi@ericsson.com>
14606 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
14607 (dwarf2_per_objfile::free_cached_comp_units)
14608 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
14609 (init_cutu_and_read_dies_no_follow): Update.
14610 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
14611 (dwarf2_cu::~dwarf2_cu): New.
14612 (free_heap_comp_unit, free_stack_comp_unit): Remove.
14613 (age_cached_comp_units, free_one_cached_comp_unit): Update.
14615 2018-01-17 Tom Tromey <tom@tromey.com>
14616 Simon Marchi <simon.marchi@ericsson.com>
14618 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
14619 (struct die_reader_specs) <abbrev_table>: New member.
14620 (struct abbrev_table): Add constructor.
14621 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
14622 <abbrev_obstack>: Now an auto_obstack.
14623 (abbrev_table_up): New typedef.
14624 (init_cu_die_reader): Add abbrev_table parameter.
14625 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
14626 Add result_dwo_abbrev_table.
14627 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
14628 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
14630 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
14632 (skip_children): Update.
14633 (abbrev_table::alloc_abbrev): Rename from
14634 abbrev_table_alloc_abbrev.
14635 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
14636 (abbrev_table::lookup_abbrev): Rename from
14637 abbrev_table_lookup_abbrev.
14638 (abbrev_table_read_table): Return abbrev_table_up.
14639 (abbrev_table_free, abbrev_table_free_cleanup)
14640 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
14641 (load_partial_dies): Update.
14643 2018-01-17 Tom Tromey <tom@tromey.com>
14645 * dwarf2read.c (dwarf2_compute_name): Update comment.
14646 (read_func_scope, read_variable): Update.
14647 (new_symbol): Remove.
14648 (new_symbol_full): Rename to new_symbol.
14650 2018-01-17 Mike Gulick <mgulick@mathworks.com>
14653 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
14654 a warning instead of throwing an error, set section size to 0 and return
14656 * gdb_bfd.h (gdb_bfd_map_section): Update description.
14658 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
14660 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
14662 (linux_ptrace_attach_fail_reason_string): Likewise.
14663 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
14665 (linux_ptrace_attach_fail_reason_string): Likewise.
14666 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
14668 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
14670 * linux-nat.c (linux_nat_attach): Remove xstrdup.
14672 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
14675 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
14676 checking for fs_base/gs_base fields in struct user_regs_struct.
14677 * configure: Regenerate.
14679 2018-01-17 Yao Qi <yao.qi@linaro.org>
14681 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
14683 (aarch64_linux_init_abi): Install it to gdbarch hook
14684 gcc_target_options.
14686 2018-01-15 Pedro Alves <palves@redhat.com>
14688 * common/signals-state-save-restore.c
14689 (save_original_signals_state): Fix typos.
14691 2017-01-12 Tom Tromey <tom@tromey.com>
14692 Sergio Durigan Junior <sergiodj@redhat.com>
14694 * Makefile.in (install-only): Install gdb-add-index.
14696 2018-01-12 John Baldwin <jhb@FreeBSD.org>
14698 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
14700 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
14702 * infrun.c (keep_going_pass_signal): Clear step-over info when
14703 insert_breakpoints fails.
14705 2018-01-11 Pedro Alves <palves@redhat.com>
14708 * infrun.c (resume): Rename to ...
14709 (resume_1): ... this.
14710 (resume): Reimplement as wrapper around resume_1.
14712 2018-01-11 Pedro Alves <palves@redhat.com>
14715 * remote.c (remote_parse_stop_reply): Default to the last-set
14716 general thread instead of to 'magic_null_ptid'.
14718 2018-01-10 Pedro Alves <palves@redhat.com>
14720 * language.h (language_get_symbol_name_matcher): Rename ...
14721 (get_symbol_name_matcher): ... this.
14722 * language.c (language_get_symbol_name_matcher): Ditto.
14723 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
14726 2018-01-10 Pedro Alves <palves@redhat.com>
14730 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
14731 Adjust to use language_get_symbol_name_matcher instead of
14732 language_defn::la_get_symbol_name_matcher.
14733 * language.c (language_get_symbol_name_matcher): If in Ada mode
14734 and the lookup name is a verbatim match, return Ada's matcher.
14735 * language.h (language_get_symbol_name_matcher): Adjust comment.
14736 (ada_lookup_name_info::verbatim_p):: New method.
14738 2018-01-10 Pedro Alves <palves@redhat.com>
14741 * ada-lang.c (ada_collect_symbol_completion_matches): If the
14742 minsym's language is language_auto or language_cplus, pass down
14743 language_ada instead.
14744 * symtab.c (compare_symbol_name): Don't frob symbol language here.
14746 2018-01-10 Pedro Alves <palves@redhat.com>
14749 * minsyms.c (linkage_name_str): New function.
14750 (iterate_over_minimal_symbols): Use it.
14752 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14754 * NEWS: Document that 'info proc' now works on FreeBSD.
14756 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14758 * configure.ac: Check for kinfo_getfile in libutil.
14759 * configure: Regenerate.
14760 * config.in: Regenerate.
14761 * fbsd-nat.c: Include "fbsd-tdep.h".
14762 (fbsd_fetch_cmdline): New.
14763 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
14764 rather than calling error.
14765 (fbsd_info_proc): New.
14766 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
14767 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
14768 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
14770 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14772 * fbsd-nat.c (struct free_deleter): Remove.
14773 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
14775 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14777 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
14778 NULL for an empty pathname.
14780 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14782 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
14783 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
14784 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
14785 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
14786 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
14787 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
14788 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
14789 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
14790 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
14791 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
14792 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
14793 (fbsd_core_fetch_timeval, fbsd_print_sigset)
14794 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
14795 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
14796 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
14798 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
14800 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
14801 (gnu_xfer_auxv): New function.
14802 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
14803 TARGET_OBJECT_AUXV.
14805 2018-01-08 Yao Qi <yao.qi@linaro.org>
14806 Simon Marchi <simon.marchi@ericsson.com>
14808 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
14810 (COMMON_OBS): Remove selftest.o.
14811 * configure.ac: Append selftest-arch.c and common/selftest.c to
14812 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
14813 * configure: Re-generated.
14814 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
14816 (maintenance_info_selftests): Likewise.
14818 2018-01-08 Xavier Roirand <roirand@adacore.com>
14820 * ada-valprint.c (val_print_packed_array_elements): Use
14821 proper number of elements when printing an array indexed
14822 by an enumeration type.
14824 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14826 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
14827 (dw2_get_file_names_reader): Adjust.
14828 (lookup_dwo_signatured_type): Adjust.
14829 (lookup_dwp_signatured_type): Adjust.
14830 (lookup_signatured_type): Adjust.
14831 (create_type_unit_group): Adjust.
14832 (get_type_unit_group): Adjust.
14833 (process_psymtab_comp_unit_reader): Adjust.
14834 (build_type_psymtabs_reader): Adjust.
14835 (scan_partial_symbols): Adjust.
14836 (add_partial_symbol): Adjust.
14837 (add_partial_subprogram): Adjust.
14838 (peek_die_abbrev): Adjust.
14839 (fixup_go_packaging): Adjust.
14840 (process_imported_unit_die): Adjust.
14841 (dwarf2_compute_name): Adjust.
14842 (dwarf2_physname): Adjust.
14843 (read_import_statement): Adjust.
14844 (handle_DW_AT_stmt_list): Adjust.
14845 (read_file_scope): Adjust.
14846 (read_func_scope): Adjust.
14847 (read_lexical_block_scope): Adjust.
14848 (read_call_site_scope): Adjust.
14849 (read_variable): Adjust.
14850 (dwarf2_rnglists_process): Adjust.
14851 (dwarf2_ranges_process): Adjust.
14852 (dwarf2_ranges_read): Adjust.
14853 (dwarf2_get_pc_bounds): Adjust.
14854 (dwarf2_record_block_ranges): Adjust.
14855 (dwarf2_add_field): Adjust.
14856 (dwarf2_add_member_fn): Adjust.
14857 (read_structure_type): Adjust.
14858 (process_structure_scope): Adjust.
14859 (read_enumeration_type): Adjust.
14860 (read_array_type): Adjust.
14861 (mark_common_block_symbol_computed): Adjust.
14862 (read_common_block): Adjust.
14863 (read_namespace_type): Adjust.
14864 (read_namespace): Adjust.
14865 (read_module_type): Adjust.
14866 (read_tag_pointer_type): Adjust.
14867 (read_tag_ptr_to_member_type): Adjust.
14868 (read_tag_string_type): Adjust.
14869 (read_subroutine_type): Adjust.
14870 (read_typedef): Adjust.
14871 (read_base_type): Adjust.
14872 (attr_to_dynamic_prop): Adjust.
14873 (read_subrange_type): Adjust.
14874 (read_unspecified_type): Adjust.
14875 (dwarf2_read_abbrevs): Adjust.
14876 (load_partial_dies): Adjust.
14877 (read_partial_die): Adjust.
14878 (find_partial_die): Adjust.
14879 (guess_partial_die_structure_name): Adjust.
14880 (fixup_partial_die): Adjust.
14881 (read_attribute_value): Adjust.
14882 (read_addr_index): Adjust.
14883 (read_addr_index_from_leb128): Adjust.
14884 (read_str_index): Adjust.
14885 (dwarf2_string_attr): Adjust.
14886 (get_debug_line_section): Adjust.
14887 (dwarf_decode_line_header): Adjust.
14888 (lnp_state_machine::check_line_address): Adjust.
14889 (dwarf_decode_lines_1): Adjust.
14890 (dwarf_decode_lines): Adjust.
14891 (dwarf2_start_symtab): Adjust.
14892 (var_decode_location): Adjust.
14893 (new_symbol_full): Adjust.
14894 (dwarf2_const_value_data): Adjust.
14895 (dwarf2_const_value_attr): Adjust.
14896 (dwarf2_const_value): Adjust.
14897 (die_type): Adjust.
14898 (die_containing_type): Adjust.
14899 (build_error_marker_type): Adjust.
14900 (lookup_die_type): Adjust.
14901 (guess_full_die_structure_name): Adjust.
14902 (anonymous_struct_prefix): Adjust.
14903 (determine_prefix): Adjust.
14904 (dwarf2_name): Adjust.
14905 (follow_die_ref_or_sig): Adjust.
14906 (follow_die_offset): Adjust.
14907 (follow_die_ref): Adjust.
14908 (follow_die_sig_1): Adjust.
14909 (follow_die_sig): Adjust.
14910 (get_signatured_type): Adjust.
14911 (get_DW_AT_signature_type): Adjust.
14912 (decode_locdesc): Adjust.
14913 (dwarf_decode_macros): Adjust.
14914 (cu_debug_loc_section): Adjust.
14915 (fill_in_loclist_baton): Adjust.
14916 (dwarf2_symbol_mark_computed): Adjust.
14917 (init_one_comp_unit): Don't assign
14918 dwarf2_cu::dwarf2_per_objfile.
14919 (set_die_type): Adjust.
14921 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14923 * dwarf2read.c (struct mapped_debug_names): Add constructor.
14924 <dwarf2_per_objfile>: New field.
14925 (dwarf2_per_objfile): Remove global.
14926 (get_dwarf2_per_objfile): New function.
14927 (set_dwarf2_per_objfile): New function.
14928 (dwarf2_build_psymtabs_hard): Change objfile parameter to
14929 dwarf2_per_objfile.
14930 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14931 (read_abbrev_offset): Likewise.
14932 (read_indirect_string): Likewise.
14933 (read_indirect_line_string): Likewise.
14934 (read_indirect_string_at_offset): Likewise.
14935 (read_indirect_string_from_dwz): Likewise.
14936 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14937 dwarf2_per_objfile.
14938 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14939 (create_all_comp_units): Change objfile parameter to
14940 dwarf2_per_objfile.
14941 (create_all_type_units): Likewise.
14942 (process_queue): Add dwarf2_per_objfile parameter.
14943 (read_and_check_comp_unit_head): Likewise.
14944 (lookup_dwo_unit_in_dwp): Likewise.
14945 (get_dwp_file): Likewise.
14946 (process_cu_includes): Likewise.
14947 (struct free_dwo_file_cleanup_data): New struct.
14948 (dwarf2_has_info): Use get_dwarf2_per_objfile and
14949 set_dwarf2_per_objfile.
14950 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
14951 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
14952 context, adjust calls.
14953 (dw2_instantiate_symtab): Likewise.
14954 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
14955 (dw2_get_cu): Likewise.
14956 (create_cu_from_index_list): Change objfile parameter to
14957 dwarf2_per_objfile.
14958 (create_cus_from_index_list): Get dwarf2_per_objfile from
14959 context, adjust calls.
14960 (create_cus_from_index): Likewise.
14961 (create_signatured_type_table_from_index): Change objfile
14962 parameter to dwarf2_per_objfile.
14963 (create_signatured_type_table_from_debug_names): Change objfile
14964 parameter to dwarf2_per_objfile.
14965 (create_addrmap_from_index): Likewise.
14966 (create_addrmap_from_aranges): Likewise.
14967 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
14968 (dw2_setup): Remove.
14969 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
14971 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
14972 get_dwarf2_per_objfile.
14973 (dw2_forget_cached_source_info): Likewise.
14974 (dw2_map_symtabs_matching_filename): Likewise.
14975 (struct dw2_symtab_iterator) <index>: Remove.
14976 <dwarf2_per_objfile>: New field.
14977 (dw2_symtab_iter_init): Replace index parameter with
14978 dwarf2_per_objfile.
14979 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
14980 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
14981 (dw2_print_stats): Likewise.
14982 (dw2_dump): Likewise.
14983 (dw2_expand_symtabs_for_function): Likewise.
14984 (dw2_expand_all_symtabs): Likewise.
14985 (dw2_expand_symtabs_with_fullname): Likewise.
14986 (dw2_expand_marked_cus): Replace index and objfile parameters
14987 with dwarf2_per_objfile.
14988 (dw_expand_symtabs_matching_file_matcher): Add
14989 dwarf2_per_objfile parameter and adjust calls.
14990 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
14992 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
14993 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
14995 (create_cus_from_debug_names_list): Replace objfile parameter
14996 with dwarf2_per_objfile and adjust calls.
14997 (create_cus_from_debug_names): Likewise.
14998 (dwarf2_read_debug_names): Likewise.
14999 (mapped_debug_names::namei_to_name): Adjust call.
15000 (dw2_debug_names_iterator::next): Likewise.
15001 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
15002 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
15003 (dw2_debug_names_dump): Likewise.
15004 (dw2_debug_names_expand_symtabs_for_function): Likewise.
15005 (dw2_debug_names_expand_symtabs_matching): Likewise.
15006 (dwarf2_initialize_objfile): Likewise.
15007 (dwarf2_build_psymtabs): Likewise.
15008 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
15010 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
15011 (read_and_check_comp_unit_head): Likewise.
15012 (read_abbrev_offset): Likewise.
15013 (create_debug_type_hash_table): Likewise.
15014 (create_debug_types_hash_table): Likewise.
15015 (create_all_type_units): Replace objfile parameter with
15016 dwarf2_per_objfile.
15017 (add_type_unit): Add dwarf2_per_objfile parameter.
15018 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
15019 with dwarf2_per_objfile.
15020 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
15021 (lookup_dwp_signatured_type): Likewise.
15022 (lookup_signatured_type): Likewise.
15023 (read_cutu_die_from_dwo): Likewise.
15024 (init_tu_and_read_dwo_dies): Likewise.
15025 (init_cutu_and_read_dies): Likewise.
15026 (init_cutu_and_read_dies_no_follow): Likewise.
15027 (allocate_type_unit_groups_table): Add objfile parameter.
15028 (create_type_unit_group): Use dwarf2_per_objfile from cu.
15029 (get_type_unit_group): Likewise.
15030 (process_psymtab_comp_unit): Update call.
15031 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
15032 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
15033 (print_tu_stats): Likewise.
15034 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
15035 in void* parameter.
15036 (build_type_psymtabs): Change objfile parameter to
15037 dwarf2_per_objfile.
15038 (process_skeletonless_type_unit): Use dwarf2_per_objfile
15039 passed in void* parameter.
15040 (process_skeletonless_type_units): Change objfile parameter to
15041 dwarf2_per_objfile.
15042 (set_partial_user): Likewise.
15043 (dwarf2_build_psymtabs_hard): Likewise.
15044 (read_comp_units_from_section): Likewise.
15045 (create_all_comp_units): Likewise.
15046 (scan_partial_symbols): Update calls.
15047 (add_partial_symbol): Likewise.
15048 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
15049 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
15050 (process_queue): Add dwarf2_per_objfile parameter.
15051 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
15052 (compute_compunit_symtab_includes): Likewise.
15053 (process_cu_includes): Add dwarf2_per_objfile parameter.
15054 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
15055 (process_full_type_unit): Likewise.
15056 (process_imported_unit_die): Update call.
15057 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
15058 (read_file_scope): Likewise.
15059 (allocate_dwo_file_hash_table): Add objfile parameter.
15060 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
15061 (create_cus_hash_table): Likewise.
15062 (create_dwp_hash_table): Likewise.
15063 (create_dwo_unit_in_dwp_v1): Likewise.
15064 (create_dwp_v2_section): Likewise.
15065 (create_dwo_unit_in_dwp_v2): Likewise.
15066 (lookup_dwo_unit_in_dwp): Likewise.
15067 (try_open_dwop_file): Likewise.
15068 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
15069 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
15070 cleanup to include a reference to dwarf2_per_objfile.
15071 (open_dwp_file): Add dwarf2_per_objfile parameter.
15072 (open_and_init_dwp_file): Likewise.
15073 (get_dwp_file): Likewise.
15074 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
15075 (queue_and_load_all_dwo_tus): Update call.
15076 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
15078 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
15079 (dwarf2_ranges_process): Likewise.
15080 (dwarf2_get_pc_bounds): Likewise.
15081 (mark_common_block_symbol_computed): Likewise.
15082 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
15083 (dwarf2_read_abbrevs): Update call.
15084 (read_partial_die): Use dwarf2_per_objfile from cu.
15085 (find_partial_die): Likewise.
15086 (fixup_partial_die): Likewise.
15087 (read_attribute_value): Likewise.
15088 (read_indirect_string_at_offset_from): Add objfile parameter.
15089 (read_indirect_string_at_offset): Add dwarf2_per_objfile
15091 (read_indirect_string_from_dwz): Add objfile parameter.
15092 (read_indirect_string): Add objfile parameter.
15093 (read_addr_index_1): Add dwarf2_per_objfile parameter.
15094 (read_addr_index): Use dwarf2_per_objfile from cu.
15095 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
15097 (read_str_index): Use dwarf2_per_objfile from cu.
15098 (get_debug_line_section): Likewise.
15099 (read_formatted_entries): Add dwarf2_per_objfile parameter.
15100 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
15101 (new_symbol_full): Use dwarf2_per_objfile from cu.
15102 (build_error_marker_type): Likewise.
15103 (lookup_die_type): Likewise.
15104 (determine_prefix): Likewise.
15105 (follow_die_offset): Likewise.
15106 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
15107 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
15108 (dwarf2_fetch_die_type_sect_off): Likewise.
15109 (dwarf2_get_die_type): Likewise.
15110 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
15111 (get_signatured_type): Likewise.
15112 (get_DW_AT_signature_type): Likewise.
15113 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
15114 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
15115 (cu_debug_loc_section): Likewise.
15116 (fill_in_loclist_baton): Likewise.
15117 (dwarf2_symbol_mark_computed): Likewise.
15118 (dwarf2_find_containing_comp_unit): Change objfile parameter to
15119 dwarf2_per_objfile.
15120 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
15122 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
15123 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
15124 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
15125 (set_die_type): Use dwarf2_free_objfile from cu.
15126 (get_die_type_at_offset): Likewise.
15127 (dwarf2_per_objfile_free): Don't assign global variable.
15128 (debug_names) <constructor>: Add dwarf2_per_objfile
15129 parameter, update m_debugstrlookup construction.
15130 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
15132 <m_dwarf2_per_objfile>: New field.
15133 <lookup>: Use m_dwarf2_per_objfile.
15134 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
15135 (psyms_seen_size): Likewise.
15136 (write_gdbindex): Replace objfile parameter with
15137 dwarf2_per_objfile.
15138 (write_debug_names): Likewise.
15139 (write_psymtabs_to_index): Likewise.
15140 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
15143 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
15145 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
15146 <dwarf2_per_objfile>: New field.
15147 (struct dwarf2_per_cu_data) <objfile>: Remove.
15148 <dwarf2_per_objfile>: New field.
15149 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
15151 (create_signatured_type_table_from_index): Likewise.
15152 (create_debug_type_hash_table): Likewise.
15153 (fill_in_sig_entry_from_dwo_entry): Likewise.
15154 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
15155 (create_type_unit_group): Assign dwarf2_per_objfile instead of
15157 (create_partial_symtab): Access objfile through
15158 dwarf2_per_objfile.
15159 (process_psymtab_comp_unit_reader): Likewise.
15160 (read_comp_units_from_section): Likewise.
15161 (scan_partial_symbols): Likewise.
15162 (add_partial_symbol): Likewise.
15163 (add_partial_subprogram): Likewise.
15164 (peek_die_abbrev): Likewise.
15165 (fixup_go_packaging): Likewise.
15166 (process_full_comp_unit): Likewise.
15167 (process_full_type_unit): Likewise.
15168 (process_imported_unit_die): Likewise.
15169 (dwarf2_compute_name): Likewise.
15170 (dwarf2_physname): Likewise.
15171 (read_import_statement): Likewise.
15172 (create_cus_hash_table): Assign dwarf2_physname instead of
15174 (read_func_scope): Access objfile through dwarf2_per_objfile.
15175 (read_lexical_block_scope): Likewise.
15176 (read_call_site_scope): Likewise.
15177 (read_variable): Likewise.
15178 (dwarf2_rnglists_process): Likewise.
15179 (dwarf2_ranges_process): Likewise.
15180 (dwarf2_ranges_read): Likewise.
15181 (dwarf2_record_block_ranges): Likewise.
15182 (dwarf2_add_field): Likewise.
15183 (dwarf2_add_member_fn): Likewise.
15184 (read_structure_type): Likewise.
15185 (process_structure_scope): Likewise.
15186 (read_enumeration_type): Likewise.
15187 (read_array_type): Likewise.
15188 (read_common_block): Likewise.
15189 (read_namespace_type): Likewise.
15190 (read_namespace): Likewise.
15191 (read_module_type): Likewise.
15192 (read_tag_pointer_type): Likewise.
15193 (read_tag_ptr_to_member_type): Likewise.
15194 (read_tag_string_type): Likewise.
15195 (read_subroutine_type): Likewise.
15196 (read_typedef): Likewise.
15197 (read_base_type): Likewise.
15198 (attr_to_dynamic_prop): Likewise.
15199 (read_subrange_type): Likewise.
15200 (read_unspecified_type): Likewise.
15201 (load_partial_dies): Likewise.
15202 (read_partial_die): Likewise.
15203 (find_partial_die): Likewise.
15204 (guess_partial_die_structure_name): Likewise.
15205 (fixup_partial_die): Likewise.
15206 (read_attribute_value): Likewise.
15207 (read_addr_index_from_leb128): Likewise.
15208 (dwarf2_read_addr_index): Likewise.
15209 (dwarf2_string_attr): Likewise.
15210 (lnp_state_machine::check_line_address): Likewise.
15211 (dwarf_decode_lines_1): Likewise.
15212 (dwarf_decode_lines): Likewise.
15213 (dwarf2_start_symtab): Likewise.
15214 (var_decode_location): Likewise.
15215 (new_symbol_full): Likewise.
15216 (dwarf2_const_value_data): Likewise.
15217 (dwarf2_const_value_attr): Likewise.
15218 (dwarf2_const_value): Likewise.
15219 (die_type): Likewise.
15220 (die_containing_type): Likewise.
15221 (lookup_die_type): Likewise.
15222 (guess_full_die_structure_name): Likewise.
15223 (anonymous_struct_prefix): Likewise.
15224 (dwarf2_name): Likewise.
15225 (follow_die_ref_or_sig): Likewise.
15226 (follow_die_offset): Likewise.
15227 (follow_die_ref): Likewise.
15228 (dwarf2_fetch_die_loc_sect_off): Likewise.
15229 (dwarf2_fetch_constant_bytes): Likewise.
15230 (dwarf2_fetch_die_type_sect_off): Likewise.
15231 (dwarf2_get_die_type): Likewise.
15232 (follow_die_sig): Likewise.
15233 (decode_locdesc): Likewise.
15234 (dwarf2_per_cu_objfile): Likewise.
15235 (dwarf2_per_cu_text_offset): Likewise.
15236 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
15238 (set_die_type): Access objfile through
15239 dwarf2_per_objfile.
15241 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
15243 * valprint.c (converted_character_d): Remove typedef.
15244 (DEF_VEC_O (converted_character_d)): Remove.
15245 (count_next_character): Use std::vector.
15246 (print_converted_chars_to_obstack): Likewise.
15247 (generic_printstr): Likewise.
15249 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
15251 * xml-support.h (struct gdb_xml_value): Add constructor.
15252 <value>: Change type to unique_xmalloc_ptr.
15253 (gdb_xml_value_s): Remove typedef.
15254 (DEF_VEC_O (gdb_xml_value_s)): Remove.
15255 (gdb_xml_element_start_handler): Change parameter type to
15257 (xml_find_attribute): Likewise.
15258 * xml-support.c (xml_find_attribute): Change parameter type to
15259 std::vector and adjust.
15260 (gdb_xml_values_cleanup): Remove.
15261 (gdb_xml_parser::start_element): Adjust to std::vector.
15262 (xinclude_start_include): Change paraeter type to std::vector
15264 * btrace.c (check_xml_btrace_version): Likewise.
15265 (parse_xml_btrace_block): Likewise.
15266 (parse_xml_btrace_pt_config_cpu): Likewise.
15267 (parse_xml_btrace_pt): Likewise.
15268 (parse_xml_btrace_conf_bts): Likewise.
15269 (parse_xml_btrace_conf_pt): Likewise.
15270 * memory-map.c (memory_map_start_memory): Likewise.
15271 (memory_map_start_property): Likewise.
15272 * osdata.c (osdata_start_osdata): Likewise.
15273 (osdata_start_item): Likewise.
15274 (osdata_start_column): Likewise.
15275 * remote.c (start_thread): Likewise.
15276 * solib-aix.c (library_list_start_library): Likewise.
15277 (library_list_start_list): Likewise.
15278 * solib-svr4.c (library_list_start_library): Likewise.
15279 (svr4_library_list_start_list): Likewise.
15280 * solib-target.c (library_list_start_segment): Likewise.
15281 (library_list_start_section): Likewise.
15282 (library_list_start_library): Likewise.
15283 (library_list_start_list): Likewise.
15284 * tracepoint.c (traceframe_info_start_memory): Likewise.
15285 (traceframe_info_start_tvar): Likewise.
15286 * xml-syscall.c (syscall_start_syscall): Likewise.
15287 * xml-tdesc.c (tdesc_start_target): Likewise.
15288 (tdesc_start_feature): Likewise.
15289 (tdesc_start_reg): Likewise.
15290 (tdesc_start_union): Likewise.
15291 (tdesc_start_struct): Likewise.
15292 (tdesc_start_flags): Likewise.
15293 (tdesc_start_enum): Likewise.
15294 (tdesc_start_field): Likewise.
15295 (tdesc_start_enum_value): Likewise.
15296 (tdesc_start_vector): Likewise.
15298 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
15300 * extension.h (struct xmethod_worker) <clone>: Remove.
15301 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
15303 (python_xmethod_worker::clone): Remove.
15304 * valops.c (find_overload_match): Use std::move instead of
15307 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
15309 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
15310 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
15311 <free_xmethod_worker_data>: Remove.
15312 <get_matching_xmethod_workers>: Chance VEC to std::vector.
15313 <get_xmethod_arg_types>: Remove.
15314 <get_xmethod_result_type>: Remove.
15315 <invoke_xmethod>: Remove.
15316 * extension.c (new_xmethod_worker): Remove.
15317 (clone_xmethod_worker): Remove.
15318 (get_matching_xmethod_workers): Return void, pass std::vector by
15320 (get_xmethod_arg_types): Rename to...
15321 (xmethod_worker::get_arg_types): ... this, and adjust.
15322 (get_xmethod_result_type): Rename to...
15323 (xmethod_worker::get_result_type): ... this, and adjust.
15324 (invoke_xmethod): Remove.
15325 (free_xmethod_worker): Remove.
15326 (free_xmethod_worker_vec): Remove.
15327 * extension.h (enum ext_lang_rc): Move here from
15329 (struct xmethod_worker): Add constructor and destructor.
15332 <invoke, clone, do_get_result_type, do_get_arg_types>: New
15333 virtual pure methods.
15334 <get_arg_types, get_result_type>: New methods.
15335 (xmethod_worker_ptr): Remove typedef.
15336 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
15337 (xmethod_worker_vec): Remove typedef.
15338 (xmethod_worker_up): New typedef.
15339 (invoke_xmethod): Remove.
15340 (clone_xmethod_worker): Remove.
15341 (free_xmethod_worker): Remove.
15342 (free_xmethod_worker_vec): Remove.
15343 (get_xmethod_arg_types): Remove.
15344 (get_xmethod_result_type): Remove.
15345 * valops.c (find_method_list): Use std::vector, don't use
15346 intermediate vector.
15347 (value_find_oload_method_list): Use std::vector.
15348 (find_overload_match): Use std::vector.
15349 (find_oload_champ): Use std::vector.
15350 * value.c (value_free): Use operator delete.
15351 (value_of_xmethod): Rename to...
15352 (value_from_xmethod): ... this. Don't assign
15353 xmethod_worker::value, take rvalue-reference.
15354 (result_type_of_xmethod): Adjust.
15355 (call_xmethod): Adjust.
15356 * value.h: Include extension.h.
15357 (struct xmethod_worker): Don't forward-declare.
15358 (value_of_xmethod): Rename to...
15359 (value_from_xmethod): ... this, take rvalue-reference.
15360 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
15361 (struct python_xmethod_worker): ... this, add constructor and
15363 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
15364 (gdbpy_free_xmethod_worker_data): Rename to...
15365 (python_xmethod_worker::~python_xmethod_worker): ... this and
15367 (gdbpy_clone_xmethod_worker_data): Rename to...
15368 (python_xmethod_worker::clone): ... this and adjust.
15369 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
15371 (gdbpy_get_xmethod_arg_types): Rename to...
15372 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
15373 (gdbpy_get_xmethod_result_type): Rename to...
15374 (python_xmethod_worker::do_get_result_type): ... this and
15376 (gdbpy_invoke_xmethod): Rename to...
15377 (python_xmethod_worker::invoke): ... this and adjust.
15378 (new_python_xmethod_worker): Rename to...
15379 (python_xmethod_worker::python_xmethod_worker): ... this and
15381 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
15383 (gdbpy_free_xmethod_worker_data): Remove.
15384 (gdbpy_get_matching_xmethod_workers): Use std::vector.
15385 (gdbpy_get_xmethod_arg_types): Remove.
15386 (gdbpy_get_xmethod_result_type): Remove.
15387 (gdbpy_invoke_xmethod): Remove.
15388 * python/python.c (python_extension_ops): Remove obsolete
15391 2018-01-05 Pedro Alves <palves@redhat.com>
15394 * common/signals-state-save-restore.c
15395 (save_original_signals_state): New parameter 'quiet'. Warn if we
15396 find a custom handler preinstalled, instead of internal erroring.
15397 But only warn if !quiet.
15398 * common/signals-state-save-restore.h
15399 (save_original_signals_state): New parameter 'quiet'.
15400 * main.c (captured_main_1): Move save_original_signals_state call
15401 after option handling, and pass QUIET.
15403 2018-01-05 Pedro Alves <palves@redhat.com>
15405 * spu-tdep.c (spu_catch_start): Pass
15406 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
15408 2018-01-05 Pedro Alves <palves@redhat.com>
15411 * ada-lang.c (literal_symbol_name_matcher): New function.
15412 (ada_get_symbol_name_matcher): Use it for
15413 symbol_name_match_type::SEARCH_NAME.
15414 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
15415 it down instead of assuming symbol_name_match_type::FULL.
15416 * block.h (block_lookup_symbol): New parameter 'match_type'.
15417 * c-valprint.c (print_unpacked_pointer): Use
15418 lookup_symbol_search_name instead of lookup_symbol.
15419 * compile/compile-object-load.c (get_out_value_type): Pass down
15420 symbol_name_match_type::SEARCH_NAME.
15421 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
15422 symbol_name_match_type::FULL.
15423 * cp-support.c (cp_get_symbol_name_matcher): Handle
15424 symbol_name_match_type::SEARCH_NAME.
15425 * infrun.c (insert_exception_resume_breakpoint): Use
15426 lookup_symbol_search_name.
15427 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
15428 * psymtab.c (maintenance_check_psymtabs): Use
15429 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
15430 * stack.c (print_frame_args): Use lookup_symbol_search_name and
15431 SYMBOL_SEARCH_NAME.
15432 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
15433 if symbol_name_match_type::SEARCH_NAME.
15434 (lookup_symbol_in_language): Pass down
15435 symbol_name_match_type::FULL.
15436 (lookup_symbol_search_name): New.
15437 (lookup_language_this): Pass down
15438 symbol_name_match_type::SEARCH_NAME.
15439 (lookup_symbol_aux, lookup_local_symbol): New parameter
15440 'match_type'. Pass it down.
15441 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
15442 (lookup_symbol_search_name): New declaration.
15443 (lookup_symbol_in_block): New 'match_type' parameter.
15445 2018-01-05 Pedro Alves <palves@redhat.com>
15448 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
15450 (ada_lookup_symbol): Reimplement in terms of
15451 ada_lookup_symbol_list, bits factored out from
15452 ada_lookup_encoded_symbol.
15454 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15456 * ada-exp.y (write_object_renaming): When subscripting an array
15457 using a symbol as the index, pass the block in call to
15458 ada_lookup_encoded_symbol when looking that symbol up.
15460 2018-01-05 Jerome Guitton <guitton@adacore.com>
15462 * ada-lang.c (ada_array_length): Use ada_index_type instead of
15465 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15467 * ada-lang.c (ada_to_fixed_value_create): Add handling of
15468 the case where VALUE_LVAL (val0) is not lval_memory.
15470 2018-01-05 Xavier Roirand <roirand@adacore.com>
15472 * ada-valprint.c (print_optional_low_bound): Handle
15473 character-indexed array printing like boolean-indexed array
15476 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15478 * NEWS: Create a new section for the next release branch.
15479 Rename the section of the current branch, now that it has
15482 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15484 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
15485 * version.in: Bump version to 8.1.50.DATE-git.
15487 2018-01-03 Xavier Roirand <roirand@adacore.com>
15489 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
15491 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
15493 (default_exception_support_info) <catch_handlers_sym>: Add field.
15494 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
15495 (ada_exception_name_addr_1): Add "catch handlers" handling.
15496 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
15497 Update all callers.
15498 (create_excep_cond_exprs) <ex>: Add parameter.
15499 (re_set_exception): Update create_excep_cond_exprs call.
15500 (print_it_exception, print_one_exception, print_mention_exception)
15501 (print_recreate_exception): Add "catch handler" handling.
15502 (allocate_location_catch_handlers, re_set_catch_handlers)
15503 (check_status_catch_handlers, print_it_catch_handlers)
15504 (print_one_catch_handlers, print_mention_catch_handlers)
15505 (print_recreate_catch_handlers): New function.
15506 (catch_handlers_breakpoint_ops): New variable.
15507 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
15508 Add parameter. Add "catch handler" handling.
15509 (ada_exception_sym_name, ada_exception_breakpoint_ops):
15510 Add "catch handler" handling.
15511 (ada_exception_catchpoint_cond_string): Add "catch handler"
15513 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
15515 (catch_ada_handlers_command): New function.
15516 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
15517 operations structure.
15518 (_initialize_ada_language): Add "catch handlers" command entry.
15519 * NEWS: Document "catch handlers" feature.
15521 2018-01-02 Joel Brobecker <brobecker@adacore.com>
15523 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
15524 account when creating the array type of the slice.
15525 (ada_value_slice): Likewise.
15527 2018-01-02 Joel Brobecker <brobecker@adacore.com>
15529 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
15531 (create_array_type_with_stride): Add byte_stride_prop parameter.
15532 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
15533 New parameter. Update all callers in this file.
15534 (array_type_has_dynamic_stride): New function.
15535 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
15536 of arrays with dynamic byte strides.
15537 * dwarf2read.c (read_array_type): Add support for dynamic
15538 DW_AT_byte_stride attributes.
15540 2018-01-02 Joel Brobecker <brobecker@adacore.com>
15542 * dwarf2read.c (read_unspecified_type): Treat
15543 DW_TAG_enumeration_type DIEs from Ada units as stubs.
15545 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15547 Update copyright year range in all GDB files.
15549 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
15551 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
15552 and gdb/testsuite/gdb.base/step-line.c.
15554 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15556 * copyright.py (main): Dump the contents of
15557 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
15558 even if BY_HAND is empty.
15560 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15562 * top.c (print_gdb_version): Update Copyright year in version
15565 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15567 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
15569 For older changes see ChangeLog-2017.
15575 version-control: never