1 2018-08-23 Xavier Roirand <roirand@adacore.com>
3 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
6 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
8 * solib-svr4.c (read_program_headers_from_bfd): Return
9 gdb::optional<gdb::byte_vector>.
10 (svr4_exec_displacement): Adjust.
12 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
14 * solib-svr4.c (read_program_header): Return
15 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
16 (find_program_interpreter): Return
17 gdb::optional<gdb::byte_vector>.
18 (scan_dyntag_auxv): Adjust.
19 (enable_break): Adjust.
20 (svr4_exec_displacement): Adjust.
22 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
24 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
25 * inf-child.c (inf_child_target::terminal_save_inferior): New.
27 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
29 * guile/scm-string.c (gdbscm_scm_from_printf): Use
31 * guile/scm-utils.c (gdbscm_printf): Likewise.
32 * serial.c (serial_printf): Likewise.
33 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
35 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
37 * stack.c (print_frame): Print frame architecture when printing on
39 * NEWS: Mention new "arch" attribute in frame output.
41 2018-08-21 Alan Hayward <alan.hayward@arm.com>
43 * arch/aarch64.h (aarch64_regnum): Update comment.
45 2018-08-21 Alan Hayward <alan.hayward@arm.com>
47 * NEWS: Add SVE to 8.2 section.
49 2018-08-21 Pedro Alves <palves@redhat.com>
51 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
52 out from gdbscm_parse_function_args.
53 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
54 gdbscm_parse_function_args_1.
56 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
59 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
62 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
64 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
66 2018-08-19 Michael Spang <spang@google.com>
69 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
72 2018-08-18 Kevin Buettner <kevinb@redhat.com>
74 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
76 * dwarf2-frame.c (class dwarf_expr_executor):
77 Add override for dwarf_variable_value.
78 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
79 (class symbol_needs_eval_context): Likewise.
80 (indirect_synthetic_pointer): Add forward declaration.
81 (sect_variable_value): New function.
82 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
83 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
84 for DW_OP_GNU_variable_value.
86 2018-08-16 Tom Tromey <tom@tromey.com>
88 * top.c (read_command_file): Update.
89 (command_line_input): Remove "repeat" argument.
90 * ada-lang.c (get_selections): Update.
91 * linespec.c (decode_line_2): Update.
92 * defs.h (command_line_input): Remove argument.
93 * cli/cli-script.c (read_next_line): Update.
94 * python/py-gdb-readline.c: Update.
96 2018-08-17 Tom Tromey <tom@tromey.com>
98 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
101 2018-08-15 Tom Tromey <tom@tromey.com>
103 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
105 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
107 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
108 If used, use find_pc_partial_function to find address range
110 * mi/mi-main.c (mi_cmd_list_features): Report
111 "data-disassemble-a-option" feature.
112 * NEWS: Mention new -data-disassemble option -a.
114 2018-08-13 Tom Tromey <tom@tromey.com>
116 * common/common-defs.h (_FORTIFY_SOURCE): Define.
118 2018-08-13 Alan Hayward <alan.hayward@arm.com>
120 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
121 (aarch64_linux_collect_sve_regset): Likewise.
122 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
123 * regcache.h (regcache_map_entry_size): New function.
125 2018-08-13 Alan Hayward <alan.hayward@arm.com>
127 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
128 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
129 (SVE_HEADER_VL_LENGTH): Likewise.
130 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
131 (SVE_HEADER_FLAGS_LENGTH): Likewise.
132 (SVE_HEADER_RESERVED_LENGTH): Likewise.
133 (SVE_HEADER_SIZE_OFFSET): Likewise.
134 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
135 (SVE_HEADER_VL_OFFSET): Likewise.
136 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
137 (SVE_HEADER_FLAGS_OFFSET): Likewise.
138 (SVE_HEADER_RESERVED_OFFSET): Likewise.
139 (SVE_HEADER_SIZE): Likewise.
140 (aarch64_linux_core_read_vq): Add function.
141 (aarch64_linux_core_read_description): Check for SVE section.
143 2018-08-13 Alan Hayward <alan.hayward@arm.com>
145 * aarch64-fbsd-tdep.c
146 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
148 * aarch64-linux-tdep.c
149 (aarch64_linux_iterate_over_regset_sections): Likewise.
151 (alpha_linux_iterate_over_regset_sections):
153 (alphanbsd_iterate_over_regset_sections): Likewise.
155 (amd64fbsd_iterate_over_regset_sections): Likewise.
157 (amd64_linux_iterate_over_regset_sections): Likewise.
159 (armbsd_iterate_over_regset_sections): Likewise.
161 (arm_fbsd_iterate_over_regset_sections): Likewise.
163 (arm_linux_iterate_over_regset_sections): Likewise.
164 * corelow.c (get_core_registers_cb): Likewise.
165 (core_target::fetch_registers): Likewise.
166 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
167 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
168 * gdbarch.h (void): Regenerate.
169 * gdbarch.sh: Add supply_size and collect_size.
170 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
171 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
172 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
173 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
174 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
175 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
176 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
177 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
178 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
179 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
180 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
181 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
182 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
183 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
184 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
185 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
186 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
187 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
188 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
189 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
190 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
191 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
192 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
193 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
194 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
195 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
196 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
197 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
198 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
199 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
201 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
203 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
206 2018-08-10 Keith Seitz <keiths@redhat.com>
208 * compile/compile-c-support.c (add_code_header, add_code_footer):
209 Move into policy class.
210 (c_push_user_expression, pop_user_expression_nop)
211 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
212 (compile_program): New host class.
213 (c_compile_program): New typedef.
214 (c_compute_porgram): Use c_compile_program.
216 2018-08-10 Keith Seitz <keiths@redhat.com>
218 * compile/compile-internal.h (compile_instance::~compile_instance):
219 Remove calls to htab_delete.
220 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
221 * compile.c (compile_instance::compile_instance): Initialize
222 htab unique pointers.
223 (compile_instance::get_cached_type, compile_instance::insert_type)
224 (compile_instance::error_symbol_once): Update for unique_ptr.
226 2018-08-10 Keith Seitz <keiths@redhat.com>
228 * compile/compile-c-symbols.c (struct symbol_error)
229 (hash_symbol_error, eq_symbol_error, del_symbol_error)
230 (compile_instance::insert_symbol_error)
231 (compile_instance::error_symbol_once): Move to ...
232 * compile/compile.c: ... here.
234 2018-08-10 Keith Seitz <keiths@redhat.com>
236 * compile/compile-c-support.c (c_get_compile_context): Use `new'
237 instead of `new_compile_instance'.
238 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
240 If the symbol error map is not initialized, create it.
241 (generate_c_for_for_one_symbol): Do not check/initialize
242 the symbol error map.
243 * compile/compile-c-types.c (compile_c_instance): Make a class.
245 (compile_instance::compile_instance): Initialize the type cache.
246 (get_cached_type): New function.
247 (insert_type): Update description.
248 (compile_c_instance::m_default_cflags): Define.
249 (convert_type): Update description. Use get_cached_type.
250 (delete_instance): Moved to destructor.
251 (new_compile_instance): Moved to constructor.
252 * compile/compile-c.h (compile_c_instance): Make class inheriting
253 from compile_instance.
254 <base>: Remove field.
255 <type_map, symbol_err_map>: Move to base class.
256 <c_plugin>: Rename to `m_plugin' and remove pointer type.
257 * compile/compile-internal.h (compile_instance): Make class.
258 <type_map_t, symbol_err_map_t>: Define.
259 <fe>: Rename to `m_gcc_fe'.
260 <scope, block, gcc_target_options>: Add `m_' prefix.
261 <m_type_map, m_symbol_err_map>: New fields, moved from
264 (convert_type, new_compile_instance): Remove.
265 * compile/compile.c (cleanup_compile_instance): Remove.
266 (compile_to_object): Use unique_ptr to eliminate cleanups.
267 (compile_instance::set_print_callback, compile_instance::version)
268 (compile_instance::set_verbose)
269 (compile_instance::set_driver_filename)
270 (compile_instance::set_triplet_regexp)
271 (compile_instance::set_arguments)
272 (compile_instance::set_source_file)
273 (compile_instance::compile): Define.
275 2018-08-10 Keith Seitz <keiths@redhat.com>
277 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
278 * compile/compile-c-types.c: Define GCC_METHODN macros and include
279 gcc-c-fe.def to define C plugin.
280 (delete_instance): Delete `c_plugin'.
281 (new_compile_instance): Initialize `c_plugin'.
282 * compile/compile-c.h: Include gcc_c_plugin.h.
283 (struct compile_c_instance) <c_plugin>: New member.
284 * gcc-c-plugin.h: New file.
285 Update all callers with API change.
287 2018-08-10 Keith Seitz <keiths@redhat.com>
289 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
290 (HFILES_NO_SRCDIR): ... to here.
291 Add compile-internal.h and compile-c.h.
292 * compile/compile-c-support.c: Include compile-c.h.
293 * compile/compile-c-symbols.c: Include compile-c.h.
294 (generate_c_for_variable_locations): Update comment.
295 * compile/compile-c-types.c: Include compile-c.h.
296 * compile/compile-c.h: New file -- moved C language declarations
297 from other files here.
298 * compile/compile-internal.h: Do not include hashtab.h or
300 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
301 (gcc_convert_symbol, gcc_symbol_address)
302 (generate_c_for_variable_locations, c_get_mode_for_size)
303 (c_get_range_decl_name): Definitions moved to compile-c.h.
304 * compile/compile-loc2c.c: Include compile-c.h.
306 2018-08-10 Keith Seitz <keiths@redhat.com>
308 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
309 (c_symbol_substitution_name): ... this.
312 2018-08-10 Keith Seitz <keiths@redhat.com>
314 * compile/compile-c-support.c (c_compute_program): Use
315 unique_xmalloc_ptr to eliminate cleanup.
316 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
317 Return a unique_xmalloc_ptr and eliminate cleanup.
318 * compile/compile-internal.h (generate_c_for_variable_locations):
319 Return unique_xmalloc_ptr and update description.
321 2018-08-10 Alan Hayward <alan.hayward@arm.com>
323 * corelow.c (core_target::get_core_register_section): Rename
324 min_size to section_min_size.
326 2018-08-09 Jim Wilson <jimw@sifive.com>
328 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
329 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
330 * NEWS: Mention new GNU/Linux RISC-V target.
331 * configure.host: Add riscv*-*-linux*.
332 * configure.nat: Add riscv*.
333 * configure.tgt: Add riscv*-*-linux*.
334 * riscv-linux-nat.c: New file.
335 * riscv-linux-tdep.c: New file.
337 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
339 * infrun.c (resume): Make static, add forward declaration.
340 (proceed): Update header comment.
341 * infrun.h (resume): Delete declaration.
343 2018-08-09 Tom Tromey <tom@tromey.com>
345 * riscv-tdep.h: Minor formatting fixes.
347 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
349 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
350 * dwarf-index-cache.c (create_dir_and_check): Likewise.
351 (test_mkdir_recursive): Likewise.
352 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
354 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
356 * valarith.c (value_subscripted_rvalue): If an array is not in
357 memory, and we don't know the upper bound, then we can't know that
358 the requested element exists or not.
360 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
362 * target.c (str_comma_list_concat_elem): Fix typo in comment.
363 (target_options_to_string): Add comment.
365 2018-08-08 Tom Tromey <tom@tromey.com>
367 * unittests/scoped_mmap-selftests.c: Check result of "write".
369 2018-08-08 Jim Wilson <jimw@sifive.com>
371 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
372 (decode_register_index_short): New.
373 (decode_j_type_insn, decode_cj_type_insn): New.
374 (decode_b_type_insn, decode_cb_type_insn): New.
375 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
376 local xlen. Check xlen when decoding ambiguous compressed insns. In
377 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
378 is_c_sw_insn instead of is_sw_insn.
379 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
380 (riscv_software_single_step): New.
381 * riscv-tdep.h (riscv_software_single_step): Declare.
383 * riscv-tdep.c (riscv_isa_xlen): Drop static.
384 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
386 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
389 * target.c (dispose_inferior): Don't dispose of inferiors that are
392 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
394 * remote.c (remote_target::download_tracepoint): Change char* to
397 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
399 * target.h (target_options_to_string): Return an std::string.
400 * target.c (str_comma_list_concat_elem): Return void, use
402 (do_option): Likewise.
403 (target_options_to_string): Return an std::string.
404 * linux-nat.c (linux_nat_target::wait): Adjust.
405 * target-debug.h (target_debug_print_options): Adjust.
407 2018-08-07 Tom Tromey <tom@tromey.com>
409 * Makefile.in (CPPFLAGS): New variable.
410 (INTERNAL_CPPFLAGS): Use it.
412 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
414 * NEWS: Mention the index cache.
416 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
418 * common/pathstuff.h (get_standard_cache_dir): New.
419 * common/pathstuff.c (get_standard_cache_dir): New.
420 * build-id.h (build_id_to_string): New.
421 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
422 DEBUG_STR_SUFFIX): Move to here.
423 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
424 DEBUG_STR_SUFFIX): Move from there.
425 (write_psymtabs_to_index): Make non-static, add basename
426 parameter. Write to temporary files, rename when done.
427 (save_gdb_index_command): Adjust call to
428 write_psymtabs_to_index.
429 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
431 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
432 (get_gdb_index_contents_from_cache): New.
433 (get_gdb_index_contents_from_cache_dwz): New.
434 (dwarf2_initialize_objfile): Read index from cache.
435 (dwarf2_build_psymtabs): Save to index.
436 * dwarf-index-cache.h: New file.
437 * dwarf-index-cache.c: New file.
438 * dwarf-index-write.h: New file.
440 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
442 * gnulib/aclocal.m4: Re-generate.
443 * gnulib/config.in: Re-generate.
444 * gnulib/configure: Re-generate.
445 * gnulib/import/Makefile.am: Re-generate.
446 * gnulib/import/Makefile.in: Re-generate.
447 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
448 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
449 * gnulib/import/m4/mkdir.m4: New file.
450 * gnulib/import/mkdir.c: New file.
451 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
454 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
456 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
457 * common/scoped_mmap.c: New file.
458 * common/scoped_mmap.h (destroy): New method.
459 (~scoped_mmap, reset): Use destroy.
460 (scoped_mmap): New move constructor.
461 (mmap_file): New declaration.
462 * unittests/scoped_mmap-selftests.c (test_normal,
463 test_invalid_filename, run_tests): New functions.
464 (_initialize_scoped_mmap_selftests): Register selftest.
466 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
468 * dwarf2read.c (read_gdb_index_from_section): Rename to...
469 (read_gdb_index_from_buffer): ... this. Remove section
470 parameter, add buffer parameter.
471 (get_gdb_index_contents_ftype,
472 get_gdb_index_contents_dwz_ftype): New typedefs.
473 (dwarf2_read_gdb_index): Add callback parameters to get the
475 (get_gdb_index_contents_from_section): New.
476 (dwarf2_initialize_objfile): Update call to
477 dwarf2_read_gdb_index.
479 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
481 * common/filestuff.h (gdb_fopen_cloexec): New overload.
482 (gdb_open_cloexec): Likewise.
483 * nat/linux-osdata.c (command_from_pid): Use string_printf.
484 (commandline_from_pid): Likewise.
485 (linux_xfer_osdata_threads): Likewise.
486 (linux_xfer_osdata_fds): Likewise.
487 * ada-lang.c (is_package_name): Likewise.
488 * auxv.c (procfs_xfer_auxv): Likewise.
489 * breakpoint.c (print_one_breakpoint_location): Use
491 (print_one_catch_solib): Use string_printf.
492 * coff-pe-read.c (add_pe_exported_sym): Likewise.
493 (add_pe_forwarded_sym): Likewise.
494 * dwarf2read.c (create_type_unit_group): Likewise.
495 (build_error_marker_type): Likewise.
496 * infcall.c (get_function_name): Likewise.
497 * valprint.c (print_converted_chars_to_obstack): Likewise.
498 * xtensa-tdep.c (xtensa_register_type): Likewise.
500 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
502 * remote.c (remote_target::download_tracepoint): Fix format
505 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
507 * tracefile.c: Include common/byte-vector.h.
508 (trace_save): Change type of buf to gdb::byte_vector. Initialize
509 with trace_regblock_size if needed. Update uses of buf.
511 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
513 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
514 std::vector<unsigned char>.
515 * tracepoint.c (collection_list::collection_list): Remove
516 m_regs_mask initializer from initializer list. Resize
517 m_regs_mask using the largest remote register number.
518 (collection_list::add_remote_register): Remove size check on
519 m_regs_mask. Use at to access element.
520 (collection_list::stringify): Change type of temp_buf to
521 gdb::char_vector. Update uses of temp_buf. Resize if needed to
522 stringify the register mask. Use pack_hex_byte for the register
525 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
527 * tracepoint.h (class collection_list) <add_register>: Remove.
528 <add_remote_register, add_ax_registers, add_local_register>:
530 <add_memrange>: Add scope parameter.
531 * tracepoint.c (encode_actions_1): Likewise.
532 (collection_list::add_register): Rename to ...
533 (collection_list::add_remote_register): ... this. Update
535 (collection_list::add_ax_registers, add_local_register): New
537 (collection_list::add_memrange): Add scope parameter. Call
538 add_local_register instead of add_register.
539 (finalize_tracepoint_aexpr): New function.
540 (collection_list::collect_symbol): Update calls to add_memrange.
541 Call add_local_register instead of add_register. Call
542 add_ax_registers. Call finalize_tracepoint_aexpr.
543 (encode_actions_1): Get remote regnos for $reg action. Call
544 add_remote_register, add_ax_registers, and add_local_register.
545 Update call to add_memrange. Call finalize_tracepoint_aexpr.
546 (validate_actionline): Call finalize_tracepoint_aexpr.
548 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
550 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
551 Replace array buf with gdb::char_vector buf, of size
552 get_remote_packet_size (). Replace references to buf and
553 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
554 and xsnprintf with snprintf. Raise errors if the buffer is too
557 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
559 * remote.c (remote_target::download_tracepoint): Fix the has_more
560 predicate in the QTDP action list iteration.
562 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
564 * remote.c (remote_target::download_tracepoint): Fix indentation
567 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
569 * proc-api.c (_initialize_proc_api): Remove c, unused.
570 * procfs.c (procfs_init_inferior): Remove signals, unused.
571 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
574 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
575 Andrew Burgess <andrew.burgess@embecosm.com>
577 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
578 'W_STOPCODE (0)' as this could be ambiguous.
580 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
582 * ser-tcp.c (net_open): Fix thinko when deciding whether to
583 disable TCP's Nagle algorithm (use "ai_protocol" instead of
586 2018-08-02 Tom Tromey <tom@tromey.com>
589 * dwarf2read.c (read_func_scope): Set symtab on template parameter
591 (process_structure_scope): Likewise.
593 2018-08-02 Xavier Roirand <roirand@adacore.com>
596 * darwin-nat.c (darwin_kill_inferior): Fix handling of
599 2018-08-02 Tom Tromey <tom@tromey.com>
601 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
602 (darwin_suspend_inferior, darwin_resume_inferior)
603 (darwin_decode_notify_message, darwin_resume_inferior_threads)
604 (darwin_check_new_threads): Check result of get_darwin_inferior.
606 2018-07-31 Joel Brobecker <brobecker@adacore.com>
610 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
612 * varobj.c (varobj_get_path_expr_parent): Report an error if
613 parent is a dynamic varobj.
615 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
617 * gnulib/aclocal.m4: Re-generate.
618 * gnulib/config.in: Re-generate.
619 * gnulib/configure: Re-generate.
620 * gnulib/import/Makefile.in: Re-generate.
621 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
622 * gnulib/import/m4/onceonly.m4: Re-generate.
624 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
626 * target-descriptions.c (struct xml_test_tdesc): New.
627 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
628 (record_xml_tdesc): Update.
629 (maintenance_check_xml_descriptions): Update.
630 * target-descriptions.h (record_xml_tdesc): Update comment.
632 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
634 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
635 checking array bounds are defined.
637 2018-07-30 Tom Tromey <tom@tromey.com>
639 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
640 irreflexivity violation.
642 2018-07-30 Tom Tromey <tom@tromey.com>
644 * cli/cli-decode.c (lookup_cmd): Remove lint code.
645 * value.c (unpack_long): Remove lint code.
646 * valops.c (value_ind): Remove lint code.
647 * valarith.c (value_x_binop, value_x_unop, value_equal)
648 (value_pos): Remove lint code.
650 2018-07-28 Tom de Vries <tdevries@suse.de>
652 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
653 with undefined upper bound as <optimized out>.
655 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
657 * gcore.in: Rename variable "name" to "prefix". Expand
660 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
662 * windows-nat.c (windows_nat_target::create_inferior): Update to
663 call close() in global namespace.
665 2018-07-26 Tom Tromey <tom@tromey.com>
667 * dwarf-index-write.c (add_address_entry): Don't add objfile
669 * dbxread.c (find_stab_function): Rename from
670 find_stab_function_addr. Return a bound_minimal_symbol.
671 (read_dbx_symtab): Use raw_text_low, raw_text_high.
672 Don't add objfile offsets.
673 (end_psymtab): Use raw_text_low, raw_text_high,
674 MSYMBOL_VALUE_RAW_ADDRESS.
675 (read_ofile_symtab): Update.
676 (process_one_symbol): Update.
677 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
679 (dw2_relocate): Remove.
680 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
682 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
684 (process_psymtab_comp_unit_reader, add_partial_symbol)
685 (add_partial_subprogram, dwarf2_ranges_read): Update.
686 (load_partial_dies): Update.
687 (add_address_entry): Don't add objfile offsets.
688 (dwarf2_build_include_psymtabs): Update.
689 (create_addrmap_from_aranges): Don't add objfile offsets.
690 (dw2_find_pc_sect_compunit_symtab): Update.
691 * mdebugread.c (parse_symbol): Don't add objfile offsets.
692 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
694 (parse_partial_symbols): Don't add objfile offsets. Use
695 raw_text_low, raw_text_high. Update.
696 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
697 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
698 or call 'relocate' quick function. Clear psymbol_map.
699 * psympriv.h (struct partial_symbol) <address>: Add section
701 <set_unrelocated_address>: Rename from set_address.
702 <raw_text_low, raw_text_high>: New methods.
703 <text_low, text_high>: Add objfile parameter.
704 (add_psymbol_to_bcache): Add 'section' parameter. Call
705 set_unrelocated_address.
706 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
707 (find_pc_psymbol): Update.
708 (fixup_psymbol_section, relocate_psymtabs): Remove.
709 (dump_psymtab, psym_functions): Update.
710 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
712 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
713 (start_psymtab_common): Update.
714 * symfile-debug.c (debug_qf_relocate): Remove.
715 (debug_sym_quick_functions): Update.
716 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
717 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
720 2018-07-26 Tom Tromey <tromey@redhat.com>
722 * dbxread.c (end_psymtab): Use text_high_valid and
724 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
725 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
726 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
728 <text_low_valid, text_high_valid>: New fields.
729 <set_text_low, set_text_high>: Update.
730 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
732 2018-07-26 Tom Tromey <tom@tromey.com>
734 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
736 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
737 textlow and texthigh fields.
738 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
740 * mdebugread.c (parse_lines, parse_partial_symbols)
741 (psymtab_to_symtab_1): Update.
742 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
743 Rename fields. Update comment. Now private.
744 <text_low, text_high, set_text_low, set_text_high>: New methods.
745 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
746 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
747 (start_psymtab_common, maintenance_info_psymtabs)
748 (maintenance_check_psymtabs): Update.
749 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
751 (scan_xcoff_symtab): Update.
753 2018-07-26 Tom Tromey <tromey@redhat.com>
755 * psympriv.h (struct partial_symbol) <unrelocated_address,
756 address, set_address>: New methods.
757 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
758 (fixup_psymbol_section, relocate_psymtabs): Update.
759 (print_partial_symbols): Add 'objfile' parameter. Update.
760 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
763 2018-07-26 Tom Tromey <tom@tromey.com>
765 * dwarf-index-write.c (write_psymbols, debug_names::insert)
766 (debug_names::write_psymbols): Update.
767 * psympriv.h (struct partial_symbol): Derive from
769 <obj_section>: New method.
770 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
771 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
772 (find_pc_sect_psymbol, fixup_psymbol_section)
773 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
774 (print_partial_symbols, recursively_search_psymtabs)
775 (compare_psymbols, psymbol_hash, psymbol_compare)
776 (add_psymbol_to_bcache, maintenance_check_psymtabs)
777 (psymbol_name_matches, psym_fill_psymbol_map): Update.
779 2018-07-26 Tom Tromey <tromey@redhat.com>
781 * dbxread.c (end_psymtab): Remove dead code.
783 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
785 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
786 DWARF unwinders are disabled.
787 * dwarf2-frame.c: Add dwarf2read.h include.
788 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
790 (dwarf2_frame_unwinders_enabled_p): Define.
791 (show_dwarf_unwinders_enabled_p): New function.
792 (_initialize_dwarf2_frame): Register switch to control DWARF
794 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
795 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
796 (show_dwarf_cmdlist): Remove static keyword.
797 * dwarf2read.h (set_dwarf_cmdlist): Declare.
798 (show_dwarf_cmdlist): Declare.
799 * NEWS: Document new feature.
801 2018-07-26 Tom de Vries <tdevries@suse.de>
804 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
806 2018-07-26 Tom de Vries <tdevries@suse.de>
808 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
809 DW_AT_count can't be translated to a dynamic prop.
811 2018-07-25 Tom de Vries <tdevries@suse.de>
813 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
816 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
818 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
820 2018-07-25 Joel Brobecker <brobecker@adacore.com>
822 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
824 2018-07-24 Keith Seitz <keiths@redhat.comt
827 * dwarf2read.c (dw2_add_symbol_to_list): New function.
828 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
829 instead of add_symbol_to_list.
830 (read_file_scope): Call prepare_one_comp_unit before reading
833 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
835 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
837 2018-07-24 Tom Tromey <tom@tromey.com>
839 * utils.c (malloc, realloc, free): Don't declare.
840 * configure, config.in: Rebuild.
841 * configure.ac: Don't check for declarations of free, malloc, or
844 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
846 * aarch64-linux-nat.c
847 (aarch64_linux_nat_target::stopped_data_address): Remove unused
849 * arm-linux-nat.c (fetch_regs): Likewise.
850 (store_regs): Likewise.
851 (fetch_vfp_regs): Likewise.
852 (store_vfp_regs): Likewise.
853 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
854 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
855 (arm_linux_nat_target::insert_watchpoint): Likewise.
856 (arm_linux_nat_target::remove_watchpoint): Likewise.
857 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
859 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
861 * ppc-linux-nat.c (fetch_register): Likewise.
862 (fetch_all_gp_regs): Likewise.
863 (fetch_ppc_registers): Likewise.
864 (store_all_gp_regs): Likewise.
865 (store_ppc_registers): Likewise.
866 (hwdebug_insert_point): Likewise.
867 (can_use_watchpoint_cond_accel): Likewise.
868 * remote-sim.c (gdb_os_write_stdout): Likewise.
870 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
871 Tom Tromey <tom@tromey.com>
873 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
875 * configure: Rebuild.
877 2018-07-22 Tom Tromey <tom@tromey.com>
879 * regformats/regdat.sh: Define xmltarget_${name} inside
880 #ifndef IN_PROCESS_AGENT.
882 2018-07-22 Tom Tromey <tom@tromey.com>
884 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
886 2018-07-22 Tom Tromey <tom@tromey.com>
888 * symfile.c (reread_symbols): Notify iter, not objfile.
890 2018-07-22 Tom Tromey <tom@tromey.com>
892 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
894 (ravenscar_thread_target::prepare_to_store): Likewise.
896 2018-07-22 Tom Tromey <tom@tromey.com>
898 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
899 unused variable. Call value_fetch_lazy when needed.
900 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
901 Remove unused variable. Call value_fetch_lazy when needed.
903 2018-07-22 Tom Tromey <tom@tromey.com>
905 * m32c-tdep.c (mark_dma): Return void.
906 (make_regs): Remove unused declarations.
908 2018-07-22 Tom Tromey <tom@tromey.com>
910 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
911 cmdscm_get_valid_command_smob_arg_unsafe for effect.
912 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
913 bkscm_get_valid_block_smob_arg_unsafe for effect.
915 2018-07-22 Tom Tromey <tom@tromey.com>
917 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
920 2018-07-22 Tom Tromey <tom@tromey.com>
922 * windows-nat.c (saved_context): Conditionally define.
923 * remote.c (remote_target::remote_btrace_maybe_reopen):
924 Conditionally declare "warned".
925 * inflow.c (sigquit_ours): Conditionally define.
926 (new_tty): Move "tty" declaration inside #if.
927 * guile/guile.c (guile_datadir): Conditionally define.
928 * charset.c (set_be_le_names): Move some declarations inside #if.
929 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
931 (parse_xml_btrace_conf): Likewise.
933 2018-07-22 Tom Tromey <tom@tromey.com>
935 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
937 2018-07-22 Tom Tromey <tom@tromey.com>
939 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
940 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
941 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
942 * buildsym-legacy.c (get_macro_table): Remove unused variable.
943 * stack.c (frame_apply_level_command): Remove unused variable.
944 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
945 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
946 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
948 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
949 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
950 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
952 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
953 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
955 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
956 Remove unused variable.
957 * cli/cli-script.c (recurse_read_control_structure): Remove unused
959 * common/tdesc.c (print_xml_feature::visit): Remove unused
961 * compile/compile-object-load.c (store_regs): Remove unused
963 * complaints.c (clear_complaints): Remove unused variable.
964 * corelow.c (core_target_open): Remove unused variable.
965 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
967 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
969 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
971 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
973 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
975 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
977 * ia64-tdep.c (examine_prologue): Remove unused variable.
978 * infcall.c (run_inferior_call): Remove unused variable.
979 * inferior.c (exit_inferior): Remove unused variable.
980 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
981 * linespec.c (decode_line_2): Remove unused variable.
982 * linux-nat.c (super_close): Remove.
983 * linux-tdep.c (linux_info_proc): Remove unused variable.
984 * mi/mi-main.c (mi_execute_command): Remove unused variable.
985 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
986 Remove unused variable.
987 * parse.c (find_minsym_type_and_address): Remove unused variable.
988 * printcmd.c (info_symbol_command, printf_floating): Remove unused
990 * python/py-breakpoint.c (bppy_set_commands): Remove unused
992 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
994 * record-btrace.c (record_btrace_target::store_registers): Remove
996 (cmd_show_record_btrace_cpu): Remove unused variable.
997 * riscv-tdep.c (riscv_register_reggroup_p)
998 (riscv_push_dummy_call, riscv_return_value): Remove unused
1000 * rust-exp.y (literal): Remove unused variable.
1001 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
1003 <STRUCTOP_ANONYMOUS>: Likewise.
1004 * s390-linux-tdep.c (s390_linux_init_abi_31)
1005 (s390_linux_init_abi_64): Remove unused variable.
1006 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
1007 (file_select_thread, net_windows_open, _initialize_ser_windows):
1008 Remove unused variables.
1009 * symtab.c (find_pc_sect_line): Remove unused variable.
1010 * target-memory.c (compute_garbled_blocks): Remove unused
1012 (target_write_memory_blocks): Remove unused variable.
1013 * target.c (target_stack::unpush): Remove unused variables.
1014 * tracepoint.c (start_tracing, all_tracepoint_actions)
1015 (merge_uploaded_trace_state_variables)
1016 (print_one_static_tracepoint_marker): Remove unused variable.
1017 * unittests/basic_string_view/element_access/char/1.cc (test01):
1018 Remove unused variable.
1019 * windows-nat.c (windows_continue, windows_add_all_dlls)
1020 (do_initial_windows_stuff, windows_nat_target::create_inferior):
1021 Remove unused variables.
1023 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
1025 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
1026 attr_profile in HAVE_ELF.
1027 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
1030 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
1032 * frame.c (frame_register_unwind): Change parameter name.
1033 (frame_unwind_register): Likewise.
1034 (frame_unwind_register_value): Likewise.
1035 (frame_unwind_register_signed): Likewise.
1036 (frame_unwind_register_unsigned): Likewise.
1037 * frame.h (frame_register_unwind): Likewise.
1038 (frame_unwind_register): Likewise.
1039 (frame_unwind_register_value): Likewise.
1040 (frame_unwind_register_signed): Likewise.
1041 (frame_unwind_register_unsigned): Likewise.
1042 (frame_unwind_arch): Likewise.
1044 2018-07-20 Maciej W. Rozycki <macro@mips.com>
1046 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
1049 2018-07-20 Maciej W. Rozycki <macro@mips.com>
1051 * mips-linux-nat.c (mips_linux_nat_target::read_description):
1052 Call `get_ptrace_pid' rather than extracting the ptrace PID by
1055 2018-07-20 Keith Seitz <keiths@redhat.com>
1057 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
1058 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
1059 m_compunit_symtab, m_language>: Add "m_" prefix.
1061 * buildsym.c: Update all uses.
1063 2018-07-20 Tom Tromey <tom@tromey.com>
1065 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
1066 * buildsym.h (record_line_ftype): Remove typedef.
1068 2018-07-20 Tom Tromey <tom@tromey.com>
1070 * buildsym-legacy.h (augment_type_symtab): Don't declare.
1071 (end_expandable_symtab): Likewise.
1072 (end_symtab_get_static_block): Likewise.
1073 (end_symtab_from_static_block): Likewise.
1074 * buildsym-legacy.c (augment_type_symtab): Remove.
1075 (end_expandable_symtab): Remove.
1076 (end_symtab_get_static_block): Remove.
1077 (end_symtab_from_static_block): Remove.
1079 2018-07-20 Tom Tromey <tom@tromey.com>
1081 * dwarf2read.c: Include buildsym.h.
1082 (struct dwarf2_cu) <builder>: New method.
1083 (fixup_go_packaging): Update.
1084 (process_full_comp_unit, process_full_type_unit): Update. Don't
1085 use scoped_free_pendings.
1086 (using_directives): Add "cu" parameter, remove "language".
1087 (read_import_statement, setup_type_unit_groups, )
1088 (read_func_scope, read_lexical_block_scope)
1089 (dwarf2_record_block_ranges, read_namespace): Update.
1090 (lnp_state_machine::lnp_state_machine): Add cu parameter.
1091 (lnp_state_machine::handle_end_sequence): Update.
1092 (class lnp_state_machine) <m_cu>: New member.
1093 <m_record_line_callback>: Remove.
1094 <m_currently_recording_lines>: New member.
1095 (lnp_state_machine::handle_set_file): Update.
1096 (noop_record_line): Remove.
1097 (dwarf_record_line_p): Add cu parameter.
1098 (dwarf_record_line_1, dwarf_finish_line): Likewise.
1099 (lnp_state_machine::record_line)
1100 (lnp_state_machine::lnp_state_machine)
1101 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1102 (dwarf_decode_lines): Update.
1103 (dwarf2_start_subfile): Add cu parameter.
1104 (dwarf2_start_symtab, new_symbol): Update.
1105 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
1106 Remove dwarf2_per_objfile parameter.
1107 (dwarf_decode_macros): Update.
1109 2018-07-20 Tom Tromey <tom@tromey.com>
1111 * stabsread.c (define_symbol): Update.
1112 * buildsym-legacy.h (get_buildsym_compunit): Declare.
1113 * dwarf2read.c (new_symbol): Update.
1114 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
1115 * cp-namespace.c: Include buildsym.h.
1116 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
1117 * buildsym-legacy.c (get_buildsym_compunit): New function.
1119 2018-07-20 Tom Tromey <tom@tromey.com>
1121 * xcoffread.c: Include buildsym-legacy.h.
1122 * windows-nat.c: Include buildsym-legacy.h.
1123 * stabsread.c: Include buildsym-legacy.h.
1124 * mdebugread.c: Include buildsym-legacy.h.
1125 * buildsym-legacy.h: New file.
1126 * buildsym-legacy.c: New file, from buildsym.c.
1127 * go32-nat.c: Include buildsym-legacy.h.
1128 * dwarf2read.c: Include buildsym-legacy.h.
1129 * dbxread.c: Include buildsym-legacy.h.
1130 * cp-namespace.c: Include buildsym-legacy.h.
1131 * coffread.c: Include buildsym-legacy.h.
1132 * buildsym.h: Move some contents to buildsym-legacy.h.
1133 * buildsym.c: Include buildsym-legacy.h. Move many functions to
1135 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
1137 2018-07-20 Tom Tromey <tom@tromey.com>
1139 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
1140 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
1141 (buildsym_compunit::buildsym_compunit)
1142 (buildsym_compunit::~buildsym_compunit)
1143 (buildsym_compunit::get_macro_table): Define.
1145 2018-07-20 Tom Tromey <tom@tromey.com>
1147 * buildsym.c (reset_symtab_globals): Remove.
1148 (buildsym_compunit::end_symtab_from_static_block): Update.
1149 (buildsym_compunit::augment_type_symtab): Update.
1150 (end_symtab_from_static_block): Call free_buildsym_compunit.
1151 (augment_type_symtab, end_symtab, end_expandable_symtab):
1154 2018-07-20 Tom Tromey <tom@tromey.com>
1156 * arch-utils.c: Do not include buildsym.h.
1157 * mipsread.c: Do not include buildsym.h.
1158 * machoread.c: Do not include buildsym.h.
1159 * elfread.c: Do not include buildsym.h.
1161 2018-07-20 Tom Tromey <tom@tromey.com>
1163 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
1165 (buildsym_compunit): Add new constructor.
1166 (struct buildsym_compunit) <get_last_source_file, finish_block,
1167 record_block_range, start_subfile, patch_subfile_names,
1168 push_subfile, pop_subfile, record_line, get_compunit_symtab,
1169 set_last_source_start_addr, get_last_source_start_addr,
1170 get_local_using_directives, set_local_using_directives,
1171 get_global_using_directives, outermost_context_p,
1172 get_current_context_stack, get_context_stack_depth,
1173 get_current_subfile, get_local_symbols, get_file_symbols,
1174 get_global_symbols, record_debugformat, record_producer,
1175 push_context, pop_context, end_symtab_get_static_block,
1176 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
1178 <record_pending_block, finish_block_internal, make_blockvector,
1179 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
1183 2018-05-22 Tom Tromey <tom@tromey.com>
1185 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1187 (finish_block_internal): Update.
1189 2018-07-20 Tom Tromey <tom@tromey.com>
1191 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1193 (finish_block_internal): Update.
1195 2018-07-20 Tom Tromey <tom@tromey.com>
1197 * buildsym.h (EXTERN): Don't define or undef.
1198 * buildsym.c (EXTERN): Don't define.
1200 2018-07-20 Tom Tromey <tom@tromey.com>
1202 * buildsym.c: Remove TODO comment.
1204 2018-07-20 Tom Tromey <tom@tromey.com>
1206 * coffread.c (coff_symtab_read): Update.
1207 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
1208 (xcoff_new_init): Update.
1209 * mipsread.c (mipscoff_new_init): Update.
1210 * mdebugread.c (mdebug_build_psymtabs): Update.
1211 * elfread.c (elf_new_init): Update.
1212 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1214 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
1215 (coffstab_build_psymtabs, elfstab_build_psymtabs)
1216 (stabsect_build_psymtabs): Update.
1217 * buildsym.h (buildsym_init): Don't declare.
1218 * buildsym.c: Update comment.
1219 (prepare_for_building): Remove.
1220 (start_symtab, restart_symtab): Update.
1221 (reset_symtab_globals): Update comment.
1222 (buildsym_init): Remove.
1224 2018-07-20 Tom Tromey <tom@tromey.com>
1226 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
1227 * stabsread.c (patch_block_stabs, define_symbol, read_type)
1228 (read_enum_type, common_block_start, common_block_end)
1229 (cleanup_undefined_types_1, finish_global_stabs): Update.
1230 * mdebugread.c (psymtab_to_symtab_1): Update.
1231 * dwarf2read.c (fixup_go_packaging, read_func_scope)
1232 (read_lexical_block_scope, new_symbol): Update.
1233 * dbxread.c (process_one_symbol): Update.
1234 * coffread.c (coff_symtab_read, process_coff_symbol)
1235 (coff_read_enum_type): Update.
1236 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
1238 (get_local_symbols, get_file_symbols, get_global_symbols): New
1240 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
1242 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
1243 (~scoped_free_pendings): Update.
1244 (finish_block, prepare_for_building, reset_symtab_globals)
1245 (end_symtab_get_static_block, end_symtab_with_blockvector)
1246 (augment_type_symtab, push_context): Update.
1247 (get_local_symbols, get_file_symbols, get_global_symbols): New
1249 (buildsym_init): Update.
1251 2018-07-20 Tom Tromey <tom@tromey.com>
1253 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
1254 (process_full_type_unit): Likewise.
1255 (dwarf2_start_symtab): Set list_in_scope.
1257 2018-07-20 Tom Tromey <tom@tromey.com>
1259 * dwarf2read.c (process_psymtab_comp_unit_reader)
1260 (build_type_psymtabs_reader): Do not set list_in_scope.
1262 2018-07-20 Tom Tromey <tom@tromey.com>
1264 * buildsym.c (free_pendings): Remove.
1265 (add_symbol_to_list, scoped_free_pendings)
1266 (finish_block_internal, buildsym_init): Update.
1268 2018-07-20 Tom Tromey <tom@tromey.com>
1270 * xcoffread.c (read_xcoff_symtab): Update.
1271 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
1273 * dbxread.c (process_one_symbol): Update.
1274 * coffread.c (coff_symtab_read): Update.
1275 * buildsym.h (finish_block): Update.
1276 * buildsym.c (finish_block): Remove "listhead" argument.
1277 (end_symtab_get_static_block): Update.
1279 2018-07-20 Tom Tromey <tom@tromey.com>
1281 * buildsym.h (class scoped_free_pendings): Remove constructor.
1282 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
1284 <m_pending_block_obstack, m_pending_blocks>: New members.
1285 (pending_block_obstack, pending_blocks): Remove.
1286 (scoped_free_pendings::scoped_free_pendings): Default.
1287 (~scoped_free_pendings): Update.
1288 (free_pending_blocks): Remove.
1289 (finish_block_internal, record_pending_block, make_blockvector)
1290 (end_symtab_get_static_block, augment_type_symtab, push_context)
1291 (buildsym_init): Update.
1293 2018-07-20 Tom Tromey <tom@tromey.com>
1295 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
1296 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
1298 (pending_addrmap, pending_addrmap_obstack)
1299 (pending_addrmap_interesting): Remove.
1300 (scoped_free_pendings, record_block_range, make_blockvector)
1301 (prepare_for_building, reset_symtab_globals, buildsym_init):
1304 2018-07-20 Tom Tromey <tom@tromey.com>
1306 * xcoffread.c (process_linenos): Update.
1307 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
1308 * mdebugread.c (psymtab_to_symtab_1): Update.
1309 * dwarf2read.c (setup_type_unit_groups)
1310 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
1311 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
1312 * dbxread.c (process_one_symbol): Update.
1313 * coffread.c (coff_symtab_read, enter_linenos)
1314 (process_coff_symbol): Update.
1315 * buildsym.h (current_subfile): Don't declare.
1316 (get_current_subfile): Declare.
1317 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
1319 (start_subfile, free_buildsym_compunit, push_subfile)
1320 (prepare_for_building, start_symtab): Update.
1321 (get_current_subfile): New function.
1323 2018-07-20 Tom Tromey <tom@tromey.com>
1325 * coffread.c (coff_symtab_read): Update.
1326 * xcoffread.c (read_xcoff_symtab): Update.
1327 * dwarf2read.c (new_symbol): Update.
1328 (read_func_scope, read_lexical_block_scope): Update.
1329 * dbxread.c (process_one_symbol): Update.
1330 * buildsym.h (context_stack, context_stack_depth): Don't declare.
1331 (outermost_context_p): Remove macro.
1332 (outermost_context_p, get_current_context_stack)
1333 (get_context_stack_depth): Declare.
1334 (pop_context): Return struct context_stack.
1335 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
1337 (context_stack_size): Remove.
1338 (INITIAL_CONTEXT_STACK_SIZE): Remove.
1339 (prepare_for_building, end_symtab_get_static_block)
1340 (augment_type_symtab, push_context): Update.
1341 (pop_context): Return struct context_stack.
1342 (outermost_context_p, get_current_context_stack)
1343 (get_context_stack_depth): New functions.
1344 (buildsym_init): Update.
1346 2018-07-20 Tom Tromey <tom@tromey.com>
1348 * rust-exp.y: Now a pure parser. Update all rules.
1349 (%union): Move earlier.
1350 (current_parser, work_obstack): Remove globals.
1351 (rust_parser, ~rust_parser): Update.
1352 (class rust_parser) <copy_name, concat3, crate_name, super_name,
1353 lex_character, lex_number, lex_string, lex_identifier,
1354 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
1355 convert_name, convert_params_to_expression,
1356 convert_ast_to_expression, ast_basic_type, ast_operation,
1357 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
1358 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
1359 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
1360 ast_array_type, ast_slice_type, ast_reference_type,
1361 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
1362 (rust_parse): Update.
1363 (rustyyerror, rustyylex): Add parser parameter.
1364 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
1365 (rust_lex_stringish_test, rust_lex_test_sequence)
1366 (rust_lex_test_trailing_dot, rust_lex_test_completion)
1367 (rust_lex_test_push_back, rust_lex_tests): Update.
1369 2018-07-19 Pedro Alves <palves@redhat.com>
1371 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
1372 gdb::unique_xmalloc_ptr.
1373 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
1374 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
1375 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
1376 copy-initialization.
1377 * guile/scm-pretty-print.c (ppscm_print_children): Use
1378 gdb::unique_xmalloc_ptr instead of cleanups.
1379 (gdbscm_apply_val_pretty_printer): Remove cleanups.
1380 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
1381 gdb::unique_xmalloc_ptr.
1382 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1383 Adjust to use gdb::unique_xmalloc_ptr.
1384 * guile/scm-utils.c (extract_arg): Adjust.
1385 * guile/scm-value.c (gdbscm_value_field): Adjust to use
1386 gdb::unique_xmalloc_ptr instead of a cleanup.
1388 2018-07-19 Tom Tromey <tom@tromey.com>
1390 * utils.c (do_value_free_to_mark)
1391 (make_cleanup_value_free_to_mark): Remove.
1392 * utils.h (make_cleanup_value_free_to_mark): Remove.
1394 2018-07-19 Pedro Alves <palves@redhat.com>
1396 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
1397 forwarding reference.
1399 2018-07-18 Pedro Alves <palves@redhat.com>
1401 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
1402 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
1405 2018-07-18 Pedro Alves <palves@redhat.com>
1407 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
1409 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
1411 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
1412 directly instead of a cleanup.
1413 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
1414 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
1415 (vlscm_binop_gdbthrow): New, factored out from ...
1416 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
1417 (vlscm_rich_compare): Use gdbscm_wrap.
1418 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
1419 instead of a cleanup.
1420 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
1422 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1423 Use xfree directly instead of a cleanup.
1424 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
1425 Adjust to use gdbscm_wrap and scoped_value_mark.
1426 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
1427 (gdbscm_value_address, gdbscm_value_dereference)
1428 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
1430 (gdbscm_value_dynamic_type): Use scoped_value_mark.
1431 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
1433 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
1434 gdbscm_wrap and scoped_value_mark.
1435 (gdbscm_value_to_string): Use xfree directly instead of a
1436 cleanup. Move 'buffer' unique_ptr to TRY scope.
1437 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
1438 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
1440 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
1441 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
1443 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
1446 2018-07-18 Tom de Vries <tdevries@suse.de>
1448 * findvar.c (default_read_var_value): Also resolve dynamic type for
1449 LOC_OPTIMIZED_OUT vars.
1451 2018-07-18 Maciej W. Rozycki <macro@mips.com>
1453 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
1456 2018-07-17 Tom Tromey <tom@tromey.com>
1458 * guile/scm-param.c (pascm_set_func, pascm_show_func)
1459 (compute_enum_list, pascm_set_param_value_x)
1460 (gdbscm_parameter_value): Update.
1461 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
1462 (gdbscm_scm_to_host_string): Update.
1463 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
1465 * guile/scm-cmd.c (cmdscm_add_completion): Update.
1466 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
1467 * guile/scm-string.c (gdbscm_scm_to_string): Return
1469 (gdbscm_scm_to_host_string): Likewise.
1471 2018-07-17 Tom Tromey <tom@tromey.com>
1473 * guile/guile.c (gdbscm_eval_from_control_command): Update.
1474 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
1475 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
1476 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
1479 2018-07-17 Tom Tromey <tom@tromey.com>
1481 * guile/scm-param.c (pascm_signal_setshow_error): Update.
1482 * guile/guile-internal.h (gdbscm_exception_message_to_string):
1484 * guile/scm-cmd.c (cmdscm_function): Update.
1485 * guile/scm-pretty-print.c
1486 (ppscm_print_exception_unless_memory_error): Update.
1487 * guile/scm-exception.c (gdbscm_exception_message_to_string):
1488 Return unique_xmalloc_ptr.
1490 2018-07-17 Tom Tromey <tom@tromey.com>
1492 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
1495 2018-07-17 Jim Wilson <jimw@sifive.com>
1497 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
1498 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
1499 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
1500 unecessary braces after EF_RISCV_RVC test. Delete call to
1501 set_gdbarch_decr_pc_after_break.
1503 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
1504 RISCV_LAST_FP_REGNUM + 1.
1505 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
1507 2018-07-17 Tom Tromey <tom@tromey.com>
1509 * configure.ac: Remove --disable-gdbcli.
1510 * configure: Rebuild.
1511 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
1512 (SUBDIR_CLI_CFLAGS): Remove.
1513 (SFILES): Use SUBDIR_CLI_SRCS.
1514 (COMMON_OBS): Use SUBDIR_CLI_OBS.
1516 2018-07-17 Tom Tromey <tom@tromey.com>
1519 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
1521 2018-07-16 Jim Wilson <jimw@sifive.com>
1523 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
1525 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1527 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
1529 (libunwind_frame_sniffer): Likewise.
1530 (libunwind_frame_prev_register): Likewise.
1531 (libunwind_sigtramp_frame_sniffer): Likewise.
1532 * ia64-tdep.c (ia64_access_reg): Likewise.
1533 (ia64_access_rse_reg): Likewise.
1534 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
1535 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
1537 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1539 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
1541 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1543 * remote-sim.c (gdbsim_target::close,
1544 gdbsim_target::mourn_inferior): Remove unused variables.
1546 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
1548 * ia64-tdep.c (ktab_buf): New global.
1549 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
1550 (get_kernel_table): Adjust.
1552 2018-07-16 Tom Tromey <tom@tromey.com>
1554 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
1555 * dwarf2read.c (using_directives, new_symbol): Use
1556 outermost_context_p.
1557 * dbxread.c (process_one_symbol): Use outermost_context_p.
1558 * coffread.c (coff_symtab_read): Use outermost_context_p.
1560 2018-07-16 Tom Tromey <tom@tromey.com>
1562 * dwarf2read.c (using_directives, read_func_scope)
1563 (read_lexical_block_scope): Update.
1564 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1565 * buildsym.h (local_using_directives, global_using_directives):
1567 (get_local_using_directives, set_local_using_directives)
1568 (get_global_using_directives): Declare.
1569 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
1570 m_global_using_directives>: New members.
1571 (finish_block_internal, prepare_for_building)
1572 (reset_symtab_globals, end_symtab_get_static_block)
1573 (push_context): Update.
1574 (get_local_using_directives, set_local_using_directives)
1575 (get_global_using_directives): New functions.
1576 (buildsym_init): Update.
1578 2018-07-16 Tom Tromey <tom@tromey.com>
1580 * xcoffread.c (xcoff_initial_scan): Don't call
1581 free_pending_blocks.
1582 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
1583 * buildsym.h (class scoped_free_pendings): Add constructor.
1584 (free_pending_blocks): Don't declare.
1585 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
1586 (free_pending_blocks): Now static.
1588 2018-07-16 Tom Tromey <tom@tromey.com>
1590 * buildsym.h (push_subfile, pop_subfile): Update declarations.
1591 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
1593 (struct subfile_stack): Remove.
1594 (subfile_stack): Remove.
1595 (push_subfile, pop_subfile, buildsym_init): Update.
1597 2018-07-16 Tom Tromey <tom@tromey.com>
1599 * buildsym.c (push_subfile): Use gdb_assert.
1600 (pop_subfile): Use gdb_assert.
1602 2018-07-16 Tom Tromey <tom@tromey.com>
1604 * buildsym.h (merge_symbol_lists): Remove.
1605 * buildsym.c (merge_symbol_lists): Remove.
1607 2018-07-16 Tom Tromey <tom@tromey.com>
1609 * stabsread.c (scan_file_globals): Update comment.
1610 * stabsread.h (scan_file_globals): Move from buildsym.h.
1611 * buildsym.h (scan_file_globals): Move to stabsread.h.
1613 2018-07-16 Tom Tromey <tom@tromey.com>
1615 * xcoffread.c (xcoff_new_init): Update.
1616 * mipsread.c (mipscoff_new_init): Update.
1617 * mdebugread.c (mdebug_build_psymtabs): Update.
1618 * elfread.c (elf_new_init): Update.
1619 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
1620 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
1621 * buildsym.h (buildsym_new_init): Don't declare.
1622 * buildsym.c (buildsym_new_init): Remove.
1624 2018-07-16 Tom Tromey <tom@tromey.com>
1626 * stabsread.h (within_function): Move from buildsym.h.
1627 * stabsread.c (start_stabs): Clear within_function.
1628 * coffread.c (coff_start_symtab): Clear within_function.
1629 * buildsym.h (within_function): Move to stabsread.h.
1630 * buildsym.c (prepare_for_building): Update.
1632 2018-07-16 Tom Tromey <tom@tromey.com>
1634 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1635 * dwarf2read.c (dwarf2_start_symtab): Don't set
1636 processing_gcc_compilation.
1637 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1639 2018-07-16 Tom Tromey <tom@tromey.com>
1641 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1642 (next_symbol_text_func): Move from buildsym.h.
1643 * stabsread.c (hashname): Move from buildsym.c.
1644 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1645 (next_symbol_text_func, hashname): Move to stabsread.h.
1646 * buildsym.c: Don't include bcache.h
1647 (hashname): Move to stasbread.c.
1649 2018-07-16 Tom Tromey <tom@tromey.com>
1651 * buildsym.h (context_stack_size): Don't declare.
1652 * buildsym.c (context_stack_size): New global.
1654 2018-07-16 Tom Tromey <tom@tromey.com>
1656 * dbxread.c (processing_acc_compilation): New global.
1657 * buildsym.h (processing_acc_compilation): Don't declare.
1659 2018-07-16 Tom Tromey <tom@tromey.com>
1661 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1662 * dbxread.c (read_ofile_symtab): Update.
1663 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1664 * buildsym.h (last_source_start_addr): Remove.
1665 (set_last_source_start_addr, get_last_source_start_addr):
1667 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1669 (struct buildsym_compunit) <m_last_source_start_addr>: New
1671 (prepare_for_building): Remove start_addr parameter.
1672 (start_symtab, restart_symtab, end_symtab_get_static_block)
1673 (end_symtab_with_blockvector): Update.
1674 (set_last_source_start_addr, get_last_source_start_addr): New
1677 2018-07-16 Tom Tromey <tom@tromey.com>
1679 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1681 (have_line_numbers): Remove.
1682 (record_line, prepare_for_building, end_symtab_get_static_block)
1683 (augment_type_symtab): Update.
1685 2018-07-16 Tom Tromey <tom@tromey.com>
1687 * buildsym.c (~buildsym_compunit): Free the macro table.
1688 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1690 <m_pending_macros>: New member.
1691 (pending_macros): Remove.
1692 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1693 (reset_symtab_globals, end_symtab_get_static_block)
1694 (end_symtab_with_blockvector, augment_type_symtab)
1695 (buildsym_init): Update.
1697 2018-07-16 Tom Tromey <tom@tromey.com>
1699 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
1701 (buildsym_compunit::set_last_source_file): New method.
1702 <m_last_source_file>: New member.
1703 (prepare_for_building): Remove "name" parameter.
1704 (start_symtab, restart_symtab, reset_symtab_globals): Update.
1705 (last_source_file): Remove.
1706 (set_last_source_file, get_last_source_file): Update.
1708 2018-07-16 Tom Tromey <tom@tromey.com>
1710 * buildsym.c (prepare_for_building): Add assert.
1712 2018-07-16 Tom Tromey <tom@tromey.com>
1714 * buildsym.c (~buildsym_compunit): Update.
1715 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
1716 (start_subfile, patch_subfile_names)
1717 (end_symtab_with_blockvector): Update.
1719 2018-07-16 Tom Tromey <tom@tromey.com>
1721 * buildsym.c (struct buildsym_compunit): Add constructor,
1722 destructor, initializers.
1723 (start_buildsym_compunit): Remove.
1724 (free_buildsym_compunit): Use "delete".
1725 (start_symtab, restart_symtab): Use "new".
1727 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
1729 * symfile.c (set_objfile_default_section_offset): Remove struct
1732 2018-07-14 Stafford Horne <shorne@gmail.com>
1734 * (Responsible Maintainers): Add myself as or1k maintainer.
1736 2018-07-13 Tom Tromey <tom@tromey.com>
1738 * symfile.c (set_objfile_default_section_offset): Use extra braces
1741 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
1743 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
1746 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1748 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1749 unittests/cli-utils-selftests.c
1750 * unittests/cli-utils-selftests.c: New file.
1752 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1754 * NEWS: Mention new commands. Mention change to 'thread apply'.
1756 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1758 * thread.c (thr_try_catch_cmd): New function.
1759 (thread_apply_all_command): Handle qcs flags.
1760 (thread_apply_command): Handle qcs flags.
1761 (taas_command): New function.
1762 (tfaas_command): New function.
1763 (_initialize_thread): Update to setup the new commands 'taas
1764 and 'tfaas'. Change doc string for 'thread apply'.
1766 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1768 * stack.c: (trailing_outermost_frame): New function, mostly
1769 extracted from backtrace_command_1.
1770 (leading_innermost_frame): New function.
1771 (backtrace_command_1): Update to call trailing_outermost_frame.
1772 (frame_apply_command_count): New function.
1773 (frame_apply_level_command): New function.
1774 (frame_apply_all_command): New function.
1775 (frame_apply_command): New function.
1776 (faas_command): New function.
1777 (frame_cmd_list): New variable.
1778 (_initialize_stack): Update to setup the new commands 'frame apply'
1781 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1783 * cli-utils.c (number_or_range_parser::get_number): Only handle
1784 numbers or convenience var as numbers.
1785 (parse_flags): New function.
1786 (parse_flags_qcs): New function.
1787 (number_or_range_parser::finished): Ensure parsing end is detected
1788 before end of string.
1789 * cli-utils.h (parse_flags): New function.
1790 (parse_flags_qcs): New function.
1791 (number_or_range_parser): Remove m_finished bool.
1792 (number_or_range_parser::skip_range): Set m_in_range to false.
1794 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
1796 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
1799 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1800 Jan Kratochvil <jan.kratochvil@redhat.com>
1801 Paul Fertser <fercerpav@gmail.com>
1802 Tsutomu Seki <sekiriki@gmail.com>
1803 Pedro Alves <palves@redhat.com>
1805 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1806 'unittests/parse-connection-spec-selftests.c'.
1807 (COMMON_SFILES): Add 'common/netstuff.c'.
1808 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
1809 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
1810 * common/netstuff.c: New file.
1811 * common/netstuff.h: New file.
1812 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
1813 (wait_for_connect): Update comment. New parameter
1814 'gdb::optional<int> sock' instead of 'struct serial *scb'.
1815 Use 'sock' directly instead of 'scb->fd'.
1816 (try_connect): New function, with code from 'net_open'.
1817 (net_open): Rewrite main loop to deal with multiple
1818 sockets/addresses. Handle IPv6-style hostnames; implement
1819 support for IPv6 connections.
1820 * unittests/parse-connection-spec-selftests.c: New file.
1822 2018-07-11 Pedro Alves <palves@redhat.com>
1825 * remote.c (remote_target::remote_detach_pid): Call
1826 set_current_process.
1828 2018-07-11 Pedro Alves <palves@redhat.com>
1830 * h8300-tdep.c (h8300_gdbarch_init): Remove
1831 set_gdbarch_ecoff_reg_to_regnum calls.
1833 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1836 * c-typeprint.c (c_type_print_base_struct_union): Don't print
1837 offsets/sizes for static members of a class/struct.
1839 2018-07-11 Alan Hayward <alan.hayward@arm.com>
1841 * target-descriptions.c (tdesc_register_bitsize): Rename.
1842 * target-descriptions.h (tdesc_register_bitsize): Likewise.
1843 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
1844 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
1846 2018-07-10 Tom Tromey <tom@tromey.com>
1848 * breakpoint.c (moribund_locations): Now static and a
1850 (breakpoint_init_inferior, moribund_breakpoint_here_p)
1851 (build_bpstat_chain, update_global_location_list)
1852 (breakpoint_retire_moribund): Update.
1853 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
1856 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1858 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
1859 (riscv_register_reggroup_p): Use new function, remove unneeded
1861 (riscv_push_dummy_call): Extend assert to compare against xlen or
1862 flen based on register type.
1864 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1866 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
1868 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
1870 * remote.c (show_hardware_watchpoint_limit): New function.
1871 (show_hardware_watchpoint_length_limit): New function.
1872 (show_hardware_breakpoint_limit): New function.
1873 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
1874 where appropriate, update help text.
1876 2018-07-09 Tom Tromey <tom@tromey.com>
1878 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
1879 (CLIBS): Don't mention NAT_CLIBS.
1881 2018-07-09 Tom Tromey <tom@tromey.com>
1883 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
1884 (LIBGDB_OBS, clean mostlyclean): Update.
1885 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
1887 2018-07-09 Tom Tromey <tom@tromey.com>
1889 * Makefile.in (%.c: %.y): Use ECHO_YACC.
1890 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
1891 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
1893 2018-07-09 Tom Tromey <tom@tromey.com>
1895 * Makefile.in (ALLDEPFILES): Remove exec.c.
1896 (COMMON_OBS): Remove exec.o.
1897 (COMMON_SFILES): Add exec.c.
1899 2018-07-09 Tom Tromey <tom@tromey.com>
1901 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
1903 2018-07-09 Tom Tromey <tom@tromey.com>
1905 * Makefile.in (clean mostlyclean): Remove stamp-version.
1906 (version.c): Depend on stamp-version.
1907 (stamp-version): New rule, from version.c rule.
1909 2018-07-09 Tom Tromey <tom@tromey.com>
1911 * Makefile.in (init.c): Depend on stamp-init.
1912 (stamp-init): New rule, from init.c rule.
1913 (clean mostlyclean): Remove stamp-init.
1915 2018-07-09 Tom Tromey <tom@tromey.com>
1917 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
1918 SUBDIR_GCC_COMPILE_SRCS.
1920 2018-07-09 Tom Tromey <tom@tromey.com>
1922 * Makefile.in (init.c): Remove some unused sed rules.
1924 2018-07-09 Tom Tromey <tom@tromey.com>
1926 * Makefile.in (TSOBS): Remove.
1927 (INIT_FILES): Update.
1928 (LIBGDB_OBS): Update.
1929 (COMMON_SFILES): Add inflow.c.
1930 (SFILES): Remove inflow.c.
1932 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
1934 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
1936 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
1938 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
1939 get_saveloc_name, is_signal_frame_name, step_name,
1940 init_remote_name, create_addr_space_name,
1941 destroy_addr_space_name, search_unwind_table_name,
1942 find_dyn_list_name): Constify.
1944 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
1946 * darwin-nat.c (darwin_pthread_kill): New function.
1947 (darwin_resume_thread): Use darwin_pthread_kill.
1949 2018-07-05 Tom de Vries <tdevries@suse.de>
1951 * macroexp.c (macro_buffer) <operator=>: New member function.
1953 2018-07-04 Tom Tromey <tom@tromey.com>
1955 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
1957 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
1959 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
1960 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
1961 * maint.c: Likewise.
1964 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1966 * NEWS: Create a new section for the next release branch.
1967 Rename the section of the current branch, now that it has
1970 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1972 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
1973 * version.in: Bump version to 8.2.50.DATE-git.
1975 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1976 Pedro Alves <palves@redhat.com>
1978 * linux-nat.c (linux_init_ptrace): Rename to ...
1979 (linux_init_ptrace_procfs): ... this. Call
1980 linux_proc_init_warnings.
1981 (linux_nat_target::post_attach)
1982 (linux_nat_target::post_startup_inferior): Adjust.
1983 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
1984 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
1986 2018-07-04 Tom de Vries <tdevries@suse.de>
1988 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
1990 (read_comp_unit_head): ... here.
1992 2018-07-03 Tom Tromey <tom@tromey.com>
1994 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
1995 (stop_tracing, tstatus_command)
1996 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
1997 (print_one_static_tracepoint_marker): Update.
1998 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
2000 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
2002 (all_tracepoints, static_tracepoints_here): Return std::vector.
2004 2018-07-03 Tom Tromey <tom@tromey.com>
2006 * common/ptid.c (ptid_equal): Remove.
2007 * common/ptid.h (ptid_equal): Don't declare.
2008 * ada-tasks.c: Update.
2009 * breakpoint.c: Update.
2010 * common/agent.c: Update.
2011 * corelow.c: Update.
2012 * darwin-nat-info.c: Update.
2013 * darwin-nat.c: Update.
2015 * dtrace-probe.c: Update.
2016 * dummy-frame.c: Update.
2017 * fbsd-nat.c: Update.
2019 * gdbthread.h: Update.
2020 * gnu-nat.c: Update.
2021 * go32-nat.c: Update.
2022 * inf-loop.c: Update.
2023 * inf-ptrace.c: Update.
2024 * infcall.c: Update.
2028 * linux-fork.c: Update.
2029 * linux-nat.c: Update.
2030 * linux-thread-db.c: Update.
2031 * mi/mi-cmd-var.c: Update.
2032 * mi/mi-interp.c: Update.
2033 * mi/mi-main.c: Update.
2034 * nto-procfs.c: Update.
2035 * ppc-linux-tdep.c: Update.
2037 * python/py-inferior.c: Update.
2038 * python/py-record-btrace.c: Update.
2039 * python/py-record.c: Update.
2040 * ravenscar-thread.c: Update.
2041 * regcache.c: Update.
2042 * remote-sim.c: Update.
2044 * sol-thread.c: Update.
2047 * tui/tui-stack.c: Update.
2049 * windows-nat.c: Update.
2050 * windows-tdep.c: Update.
2052 2018-07-03 Tom Tromey <tom@tromey.com>
2054 * common/ptid.c (ptid_match): Remove.
2055 * common/ptid.h (ptid_match): Don't declare.
2056 * fbsd-nat.c: Update.
2059 * linux-nat.c: Update.
2060 * record-btrace.c: Update.
2061 * regcache.c: Update.
2064 2018-07-03 Tom Tromey <tom@tromey.com>
2066 * common/ptid.c (ptid_tid_p): Remove.
2067 * common/ptid.h (ptid_tid_p): Don't declare.
2068 * sol-thread.c: Update.
2070 2018-07-03 Tom Tromey <tom@tromey.com>
2072 * common/ptid.c (ptid_lwp_p): Remove.
2073 * common/ptid.h (ptid_lwp_p): Don't declare.
2074 * fbsd-nat.c: Update.
2075 * linux-nat.c: Update.
2076 * nat/linux-procfs.c: Update.
2077 * nat/x86-linux-dregs.c: Update.
2078 * sol-thread.c: Update.
2080 2018-07-03 Tom Tromey <tom@tromey.com>
2082 * common/ptid.c (ptid_is_pid): Remove.
2083 * common/ptid.h (ptid_is_pid): Don't declare.
2085 * linux-nat.c: Update.
2086 * mi/mi-interp.c: Update.
2090 2018-07-03 Tom Tromey <tom@tromey.com>
2092 * common/ptid.c (ptid_get_tid): Remove.
2093 * common/ptid.h (ptid_get_tid): Don't declare.
2094 * ada-tasks.c: Update.
2095 * aix-thread.c: Update.
2096 * bsd-uthread.c: Update.
2097 * darwin-nat.c: Update.
2098 * fbsd-nat.c: Update.
2099 * i386-darwin-nat.c: Update.
2101 * linux-tdep.c: Update.
2102 * nto-procfs.c: Update.
2103 * ppc-ravenscar-thread.c: Update.
2104 * python/py-infthread.c: Update.
2105 * ravenscar-thread.c: Update.
2106 * sol-thread.c: Update.
2107 * sparc-ravenscar-thread.c: Update.
2108 * windows-nat.c: Update.
2110 2018-07-03 Tom Tromey <tom@tromey.com>
2112 * common/ptid.c (ptid_get_lwp): Remove.
2113 * common/ptid.h (ptid_get_lwp): Don't declare.
2114 * aarch64-linux-nat.c: Update.
2115 * ada-tasks.c: Update.
2116 * aix-thread.c: Update.
2117 * amd64-linux-nat.c: Update.
2118 * arm-linux-nat.c: Update.
2119 * corelow.c: Update.
2120 * fbsd-nat.c: Update.
2121 * fbsd-tdep.c: Update.
2122 * gnu-nat.c: Update.
2123 * i386-cygwin-tdep.c: Update.
2124 * i386-gnu-nat.c: Update.
2125 * i386-linux-nat.c: Update.
2126 * ia64-linux-nat.c: Update.
2127 * inf-ptrace.c: Update.
2129 * linux-fork.c: Update.
2130 * linux-nat.c: Update.
2131 * linux-tdep.c: Update.
2132 * linux-thread-db.c: Update.
2133 * mips-linux-nat.c: Update.
2134 * nat/aarch64-linux-hw-point.c: Update.
2135 * nat/aarch64-linux.c: Update.
2136 * nat/linux-btrace.c: Update.
2137 * nat/linux-osdata.c: Update.
2138 * nat/linux-procfs.c: Update.
2139 * nat/x86-linux-dregs.c: Update.
2140 * obsd-nat.c: Update.
2141 * ppc-fbsd-nat.c: Update.
2142 * ppc-linux-nat.c: Update.
2144 * python/py-infthread.c: Update.
2145 * ravenscar-thread.c: Update.
2147 * s390-linux-nat.c: Update.
2148 * sol-thread.c: Update.
2149 * sol2-tdep.c: Update.
2150 * spu-linux-nat.c: Update.
2151 * x86-linux-nat.c: Update.
2152 * xtensa-linux-nat.c: Update.
2154 2018-07-03 Tom Tromey <tom@tromey.com>
2156 * common/ptid.c (ptid_get_pid): Remove.
2157 * common/ptid.h (ptid_get_pid): Don't declare.
2158 * aarch64-linux-nat.c: Update.
2159 * ada-lang.c: Update.
2160 * aix-thread.c: Update.
2161 * alpha-bsd-nat.c: Update.
2162 * amd64-fbsd-nat.c: Update.
2163 * amd64-linux-nat.c: Update.
2164 * arm-linux-nat.c: Update.
2165 * arm-nbsd-nat.c: Update.
2167 * break-catch-syscall.c: Update.
2168 * breakpoint.c: Update.
2169 * bsd-uthread.c: Update.
2170 * corelow.c: Update.
2172 * darwin-nat.c: Update.
2173 * fbsd-nat.c: Update.
2174 * fbsd-tdep.c: Update.
2176 * gnu-nat.c: Update.
2177 * hppa-nbsd-nat.c: Update.
2178 * hppa-obsd-nat.c: Update.
2179 * i386-fbsd-nat.c: Update.
2180 * ia64-linux-nat.c: Update.
2181 * inf-ptrace.c: Update.
2183 * inferior.c: Update.
2184 * inferior.h: Update.
2187 * linux-fork.c: Update.
2188 * linux-nat.c: Update.
2189 * linux-tdep.c: Update.
2190 * linux-thread-db.c: Update.
2191 * m68k-bsd-nat.c: Update.
2192 * mi/mi-interp.c: Update.
2193 * mi/mi-main.c: Update.
2194 * mips-linux-nat.c: Update.
2195 * mips-nbsd-nat.c: Update.
2196 * mips64-obsd-nat.c: Update.
2197 * nat/aarch64-linux-hw-point.c: Update.
2198 * nat/aarch64-linux.c: Update.
2199 * nat/linux-btrace.c: Update.
2200 * nat/linux-osdata.c: Update.
2201 * nat/linux-procfs.c: Update.
2202 * nat/x86-linux-dregs.c: Update.
2203 * nto-procfs.c: Update.
2204 * obsd-nat.c: Update.
2205 * ppc-linux-nat.c: Update.
2206 * ppc-nbsd-nat.c: Update.
2207 * ppc-obsd-nat.c: Update.
2208 * proc-service.c: Update.
2210 * python/py-inferior.c: Update.
2211 * python/py-infthread.c: Update.
2212 * ravenscar-thread.c: Update.
2214 * remote-sim.c: Update.
2216 * rs6000-nat.c: Update.
2217 * s390-linux-nat.c: Update.
2218 * sh-nbsd-nat.c: Update.
2219 * sol-thread.c: Update.
2220 * sparc-nat.c: Update.
2221 * sparc64-tdep.c: Update.
2222 * spu-linux-nat.c: Update.
2223 * spu-tdep.c: Update.
2224 * target-debug.h: Update.
2227 * tid-parse.c: Update.
2228 * tracefile-tfile.c: Update.
2229 * vax-bsd-nat.c: Update.
2230 * windows-nat.c: Update.
2231 * x86-linux-nat.c: Update.
2232 * x86-nat.c: Update.
2234 2018-07-03 Tom Tromey <tom@tromey.com>
2236 * common/ptid.c (pid_to_ptid): Remove.
2237 * common/ptid.h (pid_to_ptid): Don't declare.
2238 * aix-thread.c: Update.
2239 * arm-linux-nat.c: Update.
2240 * common/ptid.c: Update.
2241 * common/ptid.h: Update.
2242 * corelow.c: Update.
2244 * darwin-nat.c: Update.
2245 * fbsd-nat.c: Update.
2246 * fork-child.c: Update.
2247 * gnu-nat.c: Update.
2248 * go32-nat.c: Update.
2249 * inf-ptrace.c: Update.
2251 * inferior.c: Update.
2253 * linux-fork.c: Update.
2254 * linux-nat.c: Update.
2255 * nat/aarch64-linux-hw-point.c: Update.
2256 * nat/fork-inferior.c: Update.
2257 * nat/x86-linux-dregs.c: Update.
2258 * nto-procfs.c: Update.
2259 * obsd-nat.c: Update.
2261 * progspace.c: Update.
2263 * rs6000-nat.c: Update.
2264 * s390-linux-nat.c: Update.
2265 * sol-thread.c: Update.
2266 * spu-linux-nat.c: Update.
2269 * tracefile-tfile.c: Update.
2270 * windows-nat.c: Update.
2272 2018-07-03 Tom Tromey <tom@tromey.com>
2274 * common/ptid.h (ptid_build): Don't declare.
2275 * common/ptid.c (ptid_build): Remove.
2276 * aix-thread.c: Update.
2277 * bsd-kvm.c: Update.
2278 * bsd-uthread.c: Update.
2279 * common/agent.c: Update.
2280 * common/ptid.c: Update.
2281 * common/ptid.h: Update.
2282 * corelow.c: Update.
2283 * darwin-nat.c: Update.
2284 * fbsd-nat.c: Update.
2285 * gnu-nat.c: Update.
2286 * linux-fork.c: Update.
2287 * linux-nat.c: Update.
2288 * linux-thread-db.c: Update.
2289 * nat/linux-osdata.c: Update.
2290 * nat/linux-procfs.c: Update.
2291 * nto-procfs.c: Update.
2292 * obsd-nat.c: Update.
2293 * proc-service.c: Update.
2295 * ravenscar-thread.c: Update.
2296 * remote-sim.c: Update.
2298 * sol-thread.c: Update.
2300 * windows-nat.c: Update.
2302 2018-07-03 Tom Tromey <tom@tromey.com>
2304 * infrun.c (follow_exec): Use exit_inferior_silent.
2305 * inferior.c (exit_inferior_num_silent): Remove.
2306 * inferior.h (exit_inferior_num_silent): Don't declare.
2308 2018-07-03 Tom Tromey <tom@tromey.com>
2311 * darwin-nat.c (darwin_attach_pid): Reset inferior and
2312 inferior_ptid on error.
2314 2018-07-02 Maciej W. Rozycki <macro@mips.com>
2315 Simon Marchi <simon.marchi@polymtl.ca>
2318 * disasm.h (gdb_disassembler): Add
2319 `m_disassembler_options_holder'. member
2320 * disasm.c (get_all_disassembler_options): New function.
2321 (gdb_disassembler::gdb_disassembler): Use it.
2322 (gdb_buffered_insn_length_init_dis): Likewise.
2323 (gdb_buffered_insn_length): Adjust accordingly.
2324 (set_disassembler_options): Handle options with arguments.
2325 (show_disassembler_options_sfunc): Likewise. Add a leading new
2326 line if showing options with descriptions.
2327 (disassembler_options_completer): Adapt to using the
2328 `disasm_options_and_args_t' structure.
2329 * mips-tdep.c (mips_disassembler_options): New variable.
2330 (mips_disassembler_options_o32): Likewise.
2331 (mips_disassembler_options_n32): Likewise.
2332 (mips_disassembler_options_n64): Likewise.
2333 (gdb_print_insn_mips): Don't set `disassembler_options'.
2334 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
2336 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
2337 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
2338 `gdbarch_disassembler_options_implicit' and
2339 `gdbarch_valid_disassembler_options'.
2340 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
2341 `disasm_options_and_args_t' structure.
2342 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
2344 (valid_disassembler_options): Switch from `disasm_options_t' to
2345 the `disasm_options_and_args_t' structure.
2346 * NEWS: Document `set disassembler-options' support for the MIPS
2348 * gdbarch.h: Regenerate.
2349 * gdbarch.c: Regenerate.
2351 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
2353 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
2355 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2357 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
2358 parameter in call to amd64_target_description.
2359 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
2360 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
2361 (amd64fbsd_init_abi): Likewise.
2362 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
2363 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
2364 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
2365 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
2367 2018-06-29 Pedro Alves <palves@redhat.com>
2369 * gdb/amd64-tdep.h (amd64_create_target_description): Add
2370 "segments" parameter.
2371 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
2372 (_initialize_amd64_tdep): Update call to
2373 amd64_create_target_description.
2374 (amd64_target_description): Add "segments" parameter. Adjust
2375 the implementation to use it.
2376 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
2377 call to amd64_create_target_description.
2378 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
2379 * gdb/arch/amd64.h (amd64_create_target_description): Add
2380 "segments" register.
2381 * gdb/arch/amd64.c (amd64_create_target_description): Add
2382 "segments" parameter. Call create_feature_i386_64bit_segments
2383 only if SEGMENTS is true.
2384 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
2385 call to amd64_create_target_description.
2387 2018-06-29 Pedro Alves <palves@redhat.com>
2389 * thread.c (thread_target_id_str): New, factored out from ...
2390 (print_thread_info_1): ... here. Use it to compute the max
2391 "Target Id" column width.
2393 2018-06-29 Pedro Alves <palves@redhat.com>
2395 * remote.c (remote_target::extra_thread_info): Delete
2396 'display_buf' and 'n' locals. from the cache, regardless of
2397 packet mechanims is in use. Use cache for qThreadExtra and qP
2400 2018-06-29 Pedro Alves <palves@redhat.com>
2402 * blockframe.c (find_pc_sect_containing_function): New function.
2403 * breakpoint.c (print_breakpoint_location): Don't call
2404 find_pc_sect_function.
2405 * linespec.c (create_sals_line_offset): Record the location's
2407 * linespec.c (convert_address_location_to_sals): Fill in sal's
2408 symbol with find_pc_sect_containing_function.
2409 * symtab.c (find_function_start_sal): Rename to ...
2410 (find_function_start_sal_1): ... this.
2411 (find_function_start_sal): Reimplement as wrapper around
2412 find_function_start_sal_1, and use
2413 find_pc_sect_containing_function to fill in the sal's symbol.
2414 (find_function_start_sal(symbol*, bool)): Adjust.
2415 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
2417 (find_pc_sect_containing_function): Declare.
2419 2018-06-29 Pedro Alves <palves@redhat.com>
2421 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
2422 true if the the location has no symbol.
2424 2018-06-28 Tom Tromey <tom@tromey.com>
2426 * NEWS: Mention --enable-codesign.
2427 * silent-rules.mk (ECHO_SIGN): New variable.
2428 * configure.ac: Add --enable-codesign.
2429 * configure: Rebuild.
2430 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
2431 (gdb$(EXEEXT)): Optionally invoke codesign.
2433 2018-06-28 Pedro Alves <palves@redhat.com>
2435 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
2437 (switch_to_thread_no_regs): Adjust comment.
2438 * infcmd.c (stop_pc): Delete.
2439 (post_create_inferior, info_program_command): Replace references
2440 to stop_pc with references to thread_info->suspend.stop_pc.
2441 * inferior.h (stop_pc): Delete declaration.
2442 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
2443 (handle_inferior_event_1, handle_signal_stop)
2444 (process_event_stop_test, keep_going_stepped_thread)
2445 (handle_step_into_function, handle_step_into_function_backward)
2446 (print_stop_location): Replace references to stop_pc with
2447 references to thread_info->suspend.stop_pc.
2448 (struct infcall_suspend_state) <stop_pc>: Delete field.
2449 (save_infcall_suspend_state, restore_infcall_suspend_state):
2450 Remove references to inf_stat->stop_pc.
2451 * linux-fork.c (fork_load_infrun_state): Likewise.
2452 * record-btrace.c (record_btrace_set_replay): Likewise.
2453 * record-full.c (record_full_goto_entry): Likewise.
2454 * remote.c (print_one_stopped_thread): Likewise.
2455 * target.c (target_resume): Extend comment.
2456 * thread.c (set_executing_thread): New.
2457 (set_executing): Use it.
2458 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
2459 Remove references to stop_pc.
2461 2018-06-28 Pedro Alves <palves@redhat.com>
2463 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
2464 Moving fetching stop_pc until after ecs->event_thread is refreshed.
2466 2018-06-28 Tom Tromey <tom@tromey.com>
2468 * coffread.c (coff_symfile_finish): Update.
2469 * xcoffread.c (xcoff_symfile_finish): Update.
2470 * elfread.c (elf_symfile_finish): Update.
2471 * symfile.h (dwarf2_free_objfile): Don't declare.
2472 * dwarf2read.c (_initialize_dwarf2_read): Use
2473 register_objfile_data_with_cleanup.
2474 (dwarf2_free_objfile): Now static. Change signature.
2476 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2478 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
2479 option "-o" to add-symbol-file-load to add an offset to each
2480 section's load address.
2481 * symfile.c (set_objfile_default_section_offset): New function.
2483 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2485 * symfile.c (add_symbol_file_command): Make sure that sections
2486 with the same name are sorted in the same order.
2488 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2490 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
2491 require the second argument. If omitted, load sections at the
2492 addresses specified in the file.
2494 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2496 * symfile.c (symbol_file_command, symbol_file_add_main_1)
2497 (_initialize_symfile): Add option "-o" to symbol-file to add an
2498 offset to each section of the symbol file.
2500 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2502 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
2504 2018-06-27 Tom Tromey <tom@tromey.com>
2506 * stack.c (_initialize_stack): Update "func" help text.
2508 2018-06-27 Tom Tromey <tom@tromey.com>
2510 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
2512 (unwind_infopy_str, pyuw_create_unwind_info)
2513 (unwind_infopy_add_saved_register, pyuw_sniffer)
2514 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
2516 (struct saved_reg): Add constructor.
2517 <value>: Now a gdbpy_ref<>.
2519 2018-06-27 Tom Tromey <tom@tromey.com>
2521 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
2523 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2525 * gdb-gdb.py.in: Format using autopep8.
2527 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2529 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
2530 (type_lookup_function): Recognize CORE_ADDR values.
2532 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2534 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
2537 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2539 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
2542 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2544 * gdb-gdb.py: Move to...
2545 * gdb-gdb.py.in: ... here.
2546 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
2547 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
2549 (distclean): Remove gdb-gdb.py when cleaning.
2550 (gdb-gdb.py, gdb-gdb.gdb): New rules.
2551 * configure: Re-generate.
2553 2018-06-27 Pedro Alves <palves@redhat.com>
2555 * proc-service.c (get_ps_regcache): New.
2556 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
2557 (ps_lsetfpregs): Use it.
2559 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
2562 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
2563 (dwarf_decode_lines_1): Adjust.
2565 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2567 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
2569 <info_proc>: Likewise.
2571 2018-06-26 Joel Brobecker <brobecker@adacore.com>
2573 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
2574 to windows_fetch_one_register, and only handle the case of
2575 fetching one register. Move the code that reloads the context
2576 and iterates over all registers if R is negative to...
2577 (windows_nat_target::fetch_registers): ... here.
2578 (do_windows_store_inferior_registers): Rename to
2579 windows_store_one_register, and only handle the case of storing
2580 one register. Move the code that handles the case where r is
2582 (windows_nat_target::store_registers) ... here.
2584 2018-06-26 Tom Tromey <tom@tromey.com>
2587 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
2588 * rust-lang.c (rust_print_struct_def): Add podata parameter.
2590 (rust_internal_print_type): Add podata parameter.
2591 (rust_print_type): Update.
2593 2018-06-26 Tom Tromey <tom@tromey.com>
2595 * typeprint.h (struct print_offset_data) <update, finish,
2596 maybe_print_hole>: New methods.
2597 <indentation>: New constant.
2598 * typeprint.c (print_offset_data::indentation): Define.
2599 (print_offset_data::maybe_print_hole, print_offset_data::update)
2600 (print_offset_data::finish): Move from c-typeprint.c and rename.
2601 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
2602 (print_spaces_filtered_with_print_options): Update.
2603 (c_print_type_union_field_offset, maybe_print_hole)
2604 (c_print_type_struct_field_offset): Move to typeprint.c and
2606 (c_type_print_base_struct_union): Update.
2608 2018-06-25 Pedro Alves <palves@redhat.com>
2610 * gdbthread.h (thread_info_ref, delete_thread)
2611 (delete_thread_silent, first_thread_of_inferior)
2612 (any_thread_of_inferior, switch_to_thread)
2613 (enable_thread_stack_temporaries)
2614 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2615 (get_last_thread_stack_temporary)
2616 (value_in_thread_stack_temporaries, can_access_registers_thread):
2617 Spell out "struct thread_info" instead of just "thread_info".
2618 * inferior.h (notice_new_inferior): Likewise.
2620 2018-06-25 Pedro Alves <palves@redhat.com>
2622 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2623 pass thread_info pointer to delete_thread.
2624 (windows_nat_target::detach): Pass inferior pointer to
2626 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2628 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2629 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2630 and pass a thread_info pointer to delete_thread.
2631 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2632 pass thread_info pointer to delete_thread.
2633 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2634 delete_thread_silent call.
2635 * procfs.c (procfs_target::detach): Pass inferior pointer to
2637 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2638 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2639 delete_thread_silent call.
2640 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2641 pass thread_info pointer to delete_thread.
2642 (windows_nat_target::detach): Pass inferior pointer to
2645 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2647 * regcache.c (readable_regcache::read_part): Fix asserts.
2648 (reg_buffer::raw_collect_part): New function.
2649 (regcache::write_part): Fix asserts.
2650 (reg_buffer::raw_supply_part): New function.
2651 (regcache::transfer_regset_register): New helper function.
2652 (regcache::transfer_regset): Call new functions.
2653 (regcache_supply_regset): Use gdb_byte*.
2654 (regcache::supply_regset): Likewise.
2655 (regcache_collect_regset): Likewise.
2656 (regcache::collect_regset): Likewise.
2657 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2658 (reg_buffer::raw_supply_part): Likewise.
2659 (regcache::transfer_regset_register): Likewise.
2660 (regcache::transfer_regset): Use gdb_byte*.
2662 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2664 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2666 2018-06-21 Pedro Alves <palves@redhat.com>
2668 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2669 instead of a ptid_t. All callers adjusted.
2670 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2672 (print_ada_task_info, display_current_task_id, task_command_1):
2674 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2676 (breakpoint_kind): Adjust.
2677 (remove_breakpoints_pid): Rename to ...
2678 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2679 pointer. All callers adjusted.
2680 (bpstat_clear_actions): Use inferior_thread.
2681 (get_bpstat_thread): New.
2682 (bpstat_do_actions): Use it.
2683 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2684 to take a thread_info pointer. All callers adjusted.
2685 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2686 (breakpoint_re_set_thread): Use inferior_thread.
2687 * breakpoint.h (struct inferior): Forward declare.
2688 (bpstat_stop_status): Update.
2689 (remove_breakpoints_pid): Delete.
2690 (remove_breakpoints_inf): New.
2691 * bsd-uthread.c (bsd_uthread_target::wait)
2692 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2693 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2694 (maint_btrace_packet_history_cmd)
2695 (maint_btrace_clear_packet_history_cmd): Adjust.
2696 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
2698 * cli/cli-interp.c: Include "inferior.h".
2699 * common/refcounted-object.h (struct
2700 refcounted_object_ref_policy): New.
2701 * compile/compile-object-load.c: Include gdbthread.h.
2702 (store_regs): Use inferior_thread.
2703 * corelow.c (core_target::close): Use current_inferior.
2704 (core_target_open): Adjust to use first_thread_of_inferior and use
2705 the current inferior.
2706 * ctf.c (ctf_target::close): Adjust to use current_inferior.
2707 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
2708 <thread>: ... this new field. All references adjusted.
2709 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
2710 Take a thread_info pointer instead of a ptid_t.
2711 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
2712 (dummy_frame_discard, register_dummy_frame_dtor): Take a
2713 thread_info pointer instead of a ptid_t.
2714 * elfread.c: Include "inferior.h".
2715 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
2716 Use inferior_thread.
2717 * eval.c (evaluate_subexp): Likewise.
2718 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
2720 * gdb_proc_service.h (struct thread_info): Forward declare.
2721 (struct ps_prochandle) <ptid>: Delete, replaced by ...
2722 <thread>: ... this new field. All references adjusted.
2723 * gdbarch.h, gdbarch.c: Regenerate.
2724 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
2725 'thread' parameter. All implementations and callers adjusted.
2726 * gdbthread.h (thread_info) <set_running>: New method.
2727 (delete_thread, delete_thread_silent): Take a thread_info pointer
2729 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
2730 (first_thread_of_process): Delete, replaced by ...
2731 (first_thread_of_inferior): ... this new function. All callers
2733 (any_live_thread_of_process): Delete, replaced by ...
2734 (any_live_thread_of_inferior): ... this new function. All callers
2736 (switch_to_thread, switch_to_no_thread): Declare.
2737 (is_executing): Delete.
2738 (enable_thread_stack_temporaries): Update comment.
2739 <enable_thread_stack_temporaries>: Take a thread_info pointer
2740 instead of a ptid_t. Incref the thread.
2741 <~enable_thread_stack_temporaries>: Decref the thread.
2744 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2745 (get_last_thread_stack_temporary)
2746 (value_in_thread_stack_temporaries, can_access_registers_thread):
2747 Take a thread_info pointer instead of a ptid_t. All callers
2749 * infcall.c (get_call_return_value): Use inferior_thread.
2750 (run_inferior_call): Work with thread pointers instead of ptid_t.
2751 (call_function_by_hand_dummy): Work with thread pointers instead
2752 of ptid_t. Use thread_info_ref.
2753 * infcmd.c (proceed_thread_callback): Access thread's state
2755 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
2756 access thread's state directly.
2757 (continue_command): Use inferior_thread.
2758 (info_program_command): Use find_thread_ptid and access thread
2760 (proceed_after_attach_callback): Use thread state directly.
2761 (notice_new_inferior): Take a thread_info pointer instead of a
2762 ptid_t. All callers adjusted.
2763 (exit_inferior): Take an inferior pointer instead of a pid. All
2765 (exit_inferior_silent): New.
2766 (detach_inferior): Delete.
2767 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
2768 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
2769 (detach_inferior_command, kill_inferior_command): Use
2770 find_inferior_id instead of valid_gdb_inferior_id and
2771 gdb_inferior_id_to_pid.
2772 (inferior_command): Use inferior and thread pointers.
2773 * inferior.h (struct thread_info): Forward declare.
2774 (notice_new_inferior): Take a thread_info pointer instead of a
2775 ptid_t. All callers adjusted.
2776 (detach_inferior): Delete declaration.
2777 (exit_inferior, exit_inferior_silent): Take an inferior pointer
2778 instead of a pid. All callers adjusted.
2779 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
2780 (valid_gdb_inferior_id): Delete.
2781 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
2782 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
2783 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
2785 <inf>: ... this new field.
2786 <step_ptid>: Delete, replaced by ...
2787 <step_thread>: ... this new field.
2788 (get_displaced_stepping_state): Take an inferior pointer instead
2789 of a pid. All callers adjusted.
2790 (displaced_step_in_progress_any_inferior): Adjust.
2791 (displaced_step_in_progress_thread): Take a thread pointer instead
2792 of a ptid_t. All callers adjusted.
2793 (displaced_step_in_progress, add_displaced_stepping_state): Take
2794 an inferior pointer instead of a pid. All callers adjusted.
2795 (get_displaced_step_closure_by_addr): Adjust.
2796 (remove_displaced_stepping_state): Take an inferior pointer
2797 instead of a pid. All callers adjusted.
2798 (displaced_step_prepare_throw, displaced_step_prepare)
2799 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
2800 All callers adjusted.
2801 (start_step_over): Adjust.
2802 (infrun_thread_ptid_changed): Remove bit updating ptids in the
2803 displaced step queue.
2804 (do_target_resume): Adjust.
2805 (fetch_inferior_event): Use inferior_thread.
2806 (context_switch, get_inferior_stop_soon): Take an
2807 execution_control_state pointer instead of a ptid_t. All callers
2809 (switch_to_thread_cleanup): Delete.
2810 (stop_all_threads): Use scoped_restore_current_thread.
2811 * inline-frame.c: Include "gdbthread.h".
2812 (inline_state) <inline_state>: Take a thread pointer instead of a
2813 ptid_t. All callers adjusted.
2814 <ptid>: Delete, replaced by ...
2815 <thread>: ... this new field.
2816 (find_inline_frame_state): Take a thread pointer instead of a
2817 ptid_t. All callers adjusted.
2818 (skip_inline_frames, step_into_inline_frame)
2819 (inline_skipped_frames, inline_skipped_symbol): Take a thread
2820 pointer instead of a ptid_t. All callers adjusted.
2821 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
2822 (inline_skipped_frames, inline_skipped_symbol): Likewise.
2823 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
2825 * linux-nat.c (get_detach_signal): Likewise.
2826 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
2827 (thread_db_notice_clone): Adjust.
2828 (thread_db_find_new_threads_silently)
2829 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
2830 a thread pointer instead of a ptid_t. All callers adjusted.
2831 * mi/mi-cmd-var.c: Include "inferior.h".
2832 (mi_cmd_var_update_iter): Update to use thread pointers.
2833 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
2835 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
2837 (mi_output_running): ... this new function.
2838 (mi_on_resume_1): Adjust to use it.
2839 (mi_user_selected_context_changed): Adjust to use inferior_thread.
2840 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
2842 (interrupt_thread_callback): : Adjust to use thread and inferior
2844 * proc-service.c: Include "gdbthread.h".
2845 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
2846 * progspace-and-thread.c: Include "inferior.h".
2847 * progspace.c: Include "inferior.h".
2848 * python/py-exitedevent.c (create_exited_event_object): Adjust to
2849 hold a reference to an inferior_object.
2850 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
2852 * python/py-inferior.c (struct inferior_object): Give the type a
2853 tag name instead of a typedef.
2854 (python_on_normal_stop): No need to check if the current thread is
2856 (inferior_to_inferior_object): Change return type to
2857 inferior_object. All callers adjusted.
2858 (find_thread_object): Delete, bits factored out to ...
2859 (thread_to_thread_object): ... this new function.
2860 * python/py-infthread.c (create_thread_object): Use
2861 inferior_to_inferior_object.
2862 (thpy_is_stopped): Use thread pointer directly.
2863 (gdbpy_selected_thread): Use inferior_thread.
2864 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
2865 field, replaced with ...
2866 <thread>: ... this new field. All users adjusted.
2867 (btpy_insn_or_gap_new): Drop const.
2868 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
2870 * python/py-record.c: Include "gdbthread.h".
2871 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2872 a ptid_t. All callers adjusted.
2873 (gdbpy_current_recording): Use inferior_thread.
2874 * python/py-record.h (recpy_record_object) <ptid>: Delete
2875 field, replaced with ...
2876 <thread>: ... this new field. All users adjusted.
2877 (recpy_element_object) <ptid>: Delete
2878 field, replaced with ...
2879 <thread>: ... this new field. All users adjusted.
2880 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2881 a ptid_t. All callers adjusted.
2882 * python/py-threadevent.c: Include "gdbthread.h".
2883 (get_event_thread): Use thread_to_thread_object.
2884 * python/python-internal.h (struct inferior_object): Forward
2886 (find_thread_object, find_inferior_object): Delete declarations.
2887 (thread_to_thread_object, inferior_to_inferior_object): New
2889 * record-btrace.c: Include "inferior.h".
2890 (require_btrace_thread): Use inferior_thread.
2891 (record_btrace_frame_sniffer)
2892 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
2893 (get_thread_current_frame): Use scoped_restore_current_thread and
2895 (get_thread_current_frame): Use thread pointer directly.
2896 (record_btrace_replay_at_breakpoint): Use thread's inferior
2898 * record-full.c: Include "inferior.h".
2899 * regcache.c: Include "gdbthread.h".
2900 (get_thread_arch_regcache): Use the inferior's address space
2902 (get_thread_regcache, registers_changed_thread): New.
2903 * regcache.h (get_thread_regcache(thread_info *thread)): New
2905 (registers_changed_thread): New.
2906 (remote_target) <remote_detach_1>: Swap order of parameters.
2907 (remote_add_thread): <remote_add_thread>: Return the new thread.
2908 (get_remote_thread_info(ptid_t)): New overload.
2909 (remote_target::remote_notice_new_inferior): Use thread pointers
2911 (remote_target::process_initial_stop_replies): Use
2912 thread_info::set_running.
2913 (remote_target::remote_detach_1, remote_target::detach)
2914 (extended_remote_target::detach): Adjust.
2915 * stack.c (frame_show_address): Use inferior_thread.
2916 * target-debug.h (target_debug_print_thread_info_pp): New.
2917 * target-delegates.c: Regenerate.
2918 * target.c (default_thread_address_space): Delete.
2919 (memory_xfer_partial_1): Use current_inferior.
2920 (target_detach): Use current_inferior.
2921 (target_thread_address_space): Delete.
2922 (generic_mourn_inferior): Use current_inferior.
2923 * target.h (struct target_ops) <thread_address_space>: Delete.
2924 (target_thread_address_space): Delete.
2925 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
2927 (delete_thread_1, delete_thread, delete_thread_silent): Take a
2928 thread pointer instead of a ptid_t. Adjust all callers.
2929 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
2930 (first_thread_of_process): Delete, replaced by ...
2931 (first_thread_of_inferior): ... this new function. All callers
2933 (any_thread_of_process): Rename to ...
2934 (any_thread_of_inferior): ... this, and take an inferior pointer.
2935 (any_live_thread_of_process): Rename to ...
2936 (any_live_thread_of_inferior): ... this, and take an inferior
2938 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2939 (value_in_thread_stack_temporaries)
2940 (get_last_thread_stack_temporary): Take a thread pointer instead
2941 of a ptid_t. Adjust all callers.
2942 (thread_info::set_running): New.
2943 (validate_registers_access): Use inferior_thread.
2944 (can_access_registers_ptid): Rename to ...
2945 (can_access_registers_thread): ... this, and take a thread
2947 (print_thread_info_1): Adjust to compare thread pointers instead
2949 (switch_to_no_thread, switch_to_thread): Make extern.
2950 (scoped_restore_current_thread::~scoped_restore_current_thread):
2951 Use m_thread pointer directly.
2952 (scoped_restore_current_thread::scoped_restore_current_thread):
2953 Use inferior_thread.
2954 (thread_command): Use thread pointer directly.
2955 (thread_num_make_value_helper): Use inferior_thread.
2956 * top.c (execute_command): Use inferior_thread.
2957 * tui/tui-interp.c: Include "inferior.h".
2958 * varobj.c (varobj_create): Use inferior_thread.
2959 (value_of_root_1): Use find_thread_global_id instead of
2960 global_thread_id_to_ptid.
2962 2018-06-21 Alan Hayward <alan.hayward@arm.com>
2964 * regcache.c (readable_regcache::read_part): Avoid memcpy when
2966 (regcache::write_part): Likewise.
2967 (readable_regcache::cooked_read_part): Update comment.
2968 (readable_regcache::cooked_write_part): Likewise.
2969 * regcache.h: (readable_regcache::read_part): Likewise.
2970 (regcache::write_part): Likewise.
2972 2018-06-21 Richard Bunt <richard.bunt@arm.com>
2973 Dirk Schubert <dirk.schubert@arm.com>
2975 * aarch64-linux-nat.c (post_attach): New.
2976 (aarch64_linux_nat_target::post_attach): Override post_attach to
2977 record the number of hardware debug registers.
2979 2018-06-20 Tom Tromey <tom@tromey.com>
2981 * python/py-param.c (add_setshow_generic): Make parameters const.
2982 (parmpy_init): Update.
2984 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2986 * regcache.h (regcache_cooked_read_ftype): Rename to...
2987 (register_read_ftype): ...this, change type to function_view.
2988 (class reg_buffer) <save>: Remove src parameter.
2989 (readonly_detached_regcache) <readonly_detached_regcache>: Make
2990 parameter non-const in first overload. Remove src parameter in
2992 * regcache.c (do_cooked_read): Remove.
2993 (readonly_detached_regcache::readonly_detached_regcache): Make
2994 parameter non-const, adjust call to other constructor.
2995 (reg_buffer::save): Remove src parameter.
2996 * frame.c (do_frame_register_read): Remove.
2997 (frame_save_as_regcache): Use lambda function.
2998 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
2999 parameter to ppu2spu_data *.
3000 (ppu2spu_sniffer): Use lambda function.
3002 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
3004 * record-full.c (record_full_target::insert_breakpoint): Remove
3005 "struct" keyword, add const.
3007 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
3009 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
3010 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
3011 * configure.ac: Remove AC_PREREQ, add missing quoting.
3012 * gnulib/configure.ac: Modernize usage of
3013 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
3014 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
3015 (AUTOMAKE_VERSION): Bump to 1.15.1.
3016 * configure: Re-generate.
3017 * config.in: Re-generate.
3018 * aclocal.m4: Re-generate.
3019 * gnulib/aclocal.m4: Re-generate.
3020 * gnulib/config.in: Re-generate.
3021 * gnulib/configure: Re-generate.
3022 * gnulib/import/Makefile.in: Re-generate.
3024 2018-06-19 Pedro Alves <palves@redhat.com>
3026 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
3027 (lookup_minimal_symbol_by_pc_section): ... here with
3028 gdb_assert_not_reached added.
3030 2018-06-19 Pedro Alves <palves@redhat.com>
3032 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
3033 parameter with a block parameter. Compare location's block symbol
3034 with the frame's block instead of addresses.
3035 (skip_inline_frames): Pass the current block instead of the
3036 frame's address. Break out as soon as we determine the frame
3037 should not be skipped.
3039 2018-06-18 Tom Tromey <tom@tromey.com>
3041 * solib-aix.c (solib_aix_get_section_offsets): Return
3043 (solib_aix_solib_create_inferior_hook): Update.
3045 2018-06-18 Tom Tromey <tom@tromey.com>
3047 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
3049 2018-06-18 Tom Tromey <tom@tromey.com>
3051 * solib-frv.c (frv_relocate_main_executable): Use
3053 * solib-dsbt.c (dsbt_relocate_main_executable): Use
3056 2018-06-18 Tom Tromey <tom@tromey.com>
3058 * objfiles.h (inhibit_section_map_updates): Update.
3059 (resume_section_map_updates, resume_section_map_updates_cleanup):
3061 * solib-svr4.c (svr4_handle_solib_event): Update.
3062 * objfiles.c (inhibit_section_map_updates): Return
3063 scoped_restore_tmpl<int>.
3064 (resume_section_map_updates, resume_section_map_updates_cleanup):
3067 2018-06-18 Tom Tromey <tom@tromey.com>
3069 * valprint.h (read_string): Update.
3070 * valprint.c (read_string): Change type of "buffer".
3071 (val_print_string): Update.
3072 * python/py-value.c (valpy_string): Update.
3073 * language.h (struct language_defn) <la_get_string>: Change
3075 (default_get_string, c_get_string): Update.
3076 * language.c (default_get_string): Change type of "buffer".
3077 * guile/scm-value.c (gdbscm_value_to_string): Update.
3078 * c-lang.c (c_get_string): Change type of "buffer".
3080 2018-06-18 Tom Tromey <tom@tromey.com>
3082 * ser-mingw.c (struct pipe_state_destroyer): New.
3083 (pipe_state_up): New typedef.
3084 (cleanup_pipe_state): Remove.
3085 (pipe_windows_open): Use pipe_state_up. Don't release argv.
3087 2018-06-18 Tom Tromey <tom@tromey.com>
3089 * rust-lang.h (rust_yyerror): Don't declare.
3090 * rust-lang.c (rust_language_defn): Update.
3091 * rust-exp.y (yyerror): Now static.
3092 * parse.c (parse_exp_in_context_1): Update.
3093 * p-lang.h (p_yyerror): Don't declare.
3094 * p-lang.c (p_language_defn): Update.
3095 * p-exp.y (yyerror): Now static.
3096 * opencl-lang.c (opencl_language_defn): Update.
3097 * objc-lang.c (objc_language_defn): Update.
3098 * m2-lang.h (m2_yyerror): Don't declare.
3099 * m2-lang.c (m2_language_defn): Update.
3100 * m2-exp.y (yyerror): Now static.
3101 * language.h (struct language_defn) <la_error>: Remove.
3102 * language.c (unk_lang_error): Remove.
3103 (unknown_language_defn, auto_language_defn): Remove.
3104 * go-lang.h (go_yyerror): Don't declare.
3105 * go-lang.c (go_language_defn): Update.
3106 * go-exp.y (yyerror): Now static.
3107 * f-lang.h (f_yyerror): Don't declare.
3108 * f-lang.c (f_language_defn): Update.
3109 * f-exp.y (yyerror): Now static.
3110 * d-lang.h (d_yyerror): Don't declare.
3111 * d-lang.c (d_language_defn): Update.
3112 * d-exp.y (yyerror): Now static.
3113 * c-lang.h (c_yyerror): Don't declare.
3114 * c-lang.c (c_language_defn, cplus_language_defn)
3115 (asm_language_defn, minimal_language_defn): Update.
3116 * c-exp.y (yyerror): Now static.
3117 * ada-lang.h (ada_yyerror): Don't declare.
3118 * ada-lang.c (ada_language_defn): Update.
3119 * ada-exp.y (yyerror): Now static.
3121 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3123 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
3124 (store_sveregs_to_thread): Likewise.
3125 (aarch64_linux_fetch_inferior_registers): Check for SVE.
3126 (aarch64_linux_store_inferior_registers): Likewise.
3127 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
3129 (aarch64_sve_regs_copy_to_regcache): Likewise.
3130 (aarch64_sve_regs_copy_from_regcache): Likewise.
3131 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
3133 (aarch64_sve_regs_copy_to_regcache): Likewise.
3134 (aarch64_sve_regs_copy_from_regcache): Likewise.
3135 (sve_context): Structure from Linux headers.
3136 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
3137 (SVE_SIG_ZREG_SIZE): Likewise.
3138 (SVE_SIG_PREG_SIZE): Likewise.
3139 (SVE_SIG_FFR_SIZE): Likewise.
3140 (SVE_SIG_REGS_OFFSET): Likewise.
3141 (SVE_SIG_ZREGS_OFFSET): Likewise.
3142 (SVE_SIG_ZREG_OFFSET): Likewise.
3143 (SVE_SIG_ZREGS_SIZE): Likewise.
3144 (SVE_SIG_PREGS_OFFSET): Likewise.
3145 (SVE_SIG_PREG_OFFSET): Likewise.
3146 (SVE_SIG_PREGS_SIZE): Likewise.
3147 (SVE_SIG_FFR_OFFSET): Likewise.
3148 (SVE_SIG_REGS_SIZE): Likewise.
3149 (SVE_SIG_CONTEXT_SIZE): Likewise.
3150 (SVE_PT_REGS_MASK): Likewise.
3151 (SVE_PT_REGS_FPSIMD): Likewise.
3152 (SVE_PT_REGS_SVE): Likewise.
3153 (SVE_PT_VL_INHERIT): Likewise.
3154 (SVE_PT_VL_ONEXEC): Likewise.
3155 (SVE_PT_REGS_OFFSET): Likewise.
3156 (SVE_PT_FPSIMD_OFFSET): Likewise.
3157 (SVE_PT_FPSIMD_SIZE): Likewise.
3158 (SVE_PT_SVE_ZREG_SIZE): Likewise.
3159 (SVE_PT_SVE_PREG_SIZE): Likewise.
3160 (SVE_PT_SVE_FFR_SIZE): Likewise.
3161 (SVE_PT_SVE_FPSR_SIZE): Likewise.
3162 (SVE_PT_SVE_FPCR_SIZE): Likewise.
3163 (__SVE_SIG_TO_PT): Likewise.
3164 (SVE_PT_SVE_OFFSET): Likewise.
3165 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
3166 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
3167 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
3168 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
3169 (SVE_PT_SVE_PREG_OFFSET): Likewise.
3170 (SVE_PT_SVE_PREGS_SIZE): Likewise.
3171 (SVE_PT_SVE_FFR_OFFSET): Likewise.
3172 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
3173 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
3174 (SVE_PT_SVE_SIZE): Likewise.
3175 (SVE_PT_SIZE): Likewise.
3176 (HAS_SVE_STATE): New define.
3178 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3180 * nat/aarch64-sve-linux-sigcontext.h: New file.
3181 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
3183 (SVE_VQ_MIN): Likewise.
3184 (SVE_VQ_MAX): Likewise.
3185 (SVE_VL_MIN): Likewise.
3186 (SVE_VL_MAX): Likewise.
3187 (SVE_NUM_ZREGS): Likewise.
3188 (SVE_NUM_PREGS): Likewise.
3189 (sve_vl_valid): Likewise.
3190 (struct user_sve_header): Likewise.
3192 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
3193 Richard Bunt <Richard.Bunt@arm.com>
3195 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
3196 was requested by GDB.
3198 2018-06-15 Tom de Vries <tdevries@suse.de>
3200 * MAINTAINERS (Write After Approval): Add Tom de Vries.
3202 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
3204 * gnulib/update-gnulib.sh: Print expected versions of
3207 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
3209 * arch-utils.c (default_type_align): Use type_length_units.
3210 * gdbtypes.c (type_align): Use type_length_units.
3212 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3214 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
3215 of 'define' command.
3217 2018-06-14 Tom de Vries <tdevries@suse.de>
3220 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
3221 get_no_prettyformat_print_options.
3223 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
3225 * sparc-nat.h: Include target.h.
3226 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
3227 <fetch_registers>: Remove this argument in function call.
3228 <store_registers>: Remove this argument in function call, remove
3230 <low_forget_process>: Call sparc64_forget_process instead of
3231 sparc_forget_process.
3233 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3235 * procfs.c (_initialize_procfs): Use add_inf_child_target.
3236 (procfs_target::make_corefile_notes): Adjust to new
3237 target_read_alloc return type.
3239 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3240 Stephen Roberts <stephen.roberts@arm.com>
3243 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
3244 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
3245 Move should_notify_stop local into more inner scope.
3247 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3248 Stephen Roberts <stephen.roberts@arm.com>
3251 * infrun.c (resume_1): Add call to mark_async_event_handler.
3253 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3255 * infrun.c (do_target_wait): Change old version of $pc printed.
3257 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
3259 * dwarf2read.c (read_index_from_section): Rename to...
3260 (read_gdb_index_from_section): ... this, update all callers.
3261 (dwarf2_read_index): Rename to...
3262 (dwarf2_read_gdb_index): ... this, update all callers.
3264 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
3266 * gdb/hppa-linux-nat.c
3267 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
3268 hppa_linux_nat_target::fetch_registers.
3270 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3272 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
3273 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
3274 (AARCH64_DWARF_SVE_FFR): Likewise.
3275 (AARCH64_DWARF_SVE_P0): Likewise.
3276 (AARCH64_DWARF_SVE_Z0): Likewise.
3278 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3280 * common/common-regcache.h (raw_compare): New function.
3281 * regcache.c (regcache::raw_compare): Likewise.
3282 * regcache.h (regcache::raw_compare): New declaration.
3284 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3286 * common/common-regcache.h (reg_buffer_common): New structure.
3287 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
3288 (reg_buffer::raw_supply): Likewise.
3289 (reg_buffer::raw_supply_integer): Likewise.
3290 (reg_buffer::raw_supply_zeroed): Likewise.
3291 (reg_buffer::raw_collect): Likewise.
3292 (reg_buffer::raw_collect_integer): Likewise.
3293 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
3294 (reg_buffer::raw_supply): Likewise.
3295 (reg_buffer::raw_supply_integer): Likewise.
3296 (reg_buffer::raw_supply_zeroed): Likewise.
3297 (reg_buffer::raw_collect): Likewise.
3298 (reg_buffer::raw_collect_integer): Likewise.
3300 2018-06-10 Tom Tromey <tom@tromey.com>
3302 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
3303 (class remote_state) <stop_reply_queue>: Now std::vector.
3304 (remote_state::~remote_state)
3305 (remote_target::stop_reply_queue_length): Update.
3306 (struct queue_iter_param, remove_child_of_pending_fork)
3307 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
3308 (check_pending_event_prevents_wildcard_vcont_callback)
3309 (remove_stop_reply_for_inferior)
3310 (remove_stop_reply_of_remote_state)
3311 (remote_notif_remove_once_on_match)
3312 (stop_reply_match_ptid_and_ws)
3313 (remote_kill_child_of_pending_fork): Remove.
3314 (remote_target::remove_new_fork_children)
3315 (remote_target::check_pending_events_prevent_wildcard_vcont)
3316 (remote_target::discard_pending_stop_replies)
3317 (remote_target::discard_pending_stop_replies_in_queue)
3318 (remote_target::remote_notif_remove_queued_reply)
3319 (remote_target::queued_stop_reply)
3320 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
3321 (remote_target::wait, remote_target::kill_new_fork_children)
3322 (remote_target::async): Update.
3324 2018-06-10 Tom Tromey <tom@tromey.com>
3326 * record-full.c (record_full_arch_list_cleanups): Remove.
3327 (record_full_message): Use try/catch.
3328 (record_full_wait_cleanups): Remove.
3329 (record_full_wait_1): Use try/catch.
3330 (record_full_restore): Likewise.
3332 2018-06-10 Tom Tromey <tom@tromey.com>
3334 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
3335 declare VEC. Add constructor.
3336 <in_target_beneath>: Now bool.
3337 (record_full_breakpoints): Now a std::vector, static.
3338 (record_full_sync_record_breakpoints)
3339 (record_full_init_record_breakpoints)
3340 (record_full_target::insert_breakpoint)
3341 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
3343 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
3345 * dwarf2read.c (process_cu_includes): Remove struct keyword.
3346 * serial.c (serial_interface_lookup): Remove struct keyword.
3348 2018-06-10 Tom Tromey <tom@tromey.com>
3350 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
3352 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
3354 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
3356 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
3357 "beneath" as a method.
3358 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
3359 Use "beneath" as a method.
3361 2018-06-10 Tom Tromey <tom@tromey.com>
3363 * tracefile.c (struct trace_file_writer_deleter): New.
3364 <operator()>: Rename from trace_file_writer_xfree.
3365 (trace_file_writer_up): New typedef.
3366 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
3368 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3370 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
3371 <m_registers, m_register_status>: Change type to
3373 * regcache.c (reg_buffer::reg_buffer): Use new instead of
3376 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3378 * common/common-regcache.h (enum register_status): Add
3379 underlying type "signed char".
3380 * regcache.h (reg_buffer) <m_register_status>: Change type to
3382 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
3383 register_status instead of signed char.
3384 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
3385 (reg_buffer::get_register_status): Remove cast.
3386 (readable_regcache::raw_read): Remove cast.
3387 (readable_regcache::cooked_read): Remove cast.
3389 2018-06-09 Tom Tromey <tom@tromey.com>
3391 * source.c (reverse_search_command, forward_search_command): Use
3394 2018-06-09 Tom Tromey <tom@tromey.com>
3396 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
3397 (serial_ops_list): Now static, std::vector.
3398 (serial_interface_lookup, serial_add_interface): Update.
3400 2018-06-09 Tom Tromey <tom@tromey.com>
3402 * dwarf2read.c (process_cu_includes): Update.
3403 (process_full_comp_unit): Update.
3404 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
3407 2018-06-08 Paul Koning <paul_koning@dell.com>
3411 * python/python.c (do_start_initialization):
3412 Avoid call to internal Python API.
3413 (init__gdb_module): New function.
3415 2018-06-08 Gary Benson <gbenson@redhat.com>
3417 * linux-thread-db.c (valprint.h): New include.
3418 (struct check_thread_db_info): New structure.
3419 (check_thread_db_on_load, tdb_testinfo): New static globals.
3420 (check_thread_db, check_thread_db_callback): New functions.
3421 (try_thread_db_load_1): Run integrity checks if requested.
3422 (maintenance_check_libthread_db): New function.
3423 (_initialize_thread_db): Register "maint check libthread-db"
3424 and "maint set/show check-libthread-db".
3425 * NEWS: Mention the above new commands.
3427 2018-06-08 Tom Tromey <tom@tromey.com>
3429 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
3432 2018-06-08 Tom Tromey <tom@tromey.com>
3434 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
3436 2018-06-08 Tom Tromey <tom@tromey.com>
3438 * common/btrace-common.h (struct btrace_data): Add constructor,
3439 destructor, move assignment operator.
3440 <empty, clear, fini>: New methods.
3441 <format>: Initialize.
3442 (btrace_data_init, btrace_data_fini, btrace_data_clear)
3443 (btrace_data_empty): Don't declare.
3444 * common/btrace-common.c (btrace_data_init): Remove.
3445 (btrace_data::fini): Rename from btrace_data_fini.
3446 (btrace_data::empty): Rename from btrace_data_empty.
3447 (btrace_data::clear): Rename from btrace_data_clear. Return
3449 * btrace.h (make_cleanup_btrace_data): Don't declare.
3450 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
3451 (parse_xml_btrace): Update.
3452 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
3453 (maint_btrace_clear_packet_history_cmd): Update.
3455 2018-06-07 Pedro Alves <palves@redhat.com>
3457 * target.h (target_ops) <beneath>: Now a method. All references
3459 (class target_stack): New.
3460 * target.c (g_target_stack): New.
3461 (g_current_top_target): Delete.
3462 (current_top_target): Get the top target out of g_target_stack.
3463 (target_stack::push, target_stack::unpush): New.
3464 (push_target, unpush_target): Reimplement.
3465 (target_is_pushed): Reimplement in terms of g_target_stack.
3466 (target_ops::beneath, target_stack::find_beneath): New.
3468 2018-06-07 Pedro Alves <palves@redhat.com>
3470 * target.h (find_target_beneath): Delete declaration.
3471 * target.c (find_target_beneath): Delete definition.
3472 * aix-thread.c: All callers of find_target_beneath adjusted to
3473 call target_ops::beneath instead.
3474 * bsd-uthread.c: Likewise.
3475 * linux-thread-db.c: Likewise.
3476 * ravenscar-thread.c: Likewise.
3477 * sol-thread.c: Likewise.
3478 * spu-multiarch.c: Likewise.
3480 2018-06-07 Pedro Alves <palves@redhat.com>
3482 * target.h (target_ops) <beneath>: Now a method. All references
3484 (target_ops) <m_beneath>: New.
3485 * target.c (target_ops::beneath): New.
3486 * corelow.c: Adjust all references to target_ops::beneath.
3487 * linux-thread-db.c: Likewise.
3488 * make-target-delegates: Likewise.
3489 * record-btrace.c: Likewise.
3490 * record-full.c: Likewise.
3491 * remote.c: Likewise.
3492 * target.c: Likewise.
3493 * target-delegates.c: Regenerate.
3495 2018-06-07 Pedro Alves <palves@redhat.com>
3497 * target.h (target_stack): Delete.
3498 (current_top_target): Declare function.
3499 * target.c (target_stack): Delete.
3500 (g_current_top_target): New.
3501 (current_top_target): New function.
3502 * auxv.c: Use current_top_target instead of target_stack
3504 * avr-tdep.c: Likewise.
3505 * breakpoint.c: Likewise.
3506 * corefile.c: Likewise.
3507 * elfread.c: Likewise.
3509 * exceptions.c: Likewise.
3510 * frame.c: Likewise.
3511 * gdbarch-selftests.c: Likewise.
3512 * gnu-v3-abi.c: Likewise.
3513 * ia64-tdep.c: Likewise.
3514 * ia64-vms-tdep.c: Likewise.
3515 * infcall.c: Likewise.
3516 * infcmd.c: Likewise.
3517 * infrun.c: Likewise.
3518 * linespec.c: Likewise.
3519 * linux-tdep.c: Likewise.
3520 * minsyms.c: Likewise.
3521 * ppc-linux-nat.c: Likewise.
3522 * ppc-linux-tdep.c: Likewise.
3523 * procfs.c: Likewise.
3524 * regcache.c: Likewise.
3525 * remote.c: Likewise.
3526 * rs6000-tdep.c: Likewise.
3527 * s390-linux-nat.c: Likewise.
3528 * s390-tdep.c: Likewise.
3529 * solib-aix.c: Likewise.
3530 * solib-darwin.c: Likewise.
3531 * solib-dsbt.c: Likewise.
3532 * solib-spu.c: Likewise.
3533 * solib-svr4.c: Likewise.
3534 * solib-target.c: Likewise.
3535 * sparc-tdep.c: Likewise.
3536 * sparc64-tdep.c: Likewise.
3537 * spu-tdep.c: Likewise.
3538 * symfile.c: Likewise.
3539 * symtab.c: Likewise.
3540 * target-descriptions.c: Likewise.
3541 * target-memory.c: Likewise.
3542 * target.c: Likewise.
3543 * target.h: Likewise.
3544 * tracefile-tfile.c: Likewise.
3545 * tracepoint.c: Likewise.
3546 * valops.c: Likewise.
3547 * valprint.c: Likewise.
3548 * value.c: Likewise.
3549 * windows-tdep.c: Likewise.
3550 * mi/mi-main.c: Likewise.
3552 2018-06-07 Tom Tromey <tom@tromey.com>
3554 * valprint.h (build_address_symbolic): Declare.
3555 * printcmd.c (print_address_symbolic): Update.
3556 (build_address_symbolic): Change "name" and "filename" to
3558 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
3560 * defs.h (build_address_symbolic): Remove declaration.
3562 2018-06-07 Alan Hayward <alan.hayward@arm.com>
3564 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
3565 (aarch64_vnv_type): Add function.
3566 (aarch64_pseudo_register_name): Add V regs for SVE.
3567 (aarch64_pseudo_register_type): Likewise.
3568 (aarch64_pseudo_register_reggroup_p): Likewise.
3569 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
3570 (aarch64_pseudo_read_value): Add V regs for SVE.
3571 (aarch64_pseudo_write_2): Use V0 offset for SVE
3572 (aarch64_pseudo_write): Add V regs for SVE.
3573 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
3575 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
3577 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
3578 (sve_vl_from_vq): Likewise.
3580 2018-06-05 Tom Tromey <tom@tromey.com>
3582 * cli/cli-cmds.c (show_version): Update.
3583 * top.c (print_gdb_version): Add "interactive" parameter.
3585 * main.c (captured_main_1): Update.
3586 * top.h (print_gdb_version): Add "interactive" parameter and a
3589 2018-06-05 David Malcolm <dmalcolm@redhat.com>
3591 * common/enum-flags.h: Add trailing semicolon to example in
3594 2018-06-05 Tom Tromey <tom@tromey.com>
3597 * NEWS: Add entry about pager.
3598 * utils.c (pagination_disabled_for_command): New global.
3599 (prompt_for_continue): Allow "c" response to prompt.
3600 (reinitialize_more_filter): Clear
3601 pagination_disabled_for_command.
3602 (fputs_maybe_filtered): Check pagination_disabled_for_command.
3604 2018-06-04 Tom Tromey <tom@tromey.com>
3606 * ada-lang.h (ada_lookup_symbol_list): Update.
3607 * ada-lang.c (resolve_subexp): Update.
3608 (symbols_are_identical_enums): Change type of syms. Remove nsyms
3610 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
3611 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
3612 results parameter to std::vector.
3613 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
3615 * ada-exp.y (block_lookup): Update.
3616 (select_possible_type_sym): Change type of syms. Remove nsyms
3618 (write_var_or_type, write_name_assoc): Update.
3620 2018-06-04 Joel Brobecker <brobecker@adacore.com>
3622 * windows-nat.c (windows_nat_target::xfer_partial): Return
3623 TARGET_XFER_E_IO if we need to delegate to the target beneath
3624 but BENEATH is NULL.
3626 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3628 * Makefile.in (config.status): Add configure.nat as a
3631 2018-06-04 Tom Tromey <tom@tromey.com>
3633 * cp-name-parser.y (cpname_state): Add method declarations.
3634 (HANDLE_QUAL): Update.
3635 (cpname_state::d_grab, cpname_state::fill_comp)
3636 (cpname_state::make_operator, cpname_state::make_dtor)
3637 (cpname_state::make_builtin_type, cpname_state::make_name)
3638 (cpname_state::d_qualify, cpname_state::d_int_type)
3639 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3640 (%union): Move earlier.
3642 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3644 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3646 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3648 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3649 (aarch64_pseudo_write_1): Likewise.
3650 (aarch64_pseudo_read_value): Use helper.
3651 (aarch64_pseudo_write): Likewise.
3653 2018-06-04 Pedro Alves <palves@redhat.com>
3655 * darwin-nat.c (darwin_ops): Delete.
3656 (darwin_attach_pid): Use get_native_target.
3658 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3660 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3661 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3663 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3665 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3666 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3667 (aarch64_gdbarch_init): Check for SVE.
3668 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3670 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3672 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3673 * aarch64-tdep.h (aarch64_read_description): Likewise.
3674 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3675 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3676 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3677 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3678 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3680 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3682 * value.c (value_fetch_lazy_bitfield): New.
3683 (value_fetch_lazy_memory): New.
3684 (value_fetch_lazy_register): New.
3685 (value_fetch_lazy): Factor out to smaller functions.
3687 2018-06-01 Tom Tromey <tom@tromey.com>
3689 * cp-name-parser.y (backslashable, represented): Now const.
3691 2018-06-01 Tom Tromey <tom@tromey.com>
3693 * cp-name-parser.y: Include parser-defs.h.
3694 (parser_fprintf): Remove declaration.
3696 2018-06-01 Tom Tromey <tom@tromey.com>
3698 * cp-name-parser.y: Use %pure-parser, %lex-param, and
3700 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
3701 (global_result): Remove globals.
3702 (struct cpname_state): New.
3703 (yyparse): Don't declare.
3704 (yylex, yyerror): Move declarations after %union.
3705 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
3706 (make_name): Add state parameter.
3708 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
3710 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
3712 (yylex): Add lvalp, state parameters.
3713 (yyerror): Add state parameter.
3714 (cp_demangled_name_to_comp): Update.
3716 2018-06-01 Tom Tromey <tom@tromey.com>
3718 * cp-name-parser.y (parser_fprintf): Declare.
3719 (GDB_YY_REMAP_PREFIX): Define.
3720 Include yy-remap.h. Don't redefine yy* identifiers.
3722 2018-06-01 Tom Tromey <tom@tromey.com>
3724 * python/py-type.c (typy_legacy_template_argument): Update.
3725 * cp-support.h (cp_demangled_name_to_comp): Update.
3726 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
3727 parameter to be a "std::string *".
3730 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
3732 * ada-lex.l: Include "diagnostics.h" instead of
3733 "common/diagnostics.h".
3734 * unittests/environ-selftests.c: Likewise.
3735 * common/diagnostics.h: Moved to ../include.
3737 2018-06-01 Joel Brobecker <brobecker@adacore.com>
3739 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
3740 to language_mode_manual while calling breakpoint_re_set_one.
3742 2018-06-01 Tom Tromey <tom@tromey.com>
3744 * valops.c (value_cast_structs, destructor_name_p): Update.
3745 * symtab.c (gdb_mangle_name): Update.
3746 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
3748 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
3749 (pascal_object_print_value_fields, pascal_object_print_value):
3751 * p-typeprint.c (pascal_type_print_derivation_info): Update.
3752 * linespec.c (find_methods): Update.
3753 * gdbtypes.h (type_name_no_tag): Remove.
3754 (type_name_or_error): Rename from type_name_no_tag_or_error.
3755 * gdbtypes.c (type_name_no_tag): Remove.
3756 (type_name_or_error): Rename from type_name_no_tag_or_error.
3757 (lookup_struct_elt_type, check_typedef): Update.
3758 * expprint.c (print_subexp_standard): Update.
3759 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
3760 * d-namespace.c (d_lookup_nested_symbol): Update.
3761 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
3762 (cp_print_class_member): Update.
3763 * cp-namespace.c (cp_lookup_nested_symbol): Update.
3764 * completer.c (add_struct_fields): Update.
3765 * c-typeprint.c (cp_type_print_derivation_info)
3766 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
3768 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
3769 (ada_prefer_type, ada_is_exception_sym): Update.
3771 2018-06-01 Tom Tromey <tom@tromey.com>
3773 * valops.c (enum_constant_from_type, value_namespace_elt)
3774 (value_maybe_namespace_elt): Update.
3775 * valarith.c (find_size_for_pointer_math): Update.
3776 * target-descriptions.c (make_gdb_type): Update.
3777 * symmisc.c (print_symbol): Update.
3778 * stabsread.c (define_symbol, read_type)
3779 (complain_about_struct_wipeout, add_undefined_type)
3780 (cleanup_undefined_types_1): Update.
3781 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
3782 (rust_range_type_p, val_print_struct, rust_print_struct_def)
3783 (rust_internal_print_type, rust_composite_type)
3784 (rust_evaluate_funcall, rust_evaluate_subexp)
3785 (rust_inclusive_range_type_p): Update.
3786 * python/py-type.c (typy_get_tag): Update.
3787 * p-typeprint.c (pascal_type_print_base): Update.
3788 * mdebugread.c (parse_symbol, parse_type): Update.
3789 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
3791 * guile/scm-type.c (gdbscm_type_tag): Update.
3792 * go-lang.c (sixg_string_p): Update.
3793 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
3795 * gdbtypes.h (struct main_type) <tag_name>: Remove.
3796 (TYPE_TAG_NAME): Remove.
3797 * gdbtypes.c (type_name_no_tag): Simplify.
3798 (check_typedef, check_types_equal, recursive_dump_type)
3799 (copy_type_recursive, arch_composite_type): Update.
3800 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
3801 in summary mode when needed.
3802 * eval.c (evaluate_funcall): Update.
3803 * dwarf2read.c (fixup_go_packaging, read_structure_type)
3804 (process_structure_scope, read_enumeration_type)
3805 (read_namespace_type, read_module_type, determine_prefix): Update.
3806 * cp-support.c (inspect_type): Update.
3807 * coffread.c (process_coff_symbol, decode_base_type): Update.
3808 * c-varobj.c (c_is_path_expr_parent): Update.
3809 * c-typeprint.c (c_type_print_base_struct_union): Update.
3810 (c_type_print_base_1): Update. Print struct/class/union/enum in
3811 summary when using C language.
3812 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
3813 (gen_maybe_namespace_elt): Update.
3814 * ada-lang.c (ada_type_name): Simplify.
3815 (empty_record, ada_template_to_fixed_record_type_1)
3816 (template_to_static_fixed_type)
3817 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
3819 2018-06-01 Tom Tromey <tom@tromey.com>
3821 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
3823 * c-typeprint.c (c_print_type_1): Add "language" parameter.
3824 (c_print_type): Update.
3825 (c_print_type): New overload.
3826 (c_type_print_varspec_prefix, c_type_print_args)
3827 (c_type_print_varspec_suffix, c_print_type_no_offsets)
3828 (c_type_print_base_struct_union, c_type_print_base_1)
3829 (cp_type_print_method_args): Add "language" parameter.
3830 (c_type_print_base): Update.
3831 * c-lang.h (c_print_type): Add new overload.
3833 2018-06-01 Tom Tromey <tom@tromey.com>
3835 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
3836 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
3838 2018-06-01 Alan Hayward <alan.hayward@arm.com>
3840 * aarch64-tdep.c (aarch64_sve_register_names): New const
3842 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
3843 (AARCH64_SVE_Z_REGS_NUM): New define.
3844 (AARCH64_SVE_P_REGS_NUM): Likewise.
3845 (AARCH64_SVE_NUM_REGS): Likewise.
3847 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
3849 * nat/linux-ptrace.h [__alpha__]
3850 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
3853 2018-05-31 Maciej W. Rozycki <macro@mips.com>
3855 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
3856 the endianness selected.
3857 * NEWS: Document `set endian auto' mode operation update.
3859 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3861 * Makefile.in: Add new header.
3862 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
3863 (sve_vl_from_vg): Likewise.
3864 (sve_vq_from_vl): Likewise.
3865 (sve_vl_from_vq): Likewise.
3866 (sve_vq_from_vg): Likewise.
3867 (sve_vg_from_vq): Likewise.
3868 * configure.nat: Add new c file.
3869 * nat/aarch64-sve-linux-ptrace.c: New file.
3870 * nat/aarch64-sve-linux-ptrace.h: New file.
3872 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3874 * aarch64-linux-nat.c (aarch64_linux_read_description):
3876 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
3878 * aarch64-tdep.c (tdesc_aarch64_list): Add.
3879 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
3880 (aarch64_gdbarch_init): Add parmeter zero.
3881 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
3882 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
3883 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
3885 * doc/gdb.texinfo: Describe SVE feature
3886 * features/aarch64-sve.c: New file.
3888 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
3891 * gdbarch.sh (significant_addr_bit): Default to zero when
3892 not set by target architecture.
3893 * gdbarch.c: Re-generated.
3894 * utils.c (address_significant): Update.
3896 2018-05-30 Joel Brobecker <brobecker@adacore.com>
3898 * stack.c (func_command): Remove trailing newline in call to error.
3900 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3902 * regcache.h (regcache_raw_collect): Remove, update callers to
3903 use regcache::raw_collect.
3904 * regcache.c (regcache_raw_collect): Remove.
3906 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3908 * regcache.h (regcache_raw_supply): Remove, update callers to
3909 use detached_regcache::raw_supply.
3910 * regcache.c (regcache_raw_supply): Remove.
3912 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3914 * regcache.h (regcache_cooked_write_part): Remove, update
3915 callers to use regcache::cooked_write_part.
3916 * regcache.c (regcache_cooked_write_part): Remove.
3918 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3920 * regcache.h (regcache_cooked_read_part): Remove, update callers
3921 to use readable_regcache::cooked_read_part.
3922 * regcache.c (regcache_cooked_read_part): Remove.
3924 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3926 * regcache.h (regcache_cooked_read_value): Remove, update
3927 callers to use readable_regcache::cooked_read_value.
3928 * regcache.c (regcache_cooked_read_value): Remove.
3930 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3932 * regcache.h (regcache_cooked_write): Remove, update callers to
3933 use regcache::cooked_write.
3934 * regcache.c (regcache_cooked_write): Remove.
3936 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3938 * regcache.h (regcache_invalidate): Remove, update callers to
3939 use detached_regcache::invalidate instead.
3940 * regcache.c (regcache_invalidate): Remove.
3942 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3944 * regcache.h (regcache_raw_write_part): Remove, update callers
3945 to use regcache::raw_write_part instead.
3946 * regcache.c (regcache_raw_write_part): Remove.
3948 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3950 * regcache.h (regcache_raw_read_part): Remove, update callers to
3951 use readable_regcache::raw_read_part instead.
3952 * regcache.c (regcache_raw_read_part): Remove.
3954 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3956 * regcache.h (regcache_cooked_read): Remove, update callers to
3957 use readable_regcache::cooked_read instead.
3958 * regcache.c (regcache_cooked_read): Remove.
3960 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3962 * regcache.h (regcache_raw_write): Remove, update callers to use
3963 regcache::raw_write instead.
3964 * regcache.c (regcache_raw_write): Remove.
3966 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3968 * regcache.h (regcache_raw_read): Remove, update callers to use
3969 readable_regcache::raw_read instead.
3970 * regcache.c (regcache_raw_read): Remove.
3972 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3974 * regcache.h (regcache_raw_update): Remove, update callers to
3975 use readable_regcache::raw_update instead.
3976 * regcache.c (regcache_raw_update): Remove.
3978 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3980 * regcache.h (regcache_register_status): Remove, update callers
3981 to use reg_buffer::get_register_status directly instead.
3982 * regcache.c (regcache_register_status): Remove.
3984 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3986 * regcache.h (regcache_get_ptid): Remove, update all callers to
3987 call regcache::ptid instead.
3988 * regcache.c (regcache_get_ptid): Remove.
3990 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3992 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
3994 2018-05-30 Pedro Alves <palves@redhat.com>
3996 * common/common-exceptions.h (exception_rethrow): Use
3999 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
4001 * breakpoint.c (print_solib_event, check_status_catch_solib):
4002 Remove struct keyword in range-based for loops.
4003 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
4004 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
4006 * linespec.c (find_superclass_methods, search_minsyms_for_name):
4008 * symfile.c (addr_info_make_relative): Likewise.
4009 * thread.c (value_in_thread_stack_temporaries): Likewise.
4011 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
4014 * valops.c (value_struct_elt_for_reference): Call check_typedef on
4015 aggregate type to get its real type before accessing it.
4017 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
4019 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
4020 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
4021 * coff-pe-read.c (add_pe_forwarded_sym): Replace
4022 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
4023 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
4024 * jit.c (jit_breakpoint_re_set_internal): Likewise.
4025 * printcmd.c (info_address_command): Likewise.
4027 2018-05-29 Tom Tromey <tom@tromey.com>
4029 * windows-nat.c (handle_exception): Update fall-through comment.
4031 2018-05-29 Tom Tromey <tom@tromey.com>
4033 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
4034 (struct program_space) <added_solibs>: Now a std::vector.
4035 * breakpoint.c (print_solib_event): Update.
4036 (check_status_catch_solib): Update.
4037 * progspace.c (clear_program_space_solib_cache): Update.
4038 * solib.c (update_solib_list): Update.
4040 2018-05-29 Tom Tromey <tom@tromey.com>
4042 * python/py-type.c (typy_richcompare): Update.
4043 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
4044 * gdbtypes.h (types_deeply_equal): Return bool.
4045 (types_equal): Likewise.
4046 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
4048 (check_types_equal): Change worklist to std::vector. Return
4050 (struct type_equality_entry): Add constructor.
4051 (compare_maybe_null_strings): Return bool.
4052 (check_types_worklist): Return bool. Change worklist to
4054 (types_deeply_equal): Use std::vector.
4055 (types_equal): Return bool.
4056 (compare_maybe_null_strings): Simplify.
4058 2018-05-29 Tom Tromey <tom@tromey.com>
4060 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
4062 2018-05-29 Tom Tromey <tom@tromey.com>
4064 * objc-lang.h: Don't include cp-support.h.
4065 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
4068 2018-05-27 Tom Tromey <tom@tromey.com>
4070 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
4072 2018-05-25 Tom Tromey <tom@tromey.com>
4074 * value.c (value::location): Initialize.
4076 2018-05-25 Tom Tromey <tom@tromey.com>
4078 * dbxread.c (init_bincl_list): Remove.
4079 (bincl_list): Now a std::vector.
4080 (bincls_allocated, next_bincl): Remove.
4081 (free_bincl_list, do_free_bincl_list_cleanup)
4082 (make_cleanup_free_bincl_list): Remove.
4083 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
4085 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
4086 (struct header_file_location): Add constructor.
4087 (add_bincl_to_list): Remove.
4089 2018-05-25 Tom Tromey <tom@tromey.com>
4091 * tui/tui.c (tui_enable): Update.
4092 * mi/mi-interp.c (mi_interp::init): Update.
4093 * interps.h (class interp) <name>: New method.
4094 <m_name>: Rename from name.
4095 (~scoped_restore_interp): Update.
4096 * interps.c (interp::interp): Update.
4097 (interp_add, interp_set, interp_lookup_existing)
4098 (current_interp_named_p): Update.
4100 2018-05-25 Tom Tromey <tom@tromey.com>
4102 * interps.c (interp_name): Remove.
4103 * mi/mi-interp.c (mi_interp::init): Update.
4104 * interps.h (interp_name): Remove.
4105 (~scoped_restore_interp): Update.
4106 * tui/tui.c (tui_enable): Update.
4108 2018-05-25 Tom Tromey <tom@tromey.com>
4110 * utils.c (fputs_maybe_filtered): Update.
4111 * linespec.c (decode_line_full): Update.
4112 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
4113 (mi_print_breakpoint_for_event, mi_solib_loaded)
4114 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4115 (mi_user_selected_context_changed): Update.
4116 * mi/mi-main.c (mi_execute_command): Update.
4117 * cli/cli-script.c (execute_control_command): Update.
4118 * python/python.c (execute_gdb_command): Update.
4119 * solib.c (info_sharedlibrary_command): Update.
4120 * interps.c (interp_ui_out): Remove.
4121 * interps.h (interp_ui_out): Remove.
4123 2018-05-25 Tom Tromey <tom@tromey.com>
4125 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
4126 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
4127 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
4129 2018-05-25 Tom Tromey <tom@tromey.com>
4131 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
4132 * interps.c (interp_exec): Use scoped_restore.
4134 2018-05-25 Tom Tromey <tom@tromey.com>
4136 * remote.c (remote_target::remote_file_get): Use
4138 (remote_target::remote_file_put): Likewise.
4140 2018-05-25 Tom Tromey <tom@tromey.com>
4142 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
4144 (get_pe_section_index, add_pe_exported_sym): Update.
4145 (read_pe_exported_syms): Use gdb::def_vector.
4147 2018-05-25 Tom Tromey <tom@tromey.com>
4149 * frame.c (remove_prev_frame): Remove.
4150 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
4152 2018-05-25 Maciej W. Rozycki <macro@mips.com>
4154 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
4156 * mips-linux-nat.c (supply_fpregset): Always call
4157 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
4158 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
4159 `mips_fill_fpregset'.
4160 * mips-linux-tdep.c (mips_supply_fpregset)
4161 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
4162 (mips_fill_fpregset_wrapper): Remove functions.
4163 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
4164 (mips_linux_fpregset): Remove variable.
4165 (mips_linux_iterate_over_regset_sections): Use
4166 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
4167 (mips_linux_o32_sigframe_init): Remove comment.
4169 2018-05-25 Pedro Alves <palves@redhat.com>
4171 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
4172 (struct readahead_cache, struct packet_reg, struct
4173 remote_arch_state, class remote_state): Move higher up in the
4175 (remote_target::m_remote_state): Now an object instead of a pointer.
4176 (remote_target::get_remote_state): Adjust.
4178 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4180 * stack.c (select_and_print_frame): Delete.
4181 (struct function_bounds): Move struct within function.
4182 (func_command): Most content moved into new function
4183 find_frame_for_function, use new function, print result, add
4185 (find_frame_for_function): New function, now returns a result.
4187 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4189 * stack.c (iterate_over_block_arg_vars): Fix comment.
4190 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
4192 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4196 (scoped_restore_selected_frame::scoped_restore_selected_frame):
4198 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
4200 * frame.h (class scoped_restore_selected_frame): New class.
4201 * stack.c (print_frame_local_vars): Remove catching and rethrowing
4202 of any exception, use scoped_restore_selected_frame to restore the
4205 2018-05-24 Pedro Alves <palves@redhat.com>
4207 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
4210 2018-05-23 Tom Tromey <tom@tromey.com>
4212 * complaints.c (struct complaints): Remove.
4213 (symfile_complaint_book): Remove.
4214 (series): New global.
4215 (complaint_internal): Update.
4216 (clear_complaints): Update.
4218 2018-05-23 Tom Tromey <tom@tromey.com>
4220 * complaints.c (counters): New global.
4221 (struct complain): Remove.
4222 (struct complaints) <root>: Remove.
4223 (complaint_sentinel): Remove.
4224 (symfile_complaint_book): Update.
4225 (find_complaint) Remove.
4226 (complaint_internal, clear_complaints): Update.
4228 2018-05-23 Tom Tromey <tom@tromey.com>
4230 * complaints.c (struct complain) <file, line>: Remove.
4231 (find_complaint): Remove file, line parameters.
4232 (complaint_internal): Update.
4234 2018-05-23 Tom Tromey <tom@tromey.com>
4236 * complaints.c (vcomplaint): Remove.
4237 (complaint_internal) Merge in contents of vcomplaint.
4239 2018-05-23 Tom Tromey <tom@tromey.com>
4241 * complaints.c (struct complaints) <explanation>: Remove.
4242 (symfile_explanations): Remove.
4243 (symfile_complaint_book): Update.
4244 (vcomplaint): Update.
4245 (struct explanation): Remove.
4247 2018-05-23 Tom Tromey <tom@tromey.com>
4249 * complaints.c (symfile_complaints): Remove.
4250 (complaint_internal): Remove "complaints" parameter.
4251 (clear_complaints, vcomplaint): Remove "c" parameter.
4252 (get_complaints): Remove.
4253 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
4254 (dwarf2_debug_line_missing_file_complaint)
4255 (dwarf2_debug_line_missing_end_sequence_complaint)
4256 (dwarf2_complex_location_expr_complaint)
4257 (dwarf2_const_value_length_mismatch_complaint)
4258 (dwarf2_section_buffer_overflow_complaint)
4259 (dwarf2_macro_malformed_definition_complaint)
4260 (dwarf2_invalid_attrib_class_complaint)
4261 (create_addrmap_from_index, dw2_symtab_iter_next)
4262 (dw2_expand_marked_cus)
4263 (dw2_debug_names_iterator::find_vec_in_debug_names)
4264 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
4265 (create_debug_type_hash_table, init_cutu_and_read_dies)
4266 (partial_die_parent_scope, add_partial_enumeration)
4267 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
4268 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
4269 (read_import_statement, read_file_scope, create_dwo_cu_reader)
4270 (create_cus_hash_table, create_dwp_hash_table)
4271 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
4272 (dwarf2_rnglists_process, dwarf2_ranges_process)
4273 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
4274 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
4275 (handle_struct_member_die, process_structure_scope)
4276 (read_array_type, read_common_block, read_module_type)
4277 (read_tag_pointer_type, read_typedef, read_base_type)
4278 (read_subrange_type, load_partial_dies, partial_die_info::read)
4279 (partial_die_info::read, partial_die_info::read)
4280 (partial_die_info::read, read_checked_initial_length_and_offset)
4281 (dwarf2_string_attr, read_formatted_entries)
4282 (dwarf_decode_line_header)
4283 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4284 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
4285 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
4286 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
4287 (get_signatured_type, get_DW_AT_signature_type)
4288 (decode_locdesc, file_file_name, consume_improper_spaces)
4289 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
4290 (dwarf_decode_macro_bytes, dwarf_decode_macros)
4291 (dwarf2_symbol_mark_computed, set_die_type)
4292 (read_attribute_value): Update.
4293 * stap-probe.c (handle_stap_probe, get_stap_base_address):
4295 * dbxread.c (unknown_symtype_complaint)
4296 (lbrac_mismatch_complaint, repeated_header_complaint)
4297 (set_namestring, function_outside_compilation_unit_complaint)
4298 (read_dbx_symtab, process_one_symbol): Update.
4299 * gdbtypes.c (stub_noname_complaint): Update.
4300 * windows-nat.c (handle_unload_dll): Update.
4301 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
4302 (decode_base_type): Update.
4303 * xcoffread.c (bf_notfound_complaint, ef_complaint)
4304 (eb_complaint, record_include_begin, record_include_end)
4305 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
4306 (process_xcoff_symbol, read_symbol)
4307 (function_outside_compilation_unit_complaint)
4308 (scan_xcoff_symtab): Update.
4309 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
4310 * buildsym.c (finish_block_internal, make_blockvector)
4311 (end_symtab_get_static_block, augment_type_symtab): Update.
4312 * dtrace-probe.c (dtrace_process_dof)
4313 (dtrace_static_probe_ops::get_probes): Update.
4314 * complaints.h (struct complaint): Don't declare.
4315 (symfile_complaints): Remove.
4316 (complaint_internal): Remove "complaints" parameter.
4317 (complaint): Likewise.
4318 (clear_complaints): Likewise.
4319 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4320 (reread_symbols): Update.
4321 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
4322 (dwarf2_frame_cache, decode_frame_entry): Update.
4323 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
4324 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4325 (info_selectors_command): Update.
4326 * macrotab.c (macro_include, check_for_redefinition)
4327 (macro_undef): Update.
4328 * objfiles.c (filter_overlapping_sections): Update.
4329 * stabsread.c (invalid_cpp_abbrev_complaint)
4330 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
4331 (define_symbol, error_type, read_type, rs6000_builtin_type)
4332 (stabs_method_name_from_physname, read_member_functions)
4333 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
4334 (attach_fields_to_type, complain_about_struct_wipeout)
4335 (read_range_type, read_args, common_block_start)
4336 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
4338 * mdebugread.c (index_complaint, unknown_ext_complaint)
4339 (basic_type_complaint, bad_tag_guess_complaint)
4340 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
4341 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
4342 (parse_procedure, parse_lines)
4343 (function_outside_compilation_unit_complaint)
4344 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
4345 (bad_tag_guess_complaint, reg_value_complaint): Update.
4346 * cp-support.c (demangled_name_complaint): Update.
4347 * macroscope.c (sal_macro_scope): Update.
4348 * dwarf-index-write.c (class debug_names): Update.
4350 2018-05-23 Tom Tromey <tom@tromey.com>
4352 * complaints.c (clear_complaints): Remove "noisy" parameter.
4353 * complaints.h (clear_complaints): Update.
4354 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4355 (reread_symbols): Update.
4357 2018-05-23 Tom Tromey <tom@tromey.com>
4359 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
4361 (vcomplaint, clear_complaints): Update.
4362 (symfile_explanations): Remove some messages.
4364 2018-05-23 Tom Tromey <tom@tromey.com>
4366 * complaints.c (internal_complaint): Remove.
4367 * complaints.h (internal_complaint): Remove.
4369 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4371 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
4373 2018-05-22 Pedro Alves <palves@redhat.com>
4375 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
4376 (remote_fileio_badfd, remote_fileio_return_errno)
4377 (remote_fileio_return_success, remote_fileio_func_open)
4378 (remote_fileio_func_open, remote_fileio_func_close)
4379 (remote_fileio_func_read, remote_fileio_func_write)
4380 (remote_fileio_func_lseek, remote_fileio_func_rename)
4381 (remote_fileio_func_unlink, remote_fileio_func_stat)
4382 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
4383 (remote_fileio_func_isatty, remote_fileio_func_system): Add
4384 remote_target parameter.
4385 (remote_fio_func_map) <func>: Add remote_target parameter.
4386 (do_remote_fileio_request, remote_fileio_request):
4387 * remote-fileio.h (remote_fileio_request):
4388 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
4389 remote_target parameter.
4390 (remote_notif_process, handle_notification): Adjust to pass down
4392 (remote_notif_state_allocate): Add remote_target parameter. Save
4394 * remote-notif.h (struct remote_target): Forward declare.
4395 (struct notif_client) <parse, ack, can_get_pending_events>: Add
4396 remote_target parameter.
4397 (struct remote_notif_state) <remote>: New field.
4398 (remote_notif_ack, remote_notif_parse): Add remote_target
4400 (remote_notif_state_allocate, remote_notif_state_allocate): Add
4401 remote_target parameter.
4402 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
4403 (threads_listing_context, rmt_thread_action, protocol_feature)
4404 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
4405 (packet_result, struct threads_listing_context, remote_state):
4406 Move definitions and declarations higher up.
4407 (remote_target) <~remote_target>: Declare.
4408 (remote_download_command_source, remote_file_put, remote_file_get)
4409 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
4410 (remote_hostio_pread_vFile, remote_hostio_send_command)
4411 (remote_hostio_set_filesystem, remote_hostio_open)
4412 (remote_hostio_close, remote_hostio_unlink, remote_state)
4413 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
4414 (get_memory_write_packet_size, get_memory_read_packet_size)
4415 (append_pending_thread_resumptions, remote_detach_1)
4416 (append_resumption, remote_resume_with_vcont)
4417 (add_current_inferior_and_thread, wait_ns, wait_as)
4418 (process_stop_reply, remote_notice_new_inferior)
4419 (process_initial_stop_replies, remote_add_thread)
4420 (btrace_sync_conf, remote_btrace_maybe_reopen)
4421 (remove_new_fork_children, kill_new_fork_children)
4422 (discard_pending_stop_replies, stop_reply_queue_length)
4423 (check_pending_events_prevent_wildcard_vcont)
4424 (discard_pending_stop_replies_in_queue, stop_reply)
4425 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
4426 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
4427 (remote_interrupt_as, remote_interrupt_ns)
4428 (remote_get_noisy_reply, remote_query_attached)
4429 (remote_add_inferior, remote_current_thread, get_current_thread)
4430 (set_thread, set_general_thread, set_continue_thread)
4431 (set_general_process, write_ptid)
4432 (remote_unpack_thread_info_response, remote_get_threadinfo)
4433 (parse_threadlist_response, remote_get_threadlist)
4434 (remote_threadlist_iterator, remote_get_threads_with_ql)
4435 (remote_get_threads_with_qxfer)
4436 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
4437 (get_offsets, remote_check_symbols, remote_supported_packet)
4438 (remote_query_supported, remote_packet_size)
4439 (remote_serial_quit_handler, remote_detach_pid)
4440 (remote_vcont_probe, remote_resume_with_hc)
4441 (send_interrupt_sequence, interrupt_query)
4442 (remote_notif_get_pending_events, fetch_register_using_p)
4443 (send_g_packet, process_g_packet, fetch_registers_using_g)
4444 (store_register_using_P, store_registers_using_G)
4445 (set_remote_traceframe, check_binary_download)
4446 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
4447 (remote_xfer_live_readonly_partial, remote_read_bytes)
4448 (remote_send_printf, remote_flash_write, readchar)
4449 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
4450 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
4451 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
4452 (extended_remote_disable_randomization, extended_remote_run)
4453 (send_environment_packet, extended_remote_environment_support)
4454 (extended_remote_set_inferior_cwd, remote_write_qxfer)
4455 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
4456 (packet_command): Now methods of ...
4457 (remote_target): ... this class.
4458 (m_remote_state) <remote_target>: New field.
4459 (struct remote_state) <stop_reply_queue,
4460 remote_async_inferior_event_token, wait_forever_enabled_p>: New
4462 (remote_state::remote_state): Allocate stop_reply_queue.
4463 (remote_state): Delete global.
4464 (get_remote_state_raw): Delete.
4465 (remote_target::get_remote_state): Allocate m_remote_state on
4467 (get_current_remote_target): New.
4468 (remote_ops, extended_remote_ops): Delete.
4469 (wait_forever_enabled_p, remote_async_inferior_event_token):
4470 Delete, moved to struct remote_state.
4471 (remote_target::close): Delete self. Destruction bits split to
4473 (remote_target::~remote_target): ... this.
4474 (show_memory_packet_size): Adjust to use
4475 get_current_remote_target.
4476 (struct protocol_feature) <func>: Add remote_target parameter.
4477 All callers adjusted.
4478 (curr_quit_handler_target): New.
4479 (remote_serial_quit_handler): Reimplement.
4480 (remote_target::open_1): Adjust to use get_current_remote_target.
4481 Heap-allocate remote_target/extended_remote_target instances.
4482 (vcont_builder::vcont_builder): Add remote_target parameter, and
4483 save it in m_remote. All callers adjusted.
4484 (vcont_builder::m_remote): New field.
4485 (vcont_builder::restart, vcont_builder::flush)
4486 (vcont_builder::push_action): Use it.
4487 (remote_target::commit_resume): Use it.
4488 (struct queue_iter_param) <remote>: New field.
4489 (remote_target::remove_new_fork_children): Fill in 'remote' field.
4490 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
4491 (check_pending_event_prevents_wildcard_vcont_callback)
4492 (remote_target::check_pending_events_prevent_wildcard_vcont)
4493 (remote_target::discard_pending_stop_replies)
4494 (remote_target::discard_pending_stop_replies_in_queue)
4495 (remote_target::remote_notif_remove_queued_reply): Fill in
4497 (remote_notif_get_pending_events): New.
4498 (remote_target::readchar, remote_target::remote_serial_write):
4499 Save/restore curr_quit_handler_target.
4501 (kill_new_fork_children): Fill in 'remote' field.
4502 (packet_command): Use get_current_remote_target, defer to
4503 remote_target method of same name.
4504 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
4505 parameter, and save it in m_remote. All callers adjusted.
4506 (scoped_remote_fd::release): Use m_remote.
4507 (scoped_remote_fd::m_remote): New field.
4508 (remote_file_put, remote_file_get, remote_file_delete): Use
4509 get_current_remote_target, defer to remote_target method of same
4511 (remote_btrace_reset): Add remote_state paremeter. Update all
4513 (remote_async_inferior_event_handler). Pass down 'data'.
4514 (remote_new_objfile): Use get_current_remote_target.
4515 (remote_target::vcont_r_supported): New.
4516 (set_range_stepping): Use get_current_remote_target and
4517 remote_target::vcont_r_supported.
4518 (_initialize_remote): Don't allocate 'remote_state' and
4519 'stop_reply_queue' globals.
4520 * remote.h (struct remote_target): Forward declare.
4521 (getpkt, putpkt, remote_notif_get_pending_events): Add
4522 'remote_target' parameter.
4524 2018-05-22 Pedro Alves <palves@redhat.com>
4526 * remote.c (vcont_builder): Now a class. Make all data members
4528 (vcont_builder) <vcont_builder, restart, flush, push_action>:
4530 (vcont_builder_restart): Rename to ...
4531 (vcont_builder::restart): ... this.
4532 (vcont_builder_flush): Rename to ...
4533 (vcont_builder::flush): ... this.
4534 (vcont_builder_push_action): Rename to ...
4535 (vcont_builder::push_action): ... this.
4536 (remote_target::commit_resume): Adjust.
4538 2018-05-22 Pedro Alves <palves@redhat.com>
4540 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
4541 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
4542 (get_fixed_memory_packet_size): New.
4543 (get_memory_packet_size): Use it.
4544 (set_memory_packet_size): Don't override the config size with
4545 DEFAULT_MAX_MEMORY_PACKET_SIZE.
4546 (show_memory_packet_size): Use get_fixed_memory_packet_size.
4547 Don't refer to get_memory_packet_size if not connected to a remote
4548 target. Show "(default)" if configured size is 0.
4550 2018-05-22 Pedro Alves <palves@redhat.com>
4552 * remote.c (remote_target::mourn_inferior): Move
4553 discard_pending_stop_replies call here from ...
4554 (_initialize_remote): ... here.
4556 2018-05-22 Pedro Alves <palves@redhat.com>
4558 * remote.c (compare_section_command): Remove set_general_process
4561 2018-05-22 Pedro Alves <palves@redhat.com>
4563 * remote.c (struct packet_reg, struct remote_arch_state):
4564 Move higher up in the file.
4565 (remote_state) <m_arch_states>: Store remote_arch_state values
4566 instead of remote_arch_state pointers.
4567 (remote_state::get_remote_arch_state): Adjust.
4569 2018-05-22 Pedro Alves <palves@redhat.com>
4571 * remote.c: Include <unordered_map>.
4572 (remote_state): Now a class.
4573 (remote_state) <get_remote_arch_state>: Declare method.
4574 <get_remote_arch_state>: New field.
4575 (remote_arch_state) <remote_arch_state>: Declare ctor.
4576 <regs>: Now a unique_ptr.
4577 (remote_gdbarch_data_handle): Delete.
4578 (get_remote_arch_state): Delete.
4579 (remote_state::get_remote_arch_state): New.
4580 (get_remote_state): Adjust to call remote_state's
4581 get_remote_arch_state method.
4582 (init_remote_state): Delete, bits factored out to ...
4583 (remote_arch_state::remote_arch_state): ... this new method.
4584 (get_remote_packet_size, get_memory_packet_size)
4585 (process_g_packet, remote_target::fetch_registers)
4586 (remote_target::prepare_to_store, store_registers_using_G)
4587 (remote_target::store_registers, remote_target::get_trace_status):
4588 Adjust to call remote_state's method.
4589 (_initialize_remote): Remove reference to
4590 remote_gdbarch_data_handle.
4592 2018-05-22 Pedro Alves <palves@redhat.com>
4594 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
4595 pread>: New method declarations.
4596 (remote_target::open_1): Adjust.
4597 (readahead_cache_invalidate): Rename to ...
4598 (readahead_cache::invalidate): ... this, and adjust to be a class
4600 (readahead_cache_invalidate_fd): Rename to ...
4601 (readahead_cache::invalidate_fd): ... this, and adjust to be a
4603 (remote_hostio_pwrite): Adjust.
4604 (remote_hostio_pread_from_cache): Rename to ...
4605 (readahead_cache::pread): ... this, and adjust to be a class
4607 (remote_hostio_close): Adjust.
4609 2018-05-22 Pedro Alves <palves@redhat.com>
4611 * remote.c (remote_hostio_close_cleanup): Delete.
4612 (class scoped_remote_fd): New.
4613 (remote_file_put, remote_file_get): Use it.
4615 2018-05-22 Pedro Alves <palves@redhat.com>
4617 (struct vCont_action_support): Use bool and initialize all fields.
4618 (struct readahead_cache): Initialize all fields.
4619 (remote_state): Use bool and initialize all fields.
4620 (remote_state::remote_state, remote_state::~remote_state): New.
4621 (new_remote_state): Delete.
4622 (_initialize_remote): Use new to allocate remote_state.
4624 2018-05-22 Pedro Alves <palves@redhat.com>
4628 * c-exp.y: Include "c-support.h".
4629 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4630 of tolower. Use c_ident_is_alpha to scan names.
4631 * c-lang.c: Include "c-support.h".
4632 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4633 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4634 * c-support.h: New file, with bits factored out from ...
4635 * cp-name-parser.y: ... this file.
4636 Include "c-support.h".
4637 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4638 c-support.h and renamed.
4639 (symbol_end, yylex): Adjust.
4641 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4643 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4644 parameter type to CORE_ADDR.
4645 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4646 parameter type in declaration to CORE_ADDR.
4647 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4648 target_auxv_search to get AT_HWCAP and use the result to get the
4650 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4651 to CORE_ADDR. Remove the cast of the return value to unsigned
4652 long. Fix error predicate of target_auxv_search.
4653 (ppc_linux_nat_target::read_description): Change the type of the
4654 hwcap variable to CORE_ADDR.
4656 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4658 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4659 if the size of fpscr is larger than 32 bits.
4661 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4663 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4664 (ppc32_linux_vsxregmap): New global.
4665 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4666 regcache_supply_regset, and regcache_collect_regset.
4667 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4668 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4669 (fetch_vsx_register, store_vsx_register): Remove.
4670 (fetch_vsx_registers): Add regno parameter. Get regset using
4671 ppc_linux_vsxregset. Use regset to supply registers.
4672 (store_vsx_registers): Add regno parameter. Get regset using
4673 ppc_linux_vsxregset. Use regset to collect registers.
4674 (fetch_register): Call fetch_vsx_registers instead of
4676 (store_register): Call store_vsx_registers instead of
4678 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4679 new regno parameter.
4680 (store_ppc_registers): Call store_vsx_registers with -1 for the
4681 new regno parameter.
4682 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4683 (ppc_collect_vsxregset): Remove.
4685 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4687 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4689 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4690 for vector register offset fields.
4691 (ppc64_fbsd_reg_offsets): Likewise.
4692 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4693 to vector register offset fields.
4694 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4695 to vector register offset fields.
4696 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
4697 vector register offset fields.
4698 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
4699 initializers for vector register offset fields.
4700 (rs6000_aix64_reg_offsets): Likewise.
4701 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
4702 (ppc_supply_vrregset): Remove.
4703 (ppc_collect_vrregset): Remove.
4704 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
4705 (ppc_linux_vrregset) : New function.
4706 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
4707 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
4708 (ppc32_linux_vrregset): Remove.
4709 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
4710 and use result instead of ppc32_linux_vrregset.
4711 (ppc32_linux_reg_offsets): Remove initializers for vector register
4713 (ppc64_linux_reg_offsets): Likewise.
4714 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
4715 * ppc-linux-nat.c: Include regset.h.
4716 (gdb_vrregset_t): Adjust comment to account for little-endian
4718 (supply_vrregset, fill_vrregset): Remove.
4719 (fetch_altivec_register, store_altivec_register): Remove.
4720 (fetch_altivec_registers): Add regno parameter. Get regset using
4721 ppc_linux_vrregset. Use regset to supply registers.
4722 (store_altivec_registers): Add regno parameter. Get regset using
4723 ppc_linux_vrregset. Use regset to collect registers.
4724 (fetch_register): Call fetch_altivec_registers instead of
4725 fetch_altivec_register.
4726 (store_register): Call store_altivec_registers instead of
4727 store_altivec_register.
4728 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
4729 the new regno parameter.
4730 (store_ppc_registers): Call store_altivec_registers with -1 for
4731 the new regno parameter.
4733 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4735 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
4736 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
4737 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4738 (gdb_vrregset_t): Change array type size to
4739 PPC_LINUX_SIZEOF_VRREGSET.
4740 (gdb_vsxregset_t): Change array type size to
4741 PPC_LINUX_SIZEOF_VSXREGSET.
4742 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
4743 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
4744 PPC_LINUX_SIZEOF_VSXREGSET.
4746 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4748 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
4749 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
4751 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
4752 ppc_linux_target_wordsize with tid.
4753 (ppc_linux_nat_target::read_description): Call ppc_linux_target
4755 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
4756 (ppc64_64bit_inferior_p): Add static and inline specifiers.
4757 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
4758 tid parameter. Remove static specifier.
4759 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
4760 (ppc_linux_target_wordsize): New declaration.
4762 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4764 * arch/ppc-linux-common.c: New file.
4765 * arch/ppc-linux-common.h: New file.
4766 * arch/ppc-linux-tdesc.h: New file.
4767 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
4768 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
4769 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
4770 arch/ppc-linux-tdesc.h.
4771 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
4772 arch/ppc-linux-tdesc.h.
4773 (ppc_linux_nat_target::read_description): Remove target
4774 description matching code. Fill a ppc_linux_features struct and
4775 call ppc_linux_match_description with it. Move comment about ISA
4776 2.05 to ppc-linux-common.c.
4777 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
4778 arch/ppc-linux-tdesc.h.
4779 (ppc_linux_core_read_description): Remove target description
4780 matching code. Fill a ppc_linux_features struct and call
4781 ppc_linux_match_description with it.
4782 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4783 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4784 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4785 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4786 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4787 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4788 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4789 (tdesc_powerpc_e500l): Remove.
4791 2018-05-22 Joel Brobecker <brobecker@adacore.com>
4793 * ada-lang.c (catch_assert_command): Pass empty string instead
4794 of NULL for excep_string argument.
4796 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4798 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
4799 the width of the requested register exceeds the width of the
4802 2018-05-21 Tom Tromey <tom@tromey.com>
4804 * printcmd.c (output_command): Remove.
4805 (output_command_const): Rename to output_command.
4806 * valprint.h (output_command): Rename from output_command_const.
4807 * tracepoint.c (trace_dump_actions): Call output_command.
4809 2018-05-21 Tom Tromey <tom@tromey.com>
4811 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
4812 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
4813 * ada-lang.h (create_ada_exception_catchpoint): Update.
4814 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
4816 (create_excep_cond_exprs, ~ada_catchpoint)
4817 (should_stop_exception, print_one_exception)
4818 (print_mention_exception, print_recreate_exception): Update.
4819 (ada_get_next_arg): Remove.
4820 (catch_ada_exception_command_split): Use std::string. Change type
4821 of "excep_string", "cond_string".
4822 (catch_ada_exception_command): Update.
4823 (create_ada_exception_catchpoint): Change type of excep_string.
4824 (ada_exception_sal): Remove excep_string parameter.
4825 (~ada_catchpoint): Remove.
4827 2018-05-21 Tom Tromey <tom@tromey.com>
4829 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
4832 2018-05-21 Tom Tromey <tom@tromey.com>
4834 * ada-lang.c (ada_exception_message_1, ada_exception_message):
4835 Return unique_xmalloc_ptr.
4836 (print_it_exception): Update.
4838 2018-05-21 Tom Tromey <tom@tromey.com>
4840 * tracepoint.c (trace_dump_actions): Use std::string.
4842 2018-05-21 Tom Tromey <tom@tromey.com>
4844 * symfile.c (reread_symbols): Use std::string for original_name.
4846 2018-05-21 Tom Tromey <tom@tromey.com>
4848 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
4849 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
4852 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
4854 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
4856 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
4857 * objfiles.c (get_objfile_bfd_data): Allocate
4858 objfile_per_bfd_storage with obstack_new when allocating on
4861 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4863 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
4865 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
4866 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
4867 * mdebugread.c (mdebug_build_psymtabs): Likewise.
4868 (add_pending): Likewise.
4869 (parse_symbol): Likewise.
4870 (parse_partial_symbols): Likewise.
4871 (psymtab_to_symtab_1): Likewise.
4872 (new_psymtab): Likewise.
4873 (elfmdebug_build_psymtabs): Likewise.
4874 * minsyms.c (terminate_minimal_symbol_table): Likewise.
4875 * objfiles.c (get_objfile_bfd_data): Likewise.
4876 (objfile_register_static_link): Likewise.
4877 * psymtab.c (allocate_psymtab): Likewise.
4878 * stabsread.c (read_member_functions): Likewise.
4879 * xcoffread.c (xcoff_end_psymtab): Likewise.
4881 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4883 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
4884 compiler supports std::is_trivially_constructible.
4885 * common/poison.h: Include obstack.h.
4886 (IsMallocable): Define to is_trivially_constructible if the
4887 compiler supports it, define to true_type otherwise.
4891 (XOBNEWVEC): Redefine.
4892 * gdb_obstack.h (obstack_zalloc): New.
4893 (OBSTACK_ZALLOC): Redefine.
4894 (obstack_calloc): New.
4895 (OBSTACK_CALLOC): Redefine.
4897 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
4898 (gdbarch_obstack): New declaration in gdbarch.h, definition in
4900 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
4901 obstack_calloc/obstack_zalloc.
4902 (gdbarch_obstack_zalloc): Remove.
4903 * target-descriptions.c (tdesc_data_init): Use obstack_new.
4905 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4907 * stack.c (backtrace_command_1): Remove useless variable int i.
4909 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4911 * stack.c (print_frame_info): Fix comment.
4913 2018-05-18 Tom Tromey <tom@tromey.com>
4915 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
4916 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
4917 (~dwarf2_per_objfile): Update
4918 (dwarf2_get_dwz_file): Use new.
4919 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
4922 2018-05-18 Tom Tromey <tom@tromey.com>
4924 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
4926 * dwarf2read.c (struct dwp_file): Add constructor and
4928 (open_and_init_dwp_file): Return a unique_ptr.
4929 (dwarf2_per_objfile, create_dwp_hash_table)
4930 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
4931 (lookup_dwo_unit_in_dwp): Update.
4932 (open_and_init_dwp_file, get_dwp_file): Update.
4934 2018-05-18 Tom Tromey <tom@tromey.com>
4936 * dwarf2read.c (dwarf2_per_objfile): Update.
4937 (struct mapped_index): Add initializers.
4938 (dwarf2_read_index): Use new.
4939 (dw2_symtab_iter_init): Update.
4940 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
4943 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4945 * dwarf2read.c (mapped_index) <total_size>: Remove.
4947 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4949 * unittests/format_pieces-selftests.c (test_format_specifier):
4952 2018-05-18 Tom Tromey <tom@tromey.com>
4954 * c-typeprint.c (maybe_print_hole): New function.
4955 (c_print_type_struct_field_offset): Update.
4956 (c_type_print_base_struct_union): Call maybe_print_hole.
4958 2018-05-17 Keith Seitz <keiths@redhat.com>
4960 * breakpoint.c (build_bpstat_chain): New function, moved from
4962 (bpstat_stop_status): Add optional parameter, `stop_chain'.
4963 If no stop chain is passed, call build_bpstat_chain to build it.
4964 * breakpoint.h (build_bpstat_chain): Declare.
4965 (bpstat_stop_status): Move documentation here from breakpoint.c.
4966 * infrun.c (handle_signal_stop): Before eliding inlined frames,
4967 build the stop chain and pass it to skip_inline_frames.
4968 Pass this stop chain to bpstat_stop_status.
4969 * inline-frame.c: Include breakpoint.h.
4970 (stopped_by_user_bp_inline_frame): New function.
4971 (skip_inline_frames): Add parameter `stop_chain'.
4972 Move documention to inline-frame.h.
4973 If non-NULL, use stopped_by_user_bp_inline_frame to determine
4974 whether the frame should be elided.
4975 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
4976 Add moved documentation and update for new parameter.
4978 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4981 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4982 unittests/format_pieces-selftests.c.
4983 * common/format.h (format_piece) <operator==>: New.
4984 (format_pieces) <operator[]>: Remove.
4985 * common/format.c (format_pieces::format_pieces): Handle \e.
4986 * unittests/format_pieces-selftests.c: New.
4988 2018-05-17 Tom Tromey <tom@tromey.com>
4991 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
4992 (dw2_instantiate_symtab): Add skip_partial parameter.
4993 (dw2_find_last_source_symtab, dw2_map_expand_apply)
4994 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
4995 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
4996 (dw2_expand_symtabs_matching_one)
4997 (dw2_find_pc_sect_compunit_symtab)
4998 (dw2_debug_names_lookup_symbol)
4999 (dw2_debug_names_expand_symtabs_for_function): Update.
5000 (init_cutu_and_read_dies): Add skip_partial parameter.
5001 (process_psymtab_comp_unit, build_type_psymtabs_1)
5002 (process_skeletonless_type_unit, load_partial_comp_unit)
5003 (psymtab_to_symtab_1): Update.
5004 (load_full_comp_unit): Add skip_partial parameter.
5005 (process_imported_unit_die, dwarf2_read_addr_index)
5006 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
5007 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
5008 (read_signatured_type): Update.
5010 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
5012 * value.c (release_value): Remove unused variable.
5013 (record_latest_value): Likewise.
5014 (access_value_history): Likewise.
5015 (preserve_values): Likewise.
5017 2018-05-17 Tom Tromey <tom@tromey.com>
5019 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
5022 2018-05-16 Maciej W. Rozycki <macro@mips.com>
5025 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
5026 Also handle registers whose width is not a multiple of
5028 (linux_nat_trad_target::store_register): Likewise.
5030 2018-05-16 Tom Tromey <tom@tromey.com>
5032 * gdbcore.h (core_bfd): Redefine.
5033 * corelow.c (core_target::close): Update.
5034 (core_target_open): Update.
5035 * progspace.h (struct program_space) <cbfd>: Now a
5038 2018-05-16 Tom Tromey <tom@tromey.com>
5041 * symfile-add-flags.h (enum symfile_add_flags)
5042 <SYMFILE_NOT_FILENAME>: New constant.
5043 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
5044 objfile name from BFD.
5045 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
5046 * minidebug.c (find_separate_debug_file_in_section): Put
5047 ".gnu_debugdata" into BFD's file name.
5049 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
5051 * regcache.c (regcache_read_ftype, regcache_write_ftype):
5054 2018-05-15 Tamar Christina <tamar.christina@arm.com>
5057 * aarch64-tdep.c (aarch64_analyze_prologue,
5058 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
5059 Indicate not interested in errors.
5061 2018-05-15 Maciej W. Rozycki <macro@mips.com>
5063 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
5064 Supply the MIPS_ZERO_REGNUM register.
5066 2018-05-15 Maciej W. Rozycki <macro@mips.com>
5068 * mips-tdep.c (mask_address_var): Make variable static.
5070 2018-05-14 Tom Tromey <tom@tromey.com>
5072 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
5074 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
5076 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
5077 FXSAVE_ADDR for the mxcsr register.
5079 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
5081 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
5083 2018-05-11 Pedro Alves <palves@redhat.com>
5085 * corelow.c (core_target) <core_target>: No longer inline.
5086 Initialize m_core_gdbarch, m_core_vec and build the section table
5088 <~core_target>: New.
5089 <core_gdbarch, get_core_register_section>: New methods.
5090 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
5091 factored out from ...
5092 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
5094 (sniff_core_bfd): Add gdbarch parameter.
5095 (core_close): Delete, merged into ...
5096 (core_target::close): ... here. Delete self.
5097 (core_close_cleanup): Delete.
5098 (core_target_open): Allocate a core_target on the heap. Use a
5099 unique_ptr instead of a cleanup. Bits moved into the core_target
5100 ctor. Adjust to use core_target methods instead of globals.
5101 (get_core_register_section): Rename to ...
5102 (core_target::get_core_register_section): ... this and adjust.
5103 (struct get_core_registers_cb_data): New.
5104 (get_core_registers_cb): Use it. Use bool.
5105 (core_target::fetch_registers, core_target::files_info)
5106 (core_target::xfer_partial, core_target::read_description)
5107 (core_target::pid_to, core_target::thread_name): Adjust to
5108 reference class fields instead of globals.
5109 * target.h (struct target_ops_deleter, target_ops_up): New.
5111 2018-05-11 Pedro Alves <palves@redhat.com>
5113 * corefile.c (core_file_command): Move to corelow.c.
5114 * corelow.c (the_core_target): Delete.
5115 (core_file_command): Moved from corefile.c. Check exec_bfd
5116 instead of the_core_target. Use target_detach instead of calling
5117 into the_core_target directly.
5118 (maybe_say_no_core_file_now): New.
5119 (core_target::detach): Use it.
5120 (_initialize_corelow): Remove references to the_core_target.
5121 * gdbcore.h (the_core_target): Delete.
5123 2018-05-11 Tom Tromey <tromey@redhat.com>
5124 Pedro Alves <palves@redhat.com>
5126 * corefile.c (core_bfd): Remove.
5127 * gdbcore.h (core_bfd): Now a macro.
5128 * progspace.h (struct program_space) <cbfd>: New field.
5130 2018-05-11 Tom Tromey <tom@tromey.com>
5132 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
5135 2018-05-10 Tom Tromey <tom@tromey.com>
5137 * configure: Rebuild.
5138 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
5140 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5143 * regformats/regdat.sh: Adjust script, following the addition
5144 of the new expedite_regs parameter to init_target_desc.
5146 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
5149 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
5150 set_gdbarch_significant_addr_bit.
5151 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
5152 set_gdbarch_significant_addr_bit.
5153 * utils.c (address_significant): Update to sign extend addr.
5155 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
5157 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
5158 (xtensa_linux_init_abi): Limit tdep->num_regs by
5159 tdep->num_nopriv_regs.
5160 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
5161 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
5164 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
5166 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
5168 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5170 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
5171 (I387_MXCSR_INIT_VAL): New constant.
5172 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
5173 buffer if it was supplied by the inferior.
5174 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
5175 (i387_xsave_get_clear_bv): New function.
5176 (i387_supply_xsave): Only read x87 control registers from the
5177 xsave buffer if the feature is enabled, and the state will have
5178 been written, otherwise, provide a suitable default.
5179 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
5180 including x87 control registers. Update control registers if they
5181 have changed from the default value, and mark features as enabled
5183 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
5185 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
5187 * spu-tdep.c (info_spu_event_command): Fix output formatting.
5189 2018-05-07 Tom Tromey <tom@tromey.com>
5191 * configure: Rebuild.
5192 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
5194 2018-05-07 Tom Tromey <tom@tromey.com>
5197 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
5198 bit. Use correct value for VDIV.
5200 2018-05-04 Tom Tromey <tom@tromey.com>
5202 * configure: Rebuild.
5203 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
5205 2018-05-04 Tom Tromey <tom@tromey.com>
5207 * linux-record.c (record_linux_system_call) <case
5208 RECORD_SYS_RECVFROM>: Add "break".
5210 2018-05-04 Tom Tromey <tom@tromey.com>
5212 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
5213 Add missing "break".
5214 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
5215 Add missing "break".
5217 2018-05-04 Tom Tromey <tom@tromey.com>
5219 * rs6000-tdep.c (ppc_process_record_op4)
5220 (ppc_process_record_op63): Add fall-through comment.
5222 2018-05-04 Tom Tromey <tom@tromey.com>
5224 * i386-tdep.c (i386_process_record): Add fall-through comment.
5226 2018-05-04 Tom Tromey <tom@tromey.com>
5228 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
5231 2018-05-04 Tom Tromey <tom@tromey.com>
5233 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
5234 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
5235 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
5237 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
5239 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
5242 2018-05-04 Tom Tromey <tom@tromey.com>
5244 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
5246 2018-05-04 Tom Tromey <tom@tromey.com>
5248 * s390-tdep.c (s390_process_record): Fix fall-through comments.
5249 * xcoffread.c (scan_xcoff_symtab): Move comment later.
5250 * symfile.c (section_is_mapped): Fix fall-through comment.
5251 * stabsread.c (define_symbol, read_member_functions): Fix
5252 fall-through comment.
5253 * s390-linux-tdep.c (s390_process_record): Fix fall-through
5255 * remote.c (remote_wait_as): Fix fall-through comment.
5256 * p-exp.y (yylex): Fix fall-through comment.
5257 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
5259 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
5260 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
5261 * jv-exp.y (yylex): Fix fall-through comment.
5262 * go-exp.y (lex_one_token): Fix fall-through comment.
5263 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
5264 fall-through comment.
5265 * f-exp.y (yylex): Fix fall-through comment.
5266 * dwarf2read.c (process_die): Fix fall-through comments.
5267 * dbxread.c (process_one_symbol): Fix fall-through comment.
5268 * d-exp.y (lex_one_token): Fix fall-through comment.
5269 * cp-name-parser.y (yylex): Fix fall-through comment.
5270 * coffread.c (coff_symtab_read): Fix fall-through comment.
5271 * c-exp.y (lex_one_token): Fix fall-through comment.
5272 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
5274 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
5277 2018-05-04 Tom Tromey <tom@tromey.com>
5280 * NEWS: Mention gdb.execute change.
5281 * gdbcmd.h (execute_control_command): Don't declare.
5282 * python/python.c (execute_gdb_command): Use read_command_lines_1,
5283 execute_control_commands, execute_control_commands_to_string.
5284 * cli/cli-script.h (execute_control_commands)
5285 (execute_control_commands_to_string): Declare.
5286 (execute_control_command): Add from_tty parameter.
5287 * cli/cli-script.c (execute_control_commands)
5288 (execute_control_commands_to_string): New functions.
5289 (execute_user_command): Use execute_control_commands.
5290 (execute_control_command_1): Add "from_tty" parameter. Update.
5291 (execute_control_command): Likewise.
5293 2018-05-04 Tom Tromey <tom@tromey.com>
5296 * NEWS: Mention that breakpoint commands are writable.
5297 * python/py-breakpoint.c (bppy_set_commands): New function.
5298 (breakpoint_object_getset) <"commands">: Use it.
5300 2018-05-04 Tom Tromey <tom@tromey.com>
5302 * tracepoint.c (actions_command): Update.
5303 * mi/mi-cmd-break.c (mi_command_line_array)
5304 (mi_command_line_array_cnt, mi_command_line_array_ptr)
5305 (mi_read_next_line): Remove.
5306 (mi_cmd_break_commands): Update.
5307 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
5309 * cli/cli-script.c (get_command_line): Update.
5310 (process_next_line): Use function_view. Constify.
5311 (recurse_read_control_structure, read_command_lines)
5312 (read_command_lines_1): Change argument types to function_view.
5313 (do_define_command, document_command): Update.
5314 * breakpoint.h (check_tracepoint_command): Don't declare.
5315 * breakpoint.c (check_tracepoint_command): Remove.
5316 (commands_command_1, create_tracepoint_from_upload): Update.
5318 2018-05-04 Tom Tromey <tom@tromey.com>
5321 * cli/cli-script.h (enum command_control_type) <define_control>:
5323 * cli/cli-script.c (multi_line_command_p): Handle define_control.
5324 (build_command_line, execute_control_command_1)
5325 (process_next_line): Likewise.
5326 (do_define_command): New function, extracted from define_command.
5327 (define_command): Use it.
5329 2018-05-04 Tom Tromey <tom@tromey.com>
5331 * tracepoint.c (actions_command): Update.
5332 * cli/cli-script.h (read_command_lines): Update.
5333 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
5334 (MAX_TMPBUF): Remove define.
5335 (define_command): Use string_printf.
5336 (document_command): Likewise.
5337 * breakpoint.c (commands_command_1): Update.
5339 2018-05-04 Tom Tromey <tom@tromey.com>
5341 * top.c (execute_command): Update.
5342 * cli/cli-script.h (print_command_lines): Now varargs.
5343 * cli/cli-script.c (print_command_lines): Now varargs.
5344 (execute_control_command_1) <case while_control, case if_control>:
5347 2018-05-04 Tom Tromey <tom@tromey.com>
5349 * tracepoint.c (all_tracepoint_actions): Rename from
5350 all_tracepoint_actions_and_cleanup. Change return type.
5351 (actions_command, encode_actions_1, encode_actions)
5352 (trace_dump_actions, tdump_command): Update.
5353 * remote.c (remote_download_command_source): Update.
5354 * python/python.c (gdbpy_eval_from_control_command)
5355 (python_command, python_interactive_command): Update.
5356 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
5357 * guile/guile.c (guile_command)
5358 (gdbscm_eval_from_control_command, guile_command): Update.
5359 * compile/compile.c (compile_code_command)
5360 (compile_print_command, compile_to_object): Update.
5361 * cli/cli-script.h (struct command_lines_deleter): New.
5362 (counted_command_line): New typedef.
5363 (struct command_line): Add constructor, destructor.
5364 <body_list>: Remove.
5365 <body_list_0, body_list_1>: New members.
5366 (command_line_up): Remove typedef.
5367 (read_command_lines, read_command_lines_1, get_command_line):
5369 (copy_command_lines): Don't declare.
5370 * cli/cli-script.c (build_command_line): Use "new".
5371 (get_command_line): Return counted_command_line.
5372 (print_command_lines, execute_user_command)
5373 (execute_control_command_1, while_command, if_command): Update.
5374 (realloc_body_list): Remove.
5375 (process_next_line, recurse_read_control_structure): Update.
5376 (read_command_lines, read_command_lines_1): Return counted_command_line.
5377 (free_command_lines): Use "delete".
5378 (copy_command_lines): Remove.
5379 (define_command, document_command, show_user_1): Update.
5380 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
5381 a counted_command_line.
5382 * breakpoint.h (counted_command_line): Remove typedef.
5383 (breakpoint_set_commands): Update.
5384 * breakpoint.c (check_no_tracepoint_commands)
5385 (validate_commands_for_breakpoint): Update.
5386 (breakpoint_set_commands): Change commands to be a
5387 counted_command_line.
5388 (commands_command_1, update_dprintf_command_list)
5389 (create_tracepoint_from_upload): Update.
5391 2018-05-04 Tom Tromey <tom@tromey.com>
5393 * cli/cli-decode.h (cmd_list_element): New constructor.
5394 (~cmd_list_element): New destructor.
5395 (struct cmd_list_element): Add initializers.
5396 * cli/cli-decode.c (do_add_cmd): Use "new".
5397 (delete_cmd): Use "delete".
5399 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5400 Pedro Alves <palves@redhat.com>
5402 PR breakpoints/19806 and support for PR external/20207.
5403 * NEWS: Mention Aarch64 watchpoint improvements.
5404 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
5405 watchpoints and PR external/20207 watchpoints.
5406 * nat/aarch64-linux-hw-point.c
5407 (kernel_supports_any_contiguous_range): New.
5408 (aarch64_watchpoint_offset): New.
5409 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
5410 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
5411 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
5412 (aarch64_align_watchpoint): New parameters aligned_offset_p and
5413 next_addr_orig_p. Support PR external/20207 watchpoints.
5414 (aarch64_downgrade_regs): New.
5415 (aarch64_dr_state_insert_one_point): New parameters offset and
5417 (aarch64_dr_state_remove_one_point): Likewise.
5418 (aarch64_handle_breakpoint): Update caller.
5419 (aarch64_handle_aligned_watchpoint): Likewise.
5420 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
5422 (aarch64_linux_set_debug_regs): Remove const from state. Call
5423 aarch64_downgrade_regs.
5424 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
5425 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
5426 (DR_CONTROL_MASK): ... this.
5427 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
5428 (unsigned int aarch64_watchpoint_offset): New prototype.
5429 (aarch64_linux_set_debug_regs): Remove const from state.
5430 * utils.c (align_up, align_down): Move to ...
5431 * common/common-utils.c (align_up, align_down): ... here.
5432 * utils.h (align_up, align_down): Move to ...
5433 * common/common-utils.h (align_up, align_down): ... here.
5435 2018-05-04 Joel Brobecker <brobecker@adacore.com>
5437 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
5438 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
5439 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
5440 Re-implement to match the ABI as summarized in GCC's
5441 gcc/config/sparc/sparc.c. All callers updated.
5442 (sparc32_store_arguments): Remove assertion.
5444 2018-05-04 Tom Tromey <tom@tromey.com>
5446 * printcmd.c: Don't include tui.h.
5447 (decode_format): Use skip_spaces.
5449 2018-05-04 Tom Tromey <tom@tromey.com>
5452 * printcmd.c (last_count): New global.
5453 (x_command): Use saved count when repeating.
5455 2018-05-04 Tom Tromey <tom@tromey.com>
5457 * nto-procfs.c (do_closedir_cleanup): Remove.
5458 (procfs_pidlist): Use gdb_dir_up.
5459 * procfs.c (do_closedir_cleanup): Remove.
5460 (proc_update_threads): Use gdb_dir_up.
5461 * common/filestuff.h (struct gdb_dir_deleter): New.
5462 (gdb_dir_up): New typedef.
5464 2018-05-04 Tom Tromey <tom@tromey.com>
5466 * ada-lang.c (print_mention_exception): Use std::string.
5468 2018-05-04 Tom Tromey <tom@tromey.com>
5470 * ada-lang.c (create_excep_cond_exprs): Update.
5471 (ada_exception_catchpoint_cond_string): Use std::string.
5473 2018-05-04 Tom Tromey <tom@tromey.com>
5475 * ada-lang.c (xget_renaming_scope): Return std::string.
5476 (old_renaming_is_invisible): Update.
5478 2018-05-04 Tom Tromey <tom@tromey.com>
5480 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
5481 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
5483 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5485 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
5487 2018-05-04 Tom Tromey <tom@tromey.com>
5489 * remote.c (remote_query_supported_append): Change type.
5490 (remote_check_symbols): Update.
5492 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
5495 * configure.ac: Prepend libpython.
5496 * python/python-config.py: Likewise.
5497 * configure: Regenerate.
5499 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
5501 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
5503 2018-05-03 Pedro Alves <palves@redhat.com>
5506 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
5507 override. Write 'true' instead of '1'.
5508 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
5511 2018-05-02 Pedro Alves <palves@redhat.com>
5513 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
5514 add_inf_child_target.
5515 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
5516 add_inf_child_target.
5517 * aix-thread.c (aix_thread_target_info): New.
5518 (aix_thread_target) <shortname, longname, doc>: Delete.
5520 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
5521 add_inf_child_target.
5522 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
5523 add_inf_child_target.
5524 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
5525 add_inf_child_target.
5526 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
5527 add_inf_child_target.
5528 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
5529 add_inf_child_target.
5530 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
5531 add_inf_child_target.
5532 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
5533 add_inf_child_target.
5534 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
5535 add_inf_child_target.
5536 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
5537 add_inf_child_target.
5538 * bfd-target.c (target_bfd_target_info): New.
5539 (target_bfd) <shortname, longname, doc>: Delete.
5541 * bsd-kvm.c (bsd_kvm_target_info): New.
5542 (bsd_kvm_target) <shortname, longname, doc>: Delete.
5544 (bsd_kvm_target::open): Rename to ...
5545 (bsd_kvm_target_open): ... this. Adjust.
5546 * bsd-uthread.c (bsd_uthread_target_info): New.
5547 (bsd_uthread_target) <shortname, longname, doc>: Delete.
5549 * corefile.c (core_file_command): Adjust.
5550 * corelow.c (core_target_info): New.
5551 (core_target) <shortname, longname, doc>: Delete.
5553 (core_target::open): Rename to ...
5554 (core_target_open): ... this. Adjust.
5555 * ctf.c (ctf_target_info): New.
5556 (ctf_target) <shortname, longname, doc>: Delete.
5558 (ctf_target::open): Rename to ...
5559 (ctf_target_open): ... this.
5560 (_initialize_ctf): Adjust.
5561 * exec.c (exec_target_info): New.
5562 (exec_target) <shortname, longname, doc>: Delete.
5564 (exec_target::open): Rename to ...
5565 (exec_target_open): ... this.
5566 * gdbcore.h (core_target_open): Declare.
5567 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
5568 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
5569 add_inf_child_target.
5570 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
5571 add_inf_child_target.
5572 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
5573 add_inf_child_target.
5574 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
5575 add_inf_child_target.
5576 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
5577 add_inf_child_target.
5578 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
5579 add_inf_child_target.
5580 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
5581 add_inf_child_target.
5582 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
5583 add_inf_child_target.
5584 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
5585 add_inf_child_target.
5586 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
5587 add_inf_child_target.
5588 * inf-child.c (inf_child_target_info): New.
5589 (inf_child_target::info): New.
5590 (inf_child_open_target): Remove 'target' parameter. Use
5591 get_native_target instead.
5592 (inf_child_target::open): Delete.
5593 (add_inf_child_target): New.
5594 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
5597 (add_inf_child_target): Declare.
5598 (inf_child_open_target): Declare.
5599 * linux-thread-db.c (thread_db_target_info): New.
5600 (thread_db_target) <shortname, longname, doc>: Delete.
5602 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
5603 add_inf_child_target.
5604 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
5605 add_inf_child_target.
5606 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
5607 add_inf_child_target.
5608 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
5609 add_inf_child_target.
5610 * make-target-delegates (print_class): Adjust.
5611 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
5612 add_inf_child_target.
5613 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
5614 add_inf_child_target.
5615 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
5616 add_inf_child_target.
5617 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
5618 add_inf_child_target.
5619 * nto-procfs.c (nto_native_target_info): New.
5620 (nto_procfs_target_native) <shortname, longname, doc>:
5623 (nto_procfs_target_info): New.
5624 (nto_procfs_target_procfs) <shortname, longname, doc>:
5627 (init_procfs_targets): Adjust.
5628 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5629 add_inf_child_target.
5630 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5631 add_inf_child_target.
5632 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5633 add_inf_child_target.
5634 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5635 add_inf_child_target.
5636 * ravenscar-thread.c (ravenscar_target_info): New.
5637 (ravenscar_thread_target) <shortname, longname, doc>:
5640 * record-btrace.c (record_btrace_target_info):
5641 (record_btrace_target) <shortname, longname, doc>: Delete.
5643 (record_btrace_target::open): Rename to ...
5644 (record_btrace_target_open): ... this. Adjust.
5645 * record-full.c (record_longname, record_doc): New.
5646 (record_full_base_target) <shortname, longname, doc>: Delete.
5648 (record_full_target_info): New.
5649 (record_full_target): <shortname>: Delete.
5651 (record_full_core_open_1, record_full_open_1): Update comments.
5652 (record_full_base_target::open): Rename to ...
5653 (record_full_open): ... this.
5654 (cmd_record_full_restore): Update.
5655 (_initialize_record_full): Update.
5656 * remote-sim.c (remote_sim_target_info): New.
5657 (gdbsim_target) <shortname, longname, doc>: Delete.
5659 (gdbsim_target::open): Rename to ...
5660 (gdbsim_target_open): ... this.
5661 (_initialize_remote_sim): Adjust.
5662 * remote.c (remote_doc): New.
5663 (remote_target_info): New.
5664 (remote_target) <shortname, longname, doc>: Delete.
5666 (extended_remote_target_info): New.
5667 (extended_remote_target) <shortname, longname, doc>: Delete.
5669 (remote_target::open_1): Make static. Adjust.
5670 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5671 * s390-linux-nat.c (_initialize_s390_nat): Use
5672 add_inf_child_target.
5673 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5674 add_inf_child_target.
5675 * sol-thread.c (thread_db_target_info): New.
5676 (sol_thread_target) <shortname, longname, doc>: Delete.
5678 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5679 add_inf_child_target.
5680 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5681 add_inf_child_target.
5682 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5683 add_inf_child_target.
5684 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5685 add_inf_child_target.
5686 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5687 add_inf_child_target.
5688 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5689 add_inf_child_target.
5690 * spu-linux-nat.c (_initialize_spu_nat): Use
5691 add_inf_child_target.
5692 * spu-multiarch.c (spu_multiarch_target_info): New.
5693 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5695 * target-delegates.c: Regenerate.
5696 * target.c: Include <unordered_map>.
5697 (target_ops_p): Delete.
5698 (DEF_VEC_P(target_ops_p)): Delete.
5699 (target_factories): New.
5700 (test_target_info): New.
5701 (test_target_ops::info): New.
5702 (open_target): Adjust to use target_factories.
5703 (add_target_with_completer): Rename to ...
5704 (add_target): ... this. Change prototype. Register target_info
5705 and open callback in target_factories. Register target_info in
5706 command context instead of target_ops.
5707 (add_target): Delete old implementation.
5708 (add_deprecated_target_alias): Change prototype. Adjust.
5709 (the_native_target): New.
5710 (set_native_target, get_native_target): New.
5711 (find_default_run_target): Use the_native_target.
5712 (find_attach_target, find_run_target): Simplify.
5713 (target_ops::open): Delete.
5714 (dummy_target_info): New.
5715 (dummy_target::shortname, dummy_target::longname)
5716 (dummy_target::doc): Delete.
5717 (dummy_target::info): New.
5718 (debug_target::shortname, debug_target::longname)
5719 (debug_target::doc): Delete.
5720 (debug_target::info): New.
5721 * target.h (struct target_info): New.
5722 (target_ops::~target_ops): Add comment.
5723 (target_ops::info): New.
5724 (target_ops::shortname, target_ops::longname, target_ops::doc): No
5725 longer virtual. Implement in terms of target_info.
5726 (set_native_target, get_native_target): Declare.
5727 (target_open_ftype): New.
5728 (add_target, add_target_with_completer)
5729 (add_deprecated_target_alias): Change prototype.
5730 (test_target) <shortname, longname, doc>: Delete.
5732 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
5733 add_inf_child_target.
5734 * tracefile-tfile.c (tfile_target_info): New.
5735 (tfile_target) <shortname, longname, doc>: Delete.
5737 (tfile_target::open): Rename to ...
5738 (tfile_target_open): ... this.
5739 (_initialize_tracefile_tfile): Adjust.
5740 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
5741 add_inf_child_target.
5742 * windows-nat.c (_initialize_windows_nat): Use
5743 add_inf_child_target.
5744 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
5745 add_inf_child_target.
5747 2018-05-02 Pedro Alves <palves@redhat.com>
5749 * linux-nat.h (linux_nat_target) <low_new_thread,
5750 low_delete_thread, low_new_fork, low_forget_process,
5751 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
5752 New virtual methods.
5753 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5754 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
5755 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
5756 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5757 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
5759 * linux-fork.c (delete_fork): Adjust to call low method.
5760 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
5761 (linux_nat_new_fork, linux_nat_forget_process_hook)
5762 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
5763 (linux_nat_status_is_event):
5764 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
5765 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
5767 (sigtrap_is_event): Rename to ...
5768 (linux_nat_target::low_status_is_event): ... this.
5769 (linux_nat_set_status_is_event): Delete.
5770 (save_stop_reason, linux_nat_wait_1)
5771 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
5773 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5774 (linux_nat_set_new_fork, linux_nat_set_forget_process)
5775 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5776 (linux_nat_set_prepare_to_resume): Delete.
5777 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
5778 low virtual methods.
5779 * amd64-linux-nat.c: Likewise.
5780 * arm-linux-nat.c: Likewise.
5781 * i386-linux-nat.c: Likewise.
5782 * ia64-linux-nat.c: Likewise.
5783 * mips-linux-nat.c: Likewise.
5784 * ppc-linux-nat.c: Likewise.
5785 * s390-linux-nat.c: Likewise.
5786 * sparc64-linux-nat.c: Likewise.
5787 * x86-linux-nat.c: Likewise.
5788 * x86-linux-nat.h: Include "nat/x86-linux.h".
5789 (x86_linux_nat_target) <low_new_fork, low_forget_process,
5790 low_prepare_to_resume, low_new_thread, low_delete_thread>:
5793 2018-05-02 Pedro Alves <palves@redhat.com>
5795 * target.h (target_ops)
5796 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5797 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
5798 stopped_by_watchpoint, have_continuable_watchpoint,
5799 stopped_data_address, watchpoint_addr_within_range,
5800 can_accel_watchpoint_condition, can_run, thread_alive,
5801 has_all_memory, has_memory, has_stack, has_registers,
5802 has_execution, can_async_p, is_async_p, supports_non_stop,
5803 always_non_stop_p, can_execute_reverse, supports_multi_process,
5804 supports_enable_disable_tracepoint,
5805 supports_disable_randomization, supports_string_tracing,
5806 supports_evaluation_of_breakpoint_conditions,
5807 can_run_breakpoint_commands, filesystem_is_local,
5808 can_download_tracepoint, get_trace_state_variable_value,
5809 set_trace_notes, get_tib_address, use_agent, can_use_agent,
5810 record_is_replaying, record_will_replay,
5811 augmented_libraries_svr4_read>: Adjust to return bool.
5812 * aarch64-linux-nat.c: All implementations adjusted.
5813 * aix-thread.c: All implementations adjusted.
5814 * arm-linux-nat.c: All implementations adjusted.
5815 * breakpoint.c: All implementations adjusted.
5816 * bsd-kvm.c: All implementations adjusted.
5817 * bsd-uthread.c: All implementations adjusted.
5818 * corelow.c: All implementations adjusted.
5819 * ctf.c: All implementations adjusted.
5820 * darwin-nat.c: All implementations adjusted.
5821 * darwin-nat.h: All implementations adjusted.
5822 * exec.c: All implementations adjusted.
5823 * fbsd-nat.c: All implementations adjusted.
5824 * fbsd-nat.h: All implementations adjusted.
5825 * gnu-nat.c: All implementations adjusted.
5826 * gnu-nat.h: All implementations adjusted.
5827 * go32-nat.c: All implementations adjusted.
5828 * ia64-linux-nat.c: All implementations adjusted.
5829 * inf-child.c: All implementations adjusted.
5830 * inf-child.h: All implementations adjusted.
5831 * inf-ptrace.c: All implementations adjusted.
5832 * inf-ptrace.h: All implementations adjusted.
5833 * linux-nat.c: All implementations adjusted.
5834 * linux-nat.h: All implementations adjusted.
5835 * mips-linux-nat.c: All implementations adjusted.
5836 * nto-procfs.c: All implementations adjusted.
5837 * ppc-linux-nat.c: All implementations adjusted.
5838 * procfs.c: All implementations adjusted.
5839 * ravenscar-thread.c: All implementations adjusted.
5840 * record-btrace.c: All implementations adjusted.
5841 * record-full.c: All implementations adjusted.
5842 * remote-sim.c: All implementations adjusted.
5843 * remote.c: All implementations adjusted.
5844 * s390-linux-nat.c: All implementations adjusted.
5845 * sol-thread.c: All implementations adjusted.
5846 * spu-multiarch.c: All implementations adjusted.
5847 * target-delegates.c: All implementations adjusted.
5848 * target.c: All implementations adjusted.
5849 * target.h: All implementations adjusted.
5850 * tracefile-tfile.c: All implementations adjusted.
5851 * tracefile.c: All implementations adjusted.
5852 * tracefile.h: All implementations adjusted.
5853 * windows-nat.c: All implementations adjusted.
5854 * x86-linux-nat.h: All implementations adjusted.
5855 * x86-nat.h: All implementations adjusted.
5857 2018-05-02 Pedro Alves <palves@redhat.com>
5859 * make-target-delegates (scan_target_h): Don't trim lines here.
5860 Replace sequences of tabs and/or whitespace with a single
5862 (top level, parsing methods): Trim each line before processing it
5865 2018-05-02 Pedro Alves <palves@redhat.com>
5866 John Baldwin <jhb@freebsd.org>
5868 * target.h (enum strata) <debug_stratum>: New.
5869 (struct target_ops) <all delegation methods>: Replace by C++
5870 virtual methods, and drop "to_" prefix. All references updated
5872 <to_shortname, to_longname, to_doc, to_data,
5873 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
5874 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
5875 virtual methods. All references updated throughout.
5876 <can_attach, supports_terminal_ours, can_create_inferior,
5877 get_thread_control_capabilities, attach_no_wait>: New
5879 <insert_breakpoint, remove_breakpoint>: Now
5880 TARGET_DEFAULT_NORETURN methods.
5881 <info_proc>: Now returns bool.
5883 (OPS_MAGIC): Delete.
5884 (current_target): Delete. All references replaced by references
5886 (target_stack): ... this. New.
5887 (target_shortname, target_longname): Adjust.
5888 (target_can_run): Now a function declaration.
5889 (default_child_has_all_memory, default_child_has_memory)
5890 (default_child_has_stack, default_child_has_registers)
5891 (default_child_has_execution): Remove target_ops parameter.
5892 (complete_target_initialization): Delete.
5893 (memory_breakpoint_target): New template class.
5894 (test_target_ops): Refactor as a C++ class with virtual methods.
5895 * make-target-delegates (NAME_PART): Tighten.
5896 (POINTER_PART, CP_SYMBOL): New.
5897 (SIMPLE_RETURN_PART): Reimplement.
5898 (VEC_RETURN_PART): Expect less.
5899 (RETURN_PART, VIRTUAL_PART): New.
5900 (METHOD): Adjust to C++ virtual methods.
5901 (scan_target_h): Remove reference to C99.
5902 (dname): Output "target_ops::" prefix.
5903 (write_function_header): Adjust to output a C++ class method.
5904 (write_declaration): New.
5905 (write_delegator): Adjust to output a C++ class method.
5906 (tdname): Output "dummy_target::" prefix.
5907 (write_tdefault, write_debugmethod): Adjust to output a C++ class
5909 (tdefault_names, debug_names): Delete.
5910 (return_types, tdefaults, styles, argtypes_array): New.
5911 (top level): All methods are delegators.
5913 (top level): Print dummy_target and debug_target classes.
5914 * target-delegates.c: Regenerate.
5915 * target-debug.h (target_debug_print_enum_info_proc_what)
5916 (target_debug_print_thread_control_capabilities)
5917 (target_debug_print_thread_info_p): New.
5918 * target.c (dummy_target): Delete.
5919 (the_dummy_target, the_debug_target): New.
5920 (target_stack): Now extern.
5921 (set_targetdebug): Push/unpush debug target.
5922 (default_child_has_all_memory, default_child_has_memory)
5923 (default_child_has_stack, default_child_has_registers)
5924 (default_child_has_execution): Remove target_ops parameter.
5925 (complete_target_initialization): Delete.
5926 (add_target_with_completer): No longer call
5927 complete_target_initialization.
5928 (target_supports_terminal_ours): Use regular delegation.
5929 (update_current_target): Delete.
5930 (push_target): No longer check magic number. Don't call
5931 update_current_target.
5932 (unpush_target): Don't call update_current_target.
5933 (target_is_pushed): No longer check magic number.
5934 (target_require_runnable): Skip for all stratums over
5936 (target_ops::info_proc): New.
5937 (target_info_proc): Use find_target_at and
5938 find_default_run_target.
5939 (target_supports_disable_randomization): Use regular delegation.
5940 (target_get_osdata): Use find_target_at.
5941 (target_ops::open, target_ops::close, target_ops::can_attach)
5942 (target_ops::attach, target_ops::can_create_inferior)
5943 (target_ops::create_inferior, target_ops::can_run)
5944 (target_can_run): New.
5945 (default_fileio_target): Use regular delegation.
5946 (target_ops::fileio_open, target_ops::fileio_pwrite)
5947 (target_ops::fileio_pread, target_ops::fileio_fstat)
5948 (target_ops::fileio_close, target_ops::fileio_unlink)
5949 (target_ops::fileio_readlink): New.
5950 (target_fileio_open_1, target_fileio_unlink)
5951 (target_fileio_readlink): Always call the target method. Handle
5953 (return_zero, return_zero_has_execution): Delete.
5954 (init_dummy_target): Delete.
5955 (dummy_target::dummy_target, dummy_target::shortname)
5956 (dummy_target::longname, dummy_target::doc)
5957 (debug_target::debug_target, debug_target::shortname)
5958 (debug_target::longname, debug_target::doc): New.
5959 (target_supports_delete_record): Use regular delegation.
5960 (setup_target_debug): Delete.
5961 (maintenance_print_target_stack): Skip debug_stratum.
5962 (initialize_targets): Instantiate the_dummy_target and
5964 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
5966 (target_auxv_search, fprint_target_auxv): Adjust.
5967 (info_auxv_command): Adjust to use target_stack.
5968 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
5969 * exceptions.c (print_flush): Handle a NULL target_stack.
5970 * regcache.c (target_ops_no_register): Refactor as class with
5973 * exec.c (exec_target): New class.
5974 (exec_ops): Now an exec_target.
5975 (exec_open, exec_close_1, exec_get_section_table)
5976 (exec_xfer_partial, exec_files_info, exec_has_memory)
5977 (exec_make_note_section): Refactor as exec_target methods.
5978 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
5980 (exec_target::find_memory_regions): New.
5981 (_initialize_exec): Don't call init_exec_ops.
5982 * gdbcore.h (exec_file_clear): Delete.
5984 * corefile.c (core_target): Delete.
5985 (core_file_command): Adjust.
5986 * corelow.c (core_target): New class.
5987 (the_core_target): New.
5988 (core_close): Remove target_ops parameter.
5989 (core_close_cleanup): Adjust.
5990 (core_target::close): New.
5991 (core_open, core_detach, get_core_registers, core_files_info)
5992 (core_xfer_partial, core_thread_alive, core_read_description)
5993 (core_pid_to_str, core_thread_name, core_has_memory)
5994 (core_has_stack, core_has_registers, core_info_proc): Rework as
5995 core_target methods.
5996 (ignore, core_remove_breakpoint, init_core_ops): Delete.
5997 (_initialize_corelow): Initialize the_core_target.
5998 * gdbcore.h (core_target): Delete.
5999 (the_core_target): New.
6001 * ctf.c: (ctf_target): New class.
6002 (ctf_ops): Now a ctf_target.
6003 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
6004 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
6005 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
6007 (init_ctf_ops): Delete.
6008 (_initialize_ctf): Don't call it.
6009 * tracefile-tfile.c (tfile_target): New class.
6010 (tfile_ops): Now a tfile_target.
6011 (tfile_open, tfile_close, tfile_files_info)
6012 (tfile_get_tracepoint_status, tfile_trace_find)
6013 (tfile_fetch_registers, tfile_xfer_partial)
6014 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
6015 Refactor as tfile_target methods.
6016 (tfile_xfer_partial_features): Remove target_ops parameter.
6017 (init_tfile_ops): Delete.
6018 (_initialize_tracefile_tfile): Don't call it.
6019 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
6020 (tracefile_has_stack, tracefile_has_registers)
6021 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
6022 tracefile_target methods.
6023 (init_tracefile_ops): Delete.
6024 (tracefile_target::tracefile_target): New.
6025 * tracefile.h: Include "target.h".
6026 (tracefile_target): New class.
6027 (init_tracefile_ops): Delete.
6029 * spu-multiarch.c (spu_multiarch_target): New class.
6030 (spu_ops): Now a spu_multiarch_target.
6031 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
6032 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
6033 (spu_search_memory, spu_mourn_inferior): Refactor as
6034 spu_multiarch_target methods.
6035 (init_spu_ops): Delete.
6036 (_initialize_spu_multiarch): Remove references to init_spu_ops,
6037 complete_target_initialization.
6039 * ravenscar-thread.c (ravenscar_thread_target): New class.
6040 (ravenscar_ops): Now a ravenscar_thread_target.
6041 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
6042 (ravenscar_thread_alive, ravenscar_pid_to_str)
6043 (ravenscar_fetch_registers, ravenscar_store_registers)
6044 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
6045 (ravenscar_stopped_by_hw_breakpoint)
6046 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
6047 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
6048 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
6050 (init_ravenscar_thread_ops): Delete.
6051 (_initialize_ravenscar): Remove references to
6052 init_ravenscar_thread_ops and complete_target_initialization.
6054 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
6055 (bsd_uthread_target): New class.
6056 (bsd_uthread_ops): Now a bsd_uthread_target.
6057 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
6058 (bsd_uthread_close, bsd_uthread_mourn_inferior)
6059 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
6060 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
6061 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
6062 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
6063 (bsd_uthread_target): Delete function.
6064 (_initialize_bsd_uthread): Remove reference to
6065 complete_target_initialization.
6067 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
6068 (target_bfd): ... this new class.
6069 (target_bfd_xfer_partial, target_bfd_get_section_table)
6070 (target_bfd_close): Refactor as target_bfd methods.
6071 (target_bfd::~target_bfd): New.
6072 (target_bfd_reopen): Adjust.
6073 (target_bfd::close): New.
6075 * record-btrace.c (record_btrace_target): New class.
6076 (record_btrace_ops): Now a record_btrace_target.
6077 (record_btrace_open, record_btrace_stop_recording)
6078 (record_btrace_disconnect, record_btrace_close)
6079 (record_btrace_async, record_btrace_info)
6080 (record_btrace_insn_history, record_btrace_insn_history_range)
6081 (record_btrace_insn_history_from, record_btrace_call_history)
6082 (record_btrace_call_history_range)
6083 (record_btrace_call_history_from, record_btrace_record_method)
6084 (record_btrace_is_replaying, record_btrace_will_replay)
6085 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
6086 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
6087 (record_btrace_store_registers, record_btrace_prepare_to_store)
6088 (record_btrace_to_get_unwinder)
6089 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
6090 (record_btrace_commit_resume, record_btrace_wait)
6091 (record_btrace_stop, record_btrace_can_execute_reverse)
6092 (record_btrace_stopped_by_sw_breakpoint)
6093 (record_btrace_supports_stopped_by_sw_breakpoint)
6094 (record_btrace_stopped_by_hw_breakpoint)
6095 (record_btrace_supports_stopped_by_hw_breakpoint)
6096 (record_btrace_update_thread_list, record_btrace_thread_alive)
6097 (record_btrace_goto_begin, record_btrace_goto_end)
6098 (record_btrace_goto, record_btrace_stop_replaying_all)
6099 (record_btrace_execution_direction)
6100 (record_btrace_prepare_to_generate_core)
6101 (record_btrace_done_generating_core): Refactor as
6102 record_btrace_target methods.
6103 (init_record_btrace_ops): Delete.
6104 (_initialize_record_btrace): Remove reference to
6105 init_record_btrace_ops.
6106 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
6107 the execution_direction global.
6108 (record_full_base_target, record_full_target)
6109 (record_full_core_target): New classes.
6110 (record_full_ops): Now a record_full_target.
6111 (record_full_core_ops): Now a record_full_core_target.
6112 (record_full_target::detach, record_full_target::disconnect)
6113 (record_full_core_target::disconnect)
6114 (record_full_target::mourn_inferior, record_full_target::kill):
6116 (record_full_open, record_full_close, record_full_async): Refactor
6117 as methods of the record_full_base_target class.
6118 (record_full_resume, record_full_commit_resume): Refactor
6119 as methods of the record_full_target class.
6120 (record_full_wait, record_full_stopped_by_watchpoint)
6121 (record_full_stopped_data_address)
6122 (record_full_stopped_by_sw_breakpoint)
6123 (record_full_supports_stopped_by_sw_breakpoint)
6124 (record_full_stopped_by_hw_breakpoint)
6125 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
6126 methods of the record_full_base_target class.
6127 (record_full_store_registers, record_full_xfer_partial)
6128 (record_full_insert_breakpoint, record_full_remove_breakpoint):
6129 Refactor as methods of the record_full_target class.
6130 (record_full_can_execute_reverse, record_full_get_bookmark)
6131 (record_full_goto_bookmark, record_full_execution_direction)
6132 (record_full_record_method, record_full_info, record_full_delete)
6133 (record_full_is_replaying, record_full_will_replay)
6134 (record_full_goto_begin, record_full_goto_end, record_full_goto)
6135 (record_full_stop_replaying): Refactor as methods of the
6136 record_full_base_target class.
6137 (record_full_core_resume, record_full_core_kill)
6138 (record_full_core_fetch_registers)
6139 (record_full_core_prepare_to_store)
6140 (record_full_core_store_registers, record_full_core_xfer_partial)
6141 (record_full_core_insert_breakpoint)
6142 (record_full_core_remove_breakpoint)
6143 (record_full_core_has_execution): Refactor
6144 as methods of the record_full_core_target class.
6145 (record_full_base_target::supports_delete_record): New.
6146 (init_record_full_ops): Delete.
6147 (init_record_full_core_ops): Delete.
6148 (record_full_save): Refactor as method of the
6149 record_full_base_target class.
6150 (_initialize_record_full): Remove references to
6151 init_record_full_ops and init_record_full_core_ops.
6153 * remote.c (remote_target, extended_remote_target): New classes.
6154 (remote_ops): Now a remote_target.
6155 (extended_remote_ops): Now an extended_remote_target.
6156 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
6157 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
6158 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
6159 (remote_pass_signals, remote_set_syscall_catchpoint)
6160 (remote_program_signals, )
6161 (remote_thread_always_alive): Remove target_ops parameter.
6162 (remote_thread_alive, remote_thread_name)
6163 (remote_update_thread_list, remote_threads_extra_info)
6164 (remote_static_tracepoint_marker_at)
6165 (remote_static_tracepoint_markers_by_strid)
6166 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
6167 (remote_open): Refactor as methods of remote_target.
6168 (extended_remote_open, extended_remote_detach)
6169 (extended_remote_attach, extended_remote_post_attach):
6170 (extended_remote_supports_disable_randomization)
6171 (extended_remote_create_inferior): : Refactor as method of
6172 extended_remote_target.
6173 (remote_set_permissions, remote_open_1, remote_detach)
6174 (remote_follow_fork, remote_follow_exec, remote_disconnect)
6175 (remote_resume, remote_commit_resume, remote_stop)
6176 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
6177 (remote_terminal_ours, remote_wait, remote_fetch_registers)
6178 (remote_prepare_to_store, remote_store_registers)
6179 (remote_flash_erase, remote_flash_done, remote_files_info)
6180 (remote_kill, remote_mourn, remote_insert_breakpoint)
6181 (remote_remove_breakpoint, remote_insert_watchpoint)
6182 (remote_watchpoint_addr_within_range)
6183 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
6184 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
6185 (remote_supports_stopped_by_sw_breakpoint)
6186 (remote_stopped_by_hw_breakpoint)
6187 (remote_supports_stopped_by_hw_breakpoint)
6188 (remote_stopped_by_watchpoint, remote_stopped_data_address)
6189 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
6190 (remote_verify_memory): Refactor as methods of remote_target.
6191 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
6193 (remote_xfer_partial, remote_get_memory_xfer_limit)
6194 (remote_search_memory, remote_rcmd, remote_memory_map)
6195 (remote_pid_to_str, remote_get_thread_local_address)
6196 (remote_get_tib_address, remote_read_description): Refactor as
6197 methods of remote_target.
6198 (remote_target::fileio_open, remote_target::fileio_pwrite)
6199 (remote_target::fileio_pread, remote_target::fileio_close): New.
6200 (remote_hostio_readlink, remote_hostio_fstat)
6201 (remote_filesystem_is_local, remote_can_execute_reverse)
6202 (remote_supports_non_stop, remote_supports_disable_randomization)
6203 (remote_supports_multi_process, remote_supports_cond_breakpoints)
6204 (remote_supports_enable_disable_tracepoint)
6205 (remote_supports_string_tracing)
6206 (remote_can_run_breakpoint_commands, remote_trace_init)
6207 (remote_download_tracepoint, remote_can_download_tracepoint)
6208 (remote_download_trace_state_variable, remote_enable_tracepoint)
6209 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
6210 (remote_trace_start, remote_get_trace_status)
6211 (remote_get_tracepoint_status, remote_trace_stop)
6212 (remote_trace_find, remote_get_trace_state_variable_value)
6213 (remote_save_trace_data, remote_get_raw_trace_data)
6214 (remote_set_disconnected_tracing, remote_core_of_thread)
6215 (remote_set_circular_trace_buffer, remote_traceframe_info)
6216 (remote_get_min_fast_tracepoint_insn_len)
6217 (remote_set_trace_buffer_size, remote_set_trace_notes)
6218 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
6219 (remote_disable_btrace, remote_teardown_btrace)
6220 (remote_read_btrace, remote_btrace_conf)
6221 (remote_augmented_libraries_svr4_read, remote_load)
6222 (remote_pid_to_exec_file, remote_can_do_single_step)
6223 (remote_execution_direction, remote_thread_handle_to_thread_info):
6224 Refactor as methods of remote_target.
6225 (init_remote_ops, init_extended_remote_ops): Delete.
6226 (remote_can_async_p, remote_is_async_p, remote_async)
6227 (remote_thread_events, remote_upload_tracepoints)
6228 (remote_upload_trace_state_variables): Refactor as methods of
6230 (_initialize_remote): Remove references to init_remote_ops and
6231 init_extended_remote_ops.
6233 * remote-sim.c (gdbsim_target): New class.
6234 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
6235 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
6236 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
6237 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
6238 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
6239 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
6240 Refactor as methods of gdbsim_target.
6241 (gdbsim_ops): Now a gdbsim_target.
6242 (init_gdbsim_ops): Delete.
6243 (gdbsim_cntrl_c): Adjust.
6244 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
6246 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
6247 (the_amd64_linux_nat_target): New.
6248 (amd64_linux_fetch_inferior_registers)
6249 (amd64_linux_store_inferior_registers): Refactor as methods of
6250 amd64_linux_nat_target.
6251 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
6252 * i386-linux-nat.c: Don't include "linux-nat.h".
6253 (i386_linux_nat_target): New class.
6254 (the_i386_linux_nat_target): New.
6255 (i386_linux_fetch_inferior_registers)
6256 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
6257 as methods of i386_linux_nat_target.
6258 (_initialize_i386_linux_nat): Adjust. Set linux_target.
6259 * inf-child.c (inf_child_ops): Delete.
6260 (inf_child_fetch_inferior_registers)
6261 (inf_child_store_inferior_registers): Delete.
6262 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
6263 methods of inf_child_target.
6264 (inf_child_target::supports_terminal_ours)
6265 (inf_child_target::terminal_init)
6266 (inf_child_target::terminal_inferior)
6267 (inf_child_target::terminal_ours_for_output)
6268 (inf_child_target::terminal_ours, inf_child_target::interrupt)
6269 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
6271 (inf_child_open, inf_child_disconnect, inf_child_close)
6272 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
6273 (inf_child_post_startup_inferior, inf_child_can_run)
6274 (inf_child_pid_to_exec_file): Refactor as methods of
6276 (inf_child_follow_fork): Delete.
6277 (inf_child_target::can_create_inferior)
6278 (inf_child_target::can_attach): New.
6279 (inf_child_target::has_all_memory, inf_child_target::has_memory)
6280 (inf_child_target::has_stack, inf_child_target::has_registers)
6281 (inf_child_target::has_execution): New.
6282 (inf_child_fileio_open, inf_child_fileio_pwrite)
6283 (inf_child_fileio_pread, inf_child_fileio_fstat)
6284 (inf_child_fileio_close, inf_child_fileio_unlink)
6285 (inf_child_fileio_readlink, inf_child_use_agent)
6286 (inf_child_can_use_agent): Refactor as methods of
6288 (return_zero, inf_child_target): Delete.
6289 (inf_child_target::inf_child_target): New.
6290 * inf-child.h: Include "target.h".
6291 (inf_child_target): Delete function prototype.
6292 (inf_child_target): New class.
6293 (inf_child_open_target, inf_child_mourn_inferior)
6294 (inf_child_maybe_unpush_target): Delete.
6295 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
6296 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
6297 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
6298 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
6299 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
6300 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
6301 (inf_ptrace_wait, inf_ptrace_xfer_partial)
6302 (inf_ptrace_thread_alive, inf_ptrace_files_info)
6303 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
6304 methods of inf_ptrace_target.
6305 (inf_ptrace_target): Delete function.
6306 * inf-ptrace.h: Include "inf-child.h".
6307 (inf_ptrace_target): Delete function declaration.
6308 (inf_ptrace_target): New class.
6309 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
6310 * linux-nat.c (linux_target): New.
6311 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
6312 (linux_nat_target::~linux_nat_target): New.
6313 (linux_child_post_attach, linux_child_post_startup_inferior)
6314 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
6315 (linux_child_remove_fork_catchpoint)
6316 (linux_child_insert_vfork_catchpoint)
6317 (linux_child_remove_vfork_catchpoint)
6318 (linux_child_insert_exec_catchpoint)
6319 (linux_child_remove_exec_catchpoint)
6320 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
6321 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
6322 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
6323 (linux_nat_stopped_data_address)
6324 (linux_nat_stopped_by_sw_breakpoint)
6325 (linux_nat_supports_stopped_by_sw_breakpoint)
6326 (linux_nat_stopped_by_hw_breakpoint)
6327 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
6328 (linux_nat_kill, linux_nat_mourn_inferior)
6329 (linux_nat_xfer_partial, linux_nat_thread_alive)
6330 (linux_nat_update_thread_list, linux_nat_pid_to_str)
6331 (linux_nat_thread_name, linux_child_pid_to_exec_file)
6332 (linux_child_static_tracepoint_markers_by_strid)
6333 (linux_nat_is_async_p, linux_nat_can_async_p)
6334 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
6335 (linux_nat_supports_multi_process)
6336 (linux_nat_supports_disable_randomization, linux_nat_async)
6337 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
6338 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
6339 (linux_nat_fileio_open, linux_nat_fileio_readlink)
6340 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
6341 methods of linux_nat_target.
6342 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
6343 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
6345 (check_stopped_by_watchpoint): Adjust.
6346 (linux_xfer_partial): Delete.
6347 (linux_target_install_ops, linux_target, linux_nat_add_target):
6349 (linux_nat_target::linux_nat_target): New.
6350 * linux-nat.h: Include "inf-ptrace.h".
6351 (linux_nat_target): New.
6352 (linux_target, linux_target_install_ops, linux_nat_add_target):
6353 Delete function declarations.
6354 (linux_target): Declare global.
6355 * linux-thread-db.c (thread_db_target): New.
6356 (thread_db_target::thread_db_target): New.
6357 (thread_db_ops): Delete.
6358 (the_thread_db_target): New.
6359 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
6360 (thread_db_update_thread_list, thread_db_pid_to_str)
6361 (thread_db_extra_thread_info)
6362 (thread_db_thread_handle_to_thread_info)
6363 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
6364 (thread_db_resume): Refactor as methods of thread_db_target.
6365 (init_thread_db_ops): Delete.
6366 (_initialize_thread_db): Remove reference to init_thread_db_ops.
6367 * x86-linux-nat.c: Don't include "linux-nat.h".
6368 (super_post_startup_inferior): Delete.
6369 (x86_linux_nat_target::~x86_linux_nat_target): New.
6370 (x86_linux_child_post_startup_inferior)
6371 (x86_linux_read_description, x86_linux_enable_btrace)
6372 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
6373 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
6374 methods of x86_linux_nat_target.
6375 (x86_linux_create_target): Delete. Bits folded ...
6376 (x86_linux_add_target): ... here. Now takes a linux_nat_target
6378 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
6379 (x86_linux_nat_target): New class.
6380 (x86_linux_create_target): Delete.
6381 (x86_linux_add_target): Now takes a linux_nat_target pointer.
6382 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
6383 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
6384 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
6385 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
6386 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
6388 (x86_use_watchpoints): Delete.
6389 * x86-nat.h: Include "breakpoint.h" and "target.h".
6390 (x86_use_watchpoints): Delete.
6391 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
6392 (x86_stopped_by_watchpoint, x86_stopped_data_address)
6393 (x86_insert_watchpoint, x86_remove_watchpoint)
6394 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
6395 (x86_stopped_by_hw_breakpoint): New declarations.
6396 (x86_nat_target): New template class.
6398 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
6399 (the_ppc_linux_nat_target): New.
6400 (ppc_linux_fetch_inferior_registers)
6401 (ppc_linux_can_use_hw_breakpoint)
6402 (ppc_linux_region_ok_for_hw_watchpoint)
6403 (ppc_linux_ranged_break_num_registers)
6404 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
6405 (ppc_linux_insert_mask_watchpoint)
6406 (ppc_linux_remove_mask_watchpoint)
6407 (ppc_linux_can_accel_watchpoint_condition)
6408 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
6409 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
6410 (ppc_linux_watchpoint_addr_within_range)
6411 (ppc_linux_masked_watch_num_registers)
6412 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
6413 (ppc_linux_read_description): Refactor as methods of
6414 ppc_linux_nat_target.
6415 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
6417 * procfs.c (procfs_xfer_partial): Delete forward declaration.
6418 (procfs_target): New class.
6419 (the_procfs_target): New.
6420 (procfs_target): Delete function.
6421 (procfs_auxv_parse, procfs_attach, procfs_detach)
6422 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
6423 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
6424 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
6425 (procfs_create_inferior, procfs_update_thread_list)
6426 (procfs_thread_alive, procfs_pid_to_str)
6427 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
6428 (procfs_stopped_data_address, procfs_insert_watchpoint)
6429 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
6430 (proc_find_memory_regions, procfs_info_proc)
6431 (procfs_make_note_section): Refactor as methods of procfs_target.
6432 (_initialize_procfs): Adjust.
6433 * sol-thread.c (sol_thread_target): New class.
6434 (sol_thread_ops): Now a sol_thread_target.
6435 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
6436 (sol_thread_fetch_registers, sol_thread_store_registers)
6437 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
6438 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
6439 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
6440 (init_sol_thread_ops): Delete.
6441 (_initialize_sol_thread): Adjust. Remove references to
6442 init_sol_thread_ops and complete_target_initialization.
6444 * windows-nat.c (windows_nat_target): New class.
6445 (windows_fetch_inferior_registers)
6446 (windows_store_inferior_registers, windows_resume, windows_wait)
6447 (windows_attach, windows_detach, windows_pid_to_exec_file)
6448 (windows_files_info, windows_create_inferior)
6449 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
6450 (windows_close, windows_pid_to_str, windows_xfer_partial)
6451 (windows_get_tib_address, windows_get_ada_task_ptid)
6452 (windows_thread_name, windows_thread_alive): Refactor as
6453 windows_nat_target methods.
6454 (do_initial_windows_stuff): Adjust.
6455 (windows_target): Delete function.
6456 (_initialize_windows_nat): Adjust.
6458 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
6459 (darwin_mourn_inferior, darwin_kill_inferior)
6460 (darwin_create_inferior, darwin_attach, darwin_detach)
6461 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
6462 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
6463 (darwin_supports_multi_process): Refactor as darwin_nat_target
6465 (darwin_resume_to, darwin_files_info): Delete.
6466 (_initialize_darwin_inferior): Rename to ...
6467 (_initialize_darwin_nat): ... this. Adjust to C++ification.
6468 * darwin-nat.h: Include "inf-child.h".
6469 (darwin_nat_target): New class.
6470 (darwin_complete_target): Delete.
6471 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
6472 (darwin_target): New.
6473 (i386_darwin_fetch_inferior_registers)
6474 (i386_darwin_store_inferior_registers): Refactor as methods of
6476 (darwin_complete_target): Delete, with ...
6477 (_initialize_i386_darwin_nat): ... bits factored out here.
6479 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
6480 (the_alpha_linux_nat_target): New.
6481 (alpha_linux_register_u_offset): Refactor as
6482 alpha_linux_nat_target method.
6483 (_initialize_alpha_linux_nat): Adjust.
6484 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
6485 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6486 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
6487 methods of linux_nat_trad_target.
6488 (linux_trad_target): Delete.
6489 * linux-nat-trad.h (linux_trad_target): Delete function.
6490 (linux_nat_trad_target): New class.
6491 * mips-linux-nat.c (mips_linux_nat_target): New class.
6492 (super_fetch_registers, super_store_registers, super_close):
6494 (the_mips_linux_nat_target): New.
6495 (mips64_linux_regsets_fetch_registers)
6496 (mips64_linux_regsets_store_registers)
6497 (mips64_linux_fetch_registers, mips64_linux_store_registers)
6498 (mips_linux_register_u_offset, mips_linux_read_description)
6499 (mips_linux_can_use_hw_breakpoint)
6500 (mips_linux_stopped_by_watchpoint)
6501 (mips_linux_stopped_data_address)
6502 (mips_linux_region_ok_for_hw_watchpoint)
6503 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6504 (mips_linux_close): Refactor as methods of mips_linux_nat.
6505 (_initialize_mips_linux_nat): Adjust to C++ification.
6507 * aix-thread.c (aix_thread_target): New class.
6508 (aix_thread_ops): Now an aix_thread_target.
6509 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
6510 (aix_thread_fetch_registers, aix_thread_store_registers)
6511 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
6512 (aix_thread_thread_alive, aix_thread_pid_to_str)
6513 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
6514 Refactor as methods of aix_thread_target.
6515 (init_aix_thread_ops): Delete.
6516 (_initialize_aix_thread): Remove references to init_aix_thread_ops
6517 and complete_target_initialization.
6518 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
6519 (rs6000_nat_target): New class.
6520 (the_rs6000_nat_target): New.
6521 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
6522 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
6523 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
6524 (super_create_inferior): Delete.
6525 (_initialize_rs6000_nat): Adjust to C++ification.
6527 * arm-linux-nat.c (arm_linux_nat_target): New class.
6528 (the_arm_linux_nat_target): New.
6529 (arm_linux_fetch_inferior_registers)
6530 (arm_linux_store_inferior_registers, arm_linux_read_description)
6531 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
6532 (arm_linux_remove_hw_breakpoint)
6533 (arm_linux_region_ok_for_hw_watchpoint)
6534 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
6535 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
6536 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
6537 arm_linux_nat_target.
6538 (_initialize_arm_linux_nat): Adjust to C++ification.
6540 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
6541 (the_aarch64_linux_nat_target): New.
6542 (aarch64_linux_fetch_inferior_registers)
6543 (aarch64_linux_store_inferior_registers)
6544 (aarch64_linux_child_post_startup_inferior)
6545 (aarch64_linux_read_description)
6546 (aarch64_linux_can_use_hw_breakpoint)
6547 (aarch64_linux_insert_hw_breakpoint)
6548 (aarch64_linux_remove_hw_breakpoint)
6549 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
6550 (aarch64_linux_region_ok_for_hw_watchpoint)
6551 (aarch64_linux_stopped_data_address)
6552 (aarch64_linux_stopped_by_watchpoint)
6553 (aarch64_linux_watchpoint_addr_within_range)
6554 (aarch64_linux_can_do_single_step): Refactor as methods of
6555 aarch64_linux_nat_target.
6556 (super_post_startup_inferior): Delete.
6557 (_initialize_aarch64_linux_nat): Adjust to C++ification.
6559 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
6560 (the_hppa_linux_nat_target): New.
6561 (hppa_linux_fetch_inferior_registers)
6562 (hppa_linux_store_inferior_registers): Refactor as methods of
6563 hppa_linux_nat_target.
6564 (_initialize_hppa_linux_nat): Adjust to C++ification.
6566 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
6567 (the_ia64_linux_nat_target): New.
6568 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
6569 (ia64_linux_stopped_data_address)
6570 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
6571 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
6572 ia64_linux_nat_target methods.
6573 (super_xfer_partial): Delete.
6574 (_initialize_ia64_linux_nat): Adjust to C++ification.
6576 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
6577 (the_m32r_linux_nat_target): New.
6578 (m32r_linux_fetch_inferior_registers)
6579 (m32r_linux_store_inferior_registers): Refactor as
6580 m32r_linux_nat_target methods.
6581 (_initialize_m32r_linux_nat): Adjust to C++ification.
6583 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
6584 (the_m68k_linux_nat_target): New.
6585 (m68k_linux_fetch_inferior_registers)
6586 (m68k_linux_store_inferior_registers): Refactor as
6587 m68k_linux_nat_target methods.
6588 (_initialize_m68k_linux_nat): Adjust to C++ification.
6590 * s390-linux-nat.c (s390_linux_nat_target): New class.
6591 (the_s390_linux_nat_target): New.
6592 (s390_linux_fetch_inferior_registers)
6593 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
6594 (s390_insert_watchpoint, s390_remove_watchpoint)
6595 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
6596 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
6597 (s390_auxv_parse, s390_read_description): Refactor as methods of
6598 s390_linux_nat_target.
6599 (_initialize_s390_nat): Adjust to C++ification.
6601 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
6602 (the_sparc_linux_nat_target): New.
6603 (_initialize_sparc_linux_nat): Adjust to C++ification.
6604 * sparc-nat.c (sparc_fetch_inferior_registers)
6605 (sparc_store_inferior_registers): Remove target_ops parameter.
6606 * sparc-nat.h (sparc_fetch_inferior_registers)
6607 (sparc_store_inferior_registers): Remove target_ops parameter.
6608 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
6609 (the_sparc64_linux_nat_target): New.
6610 (_initialize_sparc64_linux_nat): Adjust to C++ification.
6612 * spu-linux-nat.c (spu_linux_nat_target): New class.
6613 (the_spu_linux_nat_target): New.
6614 (spu_child_post_startup_inferior, spu_child_post_attach)
6615 (spu_child_wait, spu_fetch_inferior_registers)
6616 (spu_store_inferior_registers, spu_xfer_partial)
6617 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
6619 (_initialize_spu_nat): Adjust to C++ification.
6621 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
6622 (the_tilegx_linux_nat_target): New.
6623 (fetch_inferior_registers, store_inferior_registers):
6624 Refactor as methods.
6625 (_initialize_tile_linux_nat): Adjust to C++ification.
6627 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6628 (the_xtensa_linux_nat_target): New.
6629 (xtensa_linux_fetch_inferior_registers)
6630 (xtensa_linux_store_inferior_registers): Refactor as
6631 xtensa_linux_nat_target methods.
6632 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6634 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6635 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6636 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6637 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6638 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6639 (fbsd_stopped_by_sw_breakpoint)
6640 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6641 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6642 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6643 (fbsd_post_startup_inferior, fbsd_post_attach)
6644 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6645 (fbsd_set_syscall_catchpoint)
6646 (super_xfer_partial, super_resume, super_wait)
6647 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6648 (fbsd_handle_debug_trap): Remove target_ops parameter.
6649 (fbsd_nat_add_target): Delete.
6650 * fbsd-nat.h: Include "inf-ptrace.h".
6651 (fbsd_nat_add_target): Delete.
6652 (USE_SIGTRAP_SIGINFO): Define.
6653 (fbsd_nat_target): New class.
6655 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6656 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6657 (amd64bsd_target): Delete.
6658 * amd64-bsd-nat.h: New file.
6659 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6661 (amd64_fbsd_nat_target): New class.
6662 (the_amd64_fbsd_nat_target): New.
6663 (amd64fbsd_read_description): Refactor as method of
6664 amd64_fbsd_nat_target.
6665 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6666 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6667 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6668 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6669 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6670 (i386bsd_target): Delete.
6671 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6672 (i386bsd_fetch_inferior_registers)
6673 (i386bsd_store_inferior_registers): Declare.
6674 (i386_bsd_nat_target): New class.
6675 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6676 (the_i386_fbsd_nat_target): New.
6677 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6678 i386_fbsd_nat_target methods.
6679 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6680 (_initialize_i386fbsd_nat): Adjust to C++ification.
6681 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6682 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6683 (_initialize_x86_bsd_nat): Adjust to C++ification.
6684 * x86-bsd-nat.h: Include "x86-nat.h".
6685 (x86bsd_target): Delete declaration.
6686 (x86bsd_nat_target): New class.
6688 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6689 (the_aarch64_fbsd_nat_target): New.
6690 (aarch64_fbsd_fetch_inferior_registers)
6691 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6692 aarch64_fbsd_nat_target.
6693 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6694 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
6695 (the_alpha_bsd_nat_target): New.
6696 (alphabsd_fetch_inferior_registers)
6697 (alphabsd_store_inferior_registers): Refactor as
6698 alpha_bsd_nat_target methods.
6699 (_initialize_alphabsd_nat): Refactor as methods of
6700 alpha_bsd_nat_target.
6701 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
6702 (the_amd64_nbsd_nat_target): New.
6703 (_initialize_amd64nbsd_nat): Adjust to C++ification.
6704 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
6705 (the_amd64_obsd_nat_target): New.
6706 (_initialize_amd64obsd_nat): Adjust to C++ification.
6707 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
6708 (the_arm_fbsd_nat_target): New.
6709 (arm_fbsd_fetch_inferior_registers)
6710 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
6711 (_initialize_arm_fbsd_nat): Refactor as methods of
6712 arm_fbsd_nat_target.
6713 (_initialize_arm_fbsd_nat): Adjust to C++ification.
6714 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
6715 (the_arm_netbsd_nat_target): New.
6716 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
6717 arm_netbsd_nat_target.
6718 (_initialize_arm_netbsd_nat): Adjust to C++ification.
6719 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
6720 (the_hppa_nbsd_nat_target): New.
6721 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
6722 hppa_nbsd_nat_target methods.
6723 (_initialize_hppanbsd_nat): Adjust to C++ification.
6724 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
6725 (the_hppa_obsd_nat_target): New.
6726 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
6727 methods of hppa_obsd_nat_target.
6728 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
6730 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
6731 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
6733 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
6734 (_initialize_i386obsd_nat): Use add_target.
6735 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
6736 (the_m68k_bsd_nat_target): New.
6737 (m68kbsd_fetch_inferior_registers)
6738 (m68kbsd_store_inferior_registers): Refactor as methods of
6739 m68k_bsd_nat_target.
6740 (_initialize_m68kbsd_nat): Adjust to C++ification.
6741 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
6742 (the_mips_fbsd_nat_target): New.
6743 (mips_fbsd_fetch_inferior_registers)
6744 (mips_fbsd_store_inferior_registers): Refactor as methods of
6745 mips_fbsd_nat_target.
6746 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
6748 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
6749 (the_mips_nbsd_nat_target): New.
6750 (mipsnbsd_fetch_inferior_registers)
6751 (mipsnbsd_store_inferior_registers): Refactor as methods of
6752 mips_nbsd_nat_target.
6753 (_initialize_mipsnbsd_nat): Adjust to C++ification.
6754 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
6755 (the_mips64_obsd_nat_target): New.
6756 (mips64obsd_fetch_inferior_registers)
6757 (mips64obsd_store_inferior_registers): Refactor as methods of
6758 mips64_obsd_nat_target.
6759 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
6761 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
6763 * nbsd-nat.h: Include "inf-ptrace.h".
6764 (nbsd_nat_target): New class.
6765 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
6766 (obsd_wait): Refactor as methods of obsd_nat_target.
6767 (obsd_add_target): Delete.
6768 * obsd-nat.h: Include "inf-ptrace.h".
6769 (obsd_nat_target): New class.
6770 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
6771 (the_ppc_fbsd_nat_target): New.
6772 (ppcfbsd_fetch_inferior_registers)
6773 (ppcfbsd_store_inferior_registers): Refactor as methods of
6774 ppc_fbsd_nat_target.
6775 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
6777 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
6778 (the_ppc_nbsd_nat_target): New.
6779 (ppcnbsd_fetch_inferior_registers)
6780 (ppcnbsd_store_inferior_registers): Refactor as methods of
6781 ppc_nbsd_nat_target.
6782 (_initialize_ppcnbsd_nat): Adjust to C++ification.
6783 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
6784 (the_ppc_obsd_nat_target): New.
6785 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
6786 methods of ppc_obsd_nat_target.
6787 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
6789 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
6790 (the_sh_nbsd_nat_target): New.
6791 (shnbsd_fetch_inferior_registers)
6792 (shnbsd_store_inferior_registers): Refactor as methods of
6794 (_initialize_shnbsd_nat): Adjust to C++ification.
6795 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
6796 (inf_ptrace_xfer_partial): Delete.
6797 (sparc_xfer_partial, sparc_target): Delete.
6798 * sparc-nat.h (sparc_fetch_inferior_registers)
6799 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
6800 (sparc_target): Delete function declaration.
6801 (sparc_target): New template class.
6802 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
6803 (_initialize_sparcnbsd_nat): Adjust to C++ification.
6804 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
6805 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
6807 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
6808 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
6809 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
6810 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
6812 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
6813 (the_vax_bsd_nat_target): New.
6814 (vaxbsd_fetch_inferior_registers)
6815 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
6817 (_initialize_vaxbsd_nat): Adjust to C++ification.
6819 * bsd-kvm.c (bsd_kvm_target): New class.
6820 (bsd_kvm_ops): Now a bsd_kvm_target.
6821 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
6822 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
6823 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
6825 (bsd_kvm_return_one): Delete.
6826 (bsd_kvm_add_target): Adjust to C++ification.
6828 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
6829 (nto_procfs_target_procfs): New classes.
6830 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
6831 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
6832 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
6833 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
6834 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
6835 (procfs_remove_hw_breakpoint, procfs_resume)
6836 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
6837 (procfs_kill_inferior, procfs_store_registers)
6838 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
6839 as methods of nto_procfs_target.
6840 (nto_procfs_ops): Now an nto_procfs_target_procfs.
6841 (nto_native_ops): Delete.
6842 (procfs_open, procfs_native_open): Delete.
6843 (nto_native_ops): Now an nto_procfs_target_native.
6844 (init_procfs_targets): Adjust to C++ification.
6845 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
6846 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
6847 Refactor as methods of nto_procfs_target.
6849 * go32-nat.c (go32_nat_target): New class.
6850 (the_go32_nat_target): New.
6851 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
6852 (go32_store_registers, go32_xfer_partial, go32_files_info)
6853 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
6854 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
6855 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
6856 (go32_pid_to_str): Refactor as methods of go32_nat_target.
6857 (go32_target): Delete.
6858 (_initialize_go32_nat): Adjust to C++ification.
6860 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
6861 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
6862 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
6863 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
6865 (gnu_target): Delete.
6866 * gnu-nat.h (gnu_target): Delete.
6867 (gnu_nat_target): New class.
6868 * i386-gnu-nat.c (gnu_base_target): New.
6869 (i386_gnu_nat_target): New class.
6870 (the_i386_gnu_nat_target): New.
6871 (_initialize_i386gnu_nat): Adjust to C++ification.
6873 2018-05-02 Pedro Alves <palves@redhat.com>
6875 * bfd-target.c (target_bfd_xclose): Rename to ...
6876 (target_bfd_close): ... this.
6877 (target_bfd_reopen): Adjust.
6878 * target.c (target_close): Remove references to to_xclose.
6879 * target.h (target_ops::to_xclose): Delete.
6880 (target_ops::to_close): Update comments.
6882 2018-05-02 Pedro Alves <palves@redhat.com>
6884 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
6886 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
6887 * inf-ptrace.c (inf_ptrace_register_u_offset)
6888 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6889 (inf_ptrace_store_register, inf_ptrace_store_registers)
6890 (inf_ptrace_trad_target): Move to ...
6891 * linux-nat-trad.c: ... this new file.
6892 * linux-nat-trad.h: New file.
6893 * linux-nat.c (linux_target_install_ops): Make extern.
6894 (linux_trad_target): Delete.
6895 * linux-nat.h (linux_trad_target): Delete declaration.
6896 (linux_target_install_ops): Declare.
6897 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
6900 2018-05-02 Pedro Alves <palves@redhat.com>
6902 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6903 procfs_target/add_target here.
6904 * procfs.c (procfs_target): Make static.
6905 (_initialize_procfs): Call add_target here.
6906 * procfs.h (struct target_ops): Remove forward declaration.
6907 (procfs_target): Remove declaration.
6908 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
6910 2018-05-02 Pedro Alves <palves@redhat.com>
6912 * procfs.c (procfs_stopped_by_watchpoint)
6913 (procfs_insert_watchpoint, procfs_remove_watchpoint)
6914 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
6916 (procfs_use_watchpoints): Delete, move contents...
6917 (procfs_target): ... here.
6918 * procfs.h (procfs_use_watchpoints): Delete declaration.
6919 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6920 procfs_use_watchpoints.
6921 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
6922 procfs_use_watchpoints.
6924 2018-05-02 Tom Tromey <tom@tromey.com>
6927 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
6928 and var_zuinteger_unlimited.
6929 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
6930 and PARAM_ZUINTEGER_UNLIMITED.
6931 (set_parameter_value): Handle var_zuinteger and
6932 var_zuinteger_unlimited.
6933 (add_setshow_generic): Likewise.
6934 (parmpy_init): Likewise.
6936 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
6939 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
6940 pointer is not null before dereferencing it.
6942 2018-04-30 Tom Tromey <tom@tromey.com>
6944 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
6947 2018-04-30 Tom Tromey <tom@tromey.com>
6949 * breakpoint.c (mention): Remove use of is_mi_like_p.
6950 (print_mention_ranged_breakpoint): Likewise.
6951 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
6954 2018-04-30 Tom Tromey <tom@tromey.com>
6956 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
6958 2018-04-30 Tom Tromey <tom@tromey.com>
6960 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
6961 (info_spu_event_command): Remove some uses of is_mi_like_p.
6963 2018-04-30 Tom Tromey <tom@tromey.com>
6965 * python/py-framefilter.c (py_print_single_arg)
6966 (enumerate_locals, py_print_args, py_print_frame): Remove some
6967 uses of is_mi_like_p.
6969 2018-04-30 Tom Tromey <tom@tromey.com>
6972 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
6973 * ui-out.h (ui_out::is_mi_like_p): Now const.
6974 (ui_out::do_is_mi_like_p): Now const.
6975 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
6977 2018-04-30 Tom Tromey <tom@tromey.com>
6979 * varobj.c (varobj_set_visualizer): Use new_reference.
6980 * python/python.c (gdbpy_decode_line): Use new_reference.
6981 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
6984 2018-04-30 Tom Tromey <tom@tromey.com>
6986 * varobj.c (install_new_value): Use new_reference.
6987 * value.h (value_incref): Return void. Swap intro comment with
6989 * value.c (set_value_parent): Use new_reference.
6990 (value_incref): Return void. Update intro comment.
6991 (release_value): Use new_reference.
6992 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
6994 2018-04-30 Tom Tromey <tom@tromey.com>
6996 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
6997 * gdb_bfd.h (new_bfd_ref): Remove.
6998 (gdb_bfd_open): Update comment.
6999 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
7000 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
7001 (gdb_bfd_fdopenr): Use new_reference.
7002 * exec.c (exec_file_attach): Use new_reference.
7004 2018-04-30 Tom Tromey <tom@tromey.com>
7006 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
7009 2018-04-30 Tom Tromey <tom@tromey.com>
7011 * jit.c (jit_read_code_entry): Use type_align.
7012 * i386-tdep.c (i386_gdbarch_init): Don't call
7013 set_gdbarch_long_long_align_bit.
7014 * gdbarch.sh: Remove long_long_align_bit.
7015 * gdbarch.c, gdbarch.h: Rebuild.
7016 * arc-tdep.c (arc_type_align): New function.
7017 (arc_gdbarch_init): Use arc_type_align. Don't call
7018 set_gdbarch_long_long_align_bit.
7020 2018-04-30 Tom Tromey <tom@tromey.com>
7022 * rust-lang.c (rust_type_alignment): Remove.
7023 (rust_composite_type): Use type_align.
7025 2018-04-30 Tom Tromey <tom@tromey.com>
7027 * NEWS: Mention Type.align.
7028 * python/py-type.c (typy_get_alignof): New function.
7029 (type_object_getset): Add "alignof".
7031 2018-04-30 Tom Tromey <tom@tromey.com>
7035 * std-operator.def (UNOP_ALIGNOF): New operator.
7036 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
7038 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
7039 * c-lang.c (c_op_print_tab): Add alignof.
7040 * c-exp.y (ALIGNOF): New token.
7041 (exp): Add "ALIGNOF" production.
7042 (ident_tokens): Add _Alignof and alignof.
7044 2018-04-30 Tom Tromey <tom@tromey.com>
7046 * i386-tdep.c (i386_type_align): New function.
7047 (i386_gdbarch_init): Update.
7048 * gdbarch.sh (type_align): New method.
7049 * gdbarch.c, gdbarch.h: Rebuild.
7050 * arch-utils.h (default_type_align): Declare.
7051 * arch-utils.c (default_type_align): New function.
7052 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
7053 (struct type) <align_log2>: New field.
7054 <instance_flags>: Now a bitfield.
7055 (TYPE_RAW_ALIGN): New macro.
7056 (type_align, type_raw_align, set_type_align): Declare.
7057 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
7059 * dwarf2read.c (quirk_rust_enum): Set type alignment.
7060 (get_alignment, maybe_set_alignment): New functions.
7061 (read_structure_type, read_enumeration_type, read_array_type)
7062 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
7063 (read_subrange_type, read_base_type): Set type alignment.
7065 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
7067 * dwarf2read.c (read_index_from_section): Use bool.
7069 2018-04-29 Fabian Groffen <grobian@gentoo.org>
7072 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
7075 2018-04-29 John Reiser <jreiser@BitWagon.com>
7078 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
7079 last step, and do it atomically.
7081 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
7083 * compile/compile-c-types.c (convert_int, convert_float):
7086 2018-04-27 Tom Tromey <tom@tromey.com>
7089 * rust-lang.c (rust_inclusive_range_type_p): New function.
7090 (rust_range): Handle inclusive ranges.
7091 (rust_compute_range): Likewise.
7092 * rust-exp.y (struct rust_op) <inclusive>: New field.
7093 (DOTDOTEQ): New constant.
7094 (range_expr): Add "..=" productions.
7095 (operator_tokens): Add "..=" token.
7096 (ast_range): Add "inclusive" parameter.
7097 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
7099 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
7101 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
7102 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
7104 * expprint.c (print_subexp_standard): Handle new bounds values.
7105 (dump_subexp_body_standard): Likewise.
7107 2018-04-27 Tom Tromey <tom@tromey.com>
7109 * configure: Rebuild.
7110 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
7111 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
7113 (class symbol_needs_eval_context): Likewise.
7114 * dwarf2read.c (mock_mapped_index::symbol_name_count)
7115 (mock_mapped_index::symbol_name_at): Use "override". Remove
7117 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
7119 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
7120 * aarch64-tdep.c (instruction_reader::read): Use "override".
7121 (instruction_reader_test::read): Likewise.
7122 * arm-tdep.c (instruction_reader::read): Use "override".
7123 (instruction_reader_thumb::read): Likewise.
7125 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
7128 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
7129 instead of remote_send.
7130 (remote_send): Remove.
7132 2018-04-26 Pedro Alves <palves@redhat.com>
7134 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
7135 find_function_start_sal instead of find_pc_line.
7137 2018-04-26 Pedro Alves <palves@redhat.com>
7139 * breakpoint.c (set_breakpoint_location_function): Handle
7141 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
7142 * elfread.c (elf_symtab_read): Give data symbols with
7143 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
7144 (elf_rel_plt_read): Update comment.
7145 * linespec.c (convert_linespec_to_sals): Handle
7147 (minsym_found): Handle mst_data_gnu_ifunc.
7148 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
7149 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
7150 * parse.c (find_minsym_type_and_address): Handle
7152 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
7153 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
7154 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
7156 <mst_data_gnu_ifunc>: New enumerator.
7158 2018-04-26 Pedro Alves <palves@redhat.com>
7160 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
7161 (lookup_minimal_symbol_by_pc_section): ... this. Replace
7162 'want_trampoline' parameter by a lookup_msym_prefer parameter.
7164 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
7165 (lookup_minimal_symbol_by_pc): Adjust.
7166 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
7167 (lookup_solib_trampoline_symbol_by_pc): Adjust.
7168 * minsyms.h (lookup_msym_prefer): New enum.
7169 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7170 parameter by a lookup_msym_prefer parameter.
7172 2018-04-26 Pedro Alves <palves@redhat.com>
7174 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
7175 ends in "@plt" instead of looking at the symbol's section.
7177 2018-04-26 Pedro Alves <palves@redhat.com>
7179 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
7181 (find_pc_partial_function_gnu_ifunc): Rename to ...
7182 (find_pc_partial_function): ... this, and remove references to
7184 (find_pc_partial_function): Delete old implementation.
7185 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
7187 2018-04-26 Pedro Alves <palves@redhat.com>
7189 * linespec.c (struct bound_minimal_symbol_search_key): New.
7190 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
7191 skip first line if we found a GNU ifunc minimal symbol by name.
7192 (compare_msymbols): Change parameters to work with a destructured
7194 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
7197 2018-04-26 Pedro Alves <palves@redhat.com>
7199 * breakpoint.c (set_breakpoint_location_function): Don't resolve
7200 ifunc targets here. Instead, if we have an ifunc minsym, use its
7202 (add_location_to_breakpoint): Store the minsym and the objfile in
7203 the breakpoint location.
7204 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
7205 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
7206 Record the minsym in the sal.
7207 * symtab.h (symtab_and_line) <msymbol>: New field.
7209 2018-04-26 Pedro Alves <palves@redhat.com>
7211 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
7212 unless we actually resolved the ifunc.
7214 2018-04-26 Pedro Alves <palves@redhat.com>
7216 * c-exp.y (variable production): Prefer ifunc minsyms over
7217 regular function symbols.
7218 * symtab.c (find_gnu_ifunc): New function.
7219 * minsyms.h (lookup_msym_prefer): New enum.
7220 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7221 parameter by a lookup_msym_prefer parameter.
7222 * symtab.h (find_gnu_ifunc): New declaration.
7224 2018-04-26 Pedro Alves <palves@redhat.com>
7226 * blockframe.c (find_gnu_ifunc_target_type): New function.
7227 (find_function_type): New.
7228 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
7229 return a value with a memory address.
7230 (eval_call): For calls to GNU ifunc functions, try to find the
7231 type of the target function from the type that the resolver
7233 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
7235 * infcall.c (find_function_return_type): Delete.
7236 (find_function_addr): Add 'function_type' parameter. For calls to
7237 GNU ifunc functions, try to find the type of the target function
7238 from the type that the resolver returns, and return it via
7240 (call_function_by_hand_dummy): Adjust to use the function type
7241 returned by find_function_addr.
7242 (find_function_addr): Add 'function_type' parameter and move
7244 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
7247 2018-04-26 Pedro Alves <palves@redhat.com>
7249 * c-exp.y (variable production): Skip finding an alias for ifunc
7252 2018-04-26 Pedro Alves <palves@redhat.com>
7254 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
7256 2018-04-25 Pedro Alves <palves@redhat.com>
7258 * infcmd.c (kill_command): Print the pid as string, not the whole
7259 thread's ptid. Add comment. s/has been killed/killed/ in output
7261 * remote.c (remote_detach_1): Print the pid as string, not the
7262 whole thread's ptid.
7264 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7265 Sergio Durigan Junior <sergiodj@redhat.com>
7266 Pedro Alves <palves@redhat.com>
7268 * infcmd.c (kill_command): Print message when inferior has
7270 * inferior.c (print_inferior_events): Remove 'static'. Set as
7272 (add_inferior): Improve message printed when
7273 'print_inferior_events' is on.
7274 (exit_inferior): Remove message printed when
7275 'print_inferior_events' is on.
7276 (detach_inferior): Improve message printed when
7277 'print_inferior_events' is on.
7278 (initialize_inferiors): Use 'add_inferior_silent' to set
7279 'current_inferior_'.
7280 * inferior.h (print_inferior_events): Declare here as
7282 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
7283 '[Detaching...]' messages when 'print_inferior_events' is on.
7284 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
7285 as prefix/suffix for messages. Remove periods. Fix erroneous
7286 'Detaching after fork from child...', replace it by '... from
7288 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
7289 prefix/suffix when printing 'Detaching...' messages. Print
7290 them when 'print_inferior_events' is on.
7291 * remote.c (remote_detach_1): Print message when detaching
7292 from inferior and '!is_fork_parent'.
7294 2018-04-24 Tom Tromey <tom@tromey.com>
7296 * cli-out.h: Reindent.
7298 2018-04-24 Tom Tromey <tom@tromey.com>
7300 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
7301 (cli_ui_out::do_field_string): Use fputs_filtered.
7302 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
7304 2018-04-23 Tom Tromey <tom@tromey.com>
7306 * guile/scm-frame.c (gdbscm_frame_read_var): Use
7307 gdb::unique_xmalloc_ptr.
7309 2018-04-23 Tom Tromey <tom@tromey.com>
7311 * configure: Rebuild.
7313 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
7316 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
7317 prepare_for_testing. Set normal_bp to r_debug_state if target
7320 2018-04-21 Pedro Alves <palves@redhat.com>
7321 Rajendra SY <rajendra.sy@gmail.com>
7323 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
7324 * remote.c (extended_remote_attach): In all-stop mode, mark the
7325 thread as executing.
7327 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7329 * thread.c (thread_apply_all_command): Fix comment.
7330 (thread_command): Fix comment.
7332 2018-04-10 Alan Hayward <alan.hayward@arm.com>
7334 * common/tdesc.h (tdesc_create_feature): Remove xml filename
7336 * features/aarch64-core.c (create_feature_aarch64_core):
7338 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
7340 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
7342 * features/i386/32bit-avx512.c
7343 (create_feature_i386_32bit_avx512): Likewise.
7344 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
7346 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
7348 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
7350 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
7352 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
7354 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
7356 * features/i386/64bit-avx512.c
7357 (create_feature_i386_64bit_avx512): Likewise.
7358 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
7360 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
7362 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
7364 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
7366 * features/i386/64bit-segments.c
7367 (create_feature_i386_64bit_segments): Likewise.
7368 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
7370 * features/i386/x32-core.c
7371 (create_feature_i386_x32_core): Likewise.
7372 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
7373 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
7374 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
7375 * target-descriptions.c: In generated code, don't pass xml
7378 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7380 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
7381 (print_xml_feature::visit_post): Likewise.
7382 (print_xml_feature::visit): Likewise.
7383 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
7384 (print_xml_feature): Add new class.
7385 * regformats/regdat.sh: Null xmltarget on feature targets.
7386 * target-descriptions.c (struct target_desc): Add xmltarget.
7387 (maintenance_check_tdesc_xml_convert): Add unittest function.
7388 (tdesc_get_features_xml): Add function to get xml.
7389 (maintenance_check_xml_descriptions): Test xml generation.
7390 * xml-tdesc.c (string_read_description_xml): Add function.
7391 * xml-tdesc.h (string_read_description_xml): Add declaration.
7393 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7395 * features/Makefile: Add feature marker to targets with new style
7396 target descriptions.
7397 * regformats/aarch64.dat: Regenerate.
7398 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
7399 * regformats/i386/amd64-avx-linux.dat: Likewise.
7400 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
7401 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
7402 * regformats/i386/amd64-linux.dat: Likewise.
7403 * regformats/i386/amd64-mpx-linux.dat: Likewise.
7404 * regformats/i386/amd64.dat: Likewise.
7405 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
7406 * regformats/i386/i386-avx-linux.dat: Likewise.
7407 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
7408 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
7409 * regformats/i386/i386-linux.dat: Likewise.
7410 * regformats/i386/i386-mmx-linux.dat: Likewise.
7411 * regformats/i386/i386-mpx-linux.dat: Likewise.
7412 * regformats/i386/i386.dat: Likewise.
7413 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
7414 * regformats/i386/x32-avx-linux.dat: Likewise.
7415 * regformats/i386/x32-linux.dat: Likewise.
7416 * regformats/tic6x-c62x-linux.dat: Likewise.
7417 * regformats/tic6x-c64x-linux.dat: Likewise.
7418 * regformats/tic6x-c64xp-linux.dat: Likewise.
7419 * regformats/regdat.sh: Parse feature marker.
7421 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7423 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
7424 (tdesc_osabi_name): Likewise.
7425 * target-descriptions.c (tdesc_architecture_name): Add new
7427 (tdesc_osabi_name): Likewise.
7429 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7431 * common/tdesc.c (tdesc_predefined_type): Move to here.
7432 (tdesc_named_type): Likewise.
7433 (tdesc_create_vector): Likewise.
7434 (tdesc_create_struct): Likewise.
7435 (tdesc_set_struct_size): Likewise.
7436 (tdesc_create_union): Likewise.
7437 (tdesc_create_flags): Likewise.
7438 (tdesc_create_enum): Likewise.
7439 (tdesc_add_field): Likewise.
7440 (tdesc_add_typed_bitfield): Likewise.
7441 (tdesc_add_bitfield): Likewise.
7442 (tdesc_add_flag): Likewise.
7443 (tdesc_add_enum_value): Likewise.
7444 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
7445 (struct tdesc_type_vector): Likewise.
7446 (struct tdesc_type_field): Likewise.
7447 (struct tdesc_type_with_fields): Likewise.
7448 (tdesc_create_enum): Add declaration.
7449 (tdesc_add_typed_bitfield): Likewise.
7450 (tdesc_add_enum_value): Likewise.
7451 * target-descriptions.c (tdesc_type_field): Move from here.
7452 (tdesc_type_builtin): Likewise.
7453 (tdesc_type_vector): Likewise.
7454 (tdesc_type_with_fields): Likewise.
7455 (tdesc_predefined_types): Likewise.
7456 (tdesc_named_type): Likewise.
7457 (tdesc_create_vector): Likewise.
7458 (tdesc_create_struct): Likewise.
7459 (tdesc_set_struct_size): Likewise.
7460 (tdesc_create_union): Likewise.
7461 (tdesc_create_flags): Likewise.
7462 (tdesc_create_enum): Likewise.
7463 (tdesc_add_field): Likewise.
7464 (tdesc_add_typed_bitfield): Likewise.
7465 (tdesc_add_bitfield): Likewise.
7466 (tdesc_add_flag): Likewise.
7467 (tdesc_add_enum_value): Likewise.
7468 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
7469 (tdesc_add_typed_bitfield): Likewise.
7470 (tdesc_add_enum_value): Likewise.
7472 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7474 * common/tdesc.c (tdesc_feature::accept): Move to here.
7475 (tdesc_feature::operator==): Likewise.
7476 (tdesc_create_reg): Likewise.
7477 * common/tdesc.h (tdesc_type_kind): Likewise.
7478 (struct tdesc_type): Likewise.
7479 (struct tdesc_feature): Likewise.
7480 * regformats/regdat.sh: Create a feature.
7481 * target-descriptions.c (tdesc_type_kind): Move from here.
7482 (tdesc_type): Likewise.
7483 (tdesc_type_up): Likewise.
7484 (tdesc_feature): Likewise.
7485 (tdesc_create_reg): Likewise.
7487 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7489 * Makefile.in: Add arch/tdesc.c
7490 * common/tdesc.c: New file.
7491 * common/tdesc.h (tdesc_element_visitor): Move to here.
7492 (tdesc_element): Likewise.
7493 (tdesc_reg): Likewise.
7494 (tdesc_reg_up): Likewise.
7495 * regformats/regdef.h (reg): Add offset to constructors.
7496 * target-descriptions.c (tdesc_element_visitor): Move from here.
7497 (tdesc_element): Likewise.
7498 (tdesc_reg): Likewise.
7499 (tdesc_reg_up): Likewise.
7501 2018-04-17 Tom Tromey <tom@tromey.com>
7503 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
7506 2018-04-17 Tom Tromey <tom@tromey.com>
7508 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
7510 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
7512 * symtab.c (print_symbol_info): Skip printing filename and line
7513 number when `last' is NULL.
7514 (symtab_symbol_info): Use empty string instead of NULL for first
7515 invocation of print_symbol_info.
7516 (rbreak_command): Pass NULL to `last' parameter of
7519 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
7521 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
7524 2018-04-16 Pedro Alves <palves@redhat.com>
7526 * MAINTAINERS (sh): Remove.
7527 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
7528 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
7529 (ALLDEPFILES): Remove sh64-tdep.c.
7530 * NEWS: Mentions that support for SH-5/SH64 is removed.
7531 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
7532 (sh*-*-openbsd*): Ditto.
7533 (sh64-*-elf*): Remove.
7535 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
7536 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
7537 * sh-tdep.c: No longer include "sh64-tdep.h".
7538 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
7539 * sh64-tdep.c, sh64-tdep.h: Remove files.
7541 2018-04-16 Pedro Alves <palves@redhat.com>
7543 * MAINTAINERS: Remove m88k.
7544 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
7545 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
7546 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
7547 * NEWS: Mention that support for m88k was removed.
7548 * configure.host (m88*-*-*): Remove support.
7549 * configure.nat (m88k-*-*): Remove support.
7550 * configure.tgt (m88*-*-openbsd*): Remove.
7551 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
7553 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
7555 * configure.tgt (x86_tobjs): New variable.
7556 (amd64_tobjs, i386_tobjs): Use it.
7558 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7560 * symtab.c (print_symbol_info): Precede the symbol definition by
7561 the line number when available.
7562 * NEWS: Advertise this enhancement.
7564 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7566 * NEWS (New options): announce set/show record btrace cpu.
7567 * btrace.c: Include record-btrace.h.
7568 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
7569 the vendor is unknown.
7570 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
7571 Maybe overwrite the btrace configuration's cpu.
7572 (btrace_compute_ftrace): Add cpu parameter. Update callers.
7573 (btrace_fetch): Add cpu parameter. Update callers.
7574 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
7575 Maybe overwrite the btrace configuration's cpu. Skip enabling
7576 errata workarounds if the vendor is unknown.
7577 * python/py-record-btrace.c: Include record-btrace.h.
7578 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
7579 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
7580 * record-btrace.c (record_btrace_cpu_state_kind): New.
7581 (record_btrace_cpu): New.
7582 (set_record_btrace_cpu_cmdlist): New.
7583 (record_btrace_get_cpu): New.
7584 (require_btrace_thread, record_btrace_info)
7585 (record_btrace_resume_thread): Call record_btrace_get_cpu.
7586 (cmd_set_record_btrace_cpu_none): New.
7587 (cmd_set_record_btrace_cpu_auto): New.
7588 (cmd_set_record_btrace_cpu): New.
7589 (cmd_show_record_btrace_cpu): New.
7590 (_initialize_record_btrace): Initialize set/show record btrace cpu
7592 * record-btrace.h (record_btrace_get_cpu): New.
7594 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7596 * record.c (set_record_command): Fix typo in message.
7598 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7600 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
7602 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7604 * infrun.c (process_event_stop_test): Call
7605 gdbarch_in_indirect_branch_thunk.
7606 * gdbarch.sh (in_indirect_branch_thunk): New.
7607 * gdbarch.c: Regenerated.
7608 * gdbarch.h: Regenerated.
7611 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
7612 (HFILES_NO_SRCDIR): Add x86-tdep.h.
7613 (ALLDEPFILES): Add x86-tdep.c.
7614 * arch-utils.h (default_in_indirect_branch_thunk): New.
7615 * arch-utils.c (default_in_indirect_branch_thunk): New.
7616 * i386-tdep: Include x86-tdep.h.
7617 (i386_in_indirect_branch_thunk): New.
7618 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
7620 * amd64-tdep: Include x86-tdep.h.
7621 (amd64_in_indirect_branch_thunk): New.
7622 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7624 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7627 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7628 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7629 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7632 2018-04-12 Tom Tromey <tom@tromey.com>
7634 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7635 (rust_evaluate_subexp): Likewise.
7637 2018-04-12 Pedro Alves <palves@redhat.com>
7639 * procfs.c (procfs_detach): Make forward declaration's prototype
7640 match definition's protototype.
7641 (proc_get_LDT_entry): Remove stale do_cleanups call.
7643 2018-04-12 Pedro Alves <palves@redhat.com>
7645 * target.h (target_ops::to_has_exited): Delete.
7646 (target_has_exited): Delete.
7647 * target-delegates.c: Regenerate.
7649 2018-04-11 Pedro Alves <palves@redhat.com>
7651 * target.c (fileio_fh_t::t): Add comment.
7652 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7653 (target_fileio_close): Handle a NULL target.
7654 (invalidate_fileio_fh): New.
7655 (target_close): Call it.
7656 * remote.c (remote_hostio_send_command): No longer check whether
7657 remote_desc is open.
7659 2018-04-11 Pedro Alves <palves@redhat.com>
7661 * target.c (fileio_fh_t): Make it a named struct instead of a
7663 (fileio_fh_t::is_closed): New method.
7664 (DEF_VEC_O (fileio_fh_t)): Remove.
7665 (fileio_fhandles): Now a std::vector.
7666 (is_closed_fileio_fh): Delete.
7667 (acquire_fileio_fd): Adjust. Rename parameters.
7668 (release_fileio_fd): Adjust.
7669 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7670 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7671 (target_fileio_close): Adjust.
7673 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7675 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7678 2018-04-10 Pedro Alves <palves@redhat.com>
7680 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7681 (scoped_finish_thread_state): New class.
7682 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7684 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7685 (fetch_inferior_event, normal_stop): Likewise.
7686 * thread.c (finish_thread_state_cleanup): Delete.
7688 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7689 Pedro Alves <palves@redhat.com>
7691 * value.c: Include "selftest.h" and "common/array-view.h".
7692 (struct range) <operator ==>: New.
7693 (test_ranges_contain): New.
7694 (check_ranges_vector): New.
7695 (test_insert_into_bit_range_vector): New.
7696 (_initialize_values): Register selftests.
7697 * common/array-view.h (operator==, operator!=): New.
7699 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7701 * common/gdb_vecs.h (unordered_remove): Add overload that takes
7703 * inline-frame.c: Include <algorithm>.
7704 (struct inline_state): Add constructor.
7705 (inline_state_s): Remove.
7706 (DEF_VEC_O(inline_state_s)): Remove.
7707 (inline_states): Change type to std::vector.
7708 (find_inline_frame_state): Adjust to std::vector.
7709 (allocate_inline_frame_state): Remove.
7710 (clear_inline_frame_state): Adjust to std::vector.
7711 (skip_inline_frames): Adjust to std::vector.
7713 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7715 * tracepoint.h (struct trace_state_variable): Add constructor.
7716 <name>: Change type to std::string.
7717 * tracepoint.c (tsv_s): Remove.
7718 (DEF_VEC_O(tsv_s)): Remove.
7719 (tvariables): Change to std::vector.
7720 (create_trace_state_variable): Adjust to std::vector.
7721 (find_trace_state_variable): Likewise.
7722 (find_trace_state_variable_by_number): Likewise.
7723 (delete_trace_state_variable): Likewise.
7724 (trace_variable_command): Adjust to std::string.
7725 (delete_trace_variable_command): Likewise.
7726 (tvariables_info_1): Adjust to std::vector.
7727 (save_trace_state_variables): Likewise.
7728 (start_tracing): Likewise.
7729 (merge_uploaded_trace_state_variables): Adjust to std::vector
7731 * target.h (struct target_ops)
7732 <to_download_trace_state_variable>: Pass reference to
7733 trace_state_variable.
7734 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
7735 * target-delegates.c: Re-generate.
7736 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
7737 (mi_tsv_deleted): Likewise.
7738 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
7739 * remote.c (remote_download_trace_state_variable): Change
7740 pointer to reference and adjust.
7741 * make-target-delegates (parse_argtypes): Handle references.
7742 (write_function_header): Likewise.
7743 (munge_type): Likewise.
7745 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7747 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7748 string_view-selftests.c.
7749 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
7751 * unittests/basic_string_view/cons/char/1.cc: Likewise.
7752 * unittests/basic_string_view/cons/char/2.cc: Likewise.
7753 * unittests/basic_string_view/cons/char/3.cc: Likewise.
7754 * unittests/basic_string_view/element_access/char/1.cc:
7756 * unittests/basic_string_view/element_access/char/empty.cc:
7758 * unittests/basic_string_view/element_access/char/front_back.cc:
7760 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
7761 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
7763 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
7765 * unittests/basic_string_view/modifiers/swap/char/1.cc:
7767 * unittests/basic_string_view/operations/compare/char/1.cc:
7769 * unittests/basic_string_view/operations/compare/char/13650.cc:
7771 * unittests/basic_string_view/operations/copy/char/1.cc:
7773 * unittests/basic_string_view/operations/data/char/1.cc:
7775 * unittests/basic_string_view/operations/find/char/1.cc:
7777 * unittests/basic_string_view/operations/find/char/2.cc:
7779 * unittests/basic_string_view/operations/find/char/3.cc:
7781 * unittests/basic_string_view/operations/find/char/4.cc:
7783 * unittests/basic_string_view/operations/rfind/char/1.cc:
7785 * unittests/basic_string_view/operations/rfind/char/2.cc:
7787 * unittests/basic_string_view/operations/rfind/char/3.cc:
7789 * unittests/basic_string_view/operations/substr/char/1.cc:
7791 * unittests/basic_string_view/operators/char/2.cc: Likewise.
7792 * unittests/string_view-selftests.c: New file.
7794 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7796 * unittests/basic_string_view/capacity/1.cc: New file.
7797 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
7798 * unittests/basic_string_view/cons/char/1.cc: New file.
7799 * unittests/basic_string_view/cons/char/2.cc: New file.
7800 * unittests/basic_string_view/cons/char/3.cc: New file.
7801 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
7802 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
7803 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
7804 * unittests/basic_string_view/element_access/char/1.cc: New file.
7805 * unittests/basic_string_view/element_access/char/2.cc: New file.
7806 * unittests/basic_string_view/element_access/char/empty.cc: New file.
7807 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
7808 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
7809 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
7810 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
7811 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
7812 * unittests/basic_string_view/include.cc: New file.
7813 * unittests/basic_string_view/inserters/char/1.cc: New file.
7814 * unittests/basic_string_view/inserters/char/2.cc: New file.
7815 * unittests/basic_string_view/inserters/char/3.cc: New file.
7816 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
7817 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
7818 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
7819 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
7820 * unittests/basic_string_view/literals/types.cc: New file.
7821 * unittests/basic_string_view/literals/values.cc: New file.
7822 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
7823 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
7824 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
7825 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
7826 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
7827 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
7828 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
7829 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
7830 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
7831 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
7832 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
7833 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
7834 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
7835 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
7836 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
7837 * unittests/basic_string_view/operations/data/char/1.cc: New file.
7838 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
7839 * unittests/basic_string_view/operations/find/char/1.cc: New file.
7840 * unittests/basic_string_view/operations/find/char/2.cc: New file.
7841 * unittests/basic_string_view/operations/find/char/3.cc: New file.
7842 * unittests/basic_string_view/operations/find/char/4.cc: New file.
7843 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
7844 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
7845 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
7846 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
7847 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
7848 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
7849 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
7850 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
7851 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
7852 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
7853 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
7854 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
7855 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
7856 * unittests/basic_string_view/operators/char/2.cc: New file.
7857 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
7858 * unittests/basic_string_view/range_access/char/1.cc: New file.
7859 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
7860 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
7861 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
7862 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
7863 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
7864 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
7865 * unittests/basic_string_view/requirements/typedefs.cc: New file.
7866 * unittests/basic_string_view/typedefs.cc: New file.
7867 * unittests/basic_string_view/types/1.cc: New file.
7869 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7871 * common/gdb_string_view.h: Remove libstdc++ implementation
7872 details, adjust to gdb reality.
7873 * common/gdb_string_view.tcc: Likewise.
7874 * cli/cli-script.c (struct string_view): Remove.
7875 (user_args) <m_args>: Change element type to gdb::string_view.
7876 (user_args::insert_args): Adjust.
7878 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7880 * common/gdb_string_view.h: New file.
7881 * common/gdb_string_view.tcc: New file.
7883 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7885 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
7886 * configure: Re-generate.
7888 2018-04-09 Pedro Alves <palves@redhat.com>
7890 * gdbarch.sh: Include "observable.h" instead of "observer.h".
7891 (set_target_gdbarch): Call
7892 gdb::observers::architecture_changed.notify instead of
7893 observer_notify_architecture_changed.
7895 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7897 * tracepoint.c (struct current_traceframe_cleanup): Remove.
7898 (do_restore_current_traceframe_cleanup): Remove.
7899 (restore_current_traceframe_cleanup_dtor): Remove.
7900 (make_cleanup_restore_current_traceframe): Remove.
7901 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
7903 * tracepoint.h (struct scoped_restore_current_traceframe): New.
7904 * infrun.c (fetch_inferior_event): Use
7905 scoped_restore_current_traceframe.
7907 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7909 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
7911 <n_allocated_type_units>: Remove.
7912 <all_type_units>: Change to std::vector.
7913 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7914 to std::vector change.
7915 (dwarf2_per_objfile::get_cutu): Likewise.
7916 (dwarf2_per_objfile::get_tu): Likewise.
7917 (create_signatured_type_table_from_index): Likewise.
7918 (create_signatured_type_table_from_debug_names): Likewise.
7919 (dw2_symtab_iter_next): Likewise.
7920 (dw2_print_stats): Likewise.
7921 (dw2_expand_all_symtabs): Likewise.
7922 (dw2_expand_marked_cus): Likewise.
7923 (dw2_debug_names_iterator::next): Likewise.
7924 (dwarf2_initialize_objfile): Likewise.
7925 (add_signatured_type_cu_to_table): Likewise.
7926 (create_all_type_units): Likewise.
7927 (add_type_unit): Likewise.
7928 (struct tu_abbrev_offset): Add constructor.
7929 (build_type_psymtabs_1): Adjust to std::vector change.
7930 (print_tu_stats): Likewise.
7931 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7932 (write_debug_names): Likewise.
7934 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7936 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
7937 Make an std::vector.
7938 <n_comp_units>: Remove.
7939 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7940 to std::vector change.
7941 (dwarf2_per_objfile::get_cutu): Likewise.
7942 (dwarf2_per_objfile::get_cu): Likewise.
7943 (create_cus_from_index): Likewise.
7944 (create_addrmap_from_index): Likewise.
7945 (create_addrmap_from_aranges): Likewise.
7946 (dwarf2_read_index): Likewise.
7947 (dw2_find_last_source_symtab): Likewise.
7948 (dw2_map_symtabs_matching_filename): Likewise.
7949 (dw2_symtab_iter_next): Likewise.
7950 (dw2_print_stats): Likewise.
7951 (dw2_expand_all_symtabs): Likewise.
7952 (dw2_expand_symtabs_with_fullname): Likewise.
7953 (dw2_expand_marked_cus): Likewise.
7954 (dw2_map_symbol_filenames): Likewise.
7955 (create_cus_from_debug_names): Likewise.
7956 (dwarf2_read_debug_names): Likewise.
7957 (dw2_debug_names_iterator::next): Likewise.
7958 (dwarf2_initialize_objfile): Likewise.
7959 (set_partial_user): Likewise.
7960 (dwarf2_build_psymtabs_hard): Likewise.
7961 (read_comp_units_from_section): Remove arguments, adjust to
7963 (create_all_comp_units): Adjust to std::vector and
7964 read_comp_units_from_section changes.
7965 (dwarf2_find_containing_comp_unit): Adjust to std::vector
7967 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7968 (psyms_seen_size): Likewise.
7969 (write_gdbindex): Likewise.
7970 (write_debug_names): Likewise.
7972 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7974 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
7975 with dwarf2_per_objfile.
7976 (create_cus_from_index): Likewise.
7977 (create_signatured_type_table_from_index): Likewise.
7978 (dwarf2_read_index): Likewise.
7979 (dwarf2_initialize_objfile): Likewise.
7980 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
7981 per_cu rather than get_dwarf2_per_objfile.
7983 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7985 * dwarf2read.h (struct signatured_type): Forward declare.
7986 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
7988 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
7989 (dw2_get_cutu): ...this.
7990 (dwarf2_per_objfile::get_cu): Rename from...
7991 (dw2_get_cu): ...this.
7992 (dwarf2_per_objfile::get_tu): New.
7993 (create_addrmap_from_index): Adjust.
7994 (create_addrmap_from_aranges): Adjust.
7995 (dw2_find_last_source_symtab): Adjust.
7996 (dw2_map_symtabs_matching_filename): Adjust.
7997 (dw2_symtab_iter_next): Adjust.
7998 (dw2_print_stats): Adjust.
7999 (dw2_expand_all_symtabs): Adjust.
8000 (dw2_expand_symtabs_with_fullname): Adjust.
8001 (dw2_expand_marked_cus): Adjust.
8002 (dw_expand_symtabs_matching_file_matcher): Adjust.
8003 (dw2_map_symbol_filenames): Adjust.
8004 (dw2_debug_names_iterator::next): Adjust.
8005 (dwarf2_initialize_objfile): Adjust.
8006 (set_partial_user): Adjust.
8007 (dwarf2_build_psymtabs_hard): Adjust.
8009 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8011 * dwarf2read.c (create_signatured_type_table_from_debug_names):
8012 Remove unused variables.
8013 (dw2_map_symtabs_matching_filename): Likewise.
8014 (dwarf2_record_block_ranges): Likewise.
8015 (dwarf2_read_addr_index): Likewise.
8016 (follow_die_offset): Likewise.
8018 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8020 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
8021 to symbol_file_add_main.
8023 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8026 * mi/mi-console.c (do_fputc_async_safe): New.
8027 (mi_console_file::write_async_safe): New.
8028 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
8029 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
8031 * ui-file.c (ui_file::putstrn): Adjust call to
8032 fputstrn_unfiltered.
8033 * utils.c (printchar): Replace do_fputs and do_fprintf
8034 parameters by do_fputc.
8035 (fputstr_filtered): Adjust call to printchar.
8036 (fputstr_unfiltered): Likewise.
8037 (fputstrn_filtered): Likewise.
8038 (fputstrn_unfiltered): Add do_fputc parameter, pass to
8040 * utils.h (do_fputc_ftype): New typedef.
8041 (fputstrn_unfiltered): Add do_fputc parameter.
8043 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8045 * regformats/i386/i386-avx.dat: Remove.
8047 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8050 * amd64-tdep.c (amd64_none_init_abi): New function.
8051 (amd64_x32_none_init_abi): New function.
8052 (_initialize_amd64_tdep): Register handlers for x86-64 and
8053 x64_32 with GDB_OSABI_NONE.
8054 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
8055 GDB_OSABI_NONE osabi.
8057 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8060 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
8062 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
8063 * osabi.c (gdb_osabi_names): Add "unknown" entry.
8065 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
8067 * common/byte-vector.h (char_vector): New type.
8068 * target.h (target_read_alloc): Return
8069 gdb::optional<byte_vector>.
8070 (target_read_stralloc): Return gdb::optional<char_vector>.
8071 (target_get_osdata): Return gdb::optional<char_vector>.
8072 * target.c (target_read_alloc_1): Templatize. Replacement
8073 manual memory management with vector.
8074 (target_read_alloc): Change return type, adjust.
8075 (target_read_stralloc): Change return type, adjust.
8076 (target_get_osdata): Change return type, adjust.
8077 * auxv.c (struct auxv_info) <length>: Remove.
8078 <data>: Change type to gdb::optional<byte_vector>.
8079 (auxv_inferior_data_cleanup): Free auxv_info with delete.
8080 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
8081 (target_auxv_search): Adjust.
8082 (fprint_target_auxv): Adjust.
8083 * avr-tdep.c (avr_io_reg_read_command): Adjust.
8084 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
8085 (linux_make_corefile_notes): Adjust.
8086 * osdata.c (get_osdata): Adjust.
8087 * remote.c (remote_get_threads_with_qxfer): Adjust.
8088 (remote_memory_map): Adjust.
8089 (remote_traceframe_info): Adjust.
8090 (btrace_read_config): Adjust.
8091 (remote_read_btrace): Adjust.
8092 (remote_pid_to_exec_file): Adjust.
8093 * solib-aix.c (solib_aix_get_library_list): Adjust.
8094 * solib-dsbt.c (decode_loadmap): Don't free buf.
8095 (dsbt_get_initial_loadmaps): Adjust.
8096 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
8097 * solib-target.c (solib_target_current_sos): Adjust.
8098 * tracepoint.c (sdata_make_value): Adjust.
8099 * xml-support.c (xinclude_start_include): Adjust.
8100 (xml_fetch_content_from_file): Adjust.
8101 * xml-support.h (xml_fetch_another): Change return type.
8102 (xml_fetch_content_from_file): Change return type.
8103 * xml-syscall.c (xml_init_syscalls_info): Adjust.
8104 * xml-tdesc.c (file_read_description_xml): Adjust.
8105 (fetch_available_features_from_target): Change return type.
8106 (target_fetch_description_xml): Adjust.
8107 (target_read_description_xml): Adjust.
8109 2018-04-06 Tom Tromey <tom@tromey.com>
8111 * value.c (~value): Update.
8112 (struct value) <contents>: Now unique_xmalloc_ptr.
8113 (value_contents_bits_eq, allocate_value_contents)
8114 (value_contents_raw, value_contents_all_raw)
8115 (value_contents_for_printing, value_contents_for_printing_const)
8116 (set_value_enclosing_type): Update.
8118 2018-04-06 Tom Tromey <tom@tromey.com>
8120 * value.c (range_s): Remove typedef, VEC.
8121 (struct range): Add operator<.
8122 (range_lessthan): Remove.
8123 (ranges_contain): Change type.
8125 (struct value) <unavailable, optimized_out>: Now std::vector.
8126 (value_entirely_available)
8127 (value_entirely_covered_by_range_vector)
8128 (value_entirely_unavailable, value_entirely_optimized_out):
8130 (insert_into_bit_range_vector): Change argument type.
8131 (find_first_range_overlap): Likewise.
8132 (struct ranges_and_idx, value_contents_bits_eq)
8133 (require_not_optimized_out, require_available): Update.
8134 (ranges_copy_adjusted): Change argument types.
8135 (value_optimized_out, value_copy, value_fetch_lazy): Update.
8137 2018-04-06 Tom Tromey <tom@tromey.com>
8139 * value.c (~value): Update.
8140 (struct value) <parent>: Now a value_ref_ptr.
8141 (value_parent, set_value_parent, value_address, value_copy):
8144 2018-04-06 Tom Tromey <tom@tromey.com>
8146 * value.c (struct value): Add constructor, destructor, and member
8148 (allocate_value_lazy, value_decref): Update.
8150 2018-04-06 Tom Tromey <tom@tromey.com>
8152 * value.c (struct value) <released, next>: Remove.
8153 (all_values): Now a std::vector.
8154 (allocate_value_lazy): Update.
8155 (value_next): Remove.
8156 (value_mark, value_free_to_mark, release_value)
8157 (value_release_to_mark): Update.
8159 2018-04-06 Tom Tromey <tom@tromey.com>
8161 * value.h (fetch_subexp_value, value_release_to_mark): Update.
8162 (free_value_chain): Remove.
8163 * value.c (free_value_chain): Remove.
8164 (value_release_to_mark): Return a std::vector.
8165 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
8167 (check_condition): Update.
8168 * eval.c (fetch_subexp_value): Change "val_chain" to a
8170 * breakpoint.c (update_watchpoint): Update.
8171 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
8173 2018-04-06 Tom Tromey <tom@tromey.com>
8175 * value.h (free_all_values): Remove.
8176 * value.c (free_all_values): Remove.
8178 2018-04-06 Tom Tromey <tom@tromey.com>
8180 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
8181 (value_history_chain, value_history_count): Remove.
8182 (value_history): New global.
8183 (record_latest_value, access_value_history, show_values)
8184 (preserve_values): Update.
8186 2018-04-06 Tom Tromey <tom@tromey.com>
8188 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
8189 * varobj.c (varobj_set_display_format, varobj_set_value)
8190 (install_default_visualizer, construct_visualizer)
8191 (install_new_value, ~varobj, varobj_get_value_type)
8192 (my_value_of_variable, varobj_editable_p): Update.
8193 * c-varobj.c (c_describe_child, c_value_of_variable)
8194 (cplus_number_of_children, cplus_describe_child): Update.
8195 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
8196 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
8197 (ada_value_of_variable, ada_value_is_changeable_p): Update.
8199 2018-04-06 Tom Tromey <tom@tromey.com>
8201 * printcmd.c (last_examine_address): Change type to
8203 (do_examine, x_command): Update.
8205 2018-04-06 Tom Tromey <tom@tromey.com>
8207 * value.c (release_value): Update.
8208 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
8209 (struct bpstats) <val>: Now a value_ref_ptr.
8210 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8211 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8212 (~watchpoint, print_it_watchpoint, watch_command_1)
8213 (invalidate_bp_value_on_memory_change): Update.
8215 2018-04-06 Tom Tromey <tom@tromey.com>
8217 * varobj.c (varobj_clear_saved_item)
8218 (update_dynamic_varobj_children, install_new_value, ~varobj):
8220 * value.h (value_incref): Move declaration earlier.
8221 (value_decref): Rename from value_free.
8222 (struct value_ref_policy): New.
8223 (value_ref_ptr): New typedef.
8224 (struct value_deleter): Remove.
8225 (gdb_value_up): Remove typedef.
8226 (release_value): Change return type.
8227 (release_value_or_incref): Remove.
8228 * value.c (set_value_parent): Update.
8229 (value_incref): Change return type.
8230 (value_decref): Rename from value_free.
8231 (value_free_to_mark, free_all_values, free_value_chain): Update.
8232 (release_value): Return value_ref_ptr.
8233 (release_value_or_incref): Remove.
8234 (record_latest_value, set_internalvar, clear_internalvar):
8236 * stack.c (info_frame_command): Don't call value_free.
8237 * python/py-value.c (valpy_dealloc, valpy_new)
8238 (value_to_value_object): Update.
8239 * printcmd.c (do_examine): Update.
8240 * opencl-lang.c (lval_func_free_closure): Update.
8241 * mi/mi-main.c (register_changed_p): Don't call value_free.
8242 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
8243 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
8244 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
8246 * guile/scm-value.c (vlscm_free_value_smob)
8247 (vlscm_scm_from_value): Update.
8248 * frame.c (frame_register_unwind, frame_unwind_register_signed)
8249 (frame_unwind_register_unsigned, get_frame_register_bytes)
8250 (put_frame_register_bytes): Don't call value_free.
8251 * findvar.c (address_from_register): Don't call value_free.
8252 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
8253 * dwarf2loc.c (entry_data_value_free_closure)
8254 (value_of_dwarf_reg_entry, free_pieced_value_closure)
8255 (dwarf2_evaluate_loc_desc_full): Update.
8256 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8257 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8258 (~watchpoint, watch_command_1)
8259 (invalidate_bp_value_on_memory_change): Update.
8260 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
8262 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
8265 * warning.m4: Add -Wno-error=deprecated-register.
8266 * configure: Re-generate.
8268 2018-04-05 Tom Tromey <tom@tromey.com>
8270 * linespec.h: Remove include of "vec.h".
8272 2018-04-05 Tom Tromey <tom@tromey.com>
8274 * linespec.c (typep): Remove typedef.
8275 (find_methods, find_superclass_methods): Take a std::vector.
8276 (find_method): Use std::vector.
8278 2018-04-05 Tom Tromey <tom@tromey.com>
8280 * utils.c (compare_strings): Remove.
8281 * utils.h (compare_strings): Remove.
8282 * objc-lang.h (find_imps): Update.
8283 * objc-lang.c (find_methods): Take a std::vector.
8284 (uniquify_strings, find_imps): Likewise.
8285 * linespec.c (find_methods): Take a std::vector.
8286 (decode_objc): Use std::vector.
8287 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
8289 (find_method, find_function_symbols): Use std::vector.
8291 2018-04-05 Tom Tromey <tom@tromey.com>
8293 * completer.c (completion_tracker::completion_tracker): Remove
8295 (completion_tracker::discard_completions): Likewise.
8296 * breakpoint.c (ambiguous_names_p): Remove cast.
8297 * ada-lang.c (_initialize_ada_language): Remove cast.
8298 * utils.h (streq): Update.
8299 (streq_hash): Add new declaration.
8300 * utils.c (streq): Return bool.
8301 (streq_hash): New function.
8303 2018-04-05 Tom Tromey <tom@tromey.com>
8305 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
8306 Remove a string copy.
8308 2018-04-05 Tom Tromey <tom@tromey.com>
8310 * linespec.c (filter_results): Use std::vector.
8311 (decode_line_2, decode_line_full): Update.
8313 2018-04-05 Tom Tromey <tom@tromey.com>
8315 * linespec.c (canonical_to_fullform): Return std::string.
8316 (filter_results): Update.
8317 (struct decode_line_2_item): Add constructor.
8318 <fullform, displayform>: Now std::string.
8319 (decode_line_2_compare_items): Now a std::sort comparator.
8320 (decode_line_2): Update.
8322 2018-04-05 Tom Tromey <tom@tromey.com>
8324 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
8325 (unexpected_linespec_error): Update.
8326 (linespec_parse_basic, parse_linespec): Update.
8328 2018-04-05 Tom Tromey <tom@tromey.com>
8330 * linespec.c (linespec_parse_basic): Reindent.
8332 2018-04-05 Tom Tromey <tom@tromey.com>
8334 * minsyms.h (iterate_over_minimal_symbols): Update.
8335 * minsyms.c (iterate_over_minimal_symbols): Take a
8337 * linespec.c (struct collect_minsyms): Remove.
8338 (compare_msyms): Now a std::sort comparator.
8339 (add_minsym): Add parameters.
8340 (search_minsyms_for_name): Update. Use std::vector.
8342 2018-04-03 Tom Tromey <tom@tromey.com>
8344 * mipsread.c (read_alphacoff_dynamic_symtab): Use
8347 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
8349 * MAINTAINERS (Write After Approval): Add Weimin Pan.
8351 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
8354 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
8355 printing static type.
8357 2018-04-01 Tom Tromey <tom@tromey.com>
8359 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
8360 (rs6000_xfer_shared_libraries): Update.
8362 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
8364 * common/gdb_vecs.h (char_ptr): Remove.
8365 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
8367 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8369 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
8371 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
8373 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8375 * tracepoint.h (struct uploaded_tp): Initialize fields.
8376 <actions, step_actions, cmd_strings>: Change type to
8377 std::vector<char *>.
8378 * tracepoint.c (get_uploaded_tp): Allocate with new.
8379 (free_uploaded_tps): Free with delete.
8380 (parse_tracepoint_definition): Adjust to std::vector change.
8381 * breakpoint.c (read_uploaded_action): Likewise.
8382 (create_tracepoint_from_upload): Likewise.
8383 * ctf.c (ctf_write_uploaded_tp): Likewise.
8384 (SET_ARRAY_FIELD): Likewise.
8385 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
8387 2018-03-30 Tom Tromey <tom@tromey.com>
8389 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
8391 (svr4_keep_data_in_core): Update.
8392 (svr4_read_so_list): Update.
8394 2018-03-30 Tom Tromey <tom@tromey.com>
8396 * windows-nat.c (handle_output_debug_string, handle_exception):
8398 * target.h (target_read_string): Update.
8399 * target.c (target_read_string): Change "string" to
8401 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8403 * solib-frv.c (frv_current_sos): Update.
8404 * solib-dsbt.c (dsbt_current_sos): Update.
8405 * solib-darwin.c (darwin_current_sos): Update.
8406 * linux-thread-db.c (inferior_has_bug): Update.
8407 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
8408 Update. Remove alloca.
8409 * ada-lang.c (ada_main_name): Update.
8411 2018-03-30 Tom Tromey <tom@tromey.com>
8413 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
8414 (struct dwo_file_deleter): New.
8415 (dwo_file_up): New typedef.
8416 (open_and_init_dwo_file): Use dwo_file_up.
8417 (free_dwo_file_cleanup): Remove.
8419 2018-03-30 Tom Tromey <tom@tromey.com>
8421 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
8422 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
8424 2018-03-30 Tom Tromey <tom@tromey.com>
8426 * dwarf2read.c (class free_cached_comp_units): New class.
8427 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
8428 (free_cached_comp_units): Remove function.
8430 2018-03-30 Tom Tromey <tom@tromey.com>
8432 * utils.h (make_cleanup_unpush_target): Remove.
8433 * inf-ptrace.c (struct target_unpusher): New.
8434 (target_unpush_up) New typedef.
8435 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
8437 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
8439 2018-03-27 Tom Tromey <tom@tromey.com>
8441 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
8443 2018-03-27 Pedro Alves <palves@redhat.com>
8444 Tom Tromey <tom@tromey.com>
8446 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
8447 destructor. Now a class.
8448 (gdb_readline_wrapper_cleanup): Remove function.
8449 (gdb_readline_wrapper): Remove cleanups.
8451 2018-03-27 Tom Tromey <tom@tromey.com>
8453 * typeprint.h (struct type_print_options) <local_typedefs,
8454 global_typedefs>: Remove "struct" keyword.
8455 (class typedef_hash_table): New class.
8456 (recursively_update_typedef_hash, add_template_parameters)
8457 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
8458 (find_typedef_in_hash): Don't declare.
8459 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
8460 (typedef_hash_table::recursively_update): Rename from
8461 recursively_update_typedef_hash. Now a member.
8462 (typedef_hash_table::add_template_parameters): Rename from
8463 add_template_parameters. Now a member.
8464 (typedef_hash_table::typedef_hash_table): Now a constructor;
8465 rename from create_typedef_hash.
8466 (typedef_hash_table::~typedef_hash_table): Now a destructor;
8467 rename from free_typedef_hash.
8468 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
8469 (do_free_global_table): Remove.
8470 (typedef_hash_table::typedef_hash_table): New constructor; renamed
8471 from copy_type_recursive.
8472 (create_global_typedef_table): Remove.
8473 (typedef_hash_table::find_global_typedef): Now a member of
8475 (typedef_hash_table::find_typedef): Rename from
8476 find_typedef_in_hash; now a member.
8477 (whatis_exp): Update.
8478 * extension.h (struct ext_lang_type_printers): Add constructor and
8480 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
8482 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
8483 Now a constructor; rename from start_ext_lang_type_printers.
8484 (ext_lang_type_printers): Now a destructor; rename from
8485 free_ext_lang_type_printers.
8486 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
8488 (c_type_print_base_struct_union): Update. Remove cleanups.
8490 2018-03-27 Tom Tromey <tom@tromey.com>
8492 * dwarf-index-write.c: Include <cmath>.
8494 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8496 * NEWS: Add entry describing new "set|show varsize-limit" command.
8497 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
8499 * printcmd.c (_initialize_printcmd): Add "set var" alias of
8502 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
8504 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
8506 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
8507 * dwarf-index-common.c: New file.
8508 * dwarf-index-common.h: New file.
8509 * dwarf-index-write.c: New file.
8510 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
8511 (struct dwarf2_section_info): Move from here.
8512 (dwarf2_section_info_def): Likewise.
8513 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
8514 (offset_type): Likewise.
8515 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
8516 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
8517 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
8518 (byte_swap): Likewise.
8519 (MAYBE_SWAP): Likewise.
8520 (dwarf2_per_cu_ptr): Likewise.
8521 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
8522 (struct tu_stats): Likewise.
8523 (struct dwarf2_per_objfile): Likewise.
8524 (struct dwarf2_per_cu_data): Likewise.
8525 (struct signatured_type): Likewise.
8526 (sig_type_ptr): Likewise.
8527 (DEF_VEC_P (sig_type_ptr)): Likewise.
8528 (INDEX4_SUFFIX): Likewise.
8529 (INDEX5_SUFFIX): Likewise.
8530 (DEBUG_STR_SUFFIX): Likewise.
8531 (dwarf2_read_section): Make non-static.
8532 (mapped_index_string_hash): Move from here.
8533 (dwarf5_djb_hash): Likewise.
8534 (file_write): Likewise.
8535 (class data_buf): Likewise.
8536 (struct symtab_index_entry): Likewise.
8537 (struct mapped_symtab): Likewise.
8538 (find_slot): Likewise.
8539 (hash_expand): Likewise.
8540 (add_index_entry): Likewise.
8541 (uniquify_cu_indices): Likewise.
8542 (class c_str_view): Likewise.
8543 (class c_str_view_hasher): Likewise.
8544 (class vector_hasher): Likewise.
8545 (write_hash_table): Likewise.
8546 (psym_index_map): Likewise.
8547 (struct addrmap_index_data): Likewise.
8548 (add_address_entry): Likewise.
8549 (add_address_entry_worker): Likewise.
8550 (write_address_map): Likewise.
8551 (symbol_kind): Likewise.
8552 (write_psymbols): Likewise.
8553 (struct signatured_type_index_data): Likewise.
8554 (write_one_signatured_type): Likewise.
8555 (recursively_count_psymbols): Likewise.
8556 (recursively_write_psymbols): Likewise.
8557 (class debug_names): Likewise.
8558 (check_dwarf64_offsets): Likewise.
8559 (psyms_seen_size): Likewise.
8560 (write_gdbindex): Likewise.
8561 (write_debug_names): Likewise.
8562 (assert_file_size): Likewise.
8563 (write_psymtabs_to_index): Likewise.
8564 (save_gdb_index_command): Likewise.
8565 (_initialize_dwarf2_read): Don't register the "save gdb-index"
8567 * dwarf2read.h: New file.
8569 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8572 * dwarf2read.c (dwarf2_physname): Do not return the demangled
8573 symbol name if the CU's language stores symbol names in linkage
8575 * language.h (struct language_defn)
8576 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
8577 all instances of this struct.
8579 2018-03-26 Tom Tromey <tom@tromey.com>
8581 * stack.c (backtrace_command_1): Remove verbose code.
8583 2018-03-26 Tom Tromey <tom@tromey.com>
8585 * python/py-framefilter.c (py_print_type): Don't catch
8586 exceptions. Return void.
8587 (py_print_value): Likewise.
8588 (py_print_single_arg): Likewise.
8589 (enumerate_args): Don't catch exceptions.
8590 (py_print_args): Likewise.
8591 (py_print_frame): Likewise.
8592 (gdbpy_apply_frame_filter): Catch exceptions here.
8594 2018-03-26 Tom Tromey <tom@tromey.com>
8596 * stack.c (_initialize_stack): Remove trailing newlines from help
8597 text. Add "Usage" line to "backtrace" help.
8599 2018-03-26 Tom Tromey <tom@tromey.com>
8602 * python/py-framefilter.c (py_print_args): Call wrap_hint.
8604 2018-03-26 Tom Tromey <tom@tromey.com>
8606 * python/py-framefilter.c (py_print_single_arg): Return
8607 EXT_LANG_BT_ERROR from catch.
8609 2018-03-26 Tom Tromey <tom@tromey.com>
8612 * stack.c (backtrace_command_1): Move some code into no-filters
8615 2018-03-26 Tom Tromey <tom@tromey.com>
8617 * python/py-framefilter.c (throw_quit_or_print_exception): New
8619 (gdbpy_apply_frame_filter): Use it.
8621 2018-03-26 Tom Tromey <tom@tromey.com>
8624 * python/py-framefilter.c (py_print_type, py_print_value)
8625 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8628 2018-03-26 Tom Tromey <tom@tromey.com>
8630 * python/py-framefilter.c (enumerate_args): Use
8631 gdb::unique_xmalloc_ptr.
8633 2018-03-26 Tom Tromey <tom@tromey.com>
8635 * python/py-framefilter.c (py_print_frame): Return
8637 (gdbpy_apply_frame_filter): Update comment.
8638 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8640 <EXT_LANG_BT_NO_FILTERS>: Change value.
8642 2018-03-26 Tom Tromey <tom@tromey.com>
8645 * stack.c (backtrace_command): Parse "hide" argument.
8646 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8647 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8650 2018-03-26 Tom Tromey <tom@tromey.com>
8652 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8654 (backtrace_command): Remove "fulltrace", add "flags".
8656 2018-03-26 Tom Tromey <tom@tromey.com>
8658 * stack.c (backtrace_command): Rewrite command line parsing.
8660 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8662 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8664 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8666 * filename-seen-cache.h: Add include guard.
8668 2018-03-26 Keith Seitz <keiths@redhat.com>
8670 * symfile.c (place_section): Remove "struct" from section_addr_info
8672 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8673 "struct" keyword from section_addr_info.
8675 2018-03-26 Alan Hayward <alan.hayward@arm.com>
8677 * regformats/regdef.h (reg): Add constructors.
8679 2018-03-25 Pedro Alves <palves@redhat.com>
8681 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8682 if then/else bodies in var_func_name extraction.
8684 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
8686 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8687 lookup_minimal_symbol() to find symbol entry.
8688 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8690 2018-03-23 Keith Seitz <keiths@redhat.com>
8693 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8694 nested type definitions for C++, too.
8696 2018-03-23 Tom Tromey <tom@tromey.com>
8698 * machoread.c (struct oso_el): Add a constructor. Don't define as
8700 (macho_register_oso): Remove.
8701 (macho_symtab_read): Take a std::vector.
8702 (oso_el_compare_name): Now a std::sort comparator.
8703 (macho_symfile_read_all_oso): Take a std::vector.
8704 (macho_symfile_read): Use std::vector. Remove cleanups.
8706 2018-03-22 Tom Tromey <tom@tromey.com>
8708 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
8709 (record_full_goto_bookmark): Use std::string.
8711 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8714 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
8717 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8719 * rs6000-tdep.c (store_insn_p): New function.
8720 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
8721 and cr_reg to their unshifted values. Use store_insn_p to
8722 match LR saves using either R1 or fdata->alloca_reg. Use
8723 store_insn_p to match CR saves. Set alloca_reg_offset
8724 when alloca_reg and framep are set. Remove lr_reg shift
8725 when assigning to fdata->lr_register.
8727 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
8729 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
8730 command line args instead of emitting a warning.
8732 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8734 * tracepoint.h (struct static_tracepoint_marker): Initialize
8735 fields, define default constructor, move constructor and move
8736 assignment, disable the rest.
8737 <str_id, extra>: Make std::string.
8738 (release_static_tracepoint_marker): Remove.
8739 (free_current_marker): Remove.
8740 * tracepoint.c (free_current_marker): Remove.
8741 (parse_static_tracepoint_marker_definition): Adjust to
8742 std::string, use new hex2str overload.
8743 (release_static_tracepoint_marker): Remove.
8744 (print_one_static_tracepoint_marker): Get marker by reference
8745 and adjust to std::string.
8746 (info_static_tracepoint_markers_command): Adjust to std::vector
8748 * target.h (static_tracepoint_marker_p): Remove typedef.
8749 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
8750 (struct target_ops) <to_static_tracepoint_marker_at>: Return
8752 <to_static_tracepoint_markers_by_strid>: Return std::vector.
8754 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
8755 (target_debug_print_std_vector_static_tracepoint_marker): New.
8756 (target_debug_print_struct_static_tracepoint_marker_p): Rename
8758 (target_debug_print_static_tracepoint_marker_p): ... this.
8759 * target-delegates.c: Re-generate.
8760 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
8762 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
8763 (decode_static_tracepoint_spec): Adjust to std::vector.
8764 (tracepoint_print_one_detail): Adjust to std::string.
8765 (strace_marker_decode_location): Adjust to std::string.
8766 (update_static_tracepoint): Adjust to std::string, remove call
8767 to release_static_tracepoint_marker.
8768 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
8769 Adjust to std::vector.
8770 * remote.c (remote_static_tracepoint_marker_at): Return bool.
8771 (remote_static_tracepoint_markers_by_strid): Adjust to
8773 * common/rsp-low.h (hex2str): New overload with explicit count
8775 * common/rsp-low.c (hex2str): New overload with explicit count
8777 * unittests/rsp-low-selftests.c (test_hex2str): New function.
8778 (_initialize_rsp_low_selftests): Add test_hex2str test.
8779 * unittests/tracepoint-selftests.c
8780 (test_parse_static_tracepoint_marker_definition): Adjust to
8783 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8785 * tracepoint.c (parse_static_tracepoint_marker_definition):
8786 Consider case where the definition is followed by more
8788 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8789 tracepoint-selftests.c.
8790 * unittests/tracepoint-selftests.c: New.
8792 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8794 * MAINTAINERS (Write After Approval): Add Pedro Franco de
8797 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8799 * symtab.c (find_pc_sect_line): fixed indentation.
8801 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8803 * symtab.c (find_pc_sect_line): now uses binary search.
8805 2018-03-19 Tom Tromey <tom@tromey.com>
8807 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
8810 2018-03-19 Pedro Alves <palves@redhat.com>
8811 Tom Tromey <tom@tromey.com>
8813 * unittests/observable-selftests.c: New file.
8814 * common/observable.h: New file.
8815 * observable.h: New file.
8816 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
8817 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
8818 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
8819 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
8820 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
8821 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
8822 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
8823 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
8824 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
8825 python/py-breakpoint.c, python/py-finishbreakpoint.c,
8826 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
8827 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
8828 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
8829 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
8830 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
8831 tui/tui-interp.c, valops.c: Update all users.
8832 * tui/tui-hooks.c (tui_bp_created_observer)
8833 (tui_bp_deleted_observer, tui_bp_modified_observer)
8834 (tui_inferior_exit_observer, tui_before_prompt_observer)
8835 (tui_normal_stop_observer, tui_register_changed_observer):
8837 (tui_observers_token): New global.
8838 (attach_or_detach, tui_attach_detach_observers): New functions.
8839 (tui_install_hooks, tui_remove_hooks): Use
8840 tui_attach_detach_observers.
8841 * record-btrace.c (record_btrace_thread_observer): Remove.
8842 (record_btrace_thread_observer_token): New global.
8843 * observer.sh: Remove.
8844 * observer.c: Rename to observable.c.
8845 * observable.c (namespace gdb_observers): Define new objects.
8846 (observer_debug): Move into gdb_observers namespace.
8847 (struct observer, struct observer_list, xalloc_observer_list_node)
8848 (xfree_observer_list_node, generic_observer_attach)
8849 (generic_observer_detach, generic_observer_notify): Remove.
8850 (_initialize_observer): Update.
8851 Don't include observer.inc.
8852 * Makefile.in (generated_files): Remove observer.h, observer.inc.
8853 (clean mostlyclean): Likewise.
8854 (observer.h, observer.inc): Remove targets.
8855 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
8856 (COMMON_SFILES): Use observable.c, not observer.c.
8857 * .gitignore: Remove observer.h.
8859 2018-03-18 Tom Tromey <tom@tromey.com>
8861 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
8863 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
8865 2018-03-17 Tom Tromey <tom@tromey.com>
8867 * auto-load.c (auto_load_objfile_script_1): Use std::string.
8869 2018-03-17 Tom Tromey <tom@tromey.com>
8871 * target.c (class scoped_target_fd): New.
8872 (target_fileio_close_cleanup): Remove.
8873 (target_fileio_read_alloc_1): Use scoped_target_fd.
8875 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
8877 * silent-rules.mk: New.
8878 * Makefile.in: Include silent-rules.mk
8879 (srcdir, VPATH, top_srcdir): Move up.
8880 (COMPILE): Add ECHO_CXX.
8881 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
8882 (init.c): Add ECHO_INIT_C.
8883 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
8884 (version.c): Add ECHO_GEN.
8885 (printcmd.o): Add ECHO_CXX.
8886 (target-float.o): Add ECHO_CXX.
8887 (ada-exp.o): Add ECHO_CXX.
8888 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
8889 (insight$(EXEEXT)): Add ECHO_CXXLD.
8890 * gnulib/configure.ac: Add AM_SILENT_RULES.
8891 * gnulib/aclocal.m4: Re-generate.
8892 * gnulib/configure: Re-generate.
8893 * gnulib/import/Makefile.in: Re-generate.
8895 2018-03-16 Tom Tromey <tom@tromey.com>
8897 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
8898 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
8899 * utils.c (do_free_section_addr_info)
8900 (make_cleanup_free_section_addr_info): Remove.
8901 * symfile.h (struct other_sections): Add constructor.
8902 (struct section_addr_info): Remove.
8903 (section_addr_info): New typedef.
8904 (struct sym_fns) <sym_offsets>: Change type of parameter.
8905 (build_section_addr_info_from_objfile)
8906 (relative_addr_info_to_section_offsets, addr_info_make_relative)
8907 (default_symfile_offsets, symbol_file_add)
8908 (symbol_file_add_from_bfd)
8909 (build_section_addr_info_from_section_table): Update.
8910 (alloc_section_addr_info, free_section_addr_info): Don't declare.
8911 * symfile.c (alloc_section_addr_info): Remove.
8912 (build_section_addr_info_from_section_table): Change return type.
8914 (build_section_addr_info_from_bfd)
8915 (build_section_addr_info_from_objfile): Likewise.
8916 (free_section_addr_info): Remove.
8917 (relative_addr_info_to_section_offsets): Change type of "addrs".
8918 (addrs_section_compar): Now a std::sort comparator.
8919 (addrs_section_sort): Change return type.
8920 (addr_info_make_relative): Change type of "addrs". Update.
8921 (default_symfile_offsets, syms_from_objfile_1)
8922 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
8923 (symbol_file_add_separate): Update.
8924 (symbol_file_add): Change type of "addrs". Update.
8925 (add_symbol_file_command): Update. Remove cleanups.
8926 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
8928 * symfile-debug.c (debug_sym_offsets): Change type of "info".
8929 * solib.c (solib_read_symbols): Update.
8930 * objfiles.c (objfile_relocate): Update. Remove cleanups.
8931 * machoread.c (macho_symfile_offsets): Update.
8932 * jit.c (jit_bfd_try_read_symtab): Update.
8934 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
8936 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8937 unittests/utils-selftests.c.
8938 * unittests/utils-selftests.c: New file.
8940 2018-03-14 Tom Tromey <tom@tromey.com>
8943 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
8946 2018-03-14 Tom Tromey <tom@tromey.com>
8949 * printcmd.c (printf_pointer): Allow "-" in format.
8951 2018-03-14 Tom Tromey <tom@tromey.com>
8953 * printcmd.c (_initialize_printcmd): Add usage to printf.
8955 2018-03-14 Yao Qi <qiyao@sourceware.org>
8957 * MAINTAINERS: Update my email address.
8959 2018-03-13 Tom Tromey <tom@tromey.com>
8961 * machoread.c (macho_check_dsym): Change filenamep to a
8963 (macho_symfile_read): Update.
8964 * symfile.c (load_command): Use std::string.
8966 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
8968 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
8969 to error message string.
8970 (riscv_register_name): Use xsnprintf instead of sprintf.
8971 (riscv_insn::fetch_instruction): Use gdb_assert instead of
8973 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
8975 (riscv_push_dummy_call): Likewise.
8977 2018-03-12 Tom Tromey <tom@tromey.com>
8979 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
8980 Use gdb::byte_vector.
8981 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
8983 2018-03-12 Yao Qi <yao.qi@linaro.org>
8985 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
8986 parameter type to readable_regcache.
8987 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
8990 2018-03-11 Tom Tromey <tom@tromey.com>
8992 * dwarf2read.c (struct nextfield): Add initializers.
8993 (struct nextfnfield): Remove.
8994 (struct fnfieldlist): Add initializers. Remove "length" and
8995 "head", use std::vector.
8996 (struct decl_field_list): Remove.
8997 (struct field_info): Add initializers.
8998 <fields, baseclasses>: Now std::vector.
8999 <nbaseclasses, nfnfields, typedef_field_list_count,
9000 nested_types_list_count>: Remove.
9001 (dwarf2_add_field, dwarf2_add_type_defn)
9002 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
9003 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
9004 (process_structure_scope): Update.
9006 2018-03-11 Tom Tromey <tom@tromey.com>
9008 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
9009 for use by std::sort.
9010 (build_type_psymtabs_1): Use std::vector.
9012 2018-03-09 Eli Zaretskii <eliz@gnu.org>
9014 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
9015 and LIBMPFR in the printed configuration.
9017 2018-03-08 Tom Tromey <tom@tromey.com>
9019 * source.c (get_filename_and_charpos): Use scoped_fd.
9020 * nto-procfs.c (procfs_open_1): Use scoped_fd.
9021 (procfs_pidlist): Likewise.
9022 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
9023 (iterate_over_mappings): Likewise.
9025 2018-03-08 Tom Tromey <tom@tromey.com>
9027 * infcall.c (struct call_return_meta_info)
9028 <stack_temporaries_enabled>: Remove.
9029 (get_call_return_value, call_function_by_hand_dummy): Update.
9030 * thread.c (disable_thread_stack_temporaries): Remove.
9031 (enable_thread_stack_temporaries): Remove.
9032 (thread_stack_temporaries_enabled_p): Return bool.
9033 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
9034 (get_last_thread_stack_temporary): Update.
9035 * eval.c (evaluate_subexp): Update.
9036 * gdbthread.h (class enable_thread_stack_temporaries): Now a
9037 class, not a function.
9038 (value_ptr, value_vec): Remove typedefs.
9039 (class thread_info) <stack_temporaries_enabled>: Now bool.
9040 <stack_temporaries>: Now a std::vector.
9041 (thread_stack_temporaries_enabled_p)
9042 (value_in_thread_stack_temporaries): Return bool.
9044 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
9046 * remote.c (putpkt_binary): Fix omitted bytes reporting.
9047 (getpkt_or_notif_sane_1): Likewise.
9049 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9051 * build-id.c (build_id_to_debug_bfd): Use std::string.
9053 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9055 * build-id.c (find_separate_debug_file_by_buildid): Return
9057 * build-id.h (find_separate_debug_file_by_buildid): Return
9059 * coffread.c (coff_symfile_read): Adjust to std::string.
9060 * elfread.c (elf_symfile_read): Adjust to std::string.
9061 * symfile.c (separate_debug_file_exists): Change parameter to
9063 (find_separate_debug_file): Return std::string.
9064 (find_separate_debug_file_by_debuglink): Return std::string.
9065 * symfile.h (find_separate_debug_file_by_debuglink): Return
9068 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
9070 * common/xml-utils.c (xml_escape_text): Move code to...
9071 (xml_escape_text_append): ... this new function.
9072 * common/xml-utils.h (xml_escape_text_append): New declaration.
9073 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
9075 (_initialize_xml_utils): register test_xml_escape_text_append as
9078 2018-03-07 Alan Hayward <alan.hayward@arm.com>
9080 * defs.h: Remove MAX_REGISTER_SIZE.
9081 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
9083 * python/py-unwind.c (pyuw_sniffer): Likewise.
9085 2018-03-07 Tom Tromey <tom@tromey.com>
9087 * linux-tdep.c (linux_info_proc): Update.
9088 * target.h (struct target_ops) <to_fileio_readlink>: Return
9090 (target_fileio_readlink): Return optional<string>.
9091 * remote.c (remote_hostio_readlink): Return optional<string>.
9092 * inf-child.c (inf_child_fileio_readlink): Return
9094 * target.c (target_fileio_readlink): Return optional<string>.
9096 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
9098 * regcache.c (cooked_read_test): Add riscv to the list of
9099 architectures that have a save_reggroup.
9101 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
9103 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
9104 value is not a dynamic class object.
9106 2018-03-06 Tom Tromey <tom@tromey.com>
9108 * rust-exp.y: Formatting fixes.
9110 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9112 * riscv-tdep.c (riscv_register_name): Remove target description
9114 (riscv_gdbarch_init): Remove target description check.
9116 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9118 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
9120 * riscv-tdep.h: Likewise.
9122 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9124 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
9125 (riscv_pseudo_register_write): Delete.
9126 (riscv_gdbarch_init): Remove all use of pseudo registers.
9128 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9130 * record-btrace.c (btrace_print_lines): Replace cleanup
9131 parameter with RAII equivalents.
9132 (btrace_insn_history): Replace cleanup with RAII equivalents.
9133 * ui-out.h (make_cleanup_ui_out_list_begin_end,
9134 make_cleanup_ui_out_tuple_begin_end): Remove.
9135 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
9136 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
9137 make_cleanup_ui_out_list_begin_end): Remove.
9139 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9141 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
9142 parameter types to std::vector. Use bool.
9143 (record_btrace_wait): Replace VEC(tp_t) with
9144 std::vector<thread_info *>.
9145 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
9147 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9149 * record-btrace.c (record_btrace_disable_callback): Remove.
9150 (struct scoped_btrace_disable): New.
9151 (record_btrace_open): Use scoped_btrace_disable.
9153 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9155 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
9156 reading values from registers.
9158 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9160 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
9163 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9165 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
9166 change parameter type. Use GDB's print functions, and use
9167 core_addr_to_string where appropriate.
9168 (riscv_push_dummy_call): Use core_addr_to_string where
9169 appropriate, update call to riscv_print_arg_location, and reindent
9171 (riscv_return_value): Update call to riscv_print_arg_location.
9173 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9174 Tim Newsome <tim@sifive.com>
9175 Albert Ou <a0u@eecs.berkeley.edu>
9176 Darius Rad <darius@bluespec.com>
9178 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
9179 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
9180 (ALLDEPFILES): Add riscv-tdep.c
9181 * configure.tgt: Add riscv support.
9182 * riscv-tdep.c: New file.
9183 * riscv-tdep.h: New file.
9184 * NEWS: Mention new target.
9185 * MAINTAINERS: Add entry for riscv.
9187 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9189 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
9190 fields within aggregates.
9192 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
9194 * record-btrace.c (btrace_print_lines): Change type of flags to
9195 gdb_disassembly_flags.
9197 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9199 * fbsd-nat.c: Include "inf-ptrace.h".
9200 (USE_SIGTRAP_SIGINFO): Conditionally define.
9201 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
9202 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
9203 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
9205 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
9207 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
9209 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
9210 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
9211 "supports_stopped_by_hw_breakpoint" target methods.
9213 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9215 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
9216 * fbsd-nat.c (debug_fbsd_nat): New variable.
9217 (show_fbsd_nat_debug): New function.
9218 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
9219 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
9221 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9223 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
9224 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
9226 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
9227 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
9230 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9232 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
9233 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
9235 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9237 * charset.c (struct charset_vector): New.
9238 (charsets): Change type to charset_vector.
9239 (find_charset_names): Adjust.
9241 (_initialize_charset): Adjust.
9243 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9245 * progspace.h (struct program_space) <deleted_solibs>: Change
9246 type to std::vector<std::string>.
9247 * progspace.c (clear_program_space_solib_cache): Adjust.
9248 * breakpoint.c (print_solib_event): Adjust.
9249 (check_status_catch_solib): Adjust.
9250 * solib.c (update_solib_list): Adjust.
9251 * ui-out.h (class ui_out) <field_string>: New overload.
9252 * ui-out.c (ui_out::field_string): New overload.
9254 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9256 * progspace.h (struct program_space): Add constructor and
9257 destructor, initialize fields.
9258 (add_program_space): Remove.
9259 * progspace.c (add_program_space): Rename to...
9260 (program_space::program_space): ... this.
9261 (release_program_space): Rename to...
9262 (program_space::~program_space): ... this.
9263 (delete_program_space): Use delete to delete program_space.
9264 (initialize_progspace): Use new to allocate program_space.
9265 * inferior.c (add_inferior_with_spaces): Likewise.
9266 (clone_inferior_command): Likewise.
9267 * infrun.c (follow_fork_inferior): Likewise.
9268 (handle_vfork_child_exec_or_exit): Likewise.
9270 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9272 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
9273 (delim_string_to_char_ptr_vec): Return std::vector of
9274 gdb::unique_xmalloc_ptr.
9275 (dirnames_to_char_ptr_vec_append): Take std::vector of
9276 gdb::unique_xmalloc_ptr.
9277 (dirnames_to_char_ptr_vec): Return std::vector of
9278 gdb::unique_xmalloc_ptr.
9279 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
9280 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
9281 (delim_string_to_char_ptr_vec): Return an std::vector of
9282 gdb::unique_xmalloc_ptr, adjust the code.
9283 (dirnames_to_char_ptr_vec_append): Take an std::vector of
9284 gdb::unique_xmalloc_ptr, adjust the code.
9285 (dirnames_to_char_ptr_vec): Return an std::vector of
9286 gdb::unique_xmalloc_ptr, adjust the code.
9287 * auto-load.c (auto_load_safe_path_vec): Change type to
9288 std::vector of gdb::unique_xmalloc_ptr.
9289 (auto_load_expand_dir_vars): Return an std::vector of
9290 gdb::unique_xmalloc_ptr, adjust the code.
9291 (auto_load_safe_path_vec_update): Adjust.
9292 (filename_is_in_auto_load_safe_path_vec): Adjust.
9293 (auto_load_objfile_script_1): Adjust.
9294 * build-id.c (build_id_to_debug_bfd): Adjust.
9295 * linux-thread-db.c (thread_db_load_search): Adjust.
9296 * source.c (add_path): Adjust.
9298 * symfile.c (find_separate_debug_file): Adjust.
9299 * utils.c (do_free_char_ptr_vec): Remove.
9300 (make_cleanup_free_char_ptr_vec): Remove.
9302 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
9305 * common/pathstuff.c: Conditionally include "<windows.h>".
9307 2018-03-01 Georg Sauthoff <mail@georg.so>
9310 * gcore.in: Quote variables and switch interpreter to bash.
9312 2018-03-01 Tom Tromey <tom@tromey.com>
9314 * dwarf2read.c (alloc_discriminant_info): Fix default_index
9315 assertion. Add assertion for discriminant_index.
9316 (quirk_rust_enum): Use correct base type name in univariant case.
9318 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
9320 * record.c (get_call_history_modifiers): Return a
9322 (cmd_record_call_history): Adjust.
9323 * record-btrace.c (record_btrace_call_history): Adjust.
9324 (record_btrace_call_history_range): Adjust.
9325 (record_btrace_call_history_from): Adjust.
9326 * target-debug.h (target_debug_print_record_print_flags): New.
9327 * target-delegates.c: Re-generate.
9328 * target.c (target_call_history): Change flags type.
9329 (target_call_history_from): Likewise.
9330 (target_call_history_range): Likewise.
9331 * target.h (struct target_ops) <target_call_history>: Likewise.
9332 (target_call_history_from): Likewise.
9333 (target_call_history_range): Likewise.
9335 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9336 Simon Marchi <simon.marchi@polymtl.ca>
9338 * common/common-utils.c: Include "sys/stat.h".
9339 (is_regular_file): Move here from "source.c"; change return
9341 * common/common-utils.h (is_regular_file): New prototype.
9342 * common/pathstuff.c (contains_dir_separator): New function.
9343 * common/pathstuff.h (contains_dir_separator): New prototype.
9344 * source.c: Don't include "sys/stat.h".
9345 (is_regular_file): Move to "common/common-utils.c".
9347 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9349 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
9350 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
9351 * auto-load.c: Include "common/pathstuff.h".
9352 * common/common-def.h (current_directory): Move here.
9353 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
9355 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
9357 * common/pathstuff.c: New file.
9358 * common/pathstuff.h: New file.
9359 * compile/compile.c: Include "common/pathstuff.h".
9360 * defs.h (current_directory): Move to "common/common-defs.h".
9361 * dwarf2read.c: Include "common/pathstuff.h".
9363 * guile/scm-safe-call.c: Likewise.
9364 * linux-thread-db.c: Likewise.
9366 * nto-tdep.c: Likewise.
9367 * objfiles.c: Likewise.
9368 * source.c: Likewise.
9369 * symtab.c: Likewise.
9370 * utils.c: Include "common/pathstuff.h".
9371 (gdb_realpath): Move to "common/pathstuff.c".
9372 (gdb_realpath_keepfile): Likewise.
9373 (gdb_abspath): Likewise.
9374 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
9375 (gdb_realpath_keepfile): Likewise.
9376 (gdb_abspath): Likewise.
9378 2018-02-28 John Baldwin <jhb@FreeBSD.org>
9380 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
9381 wildcard process pid for super_resume for kernels with a
9384 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
9386 * compile/compile.c (get_args): Add additional comments
9387 explaining function.
9389 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
9390 Tom Tromey <tom@tromey.com>
9392 * target.h (memory_write_request_s): Remove typedef. Don't define
9394 (target_write_memory_blocks): Change argument to std::vector.
9395 (struct memory_write_request): Add constructor.
9396 * target-memory.c (compare_block_starting_address): Return bool.
9397 Change argument types.
9398 (claim_memory): Change arguments to use std::vector.
9399 (split_regular_and_flash_blocks, blocks_to_erase)
9400 (compute_garbled_blocks): Likewise.
9401 (cleanup_request_data, cleanup_write_requests_vector): Remove.
9402 (target_write_memory_blocks): Change argument to std::vector.
9403 * symfile.c (struct load_section_data): Add constructor and
9404 destructor. Use std::vector for "requests".
9405 (struct load_progress_data): Add initializers.
9406 (load_section_callback): Update. Use "new".
9407 (clear_memory_write_data): Remove.
9408 (generic_load): Update.
9410 2018-02-27 Alan Hayward <alan.hayward@arm.com>
9412 * arch/aarch64.h: Use common/tdesc.h.
9414 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9416 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
9417 architecture with a 64-bit ABI.
9419 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9421 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
9422 ahead of target description loading.
9424 2018-02-26 Tom Tromey <tom@tromey.com>
9426 * stack.c (backtrace_command_1): Update.
9427 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
9429 * python/py-framefilter.c (py_print_frame)
9430 (gdbpy_apply_frame_filter): Change type of "flags".
9431 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
9433 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
9434 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
9435 * extension.h (enum frame_filter_flag): Rename from
9437 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
9438 (apply_ext_lang_frame_filter): Change type of "flags".
9439 * extension.c (apply_ext_lang_frame_filter): Change type of
9441 * extension-priv.h (struct extension_language_ops)
9442 <apply_frame_filter>: Change type of "flags".
9444 2018-02-26 Tom Tromey <tom@tromey.com>
9447 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
9448 off-by-one in py_end computation.
9449 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
9451 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
9454 2018-02-26 Tom Tromey <tom@tromey.com>
9456 * dwarf2read.c (struct variant_field): New.
9457 (struct nextfield) <variant>: New field.
9458 (dwarf2_add_field): Handle DW_TAG_variant_part.
9459 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
9460 discriminated union.
9461 (read_structure_type): Handle DW_TAG_variant_part.
9462 (handle_struct_member_die): New function, extracted from
9463 process_structure_scope. Handle DW_TAG_variant.
9464 (process_structure_scope): Handle discriminated unions. Call
9465 handle_struct_member_die.
9467 2018-02-26 Tom Tromey <tom@tromey.com>
9469 * rust-lang.h (rust_last_path_segment): Declare.
9470 * rust-lang.c (rust_last_path_segment): Now public. Change
9472 (struct disr_info): Remove.
9473 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
9474 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
9475 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
9476 (rust_enum_p, rust_enum_variant): New function.
9477 (rust_underscore_fields): Remove "offset" parameter.
9478 (rust_print_enum): New function.
9479 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
9480 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
9481 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
9483 (rust_internal_print_type): New function, from rust_print_type.
9485 (rust_print_type): Call rust_internal_print_type.
9486 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
9487 Update enum handling.
9488 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
9489 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
9490 (rust_union_quirks): New functions.
9491 (process_full_comp_unit, process_full_type_unit): Call
9493 (process_structure_scope): Update rust_unions if necessary.
9495 2018-02-26 Tom Tromey <tom@tromey.com>
9497 * value.h (value_union_variant): Declare.
9498 * valops.c (value_union_variant): New function.
9499 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
9500 (struct discriminant_info): New.
9501 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
9503 (struct main_type) <flag_discriminated_union>: New field.
9505 2018-02-26 Tom Tromey <tom@tromey.com>
9507 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9508 unittests/unpack-selftests.c.
9509 * unittests/unpack-selftests.c: New file.
9510 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
9512 2018-02-26 Yao Qi <yao.qi@linaro.org>
9514 * dwarf2read.c (struct partial_die_info) <read>: New method.
9515 (read_partial_die): Remove the declaration.
9516 (load_partial_dies): Update.
9517 (partial_die_info::partial_die_info):
9518 (read_partial_die): Change it to partial_die_info::read.
9520 2018-02-26 Yao Qi <yao.qi@linaro.org>
9522 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
9523 (fixup_partial_die): Remove declaration.
9524 (scan_partial_symbols): Update.
9525 (partial_die_parent_scope): Likewise.
9526 (partial_die_full_name): Likewise.
9527 (fixup_partial_die): Change it to partial_die_info::fixup.
9529 2018-02-26 Yao Qi <yao.qi@linaro.org>
9531 * dwarf2read.c (read_partial_die): Update the declaration.
9532 (load_partial_dies): Caller update.
9533 (read_partial_die): Remove one argument abbrev_len.
9535 2018-02-26 Yao Qi <yao.qi@linaro.org>
9537 * dwarf2read.c (struct partial_die_info): Add ctor, delete
9538 assignment operator.
9539 (load_partial_dies): Use ctor and copy ctor.
9540 (read_partial_die): Update.
9541 (dwarf2_cu::find_partial_die): Use ctor.
9543 2018-02-26 Yao Qi <yao.qi@linaro.org>
9545 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
9546 (find_partial_die_in_comp_unit): Change it to
9547 dwarf2_cu::find_partial_die.
9548 (find_partial_die): Update.
9550 2018-02-26 Yao Qi <yao.qi@linaro.org>
9552 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
9555 2018-02-26 Yao Qi <yao.qi@linaro.org>
9557 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
9559 2018-02-26 Alan Hayward <alan.hayward@arm.com>
9561 * arch/amd64.h: Use common/tdesc.h.
9562 * arch/i386.c: Likewise.
9563 * arch/i386.h: Likewise.
9564 * arch/tic6x.c: Likewise.
9565 * arch/tdesc.h: Move file from here...
9566 * common/tdesc.h: ...to here.
9567 * features/aarch64-core.c: Regenerate.
9568 * features/aarch64-fpu.c: Regenerate.
9569 * features/i386/32bit-avx.c: Regenerate.
9570 * features/i386/32bit-avx512.c: Regenerate.
9571 * features/i386/32bit-core.c: Regenerate.
9572 * features/i386/32bit-linux.c: Regenerate.
9573 * features/i386/32bit-mpx.c: Regenerate.
9574 * features/i386/32bit-pkeys.c: Regenerate.
9575 * features/i386/32bit-sse.c: Regenerate.
9576 * features/i386/64bit-avx.c: Regenerate.
9577 * features/i386/64bit-avx512.c: Regenerate.
9578 * features/i386/64bit-core.c: Regenerate.
9579 * features/i386/64bit-linux.c: Regenerate.
9580 * features/i386/64bit-mpx.c: Regenerate.
9581 * features/i386/64bit-pkeys.c: Regenerate.
9582 * features/i386/64bit-segments.c: Regenerate.
9583 * features/i386/64bit-sse.c: Regenerate.
9584 * features/i386/x32-core.c: Regenerate.
9585 * features/tic6x-c6xp.c: Regenerate.
9586 * features/tic6x-core.c: Regenerate.
9587 * features/tic6x-gp.c: Regenerate.
9588 * target-descriptions.c: Use common/tdesc.h.
9589 * target-descriptions.h: Likewise.
9591 2018-02-24 Tom Tromey <tom@tromey.com>
9593 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
9594 (try_thread_db_load_from_dir, thread_db_load_search): Use
9596 (info_auto_load_libthread_db_compare): Return bool. Change
9598 (info_auto_load_libthread_db): Use std::vector, std::string.
9601 2018-02-24 Tom Tromey <tom@tromey.com>
9603 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
9605 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
9607 * gdbarch.c: Rebuild.
9608 * gdbarch.h: Rebuild.
9609 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
9610 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
9611 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
9614 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
9616 * gdbtypes.h (sect_offset): Change type to uint64_t.
9617 (sect_offset_str): New function.
9618 * dwarf2read.c (create_addrmap_from_aranges): Use
9620 (error_check_comp_unit_head): Likewise.
9621 (create_debug_type_hash_table): Likewise.
9622 (read_cutu_die_from_dwo): Likewise.
9623 (init_cutu_and_read_dies): Likewise.
9624 (init_cutu_and_read_dies_no_follow): Likewise.
9625 (process_psymtab_comp_unit_reader): Likewise.
9626 (partial_die_parent_scope): Likewise.
9627 (peek_die_abbrev): Likewise.
9628 (process_queue): Likewise.
9629 (dwarf2_physname): Likewise.
9630 (read_namespace_alias): Likewise.
9631 (read_import_statement): Likewise.
9632 (create_dwo_cu_reader): Likewise.
9633 (create_cus_hash_table): Likewise.
9634 (lookup_dwo_cutu): Likewise.
9635 (inherit_abstract_dies): Likewise.
9636 (read_func_scope): Likewise.
9637 (read_call_site_scope): Likewise.
9638 (dwarf2_add_member_fn): Likewise.
9639 (read_common_block): Likewise.
9640 (read_module_type): Likewise.
9641 (read_typedef): Likewise.
9642 (read_subrange_type): Likewise.
9643 (load_partial_dies): Likewise.
9644 (read_partial_die): Likewise.
9645 (find_partial_die): Likewise.
9646 (read_str_index): Likewise.
9647 (dwarf2_string_attr): Likewise.
9648 (build_error_marker_type): Likewise.
9649 (lookup_die_type): Likewise.
9650 (dump_die_shallow): Likewise.
9651 (follow_die_ref): Likewise.
9652 (dwarf2_fetch_die_loc_sect_off): Likewise.
9653 (dwarf2_fetch_constant_bytes): Likewise.
9654 (follow_die_sig): Likewise.
9655 (get_signatured_type): Likewise.
9656 (get_DW_AT_signature_type): Likewise.
9657 (dwarf2_find_containing_comp_unit): Likewise.
9658 (set_die_type): Likewise.
9660 2018-02-21 John Baldwin <jhb@FreeBSD.org>
9662 * arch/aarch64.c: Include "common-defs.h".
9663 * arch/amd64.c: Likewise.
9664 * arch/i386.c: Likewise.
9666 2018-02-21 Tom Tromey <tom@tromey.com>
9668 * value.h: (extract_field_op): Update.
9669 * eval.c (extract_field_op): Return a const char *.
9670 * expression.h (parse_expression_for_completion): Update.
9671 * completer.c (complete_expression): Update.
9672 (add_struct_fields): Make fieldname const.
9673 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9674 (mark_completion_tag, parse_exp_in_context_1): Update.
9675 (parse_expression_for_completion): Change "name" to
9676 unique_xmalloc_ptr*.
9678 2018-02-21 Tom Tromey <tom@tromey.com>
9680 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9682 2018-02-21 Yao Qi <yao.qi@linaro.org>
9684 * avr-tdep.c (avr_read_pc): Change parameter type to
9686 * gdbarch.sh (read_pc): Likewise.
9687 * gdbarch.c: Re-generated.
9688 * gdbarch.h: Re-generated.
9689 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9691 * ia64-tdep.c (ia64_read_pc): Likewise.
9692 * mips-tdep.c (mips_read_pc): Likewise.
9693 * spu-tdep.c (spu_read_pc): Likewise.
9695 2018-02-21 Yao Qi <yao.qi@linaro.org>
9697 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
9698 * regcache-dump.c: New file.
9699 * regcache.c: Move register_dump to regcache-dump.c.
9700 (maintenance_print_registers): Likewise.
9701 (maintenance_print_raw_registers): Likewise.
9702 (maintenance_print_cooked_registers): Likewise.
9703 (maintenance_print_register_groups): Likewise.
9704 (maintenance_print_remote_registers): Likewise.
9705 (_initialize_regcache): Likewise.
9706 * regcache.h (register_dump): Moved from regcache.c.
9708 2018-02-21 Yao Qi <yao.qi@linaro.org>
9710 * regcache.c (regcache::regcache): Update.
9711 (regcache::invalidate): Move it to detached_regcache::invalidate.
9712 (get_thread_arch_aspace_regcache): Update.
9713 (regcache::raw_update): Update.
9714 (regcache::cooked_read): Remove some code.
9715 (regcache::cooked_read_value): Likewise.
9716 (regcache::raw_write): Remove assert on m_readonly_p.
9717 (regcache::raw_supply_integer): Move it to
9718 detached_regcache::raw_supply_integer.
9719 (regcache::raw_supply_zeroed): Likewise.
9720 * regcache.h (detached_regcache) <raw_supply_integer>: New
9722 <raw_supply_zeroed, invalidate>: Likewise.
9723 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
9724 <invalidate>: Likewise.
9725 <m_readonly_p>: Removed.
9727 2018-02-21 Yao Qi <yao.qi@linaro.org>
9729 * infcmd.c (get_return_value): Let stop_regs point to
9730 get_current_regcache.
9731 * regcache.c (regcache::regcache): Remove.
9732 (register_dump_reg_buffer): New class.
9733 (regcache_print): Adjust.
9734 * regcache.h (regcache): Remove constructors.
9736 2018-02-21 Yao Qi <yao.qi@linaro.org>
9738 * regcache.c (class register_dump): New class.
9739 (register_dump_regcache, register_dump_none): New class.
9740 (register_dump_remote, register_dump_groups): New class.
9741 (regcache_print): Update.
9742 * regcache.h (regcache_dump_what): Move it to regcache.c.
9743 (regcache) <dump>: Remove.
9745 2018-02-21 Yao Qi <yao.qi@linaro.org>
9747 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
9749 (jit_unwind_reg_set_impl): Call raw_supply.
9750 (jit_frame_sniffer): Use reg_buffer_rw.
9751 * record-full.c (record_full_core_regbuf): Change its type.
9752 (record_full_core_open_1): Use reg_buffer_rw.
9753 (record_full_close): Likewise.
9754 (record_full_core_fetch_registers): Use regcache->raw_supply.
9755 (record_full_core_store_registers): Likewise.
9756 * regcache.c (regcache::get_register_status): Move it to
9758 (regcache_raw_set_cached_value): Remove.
9759 (regcache::raw_set_cached_value): Remove.
9760 (regcache::raw_write): Call raw_supply.
9761 (regcache::raw_supply): Move it to reg_buffer_rw.
9762 * regcache.h (regcache_raw_set_cached_value): Remove.
9763 (reg_buffer_rw): New class.
9765 2018-02-21 Yao Qi <yao.qi@linaro.org>
9767 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
9768 readonly_detached_regcache.
9769 (dummy_frame_prev_register): Use regcache->cooked_read.
9770 * frame.c (frame_save_as_regcache): Change return type.
9771 (frame_pop): Update.
9772 * frame.h (frame_save_as_regcache): Update declaration.
9773 * inferior.h (get_infcall_suspend_state_regcache): Update
9775 * infrun.c (infcall_suspend_state) <registers>: use
9776 readonly_detached_regcache.
9777 (save_infcall_suspend_state): Don't use regcache_dup.
9778 (get_infcall_suspend_state_regcache): Change return type.
9779 * linux-fork.c (struct fork_info) <savedregs>: Change to
9780 readonly_detached_regcache.
9782 (fork_save_infrun_state): Don't use regcache_dup.
9783 (info_checkpoints_command): Adjust.
9784 * mi/mi-main.c (register_changed_p): Update declaration.
9785 (mi_cmd_data_list_changed_registers): Use
9786 readonly_detached_regcache.
9787 (register_changed_p): Change parameter type to
9788 readonly_detached_regcache.
9789 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
9790 readonly_detached_regcache.
9791 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
9792 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
9794 (regcache::save): Move it to reg_buffer.
9795 (regcache::restore): Change parameter type.
9796 (regcache_dup): Remove.
9797 * regcache.h (reg_buffer) <save>: New method.
9798 (readonly_detached_regcache): New class.
9799 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
9800 readonly_detached_regcache.
9801 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
9803 2018-02-21 Yao Qi <yao.qi@linaro.org>
9805 * frame.c (frame_save_as_regcache): Use regcache method save.
9806 (frame_pop): Use regcache method restore.
9807 * infrun.c (restore_infcall_suspend_state): Likewise.
9808 * linux-fork.c (fork_load_infrun_state): Likewise.
9809 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
9811 * regcache.c (regcache_save): Remove.
9812 (regcache::restore): More asserts.
9813 (regcache_cpy): Remove.
9814 * regcache.h (regcache_save): Remove the declaration.
9815 (regcache::restore): Move from private to public.
9816 Remove the friend declaration of regcache_cpy.
9817 (regcache_cpy): Remove declaration.
9819 2018-02-21 Yao Qi <yao.qi@linaro.org>
9821 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
9822 parameter type to 'readable_regcache *'.
9823 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9824 * arm-tdep.c (arm_neon_quad_read): Likewise.
9825 (arm_pseudo_read): Likewise.
9826 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9827 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9828 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9829 * gdbarch.c: Re-generated.
9830 * gdbarch.h: Re-generated.
9831 * gdbarch.sh (pseudo_register_read): Change parameter type to
9832 'readable_regcache *'.
9833 (pseudo_register_read_value): Likewise.
9834 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
9835 (h8300_pseudo_register_read): Likewise.
9836 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
9837 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9838 (i386_pseudo_register_read_into_value): Likewise.
9839 (i386_pseudo_register_read_value): Likewise.
9840 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
9842 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
9843 * m32c-tdep.c (m32c_raw_read): Likewise.
9844 (m32c_read_flg): Likewise.
9845 (m32c_banked_register): Likewise.
9846 (m32c_banked_read): Likewise.
9847 (m32c_sb_read): Likewise.
9848 (m32c_part_read): Likewise.
9849 (m32c_cat_read): Likewise.
9850 (m32c_r3r2r1r0_read): Likewise.
9851 (m32c_pseudo_register_read): Likewise.
9852 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9853 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9854 (mep_pseudo_cr64_read): Likewise.
9855 (mep_pseudo_register_read): Likewise.
9856 * mips-tdep.c (mips_pseudo_register_read): Likewise.
9857 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9858 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9859 * regcache.c (regcache::raw_read): Move it to readable_regcache.
9860 (regcache::cooked_read): Likewise.
9861 (regcache::cooked_read_value): Likewise.
9862 (regcache_cooked_read_signed):
9863 (regcache::cooked_read): Likewise.
9864 * regcache.h (readable_regcache): New class.
9865 (regcache): Inherit readable_regcache. Move some methods to
9867 * rl78-tdep.c (rl78_pseudo_register_read): Change
9868 parameter type to 'readable_regcache *'.
9869 * rs6000-tdep.c (do_regcache_raw_read): Remove.
9870 (e500_pseudo_register_read): Change parameter type to
9871 'readable_regcache *'.
9872 (dfp_pseudo_register_read): Likewise.
9873 (vsx_pseudo_register_read): Likewise.
9874 (efpr_pseudo_register_read): Likewise.
9875 * s390-tdep.c (s390_pseudo_register_read): Likewise.
9876 * sh-tdep.c (sh_pseudo_register_read): Likewise.
9877 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
9878 (sh64_pseudo_register_read): Likewise.
9879 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9880 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9881 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9882 (spu_pseudo_register_read): Likewise.
9883 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9884 (xtensa_pseudo_register_read): Likewise.
9886 2018-02-21 Yao Qi <yao.qi@linaro.org>
9888 * regcache.c (regcache::regcache): Call reg_buffer ctor.
9889 (regcache::arch): Move it to reg_buffer::arch.
9890 (regcache::register_buffer): Likewise.
9891 (regcache::assert_regnum): Likewise.
9892 (regcache::num_raw_registers): Likewise.
9893 * regcache.h (reg_buffer): New class.
9894 (regcache): Inherit reg_buffer.
9896 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
9898 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
9899 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
9901 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
9903 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
9905 2018-02-19 Alan Hayward <alan.hayward@arm.com>
9907 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
9908 (SFILES): Remove common/*.c files.
9909 (COMMON_OBS): Remove some *.o files built from common/*.c files.
9910 * common/common.host: Add common reference.
9911 * configure.ac: Likewise.
9912 * configure: Regenerate.
9914 2018-02-16 Yao Qi <yao.qi@linaro.org>
9916 * block.c (block_namespace_info): Inherit allocate_on_obstack.
9917 (block_initialize_namespace): Use new.
9918 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
9919 (dwarf2_free_objfile): Use delete.
9920 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
9921 (copy_type_recursive): Use new.
9922 * gdb_obstack.h (allocate_on_obstack): New.
9924 2018-02-15 Yao Qi <yao.qi@linaro.org>
9927 * inferior.c (exit_inferior_1): Reset inf->control.
9929 2018-02-15 Joel Brobecker <brobecker@adacore.com>
9931 * ada-lang.c (ada_to_fixed_value_create): Delete advance
9934 2018-02-14 Pedro Alves <palves@redhat.com>
9936 * frame-unwind.c (frame_unwind_try_unwinder): Always call
9937 frame_cleanup_after_sniffer on exception.
9939 2018-02-14 Tom Tromey <tom@tromey.com>
9941 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
9943 (solib_bfd_open): Make pathname const.
9944 * solib.c (solib_bfd_open): Make pathname const.
9945 * solib-spu.c (spu_bfd_fopen): Make name const.
9946 (spu_bfd_open): Make pathname const.
9947 * solib-darwin.c (darwin_bfd_open): Make pathname const.
9948 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
9950 2018-02-14 Tom Tromey <tom@tromey.com>
9952 * symfile.c (symfile_bfd_open): Update.
9953 * source.h (openp, source_full_path_of, find_and_open_source):
9954 Change argument type to unique_xmalloc_ptr.
9955 * source.c (openp): Take a unique_xmalloc_ptr.
9956 (source_full_path_of, find_and_open_source): Likewise.
9957 (open_source_file, symtab_to_fullname): Update.
9958 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
9960 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
9961 (exec_file_find): Update.
9962 * psymtab.c (psymtab_to_fullname): Update.
9963 * nto-tdep.h (nto_find_and_open_solib): Update.
9964 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
9966 * exec.c (exec_file_attach): Update.
9967 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
9968 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
9970 2018-02-14 Tom Tromey <tom@tromey.com>
9972 * solib.c: Include source.h.
9973 * nto-tdep.c: Include source.h.
9974 * mi/mi-cmd-env.c: Include source.h.
9975 * infcmd.c: Include source.h.
9976 * exec.c: Include source.h.
9977 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
9978 (add_path, directory_switch, source_path, init_source_path): Move
9980 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
9981 (add_path, directory_switch, source_path, init_source_path):
9984 2018-02-14 Tom Tromey <tom@tromey.com>
9986 * solist.h (exec_file_find, solib_find): Return
9988 (solib_bfd_fopen): Take a const char *.
9989 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
9990 (exec_file_find, solib_find): Likewise.
9991 (solib_bfd_fopen): Do not take ownership of "pathname".
9992 (solib_bfd_open): Use unique_xmalloc_ptr.
9993 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
9994 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
9995 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
9996 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
9998 2018-02-14 Joel Brobecker <brobecker@adacore.com>
10000 * ada-lang.c (name_match_type_from_name): Remove reference to
10001 ada_name_for_lookup in function's documentation.
10002 * ada-lang.h (ada_name_for_lookup): Delete declaration.
10004 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10006 * defs.h (enum openp_flags): New enum.
10007 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
10008 Move to enum openp_flags.
10009 (openp_flags): New enum flags.
10010 (openp): Change parameter type to openp_flags.
10011 * source.c (openp): Change parameter type to openp_flags.
10012 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
10013 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
10015 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
10017 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
10020 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
10022 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
10024 (class dwarf2_queue_guard): ...the destructor of this new class.
10025 (dw2_do_instantiate_symtab): Create instance of the new class
10026 dwarf2_queue_guard, remove cleanup.
10028 2018-02-09 Tom Tromey <tom@tromey.com>
10030 * source.c (find_source_lines): Don't reference past the end of
10033 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10035 * remote.c (remote_btrace_maybe_reopen): Change error message.
10036 * btrace.c (btrace_enable): Likewise.
10037 (parse_xml_btrace): Likewise.
10038 (parse_xml_btrace_conf): Likewise.
10040 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10042 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
10043 (linux_enable_pt, linux_enable_bts): Call
10044 diagnose_perf_event_open_fail.
10046 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10048 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
10049 Remove parameter and change return type. Update callers. Move it.
10050 (linux_enable_bts, linux_enable_pt): Improve error message.
10051 (linux_enable_pt): Remove zero buffer size check.
10052 (linux_enable_btrace): Improve error messages. Remove NULL return
10055 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10057 * btrace.c (btrace_enable): Remove target_supports_btrace call.
10058 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
10059 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
10060 (linux_supports_pt, linux_supports_btrace): Remove.
10061 (linux_enable_bts): Call cpu_supports_bts.
10062 * nat/linux-btrace.h (linux_supports_btrace): Remove.
10063 * remote.c (remote_supports_btrace): Remove.
10064 (init_remote_ops): Remove remote_supports_btrace.
10065 * target-delegates.c: Regenerated.
10066 * target.c (target_supports_btrace): Remove.
10067 * target.h (target_ops) <to_supports_btrace>: Remove
10068 (target_supports_btrace): Remove.
10069 * x86-linux-nat.c (x86_linux_create_target): Remove
10070 linux_supports_btrace.
10072 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10074 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
10076 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
10077 exception and use message in own exception.
10079 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10081 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
10082 (perf_event_pt_event_type): Use gdb_file_up.
10083 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
10084 scoped_fd, and scoped_mmap.
10086 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10088 * common/scoped_mmap.h: New.
10089 * unittests/scoped_mmap-selftest.c: New.
10090 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10091 unittests/scoped_mmap-selftest.c.
10093 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10095 * common/scoped_fd.h: New.
10096 * unittests/scoped_fd-selftest.c: New.
10097 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10098 unittests/scoped_fd-selftest.c.
10100 2018-02-09 Tom Tromey <tom@tromey.com>
10102 * auto-load.c (auto_load_section_scripts): Use
10103 gdb::unique_xmalloc_ptr.
10105 2018-02-09 Tom Tromey <tom@tromey.com>
10107 * auto-load.c (execute_script_contents): Use std::string.
10109 2018-02-09 Joel Brobecker <brobecker@adacore.com>
10111 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
10112 Python function, rather than a new command.
10114 2018-02-08 Tom Tromey <tom@tromey.com>
10116 * solib.c (solib_find_1): Use std::string.
10117 (solib_bfd_fopen): Use unique_xmalloc_ptr.
10119 2018-02-08 Tom Tromey <tom@tromey.com>
10121 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
10123 2018-02-08 Tom Tromey <tom@tromey.com>
10125 * source.c (find_source_lines): Use gdb::def_vector.
10127 2018-02-08 Tom Tromey <tom@tromey.com>
10129 * macrocmd.c (struct temporary_macro_definition): New.
10130 (macro_define_command): Use temporary_macro_definition. Remove
10132 (free_macro_definition_ptr): Remove.
10134 2018-02-08 Tom Tromey <tom@tromey.com>
10136 * macroexp.c (maybe_expand): Use std::string.
10138 2018-02-08 Tom Tromey <tom@tromey.com>
10140 * macroexp.c (struct macro_buffer): Add initializers for some
10142 (init_buffer, init_shared_buffer, free_buffer)
10143 (free_buffer_return_text): Remove.
10144 (macro_buffer): New constructors.
10145 (~macro_buffer): New destructor.
10146 (macro_buffer::set_shared): New method.
10147 (macro_buffer::resize_buffer, macro_buffer::appendc)
10148 (macro_buffer::appendmem): Now methods, not free functions.
10149 (set_token, append_tokens_without_splicing, stringify)
10150 (macro_stringify): Update.
10151 (gather_arguments): Change return type. Remove argc_p argument,
10152 add args_ptr argument. Use std::vector.
10153 (substitute_args): Remove argc argument. Accept std::vector.
10154 (expand): Update. Use std::vector.
10155 (scan, macro_expand, macro_expand_next): Update.
10157 2018-02-08 Tom Tromey <tom@tromey.com>
10159 * symtab.c (default_collect_symbol_completion_matches_break_on):
10160 Use unique_xmalloc_ptr.
10161 * macroscope.h: (sal_macro_scope, user_macro_scope)
10162 (default_macro_scope): Return unique_xmalloc_ptr.
10163 * macroscope.c (sal_macro_scope, user_macro_scope)
10164 (default_macro_scope): Return unique_xmalloc_ptr.
10165 * macroexp.h (macro_expand, macro_expand_once): Return
10166 unique_xmalloc_ptr.
10167 * macroexp.c (macro_expand, macro_expand_once): Return
10168 unique_xmalloc_ptr.
10169 * macrocmd.c (macro_expand_command, macro_expand_once_command)
10170 (info_macro_command, info_macros_command): Use
10171 unique_xmalloc_ptr.
10172 * compile/compile-c-support.c (write_macro_definitions): Use
10173 unique_xmalloc_ptr.
10174 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
10176 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
10178 * value.c (value_static_field): Assign field type instead of
10179 containing type when returning an optimized out value.
10181 2018-02-06 Yao Qi <yao.qi@linaro.org>
10183 * ft32-tdep.c (ft32_read_pc): Remove.
10184 (ft32_write_pc): Remove.
10185 (ft32_gdbarch_init): Update.
10186 * m32r-tdep.c (m32r_read_pc): Remove.
10187 (m32r_gdbarch_init): Update.
10188 * mep-tdep.c (mep_read_pc): Remove.
10189 (mep_gdbarch_init): Update.
10190 * microblaze-tdep.c (microblaze_write_pc): Remove.
10191 (microblaze_gdbarch_init): Update.
10192 * mn10300-tdep.c (mn10300_read_pc): Remove.
10193 (mn10300_write_pc): Remove.
10194 (mn10300_gdbarch_init): Update.
10195 * moxie-tdep.c (moxie_read_pc): Remove.
10196 (moxie_write_pc): Remove.
10197 (moxie_gdbarch_init): Update.
10199 2018-02-06 Yao Qi <yao.qi@linaro.org>
10201 * expprint.c (print_subexp_standard): Handle
10202 OP_F77_UNDETERMINED_ARGLIST.
10203 (dump_subexp_body_standard): Likewise.
10205 2018-02-05 Alan Hayward <alan.hayward@arm.com>
10207 * target-descriptions.c (tdesc_element_visitor) Add empty
10209 (tdesc_type): Move make_gdb_type from here.
10210 (tdesc_type_builtin): Likewise.
10211 (tdesc_type_vector): Likewise.
10212 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
10213 (make_gdb_type_struct): Move from tdesc_type_with_fields.
10214 (make_gdb_type_union): Likewise.
10215 (make_gdb_type_flags): Likewise.
10216 (make_gdb_type_enum): Likewise.
10217 (make_gdb_type): New function.
10218 (tdesc_register_type): Use static make_gdb_type.
10220 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
10222 * infcmd.c (default_print_one_register_info): Align natural-format
10223 column values consistently one under another.
10224 (pad_to_column): New function.
10226 2018-02-05 Joel Brobecker <brobecker@adacore.com>
10228 * dwarf2read.c (dwarf2_physname): Move commment.
10230 2018-02-01 Leszek Swirski <leszeks@google.com>
10232 * varobj.c (varobj_formatted_print_options): Allow recursive
10233 pretty printing if pretty printing is enabled.
10235 2018-02-01 Leszek Swirski <leszeks@google.com>
10237 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
10238 names after a structop as a filename.
10240 2018-02-01 Yao Qi <yao.qi@linaro.org>
10242 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
10243 (arm_record_coproc_data_proc): Likewise.
10245 2018-02-01 Yao Qi <yao.qi@linaro.org>
10247 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
10249 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
10251 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
10252 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
10254 2018-01-31 Pedro Alves <palves@redhat.com>
10256 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
10257 * inflow.c (child_terminal_save_inferior): Wrap reference to
10258 tcgetpgrp in HAVE_TERMIOS_H.
10259 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
10261 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
10262 always iterate over all inferiors.
10263 (gdbsim_cntrl_c): Adjust.
10264 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
10266 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10268 * gdbtypes.c (lookup_array_range_type): Make sure the array's
10269 index type is objfile-owned if the element type is as well.
10271 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10275 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
10277 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
10278 "features/s390x-linux64.c".
10279 (_initialize_s390_linux_tdep): Remove initialization of tdescs
10280 s390_linux32 and s390x_linux64.
10281 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
10283 * s390-tdep.c: Include "features/s390-linux32.c" and
10284 "features/s390x-linux64.c".
10285 (s390_tdesc_valid): Add check for tdesc_has_registers.
10286 (s390_gdbarch_init): Make sure there is always a valid tdesc.
10287 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
10288 tdesc_s390x_linux64.
10289 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
10290 tdesc_s390x_linux64 to...
10291 * s390-tdep.h: ...here.
10293 2018-01-30 Pedro Alves <palves@redhat.com>
10296 * config.in, configure: Regenerate.
10297 * configure.ac: Check for getpgid.
10298 * go32-nat.c (go32_pass_ctrlc): New.
10299 (go32_target): Install it.
10300 * inf-child.c (inf_child_target): Install
10301 child_terminal_save_inferior, child_pass_ctrlc and
10303 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
10304 (inf_ptrace_target): No longer install it.
10305 * infcmd.c (interrupt_target_1): Adjust.
10306 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
10307 (child_interrupt): Declare.
10308 (inferior::terminal_state): New.
10309 * inflow.c (struct terminal_info): Update comments.
10310 (inferior_process_group): Delete.
10311 (terminal_is_ours): Delete.
10312 (gdb_tty_state): New.
10313 (child_terminal_init): Adjust.
10314 (is_gdb_terminal, sharing_input_terminal_1)
10315 (sharing_input_terminal): New functions.
10316 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
10317 Set the process's actual process group in the foreground if
10318 possible. Handle is_ours_for_output/is_ours distinction. Don't
10319 mark terminal as the inferior's if not sharing GDB's terminal.
10320 Don't check attach_flag.
10321 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
10322 pass down a target_terminal_state.
10323 (child_terminal_save_inferior): New, factored out from ...
10324 (child_terminal_ours_1): ... this. Handle
10325 target_terminal_state::is_ours_for_output.
10326 (child_interrupt, child_pass_ctrlc): New.
10327 (inflow_inferior_exit): Clear the inferior's terminal_state.
10328 (copy_terminal_info): Copy the inferior's terminal state.
10329 (_initialize_inflow): Remove reference to terminal_is_ours.
10330 * inflow.h (inferior_process_group): Delete.
10331 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
10332 * procfs.c (procfs_target): Don't install procfs_interrupt.
10333 (procfs_interrupt): Delete.
10334 * remote.c (remote_serial_quit_handler): Adjust.
10335 (remote_interrupt): Remove ptid parameter. Adjust.
10336 * target-delegates.c: Regenerate.
10337 * target.c: Include "terminal.h".
10338 (target_terminal::terminal_state): Rename to ...
10339 (target_terminal::m_terminal_state): ... this.
10340 (target_terminal::init): Adjust.
10341 (target_terminal::inferior): Adjust to per-inferior
10343 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
10344 (target_terminal::ours, target_terminal::ours_for_output): Use
10345 target_terminal_is_ours_kind.
10346 (target_interrupt): Remove ptid parameter. Adjust.
10347 (default_target_pass_ctrlc): Adjust.
10348 * target.h (target_ops::to_terminal_save_inferior): New field.
10349 (target_ops::to_interrupt): Remove ptid_t parameter.
10350 (target_interrupt): Remove ptid_t parameter. Update comment.
10351 (target_pass_ctrlc): Update comment.
10352 * target/target.h (target_terminal_state): New scoped enum,
10353 factored out of ...
10354 (target_terminal::terminal_state): ... here.
10355 (target_terminal::inferior): Update comments.
10356 (target_terminal::restore_inferior): New.
10357 (target_terminal::is_inferior, target_terminal::is_ours)
10358 (target_terminal::is_ours_for_output): Adjust.
10359 (target_terminal::scoped_restore_terminal_state): Adjust to
10360 rename, and call restore_inferior() instead of inferior().
10361 (target_terminal::scoped_restore_terminal_state::m_state): Change
10363 (target_terminal::terminal_state): Rename to ...
10364 (target_terminal::m_terminal_state): ... this and change type.
10366 2018-01-30 Pedro Alves <palves@redhat.com>
10368 * linux-nat.c (wait_for_signal): New function.
10369 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
10371 (async_terminal_is_ours)
10372 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
10373 (linux_nat_add_target): Don't override
10374 to_terminal_inferior/to_terminal_ours.
10376 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
10378 * remote.c (remote_follow_fork): Don't call "detach_inferior".
10380 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
10382 * dwarf2read.c (free_dwo_files): Add forward-declaration.
10383 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
10384 dwarf2_per_objfile_free here.
10385 (dwarf2_per_objfile_free): Remove.
10386 (_initialize_dwarf2_read): Don't register
10387 dwarf2_per_objfile_free as a registry cleanup.
10389 2018-01-27 Eli Zaretskii <eliz@gnu.org>
10391 Avoid compilation errors in MinGW native builds
10393 The error is triggered by including python-internal.h, and the
10396 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
10397 from build-gnulib/import/math.h:27,
10398 from d:/usr/Python26/include/pyport.h:235,
10399 from d:/usr/Python26/include/Python.h:58,
10400 from python/python-internal.h:94,
10401 from python/py-arch.c:24:
10402 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
10406 This happens because Python headers define 'hypot' to expand t
10407 '_hypot' in the Windows builds.
10408 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
10409 'hypoth'. This avoids a compilation error.
10411 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10413 * MAINTAINERS (Write After Approval): Fix ordering.
10415 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10417 * MAINTAINERS (Write After Approval): Add Alan Hayward.
10419 2018-01-26 Alan Modra <amodra@gmail.com>
10421 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
10422 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
10423 Remove nop. Make const. Comment.
10424 (powerpc32_plt_stub_so_2): New.
10425 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
10426 Correct count. Update uses.
10427 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
10428 Move common code reading PLT entry word. Correct
10429 powerpc32_plt_stub PLT address calculation.
10430 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
10431 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
10432 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
10433 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
10434 (ppc64_standard_linkage8): Likewise.
10435 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
10436 Correct insns description.
10437 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
10439 2018-01-24 Pedro Alves <palves@redhat.com>
10441 GCC PR libstdc++/83906
10442 * gdbtypes.c (operator==(const dynamic_prop &,
10443 const dynamic_prop &)): New.
10444 (operator==(const range_bounds &, const range_bounds &)): New.
10445 (check_types_equal): Use them instead of memcmp.
10446 * gdbtypes.h (operator==(const dynamic_prop &,
10447 const dynamic_prop &)): Declare.
10448 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
10449 (operator==(const range_bounds &, const range_bounds &)): Declare.
10450 (operator!=(const range_bounds &, const range_bounds &)): Declare.
10452 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10454 * s390-linux-tdep.c (s390_record_address_mask)
10455 (s390_record_calc_disp_common, s390_record_calc_disp)
10456 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10457 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10458 (s390_process_record): Move to s390-tdep.c.
10459 (s390_linux_init_abi_any): Adjust.
10460 * s390-tdep.c (s390_record_address_mask)
10461 (s390_record_calc_disp_common, s390_record_calc_disp)
10462 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10463 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10464 (s390_process_record): Moved from s390-linux-tdep.c
10465 (s390_gdbarch_init): Adjust.
10467 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10469 * s390-linux-nat.c (s390-tdep.h): New include.
10470 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
10471 (HFILES_NO_SRCDIR): Add s390-tdep.h.
10472 (ALLDEPFILES): Add s390-tdep.c.
10473 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
10474 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
10475 * s390-tdep.h: ...this. New file.
10476 * s390-linux-tdep.c (s390-tdep.h): New include.
10477 (_initialize_s390_tdep): Rename to...
10478 (_initialize_s390_linux_tdep): ...this and adjust.
10479 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
10480 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
10482 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
10483 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
10484 (s390_is_partial_instruction, s390_software_single_step)
10485 (is_non_branch_ril, s390_displaced_step_copy_insn)
10486 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
10487 (s390_prologue_data, s390_addr, s390_store, s390_load)
10488 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
10489 (s390_register_call_saved, s390_guess_tracepoint_registers)
10490 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
10491 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
10492 (s390_pseudo_register_name, s390_pseudo_register_type)
10493 (s390_pseudo_register_read, s390_pseudo_register_write)
10494 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
10495 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
10496 (s390_addr_bits_remove, s390_address_class_type_flags)
10497 (s390_address_class_type_flags_to_name)
10498 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
10499 (s390_function_arg_float, s390_function_arg_vector)
10500 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
10501 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
10502 (s390_frame_align, s390_register_return_value, s390_return_value)
10503 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
10504 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
10505 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
10506 (s390_trad_frame_prev_register, s390_unwind_cache)
10507 (s390_prologue_frame_unwind_cache)
10508 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
10509 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
10510 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
10511 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
10512 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
10513 (s390_frame_base_address, s390_local_base_address)
10514 (s390_frame_base, s390_gcc_target_options)
10515 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
10516 (s390_validate_reg_range, s390_tdesc_valid)
10517 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
10518 * s390-tdep.c: ...this. New file.
10520 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10522 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
10523 (s390_process_record, s390_gdbarch_tdep_alloc)
10524 (s390_linux_init_abi_any): Use/set new hook.
10526 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10528 * s390-linux-tdep.c (osabi.h): New include.
10529 (s390_linux_init_abi_31, s390_linux_init_abi_64)
10530 (s390_linux_init_abi_any): New functions.
10531 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
10533 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10535 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
10536 tdesc_has_registers check
10538 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10540 * s390-linux-tdep.c (s390_tdesc_valid): New function.
10541 (s390_validate_reg_range): New macro.
10542 (s390_gdbarch_init): Adjust.
10544 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10546 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
10547 (s390_gdbarch_tdep_alloc): Adjust.
10548 (s390_gdbarch_init): Adjust.
10550 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10552 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
10553 <have_tdb>: Change type to bool.
10554 (s390_gdbarch_tdep_alloc): Adjust.
10555 (s390_gdbarch_init): Adjust.
10557 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10559 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
10560 (gdbarch_tdep) <have_upper, have_vx>: New fields.
10561 (s390_gdbarch_tdep_alloc): New function.
10562 (s390_gdbarch_init): Allocate tdep at start and use its fields
10563 instead of separate variables.
10565 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10567 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
10568 when looking for cached gdbarch and add comment for remaining.
10570 2018-01-22 Pedro Alves <palves@redhat.com>
10571 Sergio Durigan Junior <sergiodj@redhat.com>
10573 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
10576 2018-01-22 Maciej W. Rozycki <macro@mips.com>
10578 * MAINTAINERS: Update my company e-mail address.
10580 2018-01-22 Yao Qi <yao.qi@linaro.org>
10582 * regcache.c (cooked_write_test): New function.
10583 (_initialize_regcache): Register the test.
10585 2018-01-22 Yao Qi <yao.qi@linaro.org>
10587 * ia64-tdep.c (ia64_pseudo_register_read): Call
10588 regcache->cooked_read instead of regcache_cooked_read_unsigned.
10589 * m32c-tdep.c (m32c_cat_read): Likewise.
10590 (m32c_r3r2r1r0_read): Likewise.
10591 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10592 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10594 2018-01-22 Yao Qi <yao.qi@linaro.org>
10596 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
10597 method raw_read instead of regcache_raw_read.
10598 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10599 * arm-tdep.c (arm_neon_quad_read): Likewise.
10600 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10601 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10602 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10603 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
10604 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10605 (i386_pseudo_register_read_into_value): Likewise.
10606 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10607 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10608 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10609 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
10610 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
10611 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10612 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10613 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10614 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
10616 2018-01-22 Yao Qi <yao.qi@linaro.org>
10618 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
10619 * configure.tgt: Remove target mt.
10620 * mt-tdep.c: Remove.
10621 * regcache.c (cooked_read_test): Remove the check for mt.
10623 2018-01-22 Yao Qi <yao.qi@linaro.org>
10625 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10626 instead of gdbarch_pseudo_register_read_value.
10628 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10630 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10633 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10635 * linespec.c (create_sals_line_offset): Remove code that preserved
10636 the symtab_and_line's line number.
10638 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10640 * varobj.c (varobj_create): Don't set valid_block when creating a
10643 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10645 * varobj.c (varobj_create): Remove out of date comment.
10647 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10650 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10651 updating innermost block.
10652 * parse.c (innermost_block_tracker::update): Take extra type
10653 parameter, and check types match before updating innermost block.
10654 (write_dollar_variable): Update innermost block for registers.
10655 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10656 (innermost_block_tracker::innermost_block_tracker): Initialise
10658 (innermost_block_tracker::reset): Take type parameter.
10659 (innermost_block_tracker::update): Take type parameter, and pass
10660 type through as needed.
10661 (innermost_block_tracker::m_types): New member.
10662 * varobj.c (varobj_create): Pass type when reseting innermost
10665 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10667 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10668 * ada-lang.c (resolve_subexp): Likewise.
10669 * breakpoint.c (set_breakpoint_condition) Likewise.
10670 (watch_command_1) Likewise.
10671 * c-exp.y (variable): Likewise.
10672 * d-exp.y (PrimaryExpression): Likewise.
10673 * f-exp.y (variable): Likewise.
10674 * go-exp.y (variable): Likewise.
10675 * m2-exp.y (variable): Likewise.
10676 * objfiles.c (objfile::~objfile): Likewise.
10677 * p-exp.y (variable): Likewise.
10678 * parse.c (innermost_block): Change type.
10679 * parser-defs.h (class innermost_block_tracker): New.
10680 (innermost_block): Change to innermost_block_tracker.
10681 * printcmd.c (display_command): Switch to innermost_block API.
10682 (do_one_display): Likewise.
10683 * rust-exp.y (do_one_display): Likewise.
10684 * symfile.c (clear_symtab_users): Likewise.
10685 * varobj.c (varobj_create): Switch to innermost_block API, replace
10686 use of innermost_block with block stored on varobj object.
10688 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10690 * expression.h (innermost_block): Remove declaration.
10691 * varobj.c: Add 'parser-defs.h' include.
10693 2018-01-19 Tom Tromey <tom@tromey.com>
10695 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
10696 symbols in the static and global blocks.
10698 2018-01-19 James Clarke <jrtc27@jrtc27.com>
10700 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
10701 gdb_ptrace.h, and move including gdb_wait.h ...
10702 * nat/linux-ptrace.h: ... to here.
10704 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10706 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
10707 inf_ptrace_detach_success.
10708 (inf_ptrace_detach_success): Add inferior parameter, use it
10709 instead of inferior_ptid, pass it to detach_inferior.
10710 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
10712 * inferior.c (detach_inferior): Add overload that takes an
10714 * inferior.h (detach_inferior): Likewise.
10715 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
10716 use inferior_ptid, adjust call to inf_ptrace_detach_success.
10717 * linux-thread-db.c (thread_db_detach): Use inf parameter.
10719 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10721 * target.h (struct target_ops) <to_detach>: Add inferior
10723 (target_detach): Likewise.
10724 * target.c (dispose_inferior): Pass inferior down.
10725 (target_detach): Pass inferior down. Assert that it is equal to
10726 the current inferior.
10727 * aix-thread.c (aix_thread_detach): Pass inferior down.
10728 * corefile.c (core_file_command): Pass current_inferior() down.
10729 * corelow.c (core_detach): Add inferior parameter.
10730 * darwin-nat.c (darwin_detach): Likewise.
10731 * gnu-nat.c (gnu_detach): Likewise.
10732 * inf-ptrace.c (inf_ptrace_detach): Likewise.
10733 * infcmd.c (detach_command): Pass current_inferior() down to
10735 * infrun.c (follow_fork_inferior): Pass parent_inf to
10737 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
10739 * linux-nat.c (linux_nat_detach): Add inferior parameter.
10740 * linux-thread-db.c (thread_db_detach): Likewise.
10741 * nto-procfs.c (procfs_detach): Likewise.
10742 * procfs.c (procfs_detach): Likewise.
10743 * record.c (record_detach): Likewise.
10744 * record.h (struct inferior): Forward-declare.
10745 (record_detach): Add inferior parameter.
10746 * remote-sim.c (gdbsim_detach): Likewise.
10747 * remote.c (remote_detach_1): Likewise.
10748 (remote_detach): Likewise.
10749 (extended_remote_detach): Likewise.
10750 * sol-thread.c (sol_thread_detach): Likewise.
10751 * target-debug.h (target_debug_print_inferior_p): New macro.
10752 * target-delegates.c: Re-generate.
10753 * top.c (kill_or_detach): Pass inferior down to target_detach.
10754 * windows-nat.c (windows_detach): Add inferior parameter.
10756 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10758 * target.h (struct target_ops) <to_detach>: Remove args
10760 (target_detach): Likewise.
10761 * target.c (dispose_inferior): Adjust.
10762 (target_detach): Remove args parameter, adjust.
10763 * aix-thread.c (aix_thread_detach): Adjust.
10764 * corefile.c (core_file_command): Adjust.
10765 * corelow.c (core_detach): Adjust.
10766 * darwin-nat.c (darwin_detach): Adjust.
10767 * gnu-nat.c (gnu_detach): Adjust.
10768 * inf-ptrace.c (inf_ptrace_detach): Adjust.
10769 * infcmd.c (detach_command): Adjust
10770 * infrun.c (follow_fork_inferior): Adjust.
10771 (handle_vfork_child_exec_or_exit): Adjust.
10772 * linux-fork.c (linux_fork_detach): Remove args parameter.
10773 * linux-fork.h (linux_fork_detach): Likewise.
10774 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
10775 * linux-thread-db.c (thread_db_detach): Likewise.
10776 * nto-procfs.c (procfs_detach): Likewise.
10777 * procfs.c (procfs_detach): Likewise.
10778 (do_detach): Remove signo parameter.
10779 * record.c (record_detach): Remove args parameter.
10780 * record.h (record_detach): Likewise.
10781 * remote-sim.c (gdbsim_detach): Likewise.
10782 * remote.c (remote_detach_1): Likewise.
10783 (remote_detach): Likewise.
10784 (extended_remote_detach): Likewise.
10785 * sol-thread.c (sol_thread_detach): Likewise.
10786 * target-delegates.c: Re-generate.
10787 * top.c (struct qt_args) <args>: Remove field.
10788 (kill_or_detach): Don't pass args.
10789 (quit_force): Don't set args.
10790 * windows-nat.c (windows_detach): Remove args parameter.
10792 2018-01-19 Yao Qi <yao.qi@linaro.org>
10794 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
10795 (arm_linux_init_abi): Install it.
10797 2018-01-19 Yao Qi <yao.qi@linaro.org>
10799 * osabi.c (gdb_osabi_names): Extend the regexp for
10800 arm-linux-gnueabihf.
10802 2018-01-18 Yao Qi <yao.qi@linaro.org>
10804 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
10806 (abbrev_table::add_abbrev): Update.
10807 (abbrev_table::lookup_abbrev): Update.
10809 2018-01-18 Yao Qi <yao.qi@linaro.org>
10811 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
10813 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
10815 * compile/compile.c (compile_to_object): Convert "triplet_rx"
10818 2018-01-17 Tom Tromey <tom@tromey.com>
10820 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
10822 2018-01-17 Tom Tromey <tom@tromey.com>
10824 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
10825 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
10826 (create_array_type_with_stride): Update.
10827 * dwarf2read.c (set_die_type): Update.
10829 2018-01-17 Tom Tromey <tom@tromey.com>
10831 * dwarf2read.c (delayed_method_info): Remove typedef.
10832 (dwarf2_cu::method_info): Now a std::vector.
10833 (add_to_method_list): Update.
10834 (free_delayed_list): Remove.
10835 (compute_delayed_physnames): Update.
10836 (process_full_comp_unit, process_full_type_unit): Clear the method
10837 list. Remove cleanups.
10838 (psymtab_include_file_name): Add name_holder parameter. Use
10839 unique_xmalloc_ptr.
10840 (dwarf_decode_lines): Update.
10842 2018-01-17 Tom Tromey <tom@tromey.com>
10843 Simon Marchi <simon.marchi@ericsson.com>
10845 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
10846 (dwarf2_per_objfile::free_cached_comp_units)
10847 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10848 (init_cutu_and_read_dies_no_follow): Update.
10849 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
10850 (dwarf2_cu::~dwarf2_cu): New.
10851 (free_heap_comp_unit, free_stack_comp_unit): Remove.
10852 (age_cached_comp_units, free_one_cached_comp_unit): Update.
10854 2018-01-17 Tom Tromey <tom@tromey.com>
10855 Simon Marchi <simon.marchi@ericsson.com>
10857 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
10858 (struct die_reader_specs) <abbrev_table>: New member.
10859 (struct abbrev_table): Add constructor.
10860 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
10861 <abbrev_obstack>: Now an auto_obstack.
10862 (abbrev_table_up): New typedef.
10863 (init_cu_die_reader): Add abbrev_table parameter.
10864 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
10865 Add result_dwo_abbrev_table.
10866 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10867 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
10869 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
10871 (skip_children): Update.
10872 (abbrev_table::alloc_abbrev): Rename from
10873 abbrev_table_alloc_abbrev.
10874 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
10875 (abbrev_table::lookup_abbrev): Rename from
10876 abbrev_table_lookup_abbrev.
10877 (abbrev_table_read_table): Return abbrev_table_up.
10878 (abbrev_table_free, abbrev_table_free_cleanup)
10879 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
10880 (load_partial_dies): Update.
10882 2018-01-17 Tom Tromey <tom@tromey.com>
10884 * dwarf2read.c (dwarf2_compute_name): Update comment.
10885 (read_func_scope, read_variable): Update.
10886 (new_symbol): Remove.
10887 (new_symbol_full): Rename to new_symbol.
10889 2018-01-17 Mike Gulick <mgulick@mathworks.com>
10892 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
10893 a warning instead of throwing an error, set section size to 0 and return
10895 * gdb_bfd.h (gdb_bfd_map_section): Update description.
10897 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10899 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
10901 (linux_ptrace_attach_fail_reason_string): Likewise.
10902 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
10904 (linux_ptrace_attach_fail_reason_string): Likewise.
10905 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
10907 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10909 * linux-nat.c (linux_nat_attach): Remove xstrdup.
10911 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
10914 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
10915 checking for fs_base/gs_base fields in struct user_regs_struct.
10916 * configure: Regenerate.
10918 2018-01-17 Yao Qi <yao.qi@linaro.org>
10920 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
10922 (aarch64_linux_init_abi): Install it to gdbarch hook
10923 gcc_target_options.
10925 2018-01-15 Pedro Alves <palves@redhat.com>
10927 * common/signals-state-save-restore.c
10928 (save_original_signals_state): Fix typos.
10930 2017-01-12 Tom Tromey <tom@tromey.com>
10931 Sergio Durigan Junior <sergiodj@redhat.com>
10933 * Makefile.in (install-only): Install gdb-add-index.
10935 2018-01-12 John Baldwin <jhb@FreeBSD.org>
10937 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
10939 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10941 * infrun.c (keep_going_pass_signal): Clear step-over info when
10942 insert_breakpoints fails.
10944 2018-01-11 Pedro Alves <palves@redhat.com>
10947 * infrun.c (resume): Rename to ...
10948 (resume_1): ... this.
10949 (resume): Reimplement as wrapper around resume_1.
10951 2018-01-11 Pedro Alves <palves@redhat.com>
10954 * remote.c (remote_parse_stop_reply): Default to the last-set
10955 general thread instead of to 'magic_null_ptid'.
10957 2018-01-10 Pedro Alves <palves@redhat.com>
10959 * language.h (language_get_symbol_name_matcher): Rename ...
10960 (get_symbol_name_matcher): ... this.
10961 * language.c (language_get_symbol_name_matcher): Ditto.
10962 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
10965 2018-01-10 Pedro Alves <palves@redhat.com>
10969 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
10970 Adjust to use language_get_symbol_name_matcher instead of
10971 language_defn::la_get_symbol_name_matcher.
10972 * language.c (language_get_symbol_name_matcher): If in Ada mode
10973 and the lookup name is a verbatim match, return Ada's matcher.
10974 * language.h (language_get_symbol_name_matcher): Adjust comment.
10975 (ada_lookup_name_info::verbatim_p):: New method.
10977 2018-01-10 Pedro Alves <palves@redhat.com>
10980 * ada-lang.c (ada_collect_symbol_completion_matches): If the
10981 minsym's language is language_auto or language_cplus, pass down
10982 language_ada instead.
10983 * symtab.c (compare_symbol_name): Don't frob symbol language here.
10985 2018-01-10 Pedro Alves <palves@redhat.com>
10988 * minsyms.c (linkage_name_str): New function.
10989 (iterate_over_minimal_symbols): Use it.
10991 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10993 * NEWS: Document that 'info proc' now works on FreeBSD.
10995 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10997 * configure.ac: Check for kinfo_getfile in libutil.
10998 * configure: Regenerate.
10999 * config.in: Regenerate.
11000 * fbsd-nat.c: Include "fbsd-tdep.h".
11001 (fbsd_fetch_cmdline): New.
11002 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
11003 rather than calling error.
11004 (fbsd_info_proc): New.
11005 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
11006 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
11007 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
11009 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11011 * fbsd-nat.c (struct free_deleter): Remove.
11012 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
11014 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11016 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
11017 NULL for an empty pathname.
11019 2018-01-09 John Baldwin <jhb@FreeBSD.org>
11021 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
11022 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
11023 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
11024 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
11025 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
11026 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
11027 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
11028 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
11029 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
11030 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
11031 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
11032 (fbsd_core_fetch_timeval, fbsd_print_sigset)
11033 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
11034 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
11035 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
11037 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
11039 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
11040 (gnu_xfer_auxv): New function.
11041 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
11042 TARGET_OBJECT_AUXV.
11044 2018-01-08 Yao Qi <yao.qi@linaro.org>
11045 Simon Marchi <simon.marchi@ericsson.com>
11047 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
11049 (COMMON_OBS): Remove selftest.o.
11050 * configure.ac: Append selftest-arch.c and common/selftest.c to
11051 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
11052 * configure: Re-generated.
11053 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
11055 (maintenance_info_selftests): Likewise.
11057 2018-01-08 Xavier Roirand <roirand@adacore.com>
11059 * ada-valprint.c (val_print_packed_array_elements): Use
11060 proper number of elements when printing an array indexed
11061 by an enumeration type.
11063 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11065 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
11066 (dw2_get_file_names_reader): Adjust.
11067 (lookup_dwo_signatured_type): Adjust.
11068 (lookup_dwp_signatured_type): Adjust.
11069 (lookup_signatured_type): Adjust.
11070 (create_type_unit_group): Adjust.
11071 (get_type_unit_group): Adjust.
11072 (process_psymtab_comp_unit_reader): Adjust.
11073 (build_type_psymtabs_reader): Adjust.
11074 (scan_partial_symbols): Adjust.
11075 (add_partial_symbol): Adjust.
11076 (add_partial_subprogram): Adjust.
11077 (peek_die_abbrev): Adjust.
11078 (fixup_go_packaging): Adjust.
11079 (process_imported_unit_die): Adjust.
11080 (dwarf2_compute_name): Adjust.
11081 (dwarf2_physname): Adjust.
11082 (read_import_statement): Adjust.
11083 (handle_DW_AT_stmt_list): Adjust.
11084 (read_file_scope): Adjust.
11085 (read_func_scope): Adjust.
11086 (read_lexical_block_scope): Adjust.
11087 (read_call_site_scope): Adjust.
11088 (read_variable): Adjust.
11089 (dwarf2_rnglists_process): Adjust.
11090 (dwarf2_ranges_process): Adjust.
11091 (dwarf2_ranges_read): Adjust.
11092 (dwarf2_get_pc_bounds): Adjust.
11093 (dwarf2_record_block_ranges): Adjust.
11094 (dwarf2_add_field): Adjust.
11095 (dwarf2_add_member_fn): Adjust.
11096 (read_structure_type): Adjust.
11097 (process_structure_scope): Adjust.
11098 (read_enumeration_type): Adjust.
11099 (read_array_type): Adjust.
11100 (mark_common_block_symbol_computed): Adjust.
11101 (read_common_block): Adjust.
11102 (read_namespace_type): Adjust.
11103 (read_namespace): Adjust.
11104 (read_module_type): Adjust.
11105 (read_tag_pointer_type): Adjust.
11106 (read_tag_ptr_to_member_type): Adjust.
11107 (read_tag_string_type): Adjust.
11108 (read_subroutine_type): Adjust.
11109 (read_typedef): Adjust.
11110 (read_base_type): Adjust.
11111 (attr_to_dynamic_prop): Adjust.
11112 (read_subrange_type): Adjust.
11113 (read_unspecified_type): Adjust.
11114 (dwarf2_read_abbrevs): Adjust.
11115 (load_partial_dies): Adjust.
11116 (read_partial_die): Adjust.
11117 (find_partial_die): Adjust.
11118 (guess_partial_die_structure_name): Adjust.
11119 (fixup_partial_die): Adjust.
11120 (read_attribute_value): Adjust.
11121 (read_addr_index): Adjust.
11122 (read_addr_index_from_leb128): Adjust.
11123 (read_str_index): Adjust.
11124 (dwarf2_string_attr): Adjust.
11125 (get_debug_line_section): Adjust.
11126 (dwarf_decode_line_header): Adjust.
11127 (lnp_state_machine::check_line_address): Adjust.
11128 (dwarf_decode_lines_1): Adjust.
11129 (dwarf_decode_lines): Adjust.
11130 (dwarf2_start_symtab): Adjust.
11131 (var_decode_location): Adjust.
11132 (new_symbol_full): Adjust.
11133 (dwarf2_const_value_data): Adjust.
11134 (dwarf2_const_value_attr): Adjust.
11135 (dwarf2_const_value): Adjust.
11136 (die_type): Adjust.
11137 (die_containing_type): Adjust.
11138 (build_error_marker_type): Adjust.
11139 (lookup_die_type): Adjust.
11140 (guess_full_die_structure_name): Adjust.
11141 (anonymous_struct_prefix): Adjust.
11142 (determine_prefix): Adjust.
11143 (dwarf2_name): Adjust.
11144 (follow_die_ref_or_sig): Adjust.
11145 (follow_die_offset): Adjust.
11146 (follow_die_ref): Adjust.
11147 (follow_die_sig_1): Adjust.
11148 (follow_die_sig): Adjust.
11149 (get_signatured_type): Adjust.
11150 (get_DW_AT_signature_type): Adjust.
11151 (decode_locdesc): Adjust.
11152 (dwarf_decode_macros): Adjust.
11153 (cu_debug_loc_section): Adjust.
11154 (fill_in_loclist_baton): Adjust.
11155 (dwarf2_symbol_mark_computed): Adjust.
11156 (init_one_comp_unit): Don't assign
11157 dwarf2_cu::dwarf2_per_objfile.
11158 (set_die_type): Adjust.
11160 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11162 * dwarf2read.c (struct mapped_debug_names): Add constructor.
11163 <dwarf2_per_objfile>: New field.
11164 (dwarf2_per_objfile): Remove global.
11165 (get_dwarf2_per_objfile): New function.
11166 (set_dwarf2_per_objfile): New function.
11167 (dwarf2_build_psymtabs_hard): Change objfile parameter to
11168 dwarf2_per_objfile.
11169 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11170 (read_abbrev_offset): Likewise.
11171 (read_indirect_string): Likewise.
11172 (read_indirect_line_string): Likewise.
11173 (read_indirect_string_at_offset): Likewise.
11174 (read_indirect_string_from_dwz): Likewise.
11175 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11176 dwarf2_per_objfile.
11177 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11178 (create_all_comp_units): Change objfile parameter to
11179 dwarf2_per_objfile.
11180 (create_all_type_units): Likewise.
11181 (process_queue): Add dwarf2_per_objfile parameter.
11182 (read_and_check_comp_unit_head): Likewise.
11183 (lookup_dwo_unit_in_dwp): Likewise.
11184 (get_dwp_file): Likewise.
11185 (process_cu_includes): Likewise.
11186 (struct free_dwo_file_cleanup_data): New struct.
11187 (dwarf2_has_info): Use get_dwarf2_per_objfile and
11188 set_dwarf2_per_objfile.
11189 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
11190 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
11191 context, adjust calls.
11192 (dw2_instantiate_symtab): Likewise.
11193 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
11194 (dw2_get_cu): Likewise.
11195 (create_cu_from_index_list): Change objfile parameter to
11196 dwarf2_per_objfile.
11197 (create_cus_from_index_list): Get dwarf2_per_objfile from
11198 context, adjust calls.
11199 (create_cus_from_index): Likewise.
11200 (create_signatured_type_table_from_index): Change objfile
11201 parameter to dwarf2_per_objfile.
11202 (create_signatured_type_table_from_debug_names): Change objfile
11203 parameter to dwarf2_per_objfile.
11204 (create_addrmap_from_index): Likewise.
11205 (create_addrmap_from_aranges): Likewise.
11206 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
11207 (dw2_setup): Remove.
11208 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
11210 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
11211 get_dwarf2_per_objfile.
11212 (dw2_forget_cached_source_info): Likewise.
11213 (dw2_map_symtabs_matching_filename): Likewise.
11214 (struct dw2_symtab_iterator) <index>: Remove.
11215 <dwarf2_per_objfile>: New field.
11216 (dw2_symtab_iter_init): Replace index parameter with
11217 dwarf2_per_objfile.
11218 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
11219 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
11220 (dw2_print_stats): Likewise.
11221 (dw2_dump): Likewise.
11222 (dw2_expand_symtabs_for_function): Likewise.
11223 (dw2_expand_all_symtabs): Likewise.
11224 (dw2_expand_symtabs_with_fullname): Likewise.
11225 (dw2_expand_marked_cus): Replace index and objfile parameters
11226 with dwarf2_per_objfile.
11227 (dw_expand_symtabs_matching_file_matcher): Add
11228 dwarf2_per_objfile parameter and adjust calls.
11229 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
11231 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
11232 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
11234 (create_cus_from_debug_names_list): Replace objfile parameter
11235 with dwarf2_per_objfile and adjust calls.
11236 (create_cus_from_debug_names): Likewise.
11237 (dwarf2_read_debug_names): Likewise.
11238 (mapped_debug_names::namei_to_name): Adjust call.
11239 (dw2_debug_names_iterator::next): Likewise.
11240 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
11241 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
11242 (dw2_debug_names_dump): Likewise.
11243 (dw2_debug_names_expand_symtabs_for_function): Likewise.
11244 (dw2_debug_names_expand_symtabs_matching): Likewise.
11245 (dwarf2_initialize_objfile): Likewise.
11246 (dwarf2_build_psymtabs): Likewise.
11247 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
11249 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
11250 (read_and_check_comp_unit_head): Likewise.
11251 (read_abbrev_offset): Likewise.
11252 (create_debug_type_hash_table): Likewise.
11253 (create_debug_types_hash_table): Likewise.
11254 (create_all_type_units): Replace objfile parameter with
11255 dwarf2_per_objfile.
11256 (add_type_unit): Add dwarf2_per_objfile parameter.
11257 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
11258 with dwarf2_per_objfile.
11259 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
11260 (lookup_dwp_signatured_type): Likewise.
11261 (lookup_signatured_type): Likewise.
11262 (read_cutu_die_from_dwo): Likewise.
11263 (init_tu_and_read_dwo_dies): Likewise.
11264 (init_cutu_and_read_dies): Likewise.
11265 (init_cutu_and_read_dies_no_follow): Likewise.
11266 (allocate_type_unit_groups_table): Add objfile parameter.
11267 (create_type_unit_group): Use dwarf2_per_objfile from cu.
11268 (get_type_unit_group): Likewise.
11269 (process_psymtab_comp_unit): Update call.
11270 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
11271 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
11272 (print_tu_stats): Likewise.
11273 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
11274 in void* parameter.
11275 (build_type_psymtabs): Change objfile parameter to
11276 dwarf2_per_objfile.
11277 (process_skeletonless_type_unit): Use dwarf2_per_objfile
11278 passed in void* parameter.
11279 (process_skeletonless_type_units): Change objfile parameter to
11280 dwarf2_per_objfile.
11281 (set_partial_user): Likewise.
11282 (dwarf2_build_psymtabs_hard): Likewise.
11283 (read_comp_units_from_section): Likewise.
11284 (create_all_comp_units): Likewise.
11285 (scan_partial_symbols): Update calls.
11286 (add_partial_symbol): Likewise.
11287 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
11288 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
11289 (process_queue): Add dwarf2_per_objfile parameter.
11290 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
11291 (compute_compunit_symtab_includes): Likewise.
11292 (process_cu_includes): Add dwarf2_per_objfile parameter.
11293 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
11294 (process_full_type_unit): Likewise.
11295 (process_imported_unit_die): Update call.
11296 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
11297 (read_file_scope): Likewise.
11298 (allocate_dwo_file_hash_table): Add objfile parameter.
11299 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
11300 (create_cus_hash_table): Likewise.
11301 (create_dwp_hash_table): Likewise.
11302 (create_dwo_unit_in_dwp_v1): Likewise.
11303 (create_dwp_v2_section): Likewise.
11304 (create_dwo_unit_in_dwp_v2): Likewise.
11305 (lookup_dwo_unit_in_dwp): Likewise.
11306 (try_open_dwop_file): Likewise.
11307 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
11308 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
11309 cleanup to include a reference to dwarf2_per_objfile.
11310 (open_dwp_file): Add dwarf2_per_objfile parameter.
11311 (open_and_init_dwp_file): Likewise.
11312 (get_dwp_file): Likewise.
11313 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
11314 (queue_and_load_all_dwo_tus): Update call.
11315 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
11317 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
11318 (dwarf2_ranges_process): Likewise.
11319 (dwarf2_get_pc_bounds): Likewise.
11320 (mark_common_block_symbol_computed): Likewise.
11321 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11322 (dwarf2_read_abbrevs): Update call.
11323 (read_partial_die): Use dwarf2_per_objfile from cu.
11324 (find_partial_die): Likewise.
11325 (fixup_partial_die): Likewise.
11326 (read_attribute_value): Likewise.
11327 (read_indirect_string_at_offset_from): Add objfile parameter.
11328 (read_indirect_string_at_offset): Add dwarf2_per_objfile
11330 (read_indirect_string_from_dwz): Add objfile parameter.
11331 (read_indirect_string): Add objfile parameter.
11332 (read_addr_index_1): Add dwarf2_per_objfile parameter.
11333 (read_addr_index): Use dwarf2_per_objfile from cu.
11334 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
11336 (read_str_index): Use dwarf2_per_objfile from cu.
11337 (get_debug_line_section): Likewise.
11338 (read_formatted_entries): Add dwarf2_per_objfile parameter.
11339 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
11340 (new_symbol_full): Use dwarf2_per_objfile from cu.
11341 (build_error_marker_type): Likewise.
11342 (lookup_die_type): Likewise.
11343 (determine_prefix): Likewise.
11344 (follow_die_offset): Likewise.
11345 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
11346 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
11347 (dwarf2_fetch_die_type_sect_off): Likewise.
11348 (dwarf2_get_die_type): Likewise.
11349 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
11350 (get_signatured_type): Likewise.
11351 (get_DW_AT_signature_type): Likewise.
11352 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
11353 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
11354 (cu_debug_loc_section): Likewise.
11355 (fill_in_loclist_baton): Likewise.
11356 (dwarf2_symbol_mark_computed): Likewise.
11357 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11358 dwarf2_per_objfile.
11359 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
11361 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11362 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
11363 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
11364 (set_die_type): Use dwarf2_free_objfile from cu.
11365 (get_die_type_at_offset): Likewise.
11366 (dwarf2_per_objfile_free): Don't assign global variable.
11367 (debug_names) <constructor>: Add dwarf2_per_objfile
11368 parameter, update m_debugstrlookup construction.
11369 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
11371 <m_dwarf2_per_objfile>: New field.
11372 <lookup>: Use m_dwarf2_per_objfile.
11373 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
11374 (psyms_seen_size): Likewise.
11375 (write_gdbindex): Replace objfile parameter with
11376 dwarf2_per_objfile.
11377 (write_debug_names): Likewise.
11378 (write_psymtabs_to_index): Likewise.
11379 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
11382 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11384 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
11385 <dwarf2_per_objfile>: New field.
11386 (struct dwarf2_per_cu_data) <objfile>: Remove.
11387 <dwarf2_per_objfile>: New field.
11388 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
11390 (create_signatured_type_table_from_index): Likewise.
11391 (create_debug_type_hash_table): Likewise.
11392 (fill_in_sig_entry_from_dwo_entry): Likewise.
11393 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
11394 (create_type_unit_group): Assign dwarf2_per_objfile instead of
11396 (create_partial_symtab): Access objfile through
11397 dwarf2_per_objfile.
11398 (process_psymtab_comp_unit_reader): Likewise.
11399 (read_comp_units_from_section): Likewise.
11400 (scan_partial_symbols): Likewise.
11401 (add_partial_symbol): Likewise.
11402 (add_partial_subprogram): Likewise.
11403 (peek_die_abbrev): Likewise.
11404 (fixup_go_packaging): Likewise.
11405 (process_full_comp_unit): Likewise.
11406 (process_full_type_unit): Likewise.
11407 (process_imported_unit_die): Likewise.
11408 (dwarf2_compute_name): Likewise.
11409 (dwarf2_physname): Likewise.
11410 (read_import_statement): Likewise.
11411 (create_cus_hash_table): Assign dwarf2_physname instead of
11413 (read_func_scope): Access objfile through dwarf2_per_objfile.
11414 (read_lexical_block_scope): Likewise.
11415 (read_call_site_scope): Likewise.
11416 (read_variable): Likewise.
11417 (dwarf2_rnglists_process): Likewise.
11418 (dwarf2_ranges_process): Likewise.
11419 (dwarf2_ranges_read): Likewise.
11420 (dwarf2_record_block_ranges): Likewise.
11421 (dwarf2_add_field): Likewise.
11422 (dwarf2_add_member_fn): Likewise.
11423 (read_structure_type): Likewise.
11424 (process_structure_scope): Likewise.
11425 (read_enumeration_type): Likewise.
11426 (read_array_type): Likewise.
11427 (read_common_block): Likewise.
11428 (read_namespace_type): Likewise.
11429 (read_namespace): Likewise.
11430 (read_module_type): Likewise.
11431 (read_tag_pointer_type): Likewise.
11432 (read_tag_ptr_to_member_type): Likewise.
11433 (read_tag_string_type): Likewise.
11434 (read_subroutine_type): Likewise.
11435 (read_typedef): Likewise.
11436 (read_base_type): Likewise.
11437 (attr_to_dynamic_prop): Likewise.
11438 (read_subrange_type): Likewise.
11439 (read_unspecified_type): Likewise.
11440 (load_partial_dies): Likewise.
11441 (read_partial_die): Likewise.
11442 (find_partial_die): Likewise.
11443 (guess_partial_die_structure_name): Likewise.
11444 (fixup_partial_die): Likewise.
11445 (read_attribute_value): Likewise.
11446 (read_addr_index_from_leb128): Likewise.
11447 (dwarf2_read_addr_index): Likewise.
11448 (dwarf2_string_attr): Likewise.
11449 (lnp_state_machine::check_line_address): Likewise.
11450 (dwarf_decode_lines_1): Likewise.
11451 (dwarf_decode_lines): Likewise.
11452 (dwarf2_start_symtab): Likewise.
11453 (var_decode_location): Likewise.
11454 (new_symbol_full): Likewise.
11455 (dwarf2_const_value_data): Likewise.
11456 (dwarf2_const_value_attr): Likewise.
11457 (dwarf2_const_value): Likewise.
11458 (die_type): Likewise.
11459 (die_containing_type): Likewise.
11460 (lookup_die_type): Likewise.
11461 (guess_full_die_structure_name): Likewise.
11462 (anonymous_struct_prefix): Likewise.
11463 (dwarf2_name): Likewise.
11464 (follow_die_ref_or_sig): Likewise.
11465 (follow_die_offset): Likewise.
11466 (follow_die_ref): Likewise.
11467 (dwarf2_fetch_die_loc_sect_off): Likewise.
11468 (dwarf2_fetch_constant_bytes): Likewise.
11469 (dwarf2_fetch_die_type_sect_off): Likewise.
11470 (dwarf2_get_die_type): Likewise.
11471 (follow_die_sig): Likewise.
11472 (decode_locdesc): Likewise.
11473 (dwarf2_per_cu_objfile): Likewise.
11474 (dwarf2_per_cu_text_offset): Likewise.
11475 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
11477 (set_die_type): Access objfile through
11478 dwarf2_per_objfile.
11480 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11482 * valprint.c (converted_character_d): Remove typedef.
11483 (DEF_VEC_O (converted_character_d)): Remove.
11484 (count_next_character): Use std::vector.
11485 (print_converted_chars_to_obstack): Likewise.
11486 (generic_printstr): Likewise.
11488 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11490 * xml-support.h (struct gdb_xml_value): Add constructor.
11491 <value>: Change type to unique_xmalloc_ptr.
11492 (gdb_xml_value_s): Remove typedef.
11493 (DEF_VEC_O (gdb_xml_value_s)): Remove.
11494 (gdb_xml_element_start_handler): Change parameter type to
11496 (xml_find_attribute): Likewise.
11497 * xml-support.c (xml_find_attribute): Change parameter type to
11498 std::vector and adjust.
11499 (gdb_xml_values_cleanup): Remove.
11500 (gdb_xml_parser::start_element): Adjust to std::vector.
11501 (xinclude_start_include): Change paraeter type to std::vector
11503 * btrace.c (check_xml_btrace_version): Likewise.
11504 (parse_xml_btrace_block): Likewise.
11505 (parse_xml_btrace_pt_config_cpu): Likewise.
11506 (parse_xml_btrace_pt): Likewise.
11507 (parse_xml_btrace_conf_bts): Likewise.
11508 (parse_xml_btrace_conf_pt): Likewise.
11509 * memory-map.c (memory_map_start_memory): Likewise.
11510 (memory_map_start_property): Likewise.
11511 * osdata.c (osdata_start_osdata): Likewise.
11512 (osdata_start_item): Likewise.
11513 (osdata_start_column): Likewise.
11514 * remote.c (start_thread): Likewise.
11515 * solib-aix.c (library_list_start_library): Likewise.
11516 (library_list_start_list): Likewise.
11517 * solib-svr4.c (library_list_start_library): Likewise.
11518 (svr4_library_list_start_list): Likewise.
11519 * solib-target.c (library_list_start_segment): Likewise.
11520 (library_list_start_section): Likewise.
11521 (library_list_start_library): Likewise.
11522 (library_list_start_list): Likewise.
11523 * tracepoint.c (traceframe_info_start_memory): Likewise.
11524 (traceframe_info_start_tvar): Likewise.
11525 * xml-syscall.c (syscall_start_syscall): Likewise.
11526 * xml-tdesc.c (tdesc_start_target): Likewise.
11527 (tdesc_start_feature): Likewise.
11528 (tdesc_start_reg): Likewise.
11529 (tdesc_start_union): Likewise.
11530 (tdesc_start_struct): Likewise.
11531 (tdesc_start_flags): Likewise.
11532 (tdesc_start_enum): Likewise.
11533 (tdesc_start_field): Likewise.
11534 (tdesc_start_enum_value): Likewise.
11535 (tdesc_start_vector): Likewise.
11537 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11539 * extension.h (struct xmethod_worker) <clone>: Remove.
11540 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
11542 (python_xmethod_worker::clone): Remove.
11543 * valops.c (find_overload_match): Use std::move instead of
11546 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11548 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
11549 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
11550 <free_xmethod_worker_data>: Remove.
11551 <get_matching_xmethod_workers>: Chance VEC to std::vector.
11552 <get_xmethod_arg_types>: Remove.
11553 <get_xmethod_result_type>: Remove.
11554 <invoke_xmethod>: Remove.
11555 * extension.c (new_xmethod_worker): Remove.
11556 (clone_xmethod_worker): Remove.
11557 (get_matching_xmethod_workers): Return void, pass std::vector by
11559 (get_xmethod_arg_types): Rename to...
11560 (xmethod_worker::get_arg_types): ... this, and adjust.
11561 (get_xmethod_result_type): Rename to...
11562 (xmethod_worker::get_result_type): ... this, and adjust.
11563 (invoke_xmethod): Remove.
11564 (free_xmethod_worker): Remove.
11565 (free_xmethod_worker_vec): Remove.
11566 * extension.h (enum ext_lang_rc): Move here from
11568 (struct xmethod_worker): Add constructor and destructor.
11571 <invoke, clone, do_get_result_type, do_get_arg_types>: New
11572 virtual pure methods.
11573 <get_arg_types, get_result_type>: New methods.
11574 (xmethod_worker_ptr): Remove typedef.
11575 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
11576 (xmethod_worker_vec): Remove typedef.
11577 (xmethod_worker_up): New typedef.
11578 (invoke_xmethod): Remove.
11579 (clone_xmethod_worker): Remove.
11580 (free_xmethod_worker): Remove.
11581 (free_xmethod_worker_vec): Remove.
11582 (get_xmethod_arg_types): Remove.
11583 (get_xmethod_result_type): Remove.
11584 * valops.c (find_method_list): Use std::vector, don't use
11585 intermediate vector.
11586 (value_find_oload_method_list): Use std::vector.
11587 (find_overload_match): Use std::vector.
11588 (find_oload_champ): Use std::vector.
11589 * value.c (value_free): Use operator delete.
11590 (value_of_xmethod): Rename to...
11591 (value_from_xmethod): ... this. Don't assign
11592 xmethod_worker::value, take rvalue-reference.
11593 (result_type_of_xmethod): Adjust.
11594 (call_xmethod): Adjust.
11595 * value.h: Include extension.h.
11596 (struct xmethod_worker): Don't forward-declare.
11597 (value_of_xmethod): Rename to...
11598 (value_from_xmethod): ... this, take rvalue-reference.
11599 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
11600 (struct python_xmethod_worker): ... this, add constructor and
11602 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
11603 (gdbpy_free_xmethod_worker_data): Rename to...
11604 (python_xmethod_worker::~python_xmethod_worker): ... this and
11606 (gdbpy_clone_xmethod_worker_data): Rename to...
11607 (python_xmethod_worker::clone): ... this and adjust.
11608 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
11610 (gdbpy_get_xmethod_arg_types): Rename to...
11611 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
11612 (gdbpy_get_xmethod_result_type): Rename to...
11613 (python_xmethod_worker::do_get_result_type): ... this and
11615 (gdbpy_invoke_xmethod): Rename to...
11616 (python_xmethod_worker::invoke): ... this and adjust.
11617 (new_python_xmethod_worker): Rename to...
11618 (python_xmethod_worker::python_xmethod_worker): ... this and
11620 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
11622 (gdbpy_free_xmethod_worker_data): Remove.
11623 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11624 (gdbpy_get_xmethod_arg_types): Remove.
11625 (gdbpy_get_xmethod_result_type): Remove.
11626 (gdbpy_invoke_xmethod): Remove.
11627 * python/python.c (python_extension_ops): Remove obsolete
11630 2018-01-05 Pedro Alves <palves@redhat.com>
11633 * common/signals-state-save-restore.c
11634 (save_original_signals_state): New parameter 'quiet'. Warn if we
11635 find a custom handler preinstalled, instead of internal erroring.
11636 But only warn if !quiet.
11637 * common/signals-state-save-restore.h
11638 (save_original_signals_state): New parameter 'quiet'.
11639 * main.c (captured_main_1): Move save_original_signals_state call
11640 after option handling, and pass QUIET.
11642 2018-01-05 Pedro Alves <palves@redhat.com>
11644 * spu-tdep.c (spu_catch_start): Pass
11645 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11647 2018-01-05 Pedro Alves <palves@redhat.com>
11650 * ada-lang.c (literal_symbol_name_matcher): New function.
11651 (ada_get_symbol_name_matcher): Use it for
11652 symbol_name_match_type::SEARCH_NAME.
11653 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11654 it down instead of assuming symbol_name_match_type::FULL.
11655 * block.h (block_lookup_symbol): New parameter 'match_type'.
11656 * c-valprint.c (print_unpacked_pointer): Use
11657 lookup_symbol_search_name instead of lookup_symbol.
11658 * compile/compile-object-load.c (get_out_value_type): Pass down
11659 symbol_name_match_type::SEARCH_NAME.
11660 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11661 symbol_name_match_type::FULL.
11662 * cp-support.c (cp_get_symbol_name_matcher): Handle
11663 symbol_name_match_type::SEARCH_NAME.
11664 * infrun.c (insert_exception_resume_breakpoint): Use
11665 lookup_symbol_search_name.
11666 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11667 * psymtab.c (maintenance_check_psymtabs): Use
11668 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11669 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11670 SYMBOL_SEARCH_NAME.
11671 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11672 if symbol_name_match_type::SEARCH_NAME.
11673 (lookup_symbol_in_language): Pass down
11674 symbol_name_match_type::FULL.
11675 (lookup_symbol_search_name): New.
11676 (lookup_language_this): Pass down
11677 symbol_name_match_type::SEARCH_NAME.
11678 (lookup_symbol_aux, lookup_local_symbol): New parameter
11679 'match_type'. Pass it down.
11680 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11681 (lookup_symbol_search_name): New declaration.
11682 (lookup_symbol_in_block): New 'match_type' parameter.
11684 2018-01-05 Pedro Alves <palves@redhat.com>
11687 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11689 (ada_lookup_symbol): Reimplement in terms of
11690 ada_lookup_symbol_list, bits factored out from
11691 ada_lookup_encoded_symbol.
11693 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11695 * ada-exp.y (write_object_renaming): When subscripting an array
11696 using a symbol as the index, pass the block in call to
11697 ada_lookup_encoded_symbol when looking that symbol up.
11699 2018-01-05 Jerome Guitton <guitton@adacore.com>
11701 * ada-lang.c (ada_array_length): Use ada_index_type instead of
11704 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11706 * ada-lang.c (ada_to_fixed_value_create): Add handling of
11707 the case where VALUE_LVAL (val0) is not lval_memory.
11709 2018-01-05 Xavier Roirand <roirand@adacore.com>
11711 * ada-valprint.c (print_optional_low_bound): Handle
11712 character-indexed array printing like boolean-indexed array
11715 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11717 * NEWS: Create a new section for the next release branch.
11718 Rename the section of the current branch, now that it has
11721 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11723 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
11724 * version.in: Bump version to 8.1.50.DATE-git.
11726 2018-01-03 Xavier Roirand <roirand@adacore.com>
11728 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
11730 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
11732 (default_exception_support_info) <catch_handlers_sym>: Add field.
11733 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
11734 (ada_exception_name_addr_1): Add "catch handlers" handling.
11735 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
11736 Update all callers.
11737 (create_excep_cond_exprs) <ex>: Add parameter.
11738 (re_set_exception): Update create_excep_cond_exprs call.
11739 (print_it_exception, print_one_exception, print_mention_exception)
11740 (print_recreate_exception): Add "catch handler" handling.
11741 (allocate_location_catch_handlers, re_set_catch_handlers)
11742 (check_status_catch_handlers, print_it_catch_handlers)
11743 (print_one_catch_handlers, print_mention_catch_handlers)
11744 (print_recreate_catch_handlers): New function.
11745 (catch_handlers_breakpoint_ops): New variable.
11746 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
11747 Add parameter. Add "catch handler" handling.
11748 (ada_exception_sym_name, ada_exception_breakpoint_ops):
11749 Add "catch handler" handling.
11750 (ada_exception_catchpoint_cond_string): Add "catch handler"
11752 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
11754 (catch_ada_handlers_command): New function.
11755 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
11756 operations structure.
11757 (_initialize_ada_language): Add "catch handlers" command entry.
11758 * NEWS: Document "catch handlers" feature.
11760 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11762 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
11763 account when creating the array type of the slice.
11764 (ada_value_slice): Likewise.
11766 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11768 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
11770 (create_array_type_with_stride): Add byte_stride_prop parameter.
11771 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
11772 New parameter. Update all callers in this file.
11773 (array_type_has_dynamic_stride): New function.
11774 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
11775 of arrays with dynamic byte strides.
11776 * dwarf2read.c (read_array_type): Add support for dynamic
11777 DW_AT_byte_stride attributes.
11779 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11781 * dwarf2read.c (read_unspecified_type): Treat
11782 DW_TAG_enumeration_type DIEs from Ada units as stubs.
11784 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11786 Update copyright year range in all GDB files.
11788 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11790 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
11791 and gdb/testsuite/gdb.base/step-line.c.
11793 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11795 * copyright.py (main): Dump the contents of
11796 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
11797 even if BY_HAND is empty.
11799 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11801 * top.c (print_gdb_version): Update Copyright year in version
11804 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11806 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
11808 For older changes see ChangeLog-2017.
11814 version-control: never