1 2018-08-18 Kevin Buettner <kevinb@redhat.com>
3 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
5 * dwarf2-frame.c (class dwarf_expr_executor):
6 Add override for dwarf_variable_value.
7 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
8 (class symbol_needs_eval_context): Likewise.
9 (indirect_synthetic_pointer): Add forward declaration.
10 (sect_variable_value): New function.
11 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
12 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
13 for DW_OP_GNU_variable_value.
15 2018-08-16 Tom Tromey <tom@tromey.com>
17 * top.c (read_command_file): Update.
18 (command_line_input): Remove "repeat" argument.
19 * ada-lang.c (get_selections): Update.
20 * linespec.c (decode_line_2): Update.
21 * defs.h (command_line_input): Remove argument.
22 * cli/cli-script.c (read_next_line): Update.
23 * python/py-gdb-readline.c: Update.
25 2018-08-17 Tom Tromey <tom@tromey.com>
27 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
30 2018-08-15 Tom Tromey <tom@tromey.com>
32 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
34 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
36 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
37 If used, use find_pc_partial_function to find address range
39 * mi/mi-main.c (mi_cmd_list_features): Report
40 "data-disassemble-a-option" feature.
41 * NEWS: Mention new -data-disassemble option -a.
43 2018-08-13 Tom Tromey <tom@tromey.com>
45 * common/common-defs.h (_FORTIFY_SOURCE): Define.
47 2018-08-13 Alan Hayward <alan.hayward@arm.com>
49 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
50 (aarch64_linux_collect_sve_regset): Likewise.
51 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
52 * regcache.h (regcache_map_entry_size): New function.
54 2018-08-13 Alan Hayward <alan.hayward@arm.com>
56 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
57 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
58 (SVE_HEADER_VL_LENGTH): Likewise.
59 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
60 (SVE_HEADER_FLAGS_LENGTH): Likewise.
61 (SVE_HEADER_RESERVED_LENGTH): Likewise.
62 (SVE_HEADER_SIZE_OFFSET): Likewise.
63 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
64 (SVE_HEADER_VL_OFFSET): Likewise.
65 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
66 (SVE_HEADER_FLAGS_OFFSET): Likewise.
67 (SVE_HEADER_RESERVED_OFFSET): Likewise.
68 (SVE_HEADER_SIZE): Likewise.
69 (aarch64_linux_core_read_vq): Add function.
70 (aarch64_linux_core_read_description): Check for SVE section.
72 2018-08-13 Alan Hayward <alan.hayward@arm.com>
75 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
77 * aarch64-linux-tdep.c
78 (aarch64_linux_iterate_over_regset_sections): Likewise.
80 (alpha_linux_iterate_over_regset_sections):
82 (alphanbsd_iterate_over_regset_sections): Likewise.
84 (amd64fbsd_iterate_over_regset_sections): Likewise.
86 (amd64_linux_iterate_over_regset_sections): Likewise.
88 (armbsd_iterate_over_regset_sections): Likewise.
90 (arm_fbsd_iterate_over_regset_sections): Likewise.
92 (arm_linux_iterate_over_regset_sections): Likewise.
93 * corelow.c (get_core_registers_cb): Likewise.
94 (core_target::fetch_registers): Likewise.
95 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
96 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
97 * gdbarch.h (void): Regenerate.
98 * gdbarch.sh: Add supply_size and collect_size.
99 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
100 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
101 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
102 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
103 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
104 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
105 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
106 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
107 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
108 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
109 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
110 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
111 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
112 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
113 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
114 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
115 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
116 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
117 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
118 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
119 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
120 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
121 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
122 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
123 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
124 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
125 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
126 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
127 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
128 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
130 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
132 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
135 2018-08-10 Keith Seitz <keiths@redhat.com>
137 * compile/compile-c-support.c (add_code_header, add_code_footer):
138 Move into policy class.
139 (c_push_user_expression, pop_user_expression_nop)
140 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
141 (compile_program): New host class.
142 (c_compile_program): New typedef.
143 (c_compute_porgram): Use c_compile_program.
145 2018-08-10 Keith Seitz <keiths@redhat.com>
147 * compile/compile-internal.h (compile_instance::~compile_instance):
148 Remove calls to htab_delete.
149 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
150 * compile.c (compile_instance::compile_instance): Initialize
151 htab unique pointers.
152 (compile_instance::get_cached_type, compile_instance::insert_type)
153 (compile_instance::error_symbol_once): Update for unique_ptr.
155 2018-08-10 Keith Seitz <keiths@redhat.com>
157 * compile/compile-c-symbols.c (struct symbol_error)
158 (hash_symbol_error, eq_symbol_error, del_symbol_error)
159 (compile_instance::insert_symbol_error)
160 (compile_instance::error_symbol_once): Move to ...
161 * compile/compile.c: ... here.
163 2018-08-10 Keith Seitz <keiths@redhat.com>
165 * compile/compile-c-support.c (c_get_compile_context): Use `new'
166 instead of `new_compile_instance'.
167 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
169 If the symbol error map is not initialized, create it.
170 (generate_c_for_for_one_symbol): Do not check/initialize
171 the symbol error map.
172 * compile/compile-c-types.c (compile_c_instance): Make a class.
174 (compile_instance::compile_instance): Initialize the type cache.
175 (get_cached_type): New function.
176 (insert_type): Update description.
177 (compile_c_instance::m_default_cflags): Define.
178 (convert_type): Update description. Use get_cached_type.
179 (delete_instance): Moved to destructor.
180 (new_compile_instance): Moved to constructor.
181 * compile/compile-c.h (compile_c_instance): Make class inheriting
182 from compile_instance.
183 <base>: Remove field.
184 <type_map, symbol_err_map>: Move to base class.
185 <c_plugin>: Rename to `m_plugin' and remove pointer type.
186 * compile/compile-internal.h (compile_instance): Make class.
187 <type_map_t, symbol_err_map_t>: Define.
188 <fe>: Rename to `m_gcc_fe'.
189 <scope, block, gcc_target_options>: Add `m_' prefix.
190 <m_type_map, m_symbol_err_map>: New fields, moved from
193 (convert_type, new_compile_instance): Remove.
194 * compile/compile.c (cleanup_compile_instance): Remove.
195 (compile_to_object): Use unique_ptr to eliminate cleanups.
196 (compile_instance::set_print_callback, compile_instance::version)
197 (compile_instance::set_verbose)
198 (compile_instance::set_driver_filename)
199 (compile_instance::set_triplet_regexp)
200 (compile_instance::set_arguments)
201 (compile_instance::set_source_file)
202 (compile_instance::compile): Define.
204 2018-08-10 Keith Seitz <keiths@redhat.com>
206 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
207 * compile/compile-c-types.c: Define GCC_METHODN macros and include
208 gcc-c-fe.def to define C plugin.
209 (delete_instance): Delete `c_plugin'.
210 (new_compile_instance): Initialize `c_plugin'.
211 * compile/compile-c.h: Include gcc_c_plugin.h.
212 (struct compile_c_instance) <c_plugin>: New member.
213 * gcc-c-plugin.h: New file.
214 Update all callers with API change.
216 2018-08-10 Keith Seitz <keiths@redhat.com>
218 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
219 (HFILES_NO_SRCDIR): ... to here.
220 Add compile-internal.h and compile-c.h.
221 * compile/compile-c-support.c: Include compile-c.h.
222 * compile/compile-c-symbols.c: Include compile-c.h.
223 (generate_c_for_variable_locations): Update comment.
224 * compile/compile-c-types.c: Include compile-c.h.
225 * compile/compile-c.h: New file -- moved C language declarations
226 from other files here.
227 * compile/compile-internal.h: Do not include hashtab.h or
229 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
230 (gcc_convert_symbol, gcc_symbol_address)
231 (generate_c_for_variable_locations, c_get_mode_for_size)
232 (c_get_range_decl_name): Definitions moved to compile-c.h.
233 * compile/compile-loc2c.c: Include compile-c.h.
235 2018-08-10 Keith Seitz <keiths@redhat.com>
237 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
238 (c_symbol_substitution_name): ... this.
241 2018-08-10 Keith Seitz <keiths@redhat.com>
243 * compile/compile-c-support.c (c_compute_program): Use
244 unique_xmalloc_ptr to eliminate cleanup.
245 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
246 Return a unique_xmalloc_ptr and eliminate cleanup.
247 * compile/compile-internal.h (generate_c_for_variable_locations):
248 Return unique_xmalloc_ptr and update description.
250 2018-08-10 Alan Hayward <alan.hayward@arm.com>
252 * corelow.c (core_target::get_core_register_section): Rename
253 min_size to section_min_size.
255 2018-08-09 Jim Wilson <jimw@sifive.com>
257 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
258 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
259 * NEWS: Mention new GNU/Linux RISC-V target.
260 * configure.host: Add riscv*-*-linux*.
261 * configure.nat: Add riscv*.
262 * configure.tgt: Add riscv*-*-linux*.
263 * riscv-linux-nat.c: New file.
264 * riscv-linux-tdep.c: New file.
266 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
268 * infrun.c (resume): Make static, add forward declaration.
269 (proceed): Update header comment.
270 * infrun.h (resume): Delete declaration.
272 2018-08-09 Tom Tromey <tom@tromey.com>
274 * riscv-tdep.h: Minor formatting fixes.
276 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
278 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
279 * dwarf-index-cache.c (create_dir_and_check): Likewise.
280 (test_mkdir_recursive): Likewise.
281 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
283 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
285 * valarith.c (value_subscripted_rvalue): If an array is not in
286 memory, and we don't know the upper bound, then we can't know that
287 the requested element exists or not.
289 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
291 * target.c (str_comma_list_concat_elem): Fix typo in comment.
292 (target_options_to_string): Add comment.
294 2018-08-08 Tom Tromey <tom@tromey.com>
296 * unittests/scoped_mmap-selftests.c: Check result of "write".
298 2018-08-08 Jim Wilson <jimw@sifive.com>
300 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
301 (decode_register_index_short): New.
302 (decode_j_type_insn, decode_cj_type_insn): New.
303 (decode_b_type_insn, decode_cb_type_insn): New.
304 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
305 local xlen. Check xlen when decoding ambiguous compressed insns. In
306 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
307 is_c_sw_insn instead of is_sw_insn.
308 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
309 (riscv_software_single_step): New.
310 * riscv-tdep.h (riscv_software_single_step): Declare.
312 * riscv-tdep.c (riscv_isa_xlen): Drop static.
313 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
315 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
318 * target.c (dispose_inferior): Don't dispose of inferiors that are
321 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
323 * remote.c (remote_target::download_tracepoint): Change char* to
326 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
328 * target.h (target_options_to_string): Return an std::string.
329 * target.c (str_comma_list_concat_elem): Return void, use
331 (do_option): Likewise.
332 (target_options_to_string): Return an std::string.
333 * linux-nat.c (linux_nat_target::wait): Adjust.
334 * target-debug.h (target_debug_print_options): Adjust.
336 2018-08-07 Tom Tromey <tom@tromey.com>
338 * Makefile.in (CPPFLAGS): New variable.
339 (INTERNAL_CPPFLAGS): Use it.
341 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
343 * NEWS: Mention the index cache.
345 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
347 * common/pathstuff.h (get_standard_cache_dir): New.
348 * common/pathstuff.c (get_standard_cache_dir): New.
349 * build-id.h (build_id_to_string): New.
350 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
351 DEBUG_STR_SUFFIX): Move to here.
352 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
353 DEBUG_STR_SUFFIX): Move from there.
354 (write_psymtabs_to_index): Make non-static, add basename
355 parameter. Write to temporary files, rename when done.
356 (save_gdb_index_command): Adjust call to
357 write_psymtabs_to_index.
358 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
360 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
361 (get_gdb_index_contents_from_cache): New.
362 (get_gdb_index_contents_from_cache_dwz): New.
363 (dwarf2_initialize_objfile): Read index from cache.
364 (dwarf2_build_psymtabs): Save to index.
365 * dwarf-index-cache.h: New file.
366 * dwarf-index-cache.c: New file.
367 * dwarf-index-write.h: New file.
369 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
371 * gnulib/aclocal.m4: Re-generate.
372 * gnulib/config.in: Re-generate.
373 * gnulib/configure: Re-generate.
374 * gnulib/import/Makefile.am: Re-generate.
375 * gnulib/import/Makefile.in: Re-generate.
376 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
377 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
378 * gnulib/import/m4/mkdir.m4: New file.
379 * gnulib/import/mkdir.c: New file.
380 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
383 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
385 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
386 * common/scoped_mmap.c: New file.
387 * common/scoped_mmap.h (destroy): New method.
388 (~scoped_mmap, reset): Use destroy.
389 (scoped_mmap): New move constructor.
390 (mmap_file): New declaration.
391 * unittests/scoped_mmap-selftests.c (test_normal,
392 test_invalid_filename, run_tests): New functions.
393 (_initialize_scoped_mmap_selftests): Register selftest.
395 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
397 * dwarf2read.c (read_gdb_index_from_section): Rename to...
398 (read_gdb_index_from_buffer): ... this. Remove section
399 parameter, add buffer parameter.
400 (get_gdb_index_contents_ftype,
401 get_gdb_index_contents_dwz_ftype): New typedefs.
402 (dwarf2_read_gdb_index): Add callback parameters to get the
404 (get_gdb_index_contents_from_section): New.
405 (dwarf2_initialize_objfile): Update call to
406 dwarf2_read_gdb_index.
408 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
410 * common/filestuff.h (gdb_fopen_cloexec): New overload.
411 (gdb_open_cloexec): Likewise.
412 * nat/linux-osdata.c (command_from_pid): Use string_printf.
413 (commandline_from_pid): Likewise.
414 (linux_xfer_osdata_threads): Likewise.
415 (linux_xfer_osdata_fds): Likewise.
416 * ada-lang.c (is_package_name): Likewise.
417 * auxv.c (procfs_xfer_auxv): Likewise.
418 * breakpoint.c (print_one_breakpoint_location): Use
420 (print_one_catch_solib): Use string_printf.
421 * coff-pe-read.c (add_pe_exported_sym): Likewise.
422 (add_pe_forwarded_sym): Likewise.
423 * dwarf2read.c (create_type_unit_group): Likewise.
424 (build_error_marker_type): Likewise.
425 * infcall.c (get_function_name): Likewise.
426 * valprint.c (print_converted_chars_to_obstack): Likewise.
427 * xtensa-tdep.c (xtensa_register_type): Likewise.
429 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
431 * remote.c (remote_target::download_tracepoint): Fix format
434 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
436 * tracefile.c: Include common/byte-vector.h.
437 (trace_save): Change type of buf to gdb::byte_vector. Initialize
438 with trace_regblock_size if needed. Update uses of buf.
440 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
442 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
443 std::vector<unsigned char>.
444 * tracepoint.c (collection_list::collection_list): Remove
445 m_regs_mask initializer from initializer list. Resize
446 m_regs_mask using the largest remote register number.
447 (collection_list::add_remote_register): Remove size check on
448 m_regs_mask. Use at to access element.
449 (collection_list::stringify): Change type of temp_buf to
450 gdb::char_vector. Update uses of temp_buf. Resize if needed to
451 stringify the register mask. Use pack_hex_byte for the register
454 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
456 * tracepoint.h (class collection_list) <add_register>: Remove.
457 <add_remote_register, add_ax_registers, add_local_register>:
459 <add_memrange>: Add scope parameter.
460 * tracepoint.c (encode_actions_1): Likewise.
461 (collection_list::add_register): Rename to ...
462 (collection_list::add_remote_register): ... this. Update
464 (collection_list::add_ax_registers, add_local_register): New
466 (collection_list::add_memrange): Add scope parameter. Call
467 add_local_register instead of add_register.
468 (finalize_tracepoint_aexpr): New function.
469 (collection_list::collect_symbol): Update calls to add_memrange.
470 Call add_local_register instead of add_register. Call
471 add_ax_registers. Call finalize_tracepoint_aexpr.
472 (encode_actions_1): Get remote regnos for $reg action. Call
473 add_remote_register, add_ax_registers, and add_local_register.
474 Update call to add_memrange. Call finalize_tracepoint_aexpr.
475 (validate_actionline): Call finalize_tracepoint_aexpr.
477 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
479 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
480 Replace array buf with gdb::char_vector buf, of size
481 get_remote_packet_size (). Replace references to buf and
482 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
483 and xsnprintf with snprintf. Raise errors if the buffer is too
486 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
488 * remote.c (remote_target::download_tracepoint): Fix the has_more
489 predicate in the QTDP action list iteration.
491 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
493 * remote.c (remote_target::download_tracepoint): Fix indentation
496 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
498 * proc-api.c (_initialize_proc_api): Remove c, unused.
499 * procfs.c (procfs_init_inferior): Remove signals, unused.
500 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
503 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
504 Andrew Burgess <andrew.burgess@embecosm.com>
506 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
507 'W_STOPCODE (0)' as this could be ambiguous.
509 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
511 * ser-tcp.c (net_open): Fix thinko when deciding whether to
512 disable TCP's Nagle algorithm (use "ai_protocol" instead of
515 2018-08-02 Tom Tromey <tom@tromey.com>
518 * dwarf2read.c (read_func_scope): Set symtab on template parameter
520 (process_structure_scope): Likewise.
522 2018-08-02 Xavier Roirand <roirand@adacore.com>
525 * darwin-nat.c (darwin_kill_inferior): Fix handling of
528 2018-08-02 Tom Tromey <tom@tromey.com>
530 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
531 (darwin_suspend_inferior, darwin_resume_inferior)
532 (darwin_decode_notify_message, darwin_resume_inferior_threads)
533 (darwin_check_new_threads): Check result of get_darwin_inferior.
535 2018-07-31 Joel Brobecker <brobecker@adacore.com>
539 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
541 * varobj.c (varobj_get_path_expr_parent): Report an error if
542 parent is a dynamic varobj.
544 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
546 * gnulib/aclocal.m4: Re-generate.
547 * gnulib/config.in: Re-generate.
548 * gnulib/configure: Re-generate.
549 * gnulib/import/Makefile.in: Re-generate.
550 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
551 * gnulib/import/m4/onceonly.m4: Re-generate.
553 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
555 * target-descriptions.c (struct xml_test_tdesc): New.
556 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
557 (record_xml_tdesc): Update.
558 (maintenance_check_xml_descriptions): Update.
559 * target-descriptions.h (record_xml_tdesc): Update comment.
561 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
563 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
564 checking array bounds are defined.
566 2018-07-30 Tom Tromey <tom@tromey.com>
568 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
569 irreflexivity violation.
571 2018-07-30 Tom Tromey <tom@tromey.com>
573 * cli/cli-decode.c (lookup_cmd): Remove lint code.
574 * value.c (unpack_long): Remove lint code.
575 * valops.c (value_ind): Remove lint code.
576 * valarith.c (value_x_binop, value_x_unop, value_equal)
577 (value_pos): Remove lint code.
579 2018-07-28 Tom de Vries <tdevries@suse.de>
581 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
582 with undefined upper bound as <optimized out>.
584 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
586 * gcore.in: Rename variable "name" to "prefix". Expand
589 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
591 * windows-nat.c (windows_nat_target::create_inferior): Update to
592 call close() in global namespace.
594 2018-07-26 Tom Tromey <tom@tromey.com>
596 * dwarf-index-write.c (add_address_entry): Don't add objfile
598 * dbxread.c (find_stab_function): Rename from
599 find_stab_function_addr. Return a bound_minimal_symbol.
600 (read_dbx_symtab): Use raw_text_low, raw_text_high.
601 Don't add objfile offsets.
602 (end_psymtab): Use raw_text_low, raw_text_high,
603 MSYMBOL_VALUE_RAW_ADDRESS.
604 (read_ofile_symtab): Update.
605 (process_one_symbol): Update.
606 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
608 (dw2_relocate): Remove.
609 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
611 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
613 (process_psymtab_comp_unit_reader, add_partial_symbol)
614 (add_partial_subprogram, dwarf2_ranges_read): Update.
615 (load_partial_dies): Update.
616 (add_address_entry): Don't add objfile offsets.
617 (dwarf2_build_include_psymtabs): Update.
618 (create_addrmap_from_aranges): Don't add objfile offsets.
619 (dw2_find_pc_sect_compunit_symtab): Update.
620 * mdebugread.c (parse_symbol): Don't add objfile offsets.
621 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
623 (parse_partial_symbols): Don't add objfile offsets. Use
624 raw_text_low, raw_text_high. Update.
625 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
626 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
627 or call 'relocate' quick function. Clear psymbol_map.
628 * psympriv.h (struct partial_symbol) <address>: Add section
630 <set_unrelocated_address>: Rename from set_address.
631 <raw_text_low, raw_text_high>: New methods.
632 <text_low, text_high>: Add objfile parameter.
633 (add_psymbol_to_bcache): Add 'section' parameter. Call
634 set_unrelocated_address.
635 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
636 (find_pc_psymbol): Update.
637 (fixup_psymbol_section, relocate_psymtabs): Remove.
638 (dump_psymtab, psym_functions): Update.
639 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
641 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
642 (start_psymtab_common): Update.
643 * symfile-debug.c (debug_qf_relocate): Remove.
644 (debug_sym_quick_functions): Update.
645 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
646 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
649 2018-07-26 Tom Tromey <tromey@redhat.com>
651 * dbxread.c (end_psymtab): Use text_high_valid and
653 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
654 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
655 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
657 <text_low_valid, text_high_valid>: New fields.
658 <set_text_low, set_text_high>: Update.
659 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
661 2018-07-26 Tom Tromey <tom@tromey.com>
663 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
665 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
666 textlow and texthigh fields.
667 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
669 * mdebugread.c (parse_lines, parse_partial_symbols)
670 (psymtab_to_symtab_1): Update.
671 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
672 Rename fields. Update comment. Now private.
673 <text_low, text_high, set_text_low, set_text_high>: New methods.
674 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
675 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
676 (start_psymtab_common, maintenance_info_psymtabs)
677 (maintenance_check_psymtabs): Update.
678 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
680 (scan_xcoff_symtab): Update.
682 2018-07-26 Tom Tromey <tromey@redhat.com>
684 * psympriv.h (struct partial_symbol) <unrelocated_address,
685 address, set_address>: New methods.
686 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
687 (fixup_psymbol_section, relocate_psymtabs): Update.
688 (print_partial_symbols): Add 'objfile' parameter. Update.
689 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
692 2018-07-26 Tom Tromey <tom@tromey.com>
694 * dwarf-index-write.c (write_psymbols, debug_names::insert)
695 (debug_names::write_psymbols): Update.
696 * psympriv.h (struct partial_symbol): Derive from
698 <obj_section>: New method.
699 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
700 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
701 (find_pc_sect_psymbol, fixup_psymbol_section)
702 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
703 (print_partial_symbols, recursively_search_psymtabs)
704 (compare_psymbols, psymbol_hash, psymbol_compare)
705 (add_psymbol_to_bcache, maintenance_check_psymtabs)
706 (psymbol_name_matches, psym_fill_psymbol_map): Update.
708 2018-07-26 Tom Tromey <tromey@redhat.com>
710 * dbxread.c (end_psymtab): Remove dead code.
712 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
714 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
715 DWARF unwinders are disabled.
716 * dwarf2-frame.c: Add dwarf2read.h include.
717 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
719 (dwarf2_frame_unwinders_enabled_p): Define.
720 (show_dwarf_unwinders_enabled_p): New function.
721 (_initialize_dwarf2_frame): Register switch to control DWARF
723 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
724 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
725 (show_dwarf_cmdlist): Remove static keyword.
726 * dwarf2read.h (set_dwarf_cmdlist): Declare.
727 (show_dwarf_cmdlist): Declare.
728 * NEWS: Document new feature.
730 2018-07-26 Tom de Vries <tdevries@suse.de>
733 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
735 2018-07-26 Tom de Vries <tdevries@suse.de>
737 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
738 DW_AT_count can't be translated to a dynamic prop.
740 2018-07-25 Tom de Vries <tdevries@suse.de>
742 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
745 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
747 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
749 2018-07-25 Joel Brobecker <brobecker@adacore.com>
751 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
753 2018-07-24 Keith Seitz <keiths@redhat.comt
756 * dwarf2read.c (dw2_add_symbol_to_list): New function.
757 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
758 instead of add_symbol_to_list.
759 (read_file_scope): Call prepare_one_comp_unit before reading
762 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
764 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
766 2018-07-24 Tom Tromey <tom@tromey.com>
768 * utils.c (malloc, realloc, free): Don't declare.
769 * configure, config.in: Rebuild.
770 * configure.ac: Don't check for declarations of free, malloc, or
773 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
775 * aarch64-linux-nat.c
776 (aarch64_linux_nat_target::stopped_data_address): Remove unused
778 * arm-linux-nat.c (fetch_regs): Likewise.
779 (store_regs): Likewise.
780 (fetch_vfp_regs): Likewise.
781 (store_vfp_regs): Likewise.
782 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
783 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
784 (arm_linux_nat_target::insert_watchpoint): Likewise.
785 (arm_linux_nat_target::remove_watchpoint): Likewise.
786 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
788 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
790 * ppc-linux-nat.c (fetch_register): Likewise.
791 (fetch_all_gp_regs): Likewise.
792 (fetch_ppc_registers): Likewise.
793 (store_all_gp_regs): Likewise.
794 (store_ppc_registers): Likewise.
795 (hwdebug_insert_point): Likewise.
796 (can_use_watchpoint_cond_accel): Likewise.
797 * remote-sim.c (gdb_os_write_stdout): Likewise.
799 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
800 Tom Tromey <tom@tromey.com>
802 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
804 * configure: Rebuild.
806 2018-07-22 Tom Tromey <tom@tromey.com>
808 * regformats/regdat.sh: Define xmltarget_${name} inside
809 #ifndef IN_PROCESS_AGENT.
811 2018-07-22 Tom Tromey <tom@tromey.com>
813 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
815 2018-07-22 Tom Tromey <tom@tromey.com>
817 * symfile.c (reread_symbols): Notify iter, not objfile.
819 2018-07-22 Tom Tromey <tom@tromey.com>
821 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
823 (ravenscar_thread_target::prepare_to_store): Likewise.
825 2018-07-22 Tom Tromey <tom@tromey.com>
827 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
828 unused variable. Call value_fetch_lazy when needed.
829 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
830 Remove unused variable. Call value_fetch_lazy when needed.
832 2018-07-22 Tom Tromey <tom@tromey.com>
834 * m32c-tdep.c (mark_dma): Return void.
835 (make_regs): Remove unused declarations.
837 2018-07-22 Tom Tromey <tom@tromey.com>
839 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
840 cmdscm_get_valid_command_smob_arg_unsafe for effect.
841 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
842 bkscm_get_valid_block_smob_arg_unsafe for effect.
844 2018-07-22 Tom Tromey <tom@tromey.com>
846 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
849 2018-07-22 Tom Tromey <tom@tromey.com>
851 * windows-nat.c (saved_context): Conditionally define.
852 * remote.c (remote_target::remote_btrace_maybe_reopen):
853 Conditionally declare "warned".
854 * inflow.c (sigquit_ours): Conditionally define.
855 (new_tty): Move "tty" declaration inside #if.
856 * guile/guile.c (guile_datadir): Conditionally define.
857 * charset.c (set_be_le_names): Move some declarations inside #if.
858 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
860 (parse_xml_btrace_conf): Likewise.
862 2018-07-22 Tom Tromey <tom@tromey.com>
864 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
866 2018-07-22 Tom Tromey <tom@tromey.com>
868 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
869 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
870 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
871 * buildsym-legacy.c (get_macro_table): Remove unused variable.
872 * stack.c (frame_apply_level_command): Remove unused variable.
873 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
874 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
875 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
877 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
878 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
879 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
881 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
882 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
884 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
885 Remove unused variable.
886 * cli/cli-script.c (recurse_read_control_structure): Remove unused
888 * common/tdesc.c (print_xml_feature::visit): Remove unused
890 * compile/compile-object-load.c (store_regs): Remove unused
892 * complaints.c (clear_complaints): Remove unused variable.
893 * corelow.c (core_target_open): Remove unused variable.
894 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
896 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
898 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
900 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
902 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
904 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
906 * ia64-tdep.c (examine_prologue): Remove unused variable.
907 * infcall.c (run_inferior_call): Remove unused variable.
908 * inferior.c (exit_inferior): Remove unused variable.
909 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
910 * linespec.c (decode_line_2): Remove unused variable.
911 * linux-nat.c (super_close): Remove.
912 * linux-tdep.c (linux_info_proc): Remove unused variable.
913 * mi/mi-main.c (mi_execute_command): Remove unused variable.
914 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
915 Remove unused variable.
916 * parse.c (find_minsym_type_and_address): Remove unused variable.
917 * printcmd.c (info_symbol_command, printf_floating): Remove unused
919 * python/py-breakpoint.c (bppy_set_commands): Remove unused
921 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
923 * record-btrace.c (record_btrace_target::store_registers): Remove
925 (cmd_show_record_btrace_cpu): Remove unused variable.
926 * riscv-tdep.c (riscv_register_reggroup_p)
927 (riscv_push_dummy_call, riscv_return_value): Remove unused
929 * rust-exp.y (literal): Remove unused variable.
930 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
932 <STRUCTOP_ANONYMOUS>: Likewise.
933 * s390-linux-tdep.c (s390_linux_init_abi_31)
934 (s390_linux_init_abi_64): Remove unused variable.
935 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
936 (file_select_thread, net_windows_open, _initialize_ser_windows):
937 Remove unused variables.
938 * symtab.c (find_pc_sect_line): Remove unused variable.
939 * target-memory.c (compute_garbled_blocks): Remove unused
941 (target_write_memory_blocks): Remove unused variable.
942 * target.c (target_stack::unpush): Remove unused variables.
943 * tracepoint.c (start_tracing, all_tracepoint_actions)
944 (merge_uploaded_trace_state_variables)
945 (print_one_static_tracepoint_marker): Remove unused variable.
946 * unittests/basic_string_view/element_access/char/1.cc (test01):
947 Remove unused variable.
948 * windows-nat.c (windows_continue, windows_add_all_dlls)
949 (do_initial_windows_stuff, windows_nat_target::create_inferior):
950 Remove unused variables.
952 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
954 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
955 attr_profile in HAVE_ELF.
956 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
959 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
961 * frame.c (frame_register_unwind): Change parameter name.
962 (frame_unwind_register): Likewise.
963 (frame_unwind_register_value): Likewise.
964 (frame_unwind_register_signed): Likewise.
965 (frame_unwind_register_unsigned): Likewise.
966 * frame.h (frame_register_unwind): Likewise.
967 (frame_unwind_register): Likewise.
968 (frame_unwind_register_value): Likewise.
969 (frame_unwind_register_signed): Likewise.
970 (frame_unwind_register_unsigned): Likewise.
971 (frame_unwind_arch): Likewise.
973 2018-07-20 Maciej W. Rozycki <macro@mips.com>
975 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
978 2018-07-20 Maciej W. Rozycki <macro@mips.com>
980 * mips-linux-nat.c (mips_linux_nat_target::read_description):
981 Call `get_ptrace_pid' rather than extracting the ptrace PID by
984 2018-07-20 Keith Seitz <keiths@redhat.com>
986 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
987 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
988 m_compunit_symtab, m_language>: Add "m_" prefix.
990 * buildsym.c: Update all uses.
992 2018-07-20 Tom Tromey <tom@tromey.com>
994 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
995 * buildsym.h (record_line_ftype): Remove typedef.
997 2018-07-20 Tom Tromey <tom@tromey.com>
999 * buildsym-legacy.h (augment_type_symtab): Don't declare.
1000 (end_expandable_symtab): Likewise.
1001 (end_symtab_get_static_block): Likewise.
1002 (end_symtab_from_static_block): Likewise.
1003 * buildsym-legacy.c (augment_type_symtab): Remove.
1004 (end_expandable_symtab): Remove.
1005 (end_symtab_get_static_block): Remove.
1006 (end_symtab_from_static_block): Remove.
1008 2018-07-20 Tom Tromey <tom@tromey.com>
1010 * dwarf2read.c: Include buildsym.h.
1011 (struct dwarf2_cu) <builder>: New method.
1012 (fixup_go_packaging): Update.
1013 (process_full_comp_unit, process_full_type_unit): Update. Don't
1014 use scoped_free_pendings.
1015 (using_directives): Add "cu" parameter, remove "language".
1016 (read_import_statement, setup_type_unit_groups, )
1017 (read_func_scope, read_lexical_block_scope)
1018 (dwarf2_record_block_ranges, read_namespace): Update.
1019 (lnp_state_machine::lnp_state_machine): Add cu parameter.
1020 (lnp_state_machine::handle_end_sequence): Update.
1021 (class lnp_state_machine) <m_cu>: New member.
1022 <m_record_line_callback>: Remove.
1023 <m_currently_recording_lines>: New member.
1024 (lnp_state_machine::handle_set_file): Update.
1025 (noop_record_line): Remove.
1026 (dwarf_record_line_p): Add cu parameter.
1027 (dwarf_record_line_1, dwarf_finish_line): Likewise.
1028 (lnp_state_machine::record_line)
1029 (lnp_state_machine::lnp_state_machine)
1030 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1031 (dwarf_decode_lines): Update.
1032 (dwarf2_start_subfile): Add cu parameter.
1033 (dwarf2_start_symtab, new_symbol): Update.
1034 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
1035 Remove dwarf2_per_objfile parameter.
1036 (dwarf_decode_macros): Update.
1038 2018-07-20 Tom Tromey <tom@tromey.com>
1040 * stabsread.c (define_symbol): Update.
1041 * buildsym-legacy.h (get_buildsym_compunit): Declare.
1042 * dwarf2read.c (new_symbol): Update.
1043 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
1044 * cp-namespace.c: Include buildsym.h.
1045 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
1046 * buildsym-legacy.c (get_buildsym_compunit): New function.
1048 2018-07-20 Tom Tromey <tom@tromey.com>
1050 * xcoffread.c: Include buildsym-legacy.h.
1051 * windows-nat.c: Include buildsym-legacy.h.
1052 * stabsread.c: Include buildsym-legacy.h.
1053 * mdebugread.c: Include buildsym-legacy.h.
1054 * buildsym-legacy.h: New file.
1055 * buildsym-legacy.c: New file, from buildsym.c.
1056 * go32-nat.c: Include buildsym-legacy.h.
1057 * dwarf2read.c: Include buildsym-legacy.h.
1058 * dbxread.c: Include buildsym-legacy.h.
1059 * cp-namespace.c: Include buildsym-legacy.h.
1060 * coffread.c: Include buildsym-legacy.h.
1061 * buildsym.h: Move some contents to buildsym-legacy.h.
1062 * buildsym.c: Include buildsym-legacy.h. Move many functions to
1064 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
1066 2018-07-20 Tom Tromey <tom@tromey.com>
1068 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
1069 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
1070 (buildsym_compunit::buildsym_compunit)
1071 (buildsym_compunit::~buildsym_compunit)
1072 (buildsym_compunit::get_macro_table): Define.
1074 2018-07-20 Tom Tromey <tom@tromey.com>
1076 * buildsym.c (reset_symtab_globals): Remove.
1077 (buildsym_compunit::end_symtab_from_static_block): Update.
1078 (buildsym_compunit::augment_type_symtab): Update.
1079 (end_symtab_from_static_block): Call free_buildsym_compunit.
1080 (augment_type_symtab, end_symtab, end_expandable_symtab):
1083 2018-07-20 Tom Tromey <tom@tromey.com>
1085 * arch-utils.c: Do not include buildsym.h.
1086 * mipsread.c: Do not include buildsym.h.
1087 * machoread.c: Do not include buildsym.h.
1088 * elfread.c: Do not include buildsym.h.
1090 2018-07-20 Tom Tromey <tom@tromey.com>
1092 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
1094 (buildsym_compunit): Add new constructor.
1095 (struct buildsym_compunit) <get_last_source_file, finish_block,
1096 record_block_range, start_subfile, patch_subfile_names,
1097 push_subfile, pop_subfile, record_line, get_compunit_symtab,
1098 set_last_source_start_addr, get_last_source_start_addr,
1099 get_local_using_directives, set_local_using_directives,
1100 get_global_using_directives, outermost_context_p,
1101 get_current_context_stack, get_context_stack_depth,
1102 get_current_subfile, get_local_symbols, get_file_symbols,
1103 get_global_symbols, record_debugformat, record_producer,
1104 push_context, pop_context, end_symtab_get_static_block,
1105 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
1107 <record_pending_block, finish_block_internal, make_blockvector,
1108 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
1112 2018-05-22 Tom Tromey <tom@tromey.com>
1114 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1116 (finish_block_internal): Update.
1118 2018-07-20 Tom Tromey <tom@tromey.com>
1120 * buildsym.c (record_pending_block): Move earlier. Remove objfile
1122 (finish_block_internal): Update.
1124 2018-07-20 Tom Tromey <tom@tromey.com>
1126 * buildsym.h (EXTERN): Don't define or undef.
1127 * buildsym.c (EXTERN): Don't define.
1129 2018-07-20 Tom Tromey <tom@tromey.com>
1131 * buildsym.c: Remove TODO comment.
1133 2018-07-20 Tom Tromey <tom@tromey.com>
1135 * coffread.c (coff_symtab_read): Update.
1136 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
1137 (xcoff_new_init): Update.
1138 * mipsread.c (mipscoff_new_init): Update.
1139 * mdebugread.c (mdebug_build_psymtabs): Update.
1140 * elfread.c (elf_new_init): Update.
1141 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1143 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
1144 (coffstab_build_psymtabs, elfstab_build_psymtabs)
1145 (stabsect_build_psymtabs): Update.
1146 * buildsym.h (buildsym_init): Don't declare.
1147 * buildsym.c: Update comment.
1148 (prepare_for_building): Remove.
1149 (start_symtab, restart_symtab): Update.
1150 (reset_symtab_globals): Update comment.
1151 (buildsym_init): Remove.
1153 2018-07-20 Tom Tromey <tom@tromey.com>
1155 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
1156 * stabsread.c (patch_block_stabs, define_symbol, read_type)
1157 (read_enum_type, common_block_start, common_block_end)
1158 (cleanup_undefined_types_1, finish_global_stabs): Update.
1159 * mdebugread.c (psymtab_to_symtab_1): Update.
1160 * dwarf2read.c (fixup_go_packaging, read_func_scope)
1161 (read_lexical_block_scope, new_symbol): Update.
1162 * dbxread.c (process_one_symbol): Update.
1163 * coffread.c (coff_symtab_read, process_coff_symbol)
1164 (coff_read_enum_type): Update.
1165 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
1167 (get_local_symbols, get_file_symbols, get_global_symbols): New
1169 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
1171 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
1172 (~scoped_free_pendings): Update.
1173 (finish_block, prepare_for_building, reset_symtab_globals)
1174 (end_symtab_get_static_block, end_symtab_with_blockvector)
1175 (augment_type_symtab, push_context): Update.
1176 (get_local_symbols, get_file_symbols, get_global_symbols): New
1178 (buildsym_init): Update.
1180 2018-07-20 Tom Tromey <tom@tromey.com>
1182 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
1183 (process_full_type_unit): Likewise.
1184 (dwarf2_start_symtab): Set list_in_scope.
1186 2018-07-20 Tom Tromey <tom@tromey.com>
1188 * dwarf2read.c (process_psymtab_comp_unit_reader)
1189 (build_type_psymtabs_reader): Do not set list_in_scope.
1191 2018-07-20 Tom Tromey <tom@tromey.com>
1193 * buildsym.c (free_pendings): Remove.
1194 (add_symbol_to_list, scoped_free_pendings)
1195 (finish_block_internal, buildsym_init): Update.
1197 2018-07-20 Tom Tromey <tom@tromey.com>
1199 * xcoffread.c (read_xcoff_symtab): Update.
1200 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
1202 * dbxread.c (process_one_symbol): Update.
1203 * coffread.c (coff_symtab_read): Update.
1204 * buildsym.h (finish_block): Update.
1205 * buildsym.c (finish_block): Remove "listhead" argument.
1206 (end_symtab_get_static_block): Update.
1208 2018-07-20 Tom Tromey <tom@tromey.com>
1210 * buildsym.h (class scoped_free_pendings): Remove constructor.
1211 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
1213 <m_pending_block_obstack, m_pending_blocks>: New members.
1214 (pending_block_obstack, pending_blocks): Remove.
1215 (scoped_free_pendings::scoped_free_pendings): Default.
1216 (~scoped_free_pendings): Update.
1217 (free_pending_blocks): Remove.
1218 (finish_block_internal, record_pending_block, make_blockvector)
1219 (end_symtab_get_static_block, augment_type_symtab, push_context)
1220 (buildsym_init): Update.
1222 2018-07-20 Tom Tromey <tom@tromey.com>
1224 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
1225 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
1227 (pending_addrmap, pending_addrmap_obstack)
1228 (pending_addrmap_interesting): Remove.
1229 (scoped_free_pendings, record_block_range, make_blockvector)
1230 (prepare_for_building, reset_symtab_globals, buildsym_init):
1233 2018-07-20 Tom Tromey <tom@tromey.com>
1235 * xcoffread.c (process_linenos): Update.
1236 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
1237 * mdebugread.c (psymtab_to_symtab_1): Update.
1238 * dwarf2read.c (setup_type_unit_groups)
1239 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
1240 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
1241 * dbxread.c (process_one_symbol): Update.
1242 * coffread.c (coff_symtab_read, enter_linenos)
1243 (process_coff_symbol): Update.
1244 * buildsym.h (current_subfile): Don't declare.
1245 (get_current_subfile): Declare.
1246 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
1248 (start_subfile, free_buildsym_compunit, push_subfile)
1249 (prepare_for_building, start_symtab): Update.
1250 (get_current_subfile): New function.
1252 2018-07-20 Tom Tromey <tom@tromey.com>
1254 * coffread.c (coff_symtab_read): Update.
1255 * xcoffread.c (read_xcoff_symtab): Update.
1256 * dwarf2read.c (new_symbol): Update.
1257 (read_func_scope, read_lexical_block_scope): Update.
1258 * dbxread.c (process_one_symbol): Update.
1259 * buildsym.h (context_stack, context_stack_depth): Don't declare.
1260 (outermost_context_p): Remove macro.
1261 (outermost_context_p, get_current_context_stack)
1262 (get_context_stack_depth): Declare.
1263 (pop_context): Return struct context_stack.
1264 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
1266 (context_stack_size): Remove.
1267 (INITIAL_CONTEXT_STACK_SIZE): Remove.
1268 (prepare_for_building, end_symtab_get_static_block)
1269 (augment_type_symtab, push_context): Update.
1270 (pop_context): Return struct context_stack.
1271 (outermost_context_p, get_current_context_stack)
1272 (get_context_stack_depth): New functions.
1273 (buildsym_init): Update.
1275 2018-07-20 Tom Tromey <tom@tromey.com>
1277 * rust-exp.y: Now a pure parser. Update all rules.
1278 (%union): Move earlier.
1279 (current_parser, work_obstack): Remove globals.
1280 (rust_parser, ~rust_parser): Update.
1281 (class rust_parser) <copy_name, concat3, crate_name, super_name,
1282 lex_character, lex_number, lex_string, lex_identifier,
1283 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
1284 convert_name, convert_params_to_expression,
1285 convert_ast_to_expression, ast_basic_type, ast_operation,
1286 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
1287 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
1288 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
1289 ast_array_type, ast_slice_type, ast_reference_type,
1290 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
1291 (rust_parse): Update.
1292 (rustyyerror, rustyylex): Add parser parameter.
1293 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
1294 (rust_lex_stringish_test, rust_lex_test_sequence)
1295 (rust_lex_test_trailing_dot, rust_lex_test_completion)
1296 (rust_lex_test_push_back, rust_lex_tests): Update.
1298 2018-07-19 Pedro Alves <palves@redhat.com>
1300 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
1301 gdb::unique_xmalloc_ptr.
1302 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
1303 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
1304 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
1305 copy-initialization.
1306 * guile/scm-pretty-print.c (ppscm_print_children): Use
1307 gdb::unique_xmalloc_ptr instead of cleanups.
1308 (gdbscm_apply_val_pretty_printer): Remove cleanups.
1309 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
1310 gdb::unique_xmalloc_ptr.
1311 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1312 Adjust to use gdb::unique_xmalloc_ptr.
1313 * guile/scm-utils.c (extract_arg): Adjust.
1314 * guile/scm-value.c (gdbscm_value_field): Adjust to use
1315 gdb::unique_xmalloc_ptr instead of a cleanup.
1317 2018-07-19 Tom Tromey <tom@tromey.com>
1319 * utils.c (do_value_free_to_mark)
1320 (make_cleanup_value_free_to_mark): Remove.
1321 * utils.h (make_cleanup_value_free_to_mark): Remove.
1323 2018-07-19 Pedro Alves <palves@redhat.com>
1325 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
1326 forwarding reference.
1328 2018-07-18 Pedro Alves <palves@redhat.com>
1330 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
1331 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
1334 2018-07-18 Pedro Alves <palves@redhat.com>
1336 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
1338 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
1340 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
1341 directly instead of a cleanup.
1342 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
1343 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
1344 (vlscm_binop_gdbthrow): New, factored out from ...
1345 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
1346 (vlscm_rich_compare): Use gdbscm_wrap.
1347 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
1348 instead of a cleanup.
1349 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
1351 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1352 Use xfree directly instead of a cleanup.
1353 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
1354 Adjust to use gdbscm_wrap and scoped_value_mark.
1355 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
1356 (gdbscm_value_address, gdbscm_value_dereference)
1357 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
1359 (gdbscm_value_dynamic_type): Use scoped_value_mark.
1360 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
1362 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
1363 gdbscm_wrap and scoped_value_mark.
1364 (gdbscm_value_to_string): Use xfree directly instead of a
1365 cleanup. Move 'buffer' unique_ptr to TRY scope.
1366 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
1367 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
1369 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
1370 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
1372 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
1375 2018-07-18 Tom de Vries <tdevries@suse.de>
1377 * findvar.c (default_read_var_value): Also resolve dynamic type for
1378 LOC_OPTIMIZED_OUT vars.
1380 2018-07-18 Maciej W. Rozycki <macro@mips.com>
1382 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
1385 2018-07-17 Tom Tromey <tom@tromey.com>
1387 * guile/scm-param.c (pascm_set_func, pascm_show_func)
1388 (compute_enum_list, pascm_set_param_value_x)
1389 (gdbscm_parameter_value): Update.
1390 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
1391 (gdbscm_scm_to_host_string): Update.
1392 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
1394 * guile/scm-cmd.c (cmdscm_add_completion): Update.
1395 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
1396 * guile/scm-string.c (gdbscm_scm_to_string): Return
1398 (gdbscm_scm_to_host_string): Likewise.
1400 2018-07-17 Tom Tromey <tom@tromey.com>
1402 * guile/guile.c (gdbscm_eval_from_control_command): Update.
1403 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
1404 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
1405 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
1408 2018-07-17 Tom Tromey <tom@tromey.com>
1410 * guile/scm-param.c (pascm_signal_setshow_error): Update.
1411 * guile/guile-internal.h (gdbscm_exception_message_to_string):
1413 * guile/scm-cmd.c (cmdscm_function): Update.
1414 * guile/scm-pretty-print.c
1415 (ppscm_print_exception_unless_memory_error): Update.
1416 * guile/scm-exception.c (gdbscm_exception_message_to_string):
1417 Return unique_xmalloc_ptr.
1419 2018-07-17 Tom Tromey <tom@tromey.com>
1421 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
1424 2018-07-17 Jim Wilson <jimw@sifive.com>
1426 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
1427 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
1428 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
1429 unecessary braces after EF_RISCV_RVC test. Delete call to
1430 set_gdbarch_decr_pc_after_break.
1432 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
1433 RISCV_LAST_FP_REGNUM + 1.
1434 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
1436 2018-07-17 Tom Tromey <tom@tromey.com>
1438 * configure.ac: Remove --disable-gdbcli.
1439 * configure: Rebuild.
1440 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
1441 (SUBDIR_CLI_CFLAGS): Remove.
1442 (SFILES): Use SUBDIR_CLI_SRCS.
1443 (COMMON_OBS): Use SUBDIR_CLI_OBS.
1445 2018-07-17 Tom Tromey <tom@tromey.com>
1448 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
1450 2018-07-16 Jim Wilson <jimw@sifive.com>
1452 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
1454 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1456 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
1458 (libunwind_frame_sniffer): Likewise.
1459 (libunwind_frame_prev_register): Likewise.
1460 (libunwind_sigtramp_frame_sniffer): Likewise.
1461 * ia64-tdep.c (ia64_access_reg): Likewise.
1462 (ia64_access_rse_reg): Likewise.
1463 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
1464 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
1466 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1468 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
1470 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1472 * remote-sim.c (gdbsim_target::close,
1473 gdbsim_target::mourn_inferior): Remove unused variables.
1475 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
1477 * ia64-tdep.c (ktab_buf): New global.
1478 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
1479 (get_kernel_table): Adjust.
1481 2018-07-16 Tom Tromey <tom@tromey.com>
1483 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
1484 * dwarf2read.c (using_directives, new_symbol): Use
1485 outermost_context_p.
1486 * dbxread.c (process_one_symbol): Use outermost_context_p.
1487 * coffread.c (coff_symtab_read): Use outermost_context_p.
1489 2018-07-16 Tom Tromey <tom@tromey.com>
1491 * dwarf2read.c (using_directives, read_func_scope)
1492 (read_lexical_block_scope): Update.
1493 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1494 * buildsym.h (local_using_directives, global_using_directives):
1496 (get_local_using_directives, set_local_using_directives)
1497 (get_global_using_directives): Declare.
1498 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
1499 m_global_using_directives>: New members.
1500 (finish_block_internal, prepare_for_building)
1501 (reset_symtab_globals, end_symtab_get_static_block)
1502 (push_context): Update.
1503 (get_local_using_directives, set_local_using_directives)
1504 (get_global_using_directives): New functions.
1505 (buildsym_init): Update.
1507 2018-07-16 Tom Tromey <tom@tromey.com>
1509 * xcoffread.c (xcoff_initial_scan): Don't call
1510 free_pending_blocks.
1511 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
1512 * buildsym.h (class scoped_free_pendings): Add constructor.
1513 (free_pending_blocks): Don't declare.
1514 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
1515 (free_pending_blocks): Now static.
1517 2018-07-16 Tom Tromey <tom@tromey.com>
1519 * buildsym.h (push_subfile, pop_subfile): Update declarations.
1520 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
1522 (struct subfile_stack): Remove.
1523 (subfile_stack): Remove.
1524 (push_subfile, pop_subfile, buildsym_init): Update.
1526 2018-07-16 Tom Tromey <tom@tromey.com>
1528 * buildsym.c (push_subfile): Use gdb_assert.
1529 (pop_subfile): Use gdb_assert.
1531 2018-07-16 Tom Tromey <tom@tromey.com>
1533 * buildsym.h (merge_symbol_lists): Remove.
1534 * buildsym.c (merge_symbol_lists): Remove.
1536 2018-07-16 Tom Tromey <tom@tromey.com>
1538 * stabsread.c (scan_file_globals): Update comment.
1539 * stabsread.h (scan_file_globals): Move from buildsym.h.
1540 * buildsym.h (scan_file_globals): Move to stabsread.h.
1542 2018-07-16 Tom Tromey <tom@tromey.com>
1544 * xcoffread.c (xcoff_new_init): Update.
1545 * mipsread.c (mipscoff_new_init): Update.
1546 * mdebugread.c (mdebug_build_psymtabs): Update.
1547 * elfread.c (elf_new_init): Update.
1548 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
1549 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
1550 * buildsym.h (buildsym_new_init): Don't declare.
1551 * buildsym.c (buildsym_new_init): Remove.
1553 2018-07-16 Tom Tromey <tom@tromey.com>
1555 * stabsread.h (within_function): Move from buildsym.h.
1556 * stabsread.c (start_stabs): Clear within_function.
1557 * coffread.c (coff_start_symtab): Clear within_function.
1558 * buildsym.h (within_function): Move to stabsread.h.
1559 * buildsym.c (prepare_for_building): Update.
1561 2018-07-16 Tom Tromey <tom@tromey.com>
1563 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1564 * dwarf2read.c (dwarf2_start_symtab): Don't set
1565 processing_gcc_compilation.
1566 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1568 2018-07-16 Tom Tromey <tom@tromey.com>
1570 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1571 (next_symbol_text_func): Move from buildsym.h.
1572 * stabsread.c (hashname): Move from buildsym.c.
1573 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1574 (next_symbol_text_func, hashname): Move to stabsread.h.
1575 * buildsym.c: Don't include bcache.h
1576 (hashname): Move to stasbread.c.
1578 2018-07-16 Tom Tromey <tom@tromey.com>
1580 * buildsym.h (context_stack_size): Don't declare.
1581 * buildsym.c (context_stack_size): New global.
1583 2018-07-16 Tom Tromey <tom@tromey.com>
1585 * dbxread.c (processing_acc_compilation): New global.
1586 * buildsym.h (processing_acc_compilation): Don't declare.
1588 2018-07-16 Tom Tromey <tom@tromey.com>
1590 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1591 * dbxread.c (read_ofile_symtab): Update.
1592 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1593 * buildsym.h (last_source_start_addr): Remove.
1594 (set_last_source_start_addr, get_last_source_start_addr):
1596 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1598 (struct buildsym_compunit) <m_last_source_start_addr>: New
1600 (prepare_for_building): Remove start_addr parameter.
1601 (start_symtab, restart_symtab, end_symtab_get_static_block)
1602 (end_symtab_with_blockvector): Update.
1603 (set_last_source_start_addr, get_last_source_start_addr): New
1606 2018-07-16 Tom Tromey <tom@tromey.com>
1608 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1610 (have_line_numbers): Remove.
1611 (record_line, prepare_for_building, end_symtab_get_static_block)
1612 (augment_type_symtab): Update.
1614 2018-07-16 Tom Tromey <tom@tromey.com>
1616 * buildsym.c (~buildsym_compunit): Free the macro table.
1617 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1619 <m_pending_macros>: New member.
1620 (pending_macros): Remove.
1621 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1622 (reset_symtab_globals, end_symtab_get_static_block)
1623 (end_symtab_with_blockvector, augment_type_symtab)
1624 (buildsym_init): Update.
1626 2018-07-16 Tom Tromey <tom@tromey.com>
1628 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
1630 (buildsym_compunit::set_last_source_file): New method.
1631 <m_last_source_file>: New member.
1632 (prepare_for_building): Remove "name" parameter.
1633 (start_symtab, restart_symtab, reset_symtab_globals): Update.
1634 (last_source_file): Remove.
1635 (set_last_source_file, get_last_source_file): Update.
1637 2018-07-16 Tom Tromey <tom@tromey.com>
1639 * buildsym.c (prepare_for_building): Add assert.
1641 2018-07-16 Tom Tromey <tom@tromey.com>
1643 * buildsym.c (~buildsym_compunit): Update.
1644 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
1645 (start_subfile, patch_subfile_names)
1646 (end_symtab_with_blockvector): Update.
1648 2018-07-16 Tom Tromey <tom@tromey.com>
1650 * buildsym.c (struct buildsym_compunit): Add constructor,
1651 destructor, initializers.
1652 (start_buildsym_compunit): Remove.
1653 (free_buildsym_compunit): Use "delete".
1654 (start_symtab, restart_symtab): Use "new".
1656 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
1658 * symfile.c (set_objfile_default_section_offset): Remove struct
1661 2018-07-14 Stafford Horne <shorne@gmail.com>
1663 * (Responsible Maintainers): Add myself as or1k maintainer.
1665 2018-07-13 Tom Tromey <tom@tromey.com>
1667 * symfile.c (set_objfile_default_section_offset): Use extra braces
1670 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
1672 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
1675 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1677 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1678 unittests/cli-utils-selftests.c
1679 * unittests/cli-utils-selftests.c: New file.
1681 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1683 * NEWS: Mention new commands. Mention change to 'thread apply'.
1685 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1687 * thread.c (thr_try_catch_cmd): New function.
1688 (thread_apply_all_command): Handle qcs flags.
1689 (thread_apply_command): Handle qcs flags.
1690 (taas_command): New function.
1691 (tfaas_command): New function.
1692 (_initialize_thread): Update to setup the new commands 'taas
1693 and 'tfaas'. Change doc string for 'thread apply'.
1695 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1697 * stack.c: (trailing_outermost_frame): New function, mostly
1698 extracted from backtrace_command_1.
1699 (leading_innermost_frame): New function.
1700 (backtrace_command_1): Update to call trailing_outermost_frame.
1701 (frame_apply_command_count): New function.
1702 (frame_apply_level_command): New function.
1703 (frame_apply_all_command): New function.
1704 (frame_apply_command): New function.
1705 (faas_command): New function.
1706 (frame_cmd_list): New variable.
1707 (_initialize_stack): Update to setup the new commands 'frame apply'
1710 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1712 * cli-utils.c (number_or_range_parser::get_number): Only handle
1713 numbers or convenience var as numbers.
1714 (parse_flags): New function.
1715 (parse_flags_qcs): New function.
1716 (number_or_range_parser::finished): Ensure parsing end is detected
1717 before end of string.
1718 * cli-utils.h (parse_flags): New function.
1719 (parse_flags_qcs): New function.
1720 (number_or_range_parser): Remove m_finished bool.
1721 (number_or_range_parser::skip_range): Set m_in_range to false.
1723 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
1725 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
1728 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1729 Jan Kratochvil <jan.kratochvil@redhat.com>
1730 Paul Fertser <fercerpav@gmail.com>
1731 Tsutomu Seki <sekiriki@gmail.com>
1732 Pedro Alves <palves@redhat.com>
1734 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1735 'unittests/parse-connection-spec-selftests.c'.
1736 (COMMON_SFILES): Add 'common/netstuff.c'.
1737 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
1738 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
1739 * common/netstuff.c: New file.
1740 * common/netstuff.h: New file.
1741 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
1742 (wait_for_connect): Update comment. New parameter
1743 'gdb::optional<int> sock' instead of 'struct serial *scb'.
1744 Use 'sock' directly instead of 'scb->fd'.
1745 (try_connect): New function, with code from 'net_open'.
1746 (net_open): Rewrite main loop to deal with multiple
1747 sockets/addresses. Handle IPv6-style hostnames; implement
1748 support for IPv6 connections.
1749 * unittests/parse-connection-spec-selftests.c: New file.
1751 2018-07-11 Pedro Alves <palves@redhat.com>
1754 * remote.c (remote_target::remote_detach_pid): Call
1755 set_current_process.
1757 2018-07-11 Pedro Alves <palves@redhat.com>
1759 * h8300-tdep.c (h8300_gdbarch_init): Remove
1760 set_gdbarch_ecoff_reg_to_regnum calls.
1762 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1765 * c-typeprint.c (c_type_print_base_struct_union): Don't print
1766 offsets/sizes for static members of a class/struct.
1768 2018-07-11 Alan Hayward <alan.hayward@arm.com>
1770 * target-descriptions.c (tdesc_register_bitsize): Rename.
1771 * target-descriptions.h (tdesc_register_bitsize): Likewise.
1772 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
1773 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
1775 2018-07-10 Tom Tromey <tom@tromey.com>
1777 * breakpoint.c (moribund_locations): Now static and a
1779 (breakpoint_init_inferior, moribund_breakpoint_here_p)
1780 (build_bpstat_chain, update_global_location_list)
1781 (breakpoint_retire_moribund): Update.
1782 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
1785 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1787 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
1788 (riscv_register_reggroup_p): Use new function, remove unneeded
1790 (riscv_push_dummy_call): Extend assert to compare against xlen or
1791 flen based on register type.
1793 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1795 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
1797 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
1799 * remote.c (show_hardware_watchpoint_limit): New function.
1800 (show_hardware_watchpoint_length_limit): New function.
1801 (show_hardware_breakpoint_limit): New function.
1802 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
1803 where appropriate, update help text.
1805 2018-07-09 Tom Tromey <tom@tromey.com>
1807 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
1808 (CLIBS): Don't mention NAT_CLIBS.
1810 2018-07-09 Tom Tromey <tom@tromey.com>
1812 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
1813 (LIBGDB_OBS, clean mostlyclean): Update.
1814 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
1816 2018-07-09 Tom Tromey <tom@tromey.com>
1818 * Makefile.in (%.c: %.y): Use ECHO_YACC.
1819 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
1820 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
1822 2018-07-09 Tom Tromey <tom@tromey.com>
1824 * Makefile.in (ALLDEPFILES): Remove exec.c.
1825 (COMMON_OBS): Remove exec.o.
1826 (COMMON_SFILES): Add exec.c.
1828 2018-07-09 Tom Tromey <tom@tromey.com>
1830 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
1832 2018-07-09 Tom Tromey <tom@tromey.com>
1834 * Makefile.in (clean mostlyclean): Remove stamp-version.
1835 (version.c): Depend on stamp-version.
1836 (stamp-version): New rule, from version.c rule.
1838 2018-07-09 Tom Tromey <tom@tromey.com>
1840 * Makefile.in (init.c): Depend on stamp-init.
1841 (stamp-init): New rule, from init.c rule.
1842 (clean mostlyclean): Remove stamp-init.
1844 2018-07-09 Tom Tromey <tom@tromey.com>
1846 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
1847 SUBDIR_GCC_COMPILE_SRCS.
1849 2018-07-09 Tom Tromey <tom@tromey.com>
1851 * Makefile.in (init.c): Remove some unused sed rules.
1853 2018-07-09 Tom Tromey <tom@tromey.com>
1855 * Makefile.in (TSOBS): Remove.
1856 (INIT_FILES): Update.
1857 (LIBGDB_OBS): Update.
1858 (COMMON_SFILES): Add inflow.c.
1859 (SFILES): Remove inflow.c.
1861 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
1863 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
1865 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
1867 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
1868 get_saveloc_name, is_signal_frame_name, step_name,
1869 init_remote_name, create_addr_space_name,
1870 destroy_addr_space_name, search_unwind_table_name,
1871 find_dyn_list_name): Constify.
1873 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
1875 * darwin-nat.c (darwin_pthread_kill): New function.
1876 (darwin_resume_thread): Use darwin_pthread_kill.
1878 2018-07-05 Tom de Vries <tdevries@suse.de>
1880 * macroexp.c (macro_buffer) <operator=>: New member function.
1882 2018-07-04 Tom Tromey <tom@tromey.com>
1884 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
1886 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
1888 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
1889 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
1890 * maint.c: Likewise.
1893 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1895 * NEWS: Create a new section for the next release branch.
1896 Rename the section of the current branch, now that it has
1899 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1901 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
1902 * version.in: Bump version to 8.2.50.DATE-git.
1904 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1905 Pedro Alves <palves@redhat.com>
1907 * linux-nat.c (linux_init_ptrace): Rename to ...
1908 (linux_init_ptrace_procfs): ... this. Call
1909 linux_proc_init_warnings.
1910 (linux_nat_target::post_attach)
1911 (linux_nat_target::post_startup_inferior): Adjust.
1912 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
1913 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
1915 2018-07-04 Tom de Vries <tdevries@suse.de>
1917 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
1919 (read_comp_unit_head): ... here.
1921 2018-07-03 Tom Tromey <tom@tromey.com>
1923 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
1924 (stop_tracing, tstatus_command)
1925 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
1926 (print_one_static_tracepoint_marker): Update.
1927 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
1929 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
1931 (all_tracepoints, static_tracepoints_here): Return std::vector.
1933 2018-07-03 Tom Tromey <tom@tromey.com>
1935 * common/ptid.c (ptid_equal): Remove.
1936 * common/ptid.h (ptid_equal): Don't declare.
1937 * ada-tasks.c: Update.
1938 * breakpoint.c: Update.
1939 * common/agent.c: Update.
1940 * corelow.c: Update.
1941 * darwin-nat-info.c: Update.
1942 * darwin-nat.c: Update.
1944 * dtrace-probe.c: Update.
1945 * dummy-frame.c: Update.
1946 * fbsd-nat.c: Update.
1948 * gdbthread.h: Update.
1949 * gnu-nat.c: Update.
1950 * go32-nat.c: Update.
1951 * inf-loop.c: Update.
1952 * inf-ptrace.c: Update.
1953 * infcall.c: Update.
1957 * linux-fork.c: Update.
1958 * linux-nat.c: Update.
1959 * linux-thread-db.c: Update.
1960 * mi/mi-cmd-var.c: Update.
1961 * mi/mi-interp.c: Update.
1962 * mi/mi-main.c: Update.
1963 * nto-procfs.c: Update.
1964 * ppc-linux-tdep.c: Update.
1966 * python/py-inferior.c: Update.
1967 * python/py-record-btrace.c: Update.
1968 * python/py-record.c: Update.
1969 * ravenscar-thread.c: Update.
1970 * regcache.c: Update.
1971 * remote-sim.c: Update.
1973 * sol-thread.c: Update.
1976 * tui/tui-stack.c: Update.
1978 * windows-nat.c: Update.
1979 * windows-tdep.c: Update.
1981 2018-07-03 Tom Tromey <tom@tromey.com>
1983 * common/ptid.c (ptid_match): Remove.
1984 * common/ptid.h (ptid_match): Don't declare.
1985 * fbsd-nat.c: Update.
1988 * linux-nat.c: Update.
1989 * record-btrace.c: Update.
1990 * regcache.c: Update.
1993 2018-07-03 Tom Tromey <tom@tromey.com>
1995 * common/ptid.c (ptid_tid_p): Remove.
1996 * common/ptid.h (ptid_tid_p): Don't declare.
1997 * sol-thread.c: Update.
1999 2018-07-03 Tom Tromey <tom@tromey.com>
2001 * common/ptid.c (ptid_lwp_p): Remove.
2002 * common/ptid.h (ptid_lwp_p): Don't declare.
2003 * fbsd-nat.c: Update.
2004 * linux-nat.c: Update.
2005 * nat/linux-procfs.c: Update.
2006 * nat/x86-linux-dregs.c: Update.
2007 * sol-thread.c: Update.
2009 2018-07-03 Tom Tromey <tom@tromey.com>
2011 * common/ptid.c (ptid_is_pid): Remove.
2012 * common/ptid.h (ptid_is_pid): Don't declare.
2014 * linux-nat.c: Update.
2015 * mi/mi-interp.c: Update.
2019 2018-07-03 Tom Tromey <tom@tromey.com>
2021 * common/ptid.c (ptid_get_tid): Remove.
2022 * common/ptid.h (ptid_get_tid): Don't declare.
2023 * ada-tasks.c: Update.
2024 * aix-thread.c: Update.
2025 * bsd-uthread.c: Update.
2026 * darwin-nat.c: Update.
2027 * fbsd-nat.c: Update.
2028 * i386-darwin-nat.c: Update.
2030 * linux-tdep.c: Update.
2031 * nto-procfs.c: Update.
2032 * ppc-ravenscar-thread.c: Update.
2033 * python/py-infthread.c: Update.
2034 * ravenscar-thread.c: Update.
2035 * sol-thread.c: Update.
2036 * sparc-ravenscar-thread.c: Update.
2037 * windows-nat.c: Update.
2039 2018-07-03 Tom Tromey <tom@tromey.com>
2041 * common/ptid.c (ptid_get_lwp): Remove.
2042 * common/ptid.h (ptid_get_lwp): Don't declare.
2043 * aarch64-linux-nat.c: Update.
2044 * ada-tasks.c: Update.
2045 * aix-thread.c: Update.
2046 * amd64-linux-nat.c: Update.
2047 * arm-linux-nat.c: Update.
2048 * corelow.c: Update.
2049 * fbsd-nat.c: Update.
2050 * fbsd-tdep.c: Update.
2051 * gnu-nat.c: Update.
2052 * i386-cygwin-tdep.c: Update.
2053 * i386-gnu-nat.c: Update.
2054 * i386-linux-nat.c: Update.
2055 * ia64-linux-nat.c: Update.
2056 * inf-ptrace.c: Update.
2058 * linux-fork.c: Update.
2059 * linux-nat.c: Update.
2060 * linux-tdep.c: Update.
2061 * linux-thread-db.c: Update.
2062 * mips-linux-nat.c: Update.
2063 * nat/aarch64-linux-hw-point.c: Update.
2064 * nat/aarch64-linux.c: Update.
2065 * nat/linux-btrace.c: Update.
2066 * nat/linux-osdata.c: Update.
2067 * nat/linux-procfs.c: Update.
2068 * nat/x86-linux-dregs.c: Update.
2069 * obsd-nat.c: Update.
2070 * ppc-fbsd-nat.c: Update.
2071 * ppc-linux-nat.c: Update.
2073 * python/py-infthread.c: Update.
2074 * ravenscar-thread.c: Update.
2076 * s390-linux-nat.c: Update.
2077 * sol-thread.c: Update.
2078 * sol2-tdep.c: Update.
2079 * spu-linux-nat.c: Update.
2080 * x86-linux-nat.c: Update.
2081 * xtensa-linux-nat.c: Update.
2083 2018-07-03 Tom Tromey <tom@tromey.com>
2085 * common/ptid.c (ptid_get_pid): Remove.
2086 * common/ptid.h (ptid_get_pid): Don't declare.
2087 * aarch64-linux-nat.c: Update.
2088 * ada-lang.c: Update.
2089 * aix-thread.c: Update.
2090 * alpha-bsd-nat.c: Update.
2091 * amd64-fbsd-nat.c: Update.
2092 * amd64-linux-nat.c: Update.
2093 * arm-linux-nat.c: Update.
2094 * arm-nbsd-nat.c: Update.
2096 * break-catch-syscall.c: Update.
2097 * breakpoint.c: Update.
2098 * bsd-uthread.c: Update.
2099 * corelow.c: Update.
2101 * darwin-nat.c: Update.
2102 * fbsd-nat.c: Update.
2103 * fbsd-tdep.c: Update.
2105 * gnu-nat.c: Update.
2106 * hppa-nbsd-nat.c: Update.
2107 * hppa-obsd-nat.c: Update.
2108 * i386-fbsd-nat.c: Update.
2109 * ia64-linux-nat.c: Update.
2110 * inf-ptrace.c: Update.
2112 * inferior.c: Update.
2113 * inferior.h: Update.
2116 * linux-fork.c: Update.
2117 * linux-nat.c: Update.
2118 * linux-tdep.c: Update.
2119 * linux-thread-db.c: Update.
2120 * m68k-bsd-nat.c: Update.
2121 * mi/mi-interp.c: Update.
2122 * mi/mi-main.c: Update.
2123 * mips-linux-nat.c: Update.
2124 * mips-nbsd-nat.c: Update.
2125 * mips64-obsd-nat.c: Update.
2126 * nat/aarch64-linux-hw-point.c: Update.
2127 * nat/aarch64-linux.c: Update.
2128 * nat/linux-btrace.c: Update.
2129 * nat/linux-osdata.c: Update.
2130 * nat/linux-procfs.c: Update.
2131 * nat/x86-linux-dregs.c: Update.
2132 * nto-procfs.c: Update.
2133 * obsd-nat.c: Update.
2134 * ppc-linux-nat.c: Update.
2135 * ppc-nbsd-nat.c: Update.
2136 * ppc-obsd-nat.c: Update.
2137 * proc-service.c: Update.
2139 * python/py-inferior.c: Update.
2140 * python/py-infthread.c: Update.
2141 * ravenscar-thread.c: Update.
2143 * remote-sim.c: Update.
2145 * rs6000-nat.c: Update.
2146 * s390-linux-nat.c: Update.
2147 * sh-nbsd-nat.c: Update.
2148 * sol-thread.c: Update.
2149 * sparc-nat.c: Update.
2150 * sparc64-tdep.c: Update.
2151 * spu-linux-nat.c: Update.
2152 * spu-tdep.c: Update.
2153 * target-debug.h: Update.
2156 * tid-parse.c: Update.
2157 * tracefile-tfile.c: Update.
2158 * vax-bsd-nat.c: Update.
2159 * windows-nat.c: Update.
2160 * x86-linux-nat.c: Update.
2161 * x86-nat.c: Update.
2163 2018-07-03 Tom Tromey <tom@tromey.com>
2165 * common/ptid.c (pid_to_ptid): Remove.
2166 * common/ptid.h (pid_to_ptid): Don't declare.
2167 * aix-thread.c: Update.
2168 * arm-linux-nat.c: Update.
2169 * common/ptid.c: Update.
2170 * common/ptid.h: Update.
2171 * corelow.c: Update.
2173 * darwin-nat.c: Update.
2174 * fbsd-nat.c: Update.
2175 * fork-child.c: Update.
2176 * gnu-nat.c: Update.
2177 * go32-nat.c: Update.
2178 * inf-ptrace.c: Update.
2180 * inferior.c: Update.
2182 * linux-fork.c: Update.
2183 * linux-nat.c: Update.
2184 * nat/aarch64-linux-hw-point.c: Update.
2185 * nat/fork-inferior.c: Update.
2186 * nat/x86-linux-dregs.c: Update.
2187 * nto-procfs.c: Update.
2188 * obsd-nat.c: Update.
2190 * progspace.c: Update.
2192 * rs6000-nat.c: Update.
2193 * s390-linux-nat.c: Update.
2194 * sol-thread.c: Update.
2195 * spu-linux-nat.c: Update.
2198 * tracefile-tfile.c: Update.
2199 * windows-nat.c: Update.
2201 2018-07-03 Tom Tromey <tom@tromey.com>
2203 * common/ptid.h (ptid_build): Don't declare.
2204 * common/ptid.c (ptid_build): Remove.
2205 * aix-thread.c: Update.
2206 * bsd-kvm.c: Update.
2207 * bsd-uthread.c: Update.
2208 * common/agent.c: Update.
2209 * common/ptid.c: Update.
2210 * common/ptid.h: Update.
2211 * corelow.c: Update.
2212 * darwin-nat.c: Update.
2213 * fbsd-nat.c: Update.
2214 * gnu-nat.c: Update.
2215 * linux-fork.c: Update.
2216 * linux-nat.c: Update.
2217 * linux-thread-db.c: Update.
2218 * nat/linux-osdata.c: Update.
2219 * nat/linux-procfs.c: Update.
2220 * nto-procfs.c: Update.
2221 * obsd-nat.c: Update.
2222 * proc-service.c: Update.
2224 * ravenscar-thread.c: Update.
2225 * remote-sim.c: Update.
2227 * sol-thread.c: Update.
2229 * windows-nat.c: Update.
2231 2018-07-03 Tom Tromey <tom@tromey.com>
2233 * infrun.c (follow_exec): Use exit_inferior_silent.
2234 * inferior.c (exit_inferior_num_silent): Remove.
2235 * inferior.h (exit_inferior_num_silent): Don't declare.
2237 2018-07-03 Tom Tromey <tom@tromey.com>
2240 * darwin-nat.c (darwin_attach_pid): Reset inferior and
2241 inferior_ptid on error.
2243 2018-07-02 Maciej W. Rozycki <macro@mips.com>
2244 Simon Marchi <simon.marchi@polymtl.ca>
2247 * disasm.h (gdb_disassembler): Add
2248 `m_disassembler_options_holder'. member
2249 * disasm.c (get_all_disassembler_options): New function.
2250 (gdb_disassembler::gdb_disassembler): Use it.
2251 (gdb_buffered_insn_length_init_dis): Likewise.
2252 (gdb_buffered_insn_length): Adjust accordingly.
2253 (set_disassembler_options): Handle options with arguments.
2254 (show_disassembler_options_sfunc): Likewise. Add a leading new
2255 line if showing options with descriptions.
2256 (disassembler_options_completer): Adapt to using the
2257 `disasm_options_and_args_t' structure.
2258 * mips-tdep.c (mips_disassembler_options): New variable.
2259 (mips_disassembler_options_o32): Likewise.
2260 (mips_disassembler_options_n32): Likewise.
2261 (mips_disassembler_options_n64): Likewise.
2262 (gdb_print_insn_mips): Don't set `disassembler_options'.
2263 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
2265 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
2266 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
2267 `gdbarch_disassembler_options_implicit' and
2268 `gdbarch_valid_disassembler_options'.
2269 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
2270 `disasm_options_and_args_t' structure.
2271 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
2273 (valid_disassembler_options): Switch from `disasm_options_t' to
2274 the `disasm_options_and_args_t' structure.
2275 * NEWS: Document `set disassembler-options' support for the MIPS
2277 * gdbarch.h: Regenerate.
2278 * gdbarch.c: Regenerate.
2280 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
2282 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
2284 2018-06-29 Joel Brobecker <brobecker@adacore.com>
2286 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
2287 parameter in call to amd64_target_description.
2288 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
2289 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
2290 (amd64fbsd_init_abi): Likewise.
2291 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
2292 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
2293 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
2294 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
2296 2018-06-29 Pedro Alves <palves@redhat.com>
2298 * gdb/amd64-tdep.h (amd64_create_target_description): Add
2299 "segments" parameter.
2300 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
2301 (_initialize_amd64_tdep): Update call to
2302 amd64_create_target_description.
2303 (amd64_target_description): Add "segments" parameter. Adjust
2304 the implementation to use it.
2305 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
2306 call to amd64_create_target_description.
2307 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
2308 * gdb/arch/amd64.h (amd64_create_target_description): Add
2309 "segments" register.
2310 * gdb/arch/amd64.c (amd64_create_target_description): Add
2311 "segments" parameter. Call create_feature_i386_64bit_segments
2312 only if SEGMENTS is true.
2313 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
2314 call to amd64_create_target_description.
2316 2018-06-29 Pedro Alves <palves@redhat.com>
2318 * thread.c (thread_target_id_str): New, factored out from ...
2319 (print_thread_info_1): ... here. Use it to compute the max
2320 "Target Id" column width.
2322 2018-06-29 Pedro Alves <palves@redhat.com>
2324 * remote.c (remote_target::extra_thread_info): Delete
2325 'display_buf' and 'n' locals. from the cache, regardless of
2326 packet mechanims is in use. Use cache for qThreadExtra and qP
2329 2018-06-29 Pedro Alves <palves@redhat.com>
2331 * blockframe.c (find_pc_sect_containing_function): New function.
2332 * breakpoint.c (print_breakpoint_location): Don't call
2333 find_pc_sect_function.
2334 * linespec.c (create_sals_line_offset): Record the location's
2336 * linespec.c (convert_address_location_to_sals): Fill in sal's
2337 symbol with find_pc_sect_containing_function.
2338 * symtab.c (find_function_start_sal): Rename to ...
2339 (find_function_start_sal_1): ... this.
2340 (find_function_start_sal): Reimplement as wrapper around
2341 find_function_start_sal_1, and use
2342 find_pc_sect_containing_function to fill in the sal's symbol.
2343 (find_function_start_sal(symbol*, bool)): Adjust.
2344 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
2346 (find_pc_sect_containing_function): Declare.
2348 2018-06-29 Pedro Alves <palves@redhat.com>
2350 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
2351 true if the the location has no symbol.
2353 2018-06-28 Tom Tromey <tom@tromey.com>
2355 * NEWS: Mention --enable-codesign.
2356 * silent-rules.mk (ECHO_SIGN): New variable.
2357 * configure.ac: Add --enable-codesign.
2358 * configure: Rebuild.
2359 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
2360 (gdb$(EXEEXT)): Optionally invoke codesign.
2362 2018-06-28 Pedro Alves <palves@redhat.com>
2364 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
2366 (switch_to_thread_no_regs): Adjust comment.
2367 * infcmd.c (stop_pc): Delete.
2368 (post_create_inferior, info_program_command): Replace references
2369 to stop_pc with references to thread_info->suspend.stop_pc.
2370 * inferior.h (stop_pc): Delete declaration.
2371 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
2372 (handle_inferior_event_1, handle_signal_stop)
2373 (process_event_stop_test, keep_going_stepped_thread)
2374 (handle_step_into_function, handle_step_into_function_backward)
2375 (print_stop_location): Replace references to stop_pc with
2376 references to thread_info->suspend.stop_pc.
2377 (struct infcall_suspend_state) <stop_pc>: Delete field.
2378 (save_infcall_suspend_state, restore_infcall_suspend_state):
2379 Remove references to inf_stat->stop_pc.
2380 * linux-fork.c (fork_load_infrun_state): Likewise.
2381 * record-btrace.c (record_btrace_set_replay): Likewise.
2382 * record-full.c (record_full_goto_entry): Likewise.
2383 * remote.c (print_one_stopped_thread): Likewise.
2384 * target.c (target_resume): Extend comment.
2385 * thread.c (set_executing_thread): New.
2386 (set_executing): Use it.
2387 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
2388 Remove references to stop_pc.
2390 2018-06-28 Pedro Alves <palves@redhat.com>
2392 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
2393 Moving fetching stop_pc until after ecs->event_thread is refreshed.
2395 2018-06-28 Tom Tromey <tom@tromey.com>
2397 * coffread.c (coff_symfile_finish): Update.
2398 * xcoffread.c (xcoff_symfile_finish): Update.
2399 * elfread.c (elf_symfile_finish): Update.
2400 * symfile.h (dwarf2_free_objfile): Don't declare.
2401 * dwarf2read.c (_initialize_dwarf2_read): Use
2402 register_objfile_data_with_cleanup.
2403 (dwarf2_free_objfile): Now static. Change signature.
2405 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2407 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
2408 option "-o" to add-symbol-file-load to add an offset to each
2409 section's load address.
2410 * symfile.c (set_objfile_default_section_offset): New function.
2412 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2414 * symfile.c (add_symbol_file_command): Make sure that sections
2415 with the same name are sorted in the same order.
2417 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2419 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
2420 require the second argument. If omitted, load sections at the
2421 addresses specified in the file.
2423 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2425 * symfile.c (symbol_file_command, symbol_file_add_main_1)
2426 (_initialize_symfile): Add option "-o" to symbol-file to add an
2427 offset to each section of the symbol file.
2429 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2431 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
2433 2018-06-27 Tom Tromey <tom@tromey.com>
2435 * stack.c (_initialize_stack): Update "func" help text.
2437 2018-06-27 Tom Tromey <tom@tromey.com>
2439 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
2441 (unwind_infopy_str, pyuw_create_unwind_info)
2442 (unwind_infopy_add_saved_register, pyuw_sniffer)
2443 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
2445 (struct saved_reg): Add constructor.
2446 <value>: Now a gdbpy_ref<>.
2448 2018-06-27 Tom Tromey <tom@tromey.com>
2450 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
2452 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2454 * gdb-gdb.py.in: Format using autopep8.
2456 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2458 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
2459 (type_lookup_function): Recognize CORE_ADDR values.
2461 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2463 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
2466 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2468 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
2471 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2473 * gdb-gdb.py: Move to...
2474 * gdb-gdb.py.in: ... here.
2475 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
2476 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
2478 (distclean): Remove gdb-gdb.py when cleaning.
2479 (gdb-gdb.py, gdb-gdb.gdb): New rules.
2480 * configure: Re-generate.
2482 2018-06-27 Pedro Alves <palves@redhat.com>
2484 * proc-service.c (get_ps_regcache): New.
2485 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
2486 (ps_lsetfpregs): Use it.
2488 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
2491 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
2492 (dwarf_decode_lines_1): Adjust.
2494 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2496 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
2498 <info_proc>: Likewise.
2500 2018-06-26 Joel Brobecker <brobecker@adacore.com>
2502 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
2503 to windows_fetch_one_register, and only handle the case of
2504 fetching one register. Move the code that reloads the context
2505 and iterates over all registers if R is negative to...
2506 (windows_nat_target::fetch_registers): ... here.
2507 (do_windows_store_inferior_registers): Rename to
2508 windows_store_one_register, and only handle the case of storing
2509 one register. Move the code that handles the case where r is
2511 (windows_nat_target::store_registers) ... here.
2513 2018-06-26 Tom Tromey <tom@tromey.com>
2516 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
2517 * rust-lang.c (rust_print_struct_def): Add podata parameter.
2519 (rust_internal_print_type): Add podata parameter.
2520 (rust_print_type): Update.
2522 2018-06-26 Tom Tromey <tom@tromey.com>
2524 * typeprint.h (struct print_offset_data) <update, finish,
2525 maybe_print_hole>: New methods.
2526 <indentation>: New constant.
2527 * typeprint.c (print_offset_data::indentation): Define.
2528 (print_offset_data::maybe_print_hole, print_offset_data::update)
2529 (print_offset_data::finish): Move from c-typeprint.c and rename.
2530 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
2531 (print_spaces_filtered_with_print_options): Update.
2532 (c_print_type_union_field_offset, maybe_print_hole)
2533 (c_print_type_struct_field_offset): Move to typeprint.c and
2535 (c_type_print_base_struct_union): Update.
2537 2018-06-25 Pedro Alves <palves@redhat.com>
2539 * gdbthread.h (thread_info_ref, delete_thread)
2540 (delete_thread_silent, first_thread_of_inferior)
2541 (any_thread_of_inferior, switch_to_thread)
2542 (enable_thread_stack_temporaries)
2543 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2544 (get_last_thread_stack_temporary)
2545 (value_in_thread_stack_temporaries, can_access_registers_thread):
2546 Spell out "struct thread_info" instead of just "thread_info".
2547 * inferior.h (notice_new_inferior): Likewise.
2549 2018-06-25 Pedro Alves <palves@redhat.com>
2551 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2552 pass thread_info pointer to delete_thread.
2553 (windows_nat_target::detach): Pass inferior pointer to
2555 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2557 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2558 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2559 and pass a thread_info pointer to delete_thread.
2560 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2561 pass thread_info pointer to delete_thread.
2562 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2563 delete_thread_silent call.
2564 * procfs.c (procfs_target::detach): Pass inferior pointer to
2566 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2567 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2568 delete_thread_silent call.
2569 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2570 pass thread_info pointer to delete_thread.
2571 (windows_nat_target::detach): Pass inferior pointer to
2574 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2576 * regcache.c (readable_regcache::read_part): Fix asserts.
2577 (reg_buffer::raw_collect_part): New function.
2578 (regcache::write_part): Fix asserts.
2579 (reg_buffer::raw_supply_part): New function.
2580 (regcache::transfer_regset_register): New helper function.
2581 (regcache::transfer_regset): Call new functions.
2582 (regcache_supply_regset): Use gdb_byte*.
2583 (regcache::supply_regset): Likewise.
2584 (regcache_collect_regset): Likewise.
2585 (regcache::collect_regset): Likewise.
2586 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2587 (reg_buffer::raw_supply_part): Likewise.
2588 (regcache::transfer_regset_register): Likewise.
2589 (regcache::transfer_regset): Use gdb_byte*.
2591 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2593 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2595 2018-06-21 Pedro Alves <palves@redhat.com>
2597 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2598 instead of a ptid_t. All callers adjusted.
2599 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2601 (print_ada_task_info, display_current_task_id, task_command_1):
2603 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2605 (breakpoint_kind): Adjust.
2606 (remove_breakpoints_pid): Rename to ...
2607 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2608 pointer. All callers adjusted.
2609 (bpstat_clear_actions): Use inferior_thread.
2610 (get_bpstat_thread): New.
2611 (bpstat_do_actions): Use it.
2612 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2613 to take a thread_info pointer. All callers adjusted.
2614 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2615 (breakpoint_re_set_thread): Use inferior_thread.
2616 * breakpoint.h (struct inferior): Forward declare.
2617 (bpstat_stop_status): Update.
2618 (remove_breakpoints_pid): Delete.
2619 (remove_breakpoints_inf): New.
2620 * bsd-uthread.c (bsd_uthread_target::wait)
2621 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2622 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2623 (maint_btrace_packet_history_cmd)
2624 (maint_btrace_clear_packet_history_cmd): Adjust.
2625 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
2627 * cli/cli-interp.c: Include "inferior.h".
2628 * common/refcounted-object.h (struct
2629 refcounted_object_ref_policy): New.
2630 * compile/compile-object-load.c: Include gdbthread.h.
2631 (store_regs): Use inferior_thread.
2632 * corelow.c (core_target::close): Use current_inferior.
2633 (core_target_open): Adjust to use first_thread_of_inferior and use
2634 the current inferior.
2635 * ctf.c (ctf_target::close): Adjust to use current_inferior.
2636 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
2637 <thread>: ... this new field. All references adjusted.
2638 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
2639 Take a thread_info pointer instead of a ptid_t.
2640 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
2641 (dummy_frame_discard, register_dummy_frame_dtor): Take a
2642 thread_info pointer instead of a ptid_t.
2643 * elfread.c: Include "inferior.h".
2644 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
2645 Use inferior_thread.
2646 * eval.c (evaluate_subexp): Likewise.
2647 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
2649 * gdb_proc_service.h (struct thread_info): Forward declare.
2650 (struct ps_prochandle) <ptid>: Delete, replaced by ...
2651 <thread>: ... this new field. All references adjusted.
2652 * gdbarch.h, gdbarch.c: Regenerate.
2653 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
2654 'thread' parameter. All implementations and callers adjusted.
2655 * gdbthread.h (thread_info) <set_running>: New method.
2656 (delete_thread, delete_thread_silent): Take a thread_info pointer
2658 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
2659 (first_thread_of_process): Delete, replaced by ...
2660 (first_thread_of_inferior): ... this new function. All callers
2662 (any_live_thread_of_process): Delete, replaced by ...
2663 (any_live_thread_of_inferior): ... this new function. All callers
2665 (switch_to_thread, switch_to_no_thread): Declare.
2666 (is_executing): Delete.
2667 (enable_thread_stack_temporaries): Update comment.
2668 <enable_thread_stack_temporaries>: Take a thread_info pointer
2669 instead of a ptid_t. Incref the thread.
2670 <~enable_thread_stack_temporaries>: Decref the thread.
2673 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2674 (get_last_thread_stack_temporary)
2675 (value_in_thread_stack_temporaries, can_access_registers_thread):
2676 Take a thread_info pointer instead of a ptid_t. All callers
2678 * infcall.c (get_call_return_value): Use inferior_thread.
2679 (run_inferior_call): Work with thread pointers instead of ptid_t.
2680 (call_function_by_hand_dummy): Work with thread pointers instead
2681 of ptid_t. Use thread_info_ref.
2682 * infcmd.c (proceed_thread_callback): Access thread's state
2684 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
2685 access thread's state directly.
2686 (continue_command): Use inferior_thread.
2687 (info_program_command): Use find_thread_ptid and access thread
2689 (proceed_after_attach_callback): Use thread state directly.
2690 (notice_new_inferior): Take a thread_info pointer instead of a
2691 ptid_t. All callers adjusted.
2692 (exit_inferior): Take an inferior pointer instead of a pid. All
2694 (exit_inferior_silent): New.
2695 (detach_inferior): Delete.
2696 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
2697 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
2698 (detach_inferior_command, kill_inferior_command): Use
2699 find_inferior_id instead of valid_gdb_inferior_id and
2700 gdb_inferior_id_to_pid.
2701 (inferior_command): Use inferior and thread pointers.
2702 * inferior.h (struct thread_info): Forward declare.
2703 (notice_new_inferior): Take a thread_info pointer instead of a
2704 ptid_t. All callers adjusted.
2705 (detach_inferior): Delete declaration.
2706 (exit_inferior, exit_inferior_silent): Take an inferior pointer
2707 instead of a pid. All callers adjusted.
2708 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
2709 (valid_gdb_inferior_id): Delete.
2710 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
2711 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
2712 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
2714 <inf>: ... this new field.
2715 <step_ptid>: Delete, replaced by ...
2716 <step_thread>: ... this new field.
2717 (get_displaced_stepping_state): Take an inferior pointer instead
2718 of a pid. All callers adjusted.
2719 (displaced_step_in_progress_any_inferior): Adjust.
2720 (displaced_step_in_progress_thread): Take a thread pointer instead
2721 of a ptid_t. All callers adjusted.
2722 (displaced_step_in_progress, add_displaced_stepping_state): Take
2723 an inferior pointer instead of a pid. All callers adjusted.
2724 (get_displaced_step_closure_by_addr): Adjust.
2725 (remove_displaced_stepping_state): Take an inferior pointer
2726 instead of a pid. All callers adjusted.
2727 (displaced_step_prepare_throw, displaced_step_prepare)
2728 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
2729 All callers adjusted.
2730 (start_step_over): Adjust.
2731 (infrun_thread_ptid_changed): Remove bit updating ptids in the
2732 displaced step queue.
2733 (do_target_resume): Adjust.
2734 (fetch_inferior_event): Use inferior_thread.
2735 (context_switch, get_inferior_stop_soon): Take an
2736 execution_control_state pointer instead of a ptid_t. All callers
2738 (switch_to_thread_cleanup): Delete.
2739 (stop_all_threads): Use scoped_restore_current_thread.
2740 * inline-frame.c: Include "gdbthread.h".
2741 (inline_state) <inline_state>: Take a thread pointer instead of a
2742 ptid_t. All callers adjusted.
2743 <ptid>: Delete, replaced by ...
2744 <thread>: ... this new field.
2745 (find_inline_frame_state): Take a thread pointer instead of a
2746 ptid_t. All callers adjusted.
2747 (skip_inline_frames, step_into_inline_frame)
2748 (inline_skipped_frames, inline_skipped_symbol): Take a thread
2749 pointer instead of a ptid_t. All callers adjusted.
2750 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
2751 (inline_skipped_frames, inline_skipped_symbol): Likewise.
2752 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
2754 * linux-nat.c (get_detach_signal): Likewise.
2755 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
2756 (thread_db_notice_clone): Adjust.
2757 (thread_db_find_new_threads_silently)
2758 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
2759 a thread pointer instead of a ptid_t. All callers adjusted.
2760 * mi/mi-cmd-var.c: Include "inferior.h".
2761 (mi_cmd_var_update_iter): Update to use thread pointers.
2762 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
2764 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
2766 (mi_output_running): ... this new function.
2767 (mi_on_resume_1): Adjust to use it.
2768 (mi_user_selected_context_changed): Adjust to use inferior_thread.
2769 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
2771 (interrupt_thread_callback): : Adjust to use thread and inferior
2773 * proc-service.c: Include "gdbthread.h".
2774 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
2775 * progspace-and-thread.c: Include "inferior.h".
2776 * progspace.c: Include "inferior.h".
2777 * python/py-exitedevent.c (create_exited_event_object): Adjust to
2778 hold a reference to an inferior_object.
2779 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
2781 * python/py-inferior.c (struct inferior_object): Give the type a
2782 tag name instead of a typedef.
2783 (python_on_normal_stop): No need to check if the current thread is
2785 (inferior_to_inferior_object): Change return type to
2786 inferior_object. All callers adjusted.
2787 (find_thread_object): Delete, bits factored out to ...
2788 (thread_to_thread_object): ... this new function.
2789 * python/py-infthread.c (create_thread_object): Use
2790 inferior_to_inferior_object.
2791 (thpy_is_stopped): Use thread pointer directly.
2792 (gdbpy_selected_thread): Use inferior_thread.
2793 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
2794 field, replaced with ...
2795 <thread>: ... this new field. All users adjusted.
2796 (btpy_insn_or_gap_new): Drop const.
2797 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
2799 * python/py-record.c: Include "gdbthread.h".
2800 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2801 a ptid_t. All callers adjusted.
2802 (gdbpy_current_recording): Use inferior_thread.
2803 * python/py-record.h (recpy_record_object) <ptid>: Delete
2804 field, replaced with ...
2805 <thread>: ... this new field. All users adjusted.
2806 (recpy_element_object) <ptid>: Delete
2807 field, replaced with ...
2808 <thread>: ... this new field. All users adjusted.
2809 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2810 a ptid_t. All callers adjusted.
2811 * python/py-threadevent.c: Include "gdbthread.h".
2812 (get_event_thread): Use thread_to_thread_object.
2813 * python/python-internal.h (struct inferior_object): Forward
2815 (find_thread_object, find_inferior_object): Delete declarations.
2816 (thread_to_thread_object, inferior_to_inferior_object): New
2818 * record-btrace.c: Include "inferior.h".
2819 (require_btrace_thread): Use inferior_thread.
2820 (record_btrace_frame_sniffer)
2821 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
2822 (get_thread_current_frame): Use scoped_restore_current_thread and
2824 (get_thread_current_frame): Use thread pointer directly.
2825 (record_btrace_replay_at_breakpoint): Use thread's inferior
2827 * record-full.c: Include "inferior.h".
2828 * regcache.c: Include "gdbthread.h".
2829 (get_thread_arch_regcache): Use the inferior's address space
2831 (get_thread_regcache, registers_changed_thread): New.
2832 * regcache.h (get_thread_regcache(thread_info *thread)): New
2834 (registers_changed_thread): New.
2835 (remote_target) <remote_detach_1>: Swap order of parameters.
2836 (remote_add_thread): <remote_add_thread>: Return the new thread.
2837 (get_remote_thread_info(ptid_t)): New overload.
2838 (remote_target::remote_notice_new_inferior): Use thread pointers
2840 (remote_target::process_initial_stop_replies): Use
2841 thread_info::set_running.
2842 (remote_target::remote_detach_1, remote_target::detach)
2843 (extended_remote_target::detach): Adjust.
2844 * stack.c (frame_show_address): Use inferior_thread.
2845 * target-debug.h (target_debug_print_thread_info_pp): New.
2846 * target-delegates.c: Regenerate.
2847 * target.c (default_thread_address_space): Delete.
2848 (memory_xfer_partial_1): Use current_inferior.
2849 (target_detach): Use current_inferior.
2850 (target_thread_address_space): Delete.
2851 (generic_mourn_inferior): Use current_inferior.
2852 * target.h (struct target_ops) <thread_address_space>: Delete.
2853 (target_thread_address_space): Delete.
2854 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
2856 (delete_thread_1, delete_thread, delete_thread_silent): Take a
2857 thread pointer instead of a ptid_t. Adjust all callers.
2858 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
2859 (first_thread_of_process): Delete, replaced by ...
2860 (first_thread_of_inferior): ... this new function. All callers
2862 (any_thread_of_process): Rename to ...
2863 (any_thread_of_inferior): ... this, and take an inferior pointer.
2864 (any_live_thread_of_process): Rename to ...
2865 (any_live_thread_of_inferior): ... this, and take an inferior
2867 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2868 (value_in_thread_stack_temporaries)
2869 (get_last_thread_stack_temporary): Take a thread pointer instead
2870 of a ptid_t. Adjust all callers.
2871 (thread_info::set_running): New.
2872 (validate_registers_access): Use inferior_thread.
2873 (can_access_registers_ptid): Rename to ...
2874 (can_access_registers_thread): ... this, and take a thread
2876 (print_thread_info_1): Adjust to compare thread pointers instead
2878 (switch_to_no_thread, switch_to_thread): Make extern.
2879 (scoped_restore_current_thread::~scoped_restore_current_thread):
2880 Use m_thread pointer directly.
2881 (scoped_restore_current_thread::scoped_restore_current_thread):
2882 Use inferior_thread.
2883 (thread_command): Use thread pointer directly.
2884 (thread_num_make_value_helper): Use inferior_thread.
2885 * top.c (execute_command): Use inferior_thread.
2886 * tui/tui-interp.c: Include "inferior.h".
2887 * varobj.c (varobj_create): Use inferior_thread.
2888 (value_of_root_1): Use find_thread_global_id instead of
2889 global_thread_id_to_ptid.
2891 2018-06-21 Alan Hayward <alan.hayward@arm.com>
2893 * regcache.c (readable_regcache::read_part): Avoid memcpy when
2895 (regcache::write_part): Likewise.
2896 (readable_regcache::cooked_read_part): Update comment.
2897 (readable_regcache::cooked_write_part): Likewise.
2898 * regcache.h: (readable_regcache::read_part): Likewise.
2899 (regcache::write_part): Likewise.
2901 2018-06-21 Richard Bunt <richard.bunt@arm.com>
2902 Dirk Schubert <dirk.schubert@arm.com>
2904 * aarch64-linux-nat.c (post_attach): New.
2905 (aarch64_linux_nat_target::post_attach): Override post_attach to
2906 record the number of hardware debug registers.
2908 2018-06-20 Tom Tromey <tom@tromey.com>
2910 * python/py-param.c (add_setshow_generic): Make parameters const.
2911 (parmpy_init): Update.
2913 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2915 * regcache.h (regcache_cooked_read_ftype): Rename to...
2916 (register_read_ftype): ...this, change type to function_view.
2917 (class reg_buffer) <save>: Remove src parameter.
2918 (readonly_detached_regcache) <readonly_detached_regcache>: Make
2919 parameter non-const in first overload. Remove src parameter in
2921 * regcache.c (do_cooked_read): Remove.
2922 (readonly_detached_regcache::readonly_detached_regcache): Make
2923 parameter non-const, adjust call to other constructor.
2924 (reg_buffer::save): Remove src parameter.
2925 * frame.c (do_frame_register_read): Remove.
2926 (frame_save_as_regcache): Use lambda function.
2927 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
2928 parameter to ppu2spu_data *.
2929 (ppu2spu_sniffer): Use lambda function.
2931 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2933 * record-full.c (record_full_target::insert_breakpoint): Remove
2934 "struct" keyword, add const.
2936 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2938 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
2939 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
2940 * configure.ac: Remove AC_PREREQ, add missing quoting.
2941 * gnulib/configure.ac: Modernize usage of
2942 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
2943 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
2944 (AUTOMAKE_VERSION): Bump to 1.15.1.
2945 * configure: Re-generate.
2946 * config.in: Re-generate.
2947 * aclocal.m4: Re-generate.
2948 * gnulib/aclocal.m4: Re-generate.
2949 * gnulib/config.in: Re-generate.
2950 * gnulib/configure: Re-generate.
2951 * gnulib/import/Makefile.in: Re-generate.
2953 2018-06-19 Pedro Alves <palves@redhat.com>
2955 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
2956 (lookup_minimal_symbol_by_pc_section): ... here with
2957 gdb_assert_not_reached added.
2959 2018-06-19 Pedro Alves <palves@redhat.com>
2961 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
2962 parameter with a block parameter. Compare location's block symbol
2963 with the frame's block instead of addresses.
2964 (skip_inline_frames): Pass the current block instead of the
2965 frame's address. Break out as soon as we determine the frame
2966 should not be skipped.
2968 2018-06-18 Tom Tromey <tom@tromey.com>
2970 * solib-aix.c (solib_aix_get_section_offsets): Return
2972 (solib_aix_solib_create_inferior_hook): Update.
2974 2018-06-18 Tom Tromey <tom@tromey.com>
2976 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
2978 2018-06-18 Tom Tromey <tom@tromey.com>
2980 * solib-frv.c (frv_relocate_main_executable): Use
2982 * solib-dsbt.c (dsbt_relocate_main_executable): Use
2985 2018-06-18 Tom Tromey <tom@tromey.com>
2987 * objfiles.h (inhibit_section_map_updates): Update.
2988 (resume_section_map_updates, resume_section_map_updates_cleanup):
2990 * solib-svr4.c (svr4_handle_solib_event): Update.
2991 * objfiles.c (inhibit_section_map_updates): Return
2992 scoped_restore_tmpl<int>.
2993 (resume_section_map_updates, resume_section_map_updates_cleanup):
2996 2018-06-18 Tom Tromey <tom@tromey.com>
2998 * valprint.h (read_string): Update.
2999 * valprint.c (read_string): Change type of "buffer".
3000 (val_print_string): Update.
3001 * python/py-value.c (valpy_string): Update.
3002 * language.h (struct language_defn) <la_get_string>: Change
3004 (default_get_string, c_get_string): Update.
3005 * language.c (default_get_string): Change type of "buffer".
3006 * guile/scm-value.c (gdbscm_value_to_string): Update.
3007 * c-lang.c (c_get_string): Change type of "buffer".
3009 2018-06-18 Tom Tromey <tom@tromey.com>
3011 * ser-mingw.c (struct pipe_state_destroyer): New.
3012 (pipe_state_up): New typedef.
3013 (cleanup_pipe_state): Remove.
3014 (pipe_windows_open): Use pipe_state_up. Don't release argv.
3016 2018-06-18 Tom Tromey <tom@tromey.com>
3018 * rust-lang.h (rust_yyerror): Don't declare.
3019 * rust-lang.c (rust_language_defn): Update.
3020 * rust-exp.y (yyerror): Now static.
3021 * parse.c (parse_exp_in_context_1): Update.
3022 * p-lang.h (p_yyerror): Don't declare.
3023 * p-lang.c (p_language_defn): Update.
3024 * p-exp.y (yyerror): Now static.
3025 * opencl-lang.c (opencl_language_defn): Update.
3026 * objc-lang.c (objc_language_defn): Update.
3027 * m2-lang.h (m2_yyerror): Don't declare.
3028 * m2-lang.c (m2_language_defn): Update.
3029 * m2-exp.y (yyerror): Now static.
3030 * language.h (struct language_defn) <la_error>: Remove.
3031 * language.c (unk_lang_error): Remove.
3032 (unknown_language_defn, auto_language_defn): Remove.
3033 * go-lang.h (go_yyerror): Don't declare.
3034 * go-lang.c (go_language_defn): Update.
3035 * go-exp.y (yyerror): Now static.
3036 * f-lang.h (f_yyerror): Don't declare.
3037 * f-lang.c (f_language_defn): Update.
3038 * f-exp.y (yyerror): Now static.
3039 * d-lang.h (d_yyerror): Don't declare.
3040 * d-lang.c (d_language_defn): Update.
3041 * d-exp.y (yyerror): Now static.
3042 * c-lang.h (c_yyerror): Don't declare.
3043 * c-lang.c (c_language_defn, cplus_language_defn)
3044 (asm_language_defn, minimal_language_defn): Update.
3045 * c-exp.y (yyerror): Now static.
3046 * ada-lang.h (ada_yyerror): Don't declare.
3047 * ada-lang.c (ada_language_defn): Update.
3048 * ada-exp.y (yyerror): Now static.
3050 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3052 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
3053 (store_sveregs_to_thread): Likewise.
3054 (aarch64_linux_fetch_inferior_registers): Check for SVE.
3055 (aarch64_linux_store_inferior_registers): Likewise.
3056 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
3058 (aarch64_sve_regs_copy_to_regcache): Likewise.
3059 (aarch64_sve_regs_copy_from_regcache): Likewise.
3060 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
3062 (aarch64_sve_regs_copy_to_regcache): Likewise.
3063 (aarch64_sve_regs_copy_from_regcache): Likewise.
3064 (sve_context): Structure from Linux headers.
3065 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
3066 (SVE_SIG_ZREG_SIZE): Likewise.
3067 (SVE_SIG_PREG_SIZE): Likewise.
3068 (SVE_SIG_FFR_SIZE): Likewise.
3069 (SVE_SIG_REGS_OFFSET): Likewise.
3070 (SVE_SIG_ZREGS_OFFSET): Likewise.
3071 (SVE_SIG_ZREG_OFFSET): Likewise.
3072 (SVE_SIG_ZREGS_SIZE): Likewise.
3073 (SVE_SIG_PREGS_OFFSET): Likewise.
3074 (SVE_SIG_PREG_OFFSET): Likewise.
3075 (SVE_SIG_PREGS_SIZE): Likewise.
3076 (SVE_SIG_FFR_OFFSET): Likewise.
3077 (SVE_SIG_REGS_SIZE): Likewise.
3078 (SVE_SIG_CONTEXT_SIZE): Likewise.
3079 (SVE_PT_REGS_MASK): Likewise.
3080 (SVE_PT_REGS_FPSIMD): Likewise.
3081 (SVE_PT_REGS_SVE): Likewise.
3082 (SVE_PT_VL_INHERIT): Likewise.
3083 (SVE_PT_VL_ONEXEC): Likewise.
3084 (SVE_PT_REGS_OFFSET): Likewise.
3085 (SVE_PT_FPSIMD_OFFSET): Likewise.
3086 (SVE_PT_FPSIMD_SIZE): Likewise.
3087 (SVE_PT_SVE_ZREG_SIZE): Likewise.
3088 (SVE_PT_SVE_PREG_SIZE): Likewise.
3089 (SVE_PT_SVE_FFR_SIZE): Likewise.
3090 (SVE_PT_SVE_FPSR_SIZE): Likewise.
3091 (SVE_PT_SVE_FPCR_SIZE): Likewise.
3092 (__SVE_SIG_TO_PT): Likewise.
3093 (SVE_PT_SVE_OFFSET): Likewise.
3094 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
3095 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
3096 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
3097 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
3098 (SVE_PT_SVE_PREG_OFFSET): Likewise.
3099 (SVE_PT_SVE_PREGS_SIZE): Likewise.
3100 (SVE_PT_SVE_FFR_OFFSET): Likewise.
3101 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
3102 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
3103 (SVE_PT_SVE_SIZE): Likewise.
3104 (SVE_PT_SIZE): Likewise.
3105 (HAS_SVE_STATE): New define.
3107 2018-06-18 Alan Hayward <alan.hayward@arm.com>
3109 * nat/aarch64-sve-linux-sigcontext.h: New file.
3110 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
3112 (SVE_VQ_MIN): Likewise.
3113 (SVE_VQ_MAX): Likewise.
3114 (SVE_VL_MIN): Likewise.
3115 (SVE_VL_MAX): Likewise.
3116 (SVE_NUM_ZREGS): Likewise.
3117 (SVE_NUM_PREGS): Likewise.
3118 (sve_vl_valid): Likewise.
3119 (struct user_sve_header): Likewise.
3121 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
3122 Richard Bunt <Richard.Bunt@arm.com>
3124 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
3125 was requested by GDB.
3127 2018-06-15 Tom de Vries <tdevries@suse.de>
3129 * MAINTAINERS (Write After Approval): Add Tom de Vries.
3131 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
3133 * gnulib/update-gnulib.sh: Print expected versions of
3136 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
3138 * arch-utils.c (default_type_align): Use type_length_units.
3139 * gdbtypes.c (type_align): Use type_length_units.
3141 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3143 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
3144 of 'define' command.
3146 2018-06-14 Tom de Vries <tdevries@suse.de>
3149 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
3150 get_no_prettyformat_print_options.
3152 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
3154 * sparc-nat.h: Include target.h.
3155 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
3156 <fetch_registers>: Remove this argument in function call.
3157 <store_registers>: Remove this argument in function call, remove
3159 <low_forget_process>: Call sparc64_forget_process instead of
3160 sparc_forget_process.
3162 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3164 * procfs.c (_initialize_procfs): Use add_inf_child_target.
3165 (procfs_target::make_corefile_notes): Adjust to new
3166 target_read_alloc return type.
3168 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3169 Stephen Roberts <stephen.roberts@arm.com>
3172 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
3173 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
3174 Move should_notify_stop local into more inner scope.
3176 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3177 Stephen Roberts <stephen.roberts@arm.com>
3180 * infrun.c (resume_1): Add call to mark_async_event_handler.
3182 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
3184 * infrun.c (do_target_wait): Change old version of $pc printed.
3186 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
3188 * dwarf2read.c (read_index_from_section): Rename to...
3189 (read_gdb_index_from_section): ... this, update all callers.
3190 (dwarf2_read_index): Rename to...
3191 (dwarf2_read_gdb_index): ... this, update all callers.
3193 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
3195 * gdb/hppa-linux-nat.c
3196 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
3197 hppa_linux_nat_target::fetch_registers.
3199 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3201 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
3202 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
3203 (AARCH64_DWARF_SVE_FFR): Likewise.
3204 (AARCH64_DWARF_SVE_P0): Likewise.
3205 (AARCH64_DWARF_SVE_Z0): Likewise.
3207 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3209 * common/common-regcache.h (raw_compare): New function.
3210 * regcache.c (regcache::raw_compare): Likewise.
3211 * regcache.h (regcache::raw_compare): New declaration.
3213 2018-06-11 Alan Hayward <alan.hayward@arm.com>
3215 * common/common-regcache.h (reg_buffer_common): New structure.
3216 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
3217 (reg_buffer::raw_supply): Likewise.
3218 (reg_buffer::raw_supply_integer): Likewise.
3219 (reg_buffer::raw_supply_zeroed): Likewise.
3220 (reg_buffer::raw_collect): Likewise.
3221 (reg_buffer::raw_collect_integer): Likewise.
3222 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
3223 (reg_buffer::raw_supply): Likewise.
3224 (reg_buffer::raw_supply_integer): Likewise.
3225 (reg_buffer::raw_supply_zeroed): Likewise.
3226 (reg_buffer::raw_collect): Likewise.
3227 (reg_buffer::raw_collect_integer): Likewise.
3229 2018-06-10 Tom Tromey <tom@tromey.com>
3231 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
3232 (class remote_state) <stop_reply_queue>: Now std::vector.
3233 (remote_state::~remote_state)
3234 (remote_target::stop_reply_queue_length): Update.
3235 (struct queue_iter_param, remove_child_of_pending_fork)
3236 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
3237 (check_pending_event_prevents_wildcard_vcont_callback)
3238 (remove_stop_reply_for_inferior)
3239 (remove_stop_reply_of_remote_state)
3240 (remote_notif_remove_once_on_match)
3241 (stop_reply_match_ptid_and_ws)
3242 (remote_kill_child_of_pending_fork): Remove.
3243 (remote_target::remove_new_fork_children)
3244 (remote_target::check_pending_events_prevent_wildcard_vcont)
3245 (remote_target::discard_pending_stop_replies)
3246 (remote_target::discard_pending_stop_replies_in_queue)
3247 (remote_target::remote_notif_remove_queued_reply)
3248 (remote_target::queued_stop_reply)
3249 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
3250 (remote_target::wait, remote_target::kill_new_fork_children)
3251 (remote_target::async): Update.
3253 2018-06-10 Tom Tromey <tom@tromey.com>
3255 * record-full.c (record_full_arch_list_cleanups): Remove.
3256 (record_full_message): Use try/catch.
3257 (record_full_wait_cleanups): Remove.
3258 (record_full_wait_1): Use try/catch.
3259 (record_full_restore): Likewise.
3261 2018-06-10 Tom Tromey <tom@tromey.com>
3263 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
3264 declare VEC. Add constructor.
3265 <in_target_beneath>: Now bool.
3266 (record_full_breakpoints): Now a std::vector, static.
3267 (record_full_sync_record_breakpoints)
3268 (record_full_init_record_breakpoints)
3269 (record_full_target::insert_breakpoint)
3270 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
3272 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
3274 * dwarf2read.c (process_cu_includes): Remove struct keyword.
3275 * serial.c (serial_interface_lookup): Remove struct keyword.
3277 2018-06-10 Tom Tromey <tom@tromey.com>
3279 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
3281 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
3283 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
3285 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
3286 "beneath" as a method.
3287 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
3288 Use "beneath" as a method.
3290 2018-06-10 Tom Tromey <tom@tromey.com>
3292 * tracefile.c (struct trace_file_writer_deleter): New.
3293 <operator()>: Rename from trace_file_writer_xfree.
3294 (trace_file_writer_up): New typedef.
3295 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
3297 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3299 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
3300 <m_registers, m_register_status>: Change type to
3302 * regcache.c (reg_buffer::reg_buffer): Use new instead of
3305 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3307 * common/common-regcache.h (enum register_status): Add
3308 underlying type "signed char".
3309 * regcache.h (reg_buffer) <m_register_status>: Change type to
3311 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
3312 register_status instead of signed char.
3313 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
3314 (reg_buffer::get_register_status): Remove cast.
3315 (readable_regcache::raw_read): Remove cast.
3316 (readable_regcache::cooked_read): Remove cast.
3318 2018-06-09 Tom Tromey <tom@tromey.com>
3320 * source.c (reverse_search_command, forward_search_command): Use
3323 2018-06-09 Tom Tromey <tom@tromey.com>
3325 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
3326 (serial_ops_list): Now static, std::vector.
3327 (serial_interface_lookup, serial_add_interface): Update.
3329 2018-06-09 Tom Tromey <tom@tromey.com>
3331 * dwarf2read.c (process_cu_includes): Update.
3332 (process_full_comp_unit): Update.
3333 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
3336 2018-06-08 Paul Koning <paul_koning@dell.com>
3340 * python/python.c (do_start_initialization):
3341 Avoid call to internal Python API.
3342 (init__gdb_module): New function.
3344 2018-06-08 Gary Benson <gbenson@redhat.com>
3346 * linux-thread-db.c (valprint.h): New include.
3347 (struct check_thread_db_info): New structure.
3348 (check_thread_db_on_load, tdb_testinfo): New static globals.
3349 (check_thread_db, check_thread_db_callback): New functions.
3350 (try_thread_db_load_1): Run integrity checks if requested.
3351 (maintenance_check_libthread_db): New function.
3352 (_initialize_thread_db): Register "maint check libthread-db"
3353 and "maint set/show check-libthread-db".
3354 * NEWS: Mention the above new commands.
3356 2018-06-08 Tom Tromey <tom@tromey.com>
3358 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
3361 2018-06-08 Tom Tromey <tom@tromey.com>
3363 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
3365 2018-06-08 Tom Tromey <tom@tromey.com>
3367 * common/btrace-common.h (struct btrace_data): Add constructor,
3368 destructor, move assignment operator.
3369 <empty, clear, fini>: New methods.
3370 <format>: Initialize.
3371 (btrace_data_init, btrace_data_fini, btrace_data_clear)
3372 (btrace_data_empty): Don't declare.
3373 * common/btrace-common.c (btrace_data_init): Remove.
3374 (btrace_data::fini): Rename from btrace_data_fini.
3375 (btrace_data::empty): Rename from btrace_data_empty.
3376 (btrace_data::clear): Rename from btrace_data_clear. Return
3378 * btrace.h (make_cleanup_btrace_data): Don't declare.
3379 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
3380 (parse_xml_btrace): Update.
3381 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
3382 (maint_btrace_clear_packet_history_cmd): Update.
3384 2018-06-07 Pedro Alves <palves@redhat.com>
3386 * target.h (target_ops) <beneath>: Now a method. All references
3388 (class target_stack): New.
3389 * target.c (g_target_stack): New.
3390 (g_current_top_target): Delete.
3391 (current_top_target): Get the top target out of g_target_stack.
3392 (target_stack::push, target_stack::unpush): New.
3393 (push_target, unpush_target): Reimplement.
3394 (target_is_pushed): Reimplement in terms of g_target_stack.
3395 (target_ops::beneath, target_stack::find_beneath): New.
3397 2018-06-07 Pedro Alves <palves@redhat.com>
3399 * target.h (find_target_beneath): Delete declaration.
3400 * target.c (find_target_beneath): Delete definition.
3401 * aix-thread.c: All callers of find_target_beneath adjusted to
3402 call target_ops::beneath instead.
3403 * bsd-uthread.c: Likewise.
3404 * linux-thread-db.c: Likewise.
3405 * ravenscar-thread.c: Likewise.
3406 * sol-thread.c: Likewise.
3407 * spu-multiarch.c: Likewise.
3409 2018-06-07 Pedro Alves <palves@redhat.com>
3411 * target.h (target_ops) <beneath>: Now a method. All references
3413 (target_ops) <m_beneath>: New.
3414 * target.c (target_ops::beneath): New.
3415 * corelow.c: Adjust all references to target_ops::beneath.
3416 * linux-thread-db.c: Likewise.
3417 * make-target-delegates: Likewise.
3418 * record-btrace.c: Likewise.
3419 * record-full.c: Likewise.
3420 * remote.c: Likewise.
3421 * target.c: Likewise.
3422 * target-delegates.c: Regenerate.
3424 2018-06-07 Pedro Alves <palves@redhat.com>
3426 * target.h (target_stack): Delete.
3427 (current_top_target): Declare function.
3428 * target.c (target_stack): Delete.
3429 (g_current_top_target): New.
3430 (current_top_target): New function.
3431 * auxv.c: Use current_top_target instead of target_stack
3433 * avr-tdep.c: Likewise.
3434 * breakpoint.c: Likewise.
3435 * corefile.c: Likewise.
3436 * elfread.c: Likewise.
3438 * exceptions.c: Likewise.
3439 * frame.c: Likewise.
3440 * gdbarch-selftests.c: Likewise.
3441 * gnu-v3-abi.c: Likewise.
3442 * ia64-tdep.c: Likewise.
3443 * ia64-vms-tdep.c: Likewise.
3444 * infcall.c: Likewise.
3445 * infcmd.c: Likewise.
3446 * infrun.c: Likewise.
3447 * linespec.c: Likewise.
3448 * linux-tdep.c: Likewise.
3449 * minsyms.c: Likewise.
3450 * ppc-linux-nat.c: Likewise.
3451 * ppc-linux-tdep.c: Likewise.
3452 * procfs.c: Likewise.
3453 * regcache.c: Likewise.
3454 * remote.c: Likewise.
3455 * rs6000-tdep.c: Likewise.
3456 * s390-linux-nat.c: Likewise.
3457 * s390-tdep.c: Likewise.
3458 * solib-aix.c: Likewise.
3459 * solib-darwin.c: Likewise.
3460 * solib-dsbt.c: Likewise.
3461 * solib-spu.c: Likewise.
3462 * solib-svr4.c: Likewise.
3463 * solib-target.c: Likewise.
3464 * sparc-tdep.c: Likewise.
3465 * sparc64-tdep.c: Likewise.
3466 * spu-tdep.c: Likewise.
3467 * symfile.c: Likewise.
3468 * symtab.c: Likewise.
3469 * target-descriptions.c: Likewise.
3470 * target-memory.c: Likewise.
3471 * target.c: Likewise.
3472 * target.h: Likewise.
3473 * tracefile-tfile.c: Likewise.
3474 * tracepoint.c: Likewise.
3475 * valops.c: Likewise.
3476 * valprint.c: Likewise.
3477 * value.c: Likewise.
3478 * windows-tdep.c: Likewise.
3479 * mi/mi-main.c: Likewise.
3481 2018-06-07 Tom Tromey <tom@tromey.com>
3483 * valprint.h (build_address_symbolic): Declare.
3484 * printcmd.c (print_address_symbolic): Update.
3485 (build_address_symbolic): Change "name" and "filename" to
3487 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
3489 * defs.h (build_address_symbolic): Remove declaration.
3491 2018-06-07 Alan Hayward <alan.hayward@arm.com>
3493 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
3494 (aarch64_vnv_type): Add function.
3495 (aarch64_pseudo_register_name): Add V regs for SVE.
3496 (aarch64_pseudo_register_type): Likewise.
3497 (aarch64_pseudo_register_reggroup_p): Likewise.
3498 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
3499 (aarch64_pseudo_read_value): Add V regs for SVE.
3500 (aarch64_pseudo_write_2): Use V0 offset for SVE
3501 (aarch64_pseudo_write): Add V regs for SVE.
3502 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
3504 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
3506 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
3507 (sve_vl_from_vq): Likewise.
3509 2018-06-05 Tom Tromey <tom@tromey.com>
3511 * cli/cli-cmds.c (show_version): Update.
3512 * top.c (print_gdb_version): Add "interactive" parameter.
3514 * main.c (captured_main_1): Update.
3515 * top.h (print_gdb_version): Add "interactive" parameter and a
3518 2018-06-05 David Malcolm <dmalcolm@redhat.com>
3520 * common/enum-flags.h: Add trailing semicolon to example in
3523 2018-06-05 Tom Tromey <tom@tromey.com>
3526 * NEWS: Add entry about pager.
3527 * utils.c (pagination_disabled_for_command): New global.
3528 (prompt_for_continue): Allow "c" response to prompt.
3529 (reinitialize_more_filter): Clear
3530 pagination_disabled_for_command.
3531 (fputs_maybe_filtered): Check pagination_disabled_for_command.
3533 2018-06-04 Tom Tromey <tom@tromey.com>
3535 * ada-lang.h (ada_lookup_symbol_list): Update.
3536 * ada-lang.c (resolve_subexp): Update.
3537 (symbols_are_identical_enums): Change type of syms. Remove nsyms
3539 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
3540 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
3541 results parameter to std::vector.
3542 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
3544 * ada-exp.y (block_lookup): Update.
3545 (select_possible_type_sym): Change type of syms. Remove nsyms
3547 (write_var_or_type, write_name_assoc): Update.
3549 2018-06-04 Joel Brobecker <brobecker@adacore.com>
3551 * windows-nat.c (windows_nat_target::xfer_partial): Return
3552 TARGET_XFER_E_IO if we need to delegate to the target beneath
3553 but BENEATH is NULL.
3555 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3557 * Makefile.in (config.status): Add configure.nat as a
3560 2018-06-04 Tom Tromey <tom@tromey.com>
3562 * cp-name-parser.y (cpname_state): Add method declarations.
3563 (HANDLE_QUAL): Update.
3564 (cpname_state::d_grab, cpname_state::fill_comp)
3565 (cpname_state::make_operator, cpname_state::make_dtor)
3566 (cpname_state::make_builtin_type, cpname_state::make_name)
3567 (cpname_state::d_qualify, cpname_state::d_int_type)
3568 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3569 (%union): Move earlier.
3571 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3573 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3575 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3577 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3578 (aarch64_pseudo_write_1): Likewise.
3579 (aarch64_pseudo_read_value): Use helper.
3580 (aarch64_pseudo_write): Likewise.
3582 2018-06-04 Pedro Alves <palves@redhat.com>
3584 * darwin-nat.c (darwin_ops): Delete.
3585 (darwin_attach_pid): Use get_native_target.
3587 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3589 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3590 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3592 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3594 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3595 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3596 (aarch64_gdbarch_init): Check for SVE.
3597 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3599 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3601 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3602 * aarch64-tdep.h (aarch64_read_description): Likewise.
3603 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3604 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3605 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3606 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3607 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3609 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3611 * value.c (value_fetch_lazy_bitfield): New.
3612 (value_fetch_lazy_memory): New.
3613 (value_fetch_lazy_register): New.
3614 (value_fetch_lazy): Factor out to smaller functions.
3616 2018-06-01 Tom Tromey <tom@tromey.com>
3618 * cp-name-parser.y (backslashable, represented): Now const.
3620 2018-06-01 Tom Tromey <tom@tromey.com>
3622 * cp-name-parser.y: Include parser-defs.h.
3623 (parser_fprintf): Remove declaration.
3625 2018-06-01 Tom Tromey <tom@tromey.com>
3627 * cp-name-parser.y: Use %pure-parser, %lex-param, and
3629 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
3630 (global_result): Remove globals.
3631 (struct cpname_state): New.
3632 (yyparse): Don't declare.
3633 (yylex, yyerror): Move declarations after %union.
3634 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
3635 (make_name): Add state parameter.
3637 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
3639 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
3641 (yylex): Add lvalp, state parameters.
3642 (yyerror): Add state parameter.
3643 (cp_demangled_name_to_comp): Update.
3645 2018-06-01 Tom Tromey <tom@tromey.com>
3647 * cp-name-parser.y (parser_fprintf): Declare.
3648 (GDB_YY_REMAP_PREFIX): Define.
3649 Include yy-remap.h. Don't redefine yy* identifiers.
3651 2018-06-01 Tom Tromey <tom@tromey.com>
3653 * python/py-type.c (typy_legacy_template_argument): Update.
3654 * cp-support.h (cp_demangled_name_to_comp): Update.
3655 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
3656 parameter to be a "std::string *".
3659 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
3661 * ada-lex.l: Include "diagnostics.h" instead of
3662 "common/diagnostics.h".
3663 * unittests/environ-selftests.c: Likewise.
3664 * common/diagnostics.h: Moved to ../include.
3666 2018-06-01 Joel Brobecker <brobecker@adacore.com>
3668 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
3669 to language_mode_manual while calling breakpoint_re_set_one.
3671 2018-06-01 Tom Tromey <tom@tromey.com>
3673 * valops.c (value_cast_structs, destructor_name_p): Update.
3674 * symtab.c (gdb_mangle_name): Update.
3675 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
3677 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
3678 (pascal_object_print_value_fields, pascal_object_print_value):
3680 * p-typeprint.c (pascal_type_print_derivation_info): Update.
3681 * linespec.c (find_methods): Update.
3682 * gdbtypes.h (type_name_no_tag): Remove.
3683 (type_name_or_error): Rename from type_name_no_tag_or_error.
3684 * gdbtypes.c (type_name_no_tag): Remove.
3685 (type_name_or_error): Rename from type_name_no_tag_or_error.
3686 (lookup_struct_elt_type, check_typedef): Update.
3687 * expprint.c (print_subexp_standard): Update.
3688 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
3689 * d-namespace.c (d_lookup_nested_symbol): Update.
3690 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
3691 (cp_print_class_member): Update.
3692 * cp-namespace.c (cp_lookup_nested_symbol): Update.
3693 * completer.c (add_struct_fields): Update.
3694 * c-typeprint.c (cp_type_print_derivation_info)
3695 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
3697 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
3698 (ada_prefer_type, ada_is_exception_sym): Update.
3700 2018-06-01 Tom Tromey <tom@tromey.com>
3702 * valops.c (enum_constant_from_type, value_namespace_elt)
3703 (value_maybe_namespace_elt): Update.
3704 * valarith.c (find_size_for_pointer_math): Update.
3705 * target-descriptions.c (make_gdb_type): Update.
3706 * symmisc.c (print_symbol): Update.
3707 * stabsread.c (define_symbol, read_type)
3708 (complain_about_struct_wipeout, add_undefined_type)
3709 (cleanup_undefined_types_1): Update.
3710 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
3711 (rust_range_type_p, val_print_struct, rust_print_struct_def)
3712 (rust_internal_print_type, rust_composite_type)
3713 (rust_evaluate_funcall, rust_evaluate_subexp)
3714 (rust_inclusive_range_type_p): Update.
3715 * python/py-type.c (typy_get_tag): Update.
3716 * p-typeprint.c (pascal_type_print_base): Update.
3717 * mdebugread.c (parse_symbol, parse_type): Update.
3718 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
3720 * guile/scm-type.c (gdbscm_type_tag): Update.
3721 * go-lang.c (sixg_string_p): Update.
3722 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
3724 * gdbtypes.h (struct main_type) <tag_name>: Remove.
3725 (TYPE_TAG_NAME): Remove.
3726 * gdbtypes.c (type_name_no_tag): Simplify.
3727 (check_typedef, check_types_equal, recursive_dump_type)
3728 (copy_type_recursive, arch_composite_type): Update.
3729 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
3730 in summary mode when needed.
3731 * eval.c (evaluate_funcall): Update.
3732 * dwarf2read.c (fixup_go_packaging, read_structure_type)
3733 (process_structure_scope, read_enumeration_type)
3734 (read_namespace_type, read_module_type, determine_prefix): Update.
3735 * cp-support.c (inspect_type): Update.
3736 * coffread.c (process_coff_symbol, decode_base_type): Update.
3737 * c-varobj.c (c_is_path_expr_parent): Update.
3738 * c-typeprint.c (c_type_print_base_struct_union): Update.
3739 (c_type_print_base_1): Update. Print struct/class/union/enum in
3740 summary when using C language.
3741 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
3742 (gen_maybe_namespace_elt): Update.
3743 * ada-lang.c (ada_type_name): Simplify.
3744 (empty_record, ada_template_to_fixed_record_type_1)
3745 (template_to_static_fixed_type)
3746 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
3748 2018-06-01 Tom Tromey <tom@tromey.com>
3750 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
3752 * c-typeprint.c (c_print_type_1): Add "language" parameter.
3753 (c_print_type): Update.
3754 (c_print_type): New overload.
3755 (c_type_print_varspec_prefix, c_type_print_args)
3756 (c_type_print_varspec_suffix, c_print_type_no_offsets)
3757 (c_type_print_base_struct_union, c_type_print_base_1)
3758 (cp_type_print_method_args): Add "language" parameter.
3759 (c_type_print_base): Update.
3760 * c-lang.h (c_print_type): Add new overload.
3762 2018-06-01 Tom Tromey <tom@tromey.com>
3764 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
3765 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
3767 2018-06-01 Alan Hayward <alan.hayward@arm.com>
3769 * aarch64-tdep.c (aarch64_sve_register_names): New const
3771 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
3772 (AARCH64_SVE_Z_REGS_NUM): New define.
3773 (AARCH64_SVE_P_REGS_NUM): Likewise.
3774 (AARCH64_SVE_NUM_REGS): Likewise.
3776 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
3778 * nat/linux-ptrace.h [__alpha__]
3779 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
3782 2018-05-31 Maciej W. Rozycki <macro@mips.com>
3784 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
3785 the endianness selected.
3786 * NEWS: Document `set endian auto' mode operation update.
3788 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3790 * Makefile.in: Add new header.
3791 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
3792 (sve_vl_from_vg): Likewise.
3793 (sve_vq_from_vl): Likewise.
3794 (sve_vl_from_vq): Likewise.
3795 (sve_vq_from_vg): Likewise.
3796 (sve_vg_from_vq): Likewise.
3797 * configure.nat: Add new c file.
3798 * nat/aarch64-sve-linux-ptrace.c: New file.
3799 * nat/aarch64-sve-linux-ptrace.h: New file.
3801 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3803 * aarch64-linux-nat.c (aarch64_linux_read_description):
3805 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
3807 * aarch64-tdep.c (tdesc_aarch64_list): Add.
3808 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
3809 (aarch64_gdbarch_init): Add parmeter zero.
3810 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
3811 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
3812 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
3814 * doc/gdb.texinfo: Describe SVE feature
3815 * features/aarch64-sve.c: New file.
3817 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
3820 * gdbarch.sh (significant_addr_bit): Default to zero when
3821 not set by target architecture.
3822 * gdbarch.c: Re-generated.
3823 * utils.c (address_significant): Update.
3825 2018-05-30 Joel Brobecker <brobecker@adacore.com>
3827 * stack.c (func_command): Remove trailing newline in call to error.
3829 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3831 * regcache.h (regcache_raw_collect): Remove, update callers to
3832 use regcache::raw_collect.
3833 * regcache.c (regcache_raw_collect): Remove.
3835 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3837 * regcache.h (regcache_raw_supply): Remove, update callers to
3838 use detached_regcache::raw_supply.
3839 * regcache.c (regcache_raw_supply): Remove.
3841 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3843 * regcache.h (regcache_cooked_write_part): Remove, update
3844 callers to use regcache::cooked_write_part.
3845 * regcache.c (regcache_cooked_write_part): Remove.
3847 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3849 * regcache.h (regcache_cooked_read_part): Remove, update callers
3850 to use readable_regcache::cooked_read_part.
3851 * regcache.c (regcache_cooked_read_part): Remove.
3853 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3855 * regcache.h (regcache_cooked_read_value): Remove, update
3856 callers to use readable_regcache::cooked_read_value.
3857 * regcache.c (regcache_cooked_read_value): Remove.
3859 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3861 * regcache.h (regcache_cooked_write): Remove, update callers to
3862 use regcache::cooked_write.
3863 * regcache.c (regcache_cooked_write): Remove.
3865 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3867 * regcache.h (regcache_invalidate): Remove, update callers to
3868 use detached_regcache::invalidate instead.
3869 * regcache.c (regcache_invalidate): Remove.
3871 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3873 * regcache.h (regcache_raw_write_part): Remove, update callers
3874 to use regcache::raw_write_part instead.
3875 * regcache.c (regcache_raw_write_part): Remove.
3877 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3879 * regcache.h (regcache_raw_read_part): Remove, update callers to
3880 use readable_regcache::raw_read_part instead.
3881 * regcache.c (regcache_raw_read_part): Remove.
3883 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3885 * regcache.h (regcache_cooked_read): Remove, update callers to
3886 use readable_regcache::cooked_read instead.
3887 * regcache.c (regcache_cooked_read): Remove.
3889 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3891 * regcache.h (regcache_raw_write): Remove, update callers to use
3892 regcache::raw_write instead.
3893 * regcache.c (regcache_raw_write): Remove.
3895 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3897 * regcache.h (regcache_raw_read): Remove, update callers to use
3898 readable_regcache::raw_read instead.
3899 * regcache.c (regcache_raw_read): Remove.
3901 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3903 * regcache.h (regcache_raw_update): Remove, update callers to
3904 use readable_regcache::raw_update instead.
3905 * regcache.c (regcache_raw_update): Remove.
3907 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3909 * regcache.h (regcache_register_status): Remove, update callers
3910 to use reg_buffer::get_register_status directly instead.
3911 * regcache.c (regcache_register_status): Remove.
3913 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3915 * regcache.h (regcache_get_ptid): Remove, update all callers to
3916 call regcache::ptid instead.
3917 * regcache.c (regcache_get_ptid): Remove.
3919 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3921 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
3923 2018-05-30 Pedro Alves <palves@redhat.com>
3925 * common/common-exceptions.h (exception_rethrow): Use
3928 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
3930 * breakpoint.c (print_solib_event, check_status_catch_solib):
3931 Remove struct keyword in range-based for loops.
3932 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
3933 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
3935 * linespec.c (find_superclass_methods, search_minsyms_for_name):
3937 * symfile.c (addr_info_make_relative): Likewise.
3938 * thread.c (value_in_thread_stack_temporaries): Likewise.
3940 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
3943 * valops.c (value_struct_elt_for_reference): Call check_typedef on
3944 aggregate type to get its real type before accessing it.
3946 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
3948 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
3949 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
3950 * coff-pe-read.c (add_pe_forwarded_sym): Replace
3951 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
3952 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
3953 * jit.c (jit_breakpoint_re_set_internal): Likewise.
3954 * printcmd.c (info_address_command): Likewise.
3956 2018-05-29 Tom Tromey <tom@tromey.com>
3958 * windows-nat.c (handle_exception): Update fall-through comment.
3960 2018-05-29 Tom Tromey <tom@tromey.com>
3962 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
3963 (struct program_space) <added_solibs>: Now a std::vector.
3964 * breakpoint.c (print_solib_event): Update.
3965 (check_status_catch_solib): Update.
3966 * progspace.c (clear_program_space_solib_cache): Update.
3967 * solib.c (update_solib_list): Update.
3969 2018-05-29 Tom Tromey <tom@tromey.com>
3971 * python/py-type.c (typy_richcompare): Update.
3972 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
3973 * gdbtypes.h (types_deeply_equal): Return bool.
3974 (types_equal): Likewise.
3975 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
3977 (check_types_equal): Change worklist to std::vector. Return
3979 (struct type_equality_entry): Add constructor.
3980 (compare_maybe_null_strings): Return bool.
3981 (check_types_worklist): Return bool. Change worklist to
3983 (types_deeply_equal): Use std::vector.
3984 (types_equal): Return bool.
3985 (compare_maybe_null_strings): Simplify.
3987 2018-05-29 Tom Tromey <tom@tromey.com>
3989 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
3991 2018-05-29 Tom Tromey <tom@tromey.com>
3993 * objc-lang.h: Don't include cp-support.h.
3994 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
3997 2018-05-27 Tom Tromey <tom@tromey.com>
3999 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
4001 2018-05-25 Tom Tromey <tom@tromey.com>
4003 * value.c (value::location): Initialize.
4005 2018-05-25 Tom Tromey <tom@tromey.com>
4007 * dbxread.c (init_bincl_list): Remove.
4008 (bincl_list): Now a std::vector.
4009 (bincls_allocated, next_bincl): Remove.
4010 (free_bincl_list, do_free_bincl_list_cleanup)
4011 (make_cleanup_free_bincl_list): Remove.
4012 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
4014 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
4015 (struct header_file_location): Add constructor.
4016 (add_bincl_to_list): Remove.
4018 2018-05-25 Tom Tromey <tom@tromey.com>
4020 * tui/tui.c (tui_enable): Update.
4021 * mi/mi-interp.c (mi_interp::init): Update.
4022 * interps.h (class interp) <name>: New method.
4023 <m_name>: Rename from name.
4024 (~scoped_restore_interp): Update.
4025 * interps.c (interp::interp): Update.
4026 (interp_add, interp_set, interp_lookup_existing)
4027 (current_interp_named_p): Update.
4029 2018-05-25 Tom Tromey <tom@tromey.com>
4031 * interps.c (interp_name): Remove.
4032 * mi/mi-interp.c (mi_interp::init): Update.
4033 * interps.h (interp_name): Remove.
4034 (~scoped_restore_interp): Update.
4035 * tui/tui.c (tui_enable): Update.
4037 2018-05-25 Tom Tromey <tom@tromey.com>
4039 * utils.c (fputs_maybe_filtered): Update.
4040 * linespec.c (decode_line_full): Update.
4041 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
4042 (mi_print_breakpoint_for_event, mi_solib_loaded)
4043 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4044 (mi_user_selected_context_changed): Update.
4045 * mi/mi-main.c (mi_execute_command): Update.
4046 * cli/cli-script.c (execute_control_command): Update.
4047 * python/python.c (execute_gdb_command): Update.
4048 * solib.c (info_sharedlibrary_command): Update.
4049 * interps.c (interp_ui_out): Remove.
4050 * interps.h (interp_ui_out): Remove.
4052 2018-05-25 Tom Tromey <tom@tromey.com>
4054 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
4055 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
4056 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
4058 2018-05-25 Tom Tromey <tom@tromey.com>
4060 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
4061 * interps.c (interp_exec): Use scoped_restore.
4063 2018-05-25 Tom Tromey <tom@tromey.com>
4065 * remote.c (remote_target::remote_file_get): Use
4067 (remote_target::remote_file_put): Likewise.
4069 2018-05-25 Tom Tromey <tom@tromey.com>
4071 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
4073 (get_pe_section_index, add_pe_exported_sym): Update.
4074 (read_pe_exported_syms): Use gdb::def_vector.
4076 2018-05-25 Tom Tromey <tom@tromey.com>
4078 * frame.c (remove_prev_frame): Remove.
4079 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
4081 2018-05-25 Maciej W. Rozycki <macro@mips.com>
4083 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
4085 * mips-linux-nat.c (supply_fpregset): Always call
4086 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
4087 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
4088 `mips_fill_fpregset'.
4089 * mips-linux-tdep.c (mips_supply_fpregset)
4090 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
4091 (mips_fill_fpregset_wrapper): Remove functions.
4092 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
4093 (mips_linux_fpregset): Remove variable.
4094 (mips_linux_iterate_over_regset_sections): Use
4095 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
4096 (mips_linux_o32_sigframe_init): Remove comment.
4098 2018-05-25 Pedro Alves <palves@redhat.com>
4100 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
4101 (struct readahead_cache, struct packet_reg, struct
4102 remote_arch_state, class remote_state): Move higher up in the
4104 (remote_target::m_remote_state): Now an object instead of a pointer.
4105 (remote_target::get_remote_state): Adjust.
4107 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4109 * stack.c (select_and_print_frame): Delete.
4110 (struct function_bounds): Move struct within function.
4111 (func_command): Most content moved into new function
4112 find_frame_for_function, use new function, print result, add
4114 (find_frame_for_function): New function, now returns a result.
4116 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4118 * stack.c (iterate_over_block_arg_vars): Fix comment.
4119 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
4121 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
4125 (scoped_restore_selected_frame::scoped_restore_selected_frame):
4127 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
4129 * frame.h (class scoped_restore_selected_frame): New class.
4130 * stack.c (print_frame_local_vars): Remove catching and rethrowing
4131 of any exception, use scoped_restore_selected_frame to restore the
4134 2018-05-24 Pedro Alves <palves@redhat.com>
4136 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
4139 2018-05-23 Tom Tromey <tom@tromey.com>
4141 * complaints.c (struct complaints): Remove.
4142 (symfile_complaint_book): Remove.
4143 (series): New global.
4144 (complaint_internal): Update.
4145 (clear_complaints): Update.
4147 2018-05-23 Tom Tromey <tom@tromey.com>
4149 * complaints.c (counters): New global.
4150 (struct complain): Remove.
4151 (struct complaints) <root>: Remove.
4152 (complaint_sentinel): Remove.
4153 (symfile_complaint_book): Update.
4154 (find_complaint) Remove.
4155 (complaint_internal, clear_complaints): Update.
4157 2018-05-23 Tom Tromey <tom@tromey.com>
4159 * complaints.c (struct complain) <file, line>: Remove.
4160 (find_complaint): Remove file, line parameters.
4161 (complaint_internal): Update.
4163 2018-05-23 Tom Tromey <tom@tromey.com>
4165 * complaints.c (vcomplaint): Remove.
4166 (complaint_internal) Merge in contents of vcomplaint.
4168 2018-05-23 Tom Tromey <tom@tromey.com>
4170 * complaints.c (struct complaints) <explanation>: Remove.
4171 (symfile_explanations): Remove.
4172 (symfile_complaint_book): Update.
4173 (vcomplaint): Update.
4174 (struct explanation): Remove.
4176 2018-05-23 Tom Tromey <tom@tromey.com>
4178 * complaints.c (symfile_complaints): Remove.
4179 (complaint_internal): Remove "complaints" parameter.
4180 (clear_complaints, vcomplaint): Remove "c" parameter.
4181 (get_complaints): Remove.
4182 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
4183 (dwarf2_debug_line_missing_file_complaint)
4184 (dwarf2_debug_line_missing_end_sequence_complaint)
4185 (dwarf2_complex_location_expr_complaint)
4186 (dwarf2_const_value_length_mismatch_complaint)
4187 (dwarf2_section_buffer_overflow_complaint)
4188 (dwarf2_macro_malformed_definition_complaint)
4189 (dwarf2_invalid_attrib_class_complaint)
4190 (create_addrmap_from_index, dw2_symtab_iter_next)
4191 (dw2_expand_marked_cus)
4192 (dw2_debug_names_iterator::find_vec_in_debug_names)
4193 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
4194 (create_debug_type_hash_table, init_cutu_and_read_dies)
4195 (partial_die_parent_scope, add_partial_enumeration)
4196 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
4197 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
4198 (read_import_statement, read_file_scope, create_dwo_cu_reader)
4199 (create_cus_hash_table, create_dwp_hash_table)
4200 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
4201 (dwarf2_rnglists_process, dwarf2_ranges_process)
4202 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
4203 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
4204 (handle_struct_member_die, process_structure_scope)
4205 (read_array_type, read_common_block, read_module_type)
4206 (read_tag_pointer_type, read_typedef, read_base_type)
4207 (read_subrange_type, load_partial_dies, partial_die_info::read)
4208 (partial_die_info::read, partial_die_info::read)
4209 (partial_die_info::read, read_checked_initial_length_and_offset)
4210 (dwarf2_string_attr, read_formatted_entries)
4211 (dwarf_decode_line_header)
4212 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4213 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
4214 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
4215 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
4216 (get_signatured_type, get_DW_AT_signature_type)
4217 (decode_locdesc, file_file_name, consume_improper_spaces)
4218 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
4219 (dwarf_decode_macro_bytes, dwarf_decode_macros)
4220 (dwarf2_symbol_mark_computed, set_die_type)
4221 (read_attribute_value): Update.
4222 * stap-probe.c (handle_stap_probe, get_stap_base_address):
4224 * dbxread.c (unknown_symtype_complaint)
4225 (lbrac_mismatch_complaint, repeated_header_complaint)
4226 (set_namestring, function_outside_compilation_unit_complaint)
4227 (read_dbx_symtab, process_one_symbol): Update.
4228 * gdbtypes.c (stub_noname_complaint): Update.
4229 * windows-nat.c (handle_unload_dll): Update.
4230 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
4231 (decode_base_type): Update.
4232 * xcoffread.c (bf_notfound_complaint, ef_complaint)
4233 (eb_complaint, record_include_begin, record_include_end)
4234 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
4235 (process_xcoff_symbol, read_symbol)
4236 (function_outside_compilation_unit_complaint)
4237 (scan_xcoff_symtab): Update.
4238 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
4239 * buildsym.c (finish_block_internal, make_blockvector)
4240 (end_symtab_get_static_block, augment_type_symtab): Update.
4241 * dtrace-probe.c (dtrace_process_dof)
4242 (dtrace_static_probe_ops::get_probes): Update.
4243 * complaints.h (struct complaint): Don't declare.
4244 (symfile_complaints): Remove.
4245 (complaint_internal): Remove "complaints" parameter.
4246 (complaint): Likewise.
4247 (clear_complaints): Likewise.
4248 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4249 (reread_symbols): Update.
4250 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
4251 (dwarf2_frame_cache, decode_frame_entry): Update.
4252 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
4253 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4254 (info_selectors_command): Update.
4255 * macrotab.c (macro_include, check_for_redefinition)
4256 (macro_undef): Update.
4257 * objfiles.c (filter_overlapping_sections): Update.
4258 * stabsread.c (invalid_cpp_abbrev_complaint)
4259 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
4260 (define_symbol, error_type, read_type, rs6000_builtin_type)
4261 (stabs_method_name_from_physname, read_member_functions)
4262 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
4263 (attach_fields_to_type, complain_about_struct_wipeout)
4264 (read_range_type, read_args, common_block_start)
4265 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
4267 * mdebugread.c (index_complaint, unknown_ext_complaint)
4268 (basic_type_complaint, bad_tag_guess_complaint)
4269 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
4270 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
4271 (parse_procedure, parse_lines)
4272 (function_outside_compilation_unit_complaint)
4273 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
4274 (bad_tag_guess_complaint, reg_value_complaint): Update.
4275 * cp-support.c (demangled_name_complaint): Update.
4276 * macroscope.c (sal_macro_scope): Update.
4277 * dwarf-index-write.c (class debug_names): Update.
4279 2018-05-23 Tom Tromey <tom@tromey.com>
4281 * complaints.c (clear_complaints): Remove "noisy" parameter.
4282 * complaints.h (clear_complaints): Update.
4283 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4284 (reread_symbols): Update.
4286 2018-05-23 Tom Tromey <tom@tromey.com>
4288 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
4290 (vcomplaint, clear_complaints): Update.
4291 (symfile_explanations): Remove some messages.
4293 2018-05-23 Tom Tromey <tom@tromey.com>
4295 * complaints.c (internal_complaint): Remove.
4296 * complaints.h (internal_complaint): Remove.
4298 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4300 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
4302 2018-05-22 Pedro Alves <palves@redhat.com>
4304 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
4305 (remote_fileio_badfd, remote_fileio_return_errno)
4306 (remote_fileio_return_success, remote_fileio_func_open)
4307 (remote_fileio_func_open, remote_fileio_func_close)
4308 (remote_fileio_func_read, remote_fileio_func_write)
4309 (remote_fileio_func_lseek, remote_fileio_func_rename)
4310 (remote_fileio_func_unlink, remote_fileio_func_stat)
4311 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
4312 (remote_fileio_func_isatty, remote_fileio_func_system): Add
4313 remote_target parameter.
4314 (remote_fio_func_map) <func>: Add remote_target parameter.
4315 (do_remote_fileio_request, remote_fileio_request):
4316 * remote-fileio.h (remote_fileio_request):
4317 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
4318 remote_target parameter.
4319 (remote_notif_process, handle_notification): Adjust to pass down
4321 (remote_notif_state_allocate): Add remote_target parameter. Save
4323 * remote-notif.h (struct remote_target): Forward declare.
4324 (struct notif_client) <parse, ack, can_get_pending_events>: Add
4325 remote_target parameter.
4326 (struct remote_notif_state) <remote>: New field.
4327 (remote_notif_ack, remote_notif_parse): Add remote_target
4329 (remote_notif_state_allocate, remote_notif_state_allocate): Add
4330 remote_target parameter.
4331 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
4332 (threads_listing_context, rmt_thread_action, protocol_feature)
4333 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
4334 (packet_result, struct threads_listing_context, remote_state):
4335 Move definitions and declarations higher up.
4336 (remote_target) <~remote_target>: Declare.
4337 (remote_download_command_source, remote_file_put, remote_file_get)
4338 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
4339 (remote_hostio_pread_vFile, remote_hostio_send_command)
4340 (remote_hostio_set_filesystem, remote_hostio_open)
4341 (remote_hostio_close, remote_hostio_unlink, remote_state)
4342 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
4343 (get_memory_write_packet_size, get_memory_read_packet_size)
4344 (append_pending_thread_resumptions, remote_detach_1)
4345 (append_resumption, remote_resume_with_vcont)
4346 (add_current_inferior_and_thread, wait_ns, wait_as)
4347 (process_stop_reply, remote_notice_new_inferior)
4348 (process_initial_stop_replies, remote_add_thread)
4349 (btrace_sync_conf, remote_btrace_maybe_reopen)
4350 (remove_new_fork_children, kill_new_fork_children)
4351 (discard_pending_stop_replies, stop_reply_queue_length)
4352 (check_pending_events_prevent_wildcard_vcont)
4353 (discard_pending_stop_replies_in_queue, stop_reply)
4354 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
4355 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
4356 (remote_interrupt_as, remote_interrupt_ns)
4357 (remote_get_noisy_reply, remote_query_attached)
4358 (remote_add_inferior, remote_current_thread, get_current_thread)
4359 (set_thread, set_general_thread, set_continue_thread)
4360 (set_general_process, write_ptid)
4361 (remote_unpack_thread_info_response, remote_get_threadinfo)
4362 (parse_threadlist_response, remote_get_threadlist)
4363 (remote_threadlist_iterator, remote_get_threads_with_ql)
4364 (remote_get_threads_with_qxfer)
4365 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
4366 (get_offsets, remote_check_symbols, remote_supported_packet)
4367 (remote_query_supported, remote_packet_size)
4368 (remote_serial_quit_handler, remote_detach_pid)
4369 (remote_vcont_probe, remote_resume_with_hc)
4370 (send_interrupt_sequence, interrupt_query)
4371 (remote_notif_get_pending_events, fetch_register_using_p)
4372 (send_g_packet, process_g_packet, fetch_registers_using_g)
4373 (store_register_using_P, store_registers_using_G)
4374 (set_remote_traceframe, check_binary_download)
4375 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
4376 (remote_xfer_live_readonly_partial, remote_read_bytes)
4377 (remote_send_printf, remote_flash_write, readchar)
4378 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
4379 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
4380 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
4381 (extended_remote_disable_randomization, extended_remote_run)
4382 (send_environment_packet, extended_remote_environment_support)
4383 (extended_remote_set_inferior_cwd, remote_write_qxfer)
4384 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
4385 (packet_command): Now methods of ...
4386 (remote_target): ... this class.
4387 (m_remote_state) <remote_target>: New field.
4388 (struct remote_state) <stop_reply_queue,
4389 remote_async_inferior_event_token, wait_forever_enabled_p>: New
4391 (remote_state::remote_state): Allocate stop_reply_queue.
4392 (remote_state): Delete global.
4393 (get_remote_state_raw): Delete.
4394 (remote_target::get_remote_state): Allocate m_remote_state on
4396 (get_current_remote_target): New.
4397 (remote_ops, extended_remote_ops): Delete.
4398 (wait_forever_enabled_p, remote_async_inferior_event_token):
4399 Delete, moved to struct remote_state.
4400 (remote_target::close): Delete self. Destruction bits split to
4402 (remote_target::~remote_target): ... this.
4403 (show_memory_packet_size): Adjust to use
4404 get_current_remote_target.
4405 (struct protocol_feature) <func>: Add remote_target parameter.
4406 All callers adjusted.
4407 (curr_quit_handler_target): New.
4408 (remote_serial_quit_handler): Reimplement.
4409 (remote_target::open_1): Adjust to use get_current_remote_target.
4410 Heap-allocate remote_target/extended_remote_target instances.
4411 (vcont_builder::vcont_builder): Add remote_target parameter, and
4412 save it in m_remote. All callers adjusted.
4413 (vcont_builder::m_remote): New field.
4414 (vcont_builder::restart, vcont_builder::flush)
4415 (vcont_builder::push_action): Use it.
4416 (remote_target::commit_resume): Use it.
4417 (struct queue_iter_param) <remote>: New field.
4418 (remote_target::remove_new_fork_children): Fill in 'remote' field.
4419 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
4420 (check_pending_event_prevents_wildcard_vcont_callback)
4421 (remote_target::check_pending_events_prevent_wildcard_vcont)
4422 (remote_target::discard_pending_stop_replies)
4423 (remote_target::discard_pending_stop_replies_in_queue)
4424 (remote_target::remote_notif_remove_queued_reply): Fill in
4426 (remote_notif_get_pending_events): New.
4427 (remote_target::readchar, remote_target::remote_serial_write):
4428 Save/restore curr_quit_handler_target.
4430 (kill_new_fork_children): Fill in 'remote' field.
4431 (packet_command): Use get_current_remote_target, defer to
4432 remote_target method of same name.
4433 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
4434 parameter, and save it in m_remote. All callers adjusted.
4435 (scoped_remote_fd::release): Use m_remote.
4436 (scoped_remote_fd::m_remote): New field.
4437 (remote_file_put, remote_file_get, remote_file_delete): Use
4438 get_current_remote_target, defer to remote_target method of same
4440 (remote_btrace_reset): Add remote_state paremeter. Update all
4442 (remote_async_inferior_event_handler). Pass down 'data'.
4443 (remote_new_objfile): Use get_current_remote_target.
4444 (remote_target::vcont_r_supported): New.
4445 (set_range_stepping): Use get_current_remote_target and
4446 remote_target::vcont_r_supported.
4447 (_initialize_remote): Don't allocate 'remote_state' and
4448 'stop_reply_queue' globals.
4449 * remote.h (struct remote_target): Forward declare.
4450 (getpkt, putpkt, remote_notif_get_pending_events): Add
4451 'remote_target' parameter.
4453 2018-05-22 Pedro Alves <palves@redhat.com>
4455 * remote.c (vcont_builder): Now a class. Make all data members
4457 (vcont_builder) <vcont_builder, restart, flush, push_action>:
4459 (vcont_builder_restart): Rename to ...
4460 (vcont_builder::restart): ... this.
4461 (vcont_builder_flush): Rename to ...
4462 (vcont_builder::flush): ... this.
4463 (vcont_builder_push_action): Rename to ...
4464 (vcont_builder::push_action): ... this.
4465 (remote_target::commit_resume): Adjust.
4467 2018-05-22 Pedro Alves <palves@redhat.com>
4469 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
4470 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
4471 (get_fixed_memory_packet_size): New.
4472 (get_memory_packet_size): Use it.
4473 (set_memory_packet_size): Don't override the config size with
4474 DEFAULT_MAX_MEMORY_PACKET_SIZE.
4475 (show_memory_packet_size): Use get_fixed_memory_packet_size.
4476 Don't refer to get_memory_packet_size if not connected to a remote
4477 target. Show "(default)" if configured size is 0.
4479 2018-05-22 Pedro Alves <palves@redhat.com>
4481 * remote.c (remote_target::mourn_inferior): Move
4482 discard_pending_stop_replies call here from ...
4483 (_initialize_remote): ... here.
4485 2018-05-22 Pedro Alves <palves@redhat.com>
4487 * remote.c (compare_section_command): Remove set_general_process
4490 2018-05-22 Pedro Alves <palves@redhat.com>
4492 * remote.c (struct packet_reg, struct remote_arch_state):
4493 Move higher up in the file.
4494 (remote_state) <m_arch_states>: Store remote_arch_state values
4495 instead of remote_arch_state pointers.
4496 (remote_state::get_remote_arch_state): Adjust.
4498 2018-05-22 Pedro Alves <palves@redhat.com>
4500 * remote.c: Include <unordered_map>.
4501 (remote_state): Now a class.
4502 (remote_state) <get_remote_arch_state>: Declare method.
4503 <get_remote_arch_state>: New field.
4504 (remote_arch_state) <remote_arch_state>: Declare ctor.
4505 <regs>: Now a unique_ptr.
4506 (remote_gdbarch_data_handle): Delete.
4507 (get_remote_arch_state): Delete.
4508 (remote_state::get_remote_arch_state): New.
4509 (get_remote_state): Adjust to call remote_state's
4510 get_remote_arch_state method.
4511 (init_remote_state): Delete, bits factored out to ...
4512 (remote_arch_state::remote_arch_state): ... this new method.
4513 (get_remote_packet_size, get_memory_packet_size)
4514 (process_g_packet, remote_target::fetch_registers)
4515 (remote_target::prepare_to_store, store_registers_using_G)
4516 (remote_target::store_registers, remote_target::get_trace_status):
4517 Adjust to call remote_state's method.
4518 (_initialize_remote): Remove reference to
4519 remote_gdbarch_data_handle.
4521 2018-05-22 Pedro Alves <palves@redhat.com>
4523 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
4524 pread>: New method declarations.
4525 (remote_target::open_1): Adjust.
4526 (readahead_cache_invalidate): Rename to ...
4527 (readahead_cache::invalidate): ... this, and adjust to be a class
4529 (readahead_cache_invalidate_fd): Rename to ...
4530 (readahead_cache::invalidate_fd): ... this, and adjust to be a
4532 (remote_hostio_pwrite): Adjust.
4533 (remote_hostio_pread_from_cache): Rename to ...
4534 (readahead_cache::pread): ... this, and adjust to be a class
4536 (remote_hostio_close): Adjust.
4538 2018-05-22 Pedro Alves <palves@redhat.com>
4540 * remote.c (remote_hostio_close_cleanup): Delete.
4541 (class scoped_remote_fd): New.
4542 (remote_file_put, remote_file_get): Use it.
4544 2018-05-22 Pedro Alves <palves@redhat.com>
4546 (struct vCont_action_support): Use bool and initialize all fields.
4547 (struct readahead_cache): Initialize all fields.
4548 (remote_state): Use bool and initialize all fields.
4549 (remote_state::remote_state, remote_state::~remote_state): New.
4550 (new_remote_state): Delete.
4551 (_initialize_remote): Use new to allocate remote_state.
4553 2018-05-22 Pedro Alves <palves@redhat.com>
4557 * c-exp.y: Include "c-support.h".
4558 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4559 of tolower. Use c_ident_is_alpha to scan names.
4560 * c-lang.c: Include "c-support.h".
4561 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4562 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4563 * c-support.h: New file, with bits factored out from ...
4564 * cp-name-parser.y: ... this file.
4565 Include "c-support.h".
4566 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4567 c-support.h and renamed.
4568 (symbol_end, yylex): Adjust.
4570 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4572 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4573 parameter type to CORE_ADDR.
4574 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4575 parameter type in declaration to CORE_ADDR.
4576 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4577 target_auxv_search to get AT_HWCAP and use the result to get the
4579 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4580 to CORE_ADDR. Remove the cast of the return value to unsigned
4581 long. Fix error predicate of target_auxv_search.
4582 (ppc_linux_nat_target::read_description): Change the type of the
4583 hwcap variable to CORE_ADDR.
4585 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4587 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4588 if the size of fpscr is larger than 32 bits.
4590 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4592 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4593 (ppc32_linux_vsxregmap): New global.
4594 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4595 regcache_supply_regset, and regcache_collect_regset.
4596 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4597 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4598 (fetch_vsx_register, store_vsx_register): Remove.
4599 (fetch_vsx_registers): Add regno parameter. Get regset using
4600 ppc_linux_vsxregset. Use regset to supply registers.
4601 (store_vsx_registers): Add regno parameter. Get regset using
4602 ppc_linux_vsxregset. Use regset to collect registers.
4603 (fetch_register): Call fetch_vsx_registers instead of
4605 (store_register): Call store_vsx_registers instead of
4607 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4608 new regno parameter.
4609 (store_ppc_registers): Call store_vsx_registers with -1 for the
4610 new regno parameter.
4611 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4612 (ppc_collect_vsxregset): Remove.
4614 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4616 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4618 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4619 for vector register offset fields.
4620 (ppc64_fbsd_reg_offsets): Likewise.
4621 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4622 to vector register offset fields.
4623 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4624 to vector register offset fields.
4625 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
4626 vector register offset fields.
4627 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
4628 initializers for vector register offset fields.
4629 (rs6000_aix64_reg_offsets): Likewise.
4630 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
4631 (ppc_supply_vrregset): Remove.
4632 (ppc_collect_vrregset): Remove.
4633 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
4634 (ppc_linux_vrregset) : New function.
4635 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
4636 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
4637 (ppc32_linux_vrregset): Remove.
4638 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
4639 and use result instead of ppc32_linux_vrregset.
4640 (ppc32_linux_reg_offsets): Remove initializers for vector register
4642 (ppc64_linux_reg_offsets): Likewise.
4643 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
4644 * ppc-linux-nat.c: Include regset.h.
4645 (gdb_vrregset_t): Adjust comment to account for little-endian
4647 (supply_vrregset, fill_vrregset): Remove.
4648 (fetch_altivec_register, store_altivec_register): Remove.
4649 (fetch_altivec_registers): Add regno parameter. Get regset using
4650 ppc_linux_vrregset. Use regset to supply registers.
4651 (store_altivec_registers): Add regno parameter. Get regset using
4652 ppc_linux_vrregset. Use regset to collect registers.
4653 (fetch_register): Call fetch_altivec_registers instead of
4654 fetch_altivec_register.
4655 (store_register): Call store_altivec_registers instead of
4656 store_altivec_register.
4657 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
4658 the new regno parameter.
4659 (store_ppc_registers): Call store_altivec_registers with -1 for
4660 the new regno parameter.
4662 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4664 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
4665 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
4666 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4667 (gdb_vrregset_t): Change array type size to
4668 PPC_LINUX_SIZEOF_VRREGSET.
4669 (gdb_vsxregset_t): Change array type size to
4670 PPC_LINUX_SIZEOF_VSXREGSET.
4671 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
4672 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
4673 PPC_LINUX_SIZEOF_VSXREGSET.
4675 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4677 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
4678 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
4680 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
4681 ppc_linux_target_wordsize with tid.
4682 (ppc_linux_nat_target::read_description): Call ppc_linux_target
4684 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
4685 (ppc64_64bit_inferior_p): Add static and inline specifiers.
4686 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
4687 tid parameter. Remove static specifier.
4688 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
4689 (ppc_linux_target_wordsize): New declaration.
4691 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4693 * arch/ppc-linux-common.c: New file.
4694 * arch/ppc-linux-common.h: New file.
4695 * arch/ppc-linux-tdesc.h: New file.
4696 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
4697 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
4698 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
4699 arch/ppc-linux-tdesc.h.
4700 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
4701 arch/ppc-linux-tdesc.h.
4702 (ppc_linux_nat_target::read_description): Remove target
4703 description matching code. Fill a ppc_linux_features struct and
4704 call ppc_linux_match_description with it. Move comment about ISA
4705 2.05 to ppc-linux-common.c.
4706 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
4707 arch/ppc-linux-tdesc.h.
4708 (ppc_linux_core_read_description): Remove target description
4709 matching code. Fill a ppc_linux_features struct and call
4710 ppc_linux_match_description with it.
4711 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4712 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4713 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4714 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4715 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4716 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4717 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4718 (tdesc_powerpc_e500l): Remove.
4720 2018-05-22 Joel Brobecker <brobecker@adacore.com>
4722 * ada-lang.c (catch_assert_command): Pass empty string instead
4723 of NULL for excep_string argument.
4725 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4727 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
4728 the width of the requested register exceeds the width of the
4731 2018-05-21 Tom Tromey <tom@tromey.com>
4733 * printcmd.c (output_command): Remove.
4734 (output_command_const): Rename to output_command.
4735 * valprint.h (output_command): Rename from output_command_const.
4736 * tracepoint.c (trace_dump_actions): Call output_command.
4738 2018-05-21 Tom Tromey <tom@tromey.com>
4740 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
4741 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
4742 * ada-lang.h (create_ada_exception_catchpoint): Update.
4743 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
4745 (create_excep_cond_exprs, ~ada_catchpoint)
4746 (should_stop_exception, print_one_exception)
4747 (print_mention_exception, print_recreate_exception): Update.
4748 (ada_get_next_arg): Remove.
4749 (catch_ada_exception_command_split): Use std::string. Change type
4750 of "excep_string", "cond_string".
4751 (catch_ada_exception_command): Update.
4752 (create_ada_exception_catchpoint): Change type of excep_string.
4753 (ada_exception_sal): Remove excep_string parameter.
4754 (~ada_catchpoint): Remove.
4756 2018-05-21 Tom Tromey <tom@tromey.com>
4758 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
4761 2018-05-21 Tom Tromey <tom@tromey.com>
4763 * ada-lang.c (ada_exception_message_1, ada_exception_message):
4764 Return unique_xmalloc_ptr.
4765 (print_it_exception): Update.
4767 2018-05-21 Tom Tromey <tom@tromey.com>
4769 * tracepoint.c (trace_dump_actions): Use std::string.
4771 2018-05-21 Tom Tromey <tom@tromey.com>
4773 * symfile.c (reread_symbols): Use std::string for original_name.
4775 2018-05-21 Tom Tromey <tom@tromey.com>
4777 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
4778 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
4781 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
4783 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
4785 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
4786 * objfiles.c (get_objfile_bfd_data): Allocate
4787 objfile_per_bfd_storage with obstack_new when allocating on
4790 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4792 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
4794 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
4795 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
4796 * mdebugread.c (mdebug_build_psymtabs): Likewise.
4797 (add_pending): Likewise.
4798 (parse_symbol): Likewise.
4799 (parse_partial_symbols): Likewise.
4800 (psymtab_to_symtab_1): Likewise.
4801 (new_psymtab): Likewise.
4802 (elfmdebug_build_psymtabs): Likewise.
4803 * minsyms.c (terminate_minimal_symbol_table): Likewise.
4804 * objfiles.c (get_objfile_bfd_data): Likewise.
4805 (objfile_register_static_link): Likewise.
4806 * psymtab.c (allocate_psymtab): Likewise.
4807 * stabsread.c (read_member_functions): Likewise.
4808 * xcoffread.c (xcoff_end_psymtab): Likewise.
4810 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4812 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
4813 compiler supports std::is_trivially_constructible.
4814 * common/poison.h: Include obstack.h.
4815 (IsMallocable): Define to is_trivially_constructible if the
4816 compiler supports it, define to true_type otherwise.
4820 (XOBNEWVEC): Redefine.
4821 * gdb_obstack.h (obstack_zalloc): New.
4822 (OBSTACK_ZALLOC): Redefine.
4823 (obstack_calloc): New.
4824 (OBSTACK_CALLOC): Redefine.
4826 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
4827 (gdbarch_obstack): New declaration in gdbarch.h, definition in
4829 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
4830 obstack_calloc/obstack_zalloc.
4831 (gdbarch_obstack_zalloc): Remove.
4832 * target-descriptions.c (tdesc_data_init): Use obstack_new.
4834 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4836 * stack.c (backtrace_command_1): Remove useless variable int i.
4838 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4840 * stack.c (print_frame_info): Fix comment.
4842 2018-05-18 Tom Tromey <tom@tromey.com>
4844 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
4845 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
4846 (~dwarf2_per_objfile): Update
4847 (dwarf2_get_dwz_file): Use new.
4848 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
4851 2018-05-18 Tom Tromey <tom@tromey.com>
4853 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
4855 * dwarf2read.c (struct dwp_file): Add constructor and
4857 (open_and_init_dwp_file): Return a unique_ptr.
4858 (dwarf2_per_objfile, create_dwp_hash_table)
4859 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
4860 (lookup_dwo_unit_in_dwp): Update.
4861 (open_and_init_dwp_file, get_dwp_file): Update.
4863 2018-05-18 Tom Tromey <tom@tromey.com>
4865 * dwarf2read.c (dwarf2_per_objfile): Update.
4866 (struct mapped_index): Add initializers.
4867 (dwarf2_read_index): Use new.
4868 (dw2_symtab_iter_init): Update.
4869 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
4872 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4874 * dwarf2read.c (mapped_index) <total_size>: Remove.
4876 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4878 * unittests/format_pieces-selftests.c (test_format_specifier):
4881 2018-05-18 Tom Tromey <tom@tromey.com>
4883 * c-typeprint.c (maybe_print_hole): New function.
4884 (c_print_type_struct_field_offset): Update.
4885 (c_type_print_base_struct_union): Call maybe_print_hole.
4887 2018-05-17 Keith Seitz <keiths@redhat.com>
4889 * breakpoint.c (build_bpstat_chain): New function, moved from
4891 (bpstat_stop_status): Add optional parameter, `stop_chain'.
4892 If no stop chain is passed, call build_bpstat_chain to build it.
4893 * breakpoint.h (build_bpstat_chain): Declare.
4894 (bpstat_stop_status): Move documentation here from breakpoint.c.
4895 * infrun.c (handle_signal_stop): Before eliding inlined frames,
4896 build the stop chain and pass it to skip_inline_frames.
4897 Pass this stop chain to bpstat_stop_status.
4898 * inline-frame.c: Include breakpoint.h.
4899 (stopped_by_user_bp_inline_frame): New function.
4900 (skip_inline_frames): Add parameter `stop_chain'.
4901 Move documention to inline-frame.h.
4902 If non-NULL, use stopped_by_user_bp_inline_frame to determine
4903 whether the frame should be elided.
4904 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
4905 Add moved documentation and update for new parameter.
4907 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4910 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4911 unittests/format_pieces-selftests.c.
4912 * common/format.h (format_piece) <operator==>: New.
4913 (format_pieces) <operator[]>: Remove.
4914 * common/format.c (format_pieces::format_pieces): Handle \e.
4915 * unittests/format_pieces-selftests.c: New.
4917 2018-05-17 Tom Tromey <tom@tromey.com>
4920 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
4921 (dw2_instantiate_symtab): Add skip_partial parameter.
4922 (dw2_find_last_source_symtab, dw2_map_expand_apply)
4923 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
4924 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
4925 (dw2_expand_symtabs_matching_one)
4926 (dw2_find_pc_sect_compunit_symtab)
4927 (dw2_debug_names_lookup_symbol)
4928 (dw2_debug_names_expand_symtabs_for_function): Update.
4929 (init_cutu_and_read_dies): Add skip_partial parameter.
4930 (process_psymtab_comp_unit, build_type_psymtabs_1)
4931 (process_skeletonless_type_unit, load_partial_comp_unit)
4932 (psymtab_to_symtab_1): Update.
4933 (load_full_comp_unit): Add skip_partial parameter.
4934 (process_imported_unit_die, dwarf2_read_addr_index)
4935 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
4936 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
4937 (read_signatured_type): Update.
4939 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4941 * value.c (release_value): Remove unused variable.
4942 (record_latest_value): Likewise.
4943 (access_value_history): Likewise.
4944 (preserve_values): Likewise.
4946 2018-05-17 Tom Tromey <tom@tromey.com>
4948 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
4951 2018-05-16 Maciej W. Rozycki <macro@mips.com>
4954 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
4955 Also handle registers whose width is not a multiple of
4957 (linux_nat_trad_target::store_register): Likewise.
4959 2018-05-16 Tom Tromey <tom@tromey.com>
4961 * gdbcore.h (core_bfd): Redefine.
4962 * corelow.c (core_target::close): Update.
4963 (core_target_open): Update.
4964 * progspace.h (struct program_space) <cbfd>: Now a
4967 2018-05-16 Tom Tromey <tom@tromey.com>
4970 * symfile-add-flags.h (enum symfile_add_flags)
4971 <SYMFILE_NOT_FILENAME>: New constant.
4972 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
4973 objfile name from BFD.
4974 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
4975 * minidebug.c (find_separate_debug_file_in_section): Put
4976 ".gnu_debugdata" into BFD's file name.
4978 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
4980 * regcache.c (regcache_read_ftype, regcache_write_ftype):
4983 2018-05-15 Tamar Christina <tamar.christina@arm.com>
4986 * aarch64-tdep.c (aarch64_analyze_prologue,
4987 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
4988 Indicate not interested in errors.
4990 2018-05-15 Maciej W. Rozycki <macro@mips.com>
4992 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
4993 Supply the MIPS_ZERO_REGNUM register.
4995 2018-05-15 Maciej W. Rozycki <macro@mips.com>
4997 * mips-tdep.c (mask_address_var): Make variable static.
4999 2018-05-14 Tom Tromey <tom@tromey.com>
5001 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
5003 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
5005 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
5006 FXSAVE_ADDR for the mxcsr register.
5008 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
5010 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
5012 2018-05-11 Pedro Alves <palves@redhat.com>
5014 * corelow.c (core_target) <core_target>: No longer inline.
5015 Initialize m_core_gdbarch, m_core_vec and build the section table
5017 <~core_target>: New.
5018 <core_gdbarch, get_core_register_section>: New methods.
5019 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
5020 factored out from ...
5021 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
5023 (sniff_core_bfd): Add gdbarch parameter.
5024 (core_close): Delete, merged into ...
5025 (core_target::close): ... here. Delete self.
5026 (core_close_cleanup): Delete.
5027 (core_target_open): Allocate a core_target on the heap. Use a
5028 unique_ptr instead of a cleanup. Bits moved into the core_target
5029 ctor. Adjust to use core_target methods instead of globals.
5030 (get_core_register_section): Rename to ...
5031 (core_target::get_core_register_section): ... this and adjust.
5032 (struct get_core_registers_cb_data): New.
5033 (get_core_registers_cb): Use it. Use bool.
5034 (core_target::fetch_registers, core_target::files_info)
5035 (core_target::xfer_partial, core_target::read_description)
5036 (core_target::pid_to, core_target::thread_name): Adjust to
5037 reference class fields instead of globals.
5038 * target.h (struct target_ops_deleter, target_ops_up): New.
5040 2018-05-11 Pedro Alves <palves@redhat.com>
5042 * corefile.c (core_file_command): Move to corelow.c.
5043 * corelow.c (the_core_target): Delete.
5044 (core_file_command): Moved from corefile.c. Check exec_bfd
5045 instead of the_core_target. Use target_detach instead of calling
5046 into the_core_target directly.
5047 (maybe_say_no_core_file_now): New.
5048 (core_target::detach): Use it.
5049 (_initialize_corelow): Remove references to the_core_target.
5050 * gdbcore.h (the_core_target): Delete.
5052 2018-05-11 Tom Tromey <tromey@redhat.com>
5053 Pedro Alves <palves@redhat.com>
5055 * corefile.c (core_bfd): Remove.
5056 * gdbcore.h (core_bfd): Now a macro.
5057 * progspace.h (struct program_space) <cbfd>: New field.
5059 2018-05-11 Tom Tromey <tom@tromey.com>
5061 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
5064 2018-05-10 Tom Tromey <tom@tromey.com>
5066 * configure: Rebuild.
5067 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
5069 2018-05-10 Joel Brobecker <brobecker@adacore.com>
5072 * regformats/regdat.sh: Adjust script, following the addition
5073 of the new expedite_regs parameter to init_target_desc.
5075 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
5078 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
5079 set_gdbarch_significant_addr_bit.
5080 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
5081 set_gdbarch_significant_addr_bit.
5082 * utils.c (address_significant): Update to sign extend addr.
5084 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
5086 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
5087 (xtensa_linux_init_abi): Limit tdep->num_regs by
5088 tdep->num_nopriv_regs.
5089 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
5090 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
5093 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
5095 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
5097 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
5099 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
5100 (I387_MXCSR_INIT_VAL): New constant.
5101 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
5102 buffer if it was supplied by the inferior.
5103 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
5104 (i387_xsave_get_clear_bv): New function.
5105 (i387_supply_xsave): Only read x87 control registers from the
5106 xsave buffer if the feature is enabled, and the state will have
5107 been written, otherwise, provide a suitable default.
5108 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
5109 including x87 control registers. Update control registers if they
5110 have changed from the default value, and mark features as enabled
5112 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
5114 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
5116 * spu-tdep.c (info_spu_event_command): Fix output formatting.
5118 2018-05-07 Tom Tromey <tom@tromey.com>
5120 * configure: Rebuild.
5121 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
5123 2018-05-07 Tom Tromey <tom@tromey.com>
5126 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
5127 bit. Use correct value for VDIV.
5129 2018-05-04 Tom Tromey <tom@tromey.com>
5131 * configure: Rebuild.
5132 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
5134 2018-05-04 Tom Tromey <tom@tromey.com>
5136 * linux-record.c (record_linux_system_call) <case
5137 RECORD_SYS_RECVFROM>: Add "break".
5139 2018-05-04 Tom Tromey <tom@tromey.com>
5141 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
5142 Add missing "break".
5143 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
5144 Add missing "break".
5146 2018-05-04 Tom Tromey <tom@tromey.com>
5148 * rs6000-tdep.c (ppc_process_record_op4)
5149 (ppc_process_record_op63): Add fall-through comment.
5151 2018-05-04 Tom Tromey <tom@tromey.com>
5153 * i386-tdep.c (i386_process_record): Add fall-through comment.
5155 2018-05-04 Tom Tromey <tom@tromey.com>
5157 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
5160 2018-05-04 Tom Tromey <tom@tromey.com>
5162 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
5163 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
5164 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
5166 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
5168 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
5171 2018-05-04 Tom Tromey <tom@tromey.com>
5173 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
5175 2018-05-04 Tom Tromey <tom@tromey.com>
5177 * s390-tdep.c (s390_process_record): Fix fall-through comments.
5178 * xcoffread.c (scan_xcoff_symtab): Move comment later.
5179 * symfile.c (section_is_mapped): Fix fall-through comment.
5180 * stabsread.c (define_symbol, read_member_functions): Fix
5181 fall-through comment.
5182 * s390-linux-tdep.c (s390_process_record): Fix fall-through
5184 * remote.c (remote_wait_as): Fix fall-through comment.
5185 * p-exp.y (yylex): Fix fall-through comment.
5186 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
5188 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
5189 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
5190 * jv-exp.y (yylex): Fix fall-through comment.
5191 * go-exp.y (lex_one_token): Fix fall-through comment.
5192 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
5193 fall-through comment.
5194 * f-exp.y (yylex): Fix fall-through comment.
5195 * dwarf2read.c (process_die): Fix fall-through comments.
5196 * dbxread.c (process_one_symbol): Fix fall-through comment.
5197 * d-exp.y (lex_one_token): Fix fall-through comment.
5198 * cp-name-parser.y (yylex): Fix fall-through comment.
5199 * coffread.c (coff_symtab_read): Fix fall-through comment.
5200 * c-exp.y (lex_one_token): Fix fall-through comment.
5201 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
5203 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
5206 2018-05-04 Tom Tromey <tom@tromey.com>
5209 * NEWS: Mention gdb.execute change.
5210 * gdbcmd.h (execute_control_command): Don't declare.
5211 * python/python.c (execute_gdb_command): Use read_command_lines_1,
5212 execute_control_commands, execute_control_commands_to_string.
5213 * cli/cli-script.h (execute_control_commands)
5214 (execute_control_commands_to_string): Declare.
5215 (execute_control_command): Add from_tty parameter.
5216 * cli/cli-script.c (execute_control_commands)
5217 (execute_control_commands_to_string): New functions.
5218 (execute_user_command): Use execute_control_commands.
5219 (execute_control_command_1): Add "from_tty" parameter. Update.
5220 (execute_control_command): Likewise.
5222 2018-05-04 Tom Tromey <tom@tromey.com>
5225 * NEWS: Mention that breakpoint commands are writable.
5226 * python/py-breakpoint.c (bppy_set_commands): New function.
5227 (breakpoint_object_getset) <"commands">: Use it.
5229 2018-05-04 Tom Tromey <tom@tromey.com>
5231 * tracepoint.c (actions_command): Update.
5232 * mi/mi-cmd-break.c (mi_command_line_array)
5233 (mi_command_line_array_cnt, mi_command_line_array_ptr)
5234 (mi_read_next_line): Remove.
5235 (mi_cmd_break_commands): Update.
5236 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
5238 * cli/cli-script.c (get_command_line): Update.
5239 (process_next_line): Use function_view. Constify.
5240 (recurse_read_control_structure, read_command_lines)
5241 (read_command_lines_1): Change argument types to function_view.
5242 (do_define_command, document_command): Update.
5243 * breakpoint.h (check_tracepoint_command): Don't declare.
5244 * breakpoint.c (check_tracepoint_command): Remove.
5245 (commands_command_1, create_tracepoint_from_upload): Update.
5247 2018-05-04 Tom Tromey <tom@tromey.com>
5250 * cli/cli-script.h (enum command_control_type) <define_control>:
5252 * cli/cli-script.c (multi_line_command_p): Handle define_control.
5253 (build_command_line, execute_control_command_1)
5254 (process_next_line): Likewise.
5255 (do_define_command): New function, extracted from define_command.
5256 (define_command): Use it.
5258 2018-05-04 Tom Tromey <tom@tromey.com>
5260 * tracepoint.c (actions_command): Update.
5261 * cli/cli-script.h (read_command_lines): Update.
5262 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
5263 (MAX_TMPBUF): Remove define.
5264 (define_command): Use string_printf.
5265 (document_command): Likewise.
5266 * breakpoint.c (commands_command_1): Update.
5268 2018-05-04 Tom Tromey <tom@tromey.com>
5270 * top.c (execute_command): Update.
5271 * cli/cli-script.h (print_command_lines): Now varargs.
5272 * cli/cli-script.c (print_command_lines): Now varargs.
5273 (execute_control_command_1) <case while_control, case if_control>:
5276 2018-05-04 Tom Tromey <tom@tromey.com>
5278 * tracepoint.c (all_tracepoint_actions): Rename from
5279 all_tracepoint_actions_and_cleanup. Change return type.
5280 (actions_command, encode_actions_1, encode_actions)
5281 (trace_dump_actions, tdump_command): Update.
5282 * remote.c (remote_download_command_source): Update.
5283 * python/python.c (gdbpy_eval_from_control_command)
5284 (python_command, python_interactive_command): Update.
5285 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
5286 * guile/guile.c (guile_command)
5287 (gdbscm_eval_from_control_command, guile_command): Update.
5288 * compile/compile.c (compile_code_command)
5289 (compile_print_command, compile_to_object): Update.
5290 * cli/cli-script.h (struct command_lines_deleter): New.
5291 (counted_command_line): New typedef.
5292 (struct command_line): Add constructor, destructor.
5293 <body_list>: Remove.
5294 <body_list_0, body_list_1>: New members.
5295 (command_line_up): Remove typedef.
5296 (read_command_lines, read_command_lines_1, get_command_line):
5298 (copy_command_lines): Don't declare.
5299 * cli/cli-script.c (build_command_line): Use "new".
5300 (get_command_line): Return counted_command_line.
5301 (print_command_lines, execute_user_command)
5302 (execute_control_command_1, while_command, if_command): Update.
5303 (realloc_body_list): Remove.
5304 (process_next_line, recurse_read_control_structure): Update.
5305 (read_command_lines, read_command_lines_1): Return counted_command_line.
5306 (free_command_lines): Use "delete".
5307 (copy_command_lines): Remove.
5308 (define_command, document_command, show_user_1): Update.
5309 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
5310 a counted_command_line.
5311 * breakpoint.h (counted_command_line): Remove typedef.
5312 (breakpoint_set_commands): Update.
5313 * breakpoint.c (check_no_tracepoint_commands)
5314 (validate_commands_for_breakpoint): Update.
5315 (breakpoint_set_commands): Change commands to be a
5316 counted_command_line.
5317 (commands_command_1, update_dprintf_command_list)
5318 (create_tracepoint_from_upload): Update.
5320 2018-05-04 Tom Tromey <tom@tromey.com>
5322 * cli/cli-decode.h (cmd_list_element): New constructor.
5323 (~cmd_list_element): New destructor.
5324 (struct cmd_list_element): Add initializers.
5325 * cli/cli-decode.c (do_add_cmd): Use "new".
5326 (delete_cmd): Use "delete".
5328 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5329 Pedro Alves <palves@redhat.com>
5331 PR breakpoints/19806 and support for PR external/20207.
5332 * NEWS: Mention Aarch64 watchpoint improvements.
5333 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
5334 watchpoints and PR external/20207 watchpoints.
5335 * nat/aarch64-linux-hw-point.c
5336 (kernel_supports_any_contiguous_range): New.
5337 (aarch64_watchpoint_offset): New.
5338 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
5339 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
5340 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
5341 (aarch64_align_watchpoint): New parameters aligned_offset_p and
5342 next_addr_orig_p. Support PR external/20207 watchpoints.
5343 (aarch64_downgrade_regs): New.
5344 (aarch64_dr_state_insert_one_point): New parameters offset and
5346 (aarch64_dr_state_remove_one_point): Likewise.
5347 (aarch64_handle_breakpoint): Update caller.
5348 (aarch64_handle_aligned_watchpoint): Likewise.
5349 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
5351 (aarch64_linux_set_debug_regs): Remove const from state. Call
5352 aarch64_downgrade_regs.
5353 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
5354 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
5355 (DR_CONTROL_MASK): ... this.
5356 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
5357 (unsigned int aarch64_watchpoint_offset): New prototype.
5358 (aarch64_linux_set_debug_regs): Remove const from state.
5359 * utils.c (align_up, align_down): Move to ...
5360 * common/common-utils.c (align_up, align_down): ... here.
5361 * utils.h (align_up, align_down): Move to ...
5362 * common/common-utils.h (align_up, align_down): ... here.
5364 2018-05-04 Joel Brobecker <brobecker@adacore.com>
5366 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
5367 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
5368 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
5369 Re-implement to match the ABI as summarized in GCC's
5370 gcc/config/sparc/sparc.c. All callers updated.
5371 (sparc32_store_arguments): Remove assertion.
5373 2018-05-04 Tom Tromey <tom@tromey.com>
5375 * printcmd.c: Don't include tui.h.
5376 (decode_format): Use skip_spaces.
5378 2018-05-04 Tom Tromey <tom@tromey.com>
5381 * printcmd.c (last_count): New global.
5382 (x_command): Use saved count when repeating.
5384 2018-05-04 Tom Tromey <tom@tromey.com>
5386 * nto-procfs.c (do_closedir_cleanup): Remove.
5387 (procfs_pidlist): Use gdb_dir_up.
5388 * procfs.c (do_closedir_cleanup): Remove.
5389 (proc_update_threads): Use gdb_dir_up.
5390 * common/filestuff.h (struct gdb_dir_deleter): New.
5391 (gdb_dir_up): New typedef.
5393 2018-05-04 Tom Tromey <tom@tromey.com>
5395 * ada-lang.c (print_mention_exception): Use std::string.
5397 2018-05-04 Tom Tromey <tom@tromey.com>
5399 * ada-lang.c (create_excep_cond_exprs): Update.
5400 (ada_exception_catchpoint_cond_string): Use std::string.
5402 2018-05-04 Tom Tromey <tom@tromey.com>
5404 * ada-lang.c (xget_renaming_scope): Return std::string.
5405 (old_renaming_is_invisible): Update.
5407 2018-05-04 Tom Tromey <tom@tromey.com>
5409 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
5410 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
5412 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5414 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
5416 2018-05-04 Tom Tromey <tom@tromey.com>
5418 * remote.c (remote_query_supported_append): Change type.
5419 (remote_check_symbols): Update.
5421 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
5424 * configure.ac: Prepend libpython.
5425 * python/python-config.py: Likewise.
5426 * configure: Regenerate.
5428 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
5430 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
5432 2018-05-03 Pedro Alves <palves@redhat.com>
5435 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
5436 override. Write 'true' instead of '1'.
5437 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
5440 2018-05-02 Pedro Alves <palves@redhat.com>
5442 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
5443 add_inf_child_target.
5444 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
5445 add_inf_child_target.
5446 * aix-thread.c (aix_thread_target_info): New.
5447 (aix_thread_target) <shortname, longname, doc>: Delete.
5449 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
5450 add_inf_child_target.
5451 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
5452 add_inf_child_target.
5453 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
5454 add_inf_child_target.
5455 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
5456 add_inf_child_target.
5457 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
5458 add_inf_child_target.
5459 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
5460 add_inf_child_target.
5461 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
5462 add_inf_child_target.
5463 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
5464 add_inf_child_target.
5465 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
5466 add_inf_child_target.
5467 * bfd-target.c (target_bfd_target_info): New.
5468 (target_bfd) <shortname, longname, doc>: Delete.
5470 * bsd-kvm.c (bsd_kvm_target_info): New.
5471 (bsd_kvm_target) <shortname, longname, doc>: Delete.
5473 (bsd_kvm_target::open): Rename to ...
5474 (bsd_kvm_target_open): ... this. Adjust.
5475 * bsd-uthread.c (bsd_uthread_target_info): New.
5476 (bsd_uthread_target) <shortname, longname, doc>: Delete.
5478 * corefile.c (core_file_command): Adjust.
5479 * corelow.c (core_target_info): New.
5480 (core_target) <shortname, longname, doc>: Delete.
5482 (core_target::open): Rename to ...
5483 (core_target_open): ... this. Adjust.
5484 * ctf.c (ctf_target_info): New.
5485 (ctf_target) <shortname, longname, doc>: Delete.
5487 (ctf_target::open): Rename to ...
5488 (ctf_target_open): ... this.
5489 (_initialize_ctf): Adjust.
5490 * exec.c (exec_target_info): New.
5491 (exec_target) <shortname, longname, doc>: Delete.
5493 (exec_target::open): Rename to ...
5494 (exec_target_open): ... this.
5495 * gdbcore.h (core_target_open): Declare.
5496 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
5497 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
5498 add_inf_child_target.
5499 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
5500 add_inf_child_target.
5501 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
5502 add_inf_child_target.
5503 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
5504 add_inf_child_target.
5505 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
5506 add_inf_child_target.
5507 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
5508 add_inf_child_target.
5509 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
5510 add_inf_child_target.
5511 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
5512 add_inf_child_target.
5513 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
5514 add_inf_child_target.
5515 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
5516 add_inf_child_target.
5517 * inf-child.c (inf_child_target_info): New.
5518 (inf_child_target::info): New.
5519 (inf_child_open_target): Remove 'target' parameter. Use
5520 get_native_target instead.
5521 (inf_child_target::open): Delete.
5522 (add_inf_child_target): New.
5523 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
5526 (add_inf_child_target): Declare.
5527 (inf_child_open_target): Declare.
5528 * linux-thread-db.c (thread_db_target_info): New.
5529 (thread_db_target) <shortname, longname, doc>: Delete.
5531 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
5532 add_inf_child_target.
5533 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
5534 add_inf_child_target.
5535 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
5536 add_inf_child_target.
5537 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
5538 add_inf_child_target.
5539 * make-target-delegates (print_class): Adjust.
5540 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
5541 add_inf_child_target.
5542 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
5543 add_inf_child_target.
5544 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
5545 add_inf_child_target.
5546 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
5547 add_inf_child_target.
5548 * nto-procfs.c (nto_native_target_info): New.
5549 (nto_procfs_target_native) <shortname, longname, doc>:
5552 (nto_procfs_target_info): New.
5553 (nto_procfs_target_procfs) <shortname, longname, doc>:
5556 (init_procfs_targets): Adjust.
5557 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5558 add_inf_child_target.
5559 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5560 add_inf_child_target.
5561 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5562 add_inf_child_target.
5563 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5564 add_inf_child_target.
5565 * ravenscar-thread.c (ravenscar_target_info): New.
5566 (ravenscar_thread_target) <shortname, longname, doc>:
5569 * record-btrace.c (record_btrace_target_info):
5570 (record_btrace_target) <shortname, longname, doc>: Delete.
5572 (record_btrace_target::open): Rename to ...
5573 (record_btrace_target_open): ... this. Adjust.
5574 * record-full.c (record_longname, record_doc): New.
5575 (record_full_base_target) <shortname, longname, doc>: Delete.
5577 (record_full_target_info): New.
5578 (record_full_target): <shortname>: Delete.
5580 (record_full_core_open_1, record_full_open_1): Update comments.
5581 (record_full_base_target::open): Rename to ...
5582 (record_full_open): ... this.
5583 (cmd_record_full_restore): Update.
5584 (_initialize_record_full): Update.
5585 * remote-sim.c (remote_sim_target_info): New.
5586 (gdbsim_target) <shortname, longname, doc>: Delete.
5588 (gdbsim_target::open): Rename to ...
5589 (gdbsim_target_open): ... this.
5590 (_initialize_remote_sim): Adjust.
5591 * remote.c (remote_doc): New.
5592 (remote_target_info): New.
5593 (remote_target) <shortname, longname, doc>: Delete.
5595 (extended_remote_target_info): New.
5596 (extended_remote_target) <shortname, longname, doc>: Delete.
5598 (remote_target::open_1): Make static. Adjust.
5599 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5600 * s390-linux-nat.c (_initialize_s390_nat): Use
5601 add_inf_child_target.
5602 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5603 add_inf_child_target.
5604 * sol-thread.c (thread_db_target_info): New.
5605 (sol_thread_target) <shortname, longname, doc>: Delete.
5607 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5608 add_inf_child_target.
5609 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5610 add_inf_child_target.
5611 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5612 add_inf_child_target.
5613 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5614 add_inf_child_target.
5615 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5616 add_inf_child_target.
5617 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5618 add_inf_child_target.
5619 * spu-linux-nat.c (_initialize_spu_nat): Use
5620 add_inf_child_target.
5621 * spu-multiarch.c (spu_multiarch_target_info): New.
5622 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5624 * target-delegates.c: Regenerate.
5625 * target.c: Include <unordered_map>.
5626 (target_ops_p): Delete.
5627 (DEF_VEC_P(target_ops_p)): Delete.
5628 (target_factories): New.
5629 (test_target_info): New.
5630 (test_target_ops::info): New.
5631 (open_target): Adjust to use target_factories.
5632 (add_target_with_completer): Rename to ...
5633 (add_target): ... this. Change prototype. Register target_info
5634 and open callback in target_factories. Register target_info in
5635 command context instead of target_ops.
5636 (add_target): Delete old implementation.
5637 (add_deprecated_target_alias): Change prototype. Adjust.
5638 (the_native_target): New.
5639 (set_native_target, get_native_target): New.
5640 (find_default_run_target): Use the_native_target.
5641 (find_attach_target, find_run_target): Simplify.
5642 (target_ops::open): Delete.
5643 (dummy_target_info): New.
5644 (dummy_target::shortname, dummy_target::longname)
5645 (dummy_target::doc): Delete.
5646 (dummy_target::info): New.
5647 (debug_target::shortname, debug_target::longname)
5648 (debug_target::doc): Delete.
5649 (debug_target::info): New.
5650 * target.h (struct target_info): New.
5651 (target_ops::~target_ops): Add comment.
5652 (target_ops::info): New.
5653 (target_ops::shortname, target_ops::longname, target_ops::doc): No
5654 longer virtual. Implement in terms of target_info.
5655 (set_native_target, get_native_target): Declare.
5656 (target_open_ftype): New.
5657 (add_target, add_target_with_completer)
5658 (add_deprecated_target_alias): Change prototype.
5659 (test_target) <shortname, longname, doc>: Delete.
5661 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
5662 add_inf_child_target.
5663 * tracefile-tfile.c (tfile_target_info): New.
5664 (tfile_target) <shortname, longname, doc>: Delete.
5666 (tfile_target::open): Rename to ...
5667 (tfile_target_open): ... this.
5668 (_initialize_tracefile_tfile): Adjust.
5669 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
5670 add_inf_child_target.
5671 * windows-nat.c (_initialize_windows_nat): Use
5672 add_inf_child_target.
5673 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
5674 add_inf_child_target.
5676 2018-05-02 Pedro Alves <palves@redhat.com>
5678 * linux-nat.h (linux_nat_target) <low_new_thread,
5679 low_delete_thread, low_new_fork, low_forget_process,
5680 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
5681 New virtual methods.
5682 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5683 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
5684 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
5685 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5686 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
5688 * linux-fork.c (delete_fork): Adjust to call low method.
5689 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
5690 (linux_nat_new_fork, linux_nat_forget_process_hook)
5691 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
5692 (linux_nat_status_is_event):
5693 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
5694 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
5696 (sigtrap_is_event): Rename to ...
5697 (linux_nat_target::low_status_is_event): ... this.
5698 (linux_nat_set_status_is_event): Delete.
5699 (save_stop_reason, linux_nat_wait_1)
5700 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
5702 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5703 (linux_nat_set_new_fork, linux_nat_set_forget_process)
5704 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5705 (linux_nat_set_prepare_to_resume): Delete.
5706 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
5707 low virtual methods.
5708 * amd64-linux-nat.c: Likewise.
5709 * arm-linux-nat.c: Likewise.
5710 * i386-linux-nat.c: Likewise.
5711 * ia64-linux-nat.c: Likewise.
5712 * mips-linux-nat.c: Likewise.
5713 * ppc-linux-nat.c: Likewise.
5714 * s390-linux-nat.c: Likewise.
5715 * sparc64-linux-nat.c: Likewise.
5716 * x86-linux-nat.c: Likewise.
5717 * x86-linux-nat.h: Include "nat/x86-linux.h".
5718 (x86_linux_nat_target) <low_new_fork, low_forget_process,
5719 low_prepare_to_resume, low_new_thread, low_delete_thread>:
5722 2018-05-02 Pedro Alves <palves@redhat.com>
5724 * target.h (target_ops)
5725 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5726 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
5727 stopped_by_watchpoint, have_continuable_watchpoint,
5728 stopped_data_address, watchpoint_addr_within_range,
5729 can_accel_watchpoint_condition, can_run, thread_alive,
5730 has_all_memory, has_memory, has_stack, has_registers,
5731 has_execution, can_async_p, is_async_p, supports_non_stop,
5732 always_non_stop_p, can_execute_reverse, supports_multi_process,
5733 supports_enable_disable_tracepoint,
5734 supports_disable_randomization, supports_string_tracing,
5735 supports_evaluation_of_breakpoint_conditions,
5736 can_run_breakpoint_commands, filesystem_is_local,
5737 can_download_tracepoint, get_trace_state_variable_value,
5738 set_trace_notes, get_tib_address, use_agent, can_use_agent,
5739 record_is_replaying, record_will_replay,
5740 augmented_libraries_svr4_read>: Adjust to return bool.
5741 * aarch64-linux-nat.c: All implementations adjusted.
5742 * aix-thread.c: All implementations adjusted.
5743 * arm-linux-nat.c: All implementations adjusted.
5744 * breakpoint.c: All implementations adjusted.
5745 * bsd-kvm.c: All implementations adjusted.
5746 * bsd-uthread.c: All implementations adjusted.
5747 * corelow.c: All implementations adjusted.
5748 * ctf.c: All implementations adjusted.
5749 * darwin-nat.c: All implementations adjusted.
5750 * darwin-nat.h: All implementations adjusted.
5751 * exec.c: All implementations adjusted.
5752 * fbsd-nat.c: All implementations adjusted.
5753 * fbsd-nat.h: All implementations adjusted.
5754 * gnu-nat.c: All implementations adjusted.
5755 * gnu-nat.h: All implementations adjusted.
5756 * go32-nat.c: All implementations adjusted.
5757 * ia64-linux-nat.c: All implementations adjusted.
5758 * inf-child.c: All implementations adjusted.
5759 * inf-child.h: All implementations adjusted.
5760 * inf-ptrace.c: All implementations adjusted.
5761 * inf-ptrace.h: All implementations adjusted.
5762 * linux-nat.c: All implementations adjusted.
5763 * linux-nat.h: All implementations adjusted.
5764 * mips-linux-nat.c: All implementations adjusted.
5765 * nto-procfs.c: All implementations adjusted.
5766 * ppc-linux-nat.c: All implementations adjusted.
5767 * procfs.c: All implementations adjusted.
5768 * ravenscar-thread.c: All implementations adjusted.
5769 * record-btrace.c: All implementations adjusted.
5770 * record-full.c: All implementations adjusted.
5771 * remote-sim.c: All implementations adjusted.
5772 * remote.c: All implementations adjusted.
5773 * s390-linux-nat.c: All implementations adjusted.
5774 * sol-thread.c: All implementations adjusted.
5775 * spu-multiarch.c: All implementations adjusted.
5776 * target-delegates.c: All implementations adjusted.
5777 * target.c: All implementations adjusted.
5778 * target.h: All implementations adjusted.
5779 * tracefile-tfile.c: All implementations adjusted.
5780 * tracefile.c: All implementations adjusted.
5781 * tracefile.h: All implementations adjusted.
5782 * windows-nat.c: All implementations adjusted.
5783 * x86-linux-nat.h: All implementations adjusted.
5784 * x86-nat.h: All implementations adjusted.
5786 2018-05-02 Pedro Alves <palves@redhat.com>
5788 * make-target-delegates (scan_target_h): Don't trim lines here.
5789 Replace sequences of tabs and/or whitespace with a single
5791 (top level, parsing methods): Trim each line before processing it
5794 2018-05-02 Pedro Alves <palves@redhat.com>
5795 John Baldwin <jhb@freebsd.org>
5797 * target.h (enum strata) <debug_stratum>: New.
5798 (struct target_ops) <all delegation methods>: Replace by C++
5799 virtual methods, and drop "to_" prefix. All references updated
5801 <to_shortname, to_longname, to_doc, to_data,
5802 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
5803 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
5804 virtual methods. All references updated throughout.
5805 <can_attach, supports_terminal_ours, can_create_inferior,
5806 get_thread_control_capabilities, attach_no_wait>: New
5808 <insert_breakpoint, remove_breakpoint>: Now
5809 TARGET_DEFAULT_NORETURN methods.
5810 <info_proc>: Now returns bool.
5812 (OPS_MAGIC): Delete.
5813 (current_target): Delete. All references replaced by references
5815 (target_stack): ... this. New.
5816 (target_shortname, target_longname): Adjust.
5817 (target_can_run): Now a function declaration.
5818 (default_child_has_all_memory, default_child_has_memory)
5819 (default_child_has_stack, default_child_has_registers)
5820 (default_child_has_execution): Remove target_ops parameter.
5821 (complete_target_initialization): Delete.
5822 (memory_breakpoint_target): New template class.
5823 (test_target_ops): Refactor as a C++ class with virtual methods.
5824 * make-target-delegates (NAME_PART): Tighten.
5825 (POINTER_PART, CP_SYMBOL): New.
5826 (SIMPLE_RETURN_PART): Reimplement.
5827 (VEC_RETURN_PART): Expect less.
5828 (RETURN_PART, VIRTUAL_PART): New.
5829 (METHOD): Adjust to C++ virtual methods.
5830 (scan_target_h): Remove reference to C99.
5831 (dname): Output "target_ops::" prefix.
5832 (write_function_header): Adjust to output a C++ class method.
5833 (write_declaration): New.
5834 (write_delegator): Adjust to output a C++ class method.
5835 (tdname): Output "dummy_target::" prefix.
5836 (write_tdefault, write_debugmethod): Adjust to output a C++ class
5838 (tdefault_names, debug_names): Delete.
5839 (return_types, tdefaults, styles, argtypes_array): New.
5840 (top level): All methods are delegators.
5842 (top level): Print dummy_target and debug_target classes.
5843 * target-delegates.c: Regenerate.
5844 * target-debug.h (target_debug_print_enum_info_proc_what)
5845 (target_debug_print_thread_control_capabilities)
5846 (target_debug_print_thread_info_p): New.
5847 * target.c (dummy_target): Delete.
5848 (the_dummy_target, the_debug_target): New.
5849 (target_stack): Now extern.
5850 (set_targetdebug): Push/unpush debug target.
5851 (default_child_has_all_memory, default_child_has_memory)
5852 (default_child_has_stack, default_child_has_registers)
5853 (default_child_has_execution): Remove target_ops parameter.
5854 (complete_target_initialization): Delete.
5855 (add_target_with_completer): No longer call
5856 complete_target_initialization.
5857 (target_supports_terminal_ours): Use regular delegation.
5858 (update_current_target): Delete.
5859 (push_target): No longer check magic number. Don't call
5860 update_current_target.
5861 (unpush_target): Don't call update_current_target.
5862 (target_is_pushed): No longer check magic number.
5863 (target_require_runnable): Skip for all stratums over
5865 (target_ops::info_proc): New.
5866 (target_info_proc): Use find_target_at and
5867 find_default_run_target.
5868 (target_supports_disable_randomization): Use regular delegation.
5869 (target_get_osdata): Use find_target_at.
5870 (target_ops::open, target_ops::close, target_ops::can_attach)
5871 (target_ops::attach, target_ops::can_create_inferior)
5872 (target_ops::create_inferior, target_ops::can_run)
5873 (target_can_run): New.
5874 (default_fileio_target): Use regular delegation.
5875 (target_ops::fileio_open, target_ops::fileio_pwrite)
5876 (target_ops::fileio_pread, target_ops::fileio_fstat)
5877 (target_ops::fileio_close, target_ops::fileio_unlink)
5878 (target_ops::fileio_readlink): New.
5879 (target_fileio_open_1, target_fileio_unlink)
5880 (target_fileio_readlink): Always call the target method. Handle
5882 (return_zero, return_zero_has_execution): Delete.
5883 (init_dummy_target): Delete.
5884 (dummy_target::dummy_target, dummy_target::shortname)
5885 (dummy_target::longname, dummy_target::doc)
5886 (debug_target::debug_target, debug_target::shortname)
5887 (debug_target::longname, debug_target::doc): New.
5888 (target_supports_delete_record): Use regular delegation.
5889 (setup_target_debug): Delete.
5890 (maintenance_print_target_stack): Skip debug_stratum.
5891 (initialize_targets): Instantiate the_dummy_target and
5893 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
5895 (target_auxv_search, fprint_target_auxv): Adjust.
5896 (info_auxv_command): Adjust to use target_stack.
5897 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
5898 * exceptions.c (print_flush): Handle a NULL target_stack.
5899 * regcache.c (target_ops_no_register): Refactor as class with
5902 * exec.c (exec_target): New class.
5903 (exec_ops): Now an exec_target.
5904 (exec_open, exec_close_1, exec_get_section_table)
5905 (exec_xfer_partial, exec_files_info, exec_has_memory)
5906 (exec_make_note_section): Refactor as exec_target methods.
5907 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
5909 (exec_target::find_memory_regions): New.
5910 (_initialize_exec): Don't call init_exec_ops.
5911 * gdbcore.h (exec_file_clear): Delete.
5913 * corefile.c (core_target): Delete.
5914 (core_file_command): Adjust.
5915 * corelow.c (core_target): New class.
5916 (the_core_target): New.
5917 (core_close): Remove target_ops parameter.
5918 (core_close_cleanup): Adjust.
5919 (core_target::close): New.
5920 (core_open, core_detach, get_core_registers, core_files_info)
5921 (core_xfer_partial, core_thread_alive, core_read_description)
5922 (core_pid_to_str, core_thread_name, core_has_memory)
5923 (core_has_stack, core_has_registers, core_info_proc): Rework as
5924 core_target methods.
5925 (ignore, core_remove_breakpoint, init_core_ops): Delete.
5926 (_initialize_corelow): Initialize the_core_target.
5927 * gdbcore.h (core_target): Delete.
5928 (the_core_target): New.
5930 * ctf.c: (ctf_target): New class.
5931 (ctf_ops): Now a ctf_target.
5932 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
5933 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
5934 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
5936 (init_ctf_ops): Delete.
5937 (_initialize_ctf): Don't call it.
5938 * tracefile-tfile.c (tfile_target): New class.
5939 (tfile_ops): Now a tfile_target.
5940 (tfile_open, tfile_close, tfile_files_info)
5941 (tfile_get_tracepoint_status, tfile_trace_find)
5942 (tfile_fetch_registers, tfile_xfer_partial)
5943 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
5944 Refactor as tfile_target methods.
5945 (tfile_xfer_partial_features): Remove target_ops parameter.
5946 (init_tfile_ops): Delete.
5947 (_initialize_tracefile_tfile): Don't call it.
5948 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
5949 (tracefile_has_stack, tracefile_has_registers)
5950 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
5951 tracefile_target methods.
5952 (init_tracefile_ops): Delete.
5953 (tracefile_target::tracefile_target): New.
5954 * tracefile.h: Include "target.h".
5955 (tracefile_target): New class.
5956 (init_tracefile_ops): Delete.
5958 * spu-multiarch.c (spu_multiarch_target): New class.
5959 (spu_ops): Now a spu_multiarch_target.
5960 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
5961 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
5962 (spu_search_memory, spu_mourn_inferior): Refactor as
5963 spu_multiarch_target methods.
5964 (init_spu_ops): Delete.
5965 (_initialize_spu_multiarch): Remove references to init_spu_ops,
5966 complete_target_initialization.
5968 * ravenscar-thread.c (ravenscar_thread_target): New class.
5969 (ravenscar_ops): Now a ravenscar_thread_target.
5970 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
5971 (ravenscar_thread_alive, ravenscar_pid_to_str)
5972 (ravenscar_fetch_registers, ravenscar_store_registers)
5973 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
5974 (ravenscar_stopped_by_hw_breakpoint)
5975 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
5976 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
5977 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
5979 (init_ravenscar_thread_ops): Delete.
5980 (_initialize_ravenscar): Remove references to
5981 init_ravenscar_thread_ops and complete_target_initialization.
5983 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
5984 (bsd_uthread_target): New class.
5985 (bsd_uthread_ops): Now a bsd_uthread_target.
5986 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
5987 (bsd_uthread_close, bsd_uthread_mourn_inferior)
5988 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
5989 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
5990 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
5991 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
5992 (bsd_uthread_target): Delete function.
5993 (_initialize_bsd_uthread): Remove reference to
5994 complete_target_initialization.
5996 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
5997 (target_bfd): ... this new class.
5998 (target_bfd_xfer_partial, target_bfd_get_section_table)
5999 (target_bfd_close): Refactor as target_bfd methods.
6000 (target_bfd::~target_bfd): New.
6001 (target_bfd_reopen): Adjust.
6002 (target_bfd::close): New.
6004 * record-btrace.c (record_btrace_target): New class.
6005 (record_btrace_ops): Now a record_btrace_target.
6006 (record_btrace_open, record_btrace_stop_recording)
6007 (record_btrace_disconnect, record_btrace_close)
6008 (record_btrace_async, record_btrace_info)
6009 (record_btrace_insn_history, record_btrace_insn_history_range)
6010 (record_btrace_insn_history_from, record_btrace_call_history)
6011 (record_btrace_call_history_range)
6012 (record_btrace_call_history_from, record_btrace_record_method)
6013 (record_btrace_is_replaying, record_btrace_will_replay)
6014 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
6015 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
6016 (record_btrace_store_registers, record_btrace_prepare_to_store)
6017 (record_btrace_to_get_unwinder)
6018 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
6019 (record_btrace_commit_resume, record_btrace_wait)
6020 (record_btrace_stop, record_btrace_can_execute_reverse)
6021 (record_btrace_stopped_by_sw_breakpoint)
6022 (record_btrace_supports_stopped_by_sw_breakpoint)
6023 (record_btrace_stopped_by_hw_breakpoint)
6024 (record_btrace_supports_stopped_by_hw_breakpoint)
6025 (record_btrace_update_thread_list, record_btrace_thread_alive)
6026 (record_btrace_goto_begin, record_btrace_goto_end)
6027 (record_btrace_goto, record_btrace_stop_replaying_all)
6028 (record_btrace_execution_direction)
6029 (record_btrace_prepare_to_generate_core)
6030 (record_btrace_done_generating_core): Refactor as
6031 record_btrace_target methods.
6032 (init_record_btrace_ops): Delete.
6033 (_initialize_record_btrace): Remove reference to
6034 init_record_btrace_ops.
6035 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
6036 the execution_direction global.
6037 (record_full_base_target, record_full_target)
6038 (record_full_core_target): New classes.
6039 (record_full_ops): Now a record_full_target.
6040 (record_full_core_ops): Now a record_full_core_target.
6041 (record_full_target::detach, record_full_target::disconnect)
6042 (record_full_core_target::disconnect)
6043 (record_full_target::mourn_inferior, record_full_target::kill):
6045 (record_full_open, record_full_close, record_full_async): Refactor
6046 as methods of the record_full_base_target class.
6047 (record_full_resume, record_full_commit_resume): Refactor
6048 as methods of the record_full_target class.
6049 (record_full_wait, record_full_stopped_by_watchpoint)
6050 (record_full_stopped_data_address)
6051 (record_full_stopped_by_sw_breakpoint)
6052 (record_full_supports_stopped_by_sw_breakpoint)
6053 (record_full_stopped_by_hw_breakpoint)
6054 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
6055 methods of the record_full_base_target class.
6056 (record_full_store_registers, record_full_xfer_partial)
6057 (record_full_insert_breakpoint, record_full_remove_breakpoint):
6058 Refactor as methods of the record_full_target class.
6059 (record_full_can_execute_reverse, record_full_get_bookmark)
6060 (record_full_goto_bookmark, record_full_execution_direction)
6061 (record_full_record_method, record_full_info, record_full_delete)
6062 (record_full_is_replaying, record_full_will_replay)
6063 (record_full_goto_begin, record_full_goto_end, record_full_goto)
6064 (record_full_stop_replaying): Refactor as methods of the
6065 record_full_base_target class.
6066 (record_full_core_resume, record_full_core_kill)
6067 (record_full_core_fetch_registers)
6068 (record_full_core_prepare_to_store)
6069 (record_full_core_store_registers, record_full_core_xfer_partial)
6070 (record_full_core_insert_breakpoint)
6071 (record_full_core_remove_breakpoint)
6072 (record_full_core_has_execution): Refactor
6073 as methods of the record_full_core_target class.
6074 (record_full_base_target::supports_delete_record): New.
6075 (init_record_full_ops): Delete.
6076 (init_record_full_core_ops): Delete.
6077 (record_full_save): Refactor as method of the
6078 record_full_base_target class.
6079 (_initialize_record_full): Remove references to
6080 init_record_full_ops and init_record_full_core_ops.
6082 * remote.c (remote_target, extended_remote_target): New classes.
6083 (remote_ops): Now a remote_target.
6084 (extended_remote_ops): Now an extended_remote_target.
6085 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
6086 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
6087 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
6088 (remote_pass_signals, remote_set_syscall_catchpoint)
6089 (remote_program_signals, )
6090 (remote_thread_always_alive): Remove target_ops parameter.
6091 (remote_thread_alive, remote_thread_name)
6092 (remote_update_thread_list, remote_threads_extra_info)
6093 (remote_static_tracepoint_marker_at)
6094 (remote_static_tracepoint_markers_by_strid)
6095 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
6096 (remote_open): Refactor as methods of remote_target.
6097 (extended_remote_open, extended_remote_detach)
6098 (extended_remote_attach, extended_remote_post_attach):
6099 (extended_remote_supports_disable_randomization)
6100 (extended_remote_create_inferior): : Refactor as method of
6101 extended_remote_target.
6102 (remote_set_permissions, remote_open_1, remote_detach)
6103 (remote_follow_fork, remote_follow_exec, remote_disconnect)
6104 (remote_resume, remote_commit_resume, remote_stop)
6105 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
6106 (remote_terminal_ours, remote_wait, remote_fetch_registers)
6107 (remote_prepare_to_store, remote_store_registers)
6108 (remote_flash_erase, remote_flash_done, remote_files_info)
6109 (remote_kill, remote_mourn, remote_insert_breakpoint)
6110 (remote_remove_breakpoint, remote_insert_watchpoint)
6111 (remote_watchpoint_addr_within_range)
6112 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
6113 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
6114 (remote_supports_stopped_by_sw_breakpoint)
6115 (remote_stopped_by_hw_breakpoint)
6116 (remote_supports_stopped_by_hw_breakpoint)
6117 (remote_stopped_by_watchpoint, remote_stopped_data_address)
6118 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
6119 (remote_verify_memory): Refactor as methods of remote_target.
6120 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
6122 (remote_xfer_partial, remote_get_memory_xfer_limit)
6123 (remote_search_memory, remote_rcmd, remote_memory_map)
6124 (remote_pid_to_str, remote_get_thread_local_address)
6125 (remote_get_tib_address, remote_read_description): Refactor as
6126 methods of remote_target.
6127 (remote_target::fileio_open, remote_target::fileio_pwrite)
6128 (remote_target::fileio_pread, remote_target::fileio_close): New.
6129 (remote_hostio_readlink, remote_hostio_fstat)
6130 (remote_filesystem_is_local, remote_can_execute_reverse)
6131 (remote_supports_non_stop, remote_supports_disable_randomization)
6132 (remote_supports_multi_process, remote_supports_cond_breakpoints)
6133 (remote_supports_enable_disable_tracepoint)
6134 (remote_supports_string_tracing)
6135 (remote_can_run_breakpoint_commands, remote_trace_init)
6136 (remote_download_tracepoint, remote_can_download_tracepoint)
6137 (remote_download_trace_state_variable, remote_enable_tracepoint)
6138 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
6139 (remote_trace_start, remote_get_trace_status)
6140 (remote_get_tracepoint_status, remote_trace_stop)
6141 (remote_trace_find, remote_get_trace_state_variable_value)
6142 (remote_save_trace_data, remote_get_raw_trace_data)
6143 (remote_set_disconnected_tracing, remote_core_of_thread)
6144 (remote_set_circular_trace_buffer, remote_traceframe_info)
6145 (remote_get_min_fast_tracepoint_insn_len)
6146 (remote_set_trace_buffer_size, remote_set_trace_notes)
6147 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
6148 (remote_disable_btrace, remote_teardown_btrace)
6149 (remote_read_btrace, remote_btrace_conf)
6150 (remote_augmented_libraries_svr4_read, remote_load)
6151 (remote_pid_to_exec_file, remote_can_do_single_step)
6152 (remote_execution_direction, remote_thread_handle_to_thread_info):
6153 Refactor as methods of remote_target.
6154 (init_remote_ops, init_extended_remote_ops): Delete.
6155 (remote_can_async_p, remote_is_async_p, remote_async)
6156 (remote_thread_events, remote_upload_tracepoints)
6157 (remote_upload_trace_state_variables): Refactor as methods of
6159 (_initialize_remote): Remove references to init_remote_ops and
6160 init_extended_remote_ops.
6162 * remote-sim.c (gdbsim_target): New class.
6163 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
6164 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
6165 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
6166 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
6167 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
6168 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
6169 Refactor as methods of gdbsim_target.
6170 (gdbsim_ops): Now a gdbsim_target.
6171 (init_gdbsim_ops): Delete.
6172 (gdbsim_cntrl_c): Adjust.
6173 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
6175 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
6176 (the_amd64_linux_nat_target): New.
6177 (amd64_linux_fetch_inferior_registers)
6178 (amd64_linux_store_inferior_registers): Refactor as methods of
6179 amd64_linux_nat_target.
6180 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
6181 * i386-linux-nat.c: Don't include "linux-nat.h".
6182 (i386_linux_nat_target): New class.
6183 (the_i386_linux_nat_target): New.
6184 (i386_linux_fetch_inferior_registers)
6185 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
6186 as methods of i386_linux_nat_target.
6187 (_initialize_i386_linux_nat): Adjust. Set linux_target.
6188 * inf-child.c (inf_child_ops): Delete.
6189 (inf_child_fetch_inferior_registers)
6190 (inf_child_store_inferior_registers): Delete.
6191 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
6192 methods of inf_child_target.
6193 (inf_child_target::supports_terminal_ours)
6194 (inf_child_target::terminal_init)
6195 (inf_child_target::terminal_inferior)
6196 (inf_child_target::terminal_ours_for_output)
6197 (inf_child_target::terminal_ours, inf_child_target::interrupt)
6198 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
6200 (inf_child_open, inf_child_disconnect, inf_child_close)
6201 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
6202 (inf_child_post_startup_inferior, inf_child_can_run)
6203 (inf_child_pid_to_exec_file): Refactor as methods of
6205 (inf_child_follow_fork): Delete.
6206 (inf_child_target::can_create_inferior)
6207 (inf_child_target::can_attach): New.
6208 (inf_child_target::has_all_memory, inf_child_target::has_memory)
6209 (inf_child_target::has_stack, inf_child_target::has_registers)
6210 (inf_child_target::has_execution): New.
6211 (inf_child_fileio_open, inf_child_fileio_pwrite)
6212 (inf_child_fileio_pread, inf_child_fileio_fstat)
6213 (inf_child_fileio_close, inf_child_fileio_unlink)
6214 (inf_child_fileio_readlink, inf_child_use_agent)
6215 (inf_child_can_use_agent): Refactor as methods of
6217 (return_zero, inf_child_target): Delete.
6218 (inf_child_target::inf_child_target): New.
6219 * inf-child.h: Include "target.h".
6220 (inf_child_target): Delete function prototype.
6221 (inf_child_target): New class.
6222 (inf_child_open_target, inf_child_mourn_inferior)
6223 (inf_child_maybe_unpush_target): Delete.
6224 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
6225 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
6226 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
6227 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
6228 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
6229 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
6230 (inf_ptrace_wait, inf_ptrace_xfer_partial)
6231 (inf_ptrace_thread_alive, inf_ptrace_files_info)
6232 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
6233 methods of inf_ptrace_target.
6234 (inf_ptrace_target): Delete function.
6235 * inf-ptrace.h: Include "inf-child.h".
6236 (inf_ptrace_target): Delete function declaration.
6237 (inf_ptrace_target): New class.
6238 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
6239 * linux-nat.c (linux_target): New.
6240 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
6241 (linux_nat_target::~linux_nat_target): New.
6242 (linux_child_post_attach, linux_child_post_startup_inferior)
6243 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
6244 (linux_child_remove_fork_catchpoint)
6245 (linux_child_insert_vfork_catchpoint)
6246 (linux_child_remove_vfork_catchpoint)
6247 (linux_child_insert_exec_catchpoint)
6248 (linux_child_remove_exec_catchpoint)
6249 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
6250 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
6251 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
6252 (linux_nat_stopped_data_address)
6253 (linux_nat_stopped_by_sw_breakpoint)
6254 (linux_nat_supports_stopped_by_sw_breakpoint)
6255 (linux_nat_stopped_by_hw_breakpoint)
6256 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
6257 (linux_nat_kill, linux_nat_mourn_inferior)
6258 (linux_nat_xfer_partial, linux_nat_thread_alive)
6259 (linux_nat_update_thread_list, linux_nat_pid_to_str)
6260 (linux_nat_thread_name, linux_child_pid_to_exec_file)
6261 (linux_child_static_tracepoint_markers_by_strid)
6262 (linux_nat_is_async_p, linux_nat_can_async_p)
6263 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
6264 (linux_nat_supports_multi_process)
6265 (linux_nat_supports_disable_randomization, linux_nat_async)
6266 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
6267 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
6268 (linux_nat_fileio_open, linux_nat_fileio_readlink)
6269 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
6270 methods of linux_nat_target.
6271 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
6272 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
6274 (check_stopped_by_watchpoint): Adjust.
6275 (linux_xfer_partial): Delete.
6276 (linux_target_install_ops, linux_target, linux_nat_add_target):
6278 (linux_nat_target::linux_nat_target): New.
6279 * linux-nat.h: Include "inf-ptrace.h".
6280 (linux_nat_target): New.
6281 (linux_target, linux_target_install_ops, linux_nat_add_target):
6282 Delete function declarations.
6283 (linux_target): Declare global.
6284 * linux-thread-db.c (thread_db_target): New.
6285 (thread_db_target::thread_db_target): New.
6286 (thread_db_ops): Delete.
6287 (the_thread_db_target): New.
6288 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
6289 (thread_db_update_thread_list, thread_db_pid_to_str)
6290 (thread_db_extra_thread_info)
6291 (thread_db_thread_handle_to_thread_info)
6292 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
6293 (thread_db_resume): Refactor as methods of thread_db_target.
6294 (init_thread_db_ops): Delete.
6295 (_initialize_thread_db): Remove reference to init_thread_db_ops.
6296 * x86-linux-nat.c: Don't include "linux-nat.h".
6297 (super_post_startup_inferior): Delete.
6298 (x86_linux_nat_target::~x86_linux_nat_target): New.
6299 (x86_linux_child_post_startup_inferior)
6300 (x86_linux_read_description, x86_linux_enable_btrace)
6301 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
6302 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
6303 methods of x86_linux_nat_target.
6304 (x86_linux_create_target): Delete. Bits folded ...
6305 (x86_linux_add_target): ... here. Now takes a linux_nat_target
6307 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
6308 (x86_linux_nat_target): New class.
6309 (x86_linux_create_target): Delete.
6310 (x86_linux_add_target): Now takes a linux_nat_target pointer.
6311 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
6312 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
6313 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
6314 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
6315 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
6317 (x86_use_watchpoints): Delete.
6318 * x86-nat.h: Include "breakpoint.h" and "target.h".
6319 (x86_use_watchpoints): Delete.
6320 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
6321 (x86_stopped_by_watchpoint, x86_stopped_data_address)
6322 (x86_insert_watchpoint, x86_remove_watchpoint)
6323 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
6324 (x86_stopped_by_hw_breakpoint): New declarations.
6325 (x86_nat_target): New template class.
6327 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
6328 (the_ppc_linux_nat_target): New.
6329 (ppc_linux_fetch_inferior_registers)
6330 (ppc_linux_can_use_hw_breakpoint)
6331 (ppc_linux_region_ok_for_hw_watchpoint)
6332 (ppc_linux_ranged_break_num_registers)
6333 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
6334 (ppc_linux_insert_mask_watchpoint)
6335 (ppc_linux_remove_mask_watchpoint)
6336 (ppc_linux_can_accel_watchpoint_condition)
6337 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
6338 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
6339 (ppc_linux_watchpoint_addr_within_range)
6340 (ppc_linux_masked_watch_num_registers)
6341 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
6342 (ppc_linux_read_description): Refactor as methods of
6343 ppc_linux_nat_target.
6344 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
6346 * procfs.c (procfs_xfer_partial): Delete forward declaration.
6347 (procfs_target): New class.
6348 (the_procfs_target): New.
6349 (procfs_target): Delete function.
6350 (procfs_auxv_parse, procfs_attach, procfs_detach)
6351 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
6352 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
6353 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
6354 (procfs_create_inferior, procfs_update_thread_list)
6355 (procfs_thread_alive, procfs_pid_to_str)
6356 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
6357 (procfs_stopped_data_address, procfs_insert_watchpoint)
6358 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
6359 (proc_find_memory_regions, procfs_info_proc)
6360 (procfs_make_note_section): Refactor as methods of procfs_target.
6361 (_initialize_procfs): Adjust.
6362 * sol-thread.c (sol_thread_target): New class.
6363 (sol_thread_ops): Now a sol_thread_target.
6364 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
6365 (sol_thread_fetch_registers, sol_thread_store_registers)
6366 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
6367 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
6368 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
6369 (init_sol_thread_ops): Delete.
6370 (_initialize_sol_thread): Adjust. Remove references to
6371 init_sol_thread_ops and complete_target_initialization.
6373 * windows-nat.c (windows_nat_target): New class.
6374 (windows_fetch_inferior_registers)
6375 (windows_store_inferior_registers, windows_resume, windows_wait)
6376 (windows_attach, windows_detach, windows_pid_to_exec_file)
6377 (windows_files_info, windows_create_inferior)
6378 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
6379 (windows_close, windows_pid_to_str, windows_xfer_partial)
6380 (windows_get_tib_address, windows_get_ada_task_ptid)
6381 (windows_thread_name, windows_thread_alive): Refactor as
6382 windows_nat_target methods.
6383 (do_initial_windows_stuff): Adjust.
6384 (windows_target): Delete function.
6385 (_initialize_windows_nat): Adjust.
6387 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
6388 (darwin_mourn_inferior, darwin_kill_inferior)
6389 (darwin_create_inferior, darwin_attach, darwin_detach)
6390 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
6391 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
6392 (darwin_supports_multi_process): Refactor as darwin_nat_target
6394 (darwin_resume_to, darwin_files_info): Delete.
6395 (_initialize_darwin_inferior): Rename to ...
6396 (_initialize_darwin_nat): ... this. Adjust to C++ification.
6397 * darwin-nat.h: Include "inf-child.h".
6398 (darwin_nat_target): New class.
6399 (darwin_complete_target): Delete.
6400 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
6401 (darwin_target): New.
6402 (i386_darwin_fetch_inferior_registers)
6403 (i386_darwin_store_inferior_registers): Refactor as methods of
6405 (darwin_complete_target): Delete, with ...
6406 (_initialize_i386_darwin_nat): ... bits factored out here.
6408 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
6409 (the_alpha_linux_nat_target): New.
6410 (alpha_linux_register_u_offset): Refactor as
6411 alpha_linux_nat_target method.
6412 (_initialize_alpha_linux_nat): Adjust.
6413 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
6414 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6415 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
6416 methods of linux_nat_trad_target.
6417 (linux_trad_target): Delete.
6418 * linux-nat-trad.h (linux_trad_target): Delete function.
6419 (linux_nat_trad_target): New class.
6420 * mips-linux-nat.c (mips_linux_nat_target): New class.
6421 (super_fetch_registers, super_store_registers, super_close):
6423 (the_mips_linux_nat_target): New.
6424 (mips64_linux_regsets_fetch_registers)
6425 (mips64_linux_regsets_store_registers)
6426 (mips64_linux_fetch_registers, mips64_linux_store_registers)
6427 (mips_linux_register_u_offset, mips_linux_read_description)
6428 (mips_linux_can_use_hw_breakpoint)
6429 (mips_linux_stopped_by_watchpoint)
6430 (mips_linux_stopped_data_address)
6431 (mips_linux_region_ok_for_hw_watchpoint)
6432 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6433 (mips_linux_close): Refactor as methods of mips_linux_nat.
6434 (_initialize_mips_linux_nat): Adjust to C++ification.
6436 * aix-thread.c (aix_thread_target): New class.
6437 (aix_thread_ops): Now an aix_thread_target.
6438 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
6439 (aix_thread_fetch_registers, aix_thread_store_registers)
6440 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
6441 (aix_thread_thread_alive, aix_thread_pid_to_str)
6442 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
6443 Refactor as methods of aix_thread_target.
6444 (init_aix_thread_ops): Delete.
6445 (_initialize_aix_thread): Remove references to init_aix_thread_ops
6446 and complete_target_initialization.
6447 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
6448 (rs6000_nat_target): New class.
6449 (the_rs6000_nat_target): New.
6450 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
6451 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
6452 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
6453 (super_create_inferior): Delete.
6454 (_initialize_rs6000_nat): Adjust to C++ification.
6456 * arm-linux-nat.c (arm_linux_nat_target): New class.
6457 (the_arm_linux_nat_target): New.
6458 (arm_linux_fetch_inferior_registers)
6459 (arm_linux_store_inferior_registers, arm_linux_read_description)
6460 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
6461 (arm_linux_remove_hw_breakpoint)
6462 (arm_linux_region_ok_for_hw_watchpoint)
6463 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
6464 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
6465 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
6466 arm_linux_nat_target.
6467 (_initialize_arm_linux_nat): Adjust to C++ification.
6469 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
6470 (the_aarch64_linux_nat_target): New.
6471 (aarch64_linux_fetch_inferior_registers)
6472 (aarch64_linux_store_inferior_registers)
6473 (aarch64_linux_child_post_startup_inferior)
6474 (aarch64_linux_read_description)
6475 (aarch64_linux_can_use_hw_breakpoint)
6476 (aarch64_linux_insert_hw_breakpoint)
6477 (aarch64_linux_remove_hw_breakpoint)
6478 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
6479 (aarch64_linux_region_ok_for_hw_watchpoint)
6480 (aarch64_linux_stopped_data_address)
6481 (aarch64_linux_stopped_by_watchpoint)
6482 (aarch64_linux_watchpoint_addr_within_range)
6483 (aarch64_linux_can_do_single_step): Refactor as methods of
6484 aarch64_linux_nat_target.
6485 (super_post_startup_inferior): Delete.
6486 (_initialize_aarch64_linux_nat): Adjust to C++ification.
6488 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
6489 (the_hppa_linux_nat_target): New.
6490 (hppa_linux_fetch_inferior_registers)
6491 (hppa_linux_store_inferior_registers): Refactor as methods of
6492 hppa_linux_nat_target.
6493 (_initialize_hppa_linux_nat): Adjust to C++ification.
6495 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
6496 (the_ia64_linux_nat_target): New.
6497 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
6498 (ia64_linux_stopped_data_address)
6499 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
6500 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
6501 ia64_linux_nat_target methods.
6502 (super_xfer_partial): Delete.
6503 (_initialize_ia64_linux_nat): Adjust to C++ification.
6505 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
6506 (the_m32r_linux_nat_target): New.
6507 (m32r_linux_fetch_inferior_registers)
6508 (m32r_linux_store_inferior_registers): Refactor as
6509 m32r_linux_nat_target methods.
6510 (_initialize_m32r_linux_nat): Adjust to C++ification.
6512 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
6513 (the_m68k_linux_nat_target): New.
6514 (m68k_linux_fetch_inferior_registers)
6515 (m68k_linux_store_inferior_registers): Refactor as
6516 m68k_linux_nat_target methods.
6517 (_initialize_m68k_linux_nat): Adjust to C++ification.
6519 * s390-linux-nat.c (s390_linux_nat_target): New class.
6520 (the_s390_linux_nat_target): New.
6521 (s390_linux_fetch_inferior_registers)
6522 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
6523 (s390_insert_watchpoint, s390_remove_watchpoint)
6524 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
6525 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
6526 (s390_auxv_parse, s390_read_description): Refactor as methods of
6527 s390_linux_nat_target.
6528 (_initialize_s390_nat): Adjust to C++ification.
6530 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
6531 (the_sparc_linux_nat_target): New.
6532 (_initialize_sparc_linux_nat): Adjust to C++ification.
6533 * sparc-nat.c (sparc_fetch_inferior_registers)
6534 (sparc_store_inferior_registers): Remove target_ops parameter.
6535 * sparc-nat.h (sparc_fetch_inferior_registers)
6536 (sparc_store_inferior_registers): Remove target_ops parameter.
6537 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
6538 (the_sparc64_linux_nat_target): New.
6539 (_initialize_sparc64_linux_nat): Adjust to C++ification.
6541 * spu-linux-nat.c (spu_linux_nat_target): New class.
6542 (the_spu_linux_nat_target): New.
6543 (spu_child_post_startup_inferior, spu_child_post_attach)
6544 (spu_child_wait, spu_fetch_inferior_registers)
6545 (spu_store_inferior_registers, spu_xfer_partial)
6546 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
6548 (_initialize_spu_nat): Adjust to C++ification.
6550 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
6551 (the_tilegx_linux_nat_target): New.
6552 (fetch_inferior_registers, store_inferior_registers):
6553 Refactor as methods.
6554 (_initialize_tile_linux_nat): Adjust to C++ification.
6556 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6557 (the_xtensa_linux_nat_target): New.
6558 (xtensa_linux_fetch_inferior_registers)
6559 (xtensa_linux_store_inferior_registers): Refactor as
6560 xtensa_linux_nat_target methods.
6561 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6563 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6564 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6565 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6566 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6567 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6568 (fbsd_stopped_by_sw_breakpoint)
6569 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6570 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6571 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6572 (fbsd_post_startup_inferior, fbsd_post_attach)
6573 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6574 (fbsd_set_syscall_catchpoint)
6575 (super_xfer_partial, super_resume, super_wait)
6576 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6577 (fbsd_handle_debug_trap): Remove target_ops parameter.
6578 (fbsd_nat_add_target): Delete.
6579 * fbsd-nat.h: Include "inf-ptrace.h".
6580 (fbsd_nat_add_target): Delete.
6581 (USE_SIGTRAP_SIGINFO): Define.
6582 (fbsd_nat_target): New class.
6584 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6585 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6586 (amd64bsd_target): Delete.
6587 * amd64-bsd-nat.h: New file.
6588 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6590 (amd64_fbsd_nat_target): New class.
6591 (the_amd64_fbsd_nat_target): New.
6592 (amd64fbsd_read_description): Refactor as method of
6593 amd64_fbsd_nat_target.
6594 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6595 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6596 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6597 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6598 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6599 (i386bsd_target): Delete.
6600 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6601 (i386bsd_fetch_inferior_registers)
6602 (i386bsd_store_inferior_registers): Declare.
6603 (i386_bsd_nat_target): New class.
6604 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6605 (the_i386_fbsd_nat_target): New.
6606 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6607 i386_fbsd_nat_target methods.
6608 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6609 (_initialize_i386fbsd_nat): Adjust to C++ification.
6610 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6611 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6612 (_initialize_x86_bsd_nat): Adjust to C++ification.
6613 * x86-bsd-nat.h: Include "x86-nat.h".
6614 (x86bsd_target): Delete declaration.
6615 (x86bsd_nat_target): New class.
6617 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6618 (the_aarch64_fbsd_nat_target): New.
6619 (aarch64_fbsd_fetch_inferior_registers)
6620 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6621 aarch64_fbsd_nat_target.
6622 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6623 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
6624 (the_alpha_bsd_nat_target): New.
6625 (alphabsd_fetch_inferior_registers)
6626 (alphabsd_store_inferior_registers): Refactor as
6627 alpha_bsd_nat_target methods.
6628 (_initialize_alphabsd_nat): Refactor as methods of
6629 alpha_bsd_nat_target.
6630 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
6631 (the_amd64_nbsd_nat_target): New.
6632 (_initialize_amd64nbsd_nat): Adjust to C++ification.
6633 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
6634 (the_amd64_obsd_nat_target): New.
6635 (_initialize_amd64obsd_nat): Adjust to C++ification.
6636 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
6637 (the_arm_fbsd_nat_target): New.
6638 (arm_fbsd_fetch_inferior_registers)
6639 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
6640 (_initialize_arm_fbsd_nat): Refactor as methods of
6641 arm_fbsd_nat_target.
6642 (_initialize_arm_fbsd_nat): Adjust to C++ification.
6643 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
6644 (the_arm_netbsd_nat_target): New.
6645 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
6646 arm_netbsd_nat_target.
6647 (_initialize_arm_netbsd_nat): Adjust to C++ification.
6648 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
6649 (the_hppa_nbsd_nat_target): New.
6650 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
6651 hppa_nbsd_nat_target methods.
6652 (_initialize_hppanbsd_nat): Adjust to C++ification.
6653 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
6654 (the_hppa_obsd_nat_target): New.
6655 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
6656 methods of hppa_obsd_nat_target.
6657 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
6659 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
6660 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
6662 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
6663 (_initialize_i386obsd_nat): Use add_target.
6664 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
6665 (the_m68k_bsd_nat_target): New.
6666 (m68kbsd_fetch_inferior_registers)
6667 (m68kbsd_store_inferior_registers): Refactor as methods of
6668 m68k_bsd_nat_target.
6669 (_initialize_m68kbsd_nat): Adjust to C++ification.
6670 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
6671 (the_mips_fbsd_nat_target): New.
6672 (mips_fbsd_fetch_inferior_registers)
6673 (mips_fbsd_store_inferior_registers): Refactor as methods of
6674 mips_fbsd_nat_target.
6675 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
6677 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
6678 (the_mips_nbsd_nat_target): New.
6679 (mipsnbsd_fetch_inferior_registers)
6680 (mipsnbsd_store_inferior_registers): Refactor as methods of
6681 mips_nbsd_nat_target.
6682 (_initialize_mipsnbsd_nat): Adjust to C++ification.
6683 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
6684 (the_mips64_obsd_nat_target): New.
6685 (mips64obsd_fetch_inferior_registers)
6686 (mips64obsd_store_inferior_registers): Refactor as methods of
6687 mips64_obsd_nat_target.
6688 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
6690 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
6692 * nbsd-nat.h: Include "inf-ptrace.h".
6693 (nbsd_nat_target): New class.
6694 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
6695 (obsd_wait): Refactor as methods of obsd_nat_target.
6696 (obsd_add_target): Delete.
6697 * obsd-nat.h: Include "inf-ptrace.h".
6698 (obsd_nat_target): New class.
6699 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
6700 (the_ppc_fbsd_nat_target): New.
6701 (ppcfbsd_fetch_inferior_registers)
6702 (ppcfbsd_store_inferior_registers): Refactor as methods of
6703 ppc_fbsd_nat_target.
6704 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
6706 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
6707 (the_ppc_nbsd_nat_target): New.
6708 (ppcnbsd_fetch_inferior_registers)
6709 (ppcnbsd_store_inferior_registers): Refactor as methods of
6710 ppc_nbsd_nat_target.
6711 (_initialize_ppcnbsd_nat): Adjust to C++ification.
6712 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
6713 (the_ppc_obsd_nat_target): New.
6714 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
6715 methods of ppc_obsd_nat_target.
6716 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
6718 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
6719 (the_sh_nbsd_nat_target): New.
6720 (shnbsd_fetch_inferior_registers)
6721 (shnbsd_store_inferior_registers): Refactor as methods of
6723 (_initialize_shnbsd_nat): Adjust to C++ification.
6724 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
6725 (inf_ptrace_xfer_partial): Delete.
6726 (sparc_xfer_partial, sparc_target): Delete.
6727 * sparc-nat.h (sparc_fetch_inferior_registers)
6728 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
6729 (sparc_target): Delete function declaration.
6730 (sparc_target): New template class.
6731 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
6732 (_initialize_sparcnbsd_nat): Adjust to C++ification.
6733 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
6734 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
6736 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
6737 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
6738 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
6739 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
6741 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
6742 (the_vax_bsd_nat_target): New.
6743 (vaxbsd_fetch_inferior_registers)
6744 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
6746 (_initialize_vaxbsd_nat): Adjust to C++ification.
6748 * bsd-kvm.c (bsd_kvm_target): New class.
6749 (bsd_kvm_ops): Now a bsd_kvm_target.
6750 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
6751 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
6752 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
6754 (bsd_kvm_return_one): Delete.
6755 (bsd_kvm_add_target): Adjust to C++ification.
6757 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
6758 (nto_procfs_target_procfs): New classes.
6759 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
6760 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
6761 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
6762 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
6763 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
6764 (procfs_remove_hw_breakpoint, procfs_resume)
6765 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
6766 (procfs_kill_inferior, procfs_store_registers)
6767 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
6768 as methods of nto_procfs_target.
6769 (nto_procfs_ops): Now an nto_procfs_target_procfs.
6770 (nto_native_ops): Delete.
6771 (procfs_open, procfs_native_open): Delete.
6772 (nto_native_ops): Now an nto_procfs_target_native.
6773 (init_procfs_targets): Adjust to C++ification.
6774 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
6775 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
6776 Refactor as methods of nto_procfs_target.
6778 * go32-nat.c (go32_nat_target): New class.
6779 (the_go32_nat_target): New.
6780 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
6781 (go32_store_registers, go32_xfer_partial, go32_files_info)
6782 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
6783 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
6784 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
6785 (go32_pid_to_str): Refactor as methods of go32_nat_target.
6786 (go32_target): Delete.
6787 (_initialize_go32_nat): Adjust to C++ification.
6789 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
6790 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
6791 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
6792 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
6794 (gnu_target): Delete.
6795 * gnu-nat.h (gnu_target): Delete.
6796 (gnu_nat_target): New class.
6797 * i386-gnu-nat.c (gnu_base_target): New.
6798 (i386_gnu_nat_target): New class.
6799 (the_i386_gnu_nat_target): New.
6800 (_initialize_i386gnu_nat): Adjust to C++ification.
6802 2018-05-02 Pedro Alves <palves@redhat.com>
6804 * bfd-target.c (target_bfd_xclose): Rename to ...
6805 (target_bfd_close): ... this.
6806 (target_bfd_reopen): Adjust.
6807 * target.c (target_close): Remove references to to_xclose.
6808 * target.h (target_ops::to_xclose): Delete.
6809 (target_ops::to_close): Update comments.
6811 2018-05-02 Pedro Alves <palves@redhat.com>
6813 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
6815 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
6816 * inf-ptrace.c (inf_ptrace_register_u_offset)
6817 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6818 (inf_ptrace_store_register, inf_ptrace_store_registers)
6819 (inf_ptrace_trad_target): Move to ...
6820 * linux-nat-trad.c: ... this new file.
6821 * linux-nat-trad.h: New file.
6822 * linux-nat.c (linux_target_install_ops): Make extern.
6823 (linux_trad_target): Delete.
6824 * linux-nat.h (linux_trad_target): Delete declaration.
6825 (linux_target_install_ops): Declare.
6826 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
6829 2018-05-02 Pedro Alves <palves@redhat.com>
6831 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6832 procfs_target/add_target here.
6833 * procfs.c (procfs_target): Make static.
6834 (_initialize_procfs): Call add_target here.
6835 * procfs.h (struct target_ops): Remove forward declaration.
6836 (procfs_target): Remove declaration.
6837 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
6839 2018-05-02 Pedro Alves <palves@redhat.com>
6841 * procfs.c (procfs_stopped_by_watchpoint)
6842 (procfs_insert_watchpoint, procfs_remove_watchpoint)
6843 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
6845 (procfs_use_watchpoints): Delete, move contents...
6846 (procfs_target): ... here.
6847 * procfs.h (procfs_use_watchpoints): Delete declaration.
6848 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6849 procfs_use_watchpoints.
6850 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
6851 procfs_use_watchpoints.
6853 2018-05-02 Tom Tromey <tom@tromey.com>
6856 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
6857 and var_zuinteger_unlimited.
6858 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
6859 and PARAM_ZUINTEGER_UNLIMITED.
6860 (set_parameter_value): Handle var_zuinteger and
6861 var_zuinteger_unlimited.
6862 (add_setshow_generic): Likewise.
6863 (parmpy_init): Likewise.
6865 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
6868 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
6869 pointer is not null before dereferencing it.
6871 2018-04-30 Tom Tromey <tom@tromey.com>
6873 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
6876 2018-04-30 Tom Tromey <tom@tromey.com>
6878 * breakpoint.c (mention): Remove use of is_mi_like_p.
6879 (print_mention_ranged_breakpoint): Likewise.
6880 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
6883 2018-04-30 Tom Tromey <tom@tromey.com>
6885 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
6887 2018-04-30 Tom Tromey <tom@tromey.com>
6889 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
6890 (info_spu_event_command): Remove some uses of is_mi_like_p.
6892 2018-04-30 Tom Tromey <tom@tromey.com>
6894 * python/py-framefilter.c (py_print_single_arg)
6895 (enumerate_locals, py_print_args, py_print_frame): Remove some
6896 uses of is_mi_like_p.
6898 2018-04-30 Tom Tromey <tom@tromey.com>
6901 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
6902 * ui-out.h (ui_out::is_mi_like_p): Now const.
6903 (ui_out::do_is_mi_like_p): Now const.
6904 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
6906 2018-04-30 Tom Tromey <tom@tromey.com>
6908 * varobj.c (varobj_set_visualizer): Use new_reference.
6909 * python/python.c (gdbpy_decode_line): Use new_reference.
6910 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
6913 2018-04-30 Tom Tromey <tom@tromey.com>
6915 * varobj.c (install_new_value): Use new_reference.
6916 * value.h (value_incref): Return void. Swap intro comment with
6918 * value.c (set_value_parent): Use new_reference.
6919 (value_incref): Return void. Update intro comment.
6920 (release_value): Use new_reference.
6921 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
6923 2018-04-30 Tom Tromey <tom@tromey.com>
6925 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
6926 * gdb_bfd.h (new_bfd_ref): Remove.
6927 (gdb_bfd_open): Update comment.
6928 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
6929 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
6930 (gdb_bfd_fdopenr): Use new_reference.
6931 * exec.c (exec_file_attach): Use new_reference.
6933 2018-04-30 Tom Tromey <tom@tromey.com>
6935 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
6938 2018-04-30 Tom Tromey <tom@tromey.com>
6940 * jit.c (jit_read_code_entry): Use type_align.
6941 * i386-tdep.c (i386_gdbarch_init): Don't call
6942 set_gdbarch_long_long_align_bit.
6943 * gdbarch.sh: Remove long_long_align_bit.
6944 * gdbarch.c, gdbarch.h: Rebuild.
6945 * arc-tdep.c (arc_type_align): New function.
6946 (arc_gdbarch_init): Use arc_type_align. Don't call
6947 set_gdbarch_long_long_align_bit.
6949 2018-04-30 Tom Tromey <tom@tromey.com>
6951 * rust-lang.c (rust_type_alignment): Remove.
6952 (rust_composite_type): Use type_align.
6954 2018-04-30 Tom Tromey <tom@tromey.com>
6956 * NEWS: Mention Type.align.
6957 * python/py-type.c (typy_get_alignof): New function.
6958 (type_object_getset): Add "alignof".
6960 2018-04-30 Tom Tromey <tom@tromey.com>
6964 * std-operator.def (UNOP_ALIGNOF): New operator.
6965 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
6967 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
6968 * c-lang.c (c_op_print_tab): Add alignof.
6969 * c-exp.y (ALIGNOF): New token.
6970 (exp): Add "ALIGNOF" production.
6971 (ident_tokens): Add _Alignof and alignof.
6973 2018-04-30 Tom Tromey <tom@tromey.com>
6975 * i386-tdep.c (i386_type_align): New function.
6976 (i386_gdbarch_init): Update.
6977 * gdbarch.sh (type_align): New method.
6978 * gdbarch.c, gdbarch.h: Rebuild.
6979 * arch-utils.h (default_type_align): Declare.
6980 * arch-utils.c (default_type_align): New function.
6981 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
6982 (struct type) <align_log2>: New field.
6983 <instance_flags>: Now a bitfield.
6984 (TYPE_RAW_ALIGN): New macro.
6985 (type_align, type_raw_align, set_type_align): Declare.
6986 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
6988 * dwarf2read.c (quirk_rust_enum): Set type alignment.
6989 (get_alignment, maybe_set_alignment): New functions.
6990 (read_structure_type, read_enumeration_type, read_array_type)
6991 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
6992 (read_subrange_type, read_base_type): Set type alignment.
6994 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
6996 * dwarf2read.c (read_index_from_section): Use bool.
6998 2018-04-29 Fabian Groffen <grobian@gentoo.org>
7001 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
7004 2018-04-29 John Reiser <jreiser@BitWagon.com>
7007 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
7008 last step, and do it atomically.
7010 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
7012 * compile/compile-c-types.c (convert_int, convert_float):
7015 2018-04-27 Tom Tromey <tom@tromey.com>
7018 * rust-lang.c (rust_inclusive_range_type_p): New function.
7019 (rust_range): Handle inclusive ranges.
7020 (rust_compute_range): Likewise.
7021 * rust-exp.y (struct rust_op) <inclusive>: New field.
7022 (DOTDOTEQ): New constant.
7023 (range_expr): Add "..=" productions.
7024 (operator_tokens): Add "..=" token.
7025 (ast_range): Add "inclusive" parameter.
7026 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
7028 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
7030 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
7031 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
7033 * expprint.c (print_subexp_standard): Handle new bounds values.
7034 (dump_subexp_body_standard): Likewise.
7036 2018-04-27 Tom Tromey <tom@tromey.com>
7038 * configure: Rebuild.
7039 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
7040 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
7042 (class symbol_needs_eval_context): Likewise.
7043 * dwarf2read.c (mock_mapped_index::symbol_name_count)
7044 (mock_mapped_index::symbol_name_at): Use "override". Remove
7046 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
7048 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
7049 * aarch64-tdep.c (instruction_reader::read): Use "override".
7050 (instruction_reader_test::read): Likewise.
7051 * arm-tdep.c (instruction_reader::read): Use "override".
7052 (instruction_reader_thumb::read): Likewise.
7054 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
7057 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
7058 instead of remote_send.
7059 (remote_send): Remove.
7061 2018-04-26 Pedro Alves <palves@redhat.com>
7063 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
7064 find_function_start_sal instead of find_pc_line.
7066 2018-04-26 Pedro Alves <palves@redhat.com>
7068 * breakpoint.c (set_breakpoint_location_function): Handle
7070 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
7071 * elfread.c (elf_symtab_read): Give data symbols with
7072 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
7073 (elf_rel_plt_read): Update comment.
7074 * linespec.c (convert_linespec_to_sals): Handle
7076 (minsym_found): Handle mst_data_gnu_ifunc.
7077 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
7078 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
7079 * parse.c (find_minsym_type_and_address): Handle
7081 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
7082 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
7083 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
7085 <mst_data_gnu_ifunc>: New enumerator.
7087 2018-04-26 Pedro Alves <palves@redhat.com>
7089 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
7090 (lookup_minimal_symbol_by_pc_section): ... this. Replace
7091 'want_trampoline' parameter by a lookup_msym_prefer parameter.
7093 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
7094 (lookup_minimal_symbol_by_pc): Adjust.
7095 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
7096 (lookup_solib_trampoline_symbol_by_pc): Adjust.
7097 * minsyms.h (lookup_msym_prefer): New enum.
7098 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7099 parameter by a lookup_msym_prefer parameter.
7101 2018-04-26 Pedro Alves <palves@redhat.com>
7103 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
7104 ends in "@plt" instead of looking at the symbol's section.
7106 2018-04-26 Pedro Alves <palves@redhat.com>
7108 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
7110 (find_pc_partial_function_gnu_ifunc): Rename to ...
7111 (find_pc_partial_function): ... this, and remove references to
7113 (find_pc_partial_function): Delete old implementation.
7114 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
7116 2018-04-26 Pedro Alves <palves@redhat.com>
7118 * linespec.c (struct bound_minimal_symbol_search_key): New.
7119 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
7120 skip first line if we found a GNU ifunc minimal symbol by name.
7121 (compare_msymbols): Change parameters to work with a destructured
7123 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
7126 2018-04-26 Pedro Alves <palves@redhat.com>
7128 * breakpoint.c (set_breakpoint_location_function): Don't resolve
7129 ifunc targets here. Instead, if we have an ifunc minsym, use its
7131 (add_location_to_breakpoint): Store the minsym and the objfile in
7132 the breakpoint location.
7133 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
7134 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
7135 Record the minsym in the sal.
7136 * symtab.h (symtab_and_line) <msymbol>: New field.
7138 2018-04-26 Pedro Alves <palves@redhat.com>
7140 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
7141 unless we actually resolved the ifunc.
7143 2018-04-26 Pedro Alves <palves@redhat.com>
7145 * c-exp.y (variable production): Prefer ifunc minsyms over
7146 regular function symbols.
7147 * symtab.c (find_gnu_ifunc): New function.
7148 * minsyms.h (lookup_msym_prefer): New enum.
7149 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
7150 parameter by a lookup_msym_prefer parameter.
7151 * symtab.h (find_gnu_ifunc): New declaration.
7153 2018-04-26 Pedro Alves <palves@redhat.com>
7155 * blockframe.c (find_gnu_ifunc_target_type): New function.
7156 (find_function_type): New.
7157 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
7158 return a value with a memory address.
7159 (eval_call): For calls to GNU ifunc functions, try to find the
7160 type of the target function from the type that the resolver
7162 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
7164 * infcall.c (find_function_return_type): Delete.
7165 (find_function_addr): Add 'function_type' parameter. For calls to
7166 GNU ifunc functions, try to find the type of the target function
7167 from the type that the resolver returns, and return it via
7169 (call_function_by_hand_dummy): Adjust to use the function type
7170 returned by find_function_addr.
7171 (find_function_addr): Add 'function_type' parameter and move
7173 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
7176 2018-04-26 Pedro Alves <palves@redhat.com>
7178 * c-exp.y (variable production): Skip finding an alias for ifunc
7181 2018-04-26 Pedro Alves <palves@redhat.com>
7183 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
7185 2018-04-25 Pedro Alves <palves@redhat.com>
7187 * infcmd.c (kill_command): Print the pid as string, not the whole
7188 thread's ptid. Add comment. s/has been killed/killed/ in output
7190 * remote.c (remote_detach_1): Print the pid as string, not the
7191 whole thread's ptid.
7193 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7194 Sergio Durigan Junior <sergiodj@redhat.com>
7195 Pedro Alves <palves@redhat.com>
7197 * infcmd.c (kill_command): Print message when inferior has
7199 * inferior.c (print_inferior_events): Remove 'static'. Set as
7201 (add_inferior): Improve message printed when
7202 'print_inferior_events' is on.
7203 (exit_inferior): Remove message printed when
7204 'print_inferior_events' is on.
7205 (detach_inferior): Improve message printed when
7206 'print_inferior_events' is on.
7207 (initialize_inferiors): Use 'add_inferior_silent' to set
7208 'current_inferior_'.
7209 * inferior.h (print_inferior_events): Declare here as
7211 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
7212 '[Detaching...]' messages when 'print_inferior_events' is on.
7213 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
7214 as prefix/suffix for messages. Remove periods. Fix erroneous
7215 'Detaching after fork from child...', replace it by '... from
7217 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
7218 prefix/suffix when printing 'Detaching...' messages. Print
7219 them when 'print_inferior_events' is on.
7220 * remote.c (remote_detach_1): Print message when detaching
7221 from inferior and '!is_fork_parent'.
7223 2018-04-24 Tom Tromey <tom@tromey.com>
7225 * cli-out.h: Reindent.
7227 2018-04-24 Tom Tromey <tom@tromey.com>
7229 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
7230 (cli_ui_out::do_field_string): Use fputs_filtered.
7231 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
7233 2018-04-23 Tom Tromey <tom@tromey.com>
7235 * guile/scm-frame.c (gdbscm_frame_read_var): Use
7236 gdb::unique_xmalloc_ptr.
7238 2018-04-23 Tom Tromey <tom@tromey.com>
7240 * configure: Rebuild.
7242 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
7245 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
7246 prepare_for_testing. Set normal_bp to r_debug_state if target
7249 2018-04-21 Pedro Alves <palves@redhat.com>
7250 Rajendra SY <rajendra.sy@gmail.com>
7252 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
7253 * remote.c (extended_remote_attach): In all-stop mode, mark the
7254 thread as executing.
7256 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7258 * thread.c (thread_apply_all_command): Fix comment.
7259 (thread_command): Fix comment.
7261 2018-04-10 Alan Hayward <alan.hayward@arm.com>
7263 * common/tdesc.h (tdesc_create_feature): Remove xml filename
7265 * features/aarch64-core.c (create_feature_aarch64_core):
7267 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
7269 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
7271 * features/i386/32bit-avx512.c
7272 (create_feature_i386_32bit_avx512): Likewise.
7273 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
7275 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
7277 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
7279 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
7281 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
7283 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
7285 * features/i386/64bit-avx512.c
7286 (create_feature_i386_64bit_avx512): Likewise.
7287 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
7289 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
7291 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
7293 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
7295 * features/i386/64bit-segments.c
7296 (create_feature_i386_64bit_segments): Likewise.
7297 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
7299 * features/i386/x32-core.c
7300 (create_feature_i386_x32_core): Likewise.
7301 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
7302 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
7303 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
7304 * target-descriptions.c: In generated code, don't pass xml
7307 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7309 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
7310 (print_xml_feature::visit_post): Likewise.
7311 (print_xml_feature::visit): Likewise.
7312 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
7313 (print_xml_feature): Add new class.
7314 * regformats/regdat.sh: Null xmltarget on feature targets.
7315 * target-descriptions.c (struct target_desc): Add xmltarget.
7316 (maintenance_check_tdesc_xml_convert): Add unittest function.
7317 (tdesc_get_features_xml): Add function to get xml.
7318 (maintenance_check_xml_descriptions): Test xml generation.
7319 * xml-tdesc.c (string_read_description_xml): Add function.
7320 * xml-tdesc.h (string_read_description_xml): Add declaration.
7322 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7324 * features/Makefile: Add feature marker to targets with new style
7325 target descriptions.
7326 * regformats/aarch64.dat: Regenerate.
7327 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
7328 * regformats/i386/amd64-avx-linux.dat: Likewise.
7329 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
7330 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
7331 * regformats/i386/amd64-linux.dat: Likewise.
7332 * regformats/i386/amd64-mpx-linux.dat: Likewise.
7333 * regformats/i386/amd64.dat: Likewise.
7334 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
7335 * regformats/i386/i386-avx-linux.dat: Likewise.
7336 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
7337 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
7338 * regformats/i386/i386-linux.dat: Likewise.
7339 * regformats/i386/i386-mmx-linux.dat: Likewise.
7340 * regformats/i386/i386-mpx-linux.dat: Likewise.
7341 * regformats/i386/i386.dat: Likewise.
7342 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
7343 * regformats/i386/x32-avx-linux.dat: Likewise.
7344 * regformats/i386/x32-linux.dat: Likewise.
7345 * regformats/tic6x-c62x-linux.dat: Likewise.
7346 * regformats/tic6x-c64x-linux.dat: Likewise.
7347 * regformats/tic6x-c64xp-linux.dat: Likewise.
7348 * regformats/regdat.sh: Parse feature marker.
7350 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7352 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
7353 (tdesc_osabi_name): Likewise.
7354 * target-descriptions.c (tdesc_architecture_name): Add new
7356 (tdesc_osabi_name): Likewise.
7358 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7360 * common/tdesc.c (tdesc_predefined_type): Move to here.
7361 (tdesc_named_type): Likewise.
7362 (tdesc_create_vector): Likewise.
7363 (tdesc_create_struct): Likewise.
7364 (tdesc_set_struct_size): Likewise.
7365 (tdesc_create_union): Likewise.
7366 (tdesc_create_flags): Likewise.
7367 (tdesc_create_enum): Likewise.
7368 (tdesc_add_field): Likewise.
7369 (tdesc_add_typed_bitfield): Likewise.
7370 (tdesc_add_bitfield): Likewise.
7371 (tdesc_add_flag): Likewise.
7372 (tdesc_add_enum_value): Likewise.
7373 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
7374 (struct tdesc_type_vector): Likewise.
7375 (struct tdesc_type_field): Likewise.
7376 (struct tdesc_type_with_fields): Likewise.
7377 (tdesc_create_enum): Add declaration.
7378 (tdesc_add_typed_bitfield): Likewise.
7379 (tdesc_add_enum_value): Likewise.
7380 * target-descriptions.c (tdesc_type_field): Move from here.
7381 (tdesc_type_builtin): Likewise.
7382 (tdesc_type_vector): Likewise.
7383 (tdesc_type_with_fields): Likewise.
7384 (tdesc_predefined_types): Likewise.
7385 (tdesc_named_type): Likewise.
7386 (tdesc_create_vector): Likewise.
7387 (tdesc_create_struct): Likewise.
7388 (tdesc_set_struct_size): Likewise.
7389 (tdesc_create_union): Likewise.
7390 (tdesc_create_flags): Likewise.
7391 (tdesc_create_enum): Likewise.
7392 (tdesc_add_field): Likewise.
7393 (tdesc_add_typed_bitfield): Likewise.
7394 (tdesc_add_bitfield): Likewise.
7395 (tdesc_add_flag): Likewise.
7396 (tdesc_add_enum_value): Likewise.
7397 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
7398 (tdesc_add_typed_bitfield): Likewise.
7399 (tdesc_add_enum_value): Likewise.
7401 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7403 * common/tdesc.c (tdesc_feature::accept): Move to here.
7404 (tdesc_feature::operator==): Likewise.
7405 (tdesc_create_reg): Likewise.
7406 * common/tdesc.h (tdesc_type_kind): Likewise.
7407 (struct tdesc_type): Likewise.
7408 (struct tdesc_feature): Likewise.
7409 * regformats/regdat.sh: Create a feature.
7410 * target-descriptions.c (tdesc_type_kind): Move from here.
7411 (tdesc_type): Likewise.
7412 (tdesc_type_up): Likewise.
7413 (tdesc_feature): Likewise.
7414 (tdesc_create_reg): Likewise.
7416 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7418 * Makefile.in: Add arch/tdesc.c
7419 * common/tdesc.c: New file.
7420 * common/tdesc.h (tdesc_element_visitor): Move to here.
7421 (tdesc_element): Likewise.
7422 (tdesc_reg): Likewise.
7423 (tdesc_reg_up): Likewise.
7424 * regformats/regdef.h (reg): Add offset to constructors.
7425 * target-descriptions.c (tdesc_element_visitor): Move from here.
7426 (tdesc_element): Likewise.
7427 (tdesc_reg): Likewise.
7428 (tdesc_reg_up): Likewise.
7430 2018-04-17 Tom Tromey <tom@tromey.com>
7432 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
7435 2018-04-17 Tom Tromey <tom@tromey.com>
7437 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
7439 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
7441 * symtab.c (print_symbol_info): Skip printing filename and line
7442 number when `last' is NULL.
7443 (symtab_symbol_info): Use empty string instead of NULL for first
7444 invocation of print_symbol_info.
7445 (rbreak_command): Pass NULL to `last' parameter of
7448 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
7450 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
7453 2018-04-16 Pedro Alves <palves@redhat.com>
7455 * MAINTAINERS (sh): Remove.
7456 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
7457 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
7458 (ALLDEPFILES): Remove sh64-tdep.c.
7459 * NEWS: Mentions that support for SH-5/SH64 is removed.
7460 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
7461 (sh*-*-openbsd*): Ditto.
7462 (sh64-*-elf*): Remove.
7464 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
7465 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
7466 * sh-tdep.c: No longer include "sh64-tdep.h".
7467 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
7468 * sh64-tdep.c, sh64-tdep.h: Remove files.
7470 2018-04-16 Pedro Alves <palves@redhat.com>
7472 * MAINTAINERS: Remove m88k.
7473 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
7474 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
7475 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
7476 * NEWS: Mention that support for m88k was removed.
7477 * configure.host (m88*-*-*): Remove support.
7478 * configure.nat (m88k-*-*): Remove support.
7479 * configure.tgt (m88*-*-openbsd*): Remove.
7480 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
7482 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
7484 * configure.tgt (x86_tobjs): New variable.
7485 (amd64_tobjs, i386_tobjs): Use it.
7487 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7489 * symtab.c (print_symbol_info): Precede the symbol definition by
7490 the line number when available.
7491 * NEWS: Advertise this enhancement.
7493 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7495 * NEWS (New options): announce set/show record btrace cpu.
7496 * btrace.c: Include record-btrace.h.
7497 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
7498 the vendor is unknown.
7499 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
7500 Maybe overwrite the btrace configuration's cpu.
7501 (btrace_compute_ftrace): Add cpu parameter. Update callers.
7502 (btrace_fetch): Add cpu parameter. Update callers.
7503 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
7504 Maybe overwrite the btrace configuration's cpu. Skip enabling
7505 errata workarounds if the vendor is unknown.
7506 * python/py-record-btrace.c: Include record-btrace.h.
7507 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
7508 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
7509 * record-btrace.c (record_btrace_cpu_state_kind): New.
7510 (record_btrace_cpu): New.
7511 (set_record_btrace_cpu_cmdlist): New.
7512 (record_btrace_get_cpu): New.
7513 (require_btrace_thread, record_btrace_info)
7514 (record_btrace_resume_thread): Call record_btrace_get_cpu.
7515 (cmd_set_record_btrace_cpu_none): New.
7516 (cmd_set_record_btrace_cpu_auto): New.
7517 (cmd_set_record_btrace_cpu): New.
7518 (cmd_show_record_btrace_cpu): New.
7519 (_initialize_record_btrace): Initialize set/show record btrace cpu
7521 * record-btrace.h (record_btrace_get_cpu): New.
7523 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7525 * record.c (set_record_command): Fix typo in message.
7527 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7529 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
7531 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7533 * infrun.c (process_event_stop_test): Call
7534 gdbarch_in_indirect_branch_thunk.
7535 * gdbarch.sh (in_indirect_branch_thunk): New.
7536 * gdbarch.c: Regenerated.
7537 * gdbarch.h: Regenerated.
7540 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
7541 (HFILES_NO_SRCDIR): Add x86-tdep.h.
7542 (ALLDEPFILES): Add x86-tdep.c.
7543 * arch-utils.h (default_in_indirect_branch_thunk): New.
7544 * arch-utils.c (default_in_indirect_branch_thunk): New.
7545 * i386-tdep: Include x86-tdep.h.
7546 (i386_in_indirect_branch_thunk): New.
7547 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
7549 * amd64-tdep: Include x86-tdep.h.
7550 (amd64_in_indirect_branch_thunk): New.
7551 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7553 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7556 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7557 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7558 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7561 2018-04-12 Tom Tromey <tom@tromey.com>
7563 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7564 (rust_evaluate_subexp): Likewise.
7566 2018-04-12 Pedro Alves <palves@redhat.com>
7568 * procfs.c (procfs_detach): Make forward declaration's prototype
7569 match definition's protototype.
7570 (proc_get_LDT_entry): Remove stale do_cleanups call.
7572 2018-04-12 Pedro Alves <palves@redhat.com>
7574 * target.h (target_ops::to_has_exited): Delete.
7575 (target_has_exited): Delete.
7576 * target-delegates.c: Regenerate.
7578 2018-04-11 Pedro Alves <palves@redhat.com>
7580 * target.c (fileio_fh_t::t): Add comment.
7581 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7582 (target_fileio_close): Handle a NULL target.
7583 (invalidate_fileio_fh): New.
7584 (target_close): Call it.
7585 * remote.c (remote_hostio_send_command): No longer check whether
7586 remote_desc is open.
7588 2018-04-11 Pedro Alves <palves@redhat.com>
7590 * target.c (fileio_fh_t): Make it a named struct instead of a
7592 (fileio_fh_t::is_closed): New method.
7593 (DEF_VEC_O (fileio_fh_t)): Remove.
7594 (fileio_fhandles): Now a std::vector.
7595 (is_closed_fileio_fh): Delete.
7596 (acquire_fileio_fd): Adjust. Rename parameters.
7597 (release_fileio_fd): Adjust.
7598 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7599 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7600 (target_fileio_close): Adjust.
7602 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7604 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7607 2018-04-10 Pedro Alves <palves@redhat.com>
7609 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7610 (scoped_finish_thread_state): New class.
7611 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7613 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7614 (fetch_inferior_event, normal_stop): Likewise.
7615 * thread.c (finish_thread_state_cleanup): Delete.
7617 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7618 Pedro Alves <palves@redhat.com>
7620 * value.c: Include "selftest.h" and "common/array-view.h".
7621 (struct range) <operator ==>: New.
7622 (test_ranges_contain): New.
7623 (check_ranges_vector): New.
7624 (test_insert_into_bit_range_vector): New.
7625 (_initialize_values): Register selftests.
7626 * common/array-view.h (operator==, operator!=): New.
7628 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7630 * common/gdb_vecs.h (unordered_remove): Add overload that takes
7632 * inline-frame.c: Include <algorithm>.
7633 (struct inline_state): Add constructor.
7634 (inline_state_s): Remove.
7635 (DEF_VEC_O(inline_state_s)): Remove.
7636 (inline_states): Change type to std::vector.
7637 (find_inline_frame_state): Adjust to std::vector.
7638 (allocate_inline_frame_state): Remove.
7639 (clear_inline_frame_state): Adjust to std::vector.
7640 (skip_inline_frames): Adjust to std::vector.
7642 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7644 * tracepoint.h (struct trace_state_variable): Add constructor.
7645 <name>: Change type to std::string.
7646 * tracepoint.c (tsv_s): Remove.
7647 (DEF_VEC_O(tsv_s)): Remove.
7648 (tvariables): Change to std::vector.
7649 (create_trace_state_variable): Adjust to std::vector.
7650 (find_trace_state_variable): Likewise.
7651 (find_trace_state_variable_by_number): Likewise.
7652 (delete_trace_state_variable): Likewise.
7653 (trace_variable_command): Adjust to std::string.
7654 (delete_trace_variable_command): Likewise.
7655 (tvariables_info_1): Adjust to std::vector.
7656 (save_trace_state_variables): Likewise.
7657 (start_tracing): Likewise.
7658 (merge_uploaded_trace_state_variables): Adjust to std::vector
7660 * target.h (struct target_ops)
7661 <to_download_trace_state_variable>: Pass reference to
7662 trace_state_variable.
7663 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
7664 * target-delegates.c: Re-generate.
7665 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
7666 (mi_tsv_deleted): Likewise.
7667 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
7668 * remote.c (remote_download_trace_state_variable): Change
7669 pointer to reference and adjust.
7670 * make-target-delegates (parse_argtypes): Handle references.
7671 (write_function_header): Likewise.
7672 (munge_type): Likewise.
7674 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7676 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7677 string_view-selftests.c.
7678 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
7680 * unittests/basic_string_view/cons/char/1.cc: Likewise.
7681 * unittests/basic_string_view/cons/char/2.cc: Likewise.
7682 * unittests/basic_string_view/cons/char/3.cc: Likewise.
7683 * unittests/basic_string_view/element_access/char/1.cc:
7685 * unittests/basic_string_view/element_access/char/empty.cc:
7687 * unittests/basic_string_view/element_access/char/front_back.cc:
7689 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
7690 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
7692 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
7694 * unittests/basic_string_view/modifiers/swap/char/1.cc:
7696 * unittests/basic_string_view/operations/compare/char/1.cc:
7698 * unittests/basic_string_view/operations/compare/char/13650.cc:
7700 * unittests/basic_string_view/operations/copy/char/1.cc:
7702 * unittests/basic_string_view/operations/data/char/1.cc:
7704 * unittests/basic_string_view/operations/find/char/1.cc:
7706 * unittests/basic_string_view/operations/find/char/2.cc:
7708 * unittests/basic_string_view/operations/find/char/3.cc:
7710 * unittests/basic_string_view/operations/find/char/4.cc:
7712 * unittests/basic_string_view/operations/rfind/char/1.cc:
7714 * unittests/basic_string_view/operations/rfind/char/2.cc:
7716 * unittests/basic_string_view/operations/rfind/char/3.cc:
7718 * unittests/basic_string_view/operations/substr/char/1.cc:
7720 * unittests/basic_string_view/operators/char/2.cc: Likewise.
7721 * unittests/string_view-selftests.c: New file.
7723 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7725 * unittests/basic_string_view/capacity/1.cc: New file.
7726 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
7727 * unittests/basic_string_view/cons/char/1.cc: New file.
7728 * unittests/basic_string_view/cons/char/2.cc: New file.
7729 * unittests/basic_string_view/cons/char/3.cc: New file.
7730 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
7731 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
7732 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
7733 * unittests/basic_string_view/element_access/char/1.cc: New file.
7734 * unittests/basic_string_view/element_access/char/2.cc: New file.
7735 * unittests/basic_string_view/element_access/char/empty.cc: New file.
7736 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
7737 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
7738 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
7739 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
7740 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
7741 * unittests/basic_string_view/include.cc: New file.
7742 * unittests/basic_string_view/inserters/char/1.cc: New file.
7743 * unittests/basic_string_view/inserters/char/2.cc: New file.
7744 * unittests/basic_string_view/inserters/char/3.cc: New file.
7745 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
7746 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
7747 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
7748 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
7749 * unittests/basic_string_view/literals/types.cc: New file.
7750 * unittests/basic_string_view/literals/values.cc: New file.
7751 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
7752 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
7753 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
7754 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
7755 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
7756 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
7757 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
7758 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
7759 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
7760 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
7761 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
7762 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
7763 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
7764 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
7765 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
7766 * unittests/basic_string_view/operations/data/char/1.cc: New file.
7767 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
7768 * unittests/basic_string_view/operations/find/char/1.cc: New file.
7769 * unittests/basic_string_view/operations/find/char/2.cc: New file.
7770 * unittests/basic_string_view/operations/find/char/3.cc: New file.
7771 * unittests/basic_string_view/operations/find/char/4.cc: New file.
7772 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
7773 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
7774 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
7775 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
7776 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
7777 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
7778 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
7779 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
7780 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
7781 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
7782 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
7783 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
7784 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
7785 * unittests/basic_string_view/operators/char/2.cc: New file.
7786 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
7787 * unittests/basic_string_view/range_access/char/1.cc: New file.
7788 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
7789 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
7790 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
7791 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
7792 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
7793 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
7794 * unittests/basic_string_view/requirements/typedefs.cc: New file.
7795 * unittests/basic_string_view/typedefs.cc: New file.
7796 * unittests/basic_string_view/types/1.cc: New file.
7798 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7800 * common/gdb_string_view.h: Remove libstdc++ implementation
7801 details, adjust to gdb reality.
7802 * common/gdb_string_view.tcc: Likewise.
7803 * cli/cli-script.c (struct string_view): Remove.
7804 (user_args) <m_args>: Change element type to gdb::string_view.
7805 (user_args::insert_args): Adjust.
7807 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7809 * common/gdb_string_view.h: New file.
7810 * common/gdb_string_view.tcc: New file.
7812 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7814 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
7815 * configure: Re-generate.
7817 2018-04-09 Pedro Alves <palves@redhat.com>
7819 * gdbarch.sh: Include "observable.h" instead of "observer.h".
7820 (set_target_gdbarch): Call
7821 gdb::observers::architecture_changed.notify instead of
7822 observer_notify_architecture_changed.
7824 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7826 * tracepoint.c (struct current_traceframe_cleanup): Remove.
7827 (do_restore_current_traceframe_cleanup): Remove.
7828 (restore_current_traceframe_cleanup_dtor): Remove.
7829 (make_cleanup_restore_current_traceframe): Remove.
7830 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
7832 * tracepoint.h (struct scoped_restore_current_traceframe): New.
7833 * infrun.c (fetch_inferior_event): Use
7834 scoped_restore_current_traceframe.
7836 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7838 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
7840 <n_allocated_type_units>: Remove.
7841 <all_type_units>: Change to std::vector.
7842 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7843 to std::vector change.
7844 (dwarf2_per_objfile::get_cutu): Likewise.
7845 (dwarf2_per_objfile::get_tu): Likewise.
7846 (create_signatured_type_table_from_index): Likewise.
7847 (create_signatured_type_table_from_debug_names): Likewise.
7848 (dw2_symtab_iter_next): Likewise.
7849 (dw2_print_stats): Likewise.
7850 (dw2_expand_all_symtabs): Likewise.
7851 (dw2_expand_marked_cus): Likewise.
7852 (dw2_debug_names_iterator::next): Likewise.
7853 (dwarf2_initialize_objfile): Likewise.
7854 (add_signatured_type_cu_to_table): Likewise.
7855 (create_all_type_units): Likewise.
7856 (add_type_unit): Likewise.
7857 (struct tu_abbrev_offset): Add constructor.
7858 (build_type_psymtabs_1): Adjust to std::vector change.
7859 (print_tu_stats): Likewise.
7860 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7861 (write_debug_names): Likewise.
7863 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7865 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
7866 Make an std::vector.
7867 <n_comp_units>: Remove.
7868 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7869 to std::vector change.
7870 (dwarf2_per_objfile::get_cutu): Likewise.
7871 (dwarf2_per_objfile::get_cu): Likewise.
7872 (create_cus_from_index): Likewise.
7873 (create_addrmap_from_index): Likewise.
7874 (create_addrmap_from_aranges): Likewise.
7875 (dwarf2_read_index): Likewise.
7876 (dw2_find_last_source_symtab): Likewise.
7877 (dw2_map_symtabs_matching_filename): Likewise.
7878 (dw2_symtab_iter_next): Likewise.
7879 (dw2_print_stats): Likewise.
7880 (dw2_expand_all_symtabs): Likewise.
7881 (dw2_expand_symtabs_with_fullname): Likewise.
7882 (dw2_expand_marked_cus): Likewise.
7883 (dw2_map_symbol_filenames): Likewise.
7884 (create_cus_from_debug_names): Likewise.
7885 (dwarf2_read_debug_names): Likewise.
7886 (dw2_debug_names_iterator::next): Likewise.
7887 (dwarf2_initialize_objfile): Likewise.
7888 (set_partial_user): Likewise.
7889 (dwarf2_build_psymtabs_hard): Likewise.
7890 (read_comp_units_from_section): Remove arguments, adjust to
7892 (create_all_comp_units): Adjust to std::vector and
7893 read_comp_units_from_section changes.
7894 (dwarf2_find_containing_comp_unit): Adjust to std::vector
7896 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7897 (psyms_seen_size): Likewise.
7898 (write_gdbindex): Likewise.
7899 (write_debug_names): Likewise.
7901 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7903 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
7904 with dwarf2_per_objfile.
7905 (create_cus_from_index): Likewise.
7906 (create_signatured_type_table_from_index): Likewise.
7907 (dwarf2_read_index): Likewise.
7908 (dwarf2_initialize_objfile): Likewise.
7909 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
7910 per_cu rather than get_dwarf2_per_objfile.
7912 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7914 * dwarf2read.h (struct signatured_type): Forward declare.
7915 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
7917 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
7918 (dw2_get_cutu): ...this.
7919 (dwarf2_per_objfile::get_cu): Rename from...
7920 (dw2_get_cu): ...this.
7921 (dwarf2_per_objfile::get_tu): New.
7922 (create_addrmap_from_index): Adjust.
7923 (create_addrmap_from_aranges): Adjust.
7924 (dw2_find_last_source_symtab): Adjust.
7925 (dw2_map_symtabs_matching_filename): Adjust.
7926 (dw2_symtab_iter_next): Adjust.
7927 (dw2_print_stats): Adjust.
7928 (dw2_expand_all_symtabs): Adjust.
7929 (dw2_expand_symtabs_with_fullname): Adjust.
7930 (dw2_expand_marked_cus): Adjust.
7931 (dw_expand_symtabs_matching_file_matcher): Adjust.
7932 (dw2_map_symbol_filenames): Adjust.
7933 (dw2_debug_names_iterator::next): Adjust.
7934 (dwarf2_initialize_objfile): Adjust.
7935 (set_partial_user): Adjust.
7936 (dwarf2_build_psymtabs_hard): Adjust.
7938 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7940 * dwarf2read.c (create_signatured_type_table_from_debug_names):
7941 Remove unused variables.
7942 (dw2_map_symtabs_matching_filename): Likewise.
7943 (dwarf2_record_block_ranges): Likewise.
7944 (dwarf2_read_addr_index): Likewise.
7945 (follow_die_offset): Likewise.
7947 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7949 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
7950 to symbol_file_add_main.
7952 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7955 * mi/mi-console.c (do_fputc_async_safe): New.
7956 (mi_console_file::write_async_safe): New.
7957 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
7958 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
7960 * ui-file.c (ui_file::putstrn): Adjust call to
7961 fputstrn_unfiltered.
7962 * utils.c (printchar): Replace do_fputs and do_fprintf
7963 parameters by do_fputc.
7964 (fputstr_filtered): Adjust call to printchar.
7965 (fputstr_unfiltered): Likewise.
7966 (fputstrn_filtered): Likewise.
7967 (fputstrn_unfiltered): Add do_fputc parameter, pass to
7969 * utils.h (do_fputc_ftype): New typedef.
7970 (fputstrn_unfiltered): Add do_fputc parameter.
7972 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7974 * regformats/i386/i386-avx.dat: Remove.
7976 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7979 * amd64-tdep.c (amd64_none_init_abi): New function.
7980 (amd64_x32_none_init_abi): New function.
7981 (_initialize_amd64_tdep): Register handlers for x86-64 and
7982 x64_32 with GDB_OSABI_NONE.
7983 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
7984 GDB_OSABI_NONE osabi.
7986 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7989 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
7991 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
7992 * osabi.c (gdb_osabi_names): Add "unknown" entry.
7994 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7996 * common/byte-vector.h (char_vector): New type.
7997 * target.h (target_read_alloc): Return
7998 gdb::optional<byte_vector>.
7999 (target_read_stralloc): Return gdb::optional<char_vector>.
8000 (target_get_osdata): Return gdb::optional<char_vector>.
8001 * target.c (target_read_alloc_1): Templatize. Replacement
8002 manual memory management with vector.
8003 (target_read_alloc): Change return type, adjust.
8004 (target_read_stralloc): Change return type, adjust.
8005 (target_get_osdata): Change return type, adjust.
8006 * auxv.c (struct auxv_info) <length>: Remove.
8007 <data>: Change type to gdb::optional<byte_vector>.
8008 (auxv_inferior_data_cleanup): Free auxv_info with delete.
8009 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
8010 (target_auxv_search): Adjust.
8011 (fprint_target_auxv): Adjust.
8012 * avr-tdep.c (avr_io_reg_read_command): Adjust.
8013 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
8014 (linux_make_corefile_notes): Adjust.
8015 * osdata.c (get_osdata): Adjust.
8016 * remote.c (remote_get_threads_with_qxfer): Adjust.
8017 (remote_memory_map): Adjust.
8018 (remote_traceframe_info): Adjust.
8019 (btrace_read_config): Adjust.
8020 (remote_read_btrace): Adjust.
8021 (remote_pid_to_exec_file): Adjust.
8022 * solib-aix.c (solib_aix_get_library_list): Adjust.
8023 * solib-dsbt.c (decode_loadmap): Don't free buf.
8024 (dsbt_get_initial_loadmaps): Adjust.
8025 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
8026 * solib-target.c (solib_target_current_sos): Adjust.
8027 * tracepoint.c (sdata_make_value): Adjust.
8028 * xml-support.c (xinclude_start_include): Adjust.
8029 (xml_fetch_content_from_file): Adjust.
8030 * xml-support.h (xml_fetch_another): Change return type.
8031 (xml_fetch_content_from_file): Change return type.
8032 * xml-syscall.c (xml_init_syscalls_info): Adjust.
8033 * xml-tdesc.c (file_read_description_xml): Adjust.
8034 (fetch_available_features_from_target): Change return type.
8035 (target_fetch_description_xml): Adjust.
8036 (target_read_description_xml): Adjust.
8038 2018-04-06 Tom Tromey <tom@tromey.com>
8040 * value.c (~value): Update.
8041 (struct value) <contents>: Now unique_xmalloc_ptr.
8042 (value_contents_bits_eq, allocate_value_contents)
8043 (value_contents_raw, value_contents_all_raw)
8044 (value_contents_for_printing, value_contents_for_printing_const)
8045 (set_value_enclosing_type): Update.
8047 2018-04-06 Tom Tromey <tom@tromey.com>
8049 * value.c (range_s): Remove typedef, VEC.
8050 (struct range): Add operator<.
8051 (range_lessthan): Remove.
8052 (ranges_contain): Change type.
8054 (struct value) <unavailable, optimized_out>: Now std::vector.
8055 (value_entirely_available)
8056 (value_entirely_covered_by_range_vector)
8057 (value_entirely_unavailable, value_entirely_optimized_out):
8059 (insert_into_bit_range_vector): Change argument type.
8060 (find_first_range_overlap): Likewise.
8061 (struct ranges_and_idx, value_contents_bits_eq)
8062 (require_not_optimized_out, require_available): Update.
8063 (ranges_copy_adjusted): Change argument types.
8064 (value_optimized_out, value_copy, value_fetch_lazy): Update.
8066 2018-04-06 Tom Tromey <tom@tromey.com>
8068 * value.c (~value): Update.
8069 (struct value) <parent>: Now a value_ref_ptr.
8070 (value_parent, set_value_parent, value_address, value_copy):
8073 2018-04-06 Tom Tromey <tom@tromey.com>
8075 * value.c (struct value): Add constructor, destructor, and member
8077 (allocate_value_lazy, value_decref): Update.
8079 2018-04-06 Tom Tromey <tom@tromey.com>
8081 * value.c (struct value) <released, next>: Remove.
8082 (all_values): Now a std::vector.
8083 (allocate_value_lazy): Update.
8084 (value_next): Remove.
8085 (value_mark, value_free_to_mark, release_value)
8086 (value_release_to_mark): Update.
8088 2018-04-06 Tom Tromey <tom@tromey.com>
8090 * value.h (fetch_subexp_value, value_release_to_mark): Update.
8091 (free_value_chain): Remove.
8092 * value.c (free_value_chain): Remove.
8093 (value_release_to_mark): Return a std::vector.
8094 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
8096 (check_condition): Update.
8097 * eval.c (fetch_subexp_value): Change "val_chain" to a
8099 * breakpoint.c (update_watchpoint): Update.
8100 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
8102 2018-04-06 Tom Tromey <tom@tromey.com>
8104 * value.h (free_all_values): Remove.
8105 * value.c (free_all_values): Remove.
8107 2018-04-06 Tom Tromey <tom@tromey.com>
8109 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
8110 (value_history_chain, value_history_count): Remove.
8111 (value_history): New global.
8112 (record_latest_value, access_value_history, show_values)
8113 (preserve_values): Update.
8115 2018-04-06 Tom Tromey <tom@tromey.com>
8117 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
8118 * varobj.c (varobj_set_display_format, varobj_set_value)
8119 (install_default_visualizer, construct_visualizer)
8120 (install_new_value, ~varobj, varobj_get_value_type)
8121 (my_value_of_variable, varobj_editable_p): Update.
8122 * c-varobj.c (c_describe_child, c_value_of_variable)
8123 (cplus_number_of_children, cplus_describe_child): Update.
8124 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
8125 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
8126 (ada_value_of_variable, ada_value_is_changeable_p): Update.
8128 2018-04-06 Tom Tromey <tom@tromey.com>
8130 * printcmd.c (last_examine_address): Change type to
8132 (do_examine, x_command): Update.
8134 2018-04-06 Tom Tromey <tom@tromey.com>
8136 * value.c (release_value): Update.
8137 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
8138 (struct bpstats) <val>: Now a value_ref_ptr.
8139 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8140 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8141 (~watchpoint, print_it_watchpoint, watch_command_1)
8142 (invalidate_bp_value_on_memory_change): Update.
8144 2018-04-06 Tom Tromey <tom@tromey.com>
8146 * varobj.c (varobj_clear_saved_item)
8147 (update_dynamic_varobj_children, install_new_value, ~varobj):
8149 * value.h (value_incref): Move declaration earlier.
8150 (value_decref): Rename from value_free.
8151 (struct value_ref_policy): New.
8152 (value_ref_ptr): New typedef.
8153 (struct value_deleter): Remove.
8154 (gdb_value_up): Remove typedef.
8155 (release_value): Change return type.
8156 (release_value_or_incref): Remove.
8157 * value.c (set_value_parent): Update.
8158 (value_incref): Change return type.
8159 (value_decref): Rename from value_free.
8160 (value_free_to_mark, free_all_values, free_value_chain): Update.
8161 (release_value): Return value_ref_ptr.
8162 (release_value_or_incref): Remove.
8163 (record_latest_value, set_internalvar, clear_internalvar):
8165 * stack.c (info_frame_command): Don't call value_free.
8166 * python/py-value.c (valpy_dealloc, valpy_new)
8167 (value_to_value_object): Update.
8168 * printcmd.c (do_examine): Update.
8169 * opencl-lang.c (lval_func_free_closure): Update.
8170 * mi/mi-main.c (register_changed_p): Don't call value_free.
8171 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
8172 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
8173 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
8175 * guile/scm-value.c (vlscm_free_value_smob)
8176 (vlscm_scm_from_value): Update.
8177 * frame.c (frame_register_unwind, frame_unwind_register_signed)
8178 (frame_unwind_register_unsigned, get_frame_register_bytes)
8179 (put_frame_register_bytes): Don't call value_free.
8180 * findvar.c (address_from_register): Don't call value_free.
8181 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
8182 * dwarf2loc.c (entry_data_value_free_closure)
8183 (value_of_dwarf_reg_entry, free_pieced_value_closure)
8184 (dwarf2_evaluate_loc_desc_full): Update.
8185 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
8186 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
8187 (~watchpoint, watch_command_1)
8188 (invalidate_bp_value_on_memory_change): Update.
8189 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
8191 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
8194 * warning.m4: Add -Wno-error=deprecated-register.
8195 * configure: Re-generate.
8197 2018-04-05 Tom Tromey <tom@tromey.com>
8199 * linespec.h: Remove include of "vec.h".
8201 2018-04-05 Tom Tromey <tom@tromey.com>
8203 * linespec.c (typep): Remove typedef.
8204 (find_methods, find_superclass_methods): Take a std::vector.
8205 (find_method): Use std::vector.
8207 2018-04-05 Tom Tromey <tom@tromey.com>
8209 * utils.c (compare_strings): Remove.
8210 * utils.h (compare_strings): Remove.
8211 * objc-lang.h (find_imps): Update.
8212 * objc-lang.c (find_methods): Take a std::vector.
8213 (uniquify_strings, find_imps): Likewise.
8214 * linespec.c (find_methods): Take a std::vector.
8215 (decode_objc): Use std::vector.
8216 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
8218 (find_method, find_function_symbols): Use std::vector.
8220 2018-04-05 Tom Tromey <tom@tromey.com>
8222 * completer.c (completion_tracker::completion_tracker): Remove
8224 (completion_tracker::discard_completions): Likewise.
8225 * breakpoint.c (ambiguous_names_p): Remove cast.
8226 * ada-lang.c (_initialize_ada_language): Remove cast.
8227 * utils.h (streq): Update.
8228 (streq_hash): Add new declaration.
8229 * utils.c (streq): Return bool.
8230 (streq_hash): New function.
8232 2018-04-05 Tom Tromey <tom@tromey.com>
8234 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
8235 Remove a string copy.
8237 2018-04-05 Tom Tromey <tom@tromey.com>
8239 * linespec.c (filter_results): Use std::vector.
8240 (decode_line_2, decode_line_full): Update.
8242 2018-04-05 Tom Tromey <tom@tromey.com>
8244 * linespec.c (canonical_to_fullform): Return std::string.
8245 (filter_results): Update.
8246 (struct decode_line_2_item): Add constructor.
8247 <fullform, displayform>: Now std::string.
8248 (decode_line_2_compare_items): Now a std::sort comparator.
8249 (decode_line_2): Update.
8251 2018-04-05 Tom Tromey <tom@tromey.com>
8253 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
8254 (unexpected_linespec_error): Update.
8255 (linespec_parse_basic, parse_linespec): Update.
8257 2018-04-05 Tom Tromey <tom@tromey.com>
8259 * linespec.c (linespec_parse_basic): Reindent.
8261 2018-04-05 Tom Tromey <tom@tromey.com>
8263 * minsyms.h (iterate_over_minimal_symbols): Update.
8264 * minsyms.c (iterate_over_minimal_symbols): Take a
8266 * linespec.c (struct collect_minsyms): Remove.
8267 (compare_msyms): Now a std::sort comparator.
8268 (add_minsym): Add parameters.
8269 (search_minsyms_for_name): Update. Use std::vector.
8271 2018-04-03 Tom Tromey <tom@tromey.com>
8273 * mipsread.c (read_alphacoff_dynamic_symtab): Use
8276 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
8278 * MAINTAINERS (Write After Approval): Add Weimin Pan.
8280 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
8283 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
8284 printing static type.
8286 2018-04-01 Tom Tromey <tom@tromey.com>
8288 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
8289 (rs6000_xfer_shared_libraries): Update.
8291 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
8293 * common/gdb_vecs.h (char_ptr): Remove.
8294 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
8296 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8298 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
8300 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
8302 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8304 * tracepoint.h (struct uploaded_tp): Initialize fields.
8305 <actions, step_actions, cmd_strings>: Change type to
8306 std::vector<char *>.
8307 * tracepoint.c (get_uploaded_tp): Allocate with new.
8308 (free_uploaded_tps): Free with delete.
8309 (parse_tracepoint_definition): Adjust to std::vector change.
8310 * breakpoint.c (read_uploaded_action): Likewise.
8311 (create_tracepoint_from_upload): Likewise.
8312 * ctf.c (ctf_write_uploaded_tp): Likewise.
8313 (SET_ARRAY_FIELD): Likewise.
8314 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
8316 2018-03-30 Tom Tromey <tom@tromey.com>
8318 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
8320 (svr4_keep_data_in_core): Update.
8321 (svr4_read_so_list): Update.
8323 2018-03-30 Tom Tromey <tom@tromey.com>
8325 * windows-nat.c (handle_output_debug_string, handle_exception):
8327 * target.h (target_read_string): Update.
8328 * target.c (target_read_string): Change "string" to
8330 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8332 * solib-frv.c (frv_current_sos): Update.
8333 * solib-dsbt.c (dsbt_current_sos): Update.
8334 * solib-darwin.c (darwin_current_sos): Update.
8335 * linux-thread-db.c (inferior_has_bug): Update.
8336 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
8337 Update. Remove alloca.
8338 * ada-lang.c (ada_main_name): Update.
8340 2018-03-30 Tom Tromey <tom@tromey.com>
8342 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
8343 (struct dwo_file_deleter): New.
8344 (dwo_file_up): New typedef.
8345 (open_and_init_dwo_file): Use dwo_file_up.
8346 (free_dwo_file_cleanup): Remove.
8348 2018-03-30 Tom Tromey <tom@tromey.com>
8350 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
8351 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
8353 2018-03-30 Tom Tromey <tom@tromey.com>
8355 * dwarf2read.c (class free_cached_comp_units): New class.
8356 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
8357 (free_cached_comp_units): Remove function.
8359 2018-03-30 Tom Tromey <tom@tromey.com>
8361 * utils.h (make_cleanup_unpush_target): Remove.
8362 * inf-ptrace.c (struct target_unpusher): New.
8363 (target_unpush_up) New typedef.
8364 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
8366 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
8368 2018-03-27 Tom Tromey <tom@tromey.com>
8370 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
8372 2018-03-27 Pedro Alves <palves@redhat.com>
8373 Tom Tromey <tom@tromey.com>
8375 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
8376 destructor. Now a class.
8377 (gdb_readline_wrapper_cleanup): Remove function.
8378 (gdb_readline_wrapper): Remove cleanups.
8380 2018-03-27 Tom Tromey <tom@tromey.com>
8382 * typeprint.h (struct type_print_options) <local_typedefs,
8383 global_typedefs>: Remove "struct" keyword.
8384 (class typedef_hash_table): New class.
8385 (recursively_update_typedef_hash, add_template_parameters)
8386 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
8387 (find_typedef_in_hash): Don't declare.
8388 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
8389 (typedef_hash_table::recursively_update): Rename from
8390 recursively_update_typedef_hash. Now a member.
8391 (typedef_hash_table::add_template_parameters): Rename from
8392 add_template_parameters. Now a member.
8393 (typedef_hash_table::typedef_hash_table): Now a constructor;
8394 rename from create_typedef_hash.
8395 (typedef_hash_table::~typedef_hash_table): Now a destructor;
8396 rename from free_typedef_hash.
8397 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
8398 (do_free_global_table): Remove.
8399 (typedef_hash_table::typedef_hash_table): New constructor; renamed
8400 from copy_type_recursive.
8401 (create_global_typedef_table): Remove.
8402 (typedef_hash_table::find_global_typedef): Now a member of
8404 (typedef_hash_table::find_typedef): Rename from
8405 find_typedef_in_hash; now a member.
8406 (whatis_exp): Update.
8407 * extension.h (struct ext_lang_type_printers): Add constructor and
8409 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
8411 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
8412 Now a constructor; rename from start_ext_lang_type_printers.
8413 (ext_lang_type_printers): Now a destructor; rename from
8414 free_ext_lang_type_printers.
8415 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
8417 (c_type_print_base_struct_union): Update. Remove cleanups.
8419 2018-03-27 Tom Tromey <tom@tromey.com>
8421 * dwarf-index-write.c: Include <cmath>.
8423 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8425 * NEWS: Add entry describing new "set|show varsize-limit" command.
8426 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
8428 * printcmd.c (_initialize_printcmd): Add "set var" alias of
8431 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
8433 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
8435 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
8436 * dwarf-index-common.c: New file.
8437 * dwarf-index-common.h: New file.
8438 * dwarf-index-write.c: New file.
8439 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
8440 (struct dwarf2_section_info): Move from here.
8441 (dwarf2_section_info_def): Likewise.
8442 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
8443 (offset_type): Likewise.
8444 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
8445 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
8446 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
8447 (byte_swap): Likewise.
8448 (MAYBE_SWAP): Likewise.
8449 (dwarf2_per_cu_ptr): Likewise.
8450 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
8451 (struct tu_stats): Likewise.
8452 (struct dwarf2_per_objfile): Likewise.
8453 (struct dwarf2_per_cu_data): Likewise.
8454 (struct signatured_type): Likewise.
8455 (sig_type_ptr): Likewise.
8456 (DEF_VEC_P (sig_type_ptr)): Likewise.
8457 (INDEX4_SUFFIX): Likewise.
8458 (INDEX5_SUFFIX): Likewise.
8459 (DEBUG_STR_SUFFIX): Likewise.
8460 (dwarf2_read_section): Make non-static.
8461 (mapped_index_string_hash): Move from here.
8462 (dwarf5_djb_hash): Likewise.
8463 (file_write): Likewise.
8464 (class data_buf): Likewise.
8465 (struct symtab_index_entry): Likewise.
8466 (struct mapped_symtab): Likewise.
8467 (find_slot): Likewise.
8468 (hash_expand): Likewise.
8469 (add_index_entry): Likewise.
8470 (uniquify_cu_indices): Likewise.
8471 (class c_str_view): Likewise.
8472 (class c_str_view_hasher): Likewise.
8473 (class vector_hasher): Likewise.
8474 (write_hash_table): Likewise.
8475 (psym_index_map): Likewise.
8476 (struct addrmap_index_data): Likewise.
8477 (add_address_entry): Likewise.
8478 (add_address_entry_worker): Likewise.
8479 (write_address_map): Likewise.
8480 (symbol_kind): Likewise.
8481 (write_psymbols): Likewise.
8482 (struct signatured_type_index_data): Likewise.
8483 (write_one_signatured_type): Likewise.
8484 (recursively_count_psymbols): Likewise.
8485 (recursively_write_psymbols): Likewise.
8486 (class debug_names): Likewise.
8487 (check_dwarf64_offsets): Likewise.
8488 (psyms_seen_size): Likewise.
8489 (write_gdbindex): Likewise.
8490 (write_debug_names): Likewise.
8491 (assert_file_size): Likewise.
8492 (write_psymtabs_to_index): Likewise.
8493 (save_gdb_index_command): Likewise.
8494 (_initialize_dwarf2_read): Don't register the "save gdb-index"
8496 * dwarf2read.h: New file.
8498 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8501 * dwarf2read.c (dwarf2_physname): Do not return the demangled
8502 symbol name if the CU's language stores symbol names in linkage
8504 * language.h (struct language_defn)
8505 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
8506 all instances of this struct.
8508 2018-03-26 Tom Tromey <tom@tromey.com>
8510 * stack.c (backtrace_command_1): Remove verbose code.
8512 2018-03-26 Tom Tromey <tom@tromey.com>
8514 * python/py-framefilter.c (py_print_type): Don't catch
8515 exceptions. Return void.
8516 (py_print_value): Likewise.
8517 (py_print_single_arg): Likewise.
8518 (enumerate_args): Don't catch exceptions.
8519 (py_print_args): Likewise.
8520 (py_print_frame): Likewise.
8521 (gdbpy_apply_frame_filter): Catch exceptions here.
8523 2018-03-26 Tom Tromey <tom@tromey.com>
8525 * stack.c (_initialize_stack): Remove trailing newlines from help
8526 text. Add "Usage" line to "backtrace" help.
8528 2018-03-26 Tom Tromey <tom@tromey.com>
8531 * python/py-framefilter.c (py_print_args): Call wrap_hint.
8533 2018-03-26 Tom Tromey <tom@tromey.com>
8535 * python/py-framefilter.c (py_print_single_arg): Return
8536 EXT_LANG_BT_ERROR from catch.
8538 2018-03-26 Tom Tromey <tom@tromey.com>
8541 * stack.c (backtrace_command_1): Move some code into no-filters
8544 2018-03-26 Tom Tromey <tom@tromey.com>
8546 * python/py-framefilter.c (throw_quit_or_print_exception): New
8548 (gdbpy_apply_frame_filter): Use it.
8550 2018-03-26 Tom Tromey <tom@tromey.com>
8553 * python/py-framefilter.c (py_print_type, py_print_value)
8554 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8557 2018-03-26 Tom Tromey <tom@tromey.com>
8559 * python/py-framefilter.c (enumerate_args): Use
8560 gdb::unique_xmalloc_ptr.
8562 2018-03-26 Tom Tromey <tom@tromey.com>
8564 * python/py-framefilter.c (py_print_frame): Return
8566 (gdbpy_apply_frame_filter): Update comment.
8567 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8569 <EXT_LANG_BT_NO_FILTERS>: Change value.
8571 2018-03-26 Tom Tromey <tom@tromey.com>
8574 * stack.c (backtrace_command): Parse "hide" argument.
8575 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8576 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8579 2018-03-26 Tom Tromey <tom@tromey.com>
8581 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8583 (backtrace_command): Remove "fulltrace", add "flags".
8585 2018-03-26 Tom Tromey <tom@tromey.com>
8587 * stack.c (backtrace_command): Rewrite command line parsing.
8589 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8591 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8593 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8595 * filename-seen-cache.h: Add include guard.
8597 2018-03-26 Keith Seitz <keiths@redhat.com>
8599 * symfile.c (place_section): Remove "struct" from section_addr_info
8601 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8602 "struct" keyword from section_addr_info.
8604 2018-03-26 Alan Hayward <alan.hayward@arm.com>
8606 * regformats/regdef.h (reg): Add constructors.
8608 2018-03-25 Pedro Alves <palves@redhat.com>
8610 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8611 if then/else bodies in var_func_name extraction.
8613 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
8615 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8616 lookup_minimal_symbol() to find symbol entry.
8617 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8619 2018-03-23 Keith Seitz <keiths@redhat.com>
8622 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8623 nested type definitions for C++, too.
8625 2018-03-23 Tom Tromey <tom@tromey.com>
8627 * machoread.c (struct oso_el): Add a constructor. Don't define as
8629 (macho_register_oso): Remove.
8630 (macho_symtab_read): Take a std::vector.
8631 (oso_el_compare_name): Now a std::sort comparator.
8632 (macho_symfile_read_all_oso): Take a std::vector.
8633 (macho_symfile_read): Use std::vector. Remove cleanups.
8635 2018-03-22 Tom Tromey <tom@tromey.com>
8637 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
8638 (record_full_goto_bookmark): Use std::string.
8640 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8643 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
8646 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8648 * rs6000-tdep.c (store_insn_p): New function.
8649 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
8650 and cr_reg to their unshifted values. Use store_insn_p to
8651 match LR saves using either R1 or fdata->alloca_reg. Use
8652 store_insn_p to match CR saves. Set alloca_reg_offset
8653 when alloca_reg and framep are set. Remove lr_reg shift
8654 when assigning to fdata->lr_register.
8656 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
8658 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
8659 command line args instead of emitting a warning.
8661 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8663 * tracepoint.h (struct static_tracepoint_marker): Initialize
8664 fields, define default constructor, move constructor and move
8665 assignment, disable the rest.
8666 <str_id, extra>: Make std::string.
8667 (release_static_tracepoint_marker): Remove.
8668 (free_current_marker): Remove.
8669 * tracepoint.c (free_current_marker): Remove.
8670 (parse_static_tracepoint_marker_definition): Adjust to
8671 std::string, use new hex2str overload.
8672 (release_static_tracepoint_marker): Remove.
8673 (print_one_static_tracepoint_marker): Get marker by reference
8674 and adjust to std::string.
8675 (info_static_tracepoint_markers_command): Adjust to std::vector
8677 * target.h (static_tracepoint_marker_p): Remove typedef.
8678 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
8679 (struct target_ops) <to_static_tracepoint_marker_at>: Return
8681 <to_static_tracepoint_markers_by_strid>: Return std::vector.
8683 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
8684 (target_debug_print_std_vector_static_tracepoint_marker): New.
8685 (target_debug_print_struct_static_tracepoint_marker_p): Rename
8687 (target_debug_print_static_tracepoint_marker_p): ... this.
8688 * target-delegates.c: Re-generate.
8689 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
8691 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
8692 (decode_static_tracepoint_spec): Adjust to std::vector.
8693 (tracepoint_print_one_detail): Adjust to std::string.
8694 (strace_marker_decode_location): Adjust to std::string.
8695 (update_static_tracepoint): Adjust to std::string, remove call
8696 to release_static_tracepoint_marker.
8697 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
8698 Adjust to std::vector.
8699 * remote.c (remote_static_tracepoint_marker_at): Return bool.
8700 (remote_static_tracepoint_markers_by_strid): Adjust to
8702 * common/rsp-low.h (hex2str): New overload with explicit count
8704 * common/rsp-low.c (hex2str): New overload with explicit count
8706 * unittests/rsp-low-selftests.c (test_hex2str): New function.
8707 (_initialize_rsp_low_selftests): Add test_hex2str test.
8708 * unittests/tracepoint-selftests.c
8709 (test_parse_static_tracepoint_marker_definition): Adjust to
8712 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8714 * tracepoint.c (parse_static_tracepoint_marker_definition):
8715 Consider case where the definition is followed by more
8717 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8718 tracepoint-selftests.c.
8719 * unittests/tracepoint-selftests.c: New.
8721 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8723 * MAINTAINERS (Write After Approval): Add Pedro Franco de
8726 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8728 * symtab.c (find_pc_sect_line): fixed indentation.
8730 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8732 * symtab.c (find_pc_sect_line): now uses binary search.
8734 2018-03-19 Tom Tromey <tom@tromey.com>
8736 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
8739 2018-03-19 Pedro Alves <palves@redhat.com>
8740 Tom Tromey <tom@tromey.com>
8742 * unittests/observable-selftests.c: New file.
8743 * common/observable.h: New file.
8744 * observable.h: New file.
8745 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
8746 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
8747 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
8748 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
8749 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
8750 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
8751 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
8752 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
8753 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
8754 python/py-breakpoint.c, python/py-finishbreakpoint.c,
8755 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
8756 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
8757 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
8758 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
8759 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
8760 tui/tui-interp.c, valops.c: Update all users.
8761 * tui/tui-hooks.c (tui_bp_created_observer)
8762 (tui_bp_deleted_observer, tui_bp_modified_observer)
8763 (tui_inferior_exit_observer, tui_before_prompt_observer)
8764 (tui_normal_stop_observer, tui_register_changed_observer):
8766 (tui_observers_token): New global.
8767 (attach_or_detach, tui_attach_detach_observers): New functions.
8768 (tui_install_hooks, tui_remove_hooks): Use
8769 tui_attach_detach_observers.
8770 * record-btrace.c (record_btrace_thread_observer): Remove.
8771 (record_btrace_thread_observer_token): New global.
8772 * observer.sh: Remove.
8773 * observer.c: Rename to observable.c.
8774 * observable.c (namespace gdb_observers): Define new objects.
8775 (observer_debug): Move into gdb_observers namespace.
8776 (struct observer, struct observer_list, xalloc_observer_list_node)
8777 (xfree_observer_list_node, generic_observer_attach)
8778 (generic_observer_detach, generic_observer_notify): Remove.
8779 (_initialize_observer): Update.
8780 Don't include observer.inc.
8781 * Makefile.in (generated_files): Remove observer.h, observer.inc.
8782 (clean mostlyclean): Likewise.
8783 (observer.h, observer.inc): Remove targets.
8784 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
8785 (COMMON_SFILES): Use observable.c, not observer.c.
8786 * .gitignore: Remove observer.h.
8788 2018-03-18 Tom Tromey <tom@tromey.com>
8790 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
8792 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
8794 2018-03-17 Tom Tromey <tom@tromey.com>
8796 * auto-load.c (auto_load_objfile_script_1): Use std::string.
8798 2018-03-17 Tom Tromey <tom@tromey.com>
8800 * target.c (class scoped_target_fd): New.
8801 (target_fileio_close_cleanup): Remove.
8802 (target_fileio_read_alloc_1): Use scoped_target_fd.
8804 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
8806 * silent-rules.mk: New.
8807 * Makefile.in: Include silent-rules.mk
8808 (srcdir, VPATH, top_srcdir): Move up.
8809 (COMPILE): Add ECHO_CXX.
8810 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
8811 (init.c): Add ECHO_INIT_C.
8812 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
8813 (version.c): Add ECHO_GEN.
8814 (printcmd.o): Add ECHO_CXX.
8815 (target-float.o): Add ECHO_CXX.
8816 (ada-exp.o): Add ECHO_CXX.
8817 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
8818 (insight$(EXEEXT)): Add ECHO_CXXLD.
8819 * gnulib/configure.ac: Add AM_SILENT_RULES.
8820 * gnulib/aclocal.m4: Re-generate.
8821 * gnulib/configure: Re-generate.
8822 * gnulib/import/Makefile.in: Re-generate.
8824 2018-03-16 Tom Tromey <tom@tromey.com>
8826 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
8827 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
8828 * utils.c (do_free_section_addr_info)
8829 (make_cleanup_free_section_addr_info): Remove.
8830 * symfile.h (struct other_sections): Add constructor.
8831 (struct section_addr_info): Remove.
8832 (section_addr_info): New typedef.
8833 (struct sym_fns) <sym_offsets>: Change type of parameter.
8834 (build_section_addr_info_from_objfile)
8835 (relative_addr_info_to_section_offsets, addr_info_make_relative)
8836 (default_symfile_offsets, symbol_file_add)
8837 (symbol_file_add_from_bfd)
8838 (build_section_addr_info_from_section_table): Update.
8839 (alloc_section_addr_info, free_section_addr_info): Don't declare.
8840 * symfile.c (alloc_section_addr_info): Remove.
8841 (build_section_addr_info_from_section_table): Change return type.
8843 (build_section_addr_info_from_bfd)
8844 (build_section_addr_info_from_objfile): Likewise.
8845 (free_section_addr_info): Remove.
8846 (relative_addr_info_to_section_offsets): Change type of "addrs".
8847 (addrs_section_compar): Now a std::sort comparator.
8848 (addrs_section_sort): Change return type.
8849 (addr_info_make_relative): Change type of "addrs". Update.
8850 (default_symfile_offsets, syms_from_objfile_1)
8851 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
8852 (symbol_file_add_separate): Update.
8853 (symbol_file_add): Change type of "addrs". Update.
8854 (add_symbol_file_command): Update. Remove cleanups.
8855 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
8857 * symfile-debug.c (debug_sym_offsets): Change type of "info".
8858 * solib.c (solib_read_symbols): Update.
8859 * objfiles.c (objfile_relocate): Update. Remove cleanups.
8860 * machoread.c (macho_symfile_offsets): Update.
8861 * jit.c (jit_bfd_try_read_symtab): Update.
8863 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
8865 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8866 unittests/utils-selftests.c.
8867 * unittests/utils-selftests.c: New file.
8869 2018-03-14 Tom Tromey <tom@tromey.com>
8872 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
8875 2018-03-14 Tom Tromey <tom@tromey.com>
8878 * printcmd.c (printf_pointer): Allow "-" in format.
8880 2018-03-14 Tom Tromey <tom@tromey.com>
8882 * printcmd.c (_initialize_printcmd): Add usage to printf.
8884 2018-03-14 Yao Qi <qiyao@sourceware.org>
8886 * MAINTAINERS: Update my email address.
8888 2018-03-13 Tom Tromey <tom@tromey.com>
8890 * machoread.c (macho_check_dsym): Change filenamep to a
8892 (macho_symfile_read): Update.
8893 * symfile.c (load_command): Use std::string.
8895 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
8897 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
8898 to error message string.
8899 (riscv_register_name): Use xsnprintf instead of sprintf.
8900 (riscv_insn::fetch_instruction): Use gdb_assert instead of
8902 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
8904 (riscv_push_dummy_call): Likewise.
8906 2018-03-12 Tom Tromey <tom@tromey.com>
8908 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
8909 Use gdb::byte_vector.
8910 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
8912 2018-03-12 Yao Qi <yao.qi@linaro.org>
8914 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
8915 parameter type to readable_regcache.
8916 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
8919 2018-03-11 Tom Tromey <tom@tromey.com>
8921 * dwarf2read.c (struct nextfield): Add initializers.
8922 (struct nextfnfield): Remove.
8923 (struct fnfieldlist): Add initializers. Remove "length" and
8924 "head", use std::vector.
8925 (struct decl_field_list): Remove.
8926 (struct field_info): Add initializers.
8927 <fields, baseclasses>: Now std::vector.
8928 <nbaseclasses, nfnfields, typedef_field_list_count,
8929 nested_types_list_count>: Remove.
8930 (dwarf2_add_field, dwarf2_add_type_defn)
8931 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
8932 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
8933 (process_structure_scope): Update.
8935 2018-03-11 Tom Tromey <tom@tromey.com>
8937 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
8938 for use by std::sort.
8939 (build_type_psymtabs_1): Use std::vector.
8941 2018-03-09 Eli Zaretskii <eliz@gnu.org>
8943 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
8944 and LIBMPFR in the printed configuration.
8946 2018-03-08 Tom Tromey <tom@tromey.com>
8948 * source.c (get_filename_and_charpos): Use scoped_fd.
8949 * nto-procfs.c (procfs_open_1): Use scoped_fd.
8950 (procfs_pidlist): Likewise.
8951 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
8952 (iterate_over_mappings): Likewise.
8954 2018-03-08 Tom Tromey <tom@tromey.com>
8956 * infcall.c (struct call_return_meta_info)
8957 <stack_temporaries_enabled>: Remove.
8958 (get_call_return_value, call_function_by_hand_dummy): Update.
8959 * thread.c (disable_thread_stack_temporaries): Remove.
8960 (enable_thread_stack_temporaries): Remove.
8961 (thread_stack_temporaries_enabled_p): Return bool.
8962 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
8963 (get_last_thread_stack_temporary): Update.
8964 * eval.c (evaluate_subexp): Update.
8965 * gdbthread.h (class enable_thread_stack_temporaries): Now a
8966 class, not a function.
8967 (value_ptr, value_vec): Remove typedefs.
8968 (class thread_info) <stack_temporaries_enabled>: Now bool.
8969 <stack_temporaries>: Now a std::vector.
8970 (thread_stack_temporaries_enabled_p)
8971 (value_in_thread_stack_temporaries): Return bool.
8973 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
8975 * remote.c (putpkt_binary): Fix omitted bytes reporting.
8976 (getpkt_or_notif_sane_1): Likewise.
8978 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8980 * build-id.c (build_id_to_debug_bfd): Use std::string.
8982 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8984 * build-id.c (find_separate_debug_file_by_buildid): Return
8986 * build-id.h (find_separate_debug_file_by_buildid): Return
8988 * coffread.c (coff_symfile_read): Adjust to std::string.
8989 * elfread.c (elf_symfile_read): Adjust to std::string.
8990 * symfile.c (separate_debug_file_exists): Change parameter to
8992 (find_separate_debug_file): Return std::string.
8993 (find_separate_debug_file_by_debuglink): Return std::string.
8994 * symfile.h (find_separate_debug_file_by_debuglink): Return
8997 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8999 * common/xml-utils.c (xml_escape_text): Move code to...
9000 (xml_escape_text_append): ... this new function.
9001 * common/xml-utils.h (xml_escape_text_append): New declaration.
9002 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
9004 (_initialize_xml_utils): register test_xml_escape_text_append as
9007 2018-03-07 Alan Hayward <alan.hayward@arm.com>
9009 * defs.h: Remove MAX_REGISTER_SIZE.
9010 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
9012 * python/py-unwind.c (pyuw_sniffer): Likewise.
9014 2018-03-07 Tom Tromey <tom@tromey.com>
9016 * linux-tdep.c (linux_info_proc): Update.
9017 * target.h (struct target_ops) <to_fileio_readlink>: Return
9019 (target_fileio_readlink): Return optional<string>.
9020 * remote.c (remote_hostio_readlink): Return optional<string>.
9021 * inf-child.c (inf_child_fileio_readlink): Return
9023 * target.c (target_fileio_readlink): Return optional<string>.
9025 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
9027 * regcache.c (cooked_read_test): Add riscv to the list of
9028 architectures that have a save_reggroup.
9030 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
9032 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
9033 value is not a dynamic class object.
9035 2018-03-06 Tom Tromey <tom@tromey.com>
9037 * rust-exp.y: Formatting fixes.
9039 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9041 * riscv-tdep.c (riscv_register_name): Remove target description
9043 (riscv_gdbarch_init): Remove target description check.
9045 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9047 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
9049 * riscv-tdep.h: Likewise.
9051 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9053 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
9054 (riscv_pseudo_register_write): Delete.
9055 (riscv_gdbarch_init): Remove all use of pseudo registers.
9057 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9059 * record-btrace.c (btrace_print_lines): Replace cleanup
9060 parameter with RAII equivalents.
9061 (btrace_insn_history): Replace cleanup with RAII equivalents.
9062 * ui-out.h (make_cleanup_ui_out_list_begin_end,
9063 make_cleanup_ui_out_tuple_begin_end): Remove.
9064 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
9065 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
9066 make_cleanup_ui_out_list_begin_end): Remove.
9068 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9070 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
9071 parameter types to std::vector. Use bool.
9072 (record_btrace_wait): Replace VEC(tp_t) with
9073 std::vector<thread_info *>.
9074 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
9076 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
9078 * record-btrace.c (record_btrace_disable_callback): Remove.
9079 (struct scoped_btrace_disable): New.
9080 (record_btrace_open): Use scoped_btrace_disable.
9082 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9084 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
9085 reading values from registers.
9087 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9089 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
9092 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9094 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
9095 change parameter type. Use GDB's print functions, and use
9096 core_addr_to_string where appropriate.
9097 (riscv_push_dummy_call): Use core_addr_to_string where
9098 appropriate, update call to riscv_print_arg_location, and reindent
9100 (riscv_return_value): Update call to riscv_print_arg_location.
9102 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9103 Tim Newsome <tim@sifive.com>
9104 Albert Ou <a0u@eecs.berkeley.edu>
9105 Darius Rad <darius@bluespec.com>
9107 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
9108 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
9109 (ALLDEPFILES): Add riscv-tdep.c
9110 * configure.tgt: Add riscv support.
9111 * riscv-tdep.c: New file.
9112 * riscv-tdep.h: New file.
9113 * NEWS: Mention new target.
9114 * MAINTAINERS: Add entry for riscv.
9116 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
9118 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
9119 fields within aggregates.
9121 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
9123 * record-btrace.c (btrace_print_lines): Change type of flags to
9124 gdb_disassembly_flags.
9126 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9128 * fbsd-nat.c: Include "inf-ptrace.h".
9129 (USE_SIGTRAP_SIGINFO): Conditionally define.
9130 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
9131 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
9132 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
9134 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
9136 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
9138 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
9139 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
9140 "supports_stopped_by_hw_breakpoint" target methods.
9142 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9144 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
9145 * fbsd-nat.c (debug_fbsd_nat): New variable.
9146 (show_fbsd_nat_debug): New function.
9147 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
9148 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
9150 2018-03-04 John Baldwin <jhb@FreeBSD.org>
9152 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
9153 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
9155 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
9156 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
9159 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9161 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
9162 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
9164 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9166 * charset.c (struct charset_vector): New.
9167 (charsets): Change type to charset_vector.
9168 (find_charset_names): Adjust.
9170 (_initialize_charset): Adjust.
9172 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9174 * progspace.h (struct program_space) <deleted_solibs>: Change
9175 type to std::vector<std::string>.
9176 * progspace.c (clear_program_space_solib_cache): Adjust.
9177 * breakpoint.c (print_solib_event): Adjust.
9178 (check_status_catch_solib): Adjust.
9179 * solib.c (update_solib_list): Adjust.
9180 * ui-out.h (class ui_out) <field_string>: New overload.
9181 * ui-out.c (ui_out::field_string): New overload.
9183 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9185 * progspace.h (struct program_space): Add constructor and
9186 destructor, initialize fields.
9187 (add_program_space): Remove.
9188 * progspace.c (add_program_space): Rename to...
9189 (program_space::program_space): ... this.
9190 (release_program_space): Rename to...
9191 (program_space::~program_space): ... this.
9192 (delete_program_space): Use delete to delete program_space.
9193 (initialize_progspace): Use new to allocate program_space.
9194 * inferior.c (add_inferior_with_spaces): Likewise.
9195 (clone_inferior_command): Likewise.
9196 * infrun.c (follow_fork_inferior): Likewise.
9197 (handle_vfork_child_exec_or_exit): Likewise.
9199 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
9201 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
9202 (delim_string_to_char_ptr_vec): Return std::vector of
9203 gdb::unique_xmalloc_ptr.
9204 (dirnames_to_char_ptr_vec_append): Take std::vector of
9205 gdb::unique_xmalloc_ptr.
9206 (dirnames_to_char_ptr_vec): Return std::vector of
9207 gdb::unique_xmalloc_ptr.
9208 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
9209 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
9210 (delim_string_to_char_ptr_vec): Return an std::vector of
9211 gdb::unique_xmalloc_ptr, adjust the code.
9212 (dirnames_to_char_ptr_vec_append): Take an std::vector of
9213 gdb::unique_xmalloc_ptr, adjust the code.
9214 (dirnames_to_char_ptr_vec): Return an std::vector of
9215 gdb::unique_xmalloc_ptr, adjust the code.
9216 * auto-load.c (auto_load_safe_path_vec): Change type to
9217 std::vector of gdb::unique_xmalloc_ptr.
9218 (auto_load_expand_dir_vars): Return an std::vector of
9219 gdb::unique_xmalloc_ptr, adjust the code.
9220 (auto_load_safe_path_vec_update): Adjust.
9221 (filename_is_in_auto_load_safe_path_vec): Adjust.
9222 (auto_load_objfile_script_1): Adjust.
9223 * build-id.c (build_id_to_debug_bfd): Adjust.
9224 * linux-thread-db.c (thread_db_load_search): Adjust.
9225 * source.c (add_path): Adjust.
9227 * symfile.c (find_separate_debug_file): Adjust.
9228 * utils.c (do_free_char_ptr_vec): Remove.
9229 (make_cleanup_free_char_ptr_vec): Remove.
9231 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
9234 * common/pathstuff.c: Conditionally include "<windows.h>".
9236 2018-03-01 Georg Sauthoff <mail@georg.so>
9239 * gcore.in: Quote variables and switch interpreter to bash.
9241 2018-03-01 Tom Tromey <tom@tromey.com>
9243 * dwarf2read.c (alloc_discriminant_info): Fix default_index
9244 assertion. Add assertion for discriminant_index.
9245 (quirk_rust_enum): Use correct base type name in univariant case.
9247 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
9249 * record.c (get_call_history_modifiers): Return a
9251 (cmd_record_call_history): Adjust.
9252 * record-btrace.c (record_btrace_call_history): Adjust.
9253 (record_btrace_call_history_range): Adjust.
9254 (record_btrace_call_history_from): Adjust.
9255 * target-debug.h (target_debug_print_record_print_flags): New.
9256 * target-delegates.c: Re-generate.
9257 * target.c (target_call_history): Change flags type.
9258 (target_call_history_from): Likewise.
9259 (target_call_history_range): Likewise.
9260 * target.h (struct target_ops) <target_call_history>: Likewise.
9261 (target_call_history_from): Likewise.
9262 (target_call_history_range): Likewise.
9264 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9265 Simon Marchi <simon.marchi@polymtl.ca>
9267 * common/common-utils.c: Include "sys/stat.h".
9268 (is_regular_file): Move here from "source.c"; change return
9270 * common/common-utils.h (is_regular_file): New prototype.
9271 * common/pathstuff.c (contains_dir_separator): New function.
9272 * common/pathstuff.h (contains_dir_separator): New prototype.
9273 * source.c: Don't include "sys/stat.h".
9274 (is_regular_file): Move to "common/common-utils.c".
9276 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9278 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
9279 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
9280 * auto-load.c: Include "common/pathstuff.h".
9281 * common/common-def.h (current_directory): Move here.
9282 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
9284 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
9286 * common/pathstuff.c: New file.
9287 * common/pathstuff.h: New file.
9288 * compile/compile.c: Include "common/pathstuff.h".
9289 * defs.h (current_directory): Move to "common/common-defs.h".
9290 * dwarf2read.c: Include "common/pathstuff.h".
9292 * guile/scm-safe-call.c: Likewise.
9293 * linux-thread-db.c: Likewise.
9295 * nto-tdep.c: Likewise.
9296 * objfiles.c: Likewise.
9297 * source.c: Likewise.
9298 * symtab.c: Likewise.
9299 * utils.c: Include "common/pathstuff.h".
9300 (gdb_realpath): Move to "common/pathstuff.c".
9301 (gdb_realpath_keepfile): Likewise.
9302 (gdb_abspath): Likewise.
9303 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
9304 (gdb_realpath_keepfile): Likewise.
9305 (gdb_abspath): Likewise.
9307 2018-02-28 John Baldwin <jhb@FreeBSD.org>
9309 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
9310 wildcard process pid for super_resume for kernels with a
9313 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
9315 * compile/compile.c (get_args): Add additional comments
9316 explaining function.
9318 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
9319 Tom Tromey <tom@tromey.com>
9321 * target.h (memory_write_request_s): Remove typedef. Don't define
9323 (target_write_memory_blocks): Change argument to std::vector.
9324 (struct memory_write_request): Add constructor.
9325 * target-memory.c (compare_block_starting_address): Return bool.
9326 Change argument types.
9327 (claim_memory): Change arguments to use std::vector.
9328 (split_regular_and_flash_blocks, blocks_to_erase)
9329 (compute_garbled_blocks): Likewise.
9330 (cleanup_request_data, cleanup_write_requests_vector): Remove.
9331 (target_write_memory_blocks): Change argument to std::vector.
9332 * symfile.c (struct load_section_data): Add constructor and
9333 destructor. Use std::vector for "requests".
9334 (struct load_progress_data): Add initializers.
9335 (load_section_callback): Update. Use "new".
9336 (clear_memory_write_data): Remove.
9337 (generic_load): Update.
9339 2018-02-27 Alan Hayward <alan.hayward@arm.com>
9341 * arch/aarch64.h: Use common/tdesc.h.
9343 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9345 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
9346 architecture with a 64-bit ABI.
9348 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9350 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
9351 ahead of target description loading.
9353 2018-02-26 Tom Tromey <tom@tromey.com>
9355 * stack.c (backtrace_command_1): Update.
9356 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
9358 * python/py-framefilter.c (py_print_frame)
9359 (gdbpy_apply_frame_filter): Change type of "flags".
9360 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
9362 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
9363 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
9364 * extension.h (enum frame_filter_flag): Rename from
9366 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
9367 (apply_ext_lang_frame_filter): Change type of "flags".
9368 * extension.c (apply_ext_lang_frame_filter): Change type of
9370 * extension-priv.h (struct extension_language_ops)
9371 <apply_frame_filter>: Change type of "flags".
9373 2018-02-26 Tom Tromey <tom@tromey.com>
9376 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
9377 off-by-one in py_end computation.
9378 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
9380 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
9383 2018-02-26 Tom Tromey <tom@tromey.com>
9385 * dwarf2read.c (struct variant_field): New.
9386 (struct nextfield) <variant>: New field.
9387 (dwarf2_add_field): Handle DW_TAG_variant_part.
9388 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
9389 discriminated union.
9390 (read_structure_type): Handle DW_TAG_variant_part.
9391 (handle_struct_member_die): New function, extracted from
9392 process_structure_scope. Handle DW_TAG_variant.
9393 (process_structure_scope): Handle discriminated unions. Call
9394 handle_struct_member_die.
9396 2018-02-26 Tom Tromey <tom@tromey.com>
9398 * rust-lang.h (rust_last_path_segment): Declare.
9399 * rust-lang.c (rust_last_path_segment): Now public. Change
9401 (struct disr_info): Remove.
9402 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
9403 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
9404 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
9405 (rust_enum_p, rust_enum_variant): New function.
9406 (rust_underscore_fields): Remove "offset" parameter.
9407 (rust_print_enum): New function.
9408 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
9409 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
9410 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
9412 (rust_internal_print_type): New function, from rust_print_type.
9414 (rust_print_type): Call rust_internal_print_type.
9415 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
9416 Update enum handling.
9417 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
9418 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
9419 (rust_union_quirks): New functions.
9420 (process_full_comp_unit, process_full_type_unit): Call
9422 (process_structure_scope): Update rust_unions if necessary.
9424 2018-02-26 Tom Tromey <tom@tromey.com>
9426 * value.h (value_union_variant): Declare.
9427 * valops.c (value_union_variant): New function.
9428 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
9429 (struct discriminant_info): New.
9430 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
9432 (struct main_type) <flag_discriminated_union>: New field.
9434 2018-02-26 Tom Tromey <tom@tromey.com>
9436 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9437 unittests/unpack-selftests.c.
9438 * unittests/unpack-selftests.c: New file.
9439 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
9441 2018-02-26 Yao Qi <yao.qi@linaro.org>
9443 * dwarf2read.c (struct partial_die_info) <read>: New method.
9444 (read_partial_die): Remove the declaration.
9445 (load_partial_dies): Update.
9446 (partial_die_info::partial_die_info):
9447 (read_partial_die): Change it to partial_die_info::read.
9449 2018-02-26 Yao Qi <yao.qi@linaro.org>
9451 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
9452 (fixup_partial_die): Remove declaration.
9453 (scan_partial_symbols): Update.
9454 (partial_die_parent_scope): Likewise.
9455 (partial_die_full_name): Likewise.
9456 (fixup_partial_die): Change it to partial_die_info::fixup.
9458 2018-02-26 Yao Qi <yao.qi@linaro.org>
9460 * dwarf2read.c (read_partial_die): Update the declaration.
9461 (load_partial_dies): Caller update.
9462 (read_partial_die): Remove one argument abbrev_len.
9464 2018-02-26 Yao Qi <yao.qi@linaro.org>
9466 * dwarf2read.c (struct partial_die_info): Add ctor, delete
9467 assignment operator.
9468 (load_partial_dies): Use ctor and copy ctor.
9469 (read_partial_die): Update.
9470 (dwarf2_cu::find_partial_die): Use ctor.
9472 2018-02-26 Yao Qi <yao.qi@linaro.org>
9474 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
9475 (find_partial_die_in_comp_unit): Change it to
9476 dwarf2_cu::find_partial_die.
9477 (find_partial_die): Update.
9479 2018-02-26 Yao Qi <yao.qi@linaro.org>
9481 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
9484 2018-02-26 Yao Qi <yao.qi@linaro.org>
9486 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
9488 2018-02-26 Alan Hayward <alan.hayward@arm.com>
9490 * arch/amd64.h: Use common/tdesc.h.
9491 * arch/i386.c: Likewise.
9492 * arch/i386.h: Likewise.
9493 * arch/tic6x.c: Likewise.
9494 * arch/tdesc.h: Move file from here...
9495 * common/tdesc.h: ...to here.
9496 * features/aarch64-core.c: Regenerate.
9497 * features/aarch64-fpu.c: Regenerate.
9498 * features/i386/32bit-avx.c: Regenerate.
9499 * features/i386/32bit-avx512.c: Regenerate.
9500 * features/i386/32bit-core.c: Regenerate.
9501 * features/i386/32bit-linux.c: Regenerate.
9502 * features/i386/32bit-mpx.c: Regenerate.
9503 * features/i386/32bit-pkeys.c: Regenerate.
9504 * features/i386/32bit-sse.c: Regenerate.
9505 * features/i386/64bit-avx.c: Regenerate.
9506 * features/i386/64bit-avx512.c: Regenerate.
9507 * features/i386/64bit-core.c: Regenerate.
9508 * features/i386/64bit-linux.c: Regenerate.
9509 * features/i386/64bit-mpx.c: Regenerate.
9510 * features/i386/64bit-pkeys.c: Regenerate.
9511 * features/i386/64bit-segments.c: Regenerate.
9512 * features/i386/64bit-sse.c: Regenerate.
9513 * features/i386/x32-core.c: Regenerate.
9514 * features/tic6x-c6xp.c: Regenerate.
9515 * features/tic6x-core.c: Regenerate.
9516 * features/tic6x-gp.c: Regenerate.
9517 * target-descriptions.c: Use common/tdesc.h.
9518 * target-descriptions.h: Likewise.
9520 2018-02-24 Tom Tromey <tom@tromey.com>
9522 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
9523 (try_thread_db_load_from_dir, thread_db_load_search): Use
9525 (info_auto_load_libthread_db_compare): Return bool. Change
9527 (info_auto_load_libthread_db): Use std::vector, std::string.
9530 2018-02-24 Tom Tromey <tom@tromey.com>
9532 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
9534 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
9536 * gdbarch.c: Rebuild.
9537 * gdbarch.h: Rebuild.
9538 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
9539 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
9540 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
9543 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
9545 * gdbtypes.h (sect_offset): Change type to uint64_t.
9546 (sect_offset_str): New function.
9547 * dwarf2read.c (create_addrmap_from_aranges): Use
9549 (error_check_comp_unit_head): Likewise.
9550 (create_debug_type_hash_table): Likewise.
9551 (read_cutu_die_from_dwo): Likewise.
9552 (init_cutu_and_read_dies): Likewise.
9553 (init_cutu_and_read_dies_no_follow): Likewise.
9554 (process_psymtab_comp_unit_reader): Likewise.
9555 (partial_die_parent_scope): Likewise.
9556 (peek_die_abbrev): Likewise.
9557 (process_queue): Likewise.
9558 (dwarf2_physname): Likewise.
9559 (read_namespace_alias): Likewise.
9560 (read_import_statement): Likewise.
9561 (create_dwo_cu_reader): Likewise.
9562 (create_cus_hash_table): Likewise.
9563 (lookup_dwo_cutu): Likewise.
9564 (inherit_abstract_dies): Likewise.
9565 (read_func_scope): Likewise.
9566 (read_call_site_scope): Likewise.
9567 (dwarf2_add_member_fn): Likewise.
9568 (read_common_block): Likewise.
9569 (read_module_type): Likewise.
9570 (read_typedef): Likewise.
9571 (read_subrange_type): Likewise.
9572 (load_partial_dies): Likewise.
9573 (read_partial_die): Likewise.
9574 (find_partial_die): Likewise.
9575 (read_str_index): Likewise.
9576 (dwarf2_string_attr): Likewise.
9577 (build_error_marker_type): Likewise.
9578 (lookup_die_type): Likewise.
9579 (dump_die_shallow): Likewise.
9580 (follow_die_ref): Likewise.
9581 (dwarf2_fetch_die_loc_sect_off): Likewise.
9582 (dwarf2_fetch_constant_bytes): Likewise.
9583 (follow_die_sig): Likewise.
9584 (get_signatured_type): Likewise.
9585 (get_DW_AT_signature_type): Likewise.
9586 (dwarf2_find_containing_comp_unit): Likewise.
9587 (set_die_type): Likewise.
9589 2018-02-21 John Baldwin <jhb@FreeBSD.org>
9591 * arch/aarch64.c: Include "common-defs.h".
9592 * arch/amd64.c: Likewise.
9593 * arch/i386.c: Likewise.
9595 2018-02-21 Tom Tromey <tom@tromey.com>
9597 * value.h: (extract_field_op): Update.
9598 * eval.c (extract_field_op): Return a const char *.
9599 * expression.h (parse_expression_for_completion): Update.
9600 * completer.c (complete_expression): Update.
9601 (add_struct_fields): Make fieldname const.
9602 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9603 (mark_completion_tag, parse_exp_in_context_1): Update.
9604 (parse_expression_for_completion): Change "name" to
9605 unique_xmalloc_ptr*.
9607 2018-02-21 Tom Tromey <tom@tromey.com>
9609 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9611 2018-02-21 Yao Qi <yao.qi@linaro.org>
9613 * avr-tdep.c (avr_read_pc): Change parameter type to
9615 * gdbarch.sh (read_pc): Likewise.
9616 * gdbarch.c: Re-generated.
9617 * gdbarch.h: Re-generated.
9618 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9620 * ia64-tdep.c (ia64_read_pc): Likewise.
9621 * mips-tdep.c (mips_read_pc): Likewise.
9622 * spu-tdep.c (spu_read_pc): Likewise.
9624 2018-02-21 Yao Qi <yao.qi@linaro.org>
9626 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
9627 * regcache-dump.c: New file.
9628 * regcache.c: Move register_dump to regcache-dump.c.
9629 (maintenance_print_registers): Likewise.
9630 (maintenance_print_raw_registers): Likewise.
9631 (maintenance_print_cooked_registers): Likewise.
9632 (maintenance_print_register_groups): Likewise.
9633 (maintenance_print_remote_registers): Likewise.
9634 (_initialize_regcache): Likewise.
9635 * regcache.h (register_dump): Moved from regcache.c.
9637 2018-02-21 Yao Qi <yao.qi@linaro.org>
9639 * regcache.c (regcache::regcache): Update.
9640 (regcache::invalidate): Move it to detached_regcache::invalidate.
9641 (get_thread_arch_aspace_regcache): Update.
9642 (regcache::raw_update): Update.
9643 (regcache::cooked_read): Remove some code.
9644 (regcache::cooked_read_value): Likewise.
9645 (regcache::raw_write): Remove assert on m_readonly_p.
9646 (regcache::raw_supply_integer): Move it to
9647 detached_regcache::raw_supply_integer.
9648 (regcache::raw_supply_zeroed): Likewise.
9649 * regcache.h (detached_regcache) <raw_supply_integer>: New
9651 <raw_supply_zeroed, invalidate>: Likewise.
9652 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
9653 <invalidate>: Likewise.
9654 <m_readonly_p>: Removed.
9656 2018-02-21 Yao Qi <yao.qi@linaro.org>
9658 * infcmd.c (get_return_value): Let stop_regs point to
9659 get_current_regcache.
9660 * regcache.c (regcache::regcache): Remove.
9661 (register_dump_reg_buffer): New class.
9662 (regcache_print): Adjust.
9663 * regcache.h (regcache): Remove constructors.
9665 2018-02-21 Yao Qi <yao.qi@linaro.org>
9667 * regcache.c (class register_dump): New class.
9668 (register_dump_regcache, register_dump_none): New class.
9669 (register_dump_remote, register_dump_groups): New class.
9670 (regcache_print): Update.
9671 * regcache.h (regcache_dump_what): Move it to regcache.c.
9672 (regcache) <dump>: Remove.
9674 2018-02-21 Yao Qi <yao.qi@linaro.org>
9676 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
9678 (jit_unwind_reg_set_impl): Call raw_supply.
9679 (jit_frame_sniffer): Use reg_buffer_rw.
9680 * record-full.c (record_full_core_regbuf): Change its type.
9681 (record_full_core_open_1): Use reg_buffer_rw.
9682 (record_full_close): Likewise.
9683 (record_full_core_fetch_registers): Use regcache->raw_supply.
9684 (record_full_core_store_registers): Likewise.
9685 * regcache.c (regcache::get_register_status): Move it to
9687 (regcache_raw_set_cached_value): Remove.
9688 (regcache::raw_set_cached_value): Remove.
9689 (regcache::raw_write): Call raw_supply.
9690 (regcache::raw_supply): Move it to reg_buffer_rw.
9691 * regcache.h (regcache_raw_set_cached_value): Remove.
9692 (reg_buffer_rw): New class.
9694 2018-02-21 Yao Qi <yao.qi@linaro.org>
9696 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
9697 readonly_detached_regcache.
9698 (dummy_frame_prev_register): Use regcache->cooked_read.
9699 * frame.c (frame_save_as_regcache): Change return type.
9700 (frame_pop): Update.
9701 * frame.h (frame_save_as_regcache): Update declaration.
9702 * inferior.h (get_infcall_suspend_state_regcache): Update
9704 * infrun.c (infcall_suspend_state) <registers>: use
9705 readonly_detached_regcache.
9706 (save_infcall_suspend_state): Don't use regcache_dup.
9707 (get_infcall_suspend_state_regcache): Change return type.
9708 * linux-fork.c (struct fork_info) <savedregs>: Change to
9709 readonly_detached_regcache.
9711 (fork_save_infrun_state): Don't use regcache_dup.
9712 (info_checkpoints_command): Adjust.
9713 * mi/mi-main.c (register_changed_p): Update declaration.
9714 (mi_cmd_data_list_changed_registers): Use
9715 readonly_detached_regcache.
9716 (register_changed_p): Change parameter type to
9717 readonly_detached_regcache.
9718 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
9719 readonly_detached_regcache.
9720 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
9721 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
9723 (regcache::save): Move it to reg_buffer.
9724 (regcache::restore): Change parameter type.
9725 (regcache_dup): Remove.
9726 * regcache.h (reg_buffer) <save>: New method.
9727 (readonly_detached_regcache): New class.
9728 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
9729 readonly_detached_regcache.
9730 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
9732 2018-02-21 Yao Qi <yao.qi@linaro.org>
9734 * frame.c (frame_save_as_regcache): Use regcache method save.
9735 (frame_pop): Use regcache method restore.
9736 * infrun.c (restore_infcall_suspend_state): Likewise.
9737 * linux-fork.c (fork_load_infrun_state): Likewise.
9738 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
9740 * regcache.c (regcache_save): Remove.
9741 (regcache::restore): More asserts.
9742 (regcache_cpy): Remove.
9743 * regcache.h (regcache_save): Remove the declaration.
9744 (regcache::restore): Move from private to public.
9745 Remove the friend declaration of regcache_cpy.
9746 (regcache_cpy): Remove declaration.
9748 2018-02-21 Yao Qi <yao.qi@linaro.org>
9750 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
9751 parameter type to 'readable_regcache *'.
9752 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9753 * arm-tdep.c (arm_neon_quad_read): Likewise.
9754 (arm_pseudo_read): Likewise.
9755 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9756 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9757 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9758 * gdbarch.c: Re-generated.
9759 * gdbarch.h: Re-generated.
9760 * gdbarch.sh (pseudo_register_read): Change parameter type to
9761 'readable_regcache *'.
9762 (pseudo_register_read_value): Likewise.
9763 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
9764 (h8300_pseudo_register_read): Likewise.
9765 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
9766 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9767 (i386_pseudo_register_read_into_value): Likewise.
9768 (i386_pseudo_register_read_value): Likewise.
9769 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
9771 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
9772 * m32c-tdep.c (m32c_raw_read): Likewise.
9773 (m32c_read_flg): Likewise.
9774 (m32c_banked_register): Likewise.
9775 (m32c_banked_read): Likewise.
9776 (m32c_sb_read): Likewise.
9777 (m32c_part_read): Likewise.
9778 (m32c_cat_read): Likewise.
9779 (m32c_r3r2r1r0_read): Likewise.
9780 (m32c_pseudo_register_read): Likewise.
9781 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9782 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9783 (mep_pseudo_cr64_read): Likewise.
9784 (mep_pseudo_register_read): Likewise.
9785 * mips-tdep.c (mips_pseudo_register_read): Likewise.
9786 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9787 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9788 * regcache.c (regcache::raw_read): Move it to readable_regcache.
9789 (regcache::cooked_read): Likewise.
9790 (regcache::cooked_read_value): Likewise.
9791 (regcache_cooked_read_signed):
9792 (regcache::cooked_read): Likewise.
9793 * regcache.h (readable_regcache): New class.
9794 (regcache): Inherit readable_regcache. Move some methods to
9796 * rl78-tdep.c (rl78_pseudo_register_read): Change
9797 parameter type to 'readable_regcache *'.
9798 * rs6000-tdep.c (do_regcache_raw_read): Remove.
9799 (e500_pseudo_register_read): Change parameter type to
9800 'readable_regcache *'.
9801 (dfp_pseudo_register_read): Likewise.
9802 (vsx_pseudo_register_read): Likewise.
9803 (efpr_pseudo_register_read): Likewise.
9804 * s390-tdep.c (s390_pseudo_register_read): Likewise.
9805 * sh-tdep.c (sh_pseudo_register_read): Likewise.
9806 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
9807 (sh64_pseudo_register_read): Likewise.
9808 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9809 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9810 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9811 (spu_pseudo_register_read): Likewise.
9812 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9813 (xtensa_pseudo_register_read): Likewise.
9815 2018-02-21 Yao Qi <yao.qi@linaro.org>
9817 * regcache.c (regcache::regcache): Call reg_buffer ctor.
9818 (regcache::arch): Move it to reg_buffer::arch.
9819 (regcache::register_buffer): Likewise.
9820 (regcache::assert_regnum): Likewise.
9821 (regcache::num_raw_registers): Likewise.
9822 * regcache.h (reg_buffer): New class.
9823 (regcache): Inherit reg_buffer.
9825 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
9827 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
9828 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
9830 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
9832 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
9834 2018-02-19 Alan Hayward <alan.hayward@arm.com>
9836 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
9837 (SFILES): Remove common/*.c files.
9838 (COMMON_OBS): Remove some *.o files built from common/*.c files.
9839 * common/common.host: Add common reference.
9840 * configure.ac: Likewise.
9841 * configure: Regenerate.
9843 2018-02-16 Yao Qi <yao.qi@linaro.org>
9845 * block.c (block_namespace_info): Inherit allocate_on_obstack.
9846 (block_initialize_namespace): Use new.
9847 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
9848 (dwarf2_free_objfile): Use delete.
9849 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
9850 (copy_type_recursive): Use new.
9851 * gdb_obstack.h (allocate_on_obstack): New.
9853 2018-02-15 Yao Qi <yao.qi@linaro.org>
9856 * inferior.c (exit_inferior_1): Reset inf->control.
9858 2018-02-15 Joel Brobecker <brobecker@adacore.com>
9860 * ada-lang.c (ada_to_fixed_value_create): Delete advance
9863 2018-02-14 Pedro Alves <palves@redhat.com>
9865 * frame-unwind.c (frame_unwind_try_unwinder): Always call
9866 frame_cleanup_after_sniffer on exception.
9868 2018-02-14 Tom Tromey <tom@tromey.com>
9870 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
9872 (solib_bfd_open): Make pathname const.
9873 * solib.c (solib_bfd_open): Make pathname const.
9874 * solib-spu.c (spu_bfd_fopen): Make name const.
9875 (spu_bfd_open): Make pathname const.
9876 * solib-darwin.c (darwin_bfd_open): Make pathname const.
9877 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
9879 2018-02-14 Tom Tromey <tom@tromey.com>
9881 * symfile.c (symfile_bfd_open): Update.
9882 * source.h (openp, source_full_path_of, find_and_open_source):
9883 Change argument type to unique_xmalloc_ptr.
9884 * source.c (openp): Take a unique_xmalloc_ptr.
9885 (source_full_path_of, find_and_open_source): Likewise.
9886 (open_source_file, symtab_to_fullname): Update.
9887 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
9889 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
9890 (exec_file_find): Update.
9891 * psymtab.c (psymtab_to_fullname): Update.
9892 * nto-tdep.h (nto_find_and_open_solib): Update.
9893 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
9895 * exec.c (exec_file_attach): Update.
9896 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
9897 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
9899 2018-02-14 Tom Tromey <tom@tromey.com>
9901 * solib.c: Include source.h.
9902 * nto-tdep.c: Include source.h.
9903 * mi/mi-cmd-env.c: Include source.h.
9904 * infcmd.c: Include source.h.
9905 * exec.c: Include source.h.
9906 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
9907 (add_path, directory_switch, source_path, init_source_path): Move
9909 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
9910 (add_path, directory_switch, source_path, init_source_path):
9913 2018-02-14 Tom Tromey <tom@tromey.com>
9915 * solist.h (exec_file_find, solib_find): Return
9917 (solib_bfd_fopen): Take a const char *.
9918 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
9919 (exec_file_find, solib_find): Likewise.
9920 (solib_bfd_fopen): Do not take ownership of "pathname".
9921 (solib_bfd_open): Use unique_xmalloc_ptr.
9922 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
9923 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
9924 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
9925 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
9927 2018-02-14 Joel Brobecker <brobecker@adacore.com>
9929 * ada-lang.c (name_match_type_from_name): Remove reference to
9930 ada_name_for_lookup in function's documentation.
9931 * ada-lang.h (ada_name_for_lookup): Delete declaration.
9933 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9935 * defs.h (enum openp_flags): New enum.
9936 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
9937 Move to enum openp_flags.
9938 (openp_flags): New enum flags.
9939 (openp): Change parameter type to openp_flags.
9940 * source.c (openp): Change parameter type to openp_flags.
9941 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
9942 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
9944 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9946 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
9949 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
9951 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
9953 (class dwarf2_queue_guard): ...the destructor of this new class.
9954 (dw2_do_instantiate_symtab): Create instance of the new class
9955 dwarf2_queue_guard, remove cleanup.
9957 2018-02-09 Tom Tromey <tom@tromey.com>
9959 * source.c (find_source_lines): Don't reference past the end of
9962 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9964 * remote.c (remote_btrace_maybe_reopen): Change error message.
9965 * btrace.c (btrace_enable): Likewise.
9966 (parse_xml_btrace): Likewise.
9967 (parse_xml_btrace_conf): Likewise.
9969 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9971 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
9972 (linux_enable_pt, linux_enable_bts): Call
9973 diagnose_perf_event_open_fail.
9975 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9977 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
9978 Remove parameter and change return type. Update callers. Move it.
9979 (linux_enable_bts, linux_enable_pt): Improve error message.
9980 (linux_enable_pt): Remove zero buffer size check.
9981 (linux_enable_btrace): Improve error messages. Remove NULL return
9984 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9986 * btrace.c (btrace_enable): Remove target_supports_btrace call.
9987 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
9988 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
9989 (linux_supports_pt, linux_supports_btrace): Remove.
9990 (linux_enable_bts): Call cpu_supports_bts.
9991 * nat/linux-btrace.h (linux_supports_btrace): Remove.
9992 * remote.c (remote_supports_btrace): Remove.
9993 (init_remote_ops): Remove remote_supports_btrace.
9994 * target-delegates.c: Regenerated.
9995 * target.c (target_supports_btrace): Remove.
9996 * target.h (target_ops) <to_supports_btrace>: Remove
9997 (target_supports_btrace): Remove.
9998 * x86-linux-nat.c (x86_linux_create_target): Remove
9999 linux_supports_btrace.
10001 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10003 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
10005 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
10006 exception and use message in own exception.
10008 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10010 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
10011 (perf_event_pt_event_type): Use gdb_file_up.
10012 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
10013 scoped_fd, and scoped_mmap.
10015 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10017 * common/scoped_mmap.h: New.
10018 * unittests/scoped_mmap-selftest.c: New.
10019 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10020 unittests/scoped_mmap-selftest.c.
10022 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
10024 * common/scoped_fd.h: New.
10025 * unittests/scoped_fd-selftest.c: New.
10026 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10027 unittests/scoped_fd-selftest.c.
10029 2018-02-09 Tom Tromey <tom@tromey.com>
10031 * auto-load.c (auto_load_section_scripts): Use
10032 gdb::unique_xmalloc_ptr.
10034 2018-02-09 Tom Tromey <tom@tromey.com>
10036 * auto-load.c (execute_script_contents): Use std::string.
10038 2018-02-09 Joel Brobecker <brobecker@adacore.com>
10040 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
10041 Python function, rather than a new command.
10043 2018-02-08 Tom Tromey <tom@tromey.com>
10045 * solib.c (solib_find_1): Use std::string.
10046 (solib_bfd_fopen): Use unique_xmalloc_ptr.
10048 2018-02-08 Tom Tromey <tom@tromey.com>
10050 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
10052 2018-02-08 Tom Tromey <tom@tromey.com>
10054 * source.c (find_source_lines): Use gdb::def_vector.
10056 2018-02-08 Tom Tromey <tom@tromey.com>
10058 * macrocmd.c (struct temporary_macro_definition): New.
10059 (macro_define_command): Use temporary_macro_definition. Remove
10061 (free_macro_definition_ptr): Remove.
10063 2018-02-08 Tom Tromey <tom@tromey.com>
10065 * macroexp.c (maybe_expand): Use std::string.
10067 2018-02-08 Tom Tromey <tom@tromey.com>
10069 * macroexp.c (struct macro_buffer): Add initializers for some
10071 (init_buffer, init_shared_buffer, free_buffer)
10072 (free_buffer_return_text): Remove.
10073 (macro_buffer): New constructors.
10074 (~macro_buffer): New destructor.
10075 (macro_buffer::set_shared): New method.
10076 (macro_buffer::resize_buffer, macro_buffer::appendc)
10077 (macro_buffer::appendmem): Now methods, not free functions.
10078 (set_token, append_tokens_without_splicing, stringify)
10079 (macro_stringify): Update.
10080 (gather_arguments): Change return type. Remove argc_p argument,
10081 add args_ptr argument. Use std::vector.
10082 (substitute_args): Remove argc argument. Accept std::vector.
10083 (expand): Update. Use std::vector.
10084 (scan, macro_expand, macro_expand_next): Update.
10086 2018-02-08 Tom Tromey <tom@tromey.com>
10088 * symtab.c (default_collect_symbol_completion_matches_break_on):
10089 Use unique_xmalloc_ptr.
10090 * macroscope.h: (sal_macro_scope, user_macro_scope)
10091 (default_macro_scope): Return unique_xmalloc_ptr.
10092 * macroscope.c (sal_macro_scope, user_macro_scope)
10093 (default_macro_scope): Return unique_xmalloc_ptr.
10094 * macroexp.h (macro_expand, macro_expand_once): Return
10095 unique_xmalloc_ptr.
10096 * macroexp.c (macro_expand, macro_expand_once): Return
10097 unique_xmalloc_ptr.
10098 * macrocmd.c (macro_expand_command, macro_expand_once_command)
10099 (info_macro_command, info_macros_command): Use
10100 unique_xmalloc_ptr.
10101 * compile/compile-c-support.c (write_macro_definitions): Use
10102 unique_xmalloc_ptr.
10103 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
10105 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
10107 * value.c (value_static_field): Assign field type instead of
10108 containing type when returning an optimized out value.
10110 2018-02-06 Yao Qi <yao.qi@linaro.org>
10112 * ft32-tdep.c (ft32_read_pc): Remove.
10113 (ft32_write_pc): Remove.
10114 (ft32_gdbarch_init): Update.
10115 * m32r-tdep.c (m32r_read_pc): Remove.
10116 (m32r_gdbarch_init): Update.
10117 * mep-tdep.c (mep_read_pc): Remove.
10118 (mep_gdbarch_init): Update.
10119 * microblaze-tdep.c (microblaze_write_pc): Remove.
10120 (microblaze_gdbarch_init): Update.
10121 * mn10300-tdep.c (mn10300_read_pc): Remove.
10122 (mn10300_write_pc): Remove.
10123 (mn10300_gdbarch_init): Update.
10124 * moxie-tdep.c (moxie_read_pc): Remove.
10125 (moxie_write_pc): Remove.
10126 (moxie_gdbarch_init): Update.
10128 2018-02-06 Yao Qi <yao.qi@linaro.org>
10130 * expprint.c (print_subexp_standard): Handle
10131 OP_F77_UNDETERMINED_ARGLIST.
10132 (dump_subexp_body_standard): Likewise.
10134 2018-02-05 Alan Hayward <alan.hayward@arm.com>
10136 * target-descriptions.c (tdesc_element_visitor) Add empty
10138 (tdesc_type): Move make_gdb_type from here.
10139 (tdesc_type_builtin): Likewise.
10140 (tdesc_type_vector): Likewise.
10141 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
10142 (make_gdb_type_struct): Move from tdesc_type_with_fields.
10143 (make_gdb_type_union): Likewise.
10144 (make_gdb_type_flags): Likewise.
10145 (make_gdb_type_enum): Likewise.
10146 (make_gdb_type): New function.
10147 (tdesc_register_type): Use static make_gdb_type.
10149 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
10151 * infcmd.c (default_print_one_register_info): Align natural-format
10152 column values consistently one under another.
10153 (pad_to_column): New function.
10155 2018-02-05 Joel Brobecker <brobecker@adacore.com>
10157 * dwarf2read.c (dwarf2_physname): Move commment.
10159 2018-02-01 Leszek Swirski <leszeks@google.com>
10161 * varobj.c (varobj_formatted_print_options): Allow recursive
10162 pretty printing if pretty printing is enabled.
10164 2018-02-01 Leszek Swirski <leszeks@google.com>
10166 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
10167 names after a structop as a filename.
10169 2018-02-01 Yao Qi <yao.qi@linaro.org>
10171 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
10172 (arm_record_coproc_data_proc): Likewise.
10174 2018-02-01 Yao Qi <yao.qi@linaro.org>
10176 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
10178 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
10180 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
10181 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
10183 2018-01-31 Pedro Alves <palves@redhat.com>
10185 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
10186 * inflow.c (child_terminal_save_inferior): Wrap reference to
10187 tcgetpgrp in HAVE_TERMIOS_H.
10188 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
10190 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
10191 always iterate over all inferiors.
10192 (gdbsim_cntrl_c): Adjust.
10193 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
10195 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10197 * gdbtypes.c (lookup_array_range_type): Make sure the array's
10198 index type is objfile-owned if the element type is as well.
10200 2018-01-31 Joel Brobecker <brobecker@adacore.com>
10204 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
10206 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
10207 "features/s390x-linux64.c".
10208 (_initialize_s390_linux_tdep): Remove initialization of tdescs
10209 s390_linux32 and s390x_linux64.
10210 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
10212 * s390-tdep.c: Include "features/s390-linux32.c" and
10213 "features/s390x-linux64.c".
10214 (s390_tdesc_valid): Add check for tdesc_has_registers.
10215 (s390_gdbarch_init): Make sure there is always a valid tdesc.
10216 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
10217 tdesc_s390x_linux64.
10218 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
10219 tdesc_s390x_linux64 to...
10220 * s390-tdep.h: ...here.
10222 2018-01-30 Pedro Alves <palves@redhat.com>
10225 * config.in, configure: Regenerate.
10226 * configure.ac: Check for getpgid.
10227 * go32-nat.c (go32_pass_ctrlc): New.
10228 (go32_target): Install it.
10229 * inf-child.c (inf_child_target): Install
10230 child_terminal_save_inferior, child_pass_ctrlc and
10232 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
10233 (inf_ptrace_target): No longer install it.
10234 * infcmd.c (interrupt_target_1): Adjust.
10235 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
10236 (child_interrupt): Declare.
10237 (inferior::terminal_state): New.
10238 * inflow.c (struct terminal_info): Update comments.
10239 (inferior_process_group): Delete.
10240 (terminal_is_ours): Delete.
10241 (gdb_tty_state): New.
10242 (child_terminal_init): Adjust.
10243 (is_gdb_terminal, sharing_input_terminal_1)
10244 (sharing_input_terminal): New functions.
10245 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
10246 Set the process's actual process group in the foreground if
10247 possible. Handle is_ours_for_output/is_ours distinction. Don't
10248 mark terminal as the inferior's if not sharing GDB's terminal.
10249 Don't check attach_flag.
10250 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
10251 pass down a target_terminal_state.
10252 (child_terminal_save_inferior): New, factored out from ...
10253 (child_terminal_ours_1): ... this. Handle
10254 target_terminal_state::is_ours_for_output.
10255 (child_interrupt, child_pass_ctrlc): New.
10256 (inflow_inferior_exit): Clear the inferior's terminal_state.
10257 (copy_terminal_info): Copy the inferior's terminal state.
10258 (_initialize_inflow): Remove reference to terminal_is_ours.
10259 * inflow.h (inferior_process_group): Delete.
10260 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
10261 * procfs.c (procfs_target): Don't install procfs_interrupt.
10262 (procfs_interrupt): Delete.
10263 * remote.c (remote_serial_quit_handler): Adjust.
10264 (remote_interrupt): Remove ptid parameter. Adjust.
10265 * target-delegates.c: Regenerate.
10266 * target.c: Include "terminal.h".
10267 (target_terminal::terminal_state): Rename to ...
10268 (target_terminal::m_terminal_state): ... this.
10269 (target_terminal::init): Adjust.
10270 (target_terminal::inferior): Adjust to per-inferior
10272 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
10273 (target_terminal::ours, target_terminal::ours_for_output): Use
10274 target_terminal_is_ours_kind.
10275 (target_interrupt): Remove ptid parameter. Adjust.
10276 (default_target_pass_ctrlc): Adjust.
10277 * target.h (target_ops::to_terminal_save_inferior): New field.
10278 (target_ops::to_interrupt): Remove ptid_t parameter.
10279 (target_interrupt): Remove ptid_t parameter. Update comment.
10280 (target_pass_ctrlc): Update comment.
10281 * target/target.h (target_terminal_state): New scoped enum,
10282 factored out of ...
10283 (target_terminal::terminal_state): ... here.
10284 (target_terminal::inferior): Update comments.
10285 (target_terminal::restore_inferior): New.
10286 (target_terminal::is_inferior, target_terminal::is_ours)
10287 (target_terminal::is_ours_for_output): Adjust.
10288 (target_terminal::scoped_restore_terminal_state): Adjust to
10289 rename, and call restore_inferior() instead of inferior().
10290 (target_terminal::scoped_restore_terminal_state::m_state): Change
10292 (target_terminal::terminal_state): Rename to ...
10293 (target_terminal::m_terminal_state): ... this and change type.
10295 2018-01-30 Pedro Alves <palves@redhat.com>
10297 * linux-nat.c (wait_for_signal): New function.
10298 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
10300 (async_terminal_is_ours)
10301 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
10302 (linux_nat_add_target): Don't override
10303 to_terminal_inferior/to_terminal_ours.
10305 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
10307 * remote.c (remote_follow_fork): Don't call "detach_inferior".
10309 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
10311 * dwarf2read.c (free_dwo_files): Add forward-declaration.
10312 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
10313 dwarf2_per_objfile_free here.
10314 (dwarf2_per_objfile_free): Remove.
10315 (_initialize_dwarf2_read): Don't register
10316 dwarf2_per_objfile_free as a registry cleanup.
10318 2018-01-27 Eli Zaretskii <eliz@gnu.org>
10320 Avoid compilation errors in MinGW native builds
10322 The error is triggered by including python-internal.h, and the
10325 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
10326 from build-gnulib/import/math.h:27,
10327 from d:/usr/Python26/include/pyport.h:235,
10328 from d:/usr/Python26/include/Python.h:58,
10329 from python/python-internal.h:94,
10330 from python/py-arch.c:24:
10331 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
10335 This happens because Python headers define 'hypot' to expand t
10336 '_hypot' in the Windows builds.
10337 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
10338 'hypoth'. This avoids a compilation error.
10340 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10342 * MAINTAINERS (Write After Approval): Fix ordering.
10344 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10346 * MAINTAINERS (Write After Approval): Add Alan Hayward.
10348 2018-01-26 Alan Modra <amodra@gmail.com>
10350 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
10351 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
10352 Remove nop. Make const. Comment.
10353 (powerpc32_plt_stub_so_2): New.
10354 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
10355 Correct count. Update uses.
10356 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
10357 Move common code reading PLT entry word. Correct
10358 powerpc32_plt_stub PLT address calculation.
10359 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
10360 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
10361 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
10362 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
10363 (ppc64_standard_linkage8): Likewise.
10364 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
10365 Correct insns description.
10366 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
10368 2018-01-24 Pedro Alves <palves@redhat.com>
10370 GCC PR libstdc++/83906
10371 * gdbtypes.c (operator==(const dynamic_prop &,
10372 const dynamic_prop &)): New.
10373 (operator==(const range_bounds &, const range_bounds &)): New.
10374 (check_types_equal): Use them instead of memcmp.
10375 * gdbtypes.h (operator==(const dynamic_prop &,
10376 const dynamic_prop &)): Declare.
10377 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
10378 (operator==(const range_bounds &, const range_bounds &)): Declare.
10379 (operator!=(const range_bounds &, const range_bounds &)): Declare.
10381 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10383 * s390-linux-tdep.c (s390_record_address_mask)
10384 (s390_record_calc_disp_common, s390_record_calc_disp)
10385 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10386 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10387 (s390_process_record): Move to s390-tdep.c.
10388 (s390_linux_init_abi_any): Adjust.
10389 * s390-tdep.c (s390_record_address_mask)
10390 (s390_record_calc_disp_common, s390_record_calc_disp)
10391 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10392 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10393 (s390_process_record): Moved from s390-linux-tdep.c
10394 (s390_gdbarch_init): Adjust.
10396 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10398 * s390-linux-nat.c (s390-tdep.h): New include.
10399 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
10400 (HFILES_NO_SRCDIR): Add s390-tdep.h.
10401 (ALLDEPFILES): Add s390-tdep.c.
10402 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
10403 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
10404 * s390-tdep.h: ...this. New file.
10405 * s390-linux-tdep.c (s390-tdep.h): New include.
10406 (_initialize_s390_tdep): Rename to...
10407 (_initialize_s390_linux_tdep): ...this and adjust.
10408 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
10409 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
10411 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
10412 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
10413 (s390_is_partial_instruction, s390_software_single_step)
10414 (is_non_branch_ril, s390_displaced_step_copy_insn)
10415 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
10416 (s390_prologue_data, s390_addr, s390_store, s390_load)
10417 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
10418 (s390_register_call_saved, s390_guess_tracepoint_registers)
10419 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
10420 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
10421 (s390_pseudo_register_name, s390_pseudo_register_type)
10422 (s390_pseudo_register_read, s390_pseudo_register_write)
10423 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
10424 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
10425 (s390_addr_bits_remove, s390_address_class_type_flags)
10426 (s390_address_class_type_flags_to_name)
10427 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
10428 (s390_function_arg_float, s390_function_arg_vector)
10429 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
10430 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
10431 (s390_frame_align, s390_register_return_value, s390_return_value)
10432 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
10433 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
10434 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
10435 (s390_trad_frame_prev_register, s390_unwind_cache)
10436 (s390_prologue_frame_unwind_cache)
10437 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
10438 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
10439 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
10440 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
10441 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
10442 (s390_frame_base_address, s390_local_base_address)
10443 (s390_frame_base, s390_gcc_target_options)
10444 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
10445 (s390_validate_reg_range, s390_tdesc_valid)
10446 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
10447 * s390-tdep.c: ...this. New file.
10449 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10451 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
10452 (s390_process_record, s390_gdbarch_tdep_alloc)
10453 (s390_linux_init_abi_any): Use/set new hook.
10455 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10457 * s390-linux-tdep.c (osabi.h): New include.
10458 (s390_linux_init_abi_31, s390_linux_init_abi_64)
10459 (s390_linux_init_abi_any): New functions.
10460 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
10462 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10464 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
10465 tdesc_has_registers check
10467 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10469 * s390-linux-tdep.c (s390_tdesc_valid): New function.
10470 (s390_validate_reg_range): New macro.
10471 (s390_gdbarch_init): Adjust.
10473 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10475 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
10476 (s390_gdbarch_tdep_alloc): Adjust.
10477 (s390_gdbarch_init): Adjust.
10479 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10481 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
10482 <have_tdb>: Change type to bool.
10483 (s390_gdbarch_tdep_alloc): Adjust.
10484 (s390_gdbarch_init): Adjust.
10486 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10488 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
10489 (gdbarch_tdep) <have_upper, have_vx>: New fields.
10490 (s390_gdbarch_tdep_alloc): New function.
10491 (s390_gdbarch_init): Allocate tdep at start and use its fields
10492 instead of separate variables.
10494 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10496 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
10497 when looking for cached gdbarch and add comment for remaining.
10499 2018-01-22 Pedro Alves <palves@redhat.com>
10500 Sergio Durigan Junior <sergiodj@redhat.com>
10502 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
10505 2018-01-22 Maciej W. Rozycki <macro@mips.com>
10507 * MAINTAINERS: Update my company e-mail address.
10509 2018-01-22 Yao Qi <yao.qi@linaro.org>
10511 * regcache.c (cooked_write_test): New function.
10512 (_initialize_regcache): Register the test.
10514 2018-01-22 Yao Qi <yao.qi@linaro.org>
10516 * ia64-tdep.c (ia64_pseudo_register_read): Call
10517 regcache->cooked_read instead of regcache_cooked_read_unsigned.
10518 * m32c-tdep.c (m32c_cat_read): Likewise.
10519 (m32c_r3r2r1r0_read): Likewise.
10520 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10521 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10523 2018-01-22 Yao Qi <yao.qi@linaro.org>
10525 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
10526 method raw_read instead of regcache_raw_read.
10527 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10528 * arm-tdep.c (arm_neon_quad_read): Likewise.
10529 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10530 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10531 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10532 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
10533 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10534 (i386_pseudo_register_read_into_value): Likewise.
10535 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10536 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10537 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10538 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
10539 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
10540 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10541 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10542 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10543 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
10545 2018-01-22 Yao Qi <yao.qi@linaro.org>
10547 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
10548 * configure.tgt: Remove target mt.
10549 * mt-tdep.c: Remove.
10550 * regcache.c (cooked_read_test): Remove the check for mt.
10552 2018-01-22 Yao Qi <yao.qi@linaro.org>
10554 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10555 instead of gdbarch_pseudo_register_read_value.
10557 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10559 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10562 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10564 * linespec.c (create_sals_line_offset): Remove code that preserved
10565 the symtab_and_line's line number.
10567 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10569 * varobj.c (varobj_create): Don't set valid_block when creating a
10572 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10574 * varobj.c (varobj_create): Remove out of date comment.
10576 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10579 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10580 updating innermost block.
10581 * parse.c (innermost_block_tracker::update): Take extra type
10582 parameter, and check types match before updating innermost block.
10583 (write_dollar_variable): Update innermost block for registers.
10584 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10585 (innermost_block_tracker::innermost_block_tracker): Initialise
10587 (innermost_block_tracker::reset): Take type parameter.
10588 (innermost_block_tracker::update): Take type parameter, and pass
10589 type through as needed.
10590 (innermost_block_tracker::m_types): New member.
10591 * varobj.c (varobj_create): Pass type when reseting innermost
10594 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10596 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10597 * ada-lang.c (resolve_subexp): Likewise.
10598 * breakpoint.c (set_breakpoint_condition) Likewise.
10599 (watch_command_1) Likewise.
10600 * c-exp.y (variable): Likewise.
10601 * d-exp.y (PrimaryExpression): Likewise.
10602 * f-exp.y (variable): Likewise.
10603 * go-exp.y (variable): Likewise.
10604 * m2-exp.y (variable): Likewise.
10605 * objfiles.c (objfile::~objfile): Likewise.
10606 * p-exp.y (variable): Likewise.
10607 * parse.c (innermost_block): Change type.
10608 * parser-defs.h (class innermost_block_tracker): New.
10609 (innermost_block): Change to innermost_block_tracker.
10610 * printcmd.c (display_command): Switch to innermost_block API.
10611 (do_one_display): Likewise.
10612 * rust-exp.y (do_one_display): Likewise.
10613 * symfile.c (clear_symtab_users): Likewise.
10614 * varobj.c (varobj_create): Switch to innermost_block API, replace
10615 use of innermost_block with block stored on varobj object.
10617 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10619 * expression.h (innermost_block): Remove declaration.
10620 * varobj.c: Add 'parser-defs.h' include.
10622 2018-01-19 Tom Tromey <tom@tromey.com>
10624 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
10625 symbols in the static and global blocks.
10627 2018-01-19 James Clarke <jrtc27@jrtc27.com>
10629 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
10630 gdb_ptrace.h, and move including gdb_wait.h ...
10631 * nat/linux-ptrace.h: ... to here.
10633 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10635 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
10636 inf_ptrace_detach_success.
10637 (inf_ptrace_detach_success): Add inferior parameter, use it
10638 instead of inferior_ptid, pass it to detach_inferior.
10639 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
10641 * inferior.c (detach_inferior): Add overload that takes an
10643 * inferior.h (detach_inferior): Likewise.
10644 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
10645 use inferior_ptid, adjust call to inf_ptrace_detach_success.
10646 * linux-thread-db.c (thread_db_detach): Use inf parameter.
10648 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10650 * target.h (struct target_ops) <to_detach>: Add inferior
10652 (target_detach): Likewise.
10653 * target.c (dispose_inferior): Pass inferior down.
10654 (target_detach): Pass inferior down. Assert that it is equal to
10655 the current inferior.
10656 * aix-thread.c (aix_thread_detach): Pass inferior down.
10657 * corefile.c (core_file_command): Pass current_inferior() down.
10658 * corelow.c (core_detach): Add inferior parameter.
10659 * darwin-nat.c (darwin_detach): Likewise.
10660 * gnu-nat.c (gnu_detach): Likewise.
10661 * inf-ptrace.c (inf_ptrace_detach): Likewise.
10662 * infcmd.c (detach_command): Pass current_inferior() down to
10664 * infrun.c (follow_fork_inferior): Pass parent_inf to
10666 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
10668 * linux-nat.c (linux_nat_detach): Add inferior parameter.
10669 * linux-thread-db.c (thread_db_detach): Likewise.
10670 * nto-procfs.c (procfs_detach): Likewise.
10671 * procfs.c (procfs_detach): Likewise.
10672 * record.c (record_detach): Likewise.
10673 * record.h (struct inferior): Forward-declare.
10674 (record_detach): Add inferior parameter.
10675 * remote-sim.c (gdbsim_detach): Likewise.
10676 * remote.c (remote_detach_1): Likewise.
10677 (remote_detach): Likewise.
10678 (extended_remote_detach): Likewise.
10679 * sol-thread.c (sol_thread_detach): Likewise.
10680 * target-debug.h (target_debug_print_inferior_p): New macro.
10681 * target-delegates.c: Re-generate.
10682 * top.c (kill_or_detach): Pass inferior down to target_detach.
10683 * windows-nat.c (windows_detach): Add inferior parameter.
10685 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10687 * target.h (struct target_ops) <to_detach>: Remove args
10689 (target_detach): Likewise.
10690 * target.c (dispose_inferior): Adjust.
10691 (target_detach): Remove args parameter, adjust.
10692 * aix-thread.c (aix_thread_detach): Adjust.
10693 * corefile.c (core_file_command): Adjust.
10694 * corelow.c (core_detach): Adjust.
10695 * darwin-nat.c (darwin_detach): Adjust.
10696 * gnu-nat.c (gnu_detach): Adjust.
10697 * inf-ptrace.c (inf_ptrace_detach): Adjust.
10698 * infcmd.c (detach_command): Adjust
10699 * infrun.c (follow_fork_inferior): Adjust.
10700 (handle_vfork_child_exec_or_exit): Adjust.
10701 * linux-fork.c (linux_fork_detach): Remove args parameter.
10702 * linux-fork.h (linux_fork_detach): Likewise.
10703 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
10704 * linux-thread-db.c (thread_db_detach): Likewise.
10705 * nto-procfs.c (procfs_detach): Likewise.
10706 * procfs.c (procfs_detach): Likewise.
10707 (do_detach): Remove signo parameter.
10708 * record.c (record_detach): Remove args parameter.
10709 * record.h (record_detach): Likewise.
10710 * remote-sim.c (gdbsim_detach): Likewise.
10711 * remote.c (remote_detach_1): Likewise.
10712 (remote_detach): Likewise.
10713 (extended_remote_detach): Likewise.
10714 * sol-thread.c (sol_thread_detach): Likewise.
10715 * target-delegates.c: Re-generate.
10716 * top.c (struct qt_args) <args>: Remove field.
10717 (kill_or_detach): Don't pass args.
10718 (quit_force): Don't set args.
10719 * windows-nat.c (windows_detach): Remove args parameter.
10721 2018-01-19 Yao Qi <yao.qi@linaro.org>
10723 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
10724 (arm_linux_init_abi): Install it.
10726 2018-01-19 Yao Qi <yao.qi@linaro.org>
10728 * osabi.c (gdb_osabi_names): Extend the regexp for
10729 arm-linux-gnueabihf.
10731 2018-01-18 Yao Qi <yao.qi@linaro.org>
10733 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
10735 (abbrev_table::add_abbrev): Update.
10736 (abbrev_table::lookup_abbrev): Update.
10738 2018-01-18 Yao Qi <yao.qi@linaro.org>
10740 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
10742 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
10744 * compile/compile.c (compile_to_object): Convert "triplet_rx"
10747 2018-01-17 Tom Tromey <tom@tromey.com>
10749 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
10751 2018-01-17 Tom Tromey <tom@tromey.com>
10753 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
10754 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
10755 (create_array_type_with_stride): Update.
10756 * dwarf2read.c (set_die_type): Update.
10758 2018-01-17 Tom Tromey <tom@tromey.com>
10760 * dwarf2read.c (delayed_method_info): Remove typedef.
10761 (dwarf2_cu::method_info): Now a std::vector.
10762 (add_to_method_list): Update.
10763 (free_delayed_list): Remove.
10764 (compute_delayed_physnames): Update.
10765 (process_full_comp_unit, process_full_type_unit): Clear the method
10766 list. Remove cleanups.
10767 (psymtab_include_file_name): Add name_holder parameter. Use
10768 unique_xmalloc_ptr.
10769 (dwarf_decode_lines): Update.
10771 2018-01-17 Tom Tromey <tom@tromey.com>
10772 Simon Marchi <simon.marchi@ericsson.com>
10774 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
10775 (dwarf2_per_objfile::free_cached_comp_units)
10776 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10777 (init_cutu_and_read_dies_no_follow): Update.
10778 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
10779 (dwarf2_cu::~dwarf2_cu): New.
10780 (free_heap_comp_unit, free_stack_comp_unit): Remove.
10781 (age_cached_comp_units, free_one_cached_comp_unit): Update.
10783 2018-01-17 Tom Tromey <tom@tromey.com>
10784 Simon Marchi <simon.marchi@ericsson.com>
10786 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
10787 (struct die_reader_specs) <abbrev_table>: New member.
10788 (struct abbrev_table): Add constructor.
10789 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
10790 <abbrev_obstack>: Now an auto_obstack.
10791 (abbrev_table_up): New typedef.
10792 (init_cu_die_reader): Add abbrev_table parameter.
10793 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
10794 Add result_dwo_abbrev_table.
10795 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10796 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
10798 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
10800 (skip_children): Update.
10801 (abbrev_table::alloc_abbrev): Rename from
10802 abbrev_table_alloc_abbrev.
10803 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
10804 (abbrev_table::lookup_abbrev): Rename from
10805 abbrev_table_lookup_abbrev.
10806 (abbrev_table_read_table): Return abbrev_table_up.
10807 (abbrev_table_free, abbrev_table_free_cleanup)
10808 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
10809 (load_partial_dies): Update.
10811 2018-01-17 Tom Tromey <tom@tromey.com>
10813 * dwarf2read.c (dwarf2_compute_name): Update comment.
10814 (read_func_scope, read_variable): Update.
10815 (new_symbol): Remove.
10816 (new_symbol_full): Rename to new_symbol.
10818 2018-01-17 Mike Gulick <mgulick@mathworks.com>
10821 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
10822 a warning instead of throwing an error, set section size to 0 and return
10824 * gdb_bfd.h (gdb_bfd_map_section): Update description.
10826 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10828 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
10830 (linux_ptrace_attach_fail_reason_string): Likewise.
10831 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
10833 (linux_ptrace_attach_fail_reason_string): Likewise.
10834 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
10836 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10838 * linux-nat.c (linux_nat_attach): Remove xstrdup.
10840 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
10843 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
10844 checking for fs_base/gs_base fields in struct user_regs_struct.
10845 * configure: Regenerate.
10847 2018-01-17 Yao Qi <yao.qi@linaro.org>
10849 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
10851 (aarch64_linux_init_abi): Install it to gdbarch hook
10852 gcc_target_options.
10854 2018-01-15 Pedro Alves <palves@redhat.com>
10856 * common/signals-state-save-restore.c
10857 (save_original_signals_state): Fix typos.
10859 2017-01-12 Tom Tromey <tom@tromey.com>
10860 Sergio Durigan Junior <sergiodj@redhat.com>
10862 * Makefile.in (install-only): Install gdb-add-index.
10864 2018-01-12 John Baldwin <jhb@FreeBSD.org>
10866 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
10868 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10870 * infrun.c (keep_going_pass_signal): Clear step-over info when
10871 insert_breakpoints fails.
10873 2018-01-11 Pedro Alves <palves@redhat.com>
10876 * infrun.c (resume): Rename to ...
10877 (resume_1): ... this.
10878 (resume): Reimplement as wrapper around resume_1.
10880 2018-01-11 Pedro Alves <palves@redhat.com>
10883 * remote.c (remote_parse_stop_reply): Default to the last-set
10884 general thread instead of to 'magic_null_ptid'.
10886 2018-01-10 Pedro Alves <palves@redhat.com>
10888 * language.h (language_get_symbol_name_matcher): Rename ...
10889 (get_symbol_name_matcher): ... this.
10890 * language.c (language_get_symbol_name_matcher): Ditto.
10891 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
10894 2018-01-10 Pedro Alves <palves@redhat.com>
10898 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
10899 Adjust to use language_get_symbol_name_matcher instead of
10900 language_defn::la_get_symbol_name_matcher.
10901 * language.c (language_get_symbol_name_matcher): If in Ada mode
10902 and the lookup name is a verbatim match, return Ada's matcher.
10903 * language.h (language_get_symbol_name_matcher): Adjust comment.
10904 (ada_lookup_name_info::verbatim_p):: New method.
10906 2018-01-10 Pedro Alves <palves@redhat.com>
10909 * ada-lang.c (ada_collect_symbol_completion_matches): If the
10910 minsym's language is language_auto or language_cplus, pass down
10911 language_ada instead.
10912 * symtab.c (compare_symbol_name): Don't frob symbol language here.
10914 2018-01-10 Pedro Alves <palves@redhat.com>
10917 * minsyms.c (linkage_name_str): New function.
10918 (iterate_over_minimal_symbols): Use it.
10920 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10922 * NEWS: Document that 'info proc' now works on FreeBSD.
10924 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10926 * configure.ac: Check for kinfo_getfile in libutil.
10927 * configure: Regenerate.
10928 * config.in: Regenerate.
10929 * fbsd-nat.c: Include "fbsd-tdep.h".
10930 (fbsd_fetch_cmdline): New.
10931 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
10932 rather than calling error.
10933 (fbsd_info_proc): New.
10934 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
10935 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
10936 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
10938 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10940 * fbsd-nat.c (struct free_deleter): Remove.
10941 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
10943 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10945 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
10946 NULL for an empty pathname.
10948 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10950 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
10951 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
10952 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
10953 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
10954 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
10955 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
10956 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
10957 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
10958 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
10959 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
10960 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
10961 (fbsd_core_fetch_timeval, fbsd_print_sigset)
10962 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
10963 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
10964 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
10966 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
10968 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
10969 (gnu_xfer_auxv): New function.
10970 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
10971 TARGET_OBJECT_AUXV.
10973 2018-01-08 Yao Qi <yao.qi@linaro.org>
10974 Simon Marchi <simon.marchi@ericsson.com>
10976 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
10978 (COMMON_OBS): Remove selftest.o.
10979 * configure.ac: Append selftest-arch.c and common/selftest.c to
10980 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
10981 * configure: Re-generated.
10982 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
10984 (maintenance_info_selftests): Likewise.
10986 2018-01-08 Xavier Roirand <roirand@adacore.com>
10988 * ada-valprint.c (val_print_packed_array_elements): Use
10989 proper number of elements when printing an array indexed
10990 by an enumeration type.
10992 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10994 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
10995 (dw2_get_file_names_reader): Adjust.
10996 (lookup_dwo_signatured_type): Adjust.
10997 (lookup_dwp_signatured_type): Adjust.
10998 (lookup_signatured_type): Adjust.
10999 (create_type_unit_group): Adjust.
11000 (get_type_unit_group): Adjust.
11001 (process_psymtab_comp_unit_reader): Adjust.
11002 (build_type_psymtabs_reader): Adjust.
11003 (scan_partial_symbols): Adjust.
11004 (add_partial_symbol): Adjust.
11005 (add_partial_subprogram): Adjust.
11006 (peek_die_abbrev): Adjust.
11007 (fixup_go_packaging): Adjust.
11008 (process_imported_unit_die): Adjust.
11009 (dwarf2_compute_name): Adjust.
11010 (dwarf2_physname): Adjust.
11011 (read_import_statement): Adjust.
11012 (handle_DW_AT_stmt_list): Adjust.
11013 (read_file_scope): Adjust.
11014 (read_func_scope): Adjust.
11015 (read_lexical_block_scope): Adjust.
11016 (read_call_site_scope): Adjust.
11017 (read_variable): Adjust.
11018 (dwarf2_rnglists_process): Adjust.
11019 (dwarf2_ranges_process): Adjust.
11020 (dwarf2_ranges_read): Adjust.
11021 (dwarf2_get_pc_bounds): Adjust.
11022 (dwarf2_record_block_ranges): Adjust.
11023 (dwarf2_add_field): Adjust.
11024 (dwarf2_add_member_fn): Adjust.
11025 (read_structure_type): Adjust.
11026 (process_structure_scope): Adjust.
11027 (read_enumeration_type): Adjust.
11028 (read_array_type): Adjust.
11029 (mark_common_block_symbol_computed): Adjust.
11030 (read_common_block): Adjust.
11031 (read_namespace_type): Adjust.
11032 (read_namespace): Adjust.
11033 (read_module_type): Adjust.
11034 (read_tag_pointer_type): Adjust.
11035 (read_tag_ptr_to_member_type): Adjust.
11036 (read_tag_string_type): Adjust.
11037 (read_subroutine_type): Adjust.
11038 (read_typedef): Adjust.
11039 (read_base_type): Adjust.
11040 (attr_to_dynamic_prop): Adjust.
11041 (read_subrange_type): Adjust.
11042 (read_unspecified_type): Adjust.
11043 (dwarf2_read_abbrevs): Adjust.
11044 (load_partial_dies): Adjust.
11045 (read_partial_die): Adjust.
11046 (find_partial_die): Adjust.
11047 (guess_partial_die_structure_name): Adjust.
11048 (fixup_partial_die): Adjust.
11049 (read_attribute_value): Adjust.
11050 (read_addr_index): Adjust.
11051 (read_addr_index_from_leb128): Adjust.
11052 (read_str_index): Adjust.
11053 (dwarf2_string_attr): Adjust.
11054 (get_debug_line_section): Adjust.
11055 (dwarf_decode_line_header): Adjust.
11056 (lnp_state_machine::check_line_address): Adjust.
11057 (dwarf_decode_lines_1): Adjust.
11058 (dwarf_decode_lines): Adjust.
11059 (dwarf2_start_symtab): Adjust.
11060 (var_decode_location): Adjust.
11061 (new_symbol_full): Adjust.
11062 (dwarf2_const_value_data): Adjust.
11063 (dwarf2_const_value_attr): Adjust.
11064 (dwarf2_const_value): Adjust.
11065 (die_type): Adjust.
11066 (die_containing_type): Adjust.
11067 (build_error_marker_type): Adjust.
11068 (lookup_die_type): Adjust.
11069 (guess_full_die_structure_name): Adjust.
11070 (anonymous_struct_prefix): Adjust.
11071 (determine_prefix): Adjust.
11072 (dwarf2_name): Adjust.
11073 (follow_die_ref_or_sig): Adjust.
11074 (follow_die_offset): Adjust.
11075 (follow_die_ref): Adjust.
11076 (follow_die_sig_1): Adjust.
11077 (follow_die_sig): Adjust.
11078 (get_signatured_type): Adjust.
11079 (get_DW_AT_signature_type): Adjust.
11080 (decode_locdesc): Adjust.
11081 (dwarf_decode_macros): Adjust.
11082 (cu_debug_loc_section): Adjust.
11083 (fill_in_loclist_baton): Adjust.
11084 (dwarf2_symbol_mark_computed): Adjust.
11085 (init_one_comp_unit): Don't assign
11086 dwarf2_cu::dwarf2_per_objfile.
11087 (set_die_type): Adjust.
11089 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11091 * dwarf2read.c (struct mapped_debug_names): Add constructor.
11092 <dwarf2_per_objfile>: New field.
11093 (dwarf2_per_objfile): Remove global.
11094 (get_dwarf2_per_objfile): New function.
11095 (set_dwarf2_per_objfile): New function.
11096 (dwarf2_build_psymtabs_hard): Change objfile parameter to
11097 dwarf2_per_objfile.
11098 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11099 (read_abbrev_offset): Likewise.
11100 (read_indirect_string): Likewise.
11101 (read_indirect_line_string): Likewise.
11102 (read_indirect_string_at_offset): Likewise.
11103 (read_indirect_string_from_dwz): Likewise.
11104 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11105 dwarf2_per_objfile.
11106 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11107 (create_all_comp_units): Change objfile parameter to
11108 dwarf2_per_objfile.
11109 (create_all_type_units): Likewise.
11110 (process_queue): Add dwarf2_per_objfile parameter.
11111 (read_and_check_comp_unit_head): Likewise.
11112 (lookup_dwo_unit_in_dwp): Likewise.
11113 (get_dwp_file): Likewise.
11114 (process_cu_includes): Likewise.
11115 (struct free_dwo_file_cleanup_data): New struct.
11116 (dwarf2_has_info): Use get_dwarf2_per_objfile and
11117 set_dwarf2_per_objfile.
11118 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
11119 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
11120 context, adjust calls.
11121 (dw2_instantiate_symtab): Likewise.
11122 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
11123 (dw2_get_cu): Likewise.
11124 (create_cu_from_index_list): Change objfile parameter to
11125 dwarf2_per_objfile.
11126 (create_cus_from_index_list): Get dwarf2_per_objfile from
11127 context, adjust calls.
11128 (create_cus_from_index): Likewise.
11129 (create_signatured_type_table_from_index): Change objfile
11130 parameter to dwarf2_per_objfile.
11131 (create_signatured_type_table_from_debug_names): Change objfile
11132 parameter to dwarf2_per_objfile.
11133 (create_addrmap_from_index): Likewise.
11134 (create_addrmap_from_aranges): Likewise.
11135 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
11136 (dw2_setup): Remove.
11137 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
11139 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
11140 get_dwarf2_per_objfile.
11141 (dw2_forget_cached_source_info): Likewise.
11142 (dw2_map_symtabs_matching_filename): Likewise.
11143 (struct dw2_symtab_iterator) <index>: Remove.
11144 <dwarf2_per_objfile>: New field.
11145 (dw2_symtab_iter_init): Replace index parameter with
11146 dwarf2_per_objfile.
11147 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
11148 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
11149 (dw2_print_stats): Likewise.
11150 (dw2_dump): Likewise.
11151 (dw2_expand_symtabs_for_function): Likewise.
11152 (dw2_expand_all_symtabs): Likewise.
11153 (dw2_expand_symtabs_with_fullname): Likewise.
11154 (dw2_expand_marked_cus): Replace index and objfile parameters
11155 with dwarf2_per_objfile.
11156 (dw_expand_symtabs_matching_file_matcher): Add
11157 dwarf2_per_objfile parameter and adjust calls.
11158 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
11160 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
11161 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
11163 (create_cus_from_debug_names_list): Replace objfile parameter
11164 with dwarf2_per_objfile and adjust calls.
11165 (create_cus_from_debug_names): Likewise.
11166 (dwarf2_read_debug_names): Likewise.
11167 (mapped_debug_names::namei_to_name): Adjust call.
11168 (dw2_debug_names_iterator::next): Likewise.
11169 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
11170 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
11171 (dw2_debug_names_dump): Likewise.
11172 (dw2_debug_names_expand_symtabs_for_function): Likewise.
11173 (dw2_debug_names_expand_symtabs_matching): Likewise.
11174 (dwarf2_initialize_objfile): Likewise.
11175 (dwarf2_build_psymtabs): Likewise.
11176 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
11178 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
11179 (read_and_check_comp_unit_head): Likewise.
11180 (read_abbrev_offset): Likewise.
11181 (create_debug_type_hash_table): Likewise.
11182 (create_debug_types_hash_table): Likewise.
11183 (create_all_type_units): Replace objfile parameter with
11184 dwarf2_per_objfile.
11185 (add_type_unit): Add dwarf2_per_objfile parameter.
11186 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
11187 with dwarf2_per_objfile.
11188 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
11189 (lookup_dwp_signatured_type): Likewise.
11190 (lookup_signatured_type): Likewise.
11191 (read_cutu_die_from_dwo): Likewise.
11192 (init_tu_and_read_dwo_dies): Likewise.
11193 (init_cutu_and_read_dies): Likewise.
11194 (init_cutu_and_read_dies_no_follow): Likewise.
11195 (allocate_type_unit_groups_table): Add objfile parameter.
11196 (create_type_unit_group): Use dwarf2_per_objfile from cu.
11197 (get_type_unit_group): Likewise.
11198 (process_psymtab_comp_unit): Update call.
11199 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
11200 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
11201 (print_tu_stats): Likewise.
11202 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
11203 in void* parameter.
11204 (build_type_psymtabs): Change objfile parameter to
11205 dwarf2_per_objfile.
11206 (process_skeletonless_type_unit): Use dwarf2_per_objfile
11207 passed in void* parameter.
11208 (process_skeletonless_type_units): Change objfile parameter to
11209 dwarf2_per_objfile.
11210 (set_partial_user): Likewise.
11211 (dwarf2_build_psymtabs_hard): Likewise.
11212 (read_comp_units_from_section): Likewise.
11213 (create_all_comp_units): Likewise.
11214 (scan_partial_symbols): Update calls.
11215 (add_partial_symbol): Likewise.
11216 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
11217 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
11218 (process_queue): Add dwarf2_per_objfile parameter.
11219 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
11220 (compute_compunit_symtab_includes): Likewise.
11221 (process_cu_includes): Add dwarf2_per_objfile parameter.
11222 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
11223 (process_full_type_unit): Likewise.
11224 (process_imported_unit_die): Update call.
11225 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
11226 (read_file_scope): Likewise.
11227 (allocate_dwo_file_hash_table): Add objfile parameter.
11228 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
11229 (create_cus_hash_table): Likewise.
11230 (create_dwp_hash_table): Likewise.
11231 (create_dwo_unit_in_dwp_v1): Likewise.
11232 (create_dwp_v2_section): Likewise.
11233 (create_dwo_unit_in_dwp_v2): Likewise.
11234 (lookup_dwo_unit_in_dwp): Likewise.
11235 (try_open_dwop_file): Likewise.
11236 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
11237 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
11238 cleanup to include a reference to dwarf2_per_objfile.
11239 (open_dwp_file): Add dwarf2_per_objfile parameter.
11240 (open_and_init_dwp_file): Likewise.
11241 (get_dwp_file): Likewise.
11242 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
11243 (queue_and_load_all_dwo_tus): Update call.
11244 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
11246 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
11247 (dwarf2_ranges_process): Likewise.
11248 (dwarf2_get_pc_bounds): Likewise.
11249 (mark_common_block_symbol_computed): Likewise.
11250 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
11251 (dwarf2_read_abbrevs): Update call.
11252 (read_partial_die): Use dwarf2_per_objfile from cu.
11253 (find_partial_die): Likewise.
11254 (fixup_partial_die): Likewise.
11255 (read_attribute_value): Likewise.
11256 (read_indirect_string_at_offset_from): Add objfile parameter.
11257 (read_indirect_string_at_offset): Add dwarf2_per_objfile
11259 (read_indirect_string_from_dwz): Add objfile parameter.
11260 (read_indirect_string): Add objfile parameter.
11261 (read_addr_index_1): Add dwarf2_per_objfile parameter.
11262 (read_addr_index): Use dwarf2_per_objfile from cu.
11263 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
11265 (read_str_index): Use dwarf2_per_objfile from cu.
11266 (get_debug_line_section): Likewise.
11267 (read_formatted_entries): Add dwarf2_per_objfile parameter.
11268 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
11269 (new_symbol_full): Use dwarf2_per_objfile from cu.
11270 (build_error_marker_type): Likewise.
11271 (lookup_die_type): Likewise.
11272 (determine_prefix): Likewise.
11273 (follow_die_offset): Likewise.
11274 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
11275 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
11276 (dwarf2_fetch_die_type_sect_off): Likewise.
11277 (dwarf2_get_die_type): Likewise.
11278 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
11279 (get_signatured_type): Likewise.
11280 (get_DW_AT_signature_type): Likewise.
11281 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
11282 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
11283 (cu_debug_loc_section): Likewise.
11284 (fill_in_loclist_baton): Likewise.
11285 (dwarf2_symbol_mark_computed): Likewise.
11286 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11287 dwarf2_per_objfile.
11288 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
11290 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11291 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
11292 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
11293 (set_die_type): Use dwarf2_free_objfile from cu.
11294 (get_die_type_at_offset): Likewise.
11295 (dwarf2_per_objfile_free): Don't assign global variable.
11296 (debug_names) <constructor>: Add dwarf2_per_objfile
11297 parameter, update m_debugstrlookup construction.
11298 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
11300 <m_dwarf2_per_objfile>: New field.
11301 <lookup>: Use m_dwarf2_per_objfile.
11302 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
11303 (psyms_seen_size): Likewise.
11304 (write_gdbindex): Replace objfile parameter with
11305 dwarf2_per_objfile.
11306 (write_debug_names): Likewise.
11307 (write_psymtabs_to_index): Likewise.
11308 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
11311 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11313 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
11314 <dwarf2_per_objfile>: New field.
11315 (struct dwarf2_per_cu_data) <objfile>: Remove.
11316 <dwarf2_per_objfile>: New field.
11317 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
11319 (create_signatured_type_table_from_index): Likewise.
11320 (create_debug_type_hash_table): Likewise.
11321 (fill_in_sig_entry_from_dwo_entry): Likewise.
11322 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
11323 (create_type_unit_group): Assign dwarf2_per_objfile instead of
11325 (create_partial_symtab): Access objfile through
11326 dwarf2_per_objfile.
11327 (process_psymtab_comp_unit_reader): Likewise.
11328 (read_comp_units_from_section): Likewise.
11329 (scan_partial_symbols): Likewise.
11330 (add_partial_symbol): Likewise.
11331 (add_partial_subprogram): Likewise.
11332 (peek_die_abbrev): Likewise.
11333 (fixup_go_packaging): Likewise.
11334 (process_full_comp_unit): Likewise.
11335 (process_full_type_unit): Likewise.
11336 (process_imported_unit_die): Likewise.
11337 (dwarf2_compute_name): Likewise.
11338 (dwarf2_physname): Likewise.
11339 (read_import_statement): Likewise.
11340 (create_cus_hash_table): Assign dwarf2_physname instead of
11342 (read_func_scope): Access objfile through dwarf2_per_objfile.
11343 (read_lexical_block_scope): Likewise.
11344 (read_call_site_scope): Likewise.
11345 (read_variable): Likewise.
11346 (dwarf2_rnglists_process): Likewise.
11347 (dwarf2_ranges_process): Likewise.
11348 (dwarf2_ranges_read): Likewise.
11349 (dwarf2_record_block_ranges): Likewise.
11350 (dwarf2_add_field): Likewise.
11351 (dwarf2_add_member_fn): Likewise.
11352 (read_structure_type): Likewise.
11353 (process_structure_scope): Likewise.
11354 (read_enumeration_type): Likewise.
11355 (read_array_type): Likewise.
11356 (read_common_block): Likewise.
11357 (read_namespace_type): Likewise.
11358 (read_namespace): Likewise.
11359 (read_module_type): Likewise.
11360 (read_tag_pointer_type): Likewise.
11361 (read_tag_ptr_to_member_type): Likewise.
11362 (read_tag_string_type): Likewise.
11363 (read_subroutine_type): Likewise.
11364 (read_typedef): Likewise.
11365 (read_base_type): Likewise.
11366 (attr_to_dynamic_prop): Likewise.
11367 (read_subrange_type): Likewise.
11368 (read_unspecified_type): Likewise.
11369 (load_partial_dies): Likewise.
11370 (read_partial_die): Likewise.
11371 (find_partial_die): Likewise.
11372 (guess_partial_die_structure_name): Likewise.
11373 (fixup_partial_die): Likewise.
11374 (read_attribute_value): Likewise.
11375 (read_addr_index_from_leb128): Likewise.
11376 (dwarf2_read_addr_index): Likewise.
11377 (dwarf2_string_attr): Likewise.
11378 (lnp_state_machine::check_line_address): Likewise.
11379 (dwarf_decode_lines_1): Likewise.
11380 (dwarf_decode_lines): Likewise.
11381 (dwarf2_start_symtab): Likewise.
11382 (var_decode_location): Likewise.
11383 (new_symbol_full): Likewise.
11384 (dwarf2_const_value_data): Likewise.
11385 (dwarf2_const_value_attr): Likewise.
11386 (dwarf2_const_value): Likewise.
11387 (die_type): Likewise.
11388 (die_containing_type): Likewise.
11389 (lookup_die_type): Likewise.
11390 (guess_full_die_structure_name): Likewise.
11391 (anonymous_struct_prefix): Likewise.
11392 (dwarf2_name): Likewise.
11393 (follow_die_ref_or_sig): Likewise.
11394 (follow_die_offset): Likewise.
11395 (follow_die_ref): Likewise.
11396 (dwarf2_fetch_die_loc_sect_off): Likewise.
11397 (dwarf2_fetch_constant_bytes): Likewise.
11398 (dwarf2_fetch_die_type_sect_off): Likewise.
11399 (dwarf2_get_die_type): Likewise.
11400 (follow_die_sig): Likewise.
11401 (decode_locdesc): Likewise.
11402 (dwarf2_per_cu_objfile): Likewise.
11403 (dwarf2_per_cu_text_offset): Likewise.
11404 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
11406 (set_die_type): Access objfile through
11407 dwarf2_per_objfile.
11409 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11411 * valprint.c (converted_character_d): Remove typedef.
11412 (DEF_VEC_O (converted_character_d)): Remove.
11413 (count_next_character): Use std::vector.
11414 (print_converted_chars_to_obstack): Likewise.
11415 (generic_printstr): Likewise.
11417 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11419 * xml-support.h (struct gdb_xml_value): Add constructor.
11420 <value>: Change type to unique_xmalloc_ptr.
11421 (gdb_xml_value_s): Remove typedef.
11422 (DEF_VEC_O (gdb_xml_value_s)): Remove.
11423 (gdb_xml_element_start_handler): Change parameter type to
11425 (xml_find_attribute): Likewise.
11426 * xml-support.c (xml_find_attribute): Change parameter type to
11427 std::vector and adjust.
11428 (gdb_xml_values_cleanup): Remove.
11429 (gdb_xml_parser::start_element): Adjust to std::vector.
11430 (xinclude_start_include): Change paraeter type to std::vector
11432 * btrace.c (check_xml_btrace_version): Likewise.
11433 (parse_xml_btrace_block): Likewise.
11434 (parse_xml_btrace_pt_config_cpu): Likewise.
11435 (parse_xml_btrace_pt): Likewise.
11436 (parse_xml_btrace_conf_bts): Likewise.
11437 (parse_xml_btrace_conf_pt): Likewise.
11438 * memory-map.c (memory_map_start_memory): Likewise.
11439 (memory_map_start_property): Likewise.
11440 * osdata.c (osdata_start_osdata): Likewise.
11441 (osdata_start_item): Likewise.
11442 (osdata_start_column): Likewise.
11443 * remote.c (start_thread): Likewise.
11444 * solib-aix.c (library_list_start_library): Likewise.
11445 (library_list_start_list): Likewise.
11446 * solib-svr4.c (library_list_start_library): Likewise.
11447 (svr4_library_list_start_list): Likewise.
11448 * solib-target.c (library_list_start_segment): Likewise.
11449 (library_list_start_section): Likewise.
11450 (library_list_start_library): Likewise.
11451 (library_list_start_list): Likewise.
11452 * tracepoint.c (traceframe_info_start_memory): Likewise.
11453 (traceframe_info_start_tvar): Likewise.
11454 * xml-syscall.c (syscall_start_syscall): Likewise.
11455 * xml-tdesc.c (tdesc_start_target): Likewise.
11456 (tdesc_start_feature): Likewise.
11457 (tdesc_start_reg): Likewise.
11458 (tdesc_start_union): Likewise.
11459 (tdesc_start_struct): Likewise.
11460 (tdesc_start_flags): Likewise.
11461 (tdesc_start_enum): Likewise.
11462 (tdesc_start_field): Likewise.
11463 (tdesc_start_enum_value): Likewise.
11464 (tdesc_start_vector): Likewise.
11466 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11468 * extension.h (struct xmethod_worker) <clone>: Remove.
11469 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
11471 (python_xmethod_worker::clone): Remove.
11472 * valops.c (find_overload_match): Use std::move instead of
11475 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11477 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
11478 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
11479 <free_xmethod_worker_data>: Remove.
11480 <get_matching_xmethod_workers>: Chance VEC to std::vector.
11481 <get_xmethod_arg_types>: Remove.
11482 <get_xmethod_result_type>: Remove.
11483 <invoke_xmethod>: Remove.
11484 * extension.c (new_xmethod_worker): Remove.
11485 (clone_xmethod_worker): Remove.
11486 (get_matching_xmethod_workers): Return void, pass std::vector by
11488 (get_xmethod_arg_types): Rename to...
11489 (xmethod_worker::get_arg_types): ... this, and adjust.
11490 (get_xmethod_result_type): Rename to...
11491 (xmethod_worker::get_result_type): ... this, and adjust.
11492 (invoke_xmethod): Remove.
11493 (free_xmethod_worker): Remove.
11494 (free_xmethod_worker_vec): Remove.
11495 * extension.h (enum ext_lang_rc): Move here from
11497 (struct xmethod_worker): Add constructor and destructor.
11500 <invoke, clone, do_get_result_type, do_get_arg_types>: New
11501 virtual pure methods.
11502 <get_arg_types, get_result_type>: New methods.
11503 (xmethod_worker_ptr): Remove typedef.
11504 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
11505 (xmethod_worker_vec): Remove typedef.
11506 (xmethod_worker_up): New typedef.
11507 (invoke_xmethod): Remove.
11508 (clone_xmethod_worker): Remove.
11509 (free_xmethod_worker): Remove.
11510 (free_xmethod_worker_vec): Remove.
11511 (get_xmethod_arg_types): Remove.
11512 (get_xmethod_result_type): Remove.
11513 * valops.c (find_method_list): Use std::vector, don't use
11514 intermediate vector.
11515 (value_find_oload_method_list): Use std::vector.
11516 (find_overload_match): Use std::vector.
11517 (find_oload_champ): Use std::vector.
11518 * value.c (value_free): Use operator delete.
11519 (value_of_xmethod): Rename to...
11520 (value_from_xmethod): ... this. Don't assign
11521 xmethod_worker::value, take rvalue-reference.
11522 (result_type_of_xmethod): Adjust.
11523 (call_xmethod): Adjust.
11524 * value.h: Include extension.h.
11525 (struct xmethod_worker): Don't forward-declare.
11526 (value_of_xmethod): Rename to...
11527 (value_from_xmethod): ... this, take rvalue-reference.
11528 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
11529 (struct python_xmethod_worker): ... this, add constructor and
11531 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
11532 (gdbpy_free_xmethod_worker_data): Rename to...
11533 (python_xmethod_worker::~python_xmethod_worker): ... this and
11535 (gdbpy_clone_xmethod_worker_data): Rename to...
11536 (python_xmethod_worker::clone): ... this and adjust.
11537 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
11539 (gdbpy_get_xmethod_arg_types): Rename to...
11540 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
11541 (gdbpy_get_xmethod_result_type): Rename to...
11542 (python_xmethod_worker::do_get_result_type): ... this and
11544 (gdbpy_invoke_xmethod): Rename to...
11545 (python_xmethod_worker::invoke): ... this and adjust.
11546 (new_python_xmethod_worker): Rename to...
11547 (python_xmethod_worker::python_xmethod_worker): ... this and
11549 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
11551 (gdbpy_free_xmethod_worker_data): Remove.
11552 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11553 (gdbpy_get_xmethod_arg_types): Remove.
11554 (gdbpy_get_xmethod_result_type): Remove.
11555 (gdbpy_invoke_xmethod): Remove.
11556 * python/python.c (python_extension_ops): Remove obsolete
11559 2018-01-05 Pedro Alves <palves@redhat.com>
11562 * common/signals-state-save-restore.c
11563 (save_original_signals_state): New parameter 'quiet'. Warn if we
11564 find a custom handler preinstalled, instead of internal erroring.
11565 But only warn if !quiet.
11566 * common/signals-state-save-restore.h
11567 (save_original_signals_state): New parameter 'quiet'.
11568 * main.c (captured_main_1): Move save_original_signals_state call
11569 after option handling, and pass QUIET.
11571 2018-01-05 Pedro Alves <palves@redhat.com>
11573 * spu-tdep.c (spu_catch_start): Pass
11574 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11576 2018-01-05 Pedro Alves <palves@redhat.com>
11579 * ada-lang.c (literal_symbol_name_matcher): New function.
11580 (ada_get_symbol_name_matcher): Use it for
11581 symbol_name_match_type::SEARCH_NAME.
11582 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11583 it down instead of assuming symbol_name_match_type::FULL.
11584 * block.h (block_lookup_symbol): New parameter 'match_type'.
11585 * c-valprint.c (print_unpacked_pointer): Use
11586 lookup_symbol_search_name instead of lookup_symbol.
11587 * compile/compile-object-load.c (get_out_value_type): Pass down
11588 symbol_name_match_type::SEARCH_NAME.
11589 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11590 symbol_name_match_type::FULL.
11591 * cp-support.c (cp_get_symbol_name_matcher): Handle
11592 symbol_name_match_type::SEARCH_NAME.
11593 * infrun.c (insert_exception_resume_breakpoint): Use
11594 lookup_symbol_search_name.
11595 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11596 * psymtab.c (maintenance_check_psymtabs): Use
11597 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11598 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11599 SYMBOL_SEARCH_NAME.
11600 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11601 if symbol_name_match_type::SEARCH_NAME.
11602 (lookup_symbol_in_language): Pass down
11603 symbol_name_match_type::FULL.
11604 (lookup_symbol_search_name): New.
11605 (lookup_language_this): Pass down
11606 symbol_name_match_type::SEARCH_NAME.
11607 (lookup_symbol_aux, lookup_local_symbol): New parameter
11608 'match_type'. Pass it down.
11609 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11610 (lookup_symbol_search_name): New declaration.
11611 (lookup_symbol_in_block): New 'match_type' parameter.
11613 2018-01-05 Pedro Alves <palves@redhat.com>
11616 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11618 (ada_lookup_symbol): Reimplement in terms of
11619 ada_lookup_symbol_list, bits factored out from
11620 ada_lookup_encoded_symbol.
11622 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11624 * ada-exp.y (write_object_renaming): When subscripting an array
11625 using a symbol as the index, pass the block in call to
11626 ada_lookup_encoded_symbol when looking that symbol up.
11628 2018-01-05 Jerome Guitton <guitton@adacore.com>
11630 * ada-lang.c (ada_array_length): Use ada_index_type instead of
11633 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11635 * ada-lang.c (ada_to_fixed_value_create): Add handling of
11636 the case where VALUE_LVAL (val0) is not lval_memory.
11638 2018-01-05 Xavier Roirand <roirand@adacore.com>
11640 * ada-valprint.c (print_optional_low_bound): Handle
11641 character-indexed array printing like boolean-indexed array
11644 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11646 * NEWS: Create a new section for the next release branch.
11647 Rename the section of the current branch, now that it has
11650 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11652 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
11653 * version.in: Bump version to 8.1.50.DATE-git.
11655 2018-01-03 Xavier Roirand <roirand@adacore.com>
11657 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
11659 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
11661 (default_exception_support_info) <catch_handlers_sym>: Add field.
11662 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
11663 (ada_exception_name_addr_1): Add "catch handlers" handling.
11664 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
11665 Update all callers.
11666 (create_excep_cond_exprs) <ex>: Add parameter.
11667 (re_set_exception): Update create_excep_cond_exprs call.
11668 (print_it_exception, print_one_exception, print_mention_exception)
11669 (print_recreate_exception): Add "catch handler" handling.
11670 (allocate_location_catch_handlers, re_set_catch_handlers)
11671 (check_status_catch_handlers, print_it_catch_handlers)
11672 (print_one_catch_handlers, print_mention_catch_handlers)
11673 (print_recreate_catch_handlers): New function.
11674 (catch_handlers_breakpoint_ops): New variable.
11675 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
11676 Add parameter. Add "catch handler" handling.
11677 (ada_exception_sym_name, ada_exception_breakpoint_ops):
11678 Add "catch handler" handling.
11679 (ada_exception_catchpoint_cond_string): Add "catch handler"
11681 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
11683 (catch_ada_handlers_command): New function.
11684 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
11685 operations structure.
11686 (_initialize_ada_language): Add "catch handlers" command entry.
11687 * NEWS: Document "catch handlers" feature.
11689 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11691 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
11692 account when creating the array type of the slice.
11693 (ada_value_slice): Likewise.
11695 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11697 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
11699 (create_array_type_with_stride): Add byte_stride_prop parameter.
11700 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
11701 New parameter. Update all callers in this file.
11702 (array_type_has_dynamic_stride): New function.
11703 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
11704 of arrays with dynamic byte strides.
11705 * dwarf2read.c (read_array_type): Add support for dynamic
11706 DW_AT_byte_stride attributes.
11708 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11710 * dwarf2read.c (read_unspecified_type): Treat
11711 DW_TAG_enumeration_type DIEs from Ada units as stubs.
11713 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11715 Update copyright year range in all GDB files.
11717 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11719 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
11720 and gdb/testsuite/gdb.base/step-line.c.
11722 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11724 * copyright.py (main): Dump the contents of
11725 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
11726 even if BY_HAND is empty.
11728 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11730 * top.c (print_gdb_version): Update Copyright year in version
11733 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11735 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
11737 For older changes see ChangeLog-2017.
11743 version-control: never