1 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
4 Move update of loop variable "fi".
6 2018-09-08 Joel Brobecker <brobecker@adacore.com>
8 * ada-lang.c (value_assign_to_component): In the case of
9 big-endian targets, extract the bits of the given VAL
10 using an src_offset of zero if container is not a scalar.
12 2018-09-06 Simon Ser <contact@emersion.fr>
15 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
16 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
17 * fbsd-tdep.c (fbsd_make_note_desc): New.
18 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
19 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
20 * target.h (enum target_object) Add FreeBSD-specific
21 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
23 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
25 * compile/compile-c.h (generate_c_for_variable_locations):
26 Change reference to pointer.
27 * compile/compile-c-support.c (compile_program) <compute>:
29 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
30 (generate_c_for_for_one_variable): Likewise
31 (generate_c_for_variable_locations): Likewise
32 * compile/compile-c-types.c (compile_c_instance::convert_type):
34 * compile/compile-cplus-symbols.c (convert_one_symbol):
35 std::move the scope passed to enter_scope.
36 * compile/compile-cplus-types.c
37 (compile_cplus_instance::enter_scope): Make parameter
39 (compile_cplus_instance::new_scope): Change reference to
41 (compile_cplus_instance::convert_type): Likewise
42 (compile_cplus_convert_typedef): std::move the scope passed to
44 (compile_cplus_convert_struct_or_union): Likewise.
45 (compile_cplus_convert_enum): Likewise.
46 (compile_cplus_convert_namespace): Likewise.
47 * compile/compile-cplus.h (compile_cplus_instance)
48 <enter_scope>: Make parameter rvalue-reference.
49 * compile/compile-internal.h (compile_instance)
50 <get_cached_type>: Likewise
51 * compile/compile-loc2c.c (push): Likewise
55 (print_label): Likewise
56 (pushf_register_address): Likewise
57 (pushf_register): Likewise
58 (do_compile_dwarf_expr_to_c): Likewise
59 (compile_dwarf_expr_to_c): Likewise
60 (compile_dwarf_bounds_to_c): Likewise
61 * compile/compile.c (compile_instance::get_cached_type):
63 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
64 (compile_dwarf_bounds_to_c): Likewise
65 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
66 (dwarf2_compile_property_to_c): Likewise
67 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
68 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
71 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
73 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
74 * tui/tui-data.c (init_content_element): Don't initialize it.
76 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
78 * tui/tui-data.h (struct tui_win_info)
79 <detail::opaque>: Remove.
80 * tui/tui-data.c (init_win_info): Remove assignment.
82 2018-09-05 Tom Tromey <tom@tromey.com>
84 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
86 * target-float.c (host_float_ops<T>::to_string)
87 (host_float_ops<T>::from_string): Use
88 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
91 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
93 * printcmd.c (printf_c_string): Use
94 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
95 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
97 2018-09-05 Tom Tromey <tom@tromey.com>
99 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
101 2018-09-05 Tom de Vries <tdevries@suse.de>
103 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
104 with resolve_abstract_p == true.
105 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
106 defaulting to false. Propagate resolve_abstract_p to
107 dwarf2_fetch_die_loc_sect_off.
108 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
109 parameter, defaulting to false.
110 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
111 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
113 * dwarf2read.h (struct die_info): Forward-declare.
114 (die_info_ptr): New typedef.
115 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
117 2018-09-05 Joel Brobecker <brobecker@adacore.com>
121 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
122 Pedro Alves <palves@redhat.com>
124 * gnulib/Makefile.in (aclocal_m4_deps): Move to
125 "aclocal-m4-deps.mk". Include file here.
126 $(srcdir)/aclocal.m4: Add "configure.ac".
127 * gnulib/aclocal-m4-deps.mk: New file.
128 * gnulib/update-gnulib.sh: Automatically update
129 "aclocal-m4-deps.mk".
131 2018-09-04 Tom Tromey <tom@tromey.com>
133 * configure: Rebuild.
134 * configure.ac: Remove multi-ice code.
136 2018-09-04 Tom Tromey <tom@tromey.com>
138 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
141 2018-09-04 Tom Tromey <tom@tromey.com>
143 * Makefile.in (printcmd.o, target-float.o): Remove.
144 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
146 2018-09-04 Tom Tromey <tom@tromey.com>
148 * gnulib/Makefile.in: Remove obsolete comment.
149 * Makefile.in: Remove obsolete comment.
151 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
153 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
156 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
158 * riscv-tdep.c: Add 'prologue-value.h' include.
159 (struct riscv_unwind_cache): New struct.
160 (riscv_debug_unwinder): New global.
161 (riscv_scan_prologue): Update arguments, capture register details
163 (riscv_skip_prologue): Reformat arguments line, move end of
164 prologue calculation into riscv_scan_prologue.
165 (riscv_frame_cache): Update return type, create
166 riscv_unwind_cache, scan the prologue, and fill in remaining cache
168 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
169 (riscv_frame_prev_register): Use the trad_frame within the
171 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
174 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
176 * trad-frame.h (trad_frame_set_realreg): Declare.
177 (trad_frame_set_addr): Declare.
178 * trad-frame.c (trad_frame_set_realreg): Define new function.
179 (trad_frame_set_addr): Define new function.
180 (trad_frame_set_reg_realreg): Use new function.
181 (trad_frame_set_reg_addr): Use new function.
183 2018-09-01 Keith Seitz <keiths@redhat.com>
185 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
186 pulongest instead of "%lld".
187 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
190 2018-08-31 Tom Tromey <tom@tromey.com>
192 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
195 2018-08-31 Pedro Alves <palves@redhat.com>
197 * gdbarch.h: Regenerate.
199 2018-08-31 Pedro Alves <palves@redhat.com>
201 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
202 * target.h (Hardware watchpoint interfaces): Describe
203 continuable/steppable/non-steppable watchpoints.
204 * gdbarch.h, gdbarch.c: Regenerate.
206 2018-08-31 Pedro Alves <palves@redhat.com>
208 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
211 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
212 * target.h (target_ops::have_continuable_watchpoint): Delete.
213 (target_have_continuable_watchpoint): Delete.
214 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
215 * target-delegates.c: Regenerate.
217 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
219 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
220 the files present in "gnulib/import/m4/".
222 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
224 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
225 c.sw, c.swsp, and c.sdsp.
227 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
229 * riscv-tdep.c (struct riscv_inferior_data): Delete.
230 (riscv_read_misa_reg): Don't cache value read into inferior data.
231 (riscv_new_inferior_data): Delete.
232 (riscv_inferior_data_cleanup): Delete.
233 (riscv_inferior_data): Delete.
234 (riscv_invalidate_inferior_data): Delete.
235 (_initialize_riscv_tdep): Remove initialisation of inferior data.
237 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
239 * compile/compile-cplus-types.c
240 (compile_cplus_instance::leave_scope): Take the address of scope
242 (compile_cplus_instance::convert_qualified_base): Compare quals
245 2018-08-30 Keith Seitz <keiths@redhat.com>
247 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
248 Use "%s" and host_address_to_string instead of "%p" in printf.
250 2018-08-29 Keith Seitz <keiths@redhat.com>
252 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
253 and compile-cplus-types.c.
254 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
255 * c-lang.c (cplus_language_defn): Set C++ compile functions.
256 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
258 * compile/compile-c-support.c: Include compile-cplus.h.
259 (load_libcompile): Templatize.
260 (get_compile_context): "New" function.
261 (c_get_compile_context): Use get_compile_context.
262 (cplus_get_compile_context): New function.
263 (cplus_push_user_expression, cplus_pop_user_expression)
264 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
265 (cplus_compute_program): Define new structs/functions.
266 * compile/compile-cplus-symmbols.c: New file.
267 * compile/compile-cplus-types.c: New file.
268 * compile/compile-cplus.h: New file.
269 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
271 * compile/compile-object-load.c (get_out_value_type): Use
272 strncmp_iw when comparing symbol names.
273 (compile_object_load): Add mst_bss and mst_data.
274 * compile/compile.c (_initialize_compile): Remove
275 -Wno-implicit-function-declaration from `compile_args'.
276 * compile/gcc-cp-plugin.h: New file.
277 * NEWS: Mention C++ compile support and new debug options.
279 2018-08-29 Keith Seitz <keiths@redhat.com>
281 * linespec.c (collect_info::add_symbol): Make virtual.
282 (struct symbol_searcher_collect_info): New struct.
283 (symbol_searcher::find_all_symbols): New method.
284 * symtab.h (class symbol_searcher): New class.
286 2018-08-29 Keith Seitz <keiths@redhat.com>
288 * linespec.c (struct linespec) <function_symbols, label_symbols>:
289 Change to vector of block_symbol. Update all users.
290 (struct collect_info) <symbols>: Likewise.
291 (collect_info::add_symbol): Take block_symbol as argument.
293 (decode_compound_collector) <m_symbols>: Change type to vector
294 of block_symbol. Update all users.
295 (decode_compound_collector::operator ()): Change parameter type
297 (find_method, find_function_symbols, find_linespec_symbols)
298 (find_label_symbols_in_block, find_label_symbols): Change symbol
299 vectors to block_symbol vectors.
300 * symtab.h (symbol_found_callback_ftype): Change parameter type to
303 2018-08-29 Keith Seitz <keiths@redhat.com>
305 * linespec.c (symbolp): Remove typedef and VEC definitions.
306 (bound_minimal_symbol_d): Likewise.
308 2018-08-29 Keith Seitz <keiths@redhat.com>
310 * linespec.c (decode_compound_collector::decode_compound_collector):
311 Remove initialization for `m_symtabs'.
312 (decode_compound_collector::release_symbols): Change return type
313 to std::vector. Update all callers.
314 (class decode_compound_collector) <m_symbols>: Change type to
316 (lookup_prefix_sym): Change return type to std::vector. Update all
318 (compare_symbols): Remove.
319 (std_compare_symbols): Rename to `compare_symbols'.
320 (find_method): Change `sym_classes' parameter to std::vector.
321 Update all callers. Use std::sort to sort sym_classes.
322 (find_linespec_symbols): Remove cleanup.
324 2018-08-29 Keith Seitz <keiths@redhat.com>
326 * linespec.c (struct linespec) <minimal_symbols>: Change type to
327 std::vector. Update all users.
328 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
329 (struct collect_info) <minimal_symbols>: Likewise.
330 (compare_msymbols): Return bool. Change parameters to const
331 bound_minimal_symbol references.
332 (find_method, find_function_symbols, find_linespec_symbols): Change
333 `minsyms' parameter to std::vector. Update all callers.
335 2018-08-29 Keith Seitz <keiths@redhat.com>
337 * linespec.c (struct linespec) <label_symbols>: Change type to
338 std::vector. Update all users.
339 (find_label_symbols_in_block): Change `result' parameter to
340 std::vector. Update all callers.
341 (find_label_symbols): Return std::vector. Update all callers.
343 2018-08-29 Keith Seitz <keiths@redhat.com>
345 * linespec.c (struct linespec) <function_symbols>: Change type to
346 std::vector. Update all users.
347 (struct collect_info) <function_symbols>: Likewise.
348 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
349 (std_compare_symbols): New function.
350 (find_method, find_function_symbols, find_linespec_symbols)
351 (find_label_symbols_in_block): Change `symbols' parameter to
352 std::vector. Update all callers.
353 (find_label_symbols): Likewise for `function_symbols' and
356 2018-08-29 Keith Seitz <keiths@redhat.com>
358 * linespec.c (symtab_vector_up): Define.
359 (struct linespec) <file_symtabs>: Change type to std::vector *.
361 (struct collect_info) <file_symtabs>: Likewise.
362 (collect_symtabs_from_filename): Return symtab_vector_up.
364 (decode_objc): Remove cleanup.
365 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
366 (symtab_collector::release_symtabs): Return symtab_vector_up.
368 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
370 (collect_symtabs_from_filename, symtabs_from_filename): Return
371 symtab_vector_up. Update all callers.
373 2018-08-29 Tom Tromey <tom@tromey.com>
375 * csky-tdep.c (csky_analyze_prologue): Use
376 core_addr_to_string_nz.
378 2018-08-29 Tom Tromey <tom@tromey.com>
380 * windows-nat.c (struct xlate_exception) <them>: Change type to
382 (xlate): Fix formatting. Remove last entry.
383 (struct xlate_exception, xlate): Comment out.
384 (windows_nat_target::resume): Use ranged for.
386 2018-08-29 Jim Wilson <jimw@sifive.com>
388 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
389 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
391 (riscv_linux_nat_target::store_registers): Likewise.
393 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
397 * gnulib/aclocal.m4: Regenerate.
398 * gnulib/config.in: Regenerate.
399 * gnulib/configure: Regenerate.
400 * gnulib/import/Makefile.am: Update.
401 * gnulib/import/Makefile.in: Update.
402 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
403 * gnulib/import/_Noreturn.h: ... this.
404 * gnulib/import/alloca.in.h: Update.
405 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
406 * gnulib/import/arg-nonnull.h: ... this.
407 * gnulib/import/assure.h: Update.
408 * gnulib/import/at-func.c: Update.
409 * gnulib/import/basename-lgpl.c: Update.
410 * gnulib/import/extra/snippet/c++defs.h: Rename to...
411 * gnulib/import/c++defs.h: ... this.
412 * gnulib/import/canonicalize-lgpl.c: Update.
413 * gnulib/import/cdefs.h: Update.
414 * gnulib/import/chdir-long.c: Update.
415 * gnulib/import/chdir-long.h: Update.
416 * gnulib/import/cloexec.c: Update.
417 * gnulib/import/cloexec.h: Update.
418 * gnulib/import/close.c: Update.
419 * gnulib/import/closedir.c: Update.
420 * gnulib/import/config.charset: Update.
421 * gnulib/import/dirent-private.h: Update.
422 * gnulib/import/dirent.in.h: Update.
423 * gnulib/import/dirfd.c: Update.
424 * gnulib/import/dirname-lgpl.c: Update.
425 * gnulib/import/dirname.h: Update.
426 * gnulib/import/dosname.h: Update.
427 * gnulib/import/dup-safer-flag.c: Update.
428 * gnulib/import/dup-safer.c: Update.
429 * gnulib/import/dup.c: Update.
430 * gnulib/import/dup2.c: Update.
431 * gnulib/import/errno.in.h: Update.
432 * gnulib/import/error.c: Update.
433 * gnulib/import/error.h: Update.
434 * gnulib/import/exitfail.c: Update.
435 * gnulib/import/exitfail.h: Update.
436 * gnulib/import/extra/update-copyright: Update.
437 * gnulib/import/fchdir.c: Update.
438 * gnulib/import/fcntl.c: Update.
439 * gnulib/import/fcntl.in.h: Update.
440 * gnulib/import/fd-hook.c: Update.
441 * gnulib/import/fd-hook.h: Update.
442 * gnulib/import/fd-safer-flag.c: Update.
443 * gnulib/import/fd-safer.c: Update.
444 * gnulib/import/fdopendir.c: Update.
445 * gnulib/import/filename.h: Update.
446 * gnulib/import/filenamecat-lgpl.c: Update.
447 * gnulib/import/filenamecat.h: Update.
448 * gnulib/import/flexmember.h: Update.
449 * gnulib/import/float+.h: Update.
450 * gnulib/import/float.c: Update.
451 * gnulib/import/float.in.h: Update.
452 * gnulib/import/fnmatch.c: Update.
453 * gnulib/import/fnmatch.in.h: Update.
454 * gnulib/import/fnmatch_loop.c: Update.
455 * gnulib/import/fpucw.h: Update.
456 * gnulib/import/frexp.c: Update.
457 * gnulib/import/frexpl.c: Update.
458 * gnulib/import/fstat.c: Update.
459 * gnulib/import/fstatat.c: Update.
460 * gnulib/import/getcwd-lgpl.c: Update.
461 * gnulib/import/getcwd.c: Update.
462 * gnulib/import/getdtablesize.c: Update.
463 * gnulib/import/getlogin_r.c: Update.
464 * gnulib/import/getprogname.c: Update.
465 * gnulib/import/getprogname.h: Update.
466 * gnulib/import/gettext.h: Update.
467 * gnulib/import/gettimeofday.c: Update.
468 * gnulib/import/glob-libc.h: Update.
469 * gnulib/import/glob.c: Update.
470 * gnulib/import/glob.in.h: Update.
471 * gnulib/import/glob_internal.h: Update.
472 * gnulib/import/glob_pattern_p.c: Update.
473 * gnulib/import/globfree.c: Update.
474 * gnulib/import/hard-locale.c: Update.
475 * gnulib/import/hard-locale.h: Update.
476 * gnulib/import/intprops.h: Update.
477 * gnulib/import/inttypes.in.h: Update.
478 * gnulib/import/isnan.c: Update.
479 * gnulib/import/isnand-nolibm.h: Update.
480 * gnulib/import/isnand.c: Update.
481 * gnulib/import/isnanl-nolibm.h: Update.
482 * gnulib/import/isnanl.c: Update.
483 * gnulib/import/itold.c: Update.
484 * gnulib/import/libc-config.h: Update.
485 * gnulib/import/limits.in.h: Update.
486 * gnulib/import/localcharset.c: Update.
487 * gnulib/import/localcharset.h: Update.
488 * gnulib/import/localtime-buffer.c: Update.
489 * gnulib/import/localtime-buffer.h: Update.
490 * gnulib/import/lstat.c: Update.
491 * gnulib/import/m4/00gnulib.m4: Update.
492 * gnulib/import/m4/__inline.m4: Update.
493 * gnulib/import/m4/absolute-header.m4: Update.
494 * gnulib/import/m4/alloca.m4: Update.
495 * gnulib/import/m4/builtin-expect.m4: Update.
496 * gnulib/import/m4/canonicalize.m4: Update.
497 * gnulib/import/m4/chdir-long.m4: Update.
498 * gnulib/import/m4/close.m4: Update.
499 * gnulib/import/m4/closedir.m4: Update.
500 * gnulib/import/m4/configmake.m4: Update.
501 * gnulib/import/m4/d-ino.m4: Update.
502 * gnulib/import/m4/d-type.m4: Update.
503 * gnulib/import/m4/dirent_h.m4: Update.
504 * gnulib/import/m4/dirfd.m4: Update.
505 * gnulib/import/m4/dirname.m4: Update.
506 * gnulib/import/m4/double-slash-root.m4: Update.
507 * gnulib/import/m4/dup.m4: Update.
508 * gnulib/import/m4/dup2.m4: Update.
509 * gnulib/import/m4/eealloc.m4: Update.
510 * gnulib/import/m4/environ.m4: Update.
511 * gnulib/import/m4/errno_h.m4: Update.
512 * gnulib/import/m4/error.m4: Update.
513 * gnulib/import/m4/exponentd.m4: Update.
514 * gnulib/import/m4/exponentl.m4: Update.
515 * gnulib/import/m4/extensions.m4: Update.
516 * gnulib/import/m4/extern-inline.m4: Update.
517 * gnulib/import/m4/fchdir.m4: Update.
518 * gnulib/import/m4/fcntl-o.m4: Update.
519 * gnulib/import/m4/fcntl.m4: Update.
520 * gnulib/import/m4/fcntl_h.m4: Update.
521 * gnulib/import/m4/fdopendir.m4: Update.
522 * gnulib/import/m4/filenamecat.m4: Update.
523 * gnulib/import/m4/flexmember.m4: Update.
524 * gnulib/import/m4/float_h.m4: Update.
525 * gnulib/import/m4/fnmatch.m4: Update.
526 * gnulib/import/m4/fnmatch_h.m4: Update.
527 * gnulib/import/m4/fpieee.m4: Update.
528 * gnulib/import/m4/frexp.m4: Update.
529 * gnulib/import/m4/frexpl.m4: Update.
530 * gnulib/import/m4/fstat.m4: Update.
531 * gnulib/import/m4/fstatat.m4: Update.
532 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
533 * gnulib/import/m4/getcwd-path-max.m4: Update.
534 * gnulib/import/m4/getcwd.m4: Update.
535 * gnulib/import/m4/getdtablesize.m4: Update.
536 * gnulib/import/m4/getlogin.m4: Update.
537 * gnulib/import/m4/getlogin_r.m4: Update.
538 * gnulib/import/m4/getpagesize.m4: Update.
539 * gnulib/import/m4/getprogname.m4: Update.
540 * gnulib/import/m4/gettimeofday.m4: Update.
541 * gnulib/import/m4/glibc21.m4: Update.
542 * gnulib/import/m4/glob.m4: Update.
543 * gnulib/import/m4/glob_h.m4: Update.
544 * gnulib/import/m4/gnulib-cache.m4: Update.
545 * gnulib/import/m4/gnulib-common.m4: Update.
546 * gnulib/import/m4/gnulib-comp.m4: Update.
547 * gnulib/import/m4/gnulib-tool.m4: Update.
548 * gnulib/import/m4/hard-locale.m4: Update.
549 * gnulib/import/m4/include_next.m4: Update.
550 * gnulib/import/m4/inttypes-pri.m4: Update.
551 * gnulib/import/m4/inttypes.m4: Update.
552 * gnulib/import/m4/isnand.m4: Update.
553 * gnulib/import/m4/isnanl.m4: Update.
554 * gnulib/import/m4/largefile.m4: Update.
555 * gnulib/import/m4/limits-h.m4: Update.
556 * gnulib/import/m4/localcharset.m4: Update.
557 * gnulib/import/m4/locale-fr.m4: Update.
558 * gnulib/import/m4/locale-ja.m4: Update.
559 * gnulib/import/m4/locale-zh.m4: Update.
560 * gnulib/import/m4/localtime-buffer.m4: Update.
561 * gnulib/import/m4/longlong.m4: Update.
562 * gnulib/import/m4/lstat.m4: Update.
563 * gnulib/import/m4/malloc.m4: Update.
564 * gnulib/import/m4/malloca.m4: Update.
565 * gnulib/import/m4/math_h.m4: Update.
566 * gnulib/import/m4/mbrtowc.m4: Update.
567 * gnulib/import/m4/mbsinit.m4: Update.
568 * gnulib/import/m4/mbsrtowcs.m4: Update.
569 * gnulib/import/m4/mbstate_t.m4: Update.
570 * gnulib/import/m4/memchr.m4: Update.
571 * gnulib/import/m4/memmem.m4: Update.
572 * gnulib/import/m4/mempcpy.m4: Update.
573 * gnulib/import/m4/memrchr.m4: Update.
574 * gnulib/import/m4/mkdir.m4: Update.
575 * gnulib/import/m4/mkstemp.m4: Update.
576 * gnulib/import/m4/mmap-anon.m4: Update.
577 * gnulib/import/m4/mode_t.m4: Update.
578 * gnulib/import/m4/msvc-inval.m4: Update.
579 * gnulib/import/m4/msvc-nothrow.m4: Update.
580 * gnulib/import/m4/multiarch.m4: Update.
581 * gnulib/import/m4/nocrash.m4: Update.
582 * gnulib/import/m4/off_t.m4: Update.
583 * gnulib/import/m4/onceonly.m4: Update.
584 * gnulib/import/m4/open-cloexec.m4: Update.
585 * gnulib/import/m4/open.m4: Update.
586 * gnulib/import/m4/openat.m4: Update.
587 * gnulib/import/m4/opendir.m4: Update.
588 * gnulib/import/m4/pathmax.m4: Update.
589 * gnulib/import/m4/rawmemchr.m4: Update.
590 * gnulib/import/m4/readdir.m4: Update.
591 * gnulib/import/m4/readlink.m4: Update.
592 * gnulib/import/m4/realloc.m4: Update.
593 * gnulib/import/m4/rename.m4: Update.
594 * gnulib/import/m4/rewinddir.m4: Update.
595 * gnulib/import/m4/rmdir.m4: Update.
596 * gnulib/import/m4/save-cwd.m4: Update.
597 * gnulib/import/m4/secure_getenv.m4: Update.
598 * gnulib/import/m4/setenv.m4: Update.
599 * gnulib/import/m4/signal_h.m4: Update.
600 * gnulib/import/m4/ssize_t.m4: Update.
601 * gnulib/import/m4/stat-time.m4: Update.
602 * gnulib/import/m4/stat.m4: Update.
603 * gnulib/import/m4/std-gnu11.m4: Update.
604 * gnulib/import/m4/stdbool.m4: Update.
605 * gnulib/import/m4/stddef_h.m4: Update.
606 * gnulib/import/m4/stdint.m4: Update.
607 * gnulib/import/m4/stdio_h.m4: Update.
608 * gnulib/import/m4/stdlib_h.m4: Update.
609 * gnulib/import/m4/strchrnul.m4: Update.
610 * gnulib/import/m4/strdup.m4: Update.
611 * gnulib/import/m4/strerror.m4: Update.
612 * gnulib/import/m4/string_h.m4: Update.
613 * gnulib/import/m4/strstr.m4: Update.
614 * gnulib/import/m4/strtok_r.m4: Update.
615 * gnulib/import/m4/sys_socket_h.m4: Update.
616 * gnulib/import/m4/sys_stat_h.m4: Update.
617 * gnulib/import/m4/sys_time_h.m4: Update.
618 * gnulib/import/m4/sys_types_h.m4: Update.
619 * gnulib/import/m4/tempname.m4: Update.
620 * gnulib/import/m4/time_h.m4: Update.
621 * gnulib/import/m4/unistd-safer.m4: Update.
622 * gnulib/import/m4/unistd_h.m4: Update.
623 * gnulib/import/m4/warn-on-use.m4: Update.
624 * gnulib/import/m4/wchar_h.m4: Update.
625 * gnulib/import/m4/wchar_t.m4: Update.
626 * gnulib/import/m4/wctype_h.m4: Update.
627 * gnulib/import/m4/wint_t.m4: Update.
628 * gnulib/import/malloc.c: Update.
629 * gnulib/import/malloc/scratch_buffer.h: Update.
630 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
631 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
632 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
633 * gnulib/import/malloca.c: Update.
634 * gnulib/import/malloca.h: Update.
635 * gnulib/import/malloca.valgrind: Update.
636 * gnulib/import/math.in.h: Update.
637 * gnulib/import/mbrtowc.c: Update.
638 * gnulib/import/mbsinit.c: Update.
639 * gnulib/import/mbsrtowcs-impl.h: Update.
640 * gnulib/import/mbsrtowcs-state.c: Update.
641 * gnulib/import/mbsrtowcs.c: Update.
642 * gnulib/import/memchr.c: Update.
643 * gnulib/import/memmem.c: Update.
644 * gnulib/import/mempcpy.c: Update.
645 * gnulib/import/memrchr.c: Update.
646 * gnulib/import/mkdir.c: Update.
647 * gnulib/import/mkstemp.c: Update.
648 * gnulib/import/msvc-inval.c: Update.
649 * gnulib/import/msvc-inval.h: Update.
650 * gnulib/import/msvc-nothrow.c: Update.
651 * gnulib/import/msvc-nothrow.h: Update.
652 * gnulib/import/open.c: Update.
653 * gnulib/import/openat-die.c: Update.
654 * gnulib/import/openat-priv.h: Update.
655 * gnulib/import/openat-proc.c: Update.
656 * gnulib/import/openat.c: Update.
657 * gnulib/import/openat.h: Update.
658 * gnulib/import/opendir.c: Update.
659 * gnulib/import/pathmax.h: Update.
660 * gnulib/import/pipe-safer.c: Update.
661 * gnulib/import/rawmemchr.c: Update.
662 * gnulib/import/readdir.c: Update.
663 * gnulib/import/readlink.c: Update.
664 * gnulib/import/realloc.c: Update.
665 * gnulib/import/ref-add.sin: Update.
666 * gnulib/import/ref-del.sin: Update.
667 * gnulib/import/rename.c: Update.
668 * gnulib/import/rewinddir.c: Update.
669 * gnulib/import/rmdir.c: Update.
670 * gnulib/import/same-inode.h: Update.
671 * gnulib/import/save-cwd.c: Update.
672 * gnulib/import/save-cwd.h: Update.
673 * gnulib/import/scratch_buffer.h: Update.
674 * gnulib/import/secure_getenv.c: Update.
675 * gnulib/import/setenv.c: Update.
676 * gnulib/import/signal.in.h: Update.
677 * gnulib/import/stat-time.c: Update.
678 * gnulib/import/stat-time.h: Update.
679 * gnulib/import/stat-w32.c: Update.
680 * gnulib/import/stat-w32.h: Update.
681 * gnulib/import/stat.c: Update.
682 * gnulib/import/stdbool.in.h: Update.
683 * gnulib/import/stddef.in.h: Update.
684 * gnulib/import/stdint.in.h: Update.
685 * gnulib/import/stdio.in.h: Update.
686 * gnulib/import/stdlib.in.h: Update.
687 * gnulib/import/str-two-way.h: Update.
688 * gnulib/import/strchrnul.c: Update.
689 * gnulib/import/strdup.c: Update.
690 * gnulib/import/streq.h: Update.
691 * gnulib/import/strerror-override.c: Update.
692 * gnulib/import/strerror-override.h: Update.
693 * gnulib/import/strerror.c: Update.
694 * gnulib/import/string.in.h: Update.
695 * gnulib/import/stripslash.c: Update.
696 * gnulib/import/strnlen1.c: Update.
697 * gnulib/import/strnlen1.h: Update.
698 * gnulib/import/strstr.c: Update.
699 * gnulib/import/strtok_r.c: Update.
700 * gnulib/import/sys_stat.in.h: Update.
701 * gnulib/import/sys_time.in.h: Update.
702 * gnulib/import/sys_types.in.h: Update.
703 * gnulib/import/tempname.c: Update.
704 * gnulib/import/tempname.h: Update.
705 * gnulib/import/time.in.h: Update.
706 * gnulib/import/unistd--.h: Update.
707 * gnulib/import/unistd-safer.h: Update.
708 * gnulib/import/unistd.in.h: Update.
709 * gnulib/import/unsetenv.c: Update.
710 * gnulib/import/verify.h: Update.
711 * gnulib/import/extra/snippet/warn-on-use.h: Update.
712 * gnulib/import/wchar.in.h: Update.
713 * gnulib/import/wctype.in.h: Update.
714 * gnulib/import/xalloc-oversized.h: Update.
715 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
716 "53e2c179f26a890fa6685af4b6c1397ee370433b".
718 2018-08-16 Gary Benson <gbenson@redhat.com>
721 * gdb/main.c (captured_main_1): Exit with nonzero status
722 in batch mode if the last command to be executed failed.
723 * NEWS: Mention the above.
725 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
727 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
728 end of warning message.
730 2018-08-29 Alan Hayward <alan.hayward@arm.com>
733 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
734 (aarch64_extract_return_value): Use
735 aapcs_is_vfp_call_or_return_candidate.
736 (aarch64_return_in_memory): Likewise.
737 (aarch64_store_return_value): Likewise.
739 2018-08-29 Alan Hayward <alan.hayward@arm.com>
742 (aapcs_is_vfp_call_or_return_candidate): Make static
743 (pass_in_v_or_stack): Remove function.
744 (pass_in_v_vfp_candidate): New function.
745 (aarch64_push_dummy_call): Check for float register candidates.
747 2018-08-29 Alan Hayward <alan.hayward@arm.com>
749 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
750 (aapcs_is_vfp_call_or_return_candidate_1): New function.
751 (aapcs_is_vfp_call_or_return_candidate): Likewise.
753 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
756 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
757 (struct ipa_sym_addresses): Rename to...
758 (struct ipa_sym_addresses_common): ... this.
759 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
761 2018-08-28 Tom Tromey <tom@tromey.com>
763 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
764 (token_fifo): Now a std::vector.
765 (yylex, c_parse): Update.
766 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
767 (token_fifo): Now a std::vector.
768 (yylex, d_parse): Update.
769 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
770 (token_fifo): Now a std::vector.
771 (yylex, go_parse): Update.
773 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
775 * parser-defs.h (struct type_stack) <elements>: Change type to
776 std::vector<union type_stack_elt>.
777 <depth, size>: Remove.
778 * parse.c (parse_exp_in_context_1): Adjust.
779 (type_stack_reserve): Remove.
780 (check_type_stack_depth): Remove.
781 (insert_into_type_stack): Adjust to std::vector.
782 (insert_type): Likewise.
783 (push_type): Likewise.
784 (push_type_int): Likewise.
785 (insert_type_address_space): Likewise.
786 (pop_type): Likewise.
787 (pop_type_int): Likewise.
788 (pop_typelist): Likewise.
789 (pop_type_stack): Likewise.
790 (append_type_stack): Likewise.
791 (push_type_stack): Likewise.
792 (get_type_stack): Likewise.
793 (type_stack_cleanup): Likewise.
794 (push_typelist): Likewise.
795 (follow_types): Likewise.
796 (_initialize_parse): Likewise.
798 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
800 * NEWS: Mention csky target.
802 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
803 Hafiz Abid Qadeer <abidh@codesourcery.com>
804 Don Breazeal <donb@codesourcery.com>
806 * csky-linux-tdep.c: New file.
807 * csky-tdep.c: Likewise.
808 * csky-tdep.h: Likewise.
809 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
811 (HFILES_NO_SRCDIR): Add csky-tdep.h.
812 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
813 * configure.tgt: Add csky support.
815 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
817 * python/py-framefilter.c (py_print_frame): Print frame architecture
818 when printing on an MI output.
820 2018-08-27 Tom Tromey <tom@tromey.com>
823 * configure: Rebuild.
824 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
826 2018-08-27 Tom Tromey <tom@tromey.com>
828 * aarch64-linux-tdep.c
829 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
832 2018-08-27 Tom Tromey <tom@tromey.com>
834 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
836 (ppc64_standard_linkage1, ppc64_standard_linkage2)
837 (ppc64_standard_linkage3, ppc64_standard_linkage4)
838 (ppc64_standard_linkage5, ppc64_standard_linkage6)
839 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
842 2018-08-27 Tom Tromey <tom@tromey.com>
844 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
845 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
847 2018-08-27 Tom Tromey <tom@tromey.com>
849 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
850 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
852 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
854 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
856 * sparc-linux-tdep.c (sparc32_linux_sigframe)
857 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
858 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
860 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
861 (ppc64_linux_sigaction_tramp_frame)
862 (ppc32_linux_sighandler_tramp_frame)
863 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
864 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
865 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
866 * mn10300-linux-tdep.c (am33_linux_sigframe)
867 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
868 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
869 * mips-linux-tdep.c (mips_linux_o32_sigframe)
870 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
871 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
872 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
873 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
874 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
875 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
876 * microblaze-linux-tdep.c
877 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
878 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
879 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
880 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
881 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
882 * common/common-types.h (ULONGEST_MAX): New define.
883 (CORE_ADDR_MAX): Fix formatting.
884 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
885 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
886 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
887 (arm_linux_rt_sigreturn_tramp_frame)
888 (arm_eabi_linux_sigreturn_tramp_frame)
889 (arm_eabi_linux_rt_sigreturn_tramp_frame)
890 (thumb2_eabi_linux_sigreturn_tramp_frame)
891 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
892 (arm_linux_restart_syscall_tramp_frame)
893 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
894 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
895 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
897 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
899 2018-08-27 Tom Tromey <tom@tromey.com>
901 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
903 * mips-tdep.c (mips_deal_with_atomic_sequence)
904 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
905 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
906 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
907 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
909 * aarch64-tdep.c (aarch64_software_single_step): Use
912 2018-08-27 Tom Tromey <tom@tromey.com>
914 * linespec.c (complete_linespec_component): Add cast to "char".
915 * completer.c (completion_tracker::build_completion_result): Add
918 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
920 * solist.h (struct solist, struct target_so_ops): Fix
923 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
925 * ada-tasks.c (ada_task_info_s): Remove typedef.
926 (DEF_VEC_O(ada_task_info_s)): Remove.
927 (struct ada_tasks_inferior_data): Initialize fields.
928 <task_list>: Make an std::vector.
929 (get_ada_tasks_inferior_data): Allocate with new.
930 (ada_get_task_number): Adjust.
931 (get_task_number_from_id): Likewise.
932 (valid_task_id): Likewise.
933 (ada_get_task_info_from_ptid): Likewise.
934 (iterate_over_live_ada_tasks): Likewise.
935 (add_ada_task): Likewise.
936 (read_known_tasks): Likewise.
937 (ada_build_task_list): Likewise.
938 (print_ada_task_info): Likewise.
939 (info_task): Likewise.
940 (task_command_1): Likewise.
942 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
944 * ada-lang.c (add_angle_brackets): Return std::string.
946 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
948 * python/py-threadevent.c (py_get_event_thread): Initialize
951 2018-08-24 Pedro Alves <palves@redhat.com>
953 * python/py-bpevent.c (create_breakpoint_event_object): Use
955 * python/py-continueevent.c (emit_continue_event): Use
957 * python/py-exitedevent.c (create_exited_event_object): Return a
959 (emit_exited_event): Use copy-initialization.
960 * python/py-inferior.c (python_new_inferior)
961 (python_inferior_deleted, add_thread_object): Use
963 * python/py-infevents.c (create_inferior_call_event_object)
964 (create_register_changed_event_object)
965 (create_memory_changed_event_object): Return a gdbpy_ref<>.
966 (emit_inferior_call_event, emit_memory_changed_event)
967 (emit_register_changed_event): Use copy-initialization.
968 * python/py-newobjfileevent.c (create_new_objfile_event_object):
969 Return a gdbpy_ref<>.
970 (emit_new_objfile_event): Use copy-initialization.
971 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
972 (emit_clear_objfiles_event): Use copy-initialization.
973 * python/py-signalevent.c (create_signal_event_object): Use
975 * python/py-threadevent.c (create_thread_event_object): Use
978 2018-08-24 Pedro Alves <palves@redhat.com>
979 Simon Marchi <simon.marchi@ericsson.com>
982 * python/py-continueevent.c: Include "gdbthread.h".
983 (create_continue_event_object): Add intro comment. Add 'ptid'
984 parameter. Use it to find thread to pass to
985 create_thread_event_object.
986 (emit_continue_event): Pass PTID down to
987 create_continue_event_object.
988 * python/py-event.h (py_get_event_thread): Declare.
989 (create_thread_event_object): Remove default from 'thread'
991 * python/py-stopevent.c (create_stop_event_object): Use
993 * python/py-threadevent.c (get_event_thread): Rename to ...
994 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
995 and use it to find the thread.
996 (create_thread_event_object): Assert that THREAD isn't null.
997 Don't find the event thread here.
999 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1001 * block.h (blockrange, blockranges): New struct declarations.
1002 (struct block): Add new field named `ranges'.
1003 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1004 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1005 macros for accessing ranges in struct block.
1006 (make_blockranges): New declaration.
1007 block.c (make_blockranges): New function.
1008 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1010 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1011 * blockframe.c (cache_pc_function_block): New static global.
1012 (clear_pc_function_cache): Clear cache_pc_function_block.
1013 (find_pc_partial_function): Move comment to symtab.h. Add
1014 support for non-contiguous blocks.
1015 * cli/cli-cmds.c (block.h): Include.
1016 (print_disassembly): Handle printing of non-contiguous blocks.
1017 (disassemble_current_function): Likewise.
1018 (disassemble_command): Likewise.
1020 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1022 * blockframe.c (get_pc_function_start): Likewise.
1023 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1024 (gcc_symbol_address): Likewise.
1025 * compile/compile-object-run.c (compile_object_run): Likewise.
1026 * compile/compile.c (get_expr_block_and_pc): Likewise.
1027 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1028 (func_addr_to_tail_call_list): Likewise.
1029 * findvar.c (default_read_var_value): Likewise.
1030 * inline-frame.c (inline_frame_this_id): Likewise.
1031 (skip-inline_frames): Likewise.
1032 * infcmd.c (until_next_command): Likewise.
1033 * linespec.c (convert_linespec_to_sals): Likewise.
1034 * parse.c (parse_exp_in_context_1): Likewise.
1035 * printcmd.c (build_address_symbolic): likewise.
1036 (info_address_command): Likewise.
1037 symtab.c (find_function_start_sal): Likewise.
1038 (skip_prologue_sal): Likewise.
1039 (find_function_alias_target): Likewise.
1040 (find_gnu_ifunc): Likewise.
1041 * stack.c (find_frame_funname): Likewise.
1042 * symtab.c (fixup_symbol_section): Likewise.
1043 (find_function_start_sal): Likewise.
1044 (skip_prologue_sal): Likewsie.
1045 (find_function_alias_target): Likewise.
1046 (find_gnu_ifunc): Likewise.
1047 * tracepoint.c (info_scope_command): Likewise.
1048 * value.c (value_fn_field): Likewise.
1050 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1051 in place of find_pc_partial_function.
1052 * blockframe.c (find_function_entry_range_from_pc): New function.
1053 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1054 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1055 for each range in a block.
1058 2018-08-23 Xavier Roirand <roirand@adacore.com>
1060 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1063 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1065 * solib-svr4.c (read_program_headers_from_bfd): Return
1066 gdb::optional<gdb::byte_vector>.
1067 (svr4_exec_displacement): Adjust.
1069 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1071 * solib-svr4.c (read_program_header): Return
1072 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
1073 (find_program_interpreter): Return
1074 gdb::optional<gdb::byte_vector>.
1075 (scan_dyntag_auxv): Adjust.
1076 (enable_break): Adjust.
1077 (svr4_exec_displacement): Adjust.
1079 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1081 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
1082 * inf-child.c (inf_child_target::terminal_save_inferior): New.
1084 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1086 * guile/scm-string.c (gdbscm_scm_from_printf): Use
1088 * guile/scm-utils.c (gdbscm_printf): Likewise.
1089 * serial.c (serial_printf): Likewise.
1090 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
1092 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
1094 * stack.c (print_frame): Print frame architecture when printing on
1096 * NEWS: Mention new "arch" attribute in frame output.
1098 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1100 * arch/aarch64.h (aarch64_regnum): Update comment.
1102 2018-08-21 Alan Hayward <alan.hayward@arm.com>
1104 * NEWS: Add SVE to 8.2 section.
1106 2018-08-21 Pedro Alves <palves@redhat.com>
1108 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
1109 out from gdbscm_parse_function_args.
1110 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
1111 gdbscm_parse_function_args_1.
1113 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
1116 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
1119 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
1121 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
1123 2018-08-19 Michael Spang <spang@google.com>
1126 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
1127 for PT_TLS segments.
1129 2018-08-18 Kevin Buettner <kevinb@redhat.com>
1131 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
1132 dwarf_variable_value.
1133 * dwarf2-frame.c (class dwarf_expr_executor):
1134 Add override for dwarf_variable_value.
1135 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
1136 (class symbol_needs_eval_context): Likewise.
1137 (indirect_synthetic_pointer): Add forward declaration.
1138 (sect_variable_value): New function.
1139 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
1140 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
1141 for DW_OP_GNU_variable_value.
1143 2018-08-16 Tom Tromey <tom@tromey.com>
1145 * top.c (read_command_file): Update.
1146 (command_line_input): Remove "repeat" argument.
1147 * ada-lang.c (get_selections): Update.
1148 * linespec.c (decode_line_2): Update.
1149 * defs.h (command_line_input): Remove argument.
1150 * cli/cli-script.c (read_next_line): Update.
1151 * python/py-gdb-readline.c: Update.
1153 2018-08-17 Tom Tromey <tom@tromey.com>
1155 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
1158 2018-08-15 Tom Tromey <tom@tromey.com>
1160 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
1162 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
1164 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
1165 If used, use find_pc_partial_function to find address range
1167 * mi/mi-main.c (mi_cmd_list_features): Report
1168 "data-disassemble-a-option" feature.
1169 * NEWS: Mention new -data-disassemble option -a.
1171 2018-08-13 Tom Tromey <tom@tromey.com>
1173 * common/common-defs.h (_FORTIFY_SOURCE): Define.
1175 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1177 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
1178 (aarch64_linux_collect_sve_regset): Likewise.
1179 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
1180 * regcache.h (regcache_map_entry_size): New function.
1182 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1184 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
1185 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
1186 (SVE_HEADER_VL_LENGTH): Likewise.
1187 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
1188 (SVE_HEADER_FLAGS_LENGTH): Likewise.
1189 (SVE_HEADER_RESERVED_LENGTH): Likewise.
1190 (SVE_HEADER_SIZE_OFFSET): Likewise.
1191 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
1192 (SVE_HEADER_VL_OFFSET): Likewise.
1193 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
1194 (SVE_HEADER_FLAGS_OFFSET): Likewise.
1195 (SVE_HEADER_RESERVED_OFFSET): Likewise.
1196 (SVE_HEADER_SIZE): Likewise.
1197 (aarch64_linux_core_read_vq): Add function.
1198 (aarch64_linux_core_read_description): Check for SVE section.
1200 2018-08-13 Alan Hayward <alan.hayward@arm.com>
1202 * aarch64-fbsd-tdep.c
1203 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
1205 * aarch64-linux-tdep.c
1206 (aarch64_linux_iterate_over_regset_sections): Likewise.
1207 * alpha-linux-tdep.c
1208 (alpha_linux_iterate_over_regset_sections):
1210 (alphanbsd_iterate_over_regset_sections): Likewise.
1212 (amd64fbsd_iterate_over_regset_sections): Likewise.
1213 * amd64-linux-tdep.c
1214 (amd64_linux_iterate_over_regset_sections): Likewise.
1216 (armbsd_iterate_over_regset_sections): Likewise.
1218 (arm_fbsd_iterate_over_regset_sections): Likewise.
1220 (arm_linux_iterate_over_regset_sections): Likewise.
1221 * corelow.c (get_core_registers_cb): Likewise.
1222 (core_target::fetch_registers): Likewise.
1223 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
1224 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
1225 * gdbarch.h (void): Regenerate.
1226 * gdbarch.sh: Add supply_size and collect_size.
1227 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
1228 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
1229 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
1230 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
1231 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
1232 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
1233 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
1234 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
1235 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
1236 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
1237 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
1238 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
1239 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
1240 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
1241 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
1242 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
1243 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
1244 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
1245 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
1246 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
1247 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
1248 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
1249 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
1250 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
1251 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
1252 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
1253 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
1254 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
1255 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
1256 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
1258 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
1260 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
1263 2018-08-10 Keith Seitz <keiths@redhat.com>
1265 * compile/compile-c-support.c (add_code_header, add_code_footer):
1266 Move into policy class.
1267 (c_push_user_expression, pop_user_expression_nop)
1268 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
1269 (compile_program): New host class.
1270 (c_compile_program): New typedef.
1271 (c_compute_porgram): Use c_compile_program.
1273 2018-08-10 Keith Seitz <keiths@redhat.com>
1275 * compile/compile-internal.h (compile_instance::~compile_instance):
1276 Remove calls to htab_delete.
1277 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
1278 * compile.c (compile_instance::compile_instance): Initialize
1279 htab unique pointers.
1280 (compile_instance::get_cached_type, compile_instance::insert_type)
1281 (compile_instance::error_symbol_once): Update for unique_ptr.
1283 2018-08-10 Keith Seitz <keiths@redhat.com>
1285 * compile/compile-c-symbols.c (struct symbol_error)
1286 (hash_symbol_error, eq_symbol_error, del_symbol_error)
1287 (compile_instance::insert_symbol_error)
1288 (compile_instance::error_symbol_once): Move to ...
1289 * compile/compile.c: ... here.
1291 2018-08-10 Keith Seitz <keiths@redhat.com>
1293 * compile/compile-c-support.c (c_get_compile_context): Use `new'
1294 instead of `new_compile_instance'.
1295 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
1297 If the symbol error map is not initialized, create it.
1298 (generate_c_for_for_one_symbol): Do not check/initialize
1299 the symbol error map.
1300 * compile/compile-c-types.c (compile_c_instance): Make a class.
1302 (compile_instance::compile_instance): Initialize the type cache.
1303 (get_cached_type): New function.
1304 (insert_type): Update description.
1305 (compile_c_instance::m_default_cflags): Define.
1306 (convert_type): Update description. Use get_cached_type.
1307 (delete_instance): Moved to destructor.
1308 (new_compile_instance): Moved to constructor.
1309 * compile/compile-c.h (compile_c_instance): Make class inheriting
1310 from compile_instance.
1311 <base>: Remove field.
1312 <type_map, symbol_err_map>: Move to base class.
1313 <c_plugin>: Rename to `m_plugin' and remove pointer type.
1314 * compile/compile-internal.h (compile_instance): Make class.
1315 <type_map_t, symbol_err_map_t>: Define.
1316 <fe>: Rename to `m_gcc_fe'.
1317 <scope, block, gcc_target_options>: Add `m_' prefix.
1318 <m_type_map, m_symbol_err_map>: New fields, moved from
1321 (convert_type, new_compile_instance): Remove.
1322 * compile/compile.c (cleanup_compile_instance): Remove.
1323 (compile_to_object): Use unique_ptr to eliminate cleanups.
1324 (compile_instance::set_print_callback, compile_instance::version)
1325 (compile_instance::set_verbose)
1326 (compile_instance::set_driver_filename)
1327 (compile_instance::set_triplet_regexp)
1328 (compile_instance::set_arguments)
1329 (compile_instance::set_source_file)
1330 (compile_instance::compile): Define.
1332 2018-08-10 Keith Seitz <keiths@redhat.com>
1334 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
1335 * compile/compile-c-types.c: Define GCC_METHODN macros and include
1336 gcc-c-fe.def to define C plugin.
1337 (delete_instance): Delete `c_plugin'.
1338 (new_compile_instance): Initialize `c_plugin'.
1339 * compile/compile-c.h: Include gcc_c_plugin.h.
1340 (struct compile_c_instance) <c_plugin>: New member.
1341 * gcc-c-plugin.h: New file.
1342 Update all callers with API change.
1344 2018-08-10 Keith Seitz <keiths@redhat.com>
1346 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
1347 (HFILES_NO_SRCDIR): ... to here.
1348 Add compile-internal.h and compile-c.h.
1349 * compile/compile-c-support.c: Include compile-c.h.
1350 * compile/compile-c-symbols.c: Include compile-c.h.
1351 (generate_c_for_variable_locations): Update comment.
1352 * compile/compile-c-types.c: Include compile-c.h.
1353 * compile/compile-c.h: New file -- moved C language declarations
1354 from other files here.
1355 * compile/compile-internal.h: Do not include hashtab.h or
1356 common/enum-flags.h.
1357 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
1358 (gcc_convert_symbol, gcc_symbol_address)
1359 (generate_c_for_variable_locations, c_get_mode_for_size)
1360 (c_get_range_decl_name): Definitions moved to compile-c.h.
1361 * compile/compile-loc2c.c: Include compile-c.h.
1363 2018-08-10 Keith Seitz <keiths@redhat.com>
1365 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
1366 (c_symbol_substitution_name): ... this.
1369 2018-08-10 Keith Seitz <keiths@redhat.com>
1371 * compile/compile-c-support.c (c_compute_program): Use
1372 unique_xmalloc_ptr to eliminate cleanup.
1373 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
1374 Return a unique_xmalloc_ptr and eliminate cleanup.
1375 * compile/compile-internal.h (generate_c_for_variable_locations):
1376 Return unique_xmalloc_ptr and update description.
1378 2018-08-10 Alan Hayward <alan.hayward@arm.com>
1380 * corelow.c (core_target::get_core_register_section): Rename
1381 min_size to section_min_size.
1383 2018-08-09 Jim Wilson <jimw@sifive.com>
1385 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
1386 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
1387 * NEWS: Mention new GNU/Linux RISC-V target.
1388 * configure.host: Add riscv*-*-linux*.
1389 * configure.nat: Add riscv*.
1390 * configure.tgt: Add riscv*-*-linux*.
1391 * riscv-linux-nat.c: New file.
1392 * riscv-linux-tdep.c: New file.
1394 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
1396 * infrun.c (resume): Make static, add forward declaration.
1397 (proceed): Update header comment.
1398 * infrun.h (resume): Delete declaration.
1400 2018-08-09 Tom Tromey <tom@tromey.com>
1402 * riscv-tdep.h: Minor formatting fixes.
1404 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
1406 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
1407 * dwarf-index-cache.c (create_dir_and_check): Likewise.
1408 (test_mkdir_recursive): Likewise.
1409 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
1411 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
1413 * valarith.c (value_subscripted_rvalue): If an array is not in
1414 memory, and we don't know the upper bound, then we can't know that
1415 the requested element exists or not.
1417 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
1419 * target.c (str_comma_list_concat_elem): Fix typo in comment.
1420 (target_options_to_string): Add comment.
1422 2018-08-08 Tom Tromey <tom@tromey.com>
1424 * unittests/scoped_mmap-selftests.c: Check result of "write".
1426 2018-08-08 Jim Wilson <jimw@sifive.com>
1428 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
1429 (decode_register_index_short): New.
1430 (decode_j_type_insn, decode_cj_type_insn): New.
1431 (decode_b_type_insn, decode_cb_type_insn): New.
1432 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
1433 local xlen. Check xlen when decoding ambiguous compressed insns. In
1434 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
1435 is_c_sw_insn instead of is_sw_insn.
1436 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
1437 (riscv_software_single_step): New.
1438 * riscv-tdep.h (riscv_software_single_step): Declare.
1440 * riscv-tdep.c (riscv_isa_xlen): Drop static.
1441 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
1443 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
1446 * target.c (dispose_inferior): Don't dispose of inferiors that are
1449 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
1451 * remote.c (remote_target::download_tracepoint): Change char* to
1454 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
1456 * target.h (target_options_to_string): Return an std::string.
1457 * target.c (str_comma_list_concat_elem): Return void, use
1459 (do_option): Likewise.
1460 (target_options_to_string): Return an std::string.
1461 * linux-nat.c (linux_nat_target::wait): Adjust.
1462 * target-debug.h (target_debug_print_options): Adjust.
1464 2018-08-07 Tom Tromey <tom@tromey.com>
1466 * Makefile.in (CPPFLAGS): New variable.
1467 (INTERNAL_CPPFLAGS): Use it.
1469 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1471 * NEWS: Mention the index cache.
1473 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1475 * common/pathstuff.h (get_standard_cache_dir): New.
1476 * common/pathstuff.c (get_standard_cache_dir): New.
1477 * build-id.h (build_id_to_string): New.
1478 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
1479 DEBUG_STR_SUFFIX): Move to here.
1480 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
1481 DEBUG_STR_SUFFIX): Move from there.
1482 (write_psymtabs_to_index): Make non-static, add basename
1483 parameter. Write to temporary files, rename when done.
1484 (save_gdb_index_command): Adjust call to
1485 write_psymtabs_to_index.
1486 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
1488 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
1489 (get_gdb_index_contents_from_cache): New.
1490 (get_gdb_index_contents_from_cache_dwz): New.
1491 (dwarf2_initialize_objfile): Read index from cache.
1492 (dwarf2_build_psymtabs): Save to index.
1493 * dwarf-index-cache.h: New file.
1494 * dwarf-index-cache.c: New file.
1495 * dwarf-index-write.h: New file.
1497 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1499 * gnulib/aclocal.m4: Re-generate.
1500 * gnulib/config.in: Re-generate.
1501 * gnulib/configure: Re-generate.
1502 * gnulib/import/Makefile.am: Re-generate.
1503 * gnulib/import/Makefile.in: Re-generate.
1504 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1505 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1506 * gnulib/import/m4/mkdir.m4: New file.
1507 * gnulib/import/mkdir.c: New file.
1508 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
1511 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1513 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
1514 * common/scoped_mmap.c: New file.
1515 * common/scoped_mmap.h (destroy): New method.
1516 (~scoped_mmap, reset): Use destroy.
1517 (scoped_mmap): New move constructor.
1518 (mmap_file): New declaration.
1519 * unittests/scoped_mmap-selftests.c (test_normal,
1520 test_invalid_filename, run_tests): New functions.
1521 (_initialize_scoped_mmap_selftests): Register selftest.
1523 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1525 * dwarf2read.c (read_gdb_index_from_section): Rename to...
1526 (read_gdb_index_from_buffer): ... this. Remove section
1527 parameter, add buffer parameter.
1528 (get_gdb_index_contents_ftype,
1529 get_gdb_index_contents_dwz_ftype): New typedefs.
1530 (dwarf2_read_gdb_index): Add callback parameters to get the
1532 (get_gdb_index_contents_from_section): New.
1533 (dwarf2_initialize_objfile): Update call to
1534 dwarf2_read_gdb_index.
1536 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
1538 * common/filestuff.h (gdb_fopen_cloexec): New overload.
1539 (gdb_open_cloexec): Likewise.
1540 * nat/linux-osdata.c (command_from_pid): Use string_printf.
1541 (commandline_from_pid): Likewise.
1542 (linux_xfer_osdata_threads): Likewise.
1543 (linux_xfer_osdata_fds): Likewise.
1544 * ada-lang.c (is_package_name): Likewise.
1545 * auxv.c (procfs_xfer_auxv): Likewise.
1546 * breakpoint.c (print_one_breakpoint_location): Use
1548 (print_one_catch_solib): Use string_printf.
1549 * coff-pe-read.c (add_pe_exported_sym): Likewise.
1550 (add_pe_forwarded_sym): Likewise.
1551 * dwarf2read.c (create_type_unit_group): Likewise.
1552 (build_error_marker_type): Likewise.
1553 * infcall.c (get_function_name): Likewise.
1554 * valprint.c (print_converted_chars_to_obstack): Likewise.
1555 * xtensa-tdep.c (xtensa_register_type): Likewise.
1557 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
1559 * remote.c (remote_target::download_tracepoint): Fix format
1562 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1564 * tracefile.c: Include common/byte-vector.h.
1565 (trace_save): Change type of buf to gdb::byte_vector. Initialize
1566 with trace_regblock_size if needed. Update uses of buf.
1568 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1570 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
1571 std::vector<unsigned char>.
1572 * tracepoint.c (collection_list::collection_list): Remove
1573 m_regs_mask initializer from initializer list. Resize
1574 m_regs_mask using the largest remote register number.
1575 (collection_list::add_remote_register): Remove size check on
1576 m_regs_mask. Use at to access element.
1577 (collection_list::stringify): Change type of temp_buf to
1578 gdb::char_vector. Update uses of temp_buf. Resize if needed to
1579 stringify the register mask. Use pack_hex_byte for the register
1582 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1584 * tracepoint.h (class collection_list) <add_register>: Remove.
1585 <add_remote_register, add_ax_registers, add_local_register>:
1587 <add_memrange>: Add scope parameter.
1588 * tracepoint.c (encode_actions_1): Likewise.
1589 (collection_list::add_register): Rename to ...
1590 (collection_list::add_remote_register): ... this. Update
1592 (collection_list::add_ax_registers, add_local_register): New
1594 (collection_list::add_memrange): Add scope parameter. Call
1595 add_local_register instead of add_register.
1596 (finalize_tracepoint_aexpr): New function.
1597 (collection_list::collect_symbol): Update calls to add_memrange.
1598 Call add_local_register instead of add_register. Call
1599 add_ax_registers. Call finalize_tracepoint_aexpr.
1600 (encode_actions_1): Get remote regnos for $reg action. Call
1601 add_remote_register, add_ax_registers, and add_local_register.
1602 Update call to add_memrange. Call finalize_tracepoint_aexpr.
1603 (validate_actionline): Call finalize_tracepoint_aexpr.
1605 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1607 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
1608 Replace array buf with gdb::char_vector buf, of size
1609 get_remote_packet_size (). Replace references to buf and
1610 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
1611 and xsnprintf with snprintf. Raise errors if the buffer is too
1614 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1616 * remote.c (remote_target::download_tracepoint): Fix the has_more
1617 predicate in the QTDP action list iteration.
1619 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1621 * remote.c (remote_target::download_tracepoint): Fix indentation
1624 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1626 * proc-api.c (_initialize_proc_api): Remove c, unused.
1627 * procfs.c (procfs_init_inferior): Remove signals, unused.
1628 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
1631 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
1632 Andrew Burgess <andrew.burgess@embecosm.com>
1634 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
1635 'W_STOPCODE (0)' as this could be ambiguous.
1637 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
1639 * ser-tcp.c (net_open): Fix thinko when deciding whether to
1640 disable TCP's Nagle algorithm (use "ai_protocol" instead of
1643 2018-08-02 Tom Tromey <tom@tromey.com>
1646 * dwarf2read.c (read_func_scope): Set symtab on template parameter
1648 (process_structure_scope): Likewise.
1650 2018-08-02 Xavier Roirand <roirand@adacore.com>
1653 * darwin-nat.c (darwin_kill_inferior): Fix handling of
1656 2018-08-02 Tom Tromey <tom@tromey.com>
1658 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
1659 (darwin_suspend_inferior, darwin_resume_inferior)
1660 (darwin_decode_notify_message, darwin_resume_inferior_threads)
1661 (darwin_check_new_threads): Check result of get_darwin_inferior.
1663 2018-07-31 Joel Brobecker <brobecker@adacore.com>
1667 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
1669 * varobj.c (varobj_get_path_expr_parent): Report an error if
1670 parent is a dynamic varobj.
1672 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
1674 * gnulib/aclocal.m4: Re-generate.
1675 * gnulib/config.in: Re-generate.
1676 * gnulib/configure: Re-generate.
1677 * gnulib/import/Makefile.in: Re-generate.
1678 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1679 * gnulib/import/m4/onceonly.m4: Re-generate.
1681 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
1683 * target-descriptions.c (struct xml_test_tdesc): New.
1684 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
1685 (record_xml_tdesc): Update.
1686 (maintenance_check_xml_descriptions): Update.
1687 * target-descriptions.h (record_xml_tdesc): Update comment.
1689 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
1691 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
1692 checking array bounds are defined.
1694 2018-07-30 Tom Tromey <tom@tromey.com>
1696 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
1697 irreflexivity violation.
1699 2018-07-30 Tom Tromey <tom@tromey.com>
1701 * cli/cli-decode.c (lookup_cmd): Remove lint code.
1702 * value.c (unpack_long): Remove lint code.
1703 * valops.c (value_ind): Remove lint code.
1704 * valarith.c (value_x_binop, value_x_unop, value_equal)
1705 (value_pos): Remove lint code.
1707 2018-07-28 Tom de Vries <tdevries@suse.de>
1709 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
1710 with undefined upper bound as <optimized out>.
1712 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
1714 * gcore.in: Rename variable "name" to "prefix". Expand
1717 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
1719 * windows-nat.c (windows_nat_target::create_inferior): Update to
1720 call close() in global namespace.
1722 2018-07-26 Tom Tromey <tom@tromey.com>
1724 * dwarf-index-write.c (add_address_entry): Don't add objfile
1726 * dbxread.c (find_stab_function): Rename from
1727 find_stab_function_addr. Return a bound_minimal_symbol.
1728 (read_dbx_symtab): Use raw_text_low, raw_text_high.
1729 Don't add objfile offsets.
1730 (end_psymtab): Use raw_text_low, raw_text_high,
1731 MSYMBOL_VALUE_RAW_ADDRESS.
1732 (read_ofile_symtab): Update.
1733 (process_one_symbol): Update.
1734 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
1736 (dw2_relocate): Remove.
1737 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
1739 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
1741 (process_psymtab_comp_unit_reader, add_partial_symbol)
1742 (add_partial_subprogram, dwarf2_ranges_read): Update.
1743 (load_partial_dies): Update.
1744 (add_address_entry): Don't add objfile offsets.
1745 (dwarf2_build_include_psymtabs): Update.
1746 (create_addrmap_from_aranges): Don't add objfile offsets.
1747 (dw2_find_pc_sect_compunit_symtab): Update.
1748 * mdebugread.c (parse_symbol): Don't add objfile offsets.
1749 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
1751 (parse_partial_symbols): Don't add objfile offsets. Use
1752 raw_text_low, raw_text_high. Update.
1753 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
1754 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
1755 or call 'relocate' quick function. Clear psymbol_map.
1756 * psympriv.h (struct partial_symbol) <address>: Add section
1758 <set_unrelocated_address>: Rename from set_address.
1759 <raw_text_low, raw_text_high>: New methods.
1760 <text_low, text_high>: Add objfile parameter.
1761 (add_psymbol_to_bcache): Add 'section' parameter. Call
1762 set_unrelocated_address.
1763 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1764 (find_pc_psymbol): Update.
1765 (fixup_psymbol_section, relocate_psymtabs): Remove.
1766 (dump_psymtab, psym_functions): Update.
1767 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
1769 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
1770 (start_psymtab_common): Update.
1771 * symfile-debug.c (debug_qf_relocate): Remove.
1772 (debug_sym_quick_functions): Update.
1773 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
1774 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
1777 2018-07-26 Tom Tromey <tromey@redhat.com>
1779 * dbxread.c (end_psymtab): Use text_high_valid and
1781 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
1782 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
1783 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
1785 <text_low_valid, text_high_valid>: New fields.
1786 <set_text_low, set_text_high>: Update.
1787 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
1789 2018-07-26 Tom Tromey <tom@tromey.com>
1791 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
1793 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
1794 textlow and texthigh fields.
1795 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
1797 * mdebugread.c (parse_lines, parse_partial_symbols)
1798 (psymtab_to_symtab_1): Update.
1799 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
1800 Rename fields. Update comment. Now private.
1801 <text_low, text_high, set_text_low, set_text_high>: New methods.
1802 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1803 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
1804 (start_psymtab_common, maintenance_info_psymtabs)
1805 (maintenance_check_psymtabs): Update.
1806 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
1808 (scan_xcoff_symtab): Update.
1810 2018-07-26 Tom Tromey <tromey@redhat.com>
1812 * psympriv.h (struct partial_symbol) <unrelocated_address,
1813 address, set_address>: New methods.
1814 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
1815 (fixup_psymbol_section, relocate_psymtabs): Update.
1816 (print_partial_symbols): Add 'objfile' parameter. Update.
1817 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
1820 2018-07-26 Tom Tromey <tom@tromey.com>
1822 * dwarf-index-write.c (write_psymbols, debug_names::insert)
1823 (debug_names::write_psymbols): Update.
1824 * psympriv.h (struct partial_symbol): Derive from
1825 general_symbol_info.
1826 <obj_section>: New method.
1827 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
1828 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
1829 (find_pc_sect_psymbol, fixup_psymbol_section)
1830 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
1831 (print_partial_symbols, recursively_search_psymtabs)
1832 (compare_psymbols, psymbol_hash, psymbol_compare)
1833 (add_psymbol_to_bcache, maintenance_check_psymtabs)
1834 (psymbol_name_matches, psym_fill_psymbol_map): Update.
1836 2018-07-26 Tom Tromey <tromey@redhat.com>
1838 * dbxread.c (end_psymtab): Remove dead code.
1840 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
1842 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
1843 DWARF unwinders are disabled.
1844 * dwarf2-frame.c: Add dwarf2read.h include.
1845 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
1847 (dwarf2_frame_unwinders_enabled_p): Define.
1848 (show_dwarf_unwinders_enabled_p): New function.
1849 (_initialize_dwarf2_frame): Register switch to control DWARF
1851 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
1852 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
1853 (show_dwarf_cmdlist): Remove static keyword.
1854 * dwarf2read.h (set_dwarf_cmdlist): Declare.
1855 (show_dwarf_cmdlist): Declare.
1856 * NEWS: Document new feature.
1858 2018-07-26 Tom de Vries <tdevries@suse.de>
1860 PR breakpoints/23366
1861 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
1863 2018-07-26 Tom de Vries <tdevries@suse.de>
1865 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
1866 DW_AT_count can't be translated to a dynamic prop.
1868 2018-07-25 Tom de Vries <tdevries@suse.de>
1870 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
1873 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
1875 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
1877 2018-07-25 Joel Brobecker <brobecker@adacore.com>
1879 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
1881 2018-07-24 Keith Seitz <keiths@redhat.comt
1884 * dwarf2read.c (dw2_add_symbol_to_list): New function.
1885 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
1886 instead of add_symbol_to_list.
1887 (read_file_scope): Call prepare_one_comp_unit before reading
1890 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
1892 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
1894 2018-07-24 Tom Tromey <tom@tromey.com>
1896 * utils.c (malloc, realloc, free): Don't declare.
1897 * configure, config.in: Rebuild.
1898 * configure.ac: Don't check for declarations of free, malloc, or
1901 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1903 * aarch64-linux-nat.c
1904 (aarch64_linux_nat_target::stopped_data_address): Remove unused
1906 * arm-linux-nat.c (fetch_regs): Likewise.
1907 (store_regs): Likewise.
1908 (fetch_vfp_regs): Likewise.
1909 (store_vfp_regs): Likewise.
1910 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
1911 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
1912 (arm_linux_nat_target::insert_watchpoint): Likewise.
1913 (arm_linux_nat_target::remove_watchpoint): Likewise.
1914 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
1916 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
1918 * ppc-linux-nat.c (fetch_register): Likewise.
1919 (fetch_all_gp_regs): Likewise.
1920 (fetch_ppc_registers): Likewise.
1921 (store_all_gp_regs): Likewise.
1922 (store_ppc_registers): Likewise.
1923 (hwdebug_insert_point): Likewise.
1924 (can_use_watchpoint_cond_accel): Likewise.
1925 * remote-sim.c (gdb_os_write_stdout): Likewise.
1927 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1928 Tom Tromey <tom@tromey.com>
1930 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
1932 * configure: Rebuild.
1934 2018-07-22 Tom Tromey <tom@tromey.com>
1936 * regformats/regdat.sh: Define xmltarget_${name} inside
1937 #ifndef IN_PROCESS_AGENT.
1939 2018-07-22 Tom Tromey <tom@tromey.com>
1941 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
1943 2018-07-22 Tom Tromey <tom@tromey.com>
1945 * symfile.c (reread_symbols): Notify iter, not objfile.
1947 2018-07-22 Tom Tromey <tom@tromey.com>
1949 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
1951 (ravenscar_thread_target::prepare_to_store): Likewise.
1953 2018-07-22 Tom Tromey <tom@tromey.com>
1955 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
1956 unused variable. Call value_fetch_lazy when needed.
1957 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
1958 Remove unused variable. Call value_fetch_lazy when needed.
1960 2018-07-22 Tom Tromey <tom@tromey.com>
1962 * m32c-tdep.c (mark_dma): Return void.
1963 (make_regs): Remove unused declarations.
1965 2018-07-22 Tom Tromey <tom@tromey.com>
1967 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
1968 cmdscm_get_valid_command_smob_arg_unsafe for effect.
1969 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
1970 bkscm_get_valid_block_smob_arg_unsafe for effect.
1972 2018-07-22 Tom Tromey <tom@tromey.com>
1974 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
1977 2018-07-22 Tom Tromey <tom@tromey.com>
1979 * windows-nat.c (saved_context): Conditionally define.
1980 * remote.c (remote_target::remote_btrace_maybe_reopen):
1981 Conditionally declare "warned".
1982 * inflow.c (sigquit_ours): Conditionally define.
1983 (new_tty): Move "tty" declaration inside #if.
1984 * guile/guile.c (guile_datadir): Conditionally define.
1985 * charset.c (set_be_le_names): Move some declarations inside #if.
1986 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
1988 (parse_xml_btrace_conf): Likewise.
1990 2018-07-22 Tom Tromey <tom@tromey.com>
1992 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
1994 2018-07-22 Tom Tromey <tom@tromey.com>
1996 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
1997 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
1998 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
1999 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2000 * stack.c (frame_apply_level_command): Remove unused variable.
2001 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2002 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2003 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2005 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2006 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2007 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2009 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2010 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2012 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2013 Remove unused variable.
2014 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2016 * common/tdesc.c (print_xml_feature::visit): Remove unused
2018 * compile/compile-object-load.c (store_regs): Remove unused
2020 * complaints.c (clear_complaints): Remove unused variable.
2021 * corelow.c (core_target_open): Remove unused variable.
2022 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2024 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2026 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2028 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2030 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2032 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2034 * ia64-tdep.c (examine_prologue): Remove unused variable.
2035 * infcall.c (run_inferior_call): Remove unused variable.
2036 * inferior.c (exit_inferior): Remove unused variable.
2037 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2038 * linespec.c (decode_line_2): Remove unused variable.
2039 * linux-nat.c (super_close): Remove.
2040 * linux-tdep.c (linux_info_proc): Remove unused variable.
2041 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2042 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2043 Remove unused variable.
2044 * parse.c (find_minsym_type_and_address): Remove unused variable.
2045 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2047 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2049 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2051 * record-btrace.c (record_btrace_target::store_registers): Remove
2053 (cmd_show_record_btrace_cpu): Remove unused variable.
2054 * riscv-tdep.c (riscv_register_reggroup_p)
2055 (riscv_push_dummy_call, riscv_return_value): Remove unused
2057 * rust-exp.y (literal): Remove unused variable.
2058 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2060 <STRUCTOP_ANONYMOUS>: Likewise.
2061 * s390-linux-tdep.c (s390_linux_init_abi_31)
2062 (s390_linux_init_abi_64): Remove unused variable.
2063 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2064 (file_select_thread, net_windows_open, _initialize_ser_windows):
2065 Remove unused variables.
2066 * symtab.c (find_pc_sect_line): Remove unused variable.
2067 * target-memory.c (compute_garbled_blocks): Remove unused
2069 (target_write_memory_blocks): Remove unused variable.
2070 * target.c (target_stack::unpush): Remove unused variables.
2071 * tracepoint.c (start_tracing, all_tracepoint_actions)
2072 (merge_uploaded_trace_state_variables)
2073 (print_one_static_tracepoint_marker): Remove unused variable.
2074 * unittests/basic_string_view/element_access/char/1.cc (test01):
2075 Remove unused variable.
2076 * windows-nat.c (windows_continue, windows_add_all_dlls)
2077 (do_initial_windows_stuff, windows_nat_target::create_inferior):
2078 Remove unused variables.
2080 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2082 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
2083 attr_profile in HAVE_ELF.
2084 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
2087 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
2089 * frame.c (frame_register_unwind): Change parameter name.
2090 (frame_unwind_register): Likewise.
2091 (frame_unwind_register_value): Likewise.
2092 (frame_unwind_register_signed): Likewise.
2093 (frame_unwind_register_unsigned): Likewise.
2094 * frame.h (frame_register_unwind): Likewise.
2095 (frame_unwind_register): Likewise.
2096 (frame_unwind_register_value): Likewise.
2097 (frame_unwind_register_signed): Likewise.
2098 (frame_unwind_register_unsigned): Likewise.
2099 (frame_unwind_arch): Likewise.
2101 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2103 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
2106 2018-07-20 Maciej W. Rozycki <macro@mips.com>
2108 * mips-linux-nat.c (mips_linux_nat_target::read_description):
2109 Call `get_ptrace_pid' rather than extracting the ptrace PID by
2112 2018-07-20 Keith Seitz <keiths@redhat.com>
2114 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
2115 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
2116 m_compunit_symtab, m_language>: Add "m_" prefix.
2118 * buildsym.c: Update all uses.
2120 2018-07-20 Tom Tromey <tom@tromey.com>
2122 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
2123 * buildsym.h (record_line_ftype): Remove typedef.
2125 2018-07-20 Tom Tromey <tom@tromey.com>
2127 * buildsym-legacy.h (augment_type_symtab): Don't declare.
2128 (end_expandable_symtab): Likewise.
2129 (end_symtab_get_static_block): Likewise.
2130 (end_symtab_from_static_block): Likewise.
2131 * buildsym-legacy.c (augment_type_symtab): Remove.
2132 (end_expandable_symtab): Remove.
2133 (end_symtab_get_static_block): Remove.
2134 (end_symtab_from_static_block): Remove.
2136 2018-07-20 Tom Tromey <tom@tromey.com>
2138 * dwarf2read.c: Include buildsym.h.
2139 (struct dwarf2_cu) <builder>: New method.
2140 (fixup_go_packaging): Update.
2141 (process_full_comp_unit, process_full_type_unit): Update. Don't
2142 use scoped_free_pendings.
2143 (using_directives): Add "cu" parameter, remove "language".
2144 (read_import_statement, setup_type_unit_groups, )
2145 (read_func_scope, read_lexical_block_scope)
2146 (dwarf2_record_block_ranges, read_namespace): Update.
2147 (lnp_state_machine::lnp_state_machine): Add cu parameter.
2148 (lnp_state_machine::handle_end_sequence): Update.
2149 (class lnp_state_machine) <m_cu>: New member.
2150 <m_record_line_callback>: Remove.
2151 <m_currently_recording_lines>: New member.
2152 (lnp_state_machine::handle_set_file): Update.
2153 (noop_record_line): Remove.
2154 (dwarf_record_line_p): Add cu parameter.
2155 (dwarf_record_line_1, dwarf_finish_line): Likewise.
2156 (lnp_state_machine::record_line)
2157 (lnp_state_machine::lnp_state_machine)
2158 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
2159 (dwarf_decode_lines): Update.
2160 (dwarf2_start_subfile): Add cu parameter.
2161 (dwarf2_start_symtab, new_symbol): Update.
2162 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
2163 Remove dwarf2_per_objfile parameter.
2164 (dwarf_decode_macros): Update.
2166 2018-07-20 Tom Tromey <tom@tromey.com>
2168 * stabsread.c (define_symbol): Update.
2169 * buildsym-legacy.h (get_buildsym_compunit): Declare.
2170 * dwarf2read.c (new_symbol): Update.
2171 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
2172 * cp-namespace.c: Include buildsym.h.
2173 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
2174 * buildsym-legacy.c (get_buildsym_compunit): New function.
2176 2018-07-20 Tom Tromey <tom@tromey.com>
2178 * xcoffread.c: Include buildsym-legacy.h.
2179 * windows-nat.c: Include buildsym-legacy.h.
2180 * stabsread.c: Include buildsym-legacy.h.
2181 * mdebugread.c: Include buildsym-legacy.h.
2182 * buildsym-legacy.h: New file.
2183 * buildsym-legacy.c: New file, from buildsym.c.
2184 * go32-nat.c: Include buildsym-legacy.h.
2185 * dwarf2read.c: Include buildsym-legacy.h.
2186 * dbxread.c: Include buildsym-legacy.h.
2187 * cp-namespace.c: Include buildsym-legacy.h.
2188 * coffread.c: Include buildsym-legacy.h.
2189 * buildsym.h: Move some contents to buildsym-legacy.h.
2190 * buildsym.c: Include buildsym-legacy.h. Move many functions to
2192 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
2194 2018-07-20 Tom Tromey <tom@tromey.com>
2196 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
2197 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
2198 (buildsym_compunit::buildsym_compunit)
2199 (buildsym_compunit::~buildsym_compunit)
2200 (buildsym_compunit::get_macro_table): Define.
2202 2018-07-20 Tom Tromey <tom@tromey.com>
2204 * buildsym.c (reset_symtab_globals): Remove.
2205 (buildsym_compunit::end_symtab_from_static_block): Update.
2206 (buildsym_compunit::augment_type_symtab): Update.
2207 (end_symtab_from_static_block): Call free_buildsym_compunit.
2208 (augment_type_symtab, end_symtab, end_expandable_symtab):
2211 2018-07-20 Tom Tromey <tom@tromey.com>
2213 * arch-utils.c: Do not include buildsym.h.
2214 * mipsread.c: Do not include buildsym.h.
2215 * machoread.c: Do not include buildsym.h.
2216 * elfread.c: Do not include buildsym.h.
2218 2018-07-20 Tom Tromey <tom@tromey.com>
2220 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
2222 (buildsym_compunit): Add new constructor.
2223 (struct buildsym_compunit) <get_last_source_file, finish_block,
2224 record_block_range, start_subfile, patch_subfile_names,
2225 push_subfile, pop_subfile, record_line, get_compunit_symtab,
2226 set_last_source_start_addr, get_last_source_start_addr,
2227 get_local_using_directives, set_local_using_directives,
2228 get_global_using_directives, outermost_context_p,
2229 get_current_context_stack, get_context_stack_depth,
2230 get_current_subfile, get_local_symbols, get_file_symbols,
2231 get_global_symbols, record_debugformat, record_producer,
2232 push_context, pop_context, end_symtab_get_static_block,
2233 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
2235 <record_pending_block, finish_block_internal, make_blockvector,
2236 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
2240 2018-05-22 Tom Tromey <tom@tromey.com>
2242 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2244 (finish_block_internal): Update.
2246 2018-07-20 Tom Tromey <tom@tromey.com>
2248 * buildsym.c (record_pending_block): Move earlier. Remove objfile
2250 (finish_block_internal): Update.
2252 2018-07-20 Tom Tromey <tom@tromey.com>
2254 * buildsym.h (EXTERN): Don't define or undef.
2255 * buildsym.c (EXTERN): Don't define.
2257 2018-07-20 Tom Tromey <tom@tromey.com>
2259 * buildsym.c: Remove TODO comment.
2261 2018-07-20 Tom Tromey <tom@tromey.com>
2263 * coffread.c (coff_symtab_read): Update.
2264 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
2265 (xcoff_new_init): Update.
2266 * mipsread.c (mipscoff_new_init): Update.
2267 * mdebugread.c (mdebug_build_psymtabs): Update.
2268 * elfread.c (elf_new_init): Update.
2269 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2271 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
2272 (coffstab_build_psymtabs, elfstab_build_psymtabs)
2273 (stabsect_build_psymtabs): Update.
2274 * buildsym.h (buildsym_init): Don't declare.
2275 * buildsym.c: Update comment.
2276 (prepare_for_building): Remove.
2277 (start_symtab, restart_symtab): Update.
2278 (reset_symtab_globals): Update comment.
2279 (buildsym_init): Remove.
2281 2018-07-20 Tom Tromey <tom@tromey.com>
2283 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
2284 * stabsread.c (patch_block_stabs, define_symbol, read_type)
2285 (read_enum_type, common_block_start, common_block_end)
2286 (cleanup_undefined_types_1, finish_global_stabs): Update.
2287 * mdebugread.c (psymtab_to_symtab_1): Update.
2288 * dwarf2read.c (fixup_go_packaging, read_func_scope)
2289 (read_lexical_block_scope, new_symbol): Update.
2290 * dbxread.c (process_one_symbol): Update.
2291 * coffread.c (coff_symtab_read, process_coff_symbol)
2292 (coff_read_enum_type): Update.
2293 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
2295 (get_local_symbols, get_file_symbols, get_global_symbols): New
2297 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
2299 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
2300 (~scoped_free_pendings): Update.
2301 (finish_block, prepare_for_building, reset_symtab_globals)
2302 (end_symtab_get_static_block, end_symtab_with_blockvector)
2303 (augment_type_symtab, push_context): Update.
2304 (get_local_symbols, get_file_symbols, get_global_symbols): New
2306 (buildsym_init): Update.
2308 2018-07-20 Tom Tromey <tom@tromey.com>
2310 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
2311 (process_full_type_unit): Likewise.
2312 (dwarf2_start_symtab): Set list_in_scope.
2314 2018-07-20 Tom Tromey <tom@tromey.com>
2316 * dwarf2read.c (process_psymtab_comp_unit_reader)
2317 (build_type_psymtabs_reader): Do not set list_in_scope.
2319 2018-07-20 Tom Tromey <tom@tromey.com>
2321 * buildsym.c (free_pendings): Remove.
2322 (add_symbol_to_list, scoped_free_pendings)
2323 (finish_block_internal, buildsym_init): Update.
2325 2018-07-20 Tom Tromey <tom@tromey.com>
2327 * xcoffread.c (read_xcoff_symtab): Update.
2328 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
2330 * dbxread.c (process_one_symbol): Update.
2331 * coffread.c (coff_symtab_read): Update.
2332 * buildsym.h (finish_block): Update.
2333 * buildsym.c (finish_block): Remove "listhead" argument.
2334 (end_symtab_get_static_block): Update.
2336 2018-07-20 Tom Tromey <tom@tromey.com>
2338 * buildsym.h (class scoped_free_pendings): Remove constructor.
2339 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
2341 <m_pending_block_obstack, m_pending_blocks>: New members.
2342 (pending_block_obstack, pending_blocks): Remove.
2343 (scoped_free_pendings::scoped_free_pendings): Default.
2344 (~scoped_free_pendings): Update.
2345 (free_pending_blocks): Remove.
2346 (finish_block_internal, record_pending_block, make_blockvector)
2347 (end_symtab_get_static_block, augment_type_symtab, push_context)
2348 (buildsym_init): Update.
2350 2018-07-20 Tom Tromey <tom@tromey.com>
2352 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
2353 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
2355 (pending_addrmap, pending_addrmap_obstack)
2356 (pending_addrmap_interesting): Remove.
2357 (scoped_free_pendings, record_block_range, make_blockvector)
2358 (prepare_for_building, reset_symtab_globals, buildsym_init):
2361 2018-07-20 Tom Tromey <tom@tromey.com>
2363 * xcoffread.c (process_linenos): Update.
2364 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
2365 * mdebugread.c (psymtab_to_symtab_1): Update.
2366 * dwarf2read.c (setup_type_unit_groups)
2367 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
2368 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
2369 * dbxread.c (process_one_symbol): Update.
2370 * coffread.c (coff_symtab_read, enter_linenos)
2371 (process_coff_symbol): Update.
2372 * buildsym.h (current_subfile): Don't declare.
2373 (get_current_subfile): Declare.
2374 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
2376 (start_subfile, free_buildsym_compunit, push_subfile)
2377 (prepare_for_building, start_symtab): Update.
2378 (get_current_subfile): New function.
2380 2018-07-20 Tom Tromey <tom@tromey.com>
2382 * coffread.c (coff_symtab_read): Update.
2383 * xcoffread.c (read_xcoff_symtab): Update.
2384 * dwarf2read.c (new_symbol): Update.
2385 (read_func_scope, read_lexical_block_scope): Update.
2386 * dbxread.c (process_one_symbol): Update.
2387 * buildsym.h (context_stack, context_stack_depth): Don't declare.
2388 (outermost_context_p): Remove macro.
2389 (outermost_context_p, get_current_context_stack)
2390 (get_context_stack_depth): Declare.
2391 (pop_context): Return struct context_stack.
2392 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
2394 (context_stack_size): Remove.
2395 (INITIAL_CONTEXT_STACK_SIZE): Remove.
2396 (prepare_for_building, end_symtab_get_static_block)
2397 (augment_type_symtab, push_context): Update.
2398 (pop_context): Return struct context_stack.
2399 (outermost_context_p, get_current_context_stack)
2400 (get_context_stack_depth): New functions.
2401 (buildsym_init): Update.
2403 2018-07-20 Tom Tromey <tom@tromey.com>
2405 * rust-exp.y: Now a pure parser. Update all rules.
2406 (%union): Move earlier.
2407 (current_parser, work_obstack): Remove globals.
2408 (rust_parser, ~rust_parser): Update.
2409 (class rust_parser) <copy_name, concat3, crate_name, super_name,
2410 lex_character, lex_number, lex_string, lex_identifier,
2411 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
2412 convert_name, convert_params_to_expression,
2413 convert_ast_to_expression, ast_basic_type, ast_operation,
2414 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
2415 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
2416 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
2417 ast_array_type, ast_slice_type, ast_reference_type,
2418 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
2419 (rust_parse): Update.
2420 (rustyyerror, rustyylex): Add parser parameter.
2421 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
2422 (rust_lex_stringish_test, rust_lex_test_sequence)
2423 (rust_lex_test_trailing_dot, rust_lex_test_completion)
2424 (rust_lex_test_push_back, rust_lex_tests): Update.
2426 2018-07-19 Pedro Alves <palves@redhat.com>
2428 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
2429 gdb::unique_xmalloc_ptr.
2430 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
2431 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
2432 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
2433 copy-initialization.
2434 * guile/scm-pretty-print.c (ppscm_print_children): Use
2435 gdb::unique_xmalloc_ptr instead of cleanups.
2436 (gdbscm_apply_val_pretty_printer): Remove cleanups.
2437 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
2438 gdb::unique_xmalloc_ptr.
2439 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
2440 Adjust to use gdb::unique_xmalloc_ptr.
2441 * guile/scm-utils.c (extract_arg): Adjust.
2442 * guile/scm-value.c (gdbscm_value_field): Adjust to use
2443 gdb::unique_xmalloc_ptr instead of a cleanup.
2445 2018-07-19 Tom Tromey <tom@tromey.com>
2447 * utils.c (do_value_free_to_mark)
2448 (make_cleanup_value_free_to_mark): Remove.
2449 * utils.h (make_cleanup_value_free_to_mark): Remove.
2451 2018-07-19 Pedro Alves <palves@redhat.com>
2453 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
2454 forwarding reference.
2456 2018-07-18 Pedro Alves <palves@redhat.com>
2458 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
2459 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
2462 2018-07-18 Pedro Alves <palves@redhat.com>
2464 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
2466 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
2468 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
2469 directly instead of a cleanup.
2470 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
2471 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
2472 (vlscm_binop_gdbthrow): New, factored out from ...
2473 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
2474 (vlscm_rich_compare): Use gdbscm_wrap.
2475 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
2476 instead of a cleanup.
2477 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
2479 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
2480 Use xfree directly instead of a cleanup.
2481 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
2482 Adjust to use gdbscm_wrap and scoped_value_mark.
2483 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
2484 (gdbscm_value_address, gdbscm_value_dereference)
2485 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
2487 (gdbscm_value_dynamic_type): Use scoped_value_mark.
2488 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
2490 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
2491 gdbscm_wrap and scoped_value_mark.
2492 (gdbscm_value_to_string): Use xfree directly instead of a
2493 cleanup. Move 'buffer' unique_ptr to TRY scope.
2494 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
2495 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
2497 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
2498 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
2500 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
2503 2018-07-18 Tom de Vries <tdevries@suse.de>
2505 * findvar.c (default_read_var_value): Also resolve dynamic type for
2506 LOC_OPTIMIZED_OUT vars.
2508 2018-07-18 Maciej W. Rozycki <macro@mips.com>
2510 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
2513 2018-07-17 Tom Tromey <tom@tromey.com>
2515 * guile/scm-param.c (pascm_set_func, pascm_show_func)
2516 (compute_enum_list, pascm_set_param_value_x)
2517 (gdbscm_parameter_value): Update.
2518 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
2519 (gdbscm_scm_to_host_string): Update.
2520 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
2522 * guile/scm-cmd.c (cmdscm_add_completion): Update.
2523 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
2524 * guile/scm-string.c (gdbscm_scm_to_string): Return
2526 (gdbscm_scm_to_host_string): Likewise.
2528 2018-07-17 Tom Tromey <tom@tromey.com>
2530 * guile/guile.c (gdbscm_eval_from_control_command): Update.
2531 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
2532 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
2533 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
2536 2018-07-17 Tom Tromey <tom@tromey.com>
2538 * guile/scm-param.c (pascm_signal_setshow_error): Update.
2539 * guile/guile-internal.h (gdbscm_exception_message_to_string):
2541 * guile/scm-cmd.c (cmdscm_function): Update.
2542 * guile/scm-pretty-print.c
2543 (ppscm_print_exception_unless_memory_error): Update.
2544 * guile/scm-exception.c (gdbscm_exception_message_to_string):
2545 Return unique_xmalloc_ptr.
2547 2018-07-17 Tom Tromey <tom@tromey.com>
2549 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
2552 2018-07-17 Jim Wilson <jimw@sifive.com>
2554 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
2555 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
2556 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
2557 unecessary braces after EF_RISCV_RVC test. Delete call to
2558 set_gdbarch_decr_pc_after_break.
2560 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
2561 RISCV_LAST_FP_REGNUM + 1.
2562 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
2564 2018-07-17 Tom Tromey <tom@tromey.com>
2566 * configure.ac: Remove --disable-gdbcli.
2567 * configure: Rebuild.
2568 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
2569 (SUBDIR_CLI_CFLAGS): Remove.
2570 (SFILES): Use SUBDIR_CLI_SRCS.
2571 (COMMON_OBS): Use SUBDIR_CLI_OBS.
2573 2018-07-17 Tom Tromey <tom@tromey.com>
2576 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
2578 2018-07-16 Jim Wilson <jimw@sifive.com>
2580 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
2582 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
2584 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
2586 (libunwind_frame_sniffer): Likewise.
2587 (libunwind_frame_prev_register): Likewise.
2588 (libunwind_sigtramp_frame_sniffer): Likewise.
2589 * ia64-tdep.c (ia64_access_reg): Likewise.
2590 (ia64_access_rse_reg): Likewise.
2591 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
2592 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
2594 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
2596 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
2598 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
2600 * remote-sim.c (gdbsim_target::close,
2601 gdbsim_target::mourn_inferior): Remove unused variables.
2603 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
2605 * ia64-tdep.c (ktab_buf): New global.
2606 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
2607 (get_kernel_table): Adjust.
2609 2018-07-16 Tom Tromey <tom@tromey.com>
2611 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
2612 * dwarf2read.c (using_directives, new_symbol): Use
2613 outermost_context_p.
2614 * dbxread.c (process_one_symbol): Use outermost_context_p.
2615 * coffread.c (coff_symtab_read): Use outermost_context_p.
2617 2018-07-16 Tom Tromey <tom@tromey.com>
2619 * dwarf2read.c (using_directives, read_func_scope)
2620 (read_lexical_block_scope): Update.
2621 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
2622 * buildsym.h (local_using_directives, global_using_directives):
2624 (get_local_using_directives, set_local_using_directives)
2625 (get_global_using_directives): Declare.
2626 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
2627 m_global_using_directives>: New members.
2628 (finish_block_internal, prepare_for_building)
2629 (reset_symtab_globals, end_symtab_get_static_block)
2630 (push_context): Update.
2631 (get_local_using_directives, set_local_using_directives)
2632 (get_global_using_directives): New functions.
2633 (buildsym_init): Update.
2635 2018-07-16 Tom Tromey <tom@tromey.com>
2637 * xcoffread.c (xcoff_initial_scan): Don't call
2638 free_pending_blocks.
2639 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
2640 * buildsym.h (class scoped_free_pendings): Add constructor.
2641 (free_pending_blocks): Don't declare.
2642 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
2643 (free_pending_blocks): Now static.
2645 2018-07-16 Tom Tromey <tom@tromey.com>
2647 * buildsym.h (push_subfile, pop_subfile): Update declarations.
2648 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
2650 (struct subfile_stack): Remove.
2651 (subfile_stack): Remove.
2652 (push_subfile, pop_subfile, buildsym_init): Update.
2654 2018-07-16 Tom Tromey <tom@tromey.com>
2656 * buildsym.c (push_subfile): Use gdb_assert.
2657 (pop_subfile): Use gdb_assert.
2659 2018-07-16 Tom Tromey <tom@tromey.com>
2661 * buildsym.h (merge_symbol_lists): Remove.
2662 * buildsym.c (merge_symbol_lists): Remove.
2664 2018-07-16 Tom Tromey <tom@tromey.com>
2666 * stabsread.c (scan_file_globals): Update comment.
2667 * stabsread.h (scan_file_globals): Move from buildsym.h.
2668 * buildsym.h (scan_file_globals): Move to stabsread.h.
2670 2018-07-16 Tom Tromey <tom@tromey.com>
2672 * xcoffread.c (xcoff_new_init): Update.
2673 * mipsread.c (mipscoff_new_init): Update.
2674 * mdebugread.c (mdebug_build_psymtabs): Update.
2675 * elfread.c (elf_new_init): Update.
2676 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
2677 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
2678 * buildsym.h (buildsym_new_init): Don't declare.
2679 * buildsym.c (buildsym_new_init): Remove.
2681 2018-07-16 Tom Tromey <tom@tromey.com>
2683 * stabsread.h (within_function): Move from buildsym.h.
2684 * stabsread.c (start_stabs): Clear within_function.
2685 * coffread.c (coff_start_symtab): Clear within_function.
2686 * buildsym.h (within_function): Move to stabsread.h.
2687 * buildsym.c (prepare_for_building): Update.
2689 2018-07-16 Tom Tromey <tom@tromey.com>
2691 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
2692 * dwarf2read.c (dwarf2_start_symtab): Don't set
2693 processing_gcc_compilation.
2694 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
2696 2018-07-16 Tom Tromey <tom@tromey.com>
2698 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
2699 (next_symbol_text_func): Move from buildsym.h.
2700 * stabsread.c (hashname): Move from buildsym.c.
2701 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
2702 (next_symbol_text_func, hashname): Move to stabsread.h.
2703 * buildsym.c: Don't include bcache.h
2704 (hashname): Move to stasbread.c.
2706 2018-07-16 Tom Tromey <tom@tromey.com>
2708 * buildsym.h (context_stack_size): Don't declare.
2709 * buildsym.c (context_stack_size): New global.
2711 2018-07-16 Tom Tromey <tom@tromey.com>
2713 * dbxread.c (processing_acc_compilation): New global.
2714 * buildsym.h (processing_acc_compilation): Don't declare.
2716 2018-07-16 Tom Tromey <tom@tromey.com>
2718 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
2719 * dbxread.c (read_ofile_symtab): Update.
2720 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
2721 * buildsym.h (last_source_start_addr): Remove.
2722 (set_last_source_start_addr, get_last_source_start_addr):
2724 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
2726 (struct buildsym_compunit) <m_last_source_start_addr>: New
2728 (prepare_for_building): Remove start_addr parameter.
2729 (start_symtab, restart_symtab, end_symtab_get_static_block)
2730 (end_symtab_with_blockvector): Update.
2731 (set_last_source_start_addr, get_last_source_start_addr): New
2734 2018-07-16 Tom Tromey <tom@tromey.com>
2736 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
2738 (have_line_numbers): Remove.
2739 (record_line, prepare_for_building, end_symtab_get_static_block)
2740 (augment_type_symtab): Update.
2742 2018-07-16 Tom Tromey <tom@tromey.com>
2744 * buildsym.c (~buildsym_compunit): Free the macro table.
2745 (struct buildsym_compunit) <get_macro_table, release_macros>: New
2747 <m_pending_macros>: New member.
2748 (pending_macros): Remove.
2749 (~scoped_free_pendings, get_macro_table, prepare_for_building)
2750 (reset_symtab_globals, end_symtab_get_static_block)
2751 (end_symtab_with_blockvector, augment_type_symtab)
2752 (buildsym_init): Update.
2754 2018-07-16 Tom Tromey <tom@tromey.com>
2756 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
2758 (buildsym_compunit::set_last_source_file): New method.
2759 <m_last_source_file>: New member.
2760 (prepare_for_building): Remove "name" parameter.
2761 (start_symtab, restart_symtab, reset_symtab_globals): Update.
2762 (last_source_file): Remove.
2763 (set_last_source_file, get_last_source_file): Update.
2765 2018-07-16 Tom Tromey <tom@tromey.com>
2767 * buildsym.c (prepare_for_building): Add assert.
2769 2018-07-16 Tom Tromey <tom@tromey.com>
2771 * buildsym.c (~buildsym_compunit): Update.
2772 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
2773 (start_subfile, patch_subfile_names)
2774 (end_symtab_with_blockvector): Update.
2776 2018-07-16 Tom Tromey <tom@tromey.com>
2778 * buildsym.c (struct buildsym_compunit): Add constructor,
2779 destructor, initializers.
2780 (start_buildsym_compunit): Remove.
2781 (free_buildsym_compunit): Use "delete".
2782 (start_symtab, restart_symtab): Use "new".
2784 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
2786 * symfile.c (set_objfile_default_section_offset): Remove struct
2789 2018-07-14 Stafford Horne <shorne@gmail.com>
2791 * (Responsible Maintainers): Add myself as or1k maintainer.
2793 2018-07-13 Tom Tromey <tom@tromey.com>
2795 * symfile.c (set_objfile_default_section_offset): Use extra braces
2798 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
2800 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
2803 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2805 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2806 unittests/cli-utils-selftests.c
2807 * unittests/cli-utils-selftests.c: New file.
2809 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2811 * NEWS: Mention new commands. Mention change to 'thread apply'.
2813 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2815 * thread.c (thr_try_catch_cmd): New function.
2816 (thread_apply_all_command): Handle qcs flags.
2817 (thread_apply_command): Handle qcs flags.
2818 (taas_command): New function.
2819 (tfaas_command): New function.
2820 (_initialize_thread): Update to setup the new commands 'taas
2821 and 'tfaas'. Change doc string for 'thread apply'.
2823 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2825 * stack.c: (trailing_outermost_frame): New function, mostly
2826 extracted from backtrace_command_1.
2827 (leading_innermost_frame): New function.
2828 (backtrace_command_1): Update to call trailing_outermost_frame.
2829 (frame_apply_command_count): New function.
2830 (frame_apply_level_command): New function.
2831 (frame_apply_all_command): New function.
2832 (frame_apply_command): New function.
2833 (faas_command): New function.
2834 (frame_cmd_list): New variable.
2835 (_initialize_stack): Update to setup the new commands 'frame apply'
2838 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2840 * cli-utils.c (number_or_range_parser::get_number): Only handle
2841 numbers or convenience var as numbers.
2842 (parse_flags): New function.
2843 (parse_flags_qcs): New function.
2844 (number_or_range_parser::finished): Ensure parsing end is detected
2845 before end of string.
2846 * cli-utils.h (parse_flags): New function.
2847 (parse_flags_qcs): New function.
2848 (number_or_range_parser): Remove m_finished bool.
2849 (number_or_range_parser::skip_range): Set m_in_range to false.
2851 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
2853 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
2856 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2857 Jan Kratochvil <jan.kratochvil@redhat.com>
2858 Paul Fertser <fercerpav@gmail.com>
2859 Tsutomu Seki <sekiriki@gmail.com>
2860 Pedro Alves <palves@redhat.com>
2862 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2863 'unittests/parse-connection-spec-selftests.c'.
2864 (COMMON_SFILES): Add 'common/netstuff.c'.
2865 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
2866 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
2867 * common/netstuff.c: New file.
2868 * common/netstuff.h: New file.
2869 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
2870 (wait_for_connect): Update comment. New parameter
2871 'gdb::optional<int> sock' instead of 'struct serial *scb'.
2872 Use 'sock' directly instead of 'scb->fd'.
2873 (try_connect): New function, with code from 'net_open'.
2874 (net_open): Rewrite main loop to deal with multiple
2875 sockets/addresses. Handle IPv6-style hostnames; implement
2876 support for IPv6 connections.
2877 * unittests/parse-connection-spec-selftests.c: New file.
2879 2018-07-11 Pedro Alves <palves@redhat.com>
2882 * remote.c (remote_target::remote_detach_pid): Call
2883 set_current_process.
2885 2018-07-11 Pedro Alves <palves@redhat.com>
2887 * h8300-tdep.c (h8300_gdbarch_init): Remove
2888 set_gdbarch_ecoff_reg_to_regnum calls.
2890 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
2893 * c-typeprint.c (c_type_print_base_struct_union): Don't print
2894 offsets/sizes for static members of a class/struct.
2896 2018-07-11 Alan Hayward <alan.hayward@arm.com>
2898 * target-descriptions.c (tdesc_register_bitsize): Rename.
2899 * target-descriptions.h (tdesc_register_bitsize): Likewise.
2900 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
2901 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
2903 2018-07-10 Tom Tromey <tom@tromey.com>
2905 * breakpoint.c (moribund_locations): Now static and a
2907 (breakpoint_init_inferior, moribund_breakpoint_here_p)
2908 (build_bpstat_chain, update_global_location_list)
2909 (breakpoint_retire_moribund): Update.
2910 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
2913 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2915 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
2916 (riscv_register_reggroup_p): Use new function, remove unneeded
2918 (riscv_push_dummy_call): Extend assert to compare against xlen or
2919 flen based on register type.
2921 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
2923 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
2925 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
2927 * remote.c (show_hardware_watchpoint_limit): New function.
2928 (show_hardware_watchpoint_length_limit): New function.
2929 (show_hardware_breakpoint_limit): New function.
2930 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
2931 where appropriate, update help text.
2933 2018-07-09 Tom Tromey <tom@tromey.com>
2935 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
2936 (CLIBS): Don't mention NAT_CLIBS.
2938 2018-07-09 Tom Tromey <tom@tromey.com>
2940 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
2941 (LIBGDB_OBS, clean mostlyclean): Update.
2942 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
2944 2018-07-09 Tom Tromey <tom@tromey.com>
2946 * Makefile.in (%.c: %.y): Use ECHO_YACC.
2947 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
2948 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
2950 2018-07-09 Tom Tromey <tom@tromey.com>
2952 * Makefile.in (ALLDEPFILES): Remove exec.c.
2953 (COMMON_OBS): Remove exec.o.
2954 (COMMON_SFILES): Add exec.c.
2956 2018-07-09 Tom Tromey <tom@tromey.com>
2958 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
2960 2018-07-09 Tom Tromey <tom@tromey.com>
2962 * Makefile.in (clean mostlyclean): Remove stamp-version.
2963 (version.c): Depend on stamp-version.
2964 (stamp-version): New rule, from version.c rule.
2966 2018-07-09 Tom Tromey <tom@tromey.com>
2968 * Makefile.in (init.c): Depend on stamp-init.
2969 (stamp-init): New rule, from init.c rule.
2970 (clean mostlyclean): Remove stamp-init.
2972 2018-07-09 Tom Tromey <tom@tromey.com>
2974 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
2975 SUBDIR_GCC_COMPILE_SRCS.
2977 2018-07-09 Tom Tromey <tom@tromey.com>
2979 * Makefile.in (init.c): Remove some unused sed rules.
2981 2018-07-09 Tom Tromey <tom@tromey.com>
2983 * Makefile.in (TSOBS): Remove.
2984 (INIT_FILES): Update.
2985 (LIBGDB_OBS): Update.
2986 (COMMON_SFILES): Add inflow.c.
2987 (SFILES): Remove inflow.c.
2989 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
2991 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
2993 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
2995 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
2996 get_saveloc_name, is_signal_frame_name, step_name,
2997 init_remote_name, create_addr_space_name,
2998 destroy_addr_space_name, search_unwind_table_name,
2999 find_dyn_list_name): Constify.
3001 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3003 * darwin-nat.c (darwin_pthread_kill): New function.
3004 (darwin_resume_thread): Use darwin_pthread_kill.
3006 2018-07-05 Tom de Vries <tdevries@suse.de>
3008 * macroexp.c (macro_buffer) <operator=>: New member function.
3010 2018-07-04 Tom Tromey <tom@tromey.com>
3012 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3014 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3016 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3017 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3018 * maint.c: Likewise.
3021 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3023 * NEWS: Create a new section for the next release branch.
3024 Rename the section of the current branch, now that it has
3027 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3029 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3030 * version.in: Bump version to 8.2.50.DATE-git.
3032 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3033 Pedro Alves <palves@redhat.com>
3035 * linux-nat.c (linux_init_ptrace): Rename to ...
3036 (linux_init_ptrace_procfs): ... this. Call
3037 linux_proc_init_warnings.
3038 (linux_nat_target::post_attach)
3039 (linux_nat_target::post_startup_inferior): Adjust.
3040 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3041 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3043 2018-07-04 Tom de Vries <tdevries@suse.de>
3045 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3047 (read_comp_unit_head): ... here.
3049 2018-07-03 Tom Tromey <tom@tromey.com>
3051 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3052 (stop_tracing, tstatus_command)
3053 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3054 (print_one_static_tracepoint_marker): Update.
3055 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3057 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3059 (all_tracepoints, static_tracepoints_here): Return std::vector.
3061 2018-07-03 Tom Tromey <tom@tromey.com>
3063 * common/ptid.c (ptid_equal): Remove.
3064 * common/ptid.h (ptid_equal): Don't declare.
3065 * ada-tasks.c: Update.
3066 * breakpoint.c: Update.
3067 * common/agent.c: Update.
3068 * corelow.c: Update.
3069 * darwin-nat-info.c: Update.
3070 * darwin-nat.c: Update.
3072 * dtrace-probe.c: Update.
3073 * dummy-frame.c: Update.
3074 * fbsd-nat.c: Update.
3076 * gdbthread.h: Update.
3077 * gnu-nat.c: Update.
3078 * go32-nat.c: Update.
3079 * inf-loop.c: Update.
3080 * inf-ptrace.c: Update.
3081 * infcall.c: Update.
3085 * linux-fork.c: Update.
3086 * linux-nat.c: Update.
3087 * linux-thread-db.c: Update.
3088 * mi/mi-cmd-var.c: Update.
3089 * mi/mi-interp.c: Update.
3090 * mi/mi-main.c: Update.
3091 * nto-procfs.c: Update.
3092 * ppc-linux-tdep.c: Update.
3094 * python/py-inferior.c: Update.
3095 * python/py-record-btrace.c: Update.
3096 * python/py-record.c: Update.
3097 * ravenscar-thread.c: Update.
3098 * regcache.c: Update.
3099 * remote-sim.c: Update.
3101 * sol-thread.c: Update.
3104 * tui/tui-stack.c: Update.
3106 * windows-nat.c: Update.
3107 * windows-tdep.c: Update.
3109 2018-07-03 Tom Tromey <tom@tromey.com>
3111 * common/ptid.c (ptid_match): Remove.
3112 * common/ptid.h (ptid_match): Don't declare.
3113 * fbsd-nat.c: Update.
3116 * linux-nat.c: Update.
3117 * record-btrace.c: Update.
3118 * regcache.c: Update.
3121 2018-07-03 Tom Tromey <tom@tromey.com>
3123 * common/ptid.c (ptid_tid_p): Remove.
3124 * common/ptid.h (ptid_tid_p): Don't declare.
3125 * sol-thread.c: Update.
3127 2018-07-03 Tom Tromey <tom@tromey.com>
3129 * common/ptid.c (ptid_lwp_p): Remove.
3130 * common/ptid.h (ptid_lwp_p): Don't declare.
3131 * fbsd-nat.c: Update.
3132 * linux-nat.c: Update.
3133 * nat/linux-procfs.c: Update.
3134 * nat/x86-linux-dregs.c: Update.
3135 * sol-thread.c: Update.
3137 2018-07-03 Tom Tromey <tom@tromey.com>
3139 * common/ptid.c (ptid_is_pid): Remove.
3140 * common/ptid.h (ptid_is_pid): Don't declare.
3142 * linux-nat.c: Update.
3143 * mi/mi-interp.c: Update.
3147 2018-07-03 Tom Tromey <tom@tromey.com>
3149 * common/ptid.c (ptid_get_tid): Remove.
3150 * common/ptid.h (ptid_get_tid): Don't declare.
3151 * ada-tasks.c: Update.
3152 * aix-thread.c: Update.
3153 * bsd-uthread.c: Update.
3154 * darwin-nat.c: Update.
3155 * fbsd-nat.c: Update.
3156 * i386-darwin-nat.c: Update.
3158 * linux-tdep.c: Update.
3159 * nto-procfs.c: Update.
3160 * ppc-ravenscar-thread.c: Update.
3161 * python/py-infthread.c: Update.
3162 * ravenscar-thread.c: Update.
3163 * sol-thread.c: Update.
3164 * sparc-ravenscar-thread.c: Update.
3165 * windows-nat.c: Update.
3167 2018-07-03 Tom Tromey <tom@tromey.com>
3169 * common/ptid.c (ptid_get_lwp): Remove.
3170 * common/ptid.h (ptid_get_lwp): Don't declare.
3171 * aarch64-linux-nat.c: Update.
3172 * ada-tasks.c: Update.
3173 * aix-thread.c: Update.
3174 * amd64-linux-nat.c: Update.
3175 * arm-linux-nat.c: Update.
3176 * corelow.c: Update.
3177 * fbsd-nat.c: Update.
3178 * fbsd-tdep.c: Update.
3179 * gnu-nat.c: Update.
3180 * i386-cygwin-tdep.c: Update.
3181 * i386-gnu-nat.c: Update.
3182 * i386-linux-nat.c: Update.
3183 * ia64-linux-nat.c: Update.
3184 * inf-ptrace.c: Update.
3186 * linux-fork.c: Update.
3187 * linux-nat.c: Update.
3188 * linux-tdep.c: Update.
3189 * linux-thread-db.c: Update.
3190 * mips-linux-nat.c: Update.
3191 * nat/aarch64-linux-hw-point.c: Update.
3192 * nat/aarch64-linux.c: Update.
3193 * nat/linux-btrace.c: Update.
3194 * nat/linux-osdata.c: Update.
3195 * nat/linux-procfs.c: Update.
3196 * nat/x86-linux-dregs.c: Update.
3197 * obsd-nat.c: Update.
3198 * ppc-fbsd-nat.c: Update.
3199 * ppc-linux-nat.c: Update.
3201 * python/py-infthread.c: Update.
3202 * ravenscar-thread.c: Update.
3204 * s390-linux-nat.c: Update.
3205 * sol-thread.c: Update.
3206 * sol2-tdep.c: Update.
3207 * spu-linux-nat.c: Update.
3208 * x86-linux-nat.c: Update.
3209 * xtensa-linux-nat.c: Update.
3211 2018-07-03 Tom Tromey <tom@tromey.com>
3213 * common/ptid.c (ptid_get_pid): Remove.
3214 * common/ptid.h (ptid_get_pid): Don't declare.
3215 * aarch64-linux-nat.c: Update.
3216 * ada-lang.c: Update.
3217 * aix-thread.c: Update.
3218 * alpha-bsd-nat.c: Update.
3219 * amd64-fbsd-nat.c: Update.
3220 * amd64-linux-nat.c: Update.
3221 * arm-linux-nat.c: Update.
3222 * arm-nbsd-nat.c: Update.
3224 * break-catch-syscall.c: Update.
3225 * breakpoint.c: Update.
3226 * bsd-uthread.c: Update.
3227 * corelow.c: Update.
3229 * darwin-nat.c: Update.
3230 * fbsd-nat.c: Update.
3231 * fbsd-tdep.c: Update.
3233 * gnu-nat.c: Update.
3234 * hppa-nbsd-nat.c: Update.
3235 * hppa-obsd-nat.c: Update.
3236 * i386-fbsd-nat.c: Update.
3237 * ia64-linux-nat.c: Update.
3238 * inf-ptrace.c: Update.
3240 * inferior.c: Update.
3241 * inferior.h: Update.
3244 * linux-fork.c: Update.
3245 * linux-nat.c: Update.
3246 * linux-tdep.c: Update.
3247 * linux-thread-db.c: Update.
3248 * m68k-bsd-nat.c: Update.
3249 * mi/mi-interp.c: Update.
3250 * mi/mi-main.c: Update.
3251 * mips-linux-nat.c: Update.
3252 * mips-nbsd-nat.c: Update.
3253 * mips64-obsd-nat.c: Update.
3254 * nat/aarch64-linux-hw-point.c: Update.
3255 * nat/aarch64-linux.c: Update.
3256 * nat/linux-btrace.c: Update.
3257 * nat/linux-osdata.c: Update.
3258 * nat/linux-procfs.c: Update.
3259 * nat/x86-linux-dregs.c: Update.
3260 * nto-procfs.c: Update.
3261 * obsd-nat.c: Update.
3262 * ppc-linux-nat.c: Update.
3263 * ppc-nbsd-nat.c: Update.
3264 * ppc-obsd-nat.c: Update.
3265 * proc-service.c: Update.
3267 * python/py-inferior.c: Update.
3268 * python/py-infthread.c: Update.
3269 * ravenscar-thread.c: Update.
3271 * remote-sim.c: Update.
3273 * rs6000-nat.c: Update.
3274 * s390-linux-nat.c: Update.
3275 * sh-nbsd-nat.c: Update.
3276 * sol-thread.c: Update.
3277 * sparc-nat.c: Update.
3278 * sparc64-tdep.c: Update.
3279 * spu-linux-nat.c: Update.
3280 * spu-tdep.c: Update.
3281 * target-debug.h: Update.
3284 * tid-parse.c: Update.
3285 * tracefile-tfile.c: Update.
3286 * vax-bsd-nat.c: Update.
3287 * windows-nat.c: Update.
3288 * x86-linux-nat.c: Update.
3289 * x86-nat.c: Update.
3291 2018-07-03 Tom Tromey <tom@tromey.com>
3293 * common/ptid.c (pid_to_ptid): Remove.
3294 * common/ptid.h (pid_to_ptid): Don't declare.
3295 * aix-thread.c: Update.
3296 * arm-linux-nat.c: Update.
3297 * common/ptid.c: Update.
3298 * common/ptid.h: Update.
3299 * corelow.c: Update.
3301 * darwin-nat.c: Update.
3302 * fbsd-nat.c: Update.
3303 * fork-child.c: Update.
3304 * gnu-nat.c: Update.
3305 * go32-nat.c: Update.
3306 * inf-ptrace.c: Update.
3308 * inferior.c: Update.
3310 * linux-fork.c: Update.
3311 * linux-nat.c: Update.
3312 * nat/aarch64-linux-hw-point.c: Update.
3313 * nat/fork-inferior.c: Update.
3314 * nat/x86-linux-dregs.c: Update.
3315 * nto-procfs.c: Update.
3316 * obsd-nat.c: Update.
3318 * progspace.c: Update.
3320 * rs6000-nat.c: Update.
3321 * s390-linux-nat.c: Update.
3322 * sol-thread.c: Update.
3323 * spu-linux-nat.c: Update.
3326 * tracefile-tfile.c: Update.
3327 * windows-nat.c: Update.
3329 2018-07-03 Tom Tromey <tom@tromey.com>
3331 * common/ptid.h (ptid_build): Don't declare.
3332 * common/ptid.c (ptid_build): Remove.
3333 * aix-thread.c: Update.
3334 * bsd-kvm.c: Update.
3335 * bsd-uthread.c: Update.
3336 * common/agent.c: Update.
3337 * common/ptid.c: Update.
3338 * common/ptid.h: Update.
3339 * corelow.c: Update.
3340 * darwin-nat.c: Update.
3341 * fbsd-nat.c: Update.
3342 * gnu-nat.c: Update.
3343 * linux-fork.c: Update.
3344 * linux-nat.c: Update.
3345 * linux-thread-db.c: Update.
3346 * nat/linux-osdata.c: Update.
3347 * nat/linux-procfs.c: Update.
3348 * nto-procfs.c: Update.
3349 * obsd-nat.c: Update.
3350 * proc-service.c: Update.
3352 * ravenscar-thread.c: Update.
3353 * remote-sim.c: Update.
3355 * sol-thread.c: Update.
3357 * windows-nat.c: Update.
3359 2018-07-03 Tom Tromey <tom@tromey.com>
3361 * infrun.c (follow_exec): Use exit_inferior_silent.
3362 * inferior.c (exit_inferior_num_silent): Remove.
3363 * inferior.h (exit_inferior_num_silent): Don't declare.
3365 2018-07-03 Tom Tromey <tom@tromey.com>
3368 * darwin-nat.c (darwin_attach_pid): Reset inferior and
3369 inferior_ptid on error.
3371 2018-07-02 Maciej W. Rozycki <macro@mips.com>
3372 Simon Marchi <simon.marchi@polymtl.ca>
3375 * disasm.h (gdb_disassembler): Add
3376 `m_disassembler_options_holder'. member
3377 * disasm.c (get_all_disassembler_options): New function.
3378 (gdb_disassembler::gdb_disassembler): Use it.
3379 (gdb_buffered_insn_length_init_dis): Likewise.
3380 (gdb_buffered_insn_length): Adjust accordingly.
3381 (set_disassembler_options): Handle options with arguments.
3382 (show_disassembler_options_sfunc): Likewise. Add a leading new
3383 line if showing options with descriptions.
3384 (disassembler_options_completer): Adapt to using the
3385 `disasm_options_and_args_t' structure.
3386 * mips-tdep.c (mips_disassembler_options): New variable.
3387 (mips_disassembler_options_o32): Likewise.
3388 (mips_disassembler_options_n32): Likewise.
3389 (mips_disassembler_options_n64): Likewise.
3390 (gdb_print_insn_mips): Don't set `disassembler_options'.
3391 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
3393 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
3394 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
3395 `gdbarch_disassembler_options_implicit' and
3396 `gdbarch_valid_disassembler_options'.
3397 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
3398 `disasm_options_and_args_t' structure.
3399 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
3401 (valid_disassembler_options): Switch from `disasm_options_t' to
3402 the `disasm_options_and_args_t' structure.
3403 * NEWS: Document `set disassembler-options' support for the MIPS
3405 * gdbarch.h: Regenerate.
3406 * gdbarch.c: Regenerate.
3408 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
3410 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
3412 2018-06-29 Joel Brobecker <brobecker@adacore.com>
3414 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
3415 parameter in call to amd64_target_description.
3416 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
3417 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
3418 (amd64fbsd_init_abi): Likewise.
3419 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
3420 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
3421 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
3422 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
3424 2018-06-29 Pedro Alves <palves@redhat.com>
3426 * gdb/amd64-tdep.h (amd64_create_target_description): Add
3427 "segments" parameter.
3428 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
3429 (_initialize_amd64_tdep): Update call to
3430 amd64_create_target_description.
3431 (amd64_target_description): Add "segments" parameter. Adjust
3432 the implementation to use it.
3433 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
3434 call to amd64_create_target_description.
3435 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
3436 * gdb/arch/amd64.h (amd64_create_target_description): Add
3437 "segments" register.
3438 * gdb/arch/amd64.c (amd64_create_target_description): Add
3439 "segments" parameter. Call create_feature_i386_64bit_segments
3440 only if SEGMENTS is true.
3441 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
3442 call to amd64_create_target_description.
3444 2018-06-29 Pedro Alves <palves@redhat.com>
3446 * thread.c (thread_target_id_str): New, factored out from ...
3447 (print_thread_info_1): ... here. Use it to compute the max
3448 "Target Id" column width.
3450 2018-06-29 Pedro Alves <palves@redhat.com>
3452 * remote.c (remote_target::extra_thread_info): Delete
3453 'display_buf' and 'n' locals. from the cache, regardless of
3454 packet mechanims is in use. Use cache for qThreadExtra and qP
3457 2018-06-29 Pedro Alves <palves@redhat.com>
3459 * blockframe.c (find_pc_sect_containing_function): New function.
3460 * breakpoint.c (print_breakpoint_location): Don't call
3461 find_pc_sect_function.
3462 * linespec.c (create_sals_line_offset): Record the location's
3464 * linespec.c (convert_address_location_to_sals): Fill in sal's
3465 symbol with find_pc_sect_containing_function.
3466 * symtab.c (find_function_start_sal): Rename to ...
3467 (find_function_start_sal_1): ... this.
3468 (find_function_start_sal): Reimplement as wrapper around
3469 find_function_start_sal_1, and use
3470 find_pc_sect_containing_function to fill in the sal's symbol.
3471 (find_function_start_sal(symbol*, bool)): Adjust.
3472 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
3474 (find_pc_sect_containing_function): Declare.
3476 2018-06-29 Pedro Alves <palves@redhat.com>
3478 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
3479 true if the the location has no symbol.
3481 2018-06-28 Tom Tromey <tom@tromey.com>
3483 * NEWS: Mention --enable-codesign.
3484 * silent-rules.mk (ECHO_SIGN): New variable.
3485 * configure.ac: Add --enable-codesign.
3486 * configure: Rebuild.
3487 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
3488 (gdb$(EXEEXT)): Optionally invoke codesign.
3490 2018-06-28 Pedro Alves <palves@redhat.com>
3492 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
3494 (switch_to_thread_no_regs): Adjust comment.
3495 * infcmd.c (stop_pc): Delete.
3496 (post_create_inferior, info_program_command): Replace references
3497 to stop_pc with references to thread_info->suspend.stop_pc.
3498 * inferior.h (stop_pc): Delete declaration.
3499 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
3500 (handle_inferior_event_1, handle_signal_stop)
3501 (process_event_stop_test, keep_going_stepped_thread)
3502 (handle_step_into_function, handle_step_into_function_backward)
3503 (print_stop_location): Replace references to stop_pc with
3504 references to thread_info->suspend.stop_pc.
3505 (struct infcall_suspend_state) <stop_pc>: Delete field.
3506 (save_infcall_suspend_state, restore_infcall_suspend_state):
3507 Remove references to inf_stat->stop_pc.
3508 * linux-fork.c (fork_load_infrun_state): Likewise.
3509 * record-btrace.c (record_btrace_set_replay): Likewise.
3510 * record-full.c (record_full_goto_entry): Likewise.
3511 * remote.c (print_one_stopped_thread): Likewise.
3512 * target.c (target_resume): Extend comment.
3513 * thread.c (set_executing_thread): New.
3514 (set_executing): Use it.
3515 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
3516 Remove references to stop_pc.
3518 2018-06-28 Pedro Alves <palves@redhat.com>
3520 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
3521 Moving fetching stop_pc until after ecs->event_thread is refreshed.
3523 2018-06-28 Tom Tromey <tom@tromey.com>
3525 * coffread.c (coff_symfile_finish): Update.
3526 * xcoffread.c (xcoff_symfile_finish): Update.
3527 * elfread.c (elf_symfile_finish): Update.
3528 * symfile.h (dwarf2_free_objfile): Don't declare.
3529 * dwarf2read.c (_initialize_dwarf2_read): Use
3530 register_objfile_data_with_cleanup.
3531 (dwarf2_free_objfile): Now static. Change signature.
3533 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3535 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
3536 option "-o" to add-symbol-file-load to add an offset to each
3537 section's load address.
3538 * symfile.c (set_objfile_default_section_offset): New function.
3540 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3542 * symfile.c (add_symbol_file_command): Make sure that sections
3543 with the same name are sorted in the same order.
3545 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3547 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
3548 require the second argument. If omitted, load sections at the
3549 addresses specified in the file.
3551 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3553 * symfile.c (symbol_file_command, symbol_file_add_main_1)
3554 (_initialize_symfile): Add option "-o" to symbol-file to add an
3555 offset to each section of the symbol file.
3557 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
3559 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
3561 2018-06-27 Tom Tromey <tom@tromey.com>
3563 * stack.c (_initialize_stack): Update "func" help text.
3565 2018-06-27 Tom Tromey <tom@tromey.com>
3567 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
3569 (unwind_infopy_str, pyuw_create_unwind_info)
3570 (unwind_infopy_add_saved_register, pyuw_sniffer)
3571 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
3573 (struct saved_reg): Add constructor.
3574 <value>: Now a gdbpy_ref<>.
3576 2018-06-27 Tom Tromey <tom@tromey.com>
3578 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
3580 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3582 * gdb-gdb.py.in: Format using autopep8.
3584 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3586 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
3587 (type_lookup_function): Recognize CORE_ADDR values.
3589 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3591 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
3594 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3596 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
3599 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3601 * gdb-gdb.py: Move to...
3602 * gdb-gdb.py.in: ... here.
3603 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
3604 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
3606 (distclean): Remove gdb-gdb.py when cleaning.
3607 (gdb-gdb.py, gdb-gdb.gdb): New rules.
3608 * configure: Re-generate.
3610 2018-06-27 Pedro Alves <palves@redhat.com>
3612 * proc-service.c (get_ps_regcache): New.
3613 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
3614 (ps_lsetfpregs): Use it.
3616 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
3619 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
3620 (dwarf_decode_lines_1): Adjust.
3622 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
3624 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
3626 <info_proc>: Likewise.
3628 2018-06-26 Joel Brobecker <brobecker@adacore.com>
3630 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
3631 to windows_fetch_one_register, and only handle the case of
3632 fetching one register. Move the code that reloads the context
3633 and iterates over all registers if R is negative to...
3634 (windows_nat_target::fetch_registers): ... here.
3635 (do_windows_store_inferior_registers): Rename to
3636 windows_store_one_register, and only handle the case of storing
3637 one register. Move the code that handles the case where r is
3639 (windows_nat_target::store_registers) ... here.
3641 2018-06-26 Tom Tromey <tom@tromey.com>
3644 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
3645 * rust-lang.c (rust_print_struct_def): Add podata parameter.
3647 (rust_internal_print_type): Add podata parameter.
3648 (rust_print_type): Update.
3650 2018-06-26 Tom Tromey <tom@tromey.com>
3652 * typeprint.h (struct print_offset_data) <update, finish,
3653 maybe_print_hole>: New methods.
3654 <indentation>: New constant.
3655 * typeprint.c (print_offset_data::indentation): Define.
3656 (print_offset_data::maybe_print_hole, print_offset_data::update)
3657 (print_offset_data::finish): Move from c-typeprint.c and rename.
3658 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
3659 (print_spaces_filtered_with_print_options): Update.
3660 (c_print_type_union_field_offset, maybe_print_hole)
3661 (c_print_type_struct_field_offset): Move to typeprint.c and
3663 (c_type_print_base_struct_union): Update.
3665 2018-06-25 Pedro Alves <palves@redhat.com>
3667 * gdbthread.h (thread_info_ref, delete_thread)
3668 (delete_thread_silent, first_thread_of_inferior)
3669 (any_thread_of_inferior, switch_to_thread)
3670 (enable_thread_stack_temporaries)
3671 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3672 (get_last_thread_stack_temporary)
3673 (value_in_thread_stack_temporaries, can_access_registers_thread):
3674 Spell out "struct thread_info" instead of just "thread_info".
3675 * inferior.h (notice_new_inferior): Likewise.
3677 2018-06-25 Pedro Alves <palves@redhat.com>
3679 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
3680 pass thread_info pointer to delete_thread.
3681 (windows_nat_target::detach): Pass inferior pointer to
3683 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
3685 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
3686 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
3687 and pass a thread_info pointer to delete_thread.
3688 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
3689 pass thread_info pointer to delete_thread.
3690 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
3691 delete_thread_silent call.
3692 * procfs.c (procfs_target::detach): Pass inferior pointer to
3694 (procfs_target::wait): Pass thread_info pointer to delete_thread.
3695 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
3696 delete_thread_silent call.
3697 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
3698 pass thread_info pointer to delete_thread.
3699 (windows_nat_target::detach): Pass inferior pointer to
3702 2018-06-22 Alan Hayward <alan.hayward@arm.com>
3704 * regcache.c (readable_regcache::read_part): Fix asserts.
3705 (reg_buffer::raw_collect_part): New function.
3706 (regcache::write_part): Fix asserts.
3707 (reg_buffer::raw_supply_part): New function.
3708 (regcache::transfer_regset_register): New helper function.
3709 (regcache::transfer_regset): Call new functions.
3710 (regcache_supply_regset): Use gdb_byte*.
3711 (regcache::supply_regset): Likewise.
3712 (regcache_collect_regset): Likewise.
3713 (regcache::collect_regset): Likewise.
3714 * regcache.h (reg_buffer::raw_collect_part): New declaration.
3715 (reg_buffer::raw_supply_part): Likewise.
3716 (regcache::transfer_regset_register): Likewise.
3717 (regcache::transfer_regset): Use gdb_byte*.
3719 2018-06-22 Alan Hayward <alan.hayward@arm.com>
3721 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
3723 2018-06-21 Pedro Alves <palves@redhat.com>
3725 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
3726 instead of a ptid_t. All callers adjusted.
3727 * ada-tasks.c (ada_get_task_number): Likewise. All callers
3729 (print_ada_task_info, display_current_task_id, task_command_1):
3731 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
3733 (breakpoint_kind): Adjust.
3734 (remove_breakpoints_pid): Rename to ...
3735 (remove_breakpoints_inf): ... this. Adjust to take an inferior
3736 pointer. All callers adjusted.
3737 (bpstat_clear_actions): Use inferior_thread.
3738 (get_bpstat_thread): New.
3739 (bpstat_do_actions): Use it.
3740 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
3741 to take a thread_info pointer. All callers adjusted.
3742 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
3743 (breakpoint_re_set_thread): Use inferior_thread.
3744 * breakpoint.h (struct inferior): Forward declare.
3745 (bpstat_stop_status): Update.
3746 (remove_breakpoints_pid): Delete.
3747 (remove_breakpoints_inf): New.
3748 * bsd-uthread.c (bsd_uthread_target::wait)
3749 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
3750 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
3751 (maint_btrace_packet_history_cmd)
3752 (maint_btrace_clear_packet_history_cmd): Adjust.
3753 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
3755 * cli/cli-interp.c: Include "inferior.h".
3756 * common/refcounted-object.h (struct
3757 refcounted_object_ref_policy): New.
3758 * compile/compile-object-load.c: Include gdbthread.h.
3759 (store_regs): Use inferior_thread.
3760 * corelow.c (core_target::close): Use current_inferior.
3761 (core_target_open): Adjust to use first_thread_of_inferior and use
3762 the current inferior.
3763 * ctf.c (ctf_target::close): Adjust to use current_inferior.
3764 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
3765 <thread>: ... this new field. All references adjusted.
3766 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
3767 Take a thread_info pointer instead of a ptid_t.
3768 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
3769 (dummy_frame_discard, register_dummy_frame_dtor): Take a
3770 thread_info pointer instead of a ptid_t.
3771 * elfread.c: Include "inferior.h".
3772 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
3773 Use inferior_thread.
3774 * eval.c (evaluate_subexp): Likewise.
3775 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
3777 * gdb_proc_service.h (struct thread_info): Forward declare.
3778 (struct ps_prochandle) <ptid>: Delete, replaced by ...
3779 <thread>: ... this new field. All references adjusted.
3780 * gdbarch.h, gdbarch.c: Regenerate.
3781 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
3782 'thread' parameter. All implementations and callers adjusted.
3783 * gdbthread.h (thread_info) <set_running>: New method.
3784 (delete_thread, delete_thread_silent): Take a thread_info pointer
3786 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
3787 (first_thread_of_process): Delete, replaced by ...
3788 (first_thread_of_inferior): ... this new function. All callers
3790 (any_live_thread_of_process): Delete, replaced by ...
3791 (any_live_thread_of_inferior): ... this new function. All callers
3793 (switch_to_thread, switch_to_no_thread): Declare.
3794 (is_executing): Delete.
3795 (enable_thread_stack_temporaries): Update comment.
3796 <enable_thread_stack_temporaries>: Take a thread_info pointer
3797 instead of a ptid_t. Incref the thread.
3798 <~enable_thread_stack_temporaries>: Decref the thread.
3801 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3802 (get_last_thread_stack_temporary)
3803 (value_in_thread_stack_temporaries, can_access_registers_thread):
3804 Take a thread_info pointer instead of a ptid_t. All callers
3806 * infcall.c (get_call_return_value): Use inferior_thread.
3807 (run_inferior_call): Work with thread pointers instead of ptid_t.
3808 (call_function_by_hand_dummy): Work with thread pointers instead
3809 of ptid_t. Use thread_info_ref.
3810 * infcmd.c (proceed_thread_callback): Access thread's state
3812 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
3813 access thread's state directly.
3814 (continue_command): Use inferior_thread.
3815 (info_program_command): Use find_thread_ptid and access thread
3817 (proceed_after_attach_callback): Use thread state directly.
3818 (notice_new_inferior): Take a thread_info pointer instead of a
3819 ptid_t. All callers adjusted.
3820 (exit_inferior): Take an inferior pointer instead of a pid. All
3822 (exit_inferior_silent): New.
3823 (detach_inferior): Delete.
3824 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
3825 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
3826 (detach_inferior_command, kill_inferior_command): Use
3827 find_inferior_id instead of valid_gdb_inferior_id and
3828 gdb_inferior_id_to_pid.
3829 (inferior_command): Use inferior and thread pointers.
3830 * inferior.h (struct thread_info): Forward declare.
3831 (notice_new_inferior): Take a thread_info pointer instead of a
3832 ptid_t. All callers adjusted.
3833 (detach_inferior): Delete declaration.
3834 (exit_inferior, exit_inferior_silent): Take an inferior pointer
3835 instead of a pid. All callers adjusted.
3836 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
3837 (valid_gdb_inferior_id): Delete.
3838 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
3839 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
3840 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
3842 <inf>: ... this new field.
3843 <step_ptid>: Delete, replaced by ...
3844 <step_thread>: ... this new field.
3845 (get_displaced_stepping_state): Take an inferior pointer instead
3846 of a pid. All callers adjusted.
3847 (displaced_step_in_progress_any_inferior): Adjust.
3848 (displaced_step_in_progress_thread): Take a thread pointer instead
3849 of a ptid_t. All callers adjusted.
3850 (displaced_step_in_progress, add_displaced_stepping_state): Take
3851 an inferior pointer instead of a pid. All callers adjusted.
3852 (get_displaced_step_closure_by_addr): Adjust.
3853 (remove_displaced_stepping_state): Take an inferior pointer
3854 instead of a pid. All callers adjusted.
3855 (displaced_step_prepare_throw, displaced_step_prepare)
3856 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
3857 All callers adjusted.
3858 (start_step_over): Adjust.
3859 (infrun_thread_ptid_changed): Remove bit updating ptids in the
3860 displaced step queue.
3861 (do_target_resume): Adjust.
3862 (fetch_inferior_event): Use inferior_thread.
3863 (context_switch, get_inferior_stop_soon): Take an
3864 execution_control_state pointer instead of a ptid_t. All callers
3866 (switch_to_thread_cleanup): Delete.
3867 (stop_all_threads): Use scoped_restore_current_thread.
3868 * inline-frame.c: Include "gdbthread.h".
3869 (inline_state) <inline_state>: Take a thread pointer instead of a
3870 ptid_t. All callers adjusted.
3871 <ptid>: Delete, replaced by ...
3872 <thread>: ... this new field.
3873 (find_inline_frame_state): Take a thread pointer instead of a
3874 ptid_t. All callers adjusted.
3875 (skip_inline_frames, step_into_inline_frame)
3876 (inline_skipped_frames, inline_skipped_symbol): Take a thread
3877 pointer instead of a ptid_t. All callers adjusted.
3878 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
3879 (inline_skipped_frames, inline_skipped_symbol): Likewise.
3880 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
3882 * linux-nat.c (get_detach_signal): Likewise.
3883 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
3884 (thread_db_notice_clone): Adjust.
3885 (thread_db_find_new_threads_silently)
3886 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
3887 a thread pointer instead of a ptid_t. All callers adjusted.
3888 * mi/mi-cmd-var.c: Include "inferior.h".
3889 (mi_cmd_var_update_iter): Update to use thread pointers.
3890 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
3892 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
3894 (mi_output_running): ... this new function.
3895 (mi_on_resume_1): Adjust to use it.
3896 (mi_user_selected_context_changed): Adjust to use inferior_thread.
3897 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
3899 (interrupt_thread_callback): : Adjust to use thread and inferior
3901 * proc-service.c: Include "gdbthread.h".
3902 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
3903 * progspace-and-thread.c: Include "inferior.h".
3904 * progspace.c: Include "inferior.h".
3905 * python/py-exitedevent.c (create_exited_event_object): Adjust to
3906 hold a reference to an inferior_object.
3907 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
3909 * python/py-inferior.c (struct inferior_object): Give the type a
3910 tag name instead of a typedef.
3911 (python_on_normal_stop): No need to check if the current thread is
3913 (inferior_to_inferior_object): Change return type to
3914 inferior_object. All callers adjusted.
3915 (find_thread_object): Delete, bits factored out to ...
3916 (thread_to_thread_object): ... this new function.
3917 * python/py-infthread.c (create_thread_object): Use
3918 inferior_to_inferior_object.
3919 (thpy_is_stopped): Use thread pointer directly.
3920 (gdbpy_selected_thread): Use inferior_thread.
3921 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
3922 field, replaced with ...
3923 <thread>: ... this new field. All users adjusted.
3924 (btpy_insn_or_gap_new): Drop const.
3925 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
3927 * python/py-record.c: Include "gdbthread.h".
3928 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3929 a ptid_t. All callers adjusted.
3930 (gdbpy_current_recording): Use inferior_thread.
3931 * python/py-record.h (recpy_record_object) <ptid>: Delete
3932 field, replaced with ...
3933 <thread>: ... this new field. All users adjusted.
3934 (recpy_element_object) <ptid>: Delete
3935 field, replaced with ...
3936 <thread>: ... this new field. All users adjusted.
3937 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
3938 a ptid_t. All callers adjusted.
3939 * python/py-threadevent.c: Include "gdbthread.h".
3940 (get_event_thread): Use thread_to_thread_object.
3941 * python/python-internal.h (struct inferior_object): Forward
3943 (find_thread_object, find_inferior_object): Delete declarations.
3944 (thread_to_thread_object, inferior_to_inferior_object): New
3946 * record-btrace.c: Include "inferior.h".
3947 (require_btrace_thread): Use inferior_thread.
3948 (record_btrace_frame_sniffer)
3949 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
3950 (get_thread_current_frame): Use scoped_restore_current_thread and
3952 (get_thread_current_frame): Use thread pointer directly.
3953 (record_btrace_replay_at_breakpoint): Use thread's inferior
3955 * record-full.c: Include "inferior.h".
3956 * regcache.c: Include "gdbthread.h".
3957 (get_thread_arch_regcache): Use the inferior's address space
3959 (get_thread_regcache, registers_changed_thread): New.
3960 * regcache.h (get_thread_regcache(thread_info *thread)): New
3962 (registers_changed_thread): New.
3963 (remote_target) <remote_detach_1>: Swap order of parameters.
3964 (remote_add_thread): <remote_add_thread>: Return the new thread.
3965 (get_remote_thread_info(ptid_t)): New overload.
3966 (remote_target::remote_notice_new_inferior): Use thread pointers
3968 (remote_target::process_initial_stop_replies): Use
3969 thread_info::set_running.
3970 (remote_target::remote_detach_1, remote_target::detach)
3971 (extended_remote_target::detach): Adjust.
3972 * stack.c (frame_show_address): Use inferior_thread.
3973 * target-debug.h (target_debug_print_thread_info_pp): New.
3974 * target-delegates.c: Regenerate.
3975 * target.c (default_thread_address_space): Delete.
3976 (memory_xfer_partial_1): Use current_inferior.
3977 (target_detach): Use current_inferior.
3978 (target_thread_address_space): Delete.
3979 (generic_mourn_inferior): Use current_inferior.
3980 * target.h (struct target_ops) <thread_address_space>: Delete.
3981 (target_thread_address_space): Delete.
3982 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
3984 (delete_thread_1, delete_thread, delete_thread_silent): Take a
3985 thread pointer instead of a ptid_t. Adjust all callers.
3986 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
3987 (first_thread_of_process): Delete, replaced by ...
3988 (first_thread_of_inferior): ... this new function. All callers
3990 (any_thread_of_process): Rename to ...
3991 (any_thread_of_inferior): ... this, and take an inferior pointer.
3992 (any_live_thread_of_process): Rename to ...
3993 (any_live_thread_of_inferior): ... this, and take an inferior
3995 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
3996 (value_in_thread_stack_temporaries)
3997 (get_last_thread_stack_temporary): Take a thread pointer instead
3998 of a ptid_t. Adjust all callers.
3999 (thread_info::set_running): New.
4000 (validate_registers_access): Use inferior_thread.
4001 (can_access_registers_ptid): Rename to ...
4002 (can_access_registers_thread): ... this, and take a thread
4004 (print_thread_info_1): Adjust to compare thread pointers instead
4006 (switch_to_no_thread, switch_to_thread): Make extern.
4007 (scoped_restore_current_thread::~scoped_restore_current_thread):
4008 Use m_thread pointer directly.
4009 (scoped_restore_current_thread::scoped_restore_current_thread):
4010 Use inferior_thread.
4011 (thread_command): Use thread pointer directly.
4012 (thread_num_make_value_helper): Use inferior_thread.
4013 * top.c (execute_command): Use inferior_thread.
4014 * tui/tui-interp.c: Include "inferior.h".
4015 * varobj.c (varobj_create): Use inferior_thread.
4016 (value_of_root_1): Use find_thread_global_id instead of
4017 global_thread_id_to_ptid.
4019 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4021 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4023 (regcache::write_part): Likewise.
4024 (readable_regcache::cooked_read_part): Update comment.
4025 (readable_regcache::cooked_write_part): Likewise.
4026 * regcache.h: (readable_regcache::read_part): Likewise.
4027 (regcache::write_part): Likewise.
4029 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4030 Dirk Schubert <dirk.schubert@arm.com>
4032 * aarch64-linux-nat.c (post_attach): New.
4033 (aarch64_linux_nat_target::post_attach): Override post_attach to
4034 record the number of hardware debug registers.
4036 2018-06-20 Tom Tromey <tom@tromey.com>
4038 * python/py-param.c (add_setshow_generic): Make parameters const.
4039 (parmpy_init): Update.
4041 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4043 * regcache.h (regcache_cooked_read_ftype): Rename to...
4044 (register_read_ftype): ...this, change type to function_view.
4045 (class reg_buffer) <save>: Remove src parameter.
4046 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4047 parameter non-const in first overload. Remove src parameter in
4049 * regcache.c (do_cooked_read): Remove.
4050 (readonly_detached_regcache::readonly_detached_regcache): Make
4051 parameter non-const, adjust call to other constructor.
4052 (reg_buffer::save): Remove src parameter.
4053 * frame.c (do_frame_register_read): Remove.
4054 (frame_save_as_regcache): Use lambda function.
4055 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4056 parameter to ppu2spu_data *.
4057 (ppu2spu_sniffer): Use lambda function.
4059 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4061 * record-full.c (record_full_target::insert_breakpoint): Remove
4062 "struct" keyword, add const.
4064 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
4066 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
4067 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
4068 * configure.ac: Remove AC_PREREQ, add missing quoting.
4069 * gnulib/configure.ac: Modernize usage of
4070 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
4071 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
4072 (AUTOMAKE_VERSION): Bump to 1.15.1.
4073 * configure: Re-generate.
4074 * config.in: Re-generate.
4075 * aclocal.m4: Re-generate.
4076 * gnulib/aclocal.m4: Re-generate.
4077 * gnulib/config.in: Re-generate.
4078 * gnulib/configure: Re-generate.
4079 * gnulib/import/Makefile.in: Re-generate.
4081 2018-06-19 Pedro Alves <palves@redhat.com>
4083 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
4084 (lookup_minimal_symbol_by_pc_section): ... here with
4085 gdb_assert_not_reached added.
4087 2018-06-19 Pedro Alves <palves@redhat.com>
4089 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
4090 parameter with a block parameter. Compare location's block symbol
4091 with the frame's block instead of addresses.
4092 (skip_inline_frames): Pass the current block instead of the
4093 frame's address. Break out as soon as we determine the frame
4094 should not be skipped.
4096 2018-06-18 Tom Tromey <tom@tromey.com>
4098 * solib-aix.c (solib_aix_get_section_offsets): Return
4100 (solib_aix_solib_create_inferior_hook): Update.
4102 2018-06-18 Tom Tromey <tom@tromey.com>
4104 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
4106 2018-06-18 Tom Tromey <tom@tromey.com>
4108 * solib-frv.c (frv_relocate_main_executable): Use
4110 * solib-dsbt.c (dsbt_relocate_main_executable): Use
4113 2018-06-18 Tom Tromey <tom@tromey.com>
4115 * objfiles.h (inhibit_section_map_updates): Update.
4116 (resume_section_map_updates, resume_section_map_updates_cleanup):
4118 * solib-svr4.c (svr4_handle_solib_event): Update.
4119 * objfiles.c (inhibit_section_map_updates): Return
4120 scoped_restore_tmpl<int>.
4121 (resume_section_map_updates, resume_section_map_updates_cleanup):
4124 2018-06-18 Tom Tromey <tom@tromey.com>
4126 * valprint.h (read_string): Update.
4127 * valprint.c (read_string): Change type of "buffer".
4128 (val_print_string): Update.
4129 * python/py-value.c (valpy_string): Update.
4130 * language.h (struct language_defn) <la_get_string>: Change
4132 (default_get_string, c_get_string): Update.
4133 * language.c (default_get_string): Change type of "buffer".
4134 * guile/scm-value.c (gdbscm_value_to_string): Update.
4135 * c-lang.c (c_get_string): Change type of "buffer".
4137 2018-06-18 Tom Tromey <tom@tromey.com>
4139 * ser-mingw.c (struct pipe_state_destroyer): New.
4140 (pipe_state_up): New typedef.
4141 (cleanup_pipe_state): Remove.
4142 (pipe_windows_open): Use pipe_state_up. Don't release argv.
4144 2018-06-18 Tom Tromey <tom@tromey.com>
4146 * rust-lang.h (rust_yyerror): Don't declare.
4147 * rust-lang.c (rust_language_defn): Update.
4148 * rust-exp.y (yyerror): Now static.
4149 * parse.c (parse_exp_in_context_1): Update.
4150 * p-lang.h (p_yyerror): Don't declare.
4151 * p-lang.c (p_language_defn): Update.
4152 * p-exp.y (yyerror): Now static.
4153 * opencl-lang.c (opencl_language_defn): Update.
4154 * objc-lang.c (objc_language_defn): Update.
4155 * m2-lang.h (m2_yyerror): Don't declare.
4156 * m2-lang.c (m2_language_defn): Update.
4157 * m2-exp.y (yyerror): Now static.
4158 * language.h (struct language_defn) <la_error>: Remove.
4159 * language.c (unk_lang_error): Remove.
4160 (unknown_language_defn, auto_language_defn): Remove.
4161 * go-lang.h (go_yyerror): Don't declare.
4162 * go-lang.c (go_language_defn): Update.
4163 * go-exp.y (yyerror): Now static.
4164 * f-lang.h (f_yyerror): Don't declare.
4165 * f-lang.c (f_language_defn): Update.
4166 * f-exp.y (yyerror): Now static.
4167 * d-lang.h (d_yyerror): Don't declare.
4168 * d-lang.c (d_language_defn): Update.
4169 * d-exp.y (yyerror): Now static.
4170 * c-lang.h (c_yyerror): Don't declare.
4171 * c-lang.c (c_language_defn, cplus_language_defn)
4172 (asm_language_defn, minimal_language_defn): Update.
4173 * c-exp.y (yyerror): Now static.
4174 * ada-lang.h (ada_yyerror): Don't declare.
4175 * ada-lang.c (ada_language_defn): Update.
4176 * ada-exp.y (yyerror): Now static.
4178 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4180 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
4181 (store_sveregs_to_thread): Likewise.
4182 (aarch64_linux_fetch_inferior_registers): Check for SVE.
4183 (aarch64_linux_store_inferior_registers): Likewise.
4184 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
4186 (aarch64_sve_regs_copy_to_regcache): Likewise.
4187 (aarch64_sve_regs_copy_from_regcache): Likewise.
4188 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
4190 (aarch64_sve_regs_copy_to_regcache): Likewise.
4191 (aarch64_sve_regs_copy_from_regcache): Likewise.
4192 (sve_context): Structure from Linux headers.
4193 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
4194 (SVE_SIG_ZREG_SIZE): Likewise.
4195 (SVE_SIG_PREG_SIZE): Likewise.
4196 (SVE_SIG_FFR_SIZE): Likewise.
4197 (SVE_SIG_REGS_OFFSET): Likewise.
4198 (SVE_SIG_ZREGS_OFFSET): Likewise.
4199 (SVE_SIG_ZREG_OFFSET): Likewise.
4200 (SVE_SIG_ZREGS_SIZE): Likewise.
4201 (SVE_SIG_PREGS_OFFSET): Likewise.
4202 (SVE_SIG_PREG_OFFSET): Likewise.
4203 (SVE_SIG_PREGS_SIZE): Likewise.
4204 (SVE_SIG_FFR_OFFSET): Likewise.
4205 (SVE_SIG_REGS_SIZE): Likewise.
4206 (SVE_SIG_CONTEXT_SIZE): Likewise.
4207 (SVE_PT_REGS_MASK): Likewise.
4208 (SVE_PT_REGS_FPSIMD): Likewise.
4209 (SVE_PT_REGS_SVE): Likewise.
4210 (SVE_PT_VL_INHERIT): Likewise.
4211 (SVE_PT_VL_ONEXEC): Likewise.
4212 (SVE_PT_REGS_OFFSET): Likewise.
4213 (SVE_PT_FPSIMD_OFFSET): Likewise.
4214 (SVE_PT_FPSIMD_SIZE): Likewise.
4215 (SVE_PT_SVE_ZREG_SIZE): Likewise.
4216 (SVE_PT_SVE_PREG_SIZE): Likewise.
4217 (SVE_PT_SVE_FFR_SIZE): Likewise.
4218 (SVE_PT_SVE_FPSR_SIZE): Likewise.
4219 (SVE_PT_SVE_FPCR_SIZE): Likewise.
4220 (__SVE_SIG_TO_PT): Likewise.
4221 (SVE_PT_SVE_OFFSET): Likewise.
4222 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
4223 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
4224 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
4225 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
4226 (SVE_PT_SVE_PREG_OFFSET): Likewise.
4227 (SVE_PT_SVE_PREGS_SIZE): Likewise.
4228 (SVE_PT_SVE_FFR_OFFSET): Likewise.
4229 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
4230 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
4231 (SVE_PT_SVE_SIZE): Likewise.
4232 (SVE_PT_SIZE): Likewise.
4233 (HAS_SVE_STATE): New define.
4235 2018-06-18 Alan Hayward <alan.hayward@arm.com>
4237 * nat/aarch64-sve-linux-sigcontext.h: New file.
4238 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
4240 (SVE_VQ_MIN): Likewise.
4241 (SVE_VQ_MAX): Likewise.
4242 (SVE_VL_MIN): Likewise.
4243 (SVE_VL_MAX): Likewise.
4244 (SVE_NUM_ZREGS): Likewise.
4245 (SVE_NUM_PREGS): Likewise.
4246 (sve_vl_valid): Likewise.
4247 (struct user_sve_header): Likewise.
4249 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
4250 Richard Bunt <Richard.Bunt@arm.com>
4252 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
4253 was requested by GDB.
4255 2018-06-15 Tom de Vries <tdevries@suse.de>
4257 * MAINTAINERS (Write After Approval): Add Tom de Vries.
4259 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
4261 * gnulib/update-gnulib.sh: Print expected versions of
4264 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
4266 * arch-utils.c (default_type_align): Use type_length_units.
4267 * gdbtypes.c (type_align): Use type_length_units.
4269 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4271 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
4272 of 'define' command.
4274 2018-06-14 Tom de Vries <tdevries@suse.de>
4277 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
4278 get_no_prettyformat_print_options.
4280 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
4282 * sparc-nat.h: Include target.h.
4283 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
4284 <fetch_registers>: Remove this argument in function call.
4285 <store_registers>: Remove this argument in function call, remove
4287 <low_forget_process>: Call sparc64_forget_process instead of
4288 sparc_forget_process.
4290 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4292 * procfs.c (_initialize_procfs): Use add_inf_child_target.
4293 (procfs_target::make_corefile_notes): Adjust to new
4294 target_read_alloc return type.
4296 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4297 Stephen Roberts <stephen.roberts@arm.com>
4300 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
4301 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
4302 Move should_notify_stop local into more inner scope.
4304 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4305 Stephen Roberts <stephen.roberts@arm.com>
4308 * infrun.c (resume_1): Add call to mark_async_event_handler.
4310 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
4312 * infrun.c (do_target_wait): Change old version of $pc printed.
4314 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
4316 * dwarf2read.c (read_index_from_section): Rename to...
4317 (read_gdb_index_from_section): ... this, update all callers.
4318 (dwarf2_read_index): Rename to...
4319 (dwarf2_read_gdb_index): ... this, update all callers.
4321 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
4323 * gdb/hppa-linux-nat.c
4324 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
4325 hppa_linux_nat_target::fetch_registers.
4327 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4329 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
4330 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
4331 (AARCH64_DWARF_SVE_FFR): Likewise.
4332 (AARCH64_DWARF_SVE_P0): Likewise.
4333 (AARCH64_DWARF_SVE_Z0): Likewise.
4335 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4337 * common/common-regcache.h (raw_compare): New function.
4338 * regcache.c (regcache::raw_compare): Likewise.
4339 * regcache.h (regcache::raw_compare): New declaration.
4341 2018-06-11 Alan Hayward <alan.hayward@arm.com>
4343 * common/common-regcache.h (reg_buffer_common): New structure.
4344 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
4345 (reg_buffer::raw_supply): Likewise.
4346 (reg_buffer::raw_supply_integer): Likewise.
4347 (reg_buffer::raw_supply_zeroed): Likewise.
4348 (reg_buffer::raw_collect): Likewise.
4349 (reg_buffer::raw_collect_integer): Likewise.
4350 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
4351 (reg_buffer::raw_supply): Likewise.
4352 (reg_buffer::raw_supply_integer): Likewise.
4353 (reg_buffer::raw_supply_zeroed): Likewise.
4354 (reg_buffer::raw_collect): Likewise.
4355 (reg_buffer::raw_collect_integer): Likewise.
4357 2018-06-10 Tom Tromey <tom@tromey.com>
4359 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
4360 (class remote_state) <stop_reply_queue>: Now std::vector.
4361 (remote_state::~remote_state)
4362 (remote_target::stop_reply_queue_length): Update.
4363 (struct queue_iter_param, remove_child_of_pending_fork)
4364 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
4365 (check_pending_event_prevents_wildcard_vcont_callback)
4366 (remove_stop_reply_for_inferior)
4367 (remove_stop_reply_of_remote_state)
4368 (remote_notif_remove_once_on_match)
4369 (stop_reply_match_ptid_and_ws)
4370 (remote_kill_child_of_pending_fork): Remove.
4371 (remote_target::remove_new_fork_children)
4372 (remote_target::check_pending_events_prevent_wildcard_vcont)
4373 (remote_target::discard_pending_stop_replies)
4374 (remote_target::discard_pending_stop_replies_in_queue)
4375 (remote_target::remote_notif_remove_queued_reply)
4376 (remote_target::queued_stop_reply)
4377 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
4378 (remote_target::wait, remote_target::kill_new_fork_children)
4379 (remote_target::async): Update.
4381 2018-06-10 Tom Tromey <tom@tromey.com>
4383 * record-full.c (record_full_arch_list_cleanups): Remove.
4384 (record_full_message): Use try/catch.
4385 (record_full_wait_cleanups): Remove.
4386 (record_full_wait_1): Use try/catch.
4387 (record_full_restore): Likewise.
4389 2018-06-10 Tom Tromey <tom@tromey.com>
4391 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
4392 declare VEC. Add constructor.
4393 <in_target_beneath>: Now bool.
4394 (record_full_breakpoints): Now a std::vector, static.
4395 (record_full_sync_record_breakpoints)
4396 (record_full_init_record_breakpoints)
4397 (record_full_target::insert_breakpoint)
4398 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
4400 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
4402 * dwarf2read.c (process_cu_includes): Remove struct keyword.
4403 * serial.c (serial_interface_lookup): Remove struct keyword.
4405 2018-06-10 Tom Tromey <tom@tromey.com>
4407 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
4409 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
4411 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
4413 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
4414 "beneath" as a method.
4415 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
4416 Use "beneath" as a method.
4418 2018-06-10 Tom Tromey <tom@tromey.com>
4420 * tracefile.c (struct trace_file_writer_deleter): New.
4421 <operator()>: Rename from trace_file_writer_xfree.
4422 (trace_file_writer_up): New typedef.
4423 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
4425 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
4427 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
4428 <m_registers, m_register_status>: Change type to
4430 * regcache.c (reg_buffer::reg_buffer): Use new instead of
4433 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
4435 * common/common-regcache.h (enum register_status): Add
4436 underlying type "signed char".
4437 * regcache.h (reg_buffer) <m_register_status>: Change type to
4439 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
4440 register_status instead of signed char.
4441 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
4442 (reg_buffer::get_register_status): Remove cast.
4443 (readable_regcache::raw_read): Remove cast.
4444 (readable_regcache::cooked_read): Remove cast.
4446 2018-06-09 Tom Tromey <tom@tromey.com>
4448 * source.c (reverse_search_command, forward_search_command): Use
4451 2018-06-09 Tom Tromey <tom@tromey.com>
4453 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
4454 (serial_ops_list): Now static, std::vector.
4455 (serial_interface_lookup, serial_add_interface): Update.
4457 2018-06-09 Tom Tromey <tom@tromey.com>
4459 * dwarf2read.c (process_cu_includes): Update.
4460 (process_full_comp_unit): Update.
4461 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
4464 2018-06-08 Paul Koning <paul_koning@dell.com>
4468 * python/python.c (do_start_initialization):
4469 Avoid call to internal Python API.
4470 (init__gdb_module): New function.
4472 2018-06-08 Gary Benson <gbenson@redhat.com>
4474 * linux-thread-db.c (valprint.h): New include.
4475 (struct check_thread_db_info): New structure.
4476 (check_thread_db_on_load, tdb_testinfo): New static globals.
4477 (check_thread_db, check_thread_db_callback): New functions.
4478 (try_thread_db_load_1): Run integrity checks if requested.
4479 (maintenance_check_libthread_db): New function.
4480 (_initialize_thread_db): Register "maint check libthread-db"
4481 and "maint set/show check-libthread-db".
4482 * NEWS: Mention the above new commands.
4484 2018-06-08 Tom Tromey <tom@tromey.com>
4486 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
4489 2018-06-08 Tom Tromey <tom@tromey.com>
4491 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
4493 2018-06-08 Tom Tromey <tom@tromey.com>
4495 * common/btrace-common.h (struct btrace_data): Add constructor,
4496 destructor, move assignment operator.
4497 <empty, clear, fini>: New methods.
4498 <format>: Initialize.
4499 (btrace_data_init, btrace_data_fini, btrace_data_clear)
4500 (btrace_data_empty): Don't declare.
4501 * common/btrace-common.c (btrace_data_init): Remove.
4502 (btrace_data::fini): Rename from btrace_data_fini.
4503 (btrace_data::empty): Rename from btrace_data_empty.
4504 (btrace_data::clear): Rename from btrace_data_clear. Return
4506 * btrace.h (make_cleanup_btrace_data): Don't declare.
4507 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
4508 (parse_xml_btrace): Update.
4509 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
4510 (maint_btrace_clear_packet_history_cmd): Update.
4512 2018-06-07 Pedro Alves <palves@redhat.com>
4514 * target.h (target_ops) <beneath>: Now a method. All references
4516 (class target_stack): New.
4517 * target.c (g_target_stack): New.
4518 (g_current_top_target): Delete.
4519 (current_top_target): Get the top target out of g_target_stack.
4520 (target_stack::push, target_stack::unpush): New.
4521 (push_target, unpush_target): Reimplement.
4522 (target_is_pushed): Reimplement in terms of g_target_stack.
4523 (target_ops::beneath, target_stack::find_beneath): New.
4525 2018-06-07 Pedro Alves <palves@redhat.com>
4527 * target.h (find_target_beneath): Delete declaration.
4528 * target.c (find_target_beneath): Delete definition.
4529 * aix-thread.c: All callers of find_target_beneath adjusted to
4530 call target_ops::beneath instead.
4531 * bsd-uthread.c: Likewise.
4532 * linux-thread-db.c: Likewise.
4533 * ravenscar-thread.c: Likewise.
4534 * sol-thread.c: Likewise.
4535 * spu-multiarch.c: Likewise.
4537 2018-06-07 Pedro Alves <palves@redhat.com>
4539 * target.h (target_ops) <beneath>: Now a method. All references
4541 (target_ops) <m_beneath>: New.
4542 * target.c (target_ops::beneath): New.
4543 * corelow.c: Adjust all references to target_ops::beneath.
4544 * linux-thread-db.c: Likewise.
4545 * make-target-delegates: Likewise.
4546 * record-btrace.c: Likewise.
4547 * record-full.c: Likewise.
4548 * remote.c: Likewise.
4549 * target.c: Likewise.
4550 * target-delegates.c: Regenerate.
4552 2018-06-07 Pedro Alves <palves@redhat.com>
4554 * target.h (target_stack): Delete.
4555 (current_top_target): Declare function.
4556 * target.c (target_stack): Delete.
4557 (g_current_top_target): New.
4558 (current_top_target): New function.
4559 * auxv.c: Use current_top_target instead of target_stack
4561 * avr-tdep.c: Likewise.
4562 * breakpoint.c: Likewise.
4563 * corefile.c: Likewise.
4564 * elfread.c: Likewise.
4566 * exceptions.c: Likewise.
4567 * frame.c: Likewise.
4568 * gdbarch-selftests.c: Likewise.
4569 * gnu-v3-abi.c: Likewise.
4570 * ia64-tdep.c: Likewise.
4571 * ia64-vms-tdep.c: Likewise.
4572 * infcall.c: Likewise.
4573 * infcmd.c: Likewise.
4574 * infrun.c: Likewise.
4575 * linespec.c: Likewise.
4576 * linux-tdep.c: Likewise.
4577 * minsyms.c: Likewise.
4578 * ppc-linux-nat.c: Likewise.
4579 * ppc-linux-tdep.c: Likewise.
4580 * procfs.c: Likewise.
4581 * regcache.c: Likewise.
4582 * remote.c: Likewise.
4583 * rs6000-tdep.c: Likewise.
4584 * s390-linux-nat.c: Likewise.
4585 * s390-tdep.c: Likewise.
4586 * solib-aix.c: Likewise.
4587 * solib-darwin.c: Likewise.
4588 * solib-dsbt.c: Likewise.
4589 * solib-spu.c: Likewise.
4590 * solib-svr4.c: Likewise.
4591 * solib-target.c: Likewise.
4592 * sparc-tdep.c: Likewise.
4593 * sparc64-tdep.c: Likewise.
4594 * spu-tdep.c: Likewise.
4595 * symfile.c: Likewise.
4596 * symtab.c: Likewise.
4597 * target-descriptions.c: Likewise.
4598 * target-memory.c: Likewise.
4599 * target.c: Likewise.
4600 * target.h: Likewise.
4601 * tracefile-tfile.c: Likewise.
4602 * tracepoint.c: Likewise.
4603 * valops.c: Likewise.
4604 * valprint.c: Likewise.
4605 * value.c: Likewise.
4606 * windows-tdep.c: Likewise.
4607 * mi/mi-main.c: Likewise.
4609 2018-06-07 Tom Tromey <tom@tromey.com>
4611 * valprint.h (build_address_symbolic): Declare.
4612 * printcmd.c (print_address_symbolic): Update.
4613 (build_address_symbolic): Change "name" and "filename" to
4615 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
4617 * defs.h (build_address_symbolic): Remove declaration.
4619 2018-06-07 Alan Hayward <alan.hayward@arm.com>
4621 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
4622 (aarch64_vnv_type): Add function.
4623 (aarch64_pseudo_register_name): Add V regs for SVE.
4624 (aarch64_pseudo_register_type): Likewise.
4625 (aarch64_pseudo_register_reggroup_p): Likewise.
4626 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
4627 (aarch64_pseudo_read_value): Add V regs for SVE.
4628 (aarch64_pseudo_write_2): Use V0 offset for SVE
4629 (aarch64_pseudo_write): Add V regs for SVE.
4630 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
4632 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
4634 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
4635 (sve_vl_from_vq): Likewise.
4637 2018-06-05 Tom Tromey <tom@tromey.com>
4639 * cli/cli-cmds.c (show_version): Update.
4640 * top.c (print_gdb_version): Add "interactive" parameter.
4642 * main.c (captured_main_1): Update.
4643 * top.h (print_gdb_version): Add "interactive" parameter and a
4646 2018-06-05 David Malcolm <dmalcolm@redhat.com>
4648 * common/enum-flags.h: Add trailing semicolon to example in
4651 2018-06-05 Tom Tromey <tom@tromey.com>
4654 * NEWS: Add entry about pager.
4655 * utils.c (pagination_disabled_for_command): New global.
4656 (prompt_for_continue): Allow "c" response to prompt.
4657 (reinitialize_more_filter): Clear
4658 pagination_disabled_for_command.
4659 (fputs_maybe_filtered): Check pagination_disabled_for_command.
4661 2018-06-04 Tom Tromey <tom@tromey.com>
4663 * ada-lang.h (ada_lookup_symbol_list): Update.
4664 * ada-lang.c (resolve_subexp): Update.
4665 (symbols_are_identical_enums): Change type of syms. Remove nsyms
4667 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
4668 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
4669 results parameter to std::vector.
4670 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
4672 * ada-exp.y (block_lookup): Update.
4673 (select_possible_type_sym): Change type of syms. Remove nsyms
4675 (write_var_or_type, write_name_assoc): Update.
4677 2018-06-04 Joel Brobecker <brobecker@adacore.com>
4679 * windows-nat.c (windows_nat_target::xfer_partial): Return
4680 TARGET_XFER_E_IO if we need to delegate to the target beneath
4681 but BENEATH is NULL.
4683 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
4685 * Makefile.in (config.status): Add configure.nat as a
4688 2018-06-04 Tom Tromey <tom@tromey.com>
4690 * cp-name-parser.y (cpname_state): Add method declarations.
4691 (HANDLE_QUAL): Update.
4692 (cpname_state::d_grab, cpname_state::fill_comp)
4693 (cpname_state::make_operator, cpname_state::make_dtor)
4694 (cpname_state::make_builtin_type, cpname_state::make_name)
4695 (cpname_state::d_qualify, cpname_state::d_int_type)
4696 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
4697 (%union): Move earlier.
4699 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4701 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
4703 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4705 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
4706 (aarch64_pseudo_write_1): Likewise.
4707 (aarch64_pseudo_read_value): Use helper.
4708 (aarch64_pseudo_write): Likewise.
4710 2018-06-04 Pedro Alves <palves@redhat.com>
4712 * darwin-nat.c (darwin_ops): Delete.
4713 (darwin_attach_pid): Use get_native_target.
4715 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4717 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
4718 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
4720 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4722 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
4723 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
4724 (aarch64_gdbarch_init): Check for SVE.
4725 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
4727 2018-06-04 Alan Hayward <alan.hayward@arm.com>
4729 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
4730 * aarch64-tdep.h (aarch64_read_description): Likewise.
4731 * arch/aarch64.c (aarch64_create_target_description): Likewise.
4732 * arch/aarch64.h (aarch64_create_target_description): Likewise.
4733 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
4734 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
4735 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
4737 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
4739 * value.c (value_fetch_lazy_bitfield): New.
4740 (value_fetch_lazy_memory): New.
4741 (value_fetch_lazy_register): New.
4742 (value_fetch_lazy): Factor out to smaller functions.
4744 2018-06-01 Tom Tromey <tom@tromey.com>
4746 * cp-name-parser.y (backslashable, represented): Now const.
4748 2018-06-01 Tom Tromey <tom@tromey.com>
4750 * cp-name-parser.y: Include parser-defs.h.
4751 (parser_fprintf): Remove declaration.
4753 2018-06-01 Tom Tromey <tom@tromey.com>
4755 * cp-name-parser.y: Use %pure-parser, %lex-param, and
4757 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
4758 (global_result): Remove globals.
4759 (struct cpname_state): New.
4760 (yyparse): Don't declare.
4761 (yylex, yyerror): Move declarations after %union.
4762 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
4763 (make_name): Add state parameter.
4765 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
4767 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
4769 (yylex): Add lvalp, state parameters.
4770 (yyerror): Add state parameter.
4771 (cp_demangled_name_to_comp): Update.
4773 2018-06-01 Tom Tromey <tom@tromey.com>
4775 * cp-name-parser.y (parser_fprintf): Declare.
4776 (GDB_YY_REMAP_PREFIX): Define.
4777 Include yy-remap.h. Don't redefine yy* identifiers.
4779 2018-06-01 Tom Tromey <tom@tromey.com>
4781 * python/py-type.c (typy_legacy_template_argument): Update.
4782 * cp-support.h (cp_demangled_name_to_comp): Update.
4783 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
4784 parameter to be a "std::string *".
4787 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
4789 * ada-lex.l: Include "diagnostics.h" instead of
4790 "common/diagnostics.h".
4791 * unittests/environ-selftests.c: Likewise.
4792 * common/diagnostics.h: Moved to ../include.
4794 2018-06-01 Joel Brobecker <brobecker@adacore.com>
4796 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
4797 to language_mode_manual while calling breakpoint_re_set_one.
4799 2018-06-01 Tom Tromey <tom@tromey.com>
4801 * valops.c (value_cast_structs, destructor_name_p): Update.
4802 * symtab.c (gdb_mangle_name): Update.
4803 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
4805 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
4806 (pascal_object_print_value_fields, pascal_object_print_value):
4808 * p-typeprint.c (pascal_type_print_derivation_info): Update.
4809 * linespec.c (find_methods): Update.
4810 * gdbtypes.h (type_name_no_tag): Remove.
4811 (type_name_or_error): Rename from type_name_no_tag_or_error.
4812 * gdbtypes.c (type_name_no_tag): Remove.
4813 (type_name_or_error): Rename from type_name_no_tag_or_error.
4814 (lookup_struct_elt_type, check_typedef): Update.
4815 * expprint.c (print_subexp_standard): Update.
4816 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
4817 * d-namespace.c (d_lookup_nested_symbol): Update.
4818 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
4819 (cp_print_class_member): Update.
4820 * cp-namespace.c (cp_lookup_nested_symbol): Update.
4821 * completer.c (add_struct_fields): Update.
4822 * c-typeprint.c (cp_type_print_derivation_info)
4823 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
4825 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
4826 (ada_prefer_type, ada_is_exception_sym): Update.
4828 2018-06-01 Tom Tromey <tom@tromey.com>
4830 * valops.c (enum_constant_from_type, value_namespace_elt)
4831 (value_maybe_namespace_elt): Update.
4832 * valarith.c (find_size_for_pointer_math): Update.
4833 * target-descriptions.c (make_gdb_type): Update.
4834 * symmisc.c (print_symbol): Update.
4835 * stabsread.c (define_symbol, read_type)
4836 (complain_about_struct_wipeout, add_undefined_type)
4837 (cleanup_undefined_types_1): Update.
4838 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
4839 (rust_range_type_p, val_print_struct, rust_print_struct_def)
4840 (rust_internal_print_type, rust_composite_type)
4841 (rust_evaluate_funcall, rust_evaluate_subexp)
4842 (rust_inclusive_range_type_p): Update.
4843 * python/py-type.c (typy_get_tag): Update.
4844 * p-typeprint.c (pascal_type_print_base): Update.
4845 * mdebugread.c (parse_symbol, parse_type): Update.
4846 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
4848 * guile/scm-type.c (gdbscm_type_tag): Update.
4849 * go-lang.c (sixg_string_p): Update.
4850 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
4852 * gdbtypes.h (struct main_type) <tag_name>: Remove.
4853 (TYPE_TAG_NAME): Remove.
4854 * gdbtypes.c (type_name_no_tag): Simplify.
4855 (check_typedef, check_types_equal, recursive_dump_type)
4856 (copy_type_recursive, arch_composite_type): Update.
4857 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
4858 in summary mode when needed.
4859 * eval.c (evaluate_funcall): Update.
4860 * dwarf2read.c (fixup_go_packaging, read_structure_type)
4861 (process_structure_scope, read_enumeration_type)
4862 (read_namespace_type, read_module_type, determine_prefix): Update.
4863 * cp-support.c (inspect_type): Update.
4864 * coffread.c (process_coff_symbol, decode_base_type): Update.
4865 * c-varobj.c (c_is_path_expr_parent): Update.
4866 * c-typeprint.c (c_type_print_base_struct_union): Update.
4867 (c_type_print_base_1): Update. Print struct/class/union/enum in
4868 summary when using C language.
4869 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
4870 (gen_maybe_namespace_elt): Update.
4871 * ada-lang.c (ada_type_name): Simplify.
4872 (empty_record, ada_template_to_fixed_record_type_1)
4873 (template_to_static_fixed_type)
4874 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
4876 2018-06-01 Tom Tromey <tom@tromey.com>
4878 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
4880 * c-typeprint.c (c_print_type_1): Add "language" parameter.
4881 (c_print_type): Update.
4882 (c_print_type): New overload.
4883 (c_type_print_varspec_prefix, c_type_print_args)
4884 (c_type_print_varspec_suffix, c_print_type_no_offsets)
4885 (c_type_print_base_struct_union, c_type_print_base_1)
4886 (cp_type_print_method_args): Add "language" parameter.
4887 (c_type_print_base): Update.
4888 * c-lang.h (c_print_type): Add new overload.
4890 2018-06-01 Tom Tromey <tom@tromey.com>
4892 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
4893 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
4895 2018-06-01 Alan Hayward <alan.hayward@arm.com>
4897 * aarch64-tdep.c (aarch64_sve_register_names): New const
4899 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
4900 (AARCH64_SVE_Z_REGS_NUM): New define.
4901 (AARCH64_SVE_P_REGS_NUM): Likewise.
4902 (AARCH64_SVE_NUM_REGS): Likewise.
4904 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
4906 * nat/linux-ptrace.h [__alpha__]
4907 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
4910 2018-05-31 Maciej W. Rozycki <macro@mips.com>
4912 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
4913 the endianness selected.
4914 * NEWS: Document `set endian auto' mode operation update.
4916 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4918 * Makefile.in: Add new header.
4919 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
4920 (sve_vl_from_vg): Likewise.
4921 (sve_vq_from_vl): Likewise.
4922 (sve_vl_from_vq): Likewise.
4923 (sve_vq_from_vg): Likewise.
4924 (sve_vg_from_vq): Likewise.
4925 * configure.nat: Add new c file.
4926 * nat/aarch64-sve-linux-ptrace.c: New file.
4927 * nat/aarch64-sve-linux-ptrace.h: New file.
4929 2018-05-31 Alan Hayward <alan.hayward@arm.com>
4931 * aarch64-linux-nat.c (aarch64_linux_read_description):
4933 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
4935 * aarch64-tdep.c (tdesc_aarch64_list): Add.
4936 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
4937 (aarch64_gdbarch_init): Add parmeter zero.
4938 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
4939 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
4940 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
4942 * doc/gdb.texinfo: Describe SVE feature
4943 * features/aarch64-sve.c: New file.
4945 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
4948 * gdbarch.sh (significant_addr_bit): Default to zero when
4949 not set by target architecture.
4950 * gdbarch.c: Re-generated.
4951 * utils.c (address_significant): Update.
4953 2018-05-30 Joel Brobecker <brobecker@adacore.com>
4955 * stack.c (func_command): Remove trailing newline in call to error.
4957 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4959 * regcache.h (regcache_raw_collect): Remove, update callers to
4960 use regcache::raw_collect.
4961 * regcache.c (regcache_raw_collect): Remove.
4963 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4965 * regcache.h (regcache_raw_supply): Remove, update callers to
4966 use detached_regcache::raw_supply.
4967 * regcache.c (regcache_raw_supply): Remove.
4969 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4971 * regcache.h (regcache_cooked_write_part): Remove, update
4972 callers to use regcache::cooked_write_part.
4973 * regcache.c (regcache_cooked_write_part): Remove.
4975 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4977 * regcache.h (regcache_cooked_read_part): Remove, update callers
4978 to use readable_regcache::cooked_read_part.
4979 * regcache.c (regcache_cooked_read_part): Remove.
4981 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4983 * regcache.h (regcache_cooked_read_value): Remove, update
4984 callers to use readable_regcache::cooked_read_value.
4985 * regcache.c (regcache_cooked_read_value): Remove.
4987 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4989 * regcache.h (regcache_cooked_write): Remove, update callers to
4990 use regcache::cooked_write.
4991 * regcache.c (regcache_cooked_write): Remove.
4993 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
4995 * regcache.h (regcache_invalidate): Remove, update callers to
4996 use detached_regcache::invalidate instead.
4997 * regcache.c (regcache_invalidate): Remove.
4999 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5001 * regcache.h (regcache_raw_write_part): Remove, update callers
5002 to use regcache::raw_write_part instead.
5003 * regcache.c (regcache_raw_write_part): Remove.
5005 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5007 * regcache.h (regcache_raw_read_part): Remove, update callers to
5008 use readable_regcache::raw_read_part instead.
5009 * regcache.c (regcache_raw_read_part): Remove.
5011 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5013 * regcache.h (regcache_cooked_read): Remove, update callers to
5014 use readable_regcache::cooked_read instead.
5015 * regcache.c (regcache_cooked_read): Remove.
5017 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5019 * regcache.h (regcache_raw_write): Remove, update callers to use
5020 regcache::raw_write instead.
5021 * regcache.c (regcache_raw_write): Remove.
5023 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5025 * regcache.h (regcache_raw_read): Remove, update callers to use
5026 readable_regcache::raw_read instead.
5027 * regcache.c (regcache_raw_read): Remove.
5029 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5031 * regcache.h (regcache_raw_update): Remove, update callers to
5032 use readable_regcache::raw_update instead.
5033 * regcache.c (regcache_raw_update): Remove.
5035 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5037 * regcache.h (regcache_register_status): Remove, update callers
5038 to use reg_buffer::get_register_status directly instead.
5039 * regcache.c (regcache_register_status): Remove.
5041 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5043 * regcache.h (regcache_get_ptid): Remove, update all callers to
5044 call regcache::ptid instead.
5045 * regcache.c (regcache_get_ptid): Remove.
5047 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5049 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5051 2018-05-30 Pedro Alves <palves@redhat.com>
5053 * common/common-exceptions.h (exception_rethrow): Use
5056 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5058 * breakpoint.c (print_solib_event, check_status_catch_solib):
5059 Remove struct keyword in range-based for loops.
5060 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5061 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5063 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5065 * symfile.c (addr_info_make_relative): Likewise.
5066 * thread.c (value_in_thread_stack_temporaries): Likewise.
5068 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
5071 * valops.c (value_struct_elt_for_reference): Call check_typedef on
5072 aggregate type to get its real type before accessing it.
5074 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
5076 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
5077 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
5078 * coff-pe-read.c (add_pe_forwarded_sym): Replace
5079 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
5080 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
5081 * jit.c (jit_breakpoint_re_set_internal): Likewise.
5082 * printcmd.c (info_address_command): Likewise.
5084 2018-05-29 Tom Tromey <tom@tromey.com>
5086 * windows-nat.c (handle_exception): Update fall-through comment.
5088 2018-05-29 Tom Tromey <tom@tromey.com>
5090 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
5091 (struct program_space) <added_solibs>: Now a std::vector.
5092 * breakpoint.c (print_solib_event): Update.
5093 (check_status_catch_solib): Update.
5094 * progspace.c (clear_program_space_solib_cache): Update.
5095 * solib.c (update_solib_list): Update.
5097 2018-05-29 Tom Tromey <tom@tromey.com>
5099 * python/py-type.c (typy_richcompare): Update.
5100 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
5101 * gdbtypes.h (types_deeply_equal): Return bool.
5102 (types_equal): Likewise.
5103 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
5105 (check_types_equal): Change worklist to std::vector. Return
5107 (struct type_equality_entry): Add constructor.
5108 (compare_maybe_null_strings): Return bool.
5109 (check_types_worklist): Return bool. Change worklist to
5111 (types_deeply_equal): Use std::vector.
5112 (types_equal): Return bool.
5113 (compare_maybe_null_strings): Simplify.
5115 2018-05-29 Tom Tromey <tom@tromey.com>
5117 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
5119 2018-05-29 Tom Tromey <tom@tromey.com>
5121 * objc-lang.h: Don't include cp-support.h.
5122 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
5125 2018-05-27 Tom Tromey <tom@tromey.com>
5127 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
5129 2018-05-25 Tom Tromey <tom@tromey.com>
5131 * value.c (value::location): Initialize.
5133 2018-05-25 Tom Tromey <tom@tromey.com>
5135 * dbxread.c (init_bincl_list): Remove.
5136 (bincl_list): Now a std::vector.
5137 (bincls_allocated, next_bincl): Remove.
5138 (free_bincl_list, do_free_bincl_list_cleanup)
5139 (make_cleanup_free_bincl_list): Remove.
5140 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
5142 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
5143 (struct header_file_location): Add constructor.
5144 (add_bincl_to_list): Remove.
5146 2018-05-25 Tom Tromey <tom@tromey.com>
5148 * tui/tui.c (tui_enable): Update.
5149 * mi/mi-interp.c (mi_interp::init): Update.
5150 * interps.h (class interp) <name>: New method.
5151 <m_name>: Rename from name.
5152 (~scoped_restore_interp): Update.
5153 * interps.c (interp::interp): Update.
5154 (interp_add, interp_set, interp_lookup_existing)
5155 (current_interp_named_p): Update.
5157 2018-05-25 Tom Tromey <tom@tromey.com>
5159 * interps.c (interp_name): Remove.
5160 * mi/mi-interp.c (mi_interp::init): Update.
5161 * interps.h (interp_name): Remove.
5162 (~scoped_restore_interp): Update.
5163 * tui/tui.c (tui_enable): Update.
5165 2018-05-25 Tom Tromey <tom@tromey.com>
5167 * utils.c (fputs_maybe_filtered): Update.
5168 * linespec.c (decode_line_full): Update.
5169 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
5170 (mi_print_breakpoint_for_event, mi_solib_loaded)
5171 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5172 (mi_user_selected_context_changed): Update.
5173 * mi/mi-main.c (mi_execute_command): Update.
5174 * cli/cli-script.c (execute_control_command): Update.
5175 * python/python.c (execute_gdb_command): Update.
5176 * solib.c (info_sharedlibrary_command): Update.
5177 * interps.c (interp_ui_out): Remove.
5178 * interps.h (interp_ui_out): Remove.
5180 2018-05-25 Tom Tromey <tom@tromey.com>
5182 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
5183 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
5184 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
5186 2018-05-25 Tom Tromey <tom@tromey.com>
5188 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
5189 * interps.c (interp_exec): Use scoped_restore.
5191 2018-05-25 Tom Tromey <tom@tromey.com>
5193 * remote.c (remote_target::remote_file_get): Use
5195 (remote_target::remote_file_put): Likewise.
5197 2018-05-25 Tom Tromey <tom@tromey.com>
5199 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
5201 (get_pe_section_index, add_pe_exported_sym): Update.
5202 (read_pe_exported_syms): Use gdb::def_vector.
5204 2018-05-25 Tom Tromey <tom@tromey.com>
5206 * frame.c (remove_prev_frame): Remove.
5207 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
5209 2018-05-25 Maciej W. Rozycki <macro@mips.com>
5211 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
5213 * mips-linux-nat.c (supply_fpregset): Always call
5214 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
5215 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
5216 `mips_fill_fpregset'.
5217 * mips-linux-tdep.c (mips_supply_fpregset)
5218 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
5219 (mips_fill_fpregset_wrapper): Remove functions.
5220 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
5221 (mips_linux_fpregset): Remove variable.
5222 (mips_linux_iterate_over_regset_sections): Use
5223 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
5224 (mips_linux_o32_sigframe_init): Remove comment.
5226 2018-05-25 Pedro Alves <palves@redhat.com>
5228 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
5229 (struct readahead_cache, struct packet_reg, struct
5230 remote_arch_state, class remote_state): Move higher up in the
5232 (remote_target::m_remote_state): Now an object instead of a pointer.
5233 (remote_target::get_remote_state): Adjust.
5235 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5237 * stack.c (select_and_print_frame): Delete.
5238 (struct function_bounds): Move struct within function.
5239 (func_command): Most content moved into new function
5240 find_frame_for_function, use new function, print result, add
5242 (find_frame_for_function): New function, now returns a result.
5244 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5246 * stack.c (iterate_over_block_arg_vars): Fix comment.
5247 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
5249 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
5253 (scoped_restore_selected_frame::scoped_restore_selected_frame):
5255 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
5257 * frame.h (class scoped_restore_selected_frame): New class.
5258 * stack.c (print_frame_local_vars): Remove catching and rethrowing
5259 of any exception, use scoped_restore_selected_frame to restore the
5262 2018-05-24 Pedro Alves <palves@redhat.com>
5264 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
5267 2018-05-23 Tom Tromey <tom@tromey.com>
5269 * complaints.c (struct complaints): Remove.
5270 (symfile_complaint_book): Remove.
5271 (series): New global.
5272 (complaint_internal): Update.
5273 (clear_complaints): Update.
5275 2018-05-23 Tom Tromey <tom@tromey.com>
5277 * complaints.c (counters): New global.
5278 (struct complain): Remove.
5279 (struct complaints) <root>: Remove.
5280 (complaint_sentinel): Remove.
5281 (symfile_complaint_book): Update.
5282 (find_complaint) Remove.
5283 (complaint_internal, clear_complaints): Update.
5285 2018-05-23 Tom Tromey <tom@tromey.com>
5287 * complaints.c (struct complain) <file, line>: Remove.
5288 (find_complaint): Remove file, line parameters.
5289 (complaint_internal): Update.
5291 2018-05-23 Tom Tromey <tom@tromey.com>
5293 * complaints.c (vcomplaint): Remove.
5294 (complaint_internal) Merge in contents of vcomplaint.
5296 2018-05-23 Tom Tromey <tom@tromey.com>
5298 * complaints.c (struct complaints) <explanation>: Remove.
5299 (symfile_explanations): Remove.
5300 (symfile_complaint_book): Update.
5301 (vcomplaint): Update.
5302 (struct explanation): Remove.
5304 2018-05-23 Tom Tromey <tom@tromey.com>
5306 * complaints.c (symfile_complaints): Remove.
5307 (complaint_internal): Remove "complaints" parameter.
5308 (clear_complaints, vcomplaint): Remove "c" parameter.
5309 (get_complaints): Remove.
5310 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
5311 (dwarf2_debug_line_missing_file_complaint)
5312 (dwarf2_debug_line_missing_end_sequence_complaint)
5313 (dwarf2_complex_location_expr_complaint)
5314 (dwarf2_const_value_length_mismatch_complaint)
5315 (dwarf2_section_buffer_overflow_complaint)
5316 (dwarf2_macro_malformed_definition_complaint)
5317 (dwarf2_invalid_attrib_class_complaint)
5318 (create_addrmap_from_index, dw2_symtab_iter_next)
5319 (dw2_expand_marked_cus)
5320 (dw2_debug_names_iterator::find_vec_in_debug_names)
5321 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
5322 (create_debug_type_hash_table, init_cutu_and_read_dies)
5323 (partial_die_parent_scope, add_partial_enumeration)
5324 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
5325 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
5326 (read_import_statement, read_file_scope, create_dwo_cu_reader)
5327 (create_cus_hash_table, create_dwp_hash_table)
5328 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
5329 (dwarf2_rnglists_process, dwarf2_ranges_process)
5330 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
5331 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
5332 (handle_struct_member_die, process_structure_scope)
5333 (read_array_type, read_common_block, read_module_type)
5334 (read_tag_pointer_type, read_typedef, read_base_type)
5335 (read_subrange_type, load_partial_dies, partial_die_info::read)
5336 (partial_die_info::read, partial_die_info::read)
5337 (partial_die_info::read, read_checked_initial_length_and_offset)
5338 (dwarf2_string_attr, read_formatted_entries)
5339 (dwarf_decode_line_header)
5340 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
5341 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
5342 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
5343 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
5344 (get_signatured_type, get_DW_AT_signature_type)
5345 (decode_locdesc, file_file_name, consume_improper_spaces)
5346 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
5347 (dwarf_decode_macro_bytes, dwarf_decode_macros)
5348 (dwarf2_symbol_mark_computed, set_die_type)
5349 (read_attribute_value): Update.
5350 * stap-probe.c (handle_stap_probe, get_stap_base_address):
5352 * dbxread.c (unknown_symtype_complaint)
5353 (lbrac_mismatch_complaint, repeated_header_complaint)
5354 (set_namestring, function_outside_compilation_unit_complaint)
5355 (read_dbx_symtab, process_one_symbol): Update.
5356 * gdbtypes.c (stub_noname_complaint): Update.
5357 * windows-nat.c (handle_unload_dll): Update.
5358 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
5359 (decode_base_type): Update.
5360 * xcoffread.c (bf_notfound_complaint, ef_complaint)
5361 (eb_complaint, record_include_begin, record_include_end)
5362 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
5363 (process_xcoff_symbol, read_symbol)
5364 (function_outside_compilation_unit_complaint)
5365 (scan_xcoff_symtab): Update.
5366 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
5367 * buildsym.c (finish_block_internal, make_blockvector)
5368 (end_symtab_get_static_block, augment_type_symtab): Update.
5369 * dtrace-probe.c (dtrace_process_dof)
5370 (dtrace_static_probe_ops::get_probes): Update.
5371 * complaints.h (struct complaint): Don't declare.
5372 (symfile_complaints): Remove.
5373 (complaint_internal): Remove "complaints" parameter.
5374 (complaint): Likewise.
5375 (clear_complaints): Likewise.
5376 * symfile.c (syms_from_objfile_1, finish_new_objfile)
5377 (reread_symbols): Update.
5378 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
5379 (dwarf2_frame_cache, decode_frame_entry): Update.
5380 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
5381 * objc-lang.c (lookup_objc_class, lookup_child_selector)
5382 (info_selectors_command): Update.
5383 * macrotab.c (macro_include, check_for_redefinition)
5384 (macro_undef): Update.
5385 * objfiles.c (filter_overlapping_sections): Update.
5386 * stabsread.c (invalid_cpp_abbrev_complaint)
5387 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
5388 (define_symbol, error_type, read_type, rs6000_builtin_type)
5389 (stabs_method_name_from_physname, read_member_functions)
5390 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
5391 (attach_fields_to_type, complain_about_struct_wipeout)
5392 (read_range_type, read_args, common_block_start)
5393 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
5395 * mdebugread.c (index_complaint, unknown_ext_complaint)
5396 (basic_type_complaint, bad_tag_guess_complaint)
5397 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
5398 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
5399 (parse_procedure, parse_lines)
5400 (function_outside_compilation_unit_complaint)
5401 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
5402 (bad_tag_guess_complaint, reg_value_complaint): Update.
5403 * cp-support.c (demangled_name_complaint): Update.
5404 * macroscope.c (sal_macro_scope): Update.
5405 * dwarf-index-write.c (class debug_names): Update.
5407 2018-05-23 Tom Tromey <tom@tromey.com>
5409 * complaints.c (clear_complaints): Remove "noisy" parameter.
5410 * complaints.h (clear_complaints): Update.
5411 * symfile.c (syms_from_objfile_1, finish_new_objfile)
5412 (reread_symbols): Update.
5414 2018-05-23 Tom Tromey <tom@tromey.com>
5416 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
5418 (vcomplaint, clear_complaints): Update.
5419 (symfile_explanations): Remove some messages.
5421 2018-05-23 Tom Tromey <tom@tromey.com>
5423 * complaints.c (internal_complaint): Remove.
5424 * complaints.h (internal_complaint): Remove.
5426 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5428 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
5430 2018-05-22 Pedro Alves <palves@redhat.com>
5432 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
5433 (remote_fileio_badfd, remote_fileio_return_errno)
5434 (remote_fileio_return_success, remote_fileio_func_open)
5435 (remote_fileio_func_open, remote_fileio_func_close)
5436 (remote_fileio_func_read, remote_fileio_func_write)
5437 (remote_fileio_func_lseek, remote_fileio_func_rename)
5438 (remote_fileio_func_unlink, remote_fileio_func_stat)
5439 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
5440 (remote_fileio_func_isatty, remote_fileio_func_system): Add
5441 remote_target parameter.
5442 (remote_fio_func_map) <func>: Add remote_target parameter.
5443 (do_remote_fileio_request, remote_fileio_request):
5444 * remote-fileio.h (remote_fileio_request):
5445 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
5446 remote_target parameter.
5447 (remote_notif_process, handle_notification): Adjust to pass down
5449 (remote_notif_state_allocate): Add remote_target parameter. Save
5451 * remote-notif.h (struct remote_target): Forward declare.
5452 (struct notif_client) <parse, ack, can_get_pending_events>: Add
5453 remote_target parameter.
5454 (struct remote_notif_state) <remote>: New field.
5455 (remote_notif_ack, remote_notif_parse): Add remote_target
5457 (remote_notif_state_allocate, remote_notif_state_allocate): Add
5458 remote_target parameter.
5459 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
5460 (threads_listing_context, rmt_thread_action, protocol_feature)
5461 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
5462 (packet_result, struct threads_listing_context, remote_state):
5463 Move definitions and declarations higher up.
5464 (remote_target) <~remote_target>: Declare.
5465 (remote_download_command_source, remote_file_put, remote_file_get)
5466 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
5467 (remote_hostio_pread_vFile, remote_hostio_send_command)
5468 (remote_hostio_set_filesystem, remote_hostio_open)
5469 (remote_hostio_close, remote_hostio_unlink, remote_state)
5470 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
5471 (get_memory_write_packet_size, get_memory_read_packet_size)
5472 (append_pending_thread_resumptions, remote_detach_1)
5473 (append_resumption, remote_resume_with_vcont)
5474 (add_current_inferior_and_thread, wait_ns, wait_as)
5475 (process_stop_reply, remote_notice_new_inferior)
5476 (process_initial_stop_replies, remote_add_thread)
5477 (btrace_sync_conf, remote_btrace_maybe_reopen)
5478 (remove_new_fork_children, kill_new_fork_children)
5479 (discard_pending_stop_replies, stop_reply_queue_length)
5480 (check_pending_events_prevent_wildcard_vcont)
5481 (discard_pending_stop_replies_in_queue, stop_reply)
5482 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
5483 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
5484 (remote_interrupt_as, remote_interrupt_ns)
5485 (remote_get_noisy_reply, remote_query_attached)
5486 (remote_add_inferior, remote_current_thread, get_current_thread)
5487 (set_thread, set_general_thread, set_continue_thread)
5488 (set_general_process, write_ptid)
5489 (remote_unpack_thread_info_response, remote_get_threadinfo)
5490 (parse_threadlist_response, remote_get_threadlist)
5491 (remote_threadlist_iterator, remote_get_threads_with_ql)
5492 (remote_get_threads_with_qxfer)
5493 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
5494 (get_offsets, remote_check_symbols, remote_supported_packet)
5495 (remote_query_supported, remote_packet_size)
5496 (remote_serial_quit_handler, remote_detach_pid)
5497 (remote_vcont_probe, remote_resume_with_hc)
5498 (send_interrupt_sequence, interrupt_query)
5499 (remote_notif_get_pending_events, fetch_register_using_p)
5500 (send_g_packet, process_g_packet, fetch_registers_using_g)
5501 (store_register_using_P, store_registers_using_G)
5502 (set_remote_traceframe, check_binary_download)
5503 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
5504 (remote_xfer_live_readonly_partial, remote_read_bytes)
5505 (remote_send_printf, remote_flash_write, readchar)
5506 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
5507 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
5508 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
5509 (extended_remote_disable_randomization, extended_remote_run)
5510 (send_environment_packet, extended_remote_environment_support)
5511 (extended_remote_set_inferior_cwd, remote_write_qxfer)
5512 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
5513 (packet_command): Now methods of ...
5514 (remote_target): ... this class.
5515 (m_remote_state) <remote_target>: New field.
5516 (struct remote_state) <stop_reply_queue,
5517 remote_async_inferior_event_token, wait_forever_enabled_p>: New
5519 (remote_state::remote_state): Allocate stop_reply_queue.
5520 (remote_state): Delete global.
5521 (get_remote_state_raw): Delete.
5522 (remote_target::get_remote_state): Allocate m_remote_state on
5524 (get_current_remote_target): New.
5525 (remote_ops, extended_remote_ops): Delete.
5526 (wait_forever_enabled_p, remote_async_inferior_event_token):
5527 Delete, moved to struct remote_state.
5528 (remote_target::close): Delete self. Destruction bits split to
5530 (remote_target::~remote_target): ... this.
5531 (show_memory_packet_size): Adjust to use
5532 get_current_remote_target.
5533 (struct protocol_feature) <func>: Add remote_target parameter.
5534 All callers adjusted.
5535 (curr_quit_handler_target): New.
5536 (remote_serial_quit_handler): Reimplement.
5537 (remote_target::open_1): Adjust to use get_current_remote_target.
5538 Heap-allocate remote_target/extended_remote_target instances.
5539 (vcont_builder::vcont_builder): Add remote_target parameter, and
5540 save it in m_remote. All callers adjusted.
5541 (vcont_builder::m_remote): New field.
5542 (vcont_builder::restart, vcont_builder::flush)
5543 (vcont_builder::push_action): Use it.
5544 (remote_target::commit_resume): Use it.
5545 (struct queue_iter_param) <remote>: New field.
5546 (remote_target::remove_new_fork_children): Fill in 'remote' field.
5547 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
5548 (check_pending_event_prevents_wildcard_vcont_callback)
5549 (remote_target::check_pending_events_prevent_wildcard_vcont)
5550 (remote_target::discard_pending_stop_replies)
5551 (remote_target::discard_pending_stop_replies_in_queue)
5552 (remote_target::remote_notif_remove_queued_reply): Fill in
5554 (remote_notif_get_pending_events): New.
5555 (remote_target::readchar, remote_target::remote_serial_write):
5556 Save/restore curr_quit_handler_target.
5558 (kill_new_fork_children): Fill in 'remote' field.
5559 (packet_command): Use get_current_remote_target, defer to
5560 remote_target method of same name.
5561 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
5562 parameter, and save it in m_remote. All callers adjusted.
5563 (scoped_remote_fd::release): Use m_remote.
5564 (scoped_remote_fd::m_remote): New field.
5565 (remote_file_put, remote_file_get, remote_file_delete): Use
5566 get_current_remote_target, defer to remote_target method of same
5568 (remote_btrace_reset): Add remote_state paremeter. Update all
5570 (remote_async_inferior_event_handler). Pass down 'data'.
5571 (remote_new_objfile): Use get_current_remote_target.
5572 (remote_target::vcont_r_supported): New.
5573 (set_range_stepping): Use get_current_remote_target and
5574 remote_target::vcont_r_supported.
5575 (_initialize_remote): Don't allocate 'remote_state' and
5576 'stop_reply_queue' globals.
5577 * remote.h (struct remote_target): Forward declare.
5578 (getpkt, putpkt, remote_notif_get_pending_events): Add
5579 'remote_target' parameter.
5581 2018-05-22 Pedro Alves <palves@redhat.com>
5583 * remote.c (vcont_builder): Now a class. Make all data members
5585 (vcont_builder) <vcont_builder, restart, flush, push_action>:
5587 (vcont_builder_restart): Rename to ...
5588 (vcont_builder::restart): ... this.
5589 (vcont_builder_flush): Rename to ...
5590 (vcont_builder::flush): ... this.
5591 (vcont_builder_push_action): Rename to ...
5592 (vcont_builder::push_action): ... this.
5593 (remote_target::commit_resume): Adjust.
5595 2018-05-22 Pedro Alves <palves@redhat.com>
5597 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
5598 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
5599 (get_fixed_memory_packet_size): New.
5600 (get_memory_packet_size): Use it.
5601 (set_memory_packet_size): Don't override the config size with
5602 DEFAULT_MAX_MEMORY_PACKET_SIZE.
5603 (show_memory_packet_size): Use get_fixed_memory_packet_size.
5604 Don't refer to get_memory_packet_size if not connected to a remote
5605 target. Show "(default)" if configured size is 0.
5607 2018-05-22 Pedro Alves <palves@redhat.com>
5609 * remote.c (remote_target::mourn_inferior): Move
5610 discard_pending_stop_replies call here from ...
5611 (_initialize_remote): ... here.
5613 2018-05-22 Pedro Alves <palves@redhat.com>
5615 * remote.c (compare_section_command): Remove set_general_process
5618 2018-05-22 Pedro Alves <palves@redhat.com>
5620 * remote.c (struct packet_reg, struct remote_arch_state):
5621 Move higher up in the file.
5622 (remote_state) <m_arch_states>: Store remote_arch_state values
5623 instead of remote_arch_state pointers.
5624 (remote_state::get_remote_arch_state): Adjust.
5626 2018-05-22 Pedro Alves <palves@redhat.com>
5628 * remote.c: Include <unordered_map>.
5629 (remote_state): Now a class.
5630 (remote_state) <get_remote_arch_state>: Declare method.
5631 <get_remote_arch_state>: New field.
5632 (remote_arch_state) <remote_arch_state>: Declare ctor.
5633 <regs>: Now a unique_ptr.
5634 (remote_gdbarch_data_handle): Delete.
5635 (get_remote_arch_state): Delete.
5636 (remote_state::get_remote_arch_state): New.
5637 (get_remote_state): Adjust to call remote_state's
5638 get_remote_arch_state method.
5639 (init_remote_state): Delete, bits factored out to ...
5640 (remote_arch_state::remote_arch_state): ... this new method.
5641 (get_remote_packet_size, get_memory_packet_size)
5642 (process_g_packet, remote_target::fetch_registers)
5643 (remote_target::prepare_to_store, store_registers_using_G)
5644 (remote_target::store_registers, remote_target::get_trace_status):
5645 Adjust to call remote_state's method.
5646 (_initialize_remote): Remove reference to
5647 remote_gdbarch_data_handle.
5649 2018-05-22 Pedro Alves <palves@redhat.com>
5651 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
5652 pread>: New method declarations.
5653 (remote_target::open_1): Adjust.
5654 (readahead_cache_invalidate): Rename to ...
5655 (readahead_cache::invalidate): ... this, and adjust to be a class
5657 (readahead_cache_invalidate_fd): Rename to ...
5658 (readahead_cache::invalidate_fd): ... this, and adjust to be a
5660 (remote_hostio_pwrite): Adjust.
5661 (remote_hostio_pread_from_cache): Rename to ...
5662 (readahead_cache::pread): ... this, and adjust to be a class
5664 (remote_hostio_close): Adjust.
5666 2018-05-22 Pedro Alves <palves@redhat.com>
5668 * remote.c (remote_hostio_close_cleanup): Delete.
5669 (class scoped_remote_fd): New.
5670 (remote_file_put, remote_file_get): Use it.
5672 2018-05-22 Pedro Alves <palves@redhat.com>
5674 (struct vCont_action_support): Use bool and initialize all fields.
5675 (struct readahead_cache): Initialize all fields.
5676 (remote_state): Use bool and initialize all fields.
5677 (remote_state::remote_state, remote_state::~remote_state): New.
5678 (new_remote_state): Delete.
5679 (_initialize_remote): Use new to allocate remote_state.
5681 2018-05-22 Pedro Alves <palves@redhat.com>
5685 * c-exp.y: Include "c-support.h".
5686 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
5687 of tolower. Use c_ident_is_alpha to scan names.
5688 * c-lang.c: Include "c-support.h".
5689 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
5690 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
5691 * c-support.h: New file, with bits factored out from ...
5692 * cp-name-parser.y: ... this file.
5693 Include "c-support.h".
5694 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
5695 c-support.h and renamed.
5696 (symbol_end, yylex): Adjust.
5698 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5700 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
5701 parameter type to CORE_ADDR.
5702 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
5703 parameter type in declaration to CORE_ADDR.
5704 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
5705 target_auxv_search to get AT_HWCAP and use the result to get the
5707 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
5708 to CORE_ADDR. Remove the cast of the return value to unsigned
5709 long. Fix error predicate of target_auxv_search.
5710 (ppc_linux_nat_target::read_description): Change the type of the
5711 hwcap variable to CORE_ADDR.
5713 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5715 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
5716 if the size of fpscr is larger than 32 bits.
5718 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5720 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
5721 (ppc32_linux_vsxregmap): New global.
5722 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
5723 regcache_supply_regset, and regcache_collect_regset.
5724 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
5725 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
5726 (fetch_vsx_register, store_vsx_register): Remove.
5727 (fetch_vsx_registers): Add regno parameter. Get regset using
5728 ppc_linux_vsxregset. Use regset to supply registers.
5729 (store_vsx_registers): Add regno parameter. Get regset using
5730 ppc_linux_vsxregset. Use regset to collect registers.
5731 (fetch_register): Call fetch_vsx_registers instead of
5733 (store_register): Call store_vsx_registers instead of
5735 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
5736 new regno parameter.
5737 (store_ppc_registers): Call store_vsx_registers with -1 for the
5738 new regno parameter.
5739 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
5740 (ppc_collect_vsxregset): Remove.
5742 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5744 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
5746 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
5747 for vector register offset fields.
5748 (ppc64_fbsd_reg_offsets): Likewise.
5749 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
5750 to vector register offset fields.
5751 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
5752 to vector register offset fields.
5753 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
5754 vector register offset fields.
5755 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
5756 initializers for vector register offset fields.
5757 (rs6000_aix64_reg_offsets): Likewise.
5758 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
5759 (ppc_supply_vrregset): Remove.
5760 (ppc_collect_vrregset): Remove.
5761 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
5762 (ppc_linux_vrregset) : New function.
5763 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
5764 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
5765 (ppc32_linux_vrregset): Remove.
5766 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
5767 and use result instead of ppc32_linux_vrregset.
5768 (ppc32_linux_reg_offsets): Remove initializers for vector register
5770 (ppc64_linux_reg_offsets): Likewise.
5771 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
5772 * ppc-linux-nat.c: Include regset.h.
5773 (gdb_vrregset_t): Adjust comment to account for little-endian
5775 (supply_vrregset, fill_vrregset): Remove.
5776 (fetch_altivec_register, store_altivec_register): Remove.
5777 (fetch_altivec_registers): Add regno parameter. Get regset using
5778 ppc_linux_vrregset. Use regset to supply registers.
5779 (store_altivec_registers): Add regno parameter. Get regset using
5780 ppc_linux_vrregset. Use regset to collect registers.
5781 (fetch_register): Call fetch_altivec_registers instead of
5782 fetch_altivec_register.
5783 (store_register): Call store_altivec_registers instead of
5784 store_altivec_register.
5785 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
5786 the new regno parameter.
5787 (store_ppc_registers): Call store_altivec_registers with -1 for
5788 the new regno parameter.
5790 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5792 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
5793 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
5794 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
5795 (gdb_vrregset_t): Change array type size to
5796 PPC_LINUX_SIZEOF_VRREGSET.
5797 (gdb_vsxregset_t): Change array type size to
5798 PPC_LINUX_SIZEOF_VSXREGSET.
5799 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
5800 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
5801 PPC_LINUX_SIZEOF_VSXREGSET.
5803 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5805 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
5806 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
5808 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
5809 ppc_linux_target_wordsize with tid.
5810 (ppc_linux_nat_target::read_description): Call ppc_linux_target
5812 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
5813 (ppc64_64bit_inferior_p): Add static and inline specifiers.
5814 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
5815 tid parameter. Remove static specifier.
5816 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
5817 (ppc_linux_target_wordsize): New declaration.
5819 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5821 * arch/ppc-linux-common.c: New file.
5822 * arch/ppc-linux-common.h: New file.
5823 * arch/ppc-linux-tdesc.h: New file.
5824 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
5825 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
5826 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
5827 arch/ppc-linux-tdesc.h.
5828 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
5829 arch/ppc-linux-tdesc.h.
5830 (ppc_linux_nat_target::read_description): Remove target
5831 description matching code. Fill a ppc_linux_features struct and
5832 call ppc_linux_match_description with it. Move comment about ISA
5833 2.05 to ppc-linux-common.c.
5834 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
5835 arch/ppc-linux-tdesc.h.
5836 (ppc_linux_core_read_description): Remove target description
5837 matching code. Fill a ppc_linux_features struct and call
5838 ppc_linux_match_description with it.
5839 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
5840 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
5841 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
5842 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
5843 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
5844 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
5845 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
5846 (tdesc_powerpc_e500l): Remove.
5848 2018-05-22 Joel Brobecker <brobecker@adacore.com>
5850 * ada-lang.c (catch_assert_command): Pass empty string instead
5851 of NULL for excep_string argument.
5853 2018-05-22 Maciej W. Rozycki <macro@mips.com>
5855 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
5856 the width of the requested register exceeds the width of the
5859 2018-05-21 Tom Tromey <tom@tromey.com>
5861 * printcmd.c (output_command): Remove.
5862 (output_command_const): Rename to output_command.
5863 * valprint.h (output_command): Rename from output_command_const.
5864 * tracepoint.c (trace_dump_actions): Call output_command.
5866 2018-05-21 Tom Tromey <tom@tromey.com>
5868 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5869 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
5870 * ada-lang.h (create_ada_exception_catchpoint): Update.
5871 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
5873 (create_excep_cond_exprs, ~ada_catchpoint)
5874 (should_stop_exception, print_one_exception)
5875 (print_mention_exception, print_recreate_exception): Update.
5876 (ada_get_next_arg): Remove.
5877 (catch_ada_exception_command_split): Use std::string. Change type
5878 of "excep_string", "cond_string".
5879 (catch_ada_exception_command): Update.
5880 (create_ada_exception_catchpoint): Change type of excep_string.
5881 (ada_exception_sal): Remove excep_string parameter.
5882 (~ada_catchpoint): Remove.
5884 2018-05-21 Tom Tromey <tom@tromey.com>
5886 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
5889 2018-05-21 Tom Tromey <tom@tromey.com>
5891 * ada-lang.c (ada_exception_message_1, ada_exception_message):
5892 Return unique_xmalloc_ptr.
5893 (print_it_exception): Update.
5895 2018-05-21 Tom Tromey <tom@tromey.com>
5897 * tracepoint.c (trace_dump_actions): Use std::string.
5899 2018-05-21 Tom Tromey <tom@tromey.com>
5901 * symfile.c (reread_symbols): Use std::string for original_name.
5903 2018-05-21 Tom Tromey <tom@tromey.com>
5905 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
5906 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
5909 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
5911 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
5913 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
5914 * objfiles.c (get_objfile_bfd_data): Allocate
5915 objfile_per_bfd_storage with obstack_new when allocating on
5918 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5920 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
5922 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
5923 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
5924 * mdebugread.c (mdebug_build_psymtabs): Likewise.
5925 (add_pending): Likewise.
5926 (parse_symbol): Likewise.
5927 (parse_partial_symbols): Likewise.
5928 (psymtab_to_symtab_1): Likewise.
5929 (new_psymtab): Likewise.
5930 (elfmdebug_build_psymtabs): Likewise.
5931 * minsyms.c (terminate_minimal_symbol_table): Likewise.
5932 * objfiles.c (get_objfile_bfd_data): Likewise.
5933 (objfile_register_static_link): Likewise.
5934 * psymtab.c (allocate_psymtab): Likewise.
5935 * stabsread.c (read_member_functions): Likewise.
5936 * xcoffread.c (xcoff_end_psymtab): Likewise.
5938 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
5940 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
5941 compiler supports std::is_trivially_constructible.
5942 * common/poison.h: Include obstack.h.
5943 (IsMallocable): Define to is_trivially_constructible if the
5944 compiler supports it, define to true_type otherwise.
5948 (XOBNEWVEC): Redefine.
5949 * gdb_obstack.h (obstack_zalloc): New.
5950 (OBSTACK_ZALLOC): Redefine.
5951 (obstack_calloc): New.
5952 (OBSTACK_CALLOC): Redefine.
5954 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
5955 (gdbarch_obstack): New declaration in gdbarch.h, definition in
5957 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
5958 obstack_calloc/obstack_zalloc.
5959 (gdbarch_obstack_zalloc): Remove.
5960 * target-descriptions.c (tdesc_data_init): Use obstack_new.
5962 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5964 * stack.c (backtrace_command_1): Remove useless variable int i.
5966 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5968 * stack.c (print_frame_info): Fix comment.
5970 2018-05-18 Tom Tromey <tom@tromey.com>
5972 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
5973 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
5974 (~dwarf2_per_objfile): Update
5975 (dwarf2_get_dwz_file): Use new.
5976 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
5979 2018-05-18 Tom Tromey <tom@tromey.com>
5981 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
5983 * dwarf2read.c (struct dwp_file): Add constructor and
5985 (open_and_init_dwp_file): Return a unique_ptr.
5986 (dwarf2_per_objfile, create_dwp_hash_table)
5987 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
5988 (lookup_dwo_unit_in_dwp): Update.
5989 (open_and_init_dwp_file, get_dwp_file): Update.
5991 2018-05-18 Tom Tromey <tom@tromey.com>
5993 * dwarf2read.c (dwarf2_per_objfile): Update.
5994 (struct mapped_index): Add initializers.
5995 (dwarf2_read_index): Use new.
5996 (dw2_symtab_iter_init): Update.
5997 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6000 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6002 * dwarf2read.c (mapped_index) <total_size>: Remove.
6004 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6006 * unittests/format_pieces-selftests.c (test_format_specifier):
6009 2018-05-18 Tom Tromey <tom@tromey.com>
6011 * c-typeprint.c (maybe_print_hole): New function.
6012 (c_print_type_struct_field_offset): Update.
6013 (c_type_print_base_struct_union): Call maybe_print_hole.
6015 2018-05-17 Keith Seitz <keiths@redhat.com>
6017 * breakpoint.c (build_bpstat_chain): New function, moved from
6019 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6020 If no stop chain is passed, call build_bpstat_chain to build it.
6021 * breakpoint.h (build_bpstat_chain): Declare.
6022 (bpstat_stop_status): Move documentation here from breakpoint.c.
6023 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6024 build the stop chain and pass it to skip_inline_frames.
6025 Pass this stop chain to bpstat_stop_status.
6026 * inline-frame.c: Include breakpoint.h.
6027 (stopped_by_user_bp_inline_frame): New function.
6028 (skip_inline_frames): Add parameter `stop_chain'.
6029 Move documention to inline-frame.h.
6030 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6031 whether the frame should be elided.
6032 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6033 Add moved documentation and update for new parameter.
6035 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6038 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6039 unittests/format_pieces-selftests.c.
6040 * common/format.h (format_piece) <operator==>: New.
6041 (format_pieces) <operator[]>: Remove.
6042 * common/format.c (format_pieces::format_pieces): Handle \e.
6043 * unittests/format_pieces-selftests.c: New.
6045 2018-05-17 Tom Tromey <tom@tromey.com>
6048 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6049 (dw2_instantiate_symtab): Add skip_partial parameter.
6050 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6051 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6052 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6053 (dw2_expand_symtabs_matching_one)
6054 (dw2_find_pc_sect_compunit_symtab)
6055 (dw2_debug_names_lookup_symbol)
6056 (dw2_debug_names_expand_symtabs_for_function): Update.
6057 (init_cutu_and_read_dies): Add skip_partial parameter.
6058 (process_psymtab_comp_unit, build_type_psymtabs_1)
6059 (process_skeletonless_type_unit, load_partial_comp_unit)
6060 (psymtab_to_symtab_1): Update.
6061 (load_full_comp_unit): Add skip_partial parameter.
6062 (process_imported_unit_die, dwarf2_read_addr_index)
6063 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6064 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
6065 (read_signatured_type): Update.
6067 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6069 * value.c (release_value): Remove unused variable.
6070 (record_latest_value): Likewise.
6071 (access_value_history): Likewise.
6072 (preserve_values): Likewise.
6074 2018-05-17 Tom Tromey <tom@tromey.com>
6076 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
6079 2018-05-16 Maciej W. Rozycki <macro@mips.com>
6082 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
6083 Also handle registers whose width is not a multiple of
6085 (linux_nat_trad_target::store_register): Likewise.
6087 2018-05-16 Tom Tromey <tom@tromey.com>
6089 * gdbcore.h (core_bfd): Redefine.
6090 * corelow.c (core_target::close): Update.
6091 (core_target_open): Update.
6092 * progspace.h (struct program_space) <cbfd>: Now a
6095 2018-05-16 Tom Tromey <tom@tromey.com>
6098 * symfile-add-flags.h (enum symfile_add_flags)
6099 <SYMFILE_NOT_FILENAME>: New constant.
6100 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
6101 objfile name from BFD.
6102 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
6103 * minidebug.c (find_separate_debug_file_in_section): Put
6104 ".gnu_debugdata" into BFD's file name.
6106 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
6108 * regcache.c (regcache_read_ftype, regcache_write_ftype):
6111 2018-05-15 Tamar Christina <tamar.christina@arm.com>
6114 * aarch64-tdep.c (aarch64_analyze_prologue,
6115 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
6116 Indicate not interested in errors.
6118 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6120 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
6121 Supply the MIPS_ZERO_REGNUM register.
6123 2018-05-15 Maciej W. Rozycki <macro@mips.com>
6125 * mips-tdep.c (mask_address_var): Make variable static.
6127 2018-05-14 Tom Tromey <tom@tromey.com>
6129 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
6131 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
6133 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
6134 FXSAVE_ADDR for the mxcsr register.
6136 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
6138 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
6140 2018-05-11 Pedro Alves <palves@redhat.com>
6142 * corelow.c (core_target) <core_target>: No longer inline.
6143 Initialize m_core_gdbarch, m_core_vec and build the section table
6145 <~core_target>: New.
6146 <core_gdbarch, get_core_register_section>: New methods.
6147 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
6148 factored out from ...
6149 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
6151 (sniff_core_bfd): Add gdbarch parameter.
6152 (core_close): Delete, merged into ...
6153 (core_target::close): ... here. Delete self.
6154 (core_close_cleanup): Delete.
6155 (core_target_open): Allocate a core_target on the heap. Use a
6156 unique_ptr instead of a cleanup. Bits moved into the core_target
6157 ctor. Adjust to use core_target methods instead of globals.
6158 (get_core_register_section): Rename to ...
6159 (core_target::get_core_register_section): ... this and adjust.
6160 (struct get_core_registers_cb_data): New.
6161 (get_core_registers_cb): Use it. Use bool.
6162 (core_target::fetch_registers, core_target::files_info)
6163 (core_target::xfer_partial, core_target::read_description)
6164 (core_target::pid_to, core_target::thread_name): Adjust to
6165 reference class fields instead of globals.
6166 * target.h (struct target_ops_deleter, target_ops_up): New.
6168 2018-05-11 Pedro Alves <palves@redhat.com>
6170 * corefile.c (core_file_command): Move to corelow.c.
6171 * corelow.c (the_core_target): Delete.
6172 (core_file_command): Moved from corefile.c. Check exec_bfd
6173 instead of the_core_target. Use target_detach instead of calling
6174 into the_core_target directly.
6175 (maybe_say_no_core_file_now): New.
6176 (core_target::detach): Use it.
6177 (_initialize_corelow): Remove references to the_core_target.
6178 * gdbcore.h (the_core_target): Delete.
6180 2018-05-11 Tom Tromey <tromey@redhat.com>
6181 Pedro Alves <palves@redhat.com>
6183 * corefile.c (core_bfd): Remove.
6184 * gdbcore.h (core_bfd): Now a macro.
6185 * progspace.h (struct program_space) <cbfd>: New field.
6187 2018-05-11 Tom Tromey <tom@tromey.com>
6189 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
6192 2018-05-10 Tom Tromey <tom@tromey.com>
6194 * configure: Rebuild.
6195 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
6197 2018-05-10 Joel Brobecker <brobecker@adacore.com>
6200 * regformats/regdat.sh: Adjust script, following the addition
6201 of the new expedite_regs parameter to init_target_desc.
6203 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
6206 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
6207 set_gdbarch_significant_addr_bit.
6208 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
6209 set_gdbarch_significant_addr_bit.
6210 * utils.c (address_significant): Update to sign extend addr.
6212 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
6214 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
6215 (xtensa_linux_init_abi): Limit tdep->num_regs by
6216 tdep->num_nopriv_regs.
6217 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
6218 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
6221 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
6223 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
6225 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
6227 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
6228 (I387_MXCSR_INIT_VAL): New constant.
6229 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
6230 buffer if it was supplied by the inferior.
6231 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
6232 (i387_xsave_get_clear_bv): New function.
6233 (i387_supply_xsave): Only read x87 control registers from the
6234 xsave buffer if the feature is enabled, and the state will have
6235 been written, otherwise, provide a suitable default.
6236 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
6237 including x87 control registers. Update control registers if they
6238 have changed from the default value, and mark features as enabled
6240 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
6242 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
6244 * spu-tdep.c (info_spu_event_command): Fix output formatting.
6246 2018-05-07 Tom Tromey <tom@tromey.com>
6248 * configure: Rebuild.
6249 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
6251 2018-05-07 Tom Tromey <tom@tromey.com>
6254 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
6255 bit. Use correct value for VDIV.
6257 2018-05-04 Tom Tromey <tom@tromey.com>
6259 * configure: Rebuild.
6260 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
6262 2018-05-04 Tom Tromey <tom@tromey.com>
6264 * linux-record.c (record_linux_system_call) <case
6265 RECORD_SYS_RECVFROM>: Add "break".
6267 2018-05-04 Tom Tromey <tom@tromey.com>
6269 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
6270 Add missing "break".
6271 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
6272 Add missing "break".
6274 2018-05-04 Tom Tromey <tom@tromey.com>
6276 * rs6000-tdep.c (ppc_process_record_op4)
6277 (ppc_process_record_op63): Add fall-through comment.
6279 2018-05-04 Tom Tromey <tom@tromey.com>
6281 * i386-tdep.c (i386_process_record): Add fall-through comment.
6283 2018-05-04 Tom Tromey <tom@tromey.com>
6285 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
6288 2018-05-04 Tom Tromey <tom@tromey.com>
6290 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
6291 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
6292 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
6294 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
6296 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
6299 2018-05-04 Tom Tromey <tom@tromey.com>
6301 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
6303 2018-05-04 Tom Tromey <tom@tromey.com>
6305 * s390-tdep.c (s390_process_record): Fix fall-through comments.
6306 * xcoffread.c (scan_xcoff_symtab): Move comment later.
6307 * symfile.c (section_is_mapped): Fix fall-through comment.
6308 * stabsread.c (define_symbol, read_member_functions): Fix
6309 fall-through comment.
6310 * s390-linux-tdep.c (s390_process_record): Fix fall-through
6312 * remote.c (remote_wait_as): Fix fall-through comment.
6313 * p-exp.y (yylex): Fix fall-through comment.
6314 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
6316 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
6317 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
6318 * jv-exp.y (yylex): Fix fall-through comment.
6319 * go-exp.y (lex_one_token): Fix fall-through comment.
6320 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
6321 fall-through comment.
6322 * f-exp.y (yylex): Fix fall-through comment.
6323 * dwarf2read.c (process_die): Fix fall-through comments.
6324 * dbxread.c (process_one_symbol): Fix fall-through comment.
6325 * d-exp.y (lex_one_token): Fix fall-through comment.
6326 * cp-name-parser.y (yylex): Fix fall-through comment.
6327 * coffread.c (coff_symtab_read): Fix fall-through comment.
6328 * c-exp.y (lex_one_token): Fix fall-through comment.
6329 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
6331 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
6334 2018-05-04 Tom Tromey <tom@tromey.com>
6337 * NEWS: Mention gdb.execute change.
6338 * gdbcmd.h (execute_control_command): Don't declare.
6339 * python/python.c (execute_gdb_command): Use read_command_lines_1,
6340 execute_control_commands, execute_control_commands_to_string.
6341 * cli/cli-script.h (execute_control_commands)
6342 (execute_control_commands_to_string): Declare.
6343 (execute_control_command): Add from_tty parameter.
6344 * cli/cli-script.c (execute_control_commands)
6345 (execute_control_commands_to_string): New functions.
6346 (execute_user_command): Use execute_control_commands.
6347 (execute_control_command_1): Add "from_tty" parameter. Update.
6348 (execute_control_command): Likewise.
6350 2018-05-04 Tom Tromey <tom@tromey.com>
6353 * NEWS: Mention that breakpoint commands are writable.
6354 * python/py-breakpoint.c (bppy_set_commands): New function.
6355 (breakpoint_object_getset) <"commands">: Use it.
6357 2018-05-04 Tom Tromey <tom@tromey.com>
6359 * tracepoint.c (actions_command): Update.
6360 * mi/mi-cmd-break.c (mi_command_line_array)
6361 (mi_command_line_array_cnt, mi_command_line_array_ptr)
6362 (mi_read_next_line): Remove.
6363 (mi_cmd_break_commands): Update.
6364 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
6366 * cli/cli-script.c (get_command_line): Update.
6367 (process_next_line): Use function_view. Constify.
6368 (recurse_read_control_structure, read_command_lines)
6369 (read_command_lines_1): Change argument types to function_view.
6370 (do_define_command, document_command): Update.
6371 * breakpoint.h (check_tracepoint_command): Don't declare.
6372 * breakpoint.c (check_tracepoint_command): Remove.
6373 (commands_command_1, create_tracepoint_from_upload): Update.
6375 2018-05-04 Tom Tromey <tom@tromey.com>
6378 * cli/cli-script.h (enum command_control_type) <define_control>:
6380 * cli/cli-script.c (multi_line_command_p): Handle define_control.
6381 (build_command_line, execute_control_command_1)
6382 (process_next_line): Likewise.
6383 (do_define_command): New function, extracted from define_command.
6384 (define_command): Use it.
6386 2018-05-04 Tom Tromey <tom@tromey.com>
6388 * tracepoint.c (actions_command): Update.
6389 * cli/cli-script.h (read_command_lines): Update.
6390 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
6391 (MAX_TMPBUF): Remove define.
6392 (define_command): Use string_printf.
6393 (document_command): Likewise.
6394 * breakpoint.c (commands_command_1): Update.
6396 2018-05-04 Tom Tromey <tom@tromey.com>
6398 * top.c (execute_command): Update.
6399 * cli/cli-script.h (print_command_lines): Now varargs.
6400 * cli/cli-script.c (print_command_lines): Now varargs.
6401 (execute_control_command_1) <case while_control, case if_control>:
6404 2018-05-04 Tom Tromey <tom@tromey.com>
6406 * tracepoint.c (all_tracepoint_actions): Rename from
6407 all_tracepoint_actions_and_cleanup. Change return type.
6408 (actions_command, encode_actions_1, encode_actions)
6409 (trace_dump_actions, tdump_command): Update.
6410 * remote.c (remote_download_command_source): Update.
6411 * python/python.c (gdbpy_eval_from_control_command)
6412 (python_command, python_interactive_command): Update.
6413 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
6414 * guile/guile.c (guile_command)
6415 (gdbscm_eval_from_control_command, guile_command): Update.
6416 * compile/compile.c (compile_code_command)
6417 (compile_print_command, compile_to_object): Update.
6418 * cli/cli-script.h (struct command_lines_deleter): New.
6419 (counted_command_line): New typedef.
6420 (struct command_line): Add constructor, destructor.
6421 <body_list>: Remove.
6422 <body_list_0, body_list_1>: New members.
6423 (command_line_up): Remove typedef.
6424 (read_command_lines, read_command_lines_1, get_command_line):
6426 (copy_command_lines): Don't declare.
6427 * cli/cli-script.c (build_command_line): Use "new".
6428 (get_command_line): Return counted_command_line.
6429 (print_command_lines, execute_user_command)
6430 (execute_control_command_1, while_command, if_command): Update.
6431 (realloc_body_list): Remove.
6432 (process_next_line, recurse_read_control_structure): Update.
6433 (read_command_lines, read_command_lines_1): Return counted_command_line.
6434 (free_command_lines): Use "delete".
6435 (copy_command_lines): Remove.
6436 (define_command, document_command, show_user_1): Update.
6437 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
6438 a counted_command_line.
6439 * breakpoint.h (counted_command_line): Remove typedef.
6440 (breakpoint_set_commands): Update.
6441 * breakpoint.c (check_no_tracepoint_commands)
6442 (validate_commands_for_breakpoint): Update.
6443 (breakpoint_set_commands): Change commands to be a
6444 counted_command_line.
6445 (commands_command_1, update_dprintf_command_list)
6446 (create_tracepoint_from_upload): Update.
6448 2018-05-04 Tom Tromey <tom@tromey.com>
6450 * cli/cli-decode.h (cmd_list_element): New constructor.
6451 (~cmd_list_element): New destructor.
6452 (struct cmd_list_element): Add initializers.
6453 * cli/cli-decode.c (do_add_cmd): Use "new".
6454 (delete_cmd): Use "delete".
6456 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
6457 Pedro Alves <palves@redhat.com>
6459 PR breakpoints/19806 and support for PR external/20207.
6460 * NEWS: Mention Aarch64 watchpoint improvements.
6461 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
6462 watchpoints and PR external/20207 watchpoints.
6463 * nat/aarch64-linux-hw-point.c
6464 (kernel_supports_any_contiguous_range): New.
6465 (aarch64_watchpoint_offset): New.
6466 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
6467 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
6468 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
6469 (aarch64_align_watchpoint): New parameters aligned_offset_p and
6470 next_addr_orig_p. Support PR external/20207 watchpoints.
6471 (aarch64_downgrade_regs): New.
6472 (aarch64_dr_state_insert_one_point): New parameters offset and
6474 (aarch64_dr_state_remove_one_point): Likewise.
6475 (aarch64_handle_breakpoint): Update caller.
6476 (aarch64_handle_aligned_watchpoint): Likewise.
6477 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
6479 (aarch64_linux_set_debug_regs): Remove const from state. Call
6480 aarch64_downgrade_regs.
6481 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
6482 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
6483 (DR_CONTROL_MASK): ... this.
6484 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
6485 (unsigned int aarch64_watchpoint_offset): New prototype.
6486 (aarch64_linux_set_debug_regs): Remove const from state.
6487 * utils.c (align_up, align_down): Move to ...
6488 * common/common-utils.c (align_up, align_down): ... here.
6489 * utils.h (align_up, align_down): Move to ...
6490 * common/common-utils.h (align_up, align_down): ... here.
6492 2018-05-04 Joel Brobecker <brobecker@adacore.com>
6494 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
6495 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
6496 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
6497 Re-implement to match the ABI as summarized in GCC's
6498 gcc/config/sparc/sparc.c. All callers updated.
6499 (sparc32_store_arguments): Remove assertion.
6501 2018-05-04 Tom Tromey <tom@tromey.com>
6503 * printcmd.c: Don't include tui.h.
6504 (decode_format): Use skip_spaces.
6506 2018-05-04 Tom Tromey <tom@tromey.com>
6509 * printcmd.c (last_count): New global.
6510 (x_command): Use saved count when repeating.
6512 2018-05-04 Tom Tromey <tom@tromey.com>
6514 * nto-procfs.c (do_closedir_cleanup): Remove.
6515 (procfs_pidlist): Use gdb_dir_up.
6516 * procfs.c (do_closedir_cleanup): Remove.
6517 (proc_update_threads): Use gdb_dir_up.
6518 * common/filestuff.h (struct gdb_dir_deleter): New.
6519 (gdb_dir_up): New typedef.
6521 2018-05-04 Tom Tromey <tom@tromey.com>
6523 * ada-lang.c (print_mention_exception): Use std::string.
6525 2018-05-04 Tom Tromey <tom@tromey.com>
6527 * ada-lang.c (create_excep_cond_exprs): Update.
6528 (ada_exception_catchpoint_cond_string): Use std::string.
6530 2018-05-04 Tom Tromey <tom@tromey.com>
6532 * ada-lang.c (xget_renaming_scope): Return std::string.
6533 (old_renaming_is_invisible): Update.
6535 2018-05-04 Tom Tromey <tom@tromey.com>
6537 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
6538 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
6540 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
6542 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
6544 2018-05-04 Tom Tromey <tom@tromey.com>
6546 * remote.c (remote_query_supported_append): Change type.
6547 (remote_check_symbols): Update.
6549 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
6552 * configure.ac: Prepend libpython.
6553 * python/python-config.py: Likewise.
6554 * configure: Regenerate.
6556 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
6558 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
6560 2018-05-03 Pedro Alves <palves@redhat.com>
6563 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
6564 override. Write 'true' instead of '1'.
6565 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
6568 2018-05-02 Pedro Alves <palves@redhat.com>
6570 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
6571 add_inf_child_target.
6572 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
6573 add_inf_child_target.
6574 * aix-thread.c (aix_thread_target_info): New.
6575 (aix_thread_target) <shortname, longname, doc>: Delete.
6577 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
6578 add_inf_child_target.
6579 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
6580 add_inf_child_target.
6581 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
6582 add_inf_child_target.
6583 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
6584 add_inf_child_target.
6585 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
6586 add_inf_child_target.
6587 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
6588 add_inf_child_target.
6589 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
6590 add_inf_child_target.
6591 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
6592 add_inf_child_target.
6593 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
6594 add_inf_child_target.
6595 * bfd-target.c (target_bfd_target_info): New.
6596 (target_bfd) <shortname, longname, doc>: Delete.
6598 * bsd-kvm.c (bsd_kvm_target_info): New.
6599 (bsd_kvm_target) <shortname, longname, doc>: Delete.
6601 (bsd_kvm_target::open): Rename to ...
6602 (bsd_kvm_target_open): ... this. Adjust.
6603 * bsd-uthread.c (bsd_uthread_target_info): New.
6604 (bsd_uthread_target) <shortname, longname, doc>: Delete.
6606 * corefile.c (core_file_command): Adjust.
6607 * corelow.c (core_target_info): New.
6608 (core_target) <shortname, longname, doc>: Delete.
6610 (core_target::open): Rename to ...
6611 (core_target_open): ... this. Adjust.
6612 * ctf.c (ctf_target_info): New.
6613 (ctf_target) <shortname, longname, doc>: Delete.
6615 (ctf_target::open): Rename to ...
6616 (ctf_target_open): ... this.
6617 (_initialize_ctf): Adjust.
6618 * exec.c (exec_target_info): New.
6619 (exec_target) <shortname, longname, doc>: Delete.
6621 (exec_target::open): Rename to ...
6622 (exec_target_open): ... this.
6623 * gdbcore.h (core_target_open): Declare.
6624 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
6625 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
6626 add_inf_child_target.
6627 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
6628 add_inf_child_target.
6629 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
6630 add_inf_child_target.
6631 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
6632 add_inf_child_target.
6633 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
6634 add_inf_child_target.
6635 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
6636 add_inf_child_target.
6637 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
6638 add_inf_child_target.
6639 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
6640 add_inf_child_target.
6641 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
6642 add_inf_child_target.
6643 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
6644 add_inf_child_target.
6645 * inf-child.c (inf_child_target_info): New.
6646 (inf_child_target::info): New.
6647 (inf_child_open_target): Remove 'target' parameter. Use
6648 get_native_target instead.
6649 (inf_child_target::open): Delete.
6650 (add_inf_child_target): New.
6651 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
6654 (add_inf_child_target): Declare.
6655 (inf_child_open_target): Declare.
6656 * linux-thread-db.c (thread_db_target_info): New.
6657 (thread_db_target) <shortname, longname, doc>: Delete.
6659 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
6660 add_inf_child_target.
6661 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
6662 add_inf_child_target.
6663 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
6664 add_inf_child_target.
6665 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
6666 add_inf_child_target.
6667 * make-target-delegates (print_class): Adjust.
6668 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
6669 add_inf_child_target.
6670 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
6671 add_inf_child_target.
6672 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
6673 add_inf_child_target.
6674 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
6675 add_inf_child_target.
6676 * nto-procfs.c (nto_native_target_info): New.
6677 (nto_procfs_target_native) <shortname, longname, doc>:
6680 (nto_procfs_target_info): New.
6681 (nto_procfs_target_procfs) <shortname, longname, doc>:
6684 (init_procfs_targets): Adjust.
6685 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
6686 add_inf_child_target.
6687 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
6688 add_inf_child_target.
6689 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
6690 add_inf_child_target.
6691 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
6692 add_inf_child_target.
6693 * ravenscar-thread.c (ravenscar_target_info): New.
6694 (ravenscar_thread_target) <shortname, longname, doc>:
6697 * record-btrace.c (record_btrace_target_info):
6698 (record_btrace_target) <shortname, longname, doc>: Delete.
6700 (record_btrace_target::open): Rename to ...
6701 (record_btrace_target_open): ... this. Adjust.
6702 * record-full.c (record_longname, record_doc): New.
6703 (record_full_base_target) <shortname, longname, doc>: Delete.
6705 (record_full_target_info): New.
6706 (record_full_target): <shortname>: Delete.
6708 (record_full_core_open_1, record_full_open_1): Update comments.
6709 (record_full_base_target::open): Rename to ...
6710 (record_full_open): ... this.
6711 (cmd_record_full_restore): Update.
6712 (_initialize_record_full): Update.
6713 * remote-sim.c (remote_sim_target_info): New.
6714 (gdbsim_target) <shortname, longname, doc>: Delete.
6716 (gdbsim_target::open): Rename to ...
6717 (gdbsim_target_open): ... this.
6718 (_initialize_remote_sim): Adjust.
6719 * remote.c (remote_doc): New.
6720 (remote_target_info): New.
6721 (remote_target) <shortname, longname, doc>: Delete.
6723 (extended_remote_target_info): New.
6724 (extended_remote_target) <shortname, longname, doc>: Delete.
6726 (remote_target::open_1): Make static. Adjust.
6727 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
6728 * s390-linux-nat.c (_initialize_s390_nat): Use
6729 add_inf_child_target.
6730 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
6731 add_inf_child_target.
6732 * sol-thread.c (thread_db_target_info): New.
6733 (sol_thread_target) <shortname, longname, doc>: Delete.
6735 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
6736 add_inf_child_target.
6737 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
6738 add_inf_child_target.
6739 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
6740 add_inf_child_target.
6741 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
6742 add_inf_child_target.
6743 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
6744 add_inf_child_target.
6745 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
6746 add_inf_child_target.
6747 * spu-linux-nat.c (_initialize_spu_nat): Use
6748 add_inf_child_target.
6749 * spu-multiarch.c (spu_multiarch_target_info): New.
6750 (spu_multiarch_target) <shortname, longname, doc>: Delete.
6752 * target-delegates.c: Regenerate.
6753 * target.c: Include <unordered_map>.
6754 (target_ops_p): Delete.
6755 (DEF_VEC_P(target_ops_p)): Delete.
6756 (target_factories): New.
6757 (test_target_info): New.
6758 (test_target_ops::info): New.
6759 (open_target): Adjust to use target_factories.
6760 (add_target_with_completer): Rename to ...
6761 (add_target): ... this. Change prototype. Register target_info
6762 and open callback in target_factories. Register target_info in
6763 command context instead of target_ops.
6764 (add_target): Delete old implementation.
6765 (add_deprecated_target_alias): Change prototype. Adjust.
6766 (the_native_target): New.
6767 (set_native_target, get_native_target): New.
6768 (find_default_run_target): Use the_native_target.
6769 (find_attach_target, find_run_target): Simplify.
6770 (target_ops::open): Delete.
6771 (dummy_target_info): New.
6772 (dummy_target::shortname, dummy_target::longname)
6773 (dummy_target::doc): Delete.
6774 (dummy_target::info): New.
6775 (debug_target::shortname, debug_target::longname)
6776 (debug_target::doc): Delete.
6777 (debug_target::info): New.
6778 * target.h (struct target_info): New.
6779 (target_ops::~target_ops): Add comment.
6780 (target_ops::info): New.
6781 (target_ops::shortname, target_ops::longname, target_ops::doc): No
6782 longer virtual. Implement in terms of target_info.
6783 (set_native_target, get_native_target): Declare.
6784 (target_open_ftype): New.
6785 (add_target, add_target_with_completer)
6786 (add_deprecated_target_alias): Change prototype.
6787 (test_target) <shortname, longname, doc>: Delete.
6789 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
6790 add_inf_child_target.
6791 * tracefile-tfile.c (tfile_target_info): New.
6792 (tfile_target) <shortname, longname, doc>: Delete.
6794 (tfile_target::open): Rename to ...
6795 (tfile_target_open): ... this.
6796 (_initialize_tracefile_tfile): Adjust.
6797 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
6798 add_inf_child_target.
6799 * windows-nat.c (_initialize_windows_nat): Use
6800 add_inf_child_target.
6801 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
6802 add_inf_child_target.
6804 2018-05-02 Pedro Alves <palves@redhat.com>
6806 * linux-nat.h (linux_nat_target) <low_new_thread,
6807 low_delete_thread, low_new_fork, low_forget_process,
6808 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
6809 New virtual methods.
6810 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
6811 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
6812 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
6813 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
6814 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
6816 * linux-fork.c (delete_fork): Adjust to call low method.
6817 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
6818 (linux_nat_new_fork, linux_nat_forget_process_hook)
6819 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
6820 (linux_nat_status_is_event):
6821 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
6822 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
6824 (sigtrap_is_event): Rename to ...
6825 (linux_nat_target::low_status_is_event): ... this.
6826 (linux_nat_set_status_is_event): Delete.
6827 (save_stop_reason, linux_nat_wait_1)
6828 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
6830 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
6831 (linux_nat_set_new_fork, linux_nat_set_forget_process)
6832 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
6833 (linux_nat_set_prepare_to_resume): Delete.
6834 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
6835 low virtual methods.
6836 * amd64-linux-nat.c: Likewise.
6837 * arm-linux-nat.c: Likewise.
6838 * i386-linux-nat.c: Likewise.
6839 * ia64-linux-nat.c: Likewise.
6840 * mips-linux-nat.c: Likewise.
6841 * ppc-linux-nat.c: Likewise.
6842 * s390-linux-nat.c: Likewise.
6843 * sparc64-linux-nat.c: Likewise.
6844 * x86-linux-nat.c: Likewise.
6845 * x86-linux-nat.h: Include "nat/x86-linux.h".
6846 (x86_linux_nat_target) <low_new_fork, low_forget_process,
6847 low_prepare_to_resume, low_new_thread, low_delete_thread>:
6850 2018-05-02 Pedro Alves <palves@redhat.com>
6852 * target.h (target_ops)
6853 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6854 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
6855 stopped_by_watchpoint, have_continuable_watchpoint,
6856 stopped_data_address, watchpoint_addr_within_range,
6857 can_accel_watchpoint_condition, can_run, thread_alive,
6858 has_all_memory, has_memory, has_stack, has_registers,
6859 has_execution, can_async_p, is_async_p, supports_non_stop,
6860 always_non_stop_p, can_execute_reverse, supports_multi_process,
6861 supports_enable_disable_tracepoint,
6862 supports_disable_randomization, supports_string_tracing,
6863 supports_evaluation_of_breakpoint_conditions,
6864 can_run_breakpoint_commands, filesystem_is_local,
6865 can_download_tracepoint, get_trace_state_variable_value,
6866 set_trace_notes, get_tib_address, use_agent, can_use_agent,
6867 record_is_replaying, record_will_replay,
6868 augmented_libraries_svr4_read>: Adjust to return bool.
6869 * aarch64-linux-nat.c: All implementations adjusted.
6870 * aix-thread.c: All implementations adjusted.
6871 * arm-linux-nat.c: All implementations adjusted.
6872 * breakpoint.c: All implementations adjusted.
6873 * bsd-kvm.c: All implementations adjusted.
6874 * bsd-uthread.c: All implementations adjusted.
6875 * corelow.c: All implementations adjusted.
6876 * ctf.c: All implementations adjusted.
6877 * darwin-nat.c: All implementations adjusted.
6878 * darwin-nat.h: All implementations adjusted.
6879 * exec.c: All implementations adjusted.
6880 * fbsd-nat.c: All implementations adjusted.
6881 * fbsd-nat.h: All implementations adjusted.
6882 * gnu-nat.c: All implementations adjusted.
6883 * gnu-nat.h: All implementations adjusted.
6884 * go32-nat.c: All implementations adjusted.
6885 * ia64-linux-nat.c: All implementations adjusted.
6886 * inf-child.c: All implementations adjusted.
6887 * inf-child.h: All implementations adjusted.
6888 * inf-ptrace.c: All implementations adjusted.
6889 * inf-ptrace.h: All implementations adjusted.
6890 * linux-nat.c: All implementations adjusted.
6891 * linux-nat.h: All implementations adjusted.
6892 * mips-linux-nat.c: All implementations adjusted.
6893 * nto-procfs.c: All implementations adjusted.
6894 * ppc-linux-nat.c: All implementations adjusted.
6895 * procfs.c: All implementations adjusted.
6896 * ravenscar-thread.c: All implementations adjusted.
6897 * record-btrace.c: All implementations adjusted.
6898 * record-full.c: All implementations adjusted.
6899 * remote-sim.c: All implementations adjusted.
6900 * remote.c: All implementations adjusted.
6901 * s390-linux-nat.c: All implementations adjusted.
6902 * sol-thread.c: All implementations adjusted.
6903 * spu-multiarch.c: All implementations adjusted.
6904 * target-delegates.c: All implementations adjusted.
6905 * target.c: All implementations adjusted.
6906 * target.h: All implementations adjusted.
6907 * tracefile-tfile.c: All implementations adjusted.
6908 * tracefile.c: All implementations adjusted.
6909 * tracefile.h: All implementations adjusted.
6910 * windows-nat.c: All implementations adjusted.
6911 * x86-linux-nat.h: All implementations adjusted.
6912 * x86-nat.h: All implementations adjusted.
6914 2018-05-02 Pedro Alves <palves@redhat.com>
6916 * make-target-delegates (scan_target_h): Don't trim lines here.
6917 Replace sequences of tabs and/or whitespace with a single
6919 (top level, parsing methods): Trim each line before processing it
6922 2018-05-02 Pedro Alves <palves@redhat.com>
6923 John Baldwin <jhb@freebsd.org>
6925 * target.h (enum strata) <debug_stratum>: New.
6926 (struct target_ops) <all delegation methods>: Replace by C++
6927 virtual methods, and drop "to_" prefix. All references updated
6929 <to_shortname, to_longname, to_doc, to_data,
6930 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
6931 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
6932 virtual methods. All references updated throughout.
6933 <can_attach, supports_terminal_ours, can_create_inferior,
6934 get_thread_control_capabilities, attach_no_wait>: New
6936 <insert_breakpoint, remove_breakpoint>: Now
6937 TARGET_DEFAULT_NORETURN methods.
6938 <info_proc>: Now returns bool.
6940 (OPS_MAGIC): Delete.
6941 (current_target): Delete. All references replaced by references
6943 (target_stack): ... this. New.
6944 (target_shortname, target_longname): Adjust.
6945 (target_can_run): Now a function declaration.
6946 (default_child_has_all_memory, default_child_has_memory)
6947 (default_child_has_stack, default_child_has_registers)
6948 (default_child_has_execution): Remove target_ops parameter.
6949 (complete_target_initialization): Delete.
6950 (memory_breakpoint_target): New template class.
6951 (test_target_ops): Refactor as a C++ class with virtual methods.
6952 * make-target-delegates (NAME_PART): Tighten.
6953 (POINTER_PART, CP_SYMBOL): New.
6954 (SIMPLE_RETURN_PART): Reimplement.
6955 (VEC_RETURN_PART): Expect less.
6956 (RETURN_PART, VIRTUAL_PART): New.
6957 (METHOD): Adjust to C++ virtual methods.
6958 (scan_target_h): Remove reference to C99.
6959 (dname): Output "target_ops::" prefix.
6960 (write_function_header): Adjust to output a C++ class method.
6961 (write_declaration): New.
6962 (write_delegator): Adjust to output a C++ class method.
6963 (tdname): Output "dummy_target::" prefix.
6964 (write_tdefault, write_debugmethod): Adjust to output a C++ class
6966 (tdefault_names, debug_names): Delete.
6967 (return_types, tdefaults, styles, argtypes_array): New.
6968 (top level): All methods are delegators.
6970 (top level): Print dummy_target and debug_target classes.
6971 * target-delegates.c: Regenerate.
6972 * target-debug.h (target_debug_print_enum_info_proc_what)
6973 (target_debug_print_thread_control_capabilities)
6974 (target_debug_print_thread_info_p): New.
6975 * target.c (dummy_target): Delete.
6976 (the_dummy_target, the_debug_target): New.
6977 (target_stack): Now extern.
6978 (set_targetdebug): Push/unpush debug target.
6979 (default_child_has_all_memory, default_child_has_memory)
6980 (default_child_has_stack, default_child_has_registers)
6981 (default_child_has_execution): Remove target_ops parameter.
6982 (complete_target_initialization): Delete.
6983 (add_target_with_completer): No longer call
6984 complete_target_initialization.
6985 (target_supports_terminal_ours): Use regular delegation.
6986 (update_current_target): Delete.
6987 (push_target): No longer check magic number. Don't call
6988 update_current_target.
6989 (unpush_target): Don't call update_current_target.
6990 (target_is_pushed): No longer check magic number.
6991 (target_require_runnable): Skip for all stratums over
6993 (target_ops::info_proc): New.
6994 (target_info_proc): Use find_target_at and
6995 find_default_run_target.
6996 (target_supports_disable_randomization): Use regular delegation.
6997 (target_get_osdata): Use find_target_at.
6998 (target_ops::open, target_ops::close, target_ops::can_attach)
6999 (target_ops::attach, target_ops::can_create_inferior)
7000 (target_ops::create_inferior, target_ops::can_run)
7001 (target_can_run): New.
7002 (default_fileio_target): Use regular delegation.
7003 (target_ops::fileio_open, target_ops::fileio_pwrite)
7004 (target_ops::fileio_pread, target_ops::fileio_fstat)
7005 (target_ops::fileio_close, target_ops::fileio_unlink)
7006 (target_ops::fileio_readlink): New.
7007 (target_fileio_open_1, target_fileio_unlink)
7008 (target_fileio_readlink): Always call the target method. Handle
7010 (return_zero, return_zero_has_execution): Delete.
7011 (init_dummy_target): Delete.
7012 (dummy_target::dummy_target, dummy_target::shortname)
7013 (dummy_target::longname, dummy_target::doc)
7014 (debug_target::debug_target, debug_target::shortname)
7015 (debug_target::longname, debug_target::doc): New.
7016 (target_supports_delete_record): Use regular delegation.
7017 (setup_target_debug): Delete.
7018 (maintenance_print_target_stack): Skip debug_stratum.
7019 (initialize_targets): Instantiate the_dummy_target and
7021 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7023 (target_auxv_search, fprint_target_auxv): Adjust.
7024 (info_auxv_command): Adjust to use target_stack.
7025 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7026 * exceptions.c (print_flush): Handle a NULL target_stack.
7027 * regcache.c (target_ops_no_register): Refactor as class with
7030 * exec.c (exec_target): New class.
7031 (exec_ops): Now an exec_target.
7032 (exec_open, exec_close_1, exec_get_section_table)
7033 (exec_xfer_partial, exec_files_info, exec_has_memory)
7034 (exec_make_note_section): Refactor as exec_target methods.
7035 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7037 (exec_target::find_memory_regions): New.
7038 (_initialize_exec): Don't call init_exec_ops.
7039 * gdbcore.h (exec_file_clear): Delete.
7041 * corefile.c (core_target): Delete.
7042 (core_file_command): Adjust.
7043 * corelow.c (core_target): New class.
7044 (the_core_target): New.
7045 (core_close): Remove target_ops parameter.
7046 (core_close_cleanup): Adjust.
7047 (core_target::close): New.
7048 (core_open, core_detach, get_core_registers, core_files_info)
7049 (core_xfer_partial, core_thread_alive, core_read_description)
7050 (core_pid_to_str, core_thread_name, core_has_memory)
7051 (core_has_stack, core_has_registers, core_info_proc): Rework as
7052 core_target methods.
7053 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7054 (_initialize_corelow): Initialize the_core_target.
7055 * gdbcore.h (core_target): Delete.
7056 (the_core_target): New.
7058 * ctf.c: (ctf_target): New class.
7059 (ctf_ops): Now a ctf_target.
7060 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7061 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7062 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7064 (init_ctf_ops): Delete.
7065 (_initialize_ctf): Don't call it.
7066 * tracefile-tfile.c (tfile_target): New class.
7067 (tfile_ops): Now a tfile_target.
7068 (tfile_open, tfile_close, tfile_files_info)
7069 (tfile_get_tracepoint_status, tfile_trace_find)
7070 (tfile_fetch_registers, tfile_xfer_partial)
7071 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
7072 Refactor as tfile_target methods.
7073 (tfile_xfer_partial_features): Remove target_ops parameter.
7074 (init_tfile_ops): Delete.
7075 (_initialize_tracefile_tfile): Don't call it.
7076 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
7077 (tracefile_has_stack, tracefile_has_registers)
7078 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
7079 tracefile_target methods.
7080 (init_tracefile_ops): Delete.
7081 (tracefile_target::tracefile_target): New.
7082 * tracefile.h: Include "target.h".
7083 (tracefile_target): New class.
7084 (init_tracefile_ops): Delete.
7086 * spu-multiarch.c (spu_multiarch_target): New class.
7087 (spu_ops): Now a spu_multiarch_target.
7088 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
7089 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
7090 (spu_search_memory, spu_mourn_inferior): Refactor as
7091 spu_multiarch_target methods.
7092 (init_spu_ops): Delete.
7093 (_initialize_spu_multiarch): Remove references to init_spu_ops,
7094 complete_target_initialization.
7096 * ravenscar-thread.c (ravenscar_thread_target): New class.
7097 (ravenscar_ops): Now a ravenscar_thread_target.
7098 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
7099 (ravenscar_thread_alive, ravenscar_pid_to_str)
7100 (ravenscar_fetch_registers, ravenscar_store_registers)
7101 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
7102 (ravenscar_stopped_by_hw_breakpoint)
7103 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
7104 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
7105 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
7107 (init_ravenscar_thread_ops): Delete.
7108 (_initialize_ravenscar): Remove references to
7109 init_ravenscar_thread_ops and complete_target_initialization.
7111 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
7112 (bsd_uthread_target): New class.
7113 (bsd_uthread_ops): Now a bsd_uthread_target.
7114 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
7115 (bsd_uthread_close, bsd_uthread_mourn_inferior)
7116 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
7117 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
7118 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
7119 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
7120 (bsd_uthread_target): Delete function.
7121 (_initialize_bsd_uthread): Remove reference to
7122 complete_target_initialization.
7124 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
7125 (target_bfd): ... this new class.
7126 (target_bfd_xfer_partial, target_bfd_get_section_table)
7127 (target_bfd_close): Refactor as target_bfd methods.
7128 (target_bfd::~target_bfd): New.
7129 (target_bfd_reopen): Adjust.
7130 (target_bfd::close): New.
7132 * record-btrace.c (record_btrace_target): New class.
7133 (record_btrace_ops): Now a record_btrace_target.
7134 (record_btrace_open, record_btrace_stop_recording)
7135 (record_btrace_disconnect, record_btrace_close)
7136 (record_btrace_async, record_btrace_info)
7137 (record_btrace_insn_history, record_btrace_insn_history_range)
7138 (record_btrace_insn_history_from, record_btrace_call_history)
7139 (record_btrace_call_history_range)
7140 (record_btrace_call_history_from, record_btrace_record_method)
7141 (record_btrace_is_replaying, record_btrace_will_replay)
7142 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
7143 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
7144 (record_btrace_store_registers, record_btrace_prepare_to_store)
7145 (record_btrace_to_get_unwinder)
7146 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
7147 (record_btrace_commit_resume, record_btrace_wait)
7148 (record_btrace_stop, record_btrace_can_execute_reverse)
7149 (record_btrace_stopped_by_sw_breakpoint)
7150 (record_btrace_supports_stopped_by_sw_breakpoint)
7151 (record_btrace_stopped_by_hw_breakpoint)
7152 (record_btrace_supports_stopped_by_hw_breakpoint)
7153 (record_btrace_update_thread_list, record_btrace_thread_alive)
7154 (record_btrace_goto_begin, record_btrace_goto_end)
7155 (record_btrace_goto, record_btrace_stop_replaying_all)
7156 (record_btrace_execution_direction)
7157 (record_btrace_prepare_to_generate_core)
7158 (record_btrace_done_generating_core): Refactor as
7159 record_btrace_target methods.
7160 (init_record_btrace_ops): Delete.
7161 (_initialize_record_btrace): Remove reference to
7162 init_record_btrace_ops.
7163 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
7164 the execution_direction global.
7165 (record_full_base_target, record_full_target)
7166 (record_full_core_target): New classes.
7167 (record_full_ops): Now a record_full_target.
7168 (record_full_core_ops): Now a record_full_core_target.
7169 (record_full_target::detach, record_full_target::disconnect)
7170 (record_full_core_target::disconnect)
7171 (record_full_target::mourn_inferior, record_full_target::kill):
7173 (record_full_open, record_full_close, record_full_async): Refactor
7174 as methods of the record_full_base_target class.
7175 (record_full_resume, record_full_commit_resume): Refactor
7176 as methods of the record_full_target class.
7177 (record_full_wait, record_full_stopped_by_watchpoint)
7178 (record_full_stopped_data_address)
7179 (record_full_stopped_by_sw_breakpoint)
7180 (record_full_supports_stopped_by_sw_breakpoint)
7181 (record_full_stopped_by_hw_breakpoint)
7182 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
7183 methods of the record_full_base_target class.
7184 (record_full_store_registers, record_full_xfer_partial)
7185 (record_full_insert_breakpoint, record_full_remove_breakpoint):
7186 Refactor as methods of the record_full_target class.
7187 (record_full_can_execute_reverse, record_full_get_bookmark)
7188 (record_full_goto_bookmark, record_full_execution_direction)
7189 (record_full_record_method, record_full_info, record_full_delete)
7190 (record_full_is_replaying, record_full_will_replay)
7191 (record_full_goto_begin, record_full_goto_end, record_full_goto)
7192 (record_full_stop_replaying): Refactor as methods of the
7193 record_full_base_target class.
7194 (record_full_core_resume, record_full_core_kill)
7195 (record_full_core_fetch_registers)
7196 (record_full_core_prepare_to_store)
7197 (record_full_core_store_registers, record_full_core_xfer_partial)
7198 (record_full_core_insert_breakpoint)
7199 (record_full_core_remove_breakpoint)
7200 (record_full_core_has_execution): Refactor
7201 as methods of the record_full_core_target class.
7202 (record_full_base_target::supports_delete_record): New.
7203 (init_record_full_ops): Delete.
7204 (init_record_full_core_ops): Delete.
7205 (record_full_save): Refactor as method of the
7206 record_full_base_target class.
7207 (_initialize_record_full): Remove references to
7208 init_record_full_ops and init_record_full_core_ops.
7210 * remote.c (remote_target, extended_remote_target): New classes.
7211 (remote_ops): Now a remote_target.
7212 (extended_remote_ops): Now an extended_remote_target.
7213 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
7214 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
7215 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
7216 (remote_pass_signals, remote_set_syscall_catchpoint)
7217 (remote_program_signals, )
7218 (remote_thread_always_alive): Remove target_ops parameter.
7219 (remote_thread_alive, remote_thread_name)
7220 (remote_update_thread_list, remote_threads_extra_info)
7221 (remote_static_tracepoint_marker_at)
7222 (remote_static_tracepoint_markers_by_strid)
7223 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
7224 (remote_open): Refactor as methods of remote_target.
7225 (extended_remote_open, extended_remote_detach)
7226 (extended_remote_attach, extended_remote_post_attach):
7227 (extended_remote_supports_disable_randomization)
7228 (extended_remote_create_inferior): : Refactor as method of
7229 extended_remote_target.
7230 (remote_set_permissions, remote_open_1, remote_detach)
7231 (remote_follow_fork, remote_follow_exec, remote_disconnect)
7232 (remote_resume, remote_commit_resume, remote_stop)
7233 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
7234 (remote_terminal_ours, remote_wait, remote_fetch_registers)
7235 (remote_prepare_to_store, remote_store_registers)
7236 (remote_flash_erase, remote_flash_done, remote_files_info)
7237 (remote_kill, remote_mourn, remote_insert_breakpoint)
7238 (remote_remove_breakpoint, remote_insert_watchpoint)
7239 (remote_watchpoint_addr_within_range)
7240 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
7241 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
7242 (remote_supports_stopped_by_sw_breakpoint)
7243 (remote_stopped_by_hw_breakpoint)
7244 (remote_supports_stopped_by_hw_breakpoint)
7245 (remote_stopped_by_watchpoint, remote_stopped_data_address)
7246 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
7247 (remote_verify_memory): Refactor as methods of remote_target.
7248 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
7250 (remote_xfer_partial, remote_get_memory_xfer_limit)
7251 (remote_search_memory, remote_rcmd, remote_memory_map)
7252 (remote_pid_to_str, remote_get_thread_local_address)
7253 (remote_get_tib_address, remote_read_description): Refactor as
7254 methods of remote_target.
7255 (remote_target::fileio_open, remote_target::fileio_pwrite)
7256 (remote_target::fileio_pread, remote_target::fileio_close): New.
7257 (remote_hostio_readlink, remote_hostio_fstat)
7258 (remote_filesystem_is_local, remote_can_execute_reverse)
7259 (remote_supports_non_stop, remote_supports_disable_randomization)
7260 (remote_supports_multi_process, remote_supports_cond_breakpoints)
7261 (remote_supports_enable_disable_tracepoint)
7262 (remote_supports_string_tracing)
7263 (remote_can_run_breakpoint_commands, remote_trace_init)
7264 (remote_download_tracepoint, remote_can_download_tracepoint)
7265 (remote_download_trace_state_variable, remote_enable_tracepoint)
7266 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
7267 (remote_trace_start, remote_get_trace_status)
7268 (remote_get_tracepoint_status, remote_trace_stop)
7269 (remote_trace_find, remote_get_trace_state_variable_value)
7270 (remote_save_trace_data, remote_get_raw_trace_data)
7271 (remote_set_disconnected_tracing, remote_core_of_thread)
7272 (remote_set_circular_trace_buffer, remote_traceframe_info)
7273 (remote_get_min_fast_tracepoint_insn_len)
7274 (remote_set_trace_buffer_size, remote_set_trace_notes)
7275 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
7276 (remote_disable_btrace, remote_teardown_btrace)
7277 (remote_read_btrace, remote_btrace_conf)
7278 (remote_augmented_libraries_svr4_read, remote_load)
7279 (remote_pid_to_exec_file, remote_can_do_single_step)
7280 (remote_execution_direction, remote_thread_handle_to_thread_info):
7281 Refactor as methods of remote_target.
7282 (init_remote_ops, init_extended_remote_ops): Delete.
7283 (remote_can_async_p, remote_is_async_p, remote_async)
7284 (remote_thread_events, remote_upload_tracepoints)
7285 (remote_upload_trace_state_variables): Refactor as methods of
7287 (_initialize_remote): Remove references to init_remote_ops and
7288 init_extended_remote_ops.
7290 * remote-sim.c (gdbsim_target): New class.
7291 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
7292 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
7293 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
7294 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
7295 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
7296 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
7297 Refactor as methods of gdbsim_target.
7298 (gdbsim_ops): Now a gdbsim_target.
7299 (init_gdbsim_ops): Delete.
7300 (gdbsim_cntrl_c): Adjust.
7301 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
7303 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
7304 (the_amd64_linux_nat_target): New.
7305 (amd64_linux_fetch_inferior_registers)
7306 (amd64_linux_store_inferior_registers): Refactor as methods of
7307 amd64_linux_nat_target.
7308 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
7309 * i386-linux-nat.c: Don't include "linux-nat.h".
7310 (i386_linux_nat_target): New class.
7311 (the_i386_linux_nat_target): New.
7312 (i386_linux_fetch_inferior_registers)
7313 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
7314 as methods of i386_linux_nat_target.
7315 (_initialize_i386_linux_nat): Adjust. Set linux_target.
7316 * inf-child.c (inf_child_ops): Delete.
7317 (inf_child_fetch_inferior_registers)
7318 (inf_child_store_inferior_registers): Delete.
7319 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
7320 methods of inf_child_target.
7321 (inf_child_target::supports_terminal_ours)
7322 (inf_child_target::terminal_init)
7323 (inf_child_target::terminal_inferior)
7324 (inf_child_target::terminal_ours_for_output)
7325 (inf_child_target::terminal_ours, inf_child_target::interrupt)
7326 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
7328 (inf_child_open, inf_child_disconnect, inf_child_close)
7329 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
7330 (inf_child_post_startup_inferior, inf_child_can_run)
7331 (inf_child_pid_to_exec_file): Refactor as methods of
7333 (inf_child_follow_fork): Delete.
7334 (inf_child_target::can_create_inferior)
7335 (inf_child_target::can_attach): New.
7336 (inf_child_target::has_all_memory, inf_child_target::has_memory)
7337 (inf_child_target::has_stack, inf_child_target::has_registers)
7338 (inf_child_target::has_execution): New.
7339 (inf_child_fileio_open, inf_child_fileio_pwrite)
7340 (inf_child_fileio_pread, inf_child_fileio_fstat)
7341 (inf_child_fileio_close, inf_child_fileio_unlink)
7342 (inf_child_fileio_readlink, inf_child_use_agent)
7343 (inf_child_can_use_agent): Refactor as methods of
7345 (return_zero, inf_child_target): Delete.
7346 (inf_child_target::inf_child_target): New.
7347 * inf-child.h: Include "target.h".
7348 (inf_child_target): Delete function prototype.
7349 (inf_child_target): New class.
7350 (inf_child_open_target, inf_child_mourn_inferior)
7351 (inf_child_maybe_unpush_target): Delete.
7352 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
7353 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
7354 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
7355 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
7356 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
7357 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
7358 (inf_ptrace_wait, inf_ptrace_xfer_partial)
7359 (inf_ptrace_thread_alive, inf_ptrace_files_info)
7360 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
7361 methods of inf_ptrace_target.
7362 (inf_ptrace_target): Delete function.
7363 * inf-ptrace.h: Include "inf-child.h".
7364 (inf_ptrace_target): Delete function declaration.
7365 (inf_ptrace_target): New class.
7366 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
7367 * linux-nat.c (linux_target): New.
7368 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
7369 (linux_nat_target::~linux_nat_target): New.
7370 (linux_child_post_attach, linux_child_post_startup_inferior)
7371 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
7372 (linux_child_remove_fork_catchpoint)
7373 (linux_child_insert_vfork_catchpoint)
7374 (linux_child_remove_vfork_catchpoint)
7375 (linux_child_insert_exec_catchpoint)
7376 (linux_child_remove_exec_catchpoint)
7377 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
7378 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
7379 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
7380 (linux_nat_stopped_data_address)
7381 (linux_nat_stopped_by_sw_breakpoint)
7382 (linux_nat_supports_stopped_by_sw_breakpoint)
7383 (linux_nat_stopped_by_hw_breakpoint)
7384 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
7385 (linux_nat_kill, linux_nat_mourn_inferior)
7386 (linux_nat_xfer_partial, linux_nat_thread_alive)
7387 (linux_nat_update_thread_list, linux_nat_pid_to_str)
7388 (linux_nat_thread_name, linux_child_pid_to_exec_file)
7389 (linux_child_static_tracepoint_markers_by_strid)
7390 (linux_nat_is_async_p, linux_nat_can_async_p)
7391 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
7392 (linux_nat_supports_multi_process)
7393 (linux_nat_supports_disable_randomization, linux_nat_async)
7394 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
7395 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
7396 (linux_nat_fileio_open, linux_nat_fileio_readlink)
7397 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
7398 methods of linux_nat_target.
7399 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
7400 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
7402 (check_stopped_by_watchpoint): Adjust.
7403 (linux_xfer_partial): Delete.
7404 (linux_target_install_ops, linux_target, linux_nat_add_target):
7406 (linux_nat_target::linux_nat_target): New.
7407 * linux-nat.h: Include "inf-ptrace.h".
7408 (linux_nat_target): New.
7409 (linux_target, linux_target_install_ops, linux_nat_add_target):
7410 Delete function declarations.
7411 (linux_target): Declare global.
7412 * linux-thread-db.c (thread_db_target): New.
7413 (thread_db_target::thread_db_target): New.
7414 (thread_db_ops): Delete.
7415 (the_thread_db_target): New.
7416 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
7417 (thread_db_update_thread_list, thread_db_pid_to_str)
7418 (thread_db_extra_thread_info)
7419 (thread_db_thread_handle_to_thread_info)
7420 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
7421 (thread_db_resume): Refactor as methods of thread_db_target.
7422 (init_thread_db_ops): Delete.
7423 (_initialize_thread_db): Remove reference to init_thread_db_ops.
7424 * x86-linux-nat.c: Don't include "linux-nat.h".
7425 (super_post_startup_inferior): Delete.
7426 (x86_linux_nat_target::~x86_linux_nat_target): New.
7427 (x86_linux_child_post_startup_inferior)
7428 (x86_linux_read_description, x86_linux_enable_btrace)
7429 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
7430 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
7431 methods of x86_linux_nat_target.
7432 (x86_linux_create_target): Delete. Bits folded ...
7433 (x86_linux_add_target): ... here. Now takes a linux_nat_target
7435 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
7436 (x86_linux_nat_target): New class.
7437 (x86_linux_create_target): Delete.
7438 (x86_linux_add_target): Now takes a linux_nat_target pointer.
7439 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
7440 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
7441 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
7442 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
7443 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
7445 (x86_use_watchpoints): Delete.
7446 * x86-nat.h: Include "breakpoint.h" and "target.h".
7447 (x86_use_watchpoints): Delete.
7448 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
7449 (x86_stopped_by_watchpoint, x86_stopped_data_address)
7450 (x86_insert_watchpoint, x86_remove_watchpoint)
7451 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
7452 (x86_stopped_by_hw_breakpoint): New declarations.
7453 (x86_nat_target): New template class.
7455 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
7456 (the_ppc_linux_nat_target): New.
7457 (ppc_linux_fetch_inferior_registers)
7458 (ppc_linux_can_use_hw_breakpoint)
7459 (ppc_linux_region_ok_for_hw_watchpoint)
7460 (ppc_linux_ranged_break_num_registers)
7461 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
7462 (ppc_linux_insert_mask_watchpoint)
7463 (ppc_linux_remove_mask_watchpoint)
7464 (ppc_linux_can_accel_watchpoint_condition)
7465 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
7466 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
7467 (ppc_linux_watchpoint_addr_within_range)
7468 (ppc_linux_masked_watch_num_registers)
7469 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
7470 (ppc_linux_read_description): Refactor as methods of
7471 ppc_linux_nat_target.
7472 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
7474 * procfs.c (procfs_xfer_partial): Delete forward declaration.
7475 (procfs_target): New class.
7476 (the_procfs_target): New.
7477 (procfs_target): Delete function.
7478 (procfs_auxv_parse, procfs_attach, procfs_detach)
7479 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
7480 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
7481 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
7482 (procfs_create_inferior, procfs_update_thread_list)
7483 (procfs_thread_alive, procfs_pid_to_str)
7484 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
7485 (procfs_stopped_data_address, procfs_insert_watchpoint)
7486 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
7487 (proc_find_memory_regions, procfs_info_proc)
7488 (procfs_make_note_section): Refactor as methods of procfs_target.
7489 (_initialize_procfs): Adjust.
7490 * sol-thread.c (sol_thread_target): New class.
7491 (sol_thread_ops): Now a sol_thread_target.
7492 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
7493 (sol_thread_fetch_registers, sol_thread_store_registers)
7494 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
7495 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
7496 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
7497 (init_sol_thread_ops): Delete.
7498 (_initialize_sol_thread): Adjust. Remove references to
7499 init_sol_thread_ops and complete_target_initialization.
7501 * windows-nat.c (windows_nat_target): New class.
7502 (windows_fetch_inferior_registers)
7503 (windows_store_inferior_registers, windows_resume, windows_wait)
7504 (windows_attach, windows_detach, windows_pid_to_exec_file)
7505 (windows_files_info, windows_create_inferior)
7506 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
7507 (windows_close, windows_pid_to_str, windows_xfer_partial)
7508 (windows_get_tib_address, windows_get_ada_task_ptid)
7509 (windows_thread_name, windows_thread_alive): Refactor as
7510 windows_nat_target methods.
7511 (do_initial_windows_stuff): Adjust.
7512 (windows_target): Delete function.
7513 (_initialize_windows_nat): Adjust.
7515 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
7516 (darwin_mourn_inferior, darwin_kill_inferior)
7517 (darwin_create_inferior, darwin_attach, darwin_detach)
7518 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
7519 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
7520 (darwin_supports_multi_process): Refactor as darwin_nat_target
7522 (darwin_resume_to, darwin_files_info): Delete.
7523 (_initialize_darwin_inferior): Rename to ...
7524 (_initialize_darwin_nat): ... this. Adjust to C++ification.
7525 * darwin-nat.h: Include "inf-child.h".
7526 (darwin_nat_target): New class.
7527 (darwin_complete_target): Delete.
7528 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
7529 (darwin_target): New.
7530 (i386_darwin_fetch_inferior_registers)
7531 (i386_darwin_store_inferior_registers): Refactor as methods of
7533 (darwin_complete_target): Delete, with ...
7534 (_initialize_i386_darwin_nat): ... bits factored out here.
7536 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
7537 (the_alpha_linux_nat_target): New.
7538 (alpha_linux_register_u_offset): Refactor as
7539 alpha_linux_nat_target method.
7540 (_initialize_alpha_linux_nat): Adjust.
7541 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
7542 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
7543 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
7544 methods of linux_nat_trad_target.
7545 (linux_trad_target): Delete.
7546 * linux-nat-trad.h (linux_trad_target): Delete function.
7547 (linux_nat_trad_target): New class.
7548 * mips-linux-nat.c (mips_linux_nat_target): New class.
7549 (super_fetch_registers, super_store_registers, super_close):
7551 (the_mips_linux_nat_target): New.
7552 (mips64_linux_regsets_fetch_registers)
7553 (mips64_linux_regsets_store_registers)
7554 (mips64_linux_fetch_registers, mips64_linux_store_registers)
7555 (mips_linux_register_u_offset, mips_linux_read_description)
7556 (mips_linux_can_use_hw_breakpoint)
7557 (mips_linux_stopped_by_watchpoint)
7558 (mips_linux_stopped_data_address)
7559 (mips_linux_region_ok_for_hw_watchpoint)
7560 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
7561 (mips_linux_close): Refactor as methods of mips_linux_nat.
7562 (_initialize_mips_linux_nat): Adjust to C++ification.
7564 * aix-thread.c (aix_thread_target): New class.
7565 (aix_thread_ops): Now an aix_thread_target.
7566 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
7567 (aix_thread_fetch_registers, aix_thread_store_registers)
7568 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
7569 (aix_thread_thread_alive, aix_thread_pid_to_str)
7570 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
7571 Refactor as methods of aix_thread_target.
7572 (init_aix_thread_ops): Delete.
7573 (_initialize_aix_thread): Remove references to init_aix_thread_ops
7574 and complete_target_initialization.
7575 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
7576 (rs6000_nat_target): New class.
7577 (the_rs6000_nat_target): New.
7578 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
7579 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
7580 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
7581 (super_create_inferior): Delete.
7582 (_initialize_rs6000_nat): Adjust to C++ification.
7584 * arm-linux-nat.c (arm_linux_nat_target): New class.
7585 (the_arm_linux_nat_target): New.
7586 (arm_linux_fetch_inferior_registers)
7587 (arm_linux_store_inferior_registers, arm_linux_read_description)
7588 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
7589 (arm_linux_remove_hw_breakpoint)
7590 (arm_linux_region_ok_for_hw_watchpoint)
7591 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
7592 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
7593 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
7594 arm_linux_nat_target.
7595 (_initialize_arm_linux_nat): Adjust to C++ification.
7597 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
7598 (the_aarch64_linux_nat_target): New.
7599 (aarch64_linux_fetch_inferior_registers)
7600 (aarch64_linux_store_inferior_registers)
7601 (aarch64_linux_child_post_startup_inferior)
7602 (aarch64_linux_read_description)
7603 (aarch64_linux_can_use_hw_breakpoint)
7604 (aarch64_linux_insert_hw_breakpoint)
7605 (aarch64_linux_remove_hw_breakpoint)
7606 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
7607 (aarch64_linux_region_ok_for_hw_watchpoint)
7608 (aarch64_linux_stopped_data_address)
7609 (aarch64_linux_stopped_by_watchpoint)
7610 (aarch64_linux_watchpoint_addr_within_range)
7611 (aarch64_linux_can_do_single_step): Refactor as methods of
7612 aarch64_linux_nat_target.
7613 (super_post_startup_inferior): Delete.
7614 (_initialize_aarch64_linux_nat): Adjust to C++ification.
7616 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
7617 (the_hppa_linux_nat_target): New.
7618 (hppa_linux_fetch_inferior_registers)
7619 (hppa_linux_store_inferior_registers): Refactor as methods of
7620 hppa_linux_nat_target.
7621 (_initialize_hppa_linux_nat): Adjust to C++ification.
7623 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
7624 (the_ia64_linux_nat_target): New.
7625 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
7626 (ia64_linux_stopped_data_address)
7627 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
7628 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
7629 ia64_linux_nat_target methods.
7630 (super_xfer_partial): Delete.
7631 (_initialize_ia64_linux_nat): Adjust to C++ification.
7633 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
7634 (the_m32r_linux_nat_target): New.
7635 (m32r_linux_fetch_inferior_registers)
7636 (m32r_linux_store_inferior_registers): Refactor as
7637 m32r_linux_nat_target methods.
7638 (_initialize_m32r_linux_nat): Adjust to C++ification.
7640 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
7641 (the_m68k_linux_nat_target): New.
7642 (m68k_linux_fetch_inferior_registers)
7643 (m68k_linux_store_inferior_registers): Refactor as
7644 m68k_linux_nat_target methods.
7645 (_initialize_m68k_linux_nat): Adjust to C++ification.
7647 * s390-linux-nat.c (s390_linux_nat_target): New class.
7648 (the_s390_linux_nat_target): New.
7649 (s390_linux_fetch_inferior_registers)
7650 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
7651 (s390_insert_watchpoint, s390_remove_watchpoint)
7652 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
7653 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
7654 (s390_auxv_parse, s390_read_description): Refactor as methods of
7655 s390_linux_nat_target.
7656 (_initialize_s390_nat): Adjust to C++ification.
7658 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
7659 (the_sparc_linux_nat_target): New.
7660 (_initialize_sparc_linux_nat): Adjust to C++ification.
7661 * sparc-nat.c (sparc_fetch_inferior_registers)
7662 (sparc_store_inferior_registers): Remove target_ops parameter.
7663 * sparc-nat.h (sparc_fetch_inferior_registers)
7664 (sparc_store_inferior_registers): Remove target_ops parameter.
7665 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
7666 (the_sparc64_linux_nat_target): New.
7667 (_initialize_sparc64_linux_nat): Adjust to C++ification.
7669 * spu-linux-nat.c (spu_linux_nat_target): New class.
7670 (the_spu_linux_nat_target): New.
7671 (spu_child_post_startup_inferior, spu_child_post_attach)
7672 (spu_child_wait, spu_fetch_inferior_registers)
7673 (spu_store_inferior_registers, spu_xfer_partial)
7674 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
7676 (_initialize_spu_nat): Adjust to C++ification.
7678 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
7679 (the_tilegx_linux_nat_target): New.
7680 (fetch_inferior_registers, store_inferior_registers):
7681 Refactor as methods.
7682 (_initialize_tile_linux_nat): Adjust to C++ification.
7684 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
7685 (the_xtensa_linux_nat_target): New.
7686 (xtensa_linux_fetch_inferior_registers)
7687 (xtensa_linux_store_inferior_registers): Refactor as
7688 xtensa_linux_nat_target methods.
7689 (_initialize_xtensa_linux_nat): Adjust to C++ification.
7691 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
7692 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
7693 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
7694 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
7695 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
7696 (fbsd_stopped_by_sw_breakpoint)
7697 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
7698 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
7699 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
7700 (fbsd_post_startup_inferior, fbsd_post_attach)
7701 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
7702 (fbsd_set_syscall_catchpoint)
7703 (super_xfer_partial, super_resume, super_wait)
7704 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
7705 (fbsd_handle_debug_trap): Remove target_ops parameter.
7706 (fbsd_nat_add_target): Delete.
7707 * fbsd-nat.h: Include "inf-ptrace.h".
7708 (fbsd_nat_add_target): Delete.
7709 (USE_SIGTRAP_SIGINFO): Define.
7710 (fbsd_nat_target): New class.
7712 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
7713 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
7714 (amd64bsd_target): Delete.
7715 * amd64-bsd-nat.h: New file.
7716 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
7718 (amd64_fbsd_nat_target): New class.
7719 (the_amd64_fbsd_nat_target): New.
7720 (amd64fbsd_read_description): Refactor as method of
7721 amd64_fbsd_nat_target.
7722 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
7723 (_initialize_amd64fbsd_nat): Adjust to C++ification.
7724 * amd64-nat.h (amd64bsd_target): Delete function declaration.
7725 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
7726 (i386bsd_store_inferior_registers): Remove target_ops parameter.
7727 (i386bsd_target): Delete.
7728 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
7729 (i386bsd_fetch_inferior_registers)
7730 (i386bsd_store_inferior_registers): Declare.
7731 (i386_bsd_nat_target): New class.
7732 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
7733 (the_i386_fbsd_nat_target): New.
7734 (i386fbsd_resume, i386fbsd_read_description): Refactor as
7735 i386_fbsd_nat_target methods.
7736 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
7737 (_initialize_i386fbsd_nat): Adjust to C++ification.
7738 * x86-bsd-nat.c (super_mourn_inferior): Delete.
7739 (x86bsd_mourn_inferior, x86bsd_target): Delete.
7740 (_initialize_x86_bsd_nat): Adjust to C++ification.
7741 * x86-bsd-nat.h: Include "x86-nat.h".
7742 (x86bsd_target): Delete declaration.
7743 (x86bsd_nat_target): New class.
7745 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
7746 (the_aarch64_fbsd_nat_target): New.
7747 (aarch64_fbsd_fetch_inferior_registers)
7748 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
7749 aarch64_fbsd_nat_target.
7750 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
7751 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
7752 (the_alpha_bsd_nat_target): New.
7753 (alphabsd_fetch_inferior_registers)
7754 (alphabsd_store_inferior_registers): Refactor as
7755 alpha_bsd_nat_target methods.
7756 (_initialize_alphabsd_nat): Refactor as methods of
7757 alpha_bsd_nat_target.
7758 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
7759 (the_amd64_nbsd_nat_target): New.
7760 (_initialize_amd64nbsd_nat): Adjust to C++ification.
7761 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
7762 (the_amd64_obsd_nat_target): New.
7763 (_initialize_amd64obsd_nat): Adjust to C++ification.
7764 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
7765 (the_arm_fbsd_nat_target): New.
7766 (arm_fbsd_fetch_inferior_registers)
7767 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
7768 (_initialize_arm_fbsd_nat): Refactor as methods of
7769 arm_fbsd_nat_target.
7770 (_initialize_arm_fbsd_nat): Adjust to C++ification.
7771 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
7772 (the_arm_netbsd_nat_target): New.
7773 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
7774 arm_netbsd_nat_target.
7775 (_initialize_arm_netbsd_nat): Adjust to C++ification.
7776 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
7777 (the_hppa_nbsd_nat_target): New.
7778 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
7779 hppa_nbsd_nat_target methods.
7780 (_initialize_hppanbsd_nat): Adjust to C++ification.
7781 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
7782 (the_hppa_obsd_nat_target): New.
7783 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
7784 methods of hppa_obsd_nat_target.
7785 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
7787 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
7788 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
7790 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
7791 (_initialize_i386obsd_nat): Use add_target.
7792 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
7793 (the_m68k_bsd_nat_target): New.
7794 (m68kbsd_fetch_inferior_registers)
7795 (m68kbsd_store_inferior_registers): Refactor as methods of
7796 m68k_bsd_nat_target.
7797 (_initialize_m68kbsd_nat): Adjust to C++ification.
7798 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
7799 (the_mips_fbsd_nat_target): New.
7800 (mips_fbsd_fetch_inferior_registers)
7801 (mips_fbsd_store_inferior_registers): Refactor as methods of
7802 mips_fbsd_nat_target.
7803 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
7805 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
7806 (the_mips_nbsd_nat_target): New.
7807 (mipsnbsd_fetch_inferior_registers)
7808 (mipsnbsd_store_inferior_registers): Refactor as methods of
7809 mips_nbsd_nat_target.
7810 (_initialize_mipsnbsd_nat): Adjust to C++ification.
7811 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
7812 (the_mips64_obsd_nat_target): New.
7813 (mips64obsd_fetch_inferior_registers)
7814 (mips64obsd_store_inferior_registers): Refactor as methods of
7815 mips64_obsd_nat_target.
7816 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
7818 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
7820 * nbsd-nat.h: Include "inf-ptrace.h".
7821 (nbsd_nat_target): New class.
7822 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
7823 (obsd_wait): Refactor as methods of obsd_nat_target.
7824 (obsd_add_target): Delete.
7825 * obsd-nat.h: Include "inf-ptrace.h".
7826 (obsd_nat_target): New class.
7827 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
7828 (the_ppc_fbsd_nat_target): New.
7829 (ppcfbsd_fetch_inferior_registers)
7830 (ppcfbsd_store_inferior_registers): Refactor as methods of
7831 ppc_fbsd_nat_target.
7832 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
7834 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
7835 (the_ppc_nbsd_nat_target): New.
7836 (ppcnbsd_fetch_inferior_registers)
7837 (ppcnbsd_store_inferior_registers): Refactor as methods of
7838 ppc_nbsd_nat_target.
7839 (_initialize_ppcnbsd_nat): Adjust to C++ification.
7840 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
7841 (the_ppc_obsd_nat_target): New.
7842 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
7843 methods of ppc_obsd_nat_target.
7844 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
7846 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
7847 (the_sh_nbsd_nat_target): New.
7848 (shnbsd_fetch_inferior_registers)
7849 (shnbsd_store_inferior_registers): Refactor as methods of
7851 (_initialize_shnbsd_nat): Adjust to C++ification.
7852 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
7853 (inf_ptrace_xfer_partial): Delete.
7854 (sparc_xfer_partial, sparc_target): Delete.
7855 * sparc-nat.h (sparc_fetch_inferior_registers)
7856 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
7857 (sparc_target): Delete function declaration.
7858 (sparc_target): New template class.
7859 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
7860 (_initialize_sparcnbsd_nat): Adjust to C++ification.
7861 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
7862 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
7864 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
7865 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
7866 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
7867 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
7869 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
7870 (the_vax_bsd_nat_target): New.
7871 (vaxbsd_fetch_inferior_registers)
7872 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
7874 (_initialize_vaxbsd_nat): Adjust to C++ification.
7876 * bsd-kvm.c (bsd_kvm_target): New class.
7877 (bsd_kvm_ops): Now a bsd_kvm_target.
7878 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
7879 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
7880 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
7882 (bsd_kvm_return_one): Delete.
7883 (bsd_kvm_add_target): Adjust to C++ification.
7885 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
7886 (nto_procfs_target_procfs): New classes.
7887 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
7888 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
7889 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
7890 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
7891 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
7892 (procfs_remove_hw_breakpoint, procfs_resume)
7893 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
7894 (procfs_kill_inferior, procfs_store_registers)
7895 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
7896 as methods of nto_procfs_target.
7897 (nto_procfs_ops): Now an nto_procfs_target_procfs.
7898 (nto_native_ops): Delete.
7899 (procfs_open, procfs_native_open): Delete.
7900 (nto_native_ops): Now an nto_procfs_target_native.
7901 (init_procfs_targets): Adjust to C++ification.
7902 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
7903 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
7904 Refactor as methods of nto_procfs_target.
7906 * go32-nat.c (go32_nat_target): New class.
7907 (the_go32_nat_target): New.
7908 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
7909 (go32_store_registers, go32_xfer_partial, go32_files_info)
7910 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
7911 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
7912 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
7913 (go32_pid_to_str): Refactor as methods of go32_nat_target.
7914 (go32_target): Delete.
7915 (_initialize_go32_nat): Adjust to C++ification.
7917 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
7918 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
7919 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
7920 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
7922 (gnu_target): Delete.
7923 * gnu-nat.h (gnu_target): Delete.
7924 (gnu_nat_target): New class.
7925 * i386-gnu-nat.c (gnu_base_target): New.
7926 (i386_gnu_nat_target): New class.
7927 (the_i386_gnu_nat_target): New.
7928 (_initialize_i386gnu_nat): Adjust to C++ification.
7930 2018-05-02 Pedro Alves <palves@redhat.com>
7932 * bfd-target.c (target_bfd_xclose): Rename to ...
7933 (target_bfd_close): ... this.
7934 (target_bfd_reopen): Adjust.
7935 * target.c (target_close): Remove references to to_xclose.
7936 * target.h (target_ops::to_xclose): Delete.
7937 (target_ops::to_close): Update comments.
7939 2018-05-02 Pedro Alves <palves@redhat.com>
7941 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
7943 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
7944 * inf-ptrace.c (inf_ptrace_register_u_offset)
7945 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
7946 (inf_ptrace_store_register, inf_ptrace_store_registers)
7947 (inf_ptrace_trad_target): Move to ...
7948 * linux-nat-trad.c: ... this new file.
7949 * linux-nat-trad.h: New file.
7950 * linux-nat.c (linux_target_install_ops): Make extern.
7951 (linux_trad_target): Delete.
7952 * linux-nat.h (linux_trad_target): Delete declaration.
7953 (linux_target_install_ops): Declare.
7954 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
7957 2018-05-02 Pedro Alves <palves@redhat.com>
7959 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7960 procfs_target/add_target here.
7961 * procfs.c (procfs_target): Make static.
7962 (_initialize_procfs): Call add_target here.
7963 * procfs.h (struct target_ops): Remove forward declaration.
7964 (procfs_target): Remove declaration.
7965 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
7967 2018-05-02 Pedro Alves <palves@redhat.com>
7969 * procfs.c (procfs_stopped_by_watchpoint)
7970 (procfs_insert_watchpoint, procfs_remove_watchpoint)
7971 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
7973 (procfs_use_watchpoints): Delete, move contents...
7974 (procfs_target): ... here.
7975 * procfs.h (procfs_use_watchpoints): Delete declaration.
7976 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
7977 procfs_use_watchpoints.
7978 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
7979 procfs_use_watchpoints.
7981 2018-05-02 Tom Tromey <tom@tromey.com>
7984 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
7985 and var_zuinteger_unlimited.
7986 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
7987 and PARAM_ZUINTEGER_UNLIMITED.
7988 (set_parameter_value): Handle var_zuinteger and
7989 var_zuinteger_unlimited.
7990 (add_setshow_generic): Likewise.
7991 (parmpy_init): Likewise.
7993 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
7996 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
7997 pointer is not null before dereferencing it.
7999 2018-04-30 Tom Tromey <tom@tromey.com>
8001 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8004 2018-04-30 Tom Tromey <tom@tromey.com>
8006 * breakpoint.c (mention): Remove use of is_mi_like_p.
8007 (print_mention_ranged_breakpoint): Likewise.
8008 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8011 2018-04-30 Tom Tromey <tom@tromey.com>
8013 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8015 2018-04-30 Tom Tromey <tom@tromey.com>
8017 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8018 (info_spu_event_command): Remove some uses of is_mi_like_p.
8020 2018-04-30 Tom Tromey <tom@tromey.com>
8022 * python/py-framefilter.c (py_print_single_arg)
8023 (enumerate_locals, py_print_args, py_print_frame): Remove some
8024 uses of is_mi_like_p.
8026 2018-04-30 Tom Tromey <tom@tromey.com>
8029 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8030 * ui-out.h (ui_out::is_mi_like_p): Now const.
8031 (ui_out::do_is_mi_like_p): Now const.
8032 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8034 2018-04-30 Tom Tromey <tom@tromey.com>
8036 * varobj.c (varobj_set_visualizer): Use new_reference.
8037 * python/python.c (gdbpy_decode_line): Use new_reference.
8038 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8041 2018-04-30 Tom Tromey <tom@tromey.com>
8043 * varobj.c (install_new_value): Use new_reference.
8044 * value.h (value_incref): Return void. Swap intro comment with
8046 * value.c (set_value_parent): Use new_reference.
8047 (value_incref): Return void. Update intro comment.
8048 (release_value): Use new_reference.
8049 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8051 2018-04-30 Tom Tromey <tom@tromey.com>
8053 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8054 * gdb_bfd.h (new_bfd_ref): Remove.
8055 (gdb_bfd_open): Update comment.
8056 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8057 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8058 (gdb_bfd_fdopenr): Use new_reference.
8059 * exec.c (exec_file_attach): Use new_reference.
8061 2018-04-30 Tom Tromey <tom@tromey.com>
8063 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8066 2018-04-30 Tom Tromey <tom@tromey.com>
8068 * jit.c (jit_read_code_entry): Use type_align.
8069 * i386-tdep.c (i386_gdbarch_init): Don't call
8070 set_gdbarch_long_long_align_bit.
8071 * gdbarch.sh: Remove long_long_align_bit.
8072 * gdbarch.c, gdbarch.h: Rebuild.
8073 * arc-tdep.c (arc_type_align): New function.
8074 (arc_gdbarch_init): Use arc_type_align. Don't call
8075 set_gdbarch_long_long_align_bit.
8077 2018-04-30 Tom Tromey <tom@tromey.com>
8079 * rust-lang.c (rust_type_alignment): Remove.
8080 (rust_composite_type): Use type_align.
8082 2018-04-30 Tom Tromey <tom@tromey.com>
8084 * NEWS: Mention Type.align.
8085 * python/py-type.c (typy_get_alignof): New function.
8086 (type_object_getset): Add "alignof".
8088 2018-04-30 Tom Tromey <tom@tromey.com>
8092 * std-operator.def (UNOP_ALIGNOF): New operator.
8093 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
8095 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
8096 * c-lang.c (c_op_print_tab): Add alignof.
8097 * c-exp.y (ALIGNOF): New token.
8098 (exp): Add "ALIGNOF" production.
8099 (ident_tokens): Add _Alignof and alignof.
8101 2018-04-30 Tom Tromey <tom@tromey.com>
8103 * i386-tdep.c (i386_type_align): New function.
8104 (i386_gdbarch_init): Update.
8105 * gdbarch.sh (type_align): New method.
8106 * gdbarch.c, gdbarch.h: Rebuild.
8107 * arch-utils.h (default_type_align): Declare.
8108 * arch-utils.c (default_type_align): New function.
8109 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
8110 (struct type) <align_log2>: New field.
8111 <instance_flags>: Now a bitfield.
8112 (TYPE_RAW_ALIGN): New macro.
8113 (type_align, type_raw_align, set_type_align): Declare.
8114 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
8116 * dwarf2read.c (quirk_rust_enum): Set type alignment.
8117 (get_alignment, maybe_set_alignment): New functions.
8118 (read_structure_type, read_enumeration_type, read_array_type)
8119 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
8120 (read_subrange_type, read_base_type): Set type alignment.
8122 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
8124 * dwarf2read.c (read_index_from_section): Use bool.
8126 2018-04-29 Fabian Groffen <grobian@gentoo.org>
8129 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
8132 2018-04-29 John Reiser <jreiser@BitWagon.com>
8135 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
8136 last step, and do it atomically.
8138 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
8140 * compile/compile-c-types.c (convert_int, convert_float):
8143 2018-04-27 Tom Tromey <tom@tromey.com>
8146 * rust-lang.c (rust_inclusive_range_type_p): New function.
8147 (rust_range): Handle inclusive ranges.
8148 (rust_compute_range): Likewise.
8149 * rust-exp.y (struct rust_op) <inclusive>: New field.
8150 (DOTDOTEQ): New constant.
8151 (range_expr): Add "..=" productions.
8152 (operator_tokens): Add "..=" token.
8153 (ast_range): Add "inclusive" parameter.
8154 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
8156 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
8158 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
8159 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
8161 * expprint.c (print_subexp_standard): Handle new bounds values.
8162 (dump_subexp_body_standard): Likewise.
8164 2018-04-27 Tom Tromey <tom@tromey.com>
8166 * configure: Rebuild.
8167 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
8168 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
8170 (class symbol_needs_eval_context): Likewise.
8171 * dwarf2read.c (mock_mapped_index::symbol_name_count)
8172 (mock_mapped_index::symbol_name_at): Use "override". Remove
8174 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
8176 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
8177 * aarch64-tdep.c (instruction_reader::read): Use "override".
8178 (instruction_reader_test::read): Likewise.
8179 * arm-tdep.c (instruction_reader::read): Use "override".
8180 (instruction_reader_thumb::read): Likewise.
8182 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
8185 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
8186 instead of remote_send.
8187 (remote_send): Remove.
8189 2018-04-26 Pedro Alves <palves@redhat.com>
8191 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
8192 find_function_start_sal instead of find_pc_line.
8194 2018-04-26 Pedro Alves <palves@redhat.com>
8196 * breakpoint.c (set_breakpoint_location_function): Handle
8198 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
8199 * elfread.c (elf_symtab_read): Give data symbols with
8200 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
8201 (elf_rel_plt_read): Update comment.
8202 * linespec.c (convert_linespec_to_sals): Handle
8204 (minsym_found): Handle mst_data_gnu_ifunc.
8205 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
8206 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
8207 * parse.c (find_minsym_type_and_address): Handle
8209 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
8210 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
8211 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
8213 <mst_data_gnu_ifunc>: New enumerator.
8215 2018-04-26 Pedro Alves <palves@redhat.com>
8217 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
8218 (lookup_minimal_symbol_by_pc_section): ... this. Replace
8219 'want_trampoline' parameter by a lookup_msym_prefer parameter.
8221 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
8222 (lookup_minimal_symbol_by_pc): Adjust.
8223 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
8224 (lookup_solib_trampoline_symbol_by_pc): Adjust.
8225 * minsyms.h (lookup_msym_prefer): New enum.
8226 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8227 parameter by a lookup_msym_prefer parameter.
8229 2018-04-26 Pedro Alves <palves@redhat.com>
8231 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
8232 ends in "@plt" instead of looking at the symbol's section.
8234 2018-04-26 Pedro Alves <palves@redhat.com>
8236 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
8238 (find_pc_partial_function_gnu_ifunc): Rename to ...
8239 (find_pc_partial_function): ... this, and remove references to
8241 (find_pc_partial_function): Delete old implementation.
8242 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
8244 2018-04-26 Pedro Alves <palves@redhat.com>
8246 * linespec.c (struct bound_minimal_symbol_search_key): New.
8247 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
8248 skip first line if we found a GNU ifunc minimal symbol by name.
8249 (compare_msymbols): Change parameters to work with a destructured
8251 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
8254 2018-04-26 Pedro Alves <palves@redhat.com>
8256 * breakpoint.c (set_breakpoint_location_function): Don't resolve
8257 ifunc targets here. Instead, if we have an ifunc minsym, use its
8259 (add_location_to_breakpoint): Store the minsym and the objfile in
8260 the breakpoint location.
8261 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
8262 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
8263 Record the minsym in the sal.
8264 * symtab.h (symtab_and_line) <msymbol>: New field.
8266 2018-04-26 Pedro Alves <palves@redhat.com>
8268 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
8269 unless we actually resolved the ifunc.
8271 2018-04-26 Pedro Alves <palves@redhat.com>
8273 * c-exp.y (variable production): Prefer ifunc minsyms over
8274 regular function symbols.
8275 * symtab.c (find_gnu_ifunc): New function.
8276 * minsyms.h (lookup_msym_prefer): New enum.
8277 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
8278 parameter by a lookup_msym_prefer parameter.
8279 * symtab.h (find_gnu_ifunc): New declaration.
8281 2018-04-26 Pedro Alves <palves@redhat.com>
8283 * blockframe.c (find_gnu_ifunc_target_type): New function.
8284 (find_function_type): New.
8285 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
8286 return a value with a memory address.
8287 (eval_call): For calls to GNU ifunc functions, try to find the
8288 type of the target function from the type that the resolver
8290 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
8292 * infcall.c (find_function_return_type): Delete.
8293 (find_function_addr): Add 'function_type' parameter. For calls to
8294 GNU ifunc functions, try to find the type of the target function
8295 from the type that the resolver returns, and return it via
8297 (call_function_by_hand_dummy): Adjust to use the function type
8298 returned by find_function_addr.
8299 (find_function_addr): Add 'function_type' parameter and move
8301 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
8304 2018-04-26 Pedro Alves <palves@redhat.com>
8306 * c-exp.y (variable production): Skip finding an alias for ifunc
8309 2018-04-26 Pedro Alves <palves@redhat.com>
8311 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
8313 2018-04-25 Pedro Alves <palves@redhat.com>
8315 * infcmd.c (kill_command): Print the pid as string, not the whole
8316 thread's ptid. Add comment. s/has been killed/killed/ in output
8318 * remote.c (remote_detach_1): Print the pid as string, not the
8319 whole thread's ptid.
8321 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8322 Sergio Durigan Junior <sergiodj@redhat.com>
8323 Pedro Alves <palves@redhat.com>
8325 * infcmd.c (kill_command): Print message when inferior has
8327 * inferior.c (print_inferior_events): Remove 'static'. Set as
8329 (add_inferior): Improve message printed when
8330 'print_inferior_events' is on.
8331 (exit_inferior): Remove message printed when
8332 'print_inferior_events' is on.
8333 (detach_inferior): Improve message printed when
8334 'print_inferior_events' is on.
8335 (initialize_inferiors): Use 'add_inferior_silent' to set
8336 'current_inferior_'.
8337 * inferior.h (print_inferior_events): Declare here as
8339 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
8340 '[Detaching...]' messages when 'print_inferior_events' is on.
8341 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
8342 as prefix/suffix for messages. Remove periods. Fix erroneous
8343 'Detaching after fork from child...', replace it by '... from
8345 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
8346 prefix/suffix when printing 'Detaching...' messages. Print
8347 them when 'print_inferior_events' is on.
8348 * remote.c (remote_detach_1): Print message when detaching
8349 from inferior and '!is_fork_parent'.
8351 2018-04-24 Tom Tromey <tom@tromey.com>
8353 * cli-out.h: Reindent.
8355 2018-04-24 Tom Tromey <tom@tromey.com>
8357 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
8358 (cli_ui_out::do_field_string): Use fputs_filtered.
8359 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
8361 2018-04-23 Tom Tromey <tom@tromey.com>
8363 * guile/scm-frame.c (gdbscm_frame_read_var): Use
8364 gdb::unique_xmalloc_ptr.
8366 2018-04-23 Tom Tromey <tom@tromey.com>
8368 * configure: Rebuild.
8370 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
8373 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
8374 prepare_for_testing. Set normal_bp to r_debug_state if target
8377 2018-04-21 Pedro Alves <palves@redhat.com>
8378 Rajendra SY <rajendra.sy@gmail.com>
8380 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
8381 * remote.c (extended_remote_attach): In all-stop mode, mark the
8382 thread as executing.
8384 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8386 * thread.c (thread_apply_all_command): Fix comment.
8387 (thread_command): Fix comment.
8389 2018-04-10 Alan Hayward <alan.hayward@arm.com>
8391 * common/tdesc.h (tdesc_create_feature): Remove xml filename
8393 * features/aarch64-core.c (create_feature_aarch64_core):
8395 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
8397 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
8399 * features/i386/32bit-avx512.c
8400 (create_feature_i386_32bit_avx512): Likewise.
8401 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
8403 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
8405 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
8407 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
8409 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
8411 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
8413 * features/i386/64bit-avx512.c
8414 (create_feature_i386_64bit_avx512): Likewise.
8415 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
8417 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
8419 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
8421 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
8423 * features/i386/64bit-segments.c
8424 (create_feature_i386_64bit_segments): Likewise.
8425 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
8427 * features/i386/x32-core.c
8428 (create_feature_i386_x32_core): Likewise.
8429 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
8430 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
8431 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
8432 * target-descriptions.c: In generated code, don't pass xml
8435 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8437 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
8438 (print_xml_feature::visit_post): Likewise.
8439 (print_xml_feature::visit): Likewise.
8440 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
8441 (print_xml_feature): Add new class.
8442 * regformats/regdat.sh: Null xmltarget on feature targets.
8443 * target-descriptions.c (struct target_desc): Add xmltarget.
8444 (maintenance_check_tdesc_xml_convert): Add unittest function.
8445 (tdesc_get_features_xml): Add function to get xml.
8446 (maintenance_check_xml_descriptions): Test xml generation.
8447 * xml-tdesc.c (string_read_description_xml): Add function.
8448 * xml-tdesc.h (string_read_description_xml): Add declaration.
8450 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8452 * features/Makefile: Add feature marker to targets with new style
8453 target descriptions.
8454 * regformats/aarch64.dat: Regenerate.
8455 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
8456 * regformats/i386/amd64-avx-linux.dat: Likewise.
8457 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
8458 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
8459 * regformats/i386/amd64-linux.dat: Likewise.
8460 * regformats/i386/amd64-mpx-linux.dat: Likewise.
8461 * regformats/i386/amd64.dat: Likewise.
8462 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
8463 * regformats/i386/i386-avx-linux.dat: Likewise.
8464 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
8465 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
8466 * regformats/i386/i386-linux.dat: Likewise.
8467 * regformats/i386/i386-mmx-linux.dat: Likewise.
8468 * regformats/i386/i386-mpx-linux.dat: Likewise.
8469 * regformats/i386/i386.dat: Likewise.
8470 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
8471 * regformats/i386/x32-avx-linux.dat: Likewise.
8472 * regformats/i386/x32-linux.dat: Likewise.
8473 * regformats/tic6x-c62x-linux.dat: Likewise.
8474 * regformats/tic6x-c64x-linux.dat: Likewise.
8475 * regformats/tic6x-c64xp-linux.dat: Likewise.
8476 * regformats/regdat.sh: Parse feature marker.
8478 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8480 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
8481 (tdesc_osabi_name): Likewise.
8482 * target-descriptions.c (tdesc_architecture_name): Add new
8484 (tdesc_osabi_name): Likewise.
8486 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8488 * common/tdesc.c (tdesc_predefined_type): Move to here.
8489 (tdesc_named_type): Likewise.
8490 (tdesc_create_vector): Likewise.
8491 (tdesc_create_struct): Likewise.
8492 (tdesc_set_struct_size): Likewise.
8493 (tdesc_create_union): Likewise.
8494 (tdesc_create_flags): Likewise.
8495 (tdesc_create_enum): Likewise.
8496 (tdesc_add_field): Likewise.
8497 (tdesc_add_typed_bitfield): Likewise.
8498 (tdesc_add_bitfield): Likewise.
8499 (tdesc_add_flag): Likewise.
8500 (tdesc_add_enum_value): Likewise.
8501 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
8502 (struct tdesc_type_vector): Likewise.
8503 (struct tdesc_type_field): Likewise.
8504 (struct tdesc_type_with_fields): Likewise.
8505 (tdesc_create_enum): Add declaration.
8506 (tdesc_add_typed_bitfield): Likewise.
8507 (tdesc_add_enum_value): Likewise.
8508 * target-descriptions.c (tdesc_type_field): Move from here.
8509 (tdesc_type_builtin): Likewise.
8510 (tdesc_type_vector): Likewise.
8511 (tdesc_type_with_fields): Likewise.
8512 (tdesc_predefined_types): Likewise.
8513 (tdesc_named_type): Likewise.
8514 (tdesc_create_vector): Likewise.
8515 (tdesc_create_struct): Likewise.
8516 (tdesc_set_struct_size): Likewise.
8517 (tdesc_create_union): Likewise.
8518 (tdesc_create_flags): Likewise.
8519 (tdesc_create_enum): Likewise.
8520 (tdesc_add_field): Likewise.
8521 (tdesc_add_typed_bitfield): Likewise.
8522 (tdesc_add_bitfield): Likewise.
8523 (tdesc_add_flag): Likewise.
8524 (tdesc_add_enum_value): Likewise.
8525 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
8526 (tdesc_add_typed_bitfield): Likewise.
8527 (tdesc_add_enum_value): Likewise.
8529 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8531 * common/tdesc.c (tdesc_feature::accept): Move to here.
8532 (tdesc_feature::operator==): Likewise.
8533 (tdesc_create_reg): Likewise.
8534 * common/tdesc.h (tdesc_type_kind): Likewise.
8535 (struct tdesc_type): Likewise.
8536 (struct tdesc_feature): Likewise.
8537 * regformats/regdat.sh: Create a feature.
8538 * target-descriptions.c (tdesc_type_kind): Move from here.
8539 (tdesc_type): Likewise.
8540 (tdesc_type_up): Likewise.
8541 (tdesc_feature): Likewise.
8542 (tdesc_create_reg): Likewise.
8544 2018-04-18 Alan Hayward <alan.hayward@arm.com>
8546 * Makefile.in: Add arch/tdesc.c
8547 * common/tdesc.c: New file.
8548 * common/tdesc.h (tdesc_element_visitor): Move to here.
8549 (tdesc_element): Likewise.
8550 (tdesc_reg): Likewise.
8551 (tdesc_reg_up): Likewise.
8552 * regformats/regdef.h (reg): Add offset to constructors.
8553 * target-descriptions.c (tdesc_element_visitor): Move from here.
8554 (tdesc_element): Likewise.
8555 (tdesc_reg): Likewise.
8556 (tdesc_reg_up): Likewise.
8558 2018-04-17 Tom Tromey <tom@tromey.com>
8560 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
8563 2018-04-17 Tom Tromey <tom@tromey.com>
8565 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
8567 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
8569 * symtab.c (print_symbol_info): Skip printing filename and line
8570 number when `last' is NULL.
8571 (symtab_symbol_info): Use empty string instead of NULL for first
8572 invocation of print_symbol_info.
8573 (rbreak_command): Pass NULL to `last' parameter of
8576 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
8578 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
8581 2018-04-16 Pedro Alves <palves@redhat.com>
8583 * MAINTAINERS (sh): Remove.
8584 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
8585 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
8586 (ALLDEPFILES): Remove sh64-tdep.c.
8587 * NEWS: Mentions that support for SH-5/SH64 is removed.
8588 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
8589 (sh*-*-openbsd*): Ditto.
8590 (sh64-*-elf*): Remove.
8592 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
8593 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
8594 * sh-tdep.c: No longer include "sh64-tdep.h".
8595 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
8596 * sh64-tdep.c, sh64-tdep.h: Remove files.
8598 2018-04-16 Pedro Alves <palves@redhat.com>
8600 * MAINTAINERS: Remove m88k.
8601 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
8602 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
8603 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
8604 * NEWS: Mention that support for m88k was removed.
8605 * configure.host (m88*-*-*): Remove support.
8606 * configure.nat (m88k-*-*): Remove support.
8607 * configure.tgt (m88*-*-openbsd*): Remove.
8608 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
8610 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
8612 * configure.tgt (x86_tobjs): New variable.
8613 (amd64_tobjs, i386_tobjs): Use it.
8615 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8617 * symtab.c (print_symbol_info): Precede the symbol definition by
8618 the line number when available.
8619 * NEWS: Advertise this enhancement.
8621 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8623 * NEWS (New options): announce set/show record btrace cpu.
8624 * btrace.c: Include record-btrace.h.
8625 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
8626 the vendor is unknown.
8627 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
8628 Maybe overwrite the btrace configuration's cpu.
8629 (btrace_compute_ftrace): Add cpu parameter. Update callers.
8630 (btrace_fetch): Add cpu parameter. Update callers.
8631 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
8632 Maybe overwrite the btrace configuration's cpu. Skip enabling
8633 errata workarounds if the vendor is unknown.
8634 * python/py-record-btrace.c: Include record-btrace.h.
8635 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
8636 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
8637 * record-btrace.c (record_btrace_cpu_state_kind): New.
8638 (record_btrace_cpu): New.
8639 (set_record_btrace_cpu_cmdlist): New.
8640 (record_btrace_get_cpu): New.
8641 (require_btrace_thread, record_btrace_info)
8642 (record_btrace_resume_thread): Call record_btrace_get_cpu.
8643 (cmd_set_record_btrace_cpu_none): New.
8644 (cmd_set_record_btrace_cpu_auto): New.
8645 (cmd_set_record_btrace_cpu): New.
8646 (cmd_show_record_btrace_cpu): New.
8647 (_initialize_record_btrace): Initialize set/show record btrace cpu
8649 * record-btrace.h (record_btrace_get_cpu): New.
8651 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8653 * record.c (set_record_command): Fix typo in message.
8655 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8657 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
8659 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
8661 * infrun.c (process_event_stop_test): Call
8662 gdbarch_in_indirect_branch_thunk.
8663 * gdbarch.sh (in_indirect_branch_thunk): New.
8664 * gdbarch.c: Regenerated.
8665 * gdbarch.h: Regenerated.
8668 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
8669 (HFILES_NO_SRCDIR): Add x86-tdep.h.
8670 (ALLDEPFILES): Add x86-tdep.c.
8671 * arch-utils.h (default_in_indirect_branch_thunk): New.
8672 * arch-utils.c (default_in_indirect_branch_thunk): New.
8673 * i386-tdep: Include x86-tdep.h.
8674 (i386_in_indirect_branch_thunk): New.
8675 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
8677 * amd64-tdep: Include x86-tdep.h.
8678 (amd64_in_indirect_branch_thunk): New.
8679 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
8681 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
8684 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
8685 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
8686 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
8689 2018-04-12 Tom Tromey <tom@tromey.com>
8691 * rust-lang.c (rust_print_struct_def): Remove univariant code.
8692 (rust_evaluate_subexp): Likewise.
8694 2018-04-12 Pedro Alves <palves@redhat.com>
8696 * procfs.c (procfs_detach): Make forward declaration's prototype
8697 match definition's protototype.
8698 (proc_get_LDT_entry): Remove stale do_cleanups call.
8700 2018-04-12 Pedro Alves <palves@redhat.com>
8702 * target.h (target_ops::to_has_exited): Delete.
8703 (target_has_exited): Delete.
8704 * target-delegates.c: Regenerate.
8706 2018-04-11 Pedro Alves <palves@redhat.com>
8708 * target.c (fileio_fh_t::t): Add comment.
8709 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
8710 (target_fileio_close): Handle a NULL target.
8711 (invalidate_fileio_fh): New.
8712 (target_close): Call it.
8713 * remote.c (remote_hostio_send_command): No longer check whether
8714 remote_desc is open.
8716 2018-04-11 Pedro Alves <palves@redhat.com>
8718 * target.c (fileio_fh_t): Make it a named struct instead of a
8720 (fileio_fh_t::is_closed): New method.
8721 (DEF_VEC_O (fileio_fh_t)): Remove.
8722 (fileio_fhandles): Now a std::vector.
8723 (is_closed_fileio_fh): Delete.
8724 (acquire_fileio_fd): Adjust. Rename parameters.
8725 (release_fileio_fd): Adjust.
8726 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
8727 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
8728 (target_fileio_close): Adjust.
8730 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
8732 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
8735 2018-04-10 Pedro Alves <palves@redhat.com>
8737 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
8738 (scoped_finish_thread_state): New class.
8739 * infcmd.c (run_command_1): Use it instead of finish_thread_state
8741 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
8742 (fetch_inferior_event, normal_stop): Likewise.
8743 * thread.c (finish_thread_state_cleanup): Delete.
8745 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8746 Pedro Alves <palves@redhat.com>
8748 * value.c: Include "selftest.h" and "common/array-view.h".
8749 (struct range) <operator ==>: New.
8750 (test_ranges_contain): New.
8751 (check_ranges_vector): New.
8752 (test_insert_into_bit_range_vector): New.
8753 (_initialize_values): Register selftests.
8754 * common/array-view.h (operator==, operator!=): New.
8756 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8758 * common/gdb_vecs.h (unordered_remove): Add overload that takes
8760 * inline-frame.c: Include <algorithm>.
8761 (struct inline_state): Add constructor.
8762 (inline_state_s): Remove.
8763 (DEF_VEC_O(inline_state_s)): Remove.
8764 (inline_states): Change type to std::vector.
8765 (find_inline_frame_state): Adjust to std::vector.
8766 (allocate_inline_frame_state): Remove.
8767 (clear_inline_frame_state): Adjust to std::vector.
8768 (skip_inline_frames): Adjust to std::vector.
8770 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8772 * tracepoint.h (struct trace_state_variable): Add constructor.
8773 <name>: Change type to std::string.
8774 * tracepoint.c (tsv_s): Remove.
8775 (DEF_VEC_O(tsv_s)): Remove.
8776 (tvariables): Change to std::vector.
8777 (create_trace_state_variable): Adjust to std::vector.
8778 (find_trace_state_variable): Likewise.
8779 (find_trace_state_variable_by_number): Likewise.
8780 (delete_trace_state_variable): Likewise.
8781 (trace_variable_command): Adjust to std::string.
8782 (delete_trace_variable_command): Likewise.
8783 (tvariables_info_1): Adjust to std::vector.
8784 (save_trace_state_variables): Likewise.
8785 (start_tracing): Likewise.
8786 (merge_uploaded_trace_state_variables): Adjust to std::vector
8788 * target.h (struct target_ops)
8789 <to_download_trace_state_variable>: Pass reference to
8790 trace_state_variable.
8791 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
8792 * target-delegates.c: Re-generate.
8793 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
8794 (mi_tsv_deleted): Likewise.
8795 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
8796 * remote.c (remote_download_trace_state_variable): Change
8797 pointer to reference and adjust.
8798 * make-target-delegates (parse_argtypes): Handle references.
8799 (write_function_header): Likewise.
8800 (munge_type): Likewise.
8802 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8804 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8805 string_view-selftests.c.
8806 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
8808 * unittests/basic_string_view/cons/char/1.cc: Likewise.
8809 * unittests/basic_string_view/cons/char/2.cc: Likewise.
8810 * unittests/basic_string_view/cons/char/3.cc: Likewise.
8811 * unittests/basic_string_view/element_access/char/1.cc:
8813 * unittests/basic_string_view/element_access/char/empty.cc:
8815 * unittests/basic_string_view/element_access/char/front_back.cc:
8817 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
8818 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
8820 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
8822 * unittests/basic_string_view/modifiers/swap/char/1.cc:
8824 * unittests/basic_string_view/operations/compare/char/1.cc:
8826 * unittests/basic_string_view/operations/compare/char/13650.cc:
8828 * unittests/basic_string_view/operations/copy/char/1.cc:
8830 * unittests/basic_string_view/operations/data/char/1.cc:
8832 * unittests/basic_string_view/operations/find/char/1.cc:
8834 * unittests/basic_string_view/operations/find/char/2.cc:
8836 * unittests/basic_string_view/operations/find/char/3.cc:
8838 * unittests/basic_string_view/operations/find/char/4.cc:
8840 * unittests/basic_string_view/operations/rfind/char/1.cc:
8842 * unittests/basic_string_view/operations/rfind/char/2.cc:
8844 * unittests/basic_string_view/operations/rfind/char/3.cc:
8846 * unittests/basic_string_view/operations/substr/char/1.cc:
8848 * unittests/basic_string_view/operators/char/2.cc: Likewise.
8849 * unittests/string_view-selftests.c: New file.
8851 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8853 * unittests/basic_string_view/capacity/1.cc: New file.
8854 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
8855 * unittests/basic_string_view/cons/char/1.cc: New file.
8856 * unittests/basic_string_view/cons/char/2.cc: New file.
8857 * unittests/basic_string_view/cons/char/3.cc: New file.
8858 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
8859 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
8860 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
8861 * unittests/basic_string_view/element_access/char/1.cc: New file.
8862 * unittests/basic_string_view/element_access/char/2.cc: New file.
8863 * unittests/basic_string_view/element_access/char/empty.cc: New file.
8864 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
8865 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
8866 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
8867 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
8868 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
8869 * unittests/basic_string_view/include.cc: New file.
8870 * unittests/basic_string_view/inserters/char/1.cc: New file.
8871 * unittests/basic_string_view/inserters/char/2.cc: New file.
8872 * unittests/basic_string_view/inserters/char/3.cc: New file.
8873 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
8874 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
8875 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
8876 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
8877 * unittests/basic_string_view/literals/types.cc: New file.
8878 * unittests/basic_string_view/literals/values.cc: New file.
8879 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
8880 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
8881 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
8882 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
8883 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
8884 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
8885 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
8886 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
8887 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
8888 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
8889 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
8890 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
8891 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
8892 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
8893 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
8894 * unittests/basic_string_view/operations/data/char/1.cc: New file.
8895 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
8896 * unittests/basic_string_view/operations/find/char/1.cc: New file.
8897 * unittests/basic_string_view/operations/find/char/2.cc: New file.
8898 * unittests/basic_string_view/operations/find/char/3.cc: New file.
8899 * unittests/basic_string_view/operations/find/char/4.cc: New file.
8900 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
8901 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
8902 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
8903 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
8904 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
8905 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
8906 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
8907 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
8908 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
8909 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
8910 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
8911 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
8912 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
8913 * unittests/basic_string_view/operators/char/2.cc: New file.
8914 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
8915 * unittests/basic_string_view/range_access/char/1.cc: New file.
8916 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
8917 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
8918 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
8919 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
8920 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
8921 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
8922 * unittests/basic_string_view/requirements/typedefs.cc: New file.
8923 * unittests/basic_string_view/typedefs.cc: New file.
8924 * unittests/basic_string_view/types/1.cc: New file.
8926 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8928 * common/gdb_string_view.h: Remove libstdc++ implementation
8929 details, adjust to gdb reality.
8930 * common/gdb_string_view.tcc: Likewise.
8931 * cli/cli-script.c (struct string_view): Remove.
8932 (user_args) <m_args>: Change element type to gdb::string_view.
8933 (user_args::insert_args): Adjust.
8935 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8937 * common/gdb_string_view.h: New file.
8938 * common/gdb_string_view.tcc: New file.
8940 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8942 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
8943 * configure: Re-generate.
8945 2018-04-09 Pedro Alves <palves@redhat.com>
8947 * gdbarch.sh: Include "observable.h" instead of "observer.h".
8948 (set_target_gdbarch): Call
8949 gdb::observers::architecture_changed.notify instead of
8950 observer_notify_architecture_changed.
8952 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8954 * tracepoint.c (struct current_traceframe_cleanup): Remove.
8955 (do_restore_current_traceframe_cleanup): Remove.
8956 (restore_current_traceframe_cleanup_dtor): Remove.
8957 (make_cleanup_restore_current_traceframe): Remove.
8958 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
8960 * tracepoint.h (struct scoped_restore_current_traceframe): New.
8961 * infrun.c (fetch_inferior_event): Use
8962 scoped_restore_current_traceframe.
8964 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8966 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
8968 <n_allocated_type_units>: Remove.
8969 <all_type_units>: Change to std::vector.
8970 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8971 to std::vector change.
8972 (dwarf2_per_objfile::get_cutu): Likewise.
8973 (dwarf2_per_objfile::get_tu): Likewise.
8974 (create_signatured_type_table_from_index): Likewise.
8975 (create_signatured_type_table_from_debug_names): Likewise.
8976 (dw2_symtab_iter_next): Likewise.
8977 (dw2_print_stats): Likewise.
8978 (dw2_expand_all_symtabs): Likewise.
8979 (dw2_expand_marked_cus): Likewise.
8980 (dw2_debug_names_iterator::next): Likewise.
8981 (dwarf2_initialize_objfile): Likewise.
8982 (add_signatured_type_cu_to_table): Likewise.
8983 (create_all_type_units): Likewise.
8984 (add_type_unit): Likewise.
8985 (struct tu_abbrev_offset): Add constructor.
8986 (build_type_psymtabs_1): Adjust to std::vector change.
8987 (print_tu_stats): Likewise.
8988 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
8989 (write_debug_names): Likewise.
8991 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8993 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
8994 Make an std::vector.
8995 <n_comp_units>: Remove.
8996 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
8997 to std::vector change.
8998 (dwarf2_per_objfile::get_cutu): Likewise.
8999 (dwarf2_per_objfile::get_cu): Likewise.
9000 (create_cus_from_index): Likewise.
9001 (create_addrmap_from_index): Likewise.
9002 (create_addrmap_from_aranges): Likewise.
9003 (dwarf2_read_index): Likewise.
9004 (dw2_find_last_source_symtab): Likewise.
9005 (dw2_map_symtabs_matching_filename): Likewise.
9006 (dw2_symtab_iter_next): Likewise.
9007 (dw2_print_stats): Likewise.
9008 (dw2_expand_all_symtabs): Likewise.
9009 (dw2_expand_symtabs_with_fullname): Likewise.
9010 (dw2_expand_marked_cus): Likewise.
9011 (dw2_map_symbol_filenames): Likewise.
9012 (create_cus_from_debug_names): Likewise.
9013 (dwarf2_read_debug_names): Likewise.
9014 (dw2_debug_names_iterator::next): Likewise.
9015 (dwarf2_initialize_objfile): Likewise.
9016 (set_partial_user): Likewise.
9017 (dwarf2_build_psymtabs_hard): Likewise.
9018 (read_comp_units_from_section): Remove arguments, adjust to
9020 (create_all_comp_units): Adjust to std::vector and
9021 read_comp_units_from_section changes.
9022 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9024 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9025 (psyms_seen_size): Likewise.
9026 (write_gdbindex): Likewise.
9027 (write_debug_names): Likewise.
9029 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9031 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9032 with dwarf2_per_objfile.
9033 (create_cus_from_index): Likewise.
9034 (create_signatured_type_table_from_index): Likewise.
9035 (dwarf2_read_index): Likewise.
9036 (dwarf2_initialize_objfile): Likewise.
9037 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9038 per_cu rather than get_dwarf2_per_objfile.
9040 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9042 * dwarf2read.h (struct signatured_type): Forward declare.
9043 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9045 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9046 (dw2_get_cutu): ...this.
9047 (dwarf2_per_objfile::get_cu): Rename from...
9048 (dw2_get_cu): ...this.
9049 (dwarf2_per_objfile::get_tu): New.
9050 (create_addrmap_from_index): Adjust.
9051 (create_addrmap_from_aranges): Adjust.
9052 (dw2_find_last_source_symtab): Adjust.
9053 (dw2_map_symtabs_matching_filename): Adjust.
9054 (dw2_symtab_iter_next): Adjust.
9055 (dw2_print_stats): Adjust.
9056 (dw2_expand_all_symtabs): Adjust.
9057 (dw2_expand_symtabs_with_fullname): Adjust.
9058 (dw2_expand_marked_cus): Adjust.
9059 (dw_expand_symtabs_matching_file_matcher): Adjust.
9060 (dw2_map_symbol_filenames): Adjust.
9061 (dw2_debug_names_iterator::next): Adjust.
9062 (dwarf2_initialize_objfile): Adjust.
9063 (set_partial_user): Adjust.
9064 (dwarf2_build_psymtabs_hard): Adjust.
9066 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9068 * dwarf2read.c (create_signatured_type_table_from_debug_names):
9069 Remove unused variables.
9070 (dw2_map_symtabs_matching_filename): Likewise.
9071 (dwarf2_record_block_ranges): Likewise.
9072 (dwarf2_read_addr_index): Likewise.
9073 (follow_die_offset): Likewise.
9075 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9077 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
9078 to symbol_file_add_main.
9080 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9083 * mi/mi-console.c (do_fputc_async_safe): New.
9084 (mi_console_file::write_async_safe): New.
9085 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
9086 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
9088 * ui-file.c (ui_file::putstrn): Adjust call to
9089 fputstrn_unfiltered.
9090 * utils.c (printchar): Replace do_fputs and do_fprintf
9091 parameters by do_fputc.
9092 (fputstr_filtered): Adjust call to printchar.
9093 (fputstr_unfiltered): Likewise.
9094 (fputstrn_filtered): Likewise.
9095 (fputstrn_unfiltered): Add do_fputc parameter, pass to
9097 * utils.h (do_fputc_ftype): New typedef.
9098 (fputstrn_unfiltered): Add do_fputc parameter.
9100 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9102 * regformats/i386/i386-avx.dat: Remove.
9104 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9107 * amd64-tdep.c (amd64_none_init_abi): New function.
9108 (amd64_x32_none_init_abi): New function.
9109 (_initialize_amd64_tdep): Register handlers for x86-64 and
9110 x64_32 with GDB_OSABI_NONE.
9111 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
9112 GDB_OSABI_NONE osabi.
9114 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9117 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
9119 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
9120 * osabi.c (gdb_osabi_names): Add "unknown" entry.
9122 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
9124 * common/byte-vector.h (char_vector): New type.
9125 * target.h (target_read_alloc): Return
9126 gdb::optional<byte_vector>.
9127 (target_read_stralloc): Return gdb::optional<char_vector>.
9128 (target_get_osdata): Return gdb::optional<char_vector>.
9129 * target.c (target_read_alloc_1): Templatize. Replacement
9130 manual memory management with vector.
9131 (target_read_alloc): Change return type, adjust.
9132 (target_read_stralloc): Change return type, adjust.
9133 (target_get_osdata): Change return type, adjust.
9134 * auxv.c (struct auxv_info) <length>: Remove.
9135 <data>: Change type to gdb::optional<byte_vector>.
9136 (auxv_inferior_data_cleanup): Free auxv_info with delete.
9137 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
9138 (target_auxv_search): Adjust.
9139 (fprint_target_auxv): Adjust.
9140 * avr-tdep.c (avr_io_reg_read_command): Adjust.
9141 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
9142 (linux_make_corefile_notes): Adjust.
9143 * osdata.c (get_osdata): Adjust.
9144 * remote.c (remote_get_threads_with_qxfer): Adjust.
9145 (remote_memory_map): Adjust.
9146 (remote_traceframe_info): Adjust.
9147 (btrace_read_config): Adjust.
9148 (remote_read_btrace): Adjust.
9149 (remote_pid_to_exec_file): Adjust.
9150 * solib-aix.c (solib_aix_get_library_list): Adjust.
9151 * solib-dsbt.c (decode_loadmap): Don't free buf.
9152 (dsbt_get_initial_loadmaps): Adjust.
9153 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
9154 * solib-target.c (solib_target_current_sos): Adjust.
9155 * tracepoint.c (sdata_make_value): Adjust.
9156 * xml-support.c (xinclude_start_include): Adjust.
9157 (xml_fetch_content_from_file): Adjust.
9158 * xml-support.h (xml_fetch_another): Change return type.
9159 (xml_fetch_content_from_file): Change return type.
9160 * xml-syscall.c (xml_init_syscalls_info): Adjust.
9161 * xml-tdesc.c (file_read_description_xml): Adjust.
9162 (fetch_available_features_from_target): Change return type.
9163 (target_fetch_description_xml): Adjust.
9164 (target_read_description_xml): Adjust.
9166 2018-04-06 Tom Tromey <tom@tromey.com>
9168 * value.c (~value): Update.
9169 (struct value) <contents>: Now unique_xmalloc_ptr.
9170 (value_contents_bits_eq, allocate_value_contents)
9171 (value_contents_raw, value_contents_all_raw)
9172 (value_contents_for_printing, value_contents_for_printing_const)
9173 (set_value_enclosing_type): Update.
9175 2018-04-06 Tom Tromey <tom@tromey.com>
9177 * value.c (range_s): Remove typedef, VEC.
9178 (struct range): Add operator<.
9179 (range_lessthan): Remove.
9180 (ranges_contain): Change type.
9182 (struct value) <unavailable, optimized_out>: Now std::vector.
9183 (value_entirely_available)
9184 (value_entirely_covered_by_range_vector)
9185 (value_entirely_unavailable, value_entirely_optimized_out):
9187 (insert_into_bit_range_vector): Change argument type.
9188 (find_first_range_overlap): Likewise.
9189 (struct ranges_and_idx, value_contents_bits_eq)
9190 (require_not_optimized_out, require_available): Update.
9191 (ranges_copy_adjusted): Change argument types.
9192 (value_optimized_out, value_copy, value_fetch_lazy): Update.
9194 2018-04-06 Tom Tromey <tom@tromey.com>
9196 * value.c (~value): Update.
9197 (struct value) <parent>: Now a value_ref_ptr.
9198 (value_parent, set_value_parent, value_address, value_copy):
9201 2018-04-06 Tom Tromey <tom@tromey.com>
9203 * value.c (struct value): Add constructor, destructor, and member
9205 (allocate_value_lazy, value_decref): Update.
9207 2018-04-06 Tom Tromey <tom@tromey.com>
9209 * value.c (struct value) <released, next>: Remove.
9210 (all_values): Now a std::vector.
9211 (allocate_value_lazy): Update.
9212 (value_next): Remove.
9213 (value_mark, value_free_to_mark, release_value)
9214 (value_release_to_mark): Update.
9216 2018-04-06 Tom Tromey <tom@tromey.com>
9218 * value.h (fetch_subexp_value, value_release_to_mark): Update.
9219 (free_value_chain): Remove.
9220 * value.c (free_value_chain): Remove.
9221 (value_release_to_mark): Return a std::vector.
9222 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
9224 (check_condition): Update.
9225 * eval.c (fetch_subexp_value): Change "val_chain" to a
9227 * breakpoint.c (update_watchpoint): Update.
9228 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
9230 2018-04-06 Tom Tromey <tom@tromey.com>
9232 * value.h (free_all_values): Remove.
9233 * value.c (free_all_values): Remove.
9235 2018-04-06 Tom Tromey <tom@tromey.com>
9237 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
9238 (value_history_chain, value_history_count): Remove.
9239 (value_history): New global.
9240 (record_latest_value, access_value_history, show_values)
9241 (preserve_values): Update.
9243 2018-04-06 Tom Tromey <tom@tromey.com>
9245 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
9246 * varobj.c (varobj_set_display_format, varobj_set_value)
9247 (install_default_visualizer, construct_visualizer)
9248 (install_new_value, ~varobj, varobj_get_value_type)
9249 (my_value_of_variable, varobj_editable_p): Update.
9250 * c-varobj.c (c_describe_child, c_value_of_variable)
9251 (cplus_number_of_children, cplus_describe_child): Update.
9252 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
9253 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
9254 (ada_value_of_variable, ada_value_is_changeable_p): Update.
9256 2018-04-06 Tom Tromey <tom@tromey.com>
9258 * printcmd.c (last_examine_address): Change type to
9260 (do_examine, x_command): Update.
9262 2018-04-06 Tom Tromey <tom@tromey.com>
9264 * value.c (release_value): Update.
9265 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
9266 (struct bpstats) <val>: Now a value_ref_ptr.
9267 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9268 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9269 (~watchpoint, print_it_watchpoint, watch_command_1)
9270 (invalidate_bp_value_on_memory_change): Update.
9272 2018-04-06 Tom Tromey <tom@tromey.com>
9274 * varobj.c (varobj_clear_saved_item)
9275 (update_dynamic_varobj_children, install_new_value, ~varobj):
9277 * value.h (value_incref): Move declaration earlier.
9278 (value_decref): Rename from value_free.
9279 (struct value_ref_policy): New.
9280 (value_ref_ptr): New typedef.
9281 (struct value_deleter): Remove.
9282 (gdb_value_up): Remove typedef.
9283 (release_value): Change return type.
9284 (release_value_or_incref): Remove.
9285 * value.c (set_value_parent): Update.
9286 (value_incref): Change return type.
9287 (value_decref): Rename from value_free.
9288 (value_free_to_mark, free_all_values, free_value_chain): Update.
9289 (release_value): Return value_ref_ptr.
9290 (release_value_or_incref): Remove.
9291 (record_latest_value, set_internalvar, clear_internalvar):
9293 * stack.c (info_frame_command): Don't call value_free.
9294 * python/py-value.c (valpy_dealloc, valpy_new)
9295 (value_to_value_object): Update.
9296 * printcmd.c (do_examine): Update.
9297 * opencl-lang.c (lval_func_free_closure): Update.
9298 * mi/mi-main.c (register_changed_p): Don't call value_free.
9299 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
9300 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
9301 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
9303 * guile/scm-value.c (vlscm_free_value_smob)
9304 (vlscm_scm_from_value): Update.
9305 * frame.c (frame_register_unwind, frame_unwind_register_signed)
9306 (frame_unwind_register_unsigned, get_frame_register_bytes)
9307 (put_frame_register_bytes): Don't call value_free.
9308 * findvar.c (address_from_register): Don't call value_free.
9309 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
9310 * dwarf2loc.c (entry_data_value_free_closure)
9311 (value_of_dwarf_reg_entry, free_pieced_value_closure)
9312 (dwarf2_evaluate_loc_desc_full): Update.
9313 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
9314 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
9315 (~watchpoint, watch_command_1)
9316 (invalidate_bp_value_on_memory_change): Update.
9317 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
9319 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
9322 * warning.m4: Add -Wno-error=deprecated-register.
9323 * configure: Re-generate.
9325 2018-04-05 Tom Tromey <tom@tromey.com>
9327 * linespec.h: Remove include of "vec.h".
9329 2018-04-05 Tom Tromey <tom@tromey.com>
9331 * linespec.c (typep): Remove typedef.
9332 (find_methods, find_superclass_methods): Take a std::vector.
9333 (find_method): Use std::vector.
9335 2018-04-05 Tom Tromey <tom@tromey.com>
9337 * utils.c (compare_strings): Remove.
9338 * utils.h (compare_strings): Remove.
9339 * objc-lang.h (find_imps): Update.
9340 * objc-lang.c (find_methods): Take a std::vector.
9341 (uniquify_strings, find_imps): Likewise.
9342 * linespec.c (find_methods): Take a std::vector.
9343 (decode_objc): Use std::vector.
9344 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
9346 (find_method, find_function_symbols): Use std::vector.
9348 2018-04-05 Tom Tromey <tom@tromey.com>
9350 * completer.c (completion_tracker::completion_tracker): Remove
9352 (completion_tracker::discard_completions): Likewise.
9353 * breakpoint.c (ambiguous_names_p): Remove cast.
9354 * ada-lang.c (_initialize_ada_language): Remove cast.
9355 * utils.h (streq): Update.
9356 (streq_hash): Add new declaration.
9357 * utils.c (streq): Return bool.
9358 (streq_hash): New function.
9360 2018-04-05 Tom Tromey <tom@tromey.com>
9362 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
9363 Remove a string copy.
9365 2018-04-05 Tom Tromey <tom@tromey.com>
9367 * linespec.c (filter_results): Use std::vector.
9368 (decode_line_2, decode_line_full): Update.
9370 2018-04-05 Tom Tromey <tom@tromey.com>
9372 * linespec.c (canonical_to_fullform): Return std::string.
9373 (filter_results): Update.
9374 (struct decode_line_2_item): Add constructor.
9375 <fullform, displayform>: Now std::string.
9376 (decode_line_2_compare_items): Now a std::sort comparator.
9377 (decode_line_2): Update.
9379 2018-04-05 Tom Tromey <tom@tromey.com>
9381 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
9382 (unexpected_linespec_error): Update.
9383 (linespec_parse_basic, parse_linespec): Update.
9385 2018-04-05 Tom Tromey <tom@tromey.com>
9387 * linespec.c (linespec_parse_basic): Reindent.
9389 2018-04-05 Tom Tromey <tom@tromey.com>
9391 * minsyms.h (iterate_over_minimal_symbols): Update.
9392 * minsyms.c (iterate_over_minimal_symbols): Take a
9394 * linespec.c (struct collect_minsyms): Remove.
9395 (compare_msyms): Now a std::sort comparator.
9396 (add_minsym): Add parameters.
9397 (search_minsyms_for_name): Update. Use std::vector.
9399 2018-04-03 Tom Tromey <tom@tromey.com>
9401 * mipsread.c (read_alphacoff_dynamic_symtab): Use
9404 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
9406 * MAINTAINERS (Write After Approval): Add Weimin Pan.
9408 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
9411 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
9412 printing static type.
9414 2018-04-01 Tom Tromey <tom@tromey.com>
9416 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
9417 (rs6000_xfer_shared_libraries): Update.
9419 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
9421 * common/gdb_vecs.h (char_ptr): Remove.
9422 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
9424 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
9426 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
9428 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
9430 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
9432 * tracepoint.h (struct uploaded_tp): Initialize fields.
9433 <actions, step_actions, cmd_strings>: Change type to
9434 std::vector<char *>.
9435 * tracepoint.c (get_uploaded_tp): Allocate with new.
9436 (free_uploaded_tps): Free with delete.
9437 (parse_tracepoint_definition): Adjust to std::vector change.
9438 * breakpoint.c (read_uploaded_action): Likewise.
9439 (create_tracepoint_from_upload): Likewise.
9440 * ctf.c (ctf_write_uploaded_tp): Likewise.
9441 (SET_ARRAY_FIELD): Likewise.
9442 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
9444 2018-03-30 Tom Tromey <tom@tromey.com>
9446 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
9448 (svr4_keep_data_in_core): Update.
9449 (svr4_read_so_list): Update.
9451 2018-03-30 Tom Tromey <tom@tromey.com>
9453 * windows-nat.c (handle_output_debug_string, handle_exception):
9455 * target.h (target_read_string): Update.
9456 * target.c (target_read_string): Change "string" to
9458 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
9460 * solib-frv.c (frv_current_sos): Update.
9461 * solib-dsbt.c (dsbt_current_sos): Update.
9462 * solib-darwin.c (darwin_current_sos): Update.
9463 * linux-thread-db.c (inferior_has_bug): Update.
9464 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
9465 Update. Remove alloca.
9466 * ada-lang.c (ada_main_name): Update.
9468 2018-03-30 Tom Tromey <tom@tromey.com>
9470 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
9471 (struct dwo_file_deleter): New.
9472 (dwo_file_up): New typedef.
9473 (open_and_init_dwo_file): Use dwo_file_up.
9474 (free_dwo_file_cleanup): Remove.
9476 2018-03-30 Tom Tromey <tom@tromey.com>
9478 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
9479 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
9481 2018-03-30 Tom Tromey <tom@tromey.com>
9483 * dwarf2read.c (class free_cached_comp_units): New class.
9484 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
9485 (free_cached_comp_units): Remove function.
9487 2018-03-30 Tom Tromey <tom@tromey.com>
9489 * utils.h (make_cleanup_unpush_target): Remove.
9490 * inf-ptrace.c (struct target_unpusher): New.
9491 (target_unpush_up) New typedef.
9492 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
9494 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
9496 2018-03-27 Tom Tromey <tom@tromey.com>
9498 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
9500 2018-03-27 Pedro Alves <palves@redhat.com>
9501 Tom Tromey <tom@tromey.com>
9503 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
9504 destructor. Now a class.
9505 (gdb_readline_wrapper_cleanup): Remove function.
9506 (gdb_readline_wrapper): Remove cleanups.
9508 2018-03-27 Tom Tromey <tom@tromey.com>
9510 * typeprint.h (struct type_print_options) <local_typedefs,
9511 global_typedefs>: Remove "struct" keyword.
9512 (class typedef_hash_table): New class.
9513 (recursively_update_typedef_hash, add_template_parameters)
9514 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
9515 (find_typedef_in_hash): Don't declare.
9516 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
9517 (typedef_hash_table::recursively_update): Rename from
9518 recursively_update_typedef_hash. Now a member.
9519 (typedef_hash_table::add_template_parameters): Rename from
9520 add_template_parameters. Now a member.
9521 (typedef_hash_table::typedef_hash_table): Now a constructor;
9522 rename from create_typedef_hash.
9523 (typedef_hash_table::~typedef_hash_table): Now a destructor;
9524 rename from free_typedef_hash.
9525 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
9526 (do_free_global_table): Remove.
9527 (typedef_hash_table::typedef_hash_table): New constructor; renamed
9528 from copy_type_recursive.
9529 (create_global_typedef_table): Remove.
9530 (typedef_hash_table::find_global_typedef): Now a member of
9532 (typedef_hash_table::find_typedef): Rename from
9533 find_typedef_in_hash; now a member.
9534 (whatis_exp): Update.
9535 * extension.h (struct ext_lang_type_printers): Add constructor and
9537 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
9539 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
9540 Now a constructor; rename from start_ext_lang_type_printers.
9541 (ext_lang_type_printers): Now a destructor; rename from
9542 free_ext_lang_type_printers.
9543 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
9545 (c_type_print_base_struct_union): Update. Remove cleanups.
9547 2018-03-27 Tom Tromey <tom@tromey.com>
9549 * dwarf-index-write.c: Include <cmath>.
9551 2018-03-27 Joel Brobecker <brobecker@adacore.com>
9553 * NEWS: Add entry describing new "set|show varsize-limit" command.
9554 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
9556 * printcmd.c (_initialize_printcmd): Add "set var" alias of
9559 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
9561 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
9563 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
9564 * dwarf-index-common.c: New file.
9565 * dwarf-index-common.h: New file.
9566 * dwarf-index-write.c: New file.
9567 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
9568 (struct dwarf2_section_info): Move from here.
9569 (dwarf2_section_info_def): Likewise.
9570 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
9571 (offset_type): Likewise.
9572 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
9573 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
9574 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
9575 (byte_swap): Likewise.
9576 (MAYBE_SWAP): Likewise.
9577 (dwarf2_per_cu_ptr): Likewise.
9578 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
9579 (struct tu_stats): Likewise.
9580 (struct dwarf2_per_objfile): Likewise.
9581 (struct dwarf2_per_cu_data): Likewise.
9582 (struct signatured_type): Likewise.
9583 (sig_type_ptr): Likewise.
9584 (DEF_VEC_P (sig_type_ptr)): Likewise.
9585 (INDEX4_SUFFIX): Likewise.
9586 (INDEX5_SUFFIX): Likewise.
9587 (DEBUG_STR_SUFFIX): Likewise.
9588 (dwarf2_read_section): Make non-static.
9589 (mapped_index_string_hash): Move from here.
9590 (dwarf5_djb_hash): Likewise.
9591 (file_write): Likewise.
9592 (class data_buf): Likewise.
9593 (struct symtab_index_entry): Likewise.
9594 (struct mapped_symtab): Likewise.
9595 (find_slot): Likewise.
9596 (hash_expand): Likewise.
9597 (add_index_entry): Likewise.
9598 (uniquify_cu_indices): Likewise.
9599 (class c_str_view): Likewise.
9600 (class c_str_view_hasher): Likewise.
9601 (class vector_hasher): Likewise.
9602 (write_hash_table): Likewise.
9603 (psym_index_map): Likewise.
9604 (struct addrmap_index_data): Likewise.
9605 (add_address_entry): Likewise.
9606 (add_address_entry_worker): Likewise.
9607 (write_address_map): Likewise.
9608 (symbol_kind): Likewise.
9609 (write_psymbols): Likewise.
9610 (struct signatured_type_index_data): Likewise.
9611 (write_one_signatured_type): Likewise.
9612 (recursively_count_psymbols): Likewise.
9613 (recursively_write_psymbols): Likewise.
9614 (class debug_names): Likewise.
9615 (check_dwarf64_offsets): Likewise.
9616 (psyms_seen_size): Likewise.
9617 (write_gdbindex): Likewise.
9618 (write_debug_names): Likewise.
9619 (assert_file_size): Likewise.
9620 (write_psymtabs_to_index): Likewise.
9621 (save_gdb_index_command): Likewise.
9622 (_initialize_dwarf2_read): Don't register the "save gdb-index"
9624 * dwarf2read.h: New file.
9626 2018-03-27 Joel Brobecker <brobecker@adacore.com>
9629 * dwarf2read.c (dwarf2_physname): Do not return the demangled
9630 symbol name if the CU's language stores symbol names in linkage
9632 * language.h (struct language_defn)
9633 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
9634 all instances of this struct.
9636 2018-03-26 Tom Tromey <tom@tromey.com>
9638 * stack.c (backtrace_command_1): Remove verbose code.
9640 2018-03-26 Tom Tromey <tom@tromey.com>
9642 * python/py-framefilter.c (py_print_type): Don't catch
9643 exceptions. Return void.
9644 (py_print_value): Likewise.
9645 (py_print_single_arg): Likewise.
9646 (enumerate_args): Don't catch exceptions.
9647 (py_print_args): Likewise.
9648 (py_print_frame): Likewise.
9649 (gdbpy_apply_frame_filter): Catch exceptions here.
9651 2018-03-26 Tom Tromey <tom@tromey.com>
9653 * stack.c (_initialize_stack): Remove trailing newlines from help
9654 text. Add "Usage" line to "backtrace" help.
9656 2018-03-26 Tom Tromey <tom@tromey.com>
9659 * python/py-framefilter.c (py_print_args): Call wrap_hint.
9661 2018-03-26 Tom Tromey <tom@tromey.com>
9663 * python/py-framefilter.c (py_print_single_arg): Return
9664 EXT_LANG_BT_ERROR from catch.
9666 2018-03-26 Tom Tromey <tom@tromey.com>
9669 * stack.c (backtrace_command_1): Move some code into no-filters
9672 2018-03-26 Tom Tromey <tom@tromey.com>
9674 * python/py-framefilter.c (throw_quit_or_print_exception): New
9676 (gdbpy_apply_frame_filter): Use it.
9678 2018-03-26 Tom Tromey <tom@tromey.com>
9681 * python/py-framefilter.c (py_print_type, py_print_value)
9682 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
9685 2018-03-26 Tom Tromey <tom@tromey.com>
9687 * python/py-framefilter.c (enumerate_args): Use
9688 gdb::unique_xmalloc_ptr.
9690 2018-03-26 Tom Tromey <tom@tromey.com>
9692 * python/py-framefilter.c (py_print_frame): Return
9694 (gdbpy_apply_frame_filter): Update comment.
9695 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
9697 <EXT_LANG_BT_NO_FILTERS>: Change value.
9699 2018-03-26 Tom Tromey <tom@tromey.com>
9702 * stack.c (backtrace_command): Parse "hide" argument.
9703 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
9704 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
9707 2018-03-26 Tom Tromey <tom@tromey.com>
9709 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
9711 (backtrace_command): Remove "fulltrace", add "flags".
9713 2018-03-26 Tom Tromey <tom@tromey.com>
9715 * stack.c (backtrace_command): Rewrite command line parsing.
9717 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
9719 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
9721 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
9723 * filename-seen-cache.h: Add include guard.
9725 2018-03-26 Keith Seitz <keiths@redhat.com>
9727 * symfile.c (place_section): Remove "struct" from section_addr_info
9729 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
9730 "struct" keyword from section_addr_info.
9732 2018-03-26 Alan Hayward <alan.hayward@arm.com>
9734 * regformats/regdef.h (reg): Add constructors.
9736 2018-03-25 Pedro Alves <palves@redhat.com>
9738 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
9739 if then/else bodies in var_func_name extraction.
9741 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
9743 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
9744 lookup_minimal_symbol() to find symbol entry.
9745 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
9747 2018-03-23 Keith Seitz <keiths@redhat.com>
9750 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
9751 nested type definitions for C++, too.
9753 2018-03-23 Tom Tromey <tom@tromey.com>
9755 * machoread.c (struct oso_el): Add a constructor. Don't define as
9757 (macho_register_oso): Remove.
9758 (macho_symtab_read): Take a std::vector.
9759 (oso_el_compare_name): Now a std::sort comparator.
9760 (macho_symfile_read_all_oso): Take a std::vector.
9761 (macho_symfile_read): Use std::vector. Remove cleanups.
9763 2018-03-22 Tom Tromey <tom@tromey.com>
9765 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
9766 (record_full_goto_bookmark): Use std::string.
9768 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9771 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
9774 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9776 * rs6000-tdep.c (store_insn_p): New function.
9777 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
9778 and cr_reg to their unshifted values. Use store_insn_p to
9779 match LR saves using either R1 or fdata->alloca_reg. Use
9780 store_insn_p to match CR saves. Set alloca_reg_offset
9781 when alloca_reg and framep are set. Remove lr_reg shift
9782 when assigning to fdata->lr_register.
9784 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
9786 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
9787 command line args instead of emitting a warning.
9789 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9791 * tracepoint.h (struct static_tracepoint_marker): Initialize
9792 fields, define default constructor, move constructor and move
9793 assignment, disable the rest.
9794 <str_id, extra>: Make std::string.
9795 (release_static_tracepoint_marker): Remove.
9796 (free_current_marker): Remove.
9797 * tracepoint.c (free_current_marker): Remove.
9798 (parse_static_tracepoint_marker_definition): Adjust to
9799 std::string, use new hex2str overload.
9800 (release_static_tracepoint_marker): Remove.
9801 (print_one_static_tracepoint_marker): Get marker by reference
9802 and adjust to std::string.
9803 (info_static_tracepoint_markers_command): Adjust to std::vector
9805 * target.h (static_tracepoint_marker_p): Remove typedef.
9806 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
9807 (struct target_ops) <to_static_tracepoint_marker_at>: Return
9809 <to_static_tracepoint_markers_by_strid>: Return std::vector.
9811 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
9812 (target_debug_print_std_vector_static_tracepoint_marker): New.
9813 (target_debug_print_struct_static_tracepoint_marker_p): Rename
9815 (target_debug_print_static_tracepoint_marker_p): ... this.
9816 * target-delegates.c: Re-generate.
9817 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
9819 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
9820 (decode_static_tracepoint_spec): Adjust to std::vector.
9821 (tracepoint_print_one_detail): Adjust to std::string.
9822 (strace_marker_decode_location): Adjust to std::string.
9823 (update_static_tracepoint): Adjust to std::string, remove call
9824 to release_static_tracepoint_marker.
9825 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
9826 Adjust to std::vector.
9827 * remote.c (remote_static_tracepoint_marker_at): Return bool.
9828 (remote_static_tracepoint_markers_by_strid): Adjust to
9830 * common/rsp-low.h (hex2str): New overload with explicit count
9832 * common/rsp-low.c (hex2str): New overload with explicit count
9834 * unittests/rsp-low-selftests.c (test_hex2str): New function.
9835 (_initialize_rsp_low_selftests): Add test_hex2str test.
9836 * unittests/tracepoint-selftests.c
9837 (test_parse_static_tracepoint_marker_definition): Adjust to
9840 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9842 * tracepoint.c (parse_static_tracepoint_marker_definition):
9843 Consider case where the definition is followed by more
9845 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9846 tracepoint-selftests.c.
9847 * unittests/tracepoint-selftests.c: New.
9849 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9851 * MAINTAINERS (Write After Approval): Add Pedro Franco de
9854 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
9856 * symtab.c (find_pc_sect_line): fixed indentation.
9858 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
9860 * symtab.c (find_pc_sect_line): now uses binary search.
9862 2018-03-19 Tom Tromey <tom@tromey.com>
9864 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
9867 2018-03-19 Pedro Alves <palves@redhat.com>
9868 Tom Tromey <tom@tromey.com>
9870 * unittests/observable-selftests.c: New file.
9871 * common/observable.h: New file.
9872 * observable.h: New file.
9873 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
9874 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
9875 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
9876 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
9877 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
9878 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
9879 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
9880 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
9881 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
9882 python/py-breakpoint.c, python/py-finishbreakpoint.c,
9883 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
9884 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
9885 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
9886 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
9887 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
9888 tui/tui-interp.c, valops.c: Update all users.
9889 * tui/tui-hooks.c (tui_bp_created_observer)
9890 (tui_bp_deleted_observer, tui_bp_modified_observer)
9891 (tui_inferior_exit_observer, tui_before_prompt_observer)
9892 (tui_normal_stop_observer, tui_register_changed_observer):
9894 (tui_observers_token): New global.
9895 (attach_or_detach, tui_attach_detach_observers): New functions.
9896 (tui_install_hooks, tui_remove_hooks): Use
9897 tui_attach_detach_observers.
9898 * record-btrace.c (record_btrace_thread_observer): Remove.
9899 (record_btrace_thread_observer_token): New global.
9900 * observer.sh: Remove.
9901 * observer.c: Rename to observable.c.
9902 * observable.c (namespace gdb_observers): Define new objects.
9903 (observer_debug): Move into gdb_observers namespace.
9904 (struct observer, struct observer_list, xalloc_observer_list_node)
9905 (xfree_observer_list_node, generic_observer_attach)
9906 (generic_observer_detach, generic_observer_notify): Remove.
9907 (_initialize_observer): Update.
9908 Don't include observer.inc.
9909 * Makefile.in (generated_files): Remove observer.h, observer.inc.
9910 (clean mostlyclean): Likewise.
9911 (observer.h, observer.inc): Remove targets.
9912 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
9913 (COMMON_SFILES): Use observable.c, not observer.c.
9914 * .gitignore: Remove observer.h.
9916 2018-03-18 Tom Tromey <tom@tromey.com>
9918 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
9920 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
9922 2018-03-17 Tom Tromey <tom@tromey.com>
9924 * auto-load.c (auto_load_objfile_script_1): Use std::string.
9926 2018-03-17 Tom Tromey <tom@tromey.com>
9928 * target.c (class scoped_target_fd): New.
9929 (target_fileio_close_cleanup): Remove.
9930 (target_fileio_read_alloc_1): Use scoped_target_fd.
9932 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
9934 * silent-rules.mk: New.
9935 * Makefile.in: Include silent-rules.mk
9936 (srcdir, VPATH, top_srcdir): Move up.
9937 (COMPILE): Add ECHO_CXX.
9938 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
9939 (init.c): Add ECHO_INIT_C.
9940 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
9941 (version.c): Add ECHO_GEN.
9942 (printcmd.o): Add ECHO_CXX.
9943 (target-float.o): Add ECHO_CXX.
9944 (ada-exp.o): Add ECHO_CXX.
9945 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
9946 (insight$(EXEEXT)): Add ECHO_CXXLD.
9947 * gnulib/configure.ac: Add AM_SILENT_RULES.
9948 * gnulib/aclocal.m4: Re-generate.
9949 * gnulib/configure: Re-generate.
9950 * gnulib/import/Makefile.in: Re-generate.
9952 2018-03-16 Tom Tromey <tom@tromey.com>
9954 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
9955 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
9956 * utils.c (do_free_section_addr_info)
9957 (make_cleanup_free_section_addr_info): Remove.
9958 * symfile.h (struct other_sections): Add constructor.
9959 (struct section_addr_info): Remove.
9960 (section_addr_info): New typedef.
9961 (struct sym_fns) <sym_offsets>: Change type of parameter.
9962 (build_section_addr_info_from_objfile)
9963 (relative_addr_info_to_section_offsets, addr_info_make_relative)
9964 (default_symfile_offsets, symbol_file_add)
9965 (symbol_file_add_from_bfd)
9966 (build_section_addr_info_from_section_table): Update.
9967 (alloc_section_addr_info, free_section_addr_info): Don't declare.
9968 * symfile.c (alloc_section_addr_info): Remove.
9969 (build_section_addr_info_from_section_table): Change return type.
9971 (build_section_addr_info_from_bfd)
9972 (build_section_addr_info_from_objfile): Likewise.
9973 (free_section_addr_info): Remove.
9974 (relative_addr_info_to_section_offsets): Change type of "addrs".
9975 (addrs_section_compar): Now a std::sort comparator.
9976 (addrs_section_sort): Change return type.
9977 (addr_info_make_relative): Change type of "addrs". Update.
9978 (default_symfile_offsets, syms_from_objfile_1)
9979 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
9980 (symbol_file_add_separate): Update.
9981 (symbol_file_add): Change type of "addrs". Update.
9982 (add_symbol_file_command): Update. Remove cleanups.
9983 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
9985 * symfile-debug.c (debug_sym_offsets): Change type of "info".
9986 * solib.c (solib_read_symbols): Update.
9987 * objfiles.c (objfile_relocate): Update. Remove cleanups.
9988 * machoread.c (macho_symfile_offsets): Update.
9989 * jit.c (jit_bfd_try_read_symtab): Update.
9991 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
9993 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9994 unittests/utils-selftests.c.
9995 * unittests/utils-selftests.c: New file.
9997 2018-03-14 Tom Tromey <tom@tromey.com>
10000 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10003 2018-03-14 Tom Tromey <tom@tromey.com>
10006 * printcmd.c (printf_pointer): Allow "-" in format.
10008 2018-03-14 Tom Tromey <tom@tromey.com>
10010 * printcmd.c (_initialize_printcmd): Add usage to printf.
10012 2018-03-14 Yao Qi <qiyao@sourceware.org>
10014 * MAINTAINERS: Update my email address.
10016 2018-03-13 Tom Tromey <tom@tromey.com>
10018 * machoread.c (macho_check_dsym): Change filenamep to a
10020 (macho_symfile_read): Update.
10021 * symfile.c (load_command): Use std::string.
10023 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10025 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10026 to error message string.
10027 (riscv_register_name): Use xsnprintf instead of sprintf.
10028 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10030 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10032 (riscv_push_dummy_call): Likewise.
10034 2018-03-12 Tom Tromey <tom@tromey.com>
10036 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10037 Use gdb::byte_vector.
10038 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10040 2018-03-12 Yao Qi <yao.qi@linaro.org>
10042 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10043 parameter type to readable_regcache.
10044 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10047 2018-03-11 Tom Tromey <tom@tromey.com>
10049 * dwarf2read.c (struct nextfield): Add initializers.
10050 (struct nextfnfield): Remove.
10051 (struct fnfieldlist): Add initializers. Remove "length" and
10052 "head", use std::vector.
10053 (struct decl_field_list): Remove.
10054 (struct field_info): Add initializers.
10055 <fields, baseclasses>: Now std::vector.
10056 <nbaseclasses, nfnfields, typedef_field_list_count,
10057 nested_types_list_count>: Remove.
10058 (dwarf2_add_field, dwarf2_add_type_defn)
10059 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10060 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10061 (process_structure_scope): Update.
10063 2018-03-11 Tom Tromey <tom@tromey.com>
10065 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
10066 for use by std::sort.
10067 (build_type_psymtabs_1): Use std::vector.
10069 2018-03-09 Eli Zaretskii <eliz@gnu.org>
10071 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
10072 and LIBMPFR in the printed configuration.
10074 2018-03-08 Tom Tromey <tom@tromey.com>
10076 * source.c (get_filename_and_charpos): Use scoped_fd.
10077 * nto-procfs.c (procfs_open_1): Use scoped_fd.
10078 (procfs_pidlist): Likewise.
10079 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
10080 (iterate_over_mappings): Likewise.
10082 2018-03-08 Tom Tromey <tom@tromey.com>
10084 * infcall.c (struct call_return_meta_info)
10085 <stack_temporaries_enabled>: Remove.
10086 (get_call_return_value, call_function_by_hand_dummy): Update.
10087 * thread.c (disable_thread_stack_temporaries): Remove.
10088 (enable_thread_stack_temporaries): Remove.
10089 (thread_stack_temporaries_enabled_p): Return bool.
10090 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
10091 (get_last_thread_stack_temporary): Update.
10092 * eval.c (evaluate_subexp): Update.
10093 * gdbthread.h (class enable_thread_stack_temporaries): Now a
10094 class, not a function.
10095 (value_ptr, value_vec): Remove typedefs.
10096 (class thread_info) <stack_temporaries_enabled>: Now bool.
10097 <stack_temporaries>: Now a std::vector.
10098 (thread_stack_temporaries_enabled_p)
10099 (value_in_thread_stack_temporaries): Return bool.
10101 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
10103 * remote.c (putpkt_binary): Fix omitted bytes reporting.
10104 (getpkt_or_notif_sane_1): Likewise.
10106 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10108 * build-id.c (build_id_to_debug_bfd): Use std::string.
10110 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10112 * build-id.c (find_separate_debug_file_by_buildid): Return
10114 * build-id.h (find_separate_debug_file_by_buildid): Return
10116 * coffread.c (coff_symfile_read): Adjust to std::string.
10117 * elfread.c (elf_symfile_read): Adjust to std::string.
10118 * symfile.c (separate_debug_file_exists): Change parameter to
10120 (find_separate_debug_file): Return std::string.
10121 (find_separate_debug_file_by_debuglink): Return std::string.
10122 * symfile.h (find_separate_debug_file_by_debuglink): Return
10125 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
10127 * common/xml-utils.c (xml_escape_text): Move code to...
10128 (xml_escape_text_append): ... this new function.
10129 * common/xml-utils.h (xml_escape_text_append): New declaration.
10130 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
10132 (_initialize_xml_utils): register test_xml_escape_text_append as
10135 2018-03-07 Alan Hayward <alan.hayward@arm.com>
10137 * defs.h: Remove MAX_REGISTER_SIZE.
10138 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
10140 * python/py-unwind.c (pyuw_sniffer): Likewise.
10142 2018-03-07 Tom Tromey <tom@tromey.com>
10144 * linux-tdep.c (linux_info_proc): Update.
10145 * target.h (struct target_ops) <to_fileio_readlink>: Return
10147 (target_fileio_readlink): Return optional<string>.
10148 * remote.c (remote_hostio_readlink): Return optional<string>.
10149 * inf-child.c (inf_child_fileio_readlink): Return
10151 * target.c (target_fileio_readlink): Return optional<string>.
10153 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
10155 * regcache.c (cooked_read_test): Add riscv to the list of
10156 architectures that have a save_reggroup.
10158 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
10160 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
10161 value is not a dynamic class object.
10163 2018-03-06 Tom Tromey <tom@tromey.com>
10165 * rust-exp.y: Formatting fixes.
10167 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10169 * riscv-tdep.c (riscv_register_name): Remove target description
10171 (riscv_gdbarch_init): Remove target description check.
10173 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10175 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
10177 * riscv-tdep.h: Likewise.
10179 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10181 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
10182 (riscv_pseudo_register_write): Delete.
10183 (riscv_gdbarch_init): Remove all use of pseudo registers.
10185 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10187 * record-btrace.c (btrace_print_lines): Replace cleanup
10188 parameter with RAII equivalents.
10189 (btrace_insn_history): Replace cleanup with RAII equivalents.
10190 * ui-out.h (make_cleanup_ui_out_list_begin_end,
10191 make_cleanup_ui_out_tuple_begin_end): Remove.
10192 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
10193 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
10194 make_cleanup_ui_out_list_begin_end): Remove.
10196 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10198 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
10199 parameter types to std::vector. Use bool.
10200 (record_btrace_wait): Replace VEC(tp_t) with
10201 std::vector<thread_info *>.
10202 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
10204 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10206 * record-btrace.c (record_btrace_disable_callback): Remove.
10207 (struct scoped_btrace_disable): New.
10208 (record_btrace_open): Use scoped_btrace_disable.
10210 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10212 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
10213 reading values from registers.
10215 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10217 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
10220 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10222 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
10223 change parameter type. Use GDB's print functions, and use
10224 core_addr_to_string where appropriate.
10225 (riscv_push_dummy_call): Use core_addr_to_string where
10226 appropriate, update call to riscv_print_arg_location, and reindent
10228 (riscv_return_value): Update call to riscv_print_arg_location.
10230 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10231 Tim Newsome <tim@sifive.com>
10232 Albert Ou <a0u@eecs.berkeley.edu>
10233 Darius Rad <darius@bluespec.com>
10235 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
10236 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
10237 (ALLDEPFILES): Add riscv-tdep.c
10238 * configure.tgt: Add riscv support.
10239 * riscv-tdep.c: New file.
10240 * riscv-tdep.h: New file.
10241 * NEWS: Mention new target.
10242 * MAINTAINERS: Add entry for riscv.
10244 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10246 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
10247 fields within aggregates.
10249 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
10251 * record-btrace.c (btrace_print_lines): Change type of flags to
10252 gdb_disassembly_flags.
10254 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10256 * fbsd-nat.c: Include "inf-ptrace.h".
10257 (USE_SIGTRAP_SIGINFO): Conditionally define.
10258 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
10259 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
10260 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
10262 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
10264 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
10266 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
10267 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
10268 "supports_stopped_by_hw_breakpoint" target methods.
10270 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10272 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
10273 * fbsd-nat.c (debug_fbsd_nat): New variable.
10274 (show_fbsd_nat_debug): New function.
10275 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
10276 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
10278 2018-03-04 John Baldwin <jhb@FreeBSD.org>
10280 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
10281 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
10283 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
10284 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
10287 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10289 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
10290 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
10292 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10294 * charset.c (struct charset_vector): New.
10295 (charsets): Change type to charset_vector.
10296 (find_charset_names): Adjust.
10298 (_initialize_charset): Adjust.
10300 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10302 * progspace.h (struct program_space) <deleted_solibs>: Change
10303 type to std::vector<std::string>.
10304 * progspace.c (clear_program_space_solib_cache): Adjust.
10305 * breakpoint.c (print_solib_event): Adjust.
10306 (check_status_catch_solib): Adjust.
10307 * solib.c (update_solib_list): Adjust.
10308 * ui-out.h (class ui_out) <field_string>: New overload.
10309 * ui-out.c (ui_out::field_string): New overload.
10311 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10313 * progspace.h (struct program_space): Add constructor and
10314 destructor, initialize fields.
10315 (add_program_space): Remove.
10316 * progspace.c (add_program_space): Rename to...
10317 (program_space::program_space): ... this.
10318 (release_program_space): Rename to...
10319 (program_space::~program_space): ... this.
10320 (delete_program_space): Use delete to delete program_space.
10321 (initialize_progspace): Use new to allocate program_space.
10322 * inferior.c (add_inferior_with_spaces): Likewise.
10323 (clone_inferior_command): Likewise.
10324 * infrun.c (follow_fork_inferior): Likewise.
10325 (handle_vfork_child_exec_or_exit): Likewise.
10327 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10329 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
10330 (delim_string_to_char_ptr_vec): Return std::vector of
10331 gdb::unique_xmalloc_ptr.
10332 (dirnames_to_char_ptr_vec_append): Take std::vector of
10333 gdb::unique_xmalloc_ptr.
10334 (dirnames_to_char_ptr_vec): Return std::vector of
10335 gdb::unique_xmalloc_ptr.
10336 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
10337 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
10338 (delim_string_to_char_ptr_vec): Return an std::vector of
10339 gdb::unique_xmalloc_ptr, adjust the code.
10340 (dirnames_to_char_ptr_vec_append): Take an std::vector of
10341 gdb::unique_xmalloc_ptr, adjust the code.
10342 (dirnames_to_char_ptr_vec): Return an std::vector of
10343 gdb::unique_xmalloc_ptr, adjust the code.
10344 * auto-load.c (auto_load_safe_path_vec): Change type to
10345 std::vector of gdb::unique_xmalloc_ptr.
10346 (auto_load_expand_dir_vars): Return an std::vector of
10347 gdb::unique_xmalloc_ptr, adjust the code.
10348 (auto_load_safe_path_vec_update): Adjust.
10349 (filename_is_in_auto_load_safe_path_vec): Adjust.
10350 (auto_load_objfile_script_1): Adjust.
10351 * build-id.c (build_id_to_debug_bfd): Adjust.
10352 * linux-thread-db.c (thread_db_load_search): Adjust.
10353 * source.c (add_path): Adjust.
10355 * symfile.c (find_separate_debug_file): Adjust.
10356 * utils.c (do_free_char_ptr_vec): Remove.
10357 (make_cleanup_free_char_ptr_vec): Remove.
10359 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
10362 * common/pathstuff.c: Conditionally include "<windows.h>".
10364 2018-03-01 Georg Sauthoff <mail@georg.so>
10367 * gcore.in: Quote variables and switch interpreter to bash.
10369 2018-03-01 Tom Tromey <tom@tromey.com>
10371 * dwarf2read.c (alloc_discriminant_info): Fix default_index
10372 assertion. Add assertion for discriminant_index.
10373 (quirk_rust_enum): Use correct base type name in univariant case.
10375 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
10377 * record.c (get_call_history_modifiers): Return a
10378 record_print_flags.
10379 (cmd_record_call_history): Adjust.
10380 * record-btrace.c (record_btrace_call_history): Adjust.
10381 (record_btrace_call_history_range): Adjust.
10382 (record_btrace_call_history_from): Adjust.
10383 * target-debug.h (target_debug_print_record_print_flags): New.
10384 * target-delegates.c: Re-generate.
10385 * target.c (target_call_history): Change flags type.
10386 (target_call_history_from): Likewise.
10387 (target_call_history_range): Likewise.
10388 * target.h (struct target_ops) <target_call_history>: Likewise.
10389 (target_call_history_from): Likewise.
10390 (target_call_history_range): Likewise.
10392 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
10393 Simon Marchi <simon.marchi@polymtl.ca>
10395 * common/common-utils.c: Include "sys/stat.h".
10396 (is_regular_file): Move here from "source.c"; change return
10398 * common/common-utils.h (is_regular_file): New prototype.
10399 * common/pathstuff.c (contains_dir_separator): New function.
10400 * common/pathstuff.h (contains_dir_separator): New prototype.
10401 * source.c: Don't include "sys/stat.h".
10402 (is_regular_file): Move to "common/common-utils.c".
10404 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
10406 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
10407 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
10408 * auto-load.c: Include "common/pathstuff.h".
10409 * common/common-def.h (current_directory): Move here.
10410 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
10412 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
10414 * common/pathstuff.c: New file.
10415 * common/pathstuff.h: New file.
10416 * compile/compile.c: Include "common/pathstuff.h".
10417 * defs.h (current_directory): Move to "common/common-defs.h".
10418 * dwarf2read.c: Include "common/pathstuff.h".
10419 * exec.c: Likewise.
10420 * guile/scm-safe-call.c: Likewise.
10421 * linux-thread-db.c: Likewise.
10422 * main.c: Likewise.
10423 * nto-tdep.c: Likewise.
10424 * objfiles.c: Likewise.
10425 * source.c: Likewise.
10426 * symtab.c: Likewise.
10427 * utils.c: Include "common/pathstuff.h".
10428 (gdb_realpath): Move to "common/pathstuff.c".
10429 (gdb_realpath_keepfile): Likewise.
10430 (gdb_abspath): Likewise.
10431 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
10432 (gdb_realpath_keepfile): Likewise.
10433 (gdb_abspath): Likewise.
10435 2018-02-28 John Baldwin <jhb@FreeBSD.org>
10437 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
10438 wildcard process pid for super_resume for kernels with a
10441 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
10443 * compile/compile.c (get_args): Add additional comments
10444 explaining function.
10446 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
10447 Tom Tromey <tom@tromey.com>
10449 * target.h (memory_write_request_s): Remove typedef. Don't define
10451 (target_write_memory_blocks): Change argument to std::vector.
10452 (struct memory_write_request): Add constructor.
10453 * target-memory.c (compare_block_starting_address): Return bool.
10454 Change argument types.
10455 (claim_memory): Change arguments to use std::vector.
10456 (split_regular_and_flash_blocks, blocks_to_erase)
10457 (compute_garbled_blocks): Likewise.
10458 (cleanup_request_data, cleanup_write_requests_vector): Remove.
10459 (target_write_memory_blocks): Change argument to std::vector.
10460 * symfile.c (struct load_section_data): Add constructor and
10461 destructor. Use std::vector for "requests".
10462 (struct load_progress_data): Add initializers.
10463 (load_section_callback): Update. Use "new".
10464 (clear_memory_write_data): Remove.
10465 (generic_load): Update.
10467 2018-02-27 Alan Hayward <alan.hayward@arm.com>
10469 * arch/aarch64.h: Use common/tdesc.h.
10471 2018-02-26 Maciej W. Rozycki <macro@mips.com>
10473 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
10474 architecture with a 64-bit ABI.
10476 2018-02-26 Maciej W. Rozycki <macro@mips.com>
10478 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
10479 ahead of target description loading.
10481 2018-02-26 Tom Tromey <tom@tromey.com>
10483 * stack.c (backtrace_command_1): Update.
10484 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
10486 * python/py-framefilter.c (py_print_frame)
10487 (gdbpy_apply_frame_filter): Change type of "flags".
10488 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
10490 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
10491 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
10492 * extension.h (enum frame_filter_flag): Rename from
10493 frame_filter_flags.
10494 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
10495 (apply_ext_lang_frame_filter): Change type of "flags".
10496 * extension.c (apply_ext_lang_frame_filter): Change type of
10498 * extension-priv.h (struct extension_language_ops)
10499 <apply_frame_filter>: Change type of "flags".
10501 2018-02-26 Tom Tromey <tom@tromey.com>
10504 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
10505 off-by-one in py_end computation.
10506 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
10508 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
10511 2018-02-26 Tom Tromey <tom@tromey.com>
10513 * dwarf2read.c (struct variant_field): New.
10514 (struct nextfield) <variant>: New field.
10515 (dwarf2_add_field): Handle DW_TAG_variant_part.
10516 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
10517 discriminated union.
10518 (read_structure_type): Handle DW_TAG_variant_part.
10519 (handle_struct_member_die): New function, extracted from
10520 process_structure_scope. Handle DW_TAG_variant.
10521 (process_structure_scope): Handle discriminated unions. Call
10522 handle_struct_member_die.
10524 2018-02-26 Tom Tromey <tom@tromey.com>
10526 * rust-lang.h (rust_last_path_segment): Declare.
10527 * rust-lang.c (rust_last_path_segment): Now public. Change
10529 (struct disr_info): Remove.
10530 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
10531 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
10532 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
10533 (rust_enum_p, rust_enum_variant): New function.
10534 (rust_underscore_fields): Remove "offset" parameter.
10535 (rust_print_enum): New function.
10536 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
10537 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
10538 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
10540 (rust_internal_print_type): New function, from rust_print_type.
10542 (rust_print_type): Call rust_internal_print_type.
10543 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
10544 Update enum handling.
10545 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
10546 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
10547 (rust_union_quirks): New functions.
10548 (process_full_comp_unit, process_full_type_unit): Call
10550 (process_structure_scope): Update rust_unions if necessary.
10552 2018-02-26 Tom Tromey <tom@tromey.com>
10554 * value.h (value_union_variant): Declare.
10555 * valops.c (value_union_variant): New function.
10556 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
10557 (struct discriminant_info): New.
10558 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
10560 (struct main_type) <flag_discriminated_union>: New field.
10562 2018-02-26 Tom Tromey <tom@tromey.com>
10564 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10565 unittests/unpack-selftests.c.
10566 * unittests/unpack-selftests.c: New file.
10567 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
10569 2018-02-26 Yao Qi <yao.qi@linaro.org>
10571 * dwarf2read.c (struct partial_die_info) <read>: New method.
10572 (read_partial_die): Remove the declaration.
10573 (load_partial_dies): Update.
10574 (partial_die_info::partial_die_info):
10575 (read_partial_die): Change it to partial_die_info::read.
10577 2018-02-26 Yao Qi <yao.qi@linaro.org>
10579 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
10580 (fixup_partial_die): Remove declaration.
10581 (scan_partial_symbols): Update.
10582 (partial_die_parent_scope): Likewise.
10583 (partial_die_full_name): Likewise.
10584 (fixup_partial_die): Change it to partial_die_info::fixup.
10586 2018-02-26 Yao Qi <yao.qi@linaro.org>
10588 * dwarf2read.c (read_partial_die): Update the declaration.
10589 (load_partial_dies): Caller update.
10590 (read_partial_die): Remove one argument abbrev_len.
10592 2018-02-26 Yao Qi <yao.qi@linaro.org>
10594 * dwarf2read.c (struct partial_die_info): Add ctor, delete
10595 assignment operator.
10596 (load_partial_dies): Use ctor and copy ctor.
10597 (read_partial_die): Update.
10598 (dwarf2_cu::find_partial_die): Use ctor.
10600 2018-02-26 Yao Qi <yao.qi@linaro.org>
10602 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
10603 (find_partial_die_in_comp_unit): Change it to
10604 dwarf2_cu::find_partial_die.
10605 (find_partial_die): Update.
10607 2018-02-26 Yao Qi <yao.qi@linaro.org>
10609 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
10612 2018-02-26 Yao Qi <yao.qi@linaro.org>
10614 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
10616 2018-02-26 Alan Hayward <alan.hayward@arm.com>
10618 * arch/amd64.h: Use common/tdesc.h.
10619 * arch/i386.c: Likewise.
10620 * arch/i386.h: Likewise.
10621 * arch/tic6x.c: Likewise.
10622 * arch/tdesc.h: Move file from here...
10623 * common/tdesc.h: ...to here.
10624 * features/aarch64-core.c: Regenerate.
10625 * features/aarch64-fpu.c: Regenerate.
10626 * features/i386/32bit-avx.c: Regenerate.
10627 * features/i386/32bit-avx512.c: Regenerate.
10628 * features/i386/32bit-core.c: Regenerate.
10629 * features/i386/32bit-linux.c: Regenerate.
10630 * features/i386/32bit-mpx.c: Regenerate.
10631 * features/i386/32bit-pkeys.c: Regenerate.
10632 * features/i386/32bit-sse.c: Regenerate.
10633 * features/i386/64bit-avx.c: Regenerate.
10634 * features/i386/64bit-avx512.c: Regenerate.
10635 * features/i386/64bit-core.c: Regenerate.
10636 * features/i386/64bit-linux.c: Regenerate.
10637 * features/i386/64bit-mpx.c: Regenerate.
10638 * features/i386/64bit-pkeys.c: Regenerate.
10639 * features/i386/64bit-segments.c: Regenerate.
10640 * features/i386/64bit-sse.c: Regenerate.
10641 * features/i386/x32-core.c: Regenerate.
10642 * features/tic6x-c6xp.c: Regenerate.
10643 * features/tic6x-core.c: Regenerate.
10644 * features/tic6x-gp.c: Regenerate.
10645 * target-descriptions.c: Use common/tdesc.h.
10646 * target-descriptions.h: Likewise.
10648 2018-02-24 Tom Tromey <tom@tromey.com>
10650 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
10651 (try_thread_db_load_from_dir, thread_db_load_search): Use
10653 (info_auto_load_libthread_db_compare): Return bool. Change
10655 (info_auto_load_libthread_db): Use std::vector, std::string.
10658 2018-02-24 Tom Tromey <tom@tromey.com>
10660 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
10662 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
10664 * gdbarch.c: Rebuild.
10665 * gdbarch.h: Rebuild.
10666 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
10667 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
10668 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
10671 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
10673 * gdbtypes.h (sect_offset): Change type to uint64_t.
10674 (sect_offset_str): New function.
10675 * dwarf2read.c (create_addrmap_from_aranges): Use
10677 (error_check_comp_unit_head): Likewise.
10678 (create_debug_type_hash_table): Likewise.
10679 (read_cutu_die_from_dwo): Likewise.
10680 (init_cutu_and_read_dies): Likewise.
10681 (init_cutu_and_read_dies_no_follow): Likewise.
10682 (process_psymtab_comp_unit_reader): Likewise.
10683 (partial_die_parent_scope): Likewise.
10684 (peek_die_abbrev): Likewise.
10685 (process_queue): Likewise.
10686 (dwarf2_physname): Likewise.
10687 (read_namespace_alias): Likewise.
10688 (read_import_statement): Likewise.
10689 (create_dwo_cu_reader): Likewise.
10690 (create_cus_hash_table): Likewise.
10691 (lookup_dwo_cutu): Likewise.
10692 (inherit_abstract_dies): Likewise.
10693 (read_func_scope): Likewise.
10694 (read_call_site_scope): Likewise.
10695 (dwarf2_add_member_fn): Likewise.
10696 (read_common_block): Likewise.
10697 (read_module_type): Likewise.
10698 (read_typedef): Likewise.
10699 (read_subrange_type): Likewise.
10700 (load_partial_dies): Likewise.
10701 (read_partial_die): Likewise.
10702 (find_partial_die): Likewise.
10703 (read_str_index): Likewise.
10704 (dwarf2_string_attr): Likewise.
10705 (build_error_marker_type): Likewise.
10706 (lookup_die_type): Likewise.
10707 (dump_die_shallow): Likewise.
10708 (follow_die_ref): Likewise.
10709 (dwarf2_fetch_die_loc_sect_off): Likewise.
10710 (dwarf2_fetch_constant_bytes): Likewise.
10711 (follow_die_sig): Likewise.
10712 (get_signatured_type): Likewise.
10713 (get_DW_AT_signature_type): Likewise.
10714 (dwarf2_find_containing_comp_unit): Likewise.
10715 (set_die_type): Likewise.
10717 2018-02-21 John Baldwin <jhb@FreeBSD.org>
10719 * arch/aarch64.c: Include "common-defs.h".
10720 * arch/amd64.c: Likewise.
10721 * arch/i386.c: Likewise.
10723 2018-02-21 Tom Tromey <tom@tromey.com>
10725 * value.h: (extract_field_op): Update.
10726 * eval.c (extract_field_op): Return a const char *.
10727 * expression.h (parse_expression_for_completion): Update.
10728 * completer.c (complete_expression): Update.
10729 (add_struct_fields): Make fieldname const.
10730 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
10731 (mark_completion_tag, parse_exp_in_context_1): Update.
10732 (parse_expression_for_completion): Change "name" to
10733 unique_xmalloc_ptr*.
10735 2018-02-21 Tom Tromey <tom@tromey.com>
10737 * infcall.c (call_function_by_hand_dummy): Use std::vector.
10739 2018-02-21 Yao Qi <yao.qi@linaro.org>
10741 * avr-tdep.c (avr_read_pc): Change parameter type to
10743 * gdbarch.sh (read_pc): Likewise.
10744 * gdbarch.c: Re-generated.
10745 * gdbarch.h: Re-generated.
10746 * hppa-tdep.c (hppa_read_pc): Change parameter type to
10748 * ia64-tdep.c (ia64_read_pc): Likewise.
10749 * mips-tdep.c (mips_read_pc): Likewise.
10750 * spu-tdep.c (spu_read_pc): Likewise.
10752 2018-02-21 Yao Qi <yao.qi@linaro.org>
10754 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
10755 * regcache-dump.c: New file.
10756 * regcache.c: Move register_dump to regcache-dump.c.
10757 (maintenance_print_registers): Likewise.
10758 (maintenance_print_raw_registers): Likewise.
10759 (maintenance_print_cooked_registers): Likewise.
10760 (maintenance_print_register_groups): Likewise.
10761 (maintenance_print_remote_registers): Likewise.
10762 (_initialize_regcache): Likewise.
10763 * regcache.h (register_dump): Moved from regcache.c.
10765 2018-02-21 Yao Qi <yao.qi@linaro.org>
10767 * regcache.c (regcache::regcache): Update.
10768 (regcache::invalidate): Move it to detached_regcache::invalidate.
10769 (get_thread_arch_aspace_regcache): Update.
10770 (regcache::raw_update): Update.
10771 (regcache::cooked_read): Remove some code.
10772 (regcache::cooked_read_value): Likewise.
10773 (regcache::raw_write): Remove assert on m_readonly_p.
10774 (regcache::raw_supply_integer): Move it to
10775 detached_regcache::raw_supply_integer.
10776 (regcache::raw_supply_zeroed): Likewise.
10777 * regcache.h (detached_regcache) <raw_supply_integer>: New
10779 <raw_supply_zeroed, invalidate>: Likewise.
10780 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
10781 <invalidate>: Likewise.
10782 <m_readonly_p>: Removed.
10784 2018-02-21 Yao Qi <yao.qi@linaro.org>
10786 * infcmd.c (get_return_value): Let stop_regs point to
10787 get_current_regcache.
10788 * regcache.c (regcache::regcache): Remove.
10789 (register_dump_reg_buffer): New class.
10790 (regcache_print): Adjust.
10791 * regcache.h (regcache): Remove constructors.
10793 2018-02-21 Yao Qi <yao.qi@linaro.org>
10795 * regcache.c (class register_dump): New class.
10796 (register_dump_regcache, register_dump_none): New class.
10797 (register_dump_remote, register_dump_groups): New class.
10798 (regcache_print): Update.
10799 * regcache.h (regcache_dump_what): Move it to regcache.c.
10800 (regcache) <dump>: Remove.
10802 2018-02-21 Yao Qi <yao.qi@linaro.org>
10804 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
10806 (jit_unwind_reg_set_impl): Call raw_supply.
10807 (jit_frame_sniffer): Use reg_buffer_rw.
10808 * record-full.c (record_full_core_regbuf): Change its type.
10809 (record_full_core_open_1): Use reg_buffer_rw.
10810 (record_full_close): Likewise.
10811 (record_full_core_fetch_registers): Use regcache->raw_supply.
10812 (record_full_core_store_registers): Likewise.
10813 * regcache.c (regcache::get_register_status): Move it to
10815 (regcache_raw_set_cached_value): Remove.
10816 (regcache::raw_set_cached_value): Remove.
10817 (regcache::raw_write): Call raw_supply.
10818 (regcache::raw_supply): Move it to reg_buffer_rw.
10819 * regcache.h (regcache_raw_set_cached_value): Remove.
10820 (reg_buffer_rw): New class.
10822 2018-02-21 Yao Qi <yao.qi@linaro.org>
10824 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
10825 readonly_detached_regcache.
10826 (dummy_frame_prev_register): Use regcache->cooked_read.
10827 * frame.c (frame_save_as_regcache): Change return type.
10828 (frame_pop): Update.
10829 * frame.h (frame_save_as_regcache): Update declaration.
10830 * inferior.h (get_infcall_suspend_state_regcache): Update
10832 * infrun.c (infcall_suspend_state) <registers>: use
10833 readonly_detached_regcache.
10834 (save_infcall_suspend_state): Don't use regcache_dup.
10835 (get_infcall_suspend_state_regcache): Change return type.
10836 * linux-fork.c (struct fork_info) <savedregs>: Change to
10837 readonly_detached_regcache.
10839 (fork_save_infrun_state): Don't use regcache_dup.
10840 (info_checkpoints_command): Adjust.
10841 * mi/mi-main.c (register_changed_p): Update declaration.
10842 (mi_cmd_data_list_changed_registers): Use
10843 readonly_detached_regcache.
10844 (register_changed_p): Change parameter type to
10845 readonly_detached_regcache.
10846 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
10847 readonly_detached_regcache.
10848 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
10849 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
10851 (regcache::save): Move it to reg_buffer.
10852 (regcache::restore): Change parameter type.
10853 (regcache_dup): Remove.
10854 * regcache.h (reg_buffer) <save>: New method.
10855 (readonly_detached_regcache): New class.
10856 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
10857 readonly_detached_regcache.
10858 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
10860 2018-02-21 Yao Qi <yao.qi@linaro.org>
10862 * frame.c (frame_save_as_regcache): Use regcache method save.
10863 (frame_pop): Use regcache method restore.
10864 * infrun.c (restore_infcall_suspend_state): Likewise.
10865 * linux-fork.c (fork_load_infrun_state): Likewise.
10866 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
10868 * regcache.c (regcache_save): Remove.
10869 (regcache::restore): More asserts.
10870 (regcache_cpy): Remove.
10871 * regcache.h (regcache_save): Remove the declaration.
10872 (regcache::restore): Move from private to public.
10873 Remove the friend declaration of regcache_cpy.
10874 (regcache_cpy): Remove declaration.
10876 2018-02-21 Yao Qi <yao.qi@linaro.org>
10878 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
10879 parameter type to 'readable_regcache *'.
10880 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10881 * arm-tdep.c (arm_neon_quad_read): Likewise.
10882 (arm_pseudo_read): Likewise.
10883 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10884 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10885 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10886 * gdbarch.c: Re-generated.
10887 * gdbarch.h: Re-generated.
10888 * gdbarch.sh (pseudo_register_read): Change parameter type to
10889 'readable_regcache *'.
10890 (pseudo_register_read_value): Likewise.
10891 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
10892 (h8300_pseudo_register_read): Likewise.
10893 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
10894 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10895 (i386_pseudo_register_read_into_value): Likewise.
10896 (i386_pseudo_register_read_value): Likewise.
10897 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
10899 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
10900 * m32c-tdep.c (m32c_raw_read): Likewise.
10901 (m32c_read_flg): Likewise.
10902 (m32c_banked_register): Likewise.
10903 (m32c_banked_read): Likewise.
10904 (m32c_sb_read): Likewise.
10905 (m32c_part_read): Likewise.
10906 (m32c_cat_read): Likewise.
10907 (m32c_r3r2r1r0_read): Likewise.
10908 (m32c_pseudo_register_read): Likewise.
10909 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10910 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10911 (mep_pseudo_cr64_read): Likewise.
10912 (mep_pseudo_register_read): Likewise.
10913 * mips-tdep.c (mips_pseudo_register_read): Likewise.
10914 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10915 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10916 * regcache.c (regcache::raw_read): Move it to readable_regcache.
10917 (regcache::cooked_read): Likewise.
10918 (regcache::cooked_read_value): Likewise.
10919 (regcache_cooked_read_signed):
10920 (regcache::cooked_read): Likewise.
10921 * regcache.h (readable_regcache): New class.
10922 (regcache): Inherit readable_regcache. Move some methods to
10924 * rl78-tdep.c (rl78_pseudo_register_read): Change
10925 parameter type to 'readable_regcache *'.
10926 * rs6000-tdep.c (do_regcache_raw_read): Remove.
10927 (e500_pseudo_register_read): Change parameter type to
10928 'readable_regcache *'.
10929 (dfp_pseudo_register_read): Likewise.
10930 (vsx_pseudo_register_read): Likewise.
10931 (efpr_pseudo_register_read): Likewise.
10932 * s390-tdep.c (s390_pseudo_register_read): Likewise.
10933 * sh-tdep.c (sh_pseudo_register_read): Likewise.
10934 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
10935 (sh64_pseudo_register_read): Likewise.
10936 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10937 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10938 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10939 (spu_pseudo_register_read): Likewise.
10940 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10941 (xtensa_pseudo_register_read): Likewise.
10943 2018-02-21 Yao Qi <yao.qi@linaro.org>
10945 * regcache.c (regcache::regcache): Call reg_buffer ctor.
10946 (regcache::arch): Move it to reg_buffer::arch.
10947 (regcache::register_buffer): Likewise.
10948 (regcache::assert_regnum): Likewise.
10949 (regcache::num_raw_registers): Likewise.
10950 * regcache.h (reg_buffer): New class.
10951 (regcache): Inherit reg_buffer.
10953 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
10955 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
10956 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
10958 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
10960 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
10962 2018-02-19 Alan Hayward <alan.hayward@arm.com>
10964 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
10965 (SFILES): Remove common/*.c files.
10966 (COMMON_OBS): Remove some *.o files built from common/*.c files.
10967 * common/common.host: Add common reference.
10968 * configure.ac: Likewise.
10969 * configure: Regenerate.
10971 2018-02-16 Yao Qi <yao.qi@linaro.org>
10973 * block.c (block_namespace_info): Inherit allocate_on_obstack.
10974 (block_initialize_namespace): Use new.
10975 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
10976 (dwarf2_free_objfile): Use delete.
10977 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
10978 (copy_type_recursive): Use new.
10979 * gdb_obstack.h (allocate_on_obstack): New.
10981 2018-02-15 Yao Qi <yao.qi@linaro.org>
10984 * inferior.c (exit_inferior_1): Reset inf->control.
10986 2018-02-15 Joel Brobecker <brobecker@adacore.com>
10988 * ada-lang.c (ada_to_fixed_value_create): Delete advance
10991 2018-02-14 Pedro Alves <palves@redhat.com>
10993 * frame-unwind.c (frame_unwind_try_unwinder): Always call
10994 frame_cleanup_after_sniffer on exception.
10996 2018-02-14 Tom Tromey <tom@tromey.com>
10998 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11000 (solib_bfd_open): Make pathname const.
11001 * solib.c (solib_bfd_open): Make pathname const.
11002 * solib-spu.c (spu_bfd_fopen): Make name const.
11003 (spu_bfd_open): Make pathname const.
11004 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11005 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11007 2018-02-14 Tom Tromey <tom@tromey.com>
11009 * symfile.c (symfile_bfd_open): Update.
11010 * source.h (openp, source_full_path_of, find_and_open_source):
11011 Change argument type to unique_xmalloc_ptr.
11012 * source.c (openp): Take a unique_xmalloc_ptr.
11013 (source_full_path_of, find_and_open_source): Likewise.
11014 (open_source_file, symtab_to_fullname): Update.
11015 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11016 unique_xmalloc_ptr.
11017 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11018 (exec_file_find): Update.
11019 * psymtab.c (psymtab_to_fullname): Update.
11020 * nto-tdep.h (nto_find_and_open_solib): Update.
11021 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11022 unique_xmalloc_ptr.
11023 * exec.c (exec_file_attach): Update.
11024 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11025 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11027 2018-02-14 Tom Tromey <tom@tromey.com>
11029 * solib.c: Include source.h.
11030 * nto-tdep.c: Include source.h.
11031 * mi/mi-cmd-env.c: Include source.h.
11032 * infcmd.c: Include source.h.
11033 * exec.c: Include source.h.
11034 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11035 (add_path, directory_switch, source_path, init_source_path): Move
11037 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11038 (add_path, directory_switch, source_path, init_source_path):
11041 2018-02-14 Tom Tromey <tom@tromey.com>
11043 * solist.h (exec_file_find, solib_find): Return
11044 unique_xmalloc_ptr.
11045 (solib_bfd_fopen): Take a const char *.
11046 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11047 (exec_file_find, solib_find): Likewise.
11048 (solib_bfd_fopen): Do not take ownership of "pathname".
11049 (solib_bfd_open): Use unique_xmalloc_ptr.
11050 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11051 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11052 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11053 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11055 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11057 * ada-lang.c (name_match_type_from_name): Remove reference to
11058 ada_name_for_lookup in function's documentation.
11059 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11061 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11063 * defs.h (enum openp_flags): New enum.
11064 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
11065 Move to enum openp_flags.
11066 (openp_flags): New enum flags.
11067 (openp): Change parameter type to openp_flags.
11068 * source.c (openp): Change parameter type to openp_flags.
11069 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
11070 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
11072 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11074 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
11077 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
11079 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
11081 (class dwarf2_queue_guard): ...the destructor of this new class.
11082 (dw2_do_instantiate_symtab): Create instance of the new class
11083 dwarf2_queue_guard, remove cleanup.
11085 2018-02-09 Tom Tromey <tom@tromey.com>
11087 * source.c (find_source_lines): Don't reference past the end of
11090 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11092 * remote.c (remote_btrace_maybe_reopen): Change error message.
11093 * btrace.c (btrace_enable): Likewise.
11094 (parse_xml_btrace): Likewise.
11095 (parse_xml_btrace_conf): Likewise.
11097 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11099 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
11100 (linux_enable_pt, linux_enable_bts): Call
11101 diagnose_perf_event_open_fail.
11103 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11105 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
11106 Remove parameter and change return type. Update callers. Move it.
11107 (linux_enable_bts, linux_enable_pt): Improve error message.
11108 (linux_enable_pt): Remove zero buffer size check.
11109 (linux_enable_btrace): Improve error messages. Remove NULL return
11112 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11114 * btrace.c (btrace_enable): Remove target_supports_btrace call.
11115 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
11116 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
11117 (linux_supports_pt, linux_supports_btrace): Remove.
11118 (linux_enable_bts): Call cpu_supports_bts.
11119 * nat/linux-btrace.h (linux_supports_btrace): Remove.
11120 * remote.c (remote_supports_btrace): Remove.
11121 (init_remote_ops): Remove remote_supports_btrace.
11122 * target-delegates.c: Regenerated.
11123 * target.c (target_supports_btrace): Remove.
11124 * target.h (target_ops) <to_supports_btrace>: Remove
11125 (target_supports_btrace): Remove.
11126 * x86-linux-nat.c (x86_linux_create_target): Remove
11127 linux_supports_btrace.
11129 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11131 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
11133 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
11134 exception and use message in own exception.
11136 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11138 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
11139 (perf_event_pt_event_type): Use gdb_file_up.
11140 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
11141 scoped_fd, and scoped_mmap.
11143 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11145 * common/scoped_mmap.h: New.
11146 * unittests/scoped_mmap-selftest.c: New.
11147 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11148 unittests/scoped_mmap-selftest.c.
11150 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
11152 * common/scoped_fd.h: New.
11153 * unittests/scoped_fd-selftest.c: New.
11154 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11155 unittests/scoped_fd-selftest.c.
11157 2018-02-09 Tom Tromey <tom@tromey.com>
11159 * auto-load.c (auto_load_section_scripts): Use
11160 gdb::unique_xmalloc_ptr.
11162 2018-02-09 Tom Tromey <tom@tromey.com>
11164 * auto-load.c (execute_script_contents): Use std::string.
11166 2018-02-09 Joel Brobecker <brobecker@adacore.com>
11168 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
11169 Python function, rather than a new command.
11171 2018-02-08 Tom Tromey <tom@tromey.com>
11173 * solib.c (solib_find_1): Use std::string.
11174 (solib_bfd_fopen): Use unique_xmalloc_ptr.
11176 2018-02-08 Tom Tromey <tom@tromey.com>
11178 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
11180 2018-02-08 Tom Tromey <tom@tromey.com>
11182 * source.c (find_source_lines): Use gdb::def_vector.
11184 2018-02-08 Tom Tromey <tom@tromey.com>
11186 * macrocmd.c (struct temporary_macro_definition): New.
11187 (macro_define_command): Use temporary_macro_definition. Remove
11189 (free_macro_definition_ptr): Remove.
11191 2018-02-08 Tom Tromey <tom@tromey.com>
11193 * macroexp.c (maybe_expand): Use std::string.
11195 2018-02-08 Tom Tromey <tom@tromey.com>
11197 * macroexp.c (struct macro_buffer): Add initializers for some
11199 (init_buffer, init_shared_buffer, free_buffer)
11200 (free_buffer_return_text): Remove.
11201 (macro_buffer): New constructors.
11202 (~macro_buffer): New destructor.
11203 (macro_buffer::set_shared): New method.
11204 (macro_buffer::resize_buffer, macro_buffer::appendc)
11205 (macro_buffer::appendmem): Now methods, not free functions.
11206 (set_token, append_tokens_without_splicing, stringify)
11207 (macro_stringify): Update.
11208 (gather_arguments): Change return type. Remove argc_p argument,
11209 add args_ptr argument. Use std::vector.
11210 (substitute_args): Remove argc argument. Accept std::vector.
11211 (expand): Update. Use std::vector.
11212 (scan, macro_expand, macro_expand_next): Update.
11214 2018-02-08 Tom Tromey <tom@tromey.com>
11216 * symtab.c (default_collect_symbol_completion_matches_break_on):
11217 Use unique_xmalloc_ptr.
11218 * macroscope.h: (sal_macro_scope, user_macro_scope)
11219 (default_macro_scope): Return unique_xmalloc_ptr.
11220 * macroscope.c (sal_macro_scope, user_macro_scope)
11221 (default_macro_scope): Return unique_xmalloc_ptr.
11222 * macroexp.h (macro_expand, macro_expand_once): Return
11223 unique_xmalloc_ptr.
11224 * macroexp.c (macro_expand, macro_expand_once): Return
11225 unique_xmalloc_ptr.
11226 * macrocmd.c (macro_expand_command, macro_expand_once_command)
11227 (info_macro_command, info_macros_command): Use
11228 unique_xmalloc_ptr.
11229 * compile/compile-c-support.c (write_macro_definitions): Use
11230 unique_xmalloc_ptr.
11231 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
11233 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
11235 * value.c (value_static_field): Assign field type instead of
11236 containing type when returning an optimized out value.
11238 2018-02-06 Yao Qi <yao.qi@linaro.org>
11240 * ft32-tdep.c (ft32_read_pc): Remove.
11241 (ft32_write_pc): Remove.
11242 (ft32_gdbarch_init): Update.
11243 * m32r-tdep.c (m32r_read_pc): Remove.
11244 (m32r_gdbarch_init): Update.
11245 * mep-tdep.c (mep_read_pc): Remove.
11246 (mep_gdbarch_init): Update.
11247 * microblaze-tdep.c (microblaze_write_pc): Remove.
11248 (microblaze_gdbarch_init): Update.
11249 * mn10300-tdep.c (mn10300_read_pc): Remove.
11250 (mn10300_write_pc): Remove.
11251 (mn10300_gdbarch_init): Update.
11252 * moxie-tdep.c (moxie_read_pc): Remove.
11253 (moxie_write_pc): Remove.
11254 (moxie_gdbarch_init): Update.
11256 2018-02-06 Yao Qi <yao.qi@linaro.org>
11258 * expprint.c (print_subexp_standard): Handle
11259 OP_F77_UNDETERMINED_ARGLIST.
11260 (dump_subexp_body_standard): Likewise.
11262 2018-02-05 Alan Hayward <alan.hayward@arm.com>
11264 * target-descriptions.c (tdesc_element_visitor) Add empty
11266 (tdesc_type): Move make_gdb_type from here.
11267 (tdesc_type_builtin): Likewise.
11268 (tdesc_type_vector): Likewise.
11269 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
11270 (make_gdb_type_struct): Move from tdesc_type_with_fields.
11271 (make_gdb_type_union): Likewise.
11272 (make_gdb_type_flags): Likewise.
11273 (make_gdb_type_enum): Likewise.
11274 (make_gdb_type): New function.
11275 (tdesc_register_type): Use static make_gdb_type.
11277 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
11279 * infcmd.c (default_print_one_register_info): Align natural-format
11280 column values consistently one under another.
11281 (pad_to_column): New function.
11283 2018-02-05 Joel Brobecker <brobecker@adacore.com>
11285 * dwarf2read.c (dwarf2_physname): Move commment.
11287 2018-02-01 Leszek Swirski <leszeks@google.com>
11289 * varobj.c (varobj_formatted_print_options): Allow recursive
11290 pretty printing if pretty printing is enabled.
11292 2018-02-01 Leszek Swirski <leszeks@google.com>
11294 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
11295 names after a structop as a filename.
11297 2018-02-01 Yao Qi <yao.qi@linaro.org>
11299 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
11300 (arm_record_coproc_data_proc): Likewise.
11302 2018-02-01 Yao Qi <yao.qi@linaro.org>
11304 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
11306 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
11308 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
11309 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
11311 2018-01-31 Pedro Alves <palves@redhat.com>
11313 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
11314 * inflow.c (child_terminal_save_inferior): Wrap reference to
11315 tcgetpgrp in HAVE_TERMIOS_H.
11316 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
11318 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
11319 always iterate over all inferiors.
11320 (gdbsim_cntrl_c): Adjust.
11321 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
11323 2018-01-31 Joel Brobecker <brobecker@adacore.com>
11325 * gdbtypes.c (lookup_array_range_type): Make sure the array's
11326 index type is objfile-owned if the element type is as well.
11328 2018-01-31 Joel Brobecker <brobecker@adacore.com>
11332 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
11334 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
11335 "features/s390x-linux64.c".
11336 (_initialize_s390_linux_tdep): Remove initialization of tdescs
11337 s390_linux32 and s390x_linux64.
11338 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
11340 * s390-tdep.c: Include "features/s390-linux32.c" and
11341 "features/s390x-linux64.c".
11342 (s390_tdesc_valid): Add check for tdesc_has_registers.
11343 (s390_gdbarch_init): Make sure there is always a valid tdesc.
11344 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
11345 tdesc_s390x_linux64.
11346 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
11347 tdesc_s390x_linux64 to...
11348 * s390-tdep.h: ...here.
11350 2018-01-30 Pedro Alves <palves@redhat.com>
11353 * config.in, configure: Regenerate.
11354 * configure.ac: Check for getpgid.
11355 * go32-nat.c (go32_pass_ctrlc): New.
11356 (go32_target): Install it.
11357 * inf-child.c (inf_child_target): Install
11358 child_terminal_save_inferior, child_pass_ctrlc and
11360 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
11361 (inf_ptrace_target): No longer install it.
11362 * infcmd.c (interrupt_target_1): Adjust.
11363 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
11364 (child_interrupt): Declare.
11365 (inferior::terminal_state): New.
11366 * inflow.c (struct terminal_info): Update comments.
11367 (inferior_process_group): Delete.
11368 (terminal_is_ours): Delete.
11369 (gdb_tty_state): New.
11370 (child_terminal_init): Adjust.
11371 (is_gdb_terminal, sharing_input_terminal_1)
11372 (sharing_input_terminal): New functions.
11373 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
11374 Set the process's actual process group in the foreground if
11375 possible. Handle is_ours_for_output/is_ours distinction. Don't
11376 mark terminal as the inferior's if not sharing GDB's terminal.
11377 Don't check attach_flag.
11378 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
11379 pass down a target_terminal_state.
11380 (child_terminal_save_inferior): New, factored out from ...
11381 (child_terminal_ours_1): ... this. Handle
11382 target_terminal_state::is_ours_for_output.
11383 (child_interrupt, child_pass_ctrlc): New.
11384 (inflow_inferior_exit): Clear the inferior's terminal_state.
11385 (copy_terminal_info): Copy the inferior's terminal state.
11386 (_initialize_inflow): Remove reference to terminal_is_ours.
11387 * inflow.h (inferior_process_group): Delete.
11388 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
11389 * procfs.c (procfs_target): Don't install procfs_interrupt.
11390 (procfs_interrupt): Delete.
11391 * remote.c (remote_serial_quit_handler): Adjust.
11392 (remote_interrupt): Remove ptid parameter. Adjust.
11393 * target-delegates.c: Regenerate.
11394 * target.c: Include "terminal.h".
11395 (target_terminal::terminal_state): Rename to ...
11396 (target_terminal::m_terminal_state): ... this.
11397 (target_terminal::init): Adjust.
11398 (target_terminal::inferior): Adjust to per-inferior
11400 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
11401 (target_terminal::ours, target_terminal::ours_for_output): Use
11402 target_terminal_is_ours_kind.
11403 (target_interrupt): Remove ptid parameter. Adjust.
11404 (default_target_pass_ctrlc): Adjust.
11405 * target.h (target_ops::to_terminal_save_inferior): New field.
11406 (target_ops::to_interrupt): Remove ptid_t parameter.
11407 (target_interrupt): Remove ptid_t parameter. Update comment.
11408 (target_pass_ctrlc): Update comment.
11409 * target/target.h (target_terminal_state): New scoped enum,
11410 factored out of ...
11411 (target_terminal::terminal_state): ... here.
11412 (target_terminal::inferior): Update comments.
11413 (target_terminal::restore_inferior): New.
11414 (target_terminal::is_inferior, target_terminal::is_ours)
11415 (target_terminal::is_ours_for_output): Adjust.
11416 (target_terminal::scoped_restore_terminal_state): Adjust to
11417 rename, and call restore_inferior() instead of inferior().
11418 (target_terminal::scoped_restore_terminal_state::m_state): Change
11420 (target_terminal::terminal_state): Rename to ...
11421 (target_terminal::m_terminal_state): ... this and change type.
11423 2018-01-30 Pedro Alves <palves@redhat.com>
11425 * linux-nat.c (wait_for_signal): New function.
11426 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
11428 (async_terminal_is_ours)
11429 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
11430 (linux_nat_add_target): Don't override
11431 to_terminal_inferior/to_terminal_ours.
11433 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
11435 * remote.c (remote_follow_fork): Don't call "detach_inferior".
11437 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
11439 * dwarf2read.c (free_dwo_files): Add forward-declaration.
11440 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
11441 dwarf2_per_objfile_free here.
11442 (dwarf2_per_objfile_free): Remove.
11443 (_initialize_dwarf2_read): Don't register
11444 dwarf2_per_objfile_free as a registry cleanup.
11446 2018-01-27 Eli Zaretskii <eliz@gnu.org>
11448 Avoid compilation errors in MinGW native builds
11450 The error is triggered by including python-internal.h, and the
11453 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
11454 from build-gnulib/import/math.h:27,
11455 from d:/usr/Python26/include/pyport.h:235,
11456 from d:/usr/Python26/include/Python.h:58,
11457 from python/python-internal.h:94,
11458 from python/py-arch.c:24:
11459 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
11463 This happens because Python headers define 'hypot' to expand t
11464 '_hypot' in the Windows builds.
11465 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
11466 'hypoth'. This avoids a compilation error.
11468 2018-01-26 Alan Hayward <alan.hayward@arm.com>
11470 * MAINTAINERS (Write After Approval): Fix ordering.
11472 2018-01-26 Alan Hayward <alan.hayward@arm.com>
11474 * MAINTAINERS (Write After Approval): Add Alan Hayward.
11476 2018-01-26 Alan Modra <amodra@gmail.com>
11478 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
11479 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
11480 Remove nop. Make const. Comment.
11481 (powerpc32_plt_stub_so_2): New.
11482 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
11483 Correct count. Update uses.
11484 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
11485 Move common code reading PLT entry word. Correct
11486 powerpc32_plt_stub PLT address calculation.
11487 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
11488 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
11489 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
11490 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
11491 (ppc64_standard_linkage8): Likewise.
11492 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
11493 Correct insns description.
11494 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
11496 2018-01-24 Pedro Alves <palves@redhat.com>
11498 GCC PR libstdc++/83906
11499 * gdbtypes.c (operator==(const dynamic_prop &,
11500 const dynamic_prop &)): New.
11501 (operator==(const range_bounds &, const range_bounds &)): New.
11502 (check_types_equal): Use them instead of memcmp.
11503 * gdbtypes.h (operator==(const dynamic_prop &,
11504 const dynamic_prop &)): Declare.
11505 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
11506 (operator==(const range_bounds &, const range_bounds &)): Declare.
11507 (operator!=(const range_bounds &, const range_bounds &)): Declare.
11509 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11511 * s390-linux-tdep.c (s390_record_address_mask)
11512 (s390_record_calc_disp_common, s390_record_calc_disp)
11513 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
11514 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
11515 (s390_process_record): Move to s390-tdep.c.
11516 (s390_linux_init_abi_any): Adjust.
11517 * s390-tdep.c (s390_record_address_mask)
11518 (s390_record_calc_disp_common, s390_record_calc_disp)
11519 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
11520 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
11521 (s390_process_record): Moved from s390-linux-tdep.c
11522 (s390_gdbarch_init): Adjust.
11524 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11526 * s390-linux-nat.c (s390-tdep.h): New include.
11527 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
11528 (HFILES_NO_SRCDIR): Add s390-tdep.h.
11529 (ALLDEPFILES): Add s390-tdep.c.
11530 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
11531 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
11532 * s390-tdep.h: ...this. New file.
11533 * s390-linux-tdep.c (s390-tdep.h): New include.
11534 (_initialize_s390_tdep): Rename to...
11535 (_initialize_s390_linux_tdep): ...this and adjust.
11536 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
11537 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
11539 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
11540 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
11541 (s390_is_partial_instruction, s390_software_single_step)
11542 (is_non_branch_ril, s390_displaced_step_copy_insn)
11543 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
11544 (s390_prologue_data, s390_addr, s390_store, s390_load)
11545 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
11546 (s390_register_call_saved, s390_guess_tracepoint_registers)
11547 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
11548 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
11549 (s390_pseudo_register_name, s390_pseudo_register_type)
11550 (s390_pseudo_register_read, s390_pseudo_register_write)
11551 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
11552 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
11553 (s390_addr_bits_remove, s390_address_class_type_flags)
11554 (s390_address_class_type_flags_to_name)
11555 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
11556 (s390_function_arg_float, s390_function_arg_vector)
11557 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
11558 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
11559 (s390_frame_align, s390_register_return_value, s390_return_value)
11560 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
11561 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
11562 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
11563 (s390_trad_frame_prev_register, s390_unwind_cache)
11564 (s390_prologue_frame_unwind_cache)
11565 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
11566 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
11567 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
11568 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
11569 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
11570 (s390_frame_base_address, s390_local_base_address)
11571 (s390_frame_base, s390_gcc_target_options)
11572 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
11573 (s390_validate_reg_range, s390_tdesc_valid)
11574 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
11575 * s390-tdep.c: ...this. New file.
11577 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11579 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
11580 (s390_process_record, s390_gdbarch_tdep_alloc)
11581 (s390_linux_init_abi_any): Use/set new hook.
11583 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11585 * s390-linux-tdep.c (osabi.h): New include.
11586 (s390_linux_init_abi_31, s390_linux_init_abi_64)
11587 (s390_linux_init_abi_any): New functions.
11588 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
11590 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11592 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
11593 tdesc_has_registers check
11595 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11597 * s390-linux-tdep.c (s390_tdesc_valid): New function.
11598 (s390_validate_reg_range): New macro.
11599 (s390_gdbarch_init): Adjust.
11601 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11603 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
11604 (s390_gdbarch_tdep_alloc): Adjust.
11605 (s390_gdbarch_init): Adjust.
11607 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11609 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
11610 <have_tdb>: Change type to bool.
11611 (s390_gdbarch_tdep_alloc): Adjust.
11612 (s390_gdbarch_init): Adjust.
11614 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11616 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
11617 (gdbarch_tdep) <have_upper, have_vx>: New fields.
11618 (s390_gdbarch_tdep_alloc): New function.
11619 (s390_gdbarch_init): Allocate tdep at start and use its fields
11620 instead of separate variables.
11622 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11624 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
11625 when looking for cached gdbarch and add comment for remaining.
11627 2018-01-22 Pedro Alves <palves@redhat.com>
11628 Sergio Durigan Junior <sergiodj@redhat.com>
11630 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
11633 2018-01-22 Maciej W. Rozycki <macro@mips.com>
11635 * MAINTAINERS: Update my company e-mail address.
11637 2018-01-22 Yao Qi <yao.qi@linaro.org>
11639 * regcache.c (cooked_write_test): New function.
11640 (_initialize_regcache): Register the test.
11642 2018-01-22 Yao Qi <yao.qi@linaro.org>
11644 * ia64-tdep.c (ia64_pseudo_register_read): Call
11645 regcache->cooked_read instead of regcache_cooked_read_unsigned.
11646 * m32c-tdep.c (m32c_cat_read): Likewise.
11647 (m32c_r3r2r1r0_read): Likewise.
11648 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11649 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11651 2018-01-22 Yao Qi <yao.qi@linaro.org>
11653 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
11654 method raw_read instead of regcache_raw_read.
11655 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11656 * arm-tdep.c (arm_neon_quad_read): Likewise.
11657 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11658 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11659 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11660 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
11661 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11662 (i386_pseudo_register_read_into_value): Likewise.
11663 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11664 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11665 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11666 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
11667 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
11668 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11669 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11670 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11671 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
11673 2018-01-22 Yao Qi <yao.qi@linaro.org>
11675 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
11676 * configure.tgt: Remove target mt.
11677 * mt-tdep.c: Remove.
11678 * regcache.c (cooked_read_test): Remove the check for mt.
11680 2018-01-22 Yao Qi <yao.qi@linaro.org>
11682 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
11683 instead of gdbarch_pseudo_register_read_value.
11685 2018-01-22 Joel Brobecker <brobecker@adacore.com>
11687 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
11690 2018-01-22 Joel Brobecker <brobecker@adacore.com>
11692 * linespec.c (create_sals_line_offset): Remove code that preserved
11693 the symtab_and_line's line number.
11695 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11697 * varobj.c (varobj_create): Don't set valid_block when creating a
11700 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11702 * varobj.c (varobj_create): Remove out of date comment.
11704 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11707 * ada-exp.y (write_var_from_sym): Pass extra parameter when
11708 updating innermost block.
11709 * parse.c (innermost_block_tracker::update): Take extra type
11710 parameter, and check types match before updating innermost block.
11711 (write_dollar_variable): Update innermost block for registers.
11712 * parser-defs.h (enum innermost_block_tracker_type): New enum.
11713 (innermost_block_tracker::innermost_block_tracker): Initialise
11715 (innermost_block_tracker::reset): Take type parameter.
11716 (innermost_block_tracker::update): Take type parameter, and pass
11717 type through as needed.
11718 (innermost_block_tracker::m_types): New member.
11719 * varobj.c (varobj_create): Pass type when reseting innermost
11722 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11724 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
11725 * ada-lang.c (resolve_subexp): Likewise.
11726 * breakpoint.c (set_breakpoint_condition) Likewise.
11727 (watch_command_1) Likewise.
11728 * c-exp.y (variable): Likewise.
11729 * d-exp.y (PrimaryExpression): Likewise.
11730 * f-exp.y (variable): Likewise.
11731 * go-exp.y (variable): Likewise.
11732 * m2-exp.y (variable): Likewise.
11733 * objfiles.c (objfile::~objfile): Likewise.
11734 * p-exp.y (variable): Likewise.
11735 * parse.c (innermost_block): Change type.
11736 * parser-defs.h (class innermost_block_tracker): New.
11737 (innermost_block): Change to innermost_block_tracker.
11738 * printcmd.c (display_command): Switch to innermost_block API.
11739 (do_one_display): Likewise.
11740 * rust-exp.y (do_one_display): Likewise.
11741 * symfile.c (clear_symtab_users): Likewise.
11742 * varobj.c (varobj_create): Switch to innermost_block API, replace
11743 use of innermost_block with block stored on varobj object.
11745 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
11747 * expression.h (innermost_block): Remove declaration.
11748 * varobj.c: Add 'parser-defs.h' include.
11750 2018-01-19 Tom Tromey <tom@tromey.com>
11752 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
11753 symbols in the static and global blocks.
11755 2018-01-19 James Clarke <jrtc27@jrtc27.com>
11757 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
11758 gdb_ptrace.h, and move including gdb_wait.h ...
11759 * nat/linux-ptrace.h: ... to here.
11761 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11763 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
11764 inf_ptrace_detach_success.
11765 (inf_ptrace_detach_success): Add inferior parameter, use it
11766 instead of inferior_ptid, pass it to detach_inferior.
11767 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
11769 * inferior.c (detach_inferior): Add overload that takes an
11771 * inferior.h (detach_inferior): Likewise.
11772 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
11773 use inferior_ptid, adjust call to inf_ptrace_detach_success.
11774 * linux-thread-db.c (thread_db_detach): Use inf parameter.
11776 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11778 * target.h (struct target_ops) <to_detach>: Add inferior
11780 (target_detach): Likewise.
11781 * target.c (dispose_inferior): Pass inferior down.
11782 (target_detach): Pass inferior down. Assert that it is equal to
11783 the current inferior.
11784 * aix-thread.c (aix_thread_detach): Pass inferior down.
11785 * corefile.c (core_file_command): Pass current_inferior() down.
11786 * corelow.c (core_detach): Add inferior parameter.
11787 * darwin-nat.c (darwin_detach): Likewise.
11788 * gnu-nat.c (gnu_detach): Likewise.
11789 * inf-ptrace.c (inf_ptrace_detach): Likewise.
11790 * infcmd.c (detach_command): Pass current_inferior() down to
11792 * infrun.c (follow_fork_inferior): Pass parent_inf to
11794 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
11796 * linux-nat.c (linux_nat_detach): Add inferior parameter.
11797 * linux-thread-db.c (thread_db_detach): Likewise.
11798 * nto-procfs.c (procfs_detach): Likewise.
11799 * procfs.c (procfs_detach): Likewise.
11800 * record.c (record_detach): Likewise.
11801 * record.h (struct inferior): Forward-declare.
11802 (record_detach): Add inferior parameter.
11803 * remote-sim.c (gdbsim_detach): Likewise.
11804 * remote.c (remote_detach_1): Likewise.
11805 (remote_detach): Likewise.
11806 (extended_remote_detach): Likewise.
11807 * sol-thread.c (sol_thread_detach): Likewise.
11808 * target-debug.h (target_debug_print_inferior_p): New macro.
11809 * target-delegates.c: Re-generate.
11810 * top.c (kill_or_detach): Pass inferior down to target_detach.
11811 * windows-nat.c (windows_detach): Add inferior parameter.
11813 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
11815 * target.h (struct target_ops) <to_detach>: Remove args
11817 (target_detach): Likewise.
11818 * target.c (dispose_inferior): Adjust.
11819 (target_detach): Remove args parameter, adjust.
11820 * aix-thread.c (aix_thread_detach): Adjust.
11821 * corefile.c (core_file_command): Adjust.
11822 * corelow.c (core_detach): Adjust.
11823 * darwin-nat.c (darwin_detach): Adjust.
11824 * gnu-nat.c (gnu_detach): Adjust.
11825 * inf-ptrace.c (inf_ptrace_detach): Adjust.
11826 * infcmd.c (detach_command): Adjust
11827 * infrun.c (follow_fork_inferior): Adjust.
11828 (handle_vfork_child_exec_or_exit): Adjust.
11829 * linux-fork.c (linux_fork_detach): Remove args parameter.
11830 * linux-fork.h (linux_fork_detach): Likewise.
11831 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
11832 * linux-thread-db.c (thread_db_detach): Likewise.
11833 * nto-procfs.c (procfs_detach): Likewise.
11834 * procfs.c (procfs_detach): Likewise.
11835 (do_detach): Remove signo parameter.
11836 * record.c (record_detach): Remove args parameter.
11837 * record.h (record_detach): Likewise.
11838 * remote-sim.c (gdbsim_detach): Likewise.
11839 * remote.c (remote_detach_1): Likewise.
11840 (remote_detach): Likewise.
11841 (extended_remote_detach): Likewise.
11842 * sol-thread.c (sol_thread_detach): Likewise.
11843 * target-delegates.c: Re-generate.
11844 * top.c (struct qt_args) <args>: Remove field.
11845 (kill_or_detach): Don't pass args.
11846 (quit_force): Don't set args.
11847 * windows-nat.c (windows_detach): Remove args parameter.
11849 2018-01-19 Yao Qi <yao.qi@linaro.org>
11851 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
11852 (arm_linux_init_abi): Install it.
11854 2018-01-19 Yao Qi <yao.qi@linaro.org>
11856 * osabi.c (gdb_osabi_names): Extend the regexp for
11857 arm-linux-gnueabihf.
11859 2018-01-18 Yao Qi <yao.qi@linaro.org>
11861 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
11863 (abbrev_table::add_abbrev): Update.
11864 (abbrev_table::lookup_abbrev): Update.
11866 2018-01-18 Yao Qi <yao.qi@linaro.org>
11868 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
11870 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
11872 * compile/compile.c (compile_to_object): Convert "triplet_rx"
11875 2018-01-17 Tom Tromey <tom@tromey.com>
11877 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
11879 2018-01-17 Tom Tromey <tom@tromey.com>
11881 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
11882 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
11883 (create_array_type_with_stride): Update.
11884 * dwarf2read.c (set_die_type): Update.
11886 2018-01-17 Tom Tromey <tom@tromey.com>
11888 * dwarf2read.c (delayed_method_info): Remove typedef.
11889 (dwarf2_cu::method_info): Now a std::vector.
11890 (add_to_method_list): Update.
11891 (free_delayed_list): Remove.
11892 (compute_delayed_physnames): Update.
11893 (process_full_comp_unit, process_full_type_unit): Clear the method
11894 list. Remove cleanups.
11895 (psymtab_include_file_name): Add name_holder parameter. Use
11896 unique_xmalloc_ptr.
11897 (dwarf_decode_lines): Update.
11899 2018-01-17 Tom Tromey <tom@tromey.com>
11900 Simon Marchi <simon.marchi@ericsson.com>
11902 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
11903 (dwarf2_per_objfile::free_cached_comp_units)
11904 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11905 (init_cutu_and_read_dies_no_follow): Update.
11906 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
11907 (dwarf2_cu::~dwarf2_cu): New.
11908 (free_heap_comp_unit, free_stack_comp_unit): Remove.
11909 (age_cached_comp_units, free_one_cached_comp_unit): Update.
11911 2018-01-17 Tom Tromey <tom@tromey.com>
11912 Simon Marchi <simon.marchi@ericsson.com>
11914 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
11915 (struct die_reader_specs) <abbrev_table>: New member.
11916 (struct abbrev_table): Add constructor.
11917 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
11918 <abbrev_obstack>: Now an auto_obstack.
11919 (abbrev_table_up): New typedef.
11920 (init_cu_die_reader): Add abbrev_table parameter.
11921 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
11922 Add result_dwo_abbrev_table.
11923 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
11924 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
11926 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
11928 (skip_children): Update.
11929 (abbrev_table::alloc_abbrev): Rename from
11930 abbrev_table_alloc_abbrev.
11931 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
11932 (abbrev_table::lookup_abbrev): Rename from
11933 abbrev_table_lookup_abbrev.
11934 (abbrev_table_read_table): Return abbrev_table_up.
11935 (abbrev_table_free, abbrev_table_free_cleanup)
11936 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
11937 (load_partial_dies): Update.
11939 2018-01-17 Tom Tromey <tom@tromey.com>
11941 * dwarf2read.c (dwarf2_compute_name): Update comment.
11942 (read_func_scope, read_variable): Update.
11943 (new_symbol): Remove.
11944 (new_symbol_full): Rename to new_symbol.
11946 2018-01-17 Mike Gulick <mgulick@mathworks.com>
11949 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
11950 a warning instead of throwing an error, set section size to 0 and return
11952 * gdb_bfd.h (gdb_bfd_map_section): Update description.
11954 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11956 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
11958 (linux_ptrace_attach_fail_reason_string): Likewise.
11959 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
11961 (linux_ptrace_attach_fail_reason_string): Likewise.
11962 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
11964 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
11966 * linux-nat.c (linux_nat_attach): Remove xstrdup.
11968 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
11971 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
11972 checking for fs_base/gs_base fields in struct user_regs_struct.
11973 * configure: Regenerate.
11975 2018-01-17 Yao Qi <yao.qi@linaro.org>
11977 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
11979 (aarch64_linux_init_abi): Install it to gdbarch hook
11980 gcc_target_options.
11982 2018-01-15 Pedro Alves <palves@redhat.com>
11984 * common/signals-state-save-restore.c
11985 (save_original_signals_state): Fix typos.
11987 2017-01-12 Tom Tromey <tom@tromey.com>
11988 Sergio Durigan Junior <sergiodj@redhat.com>
11990 * Makefile.in (install-only): Install gdb-add-index.
11992 2018-01-12 John Baldwin <jhb@FreeBSD.org>
11994 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
11996 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
11998 * infrun.c (keep_going_pass_signal): Clear step-over info when
11999 insert_breakpoints fails.
12001 2018-01-11 Pedro Alves <palves@redhat.com>
12004 * infrun.c (resume): Rename to ...
12005 (resume_1): ... this.
12006 (resume): Reimplement as wrapper around resume_1.
12008 2018-01-11 Pedro Alves <palves@redhat.com>
12011 * remote.c (remote_parse_stop_reply): Default to the last-set
12012 general thread instead of to 'magic_null_ptid'.
12014 2018-01-10 Pedro Alves <palves@redhat.com>
12016 * language.h (language_get_symbol_name_matcher): Rename ...
12017 (get_symbol_name_matcher): ... this.
12018 * language.c (language_get_symbol_name_matcher): Ditto.
12019 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12022 2018-01-10 Pedro Alves <palves@redhat.com>
12026 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12027 Adjust to use language_get_symbol_name_matcher instead of
12028 language_defn::la_get_symbol_name_matcher.
12029 * language.c (language_get_symbol_name_matcher): If in Ada mode
12030 and the lookup name is a verbatim match, return Ada's matcher.
12031 * language.h (language_get_symbol_name_matcher): Adjust comment.
12032 (ada_lookup_name_info::verbatim_p):: New method.
12034 2018-01-10 Pedro Alves <palves@redhat.com>
12037 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12038 minsym's language is language_auto or language_cplus, pass down
12039 language_ada instead.
12040 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12042 2018-01-10 Pedro Alves <palves@redhat.com>
12045 * minsyms.c (linkage_name_str): New function.
12046 (iterate_over_minimal_symbols): Use it.
12048 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12050 * NEWS: Document that 'info proc' now works on FreeBSD.
12052 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12054 * configure.ac: Check for kinfo_getfile in libutil.
12055 * configure: Regenerate.
12056 * config.in: Regenerate.
12057 * fbsd-nat.c: Include "fbsd-tdep.h".
12058 (fbsd_fetch_cmdline): New.
12059 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12060 rather than calling error.
12061 (fbsd_info_proc): New.
12062 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12063 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12064 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
12066 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12068 * fbsd-nat.c (struct free_deleter): Remove.
12069 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
12071 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12073 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
12074 NULL for an empty pathname.
12076 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12078 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
12079 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
12080 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
12081 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
12082 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
12083 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
12084 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
12085 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
12086 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
12087 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
12088 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
12089 (fbsd_core_fetch_timeval, fbsd_print_sigset)
12090 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
12091 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
12092 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
12094 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
12096 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
12097 (gnu_xfer_auxv): New function.
12098 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
12099 TARGET_OBJECT_AUXV.
12101 2018-01-08 Yao Qi <yao.qi@linaro.org>
12102 Simon Marchi <simon.marchi@ericsson.com>
12104 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
12106 (COMMON_OBS): Remove selftest.o.
12107 * configure.ac: Append selftest-arch.c and common/selftest.c to
12108 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
12109 * configure: Re-generated.
12110 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
12112 (maintenance_info_selftests): Likewise.
12114 2018-01-08 Xavier Roirand <roirand@adacore.com>
12116 * ada-valprint.c (val_print_packed_array_elements): Use
12117 proper number of elements when printing an array indexed
12118 by an enumeration type.
12120 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12122 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
12123 (dw2_get_file_names_reader): Adjust.
12124 (lookup_dwo_signatured_type): Adjust.
12125 (lookup_dwp_signatured_type): Adjust.
12126 (lookup_signatured_type): Adjust.
12127 (create_type_unit_group): Adjust.
12128 (get_type_unit_group): Adjust.
12129 (process_psymtab_comp_unit_reader): Adjust.
12130 (build_type_psymtabs_reader): Adjust.
12131 (scan_partial_symbols): Adjust.
12132 (add_partial_symbol): Adjust.
12133 (add_partial_subprogram): Adjust.
12134 (peek_die_abbrev): Adjust.
12135 (fixup_go_packaging): Adjust.
12136 (process_imported_unit_die): Adjust.
12137 (dwarf2_compute_name): Adjust.
12138 (dwarf2_physname): Adjust.
12139 (read_import_statement): Adjust.
12140 (handle_DW_AT_stmt_list): Adjust.
12141 (read_file_scope): Adjust.
12142 (read_func_scope): Adjust.
12143 (read_lexical_block_scope): Adjust.
12144 (read_call_site_scope): Adjust.
12145 (read_variable): Adjust.
12146 (dwarf2_rnglists_process): Adjust.
12147 (dwarf2_ranges_process): Adjust.
12148 (dwarf2_ranges_read): Adjust.
12149 (dwarf2_get_pc_bounds): Adjust.
12150 (dwarf2_record_block_ranges): Adjust.
12151 (dwarf2_add_field): Adjust.
12152 (dwarf2_add_member_fn): Adjust.
12153 (read_structure_type): Adjust.
12154 (process_structure_scope): Adjust.
12155 (read_enumeration_type): Adjust.
12156 (read_array_type): Adjust.
12157 (mark_common_block_symbol_computed): Adjust.
12158 (read_common_block): Adjust.
12159 (read_namespace_type): Adjust.
12160 (read_namespace): Adjust.
12161 (read_module_type): Adjust.
12162 (read_tag_pointer_type): Adjust.
12163 (read_tag_ptr_to_member_type): Adjust.
12164 (read_tag_string_type): Adjust.
12165 (read_subroutine_type): Adjust.
12166 (read_typedef): Adjust.
12167 (read_base_type): Adjust.
12168 (attr_to_dynamic_prop): Adjust.
12169 (read_subrange_type): Adjust.
12170 (read_unspecified_type): Adjust.
12171 (dwarf2_read_abbrevs): Adjust.
12172 (load_partial_dies): Adjust.
12173 (read_partial_die): Adjust.
12174 (find_partial_die): Adjust.
12175 (guess_partial_die_structure_name): Adjust.
12176 (fixup_partial_die): Adjust.
12177 (read_attribute_value): Adjust.
12178 (read_addr_index): Adjust.
12179 (read_addr_index_from_leb128): Adjust.
12180 (read_str_index): Adjust.
12181 (dwarf2_string_attr): Adjust.
12182 (get_debug_line_section): Adjust.
12183 (dwarf_decode_line_header): Adjust.
12184 (lnp_state_machine::check_line_address): Adjust.
12185 (dwarf_decode_lines_1): Adjust.
12186 (dwarf_decode_lines): Adjust.
12187 (dwarf2_start_symtab): Adjust.
12188 (var_decode_location): Adjust.
12189 (new_symbol_full): Adjust.
12190 (dwarf2_const_value_data): Adjust.
12191 (dwarf2_const_value_attr): Adjust.
12192 (dwarf2_const_value): Adjust.
12193 (die_type): Adjust.
12194 (die_containing_type): Adjust.
12195 (build_error_marker_type): Adjust.
12196 (lookup_die_type): Adjust.
12197 (guess_full_die_structure_name): Adjust.
12198 (anonymous_struct_prefix): Adjust.
12199 (determine_prefix): Adjust.
12200 (dwarf2_name): Adjust.
12201 (follow_die_ref_or_sig): Adjust.
12202 (follow_die_offset): Adjust.
12203 (follow_die_ref): Adjust.
12204 (follow_die_sig_1): Adjust.
12205 (follow_die_sig): Adjust.
12206 (get_signatured_type): Adjust.
12207 (get_DW_AT_signature_type): Adjust.
12208 (decode_locdesc): Adjust.
12209 (dwarf_decode_macros): Adjust.
12210 (cu_debug_loc_section): Adjust.
12211 (fill_in_loclist_baton): Adjust.
12212 (dwarf2_symbol_mark_computed): Adjust.
12213 (init_one_comp_unit): Don't assign
12214 dwarf2_cu::dwarf2_per_objfile.
12215 (set_die_type): Adjust.
12217 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12219 * dwarf2read.c (struct mapped_debug_names): Add constructor.
12220 <dwarf2_per_objfile>: New field.
12221 (dwarf2_per_objfile): Remove global.
12222 (get_dwarf2_per_objfile): New function.
12223 (set_dwarf2_per_objfile): New function.
12224 (dwarf2_build_psymtabs_hard): Change objfile parameter to
12225 dwarf2_per_objfile.
12226 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12227 (read_abbrev_offset): Likewise.
12228 (read_indirect_string): Likewise.
12229 (read_indirect_line_string): Likewise.
12230 (read_indirect_string_at_offset): Likewise.
12231 (read_indirect_string_from_dwz): Likewise.
12232 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12233 dwarf2_per_objfile.
12234 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12235 (create_all_comp_units): Change objfile parameter to
12236 dwarf2_per_objfile.
12237 (create_all_type_units): Likewise.
12238 (process_queue): Add dwarf2_per_objfile parameter.
12239 (read_and_check_comp_unit_head): Likewise.
12240 (lookup_dwo_unit_in_dwp): Likewise.
12241 (get_dwp_file): Likewise.
12242 (process_cu_includes): Likewise.
12243 (struct free_dwo_file_cleanup_data): New struct.
12244 (dwarf2_has_info): Use get_dwarf2_per_objfile and
12245 set_dwarf2_per_objfile.
12246 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
12247 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
12248 context, adjust calls.
12249 (dw2_instantiate_symtab): Likewise.
12250 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
12251 (dw2_get_cu): Likewise.
12252 (create_cu_from_index_list): Change objfile parameter to
12253 dwarf2_per_objfile.
12254 (create_cus_from_index_list): Get dwarf2_per_objfile from
12255 context, adjust calls.
12256 (create_cus_from_index): Likewise.
12257 (create_signatured_type_table_from_index): Change objfile
12258 parameter to dwarf2_per_objfile.
12259 (create_signatured_type_table_from_debug_names): Change objfile
12260 parameter to dwarf2_per_objfile.
12261 (create_addrmap_from_index): Likewise.
12262 (create_addrmap_from_aranges): Likewise.
12263 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
12264 (dw2_setup): Remove.
12265 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
12267 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
12268 get_dwarf2_per_objfile.
12269 (dw2_forget_cached_source_info): Likewise.
12270 (dw2_map_symtabs_matching_filename): Likewise.
12271 (struct dw2_symtab_iterator) <index>: Remove.
12272 <dwarf2_per_objfile>: New field.
12273 (dw2_symtab_iter_init): Replace index parameter with
12274 dwarf2_per_objfile.
12275 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
12276 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
12277 (dw2_print_stats): Likewise.
12278 (dw2_dump): Likewise.
12279 (dw2_expand_symtabs_for_function): Likewise.
12280 (dw2_expand_all_symtabs): Likewise.
12281 (dw2_expand_symtabs_with_fullname): Likewise.
12282 (dw2_expand_marked_cus): Replace index and objfile parameters
12283 with dwarf2_per_objfile.
12284 (dw_expand_symtabs_matching_file_matcher): Add
12285 dwarf2_per_objfile parameter and adjust calls.
12286 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
12288 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
12289 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
12291 (create_cus_from_debug_names_list): Replace objfile parameter
12292 with dwarf2_per_objfile and adjust calls.
12293 (create_cus_from_debug_names): Likewise.
12294 (dwarf2_read_debug_names): Likewise.
12295 (mapped_debug_names::namei_to_name): Adjust call.
12296 (dw2_debug_names_iterator::next): Likewise.
12297 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
12298 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
12299 (dw2_debug_names_dump): Likewise.
12300 (dw2_debug_names_expand_symtabs_for_function): Likewise.
12301 (dw2_debug_names_expand_symtabs_matching): Likewise.
12302 (dwarf2_initialize_objfile): Likewise.
12303 (dwarf2_build_psymtabs): Likewise.
12304 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
12306 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
12307 (read_and_check_comp_unit_head): Likewise.
12308 (read_abbrev_offset): Likewise.
12309 (create_debug_type_hash_table): Likewise.
12310 (create_debug_types_hash_table): Likewise.
12311 (create_all_type_units): Replace objfile parameter with
12312 dwarf2_per_objfile.
12313 (add_type_unit): Add dwarf2_per_objfile parameter.
12314 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
12315 with dwarf2_per_objfile.
12316 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
12317 (lookup_dwp_signatured_type): Likewise.
12318 (lookup_signatured_type): Likewise.
12319 (read_cutu_die_from_dwo): Likewise.
12320 (init_tu_and_read_dwo_dies): Likewise.
12321 (init_cutu_and_read_dies): Likewise.
12322 (init_cutu_and_read_dies_no_follow): Likewise.
12323 (allocate_type_unit_groups_table): Add objfile parameter.
12324 (create_type_unit_group): Use dwarf2_per_objfile from cu.
12325 (get_type_unit_group): Likewise.
12326 (process_psymtab_comp_unit): Update call.
12327 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
12328 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
12329 (print_tu_stats): Likewise.
12330 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
12331 in void* parameter.
12332 (build_type_psymtabs): Change objfile parameter to
12333 dwarf2_per_objfile.
12334 (process_skeletonless_type_unit): Use dwarf2_per_objfile
12335 passed in void* parameter.
12336 (process_skeletonless_type_units): Change objfile parameter to
12337 dwarf2_per_objfile.
12338 (set_partial_user): Likewise.
12339 (dwarf2_build_psymtabs_hard): Likewise.
12340 (read_comp_units_from_section): Likewise.
12341 (create_all_comp_units): Likewise.
12342 (scan_partial_symbols): Update calls.
12343 (add_partial_symbol): Likewise.
12344 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
12345 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
12346 (process_queue): Add dwarf2_per_objfile parameter.
12347 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
12348 (compute_compunit_symtab_includes): Likewise.
12349 (process_cu_includes): Add dwarf2_per_objfile parameter.
12350 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
12351 (process_full_type_unit): Likewise.
12352 (process_imported_unit_die): Update call.
12353 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
12354 (read_file_scope): Likewise.
12355 (allocate_dwo_file_hash_table): Add objfile parameter.
12356 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
12357 (create_cus_hash_table): Likewise.
12358 (create_dwp_hash_table): Likewise.
12359 (create_dwo_unit_in_dwp_v1): Likewise.
12360 (create_dwp_v2_section): Likewise.
12361 (create_dwo_unit_in_dwp_v2): Likewise.
12362 (lookup_dwo_unit_in_dwp): Likewise.
12363 (try_open_dwop_file): Likewise.
12364 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
12365 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
12366 cleanup to include a reference to dwarf2_per_objfile.
12367 (open_dwp_file): Add dwarf2_per_objfile parameter.
12368 (open_and_init_dwp_file): Likewise.
12369 (get_dwp_file): Likewise.
12370 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
12371 (queue_and_load_all_dwo_tus): Update call.
12372 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
12374 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
12375 (dwarf2_ranges_process): Likewise.
12376 (dwarf2_get_pc_bounds): Likewise.
12377 (mark_common_block_symbol_computed): Likewise.
12378 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
12379 (dwarf2_read_abbrevs): Update call.
12380 (read_partial_die): Use dwarf2_per_objfile from cu.
12381 (find_partial_die): Likewise.
12382 (fixup_partial_die): Likewise.
12383 (read_attribute_value): Likewise.
12384 (read_indirect_string_at_offset_from): Add objfile parameter.
12385 (read_indirect_string_at_offset): Add dwarf2_per_objfile
12387 (read_indirect_string_from_dwz): Add objfile parameter.
12388 (read_indirect_string): Add objfile parameter.
12389 (read_addr_index_1): Add dwarf2_per_objfile parameter.
12390 (read_addr_index): Use dwarf2_per_objfile from cu.
12391 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
12393 (read_str_index): Use dwarf2_per_objfile from cu.
12394 (get_debug_line_section): Likewise.
12395 (read_formatted_entries): Add dwarf2_per_objfile parameter.
12396 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
12397 (new_symbol_full): Use dwarf2_per_objfile from cu.
12398 (build_error_marker_type): Likewise.
12399 (lookup_die_type): Likewise.
12400 (determine_prefix): Likewise.
12401 (follow_die_offset): Likewise.
12402 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
12403 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
12404 (dwarf2_fetch_die_type_sect_off): Likewise.
12405 (dwarf2_get_die_type): Likewise.
12406 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
12407 (get_signatured_type): Likewise.
12408 (get_DW_AT_signature_type): Likewise.
12409 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
12410 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
12411 (cu_debug_loc_section): Likewise.
12412 (fill_in_loclist_baton): Likewise.
12413 (dwarf2_symbol_mark_computed): Likewise.
12414 (dwarf2_find_containing_comp_unit): Change objfile parameter to
12415 dwarf2_per_objfile.
12416 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
12418 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
12419 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
12420 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
12421 (set_die_type): Use dwarf2_free_objfile from cu.
12422 (get_die_type_at_offset): Likewise.
12423 (dwarf2_per_objfile_free): Don't assign global variable.
12424 (debug_names) <constructor>: Add dwarf2_per_objfile
12425 parameter, update m_debugstrlookup construction.
12426 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
12428 <m_dwarf2_per_objfile>: New field.
12429 <lookup>: Use m_dwarf2_per_objfile.
12430 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
12431 (psyms_seen_size): Likewise.
12432 (write_gdbindex): Replace objfile parameter with
12433 dwarf2_per_objfile.
12434 (write_debug_names): Likewise.
12435 (write_psymtabs_to_index): Likewise.
12436 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
12439 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12441 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
12442 <dwarf2_per_objfile>: New field.
12443 (struct dwarf2_per_cu_data) <objfile>: Remove.
12444 <dwarf2_per_objfile>: New field.
12445 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
12447 (create_signatured_type_table_from_index): Likewise.
12448 (create_debug_type_hash_table): Likewise.
12449 (fill_in_sig_entry_from_dwo_entry): Likewise.
12450 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
12451 (create_type_unit_group): Assign dwarf2_per_objfile instead of
12453 (create_partial_symtab): Access objfile through
12454 dwarf2_per_objfile.
12455 (process_psymtab_comp_unit_reader): Likewise.
12456 (read_comp_units_from_section): Likewise.
12457 (scan_partial_symbols): Likewise.
12458 (add_partial_symbol): Likewise.
12459 (add_partial_subprogram): Likewise.
12460 (peek_die_abbrev): Likewise.
12461 (fixup_go_packaging): Likewise.
12462 (process_full_comp_unit): Likewise.
12463 (process_full_type_unit): Likewise.
12464 (process_imported_unit_die): Likewise.
12465 (dwarf2_compute_name): Likewise.
12466 (dwarf2_physname): Likewise.
12467 (read_import_statement): Likewise.
12468 (create_cus_hash_table): Assign dwarf2_physname instead of
12470 (read_func_scope): Access objfile through dwarf2_per_objfile.
12471 (read_lexical_block_scope): Likewise.
12472 (read_call_site_scope): Likewise.
12473 (read_variable): Likewise.
12474 (dwarf2_rnglists_process): Likewise.
12475 (dwarf2_ranges_process): Likewise.
12476 (dwarf2_ranges_read): Likewise.
12477 (dwarf2_record_block_ranges): Likewise.
12478 (dwarf2_add_field): Likewise.
12479 (dwarf2_add_member_fn): Likewise.
12480 (read_structure_type): Likewise.
12481 (process_structure_scope): Likewise.
12482 (read_enumeration_type): Likewise.
12483 (read_array_type): Likewise.
12484 (read_common_block): Likewise.
12485 (read_namespace_type): Likewise.
12486 (read_namespace): Likewise.
12487 (read_module_type): Likewise.
12488 (read_tag_pointer_type): Likewise.
12489 (read_tag_ptr_to_member_type): Likewise.
12490 (read_tag_string_type): Likewise.
12491 (read_subroutine_type): Likewise.
12492 (read_typedef): Likewise.
12493 (read_base_type): Likewise.
12494 (attr_to_dynamic_prop): Likewise.
12495 (read_subrange_type): Likewise.
12496 (read_unspecified_type): Likewise.
12497 (load_partial_dies): Likewise.
12498 (read_partial_die): Likewise.
12499 (find_partial_die): Likewise.
12500 (guess_partial_die_structure_name): Likewise.
12501 (fixup_partial_die): Likewise.
12502 (read_attribute_value): Likewise.
12503 (read_addr_index_from_leb128): Likewise.
12504 (dwarf2_read_addr_index): Likewise.
12505 (dwarf2_string_attr): Likewise.
12506 (lnp_state_machine::check_line_address): Likewise.
12507 (dwarf_decode_lines_1): Likewise.
12508 (dwarf_decode_lines): Likewise.
12509 (dwarf2_start_symtab): Likewise.
12510 (var_decode_location): Likewise.
12511 (new_symbol_full): Likewise.
12512 (dwarf2_const_value_data): Likewise.
12513 (dwarf2_const_value_attr): Likewise.
12514 (dwarf2_const_value): Likewise.
12515 (die_type): Likewise.
12516 (die_containing_type): Likewise.
12517 (lookup_die_type): Likewise.
12518 (guess_full_die_structure_name): Likewise.
12519 (anonymous_struct_prefix): Likewise.
12520 (dwarf2_name): Likewise.
12521 (follow_die_ref_or_sig): Likewise.
12522 (follow_die_offset): Likewise.
12523 (follow_die_ref): Likewise.
12524 (dwarf2_fetch_die_loc_sect_off): Likewise.
12525 (dwarf2_fetch_constant_bytes): Likewise.
12526 (dwarf2_fetch_die_type_sect_off): Likewise.
12527 (dwarf2_get_die_type): Likewise.
12528 (follow_die_sig): Likewise.
12529 (decode_locdesc): Likewise.
12530 (dwarf2_per_cu_objfile): Likewise.
12531 (dwarf2_per_cu_text_offset): Likewise.
12532 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
12534 (set_die_type): Access objfile through
12535 dwarf2_per_objfile.
12537 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
12539 * valprint.c (converted_character_d): Remove typedef.
12540 (DEF_VEC_O (converted_character_d)): Remove.
12541 (count_next_character): Use std::vector.
12542 (print_converted_chars_to_obstack): Likewise.
12543 (generic_printstr): Likewise.
12545 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12547 * xml-support.h (struct gdb_xml_value): Add constructor.
12548 <value>: Change type to unique_xmalloc_ptr.
12549 (gdb_xml_value_s): Remove typedef.
12550 (DEF_VEC_O (gdb_xml_value_s)): Remove.
12551 (gdb_xml_element_start_handler): Change parameter type to
12553 (xml_find_attribute): Likewise.
12554 * xml-support.c (xml_find_attribute): Change parameter type to
12555 std::vector and adjust.
12556 (gdb_xml_values_cleanup): Remove.
12557 (gdb_xml_parser::start_element): Adjust to std::vector.
12558 (xinclude_start_include): Change paraeter type to std::vector
12560 * btrace.c (check_xml_btrace_version): Likewise.
12561 (parse_xml_btrace_block): Likewise.
12562 (parse_xml_btrace_pt_config_cpu): Likewise.
12563 (parse_xml_btrace_pt): Likewise.
12564 (parse_xml_btrace_conf_bts): Likewise.
12565 (parse_xml_btrace_conf_pt): Likewise.
12566 * memory-map.c (memory_map_start_memory): Likewise.
12567 (memory_map_start_property): Likewise.
12568 * osdata.c (osdata_start_osdata): Likewise.
12569 (osdata_start_item): Likewise.
12570 (osdata_start_column): Likewise.
12571 * remote.c (start_thread): Likewise.
12572 * solib-aix.c (library_list_start_library): Likewise.
12573 (library_list_start_list): Likewise.
12574 * solib-svr4.c (library_list_start_library): Likewise.
12575 (svr4_library_list_start_list): Likewise.
12576 * solib-target.c (library_list_start_segment): Likewise.
12577 (library_list_start_section): Likewise.
12578 (library_list_start_library): Likewise.
12579 (library_list_start_list): Likewise.
12580 * tracepoint.c (traceframe_info_start_memory): Likewise.
12581 (traceframe_info_start_tvar): Likewise.
12582 * xml-syscall.c (syscall_start_syscall): Likewise.
12583 * xml-tdesc.c (tdesc_start_target): Likewise.
12584 (tdesc_start_feature): Likewise.
12585 (tdesc_start_reg): Likewise.
12586 (tdesc_start_union): Likewise.
12587 (tdesc_start_struct): Likewise.
12588 (tdesc_start_flags): Likewise.
12589 (tdesc_start_enum): Likewise.
12590 (tdesc_start_field): Likewise.
12591 (tdesc_start_enum_value): Likewise.
12592 (tdesc_start_vector): Likewise.
12594 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12596 * extension.h (struct xmethod_worker) <clone>: Remove.
12597 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
12599 (python_xmethod_worker::clone): Remove.
12600 * valops.c (find_overload_match): Use std::move instead of
12603 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
12605 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
12606 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
12607 <free_xmethod_worker_data>: Remove.
12608 <get_matching_xmethod_workers>: Chance VEC to std::vector.
12609 <get_xmethod_arg_types>: Remove.
12610 <get_xmethod_result_type>: Remove.
12611 <invoke_xmethod>: Remove.
12612 * extension.c (new_xmethod_worker): Remove.
12613 (clone_xmethod_worker): Remove.
12614 (get_matching_xmethod_workers): Return void, pass std::vector by
12616 (get_xmethod_arg_types): Rename to...
12617 (xmethod_worker::get_arg_types): ... this, and adjust.
12618 (get_xmethod_result_type): Rename to...
12619 (xmethod_worker::get_result_type): ... this, and adjust.
12620 (invoke_xmethod): Remove.
12621 (free_xmethod_worker): Remove.
12622 (free_xmethod_worker_vec): Remove.
12623 * extension.h (enum ext_lang_rc): Move here from
12625 (struct xmethod_worker): Add constructor and destructor.
12628 <invoke, clone, do_get_result_type, do_get_arg_types>: New
12629 virtual pure methods.
12630 <get_arg_types, get_result_type>: New methods.
12631 (xmethod_worker_ptr): Remove typedef.
12632 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
12633 (xmethod_worker_vec): Remove typedef.
12634 (xmethod_worker_up): New typedef.
12635 (invoke_xmethod): Remove.
12636 (clone_xmethod_worker): Remove.
12637 (free_xmethod_worker): Remove.
12638 (free_xmethod_worker_vec): Remove.
12639 (get_xmethod_arg_types): Remove.
12640 (get_xmethod_result_type): Remove.
12641 * valops.c (find_method_list): Use std::vector, don't use
12642 intermediate vector.
12643 (value_find_oload_method_list): Use std::vector.
12644 (find_overload_match): Use std::vector.
12645 (find_oload_champ): Use std::vector.
12646 * value.c (value_free): Use operator delete.
12647 (value_of_xmethod): Rename to...
12648 (value_from_xmethod): ... this. Don't assign
12649 xmethod_worker::value, take rvalue-reference.
12650 (result_type_of_xmethod): Adjust.
12651 (call_xmethod): Adjust.
12652 * value.h: Include extension.h.
12653 (struct xmethod_worker): Don't forward-declare.
12654 (value_of_xmethod): Rename to...
12655 (value_from_xmethod): ... this, take rvalue-reference.
12656 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
12657 (struct python_xmethod_worker): ... this, add constructor and
12659 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
12660 (gdbpy_free_xmethod_worker_data): Rename to...
12661 (python_xmethod_worker::~python_xmethod_worker): ... this and
12663 (gdbpy_clone_xmethod_worker_data): Rename to...
12664 (python_xmethod_worker::clone): ... this and adjust.
12665 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
12667 (gdbpy_get_xmethod_arg_types): Rename to...
12668 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
12669 (gdbpy_get_xmethod_result_type): Rename to...
12670 (python_xmethod_worker::do_get_result_type): ... this and
12672 (gdbpy_invoke_xmethod): Rename to...
12673 (python_xmethod_worker::invoke): ... this and adjust.
12674 (new_python_xmethod_worker): Rename to...
12675 (python_xmethod_worker::python_xmethod_worker): ... this and
12677 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
12679 (gdbpy_free_xmethod_worker_data): Remove.
12680 (gdbpy_get_matching_xmethod_workers): Use std::vector.
12681 (gdbpy_get_xmethod_arg_types): Remove.
12682 (gdbpy_get_xmethod_result_type): Remove.
12683 (gdbpy_invoke_xmethod): Remove.
12684 * python/python.c (python_extension_ops): Remove obsolete
12687 2018-01-05 Pedro Alves <palves@redhat.com>
12690 * common/signals-state-save-restore.c
12691 (save_original_signals_state): New parameter 'quiet'. Warn if we
12692 find a custom handler preinstalled, instead of internal erroring.
12693 But only warn if !quiet.
12694 * common/signals-state-save-restore.h
12695 (save_original_signals_state): New parameter 'quiet'.
12696 * main.c (captured_main_1): Move save_original_signals_state call
12697 after option handling, and pass QUIET.
12699 2018-01-05 Pedro Alves <palves@redhat.com>
12701 * spu-tdep.c (spu_catch_start): Pass
12702 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
12704 2018-01-05 Pedro Alves <palves@redhat.com>
12707 * ada-lang.c (literal_symbol_name_matcher): New function.
12708 (ada_get_symbol_name_matcher): Use it for
12709 symbol_name_match_type::SEARCH_NAME.
12710 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
12711 it down instead of assuming symbol_name_match_type::FULL.
12712 * block.h (block_lookup_symbol): New parameter 'match_type'.
12713 * c-valprint.c (print_unpacked_pointer): Use
12714 lookup_symbol_search_name instead of lookup_symbol.
12715 * compile/compile-object-load.c (get_out_value_type): Pass down
12716 symbol_name_match_type::SEARCH_NAME.
12717 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
12718 symbol_name_match_type::FULL.
12719 * cp-support.c (cp_get_symbol_name_matcher): Handle
12720 symbol_name_match_type::SEARCH_NAME.
12721 * infrun.c (insert_exception_resume_breakpoint): Use
12722 lookup_symbol_search_name.
12723 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
12724 * psymtab.c (maintenance_check_psymtabs): Use
12725 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
12726 * stack.c (print_frame_args): Use lookup_symbol_search_name and
12727 SYMBOL_SEARCH_NAME.
12728 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
12729 if symbol_name_match_type::SEARCH_NAME.
12730 (lookup_symbol_in_language): Pass down
12731 symbol_name_match_type::FULL.
12732 (lookup_symbol_search_name): New.
12733 (lookup_language_this): Pass down
12734 symbol_name_match_type::SEARCH_NAME.
12735 (lookup_symbol_aux, lookup_local_symbol): New parameter
12736 'match_type'. Pass it down.
12737 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
12738 (lookup_symbol_search_name): New declaration.
12739 (lookup_symbol_in_block): New 'match_type' parameter.
12741 2018-01-05 Pedro Alves <palves@redhat.com>
12744 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
12746 (ada_lookup_symbol): Reimplement in terms of
12747 ada_lookup_symbol_list, bits factored out from
12748 ada_lookup_encoded_symbol.
12750 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12752 * ada-exp.y (write_object_renaming): When subscripting an array
12753 using a symbol as the index, pass the block in call to
12754 ada_lookup_encoded_symbol when looking that symbol up.
12756 2018-01-05 Jerome Guitton <guitton@adacore.com>
12758 * ada-lang.c (ada_array_length): Use ada_index_type instead of
12761 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12763 * ada-lang.c (ada_to_fixed_value_create): Add handling of
12764 the case where VALUE_LVAL (val0) is not lval_memory.
12766 2018-01-05 Xavier Roirand <roirand@adacore.com>
12768 * ada-valprint.c (print_optional_low_bound): Handle
12769 character-indexed array printing like boolean-indexed array
12772 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12774 * NEWS: Create a new section for the next release branch.
12775 Rename the section of the current branch, now that it has
12778 2018-01-05 Joel Brobecker <brobecker@adacore.com>
12780 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
12781 * version.in: Bump version to 8.1.50.DATE-git.
12783 2018-01-03 Xavier Roirand <roirand@adacore.com>
12785 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
12787 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
12789 (default_exception_support_info) <catch_handlers_sym>: Add field.
12790 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
12791 (ada_exception_name_addr_1): Add "catch handlers" handling.
12792 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
12793 Update all callers.
12794 (create_excep_cond_exprs) <ex>: Add parameter.
12795 (re_set_exception): Update create_excep_cond_exprs call.
12796 (print_it_exception, print_one_exception, print_mention_exception)
12797 (print_recreate_exception): Add "catch handler" handling.
12798 (allocate_location_catch_handlers, re_set_catch_handlers)
12799 (check_status_catch_handlers, print_it_catch_handlers)
12800 (print_one_catch_handlers, print_mention_catch_handlers)
12801 (print_recreate_catch_handlers): New function.
12802 (catch_handlers_breakpoint_ops): New variable.
12803 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
12804 Add parameter. Add "catch handler" handling.
12805 (ada_exception_sym_name, ada_exception_breakpoint_ops):
12806 Add "catch handler" handling.
12807 (ada_exception_catchpoint_cond_string): Add "catch handler"
12809 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
12811 (catch_ada_handlers_command): New function.
12812 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
12813 operations structure.
12814 (_initialize_ada_language): Add "catch handlers" command entry.
12815 * NEWS: Document "catch handlers" feature.
12817 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12819 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
12820 account when creating the array type of the slice.
12821 (ada_value_slice): Likewise.
12823 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12825 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
12827 (create_array_type_with_stride): Add byte_stride_prop parameter.
12828 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
12829 New parameter. Update all callers in this file.
12830 (array_type_has_dynamic_stride): New function.
12831 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
12832 of arrays with dynamic byte strides.
12833 * dwarf2read.c (read_array_type): Add support for dynamic
12834 DW_AT_byte_stride attributes.
12836 2018-01-02 Joel Brobecker <brobecker@adacore.com>
12838 * dwarf2read.c (read_unspecified_type): Treat
12839 DW_TAG_enumeration_type DIEs from Ada units as stubs.
12841 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12843 Update copyright year range in all GDB files.
12845 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12847 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
12848 and gdb/testsuite/gdb.base/step-line.c.
12850 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12852 * copyright.py (main): Dump the contents of
12853 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
12854 even if BY_HAND is empty.
12856 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12858 * top.c (print_gdb_version): Update Copyright year in version
12861 2018-01-01 Joel Brobecker <brobecker@adacore.com>
12863 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
12865 For older changes see ChangeLog-2017.
12871 version-control: never