1 2018-12-28 Tom Tromey <tom@tromey.com>
3 * utils.h (reset_terminal_style): Declare.
4 * utils.c (can_emit_style_escape): New function.
5 (set_output_style): Use it.
6 (reset_terminal_style): New function.
7 * printcmd.c (printf_command): Call reset_terminal_style.
8 * cli/cli-cmds.c (echo_command): Call reset_terminal_style.
10 2018-12-28 Tom Tromey <tom@tromey.com>
12 * utils.h (set_output_style, fprintf_styled)
13 (fputs_styled): Declare.
14 * utils.c (applied_style, desired_style): New globals.
15 (emit_style_escape, set_output_style): New function.
16 (prompt_for_continue): Emit style escapes.
17 (fputs_maybe_filtered): Likewise.
18 (fputs_styled, fprintf_styled): New functions.
19 * ui-out.h (enum class ui_out_style_kind): New.
20 (class ui_out) <field_string, field_stream, do_field_string>: Add
22 * ui-out.c (ui_out::field_stream, ui_out::field_string): Add style
24 * tui/tui-out.h (class tui_ui_out) <do_field_string>: Add style
26 * tui/tui-out.c (tui_ui_out::do_field_string): Add style
28 (tui_ui_out::do_field_string): Update.
29 * tracepoint.c (print_one_static_tracepoint_marker): Style
31 * stack.c (print_frame_info, print_frame): Style output.
32 * source.c (print_source_lines_base): Style output.
33 * skip.c (info_skip_command): Style output.
34 * record-btrace.c (btrace_call_history_src_line): Style output.
35 (btrace_call_history): Likewise.
36 * python/py-framefilter.c (py_print_frame): Style output.
37 * mi/mi-out.h (class mi_ui_out) <do_field_string>: Add style
39 * mi/mi-out.c (mi_ui_out::do_table_header)
40 (mi_ui_out::do_field_int): Update.
41 (mi_ui_out::do_field_string): Update.
42 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
44 * cli/cli-style.h: New file.
45 * cli/cli-style.c: New file.
46 * cli-out.h (class cli_ui_out) <do_field_string>: Add style
48 * cli-out.c (cli_ui_out::do_table_header)
49 (cli_ui_out::do_field_int, cli_ui_out::do_field_skip): Update.
50 (cli_ui_out::do_field_string): Add style parameter. Style the
52 * breakpoint.c (print_breakpoint_location): Style output.
53 (update_static_tracepoint): Likewise.
54 * Makefile.in (SUBDIR_CLI_SRCS): Add cli-style.c.
55 (HFILES_NO_SRCDIR): Add cli-style.h.
57 2018-12-28 Tom Tromey <tom@tromey.com>
59 * unittests/style-selftests.c: New file.
60 * ui-style.c: New file.
61 * ui-style.h: New file.
62 * ui-file.h: Include ui-style.h.
63 * Makefile.in (COMMON_SFILES): Add ui-style.c.
64 (HFILES_NO_SRCDIR): Add ui-style.h.
65 (SUBDIR_UNITTESTS_SRCS): Add style-selftests.c.
67 2018-12-28 Tom Tromey <tom@tromey.com>
69 * command.h (add_setshow_enum_cmd): Add "context" argument.
70 * cli/cli-decode.c (add_setshow_enum_cmd): Add "context"
71 argument. Call set_cmd_context.
73 2018-12-28 Tom Tromey <tom@tromey.com>
75 * utils.c (filter_initialized): New global.
76 (wrap_buffer): Now a std::string.
77 (wrap_pointer): Remove.
78 (flush_wrap_buffer): New function.
79 (filtered_printing_initialized, set_width, wrap_here)
80 (fputs_maybe_filtered): Update.
82 2018-12-28 Eli Zaretskii <eliz@gnu.org>
84 * coffread.c (coff_symtab_read): Don't record in minsyms symbols
85 that are unresolved. This avoids triggering an internal error
86 when stepping outside of 'main' in MinGW programs.
88 2018-12-27 Tom Tromey <tom@tromey.com>
90 * python/py-utils.c (gdbpy_handle_exception): Translate
91 PyExc_KeyboardInterrupt to quit.
93 2018-12-27 Tom Tromey <tom@tromey.com>
95 * python/python-internal.h (gdbpy_print_stack_or_quit): Declare.
96 * python/py-unwind.c (pyuw_sniffer): Use
97 gdbpy_print_stack_or_quit.
98 * python/py-framefilter.c (throw_quit_or_print_exception):
100 (gdbpy_apply_frame_filter): Use gdbpy_print_stack_or_quit.
101 * python/python.c (gdbpy_print_stack_or_quit): New function.
103 2018-12-27 Tom Tromey <tom@tromey.com>
105 * python/py-value.c (convert_value_from_python): Use
106 gdbpy_convert_exception.
107 * python/py-param.c (parmpy_init): Use gdbpy_convert_exception.
108 * python/py-cmd.c (cmdpy_init): Use gdbpy_convert_exception.
109 * python/py-breakpoint.c (bppy_init): Use
110 gdbpy_convert_exception.
112 2018-12-27 Tom Tromey <tom@tromey.com>
114 * configure.nat (NATDEPFILES): Use nat/ prefix.
115 * Makefile.in (CONFIG_SRC_SUBDIR): Add nat.
116 (%.o: ${srcdir}/nat/%.c): Remove rule.
117 (INIT_FILES): Do not filter out NATDEPFILES.
119 2018-12-27 Tom Tromey <tom@tromey.com>
121 * Makefile.in (INIT_FILES): Redefine.
122 (stamp-init): Remove sed, tr invocations. Use for loop. Don't
125 2018-12-27 Tom Tromey <tom@tromey.com>
127 * Makefile.in (stamp-init): Remove gdbtypes special case.
129 2018-12-27 John Baldwin <jhb@FreeBSD.org>
131 * config/i386/nm-fbsd.h: Remove file.
132 * Makefile.in (HFILES_NO_SRCDIR): Remove config/i386/nm-fbsd.h.
133 * configure.nat: Remove NAT_FILE for FreeBSD/i386.
135 2018-12-27 Tom Tromey <tom@tromey.com>
137 * minsyms.h (class minimal_symbol_reader): Use
138 DISABLE_COPY_AND_ASSIGN.
140 2018-12-27 Tom Tromey <tom@tromey.com>
142 * python/python.c (python_interactive_command): Use std::string.
143 (gdbpy_parameter): Likewise.
144 * python/py-utils.c (unicode_to_encoded_string): Update comment.
145 * python/py-symtab.c (salpy_str): Use PyString_FromFormat.
146 * python/py-record-btrace.c (recpy_bt_insn_data): Use
148 * python/py-objfile.c (objfpy_get_build_id): Use
150 * python/py-inferior.c (infpy_read_memory): Use
152 * python/py-cmd.c (gdbpy_parse_command_name): Use std::string.
154 2018-12-26 Simon Marchi <simon.marchi@polymtl.ca>
156 * target.c (target_terminal::restore_inferior): Remove struct keyword.
158 2018-12-26 Simon Marchi <simon.marchi@ericsson.com>
160 * build-id.c (build_id_to_debug_bfd): Enhance debug output.
161 * symfile.c (separate_debug_file_exists): Likewise.
163 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
165 * c-exp.y (field_name): Allow DOUBLE_KEYWORD, INT_KEYWORD, LONG,
166 SHORT, SIGNED_KEYWORD, and UNSIGNED tokens to act as a field
168 (typename_stoken): New function.
170 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
172 * c-exp.y (field_name): New %token, and new rule.
173 (exp): Replace uses of 'name' with 'field_name' where appropriate.
175 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
178 * c-exp.y (typebase): Extend the comment.
179 (ident_tokens): Likewise.
181 2018-12-18 Tom Tromey <tom@tromey.com>
183 * dwarf2read.c (dwarf2_find_containing_comp_unit): Don't take
186 2018-12-23 Joel Brobecker <brobecker@adacore.com>
190 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
192 * riscv-tdep.c (riscv_call_arg_struct): Don't adjust size before
194 (riscv_return_value): Take more care not to read/write outside of
195 argument buffer. Cast return value between the declared type and
198 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
200 * riscv-tdep.c (riscv_register_reggroup_p): Save and restore fcsr,
201 fflags, and frm registers.
203 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
205 * riscv-tdep.c (riscv_dwarf_reg_to_regnum): New function.
206 (riscv_gdbarch_init): Register new function with gdbarch.
207 * riscv-tdep.h: New enum to define RISC-V DWARF register numbers.
209 2018-12-21 Simon Marchi <simon.marchi@ericsson.com>
211 * minsyms.c (mst_str): New.
212 (minimal_symbol_reader::record_full): Add debug output.
214 2018-12-21 John Baldwin <jhb@FreeBSD.org>
216 * fbsd-nat.c (fbsd_handle_debug_trap): Require pl.pl_flags to
218 (fbsd_nat_target::stopped_by_sw_breakpoint): Likewise.
220 2018-12-21 Paul Marechal <paul.marechal@ericsson.com>
223 * target.c (target_read_stralloc): Check for empty vector.
225 2018-12-21 Дилян Палаузов <dilyan.palauzov@aegee.org>
227 * top.c (print_gdb_configuration): Print "--without-python"
228 if GDB was configured without Python.
230 2018-12-21 Andrew Burgess <andrew.burgess@embecosm.com>
232 * riscv-tdep.c (riscv_scan_prologue): Use plongest to format
233 a signed offset as a string.
235 2018-12-21 Dave Murphy <davem@devkitpro.org>
237 * dtrace-probe.c (dtrace_static_probe_ops): Explicit zero
239 * probe.c (any_static_probe_ops): Ditto.
240 * record-btrace.c (record_btrace_thread_observer_token): Ditto.
241 * stap-probe.c (stap_static_probe_ops): Ditto.
242 * tui/tui-hooks.c (tui_observers_token): Ditto.
243 * unittests/observable-selftests.c (token1, token2, token3): Ditto.
245 2018-12-19 Andrew Burgess <andrew.burgess@embecosm.com>
247 * gdb/dummy-frame.c (default_dummy_id): Defined new function.
248 * gdb/dummy-frame.h (default_dummy_id): Declare new function.
249 * gdb/frame-unwind.c (default_unwind_pc): Define new function.
250 (default_unwind_sp): Define new function.
251 * gdb/frame-unwind.h (default_unwind_pc): Declare new function.
252 (default_unwind_sp): Declare new function.
253 * gdb/frame.c (frame_unwind_pc): Assume gdbarch_unwind_pc is
255 (get_frame_sp): Assume that gdbarch_unwind_sp is available.
256 * gdb/gdbarch.c: Regenerate.
257 * gdb/gdbarch.h: Regenerate.
258 * gdb/gdbarch.sh: Update definition of dummy_id, unwind_pc, and
259 unwind_sp. Add additional header files to be included in
262 2018-12-19 Dimitar Dimitrov <dimitar@dinux.eu>
264 * nat/linux-ptrace.c (linux_ptrace_test_ret_to_nx): Remove
267 2018-12-17 Andrew Burgess <andrew.burgess@embecosm.com>
269 * dwarf2read.c (struct dwarf2_cu): Convert the fields 'mark',
270 'has_loclist', 'checked_producer', 'producer_is_gxx_lt_4_6',
271 'producer_is_gcc_lt_4_3', 'producer_is_icc_lt_14',
272 'processing_has_namespace_info' from unsigned int to bool. Update
274 (producer_is_icc_lt_14): Update return type.
275 (producer_is_gcc_lt_4_3): Likewise.
276 (producer_is_gxx_lt_4_6): Likewise.
277 (process_die): Write true instead of 1 into predicate fields.
278 (dwarf2_start_symtab): Likewise.
279 (var_decode_location): Likewise.
280 (dwarf2_mark_helper): Likewise.
281 (dwarf2_mark): Likewise.
282 (dwarf2_clear_marks): Write false instead of 0 into predicate
284 (dwarf2_cu::dwarf2_cu): Initialise predicate fields to false, not
287 2018-12-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
289 * nat/aarch64-sve-linux-ptrace.h: Include signal.h instead of
292 2018-12-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
294 * nat/linux-ptrace.c (kill_child): Fix ARI warning by removing
295 warning trailing new line.
297 2018-12-16 Philippe Waroquiers <philippe.waroquiers@skynet.be>
299 * nat/linux-ptrace.c (kill_child): New function.
300 (linux_ptrace_test_ret_to_nx): Use kill_child instead of local code.
301 Add a call to kill_child in case of early return after fork.
302 (linux_check_ptrace_features): Use kill_child instead of local code.
303 (linux_test_for_tracefork): Likewise.
305 2018-12-14 Tom Tromey <tom@tromey.com>
307 * Makefile.in: Remove "alloca" comment.
309 (local-maintainer-clean): Don't use INFOFILES.
311 2018-12-13 John Baldwin <jhb@FreeBSD.org>
313 * syscalls/update-freebsd.sh: New file.
314 * syscalls/freebsd.xml: Regenerate.
316 2018-12-13 John Baldwin <jhb@FreeBSD.org>
318 * NEWS: Add entry documenting system call aliases.
319 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
320 to get_syscalls_by_name.
321 * gdbarch.sh (UNKNOWN_SYSCALL): Remove.
322 * gdbarch.h: Regenerate.
323 * syscalls/gdb-syscalls.dtd (syscall): Add alias attribute.
324 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_name): Rename
325 from get_syscall_by_name. Now accepts a pointer to a vector of
326 integers and returns a bool.
327 [HAVE_LIBEXPAT] (struct syscall_desc): Add alias member.
328 (syscall_create_syscall_desc): Add alias parameter and pass it to
329 syscall_desc constructor.
330 (syscall_start_syscall): Handle alias attribute.
331 (syscall_attr): Add alias attribute.
332 (xml_get_syscalls_by_name): Rename from xml_get_syscall_number.
333 Now accepts a pointer to a vector of integers and returns a
334 bool. Add syscalls whose alias or name matches the requested
336 (get_syscalls_by_name): Rename from get_syscall_by_name. Now
337 accepts a pointer to a vector of integers and returns a bool.
338 * xml-syscall.h (get_syscalls_by_name): Likewise.
340 2018-12-13 John Baldwin <jhb@FreeBSD.org>
342 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
343 to get_syscalls_by_group.
344 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_group): Return
346 [HAVE_LIBEXPAT] (xml_list_syscalls_by_group): Append syscall
347 numbers to an existing vector of integers and return a bool.
348 (get_syscalls_by_group): Accept pointer to vector of integers
349 and change return type to bool.
350 * xml-syscall.h (get_syscalls_by_group): Likewise.
352 2018-12-13 Jim Wilson <jimw@sifive.com>
354 * riscv-tdep.c (riscv_print_one_register_info): For MSTATUS, add
355 comment for SD field, and correct xlen calculation. For MISA, add
356 comment for MXL field, add call to register_size, and correct base
359 2018-12-13 Stafford Horne <shorne@gmail.com>
361 * NEWS(New targets): Add or1k*-*-linux*.
363 2018-12-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
365 * nat/linux-osdata.c (linux_xfer_osdata_info_os_types): Forward
366 declare on one line to fix ARI warning.
368 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
370 * infrun.c (infcall_suspend_state::infcall_suspend_state): New.
371 (infcall_suspend_state::registers): New.
372 (infcall_suspend_state::restore): New.
373 (infcall_suspend_state::thread_suspend): Rename to...
374 (infcall_suspend_state::m_thread_suspend): ...this.
375 (infcall_suspend_state::registers): Rename to...
376 (infcall_suspend_state::m_registers): ...this.
377 (infcall_suspend_state::siginfo_gdbarch): Rename to...
378 (infcall_suspend_state::m_siginfo_gdbarch): ...this.
379 (infcall_suspend_state::siginfo_data): Rename to...
380 (infcall_suspend_state::m_siginfo_data): ...this.
381 (save_infcall_suspend_state): Rewrite to use infcall_suspend_state
383 (restore_infcall_suspend_state): Rewrite to use
384 infcall_suspend_state::restore method.
385 (get_infcall_suspend_state_regcache): Use
386 infcall_suspend_state::registers method.
388 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
390 * riscv-tdep.c (riscv_call_arg_scalar_float): Unnamed (variadic)
391 arguments are passed in integer registers.
392 (riscv_call_arg_complex_float): Likewise.
394 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
396 * nat/linux-osdata.c (common_getter): New function.
397 (struct osdata_type): Change getter to take_snapshot.
398 Add LONGEST len_avail and struct buffer buffer.
399 Change all elements in the initializer.
400 Add an element for the list of types.
401 (linux_xfer_osdata_info_os_types): New function.
402 (linux_common_xfer_osdata): Use common_getter for the list of types.
403 Replace getter call by common_getter.
404 (linux_xfer_osdata_cpus): Remove args READBUF, OFFSET, LEN.
405 Add arg BUFFER. Only keep the code that adds data in BUFFER.
406 (linux_xfer_osdata_fds): Likewise.
407 (linux_xfer_osdata_modules): Likewise.
408 (linux_xfer_osdata_msg): Likewise.
409 (linux_xfer_osdata_processes): Likewise.
410 (linux_xfer_osdata_processgroups): Likewise.
411 (linux_xfer_osdata_sem): Likewise.
412 (linux_xfer_osdata_shm): Likewise.
413 (linux_xfer_osdata_isockets): Likewise.
414 (linux_xfer_osdata_threads): Likewise.
416 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
418 * nat/linux-osdata.c: Removed various trailing spaces.
420 2018-12-10 Andrew Burgess <andrew.burgess@embecosm.com>
422 * riscv-tdep.c (riscv_register_name): Fix ARI warning by removing
423 leading whitespace before #include line.
425 2018-12-08 Simon Marchi <simon.marchi@ericsson.com>
426 Дилян Палаузов <dilyan.palauzov@aegee.org>
429 * configure.ac: Search for tgetent in libtinfow.
430 * configure: Re-generate.
432 2018-12-08 Philippe Waroquiers <philippe.waroquiers@skynet.be>
434 * linux-thread-db.c (struct thread_db_info): Add td_ta_delete_p.
435 (thread_db_err_str): Forward declare.
436 (delete_thread_db_info): Call td_ta_delete_p if available.
437 (try_thread_db_load_1): Acquire td_ta_delete address.
438 * nat/gdb_thread_db.h (td_ta_delete_ftype): Declare.
440 2018-12-08 Pedro Alves <palves@redhat.com>
442 * source.c (forward_search_command): Rename to ...
443 (search_command_helper): ... this. Add 'forward' parameter.
444 Tweak to use a gdb::def_vector<char> instead of a xrealloc'ed
445 buffer. Handle backward searches too.
446 (forward_search_command, reverse_search_command): Reimplement by
447 calling search_command_helper.
449 2018-12-07 Andrew Burgess <andrew.burgess@embecosm.com>
451 * .dir-locals.el: Copy most of the settings from c-mode over to
454 2018-12-08 Stafford Horne <shorne@gmail.com>
456 * Makefile.in (ALL_TARGET_OBS): Add or1k-linux-tdep.o.
457 * configure.tgt: Add or1k*-*-linux*.
458 * or1k-linux-tdep.c: New file.
459 * or1k-tdep.c (or1k_gdbarch_init): Call gdbarch_init_osabi.
461 2018-12-07 Pedro Alves <palves@redhat.com>
463 * dwarf2read.c (get_gdb_index_contents_from_section): Use
464 gdb::make_array_view.
466 2018-12-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
468 * language.c (_initialize_language): Fix leak by assigning
469 a static string to language. Same for range and case_sensitive,
470 even if no leak is detected for these variables.
472 2018-12-05 John Baldwin <jhb@FreeBSD.org>
474 * configure: Re-generate.
475 * configure.ac: Use separate sed expressions to escape variables
476 in auto-load directories.
478 2018-12-05 Andrew Burgess <andrew.burgess@embecosm.com>
480 * riscv-tdep.c (riscv_features_from_gdbarch_info): New function.
481 (riscv_find_default_target_description): Use new function to
482 extract feature from gdbarch_info.
483 (riscv_gdbarch_init): Add error checks for xlen and flen between
484 target description and bfd headers. Be smarter about when we
485 think the hardware floating point abi should be used.
487 2018-12-05 Alan Hayward <alan.hayward@arm.com>
489 * nat/aarch64-linux-hw-point.c
490 (aarch64_linux_any_set_debug_regs_state): New function.
491 * nat/aarch64-linux-hw-point.h
492 (aarch64_linux_any_set_debug_regs_state): New declaration.
493 * nat/aarch64-linux.c (aarch64_linux_new_thread): Check if any
496 2018-11-30 John Baldwin <jhb@FreeBSD.org>
498 * common/filestuff.c [HAVE_KINFO_GETFILE]: Include headers.
499 (fdwalk) [HAVE_KINFO_GETFILE]: Use kinfo_getfile.
501 2018-11-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
502 Simon Marchi <simon.marchi@ericsson.com>
504 * linespec.c (symtab_vector_up): Remove.
505 (symtabs_from_filename): Change return type to std::vector.
506 (collect_symtabs_from_filename): Likewise.
507 (create_sals_line_offset): Assign return value of
508 collect_symtabs_from_filename to *ls->file_symtabs.
509 (convert_explicit_location_to_linespec): Remove call to release.
510 (parse_linespec): Likewise.
511 (symtab_collector) <symtab_collector>: Remove initialization of
513 <release_symtabs>: Change return type to std::vector<symtab *>.
514 <operator ()>: Adjust.
516 2018-11-30 John Baldwin <jhb@FreeBSD.org>
518 * fbsd-nat.c [__FreeBSD_version >= 700009] (USE_SIGINFO): Macro
520 (union sigval32, struct siginfo32, fbsd_siginfo_size)
521 (fbsd_convert_siginfo): Make conditional on USE_SIGINFO instead
522 of KERN_PROC_AUXV and PT_LWPINFO.
523 (fbsd_nat_target::xfer_partial): Define method unconditionally.
524 Make TARGET_OBJECT_SIGNAL_INFO conditional on USE_SIGINFO.
525 Make TARGET_OBJECT_AUXV conditional on KERN_PROC_AUXV.
526 Make TARGET_OBJECT_FREEBSD_VMMAP and
527 TARGET_OBJECT_FREEBSD_PS_STRINGS conditional on KERN_PROC_VMMAP
528 and KERN_PROC_PS_STRINGS.
529 * fbsd-nat.h: Include <sys/proc.h>.
530 (fbsd_nat_target::xfer_partial): Declare method unconditionally.
532 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
534 * riscv-linux-nat.c: Add 'inferior.h' and 'target-descriptions.h'
536 (riscv_linux_nat_target::read_description): New method.
538 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
540 * arch/riscv.h (riscv_gdbarch_features::hash): New method.
541 * arch/riscv.c (struct riscv_gdbarch_features_hasher): New.
542 (riscv_tdesc_cache): New global.
543 (riscv_create_target_description): Look in the cache before
544 creating a new target description.
546 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
548 * arch/riscv.h (riscv_gdb_features::operator==): New.
549 (riscv_gdb_features::operator!=): New.
550 * riscv-tdep.c (riscv_gdbarch_init): Make use of the inequality
553 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
555 * arch/riscv.h (riscv_create_target_description): Make return type
557 * arch/riscv.c (riscv_create_target_description): Likewise.
558 * riscv-tdep.c (riscv_find_default_target_description): Likewise.
560 2018-11-30 Jan Kratochvil <jan.kratochvil@redhat.com>
561 Keith Seitz <keiths@redhat.com>
562 Tom Tromey <tom@tromey.com>
563 Sergio Durigan Junior <sergiodj@redhat.com>
565 https://bugzilla.redhat.com/show_bug.cgi?id=1613614
566 * dwarf2read.c (dwarf2_find_containing_comp_unit): Add
567 'mid_cu->length' to '*cu_off' when checking if 'sect_off' is
570 2018-11-30 Pedro Alves <palves@redhat.com>
572 * aix-thread.c (aix_thread_target) <aix_thread_target>: Delete.
573 <stratum>: New override.
574 * bfd-target.c (aix_thread_target) <aix_thread_target>: Delete.
575 <stratum>: New override.
576 * bsd-uthread.c (bsd_uthread_target) <bsd_uthread_target>: Delete.
577 <stratum>: New override.
578 * exec.c (exec_target) <exec_target>: Delete.
579 <stratum>: New override.
580 * gdbarch-selftests.c (register_to_value_test): Adjust to use the
581 stratum method instead of the to_stratum field.
582 * linux-thread-db.c (thread_db_target) <thread_db_target>: Delete.
583 <stratum>: New override.
584 (thread_db_target::thread_db_target): Delete.
585 * make-target-delegates (print_class): Don't print a ctor
586 declaration. Print a stratum method override declaration.
587 * process-stratum-target.h (process_stratum_target)
588 <process_stratum_target>: Delete.
589 <stratum>: New override.
590 * ravenscar-thread.c (ravenscar_thread_target)
591 <ravenscar_thread_target>: Delete.
592 <stratum>: New override.
593 * record-btrace.c (record_btrace_target)
594 <record_btrace_target>: Delete.
595 <stratum>: New override.
596 * record-full.c (record_full_base_target)
597 <record_full_base_target>: Delete.
598 <stratum>: New override.
599 * record.c (record_disconnect, record_detach)
600 (record_mourn_inferior, record_kill): Adjust to use the stratum
601 method instead of the to_stratum field.
602 * regcache.c (cooked_read_test, cooked_write_test): Likewise.
603 * sol-thread.c (sol_thread_target)
604 <sol_thread_target>: Delete.
605 <stratum>: New override.
606 * spu-multiarch.c (spu_multiarch_target)
607 <spu_multiarch_target>: Delete.
608 <stratum>: New override.
609 * target-delegates.c: Regenerate.
610 * target.c (target_stack::push, target_stack::unpush)
611 (pop_all_targets_above, pop_all_targets_at_and_above)
612 (info_target_command, target_require_runnable)
613 (target_stack::find_beneath): Adjust to use the stratum method
614 instead of the to_stratum field.
615 (dummy_target::dummy_target): Delete.
616 (dummy_target::stratum): New.
617 (debug_target::debug_target): Delete.
618 (debug_target::stratum): New.
619 (maintenance_print_target_stack): Adjust to use the stratum method
620 instead of the to_stratum field.
621 * target.h (struct target_ops) <stratum>: New method.
622 <to_stratum>: Delete.
623 <is_pushed>: Adjust to use the stratum method
624 instead of the to_stratum field.
626 2018-11-30 Pedro Alves <palves@redhat.com>
628 * corelow.c (core_target) <has_all_memory, has_execution>: New
630 * inf-child.c (inf_child_target::has_all_memory)
631 (inf_child_target::has_memory, inf_child_target::has_stack)
632 (inf_child_target::has_registers)
633 (inf_child_target::has_execution): Delete.
634 * inf-child.h (inf_child_target) <has_all_memory, has_memory,
635 has_stack, has_registers, has_execution>: Delete.
636 * process-stratum-target.c
637 (process_stratum_target::has_all_memory)
638 (process_stratum_target::has_memory)
639 (process_stratum_target::has_stack)
640 (process_stratum_target::has_registers)
641 (process_stratum_target::has_execution): New.
642 * process-stratum-target.h (process_stratum_target)
643 <has_all_memory, has_memory, has_stack, has_registers,
644 has_execution>: New method overrides.
645 * ravenscar-thread.c (ravenscar_thread_target) <has_all_memory,
646 has_memory, has_stack, has_registers, has_execution>: Delete.
647 * remote-sim.c (gdbsim_target) <has_stack, has_registers,
648 has_execution>: Delete.
649 * remote.c (remote_target) <has_all_memory, has_memory, has_stack,
650 has_registers, has_execution>: Delete.
651 * target.c (default_child_has_all_memory)
652 (default_child_has_memory, default_child_has_stack)
653 (default_child_has_registers, default_child_has_execution):
655 * target.h (default_child_has_all_memory)
656 (default_child_has_memory, default_child_has_stack)
657 (default_child_has_registers, default_child_has_execution):
659 * tracefile.h (tracefile_target) <has_execution>: New override.
661 2018-11-30 Pedro Alves <palves@redhat.com>
663 * Makefile.in (COMMON_SFILES): Add process-stratum-target.c.
664 * bsd-kvm.c: Include "process-stratum-target.h".
665 (bsd_kvm_target): Now inherits from process_stratum_target.
666 (bsd_kvm_target::bsd_kvm_target): Default it.
667 * corelow.c: Include "process-stratum-target.h".
668 (core_target): Now inherits from process_stratum_target.
669 (core_target::core_target): Don't set to_stratum here.
670 * inf-child.c (inf_child_target::inf_child_target): Delete.
671 * inf-child.h: Include "process-stratum-target.h".
672 (inf_child_target): Inherit from process_stratum_target.
673 (inf_child_target) <inf_child_target>: Default it.
674 <can_async_p, supports_non_stop, supports_disable_randomization>:
676 * process-stratum-target.c: New file.
677 * process-stratum-target.h: New file.
678 * remote-sim.c: Include "process-stratum-target.h".
679 (gdbsim_target): Inherit from process_stratum_target.
680 <gdbsim_target>: Default it.
681 * remote.c: Include "process-stratum-target.h".
682 (remote_target): Inherit from process_stratum_target.
683 <remote_target>: Default it.
684 * target.c (default_thread_address_space)
685 (default_thread_architecture): Delete.
686 * target.h (target_ops) <thread_architecture>: Now returns NULL by
688 <thread_address_space>: Ditto.
689 * test-target.h: Include "process-stratum-target.h" instead of
691 (test_target_ops): Inherit from process_stratum_target.
692 <test_target_ops>: Default it.
693 * tracefile.c (tracefile_target::tracefile_target): Delete.
694 * tracefile.h: Include "process-stratum-target.h".
695 (tracefile_target): Inherit from process_stratum_target.
696 <tracefile_target>: Default it.
697 * target-delegates.c: Regenerate.
699 2018-11-30 Pedro Alves <palves@redhat.com>
701 * Makefile.in (COMMON_SFILES): Add test-target.c.
702 * gdbarch-selftests.c: Include "test-target.h".
703 * regcache.c: Include "test-target.h".
704 * target.c (test_target_info, test_target_ops::info): Move to ...
705 * test-target.c: ... this new file.
706 * target.h (test_target_ops): Move to ...
707 * test-target.h: ... this new file.
709 2018-11-29 Philippe Waroquiers <philippe.waroquiers@skynet.be>
711 * source.c (forward_search_command): Fix leak by using
712 xrealloc even for the first allocation in the loop, as buf
715 2018-11-29 Rajendra SY <rajendra.sy@gmail.com>
718 * gdb/fbsd-tdep.c (fbsd_gdb_signal_from_target)
719 (fbsd_gdb_signal_to_target): New.
720 (fbsd_init_abi): Install gdbarch "signal_from_target" and
721 "signal_to_target" methods.
723 2018-11-29 Tom Tromey <tom@tromey.com>
725 * valarith.c (value_x_unop): Don't set argvec[3].
727 2018-11-26 Simon Marchi <simon.marchi@ericsson.com>
730 * sparc-linux-nat.c (sparc_linux_nat_target): Remove extraneous
733 2018-11-26 Pedro Alves <palves@redhat.com>
735 * procfs.c (procfs_notice_thread): Replace uses of
736 in_thread_list/is_exited with find_thread_ptid/THREAD_EXITED.
737 * sol-thread.c (sol_thread_target::wait)
738 (sol_update_thread_list_callback): Likewise.
740 2018-11-25 Tom Tromey <tom@tromey.com>
742 * ui-out.c (ui_out::field_fmt): Remove comment.
743 * tui/tui-out.c (tui_ui_out::do_field_fmt): Remove comment.
744 * mi/mi-out.c (mi_ui_out::do_field_fmt): Remove comment.
746 2018-11-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
748 * source.c (open_source_file): Leak fixed in '8e6a5953e1d Fix 4K
749 leak in open_source_file' has been partially undone by '2179fbc36d23
750 Return scoped_fd from open_source_file'. Re-add the transfer of
751 current s->fullname to the unique_xmalloc_ptr fullname given
752 to find_and_open_source.
754 2018-11-23 Pedro Alves <palves@redhat.com>
756 * gdbthread.h (enum thread_state): Move comments here.
757 (is_running, is_stopped, is_exited): Remove declarations.
759 2018-11-22 Pedro Alves <palves@redhat.com>
761 * Makefile.in (COMMON_SFILES): Add thread-iter.c.
762 * breakpoint.c (breakpoints_should_be_inserted_now): Replace
763 ALL_NON_EXITED_THREADS with all_non_exited_threads.
764 (print_one_breakpoint_location): Replace ALL_INFERIORS with
766 * bsd-kvm.c: Include inferior.h.
767 * btrace.c (btrace_free_objfile): Replace ALL_NON_EXITED_THREADS
768 with all_non_exited_threads.
769 * common/filtered-iterator.h: New.
770 * common/safe-iterator.h: New.
771 * corelow.c (core_target_open): Don't call init_thread_list here.
772 * darwin-nat.c (thread_info_from_private_thread_info): Replace
773 ALL_THREADS with all_threads.
774 * fbsd-nat.c (fbsd_nat_target::resume): Replace
775 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
776 * fbsd-tdep.c (fbsd_make_corefile_notes): Replace
777 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
778 * fork-child.c (postfork_hook): Don't call init_thread_list here.
779 * gdbarch-selftests.c (register_to_value_test): Adjust.
780 * gdbthread.h: Don't include "inferior.h" here.
781 (struct inferior): Forward declare.
782 (enum step_over_calls_kind): Moved here from inferior.h.
783 (thread_info::deletable): Definition moved to thread.c.
784 (find_thread_ptid (inferior *, ptid_t)): Declare.
785 (ALL_THREADS, ALL_THREADS_BY_INFERIOR, ALL_THREADS_SAFE): Delete.
786 Include "thread-iter.h".
787 (all_threads, all_non_exited_threads, all_threads_safe): New.
788 (any_thread_p): Declare.
789 (thread_list): Delete.
790 * infcmd.c (signal_command): Replace ALL_NON_EXITED_THREADS with
791 all_non_exited_threads.
792 (proceed_after_attach_callback): Delete.
793 (proceed_after_attach): Take an inferior pointer instead of an
794 integer PID. Adjust to use range-for.
795 (attach_post_wait): Pass down inferior pointer instead of pid.
796 Use range-for instead of ALL_NON_EXITED_THREADS.
797 (detach_command): Remove init_thread_list call.
798 * inferior-iter.h: New.
799 * inferior.c (struct delete_thread_of_inferior_arg): Delete.
800 (delete_thread_of_inferior): Delete.
801 (delete_inferior, exit_inferior_1): Use range-for with
802 inf->threads_safe() instead of iterate_over_threads.
803 (inferior_appeared): Call init_thread_list here.
804 (discard_all_inferiors): Use all_non_exited_inferiors.
805 (find_inferior_id, find_inferior_pid): Use all_inferiors.
806 (iterate_over_inferiors): Use all_inferiors_safe.
807 (have_inferiors, number_of_live_inferiors): Use
808 all_non_exited_inferiors.
809 (number_of_inferiors): Use all_inferiors and std::distance.
810 (print_inferior): Use all_inferiors.
811 * inferior.h: Include gdbthread.h.
812 (enum step_over_calls_kind): Moved to gdbthread.h.
813 (struct inferior) <thread_list>: New field.
814 <threads, non_exited_threads, threads_safe>: New methods.
815 (ALL_INFERIORS): Delete.
816 Include "inferior-iter.h".
817 (ALL_NON_EXITED_INFERIORS): Delete.
818 (all_inferiors_safe, all_inferiors, all_non_exited_inferiors): New
820 * inflow.c (child_interrupt, child_pass_ctrlc): Replace
821 ALL_NON_EXITED_THREADS with all_non_exited_threads.
822 * infrun.c (follow_exec): Use all_threads_safe.
823 (clear_proceed_status, proceed): Use all_non_exited_threads.
824 (init_wait_for_inferior): Don't clear inline frame state here.
825 (infrun_thread_stop_requested, for_each_just_stopped_thread): Use
826 all_threads instead of ALL_NON_EXITED_THREADS.
827 (random_pending_event_thread): Use all_non_exited_threads instead
828 of ALL_NON_EXITED_THREADS. Use a lambda for repeated code.
829 (clean_up_just_stopped_threads_fsms): Use all_non_exited_threads
830 instead of ALL_NON_EXITED_THREADS.
831 (handle_no_resumed): Use all_non_exited_threads instead of
832 ALL_NON_EXITED_THREADS. Use all_inferiors instead of
834 (restart_threads, switch_back_to_stepped_thread): Use
835 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
836 * linux-nat.c (check_zombie_leaders): Replace ALL_INFERIORS with
838 (kill_unfollowed_fork_children): Use inf->non_exited_threads
839 instead of ALL_NON_EXITED_THREADS.
840 * linux-tdep.c (linux_make_corefile_notes): Use
841 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
842 * linux-thread-db.c (thread_db_target::update_thread_list):
843 Replace ALL_INFERIORS with all_inferiors.
844 (thread_db_target::thread_handle_to_thread_info): Use
845 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
846 * mi/mi-interp.c (multiple_inferiors_p): New.
847 (mi_on_resume_1): Simplify using all_non_exited_threads and
848 multiple_inferiors_p.
849 * mi/mi-main.c (mi_cmd_thread_list_ids): Use all_non_exited_threads
850 instead of ALL_NON_EXITED_THREADS.
851 * nto-procfs.c (nto_procfs_target::open): Don't call
852 init_thread_list here.
853 * record-btrace.c (record_btrace_target_open)
854 (record_btrace_target::stop_recording)
855 (record_btrace_target::close)
856 (record_btrace_target::record_is_replaying)
857 (record_btrace_target::resume, record_btrace_target::wait)
858 (record_btrace_target::record_stop_replaying): Use
859 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
860 * record-full.c (record_full_wait_1): Use all_non_exited_threads
861 instead of ALL_NON_EXITED_THREADS.
862 * regcache.c (cooked_read_test): Remove reference to global
864 * remote-sim.c (gdbsim_target::create_inferior): Don't call
865 init_thread_list here.
866 * remote.c (remote_target::update_thread_list): Use
867 all_threads_safe instead of ALL_NON_EXITED_THREADS.
868 (remote_target::process_initial_stop_replies): Replace
869 ALL_INFERIORS with all_non_exited_inferiors and use
870 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
871 (remote_target::open_1): Don't call init_thread_list here.
872 (remote_target::append_pending_thread_resumptions)
873 (remote_target::remote_resume_with_hc): Use all_non_exited_threads
874 instead of ALL_NON_EXITED_THREADS.
875 (remote_target::commit_resume)
876 (remote_target::remove_new_fork_children): Replace ALL_INFERIORS
877 with all_non_exited_inferiors and use all_non_exited_threads
878 instead of ALL_NON_EXITED_THREADS.
879 (remote_target::kill_new_fork_children): Use
880 all_non_exited_threads instead of ALL_NON_EXITED_THREADS. Remove
881 init_thread_list and init_wait_for_inferior calls.
882 (remote_target::remote_btrace_maybe_reopen)
883 (remote_target::thread_handle_to_thread_info): Use
884 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
885 * target.c (target_terminal::restore_inferior)
886 (target_terminal_is_ours_kind): Replace ALL_INFERIORS with
887 all_non_exited_inferiors.
888 * thread-iter.c: New file.
889 * thread-iter.h: New file.
890 * thread.c: Include "inline-frame.h".
891 (thread_list): Delete.
892 (clear_thread_inferior_resources): Call clear_inline_frame_state.
893 (init_thread_list): Use all_threads_safe instead of
894 ALL_THREADS_SAFE. Adjust to per-inferior thread lists.
895 (new_thread): Adjust to per-inferior thread lists.
896 (add_thread_silent): Pass inferior to find_thread_ptid.
897 (thread_info::deletable): New, moved from the header.
898 (delete_thread_1): Adjust to per-inferior thread lists.
899 (find_thread_global_id): Use inf->threads().
900 (find_thread_ptid): Use find_inferior_ptid and pass inferior to
902 (find_thread_ptid(inferior*, ptid_t)): New overload.
903 (iterate_over_threads): Use all_threads_safe.
905 (thread_count): Use all_threads and std::distance.
906 (live_threads_count): Use all_non_exited_threads and
908 (valid_global_thread_id): Use all_threads.
909 (in_thread_list): Use find_thread_ptid.
910 (first_thread_of_inferior): Adjust to per-inferior thread lists.
911 (any_thread_of_inferior, any_live_thread_of_inferior): Use
912 inf->non_exited_threads().
913 (prune_threads, delete_exited_threads): Use all_threads_safe.
914 (thread_change_ptid): Pass inferior pointer to find_thread_ptid.
915 (set_resumed, set_running): Use all_non_exited_threads.
916 (is_thread_state, is_stopped, is_exited, is_running)
917 (is_executing): Delete.
918 (set_executing, set_stop_requested, finish_thread_state): Use
919 all_non_exited_threads.
920 (print_thread_info_1): Use all_inferiors and all_threads.
921 (thread_apply_all_command): Use all_non_exited_threads.
922 (thread_find_command): Use all_threads.
923 (update_threads_executing): Use all_non_exited_threads.
924 * tid-parse.c (parse_thread_id): Use inf->threads.
925 * x86-bsd-nat.c (x86bsd_dr_set): Use inf->non_exited_threads ().
927 2018-11-22 Pedro Alves <palves@redhat.com>
929 * infrun.c (follow_exec) <set follow-exec new>: Add thread and
930 switch to it before calling into try_open_exec_file.
932 2018-11-22 Pedro Alves <palves@redhat.com>
934 * cli/cli-interp.c (cli_on_user_selected_context_changed): Use
935 inferior_thread instead of find_thread_ptid, and only when
936 inferior_ptid is not null_ptid.
937 * inferior.c (add_inferior): Don't include target_pid_to_str
938 output when the inferior is not started.
939 * python/py-inferior.c (python_on_normal_stop): Don't use
941 (tui_on_user_selected_context_changed): Use inferior_thread
942 instead of find_thread_ptid, and only when inferior_ptid is not
945 2018-11-21 Benno Fünfstück <benno.fuenfstueck@gmail.com>
948 * gdb/python/python.c (execute_gdb_command): Call
949 prevent_dont_repeat earlier to avoid affecting dont_repeat.
951 2018-11-21 Andrew Burgess <andrew.burgess@embecosm.com>
953 * Makefile.in (ALL_TARGET_OBS): Add arch/riscv.o.
954 (HFILES_NO_SRCDIR): Add arch/riscv.h.
955 * arch/riscv.c: New file.
956 * arch/riscv.h: New file.
957 * configure.tgt: Add cpu_obs list of riscv, move riscv-tdep.o into
958 this list, and add arch/riscv.o.
959 * features/Makefile: Add riscv features.
960 * features/riscv/32bit-cpu.c: New file.
961 * features/riscv/32bit-cpu.xml: New file.
962 * features/riscv/32bit-csr.c: New file.
963 * features/riscv/32bit-csr.xml: New file.
964 * features/riscv/32bit-fpu.c: New file.
965 * features/riscv/32bit-fpu.xml: New file.
966 * features/riscv/64bit-cpu.c: New file.
967 * features/riscv/64bit-cpu.xml: New file.
968 * features/riscv/64bit-csr.c: New file.
969 * features/riscv/64bit-csr.xml: New file.
970 * features/riscv/64bit-fpu.c: New file.
971 * features/riscv/64bit-fpu.xml: New file.
972 * features/riscv/rebuild-csr-xml.sh: New file.
973 * riscv-tdep.c: Add 'arch/riscv.h' include.
974 (riscv_gdb_reg_names): Delete.
975 (csr_reggroup): New global.
976 (struct riscv_register_alias): Delete.
977 (struct riscv_register_feature): New structure.
978 (riscv_register_aliases): Delete.
979 (riscv_xreg_feature): New global.
980 (riscv_freg_feature): New global.
981 (riscv_virtual_feature): New global.
982 (riscv_csr_feature): New global.
983 (riscv_create_csr_aliases): New function.
984 (riscv_read_misa_reg): Delete.
985 (riscv_has_feature): Delete.
986 (riscv_isa_xlen): Simplify, just return cached xlen.
987 (riscv_isa_flen): Simplify, just return cached flen.
988 (riscv_has_fp_abi): Update for changes in struct gdbarch_tdep.
989 (riscv_register_name): Update to make use of tdesc_register_name.
990 Look up xreg and freg names in the new globals riscv_xreg_feature
991 and riscv_freg_feature. Don't supply csr aliases here.
992 (riscv_fpreg_q_type): Delete.
993 (riscv_register_type): Use tdesc_register_type in almost all
994 cases, override the returned type in a few specific cases only.
995 (riscv_print_one_register_info): Handle errors reading registers.
996 (riscv_register_reggroup_p): Use tdesc_register_in_reggroup_p for
997 registers that are otherwise unknown to GDB. Also check the
999 (riscv_print_registers_info): Remove assert about upper register
1000 number, and use gdbarch_register_reggroup_p instead of
1002 (riscv_find_default_target_description): New function.
1003 (riscv_check_tdesc_feature): New function.
1004 (riscv_add_reggroups): New function.
1005 (riscv_setup_register_aliases): New function.
1006 (riscv_init_reggroups): New function.
1007 (_initialize_riscv_tdep): Add calls to setup CSR aliases, and
1008 setup register groups. Register new riscv debug variable.
1009 * riscv-tdep.h: Add 'arch/riscv.h' include.
1010 (struct gdbarch_tdep): Remove abi union, and add
1011 riscv_gdbarch_features field. Remove cached quad floating point
1012 type, and provide initialisation for double type field.
1013 * target-descriptions.c (maint_print_c_tdesc_cmd): Add riscv to
1014 the list of targets using the feature based target descriptions.
1015 * NEWS: Mention target description support.
1017 2018-11-21 Pedro Alves <palves@redhat.com>
1019 * valops.c (find_method_list, value_find_oload_method_list)
1020 (find_overload_match, find_oload_champ): Rename parameters and
1023 2018-11-21 Pedro Alves <palves@redhat.com>
1025 * valops.c (find_method_list): Replace pointer and length
1026 parameters with an gdb::array_view. Adjust.
1027 (value_find_oload_method_list): Likewise.
1028 (find_overload_match): Use gdb::array_view for methods list.
1029 Adjust to find_oload_champ interface change.
1030 (find_oload_champ): 'xm_worker_vec' parameter now a pointer/array.
1031 'num_fns' parameter now a size_t. Eliminate 'fn_count' local.
1033 2018-11-21 Pedro Alves <palves@redhat.com>
1035 * gdbtypes.c (compare_badness): Change type of parameters to const
1036 reference. Adjust to badness_vector being a std::vector now.
1037 (rank_function): Adjust to badness_vector being a std::vector now.
1038 * gdbtypes.h (badness_vector): Now a typedef to std::vector.
1039 (LENGTH_MATCH): Delete.
1040 (compare_badness): Change type of parameters to const reference.
1041 (rank_function): Return a badness_vector by value now.
1042 (find_overload_match): Adjust to badness_vector being a
1043 std::vector now. Remove cleanups.
1044 (find_oload_champ_namespace): 'oload_champ_bv' parameter now a
1045 badness_vector pointer.
1046 (find_oload_champ_namespace_loop): 'oload_champ_bv' parameter now
1047 a badness_vector pointer. Adjust to badness_vector being a
1048 std::vector now. Remove cleanups.
1049 (find_oload_champ): 'oload_champ_bv' parameter now
1050 a badness_vector pointer. Adjust to badness_vector being a
1051 std::vector now. Remove cleanups.
1053 2018-11-21 Pedro Alves <palves@redhat.com>
1055 * cp-support.c (sym_return_val_size, sym_return_val_index)
1056 (sym_return_val): Delete.
1057 (overload_list_add_symbol): Add std::vector parameter. Adjust to
1059 (make_symbol_overload_list): Adjust to return a std::vector
1060 instead of maintaining a global open coded vector.
1061 (make_symbol_overload_list_block): Add std::vector parameter.
1062 (make_symbol_overload_list_block): Rename to ...
1063 (add_symbol_overload_list_block): ... this and add std::vector
1065 (make_symbol_overload_list_namespace): Rename to ...
1066 (add_symbol_overload_list_namespace): ... this and add std::vector
1068 (make_symbol_overload_list_adl_namespace): Rename to ...
1069 (add_symbol_overload_list_adl_namespace): ... this and add
1070 std::vector parameter.
1071 (make_symbol_overload_list_adl): Delete.
1072 (add_symbol_overload_list_adl): New.
1073 (make_symbol_overload_list_using): Rename to ...
1074 (add_symbol_overload_list_using): ... this and add std::vector
1076 (make_symbol_overload_list_qualified): Rename to ...
1077 (add_symbol_overload_list_qualified): ... this and add std::vector
1079 * cp-support.h: Include "common/array-view.h" and <vector>.
1080 (make_symbol_overload_list): Change return type to std::vector.
1081 (make_symbol_overload_list_adl): Delete declaration.
1082 (add_symbol_overload_list_adl): New declaration.
1083 * valops.c (find_overload_match): Local 'oload_syms' now a
1085 (find_oload_champ_namespace): 'oload_syms' parameter now a
1086 std::vector pointer.
1087 (find_oload_champ_namespace_loop): 'oload_syms' parameter now a
1088 std::vector pointer. Adjust to new make_symbol_overload_list
1091 2018-11-21 Pedro Alves <palves@redhat.com>
1093 * common/array-view.h (array_view::splice(size_type, size_t)): New.
1094 (array_view::splice(size_type)): New.
1095 * eval.c (eval_call, evaluate_funcall): Adjust to use array_view.
1096 * extension.c (xmethod_worker::get_arg_types): Adjust to return an
1098 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
1099 * extension.h: Include "common/array-view.h".
1100 (xmethod_worker::invoke): Adjust to use gdb::array_view.
1101 (xmethod_worker::get_arg_types): Adjust to return an std::vector.
1102 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
1103 (xmethod_worker::do_get_arg_types): Adjust to use std::vector.
1104 (xmethod_worker::do_get_result_type): Adjust to use
1106 * gdbtypes.c (rank_function): Adjust to use gdb::array_view.
1107 * gdbtypes.h: Include "common/array-view.h".
1108 (rank_function): Adjust to use gdb::array_view.
1109 * python/py-xmethods.c (python_xmethod_worker::invoke)
1110 (python_xmethod_worker::do_get_arg_types)
1111 (python_xmethod_worker::do_get_result_type)
1112 (python_xmethod_worker::invoke): Adjust to new interfaces.
1113 * valarith.c (value_user_defined_cpp_op, value_user_defined_op)
1114 (value_x_binop, value_x_unop): Adjust to use gdb::array_view.
1115 * valops.c (find_overload_match, find_oload_champ_namespace)
1116 (find_oload_champ_namespace_loop, find_oload_champ): Adjust to use
1117 gdb:array_view and the new xmethod_worker interfaces.
1118 * value.c (result_type_of_xmethod, call_xmethod): Adjust to use
1120 * value.h (find_overload_match, result_type_of_xmethod)
1121 (call_xmethod): Adjust to use gdb::array_view.
1122 * unittests/array-view-selftests.c: Add slicing tests.
1124 2018-11-21 Pedro Alves <palves@redhat.com>
1126 * ada-lang.c (ada_evaluate_subexp): Adjust to pass an array_view.
1127 * common/array-view.h (make_array_view): New.
1128 * compile/compile-object-run.c (compile_object_run): Adjust to
1130 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust.
1131 * eval.c (eval_call): Adjust to pass an array_view.
1132 (evaluate_subexp_standard): Adjust to pass an array_view.
1133 * gcore.c (call_target_sbrk): Adjust to pass an array_view.
1134 * guile/scm-value.c (gdbscm_value_call): Likewise.
1135 * infcall.c (push_dummy_code): Replace pointer + size parameters
1136 with an array_view parameter.
1137 (call_function_by_hand, call_function_by_hand_dummy): Likewise and
1139 * infcall.h: Include "common/array-view.h".
1140 (call_function_by_hand, call_function_by_hand_dummy): Replace
1141 pointer + size parameters with an array_view parameter.
1142 * linux-fork.c (inferior_call_waitpid): Adjust to use array_view.
1143 * linux-tdep.c (linux_infcall_mmap): Likewise.
1144 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1145 (value_nsstring, print_object_command): Likewise.
1146 * python/py-value.c (valpy_call): Likewise.
1147 * rust-lang.c (rust_evaluate_funcall): Likewise.
1148 * spu-tdep.c (flush_ea_cache): Likewise.
1149 * valarith.c (value_x_binop, value_x_unop): Likewise.
1150 * valops.c (value_allocate_space_in_inferior): Likewise.
1151 * unittests/array-view-selftests.c (run_tests): Add
1152 gdb::make_array_view test.
1154 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
1156 * cli-out.c (cli_ui_out::do_field_int): Use string_printf rather
1157 than a fixed size buffer.
1159 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
1161 * breakpoint.c (print_one_breakpoint_location): Reduce whitespace,
1162 and remove insertion of extra spaces in GDB's output.
1163 * cli-out.c (cli_ui_out::do_field_fmt): Update header comment.
1164 Layout field into a temporary buffer, and then output it as a
1167 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1169 * NEWS: Document the language choice done by
1170 'info [types|functions|variables]|rbreak'.
1172 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1174 * symtab.c (treg_matches_sym_type_name): Use
1175 scoped_switch_to_sym_language_if_auto instead of local logic.
1176 (print_symbol_info): Use scoped_switch_to_sym_language_if_auto
1177 to switch to SYM language when language mode is auto.
1179 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1181 * language.h (scoped_switch_to_sym_language_if_auto): New class.
1183 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1185 * symtab.c (search_symbols): Properly check absence of type regexp
1186 before entering the loop scanning the minimal symbols.
1188 2018-11-20 John Darrington <john@darrington.wattle.id.au>
1190 * s12z-tdep.c (s12z_extract_return_value): New function.
1191 (inv_reg_perm) New array.
1192 (s12z_return_value): Populate readbuf if non-null.
1194 2018-11-20 Eli Zaretskii <eliz@gnu.org>
1196 * common/filestuff.c (gdb_fopen_cloexec): Disable use of "e" mode
1197 with 'fopen' also if O_CLOEXEC is equal to O_NOINHERIT, to cater
1198 to MinGW fixed by Gnulib.
1199 (O_NOINHERIT): Define if not defined.
1201 2018-11-19 John Darrington <john@darrington.wattle.id.au>
1203 * s12z-tdep.c (s12z_frame_cache): Add an assertion.
1205 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
1207 * infrun.c (displaced_step_inferior_state) <next>: Remove.
1209 2018-11-19 Tom Tromey <tom@tromey.com>
1211 * source.c (get_filename_and_charpos): Return void.
1213 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
1215 * skip.c (_initialize_step_skip): Fix "info skip" help.
1217 2018-11-16 Tom Tromey <tom@tromey.com>
1220 * rust-lang.c (rust_internal_print_type): Handle TYPE_CODE_PTR.
1222 2018-11-19 Simon Marchi <simon.marchi@ericsson.com>
1224 * infrun.c (displaced_step_inferior_states): Change type to
1226 (get_displaced_stepping_state): Adjust.
1227 (displaced_step_in_progress_any_inferior): Adjust.
1228 (add_displaced_stepping_state): Adjust.
1229 (remove_displaced_stepping_state): Adjust.
1231 2018-11-18 Tom Tromey <tom@tromey.com>
1234 * target-delegates.c: Rebuild.
1235 * ia64-linux-nat.c (class ia64_linux_nat_target)
1236 <have_steppable_watchpoint>: Use override. Return true, not 1.
1237 (ia64_linux_nat_target::can_use_hw_breakpoint): Rename. Remove
1239 (ia64_linux_nat_target::low_new_thread): Rename.
1240 (class ia64_linux_nat_target) <read_description>: Don't declare.
1241 * target.h (struct target_ops) <have_steppable_watchpoint>: Return
1244 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1247 * aarch64-tdep.c (aarch64_push_dummy_call): Remove
1248 lang_struct_return code.
1250 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1252 * aarch64-tdep.c (aarch64_push_dummy_call): Replace arg with
1254 * alpha-tdep.c (alpha_push_dummy_call): Likewise.
1255 * amd64-tdep.c (amd64_push_arguments): Likewise.
1256 (amd64_push_dummy_call): Likewise.
1257 * amd64-windows-tdep.c (amd64_windows_push_arguments): Likewise.
1258 * arc-tdep.c (arc_push_dummy_call): Likewise.
1259 * arm-tdep.c (arm_push_dummy_call): Likewise.
1260 * avr-tdep.c (avr_push_dummy_call): Likewise.
1261 * bfin-tdep.c (bfin_push_dummy_call): Likewise.
1262 * cris-tdep.c (cris_push_dummy_call): Likewise.
1263 * csky-tdep.c (csky_push_dummy_call): Likewise.
1264 * frv-tdep.c (frv_push_dummy_call): Likewise.
1265 * gdbarch.c: Regenerate.
1266 * gdbarch.h: Regenerate.
1267 * gdbarch.sh (gdbarch_push_dummy_call): Replace arg with
1269 * h8300-tdep.c (h8300_push_dummy_call): Likewise.
1270 * hppa-tdep.c (hppa32_push_dummy_call): Likewise.
1271 (hppa64_push_dummy_call): Likewise.
1272 * i386-darwin-tdep.c (i386_darwin_push_dummy_call): Likewise.
1273 * i386-tdep.c (i386_push_dummy_call): Likewise.
1274 * ia64-tdep.c (ia64_push_dummy_call): Likewise.
1275 * infcall.c (call_function_by_hand_dummy): Likewise.
1276 * iq2000-tdep.c (iq2000_push_dummy_call): Likewise.
1277 * lm32-tdep.c (lm32_push_dummy_call): Likewise.
1278 * m32c-tdep.c (m32c_push_dummy_call): Likewise.
1279 * m32r-tdep.c (m32r_push_dummy_call): Likewise.
1280 * m68hc11-tdep.c (m68hc11_push_dummy_call): Likewise.
1281 * m68k-tdep.c (m68k_push_dummy_call): Likewise.
1282 * mep-tdep.c (mep_push_dummy_call): Likewise.
1283 * mips-tdep.c (mips_eabi_push_dummy_call): Likewise.
1284 (mips_n32n64_push_dummy_call): Likewise.
1285 (mips_o32_push_dummy_call): Likewise.
1286 (mips_o64_push_dummy_call): Likewise.
1287 * mn10300-tdep.c (mn10300_push_dummy_call): Likewise.
1288 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
1289 * nds32-tdep.c (nds32_push_dummy_call): Likewise.
1290 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
1291 * or1k-tdep.c (or1k_push_dummy_call): Likewise.
1292 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
1293 (ppc64_sysv_abi_push_dummy_call): Likewise.
1294 * ppc-tdep.h (ppc_sysv_abi_push_dummy_call): Likewise.
1295 (ppc64_sysv_abi_push_dummy_call): Likewise.
1296 * riscv-tdep.c (riscv_push_dummy_call): Likewise.
1297 * rl78-tdep.c (rl78_push_dummy_call): Likewise.
1298 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
1299 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
1300 * rx-tdep.c (rx_push_dummy_call): Likewise.
1301 * s390-tdep.c (s390_push_dummy_call): Likewise.
1302 * score-tdep.c (score_push_dummy_call): Likewise.
1303 * sh-tdep.c (sh_push_dummy_call_fpu): Likewise.
1304 (sh_push_dummy_call_nofpu): Likewise.
1305 * sparc-tdep.c (sparc32_store_arguments): Likewise.
1306 (sparc32_push_dummy_call): Likewise.
1307 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
1308 (sparc64_push_dummy_call): Likewise.
1309 * spu-tdep.c (spu_push_dummy_call): Likewise.
1310 * tic6x-tdep.c (tic6x_push_dummy_call): Likewise.
1311 * tilegx-tdep.c (tilegx_push_dummy_call): Likewise.
1312 * v850-tdep.c (v850_push_dummy_call): Likewise.
1313 * vax-tdep.c (vax_push_dummy_call): Likewise.
1314 * xstormy16-tdep.c (xstormy16_push_dummy_call): Likewise.
1315 * xtensa-tdep.c (xtensa_push_dummy_call): Likewise.
1317 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1319 * gdbarch.sh (enum function_call_return_method): Add enum.
1320 * gdbarch.h: Regenerate.
1321 * infcall.c (call_function_by_hand_dummy): Replace vars with enum.
1323 2018-11-15 Joel Brobecker <brobecker@adacore.com>
1325 * unittests/copy_bitwise-selftests.c: New file.
1326 * utils.c (selftests::bits_to_str, selftests::check_copy_bitwise)
1327 (selftests::copy_bitwise_tests): Delete, moving this code to
1328 unittests/copy_bitwise-selftests.c instead.
1329 (_initialize_utils): Do not register copy_bitwise tests.
1330 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1331 unittests/copy_bitwise-selftests.c.
1333 2018-11-14 Joel Brobecker <brobecker@adacore.com>
1335 * ada-lang.c (move_bits): Delete. Update all callers to use
1336 copy_bitwise instead.
1337 * dwarf2loc.c (copy_bitwise, bits_to_str::bits_to_str)
1338 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1339 Move from here to utils.c.
1340 (_initialize_dwarf2loc): Remove call to register copy_bitwise
1342 * utils.h (copy_bitwise): Add declaration.
1343 * utils.c (copy_bitwise, bits_to_str::bits_to_str)
1344 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1345 Moved here from dwarf2loc.c.
1346 (_initialize_utils): Register copy_bitwise selftests.
1348 2018-11-14 Jim Wilson <jimw@sifive.com>
1350 * riscv-tdep.c (struct riscv_arg_info): New field is_unnamed.
1351 (riscv_call_arg_scalar_int): If unnamed arg with twice xlen alignment,
1352 then increment next_regnum if odd.
1353 (riscv_arg_location): New arg is_unnamed. Set ainfo->is_unnamed.
1354 (riscv_push_dummy_call): New local ftype. Call check_typedef to set
1355 function type. Pass new arg to riscv_arg_location based on function
1357 (riscv_return_value): Pass new arg to riscv_arg_location.
1359 * riscv-tdep.c (BIGGEST_ALIGNMENT): New.
1360 (riscv_type_alignment) <TYPE_CODE_ARRAY>: If TYPE_VECTOR, return min
1361 of TYPE_LENGTH and BIGGEST_ALIGNMENT.
1363 * riscv-tdep.c (riscv_call_arg_scalar_int): Use std::min when
1364 setting len. New local align, set to max of arg align and xlen,
1365 and pass to first riscv_assign_stack_location call.
1367 2018-11-12 Simon Marchi <simon.marchi@polymtl.ca>
1369 * skip.c (complete_skip_number): New function.
1370 (_initialize_step_skip): Add completers to some skip commands.
1372 2018-11-09 Tom Tromey <tom@tromey.com>
1374 * remote.c (remote_g_packet_guess_s): Remove typedef and DEF_VEC.
1375 (struct remote_g_packet_data): Derive from allocate_on_obstack.
1376 <guesses>: Now a std::vector.
1377 (remote_g_packet_data_init, register_remote_g_packet_guess):
1379 (remote_read_description_p): Update. Return bool.
1380 (remote_target::read_description): Update.
1381 (struct remote_g_packet_guess): Add constructor.
1383 2018-11-09 Tom Tromey <tom@tromey.com>
1385 * common/scoped_fd.h (class scoped_fd): Add move constructor and
1386 move assignment operator.
1387 * psymtab.c (psymtab_to_fullname): Update.
1388 * source.h (open_source_file): Return scoped_fd.
1389 (find_and_open_source): Likewise.
1390 * source.c (open_source_file): Return scoped_fd.
1391 (get_filename_and_charpos): Update.
1392 (print_source_lines_base): Update. Use scoped_fd::to_file.
1393 (forward_search_command): Likewise.
1394 (reverse_search_command): Likewise.
1395 (find_and_open_source): Return scoped_fd.
1396 * tui/tui-source.c (tui_set_source_content): Update. Use
1399 2018-11-09 John Baldwin <jhb@FreeBSD.org>
1401 * minsyms.c (minimal_symbol_reader::install): Fix unsigned
1404 2018-11-09 Hafiz Abid Qadeer <abidh@codesourcery.com>
1406 * configure: Regenerate.
1408 2018-11-09 Tom de Vries <tdevries@suse.de>
1410 * symtab.c (symbol_set_names): Call symbol_find_demangled_name
1411 unconditionally, to set the language of the symbol. Manage freeing
1412 returned pointer using gdb::unique_xmalloc_ptr.
1414 2018-11-08 Tom Tromey <tom@tromey.com>
1416 * record.c (require_record_target): Upper-case "<TAB>".
1418 2018-11-08 Tom Tromey <tom@tromey.com>
1420 * python/lib/gdb/command/pretty_printers.py
1421 (InfoPrettyPrinter.invoke): Don't indent "objfile" heading.
1423 2018-11-08 Tom Tromey <tom@tromey.com>
1427 * target.h (target_supports_terminal_ours): Return bool.
1428 * target.c (target_supports_terminal_ours): Handle case where
1429 current_top_target returns nullptr. Return bool.
1431 2018-11-08 Joel Brobecker <brobecker@adacore.com>
1433 * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1):
1434 return the correct count for potential HFAs.
1436 2018-11-08 Jan Beulich <jbeulich@suse.com>
1438 * i387-tdep.c (i387_supply_xsave): Split handling of
1439 X86_XSTATE_ZMM_H and X86_XSTATE_ZMM.
1440 (i387_collect_xsave): Likewise.
1442 2018-11-08 Andrew Burgess <andrew.burgess@embecosm.com>
1444 * riscv-tdep.c (riscv_insn::decode): Update header comment.
1445 (riscv_frame_this_id): Catch errors thrown while building the
1446 frame cache, leave the frame id as the default, which is the outer
1449 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1451 * ada-lang.c (read_atcb): Only set task_info->called_task if
1452 task_info->state == Entry_Caller_Sleep.
1453 (print_ada_task_info): Do not check task_info->state before
1454 checking task_info->called_task.
1455 (info_task): Likewise.
1457 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1459 * ada-tasks.c (read_atcb): Clear task_info before computing
1460 the value of each of its fields.
1462 2018-11-07 Andrew Burgess <andrew.burgess@embecosm.com>
1464 * dwarf2read.c (dwarf2_init_integer_type): Check for name being
1465 NULL before dereferencing it.
1467 2018-11-06 Tom de Vries <tdevries@suse.de>
1469 * linux-tdep.c (linux_vsyscall_range_raw): Use xmalloc to allocate
1472 2018-11-06 Max Filippov <jcmvbkbc@gmail.com>
1474 * configure.tgt (xtensa*-*-linux*): Change to xtensa*-*-*linux*
1475 so that it applies to uclinux as well.
1477 2018-11-06 Marius Muench <marius.muench@eurecom.fr>
1479 * arm-tdep.c (arm_scan_prologue): Don't dereference FP reg
1482 2018-11-06 John Baldwin <jhb@FreeBSD.org>
1484 * riscv-fbsd-nat.c (getregs_supplies): Return true for
1485 RISCV_CSR_SSTATUS_REGNUM.
1487 2018-11-04 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1489 * source.c (open_source_file): Fix leak by transferring the
1490 current s->fullname to the unique_xmalloc_ptr fullname given
1491 to find_and_open_source.
1493 2018-11-04 Tom Tromey <tom@tromey.com>
1495 * varobj.c (install_default_visualizer): Update.
1496 * python/python-internal.h (gdbpy_get_varobj_pretty_printer):
1498 * python/py-prettyprint.c (search_pp_list): Return gdbpy_ref.
1499 (find_pretty_printer_from_progspace)
1500 (find_pretty_printer_from_gdb, find_pretty_printer)
1501 (gdbpy_get_varobj_pretty_printer): Return gdbpy_ref.
1502 (gdbpy_get_varobj_pretty_printer, gdbpy_default_visualizer):
1505 2018-11-04 Tom Tromey <tom@tromey.com>
1507 * python/python.c (gdbpy_parameter_value): Update.
1508 * python/python-internal.h (python_string_to_unicode)
1509 (python_string_to_target_python_string)
1510 (host_string_to_python_string): Return gdbpy_ref.
1511 * python/py-utils.c (python_string_to_unicode)
1512 (unicode_to_encoded_python_string)
1513 (unicode_to_target_python_string)
1514 (python_string_to_target_string)
1515 (python_string_to_target_python_string): Return gdbpy_ref.
1516 (python_string_to_host_string): Update.
1517 (host_string_to_python_string): Return gdbpy_ref.
1518 * python/py-symtab.c (stpy_get_filename, stpy_get_producer)
1519 (stpy_fullname): Update.
1520 * python/py-progspace.c (pspy_get_filename, pspy_solib_name):
1522 * python/py-prettyprint.c (print_string_repr): Update.
1523 * python/py-objfile.c (objfpy_get_filename, objfpy_get_username)
1524 (objfpy_get_build_id): Update.
1525 * python/py-breakpoint.c (bppy_get_location)
1526 (bppy_get_expression, bppy_get_condition, bppy_get_commands):
1529 2018-11-04 Tom Tromey <tom@tromey.com>
1531 * python/python-internal.h (gdb_py_object_from_longest)
1532 (gdb_py_object_from_ulongest): Return gdbpy_ref.
1533 * python/py-value.c (valpy_int): Update.
1534 * python/py-utils.c (gdb_py_object_from_longest): Return
1536 (gdb_py_object_from_ulongest): Likewise.
1537 * python/py-type.c (typy_get_alignof): Update.
1538 * python/py-linetable.c (ltpy_get_all_source_lines)
1539 (ltpy_entry_get_line, ltpy_entry_get_pc): Update.
1540 * python/py-block.c (blpy_get_start, blpy_get_end): Update.
1542 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1544 * ada-lang.c (_initialize_ada_language): Fix typo.
1546 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1548 * language.c (type): Remove.
1549 (_initialize_language): Remove assignment to type.
1551 2018-11-02 Joel Brobecker <brobecker@adacore.com>
1553 * aarch64-ravenscar-thread.h, aarch64-ravenscar-thread.c: New files.
1554 * aarch64-tdep.c: #include "aarch64-ravenscar-thread.h".
1555 (aarch64_gdbarch_init): Add call to register_aarch64_ravenscar_ops.
1556 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-ravenscar-thread.o.
1557 (HFILES_NO_SRCDIR): Add aarch64-ravenscar-thread.h.
1558 (ALLDEPFILES): Add aarch64-ravenscar-thread.c.
1559 * configure.tgt (cpu_obs) [aarch64*-*-*]: Add ravenscar-thread.o
1560 and aarch64-ravenscar-thread.o.
1561 * NEWS: Add entry documenting Ravenscar tasking support
1564 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
1566 * symtab.c (info_functions_command): Initialize quiet flag.
1567 * stack.c (info_args_command): Likewise.
1569 2018-11-01 Jim Wilson <jimw@sifive.com>
1571 * riscv-tdep.c (riscv_breakpoint_kind_from_pc): New local unaligned_p.
1572 Set if pcptr if unaligned. Return 2 if unaligned_p true. Update
1575 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1577 * ada-lang.c (ada_watch_location_expression): New function.
1578 (ada_language_defn): Set la_watch_location_expression to
1579 ada_watch_location_expression.
1581 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1583 * print-utils.c (int_string): Remove unnecessary trailing spaces.
1585 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1587 * rs6000-tdep.c (skip_prologue): Fix potential negative left
1590 2018-11-01 Jerome Guitton <guitton@adacore.com>
1591 Joel Brobecker <brobecker@adacore.com>
1593 * defs.h (enum gdb_osabi): Add GDB_OSABI_PIKEOS.
1594 * osabi.c (gdb_osabi_names): Add name for GDB_OSABI_PIKEOS.
1595 * arm-pikeos-tdep.c: New file.
1596 * configure.tgt: Add arm-pikeos-tdep.o to the case of ARM
1598 * Makefile.in (ALL_TARGET_OBS): Add arm-pikeos-tdep.o.
1600 2018-11-01 Simon Marchi <simon.marchi@ericsson.com>
1602 * common/pathstuff.c (get_standard_temp_dir): New.
1603 * common/pathstuff.h (get_standard_temp_dir): New.
1604 * config.in: Re-generate.
1605 * configure: Re-generate.
1606 * configure.ac: Don't check for mkdtemp.
1607 * gnulib/aclocal-m4-deps.mk: Re-generate.
1608 * gnulib/aclocal.m4: Re-generate.
1609 * gnulib/config.in: Re-generate.
1610 * gnulib/configure: Re-generate.
1611 * gnulib/import/Makefile.am: Re-generate.
1612 * gnulib/import/Makefile.in: Re-generate.
1613 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1614 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1615 * gnulib/import/m4/mkdtemp.m4: New file.
1616 * gnulib/import/mkdtemp.c: New file.
1617 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES):
1619 * unittests/mkdir-recursive-selftests.c (test): Use
1620 get_standard_temp_dir.
1621 (_initialize_mkdir_recursive_selftests): Remove HAVE_MKDTEMP
1623 * compile/compile.c (get_compile_file_tempdir): Likewise.
1625 2018-11-01 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1627 * rs6000-aix-tdep.c: Include "trad-frame.h" and "frame-unwind.h".
1628 (SIG_FRAME_LR_OFFSET64): New define.
1629 (SIG_FRAME_FP_OFFSET64): New define.
1630 (aix_sighandle_frame_cache): New Function.
1631 (aix_sighandle_frame_this_id): New Function.
1632 (aix_sighandle_frame_prev_register): New Function.
1633 (aix_sighandle_frame_sniffer): New Function.
1634 (aix_sighandle_frame_unwind): New global variable.
1635 (rs6000_aix_init_osabi): Install new frame unwinder.
1637 2018-10-31 Sergio Durigan Junior <sergiodj@redhat.com>
1640 * common/common-defs.h: Don't redefine _FORTIFY_SOURCE if it's
1643 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1645 * ppc-linux-nat.c: Include nat/linux-ptrace.h.
1647 2018-10-31 Andrew Burgess <andrew.burgess@embecosm.com>
1649 * dwarf2read.c (struct dwarf2_cu): Add producer_is_icc field.
1650 (producer_is_icc): New function.
1651 (check_producer): Set producer_is_icc field on dwarf2_cu.
1652 (dwarf2_init_integer_type): New function.
1653 (read_base_type): Call dwarf2_init_integer_type instead of
1654 init_integer_type in all cases.
1655 (dwarf2_cu::dwarf2_cu): Initialise producer_is_icc field.
1656 * valprint.c (maybe_negate_by_bytes): Add an assertion that the
1657 LEN is greater than 0.
1659 2018-10-30 Tom Tromey <tom@tromey.com>
1661 * main.c (captured_main_1): Check return value of bfd_init.
1663 2018-10-29 Sergio Durigan Junior <sergiodj@redhat.com>
1665 * common/offset-type.h (DEFINE_OFFSET_REL_OP): Delete.
1668 2018-10-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1670 * procfs.c: Include common/pathstuff.h.
1672 2018-10-28 Andrew Burgess <andrew.burgess@embecosm.com>
1674 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1675 Add missing braces. No functional change.
1677 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1679 * macrocmd.c (info_macro_command): Use report_unrecognized_option_error
1680 to report a bad option and fix indentation.
1681 * demangle.c (demangle_command): Use report_unrecognized_option_error
1682 to report a bad option and correctly report the bad option.
1684 2018-10-27 Tom Tromey <tom@tromey.com>
1687 * darwin-nat.c (copied_shell): New global.
1688 (may_have_sip): Rename from should_disable_startup_with_shell.
1689 (copy_shell_to_cache, maybe_cache_shell): New functions.
1690 (darwin_nat_target::create_inferior): Update. Use
1693 2018-10-27 Tom Tromey <tom@tromey.com>
1695 * unittests/scoped_fd-selftests.c (test_to_file): New function.
1696 (run_tests): Call test_to_file.
1697 * dwarf-index-write.c (write_psymtabs_to_index): Do not reopen
1699 * common/scoped_fd.h (scoped_fd::to_file): New method.
1701 2018-10-27 Tom Tromey <tom@tromey.com>
1703 * unittests/scoped_mmap-selftests.c (test_normal): Use
1704 gdb_mkostemp_cloexec.
1705 * unittests/scoped_fd-selftests.c (test_destroy, test_release):
1706 Use gdb_mkostemp_cloexec.
1707 * gnulib/aclocal-m4-deps.mk, gnulib/aclocal.m4,
1708 gnulib/config.in, gnulib/configure,
1709 gnulib/import/Makefile.am, gnulib/import/Makefile.in,
1710 gnulib/import/m4/gnulib-cache.m4,
1711 gnulib/import/m4/gnulib-comp.m4: Update.
1712 * gnulib/import/m4/mkostemp.m4: New file.
1713 * gnulib/import/m4/mkstemp.m4: Remove.
1714 * gnulib/import/mkostemp.c: New file.
1715 * gnulib/import/mkstemp.m4: Remove.
1716 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Remove
1717 mkstemp, add mkostemp. Apply new patch.
1718 * gnulib/import/stdlib.in.h: Apply patch.
1719 * gnulib/patches/0002-mkostemp-mkostemps-Fix-compilation-error-in-C-mode-o.patch:
1721 * dwarf-index-write.c (write_psymtabs_to_index): Use
1722 gdb_mkostemp_cloexec.
1723 * common/filestuff.h (gdb_mkostemp_cloexec): New function.
1725 2018-10-27 Tom Tromey <tom@tromey.com>
1727 * unittests/mkdir-recursive-selftests.c: New file.
1728 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1729 unittests/mkdir-recursive-selftests.c.
1730 * dwarf-index-cache.c (mkdir_recursive): Move to
1732 (index_cache::store): Check return value of mkdir_recursive.
1733 (create_dir_and_check, test_mkdir_recursive): Move to new file.
1734 (_initialize_index_cache): Don't register test.
1735 * common/filestuff.h (mkdir_recursive): Declare.
1736 * common/filestuff.c (mkdir_recursive): Move from
1737 dwarf-index-cache.c. Return bool.
1739 2018-10-27 Tom Tromey <tom@tromey.com>
1741 * dwarf-index-write.c (write_psymtabs_to_index): Move
1742 make_temp_filename to common/pathstuff.c.
1743 * common/pathstuff.h (make_temp_filename): Declare.
1744 * common/pathstuff.c (make_temp_filename): New function, moved
1745 from dwarf-index-write.c.
1747 2018-10-27 Tom Tromey <tom@tromey.com>
1749 * procfs.c (procfs_target::create_inferior): Use get_shell.
1750 * cli/cli-cmds.c (shell_escape): Use get_shell.
1751 * windows-nat.c (windows_nat_target::create_inferior): Use
1753 * common/pathstuff.c (get_shell): New function.
1754 * nat/fork-inferior.c (SHELL_FILE, get_startup_shell): Remove.
1755 (fork_inferior): Use get_shell.
1756 * common/pathstuff.h (get_shell): Declare.
1758 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1760 * NEWS: Mention changes to 'info [args|functions|locals|variables]'
1762 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1764 * stack.c (print_variable_and_value_data): Add preg and treg.
1765 (print_frame_local_vars): Add quiet, regexp and t_regexp arguments,
1767 (print_frame_arg_vars): Likewise.
1768 (prepare_reg): New function.
1769 (info_locals_command): Extract info print args and use them.
1770 (info_args_command): Likewise.
1771 (_initialize_stack): Modify on-line help.
1772 * symtab.c (treg_matches_sym_type_name): New function.
1773 (search_symbols): New arg t_regexp.
1774 (symtab_symbol_info): New args quiet, regexp, t_regexp.
1775 (info_variables_command): Extract info print args and use them.
1776 (info_functions_command): Likewise.
1777 (info_types_command): Update call to symtab_symbol_info.
1778 (_initialize_symtab): Modify on-line help.
1779 * symtab.h (treg_matches_sym_type_name): New function.
1780 (search_symbols): New t_regexp arg.
1782 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1784 * cli-utils.c (extract_arg_maybe_quoted): New function.
1785 (extract_info_print_args): New function.
1786 (info_print_args_help): New function.
1787 (report_unrecognized_option_error): New function.
1788 * cli-utils.h (extract_arg_maybe_quoted): New function.
1789 (extract_info_print_args): New function.
1790 (info_print_args_help): New function.
1791 (report_unrecognized_option_error): New function.
1793 2018-10-26 Tom Tromey <tom@tromey.com>
1795 * dwarf2read.c (recursively_compute_inclusions): Use std::vector.
1796 (compute_compunit_symtab_includes): Update.
1797 * symtab.h: (symtab_ptr): Remove typedef. Don't define a VEC.
1798 (compunit_symtab_ptr): Likewise.
1800 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1802 * fbsd-tdep.c (fbsd_print_auxv_entry): Only use
1803 default_print_auxv_entry for specific tag values.
1805 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1807 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_HWCAP2.
1809 2018-10-26 Jim Wilson <jimw@sifive.com>
1811 * riscv-linux-tdep.c: Include tramp-frame.h and trad-frame.h.
1812 (riscv_linux_sigframe_init): Declare.
1813 (RISCV_INST_LI_A7_SIGRETURN, RISCV_INT_ECALL): New.
1814 (riscv_linux_sigframe): New.
1815 (SIGFRAME_SIGINFO_SIZE, UCONTEXT_MCONTEXT_OFFSET): New.
1816 (riscv_linux_sigframe_init): Define.
1817 (riscv_linux_init_abi): Call tramp_frame_prepend_unwinder.
1819 * riscv-tdep.c (riscv_isa_xlen): Refer to riscv-tdep.h comment.
1820 (riscv_isa_flen): Likewise. Drop static.
1821 * riscv-tdep.h (riscv_isa_xlen): Move riscv-tdep.c comment to here.
1822 (riscv_isa_flen): Likewise. Declare.
1824 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1825 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1827 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_htm_vsx32l)
1828 (tdesc_powerpc_isa207_htm_vsx64l): Declare.
1829 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TM_SPRREGSET)
1830 (PPC32_LINUX_SIZEOF_CGPRREGSET, PPC64_LINUX_SIZEOF_CGPRREGSET)
1831 (PPC_LINUX_SIZEOF_CFPRREGSET, PPC_LINUX_SIZEOF_CVMXREGSET)
1832 (PPC_LINUX_SIZEOF_CVSXREGSET, PPC_LINUX_SIZEOF_CPPRREGSET)
1833 (PPC_LINUX_SIZEOF_CDSCRREGSET, PPC_LINUX_SIZEOF_CTARREGSET):
1835 (struct ppc_linux_features) <htm>: New field.
1836 (ppc_linux_no_features): Add initializer for htm field.
1837 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1839 * nat/ppc-linux.h (PPC_FEATURE2_HTM, NT_PPC_TM_CGPR)
1840 (NT_PPC_TM_CFPR, NT_PPC_TM_CVMX, NT_PPC_TM_CVSX)
1841 (NT_PPC_TM_SPR, NT_PPC_TM_CTAR, NT_PPC_TM_CPPR, NT_PPC_TM_CDSCR):
1842 Define if not already defined.
1843 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-htm-vsx32l
1844 and rs6000/powerpc-isa207-htm-vsx64l.
1845 (XMLTOC): Add rs6000/powerpc-isa207-htm-vsx32l.xml and
1846 rs6000/powerpc-isa207-htm-vsx64l.xml.
1847 * features/rs6000/power-htm-spr.xml: New file.
1848 * features/rs6000/power-htm-core.xml: New file.
1849 * features/rs6000/power64-htm-core.xml: New file.
1850 * features/rs6000/power-htm-fpu.xml: New file.
1851 * features/rs6000/power-htm-altivec.xml: New file.
1852 * features/rs6000/power-htm-vsx.xml: New file.
1853 * features/rs6000/power-htm-ppr.xml: New file.
1854 * features/rs6000/power-htm-dscr.xml: New file.
1855 * features/rs6000/power-htm-tar.xml: New file.
1856 * features/rs6000/powerpc-isa207-htm-vsx32l.xml: New file.
1857 * features/rs6000/powerpc-isa207-htm-vsx64l.xml: New file.
1858 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Generate.
1859 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Generate.
1860 * regformats/rs6000/powerpc-isa207-htm-vsx32l.dat: Generate.
1861 * regformats/rs6000/powerpc-isa207-htm-vsx64l.dat: Generate.
1862 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1863 fetch_regset with HTM regsets.
1864 (store_register, store_ppc_registers): Call store_regset with HTM
1866 (ppc_linux_nat_target::read_description): Set htm field in the
1867 features struct if needed.
1868 * ppc-linux-tdep.c: Include
1869 features/rs6000/powerpc-isa207-htm-vsx32l.c and
1870 features/rs6000/powerpc-isa207-htm-vsx64l.c.
1871 (ppc32_regmap_tm_spr, ppc32_regmap_cgpr, ppc64_le_regmap_cgpr)
1872 (ppc64_be_regmap_cgpr, ppc32_regmap_cfpr, ppc32_le_regmap_cvmx)
1873 (ppc32_be_regmap_cvmx, ppc32_regmap_cvsx, ppc32_regmap_cppr)
1874 (ppc32_regmap_cdscr, ppc32_regmap_ctar): New globals.
1875 (ppc32_linux_tm_sprregset, ppc32_linux_cgprregset)
1876 (ppc64_be_linux_cgprregset, ppc64_le_linux_cgprregset)
1877 (ppc32_linux_cfprregset, ppc32_le_linux_cvmxregset)
1878 (ppc32_be_linux_cvmxregset, ppc32_linux_cvsxregset)
1879 (ppc32_linux_cpprregset, ppc32_linux_cdscrregset)
1880 (ppc32_linux_ctarregset): New globals.
1881 (ppc_linux_cgprregset, ppc_linux_cvmxregset): New functions.
1882 (ppc_linux_collect_core_cpgrregset): New function.
1883 (ppc_linux_iterate_over_regset_sections): Call back with the htm
1885 (ppc_linux_core_read_description): Check if the tm spr section is
1886 present and set htm in the features struct.
1887 (_initialize_ppc_linux_tdep): Call
1888 initialize_tdesc_powerpc_isa207_htm_vsx32l and
1889 initialize_tdesc_powerpc_isa207_htm_vsx64l.
1890 * ppc-linux-tdep.h (ppc_linux_cgprregset, ppc_linux_cvmxregset):
1892 (ppc32_linux_tm_sprregset, ppc32_linux_cfprregset)
1893 (ppc32_linux_cvsxregset, ppc32_linux_cpprregset)
1894 (ppc32_linux_cdscrregset, ppc32_linux_ctarregset): Declare.
1895 * ppc-tdep.h (struct gdbarch_tdep) <have_htm_spr, have_htm_core>:
1897 <have_htm_fpu, have_htm_altivec, have_htm_vsx>:
1899 <ppc_cppr_regnum, ppc_cdscr_regnum, ppc_ctar_regnum>: Likewise.
1900 <ppc_cdl0_regnum, ppc_cvsr0_regnum, ppc_cefpr0_regnum>: Likewise.
1901 (enum) <PPC_TFHAR_REGNUM, PPC_TEXASR_REGNUM, PPC_TFIAR_REGNUM>:
1903 <PPC_CR0_REGNUM, PPC_CCR_REGNUM, PPC_CXER_REGNUM>: Likewise.
1904 <PPC_CLR_REGNUM, PPC_CCTR_REGNUM, PPC_CF0_REGNUM>: Likewise.
1905 <PPC_CFPSCR_REGNUM, PPC_CVR0_REGNUM, PPC_CVSCR_REGNUM>: Likewise.
1906 <PPC_CVRSAVE_REGNUM, PPC_CVSR0_UPPER_REGNUM>: Likewise.
1907 <PPC_CPPR_REGNUM, PPC_CDSCR_REGNUM>: Likewise.
1908 <PPC_CTAR_REGNUM>: Likewise.
1909 (PPC_IS_TMSPR_REGNUM, PPC_IS_CKPTGP_REGNUM, PPC_IS_CKPTFP_REGNUM)
1910 (PPC_IS_CKPTVMX_REGNUM, PPC_IS_CKPTVSX_REGNUM): Define.
1911 * rs6000-tdep.c (IS_CDFP_PSEUDOREG, IS_CVSX_PSEUDOREG)
1912 (IS_CEFP_PSEUDOREG): Define.
1913 (rs6000_register_name): Hide the upper halves of checkpointed VSX
1914 registers. Return names for the checkpointed DFP, VSX, and EFP
1916 (rs6000_pseudo_register_type): Remove initial assert and raise an
1917 internal error in the else clause instead. Return types for the
1918 checkpointed DFP, VSX, and EFP pseudo registers.
1919 (dfp_pseudo_register_read, dfp_pseudo_register_write): Handle
1920 checkpointed DFP pseudo registers.
1921 (vsx_pseudo_register_read, vsx_pseudo_register_write): Handle
1922 checkpointed VSX pseudo registers.
1923 (efp_pseudo_register_read, efp_pseudo_register_write): Rename
1924 from efpr_pseudo_register_read and
1925 efpr_pseudo_register_write. Handle checkpointed EFP pseudo
1927 (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
1928 Handle checkpointed DFP, VSX, and EFP registers.
1929 (dfp_ax_pseudo_register_collect, vsx_ax_pseudo_register_collect)
1930 (efp_ax_pseudo_register_collect): New functions.
1931 (rs6000_ax_pseudo_register_collect): Move DFP, VSX and EFP pseudo
1932 register logic to new functions. Handle checkpointed DFP, VSX,
1933 and EFP pseudo registers.
1934 (rs6000_gdbarch_init): Look for and validate the htm features.
1935 Include checkpointed DFP, VSX and EFP pseudo-registers.
1936 * NEWS: Mention access to PPR, DSCR, TAR, EBB/PMU registers and
1939 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1941 * rs6000-tdep.c (rs6000_gdbarch_init): Reject tdescs with vsx but
1942 without altivec or fpu.
1944 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1945 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1947 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
1948 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
1949 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
1950 Define if not already defined.
1951 * features/rs6000/power-ebb.xml: New file.
1952 * features/rs6000/power-linux-pmu.xml: New file.
1953 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
1955 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
1956 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
1957 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
1958 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
1959 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
1960 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1961 fetch_regset with ebb and pmu regsets.
1962 (store_register, store_ppc_registers): Call store_regset with ebb
1964 (ppc_linux_nat_target::read_description): Set isa207 field in the
1965 features struct if ebb and pmu are avaiable.
1966 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
1967 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
1968 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
1970 (ppc_linux_core_read_description): Check if the pmu section is
1971 present and set isa207 in the features struct.
1972 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
1973 (ppc32_linux_pmuregset): Declare.
1974 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
1975 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
1976 <ppc_sier_regnum>: New field.
1977 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
1979 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
1981 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
1982 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
1983 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
1984 ebb and pmu features.
1986 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1987 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1989 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
1990 (tdesc_powerpc_isa207_vsx64l): Declare.
1991 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
1992 (struct ppc_linux_features) <isa207>: New field.
1993 (ppc_linux_no_features): Add initializer for isa207 field.
1994 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1996 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
1997 (NT_PPC_TAR): Define if not already defined.
1998 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
1999 rs6000/powerpc-isa207-vsx64l.
2000 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
2001 rs6000/powerpc-isa207-vsx64l.xml.
2002 * features/rs6000/power-tar.xml: New file.
2003 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
2004 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
2005 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
2006 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
2007 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
2008 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
2009 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
2010 fetch_regset with the TAR regset.
2011 (store_register, store_ppc_registers): Call store_regset with the
2013 (ppc_linux_nat_target::read_description): Set isa207 field in the
2014 features struct if needed.
2015 * ppc-linux-tdep.c: Include
2016 features/rs6000/powerpc-isa207-vsx32l.c and
2017 features/rs6000/powerpc-isa207-vsx64l.c.
2018 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
2019 (ppc_linux_iterate_over_regset_sections): Call back with the tar
2021 (ppc_linux_core_read_description): Check if the tar section is
2022 present and set isa207 in the features struct.
2023 (_initialize_ppc_linux_tdep): Call
2024 initialize_tdesc_powerpc_isa207_vsx32l and
2025 initialize_tdesc_powerpc_isa207_vsx64l.
2026 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
2027 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
2028 (enum) <PPC_TAR_REGNUM>: New enum value.
2029 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
2031 (ppc_process_record_op31): Record changes to TAR.
2033 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2034 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2036 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
2037 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2038 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
2039 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
2040 (struct ppc_linux_features) <ppr_dscr>: New field.
2041 (ppc_linux_no_features): Add initializer for ppr_dscr field.
2042 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
2044 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
2045 Define if not already defined.
2046 * features/Makefile (WHICH): Add
2047 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
2048 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
2049 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2050 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
2051 * features/rs6000/power-dscr.xml: New file.
2052 * features/rs6000/power-ppr.xml: New file.
2053 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
2054 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
2055 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
2056 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
2057 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
2058 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
2059 * ppc-linux-nat.c: Include <sys/uio.h>.
2060 (fetch_regset, store_regset, check_regset): New functions.
2061 (fetch_register, fetch_ppc_registers): Call fetch_regset with
2062 DSCR and PPR regsets.
2063 (store_register, store_ppc_registers): Call store_regset with
2064 DSCR and PPR regsets.
2065 (ppc_linux_get_hwcap2): New function.
2066 (ppc_linux_nat_target::read_description): Call
2067 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
2068 features struct if needed.
2069 * ppc-linux-tdep.c: Include
2070 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
2071 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
2072 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
2073 (ppc32_linux_dscrregset): New globals.
2074 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
2076 (ppc_linux_core_read_description): Check if the ppr and dscr
2077 sections are present and set ppr_dscr in the features struct.
2078 (_initialize_ppc_linux_tdep): Call
2079 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
2080 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
2081 * ppc-linux-tdep.h (ppc32_linux_pprregset)
2082 (ppc32_linux_dscrregset): Declare.
2083 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
2084 <ppc_dscr_regnum>: New field.
2085 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
2086 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
2088 (ppc_process_record_op31): Record changes to PPR and DSCR.
2090 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2092 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
2093 second initializer line for the have_* variables. Initialize
2094 have_fpu to 0 instead of 1.
2096 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2098 * arch/ppc-linux-common.c (ppc_linux_match_description):
2099 Parenthesize tdesc assignements and indent them properly.
2101 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2103 * ppc-linux-nat.c (fetch_register): Change if statement to else
2105 (store_register): Likewise.
2107 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2109 * rs6000-tdep.c: Remove reggroups.h include.
2110 (rs6000_pseudo_register_reggroup_p): Remove.
2111 (rs6000_gdbarch_init): Remove call to
2112 set_tdesc_pseudo_register_reggroup_p.
2114 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2116 * reggroups.c (default_register_reggroup_p): Return true for
2117 decfloat registers and float_reggroup.
2119 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2121 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
2122 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
2123 ppc_linux_collect_vrregset by regcache_collect_regset.
2125 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2127 * linux-tdep.c (linux_collect_regset_section_cb): Use
2128 std::vector<gdb_byte> instead of char * and malloc for buf.
2131 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
2133 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
2134 symtab_start instead of always using language_unknown.
2136 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
2138 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
2139 READ_P parameter, catch and ignore register access errors from
2140 either the old or new MISA location.
2141 (riscv_has_feature): Update call to riscv_read_misa_reg.
2143 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2145 * python/py-function.c (convert_values_to_python): Return
2146 gdbpy_ref<>. Add header comment.
2147 (fnpy_call): Adjust.
2149 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2151 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
2152 (cmdpy_completer_handle_brkchars): Adjust.
2153 (cmdpy_completer): Adjust.
2155 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2157 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
2158 Pass correct regnum to raw_supply_zeroed.
2160 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
2162 * regcache.c (cooked_read_test): Add CSKY to the list of
2163 architectures with a save_reggroup
2165 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
2168 * infrun.c (follow_exec): In the follow_exec_mode_new case,
2169 transfer terminal state from old new new inferior.
2170 * terminal.h (swap_terminal_info): New function.
2171 * inflow.c (swap_terminal_info): New function.
2173 2018-10-23 Tom Tromey <tom@tromey.com>
2175 * record-btrace.c (get_thread_current_frame_id): Rename from
2176 get_thread_current_frame. Return a frame_id.
2177 (record_btrace_start_replaying): Update.
2179 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
2181 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
2184 2018-10-23 Joel Brobecker <brobecker@adacore.com>
2186 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
2187 have_nonsteppable_watchpoint attribute to 1.
2189 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
2191 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
2193 (struct register_alias): Rename to...
2194 (struct riscv_register_alias): ...this, and update comment.
2195 (riscv_register_aliases): Update type, and alias names. Remove
2196 CSR names from this list.
2197 (riscv_register_name): Use riscv_gdb_reg_names for int and float
2198 register names. Add an extra assertion.
2199 (riscv_is_regnum_a_named_csr): New function.
2200 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
2202 2018-10-23 John Darrington <john@darrington.wattle.id.au>
2204 * configure.tgt: Add configuration for s12z.
2205 * s12z-tdep.c: New file.
2206 * NEWS: Mention new target.
2208 2018-10-22 Jim Wilson <jimw@sifive.com>
2210 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
2211 FP reg smaller than FP reg size, and fill with -1 instead of 0.
2213 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
2214 (riscv_register_type): Use them.
2215 (riscv_print_one_register_info): Handle union of floats same as float.
2216 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
2217 riscv_fpreg_q_type fields.
2219 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
2221 * gdbarch.sh (gdbarch_num_cooked_regs): New.
2222 * gdbarch.h: Re-generate.
2223 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
2224 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
2225 * eval.c (evaluate_subexp_standard): Likewise.
2226 * findvar.c (value_of_register): Likewise.
2227 (value_of_register_lazy): Likewise.
2228 (address_from_register): Likewise.
2229 * frame.c (get_frame_register_bytes): Likewise.
2230 * gdbarch-selftests.c (register_to_value_test): Likewise.
2231 * h8300-tdep.c (h8300_register_type): Likewise.
2232 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
2233 (i386_svr4_reg_to_regnum): Likewise.
2234 * infcmd.c (default_print_registers_info): Likewise.
2235 (registers_info): Likewise.
2236 (print_vector_info): Likewise.
2237 (default_print_float_info): Likewise.
2238 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
2239 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
2240 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
2241 (mi_cmd_data_list_changed_registers): Likewise.
2242 (mi_cmd_data_list_register_values): Likewise.
2243 (mi_cmd_data_write_register_values): Likewise.
2244 (mi_cmd_trace_frame_collected): Likewise.
2245 * mips-tdep.c (print_gp_register_row): Likewise.
2246 (mips_print_registers_info): Likewise.
2247 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
2248 * regcache.c (init_regcache_descr): Likewise.
2249 (register_size): Likewise.
2250 (register_dump::dump): Likewise.
2251 (cooked_read_test): Likewise.
2252 (cooked_write_test): Likewise.
2253 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
2254 (rs6000_gdbarch_init): Likewise.
2255 * stabsread.c (stab_reg_to_regnum): Likewise.
2256 * stack.c (info_frame_command): Likewise.
2257 * target-descriptions.c (tdesc_register_name): Likewise.
2258 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
2259 * tui/tui-regs.c (tui_show_register_group): Likewise.
2260 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
2261 (user_reg_map_regnum_to_name): Likewise.
2262 (value_of_user_reg): Likewise.
2263 (maintenance_print_user_registers): Likewise.
2264 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
2265 (xtensa_register_name): Likewise.
2266 (xtensa_register_type): Likewise.
2267 (xtensa_reg_to_regnum): Likewise.
2268 (xtensa_pseudo_register_read): Likewise.
2269 (xtensa_pseudo_register_write): Likewise.
2271 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2273 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
2274 correctly-sized buffer with raw_read.
2275 (amd64_pseudo_register_write): Use correctly-sized buffer for
2278 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2280 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
2281 in add_prefix_cmd of set print type.
2283 2018-10-19 Tom Tromey <tom@tromey.com>
2286 * NEWS: Mention tabset deprecation.
2287 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
2288 (update_tab_width): New function.
2289 (tui_set_tab_width, tui_show_tab_width): New functions.
2290 (tui_set_tab_width_command): Use update_tab_width.
2291 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
2292 Add new "set tui tab-width" command.
2293 * tui/tui-source.c (tui_set_source_content): Update.
2294 * tui/tui-disasm.c (tui_set_disassem_content): Update.
2295 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
2297 (tui_tab_width): Declare.
2298 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
2299 (tui_set_default_tab_len): Remove.
2301 2018-10-19 Tom Tromey <tom@tromey.com>
2303 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
2304 (key_is_backspace, tui_getc): Don't declare.
2305 * tui/tui-io.c (key_is_start_sequence): Now static.
2306 (key_is_end_sequence, key_is_backspace): Remove.
2307 (tui_getc): Now static.
2309 2018-10-19 Tom Tromey <tom@tromey.com>
2311 * symfile.c (reread_symbols): Clear "static_links".
2313 2018-10-19 Alan Hayward <alan.hayward@arm.com>
2315 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
2317 (aarch64_linux_sigframe_init): Extra boundary checks.
2319 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
2321 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
2322 the possibly non-existent tdesc type 'vec128', but the type of raw
2323 register v16 instead.
2325 2018-10-19 Gary Benson <gbenson@redhat.com>
2327 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
2329 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
2332 * cli/cli-dump.c (restore_binary_file): Check if "file" is
2335 2018-10-17 Paul Koning <paul_koning@dell.com>
2337 * charset.c (convert_between_encodings): Fix unsigned overflow.
2339 2018-10-17 John Baldwin <jhb@FreeBSD.org>
2341 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
2342 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
2343 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
2344 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2346 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
2347 and fbsd_info_proc_mappings_header.
2348 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
2349 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2352 2018-10-17 Joel Brobecker <brobecker@adacore.com>
2354 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
2357 2018-10-15 Tom Tromey <tom@tromey.com>
2359 * tui/tui.c (strcat_to_buf): Remove casts.
2360 * tui/tui-winsource.c (tui_show_source_line)
2361 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
2362 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
2363 * tui/tui-windata.c (tui_first_data_item_displayed)
2364 (tui_delete_data_content_windows, tui_erase_data_content)
2365 (tui_display_all_data, tui_display_data_from)
2366 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
2367 * tui/tui-win.c (tui_set_win_height)
2368 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
2370 * tui/tui-win.c (tui_resize_all): Remove casts.
2371 (tui_scroll_backward_command, tui_set_focus)
2372 (tui_set_tab_width_command): Likewise.
2373 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
2374 * tui/tui-regs.c (tui_show_register_group): Remove cast.
2375 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
2376 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
2377 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
2380 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
2382 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
2383 AArch64/ARM maintainer.
2385 2018-10-11 Gary Benson <gbenson@redhat.com>
2387 * interps.h (interp::m_name): Make private and mutable.
2388 * interps.c (interp::~interp): Free m_name.
2390 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2391 Simon Marchi <simark@simark.ca>
2393 * README (`configure' options): Add documentation for new
2394 "--enable-unit-tests" option.
2395 * acinclude.m4: Include "selftest.m4".
2396 * configure: Regenerate.
2397 * configure.ac: Use "GDB_AC_SELFTEST".
2398 * maint.c (maintenance_selftest): Update message informing
2399 that selftests have been disabled.
2400 (maintenance_info_selftests): Likewise.
2401 * selftest.m4: New file.
2403 2018-10-10 Gary Benson <gbenson@redhat.com>
2405 * remote.c (remote_target::remote_send_printf): Add
2406 missing va_end found by Coverity.
2408 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
2410 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
2412 2018-10-09 Tom Tromey <tom@tromey.com>
2414 * configure: Rebuild.
2415 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
2416 * NEWS: Update --enable-ubsan documentation.
2418 2018-10-09 Gary Benson <gbenson@redhat.com>
2420 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
2423 2018-10-08 Tom Tromey <tom@tromey.com>
2425 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
2427 (riscv_fbsd_init_abi): Likewise.
2429 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2430 * valops.c (value_struct_elt_for_reference): Rename local variable
2431 to work around the shadowing a previous local warning.
2433 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2435 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
2436 * NEWS: Mention new FreeBSD/riscv native configuration.
2437 * configure.host: Add riscv*-*-freebsd*.
2438 * configure.nat: Likewise.
2439 * riscv-fbsd-nat.c: New file.
2441 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2443 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
2444 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
2445 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
2446 * NEWS: Mention new FreeBSD/riscv target.
2447 * configure.tgt: Add riscv*-*-freebsd*.
2448 * riscv-fbsd-tdep.c: New file.
2449 * riscv-fbsd-tdep.h: New file.
2451 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2453 * regcache.h (struct regcache_map_entry): Note that this type can
2454 be used with traditional frame caches.
2455 * trad-frame.c (trad_frame_set_reg_regmap): New.
2456 * trad-frame.h (trad_frame_set_reg_regmap): New.
2458 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2461 * valops.c (get_virtual_base_offset): New function.
2462 (value_struct_elt_for_reference): Use it to get virtual base offset
2463 and add it in calculating class member address.
2465 2018-10-08 John Darrington <john@darrington.wattle.id.au>
2467 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
2468 (check_producer): Check if the producer is codewarrior.
2469 (producer_is_codewarrior): New function.
2470 (lnp_state_machine::record_line): Ignore is_stmt flag for records
2471 produced by codewarrior.
2472 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
2474 2018-10-06 Tom Tromey <tom@tromey.com>
2477 * python/py-inferior.c: Add "architecture" entry.
2478 (infpy_architecture): New function.
2480 2018-10-06 Tom Tromey <tom@tromey.com>
2483 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
2484 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
2485 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
2486 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
2488 2018-10-06 Tom Tromey <tom@tromey.com>
2491 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
2492 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
2493 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
2496 2018-10-06 Tom Tromey <tom@tromey.com>
2498 * python/py-breakpoint.c (bppy_get_location): Handle a
2499 bp_breakpoint without a location.
2501 2018-10-06 Tom Tromey <tom@tromey.com>
2503 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
2504 (_RegEx): Reformat help text.
2505 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
2506 (AnyCallerIs, AnyCallerMatches): Reformat help text.
2507 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
2509 * python/lib/gdb/command/xmethods.py (InfoXMethod)
2510 (EnableXMethod, DisableXMethod): Remove help indentation.
2511 Capitalize meta-syntactic variables.
2512 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
2513 (EnableUnwinder, DisableUnwinder): Remove help indentation.
2514 Capitalize meta-syntactic variables.
2515 * python/lib/gdb/command/explore.py (ExploreCommand)
2516 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
2517 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
2518 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
2519 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
2520 Remove help indentation.
2521 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
2522 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
2523 (DisableFrameFilter, SetFrameFilterPriority)
2524 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
2526 2018-10-06 Tom Tromey <tom@tromey.com>
2529 * tui/tui-io.c (gdb_wgetch): New function.
2530 (tui_mld_getc, tui_getc): Use it.
2532 2018-10-05 Tom Tromey <tom@tromey.com>
2534 * sol-thread.c (sol_thread_target::wait): Rename inner
2537 2018-10-04 Tom Tromey <tom@tromey.com>
2539 * configure: Rebuild.
2540 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
2542 2018-10-04 Tom Tromey <tom@tromey.com>
2544 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
2545 declaration of "block".
2547 2018-10-04 Tom Tromey <tom@tromey.com>
2549 * common/filestuff.c (fdwalk): Remove inner declaration of
2552 2018-10-04 Tom Tromey <tom@tromey.com>
2554 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
2555 "structs_addr" and hoist declaration.
2557 2018-10-04 Tom Tromey <tom@tromey.com>
2559 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
2562 2018-10-04 Tom Tromey <tom@tromey.com>
2564 * mdebugread.c (parse_partial_symbols): Use std::string.
2566 2018-10-04 Tom Tromey <tom@tromey.com>
2568 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
2569 * p-valprint.c (pascal_val_print): Split inner "i" variable.
2570 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
2572 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
2574 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
2575 * varobj.c (varobj_update): Rename inner "newobj",
2577 * valprint.c (generic_emit_char): Rename inner "buf".
2578 * valops.c (find_overload_match): Rename inner "temp".
2579 (value_struct_elt_for_reference): Declare "v" in more inner
2581 * v850-tdep.c (v850_push_dummy_call): Rename "len".
2582 * unittests/array-view-selftests.c (run_tests): Rename inner
2584 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
2586 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
2587 "tsv" in more inner scope.
2588 (print_one_static_tracepoint_marker): Rename inner
2590 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
2591 (tic6x_push_dummy_call): Don't redeclare "addr".
2592 * target-float.c: Declare "dto" lower.
2593 * symtab.c (lookup_local_symbol): Rename inner "sym".
2594 (find_pc_sect_line): Rename inner "pc".
2595 * stack.c (print_frame): Don't redeclare "gdbarch".
2596 (return_command): Rename inner "gdbarch".
2597 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
2599 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
2601 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
2602 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
2604 * remote.c (remote_target::update_thread_list): Don't redeclare
2606 (remote_target::process_initial_stop_replies): Rename inner
2608 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
2609 (remote_target::wait_as): Don't redeclare "stop_reply".
2610 (remote_target::get_thread_local_address): Rename inner
2612 (remote_target::get_tib_address): Likewise.
2614 * regcache.c (cooked_read_test): Rename "regnum".
2615 * record-btrace.c (cmd_record_btrace_start): Rename inner
2617 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
2619 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
2621 (ppu2spu_sniffer): Rename inner "buf".
2622 * parse.c (operator_check_standard): Rename inner "type",
2624 * p-valprint.c (pascal_val_print): Introduce new scope for
2625 "low_bound", "high_bound".
2626 * p-exp.y (yylex): Declare "i" in loop header.
2627 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
2628 Lower declaration of "s".
2629 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
2631 (nios2_push_dummy_call): Rename "len".
2632 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
2634 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
2635 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
2636 (linux_xfer_osdata_modules): Likewise.
2637 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
2638 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
2639 (mips_o64_push_dummy_call): Likewise.
2640 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
2642 * mi/mi-main.c (list_available_thread_groups): Rename inner
2644 (mi_cmd_data_read_memory): Rename inner "opts".
2645 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
2647 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
2648 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
2650 (parse_partial_symbols): Rename inner "pst", "p", "name"
2651 * main.c (captured_main_1): Rename inner "i"s.
2652 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
2654 * linux-tdep.c (linux_info_proc): Rename inner "filename".
2655 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
2656 * infrun.c (handle_no_resumed): Don't redeclare "thread".
2657 (handle_signal_stop): Rename inner "gdbarch".
2658 (handle_command): Declare "signum" in loop header.
2659 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
2661 (examine_prologue): Rename inner "sol" and "sof".
2662 (ia64_extract_return_value): Rename inner "val". Declare another
2663 "val" in a more inner scope.
2664 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
2666 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
2668 * findvar.c (default_read_var_value): Don't redeclare "addr".
2669 * f-exp.y (yylex): Declare "i" in loop header.
2670 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
2671 Rename inner "type", "expect_type".
2672 (evaluate_subexp_for_sizeof): Rename inner "pc".
2673 * elfread.c (elf_symfile_read): Rename inner "abfd".
2674 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
2676 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
2677 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
2678 (dwarf_decode_line_header): Rename inner "lh".
2679 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
2680 "offset". Declare "i" in loop header.
2681 (disassemble_dwarf_expression): Rename inner "addr_size".
2682 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
2684 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
2685 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
2686 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
2687 "inner_list_emitter".
2688 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
2689 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
2690 declaration in a block.
2691 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
2692 * cp-valprint.c (cp_print_value_fields): Don't redeclare
2693 "obstack_final_size".
2694 * cp-support.c (inspect_type): Declare "i" in loop header.
2695 * compile/compile.c (compile_instance::insert_symbol_error):
2697 * common/agent.c (agent_run_command): Remove inner "ret"
2699 * coffread.c (coff_symfile_read): Rename inner "name".
2700 (coff_symfile_read): Rename inner "abfd".
2701 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
2702 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
2704 * c-exp.y (lex_one_token): Move "len" declaration lower.
2705 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
2707 (create_exception_master_breakpoint): Likewise. Don't redeclare
2709 (watch_command_1): Declare "mark" later.
2710 (clear_command): Don't shadow "a" or "b".
2711 (delete_command): Rename inner "b".
2712 (delete_trace_command): Likewise.
2713 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
2715 (arm_gdbarch_init): Remove inner "e_flags".
2716 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
2717 "offset" in inner blocks.
2719 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
2721 * dwarf-index-write.c (file_write): Don't write if the vector is
2724 2018-10-05 Tom de Vries <tdevries@suse.de>
2726 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
2727 PyArg_ParseTuple call.
2729 2018-10-05 Tom de Vries <tdevries@suse.de>
2731 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
2732 PyArg_ParseTuple call.
2734 2018-10-04 Joel Brobecker <brobecker@adacore.com>
2736 * psymtab.c (recursively_search_psymtabs): Reformat parameters
2737 to avoid exceeding 80 characters per line limit.
2739 2018-10-04 Tom Tromey <tom@tromey.com>
2741 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2742 (reread_symbols): Update.
2743 * complaints.h (clear_complaints): Remove argument.
2744 * complaints.c (enum complaint_series): Remove.
2745 (series): Remove global.
2746 (complaint_internal): Update.
2747 (clear_complaints): Remove argument.
2749 2018-10-04 Tom Tromey <tom@tromey.com>
2751 * symfile.c (symbol_file_add_with_addrs): Do not print "no
2752 debugging symbols" message if there is a separate debug objfile.
2754 2018-10-04 Tom Tromey <tom@tromey.com>
2757 * symfile.c (symbol_file_add_with_addrs): Update output.
2758 * psymtab.c (require_partial_symbols): Update output.
2760 2018-10-04 Tom Tromey <tom@tromey.com>
2763 * complaints.c: Emit \n.
2765 2018-10-04 Tom Tromey <tom@tromey.com>
2767 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
2768 (separate_debug_file_exists, find_separate_debug_file)
2769 (add_symbol_file_command, reread_symbols, allocate_symtab)
2770 (allocate_compunit_symtab): Use filtered printing, not
2772 * psymtab.c (require_partial_symbols, dump_psymtab)
2773 (allocate_psymtab): Use filtered printing, not unfiltered.
2775 2018-10-04 Tom Tromey <tom@tromey.com>
2777 * complaints.c (complaint_internal): Correctly check complaint
2780 2018-10-04 Tom Tromey <tom@tromey.com>
2782 * complaints.h (struct complaints): Remove declaration.
2783 * complaints.c (clear_complaints): Remove an unused variable.
2785 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2787 * MAINTAINERS (Write After Approval): Add self.
2789 2018-10-03 Tom Tromey <tom@tromey.com>
2791 * guile/scm-value.c (gdbscm_value_to_string): Initialize
2793 * coffread.c (coff_symtab_read): Initialize "newobj".
2795 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
2797 * dwarf2read.c (read_func_scope): Remove struct keyword in
2800 2018-10-03 Tom Tromey <tom@tromey.com>
2802 * README: Mention --enable-ubsan.
2803 * NEWS: Mention --enable-ubsan.
2804 * acinclude.m4: Include sanitize.m4.
2805 * configure: Rebuild.
2806 * configure.ac: Call AM_GDB_UBSAN.
2807 * sanitize.m4: New file.
2809 2018-10-03 Tom Tromey <tom@tromey.com>
2811 * expression.h (enum exp_opcode): Use uint8_t as base type.
2812 * expprint.c (op_name): Handle invalid opcodes.
2814 2018-10-03 Tom Tromey <tom@tromey.com>
2816 * parse.c (prefixify_expression): Add assert.
2817 (parse_exp_in_context_1): Throw exception if the expression is
2820 2018-10-03 Tom Tromey <tom@tromey.com>
2822 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
2824 2018-10-03 Tom Tromey <tom@tromey.com>
2826 * c-exp.y (parse_number): Work in unsigned. Remove casts.
2828 2018-10-03 Tom Tromey <tom@tromey.com>
2830 * dwarf2read.c (read_subrange_type): Make "negative_mask"
2833 2018-10-03 Tom Tromey <tom@tromey.com>
2835 * findvar.c (extract_integer): Do work in an unsigned type.
2837 2018-10-03 Tom Tromey <tom@tromey.com>
2839 * common/enum-flags.h (enum_flags::operator~): Add static assert.
2840 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
2842 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
2843 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
2845 * c-lang.h (enum c_string_type_values): Use unsigned as base
2847 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
2849 2018-10-03 Tom Tromey <tom@tromey.com>
2851 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
2852 <~dwarf2_frame_state_reg_info>: Update.
2853 <dwarf2_frame_state_reg_info>: Update.
2854 <alloc_regs>: Add assertion. Update.
2855 <reg>: Now a std::vector.
2858 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2859 (execute_cfa_program_test, dwarf2_frame_cache): Update.
2861 2018-10-03 Tom Tromey <tom@tromey.com>
2863 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
2865 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2867 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
2869 2018-10-02 Tom Tromey <tom@tromey.com>
2871 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
2873 2018-10-02 John Darrington <john@darrington.wattle.id.au>
2875 * NEWS: Mention changed commands.
2876 * ser-uds.c: New file.
2877 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
2878 * configure: Regenerate.
2879 * Makefile.in: Add new file.
2880 * serial.c (serial_open): Check if filename is a socket
2881 and lookup the appropriate interface accordingly.
2883 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2885 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
2887 (AARCH64_EXTRA_MAGIC): Likewise.
2888 (AARCH64_FPSIMD_MAGIC): Likewise.
2889 (AARCH64_SVE_MAGIC): Likewise.
2890 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
2891 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
2892 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
2893 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
2894 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
2895 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
2896 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
2897 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
2898 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
2899 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
2900 (read_aarch64_ctx): Add function.
2901 (aarch64_linux_sigframe_init): Detect FP registers.
2903 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2905 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
2906 (AARCH64_D0_REGNUM): Likewise.
2907 (AARCH64_S0_REGNUM): Likewise.
2908 (AARCH64_H0_REGNUM): Likewise.
2909 (AARCH64_B0_REGNUM): Likewise.
2910 (AARCH64_SVE_V0_REGNUM): Likewise.
2911 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
2912 (AARCH64_D0_REGNUM): Likewise.
2913 (AARCH64_S0_REGNUM): Likewise.
2914 (AARCH64_H0_REGNUM): Likewise.
2915 (AARCH64_B0_REGNUM): Likewise.
2916 (AARCH64_SVE_V0_REGNUM): Likewise.
2918 2018-10-01 Gary Benson <gbenson@redhat.com>
2920 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
2921 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
2922 prfpregset_t instead of gdb_prfpregset_t.
2923 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
2924 * configure, config.in: Rebuild.
2926 2018-10-01 Gary Benson <gbenson@redhat.com>
2928 * common/gdb_proc_service.h: New file, factored out from...
2929 * gdb_proc_service.h: Moved common code to the above file.
2930 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
2932 2018-10-01 Gary Benson <gbenson@redhat.com>
2934 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
2935 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
2937 2018-10-01 Gary Benson <gbenson@redhat.com>
2939 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
2940 (AC_CHECK_HEADERS): Check for linux/elf.h.
2941 * configure, config.in: Rebuild.
2942 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
2943 doesn't define elf_fpregset_t.
2945 2018-10-01 Gary Benson <gbenson@redhat.com>
2947 * gdb_proc_service.h: Whitespace change.
2949 2018-10-01 Tom Tromey <tom@tromey.com>
2951 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
2952 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
2953 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
2955 2018-10-01 Tom Tromey <tom@tromey.com>
2957 * README: Minor change.
2959 2018-09-30 Pedro Alves <palves@redhat.com>
2961 * darwin-nat-info.c (darwin_debug_regions_recurse)
2962 (info_mach_exceptions_command): Remove unused local variables.
2963 * darwin-nat.c (darwin_decode_notify_message)
2964 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
2965 (darwin_stop_inferior, darwin_setup_exceptions)
2966 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
2967 (darwin_nat_target::attach, darwin_nat_target::detach)
2968 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
2970 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
2973 2018-09-29 Tom Tromey <tom@tromey.com>
2975 * README: Remove some leftover text.
2977 2018-09-29 Tom Tromey <tom@tromey.com>
2979 * PROBLEMS: Rewrite.
2982 2018-09-28 John Baldwin <jhb@FreeBSD.org>
2984 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
2985 case with explicit breakpoint kind.
2986 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
2987 'additional_info' and related logic.
2988 (riscv_debug_breakpoints): New variable.
2989 (riscv_breakpoint_kind_from_pc): Use the length of the existing
2990 instruction to determine the breakpoint kind.
2991 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
2992 flag. Update description of 'set/show riscv
2993 use-compressed-breakpoints' flag.
2995 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
2997 (NEWS): Mention changes to frame related commands.
2998 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
2999 (add_prefix_cmd_suppress_notification): New function.
3000 (add_com_suppress_notification): Call
3001 add_cmd_suppress_notification.
3002 * command.h (add_cmd_suppress_notification): Declare.
3003 (add_prefix_cmd_suppress_notification): Declare.
3004 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
3005 (parse_frame_specification): Moved from stack.c, with
3006 simplification to handle a single argument.
3007 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
3008 switch to the selected frame. Add a header comment.
3009 * stack.c: Remove 'safe-ctype.h' include.
3010 (find_frame_for_function): Add declaration.
3011 (find_frame_for_address): New function.
3012 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
3013 (frame_selection_by_function_completer): New function.
3014 (info_frame_command): Rename to...
3015 (info_frame_command_core): ...this, and update parameter types.
3016 (select_frame_command): Rename to...
3017 (select_frame_command_core): ...this, and update parameter types.
3018 (frame_command): Rename to...
3019 (frame_command_core): ...this, and update parameter types.
3020 (class frame_command_helper): New class to wrap implementations of
3021 frame related sub-commands.
3022 (frame_apply_cmd_list): New static global.
3023 (frame_cmd_list): Make static.
3024 (select_frame_cmd_list): New global for sub-commands.
3025 (info_frame_cmd_list): New global for sub-commands.
3026 (_initialize_stack): Register sub-commands for 'frame',
3027 'select-frame', and 'info frame'. Update 'frame apply' commands
3028 to use frame_apply_cmd_list. Move function local static
3029 frame_apply_list to file static frame_apply_cmd_list for
3031 * stack.h (select_frame_command): Delete declarationn.
3032 (select_frame_for_mi): Declare new function.
3034 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
3036 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
3037 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
3040 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
3042 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
3044 2018-09-26 Tom Tromey <tom@tromey.com>
3046 * valops.c (auto_abandon): Remove dead code.
3048 2018-09-26 Tom Tromey <tom@tromey.com>
3050 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
3052 2018-09-24 Tom Tromey <tom@tromey.com>
3054 * common/pathstuff.c (get_standard_cache_dir): Make
3055 "xdg_cache_home" and "home" const.
3056 * top.c (init_history): Make "tmpenv" const.
3057 * main.c (get_init_files): Make "homedir" const.
3059 2018-09-23 Tom Tromey <tom@tromey.com>
3062 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
3064 2018-09-23 Tom Tromey <tom@tromey.com>
3066 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
3067 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
3068 * python/python-internal.h (gdbpy_handle_exception): Declare.
3069 * python/py-utils.c (gdbpy_handle_exception): New function.
3071 2018-09-23 Tom Tromey <tom@tromey.com>
3074 * python/py-type.c (typy_template_argument): Check for negative
3077 2018-09-23 Tom Tromey <tom@tromey.com>
3080 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
3082 2018-09-23 Tom Tromey <tom@tromey.com>
3085 * python/py-value.c (valpy_int): Allow conversion from pointer
3088 2018-09-23 Tom Tromey <tom@tromey.com>
3091 * python/py-value.c (valpy_int): Respect type sign.
3093 2018-09-23 Tom Tromey <tom@tromey.com>
3096 * python/py-value.c (valpy_float): Allow conversions from int or
3098 (valpy_int, valpy_long): Allow conversions from float.
3100 2018-09-23 Tom Tromey <tom@tromey.com>
3102 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
3103 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
3105 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3107 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
3109 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
3111 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
3113 * windows-nat.c (windows_nat_target::wait): Remove a spurious
3114 target_terminal::ours().
3116 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
3118 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
3121 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
3123 * breakpoint.c (update_inserted_breakpoint_locations): Remove
3124 redundant condition.
3126 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3128 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
3130 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
3131 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
3132 * sol-thread.c (ps_pdmodel): Don't guard definition.
3134 * procfs.c: Fix formatting.
3136 * procfs.c (sysset_t_alloc): Remove.
3137 (create_procinfo): Use XNEW instead of sysset_t_alloc.
3138 (procfs_debug_inferior): Likewise.
3139 (procfs_set_exec_trap): Likewise.
3140 (proc_set_traced_sysentry): Don't allocate argp dynamically.
3141 (proc_set_traced_sysexit): Likewise.
3143 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
3144 (dead_procinfo): Likewise.
3145 (proc_warn): Likewise.
3146 (proc_error): Likewise.
3147 (proc_get_LDT_entry): Likewise.
3148 (do_attach): Likewise.
3149 (procfs_target::pid_to_str): Likewise.
3150 (iterate_over_mappings): Likewise.
3152 * procfs.c (create_procinfo): Fix ARI warning.
3153 (proc_get_status): Likewise.
3154 (proc_stop_process): Likewise.
3155 (proc_run_process): Likewise.
3156 (proc_kill): Likewise.
3157 (proc_get_LDT_entry): Likewise.
3158 (procfs_find_LDT_entry): Likewise.
3159 (proc_update_threads): Likewise.
3160 (proc_iterate_over_threads): Likewise.
3161 (do_attach): Likewise.
3162 (procfs_xfer_memory): Likewise.
3163 (invalidate_cache): Likewise.
3164 (procfs_target::resume): Likewise.
3165 (procfs_init_inferior): Likewise.
3166 (procfs_set_exec_trap): Likewise.
3167 (procfs_target::thread_alive): Likewise.
3168 (procfs_target::pid_to_exec_file): Likewise.
3169 (iterate_over_mappings): Likewise.
3170 (procfs_target::make_corefile_notes): Likewise.
3171 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
3173 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
3174 (procfs_find_LDT_entry): Likewise.
3175 * sol-thread.c (ps_lgetLDT): Likewise.
3177 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3180 * procfs.c (procfs_target): Declare pid_to_exec_file.
3181 (procfs_target::pid_to_exec_file): New.
3183 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3185 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
3187 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
3188 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
3190 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3192 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
3193 (supply_fpregset, fill_fpregset): Move ...
3194 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
3195 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
3196 Remove references to ioctl-based procfs.
3197 Include <sys/reg.h>.
3198 Remove PR_MODEL_NATIVE guards.
3199 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
3200 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
3202 2018-09-19 Xavier Roirand <roirand@adacore.com>
3205 * solib-darwin.c (darwin_get_dyld_bfd): New function.
3206 (darwin_solib_get_all_image_info_addr_at_init): Update call.
3207 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
3209 2018-09-19 John Baldwin <jhb@FreeBSD.org>
3211 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
3212 (fbsd_print_sockaddr_in6): Likewise.
3214 2018-09-19 Richard Bunt <richard.bunt@arm.com>
3215 Chris January <chris.january@arm.com>
3217 * eval.c (skip_undetermined_arglist): Skip argument list helper.
3218 (evaluate_subexp_standard): Return a dummy type when
3219 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
3220 OP_F77_UNDETERMINED_ARGLIST case.
3221 * expression.h (enum noside): Update comment.
3223 2018-09-19 George Vasick <george.vasick@oracle.com>
3225 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
3227 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
3228 April Chin <april.chin@oracle.com>
3229 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3231 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
3233 (create_procinfo): Print pids in /proc without leading zeros.
3235 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
3237 * nios2-tdep.c (nios2_gcc_target_options): New.
3238 (nios2_gdb_arch_init): Install new hook.
3240 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
3242 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
3244 * update-gnulib.sh: Apply patch.
3245 * configure: Re-generate.
3247 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3249 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
3250 description. Make "info proc" command descriptions more
3253 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3255 * NEWS: Mention 'info proc files' command.
3257 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3259 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
3260 descriptors for IP_FILES and IP_ALL.
3262 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3264 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
3265 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
3266 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
3267 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
3268 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
3269 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
3270 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
3271 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
3272 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
3273 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
3274 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
3275 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
3276 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
3277 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
3278 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
3279 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
3280 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
3281 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
3282 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
3283 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
3284 (struct fbsd_sockaddr_un): New types.
3285 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
3286 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
3287 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
3288 (fbsd_core_info_proc_files): New functions.
3289 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
3291 * fbsd-tdep.h (fbsd_info_proc_files_header)
3292 (fbsd_info_proc_files_entry): New.
3294 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3296 * defs.h (enum info_proc_what) [IP_FILES]: New value.
3297 * infcmd.c (info_proc_cmd_files): New function.
3298 (_initialize_infcmd): Register 'info proc files' command.
3300 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3302 * gnulib/aclocal-m4-deps.mk: Re-generate.
3303 * gnulib/aclocal.m4: Re-generate.
3304 * gnulib/config.in: Re-generate.
3305 * gnulib/configure: Re-generate.
3306 * gnulib/import/Makefile.am: Re-generate.
3307 * gnulib/import/Makefile.in: Re-generate.
3308 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3309 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3310 * gnulib/import/arpa_inet.in.h: New file.
3311 * gnulib/import/inet_ntop.c: New file.
3312 * gnulib/import/m4/arpa_inet_h.m4: New file.
3313 * gnulib/import/m4/inet_ntop.m4: New file.
3314 * gnulib/import/m4/netinet_in_h.m4: New file.
3315 * gnulib/import/m4/socklen.m4: New file.
3316 * gnulib/import/m4/sockpfaf.m4: New file.
3317 * gnulib/import/m4/stdalign.m4: New file.
3318 * gnulib/import/m4/sys_uio_h.m4: New file.
3319 * gnulib/import/netinet_in.in.h: New file.
3320 * gnulib/import/stdalign.in.h: New file.
3321 * gnulib/import/sys_socket.c: New file.
3322 * gnulib/import/sys_socket.in.h: New file.
3323 * gnulib/import/sys_uio.in.h: New file.
3324 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
3327 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3329 * gnulib/aclocal-m4-deps.mk: New file.
3330 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
3333 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3335 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
3338 2018-09-18 Tom Tromey <tom@tromey.com>
3340 * compile/compile-object-load.c (struct
3341 link_hash_table_cleanup_data): Add constructor and destructor.
3342 Use DISABLE_COPY_AND_ASSIGN.
3343 (~link_hash_table_cleanup_data): Rename from
3344 link_hash_table_free. Now a destructor.
3345 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
3347 2018-09-18 Tom Tromey <tom@tromey.com>
3349 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3350 * compile/compile-object-load.c (struct munmap_list): Move to
3352 (munmap_list::add): Rename from munmap_list_add; rewrite.
3353 (munmap_list::~munmap_list): Rename from munmap_list_free.
3354 (munmap_listp_free_cleanup): Remove.
3355 (compile_object_load): Update.
3356 * compile/compile-object-load.h (struct munmap_list): Move from
3357 compile-object-load.c. Rewrite.
3359 2018-09-18 Alan Hayward <alan.hayward@arm.com>
3361 * aarch64-tdep.c (pass_in_v): Use register size.
3362 (aarch64_extract_return_value): Likewise.
3363 (aarch64_store_return_value): Likewise.
3365 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3367 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
3370 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3372 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
3373 Fix short help line.
3375 2018-09-17 Tom Tromey <tom@tromey.com>
3378 * configure: Rebuild.
3379 * configure.ac: Conditionally use -DNDEBUG for Python.
3381 2018-09-17 Tom Tromey <tom@tromey.com>
3383 * configure: Rebuild.
3384 * configure.ac: Use gmp as a library dependency when checking for
3387 2018-09-17 Pedro Alves <palves@redhat.com>
3389 * python/py-inferior.c (find_inferior_object): Delete.
3391 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
3393 * compile/compile-cplus-types.c
3394 (compile_cplus_instance::enter_scope): Don't use new_scope after
3397 2018-09-17 Tom Tromey <tom@tromey.com>
3399 * common/pathstuff.c (get_standard_cache_dir): Use
3400 ~/Library/Caches on macOS.
3401 * common/pathstuff.h (get_standard_cache_dir): Update comment.
3403 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
3406 * breakpoint.c (commands_cmd_element): New.
3407 (_initialize_breakpoint): Assign commands_cmd_element.
3408 * breakpoint.h (commands_cmd_element): New.
3409 * cli/cli-script.c (while_cmd_element, if_command,
3410 define_cmd_element): New.
3411 (command_name_equals): Remove.
3412 (process_next_line): Compare commands by pointer, not by name.
3413 (_initialize_cli_script): Assign the various cmd_list_element
3415 * compile/compile.c (compile_cmd_element): New.
3416 (_initialize_compile): Assign compile_cmd_element.
3417 * compile/compile.h (compile_cmd_element): New.
3418 * guile/guile.c (guile_cmd_element): New.
3419 (install_gdb_commands): Assign guile_cmd_element.
3420 * guile/guile.h (guile_cmd_element): New.
3421 * python/python.c (python_cmd_element): New.
3422 (_initialize_python): Assign python_cmd_element.
3423 * python/python.h (python_cmd_element): New.
3424 * tracepoint.c (while_stepping_cmd_element): New.
3425 (_initialize_tracepoint): Assign while_stepping_cmd_element.
3426 * tracepoint.h (while_stepping_cmd_element): New.
3428 2018-09-17 Tom Tromey <tom@tromey.com>
3430 * infrun.c (save_infcall_suspend_state): Return
3431 infcall_suspend_state_up.
3432 (save_infcall_control_state): Return infcall_control_state_up.
3433 * inferior.h (save_infcall_suspend_state)
3434 (save_infcall_control_state): Declare later. Return unique
3437 2018-09-17 Tom Tromey <tom@tromey.com>
3439 * infrun.c (struct stop_context): Declare constructor,
3440 destructor, "changed" method.
3441 (stop_context::stop_context): Rename from save_stop_context.
3442 (stop_context::~stop_context): Rename from
3443 release_stop_context_cleanup.
3444 (normal_stop): Update.
3445 (stop_context::changed): Rename from stop_context_changed. Return
3448 2018-09-17 Tom Tromey <tom@tromey.com>
3450 * inferior.h (struct infcall_suspend_state_deleter): New.
3451 (infcall_suspend_state_up): New typedef.
3452 (struct infcall_control_state_deleter): New.
3453 (infcall_control_state_up): New typedef.
3454 (make_cleanup_restore_infcall_suspend_state)
3455 (make_cleanup_restore_infcall_control_state): Don't declare.
3456 * infcall.c (call_function_by_hand_dummy): Update.
3457 * infrun.c (do_restore_infcall_suspend_state_cleanup)
3458 (make_cleanup_restore_infcall_suspend_state): Remove.
3459 (do_restore_infcall_control_state_cleanup)
3460 (make_cleanup_restore_infcall_control_state): Remove.
3462 2018-09-17 Tom Tromey <tom@tromey.com>
3464 * gdbthread.h (struct thread_control_state): Add initializer.
3465 (class thread_info) <control>: Remove initializer.
3466 * inferior.h (struct inferior_control_state): Add initializer.
3467 (class inferior) <control>: Remove initializer.
3468 (exit_inferior_1): Update.
3469 * infrun.c (struct infcall_control_state): Add constructors.
3470 (save_infcall_control_state): Use new.
3471 (restore_infcall_control_state, discard_infcall_control_state):
3474 2018-09-17 Tom Tromey <tom@tromey.com>
3476 * infrun.c (struct infcall_suspend_state) <registers>: Now a
3478 <siginfo_data>: Now a unique_xmalloc_ptr.
3479 (save_infcall_suspend_state, restore_infcall_suspend_state)
3480 (discard_infcall_suspend_state)
3481 (get_infcall_suspend_state_regcache): Update.
3483 2018-09-17 Tom Tromey <tom@tromey.com>
3485 * gdbthread.h (struct thread_suspend_state): Add initializers.
3486 (class thread_info) <suspend>: Remove initializer.
3487 * infrun.c (struct infcall_suspend_state): Add initializers.
3488 (save_infcall_suspend_state): Use new.
3489 (discard_infcall_suspend_state): Use delete.
3491 2018-09-16 Tom Tromey <tom@tromey.com>
3493 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
3495 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
3496 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
3497 (py_varobj_iter_new): Likewise.
3498 (py_varobj_get_iterator): Use gdbpy_ref.
3500 2018-09-16 Tom Tromey <tom@tromey.com>
3502 * python/py-threadevent.c (py_get_event_thread): Simplify.
3503 * python/py-inferior.c (infpy_thread_from_thread_handle):
3504 Return immediately after calling thread_to_thread_object. Use
3506 (thread_to_thread_object): Set the exception on a NULL return.
3508 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3510 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
3512 2018-09-16 Tom Tromey <tom@tromey.com>
3514 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
3517 2018-09-16 Tom Tromey <tom@tromey.com>
3519 * python/python-internal.h (thread_to_thread_object): Change
3521 * python/py-inferior.c (thread_to_thread_object): Return a new
3523 (infpy_thread_from_thread_handle): Update.
3524 * python/py-infthread.c (gdbpy_selected_thread): Update.
3525 * python/py-stopevent.c (create_stop_event_object): Update.
3526 * python/py-threadevent.c (py_get_event_thread): Return a new
3528 (py_get_event_thread): Update.
3529 * python/py-event.h (py_get_event_thread): Change return type.
3530 * python/py-continueevent.c (create_continue_event_object):
3533 2018-09-16 Tom Tromey <tom@tromey.com>
3535 * python/py-progspace.c (pspy_get_objfiles): Update.
3536 * python/python-internal.h (objfile_to_objfile_object): Change
3538 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3540 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3542 * python/python.c (gdbpy_get_current_objfile): Update.
3543 (gdbpy_objfiles): Update.
3544 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
3546 (objfile_to_objfile_object): Return a new reference.
3547 * python/py-symtab.c (stpy_get_objfile): Update.
3548 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
3551 2018-09-16 Tom Tromey <tom@tromey.com>
3553 * python/py-inferior.c (infpy_get_progspace): Update.
3554 * python/python-internal.h (pspace_to_pspace_object): Change
3556 * python/py-newobjfileevent.c
3557 (create_clear_objfiles_event_object): Update.
3558 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3560 * python/python.c (gdbpy_get_current_progspace): Update.
3561 (gdbpy_progspaces): Update.
3562 * python/py-progspace.c (pspace_to_pspace_object): Return a new
3564 * python/py-objfile.c (objfpy_get_progspace): Update.
3565 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
3568 2018-09-16 Tom Tromey <tom@tromey.com>
3570 * python/lib/gdb/__init__.py (current_progspace, objfiles)
3571 (solib_name, block_for_pc, find_pc_line): New functions.
3572 (execute_unwinders): Update.
3573 * python/py-block.c (gdbpy_block_for_pc): Remove.
3574 * python/py-inferior.c (infpy_get_progspace): New function.
3575 (inferior_object_getset) <progspace>: Add.
3576 * python/py-progspace.c (pspy_objfiles): Rewrite.
3577 (pspy_solib_name, pspy_block_for_pc)
3578 (pspy_find_pc_line, pspy_is_valid): New functions.
3579 (progspace_object_methods): Add entries for solib_name,
3580 block_for_pc, find_pc_line, is_valid.
3581 * python/python-internal.h (gdbpy_block_for_pc)
3582 (build_objfiles_list): Don't declare.
3583 * python/python.c: Don't include solib.h.
3584 (gdbpy_solib_name, gdbpy_find_pc_line)
3585 (gdbpy_get_current_progspace, build_objfiles_list)
3586 (gdbpy_objfiles): Remove.
3587 (GdbMethods) <current_progspace, objfiles, block_for_pc,
3588 solib_name, find_pc_line>: Remove entries.
3590 2018-09-16 Tom Tromey <tom@tromey.com>
3592 * top.c (new_ui_command): Use GNU style for metasyntactic
3594 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
3596 * maint.c (maintenance_translate_address): Remove "<>" around
3598 * interps.c (interpreter_exec_cmd): Use GNU style for
3599 metasyntactic variables.
3600 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
3601 metasyntactic variables.
3602 * tracepoint.c (tfind_range_command): Use GNU style for
3603 metasyntactic variables.
3604 (tfind_outside_command): Likewise.
3605 (_initialize_tracepoint): Likewise.
3606 * remote.c (extended_remote_target::create_inferior): Use GNU
3607 style for metasyntactic variables.
3608 * sparc64-tdep.c (adi_examine_command): Use GNU style for
3609 metasyntactic variables.
3610 (adi_assign_command): Likewise.
3612 2018-09-16 Tom Tromey <tom@tromey.com>
3614 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
3615 metasyntactic variables. Print message if no disassembler options
3618 2018-09-15 Tom Tromey <tom@tromey.com>
3620 * infcmd.c (get_inferior_args): Return const char *.
3621 * inferior.h (get_inferior_args): Return type now const.
3622 * linux-tdep.c (linux_fill_prpsinfo): Update.
3623 * procfs.c (procfs_target::make_corefile_notes): Update.
3625 2018-09-07 Tom Tromey <tom@tromey.com>
3627 * python/python.c (execute_gdb_command): Call bpstat_do_actions
3630 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
3632 * nios2-tdep.c (nios2_type_align): New.
3633 (nios2_gdb_arch_init): Install type_align hook.
3635 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3637 * eval.c (fake_method::fake_method): Call xzalloc directly for a
3638 type that is neither object file owned, nor gdbarch owned.
3639 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
3640 gdbarch is non-NULL.
3641 (alloc_type_instance): Allocate non-objfile owned types on the
3643 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
3644 using TYPE_ALLOC to ensure memory is allocated on the correct
3646 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
3647 obstack, or the gdbarch obstack.
3648 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
3650 2018-09-14 Tom Tromey <tom@tromey.com>
3652 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
3655 2018-09-14 Tom Tromey <tom@tromey.com>
3657 * nat/fork-inferior.c (get_startup_shell): Remove "static".
3659 2018-09-13 Tom Tromey <tom@tromey.com>
3661 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
3664 2018-09-13 Tom Tromey <tom@tromey.com>
3666 * exec.c (try_open_exec_file): Use std::string.
3668 2018-09-13 Tom Tromey <tom@tromey.com>
3670 * utils.h (gdb_bfd_errmsg): Return std::string.
3671 * exec.c (exec_file_attach): Update.
3672 * compile/compile-object-load.c (compile_object_load): Update.
3673 * utils.c (gdb_bfd_errmsg): Return std::string.
3675 2018-09-13 Tom Tromey <tom@tromey.com>
3677 * procfs.c (struct procinfo_deleter): New.
3678 (procinfo_up): New typedef.
3679 (do_destroy_procinfo_cleanup): Remove.
3680 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
3682 2018-09-13 Tom Tromey <tom@tromey.com>
3684 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
3686 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3687 2018-09-13 Tom Tromey <tom@tromey.com>
3689 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
3690 (pspy_get_objfiles): New function.
3691 (progspace_object_methods): New.
3692 (pspace_object_type): Add tp_methods callback.
3693 * python/python-internal.h (build_objfiles_list): New
3695 * python/python.c (build_objfiles_list): New function.
3696 (gdbpy_objfiles): Implement using build_objfiles_list.
3697 * NEWS: Mention the Progspace.objfiles method.
3699 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3701 * python/py-inferior.c (infpy_get_progspace): New function.
3702 (inferior_object_getset): Add progspace property.
3703 * NEWS: Mention the new property.
3705 2018-09-13 Tom Tromey <tom@tromey.com>
3708 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
3710 2018-09-13 Tom Tromey <tom@tromey.com>
3713 * rust-lang.c (rust_enum_variant): Now static.
3714 (rust_empty_enum_p): New function.
3715 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
3718 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3720 * python/py-inferior.c (infpy_repr): New.
3721 (inferior_object_type): Register infpy_repr.
3722 * python/py-objfile.c (objfpy_repr): New.
3723 (objfile_object_type): Register objfpy_repr.
3725 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3727 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
3729 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3731 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
3734 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
3736 * common/common-utils.c: Don't include '<sys/stat.h>'.
3737 (is_regular_file): Move to...
3738 * common/filestuff.c (is_regular_file): ... here.
3739 * common/common-utils.h (is_regular_file): Move to...
3740 * common/filestuff.h (is_regular_file): ... here.
3742 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
3744 * skip.c (debug_skip): New variable.
3745 (skiplist_entry::do_skip_file_p): Add debug output.
3746 (skiplist_entry::do_skip_gfile_p): Likewise.
3747 (skiplist_entry::skip_function_p): Likewise.
3748 (_initialize_step_skip): Create debug command.
3749 * NEWS: Mention set/show debug skip.
3751 2018-09-11 Xavier Roirand <roirand@adacore.com>
3753 * darwin-nat.c (should_disable_startup_with_shell):
3755 (darwin_nat_target::create_inferior): Add call.
3757 2018-09-11 Xavier Roirand <roirand@adacore.com>
3759 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
3760 inf_port, msg_state>: Initialize.
3761 (struct darwin_thread_info) <signaled, single_step>: Change
3762 type and initialize.
3763 (struct darwin_thread_info) <event>: Initialize.
3765 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3769 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
3772 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3775 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
3779 * gnulib/aclocal.m4: Regenerate.
3780 * gnulib/config.in: Regenerate.
3781 * gnulib/configure: Regenerate.
3782 * gnulib/import/Makefile.am: Update.
3783 * gnulib/import/Makefile.in: Update.
3784 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
3785 * gnulib/import/_Noreturn.h: ... this.
3786 * gnulib/import/alloca.in.h: Update.
3787 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
3788 * gnulib/import/arg-nonnull.h: ... this.
3789 * gnulib/import/assure.h: Update.
3790 * gnulib/import/at-func.c: Update.
3791 * gnulib/import/basename-lgpl.c: Update.
3792 * gnulib/import/extra/snippet/c++defs.h: Rename to...
3793 * gnulib/import/c++defs.h: ... this.
3794 * gnulib/import/canonicalize-lgpl.c: Update.
3795 * gnulib/import/cdefs.h: Update.
3796 * gnulib/import/chdir-long.c: Update.
3797 * gnulib/import/chdir-long.h: Update.
3798 * gnulib/import/cloexec.c: Update.
3799 * gnulib/import/cloexec.h: Update.
3800 * gnulib/import/close.c: Update.
3801 * gnulib/import/closedir.c: Update.
3802 * gnulib/import/config.charset: Update.
3803 * gnulib/import/dirent-private.h: Update.
3804 * gnulib/import/dirent.in.h: Update.
3805 * gnulib/import/dirfd.c: Update.
3806 * gnulib/import/dirname-lgpl.c: Update.
3807 * gnulib/import/dirname.h: Update.
3808 * gnulib/import/dosname.h: Update.
3809 * gnulib/import/dup-safer-flag.c: Update.
3810 * gnulib/import/dup-safer.c: Update.
3811 * gnulib/import/dup.c: Update.
3812 * gnulib/import/dup2.c: Update.
3813 * gnulib/import/errno.in.h: Update.
3814 * gnulib/import/error.c: Update.
3815 * gnulib/import/error.h: Update.
3816 * gnulib/import/exitfail.c: Update.
3817 * gnulib/import/exitfail.h: Update.
3818 * gnulib/import/extra/update-copyright: Update.
3819 * gnulib/import/fchdir.c: Update.
3820 * gnulib/import/fcntl.c: Update.
3821 * gnulib/import/fcntl.in.h: Update.
3822 * gnulib/import/fd-hook.c: Update.
3823 * gnulib/import/fd-hook.h: Update.
3824 * gnulib/import/fd-safer-flag.c: Update.
3825 * gnulib/import/fd-safer.c: Update.
3826 * gnulib/import/fdopendir.c: Update.
3827 * gnulib/import/filename.h: Update.
3828 * gnulib/import/filenamecat-lgpl.c: Update.
3829 * gnulib/import/filenamecat.h: Update.
3830 * gnulib/import/flexmember.h: Update.
3831 * gnulib/import/float+.h: Update.
3832 * gnulib/import/float.c: Update.
3833 * gnulib/import/float.in.h: Update.
3834 * gnulib/import/fnmatch.c: Update.
3835 * gnulib/import/fnmatch.in.h: Update.
3836 * gnulib/import/fnmatch_loop.c: Update.
3837 * gnulib/import/fpucw.h: Update.
3838 * gnulib/import/frexp.c: Update.
3839 * gnulib/import/frexpl.c: Update.
3840 * gnulib/import/fstat.c: Update.
3841 * gnulib/import/fstatat.c: Update.
3842 * gnulib/import/getcwd-lgpl.c: Update.
3843 * gnulib/import/getcwd.c: Update.
3844 * gnulib/import/getdtablesize.c: Update.
3845 * gnulib/import/getlogin_r.c: Update.
3846 * gnulib/import/getprogname.c: Update.
3847 * gnulib/import/getprogname.h: Update.
3848 * gnulib/import/gettext.h: Update.
3849 * gnulib/import/gettimeofday.c: Update.
3850 * gnulib/import/glob-libc.h: Update.
3851 * gnulib/import/glob.c: Update.
3852 * gnulib/import/glob.in.h: Update.
3853 * gnulib/import/glob_internal.h: Update.
3854 * gnulib/import/glob_pattern_p.c: Update.
3855 * gnulib/import/globfree.c: Update.
3856 * gnulib/import/hard-locale.c: Update.
3857 * gnulib/import/hard-locale.h: Update.
3858 * gnulib/import/intprops.h: Update.
3859 * gnulib/import/inttypes.in.h: Update.
3860 * gnulib/import/isnan.c: Update.
3861 * gnulib/import/isnand-nolibm.h: Update.
3862 * gnulib/import/isnand.c: Update.
3863 * gnulib/import/isnanl-nolibm.h: Update.
3864 * gnulib/import/isnanl.c: Update.
3865 * gnulib/import/itold.c: Update.
3866 * gnulib/import/libc-config.h: Update.
3867 * gnulib/import/limits.in.h: Update.
3868 * gnulib/import/localcharset.c: Update.
3869 * gnulib/import/localcharset.h: Update.
3870 * gnulib/import/localtime-buffer.c: Update.
3871 * gnulib/import/localtime-buffer.h: Update.
3872 * gnulib/import/lstat.c: Update.
3873 * gnulib/import/m4/00gnulib.m4: Update.
3874 * gnulib/import/m4/__inline.m4: Update.
3875 * gnulib/import/m4/absolute-header.m4: Update.
3876 * gnulib/import/m4/alloca.m4: Update.
3877 * gnulib/import/m4/builtin-expect.m4: Update.
3878 * gnulib/import/m4/canonicalize.m4: Update.
3879 * gnulib/import/m4/chdir-long.m4: Update.
3880 * gnulib/import/m4/close.m4: Update.
3881 * gnulib/import/m4/closedir.m4: Update.
3882 * gnulib/import/m4/configmake.m4: Update.
3883 * gnulib/import/m4/d-ino.m4: Update.
3884 * gnulib/import/m4/d-type.m4: Update.
3885 * gnulib/import/m4/dirent_h.m4: Update.
3886 * gnulib/import/m4/dirfd.m4: Update.
3887 * gnulib/import/m4/dirname.m4: Update.
3888 * gnulib/import/m4/double-slash-root.m4: Update.
3889 * gnulib/import/m4/dup.m4: Update.
3890 * gnulib/import/m4/dup2.m4: Update.
3891 * gnulib/import/m4/eealloc.m4: Update.
3892 * gnulib/import/m4/environ.m4: Update.
3893 * gnulib/import/m4/errno_h.m4: Update.
3894 * gnulib/import/m4/error.m4: Update.
3895 * gnulib/import/m4/exponentd.m4: Update.
3896 * gnulib/import/m4/exponentl.m4: Update.
3897 * gnulib/import/m4/extensions.m4: Update.
3898 * gnulib/import/m4/extern-inline.m4: Update.
3899 * gnulib/import/m4/fchdir.m4: Update.
3900 * gnulib/import/m4/fcntl-o.m4: Update.
3901 * gnulib/import/m4/fcntl.m4: Update.
3902 * gnulib/import/m4/fcntl_h.m4: Update.
3903 * gnulib/import/m4/fdopendir.m4: Update.
3904 * gnulib/import/m4/filenamecat.m4: Update.
3905 * gnulib/import/m4/flexmember.m4: Update.
3906 * gnulib/import/m4/float_h.m4: Update.
3907 * gnulib/import/m4/fnmatch.m4: Update.
3908 * gnulib/import/m4/fnmatch_h.m4: Update.
3909 * gnulib/import/m4/fpieee.m4: Update.
3910 * gnulib/import/m4/frexp.m4: Update.
3911 * gnulib/import/m4/frexpl.m4: Update.
3912 * gnulib/import/m4/fstat.m4: Update.
3913 * gnulib/import/m4/fstatat.m4: Update.
3914 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
3915 * gnulib/import/m4/getcwd-path-max.m4: Update.
3916 * gnulib/import/m4/getcwd.m4: Update.
3917 * gnulib/import/m4/getdtablesize.m4: Update.
3918 * gnulib/import/m4/getlogin.m4: Update.
3919 * gnulib/import/m4/getlogin_r.m4: Update.
3920 * gnulib/import/m4/getpagesize.m4: Update.
3921 * gnulib/import/m4/getprogname.m4: Update.
3922 * gnulib/import/m4/gettimeofday.m4: Update.
3923 * gnulib/import/m4/glibc21.m4: Update.
3924 * gnulib/import/m4/glob.m4: Update.
3925 * gnulib/import/m4/glob_h.m4: Update.
3926 * gnulib/import/m4/gnulib-cache.m4: Update.
3927 * gnulib/import/m4/gnulib-common.m4: Update.
3928 * gnulib/import/m4/gnulib-comp.m4: Update.
3929 * gnulib/import/m4/gnulib-tool.m4: Update.
3930 * gnulib/import/m4/hard-locale.m4: Update.
3931 * gnulib/import/m4/include_next.m4: Update.
3932 * gnulib/import/m4/inttypes-pri.m4: Update.
3933 * gnulib/import/m4/inttypes.m4: Update.
3934 * gnulib/import/m4/isnand.m4: Update.
3935 * gnulib/import/m4/isnanl.m4: Update.
3936 * gnulib/import/m4/largefile.m4: Update.
3937 * gnulib/import/m4/limits-h.m4: Update.
3938 * gnulib/import/m4/localcharset.m4: Update.
3939 * gnulib/import/m4/locale-fr.m4: Update.
3940 * gnulib/import/m4/locale-ja.m4: Update.
3941 * gnulib/import/m4/locale-zh.m4: Update.
3942 * gnulib/import/m4/localtime-buffer.m4: Update.
3943 * gnulib/import/m4/longlong.m4: Update.
3944 * gnulib/import/m4/lstat.m4: Update.
3945 * gnulib/import/m4/malloc.m4: Update.
3946 * gnulib/import/m4/malloca.m4: Update.
3947 * gnulib/import/m4/math_h.m4: Update.
3948 * gnulib/import/m4/mbrtowc.m4: Update.
3949 * gnulib/import/m4/mbsinit.m4: Update.
3950 * gnulib/import/m4/mbsrtowcs.m4: Update.
3951 * gnulib/import/m4/mbstate_t.m4: Update.
3952 * gnulib/import/m4/memchr.m4: Update.
3953 * gnulib/import/m4/memmem.m4: Update.
3954 * gnulib/import/m4/mempcpy.m4: Update.
3955 * gnulib/import/m4/memrchr.m4: Update.
3956 * gnulib/import/m4/mkdir.m4: Update.
3957 * gnulib/import/m4/mkstemp.m4: Update.
3958 * gnulib/import/m4/mmap-anon.m4: Update.
3959 * gnulib/import/m4/mode_t.m4: Update.
3960 * gnulib/import/m4/msvc-inval.m4: Update.
3961 * gnulib/import/m4/msvc-nothrow.m4: Update.
3962 * gnulib/import/m4/multiarch.m4: Update.
3963 * gnulib/import/m4/nocrash.m4: Update.
3964 * gnulib/import/m4/off_t.m4: Update.
3965 * gnulib/import/m4/onceonly.m4: Update.
3966 * gnulib/import/m4/open-cloexec.m4: Update.
3967 * gnulib/import/m4/open.m4: Update.
3968 * gnulib/import/m4/openat.m4: Update.
3969 * gnulib/import/m4/opendir.m4: Update.
3970 * gnulib/import/m4/pathmax.m4: Update.
3971 * gnulib/import/m4/rawmemchr.m4: Update.
3972 * gnulib/import/m4/readdir.m4: Update.
3973 * gnulib/import/m4/readlink.m4: Update.
3974 * gnulib/import/m4/realloc.m4: Update.
3975 * gnulib/import/m4/rename.m4: Update.
3976 * gnulib/import/m4/rewinddir.m4: Update.
3977 * gnulib/import/m4/rmdir.m4: Update.
3978 * gnulib/import/m4/save-cwd.m4: Update.
3979 * gnulib/import/m4/secure_getenv.m4: Update.
3980 * gnulib/import/m4/setenv.m4: Update.
3981 * gnulib/import/m4/signal_h.m4: Update.
3982 * gnulib/import/m4/ssize_t.m4: Update.
3983 * gnulib/import/m4/stat-time.m4: Update.
3984 * gnulib/import/m4/stat.m4: Update.
3985 * gnulib/import/m4/std-gnu11.m4: Update.
3986 * gnulib/import/m4/stdbool.m4: Update.
3987 * gnulib/import/m4/stddef_h.m4: Update.
3988 * gnulib/import/m4/stdint.m4: Update.
3989 * gnulib/import/m4/stdio_h.m4: Update.
3990 * gnulib/import/m4/stdlib_h.m4: Update.
3991 * gnulib/import/m4/strchrnul.m4: Update.
3992 * gnulib/import/m4/strdup.m4: Update.
3993 * gnulib/import/m4/strerror.m4: Update.
3994 * gnulib/import/m4/string_h.m4: Update.
3995 * gnulib/import/m4/strstr.m4: Update.
3996 * gnulib/import/m4/strtok_r.m4: Update.
3997 * gnulib/import/m4/sys_socket_h.m4: Update.
3998 * gnulib/import/m4/sys_stat_h.m4: Update.
3999 * gnulib/import/m4/sys_time_h.m4: Update.
4000 * gnulib/import/m4/sys_types_h.m4: Update.
4001 * gnulib/import/m4/tempname.m4: Update.
4002 * gnulib/import/m4/time_h.m4: Update.
4003 * gnulib/import/m4/unistd-safer.m4: Update.
4004 * gnulib/import/m4/unistd_h.m4: Update.
4005 * gnulib/import/m4/warn-on-use.m4: Update.
4006 * gnulib/import/m4/wchar_h.m4: Update.
4007 * gnulib/import/m4/wchar_t.m4: Update.
4008 * gnulib/import/m4/wctype_h.m4: Update.
4009 * gnulib/import/m4/wint_t.m4: Update.
4010 * gnulib/import/malloc.c: Update.
4011 * gnulib/import/malloc/scratch_buffer.h: Update.
4012 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4013 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4014 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4015 * gnulib/import/malloca.c: Update.
4016 * gnulib/import/malloca.h: Update.
4017 * gnulib/import/malloca.valgrind: Update.
4018 * gnulib/import/math.in.h: Update.
4019 * gnulib/import/mbrtowc.c: Update.
4020 * gnulib/import/mbsinit.c: Update.
4021 * gnulib/import/mbsrtowcs-impl.h: Update.
4022 * gnulib/import/mbsrtowcs-state.c: Update.
4023 * gnulib/import/mbsrtowcs.c: Update.
4024 * gnulib/import/memchr.c: Update.
4025 * gnulib/import/memmem.c: Update.
4026 * gnulib/import/mempcpy.c: Update.
4027 * gnulib/import/memrchr.c: Update.
4028 * gnulib/import/mkdir.c: Update.
4029 * gnulib/import/mkstemp.c: Update.
4030 * gnulib/import/msvc-inval.c: Update.
4031 * gnulib/import/msvc-inval.h: Update.
4032 * gnulib/import/msvc-nothrow.c: Update.
4033 * gnulib/import/msvc-nothrow.h: Update.
4034 * gnulib/import/open.c: Update.
4035 * gnulib/import/openat-die.c: Update.
4036 * gnulib/import/openat-priv.h: Update.
4037 * gnulib/import/openat-proc.c: Update.
4038 * gnulib/import/openat.c: Update.
4039 * gnulib/import/openat.h: Update.
4040 * gnulib/import/opendir.c: Update.
4041 * gnulib/import/pathmax.h: Update.
4042 * gnulib/import/pipe-safer.c: Update.
4043 * gnulib/import/rawmemchr.c: Update.
4044 * gnulib/import/readdir.c: Update.
4045 * gnulib/import/readlink.c: Update.
4046 * gnulib/import/realloc.c: Update.
4047 * gnulib/import/ref-add.sin: Update.
4048 * gnulib/import/ref-del.sin: Update.
4049 * gnulib/import/rename.c: Update.
4050 * gnulib/import/rewinddir.c: Update.
4051 * gnulib/import/rmdir.c: Update.
4052 * gnulib/import/same-inode.h: Update.
4053 * gnulib/import/save-cwd.c: Update.
4054 * gnulib/import/save-cwd.h: Update.
4055 * gnulib/import/scratch_buffer.h: Update.
4056 * gnulib/import/secure_getenv.c: Update.
4057 * gnulib/import/setenv.c: Update.
4058 * gnulib/import/signal.in.h: Update.
4059 * gnulib/import/stat-time.c: Update.
4060 * gnulib/import/stat-time.h: Update.
4061 * gnulib/import/stat-w32.c: Update.
4062 * gnulib/import/stat-w32.h: Update.
4063 * gnulib/import/stat.c: Update.
4064 * gnulib/import/stdbool.in.h: Update.
4065 * gnulib/import/stddef.in.h: Update.
4066 * gnulib/import/stdint.in.h: Update.
4067 * gnulib/import/stdio.in.h: Update.
4068 * gnulib/import/stdlib.in.h: Update.
4069 * gnulib/import/str-two-way.h: Update.
4070 * gnulib/import/strchrnul.c: Update.
4071 * gnulib/import/strdup.c: Update.
4072 * gnulib/import/streq.h: Update.
4073 * gnulib/import/strerror-override.c: Update.
4074 * gnulib/import/strerror-override.h: Update.
4075 * gnulib/import/strerror.c: Update.
4076 * gnulib/import/string.in.h: Update.
4077 * gnulib/import/stripslash.c: Update.
4078 * gnulib/import/strnlen1.c: Update.
4079 * gnulib/import/strnlen1.h: Update.
4080 * gnulib/import/strstr.c: Update.
4081 * gnulib/import/strtok_r.c: Update.
4082 * gnulib/import/sys_stat.in.h: Update.
4083 * gnulib/import/sys_time.in.h: Update.
4084 * gnulib/import/sys_types.in.h: Update.
4085 * gnulib/import/tempname.c: Update.
4086 * gnulib/import/tempname.h: Update.
4087 * gnulib/import/time.in.h: Update.
4088 * gnulib/import/unistd--.h: Update.
4089 * gnulib/import/unistd-safer.h: Update.
4090 * gnulib/import/unistd.in.h: Update.
4091 * gnulib/import/unsetenv.c: Update.
4092 * gnulib/import/verify.h: Update.
4093 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4094 * gnulib/import/wchar.in.h: Update.
4095 * gnulib/import/wctype.in.h: Update.
4096 * gnulib/import/xalloc-oversized.h: Update.
4097 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4098 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4100 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
4102 * record-btrace.c (get_thread_current_frame): Remove
4105 2018-09-10 Jerome Guitton <guitton@adacore.com>
4107 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
4108 with check_tag to 1 if and only if the type is tagged and the
4109 component being searched cannot been found in the current
4110 view. Otherwise, always call ada_to_fixed_type with
4113 2018-09-10 Xavier Roirand <roirand@adacore.com>
4115 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
4117 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
4118 * ada-varobj.c (ada_varobj_get_number_of_children,
4119 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
4121 2018-09-10 Xavier Roirand <roirand@adacore.com>
4123 * ada-valprint.c (ada_value_print): Use type instead of
4126 2018-09-10 Xavier Roirand <roirand@adacore.com>
4128 * ada-lang.c (ada_value_subscript): Handle case when parameter is
4129 an array of access to unconstrained array.
4131 2018-09-10 Xavier Roirand <roirand@adacore.com>
4133 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
4134 (ada_check_typedef): Use it.
4136 2018-09-10 Xavier Roirand <roirand@adacore.com>
4138 * ada-varobj.c (ada_varobj_describe_struct_child)
4139 (ada_varobj_describe_child): Handle union case like struct one.
4141 2018-09-10 Tom Tromey <tom@tromey.com>
4144 * python/python.c (_initialize_python): Make example in "python"
4145 help work in Python 3.
4147 2018-09-10 Eli Zaretskii <eliz@gnu.org>
4149 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
4150 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
4151 $(EXEEXT) to the script, as it is not a program.
4153 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
4155 * python/py-prettyprint.c (pretty_print_one_value): Return
4157 (print_string_repr): Adjust.
4158 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
4159 * python/python-internal.h (apply_varobj_pretty_printer): Return
4161 * varobj.c (varobj_value_get_print_value): Adjust.
4163 2018-09-08 Tom Tromey <tom@tromey.com>
4166 * python/py-prettyprint.c (pretty_print_one_value): Check for
4169 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4171 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
4172 replace_operator_with_call.
4174 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4176 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
4178 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4180 * ada-typeprint.c (print_range): Print the bounds using TYPE
4181 rather than its TYPE_TARGET_TYPE.
4183 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4185 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
4186 call to ada_to_fixed_value_create.
4188 2018-09-08 Jerome Guitton <guitton@adacore.com>
4190 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
4192 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4194 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
4197 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4199 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
4200 Move update of loop variable "fi".
4202 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4204 * ada-lang.c (value_assign_to_component): In the case of
4205 big-endian targets, extract the bits of the given VAL
4206 using an src_offset of zero if container is not a scalar.
4208 2018-09-06 Simon Ser <contact@emersion.fr>
4211 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
4212 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
4213 * fbsd-tdep.c (fbsd_make_note_desc): New.
4214 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
4215 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
4216 * target.h (enum target_object) Add FreeBSD-specific
4217 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
4219 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4221 * compile/compile-c.h (generate_c_for_variable_locations):
4222 Change reference to pointer.
4223 * compile/compile-c-support.c (compile_program) <compute>:
4225 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
4226 (generate_c_for_for_one_variable): Likewise
4227 (generate_c_for_variable_locations): Likewise
4228 * compile/compile-c-types.c (compile_c_instance::convert_type):
4230 * compile/compile-cplus-symbols.c (convert_one_symbol):
4231 std::move the scope passed to enter_scope.
4232 * compile/compile-cplus-types.c
4233 (compile_cplus_instance::enter_scope): Make parameter
4235 (compile_cplus_instance::new_scope): Change reference to
4237 (compile_cplus_instance::convert_type): Likewise
4238 (compile_cplus_convert_typedef): std::move the scope passed to
4240 (compile_cplus_convert_struct_or_union): Likewise.
4241 (compile_cplus_convert_enum): Likewise.
4242 (compile_cplus_convert_namespace): Likewise.
4243 * compile/compile-cplus.h (compile_cplus_instance)
4244 <enter_scope>: Make parameter rvalue-reference.
4245 * compile/compile-internal.h (compile_instance)
4246 <get_cached_type>: Likewise
4247 * compile/compile-loc2c.c (push): Likewise
4251 (print_label): Likewise
4252 (pushf_register_address): Likewise
4253 (pushf_register): Likewise
4254 (do_compile_dwarf_expr_to_c): Likewise
4255 (compile_dwarf_expr_to_c): Likewise
4256 (compile_dwarf_bounds_to_c): Likewise
4257 * compile/compile.c (compile_instance::get_cached_type):
4259 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
4260 (compile_dwarf_bounds_to_c): Likewise
4261 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
4262 (dwarf2_compile_property_to_c): Likewise
4263 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
4264 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
4267 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4269 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
4270 * tui/tui-data.c (init_content_element): Don't initialize it.
4272 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4274 * tui/tui-data.h (struct tui_win_info)
4275 <detail::opaque>: Remove.
4276 * tui/tui-data.c (init_win_info): Remove assignment.
4278 2018-09-05 Tom Tromey <tom@tromey.com>
4280 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
4281 -Wformat-nonliteral.
4282 * target-float.c (host_float_ops<T>::to_string)
4283 (host_float_ops<T>::from_string): Use
4284 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4285 * configure: Rebuild.
4287 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
4289 * printcmd.c (printf_c_string): Use
4290 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4291 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
4293 2018-09-05 Tom Tromey <tom@tromey.com>
4295 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
4297 2018-09-05 Tom de Vries <tdevries@suse.de>
4299 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
4300 with resolve_abstract_p == true.
4301 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
4302 defaulting to false. Propagate resolve_abstract_p to
4303 dwarf2_fetch_die_loc_sect_off.
4304 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
4305 parameter, defaulting to false.
4306 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
4307 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
4309 * dwarf2read.h (struct die_info): Forward-declare.
4310 (die_info_ptr): New typedef.
4311 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
4313 2018-09-05 Joel Brobecker <brobecker@adacore.com>
4317 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
4318 Pedro Alves <palves@redhat.com>
4320 * gnulib/Makefile.in (aclocal_m4_deps): Move to
4321 "aclocal-m4-deps.mk". Include file here.
4322 $(srcdir)/aclocal.m4: Add "configure.ac".
4323 * gnulib/aclocal-m4-deps.mk: New file.
4324 * gnulib/update-gnulib.sh: Automatically update
4325 "aclocal-m4-deps.mk".
4327 2018-09-04 Tom Tromey <tom@tromey.com>
4329 * configure: Rebuild.
4330 * configure.ac: Remove multi-ice code.
4332 2018-09-04 Tom Tromey <tom@tromey.com>
4334 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
4335 (ada-exp.o): Update.
4337 2018-09-04 Tom Tromey <tom@tromey.com>
4339 * Makefile.in (printcmd.o, target-float.o): Remove.
4340 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
4342 2018-09-04 Tom Tromey <tom@tromey.com>
4344 * gnulib/Makefile.in: Remove obsolete comment.
4345 * Makefile.in: Remove obsolete comment.
4347 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
4349 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
4352 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4354 * riscv-tdep.c: Add 'prologue-value.h' include.
4355 (struct riscv_unwind_cache): New struct.
4356 (riscv_debug_unwinder): New global.
4357 (riscv_scan_prologue): Update arguments, capture register details
4359 (riscv_skip_prologue): Reformat arguments line, move end of
4360 prologue calculation into riscv_scan_prologue.
4361 (riscv_frame_cache): Update return type, create
4362 riscv_unwind_cache, scan the prologue, and fill in remaining cache
4364 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
4365 (riscv_frame_prev_register): Use the trad_frame within the
4367 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
4370 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4372 * trad-frame.h (trad_frame_set_realreg): Declare.
4373 (trad_frame_set_addr): Declare.
4374 * trad-frame.c (trad_frame_set_realreg): Define new function.
4375 (trad_frame_set_addr): Define new function.
4376 (trad_frame_set_reg_realreg): Use new function.
4377 (trad_frame_set_reg_addr): Use new function.
4379 2018-09-01 Keith Seitz <keiths@redhat.com>
4381 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
4382 pulongest instead of "%lld".
4383 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
4386 2018-08-31 Tom Tromey <tom@tromey.com>
4388 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
4391 2018-08-31 Pedro Alves <palves@redhat.com>
4393 * gdbarch.h: Regenerate.
4395 2018-08-31 Pedro Alves <palves@redhat.com>
4397 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
4398 * target.h (Hardware watchpoint interfaces): Describe
4399 continuable/steppable/non-steppable watchpoints.
4400 * gdbarch.h, gdbarch.c: Regenerate.
4402 2018-08-31 Pedro Alves <palves@redhat.com>
4404 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
4407 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
4408 * target.h (target_ops::have_continuable_watchpoint): Delete.
4409 (target_have_continuable_watchpoint): Delete.
4410 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
4411 * target-delegates.c: Regenerate.
4413 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4415 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
4416 the files present in "gnulib/import/m4/".
4418 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4420 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
4421 c.sw, c.swsp, and c.sdsp.
4423 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4425 * riscv-tdep.c (struct riscv_inferior_data): Delete.
4426 (riscv_read_misa_reg): Don't cache value read into inferior data.
4427 (riscv_new_inferior_data): Delete.
4428 (riscv_inferior_data_cleanup): Delete.
4429 (riscv_inferior_data): Delete.
4430 (riscv_invalidate_inferior_data): Delete.
4431 (_initialize_riscv_tdep): Remove initialisation of inferior data.
4433 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
4435 * compile/compile-cplus-types.c
4436 (compile_cplus_instance::leave_scope): Take the address of scope
4438 (compile_cplus_instance::convert_qualified_base): Compare quals
4441 2018-08-30 Keith Seitz <keiths@redhat.com>
4443 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
4444 Use "%s" and host_address_to_string instead of "%p" in printf.
4446 2018-08-29 Keith Seitz <keiths@redhat.com>
4448 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
4449 and compile-cplus-types.c.
4450 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
4451 * c-lang.c (cplus_language_defn): Set C++ compile functions.
4452 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
4454 * compile/compile-c-support.c: Include compile-cplus.h.
4455 (load_libcompile): Templatize.
4456 (get_compile_context): "New" function.
4457 (c_get_compile_context): Use get_compile_context.
4458 (cplus_get_compile_context): New function.
4459 (cplus_push_user_expression, cplus_pop_user_expression)
4460 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
4461 (cplus_compute_program): Define new structs/functions.
4462 * compile/compile-cplus-symmbols.c: New file.
4463 * compile/compile-cplus-types.c: New file.
4464 * compile/compile-cplus.h: New file.
4465 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
4467 * compile/compile-object-load.c (get_out_value_type): Use
4468 strncmp_iw when comparing symbol names.
4469 (compile_object_load): Add mst_bss and mst_data.
4470 * compile/compile.c (_initialize_compile): Remove
4471 -Wno-implicit-function-declaration from `compile_args'.
4472 * compile/gcc-cp-plugin.h: New file.
4473 * NEWS: Mention C++ compile support and new debug options.
4475 2018-08-29 Keith Seitz <keiths@redhat.com>
4477 * linespec.c (collect_info::add_symbol): Make virtual.
4478 (struct symbol_searcher_collect_info): New struct.
4479 (symbol_searcher::find_all_symbols): New method.
4480 * symtab.h (class symbol_searcher): New class.
4482 2018-08-29 Keith Seitz <keiths@redhat.com>
4484 * linespec.c (struct linespec) <function_symbols, label_symbols>:
4485 Change to vector of block_symbol. Update all users.
4486 (struct collect_info) <symbols>: Likewise.
4487 (collect_info::add_symbol): Take block_symbol as argument.
4489 (decode_compound_collector) <m_symbols>: Change type to vector
4490 of block_symbol. Update all users.
4491 (decode_compound_collector::operator ()): Change parameter type
4493 (find_method, find_function_symbols, find_linespec_symbols)
4494 (find_label_symbols_in_block, find_label_symbols): Change symbol
4495 vectors to block_symbol vectors.
4496 * symtab.h (symbol_found_callback_ftype): Change parameter type to
4499 2018-08-29 Keith Seitz <keiths@redhat.com>
4501 * linespec.c (symbolp): Remove typedef and VEC definitions.
4502 (bound_minimal_symbol_d): Likewise.
4504 2018-08-29 Keith Seitz <keiths@redhat.com>
4506 * linespec.c (decode_compound_collector::decode_compound_collector):
4507 Remove initialization for `m_symtabs'.
4508 (decode_compound_collector::release_symbols): Change return type
4509 to std::vector. Update all callers.
4510 (class decode_compound_collector) <m_symbols>: Change type to
4512 (lookup_prefix_sym): Change return type to std::vector. Update all
4514 (compare_symbols): Remove.
4515 (std_compare_symbols): Rename to `compare_symbols'.
4516 (find_method): Change `sym_classes' parameter to std::vector.
4517 Update all callers. Use std::sort to sort sym_classes.
4518 (find_linespec_symbols): Remove cleanup.
4520 2018-08-29 Keith Seitz <keiths@redhat.com>
4522 * linespec.c (struct linespec) <minimal_symbols>: Change type to
4523 std::vector. Update all users.
4524 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
4525 (struct collect_info) <minimal_symbols>: Likewise.
4526 (compare_msymbols): Return bool. Change parameters to const
4527 bound_minimal_symbol references.
4528 (find_method, find_function_symbols, find_linespec_symbols): Change
4529 `minsyms' parameter to std::vector. Update all callers.
4531 2018-08-29 Keith Seitz <keiths@redhat.com>
4533 * linespec.c (struct linespec) <label_symbols>: Change type to
4534 std::vector. Update all users.
4535 (find_label_symbols_in_block): Change `result' parameter to
4536 std::vector. Update all callers.
4537 (find_label_symbols): Return std::vector. Update all callers.
4539 2018-08-29 Keith Seitz <keiths@redhat.com>
4541 * linespec.c (struct linespec) <function_symbols>: Change type to
4542 std::vector. Update all users.
4543 (struct collect_info) <function_symbols>: Likewise.
4544 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
4545 (std_compare_symbols): New function.
4546 (find_method, find_function_symbols, find_linespec_symbols)
4547 (find_label_symbols_in_block): Change `symbols' parameter to
4548 std::vector. Update all callers.
4549 (find_label_symbols): Likewise for `function_symbols' and
4552 2018-08-29 Keith Seitz <keiths@redhat.com>
4554 * linespec.c (symtab_vector_up): Define.
4555 (struct linespec) <file_symtabs>: Change type to std::vector *.
4557 (struct collect_info) <file_symtabs>: Likewise.
4558 (collect_symtabs_from_filename): Return symtab_vector_up.
4560 (decode_objc): Remove cleanup.
4561 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
4562 (symtab_collector::release_symtabs): Return symtab_vector_up.
4564 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
4566 (collect_symtabs_from_filename, symtabs_from_filename): Return
4567 symtab_vector_up. Update all callers.
4569 2018-08-29 Tom Tromey <tom@tromey.com>
4571 * csky-tdep.c (csky_analyze_prologue): Use
4572 core_addr_to_string_nz.
4574 2018-08-29 Tom Tromey <tom@tromey.com>
4576 * windows-nat.c (struct xlate_exception) <them>: Change type to
4578 (xlate): Fix formatting. Remove last entry.
4579 (struct xlate_exception, xlate): Comment out.
4580 (windows_nat_target::resume): Use ranged for.
4582 2018-08-29 Jim Wilson <jimw@sifive.com>
4584 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
4585 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
4587 (riscv_linux_nat_target::store_registers): Likewise.
4589 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
4593 * gnulib/aclocal.m4: Regenerate.
4594 * gnulib/config.in: Regenerate.
4595 * gnulib/configure: Regenerate.
4596 * gnulib/import/Makefile.am: Update.
4597 * gnulib/import/Makefile.in: Update.
4598 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
4599 * gnulib/import/_Noreturn.h: ... this.
4600 * gnulib/import/alloca.in.h: Update.
4601 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
4602 * gnulib/import/arg-nonnull.h: ... this.
4603 * gnulib/import/assure.h: Update.
4604 * gnulib/import/at-func.c: Update.
4605 * gnulib/import/basename-lgpl.c: Update.
4606 * gnulib/import/extra/snippet/c++defs.h: Rename to...
4607 * gnulib/import/c++defs.h: ... this.
4608 * gnulib/import/canonicalize-lgpl.c: Update.
4609 * gnulib/import/cdefs.h: Update.
4610 * gnulib/import/chdir-long.c: Update.
4611 * gnulib/import/chdir-long.h: Update.
4612 * gnulib/import/cloexec.c: Update.
4613 * gnulib/import/cloexec.h: Update.
4614 * gnulib/import/close.c: Update.
4615 * gnulib/import/closedir.c: Update.
4616 * gnulib/import/config.charset: Update.
4617 * gnulib/import/dirent-private.h: Update.
4618 * gnulib/import/dirent.in.h: Update.
4619 * gnulib/import/dirfd.c: Update.
4620 * gnulib/import/dirname-lgpl.c: Update.
4621 * gnulib/import/dirname.h: Update.
4622 * gnulib/import/dosname.h: Update.
4623 * gnulib/import/dup-safer-flag.c: Update.
4624 * gnulib/import/dup-safer.c: Update.
4625 * gnulib/import/dup.c: Update.
4626 * gnulib/import/dup2.c: Update.
4627 * gnulib/import/errno.in.h: Update.
4628 * gnulib/import/error.c: Update.
4629 * gnulib/import/error.h: Update.
4630 * gnulib/import/exitfail.c: Update.
4631 * gnulib/import/exitfail.h: Update.
4632 * gnulib/import/extra/update-copyright: Update.
4633 * gnulib/import/fchdir.c: Update.
4634 * gnulib/import/fcntl.c: Update.
4635 * gnulib/import/fcntl.in.h: Update.
4636 * gnulib/import/fd-hook.c: Update.
4637 * gnulib/import/fd-hook.h: Update.
4638 * gnulib/import/fd-safer-flag.c: Update.
4639 * gnulib/import/fd-safer.c: Update.
4640 * gnulib/import/fdopendir.c: Update.
4641 * gnulib/import/filename.h: Update.
4642 * gnulib/import/filenamecat-lgpl.c: Update.
4643 * gnulib/import/filenamecat.h: Update.
4644 * gnulib/import/flexmember.h: Update.
4645 * gnulib/import/float+.h: Update.
4646 * gnulib/import/float.c: Update.
4647 * gnulib/import/float.in.h: Update.
4648 * gnulib/import/fnmatch.c: Update.
4649 * gnulib/import/fnmatch.in.h: Update.
4650 * gnulib/import/fnmatch_loop.c: Update.
4651 * gnulib/import/fpucw.h: Update.
4652 * gnulib/import/frexp.c: Update.
4653 * gnulib/import/frexpl.c: Update.
4654 * gnulib/import/fstat.c: Update.
4655 * gnulib/import/fstatat.c: Update.
4656 * gnulib/import/getcwd-lgpl.c: Update.
4657 * gnulib/import/getcwd.c: Update.
4658 * gnulib/import/getdtablesize.c: Update.
4659 * gnulib/import/getlogin_r.c: Update.
4660 * gnulib/import/getprogname.c: Update.
4661 * gnulib/import/getprogname.h: Update.
4662 * gnulib/import/gettext.h: Update.
4663 * gnulib/import/gettimeofday.c: Update.
4664 * gnulib/import/glob-libc.h: Update.
4665 * gnulib/import/glob.c: Update.
4666 * gnulib/import/glob.in.h: Update.
4667 * gnulib/import/glob_internal.h: Update.
4668 * gnulib/import/glob_pattern_p.c: Update.
4669 * gnulib/import/globfree.c: Update.
4670 * gnulib/import/hard-locale.c: Update.
4671 * gnulib/import/hard-locale.h: Update.
4672 * gnulib/import/intprops.h: Update.
4673 * gnulib/import/inttypes.in.h: Update.
4674 * gnulib/import/isnan.c: Update.
4675 * gnulib/import/isnand-nolibm.h: Update.
4676 * gnulib/import/isnand.c: Update.
4677 * gnulib/import/isnanl-nolibm.h: Update.
4678 * gnulib/import/isnanl.c: Update.
4679 * gnulib/import/itold.c: Update.
4680 * gnulib/import/libc-config.h: Update.
4681 * gnulib/import/limits.in.h: Update.
4682 * gnulib/import/localcharset.c: Update.
4683 * gnulib/import/localcharset.h: Update.
4684 * gnulib/import/localtime-buffer.c: Update.
4685 * gnulib/import/localtime-buffer.h: Update.
4686 * gnulib/import/lstat.c: Update.
4687 * gnulib/import/m4/00gnulib.m4: Update.
4688 * gnulib/import/m4/__inline.m4: Update.
4689 * gnulib/import/m4/absolute-header.m4: Update.
4690 * gnulib/import/m4/alloca.m4: Update.
4691 * gnulib/import/m4/builtin-expect.m4: Update.
4692 * gnulib/import/m4/canonicalize.m4: Update.
4693 * gnulib/import/m4/chdir-long.m4: Update.
4694 * gnulib/import/m4/close.m4: Update.
4695 * gnulib/import/m4/closedir.m4: Update.
4696 * gnulib/import/m4/configmake.m4: Update.
4697 * gnulib/import/m4/d-ino.m4: Update.
4698 * gnulib/import/m4/d-type.m4: Update.
4699 * gnulib/import/m4/dirent_h.m4: Update.
4700 * gnulib/import/m4/dirfd.m4: Update.
4701 * gnulib/import/m4/dirname.m4: Update.
4702 * gnulib/import/m4/double-slash-root.m4: Update.
4703 * gnulib/import/m4/dup.m4: Update.
4704 * gnulib/import/m4/dup2.m4: Update.
4705 * gnulib/import/m4/eealloc.m4: Update.
4706 * gnulib/import/m4/environ.m4: Update.
4707 * gnulib/import/m4/errno_h.m4: Update.
4708 * gnulib/import/m4/error.m4: Update.
4709 * gnulib/import/m4/exponentd.m4: Update.
4710 * gnulib/import/m4/exponentl.m4: Update.
4711 * gnulib/import/m4/extensions.m4: Update.
4712 * gnulib/import/m4/extern-inline.m4: Update.
4713 * gnulib/import/m4/fchdir.m4: Update.
4714 * gnulib/import/m4/fcntl-o.m4: Update.
4715 * gnulib/import/m4/fcntl.m4: Update.
4716 * gnulib/import/m4/fcntl_h.m4: Update.
4717 * gnulib/import/m4/fdopendir.m4: Update.
4718 * gnulib/import/m4/filenamecat.m4: Update.
4719 * gnulib/import/m4/flexmember.m4: Update.
4720 * gnulib/import/m4/float_h.m4: Update.
4721 * gnulib/import/m4/fnmatch.m4: Update.
4722 * gnulib/import/m4/fnmatch_h.m4: Update.
4723 * gnulib/import/m4/fpieee.m4: Update.
4724 * gnulib/import/m4/frexp.m4: Update.
4725 * gnulib/import/m4/frexpl.m4: Update.
4726 * gnulib/import/m4/fstat.m4: Update.
4727 * gnulib/import/m4/fstatat.m4: Update.
4728 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
4729 * gnulib/import/m4/getcwd-path-max.m4: Update.
4730 * gnulib/import/m4/getcwd.m4: Update.
4731 * gnulib/import/m4/getdtablesize.m4: Update.
4732 * gnulib/import/m4/getlogin.m4: Update.
4733 * gnulib/import/m4/getlogin_r.m4: Update.
4734 * gnulib/import/m4/getpagesize.m4: Update.
4735 * gnulib/import/m4/getprogname.m4: Update.
4736 * gnulib/import/m4/gettimeofday.m4: Update.
4737 * gnulib/import/m4/glibc21.m4: Update.
4738 * gnulib/import/m4/glob.m4: Update.
4739 * gnulib/import/m4/glob_h.m4: Update.
4740 * gnulib/import/m4/gnulib-cache.m4: Update.
4741 * gnulib/import/m4/gnulib-common.m4: Update.
4742 * gnulib/import/m4/gnulib-comp.m4: Update.
4743 * gnulib/import/m4/gnulib-tool.m4: Update.
4744 * gnulib/import/m4/hard-locale.m4: Update.
4745 * gnulib/import/m4/include_next.m4: Update.
4746 * gnulib/import/m4/inttypes-pri.m4: Update.
4747 * gnulib/import/m4/inttypes.m4: Update.
4748 * gnulib/import/m4/isnand.m4: Update.
4749 * gnulib/import/m4/isnanl.m4: Update.
4750 * gnulib/import/m4/largefile.m4: Update.
4751 * gnulib/import/m4/limits-h.m4: Update.
4752 * gnulib/import/m4/localcharset.m4: Update.
4753 * gnulib/import/m4/locale-fr.m4: Update.
4754 * gnulib/import/m4/locale-ja.m4: Update.
4755 * gnulib/import/m4/locale-zh.m4: Update.
4756 * gnulib/import/m4/localtime-buffer.m4: Update.
4757 * gnulib/import/m4/longlong.m4: Update.
4758 * gnulib/import/m4/lstat.m4: Update.
4759 * gnulib/import/m4/malloc.m4: Update.
4760 * gnulib/import/m4/malloca.m4: Update.
4761 * gnulib/import/m4/math_h.m4: Update.
4762 * gnulib/import/m4/mbrtowc.m4: Update.
4763 * gnulib/import/m4/mbsinit.m4: Update.
4764 * gnulib/import/m4/mbsrtowcs.m4: Update.
4765 * gnulib/import/m4/mbstate_t.m4: Update.
4766 * gnulib/import/m4/memchr.m4: Update.
4767 * gnulib/import/m4/memmem.m4: Update.
4768 * gnulib/import/m4/mempcpy.m4: Update.
4769 * gnulib/import/m4/memrchr.m4: Update.
4770 * gnulib/import/m4/mkdir.m4: Update.
4771 * gnulib/import/m4/mkstemp.m4: Update.
4772 * gnulib/import/m4/mmap-anon.m4: Update.
4773 * gnulib/import/m4/mode_t.m4: Update.
4774 * gnulib/import/m4/msvc-inval.m4: Update.
4775 * gnulib/import/m4/msvc-nothrow.m4: Update.
4776 * gnulib/import/m4/multiarch.m4: Update.
4777 * gnulib/import/m4/nocrash.m4: Update.
4778 * gnulib/import/m4/off_t.m4: Update.
4779 * gnulib/import/m4/onceonly.m4: Update.
4780 * gnulib/import/m4/open-cloexec.m4: Update.
4781 * gnulib/import/m4/open.m4: Update.
4782 * gnulib/import/m4/openat.m4: Update.
4783 * gnulib/import/m4/opendir.m4: Update.
4784 * gnulib/import/m4/pathmax.m4: Update.
4785 * gnulib/import/m4/rawmemchr.m4: Update.
4786 * gnulib/import/m4/readdir.m4: Update.
4787 * gnulib/import/m4/readlink.m4: Update.
4788 * gnulib/import/m4/realloc.m4: Update.
4789 * gnulib/import/m4/rename.m4: Update.
4790 * gnulib/import/m4/rewinddir.m4: Update.
4791 * gnulib/import/m4/rmdir.m4: Update.
4792 * gnulib/import/m4/save-cwd.m4: Update.
4793 * gnulib/import/m4/secure_getenv.m4: Update.
4794 * gnulib/import/m4/setenv.m4: Update.
4795 * gnulib/import/m4/signal_h.m4: Update.
4796 * gnulib/import/m4/ssize_t.m4: Update.
4797 * gnulib/import/m4/stat-time.m4: Update.
4798 * gnulib/import/m4/stat.m4: Update.
4799 * gnulib/import/m4/std-gnu11.m4: Update.
4800 * gnulib/import/m4/stdbool.m4: Update.
4801 * gnulib/import/m4/stddef_h.m4: Update.
4802 * gnulib/import/m4/stdint.m4: Update.
4803 * gnulib/import/m4/stdio_h.m4: Update.
4804 * gnulib/import/m4/stdlib_h.m4: Update.
4805 * gnulib/import/m4/strchrnul.m4: Update.
4806 * gnulib/import/m4/strdup.m4: Update.
4807 * gnulib/import/m4/strerror.m4: Update.
4808 * gnulib/import/m4/string_h.m4: Update.
4809 * gnulib/import/m4/strstr.m4: Update.
4810 * gnulib/import/m4/strtok_r.m4: Update.
4811 * gnulib/import/m4/sys_socket_h.m4: Update.
4812 * gnulib/import/m4/sys_stat_h.m4: Update.
4813 * gnulib/import/m4/sys_time_h.m4: Update.
4814 * gnulib/import/m4/sys_types_h.m4: Update.
4815 * gnulib/import/m4/tempname.m4: Update.
4816 * gnulib/import/m4/time_h.m4: Update.
4817 * gnulib/import/m4/unistd-safer.m4: Update.
4818 * gnulib/import/m4/unistd_h.m4: Update.
4819 * gnulib/import/m4/warn-on-use.m4: Update.
4820 * gnulib/import/m4/wchar_h.m4: Update.
4821 * gnulib/import/m4/wchar_t.m4: Update.
4822 * gnulib/import/m4/wctype_h.m4: Update.
4823 * gnulib/import/m4/wint_t.m4: Update.
4824 * gnulib/import/malloc.c: Update.
4825 * gnulib/import/malloc/scratch_buffer.h: Update.
4826 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4827 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4828 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4829 * gnulib/import/malloca.c: Update.
4830 * gnulib/import/malloca.h: Update.
4831 * gnulib/import/malloca.valgrind: Update.
4832 * gnulib/import/math.in.h: Update.
4833 * gnulib/import/mbrtowc.c: Update.
4834 * gnulib/import/mbsinit.c: Update.
4835 * gnulib/import/mbsrtowcs-impl.h: Update.
4836 * gnulib/import/mbsrtowcs-state.c: Update.
4837 * gnulib/import/mbsrtowcs.c: Update.
4838 * gnulib/import/memchr.c: Update.
4839 * gnulib/import/memmem.c: Update.
4840 * gnulib/import/mempcpy.c: Update.
4841 * gnulib/import/memrchr.c: Update.
4842 * gnulib/import/mkdir.c: Update.
4843 * gnulib/import/mkstemp.c: Update.
4844 * gnulib/import/msvc-inval.c: Update.
4845 * gnulib/import/msvc-inval.h: Update.
4846 * gnulib/import/msvc-nothrow.c: Update.
4847 * gnulib/import/msvc-nothrow.h: Update.
4848 * gnulib/import/open.c: Update.
4849 * gnulib/import/openat-die.c: Update.
4850 * gnulib/import/openat-priv.h: Update.
4851 * gnulib/import/openat-proc.c: Update.
4852 * gnulib/import/openat.c: Update.
4853 * gnulib/import/openat.h: Update.
4854 * gnulib/import/opendir.c: Update.
4855 * gnulib/import/pathmax.h: Update.
4856 * gnulib/import/pipe-safer.c: Update.
4857 * gnulib/import/rawmemchr.c: Update.
4858 * gnulib/import/readdir.c: Update.
4859 * gnulib/import/readlink.c: Update.
4860 * gnulib/import/realloc.c: Update.
4861 * gnulib/import/ref-add.sin: Update.
4862 * gnulib/import/ref-del.sin: Update.
4863 * gnulib/import/rename.c: Update.
4864 * gnulib/import/rewinddir.c: Update.
4865 * gnulib/import/rmdir.c: Update.
4866 * gnulib/import/same-inode.h: Update.
4867 * gnulib/import/save-cwd.c: Update.
4868 * gnulib/import/save-cwd.h: Update.
4869 * gnulib/import/scratch_buffer.h: Update.
4870 * gnulib/import/secure_getenv.c: Update.
4871 * gnulib/import/setenv.c: Update.
4872 * gnulib/import/signal.in.h: Update.
4873 * gnulib/import/stat-time.c: Update.
4874 * gnulib/import/stat-time.h: Update.
4875 * gnulib/import/stat-w32.c: Update.
4876 * gnulib/import/stat-w32.h: Update.
4877 * gnulib/import/stat.c: Update.
4878 * gnulib/import/stdbool.in.h: Update.
4879 * gnulib/import/stddef.in.h: Update.
4880 * gnulib/import/stdint.in.h: Update.
4881 * gnulib/import/stdio.in.h: Update.
4882 * gnulib/import/stdlib.in.h: Update.
4883 * gnulib/import/str-two-way.h: Update.
4884 * gnulib/import/strchrnul.c: Update.
4885 * gnulib/import/strdup.c: Update.
4886 * gnulib/import/streq.h: Update.
4887 * gnulib/import/strerror-override.c: Update.
4888 * gnulib/import/strerror-override.h: Update.
4889 * gnulib/import/strerror.c: Update.
4890 * gnulib/import/string.in.h: Update.
4891 * gnulib/import/stripslash.c: Update.
4892 * gnulib/import/strnlen1.c: Update.
4893 * gnulib/import/strnlen1.h: Update.
4894 * gnulib/import/strstr.c: Update.
4895 * gnulib/import/strtok_r.c: Update.
4896 * gnulib/import/sys_stat.in.h: Update.
4897 * gnulib/import/sys_time.in.h: Update.
4898 * gnulib/import/sys_types.in.h: Update.
4899 * gnulib/import/tempname.c: Update.
4900 * gnulib/import/tempname.h: Update.
4901 * gnulib/import/time.in.h: Update.
4902 * gnulib/import/unistd--.h: Update.
4903 * gnulib/import/unistd-safer.h: Update.
4904 * gnulib/import/unistd.in.h: Update.
4905 * gnulib/import/unsetenv.c: Update.
4906 * gnulib/import/verify.h: Update.
4907 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4908 * gnulib/import/wchar.in.h: Update.
4909 * gnulib/import/wctype.in.h: Update.
4910 * gnulib/import/xalloc-oversized.h: Update.
4911 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4912 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4914 2018-08-16 Gary Benson <gbenson@redhat.com>
4917 * gdb/main.c (captured_main_1): Exit with nonzero status
4918 in batch mode if the last command to be executed failed.
4919 * NEWS: Mention the above.
4921 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
4923 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
4924 end of warning message.
4926 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4929 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
4930 (aarch64_extract_return_value): Use
4931 aapcs_is_vfp_call_or_return_candidate.
4932 (aarch64_return_in_memory): Likewise.
4933 (aarch64_store_return_value): Likewise.
4935 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4938 (aapcs_is_vfp_call_or_return_candidate): Make static
4939 (pass_in_v_or_stack): Remove function.
4940 (pass_in_v_vfp_candidate): New function.
4941 (aarch64_push_dummy_call): Check for float register candidates.
4943 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4945 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
4946 (aapcs_is_vfp_call_or_return_candidate_1): New function.
4947 (aapcs_is_vfp_call_or_return_candidate): Likewise.
4949 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4952 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
4953 (struct ipa_sym_addresses): Rename to...
4954 (struct ipa_sym_addresses_common): ... this.
4955 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
4957 2018-08-28 Tom Tromey <tom@tromey.com>
4959 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4960 (token_fifo): Now a std::vector.
4961 (yylex, c_parse): Update.
4962 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4963 (token_fifo): Now a std::vector.
4964 (yylex, d_parse): Update.
4965 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4966 (token_fifo): Now a std::vector.
4967 (yylex, go_parse): Update.
4969 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
4971 * parser-defs.h (struct type_stack) <elements>: Change type to
4972 std::vector<union type_stack_elt>.
4973 <depth, size>: Remove.
4974 * parse.c (parse_exp_in_context_1): Adjust.
4975 (type_stack_reserve): Remove.
4976 (check_type_stack_depth): Remove.
4977 (insert_into_type_stack): Adjust to std::vector.
4978 (insert_type): Likewise.
4979 (push_type): Likewise.
4980 (push_type_int): Likewise.
4981 (insert_type_address_space): Likewise.
4982 (pop_type): Likewise.
4983 (pop_type_int): Likewise.
4984 (pop_typelist): Likewise.
4985 (pop_type_stack): Likewise.
4986 (append_type_stack): Likewise.
4987 (push_type_stack): Likewise.
4988 (get_type_stack): Likewise.
4989 (type_stack_cleanup): Likewise.
4990 (push_typelist): Likewise.
4991 (follow_types): Likewise.
4992 (_initialize_parse): Likewise.
4994 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
4996 * NEWS: Mention csky target.
4998 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
4999 Hafiz Abid Qadeer <abidh@codesourcery.com>
5000 Don Breazeal <donb@codesourcery.com>
5002 * csky-linux-tdep.c: New file.
5003 * csky-tdep.c: Likewise.
5004 * csky-tdep.h: Likewise.
5005 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
5007 (HFILES_NO_SRCDIR): Add csky-tdep.h.
5008 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
5009 * configure.tgt: Add csky support.
5011 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
5013 * python/py-framefilter.c (py_print_frame): Print frame architecture
5014 when printing on an MI output.
5016 2018-08-27 Tom Tromey <tom@tromey.com>
5019 * configure: Rebuild.
5020 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
5022 2018-08-27 Tom Tromey <tom@tromey.com>
5024 * aarch64-linux-tdep.c
5025 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
5028 2018-08-27 Tom Tromey <tom@tromey.com>
5030 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
5032 (ppc64_standard_linkage1, ppc64_standard_linkage2)
5033 (ppc64_standard_linkage3, ppc64_standard_linkage4)
5034 (ppc64_standard_linkage5, ppc64_standard_linkage6)
5035 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
5038 2018-08-27 Tom Tromey <tom@tromey.com>
5040 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
5041 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
5043 2018-08-27 Tom Tromey <tom@tromey.com>
5045 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
5046 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
5048 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
5050 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
5052 * sparc-linux-tdep.c (sparc32_linux_sigframe)
5053 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
5054 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
5056 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
5057 (ppc64_linux_sigaction_tramp_frame)
5058 (ppc32_linux_sighandler_tramp_frame)
5059 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
5060 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
5061 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
5062 * mn10300-linux-tdep.c (am33_linux_sigframe)
5063 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
5064 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
5065 * mips-linux-tdep.c (mips_linux_o32_sigframe)
5066 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
5067 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
5068 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
5069 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
5070 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
5071 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
5072 * microblaze-linux-tdep.c
5073 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
5074 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
5075 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
5076 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
5077 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
5078 * common/common-types.h (ULONGEST_MAX): New define.
5079 (CORE_ADDR_MAX): Fix formatting.
5080 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
5081 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
5082 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
5083 (arm_linux_rt_sigreturn_tramp_frame)
5084 (arm_eabi_linux_sigreturn_tramp_frame)
5085 (arm_eabi_linux_rt_sigreturn_tramp_frame)
5086 (thumb2_eabi_linux_sigreturn_tramp_frame)
5087 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
5088 (arm_linux_restart_syscall_tramp_frame)
5089 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
5090 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
5091 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
5093 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
5095 2018-08-27 Tom Tromey <tom@tromey.com>
5097 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
5099 * mips-tdep.c (mips_deal_with_atomic_sequence)
5100 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
5101 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
5102 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
5103 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
5105 * aarch64-tdep.c (aarch64_software_single_step): Use
5108 2018-08-27 Tom Tromey <tom@tromey.com>
5110 * linespec.c (complete_linespec_component): Add cast to "char".
5111 * completer.c (completion_tracker::build_completion_result): Add
5114 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5116 * solist.h (struct solist, struct target_so_ops): Fix
5119 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5121 * ada-tasks.c (ada_task_info_s): Remove typedef.
5122 (DEF_VEC_O(ada_task_info_s)): Remove.
5123 (struct ada_tasks_inferior_data): Initialize fields.
5124 <task_list>: Make an std::vector.
5125 (get_ada_tasks_inferior_data): Allocate with new.
5126 (ada_get_task_number): Adjust.
5127 (get_task_number_from_id): Likewise.
5128 (valid_task_id): Likewise.
5129 (ada_get_task_info_from_ptid): Likewise.
5130 (iterate_over_live_ada_tasks): Likewise.
5131 (add_ada_task): Likewise.
5132 (read_known_tasks): Likewise.
5133 (ada_build_task_list): Likewise.
5134 (print_ada_task_info): Likewise.
5135 (info_task): Likewise.
5136 (task_command_1): Likewise.
5138 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5140 * ada-lang.c (add_angle_brackets): Return std::string.
5142 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
5144 * python/py-threadevent.c (py_get_event_thread): Initialize
5147 2018-08-24 Pedro Alves <palves@redhat.com>
5149 * python/py-bpevent.c (create_breakpoint_event_object): Use
5150 copy-initialization.
5151 * python/py-continueevent.c (emit_continue_event): Use
5152 copy-initialization.
5153 * python/py-exitedevent.c (create_exited_event_object): Return a
5155 (emit_exited_event): Use copy-initialization.
5156 * python/py-inferior.c (python_new_inferior)
5157 (python_inferior_deleted, add_thread_object): Use
5158 copy-initialization.
5159 * python/py-infevents.c (create_inferior_call_event_object)
5160 (create_register_changed_event_object)
5161 (create_memory_changed_event_object): Return a gdbpy_ref<>.
5162 (emit_inferior_call_event, emit_memory_changed_event)
5163 (emit_register_changed_event): Use copy-initialization.
5164 * python/py-newobjfileevent.c (create_new_objfile_event_object):
5165 Return a gdbpy_ref<>.
5166 (emit_new_objfile_event): Use copy-initialization.
5167 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
5168 (emit_clear_objfiles_event): Use copy-initialization.
5169 * python/py-signalevent.c (create_signal_event_object): Use
5170 copy-initialization.
5171 * python/py-threadevent.c (create_thread_event_object): Use
5172 copy-initialization.
5174 2018-08-24 Pedro Alves <palves@redhat.com>
5175 Simon Marchi <simon.marchi@ericsson.com>
5178 * python/py-continueevent.c: Include "gdbthread.h".
5179 (create_continue_event_object): Add intro comment. Add 'ptid'
5180 parameter. Use it to find thread to pass to
5181 create_thread_event_object.
5182 (emit_continue_event): Pass PTID down to
5183 create_continue_event_object.
5184 * python/py-event.h (py_get_event_thread): Declare.
5185 (create_thread_event_object): Remove default from 'thread'
5187 * python/py-stopevent.c (create_stop_event_object): Use
5188 py_get_event_thread.
5189 * python/py-threadevent.c (get_event_thread): Rename to ...
5190 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
5191 and use it to find the thread.
5192 (create_thread_event_object): Assert that THREAD isn't null.
5193 Don't find the event thread here.
5195 2018-08-23 Kevin Buettner <kevinb@redhat.com>
5197 * block.h (blockrange, blockranges): New struct declarations.
5198 (struct block): Add new field named `ranges'.
5199 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
5200 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
5201 macros for accessing ranges in struct block.
5202 (make_blockranges): New declaration.
5203 block.c (make_blockranges): New function.
5204 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
5206 * symtab.h (find_pc_partial_function): Add new parameter `block'.
5207 * blockframe.c (cache_pc_function_block): New static global.
5208 (clear_pc_function_cache): Clear cache_pc_function_block.
5209 (find_pc_partial_function): Move comment to symtab.h. Add
5210 support for non-contiguous blocks.
5211 * cli/cli-cmds.c (block.h): Include.
5212 (print_disassembly): Handle printing of non-contiguous blocks.
5213 (disassemble_current_function): Likewise.
5214 (disassemble_command): Likewise.
5216 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
5218 * blockframe.c (get_pc_function_start): Likewise.
5219 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
5220 (gcc_symbol_address): Likewise.
5221 * compile/compile-object-run.c (compile_object_run): Likewise.
5222 * compile/compile.c (get_expr_block_and_pc): Likewise.
5223 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
5224 (func_addr_to_tail_call_list): Likewise.
5225 * findvar.c (default_read_var_value): Likewise.
5226 * inline-frame.c (inline_frame_this_id): Likewise.
5227 (skip-inline_frames): Likewise.
5228 * infcmd.c (until_next_command): Likewise.
5229 * linespec.c (convert_linespec_to_sals): Likewise.
5230 * parse.c (parse_exp_in_context_1): Likewise.
5231 * printcmd.c (build_address_symbolic): likewise.
5232 (info_address_command): Likewise.
5233 symtab.c (find_function_start_sal): Likewise.
5234 (skip_prologue_sal): Likewise.
5235 (find_function_alias_target): Likewise.
5236 (find_gnu_ifunc): Likewise.
5237 * stack.c (find_frame_funname): Likewise.
5238 * symtab.c (fixup_symbol_section): Likewise.
5239 (find_function_start_sal): Likewise.
5240 (skip_prologue_sal): Likewsie.
5241 (find_function_alias_target): Likewise.
5242 (find_gnu_ifunc): Likewise.
5243 * tracepoint.c (info_scope_command): Likewise.
5244 * value.c (value_fn_field): Likewise.
5246 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
5247 in place of find_pc_partial_function.
5248 * blockframe.c (find_function_entry_range_from_pc): New function.
5249 * symtab.h (find_function_entry_range_from_pc): Declare and document.
5250 * objfiles.c (objfile_relocate1): Relocate start and end addresses
5251 for each range in a block.
5254 2018-08-23 Xavier Roirand <roirand@adacore.com>
5256 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
5259 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5261 * solib-svr4.c (read_program_headers_from_bfd): Return
5262 gdb::optional<gdb::byte_vector>.
5263 (svr4_exec_displacement): Adjust.
5265 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5267 * solib-svr4.c (read_program_header): Return
5268 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
5269 (find_program_interpreter): Return
5270 gdb::optional<gdb::byte_vector>.
5271 (scan_dyntag_auxv): Adjust.
5272 (enable_break): Adjust.
5273 (svr4_exec_displacement): Adjust.
5275 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5277 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
5278 * inf-child.c (inf_child_target::terminal_save_inferior): New.
5280 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5282 * guile/scm-string.c (gdbscm_scm_from_printf): Use
5284 * guile/scm-utils.c (gdbscm_printf): Likewise.
5285 * serial.c (serial_printf): Likewise.
5286 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
5288 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
5290 * stack.c (print_frame): Print frame architecture when printing on
5292 * NEWS: Mention new "arch" attribute in frame output.
5294 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5296 * arch/aarch64.h (aarch64_regnum): Update comment.
5298 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5300 * NEWS: Add SVE to 8.2 section.
5302 2018-08-21 Pedro Alves <palves@redhat.com>
5304 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
5305 out from gdbscm_parse_function_args.
5306 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
5307 gdbscm_parse_function_args_1.
5309 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
5312 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
5315 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
5317 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
5319 2018-08-19 Michael Spang <spang@google.com>
5322 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
5323 for PT_TLS segments.
5325 2018-08-18 Kevin Buettner <kevinb@redhat.com>
5327 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
5328 dwarf_variable_value.
5329 * dwarf2-frame.c (class dwarf_expr_executor):
5330 Add override for dwarf_variable_value.
5331 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
5332 (class symbol_needs_eval_context): Likewise.
5333 (indirect_synthetic_pointer): Add forward declaration.
5334 (sect_variable_value): New function.
5335 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
5336 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
5337 for DW_OP_GNU_variable_value.
5339 2018-08-16 Tom Tromey <tom@tromey.com>
5341 * top.c (read_command_file): Update.
5342 (command_line_input): Remove "repeat" argument.
5343 * ada-lang.c (get_selections): Update.
5344 * linespec.c (decode_line_2): Update.
5345 * defs.h (command_line_input): Remove argument.
5346 * cli/cli-script.c (read_next_line): Update.
5347 * python/py-gdb-readline.c: Update.
5349 2018-08-17 Tom Tromey <tom@tromey.com>
5351 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
5354 2018-08-15 Tom Tromey <tom@tromey.com>
5356 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
5358 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
5360 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
5361 If used, use find_pc_partial_function to find address range
5363 * mi/mi-main.c (mi_cmd_list_features): Report
5364 "data-disassemble-a-option" feature.
5365 * NEWS: Mention new -data-disassemble option -a.
5367 2018-08-13 Tom Tromey <tom@tromey.com>
5369 * common/common-defs.h (_FORTIFY_SOURCE): Define.
5371 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5373 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
5374 (aarch64_linux_collect_sve_regset): Likewise.
5375 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
5376 * regcache.h (regcache_map_entry_size): New function.
5378 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5380 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
5381 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
5382 (SVE_HEADER_VL_LENGTH): Likewise.
5383 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
5384 (SVE_HEADER_FLAGS_LENGTH): Likewise.
5385 (SVE_HEADER_RESERVED_LENGTH): Likewise.
5386 (SVE_HEADER_SIZE_OFFSET): Likewise.
5387 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
5388 (SVE_HEADER_VL_OFFSET): Likewise.
5389 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
5390 (SVE_HEADER_FLAGS_OFFSET): Likewise.
5391 (SVE_HEADER_RESERVED_OFFSET): Likewise.
5392 (SVE_HEADER_SIZE): Likewise.
5393 (aarch64_linux_core_read_vq): Add function.
5394 (aarch64_linux_core_read_description): Check for SVE section.
5396 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5398 * aarch64-fbsd-tdep.c
5399 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
5401 * aarch64-linux-tdep.c
5402 (aarch64_linux_iterate_over_regset_sections): Likewise.
5403 * alpha-linux-tdep.c
5404 (alpha_linux_iterate_over_regset_sections):
5406 (alphanbsd_iterate_over_regset_sections): Likewise.
5408 (amd64fbsd_iterate_over_regset_sections): Likewise.
5409 * amd64-linux-tdep.c
5410 (amd64_linux_iterate_over_regset_sections): Likewise.
5412 (armbsd_iterate_over_regset_sections): Likewise.
5414 (arm_fbsd_iterate_over_regset_sections): Likewise.
5416 (arm_linux_iterate_over_regset_sections): Likewise.
5417 * corelow.c (get_core_registers_cb): Likewise.
5418 (core_target::fetch_registers): Likewise.
5419 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
5420 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
5421 * gdbarch.h (void): Regenerate.
5422 * gdbarch.sh: Add supply_size and collect_size.
5423 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
5424 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
5425 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
5426 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
5427 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
5428 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
5429 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
5430 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
5431 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
5432 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
5433 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
5434 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
5435 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
5436 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
5437 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections):
5439 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
5440 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
5441 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
5442 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
5443 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
5444 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
5445 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections):
5447 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
5448 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
5449 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
5450 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
5451 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
5452 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
5453 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
5454 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
5456 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
5458 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
5461 2018-08-10 Keith Seitz <keiths@redhat.com>
5463 * compile/compile-c-support.c (add_code_header, add_code_footer):
5464 Move into policy class.
5465 (c_push_user_expression, pop_user_expression_nop)
5466 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
5467 (compile_program): New host class.
5468 (c_compile_program): New typedef.
5469 (c_compute_porgram): Use c_compile_program.
5471 2018-08-10 Keith Seitz <keiths@redhat.com>
5473 * compile/compile-internal.h (compile_instance::~compile_instance):
5474 Remove calls to htab_delete.
5475 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
5476 * compile.c (compile_instance::compile_instance): Initialize
5477 htab unique pointers.
5478 (compile_instance::get_cached_type, compile_instance::insert_type)
5479 (compile_instance::error_symbol_once): Update for unique_ptr.
5481 2018-08-10 Keith Seitz <keiths@redhat.com>
5483 * compile/compile-c-symbols.c (struct symbol_error)
5484 (hash_symbol_error, eq_symbol_error, del_symbol_error)
5485 (compile_instance::insert_symbol_error)
5486 (compile_instance::error_symbol_once): Move to ...
5487 * compile/compile.c: ... here.
5489 2018-08-10 Keith Seitz <keiths@redhat.com>
5491 * compile/compile-c-support.c (c_get_compile_context): Use `new'
5492 instead of `new_compile_instance'.
5493 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
5495 If the symbol error map is not initialized, create it.
5496 (generate_c_for_for_one_symbol): Do not check/initialize
5497 the symbol error map.
5498 * compile/compile-c-types.c (compile_c_instance): Make a class.
5500 (compile_instance::compile_instance): Initialize the type cache.
5501 (get_cached_type): New function.
5502 (insert_type): Update description.
5503 (compile_c_instance::m_default_cflags): Define.
5504 (convert_type): Update description. Use get_cached_type.
5505 (delete_instance): Moved to destructor.
5506 (new_compile_instance): Moved to constructor.
5507 * compile/compile-c.h (compile_c_instance): Make class inheriting
5508 from compile_instance.
5509 <base>: Remove field.
5510 <type_map, symbol_err_map>: Move to base class.
5511 <c_plugin>: Rename to `m_plugin' and remove pointer type.
5512 * compile/compile-internal.h (compile_instance): Make class.
5513 <type_map_t, symbol_err_map_t>: Define.
5514 <fe>: Rename to `m_gcc_fe'.
5515 <scope, block, gcc_target_options>: Add `m_' prefix.
5516 <m_type_map, m_symbol_err_map>: New fields, moved from
5519 (convert_type, new_compile_instance): Remove.
5520 * compile/compile.c (cleanup_compile_instance): Remove.
5521 (compile_to_object): Use unique_ptr to eliminate cleanups.
5522 (compile_instance::set_print_callback, compile_instance::version)
5523 (compile_instance::set_verbose)
5524 (compile_instance::set_driver_filename)
5525 (compile_instance::set_triplet_regexp)
5526 (compile_instance::set_arguments)
5527 (compile_instance::set_source_file)
5528 (compile_instance::compile): Define.
5530 2018-08-10 Keith Seitz <keiths@redhat.com>
5532 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
5533 * compile/compile-c-types.c: Define GCC_METHODN macros and include
5534 gcc-c-fe.def to define C plugin.
5535 (delete_instance): Delete `c_plugin'.
5536 (new_compile_instance): Initialize `c_plugin'.
5537 * compile/compile-c.h: Include gcc_c_plugin.h.
5538 (struct compile_c_instance) <c_plugin>: New member.
5539 * gcc-c-plugin.h: New file.
5540 Update all callers with API change.
5542 2018-08-10 Keith Seitz <keiths@redhat.com>
5544 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
5545 (HFILES_NO_SRCDIR): ... to here.
5546 Add compile-internal.h and compile-c.h.
5547 * compile/compile-c-support.c: Include compile-c.h.
5548 * compile/compile-c-symbols.c: Include compile-c.h.
5549 (generate_c_for_variable_locations): Update comment.
5550 * compile/compile-c-types.c: Include compile-c.h.
5551 * compile/compile-c.h: New file -- moved C language declarations
5552 from other files here.
5553 * compile/compile-internal.h: Do not include hashtab.h or
5554 common/enum-flags.h.
5555 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
5556 (gcc_convert_symbol, gcc_symbol_address)
5557 (generate_c_for_variable_locations, c_get_mode_for_size)
5558 (c_get_range_decl_name): Definitions moved to compile-c.h.
5559 * compile/compile-loc2c.c: Include compile-c.h.
5561 2018-08-10 Keith Seitz <keiths@redhat.com>
5563 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
5564 (c_symbol_substitution_name): ... this.
5567 2018-08-10 Keith Seitz <keiths@redhat.com>
5569 * compile/compile-c-support.c (c_compute_program): Use
5570 unique_xmalloc_ptr to eliminate cleanup.
5571 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
5572 Return a unique_xmalloc_ptr and eliminate cleanup.
5573 * compile/compile-internal.h (generate_c_for_variable_locations):
5574 Return unique_xmalloc_ptr and update description.
5576 2018-08-10 Alan Hayward <alan.hayward@arm.com>
5578 * corelow.c (core_target::get_core_register_section): Rename
5579 min_size to section_min_size.
5581 2018-08-09 Jim Wilson <jimw@sifive.com>
5583 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
5584 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
5585 * NEWS: Mention new GNU/Linux RISC-V target.
5586 * configure.host: Add riscv*-*-linux*.
5587 * configure.nat: Add riscv*.
5588 * configure.tgt: Add riscv*-*-linux*.
5589 * riscv-linux-nat.c: New file.
5590 * riscv-linux-tdep.c: New file.
5592 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5594 * infrun.c (resume): Make static, add forward declaration.
5595 (proceed): Update header comment.
5596 * infrun.h (resume): Delete declaration.
5598 2018-08-09 Tom Tromey <tom@tromey.com>
5600 * riscv-tdep.h: Minor formatting fixes.
5602 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
5604 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
5605 * dwarf-index-cache.c (create_dir_and_check): Likewise.
5606 (test_mkdir_recursive): Likewise.
5607 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
5609 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5611 * valarith.c (value_subscripted_rvalue): If an array is not in
5612 memory, and we don't know the upper bound, then we can't know that
5613 the requested element exists or not.
5615 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
5617 * target.c (str_comma_list_concat_elem): Fix typo in comment.
5618 (target_options_to_string): Add comment.
5620 2018-08-08 Tom Tromey <tom@tromey.com>
5622 * unittests/scoped_mmap-selftests.c: Check result of "write".
5624 2018-08-08 Jim Wilson <jimw@sifive.com>
5626 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
5627 (decode_register_index_short): New.
5628 (decode_j_type_insn, decode_cj_type_insn): New.
5629 (decode_b_type_insn, decode_cb_type_insn): New.
5630 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
5631 local xlen. Check xlen when decoding ambiguous compressed insns. In
5632 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
5633 is_c_sw_insn instead of is_sw_insn.
5634 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
5635 (riscv_software_single_step): New.
5636 * riscv-tdep.h (riscv_software_single_step): Declare.
5638 * riscv-tdep.c (riscv_isa_xlen): Drop static.
5639 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
5641 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
5644 * target.c (dispose_inferior): Don't dispose of inferiors that are
5647 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
5649 * remote.c (remote_target::download_tracepoint): Change char* to
5652 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
5654 * target.h (target_options_to_string): Return an std::string.
5655 * target.c (str_comma_list_concat_elem): Return void, use
5657 (do_option): Likewise.
5658 (target_options_to_string): Return an std::string.
5659 * linux-nat.c (linux_nat_target::wait): Adjust.
5660 * target-debug.h (target_debug_print_options): Adjust.
5662 2018-08-07 Tom Tromey <tom@tromey.com>
5664 * Makefile.in (CPPFLAGS): New variable.
5665 (INTERNAL_CPPFLAGS): Use it.
5667 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5669 * NEWS: Mention the index cache.
5671 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5673 * common/pathstuff.h (get_standard_cache_dir): New.
5674 * common/pathstuff.c (get_standard_cache_dir): New.
5675 * build-id.h (build_id_to_string): New.
5676 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
5677 DEBUG_STR_SUFFIX): Move to here.
5678 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
5679 DEBUG_STR_SUFFIX): Move from there.
5680 (write_psymtabs_to_index): Make non-static, add basename
5681 parameter. Write to temporary files, rename when done.
5682 (save_gdb_index_command): Adjust call to
5683 write_psymtabs_to_index.
5684 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
5686 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
5687 (get_gdb_index_contents_from_cache): New.
5688 (get_gdb_index_contents_from_cache_dwz): New.
5689 (dwarf2_initialize_objfile): Read index from cache.
5690 (dwarf2_build_psymtabs): Save to index.
5691 * dwarf-index-cache.h: New file.
5692 * dwarf-index-cache.c: New file.
5693 * dwarf-index-write.h: New file.
5695 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5697 * gnulib/aclocal.m4: Re-generate.
5698 * gnulib/config.in: Re-generate.
5699 * gnulib/configure: Re-generate.
5700 * gnulib/import/Makefile.am: Re-generate.
5701 * gnulib/import/Makefile.in: Re-generate.
5702 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
5703 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5704 * gnulib/import/m4/mkdir.m4: New file.
5705 * gnulib/import/mkdir.c: New file.
5706 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
5709 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5711 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
5712 * common/scoped_mmap.c: New file.
5713 * common/scoped_mmap.h (destroy): New method.
5714 (~scoped_mmap, reset): Use destroy.
5715 (scoped_mmap): New move constructor.
5716 (mmap_file): New declaration.
5717 * unittests/scoped_mmap-selftests.c (test_normal,
5718 test_invalid_filename, run_tests): New functions.
5719 (_initialize_scoped_mmap_selftests): Register selftest.
5721 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5723 * dwarf2read.c (read_gdb_index_from_section): Rename to...
5724 (read_gdb_index_from_buffer): ... this. Remove section
5725 parameter, add buffer parameter.
5726 (get_gdb_index_contents_ftype,
5727 get_gdb_index_contents_dwz_ftype): New typedefs.
5728 (dwarf2_read_gdb_index): Add callback parameters to get the
5730 (get_gdb_index_contents_from_section): New.
5731 (dwarf2_initialize_objfile): Update call to
5732 dwarf2_read_gdb_index.
5734 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5736 * common/filestuff.h (gdb_fopen_cloexec): New overload.
5737 (gdb_open_cloexec): Likewise.
5738 * nat/linux-osdata.c (command_from_pid): Use string_printf.
5739 (commandline_from_pid): Likewise.
5740 (linux_xfer_osdata_threads): Likewise.
5741 (linux_xfer_osdata_fds): Likewise.
5742 * ada-lang.c (is_package_name): Likewise.
5743 * auxv.c (procfs_xfer_auxv): Likewise.
5744 * breakpoint.c (print_one_breakpoint_location): Use
5746 (print_one_catch_solib): Use string_printf.
5747 * coff-pe-read.c (add_pe_exported_sym): Likewise.
5748 (add_pe_forwarded_sym): Likewise.
5749 * dwarf2read.c (create_type_unit_group): Likewise.
5750 (build_error_marker_type): Likewise.
5751 * infcall.c (get_function_name): Likewise.
5752 * valprint.c (print_converted_chars_to_obstack): Likewise.
5753 * xtensa-tdep.c (xtensa_register_type): Likewise.
5755 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
5757 * remote.c (remote_target::download_tracepoint): Fix format
5760 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5762 * tracefile.c: Include common/byte-vector.h.
5763 (trace_save): Change type of buf to gdb::byte_vector. Initialize
5764 with trace_regblock_size if needed. Update uses of buf.
5766 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5768 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
5769 std::vector<unsigned char>.
5770 * tracepoint.c (collection_list::collection_list): Remove
5771 m_regs_mask initializer from initializer list. Resize
5772 m_regs_mask using the largest remote register number.
5773 (collection_list::add_remote_register): Remove size check on
5774 m_regs_mask. Use at to access element.
5775 (collection_list::stringify): Change type of temp_buf to
5776 gdb::char_vector. Update uses of temp_buf. Resize if needed to
5777 stringify the register mask. Use pack_hex_byte for the register
5780 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5782 * tracepoint.h (class collection_list) <add_register>: Remove.
5783 <add_remote_register, add_ax_registers, add_local_register>:
5785 <add_memrange>: Add scope parameter.
5786 * tracepoint.c (encode_actions_1): Likewise.
5787 (collection_list::add_register): Rename to ...
5788 (collection_list::add_remote_register): ... this. Update
5790 (collection_list::add_ax_registers, add_local_register): New
5792 (collection_list::add_memrange): Add scope parameter. Call
5793 add_local_register instead of add_register.
5794 (finalize_tracepoint_aexpr): New function.
5795 (collection_list::collect_symbol): Update calls to add_memrange.
5796 Call add_local_register instead of add_register. Call
5797 add_ax_registers. Call finalize_tracepoint_aexpr.
5798 (encode_actions_1): Get remote regnos for $reg action. Call
5799 add_remote_register, add_ax_registers, and add_local_register.
5800 Update call to add_memrange. Call finalize_tracepoint_aexpr.
5801 (validate_actionline): Call finalize_tracepoint_aexpr.
5803 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5805 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
5806 Replace array buf with gdb::char_vector buf, of size
5807 get_remote_packet_size (). Replace references to buf and
5808 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
5809 and xsnprintf with snprintf. Raise errors if the buffer is too
5812 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5814 * remote.c (remote_target::download_tracepoint): Fix the has_more
5815 predicate in the QTDP action list iteration.
5817 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5819 * remote.c (remote_target::download_tracepoint): Fix indentation
5822 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5824 * proc-api.c (_initialize_proc_api): Remove c, unused.
5825 * procfs.c (procfs_init_inferior): Remove signals, unused.
5826 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
5829 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
5830 Andrew Burgess <andrew.burgess@embecosm.com>
5832 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
5833 'W_STOPCODE (0)' as this could be ambiguous.
5835 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
5837 * ser-tcp.c (net_open): Fix thinko when deciding whether to
5838 disable TCP's Nagle algorithm (use "ai_protocol" instead of
5841 2018-08-02 Tom Tromey <tom@tromey.com>
5844 * dwarf2read.c (read_func_scope): Set symtab on template parameter
5846 (process_structure_scope): Likewise.
5848 2018-08-02 Xavier Roirand <roirand@adacore.com>
5851 * darwin-nat.c (darwin_kill_inferior): Fix handling of
5854 2018-08-02 Tom Tromey <tom@tromey.com>
5856 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
5857 (darwin_suspend_inferior, darwin_resume_inferior)
5858 (darwin_decode_notify_message, darwin_resume_inferior_threads)
5859 (darwin_check_new_threads): Check result of get_darwin_inferior.
5861 2018-07-31 Joel Brobecker <brobecker@adacore.com>
5865 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
5867 * varobj.c (varobj_get_path_expr_parent): Report an error if
5868 parent is a dynamic varobj.
5870 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5872 * gnulib/aclocal.m4: Re-generate.
5873 * gnulib/config.in: Re-generate.
5874 * gnulib/configure: Re-generate.
5875 * gnulib/import/Makefile.in: Re-generate.
5876 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5877 * gnulib/import/m4/onceonly.m4: Re-generate.
5879 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5881 * target-descriptions.c (struct xml_test_tdesc): New.
5882 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
5883 (record_xml_tdesc): Update.
5884 (maintenance_check_xml_descriptions): Update.
5885 * target-descriptions.h (record_xml_tdesc): Update comment.
5887 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
5889 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
5890 checking array bounds are defined.
5892 2018-07-30 Tom Tromey <tom@tromey.com>
5894 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
5895 irreflexivity violation.
5897 2018-07-30 Tom Tromey <tom@tromey.com>
5899 * cli/cli-decode.c (lookup_cmd): Remove lint code.
5900 * value.c (unpack_long): Remove lint code.
5901 * valops.c (value_ind): Remove lint code.
5902 * valarith.c (value_x_binop, value_x_unop, value_equal)
5903 (value_pos): Remove lint code.
5905 2018-07-28 Tom de Vries <tdevries@suse.de>
5907 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
5908 with undefined upper bound as <optimized out>.
5910 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
5912 * gcore.in: Rename variable "name" to "prefix". Expand
5915 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
5917 * windows-nat.c (windows_nat_target::create_inferior): Update to
5918 call close() in global namespace.
5920 2018-07-26 Tom Tromey <tom@tromey.com>
5922 * dwarf-index-write.c (add_address_entry): Don't add objfile
5924 * dbxread.c (find_stab_function): Rename from
5925 find_stab_function_addr. Return a bound_minimal_symbol.
5926 (read_dbx_symtab): Use raw_text_low, raw_text_high.
5927 Don't add objfile offsets.
5928 (end_psymtab): Use raw_text_low, raw_text_high,
5929 MSYMBOL_VALUE_RAW_ADDRESS.
5930 (read_ofile_symtab): Update.
5931 (process_one_symbol): Update.
5932 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
5934 (dw2_relocate): Remove.
5935 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
5937 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
5939 (process_psymtab_comp_unit_reader, add_partial_symbol)
5940 (add_partial_subprogram, dwarf2_ranges_read): Update.
5941 (load_partial_dies): Update.
5942 (add_address_entry): Don't add objfile offsets.
5943 (dwarf2_build_include_psymtabs): Update.
5944 (create_addrmap_from_aranges): Don't add objfile offsets.
5945 (dw2_find_pc_sect_compunit_symtab): Update.
5946 * mdebugread.c (parse_symbol): Don't add objfile offsets.
5947 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
5949 (parse_partial_symbols): Don't add objfile offsets. Use
5950 raw_text_low, raw_text_high. Update.
5951 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
5952 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
5953 or call 'relocate' quick function. Clear psymbol_map.
5954 * psympriv.h (struct partial_symbol) <address>: Add section
5956 <set_unrelocated_address>: Rename from set_address.
5957 <raw_text_low, raw_text_high>: New methods.
5958 <text_low, text_high>: Add objfile parameter.
5959 (add_psymbol_to_bcache): Add 'section' parameter. Call
5960 set_unrelocated_address.
5961 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5962 (find_pc_psymbol): Update.
5963 (fixup_psymbol_section, relocate_psymtabs): Remove.
5964 (dump_psymtab, psym_functions): Update.
5965 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
5967 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
5968 (start_psymtab_common): Update.
5969 * symfile-debug.c (debug_qf_relocate): Remove.
5970 (debug_sym_quick_functions): Update.
5971 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
5972 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
5975 2018-07-26 Tom Tromey <tromey@redhat.com>
5977 * dbxread.c (end_psymtab): Use text_high_valid and
5979 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
5980 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
5981 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5983 <text_low_valid, text_high_valid>: New fields.
5984 <set_text_low, set_text_high>: Update.
5985 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
5987 2018-07-26 Tom Tromey <tom@tromey.com>
5989 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
5991 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
5992 textlow and texthigh fields.
5993 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
5995 * mdebugread.c (parse_lines, parse_partial_symbols)
5996 (psymtab_to_symtab_1): Update.
5997 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5998 Rename fields. Update comment. Now private.
5999 <text_low, text_high, set_text_low, set_text_high>: New methods.
6000 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
6001 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
6002 (start_psymtab_common, maintenance_info_psymtabs)
6003 (maintenance_check_psymtabs): Update.
6004 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
6006 (scan_xcoff_symtab): Update.
6008 2018-07-26 Tom Tromey <tromey@redhat.com>
6010 * psympriv.h (struct partial_symbol) <unrelocated_address,
6011 address, set_address>: New methods.
6012 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
6013 (fixup_psymbol_section, relocate_psymtabs): Update.
6014 (print_partial_symbols): Add 'objfile' parameter. Update.
6015 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
6018 2018-07-26 Tom Tromey <tom@tromey.com>
6020 * dwarf-index-write.c (write_psymbols, debug_names::insert)
6021 (debug_names::write_psymbols): Update.
6022 * psympriv.h (struct partial_symbol): Derive from
6023 general_symbol_info.
6024 <obj_section>: New method.
6025 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
6026 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
6027 (find_pc_sect_psymbol, fixup_psymbol_section)
6028 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
6029 (print_partial_symbols, recursively_search_psymtabs)
6030 (compare_psymbols, psymbol_hash, psymbol_compare)
6031 (add_psymbol_to_bcache, maintenance_check_psymtabs)
6032 (psymbol_name_matches, psym_fill_psymbol_map): Update.
6034 2018-07-26 Tom Tromey <tromey@redhat.com>
6036 * dbxread.c (end_psymtab): Remove dead code.
6038 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
6040 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
6041 DWARF unwinders are disabled.
6042 * dwarf2-frame.c: Add dwarf2read.h include.
6043 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
6045 (dwarf2_frame_unwinders_enabled_p): Define.
6046 (show_dwarf_unwinders_enabled_p): New function.
6047 (_initialize_dwarf2_frame): Register switch to control DWARF
6049 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
6050 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
6051 (show_dwarf_cmdlist): Remove static keyword.
6052 * dwarf2read.h (set_dwarf_cmdlist): Declare.
6053 (show_dwarf_cmdlist): Declare.
6054 * NEWS: Document new feature.
6056 2018-07-26 Tom de Vries <tdevries@suse.de>
6058 PR breakpoints/23366
6059 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
6061 2018-07-26 Tom de Vries <tdevries@suse.de>
6063 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
6064 DW_AT_count can't be translated to a dynamic prop.
6066 2018-07-25 Tom de Vries <tdevries@suse.de>
6068 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
6071 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
6073 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
6075 2018-07-25 Joel Brobecker <brobecker@adacore.com>
6077 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
6079 2018-07-24 Keith Seitz <keiths@redhat.comt
6082 * dwarf2read.c (dw2_add_symbol_to_list): New function.
6083 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
6084 instead of add_symbol_to_list.
6085 (read_file_scope): Call prepare_one_comp_unit before reading
6088 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
6090 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
6092 2018-07-24 Tom Tromey <tom@tromey.com>
6094 * utils.c (malloc, realloc, free): Don't declare.
6095 * configure, config.in: Rebuild.
6096 * configure.ac: Don't check for declarations of free, malloc, or
6099 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
6101 * aarch64-linux-nat.c
6102 (aarch64_linux_nat_target::stopped_data_address): Remove unused
6104 * arm-linux-nat.c (fetch_regs): Likewise.
6105 (store_regs): Likewise.
6106 (fetch_vfp_regs): Likewise.
6107 (store_vfp_regs): Likewise.
6108 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
6109 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
6110 (arm_linux_nat_target::insert_watchpoint): Likewise.
6111 (arm_linux_nat_target::remove_watchpoint): Likewise.
6112 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
6114 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
6116 * ppc-linux-nat.c (fetch_register): Likewise.
6117 (fetch_all_gp_regs): Likewise.
6118 (fetch_ppc_registers): Likewise.
6119 (store_all_gp_regs): Likewise.
6120 (store_ppc_registers): Likewise.
6121 (hwdebug_insert_point): Likewise.
6122 (can_use_watchpoint_cond_accel): Likewise.
6123 * remote-sim.c (gdb_os_write_stdout): Likewise.
6125 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
6126 Tom Tromey <tom@tromey.com>
6128 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
6130 * configure: Rebuild.
6132 2018-07-22 Tom Tromey <tom@tromey.com>
6134 * regformats/regdat.sh: Define xmltarget_${name} inside
6135 #ifndef IN_PROCESS_AGENT.
6137 2018-07-22 Tom Tromey <tom@tromey.com>
6139 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
6141 2018-07-22 Tom Tromey <tom@tromey.com>
6143 * symfile.c (reread_symbols): Notify iter, not objfile.
6145 2018-07-22 Tom Tromey <tom@tromey.com>
6147 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
6149 (ravenscar_thread_target::prepare_to_store): Likewise.
6151 2018-07-22 Tom Tromey <tom@tromey.com>
6153 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
6154 unused variable. Call value_fetch_lazy when needed.
6155 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
6156 Remove unused variable. Call value_fetch_lazy when needed.
6158 2018-07-22 Tom Tromey <tom@tromey.com>
6160 * m32c-tdep.c (mark_dma): Return void.
6161 (make_regs): Remove unused declarations.
6163 2018-07-22 Tom Tromey <tom@tromey.com>
6165 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
6166 cmdscm_get_valid_command_smob_arg_unsafe for effect.
6167 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
6168 bkscm_get_valid_block_smob_arg_unsafe for effect.
6170 2018-07-22 Tom Tromey <tom@tromey.com>
6172 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
6175 2018-07-22 Tom Tromey <tom@tromey.com>
6177 * windows-nat.c (saved_context): Conditionally define.
6178 * remote.c (remote_target::remote_btrace_maybe_reopen):
6179 Conditionally declare "warned".
6180 * inflow.c (sigquit_ours): Conditionally define.
6181 (new_tty): Move "tty" declaration inside #if.
6182 * guile/guile.c (guile_datadir): Conditionally define.
6183 * charset.c (set_be_le_names): Move some declarations inside #if.
6184 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
6186 (parse_xml_btrace_conf): Likewise.
6188 2018-07-22 Tom Tromey <tom@tromey.com>
6190 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
6192 2018-07-22 Tom Tromey <tom@tromey.com>
6194 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
6195 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
6196 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
6197 * buildsym-legacy.c (get_macro_table): Remove unused variable.
6198 * stack.c (frame_apply_level_command): Remove unused variable.
6199 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
6200 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
6201 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
6203 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
6204 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
6205 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
6207 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
6208 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
6210 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
6211 Remove unused variable.
6212 * cli/cli-script.c (recurse_read_control_structure): Remove unused
6214 * common/tdesc.c (print_xml_feature::visit): Remove unused
6216 * compile/compile-object-load.c (store_regs): Remove unused
6218 * complaints.c (clear_complaints): Remove unused variable.
6219 * corelow.c (core_target_open): Remove unused variable.
6220 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
6222 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
6224 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
6226 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
6228 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
6230 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
6232 * ia64-tdep.c (examine_prologue): Remove unused variable.
6233 * infcall.c (run_inferior_call): Remove unused variable.
6234 * inferior.c (exit_inferior): Remove unused variable.
6235 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
6236 * linespec.c (decode_line_2): Remove unused variable.
6237 * linux-nat.c (super_close): Remove.
6238 * linux-tdep.c (linux_info_proc): Remove unused variable.
6239 * mi/mi-main.c (mi_execute_command): Remove unused variable.
6240 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
6241 Remove unused variable.
6242 * parse.c (find_minsym_type_and_address): Remove unused variable.
6243 * printcmd.c (info_symbol_command, printf_floating): Remove unused
6245 * python/py-breakpoint.c (bppy_set_commands): Remove unused
6247 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
6249 * record-btrace.c (record_btrace_target::store_registers): Remove
6251 (cmd_show_record_btrace_cpu): Remove unused variable.
6252 * riscv-tdep.c (riscv_register_reggroup_p)
6253 (riscv_push_dummy_call, riscv_return_value): Remove unused
6255 * rust-exp.y (literal): Remove unused variable.
6256 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
6258 <STRUCTOP_ANONYMOUS>: Likewise.
6259 * s390-linux-tdep.c (s390_linux_init_abi_31)
6260 (s390_linux_init_abi_64): Remove unused variable.
6261 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
6262 (file_select_thread, net_windows_open, _initialize_ser_windows):
6263 Remove unused variables.
6264 * symtab.c (find_pc_sect_line): Remove unused variable.
6265 * target-memory.c (compute_garbled_blocks): Remove unused
6267 (target_write_memory_blocks): Remove unused variable.
6268 * target.c (target_stack::unpush): Remove unused variables.
6269 * tracepoint.c (start_tracing, all_tracepoint_actions)
6270 (merge_uploaded_trace_state_variables)
6271 (print_one_static_tracepoint_marker): Remove unused variable.
6272 * unittests/basic_string_view/element_access/char/1.cc (test01):
6273 Remove unused variable.
6274 * windows-nat.c (windows_continue, windows_add_all_dlls)
6275 (do_initial_windows_stuff, windows_nat_target::create_inferior):
6276 Remove unused variables.
6278 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
6280 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
6281 attr_profile in HAVE_ELF.
6282 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
6285 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
6287 * frame.c (frame_register_unwind): Change parameter name.
6288 (frame_unwind_register): Likewise.
6289 (frame_unwind_register_value): Likewise.
6290 (frame_unwind_register_signed): Likewise.
6291 (frame_unwind_register_unsigned): Likewise.
6292 * frame.h (frame_register_unwind): Likewise.
6293 (frame_unwind_register): Likewise.
6294 (frame_unwind_register_value): Likewise.
6295 (frame_unwind_register_signed): Likewise.
6296 (frame_unwind_register_unsigned): Likewise.
6297 (frame_unwind_arch): Likewise.
6299 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6301 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
6304 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6306 * mips-linux-nat.c (mips_linux_nat_target::read_description):
6307 Call `get_ptrace_pid' rather than extracting the ptrace PID by
6310 2018-07-20 Keith Seitz <keiths@redhat.com>
6312 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
6313 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
6314 m_compunit_symtab, m_language>: Add "m_" prefix.
6316 * buildsym.c: Update all uses.
6318 2018-07-20 Tom Tromey <tom@tromey.com>
6320 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
6321 * buildsym.h (record_line_ftype): Remove typedef.
6323 2018-07-20 Tom Tromey <tom@tromey.com>
6325 * buildsym-legacy.h (augment_type_symtab): Don't declare.
6326 (end_expandable_symtab): Likewise.
6327 (end_symtab_get_static_block): Likewise.
6328 (end_symtab_from_static_block): Likewise.
6329 * buildsym-legacy.c (augment_type_symtab): Remove.
6330 (end_expandable_symtab): Remove.
6331 (end_symtab_get_static_block): Remove.
6332 (end_symtab_from_static_block): Remove.
6334 2018-07-20 Tom Tromey <tom@tromey.com>
6336 * dwarf2read.c: Include buildsym.h.
6337 (struct dwarf2_cu) <builder>: New method.
6338 (fixup_go_packaging): Update.
6339 (process_full_comp_unit, process_full_type_unit): Update. Don't
6340 use scoped_free_pendings.
6341 (using_directives): Add "cu" parameter, remove "language".
6342 (read_import_statement, setup_type_unit_groups, )
6343 (read_func_scope, read_lexical_block_scope)
6344 (dwarf2_record_block_ranges, read_namespace): Update.
6345 (lnp_state_machine::lnp_state_machine): Add cu parameter.
6346 (lnp_state_machine::handle_end_sequence): Update.
6347 (class lnp_state_machine) <m_cu>: New member.
6348 <m_record_line_callback>: Remove.
6349 <m_currently_recording_lines>: New member.
6350 (lnp_state_machine::handle_set_file): Update.
6351 (noop_record_line): Remove.
6352 (dwarf_record_line_p): Add cu parameter.
6353 (dwarf_record_line_1, dwarf_finish_line): Likewise.
6354 (lnp_state_machine::record_line)
6355 (lnp_state_machine::lnp_state_machine)
6356 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6357 (dwarf_decode_lines): Update.
6358 (dwarf2_start_subfile): Add cu parameter.
6359 (dwarf2_start_symtab, new_symbol): Update.
6360 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
6361 Remove dwarf2_per_objfile parameter.
6362 (dwarf_decode_macros): Update.
6364 2018-07-20 Tom Tromey <tom@tromey.com>
6366 * stabsread.c (define_symbol): Update.
6367 * buildsym-legacy.h (get_buildsym_compunit): Declare.
6368 * dwarf2read.c (new_symbol): Update.
6369 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
6370 * cp-namespace.c: Include buildsym.h.
6371 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
6372 * buildsym-legacy.c (get_buildsym_compunit): New function.
6374 2018-07-20 Tom Tromey <tom@tromey.com>
6376 * xcoffread.c: Include buildsym-legacy.h.
6377 * windows-nat.c: Include buildsym-legacy.h.
6378 * stabsread.c: Include buildsym-legacy.h.
6379 * mdebugread.c: Include buildsym-legacy.h.
6380 * buildsym-legacy.h: New file.
6381 * buildsym-legacy.c: New file, from buildsym.c.
6382 * go32-nat.c: Include buildsym-legacy.h.
6383 * dwarf2read.c: Include buildsym-legacy.h.
6384 * dbxread.c: Include buildsym-legacy.h.
6385 * cp-namespace.c: Include buildsym-legacy.h.
6386 * coffread.c: Include buildsym-legacy.h.
6387 * buildsym.h: Move some contents to buildsym-legacy.h.
6388 * buildsym.c: Include buildsym-legacy.h. Move many functions to
6390 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
6392 2018-07-20 Tom Tromey <tom@tromey.com>
6394 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
6395 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
6396 (buildsym_compunit::buildsym_compunit)
6397 (buildsym_compunit::~buildsym_compunit)
6398 (buildsym_compunit::get_macro_table): Define.
6400 2018-07-20 Tom Tromey <tom@tromey.com>
6402 * buildsym.c (reset_symtab_globals): Remove.
6403 (buildsym_compunit::end_symtab_from_static_block): Update.
6404 (buildsym_compunit::augment_type_symtab): Update.
6405 (end_symtab_from_static_block): Call free_buildsym_compunit.
6406 (augment_type_symtab, end_symtab, end_expandable_symtab):
6409 2018-07-20 Tom Tromey <tom@tromey.com>
6411 * arch-utils.c: Do not include buildsym.h.
6412 * mipsread.c: Do not include buildsym.h.
6413 * machoread.c: Do not include buildsym.h.
6414 * elfread.c: Do not include buildsym.h.
6416 2018-07-20 Tom Tromey <tom@tromey.com>
6418 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
6420 (buildsym_compunit): Add new constructor.
6421 (struct buildsym_compunit) <get_last_source_file, finish_block,
6422 record_block_range, start_subfile, patch_subfile_names,
6423 push_subfile, pop_subfile, record_line, get_compunit_symtab,
6424 set_last_source_start_addr, get_last_source_start_addr,
6425 get_local_using_directives, set_local_using_directives,
6426 get_global_using_directives, outermost_context_p,
6427 get_current_context_stack, get_context_stack_depth,
6428 get_current_subfile, get_local_symbols, get_file_symbols,
6429 get_global_symbols, record_debugformat, record_producer,
6430 push_context, pop_context, end_symtab_get_static_block,
6431 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
6433 <record_pending_block, finish_block_internal, make_blockvector,
6434 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
6438 2018-05-22 Tom Tromey <tom@tromey.com>
6440 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6442 (finish_block_internal): Update.
6444 2018-07-20 Tom Tromey <tom@tromey.com>
6446 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6448 (finish_block_internal): Update.
6450 2018-07-20 Tom Tromey <tom@tromey.com>
6452 * buildsym.h (EXTERN): Don't define or undef.
6453 * buildsym.c (EXTERN): Don't define.
6455 2018-07-20 Tom Tromey <tom@tromey.com>
6457 * buildsym.c: Remove TODO comment.
6459 2018-07-20 Tom Tromey <tom@tromey.com>
6461 * coffread.c (coff_symtab_read): Update.
6462 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6463 (xcoff_new_init): Update.
6464 * mipsread.c (mipscoff_new_init): Update.
6465 * mdebugread.c (mdebug_build_psymtabs): Update.
6466 * elfread.c (elf_new_init): Update.
6467 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
6469 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
6470 (coffstab_build_psymtabs, elfstab_build_psymtabs)
6471 (stabsect_build_psymtabs): Update.
6472 * buildsym.h (buildsym_init): Don't declare.
6473 * buildsym.c: Update comment.
6474 (prepare_for_building): Remove.
6475 (start_symtab, restart_symtab): Update.
6476 (reset_symtab_globals): Update comment.
6477 (buildsym_init): Remove.
6479 2018-07-20 Tom Tromey <tom@tromey.com>
6481 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
6482 * stabsread.c (patch_block_stabs, define_symbol, read_type)
6483 (read_enum_type, common_block_start, common_block_end)
6484 (cleanup_undefined_types_1, finish_global_stabs): Update.
6485 * mdebugread.c (psymtab_to_symtab_1): Update.
6486 * dwarf2read.c (fixup_go_packaging, read_func_scope)
6487 (read_lexical_block_scope, new_symbol): Update.
6488 * dbxread.c (process_one_symbol): Update.
6489 * coffread.c (coff_symtab_read, process_coff_symbol)
6490 (coff_read_enum_type): Update.
6491 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
6493 (get_local_symbols, get_file_symbols, get_global_symbols): New
6495 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
6497 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
6498 (~scoped_free_pendings): Update.
6499 (finish_block, prepare_for_building, reset_symtab_globals)
6500 (end_symtab_get_static_block, end_symtab_with_blockvector)
6501 (augment_type_symtab, push_context): Update.
6502 (get_local_symbols, get_file_symbols, get_global_symbols): New
6504 (buildsym_init): Update.
6506 2018-07-20 Tom Tromey <tom@tromey.com>
6508 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
6509 (process_full_type_unit): Likewise.
6510 (dwarf2_start_symtab): Set list_in_scope.
6512 2018-07-20 Tom Tromey <tom@tromey.com>
6514 * dwarf2read.c (process_psymtab_comp_unit_reader)
6515 (build_type_psymtabs_reader): Do not set list_in_scope.
6517 2018-07-20 Tom Tromey <tom@tromey.com>
6519 * buildsym.c (free_pendings): Remove.
6520 (add_symbol_to_list, scoped_free_pendings)
6521 (finish_block_internal, buildsym_init): Update.
6523 2018-07-20 Tom Tromey <tom@tromey.com>
6525 * xcoffread.c (read_xcoff_symtab): Update.
6526 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
6528 * dbxread.c (process_one_symbol): Update.
6529 * coffread.c (coff_symtab_read): Update.
6530 * buildsym.h (finish_block): Update.
6531 * buildsym.c (finish_block): Remove "listhead" argument.
6532 (end_symtab_get_static_block): Update.
6534 2018-07-20 Tom Tromey <tom@tromey.com>
6536 * buildsym.h (class scoped_free_pendings): Remove constructor.
6537 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
6539 <m_pending_block_obstack, m_pending_blocks>: New members.
6540 (pending_block_obstack, pending_blocks): Remove.
6541 (scoped_free_pendings::scoped_free_pendings): Default.
6542 (~scoped_free_pendings): Update.
6543 (free_pending_blocks): Remove.
6544 (finish_block_internal, record_pending_block, make_blockvector)
6545 (end_symtab_get_static_block, augment_type_symtab, push_context)
6546 (buildsym_init): Update.
6548 2018-07-20 Tom Tromey <tom@tromey.com>
6550 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
6551 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
6553 (pending_addrmap, pending_addrmap_obstack)
6554 (pending_addrmap_interesting): Remove.
6555 (scoped_free_pendings, record_block_range, make_blockvector)
6556 (prepare_for_building, reset_symtab_globals, buildsym_init):
6559 2018-07-20 Tom Tromey <tom@tromey.com>
6561 * xcoffread.c (process_linenos): Update.
6562 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
6563 * mdebugread.c (psymtab_to_symtab_1): Update.
6564 * dwarf2read.c (setup_type_unit_groups)
6565 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
6566 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
6567 * dbxread.c (process_one_symbol): Update.
6568 * coffread.c (coff_symtab_read, enter_linenos)
6569 (process_coff_symbol): Update.
6570 * buildsym.h (current_subfile): Don't declare.
6571 (get_current_subfile): Declare.
6572 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
6574 (start_subfile, free_buildsym_compunit, push_subfile)
6575 (prepare_for_building, start_symtab): Update.
6576 (get_current_subfile): New function.
6578 2018-07-20 Tom Tromey <tom@tromey.com>
6580 * coffread.c (coff_symtab_read): Update.
6581 * xcoffread.c (read_xcoff_symtab): Update.
6582 * dwarf2read.c (new_symbol): Update.
6583 (read_func_scope, read_lexical_block_scope): Update.
6584 * dbxread.c (process_one_symbol): Update.
6585 * buildsym.h (context_stack, context_stack_depth): Don't declare.
6586 (outermost_context_p): Remove macro.
6587 (outermost_context_p, get_current_context_stack)
6588 (get_context_stack_depth): Declare.
6589 (pop_context): Return struct context_stack.
6590 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
6592 (context_stack_size): Remove.
6593 (INITIAL_CONTEXT_STACK_SIZE): Remove.
6594 (prepare_for_building, end_symtab_get_static_block)
6595 (augment_type_symtab, push_context): Update.
6596 (pop_context): Return struct context_stack.
6597 (outermost_context_p, get_current_context_stack)
6598 (get_context_stack_depth): New functions.
6599 (buildsym_init): Update.
6601 2018-07-20 Tom Tromey <tom@tromey.com>
6603 * rust-exp.y: Now a pure parser. Update all rules.
6604 (%union): Move earlier.
6605 (current_parser, work_obstack): Remove globals.
6606 (rust_parser, ~rust_parser): Update.
6607 (class rust_parser) <copy_name, concat3, crate_name, super_name,
6608 lex_character, lex_number, lex_string, lex_identifier,
6609 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
6610 convert_name, convert_params_to_expression,
6611 convert_ast_to_expression, ast_basic_type, ast_operation,
6612 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
6613 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
6614 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
6615 ast_array_type, ast_slice_type, ast_reference_type,
6616 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
6617 (rust_parse): Update.
6618 (rustyyerror, rustyylex): Add parser parameter.
6619 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
6620 (rust_lex_stringish_test, rust_lex_test_sequence)
6621 (rust_lex_test_trailing_dot, rust_lex_test_completion)
6622 (rust_lex_test_push_back, rust_lex_tests): Update.
6624 2018-07-19 Pedro Alves <palves@redhat.com>
6626 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
6627 gdb::unique_xmalloc_ptr.
6628 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
6629 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
6630 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
6631 copy-initialization.
6632 * guile/scm-pretty-print.c (ppscm_print_children): Use
6633 gdb::unique_xmalloc_ptr instead of cleanups.
6634 (gdbscm_apply_val_pretty_printer): Remove cleanups.
6635 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
6636 gdb::unique_xmalloc_ptr.
6637 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6638 Adjust to use gdb::unique_xmalloc_ptr.
6639 * guile/scm-utils.c (extract_arg): Adjust.
6640 * guile/scm-value.c (gdbscm_value_field): Adjust to use
6641 gdb::unique_xmalloc_ptr instead of a cleanup.
6643 2018-07-19 Tom Tromey <tom@tromey.com>
6645 * utils.c (do_value_free_to_mark)
6646 (make_cleanup_value_free_to_mark): Remove.
6647 * utils.h (make_cleanup_value_free_to_mark): Remove.
6649 2018-07-19 Pedro Alves <palves@redhat.com>
6651 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
6652 forwarding reference.
6654 2018-07-18 Pedro Alves <palves@redhat.com>
6656 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
6657 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
6660 2018-07-18 Pedro Alves <palves@redhat.com>
6662 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
6664 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
6666 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
6667 directly instead of a cleanup.
6668 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
6669 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
6670 (vlscm_binop_gdbthrow): New, factored out from ...
6671 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
6672 (vlscm_rich_compare): Use gdbscm_wrap.
6673 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
6674 instead of a cleanup.
6675 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
6677 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6678 Use xfree directly instead of a cleanup.
6679 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
6680 Adjust to use gdbscm_wrap and scoped_value_mark.
6681 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
6682 (gdbscm_value_address, gdbscm_value_dereference)
6683 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
6685 (gdbscm_value_dynamic_type): Use scoped_value_mark.
6686 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
6688 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
6689 gdbscm_wrap and scoped_value_mark.
6690 (gdbscm_value_to_string): Use xfree directly instead of a
6691 cleanup. Move 'buffer' unique_ptr to TRY scope.
6692 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
6693 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
6695 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
6696 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
6698 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
6701 2018-07-18 Tom de Vries <tdevries@suse.de>
6703 * findvar.c (default_read_var_value): Also resolve dynamic type for
6704 LOC_OPTIMIZED_OUT vars.
6706 2018-07-18 Maciej W. Rozycki <macro@mips.com>
6708 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
6711 2018-07-17 Tom Tromey <tom@tromey.com>
6713 * guile/scm-param.c (pascm_set_func, pascm_show_func)
6714 (compute_enum_list, pascm_set_param_value_x)
6715 (gdbscm_parameter_value): Update.
6716 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
6717 (gdbscm_scm_to_host_string): Update.
6718 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
6720 * guile/scm-cmd.c (cmdscm_add_completion): Update.
6721 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
6722 * guile/scm-string.c (gdbscm_scm_to_string): Return
6724 (gdbscm_scm_to_host_string): Likewise.
6726 2018-07-17 Tom Tromey <tom@tromey.com>
6728 * guile/guile.c (gdbscm_eval_from_control_command): Update.
6729 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
6730 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
6731 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
6734 2018-07-17 Tom Tromey <tom@tromey.com>
6736 * guile/scm-param.c (pascm_signal_setshow_error): Update.
6737 * guile/guile-internal.h (gdbscm_exception_message_to_string):
6739 * guile/scm-cmd.c (cmdscm_function): Update.
6740 * guile/scm-pretty-print.c
6741 (ppscm_print_exception_unless_memory_error): Update.
6742 * guile/scm-exception.c (gdbscm_exception_message_to_string):
6743 Return unique_xmalloc_ptr.
6745 2018-07-17 Tom Tromey <tom@tromey.com>
6747 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
6750 2018-07-17 Jim Wilson <jimw@sifive.com>
6752 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
6753 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
6754 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
6755 unecessary braces after EF_RISCV_RVC test. Delete call to
6756 set_gdbarch_decr_pc_after_break.
6758 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
6759 RISCV_LAST_FP_REGNUM + 1.
6760 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
6762 2018-07-17 Tom Tromey <tom@tromey.com>
6764 * configure.ac: Remove --disable-gdbcli.
6765 * configure: Rebuild.
6766 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
6767 (SUBDIR_CLI_CFLAGS): Remove.
6768 (SFILES): Use SUBDIR_CLI_SRCS.
6769 (COMMON_OBS): Use SUBDIR_CLI_OBS.
6771 2018-07-17 Tom Tromey <tom@tromey.com>
6774 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
6776 2018-07-16 Jim Wilson <jimw@sifive.com>
6778 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
6780 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6782 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
6784 (libunwind_frame_sniffer): Likewise.
6785 (libunwind_frame_prev_register): Likewise.
6786 (libunwind_sigtramp_frame_sniffer): Likewise.
6787 * ia64-tdep.c (ia64_access_reg): Likewise.
6788 (ia64_access_rse_reg): Likewise.
6789 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
6790 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
6792 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6794 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
6796 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6798 * remote-sim.c (gdbsim_target::close,
6799 gdbsim_target::mourn_inferior): Remove unused variables.
6801 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
6803 * ia64-tdep.c (ktab_buf): New global.
6804 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
6805 (get_kernel_table): Adjust.
6807 2018-07-16 Tom Tromey <tom@tromey.com>
6809 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
6810 * dwarf2read.c (using_directives, new_symbol): Use
6811 outermost_context_p.
6812 * dbxread.c (process_one_symbol): Use outermost_context_p.
6813 * coffread.c (coff_symtab_read): Use outermost_context_p.
6815 2018-07-16 Tom Tromey <tom@tromey.com>
6817 * dwarf2read.c (using_directives, read_func_scope)
6818 (read_lexical_block_scope): Update.
6819 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6820 * buildsym.h (local_using_directives, global_using_directives):
6822 (get_local_using_directives, set_local_using_directives)
6823 (get_global_using_directives): Declare.
6824 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
6825 m_global_using_directives>: New members.
6826 (finish_block_internal, prepare_for_building)
6827 (reset_symtab_globals, end_symtab_get_static_block)
6828 (push_context): Update.
6829 (get_local_using_directives, set_local_using_directives)
6830 (get_global_using_directives): New functions.
6831 (buildsym_init): Update.
6833 2018-07-16 Tom Tromey <tom@tromey.com>
6835 * xcoffread.c (xcoff_initial_scan): Don't call
6836 free_pending_blocks.
6837 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
6838 * buildsym.h (class scoped_free_pendings): Add constructor.
6839 (free_pending_blocks): Don't declare.
6840 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
6841 (free_pending_blocks): Now static.
6843 2018-07-16 Tom Tromey <tom@tromey.com>
6845 * buildsym.h (push_subfile, pop_subfile): Update declarations.
6846 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
6848 (struct subfile_stack): Remove.
6849 (subfile_stack): Remove.
6850 (push_subfile, pop_subfile, buildsym_init): Update.
6852 2018-07-16 Tom Tromey <tom@tromey.com>
6854 * buildsym.c (push_subfile): Use gdb_assert.
6855 (pop_subfile): Use gdb_assert.
6857 2018-07-16 Tom Tromey <tom@tromey.com>
6859 * buildsym.h (merge_symbol_lists): Remove.
6860 * buildsym.c (merge_symbol_lists): Remove.
6862 2018-07-16 Tom Tromey <tom@tromey.com>
6864 * stabsread.c (scan_file_globals): Update comment.
6865 * stabsread.h (scan_file_globals): Move from buildsym.h.
6866 * buildsym.h (scan_file_globals): Move to stabsread.h.
6868 2018-07-16 Tom Tromey <tom@tromey.com>
6870 * xcoffread.c (xcoff_new_init): Update.
6871 * mipsread.c (mipscoff_new_init): Update.
6872 * mdebugread.c (mdebug_build_psymtabs): Update.
6873 * elfread.c (elf_new_init): Update.
6874 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
6875 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
6876 * buildsym.h (buildsym_new_init): Don't declare.
6877 * buildsym.c (buildsym_new_init): Remove.
6879 2018-07-16 Tom Tromey <tom@tromey.com>
6881 * stabsread.h (within_function): Move from buildsym.h.
6882 * stabsread.c (start_stabs): Clear within_function.
6883 * coffread.c (coff_start_symtab): Clear within_function.
6884 * buildsym.h (within_function): Move to stabsread.h.
6885 * buildsym.c (prepare_for_building): Update.
6887 2018-07-16 Tom Tromey <tom@tromey.com>
6889 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
6890 * dwarf2read.c (dwarf2_start_symtab): Don't set
6891 processing_gcc_compilation.
6892 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
6894 2018-07-16 Tom Tromey <tom@tromey.com>
6896 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
6897 (next_symbol_text_func): Move from buildsym.h.
6898 * stabsread.c (hashname): Move from buildsym.c.
6899 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
6900 (next_symbol_text_func, hashname): Move to stabsread.h.
6901 * buildsym.c: Don't include bcache.h
6902 (hashname): Move to stasbread.c.
6904 2018-07-16 Tom Tromey <tom@tromey.com>
6906 * buildsym.h (context_stack_size): Don't declare.
6907 * buildsym.c (context_stack_size): New global.
6909 2018-07-16 Tom Tromey <tom@tromey.com>
6911 * dbxread.c (processing_acc_compilation): New global.
6912 * buildsym.h (processing_acc_compilation): Don't declare.
6914 2018-07-16 Tom Tromey <tom@tromey.com>
6916 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
6917 * dbxread.c (read_ofile_symtab): Update.
6918 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
6919 * buildsym.h (last_source_start_addr): Remove.
6920 (set_last_source_start_addr, get_last_source_start_addr):
6922 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
6924 (struct buildsym_compunit) <m_last_source_start_addr>: New
6926 (prepare_for_building): Remove start_addr parameter.
6927 (start_symtab, restart_symtab, end_symtab_get_static_block)
6928 (end_symtab_with_blockvector): Update.
6929 (set_last_source_start_addr, get_last_source_start_addr): New
6932 2018-07-16 Tom Tromey <tom@tromey.com>
6934 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
6936 (have_line_numbers): Remove.
6937 (record_line, prepare_for_building, end_symtab_get_static_block)
6938 (augment_type_symtab): Update.
6940 2018-07-16 Tom Tromey <tom@tromey.com>
6942 * buildsym.c (~buildsym_compunit): Free the macro table.
6943 (struct buildsym_compunit) <get_macro_table, release_macros>: New
6945 <m_pending_macros>: New member.
6946 (pending_macros): Remove.
6947 (~scoped_free_pendings, get_macro_table, prepare_for_building)
6948 (reset_symtab_globals, end_symtab_get_static_block)
6949 (end_symtab_with_blockvector, augment_type_symtab)
6950 (buildsym_init): Update.
6952 2018-07-16 Tom Tromey <tom@tromey.com>
6954 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
6956 (buildsym_compunit::set_last_source_file): New method.
6957 <m_last_source_file>: New member.
6958 (prepare_for_building): Remove "name" parameter.
6959 (start_symtab, restart_symtab, reset_symtab_globals): Update.
6960 (last_source_file): Remove.
6961 (set_last_source_file, get_last_source_file): Update.
6963 2018-07-16 Tom Tromey <tom@tromey.com>
6965 * buildsym.c (prepare_for_building): Add assert.
6967 2018-07-16 Tom Tromey <tom@tromey.com>
6969 * buildsym.c (~buildsym_compunit): Update.
6970 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
6971 (start_subfile, patch_subfile_names)
6972 (end_symtab_with_blockvector): Update.
6974 2018-07-16 Tom Tromey <tom@tromey.com>
6976 * buildsym.c (struct buildsym_compunit): Add constructor,
6977 destructor, initializers.
6978 (start_buildsym_compunit): Remove.
6979 (free_buildsym_compunit): Use "delete".
6980 (start_symtab, restart_symtab): Use "new".
6982 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
6984 * symfile.c (set_objfile_default_section_offset): Remove struct
6987 2018-07-14 Stafford Horne <shorne@gmail.com>
6989 * (Responsible Maintainers): Add myself as or1k maintainer.
6991 2018-07-13 Tom Tromey <tom@tromey.com>
6993 * symfile.c (set_objfile_default_section_offset): Use extra braces
6996 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6998 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
7001 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7003 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7004 unittests/cli-utils-selftests.c
7005 * unittests/cli-utils-selftests.c: New file.
7007 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7009 * NEWS: Mention new commands. Mention change to 'thread apply'.
7011 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7013 * thread.c (thr_try_catch_cmd): New function.
7014 (thread_apply_all_command): Handle qcs flags.
7015 (thread_apply_command): Handle qcs flags.
7016 (taas_command): New function.
7017 (tfaas_command): New function.
7018 (_initialize_thread): Update to setup the new commands 'taas
7019 and 'tfaas'. Change doc string for 'thread apply'.
7021 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7023 * stack.c: (trailing_outermost_frame): New function, mostly
7024 extracted from backtrace_command_1.
7025 (leading_innermost_frame): New function.
7026 (backtrace_command_1): Update to call trailing_outermost_frame.
7027 (frame_apply_command_count): New function.
7028 (frame_apply_level_command): New function.
7029 (frame_apply_all_command): New function.
7030 (frame_apply_command): New function.
7031 (faas_command): New function.
7032 (frame_cmd_list): New variable.
7033 (_initialize_stack): Update to setup the new commands 'frame apply'
7036 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7038 * cli-utils.c (number_or_range_parser::get_number): Only handle
7039 numbers or convenience var as numbers.
7040 (parse_flags): New function.
7041 (parse_flags_qcs): New function.
7042 (number_or_range_parser::finished): Ensure parsing end is detected
7043 before end of string.
7044 * cli-utils.h (parse_flags): New function.
7045 (parse_flags_qcs): New function.
7046 (number_or_range_parser): Remove m_finished bool.
7047 (number_or_range_parser::skip_range): Set m_in_range to false.
7049 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
7051 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
7054 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
7055 Jan Kratochvil <jan.kratochvil@redhat.com>
7056 Paul Fertser <fercerpav@gmail.com>
7057 Tsutomu Seki <sekiriki@gmail.com>
7058 Pedro Alves <palves@redhat.com>
7060 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7061 'unittests/parse-connection-spec-selftests.c'.
7062 (COMMON_SFILES): Add 'common/netstuff.c'.
7063 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
7064 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
7065 * common/netstuff.c: New file.
7066 * common/netstuff.h: New file.
7067 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
7068 (wait_for_connect): Update comment. New parameter
7069 'gdb::optional<int> sock' instead of 'struct serial *scb'.
7070 Use 'sock' directly instead of 'scb->fd'.
7071 (try_connect): New function, with code from 'net_open'.
7072 (net_open): Rewrite main loop to deal with multiple
7073 sockets/addresses. Handle IPv6-style hostnames; implement
7074 support for IPv6 connections.
7075 * unittests/parse-connection-spec-selftests.c: New file.
7077 2018-07-11 Pedro Alves <palves@redhat.com>
7080 * remote.c (remote_target::remote_detach_pid): Call
7081 set_current_process.
7083 2018-07-11 Pedro Alves <palves@redhat.com>
7085 * h8300-tdep.c (h8300_gdbarch_init): Remove
7086 set_gdbarch_ecoff_reg_to_regnum calls.
7088 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
7091 * c-typeprint.c (c_type_print_base_struct_union): Don't print
7092 offsets/sizes for static members of a class/struct.
7094 2018-07-11 Alan Hayward <alan.hayward@arm.com>
7096 * target-descriptions.c (tdesc_register_bitsize): Rename.
7097 * target-descriptions.h (tdesc_register_bitsize): Likewise.
7098 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
7099 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
7101 2018-07-10 Tom Tromey <tom@tromey.com>
7103 * breakpoint.c (moribund_locations): Now static and a
7105 (breakpoint_init_inferior, moribund_breakpoint_here_p)
7106 (build_bpstat_chain, update_global_location_list)
7107 (breakpoint_retire_moribund): Update.
7108 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
7111 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
7113 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
7114 (riscv_register_reggroup_p): Use new function, remove unneeded
7116 (riscv_push_dummy_call): Extend assert to compare against xlen or
7117 flen based on register type.
7119 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
7121 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
7123 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
7125 * remote.c (show_hardware_watchpoint_limit): New function.
7126 (show_hardware_watchpoint_length_limit): New function.
7127 (show_hardware_breakpoint_limit): New function.
7128 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
7129 where appropriate, update help text.
7131 2018-07-09 Tom Tromey <tom@tromey.com>
7133 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
7134 (CLIBS): Don't mention NAT_CLIBS.
7136 2018-07-09 Tom Tromey <tom@tromey.com>
7138 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
7139 (LIBGDB_OBS, clean mostlyclean): Update.
7140 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
7142 2018-07-09 Tom Tromey <tom@tromey.com>
7144 * Makefile.in (%.c: %.y): Use ECHO_YACC.
7145 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
7146 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
7148 2018-07-09 Tom Tromey <tom@tromey.com>
7150 * Makefile.in (ALLDEPFILES): Remove exec.c.
7151 (COMMON_OBS): Remove exec.o.
7152 (COMMON_SFILES): Add exec.c.
7154 2018-07-09 Tom Tromey <tom@tromey.com>
7156 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
7158 2018-07-09 Tom Tromey <tom@tromey.com>
7160 * Makefile.in (clean mostlyclean): Remove stamp-version.
7161 (version.c): Depend on stamp-version.
7162 (stamp-version): New rule, from version.c rule.
7164 2018-07-09 Tom Tromey <tom@tromey.com>
7166 * Makefile.in (init.c): Depend on stamp-init.
7167 (stamp-init): New rule, from init.c rule.
7168 (clean mostlyclean): Remove stamp-init.
7170 2018-07-09 Tom Tromey <tom@tromey.com>
7172 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
7173 SUBDIR_GCC_COMPILE_SRCS.
7175 2018-07-09 Tom Tromey <tom@tromey.com>
7177 * Makefile.in (init.c): Remove some unused sed rules.
7179 2018-07-09 Tom Tromey <tom@tromey.com>
7181 * Makefile.in (TSOBS): Remove.
7182 (INIT_FILES): Update.
7183 (LIBGDB_OBS): Update.
7184 (COMMON_SFILES): Add inflow.c.
7185 (SFILES): Remove inflow.c.
7187 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
7189 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
7191 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
7193 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
7194 get_saveloc_name, is_signal_frame_name, step_name,
7195 init_remote_name, create_addr_space_name,
7196 destroy_addr_space_name, search_unwind_table_name,
7197 find_dyn_list_name): Constify.
7199 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
7201 * darwin-nat.c (darwin_pthread_kill): New function.
7202 (darwin_resume_thread): Use darwin_pthread_kill.
7204 2018-07-05 Tom de Vries <tdevries@suse.de>
7206 * macroexp.c (macro_buffer) <operator=>: New member function.
7208 2018-07-04 Tom Tromey <tom@tromey.com>
7210 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
7212 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
7214 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
7215 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
7216 * maint.c: Likewise.
7219 2018-07-04 Joel Brobecker <brobecker@adacore.com>
7221 * NEWS: Create a new section for the next release branch.
7222 Rename the section of the current branch, now that it has
7225 2018-07-04 Joel Brobecker <brobecker@adacore.com>
7227 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
7228 * version.in: Bump version to 8.2.50.DATE-git.
7230 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
7231 Pedro Alves <palves@redhat.com>
7233 * linux-nat.c (linux_init_ptrace): Rename to ...
7234 (linux_init_ptrace_procfs): ... this. Call
7235 linux_proc_init_warnings.
7236 (linux_nat_target::post_attach)
7237 (linux_nat_target::post_startup_inferior): Adjust.
7238 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
7239 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
7241 2018-07-04 Tom de Vries <tdevries@suse.de>
7243 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
7245 (read_comp_unit_head): ... here.
7247 2018-07-03 Tom Tromey <tom@tromey.com>
7249 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
7250 (stop_tracing, tstatus_command)
7251 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
7252 (print_one_static_tracepoint_marker): Update.
7253 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
7255 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
7257 (all_tracepoints, static_tracepoints_here): Return std::vector.
7259 2018-07-03 Tom Tromey <tom@tromey.com>
7261 * common/ptid.c (ptid_equal): Remove.
7262 * common/ptid.h (ptid_equal): Don't declare.
7263 * ada-tasks.c: Update.
7264 * breakpoint.c: Update.
7265 * common/agent.c: Update.
7266 * corelow.c: Update.
7267 * darwin-nat-info.c: Update.
7268 * darwin-nat.c: Update.
7270 * dtrace-probe.c: Update.
7271 * dummy-frame.c: Update.
7272 * fbsd-nat.c: Update.
7274 * gdbthread.h: Update.
7275 * gnu-nat.c: Update.
7276 * go32-nat.c: Update.
7277 * inf-loop.c: Update.
7278 * inf-ptrace.c: Update.
7279 * infcall.c: Update.
7283 * linux-fork.c: Update.
7284 * linux-nat.c: Update.
7285 * linux-thread-db.c: Update.
7286 * mi/mi-cmd-var.c: Update.
7287 * mi/mi-interp.c: Update.
7288 * mi/mi-main.c: Update.
7289 * nto-procfs.c: Update.
7290 * ppc-linux-tdep.c: Update.
7292 * python/py-inferior.c: Update.
7293 * python/py-record-btrace.c: Update.
7294 * python/py-record.c: Update.
7295 * ravenscar-thread.c: Update.
7296 * regcache.c: Update.
7297 * remote-sim.c: Update.
7299 * sol-thread.c: Update.
7302 * tui/tui-stack.c: Update.
7304 * windows-nat.c: Update.
7305 * windows-tdep.c: Update.
7307 2018-07-03 Tom Tromey <tom@tromey.com>
7309 * common/ptid.c (ptid_match): Remove.
7310 * common/ptid.h (ptid_match): Don't declare.
7311 * fbsd-nat.c: Update.
7314 * linux-nat.c: Update.
7315 * record-btrace.c: Update.
7316 * regcache.c: Update.
7319 2018-07-03 Tom Tromey <tom@tromey.com>
7321 * common/ptid.c (ptid_tid_p): Remove.
7322 * common/ptid.h (ptid_tid_p): Don't declare.
7323 * sol-thread.c: Update.
7325 2018-07-03 Tom Tromey <tom@tromey.com>
7327 * common/ptid.c (ptid_lwp_p): Remove.
7328 * common/ptid.h (ptid_lwp_p): Don't declare.
7329 * fbsd-nat.c: Update.
7330 * linux-nat.c: Update.
7331 * nat/linux-procfs.c: Update.
7332 * nat/x86-linux-dregs.c: Update.
7333 * sol-thread.c: Update.
7335 2018-07-03 Tom Tromey <tom@tromey.com>
7337 * common/ptid.c (ptid_is_pid): Remove.
7338 * common/ptid.h (ptid_is_pid): Don't declare.
7340 * linux-nat.c: Update.
7341 * mi/mi-interp.c: Update.
7345 2018-07-03 Tom Tromey <tom@tromey.com>
7347 * common/ptid.c (ptid_get_tid): Remove.
7348 * common/ptid.h (ptid_get_tid): Don't declare.
7349 * ada-tasks.c: Update.
7350 * aix-thread.c: Update.
7351 * bsd-uthread.c: Update.
7352 * darwin-nat.c: Update.
7353 * fbsd-nat.c: Update.
7354 * i386-darwin-nat.c: Update.
7356 * linux-tdep.c: Update.
7357 * nto-procfs.c: Update.
7358 * ppc-ravenscar-thread.c: Update.
7359 * python/py-infthread.c: Update.
7360 * ravenscar-thread.c: Update.
7361 * sol-thread.c: Update.
7362 * sparc-ravenscar-thread.c: Update.
7363 * windows-nat.c: Update.
7365 2018-07-03 Tom Tromey <tom@tromey.com>
7367 * common/ptid.c (ptid_get_lwp): Remove.
7368 * common/ptid.h (ptid_get_lwp): Don't declare.
7369 * aarch64-linux-nat.c: Update.
7370 * ada-tasks.c: Update.
7371 * aix-thread.c: Update.
7372 * amd64-linux-nat.c: Update.
7373 * arm-linux-nat.c: Update.
7374 * corelow.c: Update.
7375 * fbsd-nat.c: Update.
7376 * fbsd-tdep.c: Update.
7377 * gnu-nat.c: Update.
7378 * i386-cygwin-tdep.c: Update.
7379 * i386-gnu-nat.c: Update.
7380 * i386-linux-nat.c: Update.
7381 * ia64-linux-nat.c: Update.
7382 * inf-ptrace.c: Update.
7384 * linux-fork.c: Update.
7385 * linux-nat.c: Update.
7386 * linux-tdep.c: Update.
7387 * linux-thread-db.c: Update.
7388 * mips-linux-nat.c: Update.
7389 * nat/aarch64-linux-hw-point.c: Update.
7390 * nat/aarch64-linux.c: Update.
7391 * nat/linux-btrace.c: Update.
7392 * nat/linux-osdata.c: Update.
7393 * nat/linux-procfs.c: Update.
7394 * nat/x86-linux-dregs.c: Update.
7395 * obsd-nat.c: Update.
7396 * ppc-fbsd-nat.c: Update.
7397 * ppc-linux-nat.c: Update.
7399 * python/py-infthread.c: Update.
7400 * ravenscar-thread.c: Update.
7402 * s390-linux-nat.c: Update.
7403 * sol-thread.c: Update.
7404 * sol2-tdep.c: Update.
7405 * spu-linux-nat.c: Update.
7406 * x86-linux-nat.c: Update.
7407 * xtensa-linux-nat.c: Update.
7409 2018-07-03 Tom Tromey <tom@tromey.com>
7411 * common/ptid.c (ptid_get_pid): Remove.
7412 * common/ptid.h (ptid_get_pid): Don't declare.
7413 * aarch64-linux-nat.c: Update.
7414 * ada-lang.c: Update.
7415 * aix-thread.c: Update.
7416 * alpha-bsd-nat.c: Update.
7417 * amd64-fbsd-nat.c: Update.
7418 * amd64-linux-nat.c: Update.
7419 * arm-linux-nat.c: Update.
7420 * arm-nbsd-nat.c: Update.
7422 * break-catch-syscall.c: Update.
7423 * breakpoint.c: Update.
7424 * bsd-uthread.c: Update.
7425 * corelow.c: Update.
7427 * darwin-nat.c: Update.
7428 * fbsd-nat.c: Update.
7429 * fbsd-tdep.c: Update.
7431 * gnu-nat.c: Update.
7432 * hppa-nbsd-nat.c: Update.
7433 * hppa-obsd-nat.c: Update.
7434 * i386-fbsd-nat.c: Update.
7435 * ia64-linux-nat.c: Update.
7436 * inf-ptrace.c: Update.
7438 * inferior.c: Update.
7439 * inferior.h: Update.
7442 * linux-fork.c: Update.
7443 * linux-nat.c: Update.
7444 * linux-tdep.c: Update.
7445 * linux-thread-db.c: Update.
7446 * m68k-bsd-nat.c: Update.
7447 * mi/mi-interp.c: Update.
7448 * mi/mi-main.c: Update.
7449 * mips-linux-nat.c: Update.
7450 * mips-nbsd-nat.c: Update.
7451 * mips64-obsd-nat.c: Update.
7452 * nat/aarch64-linux-hw-point.c: Update.
7453 * nat/aarch64-linux.c: Update.
7454 * nat/linux-btrace.c: Update.
7455 * nat/linux-osdata.c: Update.
7456 * nat/linux-procfs.c: Update.
7457 * nat/x86-linux-dregs.c: Update.
7458 * nto-procfs.c: Update.
7459 * obsd-nat.c: Update.
7460 * ppc-linux-nat.c: Update.
7461 * ppc-nbsd-nat.c: Update.
7462 * ppc-obsd-nat.c: Update.
7463 * proc-service.c: Update.
7465 * python/py-inferior.c: Update.
7466 * python/py-infthread.c: Update.
7467 * ravenscar-thread.c: Update.
7469 * remote-sim.c: Update.
7471 * rs6000-nat.c: Update.
7472 * s390-linux-nat.c: Update.
7473 * sh-nbsd-nat.c: Update.
7474 * sol-thread.c: Update.
7475 * sparc-nat.c: Update.
7476 * sparc64-tdep.c: Update.
7477 * spu-linux-nat.c: Update.
7478 * spu-tdep.c: Update.
7479 * target-debug.h: Update.
7482 * tid-parse.c: Update.
7483 * tracefile-tfile.c: Update.
7484 * vax-bsd-nat.c: Update.
7485 * windows-nat.c: Update.
7486 * x86-linux-nat.c: Update.
7487 * x86-nat.c: Update.
7489 2018-07-03 Tom Tromey <tom@tromey.com>
7491 * common/ptid.c (pid_to_ptid): Remove.
7492 * common/ptid.h (pid_to_ptid): Don't declare.
7493 * aix-thread.c: Update.
7494 * arm-linux-nat.c: Update.
7495 * common/ptid.c: Update.
7496 * common/ptid.h: Update.
7497 * corelow.c: Update.
7499 * darwin-nat.c: Update.
7500 * fbsd-nat.c: Update.
7501 * fork-child.c: Update.
7502 * gnu-nat.c: Update.
7503 * go32-nat.c: Update.
7504 * inf-ptrace.c: Update.
7506 * inferior.c: Update.
7508 * linux-fork.c: Update.
7509 * linux-nat.c: Update.
7510 * nat/aarch64-linux-hw-point.c: Update.
7511 * nat/fork-inferior.c: Update.
7512 * nat/x86-linux-dregs.c: Update.
7513 * nto-procfs.c: Update.
7514 * obsd-nat.c: Update.
7516 * progspace.c: Update.
7518 * rs6000-nat.c: Update.
7519 * s390-linux-nat.c: Update.
7520 * sol-thread.c: Update.
7521 * spu-linux-nat.c: Update.
7524 * tracefile-tfile.c: Update.
7525 * windows-nat.c: Update.
7527 2018-07-03 Tom Tromey <tom@tromey.com>
7529 * common/ptid.h (ptid_build): Don't declare.
7530 * common/ptid.c (ptid_build): Remove.
7531 * aix-thread.c: Update.
7532 * bsd-kvm.c: Update.
7533 * bsd-uthread.c: Update.
7534 * common/agent.c: Update.
7535 * common/ptid.c: Update.
7536 * common/ptid.h: Update.
7537 * corelow.c: Update.
7538 * darwin-nat.c: Update.
7539 * fbsd-nat.c: Update.
7540 * gnu-nat.c: Update.
7541 * linux-fork.c: Update.
7542 * linux-nat.c: Update.
7543 * linux-thread-db.c: Update.
7544 * nat/linux-osdata.c: Update.
7545 * nat/linux-procfs.c: Update.
7546 * nto-procfs.c: Update.
7547 * obsd-nat.c: Update.
7548 * proc-service.c: Update.
7550 * ravenscar-thread.c: Update.
7551 * remote-sim.c: Update.
7553 * sol-thread.c: Update.
7555 * windows-nat.c: Update.
7557 2018-07-03 Tom Tromey <tom@tromey.com>
7559 * infrun.c (follow_exec): Use exit_inferior_silent.
7560 * inferior.c (exit_inferior_num_silent): Remove.
7561 * inferior.h (exit_inferior_num_silent): Don't declare.
7563 2018-07-03 Tom Tromey <tom@tromey.com>
7566 * darwin-nat.c (darwin_attach_pid): Reset inferior and
7567 inferior_ptid on error.
7569 2018-07-02 Maciej W. Rozycki <macro@mips.com>
7570 Simon Marchi <simon.marchi@polymtl.ca>
7573 * disasm.h (gdb_disassembler): Add
7574 `m_disassembler_options_holder'. member
7575 * disasm.c (get_all_disassembler_options): New function.
7576 (gdb_disassembler::gdb_disassembler): Use it.
7577 (gdb_buffered_insn_length_init_dis): Likewise.
7578 (gdb_buffered_insn_length): Adjust accordingly.
7579 (set_disassembler_options): Handle options with arguments.
7580 (show_disassembler_options_sfunc): Likewise. Add a leading new
7581 line if showing options with descriptions.
7582 (disassembler_options_completer): Adapt to using the
7583 `disasm_options_and_args_t' structure.
7584 * mips-tdep.c (mips_disassembler_options): New variable.
7585 (mips_disassembler_options_o32): Likewise.
7586 (mips_disassembler_options_n32): Likewise.
7587 (mips_disassembler_options_n64): Likewise.
7588 (gdb_print_insn_mips): Don't set `disassembler_options'.
7589 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
7591 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
7592 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
7593 `gdbarch_disassembler_options_implicit' and
7594 `gdbarch_valid_disassembler_options'.
7595 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
7596 `disasm_options_and_args_t' structure.
7597 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
7599 (valid_disassembler_options): Switch from `disasm_options_t' to
7600 the `disasm_options_and_args_t' structure.
7601 * NEWS: Document `set disassembler-options' support for the MIPS
7603 * gdbarch.h: Regenerate.
7604 * gdbarch.c: Regenerate.
7606 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
7608 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
7610 2018-06-29 Joel Brobecker <brobecker@adacore.com>
7612 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
7613 parameter in call to amd64_target_description.
7614 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
7615 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
7616 (amd64fbsd_init_abi): Likewise.
7617 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
7618 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7619 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7620 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
7622 2018-06-29 Pedro Alves <palves@redhat.com>
7624 * gdb/amd64-tdep.h (amd64_create_target_description): Add
7625 "segments" parameter.
7626 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
7627 (_initialize_amd64_tdep): Update call to
7628 amd64_create_target_description.
7629 (amd64_target_description): Add "segments" parameter. Adjust
7630 the implementation to use it.
7631 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
7632 call to amd64_create_target_description.
7633 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
7634 * gdb/arch/amd64.h (amd64_create_target_description): Add
7635 "segments" register.
7636 * gdb/arch/amd64.c (amd64_create_target_description): Add
7637 "segments" parameter. Call create_feature_i386_64bit_segments
7638 only if SEGMENTS is true.
7639 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
7640 call to amd64_create_target_description.
7642 2018-06-29 Pedro Alves <palves@redhat.com>
7644 * thread.c (thread_target_id_str): New, factored out from ...
7645 (print_thread_info_1): ... here. Use it to compute the max
7646 "Target Id" column width.
7648 2018-06-29 Pedro Alves <palves@redhat.com>
7650 * remote.c (remote_target::extra_thread_info): Delete
7651 'display_buf' and 'n' locals. from the cache, regardless of
7652 packet mechanims is in use. Use cache for qThreadExtra and qP
7655 2018-06-29 Pedro Alves <palves@redhat.com>
7657 * blockframe.c (find_pc_sect_containing_function): New function.
7658 * breakpoint.c (print_breakpoint_location): Don't call
7659 find_pc_sect_function.
7660 * linespec.c (create_sals_line_offset): Record the location's
7662 * linespec.c (convert_address_location_to_sals): Fill in sal's
7663 symbol with find_pc_sect_containing_function.
7664 * symtab.c (find_function_start_sal): Rename to ...
7665 (find_function_start_sal_1): ... this.
7666 (find_function_start_sal): Reimplement as wrapper around
7667 find_function_start_sal_1, and use
7668 find_pc_sect_containing_function to fill in the sal's symbol.
7669 (find_function_start_sal(symbol*, bool)): Adjust.
7670 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
7672 (find_pc_sect_containing_function): Declare.
7674 2018-06-29 Pedro Alves <palves@redhat.com>
7676 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
7677 true if the the location has no symbol.
7679 2018-06-28 Tom Tromey <tom@tromey.com>
7681 * NEWS: Mention --enable-codesign.
7682 * silent-rules.mk (ECHO_SIGN): New variable.
7683 * configure.ac: Add --enable-codesign.
7684 * configure: Rebuild.
7685 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
7686 (gdb$(EXEEXT)): Optionally invoke codesign.
7688 2018-06-28 Pedro Alves <palves@redhat.com>
7690 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
7692 (switch_to_thread_no_regs): Adjust comment.
7693 * infcmd.c (stop_pc): Delete.
7694 (post_create_inferior, info_program_command): Replace references
7695 to stop_pc with references to thread_info->suspend.stop_pc.
7696 * inferior.h (stop_pc): Delete declaration.
7697 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
7698 (handle_inferior_event_1, handle_signal_stop)
7699 (process_event_stop_test, keep_going_stepped_thread)
7700 (handle_step_into_function, handle_step_into_function_backward)
7701 (print_stop_location): Replace references to stop_pc with
7702 references to thread_info->suspend.stop_pc.
7703 (struct infcall_suspend_state) <stop_pc>: Delete field.
7704 (save_infcall_suspend_state, restore_infcall_suspend_state):
7705 Remove references to inf_stat->stop_pc.
7706 * linux-fork.c (fork_load_infrun_state): Likewise.
7707 * record-btrace.c (record_btrace_set_replay): Likewise.
7708 * record-full.c (record_full_goto_entry): Likewise.
7709 * remote.c (print_one_stopped_thread): Likewise.
7710 * target.c (target_resume): Extend comment.
7711 * thread.c (set_executing_thread): New.
7712 (set_executing): Use it.
7713 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
7714 Remove references to stop_pc.
7716 2018-06-28 Pedro Alves <palves@redhat.com>
7718 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
7719 Moving fetching stop_pc until after ecs->event_thread is refreshed.
7721 2018-06-28 Tom Tromey <tom@tromey.com>
7723 * coffread.c (coff_symfile_finish): Update.
7724 * xcoffread.c (xcoff_symfile_finish): Update.
7725 * elfread.c (elf_symfile_finish): Update.
7726 * symfile.h (dwarf2_free_objfile): Don't declare.
7727 * dwarf2read.c (_initialize_dwarf2_read): Use
7728 register_objfile_data_with_cleanup.
7729 (dwarf2_free_objfile): Now static. Change signature.
7731 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7733 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
7734 option "-o" to add-symbol-file-load to add an offset to each
7735 section's load address.
7736 * symfile.c (set_objfile_default_section_offset): New function.
7738 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7740 * symfile.c (add_symbol_file_command): Make sure that sections
7741 with the same name are sorted in the same order.
7743 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7745 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
7746 require the second argument. If omitted, load sections at the
7747 addresses specified in the file.
7749 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7751 * symfile.c (symbol_file_command, symbol_file_add_main_1)
7752 (_initialize_symfile): Add option "-o" to symbol-file to add an
7753 offset to each section of the symbol file.
7755 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7757 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
7759 2018-06-27 Tom Tromey <tom@tromey.com>
7761 * stack.c (_initialize_stack): Update "func" help text.
7763 2018-06-27 Tom Tromey <tom@tromey.com>
7765 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
7767 (unwind_infopy_str, pyuw_create_unwind_info)
7768 (unwind_infopy_add_saved_register, pyuw_sniffer)
7769 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
7771 (struct saved_reg): Add constructor.
7772 <value>: Now a gdbpy_ref<>.
7774 2018-06-27 Tom Tromey <tom@tromey.com>
7776 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
7778 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7780 * gdb-gdb.py.in: Format using autopep8.
7782 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7784 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
7785 (type_lookup_function): Recognize CORE_ADDR values.
7787 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7789 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
7792 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7794 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
7797 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7799 * gdb-gdb.py: Move to...
7800 * gdb-gdb.py.in: ... here.
7801 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
7802 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
7804 (distclean): Remove gdb-gdb.py when cleaning.
7805 (gdb-gdb.py, gdb-gdb.gdb): New rules.
7806 * configure: Re-generate.
7808 2018-06-27 Pedro Alves <palves@redhat.com>
7810 * proc-service.c (get_ps_regcache): New.
7811 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7812 (ps_lsetfpregs): Use it.
7814 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
7817 * dwarf2read.c (lnp_state_machine::check_line_address): Update
7819 (dwarf_decode_lines_1): Adjust.
7821 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7823 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
7825 <info_proc>: Likewise.
7827 2018-06-26 Joel Brobecker <brobecker@adacore.com>
7829 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
7830 to windows_fetch_one_register, and only handle the case of
7831 fetching one register. Move the code that reloads the context
7832 and iterates over all registers if R is negative to...
7833 (windows_nat_target::fetch_registers): ... here.
7834 (do_windows_store_inferior_registers): Rename to
7835 windows_store_one_register, and only handle the case of storing
7836 one register. Move the code that handles the case where r is
7838 (windows_nat_target::store_registers) ... here.
7840 2018-06-26 Tom Tromey <tom@tromey.com>
7843 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
7844 * rust-lang.c (rust_print_struct_def): Add podata parameter.
7846 (rust_internal_print_type): Add podata parameter.
7847 (rust_print_type): Update.
7849 2018-06-26 Tom Tromey <tom@tromey.com>
7851 * typeprint.h (struct print_offset_data) <update, finish,
7852 maybe_print_hole>: New methods.
7853 <indentation>: New constant.
7854 * typeprint.c (print_offset_data::indentation): Define.
7855 (print_offset_data::maybe_print_hole, print_offset_data::update)
7856 (print_offset_data::finish): Move from c-typeprint.c and rename.
7857 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
7858 (print_spaces_filtered_with_print_options): Update.
7859 (c_print_type_union_field_offset, maybe_print_hole)
7860 (c_print_type_struct_field_offset): Move to typeprint.c and
7862 (c_type_print_base_struct_union): Update.
7864 2018-06-25 Pedro Alves <palves@redhat.com>
7866 * gdbthread.h (thread_info_ref, delete_thread)
7867 (delete_thread_silent, first_thread_of_inferior)
7868 (any_thread_of_inferior, switch_to_thread)
7869 (enable_thread_stack_temporaries)
7870 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7871 (get_last_thread_stack_temporary)
7872 (value_in_thread_stack_temporaries, can_access_registers_thread):
7873 Spell out "struct thread_info" instead of just "thread_info".
7874 * inferior.h (notice_new_inferior): Likewise.
7876 2018-06-25 Pedro Alves <palves@redhat.com>
7878 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7879 pass thread_info pointer to delete_thread.
7880 (windows_nat_target::detach): Pass inferior pointer to
7882 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
7884 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
7885 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
7886 and pass a thread_info pointer to delete_thread.
7887 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
7888 pass thread_info pointer to delete_thread.
7889 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
7890 delete_thread_silent call.
7891 * procfs.c (procfs_target::detach): Pass inferior pointer to
7893 (procfs_target::wait): Pass thread_info pointer to delete_thread.
7894 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
7895 delete_thread_silent call.
7896 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7897 pass thread_info pointer to delete_thread.
7898 (windows_nat_target::detach): Pass inferior pointer to
7901 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7903 * regcache.c (readable_regcache::read_part): Fix asserts.
7904 (reg_buffer::raw_collect_part): New function.
7905 (regcache::write_part): Fix asserts.
7906 (reg_buffer::raw_supply_part): New function.
7907 (regcache::transfer_regset_register): New helper function.
7908 (regcache::transfer_regset): Call new functions.
7909 (regcache_supply_regset): Use gdb_byte*.
7910 (regcache::supply_regset): Likewise.
7911 (regcache_collect_regset): Likewise.
7912 (regcache::collect_regset): Likewise.
7913 * regcache.h (reg_buffer::raw_collect_part): New declaration.
7914 (reg_buffer::raw_supply_part): Likewise.
7915 (regcache::transfer_regset_register): Likewise.
7916 (regcache::transfer_regset): Use gdb_byte*.
7918 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7920 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
7922 2018-06-21 Pedro Alves <palves@redhat.com>
7924 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
7925 instead of a ptid_t. All callers adjusted.
7926 * ada-tasks.c (ada_get_task_number): Likewise. All callers
7928 (print_ada_task_info, display_current_task_id, task_command_1):
7930 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
7932 (breakpoint_kind): Adjust.
7933 (remove_breakpoints_pid): Rename to ...
7934 (remove_breakpoints_inf): ... this. Adjust to take an inferior
7935 pointer. All callers adjusted.
7936 (bpstat_clear_actions): Use inferior_thread.
7937 (get_bpstat_thread): New.
7938 (bpstat_do_actions): Use it.
7939 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
7940 to take a thread_info pointer. All callers adjusted.
7941 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
7942 (breakpoint_re_set_thread): Use inferior_thread.
7943 * breakpoint.h (struct inferior): Forward declare.
7944 (bpstat_stop_status): Update.
7945 (remove_breakpoints_pid): Delete.
7946 (remove_breakpoints_inf): New.
7947 * bsd-uthread.c (bsd_uthread_target::wait)
7948 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
7949 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
7950 (maint_btrace_packet_history_cmd)
7951 (maint_btrace_clear_packet_history_cmd): Adjust.
7952 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
7954 * cli/cli-interp.c: Include "inferior.h".
7955 * common/refcounted-object.h (struct
7956 refcounted_object_ref_policy): New.
7957 * compile/compile-object-load.c: Include gdbthread.h.
7958 (store_regs): Use inferior_thread.
7959 * corelow.c (core_target::close): Use current_inferior.
7960 (core_target_open): Adjust to use first_thread_of_inferior and use
7961 the current inferior.
7962 * ctf.c (ctf_target::close): Adjust to use current_inferior.
7963 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
7964 <thread>: ... this new field. All references adjusted.
7965 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
7966 Take a thread_info pointer instead of a ptid_t.
7967 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
7968 (dummy_frame_discard, register_dummy_frame_dtor): Take a
7969 thread_info pointer instead of a ptid_t.
7970 * elfread.c: Include "inferior.h".
7971 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
7972 Use inferior_thread.
7973 * eval.c (evaluate_subexp): Likewise.
7974 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
7976 * gdb_proc_service.h (struct thread_info): Forward declare.
7977 (struct ps_prochandle) <ptid>: Delete, replaced by ...
7978 <thread>: ... this new field. All references adjusted.
7979 * gdbarch.h, gdbarch.c: Regenerate.
7980 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
7981 'thread' parameter. All implementations and callers adjusted.
7982 * gdbthread.h (thread_info) <set_running>: New method.
7983 (delete_thread, delete_thread_silent): Take a thread_info pointer
7985 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
7986 (first_thread_of_process): Delete, replaced by ...
7987 (first_thread_of_inferior): ... this new function. All callers
7989 (any_live_thread_of_process): Delete, replaced by ...
7990 (any_live_thread_of_inferior): ... this new function. All callers
7992 (switch_to_thread, switch_to_no_thread): Declare.
7993 (is_executing): Delete.
7994 (enable_thread_stack_temporaries): Update comment.
7995 <enable_thread_stack_temporaries>: Take a thread_info pointer
7996 instead of a ptid_t. Incref the thread.
7997 <~enable_thread_stack_temporaries>: Decref the thread.
8000 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
8001 (get_last_thread_stack_temporary)
8002 (value_in_thread_stack_temporaries, can_access_registers_thread):
8003 Take a thread_info pointer instead of a ptid_t. All callers
8005 * infcall.c (get_call_return_value): Use inferior_thread.
8006 (run_inferior_call): Work with thread pointers instead of ptid_t.
8007 (call_function_by_hand_dummy): Work with thread pointers instead
8008 of ptid_t. Use thread_info_ref.
8009 * infcmd.c (proceed_thread_callback): Access thread's state
8011 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
8012 access thread's state directly.
8013 (continue_command): Use inferior_thread.
8014 (info_program_command): Use find_thread_ptid and access thread
8016 (proceed_after_attach_callback): Use thread state directly.
8017 (notice_new_inferior): Take a thread_info pointer instead of a
8018 ptid_t. All callers adjusted.
8019 (exit_inferior): Take an inferior pointer instead of a pid. All
8021 (exit_inferior_silent): New.
8022 (detach_inferior): Delete.
8023 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
8024 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
8025 (detach_inferior_command, kill_inferior_command): Use
8026 find_inferior_id instead of valid_gdb_inferior_id and
8027 gdb_inferior_id_to_pid.
8028 (inferior_command): Use inferior and thread pointers.
8029 * inferior.h (struct thread_info): Forward declare.
8030 (notice_new_inferior): Take a thread_info pointer instead of a
8031 ptid_t. All callers adjusted.
8032 (detach_inferior): Delete declaration.
8033 (exit_inferior, exit_inferior_silent): Take an inferior pointer
8034 instead of a pid. All callers adjusted.
8035 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
8036 (valid_gdb_inferior_id): Delete.
8037 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
8038 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
8039 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
8041 <inf>: ... this new field.
8042 <step_ptid>: Delete, replaced by ...
8043 <step_thread>: ... this new field.
8044 (get_displaced_stepping_state): Take an inferior pointer instead
8045 of a pid. All callers adjusted.
8046 (displaced_step_in_progress_any_inferior): Adjust.
8047 (displaced_step_in_progress_thread): Take a thread pointer instead
8048 of a ptid_t. All callers adjusted.
8049 (displaced_step_in_progress, add_displaced_stepping_state): Take
8050 an inferior pointer instead of a pid. All callers adjusted.
8051 (get_displaced_step_closure_by_addr): Adjust.
8052 (remove_displaced_stepping_state): Take an inferior pointer
8053 instead of a pid. All callers adjusted.
8054 (displaced_step_prepare_throw, displaced_step_prepare)
8055 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
8056 All callers adjusted.
8057 (start_step_over): Adjust.
8058 (infrun_thread_ptid_changed): Remove bit updating ptids in the
8059 displaced step queue.
8060 (do_target_resume): Adjust.
8061 (fetch_inferior_event): Use inferior_thread.
8062 (context_switch, get_inferior_stop_soon): Take an
8063 execution_control_state pointer instead of a ptid_t. All callers
8065 (switch_to_thread_cleanup): Delete.
8066 (stop_all_threads): Use scoped_restore_current_thread.
8067 * inline-frame.c: Include "gdbthread.h".
8068 (inline_state) <inline_state>: Take a thread pointer instead of a
8069 ptid_t. All callers adjusted.
8070 <ptid>: Delete, replaced by ...
8071 <thread>: ... this new field.
8072 (find_inline_frame_state): Take a thread pointer instead of a
8073 ptid_t. All callers adjusted.
8074 (skip_inline_frames, step_into_inline_frame)
8075 (inline_skipped_frames, inline_skipped_symbol): Take a thread
8076 pointer instead of a ptid_t. All callers adjusted.
8077 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
8078 (inline_skipped_frames, inline_skipped_symbol): Likewise.
8079 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
8081 * linux-nat.c (get_detach_signal): Likewise.
8082 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
8083 (thread_db_notice_clone): Adjust.
8084 (thread_db_find_new_threads_silently)
8085 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
8086 a thread pointer instead of a ptid_t. All callers adjusted.
8087 * mi/mi-cmd-var.c: Include "inferior.h".
8088 (mi_cmd_var_update_iter): Update to use thread pointers.
8089 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
8091 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
8093 (mi_output_running): ... this new function.
8094 (mi_on_resume_1): Adjust to use it.
8095 (mi_user_selected_context_changed): Adjust to use inferior_thread.
8096 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
8098 (interrupt_thread_callback): : Adjust to use thread and inferior
8100 * proc-service.c: Include "gdbthread.h".
8101 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
8102 * progspace-and-thread.c: Include "inferior.h".
8103 * progspace.c: Include "inferior.h".
8104 * python/py-exitedevent.c (create_exited_event_object): Adjust to
8105 hold a reference to an inferior_object.
8106 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
8108 * python/py-inferior.c (struct inferior_object): Give the type a
8109 tag name instead of a typedef.
8110 (python_on_normal_stop): No need to check if the current thread is
8112 (inferior_to_inferior_object): Change return type to
8113 inferior_object. All callers adjusted.
8114 (find_thread_object): Delete, bits factored out to ...
8115 (thread_to_thread_object): ... this new function.
8116 * python/py-infthread.c (create_thread_object): Use
8117 inferior_to_inferior_object.
8118 (thpy_is_stopped): Use thread pointer directly.
8119 (gdbpy_selected_thread): Use inferior_thread.
8120 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
8121 field, replaced with ...
8122 <thread>: ... this new field. All users adjusted.
8123 (btpy_insn_or_gap_new): Drop const.
8124 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
8126 * python/py-record.c: Include "gdbthread.h".
8127 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
8128 a ptid_t. All callers adjusted.
8129 (gdbpy_current_recording): Use inferior_thread.
8130 * python/py-record.h (recpy_record_object) <ptid>: Delete
8131 field, replaced with ...
8132 <thread>: ... this new field. All users adjusted.
8133 (recpy_element_object) <ptid>: Delete
8134 field, replaced with ...
8135 <thread>: ... this new field. All users adjusted.
8136 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
8137 a ptid_t. All callers adjusted.
8138 * python/py-threadevent.c: Include "gdbthread.h".
8139 (get_event_thread): Use thread_to_thread_object.
8140 * python/python-internal.h (struct inferior_object): Forward
8142 (find_thread_object, find_inferior_object): Delete declarations.
8143 (thread_to_thread_object, inferior_to_inferior_object): New
8145 * record-btrace.c: Include "inferior.h".
8146 (require_btrace_thread): Use inferior_thread.
8147 (record_btrace_frame_sniffer)
8148 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
8149 (get_thread_current_frame): Use scoped_restore_current_thread and
8151 (get_thread_current_frame): Use thread pointer directly.
8152 (record_btrace_replay_at_breakpoint): Use thread's inferior
8154 * record-full.c: Include "inferior.h".
8155 * regcache.c: Include "gdbthread.h".
8156 (get_thread_arch_regcache): Use the inferior's address space
8158 (get_thread_regcache, registers_changed_thread): New.
8159 * regcache.h (get_thread_regcache(thread_info *thread)): New
8161 (registers_changed_thread): New.
8162 (remote_target) <remote_detach_1>: Swap order of parameters.
8163 (remote_add_thread): <remote_add_thread>: Return the new thread.
8164 (get_remote_thread_info(ptid_t)): New overload.
8165 (remote_target::remote_notice_new_inferior): Use thread pointers
8167 (remote_target::process_initial_stop_replies): Use
8168 thread_info::set_running.
8169 (remote_target::remote_detach_1, remote_target::detach)
8170 (extended_remote_target::detach): Adjust.
8171 * stack.c (frame_show_address): Use inferior_thread.
8172 * target-debug.h (target_debug_print_thread_info_pp): New.
8173 * target-delegates.c: Regenerate.
8174 * target.c (default_thread_address_space): Delete.
8175 (memory_xfer_partial_1): Use current_inferior.
8176 (target_detach): Use current_inferior.
8177 (target_thread_address_space): Delete.
8178 (generic_mourn_inferior): Use current_inferior.
8179 * target.h (struct target_ops) <thread_address_space>: Delete.
8180 (target_thread_address_space): Delete.
8181 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
8183 (delete_thread_1, delete_thread, delete_thread_silent): Take a
8184 thread pointer instead of a ptid_t. Adjust all callers.
8185 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
8186 (first_thread_of_process): Delete, replaced by ...
8187 (first_thread_of_inferior): ... this new function. All callers
8189 (any_thread_of_process): Rename to ...
8190 (any_thread_of_inferior): ... this, and take an inferior pointer.
8191 (any_live_thread_of_process): Rename to ...
8192 (any_live_thread_of_inferior): ... this, and take an inferior
8194 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
8195 (value_in_thread_stack_temporaries)
8196 (get_last_thread_stack_temporary): Take a thread pointer instead
8197 of a ptid_t. Adjust all callers.
8198 (thread_info::set_running): New.
8199 (validate_registers_access): Use inferior_thread.
8200 (can_access_registers_ptid): Rename to ...
8201 (can_access_registers_thread): ... this, and take a thread
8203 (print_thread_info_1): Adjust to compare thread pointers instead
8205 (switch_to_no_thread, switch_to_thread): Make extern.
8206 (scoped_restore_current_thread::~scoped_restore_current_thread):
8207 Use m_thread pointer directly.
8208 (scoped_restore_current_thread::scoped_restore_current_thread):
8209 Use inferior_thread.
8210 (thread_command): Use thread pointer directly.
8211 (thread_num_make_value_helper): Use inferior_thread.
8212 * top.c (execute_command): Use inferior_thread.
8213 * tui/tui-interp.c: Include "inferior.h".
8214 * varobj.c (varobj_create): Use inferior_thread.
8215 (value_of_root_1): Use find_thread_global_id instead of
8216 global_thread_id_to_ptid.
8218 2018-06-21 Alan Hayward <alan.hayward@arm.com>
8220 * regcache.c (readable_regcache::read_part): Avoid memcpy when
8222 (regcache::write_part): Likewise.
8223 (readable_regcache::cooked_read_part): Update comment.
8224 (readable_regcache::cooked_write_part): Likewise.
8225 * regcache.h: (readable_regcache::read_part): Likewise.
8226 (regcache::write_part): Likewise.
8228 2018-06-21 Richard Bunt <richard.bunt@arm.com>
8229 Dirk Schubert <dirk.schubert@arm.com>
8231 * aarch64-linux-nat.c (post_attach): New.
8232 (aarch64_linux_nat_target::post_attach): Override post_attach to
8233 record the number of hardware debug registers.
8235 2018-06-20 Tom Tromey <tom@tromey.com>
8237 * python/py-param.c (add_setshow_generic): Make parameters const.
8238 (parmpy_init): Update.
8240 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
8242 * regcache.h (regcache_cooked_read_ftype): Rename to...
8243 (register_read_ftype): ...this, change type to function_view.
8244 (class reg_buffer) <save>: Remove src parameter.
8245 (readonly_detached_regcache) <readonly_detached_regcache>: Make
8246 parameter non-const in first overload. Remove src parameter in
8248 * regcache.c (do_cooked_read): Remove.
8249 (readonly_detached_regcache::readonly_detached_regcache): Make
8250 parameter non-const, adjust call to other constructor.
8251 (reg_buffer::save): Remove src parameter.
8252 * frame.c (do_frame_register_read): Remove.
8253 (frame_save_as_regcache): Use lambda function.
8254 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
8255 parameter to ppu2spu_data *.
8256 (ppu2spu_sniffer): Use lambda function.
8258 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
8260 * record-full.c (record_full_target::insert_breakpoint): Remove
8261 "struct" keyword, add const.
8263 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
8265 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
8266 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
8267 * configure.ac: Remove AC_PREREQ, add missing quoting.
8268 * gnulib/configure.ac: Modernize usage of
8269 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
8270 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
8271 (AUTOMAKE_VERSION): Bump to 1.15.1.
8272 * configure: Re-generate.
8273 * config.in: Re-generate.
8274 * aclocal.m4: Re-generate.
8275 * gnulib/aclocal.m4: Re-generate.
8276 * gnulib/config.in: Re-generate.
8277 * gnulib/configure: Re-generate.
8278 * gnulib/import/Makefile.in: Re-generate.
8280 2018-06-19 Pedro Alves <palves@redhat.com>
8282 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
8283 (lookup_minimal_symbol_by_pc_section): ... here with
8284 gdb_assert_not_reached added.
8286 2018-06-19 Pedro Alves <palves@redhat.com>
8288 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
8289 parameter with a block parameter. Compare location's block symbol
8290 with the frame's block instead of addresses.
8291 (skip_inline_frames): Pass the current block instead of the
8292 frame's address. Break out as soon as we determine the frame
8293 should not be skipped.
8295 2018-06-18 Tom Tromey <tom@tromey.com>
8297 * solib-aix.c (solib_aix_get_section_offsets): Return
8299 (solib_aix_solib_create_inferior_hook): Update.
8301 2018-06-18 Tom Tromey <tom@tromey.com>
8303 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
8305 2018-06-18 Tom Tromey <tom@tromey.com>
8307 * solib-frv.c (frv_relocate_main_executable): Use
8309 * solib-dsbt.c (dsbt_relocate_main_executable): Use
8312 2018-06-18 Tom Tromey <tom@tromey.com>
8314 * objfiles.h (inhibit_section_map_updates): Update.
8315 (resume_section_map_updates, resume_section_map_updates_cleanup):
8317 * solib-svr4.c (svr4_handle_solib_event): Update.
8318 * objfiles.c (inhibit_section_map_updates): Return
8319 scoped_restore_tmpl<int>.
8320 (resume_section_map_updates, resume_section_map_updates_cleanup):
8323 2018-06-18 Tom Tromey <tom@tromey.com>
8325 * valprint.h (read_string): Update.
8326 * valprint.c (read_string): Change type of "buffer".
8327 (val_print_string): Update.
8328 * python/py-value.c (valpy_string): Update.
8329 * language.h (struct language_defn) <la_get_string>: Change
8331 (default_get_string, c_get_string): Update.
8332 * language.c (default_get_string): Change type of "buffer".
8333 * guile/scm-value.c (gdbscm_value_to_string): Update.
8334 * c-lang.c (c_get_string): Change type of "buffer".
8336 2018-06-18 Tom Tromey <tom@tromey.com>
8338 * ser-mingw.c (struct pipe_state_destroyer): New.
8339 (pipe_state_up): New typedef.
8340 (cleanup_pipe_state): Remove.
8341 (pipe_windows_open): Use pipe_state_up. Don't release argv.
8343 2018-06-18 Tom Tromey <tom@tromey.com>
8345 * rust-lang.h (rust_yyerror): Don't declare.
8346 * rust-lang.c (rust_language_defn): Update.
8347 * rust-exp.y (yyerror): Now static.
8348 * parse.c (parse_exp_in_context_1): Update.
8349 * p-lang.h (p_yyerror): Don't declare.
8350 * p-lang.c (p_language_defn): Update.
8351 * p-exp.y (yyerror): Now static.
8352 * opencl-lang.c (opencl_language_defn): Update.
8353 * objc-lang.c (objc_language_defn): Update.
8354 * m2-lang.h (m2_yyerror): Don't declare.
8355 * m2-lang.c (m2_language_defn): Update.
8356 * m2-exp.y (yyerror): Now static.
8357 * language.h (struct language_defn) <la_error>: Remove.
8358 * language.c (unk_lang_error): Remove.
8359 (unknown_language_defn, auto_language_defn): Remove.
8360 * go-lang.h (go_yyerror): Don't declare.
8361 * go-lang.c (go_language_defn): Update.
8362 * go-exp.y (yyerror): Now static.
8363 * f-lang.h (f_yyerror): Don't declare.
8364 * f-lang.c (f_language_defn): Update.
8365 * f-exp.y (yyerror): Now static.
8366 * d-lang.h (d_yyerror): Don't declare.
8367 * d-lang.c (d_language_defn): Update.
8368 * d-exp.y (yyerror): Now static.
8369 * c-lang.h (c_yyerror): Don't declare.
8370 * c-lang.c (c_language_defn, cplus_language_defn)
8371 (asm_language_defn, minimal_language_defn): Update.
8372 * c-exp.y (yyerror): Now static.
8373 * ada-lang.h (ada_yyerror): Don't declare.
8374 * ada-lang.c (ada_language_defn): Update.
8375 * ada-exp.y (yyerror): Now static.
8377 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8379 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
8380 (store_sveregs_to_thread): Likewise.
8381 (aarch64_linux_fetch_inferior_registers): Check for SVE.
8382 (aarch64_linux_store_inferior_registers): Likewise.
8383 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
8385 (aarch64_sve_regs_copy_to_regcache): Likewise.
8386 (aarch64_sve_regs_copy_from_regcache): Likewise.
8387 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
8389 (aarch64_sve_regs_copy_to_regcache): Likewise.
8390 (aarch64_sve_regs_copy_from_regcache): Likewise.
8391 (sve_context): Structure from Linux headers.
8392 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
8393 (SVE_SIG_ZREG_SIZE): Likewise.
8394 (SVE_SIG_PREG_SIZE): Likewise.
8395 (SVE_SIG_FFR_SIZE): Likewise.
8396 (SVE_SIG_REGS_OFFSET): Likewise.
8397 (SVE_SIG_ZREGS_OFFSET): Likewise.
8398 (SVE_SIG_ZREG_OFFSET): Likewise.
8399 (SVE_SIG_ZREGS_SIZE): Likewise.
8400 (SVE_SIG_PREGS_OFFSET): Likewise.
8401 (SVE_SIG_PREG_OFFSET): Likewise.
8402 (SVE_SIG_PREGS_SIZE): Likewise.
8403 (SVE_SIG_FFR_OFFSET): Likewise.
8404 (SVE_SIG_REGS_SIZE): Likewise.
8405 (SVE_SIG_CONTEXT_SIZE): Likewise.
8406 (SVE_PT_REGS_MASK): Likewise.
8407 (SVE_PT_REGS_FPSIMD): Likewise.
8408 (SVE_PT_REGS_SVE): Likewise.
8409 (SVE_PT_VL_INHERIT): Likewise.
8410 (SVE_PT_VL_ONEXEC): Likewise.
8411 (SVE_PT_REGS_OFFSET): Likewise.
8412 (SVE_PT_FPSIMD_OFFSET): Likewise.
8413 (SVE_PT_FPSIMD_SIZE): Likewise.
8414 (SVE_PT_SVE_ZREG_SIZE): Likewise.
8415 (SVE_PT_SVE_PREG_SIZE): Likewise.
8416 (SVE_PT_SVE_FFR_SIZE): Likewise.
8417 (SVE_PT_SVE_FPSR_SIZE): Likewise.
8418 (SVE_PT_SVE_FPCR_SIZE): Likewise.
8419 (__SVE_SIG_TO_PT): Likewise.
8420 (SVE_PT_SVE_OFFSET): Likewise.
8421 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
8422 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
8423 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
8424 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
8425 (SVE_PT_SVE_PREG_OFFSET): Likewise.
8426 (SVE_PT_SVE_PREGS_SIZE): Likewise.
8427 (SVE_PT_SVE_FFR_OFFSET): Likewise.
8428 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
8429 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
8430 (SVE_PT_SVE_SIZE): Likewise.
8431 (SVE_PT_SIZE): Likewise.
8432 (HAS_SVE_STATE): New define.
8434 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8436 * nat/aarch64-sve-linux-sigcontext.h: New file.
8437 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
8439 (SVE_VQ_MIN): Likewise.
8440 (SVE_VQ_MAX): Likewise.
8441 (SVE_VL_MIN): Likewise.
8442 (SVE_VL_MAX): Likewise.
8443 (SVE_NUM_ZREGS): Likewise.
8444 (SVE_NUM_PREGS): Likewise.
8445 (sve_vl_valid): Likewise.
8446 (struct user_sve_header): Likewise.
8448 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
8449 Richard Bunt <Richard.Bunt@arm.com>
8451 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
8452 was requested by GDB.
8454 2018-06-15 Tom de Vries <tdevries@suse.de>
8456 * MAINTAINERS (Write After Approval): Add Tom de Vries.
8458 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
8460 * gnulib/update-gnulib.sh: Print expected versions of
8463 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
8465 * arch-utils.c (default_type_align): Use type_length_units.
8466 * gdbtypes.c (type_align): Use type_length_units.
8468 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8470 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
8471 of 'define' command.
8473 2018-06-14 Tom de Vries <tdevries@suse.de>
8476 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
8477 get_no_prettyformat_print_options.
8479 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
8481 * sparc-nat.h: Include target.h.
8482 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
8483 <fetch_registers>: Remove this argument in function call.
8484 <store_registers>: Remove this argument in function call, remove
8486 <low_forget_process>: Call sparc64_forget_process instead of
8487 sparc_forget_process.
8489 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8491 * procfs.c (_initialize_procfs): Use add_inf_child_target.
8492 (procfs_target::make_corefile_notes): Adjust to new
8493 target_read_alloc return type.
8495 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8496 Stephen Roberts <stephen.roberts@arm.com>
8499 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
8500 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
8501 Move should_notify_stop local into more inner scope.
8503 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8504 Stephen Roberts <stephen.roberts@arm.com>
8507 * infrun.c (resume_1): Add call to mark_async_event_handler.
8509 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8511 * infrun.c (do_target_wait): Change old version of $pc printed.
8513 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
8515 * dwarf2read.c (read_index_from_section): Rename to...
8516 (read_gdb_index_from_section): ... this, update all callers.
8517 (dwarf2_read_index): Rename to...
8518 (dwarf2_read_gdb_index): ... this, update all callers.
8520 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
8523 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
8524 hppa_linux_nat_target::fetch_registers.
8526 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8528 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
8529 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
8530 (AARCH64_DWARF_SVE_FFR): Likewise.
8531 (AARCH64_DWARF_SVE_P0): Likewise.
8532 (AARCH64_DWARF_SVE_Z0): Likewise.
8534 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8536 * common/common-regcache.h (raw_compare): New function.
8537 * regcache.c (regcache::raw_compare): Likewise.
8538 * regcache.h (regcache::raw_compare): New declaration.
8540 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8542 * common/common-regcache.h (reg_buffer_common): New structure.
8543 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
8544 (reg_buffer::raw_supply): Likewise.
8545 (reg_buffer::raw_supply_integer): Likewise.
8546 (reg_buffer::raw_supply_zeroed): Likewise.
8547 (reg_buffer::raw_collect): Likewise.
8548 (reg_buffer::raw_collect_integer): Likewise.
8549 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
8550 (reg_buffer::raw_supply): Likewise.
8551 (reg_buffer::raw_supply_integer): Likewise.
8552 (reg_buffer::raw_supply_zeroed): Likewise.
8553 (reg_buffer::raw_collect): Likewise.
8554 (reg_buffer::raw_collect_integer): Likewise.
8556 2018-06-10 Tom Tromey <tom@tromey.com>
8558 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
8559 (class remote_state) <stop_reply_queue>: Now std::vector.
8560 (remote_state::~remote_state)
8561 (remote_target::stop_reply_queue_length): Update.
8562 (struct queue_iter_param, remove_child_of_pending_fork)
8563 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
8564 (check_pending_event_prevents_wildcard_vcont_callback)
8565 (remove_stop_reply_for_inferior)
8566 (remove_stop_reply_of_remote_state)
8567 (remote_notif_remove_once_on_match)
8568 (stop_reply_match_ptid_and_ws)
8569 (remote_kill_child_of_pending_fork): Remove.
8570 (remote_target::remove_new_fork_children)
8571 (remote_target::check_pending_events_prevent_wildcard_vcont)
8572 (remote_target::discard_pending_stop_replies)
8573 (remote_target::discard_pending_stop_replies_in_queue)
8574 (remote_target::remote_notif_remove_queued_reply)
8575 (remote_target::queued_stop_reply)
8576 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
8577 (remote_target::wait, remote_target::kill_new_fork_children)
8578 (remote_target::async): Update.
8580 2018-06-10 Tom Tromey <tom@tromey.com>
8582 * record-full.c (record_full_arch_list_cleanups): Remove.
8583 (record_full_message): Use try/catch.
8584 (record_full_wait_cleanups): Remove.
8585 (record_full_wait_1): Use try/catch.
8586 (record_full_restore): Likewise.
8588 2018-06-10 Tom Tromey <tom@tromey.com>
8590 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
8591 declare VEC. Add constructor.
8592 <in_target_beneath>: Now bool.
8593 (record_full_breakpoints): Now a std::vector, static.
8594 (record_full_sync_record_breakpoints)
8595 (record_full_init_record_breakpoints)
8596 (record_full_target::insert_breakpoint)
8597 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
8599 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8601 * dwarf2read.c (process_cu_includes): Remove struct keyword.
8602 * serial.c (serial_interface_lookup): Remove struct keyword.
8604 2018-06-10 Tom Tromey <tom@tromey.com>
8606 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
8608 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
8610 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
8612 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
8613 "beneath" as a method.
8614 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
8615 Use "beneath" as a method.
8617 2018-06-10 Tom Tromey <tom@tromey.com>
8619 * tracefile.c (struct trace_file_writer_deleter): New.
8620 <operator()>: Rename from trace_file_writer_xfree.
8621 (trace_file_writer_up): New typedef.
8622 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
8624 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8626 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
8627 <m_registers, m_register_status>: Change type to
8629 * regcache.c (reg_buffer::reg_buffer): Use new instead of
8632 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8634 * common/common-regcache.h (enum register_status): Add
8635 underlying type "signed char".
8636 * regcache.h (reg_buffer) <m_register_status>: Change type to
8638 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
8639 register_status instead of signed char.
8640 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
8641 (reg_buffer::get_register_status): Remove cast.
8642 (readable_regcache::raw_read): Remove cast.
8643 (readable_regcache::cooked_read): Remove cast.
8645 2018-06-09 Tom Tromey <tom@tromey.com>
8647 * source.c (reverse_search_command, forward_search_command): Use
8650 2018-06-09 Tom Tromey <tom@tromey.com>
8652 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
8653 (serial_ops_list): Now static, std::vector.
8654 (serial_interface_lookup, serial_add_interface): Update.
8656 2018-06-09 Tom Tromey <tom@tromey.com>
8658 * dwarf2read.c (process_cu_includes): Update.
8659 (process_full_comp_unit): Update.
8660 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
8663 2018-06-08 Paul Koning <paul_koning@dell.com>
8667 * python/python.c (do_start_initialization):
8668 Avoid call to internal Python API.
8669 (init__gdb_module): New function.
8671 2018-06-08 Gary Benson <gbenson@redhat.com>
8673 * linux-thread-db.c (valprint.h): New include.
8674 (struct check_thread_db_info): New structure.
8675 (check_thread_db_on_load, tdb_testinfo): New static globals.
8676 (check_thread_db, check_thread_db_callback): New functions.
8677 (try_thread_db_load_1): Run integrity checks if requested.
8678 (maintenance_check_libthread_db): New function.
8679 (_initialize_thread_db): Register "maint check libthread-db"
8680 and "maint set/show check-libthread-db".
8681 * NEWS: Mention the above new commands.
8683 2018-06-08 Tom Tromey <tom@tromey.com>
8685 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
8688 2018-06-08 Tom Tromey <tom@tromey.com>
8690 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
8692 2018-06-08 Tom Tromey <tom@tromey.com>
8694 * common/btrace-common.h (struct btrace_data): Add constructor,
8695 destructor, move assignment operator.
8696 <empty, clear, fini>: New methods.
8697 <format>: Initialize.
8698 (btrace_data_init, btrace_data_fini, btrace_data_clear)
8699 (btrace_data_empty): Don't declare.
8700 * common/btrace-common.c (btrace_data_init): Remove.
8701 (btrace_data::fini): Rename from btrace_data_fini.
8702 (btrace_data::empty): Rename from btrace_data_empty.
8703 (btrace_data::clear): Rename from btrace_data_clear. Return
8705 * btrace.h (make_cleanup_btrace_data): Don't declare.
8706 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
8707 (parse_xml_btrace): Update.
8708 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
8709 (maint_btrace_clear_packet_history_cmd): Update.
8711 2018-06-07 Pedro Alves <palves@redhat.com>
8713 * target.h (target_ops) <beneath>: Now a method. All references
8715 (class target_stack): New.
8716 * target.c (g_target_stack): New.
8717 (g_current_top_target): Delete.
8718 (current_top_target): Get the top target out of g_target_stack.
8719 (target_stack::push, target_stack::unpush): New.
8720 (push_target, unpush_target): Reimplement.
8721 (target_is_pushed): Reimplement in terms of g_target_stack.
8722 (target_ops::beneath, target_stack::find_beneath): New.
8724 2018-06-07 Pedro Alves <palves@redhat.com>
8726 * target.h (find_target_beneath): Delete declaration.
8727 * target.c (find_target_beneath): Delete definition.
8728 * aix-thread.c: All callers of find_target_beneath adjusted to
8729 call target_ops::beneath instead.
8730 * bsd-uthread.c: Likewise.
8731 * linux-thread-db.c: Likewise.
8732 * ravenscar-thread.c: Likewise.
8733 * sol-thread.c: Likewise.
8734 * spu-multiarch.c: Likewise.
8736 2018-06-07 Pedro Alves <palves@redhat.com>
8738 * target.h (target_ops) <beneath>: Now a method. All references
8740 (target_ops) <m_beneath>: New.
8741 * target.c (target_ops::beneath): New.
8742 * corelow.c: Adjust all references to target_ops::beneath.
8743 * linux-thread-db.c: Likewise.
8744 * make-target-delegates: Likewise.
8745 * record-btrace.c: Likewise.
8746 * record-full.c: Likewise.
8747 * remote.c: Likewise.
8748 * target.c: Likewise.
8749 * target-delegates.c: Regenerate.
8751 2018-06-07 Pedro Alves <palves@redhat.com>
8753 * target.h (target_stack): Delete.
8754 (current_top_target): Declare function.
8755 * target.c (target_stack): Delete.
8756 (g_current_top_target): New.
8757 (current_top_target): New function.
8758 * auxv.c: Use current_top_target instead of target_stack
8760 * avr-tdep.c: Likewise.
8761 * breakpoint.c: Likewise.
8762 * corefile.c: Likewise.
8763 * elfread.c: Likewise.
8765 * exceptions.c: Likewise.
8766 * frame.c: Likewise.
8767 * gdbarch-selftests.c: Likewise.
8768 * gnu-v3-abi.c: Likewise.
8769 * ia64-tdep.c: Likewise.
8770 * ia64-vms-tdep.c: Likewise.
8771 * infcall.c: Likewise.
8772 * infcmd.c: Likewise.
8773 * infrun.c: Likewise.
8774 * linespec.c: Likewise.
8775 * linux-tdep.c: Likewise.
8776 * minsyms.c: Likewise.
8777 * ppc-linux-nat.c: Likewise.
8778 * ppc-linux-tdep.c: Likewise.
8779 * procfs.c: Likewise.
8780 * regcache.c: Likewise.
8781 * remote.c: Likewise.
8782 * rs6000-tdep.c: Likewise.
8783 * s390-linux-nat.c: Likewise.
8784 * s390-tdep.c: Likewise.
8785 * solib-aix.c: Likewise.
8786 * solib-darwin.c: Likewise.
8787 * solib-dsbt.c: Likewise.
8788 * solib-spu.c: Likewise.
8789 * solib-svr4.c: Likewise.
8790 * solib-target.c: Likewise.
8791 * sparc-tdep.c: Likewise.
8792 * sparc64-tdep.c: Likewise.
8793 * spu-tdep.c: Likewise.
8794 * symfile.c: Likewise.
8795 * symtab.c: Likewise.
8796 * target-descriptions.c: Likewise.
8797 * target-memory.c: Likewise.
8798 * target.c: Likewise.
8799 * target.h: Likewise.
8800 * tracefile-tfile.c: Likewise.
8801 * tracepoint.c: Likewise.
8802 * valops.c: Likewise.
8803 * valprint.c: Likewise.
8804 * value.c: Likewise.
8805 * windows-tdep.c: Likewise.
8806 * mi/mi-main.c: Likewise.
8808 2018-06-07 Tom Tromey <tom@tromey.com>
8810 * valprint.h (build_address_symbolic): Declare.
8811 * printcmd.c (print_address_symbolic): Update.
8812 (build_address_symbolic): Change "name" and "filename" to
8814 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
8816 * defs.h (build_address_symbolic): Remove declaration.
8818 2018-06-07 Alan Hayward <alan.hayward@arm.com>
8820 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
8821 (aarch64_vnv_type): Add function.
8822 (aarch64_pseudo_register_name): Add V regs for SVE.
8823 (aarch64_pseudo_register_type): Likewise.
8824 (aarch64_pseudo_register_reggroup_p): Likewise.
8825 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
8826 (aarch64_pseudo_read_value): Add V regs for SVE.
8827 (aarch64_pseudo_write_2): Use V0 offset for SVE
8828 (aarch64_pseudo_write): Add V regs for SVE.
8829 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
8831 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
8833 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
8834 (sve_vl_from_vq): Likewise.
8836 2018-06-05 Tom Tromey <tom@tromey.com>
8838 * cli/cli-cmds.c (show_version): Update.
8839 * top.c (print_gdb_version): Add "interactive" parameter.
8841 * main.c (captured_main_1): Update.
8842 * top.h (print_gdb_version): Add "interactive" parameter and a
8845 2018-06-05 David Malcolm <dmalcolm@redhat.com>
8847 * common/enum-flags.h: Add trailing semicolon to example in
8850 2018-06-05 Tom Tromey <tom@tromey.com>
8853 * NEWS: Add entry about pager.
8854 * utils.c (pagination_disabled_for_command): New global.
8855 (prompt_for_continue): Allow "c" response to prompt.
8856 (reinitialize_more_filter): Clear
8857 pagination_disabled_for_command.
8858 (fputs_maybe_filtered): Check pagination_disabled_for_command.
8860 2018-06-04 Tom Tromey <tom@tromey.com>
8862 * ada-lang.h (ada_lookup_symbol_list): Update.
8863 * ada-lang.c (resolve_subexp): Update.
8864 (symbols_are_identical_enums): Change type of syms. Remove nsyms
8866 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
8867 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
8868 results parameter to std::vector.
8869 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
8871 * ada-exp.y (block_lookup): Update.
8872 (select_possible_type_sym): Change type of syms. Remove nsyms
8874 (write_var_or_type, write_name_assoc): Update.
8876 2018-06-04 Joel Brobecker <brobecker@adacore.com>
8878 * windows-nat.c (windows_nat_target::xfer_partial): Return
8879 TARGET_XFER_E_IO if we need to delegate to the target beneath
8880 but BENEATH is NULL.
8882 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
8884 * Makefile.in (config.status): Add configure.nat as a
8887 2018-06-04 Tom Tromey <tom@tromey.com>
8889 * cp-name-parser.y (cpname_state): Add method declarations.
8890 (HANDLE_QUAL): Update.
8891 (cpname_state::d_grab, cpname_state::fill_comp)
8892 (cpname_state::make_operator, cpname_state::make_dtor)
8893 (cpname_state::make_builtin_type, cpname_state::make_name)
8894 (cpname_state::d_qualify, cpname_state::d_int_type)
8895 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
8896 (%union): Move earlier.
8898 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8900 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
8902 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8904 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
8905 (aarch64_pseudo_write_1): Likewise.
8906 (aarch64_pseudo_read_value): Use helper.
8907 (aarch64_pseudo_write): Likewise.
8909 2018-06-04 Pedro Alves <palves@redhat.com>
8911 * darwin-nat.c (darwin_ops): Delete.
8912 (darwin_attach_pid): Use get_native_target.
8914 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8916 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
8917 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
8919 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8921 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
8922 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
8923 (aarch64_gdbarch_init): Check for SVE.
8924 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
8926 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8928 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
8929 * aarch64-tdep.h (aarch64_read_description): Likewise.
8930 * arch/aarch64.c (aarch64_create_target_description): Likewise.
8931 * arch/aarch64.h (aarch64_create_target_description): Likewise.
8932 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
8933 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
8934 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
8936 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
8938 * value.c (value_fetch_lazy_bitfield): New.
8939 (value_fetch_lazy_memory): New.
8940 (value_fetch_lazy_register): New.
8941 (value_fetch_lazy): Factor out to smaller functions.
8943 2018-06-01 Tom Tromey <tom@tromey.com>
8945 * cp-name-parser.y (backslashable, represented): Now const.
8947 2018-06-01 Tom Tromey <tom@tromey.com>
8949 * cp-name-parser.y: Include parser-defs.h.
8950 (parser_fprintf): Remove declaration.
8952 2018-06-01 Tom Tromey <tom@tromey.com>
8954 * cp-name-parser.y: Use %pure-parser, %lex-param, and
8956 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
8957 (global_result): Remove globals.
8958 (struct cpname_state): New.
8959 (yyparse): Don't declare.
8960 (yylex, yyerror): Move declarations after %union.
8961 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
8962 (make_name): Add state parameter.
8964 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
8966 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
8968 (yylex): Add lvalp, state parameters.
8969 (yyerror): Add state parameter.
8970 (cp_demangled_name_to_comp): Update.
8972 2018-06-01 Tom Tromey <tom@tromey.com>
8974 * cp-name-parser.y (parser_fprintf): Declare.
8975 (GDB_YY_REMAP_PREFIX): Define.
8976 Include yy-remap.h. Don't redefine yy* identifiers.
8978 2018-06-01 Tom Tromey <tom@tromey.com>
8980 * python/py-type.c (typy_legacy_template_argument): Update.
8981 * cp-support.h (cp_demangled_name_to_comp): Update.
8982 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
8983 parameter to be a "std::string *".
8986 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
8988 * ada-lex.l: Include "diagnostics.h" instead of
8989 "common/diagnostics.h".
8990 * unittests/environ-selftests.c: Likewise.
8991 * common/diagnostics.h: Moved to ../include.
8993 2018-06-01 Joel Brobecker <brobecker@adacore.com>
8995 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
8996 to language_mode_manual while calling breakpoint_re_set_one.
8998 2018-06-01 Tom Tromey <tom@tromey.com>
9000 * valops.c (value_cast_structs, destructor_name_p): Update.
9001 * symtab.c (gdb_mangle_name): Update.
9002 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
9004 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
9005 (pascal_object_print_value_fields, pascal_object_print_value):
9007 * p-typeprint.c (pascal_type_print_derivation_info): Update.
9008 * linespec.c (find_methods): Update.
9009 * gdbtypes.h (type_name_no_tag): Remove.
9010 (type_name_or_error): Rename from type_name_no_tag_or_error.
9011 * gdbtypes.c (type_name_no_tag): Remove.
9012 (type_name_or_error): Rename from type_name_no_tag_or_error.
9013 (lookup_struct_elt_type, check_typedef): Update.
9014 * expprint.c (print_subexp_standard): Update.
9015 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
9016 * d-namespace.c (d_lookup_nested_symbol): Update.
9017 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
9018 (cp_print_class_member): Update.
9019 * cp-namespace.c (cp_lookup_nested_symbol): Update.
9020 * completer.c (add_struct_fields): Update.
9021 * c-typeprint.c (cp_type_print_derivation_info)
9022 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
9024 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
9025 (ada_prefer_type, ada_is_exception_sym): Update.
9027 2018-06-01 Tom Tromey <tom@tromey.com>
9029 * valops.c (enum_constant_from_type, value_namespace_elt)
9030 (value_maybe_namespace_elt): Update.
9031 * valarith.c (find_size_for_pointer_math): Update.
9032 * target-descriptions.c (make_gdb_type): Update.
9033 * symmisc.c (print_symbol): Update.
9034 * stabsread.c (define_symbol, read_type)
9035 (complain_about_struct_wipeout, add_undefined_type)
9036 (cleanup_undefined_types_1): Update.
9037 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
9038 (rust_range_type_p, val_print_struct, rust_print_struct_def)
9039 (rust_internal_print_type, rust_composite_type)
9040 (rust_evaluate_funcall, rust_evaluate_subexp)
9041 (rust_inclusive_range_type_p): Update.
9042 * python/py-type.c (typy_get_tag): Update.
9043 * p-typeprint.c (pascal_type_print_base): Update.
9044 * mdebugread.c (parse_symbol, parse_type): Update.
9045 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
9047 * guile/scm-type.c (gdbscm_type_tag): Update.
9048 * go-lang.c (sixg_string_p): Update.
9049 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
9051 * gdbtypes.h (struct main_type) <tag_name>: Remove.
9052 (TYPE_TAG_NAME): Remove.
9053 * gdbtypes.c (type_name_no_tag): Simplify.
9054 (check_typedef, check_types_equal, recursive_dump_type)
9055 (copy_type_recursive, arch_composite_type): Update.
9056 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
9057 in summary mode when needed.
9058 * eval.c (evaluate_funcall): Update.
9059 * dwarf2read.c (fixup_go_packaging, read_structure_type)
9060 (process_structure_scope, read_enumeration_type)
9061 (read_namespace_type, read_module_type, determine_prefix): Update.
9062 * cp-support.c (inspect_type): Update.
9063 * coffread.c (process_coff_symbol, decode_base_type): Update.
9064 * c-varobj.c (c_is_path_expr_parent): Update.
9065 * c-typeprint.c (c_type_print_base_struct_union): Update.
9066 (c_type_print_base_1): Update. Print struct/class/union/enum in
9067 summary when using C language.
9068 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
9069 (gen_maybe_namespace_elt): Update.
9070 * ada-lang.c (ada_type_name): Simplify.
9071 (empty_record, ada_template_to_fixed_record_type_1)
9072 (template_to_static_fixed_type)
9073 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
9075 2018-06-01 Tom Tromey <tom@tromey.com>
9077 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
9079 * c-typeprint.c (c_print_type_1): Add "language" parameter.
9080 (c_print_type): Update.
9081 (c_print_type): New overload.
9082 (c_type_print_varspec_prefix, c_type_print_args)
9083 (c_type_print_varspec_suffix, c_print_type_no_offsets)
9084 (c_type_print_base_struct_union, c_type_print_base_1)
9085 (cp_type_print_method_args): Add "language" parameter.
9086 (c_type_print_base): Update.
9087 * c-lang.h (c_print_type): Add new overload.
9089 2018-06-01 Tom Tromey <tom@tromey.com>
9091 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
9092 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
9094 2018-06-01 Alan Hayward <alan.hayward@arm.com>
9096 * aarch64-tdep.c (aarch64_sve_register_names): New const
9098 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
9099 (AARCH64_SVE_Z_REGS_NUM): New define.
9100 (AARCH64_SVE_P_REGS_NUM): Likewise.
9101 (AARCH64_SVE_NUM_REGS): Likewise.
9103 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
9105 * nat/linux-ptrace.h [__alpha__]
9106 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
9109 2018-05-31 Maciej W. Rozycki <macro@mips.com>
9111 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
9112 the endianness selected.
9113 * NEWS: Document `set endian auto' mode operation update.
9115 2018-05-31 Alan Hayward <alan.hayward@arm.com>
9117 * Makefile.in: Add new header.
9118 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
9119 (sve_vl_from_vg): Likewise.
9120 (sve_vq_from_vl): Likewise.
9121 (sve_vl_from_vq): Likewise.
9122 (sve_vq_from_vg): Likewise.
9123 (sve_vg_from_vq): Likewise.
9124 * configure.nat: Add new c file.
9125 * nat/aarch64-sve-linux-ptrace.c: New file.
9126 * nat/aarch64-sve-linux-ptrace.h: New file.
9128 2018-05-31 Alan Hayward <alan.hayward@arm.com>
9130 * aarch64-linux-nat.c (aarch64_linux_read_description):
9132 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
9134 * aarch64-tdep.c (tdesc_aarch64_list): Add.
9135 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
9136 (aarch64_gdbarch_init): Add parmeter zero.
9137 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
9138 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
9139 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
9141 * doc/gdb.texinfo: Describe SVE feature
9142 * features/aarch64-sve.c: New file.
9144 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
9147 * gdbarch.sh (significant_addr_bit): Default to zero when
9148 not set by target architecture.
9149 * gdbarch.c: Re-generated.
9150 * utils.c (address_significant): Update.
9152 2018-05-30 Joel Brobecker <brobecker@adacore.com>
9154 * stack.c (func_command): Remove trailing newline in call to error.
9156 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9158 * regcache.h (regcache_raw_collect): Remove, update callers to
9159 use regcache::raw_collect.
9160 * regcache.c (regcache_raw_collect): Remove.
9162 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9164 * regcache.h (regcache_raw_supply): Remove, update callers to
9165 use detached_regcache::raw_supply.
9166 * regcache.c (regcache_raw_supply): Remove.
9168 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9170 * regcache.h (regcache_cooked_write_part): Remove, update
9171 callers to use regcache::cooked_write_part.
9172 * regcache.c (regcache_cooked_write_part): Remove.
9174 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9176 * regcache.h (regcache_cooked_read_part): Remove, update callers
9177 to use readable_regcache::cooked_read_part.
9178 * regcache.c (regcache_cooked_read_part): Remove.
9180 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9182 * regcache.h (regcache_cooked_read_value): Remove, update
9183 callers to use readable_regcache::cooked_read_value.
9184 * regcache.c (regcache_cooked_read_value): Remove.
9186 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9188 * regcache.h (regcache_cooked_write): Remove, update callers to
9189 use regcache::cooked_write.
9190 * regcache.c (regcache_cooked_write): Remove.
9192 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9194 * regcache.h (regcache_invalidate): Remove, update callers to
9195 use detached_regcache::invalidate instead.
9196 * regcache.c (regcache_invalidate): Remove.
9198 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9200 * regcache.h (regcache_raw_write_part): Remove, update callers
9201 to use regcache::raw_write_part instead.
9202 * regcache.c (regcache_raw_write_part): Remove.
9204 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9206 * regcache.h (regcache_raw_read_part): Remove, update callers to
9207 use readable_regcache::raw_read_part instead.
9208 * regcache.c (regcache_raw_read_part): Remove.
9210 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9212 * regcache.h (regcache_cooked_read): Remove, update callers to
9213 use readable_regcache::cooked_read instead.
9214 * regcache.c (regcache_cooked_read): Remove.
9216 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9218 * regcache.h (regcache_raw_write): Remove, update callers to use
9219 regcache::raw_write instead.
9220 * regcache.c (regcache_raw_write): Remove.
9222 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9224 * regcache.h (regcache_raw_read): Remove, update callers to use
9225 readable_regcache::raw_read instead.
9226 * regcache.c (regcache_raw_read): Remove.
9228 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9230 * regcache.h (regcache_raw_update): Remove, update callers to
9231 use readable_regcache::raw_update instead.
9232 * regcache.c (regcache_raw_update): Remove.
9234 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9236 * regcache.h (regcache_register_status): Remove, update callers
9237 to use reg_buffer::get_register_status directly instead.
9238 * regcache.c (regcache_register_status): Remove.
9240 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9242 * regcache.h (regcache_get_ptid): Remove, update all callers to
9243 call regcache::ptid instead.
9244 * regcache.c (regcache_get_ptid): Remove.
9246 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9248 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
9250 2018-05-30 Pedro Alves <palves@redhat.com>
9252 * common/common-exceptions.h (exception_rethrow): Use
9255 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
9257 * breakpoint.c (print_solib_event, check_status_catch_solib):
9258 Remove struct keyword in range-based for loops.
9259 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
9260 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
9262 * linespec.c (find_superclass_methods, search_minsyms_for_name):
9264 * symfile.c (addr_info_make_relative): Likewise.
9265 * thread.c (value_in_thread_stack_temporaries): Likewise.
9267 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
9270 * valops.c (value_struct_elt_for_reference): Call check_typedef on
9271 aggregate type to get its real type before accessing it.
9273 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
9275 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
9276 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
9277 * coff-pe-read.c (add_pe_forwarded_sym): Replace
9278 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
9279 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
9280 * jit.c (jit_breakpoint_re_set_internal): Likewise.
9281 * printcmd.c (info_address_command): Likewise.
9283 2018-05-29 Tom Tromey <tom@tromey.com>
9285 * windows-nat.c (handle_exception): Update fall-through comment.
9287 2018-05-29 Tom Tromey <tom@tromey.com>
9289 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
9290 (struct program_space) <added_solibs>: Now a std::vector.
9291 * breakpoint.c (print_solib_event): Update.
9292 (check_status_catch_solib): Update.
9293 * progspace.c (clear_program_space_solib_cache): Update.
9294 * solib.c (update_solib_list): Update.
9296 2018-05-29 Tom Tromey <tom@tromey.com>
9298 * python/py-type.c (typy_richcompare): Update.
9299 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
9300 * gdbtypes.h (types_deeply_equal): Return bool.
9301 (types_equal): Likewise.
9302 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
9304 (check_types_equal): Change worklist to std::vector. Return
9306 (struct type_equality_entry): Add constructor.
9307 (compare_maybe_null_strings): Return bool.
9308 (check_types_worklist): Return bool. Change worklist to
9310 (types_deeply_equal): Use std::vector.
9311 (types_equal): Return bool.
9312 (compare_maybe_null_strings): Simplify.
9314 2018-05-29 Tom Tromey <tom@tromey.com>
9316 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
9318 2018-05-29 Tom Tromey <tom@tromey.com>
9320 * objc-lang.h: Don't include cp-support.h.
9321 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
9324 2018-05-27 Tom Tromey <tom@tromey.com>
9326 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
9328 2018-05-25 Tom Tromey <tom@tromey.com>
9330 * value.c (value::location): Initialize.
9332 2018-05-25 Tom Tromey <tom@tromey.com>
9334 * dbxread.c (init_bincl_list): Remove.
9335 (bincl_list): Now a std::vector.
9336 (bincls_allocated, next_bincl): Remove.
9337 (free_bincl_list, do_free_bincl_list_cleanup)
9338 (make_cleanup_free_bincl_list): Remove.
9339 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
9341 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
9342 (struct header_file_location): Add constructor.
9343 (add_bincl_to_list): Remove.
9345 2018-05-25 Tom Tromey <tom@tromey.com>
9347 * tui/tui.c (tui_enable): Update.
9348 * mi/mi-interp.c (mi_interp::init): Update.
9349 * interps.h (class interp) <name>: New method.
9350 <m_name>: Rename from name.
9351 (~scoped_restore_interp): Update.
9352 * interps.c (interp::interp): Update.
9353 (interp_add, interp_set, interp_lookup_existing)
9354 (current_interp_named_p): Update.
9356 2018-05-25 Tom Tromey <tom@tromey.com>
9358 * interps.c (interp_name): Remove.
9359 * mi/mi-interp.c (mi_interp::init): Update.
9360 * interps.h (interp_name): Remove.
9361 (~scoped_restore_interp): Update.
9362 * tui/tui.c (tui_enable): Update.
9364 2018-05-25 Tom Tromey <tom@tromey.com>
9366 * utils.c (fputs_maybe_filtered): Update.
9367 * linespec.c (decode_line_full): Update.
9368 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
9369 (mi_print_breakpoint_for_event, mi_solib_loaded)
9370 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
9371 (mi_user_selected_context_changed): Update.
9372 * mi/mi-main.c (mi_execute_command): Update.
9373 * cli/cli-script.c (execute_control_command): Update.
9374 * python/python.c (execute_gdb_command): Update.
9375 * solib.c (info_sharedlibrary_command): Update.
9376 * interps.c (interp_ui_out): Remove.
9377 * interps.h (interp_ui_out): Remove.
9379 2018-05-25 Tom Tromey <tom@tromey.com>
9381 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
9382 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
9383 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
9385 2018-05-25 Tom Tromey <tom@tromey.com>
9387 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
9388 * interps.c (interp_exec): Use scoped_restore.
9390 2018-05-25 Tom Tromey <tom@tromey.com>
9392 * remote.c (remote_target::remote_file_get): Use
9394 (remote_target::remote_file_put): Likewise.
9396 2018-05-25 Tom Tromey <tom@tromey.com>
9398 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
9400 (get_pe_section_index, add_pe_exported_sym): Update.
9401 (read_pe_exported_syms): Use gdb::def_vector.
9403 2018-05-25 Tom Tromey <tom@tromey.com>
9405 * frame.c (remove_prev_frame): Remove.
9406 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
9408 2018-05-25 Maciej W. Rozycki <macro@mips.com>
9410 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
9412 * mips-linux-nat.c (supply_fpregset): Always call
9413 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
9414 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
9415 `mips_fill_fpregset'.
9416 * mips-linux-tdep.c (mips_supply_fpregset)
9417 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
9418 (mips_fill_fpregset_wrapper): Remove functions.
9419 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
9420 (mips_linux_fpregset): Remove variable.
9421 (mips_linux_iterate_over_regset_sections): Use
9422 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
9423 (mips_linux_o32_sigframe_init): Remove comment.
9425 2018-05-25 Pedro Alves <palves@redhat.com>
9427 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
9428 (struct readahead_cache, struct packet_reg, struct
9429 remote_arch_state, class remote_state): Move higher up in the
9431 (remote_target::m_remote_state): Now an object instead of a pointer.
9432 (remote_target::get_remote_state): Adjust.
9434 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9436 * stack.c (select_and_print_frame): Delete.
9437 (struct function_bounds): Move struct within function.
9438 (func_command): Most content moved into new function
9439 find_frame_for_function, use new function, print result, add
9441 (find_frame_for_function): New function, now returns a result.
9443 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9445 * stack.c (iterate_over_block_arg_vars): Fix comment.
9446 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
9448 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9452 (scoped_restore_selected_frame::scoped_restore_selected_frame):
9454 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
9456 * frame.h (class scoped_restore_selected_frame): New class.
9457 * stack.c (print_frame_local_vars): Remove catching and rethrowing
9458 of any exception, use scoped_restore_selected_frame to restore the
9461 2018-05-24 Pedro Alves <palves@redhat.com>
9463 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
9466 2018-05-23 Tom Tromey <tom@tromey.com>
9468 * complaints.c (struct complaints): Remove.
9469 (symfile_complaint_book): Remove.
9470 (series): New global.
9471 (complaint_internal): Update.
9472 (clear_complaints): Update.
9474 2018-05-23 Tom Tromey <tom@tromey.com>
9476 * complaints.c (counters): New global.
9477 (struct complain): Remove.
9478 (struct complaints) <root>: Remove.
9479 (complaint_sentinel): Remove.
9480 (symfile_complaint_book): Update.
9481 (find_complaint) Remove.
9482 (complaint_internal, clear_complaints): Update.
9484 2018-05-23 Tom Tromey <tom@tromey.com>
9486 * complaints.c (struct complain) <file, line>: Remove.
9487 (find_complaint): Remove file, line parameters.
9488 (complaint_internal): Update.
9490 2018-05-23 Tom Tromey <tom@tromey.com>
9492 * complaints.c (vcomplaint): Remove.
9493 (complaint_internal) Merge in contents of vcomplaint.
9495 2018-05-23 Tom Tromey <tom@tromey.com>
9497 * complaints.c (struct complaints) <explanation>: Remove.
9498 (symfile_explanations): Remove.
9499 (symfile_complaint_book): Update.
9500 (vcomplaint): Update.
9501 (struct explanation): Remove.
9503 2018-05-23 Tom Tromey <tom@tromey.com>
9505 * complaints.c (symfile_complaints): Remove.
9506 (complaint_internal): Remove "complaints" parameter.
9507 (clear_complaints, vcomplaint): Remove "c" parameter.
9508 (get_complaints): Remove.
9509 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
9510 (dwarf2_debug_line_missing_file_complaint)
9511 (dwarf2_debug_line_missing_end_sequence_complaint)
9512 (dwarf2_complex_location_expr_complaint)
9513 (dwarf2_const_value_length_mismatch_complaint)
9514 (dwarf2_section_buffer_overflow_complaint)
9515 (dwarf2_macro_malformed_definition_complaint)
9516 (dwarf2_invalid_attrib_class_complaint)
9517 (create_addrmap_from_index, dw2_symtab_iter_next)
9518 (dw2_expand_marked_cus)
9519 (dw2_debug_names_iterator::find_vec_in_debug_names)
9520 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
9521 (create_debug_type_hash_table, init_cutu_and_read_dies)
9522 (partial_die_parent_scope, add_partial_enumeration)
9523 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
9524 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
9525 (read_import_statement, read_file_scope, create_dwo_cu_reader)
9526 (create_cus_hash_table, create_dwp_hash_table)
9527 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
9528 (dwarf2_rnglists_process, dwarf2_ranges_process)
9529 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
9530 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
9531 (handle_struct_member_die, process_structure_scope)
9532 (read_array_type, read_common_block, read_module_type)
9533 (read_tag_pointer_type, read_typedef, read_base_type)
9534 (read_subrange_type, load_partial_dies, partial_die_info::read)
9535 (partial_die_info::read, partial_die_info::read)
9536 (partial_die_info::read, read_checked_initial_length_and_offset)
9537 (dwarf2_string_attr, read_formatted_entries)
9538 (dwarf_decode_line_header)
9539 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
9540 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
9541 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
9542 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9543 (get_signatured_type, get_DW_AT_signature_type)
9544 (decode_locdesc, file_file_name, consume_improper_spaces)
9545 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
9546 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9547 (dwarf2_symbol_mark_computed, set_die_type)
9548 (read_attribute_value): Update.
9549 * stap-probe.c (handle_stap_probe, get_stap_base_address):
9551 * dbxread.c (unknown_symtype_complaint)
9552 (lbrac_mismatch_complaint, repeated_header_complaint)
9553 (set_namestring, function_outside_compilation_unit_complaint)
9554 (read_dbx_symtab, process_one_symbol): Update.
9555 * gdbtypes.c (stub_noname_complaint): Update.
9556 * windows-nat.c (handle_unload_dll): Update.
9557 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
9558 (decode_base_type): Update.
9559 * xcoffread.c (bf_notfound_complaint, ef_complaint)
9560 (eb_complaint, record_include_begin, record_include_end)
9561 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
9562 (process_xcoff_symbol, read_symbol)
9563 (function_outside_compilation_unit_complaint)
9564 (scan_xcoff_symtab): Update.
9565 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
9566 * buildsym.c (finish_block_internal, make_blockvector)
9567 (end_symtab_get_static_block, augment_type_symtab): Update.
9568 * dtrace-probe.c (dtrace_process_dof)
9569 (dtrace_static_probe_ops::get_probes): Update.
9570 * complaints.h (struct complaint): Don't declare.
9571 (symfile_complaints): Remove.
9572 (complaint_internal): Remove "complaints" parameter.
9573 (complaint): Likewise.
9574 (clear_complaints): Likewise.
9575 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9576 (reread_symbols): Update.
9577 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
9578 (dwarf2_frame_cache, decode_frame_entry): Update.
9579 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
9580 * objc-lang.c (lookup_objc_class, lookup_child_selector)
9581 (info_selectors_command): Update.
9582 * macrotab.c (macro_include, check_for_redefinition)
9583 (macro_undef): Update.
9584 * objfiles.c (filter_overlapping_sections): Update.
9585 * stabsread.c (invalid_cpp_abbrev_complaint)
9586 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
9587 (define_symbol, error_type, read_type, rs6000_builtin_type)
9588 (stabs_method_name_from_physname, read_member_functions)
9589 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
9590 (attach_fields_to_type, complain_about_struct_wipeout)
9591 (read_range_type, read_args, common_block_start)
9592 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
9594 * mdebugread.c (index_complaint, unknown_ext_complaint)
9595 (basic_type_complaint, bad_tag_guess_complaint)
9596 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
9597 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
9598 (parse_procedure, parse_lines)
9599 (function_outside_compilation_unit_complaint)
9600 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
9601 (bad_tag_guess_complaint, reg_value_complaint): Update.
9602 * cp-support.c (demangled_name_complaint): Update.
9603 * macroscope.c (sal_macro_scope): Update.
9604 * dwarf-index-write.c (class debug_names): Update.
9606 2018-05-23 Tom Tromey <tom@tromey.com>
9608 * complaints.c (clear_complaints): Remove "noisy" parameter.
9609 * complaints.h (clear_complaints): Update.
9610 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9611 (reread_symbols): Update.
9613 2018-05-23 Tom Tromey <tom@tromey.com>
9615 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
9617 (vcomplaint, clear_complaints): Update.
9618 (symfile_explanations): Remove some messages.
9620 2018-05-23 Tom Tromey <tom@tromey.com>
9622 * complaints.c (internal_complaint): Remove.
9623 * complaints.h (internal_complaint): Remove.
9625 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9627 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
9629 2018-05-22 Pedro Alves <palves@redhat.com>
9631 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
9632 (remote_fileio_badfd, remote_fileio_return_errno)
9633 (remote_fileio_return_success, remote_fileio_func_open)
9634 (remote_fileio_func_open, remote_fileio_func_close)
9635 (remote_fileio_func_read, remote_fileio_func_write)
9636 (remote_fileio_func_lseek, remote_fileio_func_rename)
9637 (remote_fileio_func_unlink, remote_fileio_func_stat)
9638 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
9639 (remote_fileio_func_isatty, remote_fileio_func_system): Add
9640 remote_target parameter.
9641 (remote_fio_func_map) <func>: Add remote_target parameter.
9642 (do_remote_fileio_request, remote_fileio_request):
9643 * remote-fileio.h (remote_fileio_request):
9644 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
9645 remote_target parameter.
9646 (remote_notif_process, handle_notification): Adjust to pass down
9648 (remote_notif_state_allocate): Add remote_target parameter. Save
9650 * remote-notif.h (struct remote_target): Forward declare.
9651 (struct notif_client) <parse, ack, can_get_pending_events>: Add
9652 remote_target parameter.
9653 (struct remote_notif_state) <remote>: New field.
9654 (remote_notif_ack, remote_notif_parse): Add remote_target
9656 (remote_notif_state_allocate, remote_notif_state_allocate): Add
9657 remote_target parameter.
9658 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
9659 (threads_listing_context, rmt_thread_action, protocol_feature)
9660 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
9661 (packet_result, struct threads_listing_context, remote_state):
9662 Move definitions and declarations higher up.
9663 (remote_target) <~remote_target>: Declare.
9664 (remote_download_command_source, remote_file_put, remote_file_get)
9665 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
9666 (remote_hostio_pread_vFile, remote_hostio_send_command)
9667 (remote_hostio_set_filesystem, remote_hostio_open)
9668 (remote_hostio_close, remote_hostio_unlink, remote_state)
9669 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
9670 (get_memory_write_packet_size, get_memory_read_packet_size)
9671 (append_pending_thread_resumptions, remote_detach_1)
9672 (append_resumption, remote_resume_with_vcont)
9673 (add_current_inferior_and_thread, wait_ns, wait_as)
9674 (process_stop_reply, remote_notice_new_inferior)
9675 (process_initial_stop_replies, remote_add_thread)
9676 (btrace_sync_conf, remote_btrace_maybe_reopen)
9677 (remove_new_fork_children, kill_new_fork_children)
9678 (discard_pending_stop_replies, stop_reply_queue_length)
9679 (check_pending_events_prevent_wildcard_vcont)
9680 (discard_pending_stop_replies_in_queue, stop_reply)
9681 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
9682 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
9683 (remote_interrupt_as, remote_interrupt_ns)
9684 (remote_get_noisy_reply, remote_query_attached)
9685 (remote_add_inferior, remote_current_thread, get_current_thread)
9686 (set_thread, set_general_thread, set_continue_thread)
9687 (set_general_process, write_ptid)
9688 (remote_unpack_thread_info_response, remote_get_threadinfo)
9689 (parse_threadlist_response, remote_get_threadlist)
9690 (remote_threadlist_iterator, remote_get_threads_with_ql)
9691 (remote_get_threads_with_qxfer)
9692 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
9693 (get_offsets, remote_check_symbols, remote_supported_packet)
9694 (remote_query_supported, remote_packet_size)
9695 (remote_serial_quit_handler, remote_detach_pid)
9696 (remote_vcont_probe, remote_resume_with_hc)
9697 (send_interrupt_sequence, interrupt_query)
9698 (remote_notif_get_pending_events, fetch_register_using_p)
9699 (send_g_packet, process_g_packet, fetch_registers_using_g)
9700 (store_register_using_P, store_registers_using_G)
9701 (set_remote_traceframe, check_binary_download)
9702 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
9703 (remote_xfer_live_readonly_partial, remote_read_bytes)
9704 (remote_send_printf, remote_flash_write, readchar)
9705 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
9706 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
9707 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
9708 (extended_remote_disable_randomization, extended_remote_run)
9709 (send_environment_packet, extended_remote_environment_support)
9710 (extended_remote_set_inferior_cwd, remote_write_qxfer)
9711 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
9712 (packet_command): Now methods of ...
9713 (remote_target): ... this class.
9714 (m_remote_state) <remote_target>: New field.
9715 (struct remote_state) <stop_reply_queue,
9716 remote_async_inferior_event_token, wait_forever_enabled_p>: New
9718 (remote_state::remote_state): Allocate stop_reply_queue.
9719 (remote_state): Delete global.
9720 (get_remote_state_raw): Delete.
9721 (remote_target::get_remote_state): Allocate m_remote_state on
9723 (get_current_remote_target): New.
9724 (remote_ops, extended_remote_ops): Delete.
9725 (wait_forever_enabled_p, remote_async_inferior_event_token):
9726 Delete, moved to struct remote_state.
9727 (remote_target::close): Delete self. Destruction bits split to
9729 (remote_target::~remote_target): ... this.
9730 (show_memory_packet_size): Adjust to use
9731 get_current_remote_target.
9732 (struct protocol_feature) <func>: Add remote_target parameter.
9733 All callers adjusted.
9734 (curr_quit_handler_target): New.
9735 (remote_serial_quit_handler): Reimplement.
9736 (remote_target::open_1): Adjust to use get_current_remote_target.
9737 Heap-allocate remote_target/extended_remote_target instances.
9738 (vcont_builder::vcont_builder): Add remote_target parameter, and
9739 save it in m_remote. All callers adjusted.
9740 (vcont_builder::m_remote): New field.
9741 (vcont_builder::restart, vcont_builder::flush)
9742 (vcont_builder::push_action): Use it.
9743 (remote_target::commit_resume): Use it.
9744 (struct queue_iter_param) <remote>: New field.
9745 (remote_target::remove_new_fork_children): Fill in 'remote' field.
9746 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
9747 (check_pending_event_prevents_wildcard_vcont_callback)
9748 (remote_target::check_pending_events_prevent_wildcard_vcont)
9749 (remote_target::discard_pending_stop_replies)
9750 (remote_target::discard_pending_stop_replies_in_queue)
9751 (remote_target::remote_notif_remove_queued_reply): Fill in
9753 (remote_notif_get_pending_events): New.
9754 (remote_target::readchar, remote_target::remote_serial_write):
9755 Save/restore curr_quit_handler_target.
9757 (kill_new_fork_children): Fill in 'remote' field.
9758 (packet_command): Use get_current_remote_target, defer to
9759 remote_target method of same name.
9760 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
9761 parameter, and save it in m_remote. All callers adjusted.
9762 (scoped_remote_fd::release): Use m_remote.
9763 (scoped_remote_fd::m_remote): New field.
9764 (remote_file_put, remote_file_get, remote_file_delete): Use
9765 get_current_remote_target, defer to remote_target method of same
9767 (remote_btrace_reset): Add remote_state paremeter. Update all
9769 (remote_async_inferior_event_handler). Pass down 'data'.
9770 (remote_new_objfile): Use get_current_remote_target.
9771 (remote_target::vcont_r_supported): New.
9772 (set_range_stepping): Use get_current_remote_target and
9773 remote_target::vcont_r_supported.
9774 (_initialize_remote): Don't allocate 'remote_state' and
9775 'stop_reply_queue' globals.
9776 * remote.h (struct remote_target): Forward declare.
9777 (getpkt, putpkt, remote_notif_get_pending_events): Add
9778 'remote_target' parameter.
9780 2018-05-22 Pedro Alves <palves@redhat.com>
9782 * remote.c (vcont_builder): Now a class. Make all data members
9784 (vcont_builder) <vcont_builder, restart, flush, push_action>:
9786 (vcont_builder_restart): Rename to ...
9787 (vcont_builder::restart): ... this.
9788 (vcont_builder_flush): Rename to ...
9789 (vcont_builder::flush): ... this.
9790 (vcont_builder_push_action): Rename to ...
9791 (vcont_builder::push_action): ... this.
9792 (remote_target::commit_resume): Adjust.
9794 2018-05-22 Pedro Alves <palves@redhat.com>
9796 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
9797 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
9798 (get_fixed_memory_packet_size): New.
9799 (get_memory_packet_size): Use it.
9800 (set_memory_packet_size): Don't override the config size with
9801 DEFAULT_MAX_MEMORY_PACKET_SIZE.
9802 (show_memory_packet_size): Use get_fixed_memory_packet_size.
9803 Don't refer to get_memory_packet_size if not connected to a remote
9804 target. Show "(default)" if configured size is 0.
9806 2018-05-22 Pedro Alves <palves@redhat.com>
9808 * remote.c (remote_target::mourn_inferior): Move
9809 discard_pending_stop_replies call here from ...
9810 (_initialize_remote): ... here.
9812 2018-05-22 Pedro Alves <palves@redhat.com>
9814 * remote.c (compare_section_command): Remove set_general_process
9817 2018-05-22 Pedro Alves <palves@redhat.com>
9819 * remote.c (struct packet_reg, struct remote_arch_state):
9820 Move higher up in the file.
9821 (remote_state) <m_arch_states>: Store remote_arch_state values
9822 instead of remote_arch_state pointers.
9823 (remote_state::get_remote_arch_state): Adjust.
9825 2018-05-22 Pedro Alves <palves@redhat.com>
9827 * remote.c: Include <unordered_map>.
9828 (remote_state): Now a class.
9829 (remote_state) <get_remote_arch_state>: Declare method.
9830 <get_remote_arch_state>: New field.
9831 (remote_arch_state) <remote_arch_state>: Declare ctor.
9832 <regs>: Now a unique_ptr.
9833 (remote_gdbarch_data_handle): Delete.
9834 (get_remote_arch_state): Delete.
9835 (remote_state::get_remote_arch_state): New.
9836 (get_remote_state): Adjust to call remote_state's
9837 get_remote_arch_state method.
9838 (init_remote_state): Delete, bits factored out to ...
9839 (remote_arch_state::remote_arch_state): ... this new method.
9840 (get_remote_packet_size, get_memory_packet_size)
9841 (process_g_packet, remote_target::fetch_registers)
9842 (remote_target::prepare_to_store, store_registers_using_G)
9843 (remote_target::store_registers, remote_target::get_trace_status):
9844 Adjust to call remote_state's method.
9845 (_initialize_remote): Remove reference to
9846 remote_gdbarch_data_handle.
9848 2018-05-22 Pedro Alves <palves@redhat.com>
9850 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
9851 pread>: New method declarations.
9852 (remote_target::open_1): Adjust.
9853 (readahead_cache_invalidate): Rename to ...
9854 (readahead_cache::invalidate): ... this, and adjust to be a class
9856 (readahead_cache_invalidate_fd): Rename to ...
9857 (readahead_cache::invalidate_fd): ... this, and adjust to be a
9859 (remote_hostio_pwrite): Adjust.
9860 (remote_hostio_pread_from_cache): Rename to ...
9861 (readahead_cache::pread): ... this, and adjust to be a class
9863 (remote_hostio_close): Adjust.
9865 2018-05-22 Pedro Alves <palves@redhat.com>
9867 * remote.c (remote_hostio_close_cleanup): Delete.
9868 (class scoped_remote_fd): New.
9869 (remote_file_put, remote_file_get): Use it.
9871 2018-05-22 Pedro Alves <palves@redhat.com>
9873 (struct vCont_action_support): Use bool and initialize all fields.
9874 (struct readahead_cache): Initialize all fields.
9875 (remote_state): Use bool and initialize all fields.
9876 (remote_state::remote_state, remote_state::~remote_state): New.
9877 (new_remote_state): Delete.
9878 (_initialize_remote): Use new to allocate remote_state.
9880 2018-05-22 Pedro Alves <palves@redhat.com>
9884 * c-exp.y: Include "c-support.h".
9885 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
9886 of tolower. Use c_ident_is_alpha to scan names.
9887 * c-lang.c: Include "c-support.h".
9888 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
9889 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
9890 * c-support.h: New file, with bits factored out from ...
9891 * cp-name-parser.y: ... this file.
9892 Include "c-support.h".
9893 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
9894 c-support.h and renamed.
9895 (symbol_end, yylex): Adjust.
9897 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9899 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
9900 parameter type to CORE_ADDR.
9901 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
9902 parameter type in declaration to CORE_ADDR.
9903 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
9904 target_auxv_search to get AT_HWCAP and use the result to get the
9906 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
9907 to CORE_ADDR. Remove the cast of the return value to unsigned
9908 long. Fix error predicate of target_auxv_search.
9909 (ppc_linux_nat_target::read_description): Change the type of the
9910 hwcap variable to CORE_ADDR.
9912 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9914 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
9915 if the size of fpscr is larger than 32 bits.
9917 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9919 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
9920 (ppc32_linux_vsxregmap): New global.
9921 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
9922 regcache_supply_regset, and regcache_collect_regset.
9923 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
9924 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
9925 (fetch_vsx_register, store_vsx_register): Remove.
9926 (fetch_vsx_registers): Add regno parameter. Get regset using
9927 ppc_linux_vsxregset. Use regset to supply registers.
9928 (store_vsx_registers): Add regno parameter. Get regset using
9929 ppc_linux_vsxregset. Use regset to collect registers.
9930 (fetch_register): Call fetch_vsx_registers instead of
9932 (store_register): Call store_vsx_registers instead of
9934 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
9935 new regno parameter.
9936 (store_ppc_registers): Call store_vsx_registers with -1 for the
9937 new regno parameter.
9938 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
9939 (ppc_collect_vsxregset): Remove.
9941 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9943 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
9945 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
9946 for vector register offset fields.
9947 (ppc64_fbsd_reg_offsets): Likewise.
9948 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9949 to vector register offset fields.
9950 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9951 to vector register offset fields.
9952 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
9953 vector register offset fields.
9954 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
9955 initializers for vector register offset fields.
9956 (rs6000_aix64_reg_offsets): Likewise.
9957 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
9958 (ppc_supply_vrregset): Remove.
9959 (ppc_collect_vrregset): Remove.
9960 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
9961 (ppc_linux_vrregset) : New function.
9962 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
9963 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
9964 (ppc32_linux_vrregset): Remove.
9965 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
9966 and use result instead of ppc32_linux_vrregset.
9967 (ppc32_linux_reg_offsets): Remove initializers for vector register
9969 (ppc64_linux_reg_offsets): Likewise.
9970 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
9971 * ppc-linux-nat.c: Include regset.h.
9972 (gdb_vrregset_t): Adjust comment to account for little-endian
9974 (supply_vrregset, fill_vrregset): Remove.
9975 (fetch_altivec_register, store_altivec_register): Remove.
9976 (fetch_altivec_registers): Add regno parameter. Get regset using
9977 ppc_linux_vrregset. Use regset to supply registers.
9978 (store_altivec_registers): Add regno parameter. Get regset using
9979 ppc_linux_vrregset. Use regset to collect registers.
9980 (fetch_register): Call fetch_altivec_registers instead of
9981 fetch_altivec_register.
9982 (store_register): Call store_altivec_registers instead of
9983 store_altivec_register.
9984 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
9985 the new regno parameter.
9986 (store_ppc_registers): Call store_altivec_registers with -1 for
9987 the new regno parameter.
9989 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9991 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
9992 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
9993 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
9994 (gdb_vrregset_t): Change array type size to
9995 PPC_LINUX_SIZEOF_VRREGSET.
9996 (gdb_vsxregset_t): Change array type size to
9997 PPC_LINUX_SIZEOF_VSXREGSET.
9998 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
9999 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
10000 PPC_LINUX_SIZEOF_VSXREGSET.
10002 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10004 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
10005 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
10007 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
10008 ppc_linux_target_wordsize with tid.
10009 (ppc_linux_nat_target::read_description): Call ppc_linux_target
10011 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
10012 (ppc64_64bit_inferior_p): Add static and inline specifiers.
10013 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
10014 tid parameter. Remove static specifier.
10015 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
10016 (ppc_linux_target_wordsize): New declaration.
10018 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10020 * arch/ppc-linux-common.c: New file.
10021 * arch/ppc-linux-common.h: New file.
10022 * arch/ppc-linux-tdesc.h: New file.
10023 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
10024 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
10025 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
10026 arch/ppc-linux-tdesc.h.
10027 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
10028 arch/ppc-linux-tdesc.h.
10029 (ppc_linux_nat_target::read_description): Remove target
10030 description matching code. Fill a ppc_linux_features struct and
10031 call ppc_linux_match_description with it. Move comment about ISA
10032 2.05 to ppc-linux-common.c.
10033 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
10034 arch/ppc-linux-tdesc.h.
10035 (ppc_linux_core_read_description): Remove target description
10036 matching code. Fill a ppc_linux_features struct and call
10037 ppc_linux_match_description with it.
10038 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
10039 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
10040 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
10041 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
10042 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
10043 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
10044 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
10045 (tdesc_powerpc_e500l): Remove.
10047 2018-05-22 Joel Brobecker <brobecker@adacore.com>
10049 * ada-lang.c (catch_assert_command): Pass empty string instead
10050 of NULL for excep_string argument.
10052 2018-05-22 Maciej W. Rozycki <macro@mips.com>
10054 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
10055 the width of the requested register exceeds the width of the
10056 `ptrace' data type.
10058 2018-05-21 Tom Tromey <tom@tromey.com>
10060 * printcmd.c (output_command): Remove.
10061 (output_command_const): Rename to output_command.
10062 * valprint.h (output_command): Rename from output_command_const.
10063 * tracepoint.c (trace_dump_actions): Call output_command.
10065 2018-05-21 Tom Tromey <tom@tromey.com>
10067 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
10068 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
10069 * ada-lang.h (create_ada_exception_catchpoint): Update.
10070 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
10072 (create_excep_cond_exprs, ~ada_catchpoint)
10073 (should_stop_exception, print_one_exception)
10074 (print_mention_exception, print_recreate_exception): Update.
10075 (ada_get_next_arg): Remove.
10076 (catch_ada_exception_command_split): Use std::string. Change type
10077 of "excep_string", "cond_string".
10078 (catch_ada_exception_command): Update.
10079 (create_ada_exception_catchpoint): Change type of excep_string.
10080 (ada_exception_sal): Remove excep_string parameter.
10081 (~ada_catchpoint): Remove.
10083 2018-05-21 Tom Tromey <tom@tromey.com>
10085 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
10088 2018-05-21 Tom Tromey <tom@tromey.com>
10090 * ada-lang.c (ada_exception_message_1, ada_exception_message):
10091 Return unique_xmalloc_ptr.
10092 (print_it_exception): Update.
10094 2018-05-21 Tom Tromey <tom@tromey.com>
10096 * tracepoint.c (trace_dump_actions): Use std::string.
10098 2018-05-21 Tom Tromey <tom@tromey.com>
10100 * symfile.c (reread_symbols): Use std::string for original_name.
10102 2018-05-21 Tom Tromey <tom@tromey.com>
10104 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
10105 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
10108 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
10110 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
10112 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
10113 * objfiles.c (get_objfile_bfd_data): Allocate
10114 objfile_per_bfd_storage with obstack_new when allocating on
10117 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
10119 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
10121 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
10122 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
10123 * mdebugread.c (mdebug_build_psymtabs): Likewise.
10124 (add_pending): Likewise.
10125 (parse_symbol): Likewise.
10126 (parse_partial_symbols): Likewise.
10127 (psymtab_to_symtab_1): Likewise.
10128 (new_psymtab): Likewise.
10129 (elfmdebug_build_psymtabs): Likewise.
10130 * minsyms.c (terminate_minimal_symbol_table): Likewise.
10131 * objfiles.c (get_objfile_bfd_data): Likewise.
10132 (objfile_register_static_link): Likewise.
10133 * psymtab.c (allocate_psymtab): Likewise.
10134 * stabsread.c (read_member_functions): Likewise.
10135 * xcoffread.c (xcoff_end_psymtab): Likewise.
10137 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
10139 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
10140 compiler supports std::is_trivially_constructible.
10141 * common/poison.h: Include obstack.h.
10142 (IsMallocable): Define to is_trivially_constructible if the
10143 compiler supports it, define to true_type otherwise.
10145 (XOBNEW): Redefine.
10147 (XOBNEWVEC): Redefine.
10148 * gdb_obstack.h (obstack_zalloc): New.
10149 (OBSTACK_ZALLOC): Redefine.
10150 (obstack_calloc): New.
10151 (OBSTACK_CALLOC): Redefine.
10152 (obstack_new): New.
10153 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
10154 (gdbarch_obstack): New declaration in gdbarch.h, definition in
10156 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
10157 obstack_calloc/obstack_zalloc.
10158 (gdbarch_obstack_zalloc): Remove.
10159 * target-descriptions.c (tdesc_data_init): Use obstack_new.
10161 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10163 * stack.c (backtrace_command_1): Remove useless variable int i.
10165 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10167 * stack.c (print_frame_info): Fix comment.
10169 2018-05-18 Tom Tromey <tom@tromey.com>
10171 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
10172 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
10173 (~dwarf2_per_objfile): Update
10174 (dwarf2_get_dwz_file): Use new.
10175 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
10178 2018-05-18 Tom Tromey <tom@tromey.com>
10180 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
10182 * dwarf2read.c (struct dwp_file): Add constructor and
10184 (open_and_init_dwp_file): Return a unique_ptr.
10185 (dwarf2_per_objfile, create_dwp_hash_table)
10186 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
10187 (lookup_dwo_unit_in_dwp): Update.
10188 (open_and_init_dwp_file, get_dwp_file): Update.
10190 2018-05-18 Tom Tromey <tom@tromey.com>
10192 * dwarf2read.c (dwarf2_per_objfile): Update.
10193 (struct mapped_index): Add initializers.
10194 (dwarf2_read_index): Use new.
10195 (dw2_symtab_iter_init): Update.
10196 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
10199 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
10201 * dwarf2read.c (mapped_index) <total_size>: Remove.
10203 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
10205 * unittests/format_pieces-selftests.c (test_format_specifier):
10208 2018-05-18 Tom Tromey <tom@tromey.com>
10210 * c-typeprint.c (maybe_print_hole): New function.
10211 (c_print_type_struct_field_offset): Update.
10212 (c_type_print_base_struct_union): Call maybe_print_hole.
10214 2018-05-17 Keith Seitz <keiths@redhat.com>
10216 * breakpoint.c (build_bpstat_chain): New function, moved from
10217 bpstat_stop_status.
10218 (bpstat_stop_status): Add optional parameter, `stop_chain'.
10219 If no stop chain is passed, call build_bpstat_chain to build it.
10220 * breakpoint.h (build_bpstat_chain): Declare.
10221 (bpstat_stop_status): Move documentation here from breakpoint.c.
10222 * infrun.c (handle_signal_stop): Before eliding inlined frames,
10223 build the stop chain and pass it to skip_inline_frames.
10224 Pass this stop chain to bpstat_stop_status.
10225 * inline-frame.c: Include breakpoint.h.
10226 (stopped_by_user_bp_inline_frame): New function.
10227 (skip_inline_frames): Add parameter `stop_chain'.
10228 Move documention to inline-frame.h.
10229 If non-NULL, use stopped_by_user_bp_inline_frame to determine
10230 whether the frame should be elided.
10231 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
10232 Add moved documentation and update for new parameter.
10234 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
10237 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10238 unittests/format_pieces-selftests.c.
10239 * common/format.h (format_piece) <operator==>: New.
10240 (format_pieces) <operator[]>: Remove.
10241 * common/format.c (format_pieces::format_pieces): Handle \e.
10242 * unittests/format_pieces-selftests.c: New.
10244 2018-05-17 Tom Tromey <tom@tromey.com>
10247 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
10248 (dw2_instantiate_symtab): Add skip_partial parameter.
10249 (dw2_find_last_source_symtab, dw2_map_expand_apply)
10250 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
10251 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
10252 (dw2_expand_symtabs_matching_one)
10253 (dw2_find_pc_sect_compunit_symtab)
10254 (dw2_debug_names_lookup_symbol)
10255 (dw2_debug_names_expand_symtabs_for_function): Update.
10256 (init_cutu_and_read_dies): Add skip_partial parameter.
10257 (process_psymtab_comp_unit, build_type_psymtabs_1)
10258 (process_skeletonless_type_unit, load_partial_comp_unit)
10259 (psymtab_to_symtab_1): Update.
10260 (load_full_comp_unit): Add skip_partial parameter.
10261 (process_imported_unit_die, dwarf2_read_addr_index)
10262 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
10263 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
10264 (read_signatured_type): Update.
10266 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
10268 * value.c (release_value): Remove unused variable.
10269 (record_latest_value): Likewise.
10270 (access_value_history): Likewise.
10271 (preserve_values): Likewise.
10273 2018-05-17 Tom Tromey <tom@tromey.com>
10275 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
10278 2018-05-16 Maciej W. Rozycki <macro@mips.com>
10281 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
10282 Also handle registers whose width is not a multiple of
10284 (linux_nat_trad_target::store_register): Likewise.
10286 2018-05-16 Tom Tromey <tom@tromey.com>
10288 * gdbcore.h (core_bfd): Redefine.
10289 * corelow.c (core_target::close): Update.
10290 (core_target_open): Update.
10291 * progspace.h (struct program_space) <cbfd>: Now a
10294 2018-05-16 Tom Tromey <tom@tromey.com>
10297 * symfile-add-flags.h (enum symfile_add_flags)
10298 <SYMFILE_NOT_FILENAME>: New constant.
10299 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
10300 objfile name from BFD.
10301 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
10302 * minidebug.c (find_separate_debug_file_in_section): Put
10303 ".gnu_debugdata" into BFD's file name.
10305 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
10307 * regcache.c (regcache_read_ftype, regcache_write_ftype):
10310 2018-05-15 Tamar Christina <tamar.christina@arm.com>
10313 * aarch64-tdep.c (aarch64_analyze_prologue,
10314 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
10315 Indicate not interested in errors.
10317 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10319 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
10320 Supply the MIPS_ZERO_REGNUM register.
10322 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10324 * mips-tdep.c (mask_address_var): Make variable static.
10326 2018-05-14 Tom Tromey <tom@tromey.com>
10328 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
10330 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
10332 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
10333 FXSAVE_ADDR for the mxcsr register.
10335 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
10337 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
10339 2018-05-11 Pedro Alves <palves@redhat.com>
10341 * corelow.c (core_target) <core_target>: No longer inline.
10342 Initialize m_core_gdbarch, m_core_vec and build the section table
10344 <~core_target>: New.
10345 <core_gdbarch, get_core_register_section>: New methods.
10346 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
10347 factored out from ...
10348 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
10349 (core_ops): Delete.
10350 (sniff_core_bfd): Add gdbarch parameter.
10351 (core_close): Delete, merged into ...
10352 (core_target::close): ... here. Delete self.
10353 (core_close_cleanup): Delete.
10354 (core_target_open): Allocate a core_target on the heap. Use a
10355 unique_ptr instead of a cleanup. Bits moved into the core_target
10356 ctor. Adjust to use core_target methods instead of globals.
10357 (get_core_register_section): Rename to ...
10358 (core_target::get_core_register_section): ... this and adjust.
10359 (struct get_core_registers_cb_data): New.
10360 (get_core_registers_cb): Use it. Use bool.
10361 (core_target::fetch_registers, core_target::files_info)
10362 (core_target::xfer_partial, core_target::read_description)
10363 (core_target::pid_to, core_target::thread_name): Adjust to
10364 reference class fields instead of globals.
10365 * target.h (struct target_ops_deleter, target_ops_up): New.
10367 2018-05-11 Pedro Alves <palves@redhat.com>
10369 * corefile.c (core_file_command): Move to corelow.c.
10370 * corelow.c (the_core_target): Delete.
10371 (core_file_command): Moved from corefile.c. Check exec_bfd
10372 instead of the_core_target. Use target_detach instead of calling
10373 into the_core_target directly.
10374 (maybe_say_no_core_file_now): New.
10375 (core_target::detach): Use it.
10376 (_initialize_corelow): Remove references to the_core_target.
10377 * gdbcore.h (the_core_target): Delete.
10379 2018-05-11 Tom Tromey <tromey@redhat.com>
10380 Pedro Alves <palves@redhat.com>
10382 * corefile.c (core_bfd): Remove.
10383 * gdbcore.h (core_bfd): Now a macro.
10384 * progspace.h (struct program_space) <cbfd>: New field.
10386 2018-05-11 Tom Tromey <tom@tromey.com>
10388 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
10391 2018-05-10 Tom Tromey <tom@tromey.com>
10393 * configure: Rebuild.
10394 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
10396 2018-05-10 Joel Brobecker <brobecker@adacore.com>
10399 * regformats/regdat.sh: Adjust script, following the addition
10400 of the new expedite_regs parameter to init_target_desc.
10402 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
10405 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
10406 set_gdbarch_significant_addr_bit.
10407 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
10408 set_gdbarch_significant_addr_bit.
10409 * utils.c (address_significant): Update to sign extend addr.
10411 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
10413 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
10414 (xtensa_linux_init_abi): Limit tdep->num_regs by
10415 tdep->num_nopriv_regs.
10416 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
10417 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
10420 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
10422 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
10424 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
10426 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
10427 (I387_MXCSR_INIT_VAL): New constant.
10428 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
10429 buffer if it was supplied by the inferior.
10430 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
10431 (i387_xsave_get_clear_bv): New function.
10432 (i387_supply_xsave): Only read x87 control registers from the
10433 xsave buffer if the feature is enabled, and the state will have
10434 been written, otherwise, provide a suitable default.
10435 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
10436 including x87 control registers. Update control registers if they
10437 have changed from the default value, and mark features as enabled
10439 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
10441 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
10443 * spu-tdep.c (info_spu_event_command): Fix output formatting.
10445 2018-05-07 Tom Tromey <tom@tromey.com>
10447 * configure: Rebuild.
10448 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
10450 2018-05-07 Tom Tromey <tom@tromey.com>
10453 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
10454 bit. Use correct value for VDIV.
10456 2018-05-04 Tom Tromey <tom@tromey.com>
10458 * configure: Rebuild.
10459 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
10461 2018-05-04 Tom Tromey <tom@tromey.com>
10463 * linux-record.c (record_linux_system_call) <case
10464 RECORD_SYS_RECVFROM>: Add "break".
10466 2018-05-04 Tom Tromey <tom@tromey.com>
10468 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
10469 Add missing "break".
10470 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
10471 Add missing "break".
10473 2018-05-04 Tom Tromey <tom@tromey.com>
10475 * rs6000-tdep.c (ppc_process_record_op4)
10476 (ppc_process_record_op63): Add fall-through comment.
10478 2018-05-04 Tom Tromey <tom@tromey.com>
10480 * i386-tdep.c (i386_process_record): Add fall-through comment.
10482 2018-05-04 Tom Tromey <tom@tromey.com>
10484 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
10487 2018-05-04 Tom Tromey <tom@tromey.com>
10489 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
10490 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
10491 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
10493 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
10495 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
10498 2018-05-04 Tom Tromey <tom@tromey.com>
10500 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
10502 2018-05-04 Tom Tromey <tom@tromey.com>
10504 * s390-tdep.c (s390_process_record): Fix fall-through comments.
10505 * xcoffread.c (scan_xcoff_symtab): Move comment later.
10506 * symfile.c (section_is_mapped): Fix fall-through comment.
10507 * stabsread.c (define_symbol, read_member_functions): Fix
10508 fall-through comment.
10509 * s390-linux-tdep.c (s390_process_record): Fix fall-through
10511 * remote.c (remote_wait_as): Fix fall-through comment.
10512 * p-exp.y (yylex): Fix fall-through comment.
10513 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
10515 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
10516 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
10517 * jv-exp.y (yylex): Fix fall-through comment.
10518 * go-exp.y (lex_one_token): Fix fall-through comment.
10519 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
10520 fall-through comment.
10521 * f-exp.y (yylex): Fix fall-through comment.
10522 * dwarf2read.c (process_die): Fix fall-through comments.
10523 * dbxread.c (process_one_symbol): Fix fall-through comment.
10524 * d-exp.y (lex_one_token): Fix fall-through comment.
10525 * cp-name-parser.y (yylex): Fix fall-through comment.
10526 * coffread.c (coff_symtab_read): Fix fall-through comment.
10527 * c-exp.y (lex_one_token): Fix fall-through comment.
10528 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
10530 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
10533 2018-05-04 Tom Tromey <tom@tromey.com>
10536 * NEWS: Mention gdb.execute change.
10537 * gdbcmd.h (execute_control_command): Don't declare.
10538 * python/python.c (execute_gdb_command): Use read_command_lines_1,
10539 execute_control_commands, execute_control_commands_to_string.
10540 * cli/cli-script.h (execute_control_commands)
10541 (execute_control_commands_to_string): Declare.
10542 (execute_control_command): Add from_tty parameter.
10543 * cli/cli-script.c (execute_control_commands)
10544 (execute_control_commands_to_string): New functions.
10545 (execute_user_command): Use execute_control_commands.
10546 (execute_control_command_1): Add "from_tty" parameter. Update.
10547 (execute_control_command): Likewise.
10549 2018-05-04 Tom Tromey <tom@tromey.com>
10552 * NEWS: Mention that breakpoint commands are writable.
10553 * python/py-breakpoint.c (bppy_set_commands): New function.
10554 (breakpoint_object_getset) <"commands">: Use it.
10556 2018-05-04 Tom Tromey <tom@tromey.com>
10558 * tracepoint.c (actions_command): Update.
10559 * mi/mi-cmd-break.c (mi_command_line_array)
10560 (mi_command_line_array_cnt, mi_command_line_array_ptr)
10561 (mi_read_next_line): Remove.
10562 (mi_cmd_break_commands): Update.
10563 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
10565 * cli/cli-script.c (get_command_line): Update.
10566 (process_next_line): Use function_view. Constify.
10567 (recurse_read_control_structure, read_command_lines)
10568 (read_command_lines_1): Change argument types to function_view.
10569 (do_define_command, document_command): Update.
10570 * breakpoint.h (check_tracepoint_command): Don't declare.
10571 * breakpoint.c (check_tracepoint_command): Remove.
10572 (commands_command_1, create_tracepoint_from_upload): Update.
10574 2018-05-04 Tom Tromey <tom@tromey.com>
10577 * cli/cli-script.h (enum command_control_type) <define_control>:
10579 * cli/cli-script.c (multi_line_command_p): Handle define_control.
10580 (build_command_line, execute_control_command_1)
10581 (process_next_line): Likewise.
10582 (do_define_command): New function, extracted from define_command.
10583 (define_command): Use it.
10585 2018-05-04 Tom Tromey <tom@tromey.com>
10587 * tracepoint.c (actions_command): Update.
10588 * cli/cli-script.h (read_command_lines): Update.
10589 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
10590 (MAX_TMPBUF): Remove define.
10591 (define_command): Use string_printf.
10592 (document_command): Likewise.
10593 * breakpoint.c (commands_command_1): Update.
10595 2018-05-04 Tom Tromey <tom@tromey.com>
10597 * top.c (execute_command): Update.
10598 * cli/cli-script.h (print_command_lines): Now varargs.
10599 * cli/cli-script.c (print_command_lines): Now varargs.
10600 (execute_control_command_1) <case while_control, case if_control>:
10603 2018-05-04 Tom Tromey <tom@tromey.com>
10605 * tracepoint.c (all_tracepoint_actions): Rename from
10606 all_tracepoint_actions_and_cleanup. Change return type.
10607 (actions_command, encode_actions_1, encode_actions)
10608 (trace_dump_actions, tdump_command): Update.
10609 * remote.c (remote_download_command_source): Update.
10610 * python/python.c (gdbpy_eval_from_control_command)
10611 (python_command, python_interactive_command): Update.
10612 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10613 * guile/guile.c (guile_command)
10614 (gdbscm_eval_from_control_command, guile_command): Update.
10615 * compile/compile.c (compile_code_command)
10616 (compile_print_command, compile_to_object): Update.
10617 * cli/cli-script.h (struct command_lines_deleter): New.
10618 (counted_command_line): New typedef.
10619 (struct command_line): Add constructor, destructor.
10620 <body_list>: Remove.
10621 <body_list_0, body_list_1>: New members.
10622 (command_line_up): Remove typedef.
10623 (read_command_lines, read_command_lines_1, get_command_line):
10625 (copy_command_lines): Don't declare.
10626 * cli/cli-script.c (build_command_line): Use "new".
10627 (get_command_line): Return counted_command_line.
10628 (print_command_lines, execute_user_command)
10629 (execute_control_command_1, while_command, if_command): Update.
10630 (realloc_body_list): Remove.
10631 (process_next_line, recurse_read_control_structure): Update.
10632 (read_command_lines, read_command_lines_1): Return counted_command_line.
10633 (free_command_lines): Use "delete".
10634 (copy_command_lines): Remove.
10635 (define_command, document_command, show_user_1): Update.
10636 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
10637 a counted_command_line.
10638 * breakpoint.h (counted_command_line): Remove typedef.
10639 (breakpoint_set_commands): Update.
10640 * breakpoint.c (check_no_tracepoint_commands)
10641 (validate_commands_for_breakpoint): Update.
10642 (breakpoint_set_commands): Change commands to be a
10643 counted_command_line.
10644 (commands_command_1, update_dprintf_command_list)
10645 (create_tracepoint_from_upload): Update.
10647 2018-05-04 Tom Tromey <tom@tromey.com>
10649 * cli/cli-decode.h (cmd_list_element): New constructor.
10650 (~cmd_list_element): New destructor.
10651 (struct cmd_list_element): Add initializers.
10652 * cli/cli-decode.c (do_add_cmd): Use "new".
10653 (delete_cmd): Use "delete".
10655 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
10656 Pedro Alves <palves@redhat.com>
10658 PR breakpoints/19806 and support for PR external/20207.
10659 * NEWS: Mention Aarch64 watchpoint improvements.
10660 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
10661 watchpoints and PR external/20207 watchpoints.
10662 * nat/aarch64-linux-hw-point.c
10663 (kernel_supports_any_contiguous_range): New.
10664 (aarch64_watchpoint_offset): New.
10665 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
10666 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
10667 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
10668 (aarch64_align_watchpoint): New parameters aligned_offset_p and
10669 next_addr_orig_p. Support PR external/20207 watchpoints.
10670 (aarch64_downgrade_regs): New.
10671 (aarch64_dr_state_insert_one_point): New parameters offset and
10673 (aarch64_dr_state_remove_one_point): Likewise.
10674 (aarch64_handle_breakpoint): Update caller.
10675 (aarch64_handle_aligned_watchpoint): Likewise.
10676 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
10678 (aarch64_linux_set_debug_regs): Remove const from state. Call
10679 aarch64_downgrade_regs.
10680 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
10681 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
10682 (DR_CONTROL_MASK): ... this.
10683 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
10684 (unsigned int aarch64_watchpoint_offset): New prototype.
10685 (aarch64_linux_set_debug_regs): Remove const from state.
10686 * utils.c (align_up, align_down): Move to ...
10687 * common/common-utils.c (align_up, align_down): ... here.
10688 * utils.h (align_up, align_down): Move to ...
10689 * common/common-utils.h (align_up, align_down): ... here.
10691 2018-05-04 Joel Brobecker <brobecker@adacore.com>
10693 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
10694 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
10695 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
10696 Re-implement to match the ABI as summarized in GCC's
10697 gcc/config/sparc/sparc.c. All callers updated.
10698 (sparc32_store_arguments): Remove assertion.
10700 2018-05-04 Tom Tromey <tom@tromey.com>
10702 * printcmd.c: Don't include tui.h.
10703 (decode_format): Use skip_spaces.
10705 2018-05-04 Tom Tromey <tom@tromey.com>
10708 * printcmd.c (last_count): New global.
10709 (x_command): Use saved count when repeating.
10711 2018-05-04 Tom Tromey <tom@tromey.com>
10713 * nto-procfs.c (do_closedir_cleanup): Remove.
10714 (procfs_pidlist): Use gdb_dir_up.
10715 * procfs.c (do_closedir_cleanup): Remove.
10716 (proc_update_threads): Use gdb_dir_up.
10717 * common/filestuff.h (struct gdb_dir_deleter): New.
10718 (gdb_dir_up): New typedef.
10720 2018-05-04 Tom Tromey <tom@tromey.com>
10722 * ada-lang.c (print_mention_exception): Use std::string.
10724 2018-05-04 Tom Tromey <tom@tromey.com>
10726 * ada-lang.c (create_excep_cond_exprs): Update.
10727 (ada_exception_catchpoint_cond_string): Use std::string.
10729 2018-05-04 Tom Tromey <tom@tromey.com>
10731 * ada-lang.c (xget_renaming_scope): Return std::string.
10732 (old_renaming_is_invisible): Update.
10734 2018-05-04 Tom Tromey <tom@tromey.com>
10736 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
10737 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
10739 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
10741 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
10743 2018-05-04 Tom Tromey <tom@tromey.com>
10745 * remote.c (remote_query_supported_append): Change type.
10746 (remote_check_symbols): Update.
10748 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
10751 * configure.ac: Prepend libpython.
10752 * python/python-config.py: Likewise.
10753 * configure: Regenerate.
10755 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
10757 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
10759 2018-05-03 Pedro Alves <palves@redhat.com>
10762 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
10763 override. Write 'true' instead of '1'.
10764 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
10767 2018-05-02 Pedro Alves <palves@redhat.com>
10769 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
10770 add_inf_child_target.
10771 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
10772 add_inf_child_target.
10773 * aix-thread.c (aix_thread_target_info): New.
10774 (aix_thread_target) <shortname, longname, doc>: Delete.
10776 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
10777 add_inf_child_target.
10778 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
10779 add_inf_child_target.
10780 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
10781 add_inf_child_target.
10782 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
10783 add_inf_child_target.
10784 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
10785 add_inf_child_target.
10786 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
10787 add_inf_child_target.
10788 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
10789 add_inf_child_target.
10790 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
10791 add_inf_child_target.
10792 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
10793 add_inf_child_target.
10794 * bfd-target.c (target_bfd_target_info): New.
10795 (target_bfd) <shortname, longname, doc>: Delete.
10797 * bsd-kvm.c (bsd_kvm_target_info): New.
10798 (bsd_kvm_target) <shortname, longname, doc>: Delete.
10800 (bsd_kvm_target::open): Rename to ...
10801 (bsd_kvm_target_open): ... this. Adjust.
10802 * bsd-uthread.c (bsd_uthread_target_info): New.
10803 (bsd_uthread_target) <shortname, longname, doc>: Delete.
10805 * corefile.c (core_file_command): Adjust.
10806 * corelow.c (core_target_info): New.
10807 (core_target) <shortname, longname, doc>: Delete.
10809 (core_target::open): Rename to ...
10810 (core_target_open): ... this. Adjust.
10811 * ctf.c (ctf_target_info): New.
10812 (ctf_target) <shortname, longname, doc>: Delete.
10814 (ctf_target::open): Rename to ...
10815 (ctf_target_open): ... this.
10816 (_initialize_ctf): Adjust.
10817 * exec.c (exec_target_info): New.
10818 (exec_target) <shortname, longname, doc>: Delete.
10820 (exec_target::open): Rename to ...
10821 (exec_target_open): ... this.
10822 * gdbcore.h (core_target_open): Declare.
10823 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
10824 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
10825 add_inf_child_target.
10826 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
10827 add_inf_child_target.
10828 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
10829 add_inf_child_target.
10830 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
10831 add_inf_child_target.
10832 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
10833 add_inf_child_target.
10834 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
10835 add_inf_child_target.
10836 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
10837 add_inf_child_target.
10838 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
10839 add_inf_child_target.
10840 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
10841 add_inf_child_target.
10842 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
10843 add_inf_child_target.
10844 * inf-child.c (inf_child_target_info): New.
10845 (inf_child_target::info): New.
10846 (inf_child_open_target): Remove 'target' parameter. Use
10847 get_native_target instead.
10848 (inf_child_target::open): Delete.
10849 (add_inf_child_target): New.
10850 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
10853 (add_inf_child_target): Declare.
10854 (inf_child_open_target): Declare.
10855 * linux-thread-db.c (thread_db_target_info): New.
10856 (thread_db_target) <shortname, longname, doc>: Delete.
10858 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
10859 add_inf_child_target.
10860 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
10861 add_inf_child_target.
10862 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
10863 add_inf_child_target.
10864 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
10865 add_inf_child_target.
10866 * make-target-delegates (print_class): Adjust.
10867 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
10868 add_inf_child_target.
10869 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
10870 add_inf_child_target.
10871 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
10872 add_inf_child_target.
10873 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
10874 add_inf_child_target.
10875 * nto-procfs.c (nto_native_target_info): New.
10876 (nto_procfs_target_native) <shortname, longname, doc>:
10879 (nto_procfs_target_info): New.
10880 (nto_procfs_target_procfs) <shortname, longname, doc>:
10883 (init_procfs_targets): Adjust.
10884 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
10885 add_inf_child_target.
10886 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
10887 add_inf_child_target.
10888 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
10889 add_inf_child_target.
10890 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
10891 add_inf_child_target.
10892 * ravenscar-thread.c (ravenscar_target_info): New.
10893 (ravenscar_thread_target) <shortname, longname, doc>:
10896 * record-btrace.c (record_btrace_target_info):
10897 (record_btrace_target) <shortname, longname, doc>: Delete.
10899 (record_btrace_target::open): Rename to ...
10900 (record_btrace_target_open): ... this. Adjust.
10901 * record-full.c (record_longname, record_doc): New.
10902 (record_full_base_target) <shortname, longname, doc>: Delete.
10904 (record_full_target_info): New.
10905 (record_full_target): <shortname>: Delete.
10907 (record_full_core_open_1, record_full_open_1): Update comments.
10908 (record_full_base_target::open): Rename to ...
10909 (record_full_open): ... this.
10910 (cmd_record_full_restore): Update.
10911 (_initialize_record_full): Update.
10912 * remote-sim.c (remote_sim_target_info): New.
10913 (gdbsim_target) <shortname, longname, doc>: Delete.
10915 (gdbsim_target::open): Rename to ...
10916 (gdbsim_target_open): ... this.
10917 (_initialize_remote_sim): Adjust.
10918 * remote.c (remote_doc): New.
10919 (remote_target_info): New.
10920 (remote_target) <shortname, longname, doc>: Delete.
10922 (extended_remote_target_info): New.
10923 (extended_remote_target) <shortname, longname, doc>: Delete.
10925 (remote_target::open_1): Make static. Adjust.
10926 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
10927 * s390-linux-nat.c (_initialize_s390_nat): Use
10928 add_inf_child_target.
10929 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
10930 add_inf_child_target.
10931 * sol-thread.c (thread_db_target_info): New.
10932 (sol_thread_target) <shortname, longname, doc>: Delete.
10934 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
10935 add_inf_child_target.
10936 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
10937 add_inf_child_target.
10938 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
10939 add_inf_child_target.
10940 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
10941 add_inf_child_target.
10942 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
10943 add_inf_child_target.
10944 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
10945 add_inf_child_target.
10946 * spu-linux-nat.c (_initialize_spu_nat): Use
10947 add_inf_child_target.
10948 * spu-multiarch.c (spu_multiarch_target_info): New.
10949 (spu_multiarch_target) <shortname, longname, doc>: Delete.
10951 * target-delegates.c: Regenerate.
10952 * target.c: Include <unordered_map>.
10953 (target_ops_p): Delete.
10954 (DEF_VEC_P(target_ops_p)): Delete.
10955 (target_factories): New.
10956 (test_target_info): New.
10957 (test_target_ops::info): New.
10958 (open_target): Adjust to use target_factories.
10959 (add_target_with_completer): Rename to ...
10960 (add_target): ... this. Change prototype. Register target_info
10961 and open callback in target_factories. Register target_info in
10962 command context instead of target_ops.
10963 (add_target): Delete old implementation.
10964 (add_deprecated_target_alias): Change prototype. Adjust.
10965 (the_native_target): New.
10966 (set_native_target, get_native_target): New.
10967 (find_default_run_target): Use the_native_target.
10968 (find_attach_target, find_run_target): Simplify.
10969 (target_ops::open): Delete.
10970 (dummy_target_info): New.
10971 (dummy_target::shortname, dummy_target::longname)
10972 (dummy_target::doc): Delete.
10973 (dummy_target::info): New.
10974 (debug_target::shortname, debug_target::longname)
10975 (debug_target::doc): Delete.
10976 (debug_target::info): New.
10977 * target.h (struct target_info): New.
10978 (target_ops::~target_ops): Add comment.
10979 (target_ops::info): New.
10980 (target_ops::shortname, target_ops::longname, target_ops::doc): No
10981 longer virtual. Implement in terms of target_info.
10982 (set_native_target, get_native_target): Declare.
10983 (target_open_ftype): New.
10984 (add_target, add_target_with_completer)
10985 (add_deprecated_target_alias): Change prototype.
10986 (test_target) <shortname, longname, doc>: Delete.
10988 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
10989 add_inf_child_target.
10990 * tracefile-tfile.c (tfile_target_info): New.
10991 (tfile_target) <shortname, longname, doc>: Delete.
10993 (tfile_target::open): Rename to ...
10994 (tfile_target_open): ... this.
10995 (_initialize_tracefile_tfile): Adjust.
10996 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
10997 add_inf_child_target.
10998 * windows-nat.c (_initialize_windows_nat): Use
10999 add_inf_child_target.
11000 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
11001 add_inf_child_target.
11003 2018-05-02 Pedro Alves <palves@redhat.com>
11005 * linux-nat.h (linux_nat_target) <low_new_thread,
11006 low_delete_thread, low_new_fork, low_forget_process,
11007 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
11008 New virtual methods.
11009 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
11010 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
11011 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
11012 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
11013 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
11015 * linux-fork.c (delete_fork): Adjust to call low method.
11016 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
11017 (linux_nat_new_fork, linux_nat_forget_process_hook)
11018 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
11019 (linux_nat_status_is_event):
11020 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
11021 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
11022 to call low method.
11023 (sigtrap_is_event): Rename to ...
11024 (linux_nat_target::low_status_is_event): ... this.
11025 (linux_nat_set_status_is_event): Delete.
11026 (save_stop_reason, linux_nat_wait_1)
11027 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
11029 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
11030 (linux_nat_set_new_fork, linux_nat_set_forget_process)
11031 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
11032 (linux_nat_set_prepare_to_resume): Delete.
11033 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
11034 low virtual methods.
11035 * amd64-linux-nat.c: Likewise.
11036 * arm-linux-nat.c: Likewise.
11037 * i386-linux-nat.c: Likewise.
11038 * ia64-linux-nat.c: Likewise.
11039 * mips-linux-nat.c: Likewise.
11040 * ppc-linux-nat.c: Likewise.
11041 * s390-linux-nat.c: Likewise.
11042 * sparc64-linux-nat.c: Likewise.
11043 * x86-linux-nat.c: Likewise.
11044 * x86-linux-nat.h: Include "nat/x86-linux.h".
11045 (x86_linux_nat_target) <low_new_fork, low_forget_process,
11046 low_prepare_to_resume, low_new_thread, low_delete_thread>:
11049 2018-05-02 Pedro Alves <palves@redhat.com>
11051 * target.h (target_ops)
11052 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11053 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
11054 stopped_by_watchpoint, have_continuable_watchpoint,
11055 stopped_data_address, watchpoint_addr_within_range,
11056 can_accel_watchpoint_condition, can_run, thread_alive,
11057 has_all_memory, has_memory, has_stack, has_registers,
11058 has_execution, can_async_p, is_async_p, supports_non_stop,
11059 always_non_stop_p, can_execute_reverse, supports_multi_process,
11060 supports_enable_disable_tracepoint,
11061 supports_disable_randomization, supports_string_tracing,
11062 supports_evaluation_of_breakpoint_conditions,
11063 can_run_breakpoint_commands, filesystem_is_local,
11064 can_download_tracepoint, get_trace_state_variable_value,
11065 set_trace_notes, get_tib_address, use_agent, can_use_agent,
11066 record_is_replaying, record_will_replay,
11067 augmented_libraries_svr4_read>: Adjust to return bool.
11068 * aarch64-linux-nat.c: All implementations adjusted.
11069 * aix-thread.c: All implementations adjusted.
11070 * arm-linux-nat.c: All implementations adjusted.
11071 * breakpoint.c: All implementations adjusted.
11072 * bsd-kvm.c: All implementations adjusted.
11073 * bsd-uthread.c: All implementations adjusted.
11074 * corelow.c: All implementations adjusted.
11075 * ctf.c: All implementations adjusted.
11076 * darwin-nat.c: All implementations adjusted.
11077 * darwin-nat.h: All implementations adjusted.
11078 * exec.c: All implementations adjusted.
11079 * fbsd-nat.c: All implementations adjusted.
11080 * fbsd-nat.h: All implementations adjusted.
11081 * gnu-nat.c: All implementations adjusted.
11082 * gnu-nat.h: All implementations adjusted.
11083 * go32-nat.c: All implementations adjusted.
11084 * ia64-linux-nat.c: All implementations adjusted.
11085 * inf-child.c: All implementations adjusted.
11086 * inf-child.h: All implementations adjusted.
11087 * inf-ptrace.c: All implementations adjusted.
11088 * inf-ptrace.h: All implementations adjusted.
11089 * linux-nat.c: All implementations adjusted.
11090 * linux-nat.h: All implementations adjusted.
11091 * mips-linux-nat.c: All implementations adjusted.
11092 * nto-procfs.c: All implementations adjusted.
11093 * ppc-linux-nat.c: All implementations adjusted.
11094 * procfs.c: All implementations adjusted.
11095 * ravenscar-thread.c: All implementations adjusted.
11096 * record-btrace.c: All implementations adjusted.
11097 * record-full.c: All implementations adjusted.
11098 * remote-sim.c: All implementations adjusted.
11099 * remote.c: All implementations adjusted.
11100 * s390-linux-nat.c: All implementations adjusted.
11101 * sol-thread.c: All implementations adjusted.
11102 * spu-multiarch.c: All implementations adjusted.
11103 * target-delegates.c: All implementations adjusted.
11104 * target.c: All implementations adjusted.
11105 * target.h: All implementations adjusted.
11106 * tracefile-tfile.c: All implementations adjusted.
11107 * tracefile.c: All implementations adjusted.
11108 * tracefile.h: All implementations adjusted.
11109 * windows-nat.c: All implementations adjusted.
11110 * x86-linux-nat.h: All implementations adjusted.
11111 * x86-nat.h: All implementations adjusted.
11113 2018-05-02 Pedro Alves <palves@redhat.com>
11115 * make-target-delegates (scan_target_h): Don't trim lines here.
11116 Replace sequences of tabs and/or whitespace with a single
11118 (top level, parsing methods): Trim each line before processing it
11121 2018-05-02 Pedro Alves <palves@redhat.com>
11122 John Baldwin <jhb@freebsd.org>
11124 * target.h (enum strata) <debug_stratum>: New.
11125 (struct target_ops) <all delegation methods>: Replace by C++
11126 virtual methods, and drop "to_" prefix. All references updated
11128 <to_shortname, to_longname, to_doc, to_data,
11129 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
11130 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
11131 virtual methods. All references updated throughout.
11132 <can_attach, supports_terminal_ours, can_create_inferior,
11133 get_thread_control_capabilities, attach_no_wait>: New
11135 <insert_breakpoint, remove_breakpoint>: Now
11136 TARGET_DEFAULT_NORETURN methods.
11137 <info_proc>: Now returns bool.
11138 <to_magic>: Delete.
11139 (OPS_MAGIC): Delete.
11140 (current_target): Delete. All references replaced by references
11142 (target_stack): ... this. New.
11143 (target_shortname, target_longname): Adjust.
11144 (target_can_run): Now a function declaration.
11145 (default_child_has_all_memory, default_child_has_memory)
11146 (default_child_has_stack, default_child_has_registers)
11147 (default_child_has_execution): Remove target_ops parameter.
11148 (complete_target_initialization): Delete.
11149 (memory_breakpoint_target): New template class.
11150 (test_target_ops): Refactor as a C++ class with virtual methods.
11151 * make-target-delegates (NAME_PART): Tighten.
11152 (POINTER_PART, CP_SYMBOL): New.
11153 (SIMPLE_RETURN_PART): Reimplement.
11154 (VEC_RETURN_PART): Expect less.
11155 (RETURN_PART, VIRTUAL_PART): New.
11156 (METHOD): Adjust to C++ virtual methods.
11157 (scan_target_h): Remove reference to C99.
11158 (dname): Output "target_ops::" prefix.
11159 (write_function_header): Adjust to output a C++ class method.
11160 (write_declaration): New.
11161 (write_delegator): Adjust to output a C++ class method.
11162 (tdname): Output "dummy_target::" prefix.
11163 (write_tdefault, write_debugmethod): Adjust to output a C++ class
11165 (tdefault_names, debug_names): Delete.
11166 (return_types, tdefaults, styles, argtypes_array): New.
11167 (top level): All methods are delegators.
11168 (print_class): New.
11169 (top level): Print dummy_target and debug_target classes.
11170 * target-delegates.c: Regenerate.
11171 * target-debug.h (target_debug_print_enum_info_proc_what)
11172 (target_debug_print_thread_control_capabilities)
11173 (target_debug_print_thread_info_p): New.
11174 * target.c (dummy_target): Delete.
11175 (the_dummy_target, the_debug_target): New.
11176 (target_stack): Now extern.
11177 (set_targetdebug): Push/unpush debug target.
11178 (default_child_has_all_memory, default_child_has_memory)
11179 (default_child_has_stack, default_child_has_registers)
11180 (default_child_has_execution): Remove target_ops parameter.
11181 (complete_target_initialization): Delete.
11182 (add_target_with_completer): No longer call
11183 complete_target_initialization.
11184 (target_supports_terminal_ours): Use regular delegation.
11185 (update_current_target): Delete.
11186 (push_target): No longer check magic number. Don't call
11187 update_current_target.
11188 (unpush_target): Don't call update_current_target.
11189 (target_is_pushed): No longer check magic number.
11190 (target_require_runnable): Skip for all stratums over
11192 (target_ops::info_proc): New.
11193 (target_info_proc): Use find_target_at and
11194 find_default_run_target.
11195 (target_supports_disable_randomization): Use regular delegation.
11196 (target_get_osdata): Use find_target_at.
11197 (target_ops::open, target_ops::close, target_ops::can_attach)
11198 (target_ops::attach, target_ops::can_create_inferior)
11199 (target_ops::create_inferior, target_ops::can_run)
11200 (target_can_run): New.
11201 (default_fileio_target): Use regular delegation.
11202 (target_ops::fileio_open, target_ops::fileio_pwrite)
11203 (target_ops::fileio_pread, target_ops::fileio_fstat)
11204 (target_ops::fileio_close, target_ops::fileio_unlink)
11205 (target_ops::fileio_readlink): New.
11206 (target_fileio_open_1, target_fileio_unlink)
11207 (target_fileio_readlink): Always call the target method. Handle
11209 (return_zero, return_zero_has_execution): Delete.
11210 (init_dummy_target): Delete.
11211 (dummy_target::dummy_target, dummy_target::shortname)
11212 (dummy_target::longname, dummy_target::doc)
11213 (debug_target::debug_target, debug_target::shortname)
11214 (debug_target::longname, debug_target::doc): New.
11215 (target_supports_delete_record): Use regular delegation.
11216 (setup_target_debug): Delete.
11217 (maintenance_print_target_stack): Skip debug_stratum.
11218 (initialize_targets): Instantiate the_dummy_target and
11220 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
11222 (target_auxv_search, fprint_target_auxv): Adjust.
11223 (info_auxv_command): Adjust to use target_stack.
11224 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
11225 * exceptions.c (print_flush): Handle a NULL target_stack.
11226 * regcache.c (target_ops_no_register): Refactor as class with
11229 * exec.c (exec_target): New class.
11230 (exec_ops): Now an exec_target.
11231 (exec_open, exec_close_1, exec_get_section_table)
11232 (exec_xfer_partial, exec_files_info, exec_has_memory)
11233 (exec_make_note_section): Refactor as exec_target methods.
11234 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
11236 (exec_target::find_memory_regions): New.
11237 (_initialize_exec): Don't call init_exec_ops.
11238 * gdbcore.h (exec_file_clear): Delete.
11240 * corefile.c (core_target): Delete.
11241 (core_file_command): Adjust.
11242 * corelow.c (core_target): New class.
11243 (the_core_target): New.
11244 (core_close): Remove target_ops parameter.
11245 (core_close_cleanup): Adjust.
11246 (core_target::close): New.
11247 (core_open, core_detach, get_core_registers, core_files_info)
11248 (core_xfer_partial, core_thread_alive, core_read_description)
11249 (core_pid_to_str, core_thread_name, core_has_memory)
11250 (core_has_stack, core_has_registers, core_info_proc): Rework as
11251 core_target methods.
11252 (ignore, core_remove_breakpoint, init_core_ops): Delete.
11253 (_initialize_corelow): Initialize the_core_target.
11254 * gdbcore.h (core_target): Delete.
11255 (the_core_target): New.
11257 * ctf.c: (ctf_target): New class.
11258 (ctf_ops): Now a ctf_target.
11259 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
11260 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
11261 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
11263 (init_ctf_ops): Delete.
11264 (_initialize_ctf): Don't call it.
11265 * tracefile-tfile.c (tfile_target): New class.
11266 (tfile_ops): Now a tfile_target.
11267 (tfile_open, tfile_close, tfile_files_info)
11268 (tfile_get_tracepoint_status, tfile_trace_find)
11269 (tfile_fetch_registers, tfile_xfer_partial)
11270 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
11271 Refactor as tfile_target methods.
11272 (tfile_xfer_partial_features): Remove target_ops parameter.
11273 (init_tfile_ops): Delete.
11274 (_initialize_tracefile_tfile): Don't call it.
11275 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
11276 (tracefile_has_stack, tracefile_has_registers)
11277 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
11278 tracefile_target methods.
11279 (init_tracefile_ops): Delete.
11280 (tracefile_target::tracefile_target): New.
11281 * tracefile.h: Include "target.h".
11282 (tracefile_target): New class.
11283 (init_tracefile_ops): Delete.
11285 * spu-multiarch.c (spu_multiarch_target): New class.
11286 (spu_ops): Now a spu_multiarch_target.
11287 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
11288 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
11289 (spu_search_memory, spu_mourn_inferior): Refactor as
11290 spu_multiarch_target methods.
11291 (init_spu_ops): Delete.
11292 (_initialize_spu_multiarch): Remove references to init_spu_ops,
11293 complete_target_initialization.
11295 * ravenscar-thread.c (ravenscar_thread_target): New class.
11296 (ravenscar_ops): Now a ravenscar_thread_target.
11297 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
11298 (ravenscar_thread_alive, ravenscar_pid_to_str)
11299 (ravenscar_fetch_registers, ravenscar_store_registers)
11300 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
11301 (ravenscar_stopped_by_hw_breakpoint)
11302 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
11303 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
11304 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
11306 (init_ravenscar_thread_ops): Delete.
11307 (_initialize_ravenscar): Remove references to
11308 init_ravenscar_thread_ops and complete_target_initialization.
11310 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
11311 (bsd_uthread_target): New class.
11312 (bsd_uthread_ops): Now a bsd_uthread_target.
11313 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
11314 (bsd_uthread_close, bsd_uthread_mourn_inferior)
11315 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
11316 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
11317 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
11318 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
11319 (bsd_uthread_target): Delete function.
11320 (_initialize_bsd_uthread): Remove reference to
11321 complete_target_initialization.
11323 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
11324 (target_bfd): ... this new class.
11325 (target_bfd_xfer_partial, target_bfd_get_section_table)
11326 (target_bfd_close): Refactor as target_bfd methods.
11327 (target_bfd::~target_bfd): New.
11328 (target_bfd_reopen): Adjust.
11329 (target_bfd::close): New.
11331 * record-btrace.c (record_btrace_target): New class.
11332 (record_btrace_ops): Now a record_btrace_target.
11333 (record_btrace_open, record_btrace_stop_recording)
11334 (record_btrace_disconnect, record_btrace_close)
11335 (record_btrace_async, record_btrace_info)
11336 (record_btrace_insn_history, record_btrace_insn_history_range)
11337 (record_btrace_insn_history_from, record_btrace_call_history)
11338 (record_btrace_call_history_range)
11339 (record_btrace_call_history_from, record_btrace_record_method)
11340 (record_btrace_is_replaying, record_btrace_will_replay)
11341 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
11342 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
11343 (record_btrace_store_registers, record_btrace_prepare_to_store)
11344 (record_btrace_to_get_unwinder)
11345 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
11346 (record_btrace_commit_resume, record_btrace_wait)
11347 (record_btrace_stop, record_btrace_can_execute_reverse)
11348 (record_btrace_stopped_by_sw_breakpoint)
11349 (record_btrace_supports_stopped_by_sw_breakpoint)
11350 (record_btrace_stopped_by_hw_breakpoint)
11351 (record_btrace_supports_stopped_by_hw_breakpoint)
11352 (record_btrace_update_thread_list, record_btrace_thread_alive)
11353 (record_btrace_goto_begin, record_btrace_goto_end)
11354 (record_btrace_goto, record_btrace_stop_replaying_all)
11355 (record_btrace_execution_direction)
11356 (record_btrace_prepare_to_generate_core)
11357 (record_btrace_done_generating_core): Refactor as
11358 record_btrace_target methods.
11359 (init_record_btrace_ops): Delete.
11360 (_initialize_record_btrace): Remove reference to
11361 init_record_btrace_ops.
11362 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
11363 the execution_direction global.
11364 (record_full_base_target, record_full_target)
11365 (record_full_core_target): New classes.
11366 (record_full_ops): Now a record_full_target.
11367 (record_full_core_ops): Now a record_full_core_target.
11368 (record_full_target::detach, record_full_target::disconnect)
11369 (record_full_core_target::disconnect)
11370 (record_full_target::mourn_inferior, record_full_target::kill):
11372 (record_full_open, record_full_close, record_full_async): Refactor
11373 as methods of the record_full_base_target class.
11374 (record_full_resume, record_full_commit_resume): Refactor
11375 as methods of the record_full_target class.
11376 (record_full_wait, record_full_stopped_by_watchpoint)
11377 (record_full_stopped_data_address)
11378 (record_full_stopped_by_sw_breakpoint)
11379 (record_full_supports_stopped_by_sw_breakpoint)
11380 (record_full_stopped_by_hw_breakpoint)
11381 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
11382 methods of the record_full_base_target class.
11383 (record_full_store_registers, record_full_xfer_partial)
11384 (record_full_insert_breakpoint, record_full_remove_breakpoint):
11385 Refactor as methods of the record_full_target class.
11386 (record_full_can_execute_reverse, record_full_get_bookmark)
11387 (record_full_goto_bookmark, record_full_execution_direction)
11388 (record_full_record_method, record_full_info, record_full_delete)
11389 (record_full_is_replaying, record_full_will_replay)
11390 (record_full_goto_begin, record_full_goto_end, record_full_goto)
11391 (record_full_stop_replaying): Refactor as methods of the
11392 record_full_base_target class.
11393 (record_full_core_resume, record_full_core_kill)
11394 (record_full_core_fetch_registers)
11395 (record_full_core_prepare_to_store)
11396 (record_full_core_store_registers, record_full_core_xfer_partial)
11397 (record_full_core_insert_breakpoint)
11398 (record_full_core_remove_breakpoint)
11399 (record_full_core_has_execution): Refactor
11400 as methods of the record_full_core_target class.
11401 (record_full_base_target::supports_delete_record): New.
11402 (init_record_full_ops): Delete.
11403 (init_record_full_core_ops): Delete.
11404 (record_full_save): Refactor as method of the
11405 record_full_base_target class.
11406 (_initialize_record_full): Remove references to
11407 init_record_full_ops and init_record_full_core_ops.
11409 * remote.c (remote_target, extended_remote_target): New classes.
11410 (remote_ops): Now a remote_target.
11411 (extended_remote_ops): Now an extended_remote_target.
11412 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
11413 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
11414 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
11415 (remote_pass_signals, remote_set_syscall_catchpoint)
11416 (remote_program_signals, )
11417 (remote_thread_always_alive): Remove target_ops parameter.
11418 (remote_thread_alive, remote_thread_name)
11419 (remote_update_thread_list, remote_threads_extra_info)
11420 (remote_static_tracepoint_marker_at)
11421 (remote_static_tracepoint_markers_by_strid)
11422 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
11423 (remote_open): Refactor as methods of remote_target.
11424 (extended_remote_open, extended_remote_detach)
11425 (extended_remote_attach, extended_remote_post_attach):
11426 (extended_remote_supports_disable_randomization)
11427 (extended_remote_create_inferior): : Refactor as method of
11428 extended_remote_target.
11429 (remote_set_permissions, remote_open_1, remote_detach)
11430 (remote_follow_fork, remote_follow_exec, remote_disconnect)
11431 (remote_resume, remote_commit_resume, remote_stop)
11432 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
11433 (remote_terminal_ours, remote_wait, remote_fetch_registers)
11434 (remote_prepare_to_store, remote_store_registers)
11435 (remote_flash_erase, remote_flash_done, remote_files_info)
11436 (remote_kill, remote_mourn, remote_insert_breakpoint)
11437 (remote_remove_breakpoint, remote_insert_watchpoint)
11438 (remote_watchpoint_addr_within_range)
11439 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
11440 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
11441 (remote_supports_stopped_by_sw_breakpoint)
11442 (remote_stopped_by_hw_breakpoint)
11443 (remote_supports_stopped_by_hw_breakpoint)
11444 (remote_stopped_by_watchpoint, remote_stopped_data_address)
11445 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
11446 (remote_verify_memory): Refactor as methods of remote_target.
11447 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
11449 (remote_xfer_partial, remote_get_memory_xfer_limit)
11450 (remote_search_memory, remote_rcmd, remote_memory_map)
11451 (remote_pid_to_str, remote_get_thread_local_address)
11452 (remote_get_tib_address, remote_read_description): Refactor as
11453 methods of remote_target.
11454 (remote_target::fileio_open, remote_target::fileio_pwrite)
11455 (remote_target::fileio_pread, remote_target::fileio_close): New.
11456 (remote_hostio_readlink, remote_hostio_fstat)
11457 (remote_filesystem_is_local, remote_can_execute_reverse)
11458 (remote_supports_non_stop, remote_supports_disable_randomization)
11459 (remote_supports_multi_process, remote_supports_cond_breakpoints)
11460 (remote_supports_enable_disable_tracepoint)
11461 (remote_supports_string_tracing)
11462 (remote_can_run_breakpoint_commands, remote_trace_init)
11463 (remote_download_tracepoint, remote_can_download_tracepoint)
11464 (remote_download_trace_state_variable, remote_enable_tracepoint)
11465 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
11466 (remote_trace_start, remote_get_trace_status)
11467 (remote_get_tracepoint_status, remote_trace_stop)
11468 (remote_trace_find, remote_get_trace_state_variable_value)
11469 (remote_save_trace_data, remote_get_raw_trace_data)
11470 (remote_set_disconnected_tracing, remote_core_of_thread)
11471 (remote_set_circular_trace_buffer, remote_traceframe_info)
11472 (remote_get_min_fast_tracepoint_insn_len)
11473 (remote_set_trace_buffer_size, remote_set_trace_notes)
11474 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
11475 (remote_disable_btrace, remote_teardown_btrace)
11476 (remote_read_btrace, remote_btrace_conf)
11477 (remote_augmented_libraries_svr4_read, remote_load)
11478 (remote_pid_to_exec_file, remote_can_do_single_step)
11479 (remote_execution_direction, remote_thread_handle_to_thread_info):
11480 Refactor as methods of remote_target.
11481 (init_remote_ops, init_extended_remote_ops): Delete.
11482 (remote_can_async_p, remote_is_async_p, remote_async)
11483 (remote_thread_events, remote_upload_tracepoints)
11484 (remote_upload_trace_state_variables): Refactor as methods of
11486 (_initialize_remote): Remove references to init_remote_ops and
11487 init_extended_remote_ops.
11489 * remote-sim.c (gdbsim_target): New class.
11490 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
11491 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
11492 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
11493 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
11494 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
11495 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
11496 Refactor as methods of gdbsim_target.
11497 (gdbsim_ops): Now a gdbsim_target.
11498 (init_gdbsim_ops): Delete.
11499 (gdbsim_cntrl_c): Adjust.
11500 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
11502 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
11503 (the_amd64_linux_nat_target): New.
11504 (amd64_linux_fetch_inferior_registers)
11505 (amd64_linux_store_inferior_registers): Refactor as methods of
11506 amd64_linux_nat_target.
11507 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
11508 * i386-linux-nat.c: Don't include "linux-nat.h".
11509 (i386_linux_nat_target): New class.
11510 (the_i386_linux_nat_target): New.
11511 (i386_linux_fetch_inferior_registers)
11512 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
11513 as methods of i386_linux_nat_target.
11514 (_initialize_i386_linux_nat): Adjust. Set linux_target.
11515 * inf-child.c (inf_child_ops): Delete.
11516 (inf_child_fetch_inferior_registers)
11517 (inf_child_store_inferior_registers): Delete.
11518 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
11519 methods of inf_child_target.
11520 (inf_child_target::supports_terminal_ours)
11521 (inf_child_target::terminal_init)
11522 (inf_child_target::terminal_inferior)
11523 (inf_child_target::terminal_ours_for_output)
11524 (inf_child_target::terminal_ours, inf_child_target::interrupt)
11525 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
11527 (inf_child_open, inf_child_disconnect, inf_child_close)
11528 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
11529 (inf_child_post_startup_inferior, inf_child_can_run)
11530 (inf_child_pid_to_exec_file): Refactor as methods of
11532 (inf_child_follow_fork): Delete.
11533 (inf_child_target::can_create_inferior)
11534 (inf_child_target::can_attach): New.
11535 (inf_child_target::has_all_memory, inf_child_target::has_memory)
11536 (inf_child_target::has_stack, inf_child_target::has_registers)
11537 (inf_child_target::has_execution): New.
11538 (inf_child_fileio_open, inf_child_fileio_pwrite)
11539 (inf_child_fileio_pread, inf_child_fileio_fstat)
11540 (inf_child_fileio_close, inf_child_fileio_unlink)
11541 (inf_child_fileio_readlink, inf_child_use_agent)
11542 (inf_child_can_use_agent): Refactor as methods of
11544 (return_zero, inf_child_target): Delete.
11545 (inf_child_target::inf_child_target): New.
11546 * inf-child.h: Include "target.h".
11547 (inf_child_target): Delete function prototype.
11548 (inf_child_target): New class.
11549 (inf_child_open_target, inf_child_mourn_inferior)
11550 (inf_child_maybe_unpush_target): Delete.
11551 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
11552 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
11553 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
11554 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
11555 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
11556 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
11557 (inf_ptrace_wait, inf_ptrace_xfer_partial)
11558 (inf_ptrace_thread_alive, inf_ptrace_files_info)
11559 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
11560 methods of inf_ptrace_target.
11561 (inf_ptrace_target): Delete function.
11562 * inf-ptrace.h: Include "inf-child.h".
11563 (inf_ptrace_target): Delete function declaration.
11564 (inf_ptrace_target): New class.
11565 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
11566 * linux-nat.c (linux_target): New.
11567 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
11568 (linux_nat_target::~linux_nat_target): New.
11569 (linux_child_post_attach, linux_child_post_startup_inferior)
11570 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
11571 (linux_child_remove_fork_catchpoint)
11572 (linux_child_insert_vfork_catchpoint)
11573 (linux_child_remove_vfork_catchpoint)
11574 (linux_child_insert_exec_catchpoint)
11575 (linux_child_remove_exec_catchpoint)
11576 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
11577 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
11578 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
11579 (linux_nat_stopped_data_address)
11580 (linux_nat_stopped_by_sw_breakpoint)
11581 (linux_nat_supports_stopped_by_sw_breakpoint)
11582 (linux_nat_stopped_by_hw_breakpoint)
11583 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
11584 (linux_nat_kill, linux_nat_mourn_inferior)
11585 (linux_nat_xfer_partial, linux_nat_thread_alive)
11586 (linux_nat_update_thread_list, linux_nat_pid_to_str)
11587 (linux_nat_thread_name, linux_child_pid_to_exec_file)
11588 (linux_child_static_tracepoint_markers_by_strid)
11589 (linux_nat_is_async_p, linux_nat_can_async_p)
11590 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
11591 (linux_nat_supports_multi_process)
11592 (linux_nat_supports_disable_randomization, linux_nat_async)
11593 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
11594 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
11595 (linux_nat_fileio_open, linux_nat_fileio_readlink)
11596 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
11597 methods of linux_nat_target.
11598 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
11599 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
11601 (check_stopped_by_watchpoint): Adjust.
11602 (linux_xfer_partial): Delete.
11603 (linux_target_install_ops, linux_target, linux_nat_add_target):
11605 (linux_nat_target::linux_nat_target): New.
11606 * linux-nat.h: Include "inf-ptrace.h".
11607 (linux_nat_target): New.
11608 (linux_target, linux_target_install_ops, linux_nat_add_target):
11609 Delete function declarations.
11610 (linux_target): Declare global.
11611 * linux-thread-db.c (thread_db_target): New.
11612 (thread_db_target::thread_db_target): New.
11613 (thread_db_ops): Delete.
11614 (the_thread_db_target): New.
11615 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
11616 (thread_db_update_thread_list, thread_db_pid_to_str)
11617 (thread_db_extra_thread_info)
11618 (thread_db_thread_handle_to_thread_info)
11619 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
11620 (thread_db_resume): Refactor as methods of thread_db_target.
11621 (init_thread_db_ops): Delete.
11622 (_initialize_thread_db): Remove reference to init_thread_db_ops.
11623 * x86-linux-nat.c: Don't include "linux-nat.h".
11624 (super_post_startup_inferior): Delete.
11625 (x86_linux_nat_target::~x86_linux_nat_target): New.
11626 (x86_linux_child_post_startup_inferior)
11627 (x86_linux_read_description, x86_linux_enable_btrace)
11628 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
11629 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
11630 methods of x86_linux_nat_target.
11631 (x86_linux_create_target): Delete. Bits folded ...
11632 (x86_linux_add_target): ... here. Now takes a linux_nat_target
11634 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
11635 (x86_linux_nat_target): New class.
11636 (x86_linux_create_target): Delete.
11637 (x86_linux_add_target): Now takes a linux_nat_target pointer.
11638 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
11639 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
11640 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
11641 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
11642 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
11644 (x86_use_watchpoints): Delete.
11645 * x86-nat.h: Include "breakpoint.h" and "target.h".
11646 (x86_use_watchpoints): Delete.
11647 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
11648 (x86_stopped_by_watchpoint, x86_stopped_data_address)
11649 (x86_insert_watchpoint, x86_remove_watchpoint)
11650 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
11651 (x86_stopped_by_hw_breakpoint): New declarations.
11652 (x86_nat_target): New template class.
11654 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
11655 (the_ppc_linux_nat_target): New.
11656 (ppc_linux_fetch_inferior_registers)
11657 (ppc_linux_can_use_hw_breakpoint)
11658 (ppc_linux_region_ok_for_hw_watchpoint)
11659 (ppc_linux_ranged_break_num_registers)
11660 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
11661 (ppc_linux_insert_mask_watchpoint)
11662 (ppc_linux_remove_mask_watchpoint)
11663 (ppc_linux_can_accel_watchpoint_condition)
11664 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
11665 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
11666 (ppc_linux_watchpoint_addr_within_range)
11667 (ppc_linux_masked_watch_num_registers)
11668 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
11669 (ppc_linux_read_description): Refactor as methods of
11670 ppc_linux_nat_target.
11671 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
11673 * procfs.c (procfs_xfer_partial): Delete forward declaration.
11674 (procfs_target): New class.
11675 (the_procfs_target): New.
11676 (procfs_target): Delete function.
11677 (procfs_auxv_parse, procfs_attach, procfs_detach)
11678 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
11679 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
11680 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
11681 (procfs_create_inferior, procfs_update_thread_list)
11682 (procfs_thread_alive, procfs_pid_to_str)
11683 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
11684 (procfs_stopped_data_address, procfs_insert_watchpoint)
11685 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
11686 (proc_find_memory_regions, procfs_info_proc)
11687 (procfs_make_note_section): Refactor as methods of procfs_target.
11688 (_initialize_procfs): Adjust.
11689 * sol-thread.c (sol_thread_target): New class.
11690 (sol_thread_ops): Now a sol_thread_target.
11691 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
11692 (sol_thread_fetch_registers, sol_thread_store_registers)
11693 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
11694 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
11695 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
11696 (init_sol_thread_ops): Delete.
11697 (_initialize_sol_thread): Adjust. Remove references to
11698 init_sol_thread_ops and complete_target_initialization.
11700 * windows-nat.c (windows_nat_target): New class.
11701 (windows_fetch_inferior_registers)
11702 (windows_store_inferior_registers, windows_resume, windows_wait)
11703 (windows_attach, windows_detach, windows_pid_to_exec_file)
11704 (windows_files_info, windows_create_inferior)
11705 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
11706 (windows_close, windows_pid_to_str, windows_xfer_partial)
11707 (windows_get_tib_address, windows_get_ada_task_ptid)
11708 (windows_thread_name, windows_thread_alive): Refactor as
11709 windows_nat_target methods.
11710 (do_initial_windows_stuff): Adjust.
11711 (windows_target): Delete function.
11712 (_initialize_windows_nat): Adjust.
11714 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
11715 (darwin_mourn_inferior, darwin_kill_inferior)
11716 (darwin_create_inferior, darwin_attach, darwin_detach)
11717 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
11718 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
11719 (darwin_supports_multi_process): Refactor as darwin_nat_target
11721 (darwin_resume_to, darwin_files_info): Delete.
11722 (_initialize_darwin_inferior): Rename to ...
11723 (_initialize_darwin_nat): ... this. Adjust to C++ification.
11724 * darwin-nat.h: Include "inf-child.h".
11725 (darwin_nat_target): New class.
11726 (darwin_complete_target): Delete.
11727 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
11728 (darwin_target): New.
11729 (i386_darwin_fetch_inferior_registers)
11730 (i386_darwin_store_inferior_registers): Refactor as methods of
11732 (darwin_complete_target): Delete, with ...
11733 (_initialize_i386_darwin_nat): ... bits factored out here.
11735 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
11736 (the_alpha_linux_nat_target): New.
11737 (alpha_linux_register_u_offset): Refactor as
11738 alpha_linux_nat_target method.
11739 (_initialize_alpha_linux_nat): Adjust.
11740 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
11741 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11742 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
11743 methods of linux_nat_trad_target.
11744 (linux_trad_target): Delete.
11745 * linux-nat-trad.h (linux_trad_target): Delete function.
11746 (linux_nat_trad_target): New class.
11747 * mips-linux-nat.c (mips_linux_nat_target): New class.
11748 (super_fetch_registers, super_store_registers, super_close):
11750 (the_mips_linux_nat_target): New.
11751 (mips64_linux_regsets_fetch_registers)
11752 (mips64_linux_regsets_store_registers)
11753 (mips64_linux_fetch_registers, mips64_linux_store_registers)
11754 (mips_linux_register_u_offset, mips_linux_read_description)
11755 (mips_linux_can_use_hw_breakpoint)
11756 (mips_linux_stopped_by_watchpoint)
11757 (mips_linux_stopped_data_address)
11758 (mips_linux_region_ok_for_hw_watchpoint)
11759 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
11760 (mips_linux_close): Refactor as methods of mips_linux_nat.
11761 (_initialize_mips_linux_nat): Adjust to C++ification.
11763 * aix-thread.c (aix_thread_target): New class.
11764 (aix_thread_ops): Now an aix_thread_target.
11765 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
11766 (aix_thread_fetch_registers, aix_thread_store_registers)
11767 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
11768 (aix_thread_thread_alive, aix_thread_pid_to_str)
11769 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
11770 Refactor as methods of aix_thread_target.
11771 (init_aix_thread_ops): Delete.
11772 (_initialize_aix_thread): Remove references to init_aix_thread_ops
11773 and complete_target_initialization.
11774 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
11775 (rs6000_nat_target): New class.
11776 (the_rs6000_nat_target): New.
11777 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
11778 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
11779 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
11780 (super_create_inferior): Delete.
11781 (_initialize_rs6000_nat): Adjust to C++ification.
11783 * arm-linux-nat.c (arm_linux_nat_target): New class.
11784 (the_arm_linux_nat_target): New.
11785 (arm_linux_fetch_inferior_registers)
11786 (arm_linux_store_inferior_registers, arm_linux_read_description)
11787 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
11788 (arm_linux_remove_hw_breakpoint)
11789 (arm_linux_region_ok_for_hw_watchpoint)
11790 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
11791 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
11792 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
11793 arm_linux_nat_target.
11794 (_initialize_arm_linux_nat): Adjust to C++ification.
11796 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
11797 (the_aarch64_linux_nat_target): New.
11798 (aarch64_linux_fetch_inferior_registers)
11799 (aarch64_linux_store_inferior_registers)
11800 (aarch64_linux_child_post_startup_inferior)
11801 (aarch64_linux_read_description)
11802 (aarch64_linux_can_use_hw_breakpoint)
11803 (aarch64_linux_insert_hw_breakpoint)
11804 (aarch64_linux_remove_hw_breakpoint)
11805 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
11806 (aarch64_linux_region_ok_for_hw_watchpoint)
11807 (aarch64_linux_stopped_data_address)
11808 (aarch64_linux_stopped_by_watchpoint)
11809 (aarch64_linux_watchpoint_addr_within_range)
11810 (aarch64_linux_can_do_single_step): Refactor as methods of
11811 aarch64_linux_nat_target.
11812 (super_post_startup_inferior): Delete.
11813 (_initialize_aarch64_linux_nat): Adjust to C++ification.
11815 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
11816 (the_hppa_linux_nat_target): New.
11817 (hppa_linux_fetch_inferior_registers)
11818 (hppa_linux_store_inferior_registers): Refactor as methods of
11819 hppa_linux_nat_target.
11820 (_initialize_hppa_linux_nat): Adjust to C++ification.
11822 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
11823 (the_ia64_linux_nat_target): New.
11824 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
11825 (ia64_linux_stopped_data_address)
11826 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
11827 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
11828 ia64_linux_nat_target methods.
11829 (super_xfer_partial): Delete.
11830 (_initialize_ia64_linux_nat): Adjust to C++ification.
11832 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
11833 (the_m32r_linux_nat_target): New.
11834 (m32r_linux_fetch_inferior_registers)
11835 (m32r_linux_store_inferior_registers): Refactor as
11836 m32r_linux_nat_target methods.
11837 (_initialize_m32r_linux_nat): Adjust to C++ification.
11839 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
11840 (the_m68k_linux_nat_target): New.
11841 (m68k_linux_fetch_inferior_registers)
11842 (m68k_linux_store_inferior_registers): Refactor as
11843 m68k_linux_nat_target methods.
11844 (_initialize_m68k_linux_nat): Adjust to C++ification.
11846 * s390-linux-nat.c (s390_linux_nat_target): New class.
11847 (the_s390_linux_nat_target): New.
11848 (s390_linux_fetch_inferior_registers)
11849 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
11850 (s390_insert_watchpoint, s390_remove_watchpoint)
11851 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
11852 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
11853 (s390_auxv_parse, s390_read_description): Refactor as methods of
11854 s390_linux_nat_target.
11855 (_initialize_s390_nat): Adjust to C++ification.
11857 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
11858 (the_sparc_linux_nat_target): New.
11859 (_initialize_sparc_linux_nat): Adjust to C++ification.
11860 * sparc-nat.c (sparc_fetch_inferior_registers)
11861 (sparc_store_inferior_registers): Remove target_ops parameter.
11862 * sparc-nat.h (sparc_fetch_inferior_registers)
11863 (sparc_store_inferior_registers): Remove target_ops parameter.
11864 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
11865 (the_sparc64_linux_nat_target): New.
11866 (_initialize_sparc64_linux_nat): Adjust to C++ification.
11868 * spu-linux-nat.c (spu_linux_nat_target): New class.
11869 (the_spu_linux_nat_target): New.
11870 (spu_child_post_startup_inferior, spu_child_post_attach)
11871 (spu_child_wait, spu_fetch_inferior_registers)
11872 (spu_store_inferior_registers, spu_xfer_partial)
11873 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
11875 (_initialize_spu_nat): Adjust to C++ification.
11877 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
11878 (the_tilegx_linux_nat_target): New.
11879 (fetch_inferior_registers, store_inferior_registers):
11880 Refactor as methods.
11881 (_initialize_tile_linux_nat): Adjust to C++ification.
11883 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
11884 (the_xtensa_linux_nat_target): New.
11885 (xtensa_linux_fetch_inferior_registers)
11886 (xtensa_linux_store_inferior_registers): Refactor as
11887 xtensa_linux_nat_target methods.
11888 (_initialize_xtensa_linux_nat): Adjust to C++ification.
11890 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
11891 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
11892 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
11893 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
11894 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
11895 (fbsd_stopped_by_sw_breakpoint)
11896 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
11897 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
11898 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
11899 (fbsd_post_startup_inferior, fbsd_post_attach)
11900 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
11901 (fbsd_set_syscall_catchpoint)
11902 (super_xfer_partial, super_resume, super_wait)
11903 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
11904 (fbsd_handle_debug_trap): Remove target_ops parameter.
11905 (fbsd_nat_add_target): Delete.
11906 * fbsd-nat.h: Include "inf-ptrace.h".
11907 (fbsd_nat_add_target): Delete.
11908 (USE_SIGTRAP_SIGINFO): Define.
11909 (fbsd_nat_target): New class.
11911 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
11912 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
11913 (amd64bsd_target): Delete.
11914 * amd64-bsd-nat.h: New file.
11915 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
11917 (amd64_fbsd_nat_target): New class.
11918 (the_amd64_fbsd_nat_target): New.
11919 (amd64fbsd_read_description): Refactor as method of
11920 amd64_fbsd_nat_target.
11921 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11922 (_initialize_amd64fbsd_nat): Adjust to C++ification.
11923 * amd64-nat.h (amd64bsd_target): Delete function declaration.
11924 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
11925 (i386bsd_store_inferior_registers): Remove target_ops parameter.
11926 (i386bsd_target): Delete.
11927 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
11928 (i386bsd_fetch_inferior_registers)
11929 (i386bsd_store_inferior_registers): Declare.
11930 (i386_bsd_nat_target): New class.
11931 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
11932 (the_i386_fbsd_nat_target): New.
11933 (i386fbsd_resume, i386fbsd_read_description): Refactor as
11934 i386_fbsd_nat_target methods.
11935 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11936 (_initialize_i386fbsd_nat): Adjust to C++ification.
11937 * x86-bsd-nat.c (super_mourn_inferior): Delete.
11938 (x86bsd_mourn_inferior, x86bsd_target): Delete.
11939 (_initialize_x86_bsd_nat): Adjust to C++ification.
11940 * x86-bsd-nat.h: Include "x86-nat.h".
11941 (x86bsd_target): Delete declaration.
11942 (x86bsd_nat_target): New class.
11944 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
11945 (the_aarch64_fbsd_nat_target): New.
11946 (aarch64_fbsd_fetch_inferior_registers)
11947 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
11948 aarch64_fbsd_nat_target.
11949 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
11950 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
11951 (the_alpha_bsd_nat_target): New.
11952 (alphabsd_fetch_inferior_registers)
11953 (alphabsd_store_inferior_registers): Refactor as
11954 alpha_bsd_nat_target methods.
11955 (_initialize_alphabsd_nat): Refactor as methods of
11956 alpha_bsd_nat_target.
11957 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
11958 (the_amd64_nbsd_nat_target): New.
11959 (_initialize_amd64nbsd_nat): Adjust to C++ification.
11960 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
11961 (the_amd64_obsd_nat_target): New.
11962 (_initialize_amd64obsd_nat): Adjust to C++ification.
11963 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
11964 (the_arm_fbsd_nat_target): New.
11965 (arm_fbsd_fetch_inferior_registers)
11966 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
11967 (_initialize_arm_fbsd_nat): Refactor as methods of
11968 arm_fbsd_nat_target.
11969 (_initialize_arm_fbsd_nat): Adjust to C++ification.
11970 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
11971 (the_arm_netbsd_nat_target): New.
11972 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
11973 arm_netbsd_nat_target.
11974 (_initialize_arm_netbsd_nat): Adjust to C++ification.
11975 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
11976 (the_hppa_nbsd_nat_target): New.
11977 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
11978 hppa_nbsd_nat_target methods.
11979 (_initialize_hppanbsd_nat): Adjust to C++ification.
11980 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
11981 (the_hppa_obsd_nat_target): New.
11982 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
11983 methods of hppa_obsd_nat_target.
11984 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
11986 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
11987 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
11989 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
11990 (_initialize_i386obsd_nat): Use add_target.
11991 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
11992 (the_m68k_bsd_nat_target): New.
11993 (m68kbsd_fetch_inferior_registers)
11994 (m68kbsd_store_inferior_registers): Refactor as methods of
11995 m68k_bsd_nat_target.
11996 (_initialize_m68kbsd_nat): Adjust to C++ification.
11997 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
11998 (the_mips_fbsd_nat_target): New.
11999 (mips_fbsd_fetch_inferior_registers)
12000 (mips_fbsd_store_inferior_registers): Refactor as methods of
12001 mips_fbsd_nat_target.
12002 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
12004 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
12005 (the_mips_nbsd_nat_target): New.
12006 (mipsnbsd_fetch_inferior_registers)
12007 (mipsnbsd_store_inferior_registers): Refactor as methods of
12008 mips_nbsd_nat_target.
12009 (_initialize_mipsnbsd_nat): Adjust to C++ification.
12010 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
12011 (the_mips64_obsd_nat_target): New.
12012 (mips64obsd_fetch_inferior_registers)
12013 (mips64obsd_store_inferior_registers): Refactor as methods of
12014 mips64_obsd_nat_target.
12015 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
12017 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
12019 * nbsd-nat.h: Include "inf-ptrace.h".
12020 (nbsd_nat_target): New class.
12021 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
12022 (obsd_wait): Refactor as methods of obsd_nat_target.
12023 (obsd_add_target): Delete.
12024 * obsd-nat.h: Include "inf-ptrace.h".
12025 (obsd_nat_target): New class.
12026 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
12027 (the_ppc_fbsd_nat_target): New.
12028 (ppcfbsd_fetch_inferior_registers)
12029 (ppcfbsd_store_inferior_registers): Refactor as methods of
12030 ppc_fbsd_nat_target.
12031 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
12033 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
12034 (the_ppc_nbsd_nat_target): New.
12035 (ppcnbsd_fetch_inferior_registers)
12036 (ppcnbsd_store_inferior_registers): Refactor as methods of
12037 ppc_nbsd_nat_target.
12038 (_initialize_ppcnbsd_nat): Adjust to C++ification.
12039 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
12040 (the_ppc_obsd_nat_target): New.
12041 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
12042 methods of ppc_obsd_nat_target.
12043 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
12045 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
12046 (the_sh_nbsd_nat_target): New.
12047 (shnbsd_fetch_inferior_registers)
12048 (shnbsd_store_inferior_registers): Refactor as methods of
12049 sh_nbsd_nat_target.
12050 (_initialize_shnbsd_nat): Adjust to C++ification.
12051 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
12052 (inf_ptrace_xfer_partial): Delete.
12053 (sparc_xfer_partial, sparc_target): Delete.
12054 * sparc-nat.h (sparc_fetch_inferior_registers)
12055 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
12056 (sparc_target): Delete function declaration.
12057 (sparc_target): New template class.
12058 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
12059 (_initialize_sparcnbsd_nat): Adjust to C++ification.
12060 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
12061 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
12063 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
12064 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
12065 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
12066 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
12068 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
12069 (the_vax_bsd_nat_target): New.
12070 (vaxbsd_fetch_inferior_registers)
12071 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
12073 (_initialize_vaxbsd_nat): Adjust to C++ification.
12075 * bsd-kvm.c (bsd_kvm_target): New class.
12076 (bsd_kvm_ops): Now a bsd_kvm_target.
12077 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
12078 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
12079 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
12081 (bsd_kvm_return_one): Delete.
12082 (bsd_kvm_add_target): Adjust to C++ification.
12084 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
12085 (nto_procfs_target_procfs): New classes.
12086 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
12087 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
12088 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
12089 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
12090 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
12091 (procfs_remove_hw_breakpoint, procfs_resume)
12092 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
12093 (procfs_kill_inferior, procfs_store_registers)
12094 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
12095 as methods of nto_procfs_target.
12096 (nto_procfs_ops): Now an nto_procfs_target_procfs.
12097 (nto_native_ops): Delete.
12098 (procfs_open, procfs_native_open): Delete.
12099 (nto_native_ops): Now an nto_procfs_target_native.
12100 (init_procfs_targets): Adjust to C++ification.
12101 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
12102 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
12103 Refactor as methods of nto_procfs_target.
12105 * go32-nat.c (go32_nat_target): New class.
12106 (the_go32_nat_target): New.
12107 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
12108 (go32_store_registers, go32_xfer_partial, go32_files_info)
12109 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
12110 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
12111 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
12112 (go32_pid_to_str): Refactor as methods of go32_nat_target.
12113 (go32_target): Delete.
12114 (_initialize_go32_nat): Adjust to C++ification.
12116 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
12117 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
12118 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
12119 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
12121 (gnu_target): Delete.
12122 * gnu-nat.h (gnu_target): Delete.
12123 (gnu_nat_target): New class.
12124 * i386-gnu-nat.c (gnu_base_target): New.
12125 (i386_gnu_nat_target): New class.
12126 (the_i386_gnu_nat_target): New.
12127 (_initialize_i386gnu_nat): Adjust to C++ification.
12129 2018-05-02 Pedro Alves <palves@redhat.com>
12131 * bfd-target.c (target_bfd_xclose): Rename to ...
12132 (target_bfd_close): ... this.
12133 (target_bfd_reopen): Adjust.
12134 * target.c (target_close): Remove references to to_xclose.
12135 * target.h (target_ops::to_xclose): Delete.
12136 (target_ops::to_close): Update comments.
12138 2018-05-02 Pedro Alves <palves@redhat.com>
12140 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
12142 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
12143 * inf-ptrace.c (inf_ptrace_register_u_offset)
12144 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
12145 (inf_ptrace_store_register, inf_ptrace_store_registers)
12146 (inf_ptrace_trad_target): Move to ...
12147 * linux-nat-trad.c: ... this new file.
12148 * linux-nat-trad.h: New file.
12149 * linux-nat.c (linux_target_install_ops): Make extern.
12150 (linux_trad_target): Delete.
12151 * linux-nat.h (linux_trad_target): Delete declaration.
12152 (linux_target_install_ops): Declare.
12153 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
12156 2018-05-02 Pedro Alves <palves@redhat.com>
12158 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
12159 procfs_target/add_target here.
12160 * procfs.c (procfs_target): Make static.
12161 (_initialize_procfs): Call add_target here.
12162 * procfs.h (struct target_ops): Remove forward declaration.
12163 (procfs_target): Remove declaration.
12164 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
12166 2018-05-02 Pedro Alves <palves@redhat.com>
12168 * procfs.c (procfs_stopped_by_watchpoint)
12169 (procfs_insert_watchpoint, procfs_remove_watchpoint)
12170 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
12172 (procfs_use_watchpoints): Delete, move contents...
12173 (procfs_target): ... here.
12174 * procfs.h (procfs_use_watchpoints): Delete declaration.
12175 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
12176 procfs_use_watchpoints.
12177 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
12178 procfs_use_watchpoints.
12180 2018-05-02 Tom Tromey <tom@tromey.com>
12183 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
12184 and var_zuinteger_unlimited.
12185 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
12186 and PARAM_ZUINTEGER_UNLIMITED.
12187 (set_parameter_value): Handle var_zuinteger and
12188 var_zuinteger_unlimited.
12189 (add_setshow_generic): Likewise.
12190 (parmpy_init): Likewise.
12192 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
12195 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
12196 pointer is not null before dereferencing it.
12198 2018-04-30 Tom Tromey <tom@tromey.com>
12200 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
12203 2018-04-30 Tom Tromey <tom@tromey.com>
12205 * breakpoint.c (mention): Remove use of is_mi_like_p.
12206 (print_mention_ranged_breakpoint): Likewise.
12207 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
12210 2018-04-30 Tom Tromey <tom@tromey.com>
12212 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
12214 2018-04-30 Tom Tromey <tom@tromey.com>
12216 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
12217 (info_spu_event_command): Remove some uses of is_mi_like_p.
12219 2018-04-30 Tom Tromey <tom@tromey.com>
12221 * python/py-framefilter.c (py_print_single_arg)
12222 (enumerate_locals, py_print_args, py_print_frame): Remove some
12223 uses of is_mi_like_p.
12225 2018-04-30 Tom Tromey <tom@tromey.com>
12227 * ui-out.c: Update.
12228 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
12229 * ui-out.h (ui_out::is_mi_like_p): Now const.
12230 (ui_out::do_is_mi_like_p): Now const.
12231 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
12233 2018-04-30 Tom Tromey <tom@tromey.com>
12235 * varobj.c (varobj_set_visualizer): Use new_reference.
12236 * python/python.c (gdbpy_decode_line): Use new_reference.
12237 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
12240 2018-04-30 Tom Tromey <tom@tromey.com>
12242 * varobj.c (install_new_value): Use new_reference.
12243 * value.h (value_incref): Return void. Swap intro comment with
12245 * value.c (set_value_parent): Use new_reference.
12246 (value_incref): Return void. Update intro comment.
12247 (release_value): Use new_reference.
12248 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
12250 2018-04-30 Tom Tromey <tom@tromey.com>
12252 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
12253 * gdb_bfd.h (new_bfd_ref): Remove.
12254 (gdb_bfd_open): Update comment.
12255 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
12256 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
12257 (gdb_bfd_fdopenr): Use new_reference.
12258 * exec.c (exec_file_attach): Use new_reference.
12260 2018-04-30 Tom Tromey <tom@tromey.com>
12262 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
12265 2018-04-30 Tom Tromey <tom@tromey.com>
12267 * jit.c (jit_read_code_entry): Use type_align.
12268 * i386-tdep.c (i386_gdbarch_init): Don't call
12269 set_gdbarch_long_long_align_bit.
12270 * gdbarch.sh: Remove long_long_align_bit.
12271 * gdbarch.c, gdbarch.h: Rebuild.
12272 * arc-tdep.c (arc_type_align): New function.
12273 (arc_gdbarch_init): Use arc_type_align. Don't call
12274 set_gdbarch_long_long_align_bit.
12276 2018-04-30 Tom Tromey <tom@tromey.com>
12278 * rust-lang.c (rust_type_alignment): Remove.
12279 (rust_composite_type): Use type_align.
12281 2018-04-30 Tom Tromey <tom@tromey.com>
12283 * NEWS: Mention Type.align.
12284 * python/py-type.c (typy_get_alignof): New function.
12285 (type_object_getset): Add "alignof".
12287 2018-04-30 Tom Tromey <tom@tromey.com>
12291 * std-operator.def (UNOP_ALIGNOF): New operator.
12292 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
12294 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
12295 * c-lang.c (c_op_print_tab): Add alignof.
12296 * c-exp.y (ALIGNOF): New token.
12297 (exp): Add "ALIGNOF" production.
12298 (ident_tokens): Add _Alignof and alignof.
12300 2018-04-30 Tom Tromey <tom@tromey.com>
12302 * i386-tdep.c (i386_type_align): New function.
12303 (i386_gdbarch_init): Update.
12304 * gdbarch.sh (type_align): New method.
12305 * gdbarch.c, gdbarch.h: Rebuild.
12306 * arch-utils.h (default_type_align): Declare.
12307 * arch-utils.c (default_type_align): New function.
12308 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
12309 (struct type) <align_log2>: New field.
12310 <instance_flags>: Now a bitfield.
12311 (TYPE_RAW_ALIGN): New macro.
12312 (type_align, type_raw_align, set_type_align): Declare.
12313 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
12315 * dwarf2read.c (quirk_rust_enum): Set type alignment.
12316 (get_alignment, maybe_set_alignment): New functions.
12317 (read_structure_type, read_enumeration_type, read_array_type)
12318 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
12319 (read_subrange_type, read_base_type): Set type alignment.
12321 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
12323 * dwarf2read.c (read_index_from_section): Use bool.
12325 2018-04-29 Fabian Groffen <grobian@gentoo.org>
12328 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
12331 2018-04-29 John Reiser <jreiser@BitWagon.com>
12334 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
12335 last step, and do it atomically.
12337 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
12339 * compile/compile-c-types.c (convert_int, convert_float):
12340 Update for C FE v1.
12342 2018-04-27 Tom Tromey <tom@tromey.com>
12345 * rust-lang.c (rust_inclusive_range_type_p): New function.
12346 (rust_range): Handle inclusive ranges.
12347 (rust_compute_range): Likewise.
12348 * rust-exp.y (struct rust_op) <inclusive>: New field.
12349 (DOTDOTEQ): New constant.
12350 (range_expr): Add "..=" productions.
12351 (operator_tokens): Add "..=" token.
12352 (ast_range): Add "inclusive" parameter.
12353 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
12355 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
12357 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
12358 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
12360 * expprint.c (print_subexp_standard): Handle new bounds values.
12361 (dump_subexp_body_standard): Likewise.
12363 2018-04-27 Tom Tromey <tom@tromey.com>
12365 * configure: Rebuild.
12366 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
12367 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
12369 (class symbol_needs_eval_context): Likewise.
12370 * dwarf2read.c (mock_mapped_index::symbol_name_count)
12371 (mock_mapped_index::symbol_name_at): Use "override". Remove
12373 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
12375 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
12376 * aarch64-tdep.c (instruction_reader::read): Use "override".
12377 (instruction_reader_test::read): Likewise.
12378 * arm-tdep.c (instruction_reader::read): Use "override".
12379 (instruction_reader_thumb::read): Likewise.
12381 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
12384 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
12385 instead of remote_send.
12386 (remote_send): Remove.
12388 2018-04-26 Pedro Alves <palves@redhat.com>
12390 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
12391 find_function_start_sal instead of find_pc_line.
12393 2018-04-26 Pedro Alves <palves@redhat.com>
12395 * breakpoint.c (set_breakpoint_location_function): Handle
12396 mst_data_gnu_ifunc.
12397 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
12398 * elfread.c (elf_symtab_read): Give data symbols with
12399 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
12400 (elf_rel_plt_read): Update comment.
12401 * linespec.c (convert_linespec_to_sals): Handle
12402 mst_data_gnu_ifunc.
12403 (minsym_found): Handle mst_data_gnu_ifunc.
12404 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
12405 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
12406 * parse.c (find_minsym_type_and_address): Handle
12407 mst_data_gnu_ifunc.
12408 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
12409 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
12410 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
12412 <mst_data_gnu_ifunc>: New enumerator.
12414 2018-04-26 Pedro Alves <palves@redhat.com>
12416 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
12417 (lookup_minimal_symbol_by_pc_section): ... this. Replace
12418 'want_trampoline' parameter by a lookup_msym_prefer parameter.
12420 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
12421 (lookup_minimal_symbol_by_pc): Adjust.
12422 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
12423 (lookup_solib_trampoline_symbol_by_pc): Adjust.
12424 * minsyms.h (lookup_msym_prefer): New enum.
12425 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12426 parameter by a lookup_msym_prefer parameter.
12428 2018-04-26 Pedro Alves <palves@redhat.com>
12430 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
12431 ends in "@plt" instead of looking at the symbol's section.
12433 2018-04-26 Pedro Alves <palves@redhat.com>
12435 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
12437 (find_pc_partial_function_gnu_ifunc): Rename to ...
12438 (find_pc_partial_function): ... this, and remove references to
12440 (find_pc_partial_function): Delete old implementation.
12441 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
12443 2018-04-26 Pedro Alves <palves@redhat.com>
12445 * linespec.c (struct bound_minimal_symbol_search_key): New.
12446 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
12447 skip first line if we found a GNU ifunc minimal symbol by name.
12448 (compare_msymbols): Change parameters to work with a destructured
12450 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
12453 2018-04-26 Pedro Alves <palves@redhat.com>
12455 * breakpoint.c (set_breakpoint_location_function): Don't resolve
12456 ifunc targets here. Instead, if we have an ifunc minsym, use its
12458 (add_location_to_breakpoint): Store the minsym and the objfile in
12459 the breakpoint location.
12460 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
12461 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
12462 Record the minsym in the sal.
12463 * symtab.h (symtab_and_line) <msymbol>: New field.
12465 2018-04-26 Pedro Alves <palves@redhat.com>
12467 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
12468 unless we actually resolved the ifunc.
12470 2018-04-26 Pedro Alves <palves@redhat.com>
12472 * c-exp.y (variable production): Prefer ifunc minsyms over
12473 regular function symbols.
12474 * symtab.c (find_gnu_ifunc): New function.
12475 * minsyms.h (lookup_msym_prefer): New enum.
12476 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12477 parameter by a lookup_msym_prefer parameter.
12478 * symtab.h (find_gnu_ifunc): New declaration.
12480 2018-04-26 Pedro Alves <palves@redhat.com>
12482 * blockframe.c (find_gnu_ifunc_target_type): New function.
12483 (find_function_type): New.
12484 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
12485 return a value with a memory address.
12486 (eval_call): For calls to GNU ifunc functions, try to find the
12487 type of the target function from the type that the resolver
12489 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
12491 * infcall.c (find_function_return_type): Delete.
12492 (find_function_addr): Add 'function_type' parameter. For calls to
12493 GNU ifunc functions, try to find the type of the target function
12494 from the type that the resolver returns, and return it via
12496 (call_function_by_hand_dummy): Adjust to use the function type
12497 returned by find_function_addr.
12498 (find_function_addr): Add 'function_type' parameter and move
12500 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
12503 2018-04-26 Pedro Alves <palves@redhat.com>
12505 * c-exp.y (variable production): Skip finding an alias for ifunc
12508 2018-04-26 Pedro Alves <palves@redhat.com>
12510 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
12512 2018-04-25 Pedro Alves <palves@redhat.com>
12514 * infcmd.c (kill_command): Print the pid as string, not the whole
12515 thread's ptid. Add comment. s/has been killed/killed/ in output
12517 * remote.c (remote_detach_1): Print the pid as string, not the
12518 whole thread's ptid.
12520 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12521 Sergio Durigan Junior <sergiodj@redhat.com>
12522 Pedro Alves <palves@redhat.com>
12524 * infcmd.c (kill_command): Print message when inferior has
12526 * inferior.c (print_inferior_events): Remove 'static'. Set as
12528 (add_inferior): Improve message printed when
12529 'print_inferior_events' is on.
12530 (exit_inferior): Remove message printed when
12531 'print_inferior_events' is on.
12532 (detach_inferior): Improve message printed when
12533 'print_inferior_events' is on.
12534 (initialize_inferiors): Use 'add_inferior_silent' to set
12535 'current_inferior_'.
12536 * inferior.h (print_inferior_events): Declare here as
12538 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
12539 '[Detaching...]' messages when 'print_inferior_events' is on.
12540 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
12541 as prefix/suffix for messages. Remove periods. Fix erroneous
12542 'Detaching after fork from child...', replace it by '... from
12544 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
12545 prefix/suffix when printing 'Detaching...' messages. Print
12546 them when 'print_inferior_events' is on.
12547 * remote.c (remote_detach_1): Print message when detaching
12548 from inferior and '!is_fork_parent'.
12550 2018-04-24 Tom Tromey <tom@tromey.com>
12552 * cli-out.h: Reindent.
12554 2018-04-24 Tom Tromey <tom@tromey.com>
12556 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
12557 (cli_ui_out::do_field_string): Use fputs_filtered.
12558 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
12560 2018-04-23 Tom Tromey <tom@tromey.com>
12562 * guile/scm-frame.c (gdbscm_frame_read_var): Use
12563 gdb::unique_xmalloc_ptr.
12565 2018-04-23 Tom Tromey <tom@tromey.com>
12567 * configure: Rebuild.
12569 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
12572 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
12573 prepare_for_testing. Set normal_bp to r_debug_state if target
12576 2018-04-21 Pedro Alves <palves@redhat.com>
12577 Rajendra SY <rajendra.sy@gmail.com>
12579 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
12580 * remote.c (extended_remote_attach): In all-stop mode, mark the
12581 thread as executing.
12583 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12585 * thread.c (thread_apply_all_command): Fix comment.
12586 (thread_command): Fix comment.
12588 2018-04-10 Alan Hayward <alan.hayward@arm.com>
12590 * common/tdesc.h (tdesc_create_feature): Remove xml filename
12592 * features/aarch64-core.c (create_feature_aarch64_core):
12594 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
12596 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
12598 * features/i386/32bit-avx512.c
12599 (create_feature_i386_32bit_avx512): Likewise.
12600 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
12602 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
12604 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
12606 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
12608 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
12610 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
12612 * features/i386/64bit-avx512.c
12613 (create_feature_i386_64bit_avx512): Likewise.
12614 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
12616 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
12618 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
12620 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
12622 * features/i386/64bit-segments.c
12623 (create_feature_i386_64bit_segments): Likewise.
12624 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
12626 * features/i386/x32-core.c
12627 (create_feature_i386_x32_core): Likewise.
12628 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
12629 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
12630 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
12631 * target-descriptions.c: In generated code, don't pass xml
12634 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12636 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
12637 (print_xml_feature::visit_post): Likewise.
12638 (print_xml_feature::visit): Likewise.
12639 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
12640 (print_xml_feature): Add new class.
12641 * regformats/regdat.sh: Null xmltarget on feature targets.
12642 * target-descriptions.c (struct target_desc): Add xmltarget.
12643 (maintenance_check_tdesc_xml_convert): Add unittest function.
12644 (tdesc_get_features_xml): Add function to get xml.
12645 (maintenance_check_xml_descriptions): Test xml generation.
12646 * xml-tdesc.c (string_read_description_xml): Add function.
12647 * xml-tdesc.h (string_read_description_xml): Add declaration.
12649 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12651 * features/Makefile: Add feature marker to targets with new style
12652 target descriptions.
12653 * regformats/aarch64.dat: Regenerate.
12654 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
12655 * regformats/i386/amd64-avx-linux.dat: Likewise.
12656 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
12657 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
12658 * regformats/i386/amd64-linux.dat: Likewise.
12659 * regformats/i386/amd64-mpx-linux.dat: Likewise.
12660 * regformats/i386/amd64.dat: Likewise.
12661 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
12662 * regformats/i386/i386-avx-linux.dat: Likewise.
12663 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
12664 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
12665 * regformats/i386/i386-linux.dat: Likewise.
12666 * regformats/i386/i386-mmx-linux.dat: Likewise.
12667 * regformats/i386/i386-mpx-linux.dat: Likewise.
12668 * regformats/i386/i386.dat: Likewise.
12669 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
12670 * regformats/i386/x32-avx-linux.dat: Likewise.
12671 * regformats/i386/x32-linux.dat: Likewise.
12672 * regformats/tic6x-c62x-linux.dat: Likewise.
12673 * regformats/tic6x-c64x-linux.dat: Likewise.
12674 * regformats/tic6x-c64xp-linux.dat: Likewise.
12675 * regformats/regdat.sh: Parse feature marker.
12677 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12679 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
12680 (tdesc_osabi_name): Likewise.
12681 * target-descriptions.c (tdesc_architecture_name): Add new
12683 (tdesc_osabi_name): Likewise.
12685 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12687 * common/tdesc.c (tdesc_predefined_type): Move to here.
12688 (tdesc_named_type): Likewise.
12689 (tdesc_create_vector): Likewise.
12690 (tdesc_create_struct): Likewise.
12691 (tdesc_set_struct_size): Likewise.
12692 (tdesc_create_union): Likewise.
12693 (tdesc_create_flags): Likewise.
12694 (tdesc_create_enum): Likewise.
12695 (tdesc_add_field): Likewise.
12696 (tdesc_add_typed_bitfield): Likewise.
12697 (tdesc_add_bitfield): Likewise.
12698 (tdesc_add_flag): Likewise.
12699 (tdesc_add_enum_value): Likewise.
12700 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
12701 (struct tdesc_type_vector): Likewise.
12702 (struct tdesc_type_field): Likewise.
12703 (struct tdesc_type_with_fields): Likewise.
12704 (tdesc_create_enum): Add declaration.
12705 (tdesc_add_typed_bitfield): Likewise.
12706 (tdesc_add_enum_value): Likewise.
12707 * target-descriptions.c (tdesc_type_field): Move from here.
12708 (tdesc_type_builtin): Likewise.
12709 (tdesc_type_vector): Likewise.
12710 (tdesc_type_with_fields): Likewise.
12711 (tdesc_predefined_types): Likewise.
12712 (tdesc_named_type): Likewise.
12713 (tdesc_create_vector): Likewise.
12714 (tdesc_create_struct): Likewise.
12715 (tdesc_set_struct_size): Likewise.
12716 (tdesc_create_union): Likewise.
12717 (tdesc_create_flags): Likewise.
12718 (tdesc_create_enum): Likewise.
12719 (tdesc_add_field): Likewise.
12720 (tdesc_add_typed_bitfield): Likewise.
12721 (tdesc_add_bitfield): Likewise.
12722 (tdesc_add_flag): Likewise.
12723 (tdesc_add_enum_value): Likewise.
12724 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
12725 (tdesc_add_typed_bitfield): Likewise.
12726 (tdesc_add_enum_value): Likewise.
12728 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12730 * common/tdesc.c (tdesc_feature::accept): Move to here.
12731 (tdesc_feature::operator==): Likewise.
12732 (tdesc_create_reg): Likewise.
12733 * common/tdesc.h (tdesc_type_kind): Likewise.
12734 (struct tdesc_type): Likewise.
12735 (struct tdesc_feature): Likewise.
12736 * regformats/regdat.sh: Create a feature.
12737 * target-descriptions.c (tdesc_type_kind): Move from here.
12738 (tdesc_type): Likewise.
12739 (tdesc_type_up): Likewise.
12740 (tdesc_feature): Likewise.
12741 (tdesc_create_reg): Likewise.
12743 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12745 * Makefile.in: Add arch/tdesc.c
12746 * common/tdesc.c: New file.
12747 * common/tdesc.h (tdesc_element_visitor): Move to here.
12748 (tdesc_element): Likewise.
12749 (tdesc_reg): Likewise.
12750 (tdesc_reg_up): Likewise.
12751 * regformats/regdef.h (reg): Add offset to constructors.
12752 * target-descriptions.c (tdesc_element_visitor): Move from here.
12753 (tdesc_element): Likewise.
12754 (tdesc_reg): Likewise.
12755 (tdesc_reg_up): Likewise.
12757 2018-04-17 Tom Tromey <tom@tromey.com>
12759 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
12760 discriminant field.
12762 2018-04-17 Tom Tromey <tom@tromey.com>
12764 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
12766 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
12768 * symtab.c (print_symbol_info): Skip printing filename and line
12769 number when `last' is NULL.
12770 (symtab_symbol_info): Use empty string instead of NULL for first
12771 invocation of print_symbol_info.
12772 (rbreak_command): Pass NULL to `last' parameter of
12775 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
12777 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
12778 instead of nullptr.
12780 2018-04-16 Pedro Alves <palves@redhat.com>
12782 * MAINTAINERS (sh): Remove.
12783 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
12784 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
12785 (ALLDEPFILES): Remove sh64-tdep.c.
12786 * NEWS: Mentions that support for SH-5/SH64 is removed.
12787 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
12788 (sh*-*-openbsd*): Ditto.
12789 (sh64-*-elf*): Remove.
12791 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
12792 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
12793 * sh-tdep.c: No longer include "sh64-tdep.h".
12794 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
12795 * sh64-tdep.c, sh64-tdep.h: Remove files.
12797 2018-04-16 Pedro Alves <palves@redhat.com>
12799 * MAINTAINERS: Remove m88k.
12800 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
12801 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
12802 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
12803 * NEWS: Mention that support for m88k was removed.
12804 * configure.host (m88*-*-*): Remove support.
12805 * configure.nat (m88k-*-*): Remove support.
12806 * configure.tgt (m88*-*-openbsd*): Remove.
12807 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
12809 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
12811 * configure.tgt (x86_tobjs): New variable.
12812 (amd64_tobjs, i386_tobjs): Use it.
12814 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12816 * symtab.c (print_symbol_info): Precede the symbol definition by
12817 the line number when available.
12818 * NEWS: Advertise this enhancement.
12820 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12822 * NEWS (New options): announce set/show record btrace cpu.
12823 * btrace.c: Include record-btrace.h.
12824 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
12825 the vendor is unknown.
12826 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
12827 Maybe overwrite the btrace configuration's cpu.
12828 (btrace_compute_ftrace): Add cpu parameter. Update callers.
12829 (btrace_fetch): Add cpu parameter. Update callers.
12830 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
12831 Maybe overwrite the btrace configuration's cpu. Skip enabling
12832 errata workarounds if the vendor is unknown.
12833 * python/py-record-btrace.c: Include record-btrace.h.
12834 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
12835 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
12836 * record-btrace.c (record_btrace_cpu_state_kind): New.
12837 (record_btrace_cpu): New.
12838 (set_record_btrace_cpu_cmdlist): New.
12839 (record_btrace_get_cpu): New.
12840 (require_btrace_thread, record_btrace_info)
12841 (record_btrace_resume_thread): Call record_btrace_get_cpu.
12842 (cmd_set_record_btrace_cpu_none): New.
12843 (cmd_set_record_btrace_cpu_auto): New.
12844 (cmd_set_record_btrace_cpu): New.
12845 (cmd_show_record_btrace_cpu): New.
12846 (_initialize_record_btrace): Initialize set/show record btrace cpu
12848 * record-btrace.h (record_btrace_get_cpu): New.
12850 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12852 * record.c (set_record_command): Fix typo in message.
12854 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12856 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
12858 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12860 * infrun.c (process_event_stop_test): Call
12861 gdbarch_in_indirect_branch_thunk.
12862 * gdbarch.sh (in_indirect_branch_thunk): New.
12863 * gdbarch.c: Regenerated.
12864 * gdbarch.h: Regenerated.
12867 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
12868 (HFILES_NO_SRCDIR): Add x86-tdep.h.
12869 (ALLDEPFILES): Add x86-tdep.c.
12870 * arch-utils.h (default_in_indirect_branch_thunk): New.
12871 * arch-utils.c (default_in_indirect_branch_thunk): New.
12872 * i386-tdep: Include x86-tdep.h.
12873 (i386_in_indirect_branch_thunk): New.
12874 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
12876 * amd64-tdep: Include x86-tdep.h.
12877 (amd64_in_indirect_branch_thunk): New.
12878 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
12880 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12883 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
12884 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
12885 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
12888 2018-04-12 Tom Tromey <tom@tromey.com>
12890 * rust-lang.c (rust_print_struct_def): Remove univariant code.
12891 (rust_evaluate_subexp): Likewise.
12893 2018-04-12 Pedro Alves <palves@redhat.com>
12895 * procfs.c (procfs_detach): Make forward declaration's prototype
12896 match definition's protototype.
12897 (proc_get_LDT_entry): Remove stale do_cleanups call.
12899 2018-04-12 Pedro Alves <palves@redhat.com>
12901 * target.h (target_ops::to_has_exited): Delete.
12902 (target_has_exited): Delete.
12903 * target-delegates.c: Regenerate.
12905 2018-04-11 Pedro Alves <palves@redhat.com>
12907 * target.c (fileio_fh_t::t): Add comment.
12908 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12909 (target_fileio_close): Handle a NULL target.
12910 (invalidate_fileio_fh): New.
12911 (target_close): Call it.
12912 * remote.c (remote_hostio_send_command): No longer check whether
12913 remote_desc is open.
12915 2018-04-11 Pedro Alves <palves@redhat.com>
12917 * target.c (fileio_fh_t): Make it a named struct instead of a
12919 (fileio_fh_t::is_closed): New method.
12920 (DEF_VEC_O (fileio_fh_t)): Remove.
12921 (fileio_fhandles): Now a std::vector.
12922 (is_closed_fileio_fh): Delete.
12923 (acquire_fileio_fd): Adjust. Rename parameters.
12924 (release_fileio_fd): Adjust.
12925 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
12926 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12927 (target_fileio_close): Adjust.
12929 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
12931 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
12934 2018-04-10 Pedro Alves <palves@redhat.com>
12936 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
12937 (scoped_finish_thread_state): New class.
12938 * infcmd.c (run_command_1): Use it instead of finish_thread_state
12940 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
12941 (fetch_inferior_event, normal_stop): Likewise.
12942 * thread.c (finish_thread_state_cleanup): Delete.
12944 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12945 Pedro Alves <palves@redhat.com>
12947 * value.c: Include "selftest.h" and "common/array-view.h".
12948 (struct range) <operator ==>: New.
12949 (test_ranges_contain): New.
12950 (check_ranges_vector): New.
12951 (test_insert_into_bit_range_vector): New.
12952 (_initialize_values): Register selftests.
12953 * common/array-view.h (operator==, operator!=): New.
12955 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12957 * common/gdb_vecs.h (unordered_remove): Add overload that takes
12959 * inline-frame.c: Include <algorithm>.
12960 (struct inline_state): Add constructor.
12961 (inline_state_s): Remove.
12962 (DEF_VEC_O(inline_state_s)): Remove.
12963 (inline_states): Change type to std::vector.
12964 (find_inline_frame_state): Adjust to std::vector.
12965 (allocate_inline_frame_state): Remove.
12966 (clear_inline_frame_state): Adjust to std::vector.
12967 (skip_inline_frames): Adjust to std::vector.
12969 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12971 * tracepoint.h (struct trace_state_variable): Add constructor.
12972 <name>: Change type to std::string.
12973 * tracepoint.c (tsv_s): Remove.
12974 (DEF_VEC_O(tsv_s)): Remove.
12975 (tvariables): Change to std::vector.
12976 (create_trace_state_variable): Adjust to std::vector.
12977 (find_trace_state_variable): Likewise.
12978 (find_trace_state_variable_by_number): Likewise.
12979 (delete_trace_state_variable): Likewise.
12980 (trace_variable_command): Adjust to std::string.
12981 (delete_trace_variable_command): Likewise.
12982 (tvariables_info_1): Adjust to std::vector.
12983 (save_trace_state_variables): Likewise.
12984 (start_tracing): Likewise.
12985 (merge_uploaded_trace_state_variables): Adjust to std::vector
12987 * target.h (struct target_ops)
12988 <to_download_trace_state_variable>: Pass reference to
12989 trace_state_variable.
12990 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
12991 * target-delegates.c: Re-generate.
12992 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
12993 (mi_tsv_deleted): Likewise.
12994 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
12995 * remote.c (remote_download_trace_state_variable): Change
12996 pointer to reference and adjust.
12997 * make-target-delegates (parse_argtypes): Handle references.
12998 (write_function_header): Likewise.
12999 (munge_type): Likewise.
13001 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13003 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13004 string_view-selftests.c.
13005 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
13007 * unittests/basic_string_view/cons/char/1.cc: Likewise.
13008 * unittests/basic_string_view/cons/char/2.cc: Likewise.
13009 * unittests/basic_string_view/cons/char/3.cc: Likewise.
13010 * unittests/basic_string_view/element_access/char/1.cc:
13012 * unittests/basic_string_view/element_access/char/empty.cc:
13014 * unittests/basic_string_view/element_access/char/front_back.cc:
13016 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
13017 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
13019 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
13021 * unittests/basic_string_view/modifiers/swap/char/1.cc:
13023 * unittests/basic_string_view/operations/compare/char/1.cc:
13025 * unittests/basic_string_view/operations/compare/char/13650.cc:
13027 * unittests/basic_string_view/operations/copy/char/1.cc:
13029 * unittests/basic_string_view/operations/data/char/1.cc:
13031 * unittests/basic_string_view/operations/find/char/1.cc:
13033 * unittests/basic_string_view/operations/find/char/2.cc:
13035 * unittests/basic_string_view/operations/find/char/3.cc:
13037 * unittests/basic_string_view/operations/find/char/4.cc:
13039 * unittests/basic_string_view/operations/rfind/char/1.cc:
13041 * unittests/basic_string_view/operations/rfind/char/2.cc:
13043 * unittests/basic_string_view/operations/rfind/char/3.cc:
13045 * unittests/basic_string_view/operations/substr/char/1.cc:
13047 * unittests/basic_string_view/operators/char/2.cc: Likewise.
13048 * unittests/string_view-selftests.c: New file.
13050 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13052 * unittests/basic_string_view/capacity/1.cc: New file.
13053 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
13054 * unittests/basic_string_view/cons/char/1.cc: New file.
13055 * unittests/basic_string_view/cons/char/2.cc: New file.
13056 * unittests/basic_string_view/cons/char/3.cc: New file.
13057 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
13058 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
13059 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
13060 * unittests/basic_string_view/element_access/char/1.cc: New file.
13061 * unittests/basic_string_view/element_access/char/2.cc: New file.
13062 * unittests/basic_string_view/element_access/char/empty.cc: New file.
13063 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
13064 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
13065 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
13066 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
13067 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
13068 * unittests/basic_string_view/include.cc: New file.
13069 * unittests/basic_string_view/inserters/char/1.cc: New file.
13070 * unittests/basic_string_view/inserters/char/2.cc: New file.
13071 * unittests/basic_string_view/inserters/char/3.cc: New file.
13072 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
13073 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
13074 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
13075 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
13076 * unittests/basic_string_view/literals/types.cc: New file.
13077 * unittests/basic_string_view/literals/values.cc: New file.
13078 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
13079 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
13080 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
13081 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
13082 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
13083 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
13084 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
13085 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
13086 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
13087 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
13088 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
13089 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
13090 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
13091 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
13092 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
13093 * unittests/basic_string_view/operations/data/char/1.cc: New file.
13094 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
13095 * unittests/basic_string_view/operations/find/char/1.cc: New file.
13096 * unittests/basic_string_view/operations/find/char/2.cc: New file.
13097 * unittests/basic_string_view/operations/find/char/3.cc: New file.
13098 * unittests/basic_string_view/operations/find/char/4.cc: New file.
13099 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
13100 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
13101 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
13102 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
13103 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
13104 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
13105 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
13106 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
13107 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
13108 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
13109 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
13110 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
13111 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
13112 * unittests/basic_string_view/operators/char/2.cc: New file.
13113 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
13114 * unittests/basic_string_view/range_access/char/1.cc: New file.
13115 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
13116 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
13117 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
13118 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
13119 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
13120 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
13121 * unittests/basic_string_view/requirements/typedefs.cc: New file.
13122 * unittests/basic_string_view/typedefs.cc: New file.
13123 * unittests/basic_string_view/types/1.cc: New file.
13125 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13127 * common/gdb_string_view.h: Remove libstdc++ implementation
13128 details, adjust to gdb reality.
13129 * common/gdb_string_view.tcc: Likewise.
13130 * cli/cli-script.c (struct string_view): Remove.
13131 (user_args) <m_args>: Change element type to gdb::string_view.
13132 (user_args::insert_args): Adjust.
13134 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13136 * common/gdb_string_view.h: New file.
13137 * common/gdb_string_view.tcc: New file.
13139 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13141 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
13142 * configure: Re-generate.
13144 2018-04-09 Pedro Alves <palves@redhat.com>
13146 * gdbarch.sh: Include "observable.h" instead of "observer.h".
13147 (set_target_gdbarch): Call
13148 gdb::observers::architecture_changed.notify instead of
13149 observer_notify_architecture_changed.
13151 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13153 * tracepoint.c (struct current_traceframe_cleanup): Remove.
13154 (do_restore_current_traceframe_cleanup): Remove.
13155 (restore_current_traceframe_cleanup_dtor): Remove.
13156 (make_cleanup_restore_current_traceframe): Remove.
13157 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
13159 * tracepoint.h (struct scoped_restore_current_traceframe): New.
13160 * infrun.c (fetch_inferior_event): Use
13161 scoped_restore_current_traceframe.
13163 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13165 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
13167 <n_allocated_type_units>: Remove.
13168 <all_type_units>: Change to std::vector.
13169 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
13170 to std::vector change.
13171 (dwarf2_per_objfile::get_cutu): Likewise.
13172 (dwarf2_per_objfile::get_tu): Likewise.
13173 (create_signatured_type_table_from_index): Likewise.
13174 (create_signatured_type_table_from_debug_names): Likewise.
13175 (dw2_symtab_iter_next): Likewise.
13176 (dw2_print_stats): Likewise.
13177 (dw2_expand_all_symtabs): Likewise.
13178 (dw2_expand_marked_cus): Likewise.
13179 (dw2_debug_names_iterator::next): Likewise.
13180 (dwarf2_initialize_objfile): Likewise.
13181 (add_signatured_type_cu_to_table): Likewise.
13182 (create_all_type_units): Likewise.
13183 (add_type_unit): Likewise.
13184 (struct tu_abbrev_offset): Add constructor.
13185 (build_type_psymtabs_1): Adjust to std::vector change.
13186 (print_tu_stats): Likewise.
13187 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
13188 (write_debug_names): Likewise.
13190 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13192 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
13193 Make an std::vector.
13194 <n_comp_units>: Remove.
13195 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
13196 to std::vector change.
13197 (dwarf2_per_objfile::get_cutu): Likewise.
13198 (dwarf2_per_objfile::get_cu): Likewise.
13199 (create_cus_from_index): Likewise.
13200 (create_addrmap_from_index): Likewise.
13201 (create_addrmap_from_aranges): Likewise.
13202 (dwarf2_read_index): Likewise.
13203 (dw2_find_last_source_symtab): Likewise.
13204 (dw2_map_symtabs_matching_filename): Likewise.
13205 (dw2_symtab_iter_next): Likewise.
13206 (dw2_print_stats): Likewise.
13207 (dw2_expand_all_symtabs): Likewise.
13208 (dw2_expand_symtabs_with_fullname): Likewise.
13209 (dw2_expand_marked_cus): Likewise.
13210 (dw2_map_symbol_filenames): Likewise.
13211 (create_cus_from_debug_names): Likewise.
13212 (dwarf2_read_debug_names): Likewise.
13213 (dw2_debug_names_iterator::next): Likewise.
13214 (dwarf2_initialize_objfile): Likewise.
13215 (set_partial_user): Likewise.
13216 (dwarf2_build_psymtabs_hard): Likewise.
13217 (read_comp_units_from_section): Remove arguments, adjust to
13218 std::vector change.
13219 (create_all_comp_units): Adjust to std::vector and
13220 read_comp_units_from_section changes.
13221 (dwarf2_find_containing_comp_unit): Adjust to std::vector
13223 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
13224 (psyms_seen_size): Likewise.
13225 (write_gdbindex): Likewise.
13226 (write_debug_names): Likewise.
13228 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13230 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
13231 with dwarf2_per_objfile.
13232 (create_cus_from_index): Likewise.
13233 (create_signatured_type_table_from_index): Likewise.
13234 (dwarf2_read_index): Likewise.
13235 (dwarf2_initialize_objfile): Likewise.
13236 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
13237 per_cu rather than get_dwarf2_per_objfile.
13239 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13241 * dwarf2read.h (struct signatured_type): Forward declare.
13242 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
13244 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
13245 (dw2_get_cutu): ...this.
13246 (dwarf2_per_objfile::get_cu): Rename from...
13247 (dw2_get_cu): ...this.
13248 (dwarf2_per_objfile::get_tu): New.
13249 (create_addrmap_from_index): Adjust.
13250 (create_addrmap_from_aranges): Adjust.
13251 (dw2_find_last_source_symtab): Adjust.
13252 (dw2_map_symtabs_matching_filename): Adjust.
13253 (dw2_symtab_iter_next): Adjust.
13254 (dw2_print_stats): Adjust.
13255 (dw2_expand_all_symtabs): Adjust.
13256 (dw2_expand_symtabs_with_fullname): Adjust.
13257 (dw2_expand_marked_cus): Adjust.
13258 (dw_expand_symtabs_matching_file_matcher): Adjust.
13259 (dw2_map_symbol_filenames): Adjust.
13260 (dw2_debug_names_iterator::next): Adjust.
13261 (dwarf2_initialize_objfile): Adjust.
13262 (set_partial_user): Adjust.
13263 (dwarf2_build_psymtabs_hard): Adjust.
13265 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13267 * dwarf2read.c (create_signatured_type_table_from_debug_names):
13268 Remove unused variables.
13269 (dw2_map_symtabs_matching_filename): Likewise.
13270 (dwarf2_record_block_ranges): Likewise.
13271 (dwarf2_read_addr_index): Likewise.
13272 (follow_die_offset): Likewise.
13274 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13276 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
13277 to symbol_file_add_main.
13279 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13282 * mi/mi-console.c (do_fputc_async_safe): New.
13283 (mi_console_file::write_async_safe): New.
13284 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
13285 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
13287 * ui-file.c (ui_file::putstrn): Adjust call to
13288 fputstrn_unfiltered.
13289 * utils.c (printchar): Replace do_fputs and do_fprintf
13290 parameters by do_fputc.
13291 (fputstr_filtered): Adjust call to printchar.
13292 (fputstr_unfiltered): Likewise.
13293 (fputstrn_filtered): Likewise.
13294 (fputstrn_unfiltered): Add do_fputc parameter, pass to
13296 * utils.h (do_fputc_ftype): New typedef.
13297 (fputstrn_unfiltered): Add do_fputc parameter.
13299 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13301 * regformats/i386/i386-avx.dat: Remove.
13303 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13306 * amd64-tdep.c (amd64_none_init_abi): New function.
13307 (amd64_x32_none_init_abi): New function.
13308 (_initialize_amd64_tdep): Register handlers for x86-64 and
13309 x64_32 with GDB_OSABI_NONE.
13310 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
13311 GDB_OSABI_NONE osabi.
13313 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13316 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
13318 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
13319 * osabi.c (gdb_osabi_names): Add "unknown" entry.
13321 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13323 * common/byte-vector.h (char_vector): New type.
13324 * target.h (target_read_alloc): Return
13325 gdb::optional<byte_vector>.
13326 (target_read_stralloc): Return gdb::optional<char_vector>.
13327 (target_get_osdata): Return gdb::optional<char_vector>.
13328 * target.c (target_read_alloc_1): Templatize. Replacement
13329 manual memory management with vector.
13330 (target_read_alloc): Change return type, adjust.
13331 (target_read_stralloc): Change return type, adjust.
13332 (target_get_osdata): Change return type, adjust.
13333 * auxv.c (struct auxv_info) <length>: Remove.
13334 <data>: Change type to gdb::optional<byte_vector>.
13335 (auxv_inferior_data_cleanup): Free auxv_info with delete.
13336 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
13337 (target_auxv_search): Adjust.
13338 (fprint_target_auxv): Adjust.
13339 * avr-tdep.c (avr_io_reg_read_command): Adjust.
13340 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
13341 (linux_make_corefile_notes): Adjust.
13342 * osdata.c (get_osdata): Adjust.
13343 * remote.c (remote_get_threads_with_qxfer): Adjust.
13344 (remote_memory_map): Adjust.
13345 (remote_traceframe_info): Adjust.
13346 (btrace_read_config): Adjust.
13347 (remote_read_btrace): Adjust.
13348 (remote_pid_to_exec_file): Adjust.
13349 * solib-aix.c (solib_aix_get_library_list): Adjust.
13350 * solib-dsbt.c (decode_loadmap): Don't free buf.
13351 (dsbt_get_initial_loadmaps): Adjust.
13352 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
13353 * solib-target.c (solib_target_current_sos): Adjust.
13354 * tracepoint.c (sdata_make_value): Adjust.
13355 * xml-support.c (xinclude_start_include): Adjust.
13356 (xml_fetch_content_from_file): Adjust.
13357 * xml-support.h (xml_fetch_another): Change return type.
13358 (xml_fetch_content_from_file): Change return type.
13359 * xml-syscall.c (xml_init_syscalls_info): Adjust.
13360 * xml-tdesc.c (file_read_description_xml): Adjust.
13361 (fetch_available_features_from_target): Change return type.
13362 (target_fetch_description_xml): Adjust.
13363 (target_read_description_xml): Adjust.
13365 2018-04-06 Tom Tromey <tom@tromey.com>
13367 * value.c (~value): Update.
13368 (struct value) <contents>: Now unique_xmalloc_ptr.
13369 (value_contents_bits_eq, allocate_value_contents)
13370 (value_contents_raw, value_contents_all_raw)
13371 (value_contents_for_printing, value_contents_for_printing_const)
13372 (set_value_enclosing_type): Update.
13374 2018-04-06 Tom Tromey <tom@tromey.com>
13376 * value.c (range_s): Remove typedef, VEC.
13377 (struct range): Add operator<.
13378 (range_lessthan): Remove.
13379 (ranges_contain): Change type.
13381 (struct value) <unavailable, optimized_out>: Now std::vector.
13382 (value_entirely_available)
13383 (value_entirely_covered_by_range_vector)
13384 (value_entirely_unavailable, value_entirely_optimized_out):
13386 (insert_into_bit_range_vector): Change argument type.
13387 (find_first_range_overlap): Likewise.
13388 (struct ranges_and_idx, value_contents_bits_eq)
13389 (require_not_optimized_out, require_available): Update.
13390 (ranges_copy_adjusted): Change argument types.
13391 (value_optimized_out, value_copy, value_fetch_lazy): Update.
13393 2018-04-06 Tom Tromey <tom@tromey.com>
13395 * value.c (~value): Update.
13396 (struct value) <parent>: Now a value_ref_ptr.
13397 (value_parent, set_value_parent, value_address, value_copy):
13400 2018-04-06 Tom Tromey <tom@tromey.com>
13402 * value.c (struct value): Add constructor, destructor, and member
13404 (allocate_value_lazy, value_decref): Update.
13406 2018-04-06 Tom Tromey <tom@tromey.com>
13408 * value.c (struct value) <released, next>: Remove.
13409 (all_values): Now a std::vector.
13410 (allocate_value_lazy): Update.
13411 (value_next): Remove.
13412 (value_mark, value_free_to_mark, release_value)
13413 (value_release_to_mark): Update.
13415 2018-04-06 Tom Tromey <tom@tromey.com>
13417 * value.h (fetch_subexp_value, value_release_to_mark): Update.
13418 (free_value_chain): Remove.
13419 * value.c (free_value_chain): Remove.
13420 (value_release_to_mark): Return a std::vector.
13421 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
13423 (check_condition): Update.
13424 * eval.c (fetch_subexp_value): Change "val_chain" to a
13426 * breakpoint.c (update_watchpoint): Update.
13427 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
13429 2018-04-06 Tom Tromey <tom@tromey.com>
13431 * value.h (free_all_values): Remove.
13432 * value.c (free_all_values): Remove.
13434 2018-04-06 Tom Tromey <tom@tromey.com>
13436 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
13437 (value_history_chain, value_history_count): Remove.
13438 (value_history): New global.
13439 (record_latest_value, access_value_history, show_values)
13440 (preserve_values): Update.
13442 2018-04-06 Tom Tromey <tom@tromey.com>
13444 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
13445 * varobj.c (varobj_set_display_format, varobj_set_value)
13446 (install_default_visualizer, construct_visualizer)
13447 (install_new_value, ~varobj, varobj_get_value_type)
13448 (my_value_of_variable, varobj_editable_p): Update.
13449 * c-varobj.c (c_describe_child, c_value_of_variable)
13450 (cplus_number_of_children, cplus_describe_child): Update.
13451 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
13452 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
13453 (ada_value_of_variable, ada_value_is_changeable_p): Update.
13455 2018-04-06 Tom Tromey <tom@tromey.com>
13457 * printcmd.c (last_examine_address): Change type to
13459 (do_examine, x_command): Update.
13461 2018-04-06 Tom Tromey <tom@tromey.com>
13463 * value.c (release_value): Update.
13464 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
13465 (struct bpstats) <val>: Now a value_ref_ptr.
13466 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13467 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13468 (~watchpoint, print_it_watchpoint, watch_command_1)
13469 (invalidate_bp_value_on_memory_change): Update.
13471 2018-04-06 Tom Tromey <tom@tromey.com>
13473 * varobj.c (varobj_clear_saved_item)
13474 (update_dynamic_varobj_children, install_new_value, ~varobj):
13476 * value.h (value_incref): Move declaration earlier.
13477 (value_decref): Rename from value_free.
13478 (struct value_ref_policy): New.
13479 (value_ref_ptr): New typedef.
13480 (struct value_deleter): Remove.
13481 (gdb_value_up): Remove typedef.
13482 (release_value): Change return type.
13483 (release_value_or_incref): Remove.
13484 * value.c (set_value_parent): Update.
13485 (value_incref): Change return type.
13486 (value_decref): Rename from value_free.
13487 (value_free_to_mark, free_all_values, free_value_chain): Update.
13488 (release_value): Return value_ref_ptr.
13489 (release_value_or_incref): Remove.
13490 (record_latest_value, set_internalvar, clear_internalvar):
13492 * stack.c (info_frame_command): Don't call value_free.
13493 * python/py-value.c (valpy_dealloc, valpy_new)
13494 (value_to_value_object): Update.
13495 * printcmd.c (do_examine): Update.
13496 * opencl-lang.c (lval_func_free_closure): Update.
13497 * mi/mi-main.c (register_changed_p): Don't call value_free.
13498 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
13499 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
13500 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
13502 * guile/scm-value.c (vlscm_free_value_smob)
13503 (vlscm_scm_from_value): Update.
13504 * frame.c (frame_register_unwind, frame_unwind_register_signed)
13505 (frame_unwind_register_unsigned, get_frame_register_bytes)
13506 (put_frame_register_bytes): Don't call value_free.
13507 * findvar.c (address_from_register): Don't call value_free.
13508 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
13509 * dwarf2loc.c (entry_data_value_free_closure)
13510 (value_of_dwarf_reg_entry, free_pieced_value_closure)
13511 (dwarf2_evaluate_loc_desc_full): Update.
13512 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13513 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13514 (~watchpoint, watch_command_1)
13515 (invalidate_bp_value_on_memory_change): Update.
13516 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
13518 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
13521 * warning.m4: Add -Wno-error=deprecated-register.
13522 * configure: Re-generate.
13524 2018-04-05 Tom Tromey <tom@tromey.com>
13526 * linespec.h: Remove include of "vec.h".
13528 2018-04-05 Tom Tromey <tom@tromey.com>
13530 * linespec.c (typep): Remove typedef.
13531 (find_methods, find_superclass_methods): Take a std::vector.
13532 (find_method): Use std::vector.
13534 2018-04-05 Tom Tromey <tom@tromey.com>
13536 * utils.c (compare_strings): Remove.
13537 * utils.h (compare_strings): Remove.
13538 * objc-lang.h (find_imps): Update.
13539 * objc-lang.c (find_methods): Take a std::vector.
13540 (uniquify_strings, find_imps): Likewise.
13541 * linespec.c (find_methods): Take a std::vector.
13542 (decode_objc): Use std::vector.
13543 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
13545 (find_method, find_function_symbols): Use std::vector.
13547 2018-04-05 Tom Tromey <tom@tromey.com>
13549 * completer.c (completion_tracker::completion_tracker): Remove
13551 (completion_tracker::discard_completions): Likewise.
13552 * breakpoint.c (ambiguous_names_p): Remove cast.
13553 * ada-lang.c (_initialize_ada_language): Remove cast.
13554 * utils.h (streq): Update.
13555 (streq_hash): Add new declaration.
13556 * utils.c (streq): Return bool.
13557 (streq_hash): New function.
13559 2018-04-05 Tom Tromey <tom@tromey.com>
13561 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
13562 Remove a string copy.
13564 2018-04-05 Tom Tromey <tom@tromey.com>
13566 * linespec.c (filter_results): Use std::vector.
13567 (decode_line_2, decode_line_full): Update.
13569 2018-04-05 Tom Tromey <tom@tromey.com>
13571 * linespec.c (canonical_to_fullform): Return std::string.
13572 (filter_results): Update.
13573 (struct decode_line_2_item): Add constructor.
13574 <fullform, displayform>: Now std::string.
13575 (decode_line_2_compare_items): Now a std::sort comparator.
13576 (decode_line_2): Update.
13578 2018-04-05 Tom Tromey <tom@tromey.com>
13580 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
13581 (unexpected_linespec_error): Update.
13582 (linespec_parse_basic, parse_linespec): Update.
13584 2018-04-05 Tom Tromey <tom@tromey.com>
13586 * linespec.c (linespec_parse_basic): Reindent.
13588 2018-04-05 Tom Tromey <tom@tromey.com>
13590 * minsyms.h (iterate_over_minimal_symbols): Update.
13591 * minsyms.c (iterate_over_minimal_symbols): Take a
13592 gdb::function_view.
13593 * linespec.c (struct collect_minsyms): Remove.
13594 (compare_msyms): Now a std::sort comparator.
13595 (add_minsym): Add parameters.
13596 (search_minsyms_for_name): Update. Use std::vector.
13598 2018-04-03 Tom Tromey <tom@tromey.com>
13600 * mipsread.c (read_alphacoff_dynamic_symtab): Use
13603 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13605 * MAINTAINERS (Write After Approval): Add Weimin Pan.
13607 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13610 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
13611 printing static type.
13613 2018-04-01 Tom Tromey <tom@tromey.com>
13615 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
13616 (rs6000_xfer_shared_libraries): Update.
13618 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
13620 * common/gdb_vecs.h (char_ptr): Remove.
13621 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
13623 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13625 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
13627 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
13629 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13631 * tracepoint.h (struct uploaded_tp): Initialize fields.
13632 <actions, step_actions, cmd_strings>: Change type to
13633 std::vector<char *>.
13634 * tracepoint.c (get_uploaded_tp): Allocate with new.
13635 (free_uploaded_tps): Free with delete.
13636 (parse_tracepoint_definition): Adjust to std::vector change.
13637 * breakpoint.c (read_uploaded_action): Likewise.
13638 (create_tracepoint_from_upload): Likewise.
13639 * ctf.c (ctf_write_uploaded_tp): Likewise.
13640 (SET_ARRAY_FIELD): Likewise.
13641 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
13643 2018-03-30 Tom Tromey <tom@tromey.com>
13645 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
13647 (svr4_keep_data_in_core): Update.
13648 (svr4_read_so_list): Update.
13650 2018-03-30 Tom Tromey <tom@tromey.com>
13652 * windows-nat.c (handle_output_debug_string, handle_exception):
13654 * target.h (target_read_string): Update.
13655 * target.c (target_read_string): Change "string" to
13656 unique_xmalloc_ptr.
13657 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
13659 * solib-frv.c (frv_current_sos): Update.
13660 * solib-dsbt.c (dsbt_current_sos): Update.
13661 * solib-darwin.c (darwin_current_sos): Update.
13662 * linux-thread-db.c (inferior_has_bug): Update.
13663 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
13664 Update. Remove alloca.
13665 * ada-lang.c (ada_main_name): Update.
13667 2018-03-30 Tom Tromey <tom@tromey.com>
13669 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
13670 (struct dwo_file_deleter): New.
13671 (dwo_file_up): New typedef.
13672 (open_and_init_dwo_file): Use dwo_file_up.
13673 (free_dwo_file_cleanup): Remove.
13675 2018-03-30 Tom Tromey <tom@tromey.com>
13677 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
13678 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
13680 2018-03-30 Tom Tromey <tom@tromey.com>
13682 * dwarf2read.c (class free_cached_comp_units): New class.
13683 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
13684 (free_cached_comp_units): Remove function.
13686 2018-03-30 Tom Tromey <tom@tromey.com>
13688 * utils.h (make_cleanup_unpush_target): Remove.
13689 * inf-ptrace.c (struct target_unpusher): New.
13690 (target_unpush_up) New typedef.
13691 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
13693 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
13695 2018-03-27 Tom Tromey <tom@tromey.com>
13697 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
13699 2018-03-27 Pedro Alves <palves@redhat.com>
13700 Tom Tromey <tom@tromey.com>
13702 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
13703 destructor. Now a class.
13704 (gdb_readline_wrapper_cleanup): Remove function.
13705 (gdb_readline_wrapper): Remove cleanups.
13707 2018-03-27 Tom Tromey <tom@tromey.com>
13709 * typeprint.h (struct type_print_options) <local_typedefs,
13710 global_typedefs>: Remove "struct" keyword.
13711 (class typedef_hash_table): New class.
13712 (recursively_update_typedef_hash, add_template_parameters)
13713 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
13714 (find_typedef_in_hash): Don't declare.
13715 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
13716 (typedef_hash_table::recursively_update): Rename from
13717 recursively_update_typedef_hash. Now a member.
13718 (typedef_hash_table::add_template_parameters): Rename from
13719 add_template_parameters. Now a member.
13720 (typedef_hash_table::typedef_hash_table): Now a constructor;
13721 rename from create_typedef_hash.
13722 (typedef_hash_table::~typedef_hash_table): Now a destructor;
13723 rename from free_typedef_hash.
13724 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
13725 (do_free_global_table): Remove.
13726 (typedef_hash_table::typedef_hash_table): New constructor; renamed
13727 from copy_type_recursive.
13728 (create_global_typedef_table): Remove.
13729 (typedef_hash_table::find_global_typedef): Now a member of
13730 typedef_hash_table.
13731 (typedef_hash_table::find_typedef): Rename from
13732 find_typedef_in_hash; now a member.
13733 (whatis_exp): Update.
13734 * extension.h (struct ext_lang_type_printers): Add constructor and
13736 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
13738 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
13739 Now a constructor; rename from start_ext_lang_type_printers.
13740 (ext_lang_type_printers): Now a destructor; rename from
13741 free_ext_lang_type_printers.
13742 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
13744 (c_type_print_base_struct_union): Update. Remove cleanups.
13746 2018-03-27 Tom Tromey <tom@tromey.com>
13748 * dwarf-index-write.c: Include <cmath>.
13750 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13752 * NEWS: Add entry describing new "set|show varsize-limit" command.
13753 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
13755 * printcmd.c (_initialize_printcmd): Add "set var" alias of
13758 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
13760 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
13761 dwarf-index-write.c
13762 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
13763 * dwarf-index-common.c: New file.
13764 * dwarf-index-common.h: New file.
13765 * dwarf-index-write.c: New file.
13766 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
13767 (struct dwarf2_section_info): Move from here.
13768 (dwarf2_section_info_def): Likewise.
13769 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
13770 (offset_type): Likewise.
13771 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
13772 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
13773 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
13774 (byte_swap): Likewise.
13775 (MAYBE_SWAP): Likewise.
13776 (dwarf2_per_cu_ptr): Likewise.
13777 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
13778 (struct tu_stats): Likewise.
13779 (struct dwarf2_per_objfile): Likewise.
13780 (struct dwarf2_per_cu_data): Likewise.
13781 (struct signatured_type): Likewise.
13782 (sig_type_ptr): Likewise.
13783 (DEF_VEC_P (sig_type_ptr)): Likewise.
13784 (INDEX4_SUFFIX): Likewise.
13785 (INDEX5_SUFFIX): Likewise.
13786 (DEBUG_STR_SUFFIX): Likewise.
13787 (dwarf2_read_section): Make non-static.
13788 (mapped_index_string_hash): Move from here.
13789 (dwarf5_djb_hash): Likewise.
13790 (file_write): Likewise.
13791 (class data_buf): Likewise.
13792 (struct symtab_index_entry): Likewise.
13793 (struct mapped_symtab): Likewise.
13794 (find_slot): Likewise.
13795 (hash_expand): Likewise.
13796 (add_index_entry): Likewise.
13797 (uniquify_cu_indices): Likewise.
13798 (class c_str_view): Likewise.
13799 (class c_str_view_hasher): Likewise.
13800 (class vector_hasher): Likewise.
13801 (write_hash_table): Likewise.
13802 (psym_index_map): Likewise.
13803 (struct addrmap_index_data): Likewise.
13804 (add_address_entry): Likewise.
13805 (add_address_entry_worker): Likewise.
13806 (write_address_map): Likewise.
13807 (symbol_kind): Likewise.
13808 (write_psymbols): Likewise.
13809 (struct signatured_type_index_data): Likewise.
13810 (write_one_signatured_type): Likewise.
13811 (recursively_count_psymbols): Likewise.
13812 (recursively_write_psymbols): Likewise.
13813 (class debug_names): Likewise.
13814 (check_dwarf64_offsets): Likewise.
13815 (psyms_seen_size): Likewise.
13816 (write_gdbindex): Likewise.
13817 (write_debug_names): Likewise.
13818 (assert_file_size): Likewise.
13819 (write_psymtabs_to_index): Likewise.
13820 (save_gdb_index_command): Likewise.
13821 (_initialize_dwarf2_read): Don't register the "save gdb-index"
13823 * dwarf2read.h: New file.
13825 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13828 * dwarf2read.c (dwarf2_physname): Do not return the demangled
13829 symbol name if the CU's language stores symbol names in linkage
13831 * language.h (struct language_defn)
13832 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
13833 all instances of this struct.
13835 2018-03-26 Tom Tromey <tom@tromey.com>
13837 * stack.c (backtrace_command_1): Remove verbose code.
13839 2018-03-26 Tom Tromey <tom@tromey.com>
13841 * python/py-framefilter.c (py_print_type): Don't catch
13842 exceptions. Return void.
13843 (py_print_value): Likewise.
13844 (py_print_single_arg): Likewise.
13845 (enumerate_args): Don't catch exceptions.
13846 (py_print_args): Likewise.
13847 (py_print_frame): Likewise.
13848 (gdbpy_apply_frame_filter): Catch exceptions here.
13850 2018-03-26 Tom Tromey <tom@tromey.com>
13852 * stack.c (_initialize_stack): Remove trailing newlines from help
13853 text. Add "Usage" line to "backtrace" help.
13855 2018-03-26 Tom Tromey <tom@tromey.com>
13858 * python/py-framefilter.c (py_print_args): Call wrap_hint.
13860 2018-03-26 Tom Tromey <tom@tromey.com>
13862 * python/py-framefilter.c (py_print_single_arg): Return
13863 EXT_LANG_BT_ERROR from catch.
13865 2018-03-26 Tom Tromey <tom@tromey.com>
13867 PR backtrace/15584:
13868 * stack.c (backtrace_command_1): Move some code into no-filters
13871 2018-03-26 Tom Tromey <tom@tromey.com>
13873 * python/py-framefilter.c (throw_quit_or_print_exception): New
13875 (gdbpy_apply_frame_filter): Use it.
13877 2018-03-26 Tom Tromey <tom@tromey.com>
13880 * python/py-framefilter.c (py_print_type, py_print_value)
13881 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
13884 2018-03-26 Tom Tromey <tom@tromey.com>
13886 * python/py-framefilter.c (enumerate_args): Use
13887 gdb::unique_xmalloc_ptr.
13889 2018-03-26 Tom Tromey <tom@tromey.com>
13891 * python/py-framefilter.c (py_print_frame): Return
13893 (gdbpy_apply_frame_filter): Update comment.
13894 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
13896 <EXT_LANG_BT_NO_FILTERS>: Change value.
13898 2018-03-26 Tom Tromey <tom@tromey.com>
13900 PR backtrace/15582:
13901 * stack.c (backtrace_command): Parse "hide" argument.
13902 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
13903 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
13906 2018-03-26 Tom Tromey <tom@tromey.com>
13908 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
13910 (backtrace_command): Remove "fulltrace", add "flags".
13912 2018-03-26 Tom Tromey <tom@tromey.com>
13914 * stack.c (backtrace_command): Rewrite command line parsing.
13916 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13918 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
13920 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13922 * filename-seen-cache.h: Add include guard.
13924 2018-03-26 Keith Seitz <keiths@redhat.com>
13926 * symfile.c (place_section): Remove "struct" from section_addr_info
13928 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
13929 "struct" keyword from section_addr_info.
13931 2018-03-26 Alan Hayward <alan.hayward@arm.com>
13933 * regformats/regdef.h (reg): Add constructors.
13935 2018-03-25 Pedro Alves <palves@redhat.com>
13937 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
13938 if then/else bodies in var_func_name extraction.
13940 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
13942 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
13943 lookup_minimal_symbol() to find symbol entry.
13944 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
13946 2018-03-23 Keith Seitz <keiths@redhat.com>
13949 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
13950 nested type definitions for C++, too.
13952 2018-03-23 Tom Tromey <tom@tromey.com>
13954 * machoread.c (struct oso_el): Add a constructor. Don't define as
13956 (macho_register_oso): Remove.
13957 (macho_symtab_read): Take a std::vector.
13958 (oso_el_compare_name): Now a std::sort comparator.
13959 (macho_symfile_read_all_oso): Take a std::vector.
13960 (macho_symfile_read): Use std::vector. Remove cleanups.
13962 2018-03-22 Tom Tromey <tom@tromey.com>
13964 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
13965 (record_full_goto_bookmark): Use std::string.
13967 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13970 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
13973 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13975 * rs6000-tdep.c (store_insn_p): New function.
13976 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
13977 and cr_reg to their unshifted values. Use store_insn_p to
13978 match LR saves using either R1 or fdata->alloca_reg. Use
13979 store_insn_p to match CR saves. Set alloca_reg_offset
13980 when alloca_reg and framep are set. Remove lr_reg shift
13981 when assigning to fdata->lr_register.
13983 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
13985 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
13986 command line args instead of emitting a warning.
13988 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13990 * tracepoint.h (struct static_tracepoint_marker): Initialize
13991 fields, define default constructor, move constructor and move
13992 assignment, disable the rest.
13993 <str_id, extra>: Make std::string.
13994 (release_static_tracepoint_marker): Remove.
13995 (free_current_marker): Remove.
13996 * tracepoint.c (free_current_marker): Remove.
13997 (parse_static_tracepoint_marker_definition): Adjust to
13998 std::string, use new hex2str overload.
13999 (release_static_tracepoint_marker): Remove.
14000 (print_one_static_tracepoint_marker): Get marker by reference
14001 and adjust to std::string.
14002 (info_static_tracepoint_markers_command): Adjust to std::vector
14004 * target.h (static_tracepoint_marker_p): Remove typedef.
14005 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
14006 (struct target_ops) <to_static_tracepoint_marker_at>: Return
14008 <to_static_tracepoint_markers_by_strid>: Return std::vector.
14010 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
14011 (target_debug_print_std_vector_static_tracepoint_marker): New.
14012 (target_debug_print_struct_static_tracepoint_marker_p): Rename
14014 (target_debug_print_static_tracepoint_marker_p): ... this.
14015 * target-delegates.c: Re-generate.
14016 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
14018 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
14019 (decode_static_tracepoint_spec): Adjust to std::vector.
14020 (tracepoint_print_one_detail): Adjust to std::string.
14021 (strace_marker_decode_location): Adjust to std::string.
14022 (update_static_tracepoint): Adjust to std::string, remove call
14023 to release_static_tracepoint_marker.
14024 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
14025 Adjust to std::vector.
14026 * remote.c (remote_static_tracepoint_marker_at): Return bool.
14027 (remote_static_tracepoint_markers_by_strid): Adjust to
14029 * common/rsp-low.h (hex2str): New overload with explicit count
14031 * common/rsp-low.c (hex2str): New overload with explicit count
14033 * unittests/rsp-low-selftests.c (test_hex2str): New function.
14034 (_initialize_rsp_low_selftests): Add test_hex2str test.
14035 * unittests/tracepoint-selftests.c
14036 (test_parse_static_tracepoint_marker_definition): Adjust to
14039 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14041 * tracepoint.c (parse_static_tracepoint_marker_definition):
14042 Consider case where the definition is followed by more
14044 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14045 tracepoint-selftests.c.
14046 * unittests/tracepoint-selftests.c: New.
14048 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
14050 * MAINTAINERS (Write After Approval): Add Pedro Franco de
14053 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
14055 * symtab.c (find_pc_sect_line): fixed indentation.
14057 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
14059 * symtab.c (find_pc_sect_line): now uses binary search.
14061 2018-03-19 Tom Tromey <tom@tromey.com>
14063 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
14064 "IDENT" production.
14066 2018-03-19 Pedro Alves <palves@redhat.com>
14067 Tom Tromey <tom@tromey.com>
14069 * unittests/observable-selftests.c: New file.
14070 * common/observable.h: New file.
14071 * observable.h: New file.
14072 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
14073 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
14074 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
14075 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
14076 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
14077 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
14078 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
14079 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
14080 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
14081 python/py-breakpoint.c, python/py-finishbreakpoint.c,
14082 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
14083 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
14084 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
14085 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
14086 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
14087 tui/tui-interp.c, valops.c: Update all users.
14088 * tui/tui-hooks.c (tui_bp_created_observer)
14089 (tui_bp_deleted_observer, tui_bp_modified_observer)
14090 (tui_inferior_exit_observer, tui_before_prompt_observer)
14091 (tui_normal_stop_observer, tui_register_changed_observer):
14093 (tui_observers_token): New global.
14094 (attach_or_detach, tui_attach_detach_observers): New functions.
14095 (tui_install_hooks, tui_remove_hooks): Use
14096 tui_attach_detach_observers.
14097 * record-btrace.c (record_btrace_thread_observer): Remove.
14098 (record_btrace_thread_observer_token): New global.
14099 * observer.sh: Remove.
14100 * observer.c: Rename to observable.c.
14101 * observable.c (namespace gdb_observers): Define new objects.
14102 (observer_debug): Move into gdb_observers namespace.
14103 (struct observer, struct observer_list, xalloc_observer_list_node)
14104 (xfree_observer_list_node, generic_observer_attach)
14105 (generic_observer_detach, generic_observer_notify): Remove.
14106 (_initialize_observer): Update.
14107 Don't include observer.inc.
14108 * Makefile.in (generated_files): Remove observer.h, observer.inc.
14109 (clean mostlyclean): Likewise.
14110 (observer.h, observer.inc): Remove targets.
14111 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
14112 (COMMON_SFILES): Use observable.c, not observer.c.
14113 * .gitignore: Remove observer.h.
14115 2018-03-18 Tom Tromey <tom@tromey.com>
14117 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
14119 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
14121 2018-03-17 Tom Tromey <tom@tromey.com>
14123 * auto-load.c (auto_load_objfile_script_1): Use std::string.
14125 2018-03-17 Tom Tromey <tom@tromey.com>
14127 * target.c (class scoped_target_fd): New.
14128 (target_fileio_close_cleanup): Remove.
14129 (target_fileio_read_alloc_1): Use scoped_target_fd.
14131 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
14133 * silent-rules.mk: New.
14134 * Makefile.in: Include silent-rules.mk
14135 (srcdir, VPATH, top_srcdir): Move up.
14136 (COMPILE): Add ECHO_CXX.
14137 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
14138 (init.c): Add ECHO_INIT_C.
14139 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
14140 (version.c): Add ECHO_GEN.
14141 (printcmd.o): Add ECHO_CXX.
14142 (target-float.o): Add ECHO_CXX.
14143 (ada-exp.o): Add ECHO_CXX.
14144 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
14145 (insight$(EXEEXT)): Add ECHO_CXXLD.
14146 * gnulib/configure.ac: Add AM_SILENT_RULES.
14147 * gnulib/aclocal.m4: Re-generate.
14148 * gnulib/configure: Re-generate.
14149 * gnulib/import/Makefile.in: Re-generate.
14151 2018-03-16 Tom Tromey <tom@tromey.com>
14153 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
14154 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
14155 * utils.c (do_free_section_addr_info)
14156 (make_cleanup_free_section_addr_info): Remove.
14157 * symfile.h (struct other_sections): Add constructor.
14158 (struct section_addr_info): Remove.
14159 (section_addr_info): New typedef.
14160 (struct sym_fns) <sym_offsets>: Change type of parameter.
14161 (build_section_addr_info_from_objfile)
14162 (relative_addr_info_to_section_offsets, addr_info_make_relative)
14163 (default_symfile_offsets, symbol_file_add)
14164 (symbol_file_add_from_bfd)
14165 (build_section_addr_info_from_section_table): Update.
14166 (alloc_section_addr_info, free_section_addr_info): Don't declare.
14167 * symfile.c (alloc_section_addr_info): Remove.
14168 (build_section_addr_info_from_section_table): Change return type.
14170 (build_section_addr_info_from_bfd)
14171 (build_section_addr_info_from_objfile): Likewise.
14172 (free_section_addr_info): Remove.
14173 (relative_addr_info_to_section_offsets): Change type of "addrs".
14174 (addrs_section_compar): Now a std::sort comparator.
14175 (addrs_section_sort): Change return type.
14176 (addr_info_make_relative): Change type of "addrs". Update.
14177 (default_symfile_offsets, syms_from_objfile_1)
14178 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
14179 (symbol_file_add_separate): Update.
14180 (symbol_file_add): Change type of "addrs". Update.
14181 (add_symbol_file_command): Update. Remove cleanups.
14182 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
14184 * symfile-debug.c (debug_sym_offsets): Change type of "info".
14185 * solib.c (solib_read_symbols): Update.
14186 * objfiles.c (objfile_relocate): Update. Remove cleanups.
14187 * machoread.c (macho_symfile_offsets): Update.
14188 * jit.c (jit_bfd_try_read_symtab): Update.
14190 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
14192 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14193 unittests/utils-selftests.c.
14194 * unittests/utils-selftests.c: New file.
14196 2018-03-14 Tom Tromey <tom@tromey.com>
14199 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
14202 2018-03-14 Tom Tromey <tom@tromey.com>
14205 * printcmd.c (printf_pointer): Allow "-" in format.
14207 2018-03-14 Tom Tromey <tom@tromey.com>
14209 * printcmd.c (_initialize_printcmd): Add usage to printf.
14211 2018-03-14 Yao Qi <qiyao@sourceware.org>
14213 * MAINTAINERS: Update my email address.
14215 2018-03-13 Tom Tromey <tom@tromey.com>
14217 * machoread.c (macho_check_dsym): Change filenamep to a
14219 (macho_symfile_read): Update.
14220 * symfile.c (load_command): Use std::string.
14222 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
14224 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
14225 to error message string.
14226 (riscv_register_name): Use xsnprintf instead of sprintf.
14227 (riscv_insn::fetch_instruction): Use gdb_assert instead of
14229 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
14231 (riscv_push_dummy_call): Likewise.
14233 2018-03-12 Tom Tromey <tom@tromey.com>
14235 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
14236 Use gdb::byte_vector.
14237 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
14239 2018-03-12 Yao Qi <yao.qi@linaro.org>
14241 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
14242 parameter type to readable_regcache.
14243 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
14246 2018-03-11 Tom Tromey <tom@tromey.com>
14248 * dwarf2read.c (struct nextfield): Add initializers.
14249 (struct nextfnfield): Remove.
14250 (struct fnfieldlist): Add initializers. Remove "length" and
14251 "head", use std::vector.
14252 (struct decl_field_list): Remove.
14253 (struct field_info): Add initializers.
14254 <fields, baseclasses>: Now std::vector.
14255 <nbaseclasses, nfnfields, typedef_field_list_count,
14256 nested_types_list_count>: Remove.
14257 (dwarf2_add_field, dwarf2_add_type_defn)
14258 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
14259 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
14260 (process_structure_scope): Update.
14262 2018-03-11 Tom Tromey <tom@tromey.com>
14264 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
14265 for use by std::sort.
14266 (build_type_psymtabs_1): Use std::vector.
14268 2018-03-09 Eli Zaretskii <eliz@gnu.org>
14270 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
14271 and LIBMPFR in the printed configuration.
14273 2018-03-08 Tom Tromey <tom@tromey.com>
14275 * source.c (get_filename_and_charpos): Use scoped_fd.
14276 * nto-procfs.c (procfs_open_1): Use scoped_fd.
14277 (procfs_pidlist): Likewise.
14278 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
14279 (iterate_over_mappings): Likewise.
14281 2018-03-08 Tom Tromey <tom@tromey.com>
14283 * infcall.c (struct call_return_meta_info)
14284 <stack_temporaries_enabled>: Remove.
14285 (get_call_return_value, call_function_by_hand_dummy): Update.
14286 * thread.c (disable_thread_stack_temporaries): Remove.
14287 (enable_thread_stack_temporaries): Remove.
14288 (thread_stack_temporaries_enabled_p): Return bool.
14289 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
14290 (get_last_thread_stack_temporary): Update.
14291 * eval.c (evaluate_subexp): Update.
14292 * gdbthread.h (class enable_thread_stack_temporaries): Now a
14293 class, not a function.
14294 (value_ptr, value_vec): Remove typedefs.
14295 (class thread_info) <stack_temporaries_enabled>: Now bool.
14296 <stack_temporaries>: Now a std::vector.
14297 (thread_stack_temporaries_enabled_p)
14298 (value_in_thread_stack_temporaries): Return bool.
14300 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
14302 * remote.c (putpkt_binary): Fix omitted bytes reporting.
14303 (getpkt_or_notif_sane_1): Likewise.
14305 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14307 * build-id.c (build_id_to_debug_bfd): Use std::string.
14309 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14311 * build-id.c (find_separate_debug_file_by_buildid): Return
14313 * build-id.h (find_separate_debug_file_by_buildid): Return
14315 * coffread.c (coff_symfile_read): Adjust to std::string.
14316 * elfread.c (elf_symfile_read): Adjust to std::string.
14317 * symfile.c (separate_debug_file_exists): Change parameter to
14319 (find_separate_debug_file): Return std::string.
14320 (find_separate_debug_file_by_debuglink): Return std::string.
14321 * symfile.h (find_separate_debug_file_by_debuglink): Return
14324 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14326 * common/xml-utils.c (xml_escape_text): Move code to...
14327 (xml_escape_text_append): ... this new function.
14328 * common/xml-utils.h (xml_escape_text_append): New declaration.
14329 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
14331 (_initialize_xml_utils): register test_xml_escape_text_append as
14334 2018-03-07 Alan Hayward <alan.hayward@arm.com>
14336 * defs.h: Remove MAX_REGISTER_SIZE.
14337 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
14339 * python/py-unwind.c (pyuw_sniffer): Likewise.
14341 2018-03-07 Tom Tromey <tom@tromey.com>
14343 * linux-tdep.c (linux_info_proc): Update.
14344 * target.h (struct target_ops) <to_fileio_readlink>: Return
14346 (target_fileio_readlink): Return optional<string>.
14347 * remote.c (remote_hostio_readlink): Return optional<string>.
14348 * inf-child.c (inf_child_fileio_readlink): Return
14350 * target.c (target_fileio_readlink): Return optional<string>.
14352 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
14354 * regcache.c (cooked_read_test): Add riscv to the list of
14355 architectures that have a save_reggroup.
14357 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
14359 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
14360 value is not a dynamic class object.
14362 2018-03-06 Tom Tromey <tom@tromey.com>
14364 * rust-exp.y: Formatting fixes.
14366 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14368 * riscv-tdep.c (riscv_register_name): Remove target description
14370 (riscv_gdbarch_init): Remove target description check.
14372 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14374 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
14376 * riscv-tdep.h: Likewise.
14378 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14380 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
14381 (riscv_pseudo_register_write): Delete.
14382 (riscv_gdbarch_init): Remove all use of pseudo registers.
14384 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14386 * record-btrace.c (btrace_print_lines): Replace cleanup
14387 parameter with RAII equivalents.
14388 (btrace_insn_history): Replace cleanup with RAII equivalents.
14389 * ui-out.h (make_cleanup_ui_out_list_begin_end,
14390 make_cleanup_ui_out_tuple_begin_end): Remove.
14391 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
14392 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
14393 make_cleanup_ui_out_list_begin_end): Remove.
14395 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14397 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
14398 parameter types to std::vector. Use bool.
14399 (record_btrace_wait): Replace VEC(tp_t) with
14400 std::vector<thread_info *>.
14401 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
14403 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14405 * record-btrace.c (record_btrace_disable_callback): Remove.
14406 (struct scoped_btrace_disable): New.
14407 (record_btrace_open): Use scoped_btrace_disable.
14409 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14411 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
14412 reading values from registers.
14414 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14416 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
14419 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14421 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
14422 change parameter type. Use GDB's print functions, and use
14423 core_addr_to_string where appropriate.
14424 (riscv_push_dummy_call): Use core_addr_to_string where
14425 appropriate, update call to riscv_print_arg_location, and reindent
14427 (riscv_return_value): Update call to riscv_print_arg_location.
14429 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14430 Tim Newsome <tim@sifive.com>
14431 Albert Ou <a0u@eecs.berkeley.edu>
14432 Darius Rad <darius@bluespec.com>
14434 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
14435 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
14436 (ALLDEPFILES): Add riscv-tdep.c
14437 * configure.tgt: Add riscv support.
14438 * riscv-tdep.c: New file.
14439 * riscv-tdep.h: New file.
14440 * NEWS: Mention new target.
14441 * MAINTAINERS: Add entry for riscv.
14443 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14445 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
14446 fields within aggregates.
14448 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
14450 * record-btrace.c (btrace_print_lines): Change type of flags to
14451 gdb_disassembly_flags.
14453 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14455 * fbsd-nat.c: Include "inf-ptrace.h".
14456 (USE_SIGTRAP_SIGINFO): Conditionally define.
14457 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
14458 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
14459 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
14461 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
14463 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
14465 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
14466 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
14467 "supports_stopped_by_hw_breakpoint" target methods.
14469 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14471 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
14472 * fbsd-nat.c (debug_fbsd_nat): New variable.
14473 (show_fbsd_nat_debug): New function.
14474 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
14475 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
14477 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14479 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
14480 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
14482 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
14483 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
14486 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14488 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
14489 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
14491 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14493 * charset.c (struct charset_vector): New.
14494 (charsets): Change type to charset_vector.
14495 (find_charset_names): Adjust.
14497 (_initialize_charset): Adjust.
14499 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14501 * progspace.h (struct program_space) <deleted_solibs>: Change
14502 type to std::vector<std::string>.
14503 * progspace.c (clear_program_space_solib_cache): Adjust.
14504 * breakpoint.c (print_solib_event): Adjust.
14505 (check_status_catch_solib): Adjust.
14506 * solib.c (update_solib_list): Adjust.
14507 * ui-out.h (class ui_out) <field_string>: New overload.
14508 * ui-out.c (ui_out::field_string): New overload.
14510 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14512 * progspace.h (struct program_space): Add constructor and
14513 destructor, initialize fields.
14514 (add_program_space): Remove.
14515 * progspace.c (add_program_space): Rename to...
14516 (program_space::program_space): ... this.
14517 (release_program_space): Rename to...
14518 (program_space::~program_space): ... this.
14519 (delete_program_space): Use delete to delete program_space.
14520 (initialize_progspace): Use new to allocate program_space.
14521 * inferior.c (add_inferior_with_spaces): Likewise.
14522 (clone_inferior_command): Likewise.
14523 * infrun.c (follow_fork_inferior): Likewise.
14524 (handle_vfork_child_exec_or_exit): Likewise.
14526 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14528 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
14529 (delim_string_to_char_ptr_vec): Return std::vector of
14530 gdb::unique_xmalloc_ptr.
14531 (dirnames_to_char_ptr_vec_append): Take std::vector of
14532 gdb::unique_xmalloc_ptr.
14533 (dirnames_to_char_ptr_vec): Return std::vector of
14534 gdb::unique_xmalloc_ptr.
14535 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
14536 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
14537 (delim_string_to_char_ptr_vec): Return an std::vector of
14538 gdb::unique_xmalloc_ptr, adjust the code.
14539 (dirnames_to_char_ptr_vec_append): Take an std::vector of
14540 gdb::unique_xmalloc_ptr, adjust the code.
14541 (dirnames_to_char_ptr_vec): Return an std::vector of
14542 gdb::unique_xmalloc_ptr, adjust the code.
14543 * auto-load.c (auto_load_safe_path_vec): Change type to
14544 std::vector of gdb::unique_xmalloc_ptr.
14545 (auto_load_expand_dir_vars): Return an std::vector of
14546 gdb::unique_xmalloc_ptr, adjust the code.
14547 (auto_load_safe_path_vec_update): Adjust.
14548 (filename_is_in_auto_load_safe_path_vec): Adjust.
14549 (auto_load_objfile_script_1): Adjust.
14550 * build-id.c (build_id_to_debug_bfd): Adjust.
14551 * linux-thread-db.c (thread_db_load_search): Adjust.
14552 * source.c (add_path): Adjust.
14554 * symfile.c (find_separate_debug_file): Adjust.
14555 * utils.c (do_free_char_ptr_vec): Remove.
14556 (make_cleanup_free_char_ptr_vec): Remove.
14558 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
14561 * common/pathstuff.c: Conditionally include "<windows.h>".
14563 2018-03-01 Georg Sauthoff <mail@georg.so>
14566 * gcore.in: Quote variables and switch interpreter to bash.
14568 2018-03-01 Tom Tromey <tom@tromey.com>
14570 * dwarf2read.c (alloc_discriminant_info): Fix default_index
14571 assertion. Add assertion for discriminant_index.
14572 (quirk_rust_enum): Use correct base type name in univariant case.
14574 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
14576 * record.c (get_call_history_modifiers): Return a
14577 record_print_flags.
14578 (cmd_record_call_history): Adjust.
14579 * record-btrace.c (record_btrace_call_history): Adjust.
14580 (record_btrace_call_history_range): Adjust.
14581 (record_btrace_call_history_from): Adjust.
14582 * target-debug.h (target_debug_print_record_print_flags): New.
14583 * target-delegates.c: Re-generate.
14584 * target.c (target_call_history): Change flags type.
14585 (target_call_history_from): Likewise.
14586 (target_call_history_range): Likewise.
14587 * target.h (struct target_ops) <target_call_history>: Likewise.
14588 (target_call_history_from): Likewise.
14589 (target_call_history_range): Likewise.
14591 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14592 Simon Marchi <simon.marchi@polymtl.ca>
14594 * common/common-utils.c: Include "sys/stat.h".
14595 (is_regular_file): Move here from "source.c"; change return
14597 * common/common-utils.h (is_regular_file): New prototype.
14598 * common/pathstuff.c (contains_dir_separator): New function.
14599 * common/pathstuff.h (contains_dir_separator): New prototype.
14600 * source.c: Don't include "sys/stat.h".
14601 (is_regular_file): Move to "common/common-utils.c".
14603 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14605 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
14606 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
14607 * auto-load.c: Include "common/pathstuff.h".
14608 * common/common-def.h (current_directory): Move here.
14609 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
14611 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
14613 * common/pathstuff.c: New file.
14614 * common/pathstuff.h: New file.
14615 * compile/compile.c: Include "common/pathstuff.h".
14616 * defs.h (current_directory): Move to "common/common-defs.h".
14617 * dwarf2read.c: Include "common/pathstuff.h".
14618 * exec.c: Likewise.
14619 * guile/scm-safe-call.c: Likewise.
14620 * linux-thread-db.c: Likewise.
14621 * main.c: Likewise.
14622 * nto-tdep.c: Likewise.
14623 * objfiles.c: Likewise.
14624 * source.c: Likewise.
14625 * symtab.c: Likewise.
14626 * utils.c: Include "common/pathstuff.h".
14627 (gdb_realpath): Move to "common/pathstuff.c".
14628 (gdb_realpath_keepfile): Likewise.
14629 (gdb_abspath): Likewise.
14630 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
14631 (gdb_realpath_keepfile): Likewise.
14632 (gdb_abspath): Likewise.
14634 2018-02-28 John Baldwin <jhb@FreeBSD.org>
14636 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
14637 wildcard process pid for super_resume for kernels with a
14640 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
14642 * compile/compile.c (get_args): Add additional comments
14643 explaining function.
14645 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
14646 Tom Tromey <tom@tromey.com>
14648 * target.h (memory_write_request_s): Remove typedef. Don't define
14650 (target_write_memory_blocks): Change argument to std::vector.
14651 (struct memory_write_request): Add constructor.
14652 * target-memory.c (compare_block_starting_address): Return bool.
14653 Change argument types.
14654 (claim_memory): Change arguments to use std::vector.
14655 (split_regular_and_flash_blocks, blocks_to_erase)
14656 (compute_garbled_blocks): Likewise.
14657 (cleanup_request_data, cleanup_write_requests_vector): Remove.
14658 (target_write_memory_blocks): Change argument to std::vector.
14659 * symfile.c (struct load_section_data): Add constructor and
14660 destructor. Use std::vector for "requests".
14661 (struct load_progress_data): Add initializers.
14662 (load_section_callback): Update. Use "new".
14663 (clear_memory_write_data): Remove.
14664 (generic_load): Update.
14666 2018-02-27 Alan Hayward <alan.hayward@arm.com>
14668 * arch/aarch64.h: Use common/tdesc.h.
14670 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14672 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
14673 architecture with a 64-bit ABI.
14675 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14677 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
14678 ahead of target description loading.
14680 2018-02-26 Tom Tromey <tom@tromey.com>
14682 * stack.c (backtrace_command_1): Update.
14683 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
14685 * python/py-framefilter.c (py_print_frame)
14686 (gdbpy_apply_frame_filter): Change type of "flags".
14687 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
14689 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
14690 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
14691 * extension.h (enum frame_filter_flag): Rename from
14692 frame_filter_flags.
14693 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
14694 (apply_ext_lang_frame_filter): Change type of "flags".
14695 * extension.c (apply_ext_lang_frame_filter): Change type of
14697 * extension-priv.h (struct extension_language_ops)
14698 <apply_frame_filter>: Change type of "flags".
14700 2018-02-26 Tom Tromey <tom@tromey.com>
14703 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
14704 off-by-one in py_end computation.
14705 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
14707 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
14710 2018-02-26 Tom Tromey <tom@tromey.com>
14712 * dwarf2read.c (struct variant_field): New.
14713 (struct nextfield) <variant>: New field.
14714 (dwarf2_add_field): Handle DW_TAG_variant_part.
14715 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
14716 discriminated union.
14717 (read_structure_type): Handle DW_TAG_variant_part.
14718 (handle_struct_member_die): New function, extracted from
14719 process_structure_scope. Handle DW_TAG_variant.
14720 (process_structure_scope): Handle discriminated unions. Call
14721 handle_struct_member_die.
14723 2018-02-26 Tom Tromey <tom@tromey.com>
14725 * rust-lang.h (rust_last_path_segment): Declare.
14726 * rust-lang.c (rust_last_path_segment): Now public. Change
14728 (struct disr_info): Remove.
14729 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
14730 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
14731 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
14732 (rust_enum_p, rust_enum_variant): New function.
14733 (rust_underscore_fields): Remove "offset" parameter.
14734 (rust_print_enum): New function.
14735 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
14736 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
14737 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
14739 (rust_internal_print_type): New function, from rust_print_type.
14741 (rust_print_type): Call rust_internal_print_type.
14742 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
14743 Update enum handling.
14744 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
14745 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
14746 (rust_union_quirks): New functions.
14747 (process_full_comp_unit, process_full_type_unit): Call
14749 (process_structure_scope): Update rust_unions if necessary.
14751 2018-02-26 Tom Tromey <tom@tromey.com>
14753 * value.h (value_union_variant): Declare.
14754 * valops.c (value_union_variant): New function.
14755 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
14756 (struct discriminant_info): New.
14757 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
14759 (struct main_type) <flag_discriminated_union>: New field.
14761 2018-02-26 Tom Tromey <tom@tromey.com>
14763 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14764 unittests/unpack-selftests.c.
14765 * unittests/unpack-selftests.c: New file.
14766 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
14768 2018-02-26 Yao Qi <yao.qi@linaro.org>
14770 * dwarf2read.c (struct partial_die_info) <read>: New method.
14771 (read_partial_die): Remove the declaration.
14772 (load_partial_dies): Update.
14773 (partial_die_info::partial_die_info):
14774 (read_partial_die): Change it to partial_die_info::read.
14776 2018-02-26 Yao Qi <yao.qi@linaro.org>
14778 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
14779 (fixup_partial_die): Remove declaration.
14780 (scan_partial_symbols): Update.
14781 (partial_die_parent_scope): Likewise.
14782 (partial_die_full_name): Likewise.
14783 (fixup_partial_die): Change it to partial_die_info::fixup.
14785 2018-02-26 Yao Qi <yao.qi@linaro.org>
14787 * dwarf2read.c (read_partial_die): Update the declaration.
14788 (load_partial_dies): Caller update.
14789 (read_partial_die): Remove one argument abbrev_len.
14791 2018-02-26 Yao Qi <yao.qi@linaro.org>
14793 * dwarf2read.c (struct partial_die_info): Add ctor, delete
14794 assignment operator.
14795 (load_partial_dies): Use ctor and copy ctor.
14796 (read_partial_die): Update.
14797 (dwarf2_cu::find_partial_die): Use ctor.
14799 2018-02-26 Yao Qi <yao.qi@linaro.org>
14801 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
14802 (find_partial_die_in_comp_unit): Change it to
14803 dwarf2_cu::find_partial_die.
14804 (find_partial_die): Update.
14806 2018-02-26 Yao Qi <yao.qi@linaro.org>
14808 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
14811 2018-02-26 Yao Qi <yao.qi@linaro.org>
14813 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
14815 2018-02-26 Alan Hayward <alan.hayward@arm.com>
14817 * arch/amd64.h: Use common/tdesc.h.
14818 * arch/i386.c: Likewise.
14819 * arch/i386.h: Likewise.
14820 * arch/tic6x.c: Likewise.
14821 * arch/tdesc.h: Move file from here...
14822 * common/tdesc.h: ...to here.
14823 * features/aarch64-core.c: Regenerate.
14824 * features/aarch64-fpu.c: Regenerate.
14825 * features/i386/32bit-avx.c: Regenerate.
14826 * features/i386/32bit-avx512.c: Regenerate.
14827 * features/i386/32bit-core.c: Regenerate.
14828 * features/i386/32bit-linux.c: Regenerate.
14829 * features/i386/32bit-mpx.c: Regenerate.
14830 * features/i386/32bit-pkeys.c: Regenerate.
14831 * features/i386/32bit-sse.c: Regenerate.
14832 * features/i386/64bit-avx.c: Regenerate.
14833 * features/i386/64bit-avx512.c: Regenerate.
14834 * features/i386/64bit-core.c: Regenerate.
14835 * features/i386/64bit-linux.c: Regenerate.
14836 * features/i386/64bit-mpx.c: Regenerate.
14837 * features/i386/64bit-pkeys.c: Regenerate.
14838 * features/i386/64bit-segments.c: Regenerate.
14839 * features/i386/64bit-sse.c: Regenerate.
14840 * features/i386/x32-core.c: Regenerate.
14841 * features/tic6x-c6xp.c: Regenerate.
14842 * features/tic6x-core.c: Regenerate.
14843 * features/tic6x-gp.c: Regenerate.
14844 * target-descriptions.c: Use common/tdesc.h.
14845 * target-descriptions.h: Likewise.
14847 2018-02-24 Tom Tromey <tom@tromey.com>
14849 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
14850 (try_thread_db_load_from_dir, thread_db_load_search): Use
14852 (info_auto_load_libthread_db_compare): Return bool. Change
14854 (info_auto_load_libthread_db): Use std::vector, std::string.
14857 2018-02-24 Tom Tromey <tom@tromey.com>
14859 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
14861 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
14863 * gdbarch.c: Rebuild.
14864 * gdbarch.h: Rebuild.
14865 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
14866 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
14867 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
14870 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
14872 * gdbtypes.h (sect_offset): Change type to uint64_t.
14873 (sect_offset_str): New function.
14874 * dwarf2read.c (create_addrmap_from_aranges): Use
14876 (error_check_comp_unit_head): Likewise.
14877 (create_debug_type_hash_table): Likewise.
14878 (read_cutu_die_from_dwo): Likewise.
14879 (init_cutu_and_read_dies): Likewise.
14880 (init_cutu_and_read_dies_no_follow): Likewise.
14881 (process_psymtab_comp_unit_reader): Likewise.
14882 (partial_die_parent_scope): Likewise.
14883 (peek_die_abbrev): Likewise.
14884 (process_queue): Likewise.
14885 (dwarf2_physname): Likewise.
14886 (read_namespace_alias): Likewise.
14887 (read_import_statement): Likewise.
14888 (create_dwo_cu_reader): Likewise.
14889 (create_cus_hash_table): Likewise.
14890 (lookup_dwo_cutu): Likewise.
14891 (inherit_abstract_dies): Likewise.
14892 (read_func_scope): Likewise.
14893 (read_call_site_scope): Likewise.
14894 (dwarf2_add_member_fn): Likewise.
14895 (read_common_block): Likewise.
14896 (read_module_type): Likewise.
14897 (read_typedef): Likewise.
14898 (read_subrange_type): Likewise.
14899 (load_partial_dies): Likewise.
14900 (read_partial_die): Likewise.
14901 (find_partial_die): Likewise.
14902 (read_str_index): Likewise.
14903 (dwarf2_string_attr): Likewise.
14904 (build_error_marker_type): Likewise.
14905 (lookup_die_type): Likewise.
14906 (dump_die_shallow): Likewise.
14907 (follow_die_ref): Likewise.
14908 (dwarf2_fetch_die_loc_sect_off): Likewise.
14909 (dwarf2_fetch_constant_bytes): Likewise.
14910 (follow_die_sig): Likewise.
14911 (get_signatured_type): Likewise.
14912 (get_DW_AT_signature_type): Likewise.
14913 (dwarf2_find_containing_comp_unit): Likewise.
14914 (set_die_type): Likewise.
14916 2018-02-21 John Baldwin <jhb@FreeBSD.org>
14918 * arch/aarch64.c: Include "common-defs.h".
14919 * arch/amd64.c: Likewise.
14920 * arch/i386.c: Likewise.
14922 2018-02-21 Tom Tromey <tom@tromey.com>
14924 * value.h: (extract_field_op): Update.
14925 * eval.c (extract_field_op): Return a const char *.
14926 * expression.h (parse_expression_for_completion): Update.
14927 * completer.c (complete_expression): Update.
14928 (add_struct_fields): Make fieldname const.
14929 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
14930 (mark_completion_tag, parse_exp_in_context_1): Update.
14931 (parse_expression_for_completion): Change "name" to
14932 unique_xmalloc_ptr*.
14934 2018-02-21 Tom Tromey <tom@tromey.com>
14936 * infcall.c (call_function_by_hand_dummy): Use std::vector.
14938 2018-02-21 Yao Qi <yao.qi@linaro.org>
14940 * avr-tdep.c (avr_read_pc): Change parameter type to
14942 * gdbarch.sh (read_pc): Likewise.
14943 * gdbarch.c: Re-generated.
14944 * gdbarch.h: Re-generated.
14945 * hppa-tdep.c (hppa_read_pc): Change parameter type to
14947 * ia64-tdep.c (ia64_read_pc): Likewise.
14948 * mips-tdep.c (mips_read_pc): Likewise.
14949 * spu-tdep.c (spu_read_pc): Likewise.
14951 2018-02-21 Yao Qi <yao.qi@linaro.org>
14953 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
14954 * regcache-dump.c: New file.
14955 * regcache.c: Move register_dump to regcache-dump.c.
14956 (maintenance_print_registers): Likewise.
14957 (maintenance_print_raw_registers): Likewise.
14958 (maintenance_print_cooked_registers): Likewise.
14959 (maintenance_print_register_groups): Likewise.
14960 (maintenance_print_remote_registers): Likewise.
14961 (_initialize_regcache): Likewise.
14962 * regcache.h (register_dump): Moved from regcache.c.
14964 2018-02-21 Yao Qi <yao.qi@linaro.org>
14966 * regcache.c (regcache::regcache): Update.
14967 (regcache::invalidate): Move it to detached_regcache::invalidate.
14968 (get_thread_arch_aspace_regcache): Update.
14969 (regcache::raw_update): Update.
14970 (regcache::cooked_read): Remove some code.
14971 (regcache::cooked_read_value): Likewise.
14972 (regcache::raw_write): Remove assert on m_readonly_p.
14973 (regcache::raw_supply_integer): Move it to
14974 detached_regcache::raw_supply_integer.
14975 (regcache::raw_supply_zeroed): Likewise.
14976 * regcache.h (detached_regcache) <raw_supply_integer>: New
14978 <raw_supply_zeroed, invalidate>: Likewise.
14979 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
14980 <invalidate>: Likewise.
14981 <m_readonly_p>: Removed.
14983 2018-02-21 Yao Qi <yao.qi@linaro.org>
14985 * infcmd.c (get_return_value): Let stop_regs point to
14986 get_current_regcache.
14987 * regcache.c (regcache::regcache): Remove.
14988 (register_dump_reg_buffer): New class.
14989 (regcache_print): Adjust.
14990 * regcache.h (regcache): Remove constructors.
14992 2018-02-21 Yao Qi <yao.qi@linaro.org>
14994 * regcache.c (class register_dump): New class.
14995 (register_dump_regcache, register_dump_none): New class.
14996 (register_dump_remote, register_dump_groups): New class.
14997 (regcache_print): Update.
14998 * regcache.h (regcache_dump_what): Move it to regcache.c.
14999 (regcache) <dump>: Remove.
15001 2018-02-21 Yao Qi <yao.qi@linaro.org>
15003 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
15005 (jit_unwind_reg_set_impl): Call raw_supply.
15006 (jit_frame_sniffer): Use reg_buffer_rw.
15007 * record-full.c (record_full_core_regbuf): Change its type.
15008 (record_full_core_open_1): Use reg_buffer_rw.
15009 (record_full_close): Likewise.
15010 (record_full_core_fetch_registers): Use regcache->raw_supply.
15011 (record_full_core_store_registers): Likewise.
15012 * regcache.c (regcache::get_register_status): Move it to
15014 (regcache_raw_set_cached_value): Remove.
15015 (regcache::raw_set_cached_value): Remove.
15016 (regcache::raw_write): Call raw_supply.
15017 (regcache::raw_supply): Move it to reg_buffer_rw.
15018 * regcache.h (regcache_raw_set_cached_value): Remove.
15019 (reg_buffer_rw): New class.
15021 2018-02-21 Yao Qi <yao.qi@linaro.org>
15023 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
15024 readonly_detached_regcache.
15025 (dummy_frame_prev_register): Use regcache->cooked_read.
15026 * frame.c (frame_save_as_regcache): Change return type.
15027 (frame_pop): Update.
15028 * frame.h (frame_save_as_regcache): Update declaration.
15029 * inferior.h (get_infcall_suspend_state_regcache): Update
15031 * infrun.c (infcall_suspend_state) <registers>: use
15032 readonly_detached_regcache.
15033 (save_infcall_suspend_state): Don't use regcache_dup.
15034 (get_infcall_suspend_state_regcache): Change return type.
15035 * linux-fork.c (struct fork_info) <savedregs>: Change to
15036 readonly_detached_regcache.
15038 (fork_save_infrun_state): Don't use regcache_dup.
15039 (info_checkpoints_command): Adjust.
15040 * mi/mi-main.c (register_changed_p): Update declaration.
15041 (mi_cmd_data_list_changed_registers): Use
15042 readonly_detached_regcache.
15043 (register_changed_p): Change parameter type to
15044 readonly_detached_regcache.
15045 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
15046 readonly_detached_regcache.
15047 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
15048 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
15050 (regcache::save): Move it to reg_buffer.
15051 (regcache::restore): Change parameter type.
15052 (regcache_dup): Remove.
15053 * regcache.h (reg_buffer) <save>: New method.
15054 (readonly_detached_regcache): New class.
15055 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
15056 readonly_detached_regcache.
15057 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
15059 2018-02-21 Yao Qi <yao.qi@linaro.org>
15061 * frame.c (frame_save_as_regcache): Use regcache method save.
15062 (frame_pop): Use regcache method restore.
15063 * infrun.c (restore_infcall_suspend_state): Likewise.
15064 * linux-fork.c (fork_load_infrun_state): Likewise.
15065 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
15067 * regcache.c (regcache_save): Remove.
15068 (regcache::restore): More asserts.
15069 (regcache_cpy): Remove.
15070 * regcache.h (regcache_save): Remove the declaration.
15071 (regcache::restore): Move from private to public.
15072 Remove the friend declaration of regcache_cpy.
15073 (regcache_cpy): Remove declaration.
15075 2018-02-21 Yao Qi <yao.qi@linaro.org>
15077 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
15078 parameter type to 'readable_regcache *'.
15079 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15080 * arm-tdep.c (arm_neon_quad_read): Likewise.
15081 (arm_pseudo_read): Likewise.
15082 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15083 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15084 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15085 * gdbarch.c: Re-generated.
15086 * gdbarch.h: Re-generated.
15087 * gdbarch.sh (pseudo_register_read): Change parameter type to
15088 'readable_regcache *'.
15089 (pseudo_register_read_value): Likewise.
15090 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
15091 (h8300_pseudo_register_read): Likewise.
15092 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
15093 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15094 (i386_pseudo_register_read_into_value): Likewise.
15095 (i386_pseudo_register_read_value): Likewise.
15096 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
15098 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
15099 * m32c-tdep.c (m32c_raw_read): Likewise.
15100 (m32c_read_flg): Likewise.
15101 (m32c_banked_register): Likewise.
15102 (m32c_banked_read): Likewise.
15103 (m32c_sb_read): Likewise.
15104 (m32c_part_read): Likewise.
15105 (m32c_cat_read): Likewise.
15106 (m32c_r3r2r1r0_read): Likewise.
15107 (m32c_pseudo_register_read): Likewise.
15108 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15109 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15110 (mep_pseudo_cr64_read): Likewise.
15111 (mep_pseudo_register_read): Likewise.
15112 * mips-tdep.c (mips_pseudo_register_read): Likewise.
15113 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15114 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15115 * regcache.c (regcache::raw_read): Move it to readable_regcache.
15116 (regcache::cooked_read): Likewise.
15117 (regcache::cooked_read_value): Likewise.
15118 (regcache_cooked_read_signed):
15119 (regcache::cooked_read): Likewise.
15120 * regcache.h (readable_regcache): New class.
15121 (regcache): Inherit readable_regcache. Move some methods to
15123 * rl78-tdep.c (rl78_pseudo_register_read): Change
15124 parameter type to 'readable_regcache *'.
15125 * rs6000-tdep.c (do_regcache_raw_read): Remove.
15126 (e500_pseudo_register_read): Change parameter type to
15127 'readable_regcache *'.
15128 (dfp_pseudo_register_read): Likewise.
15129 (vsx_pseudo_register_read): Likewise.
15130 (efpr_pseudo_register_read): Likewise.
15131 * s390-tdep.c (s390_pseudo_register_read): Likewise.
15132 * sh-tdep.c (sh_pseudo_register_read): Likewise.
15133 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
15134 (sh64_pseudo_register_read): Likewise.
15135 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15136 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15137 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15138 (spu_pseudo_register_read): Likewise.
15139 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15140 (xtensa_pseudo_register_read): Likewise.
15142 2018-02-21 Yao Qi <yao.qi@linaro.org>
15144 * regcache.c (regcache::regcache): Call reg_buffer ctor.
15145 (regcache::arch): Move it to reg_buffer::arch.
15146 (regcache::register_buffer): Likewise.
15147 (regcache::assert_regnum): Likewise.
15148 (regcache::num_raw_registers): Likewise.
15149 * regcache.h (reg_buffer): New class.
15150 (regcache): Inherit reg_buffer.
15152 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
15154 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
15155 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
15157 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
15159 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
15161 2018-02-19 Alan Hayward <alan.hayward@arm.com>
15163 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
15164 (SFILES): Remove common/*.c files.
15165 (COMMON_OBS): Remove some *.o files built from common/*.c files.
15166 * common/common.host: Add common reference.
15167 * configure.ac: Likewise.
15168 * configure: Regenerate.
15170 2018-02-16 Yao Qi <yao.qi@linaro.org>
15172 * block.c (block_namespace_info): Inherit allocate_on_obstack.
15173 (block_initialize_namespace): Use new.
15174 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
15175 (dwarf2_free_objfile): Use delete.
15176 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
15177 (copy_type_recursive): Use new.
15178 * gdb_obstack.h (allocate_on_obstack): New.
15180 2018-02-15 Yao Qi <yao.qi@linaro.org>
15183 * inferior.c (exit_inferior_1): Reset inf->control.
15185 2018-02-15 Joel Brobecker <brobecker@adacore.com>
15187 * ada-lang.c (ada_to_fixed_value_create): Delete advance
15190 2018-02-14 Pedro Alves <palves@redhat.com>
15192 * frame-unwind.c (frame_unwind_try_unwinder): Always call
15193 frame_cleanup_after_sniffer on exception.
15195 2018-02-14 Tom Tromey <tom@tromey.com>
15197 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
15199 (solib_bfd_open): Make pathname const.
15200 * solib.c (solib_bfd_open): Make pathname const.
15201 * solib-spu.c (spu_bfd_fopen): Make name const.
15202 (spu_bfd_open): Make pathname const.
15203 * solib-darwin.c (darwin_bfd_open): Make pathname const.
15204 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
15206 2018-02-14 Tom Tromey <tom@tromey.com>
15208 * symfile.c (symfile_bfd_open): Update.
15209 * source.h (openp, source_full_path_of, find_and_open_source):
15210 Change argument type to unique_xmalloc_ptr.
15211 * source.c (openp): Take a unique_xmalloc_ptr.
15212 (source_full_path_of, find_and_open_source): Likewise.
15213 (open_source_file, symtab_to_fullname): Update.
15214 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
15215 unique_xmalloc_ptr.
15216 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
15217 (exec_file_find): Update.
15218 * psymtab.c (psymtab_to_fullname): Update.
15219 * nto-tdep.h (nto_find_and_open_solib): Update.
15220 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
15221 unique_xmalloc_ptr.
15222 * exec.c (exec_file_attach): Update.
15223 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
15224 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
15226 2018-02-14 Tom Tromey <tom@tromey.com>
15228 * solib.c: Include source.h.
15229 * nto-tdep.c: Include source.h.
15230 * mi/mi-cmd-env.c: Include source.h.
15231 * infcmd.c: Include source.h.
15232 * exec.c: Include source.h.
15233 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
15234 (add_path, directory_switch, source_path, init_source_path): Move
15236 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
15237 (add_path, directory_switch, source_path, init_source_path):
15240 2018-02-14 Tom Tromey <tom@tromey.com>
15242 * solist.h (exec_file_find, solib_find): Return
15243 unique_xmalloc_ptr.
15244 (solib_bfd_fopen): Take a const char *.
15245 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
15246 (exec_file_find, solib_find): Likewise.
15247 (solib_bfd_fopen): Do not take ownership of "pathname".
15248 (solib_bfd_open): Use unique_xmalloc_ptr.
15249 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
15250 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
15251 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
15252 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
15254 2018-02-14 Joel Brobecker <brobecker@adacore.com>
15256 * ada-lang.c (name_match_type_from_name): Remove reference to
15257 ada_name_for_lookup in function's documentation.
15258 * ada-lang.h (ada_name_for_lookup): Delete declaration.
15260 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
15262 * defs.h (enum openp_flags): New enum.
15263 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
15264 Move to enum openp_flags.
15265 (openp_flags): New enum flags.
15266 (openp): Change parameter type to openp_flags.
15267 * source.c (openp): Change parameter type to openp_flags.
15268 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
15269 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
15271 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
15273 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
15276 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
15278 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
15280 (class dwarf2_queue_guard): ...the destructor of this new class.
15281 (dw2_do_instantiate_symtab): Create instance of the new class
15282 dwarf2_queue_guard, remove cleanup.
15284 2018-02-09 Tom Tromey <tom@tromey.com>
15286 * source.c (find_source_lines): Don't reference past the end of
15289 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15291 * remote.c (remote_btrace_maybe_reopen): Change error message.
15292 * btrace.c (btrace_enable): Likewise.
15293 (parse_xml_btrace): Likewise.
15294 (parse_xml_btrace_conf): Likewise.
15296 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15298 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
15299 (linux_enable_pt, linux_enable_bts): Call
15300 diagnose_perf_event_open_fail.
15302 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15304 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
15305 Remove parameter and change return type. Update callers. Move it.
15306 (linux_enable_bts, linux_enable_pt): Improve error message.
15307 (linux_enable_pt): Remove zero buffer size check.
15308 (linux_enable_btrace): Improve error messages. Remove NULL return
15311 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15313 * btrace.c (btrace_enable): Remove target_supports_btrace call.
15314 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
15315 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
15316 (linux_supports_pt, linux_supports_btrace): Remove.
15317 (linux_enable_bts): Call cpu_supports_bts.
15318 * nat/linux-btrace.h (linux_supports_btrace): Remove.
15319 * remote.c (remote_supports_btrace): Remove.
15320 (init_remote_ops): Remove remote_supports_btrace.
15321 * target-delegates.c: Regenerated.
15322 * target.c (target_supports_btrace): Remove.
15323 * target.h (target_ops) <to_supports_btrace>: Remove
15324 (target_supports_btrace): Remove.
15325 * x86-linux-nat.c (x86_linux_create_target): Remove
15326 linux_supports_btrace.
15328 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15330 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
15332 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
15333 exception and use message in own exception.
15335 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15337 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
15338 (perf_event_pt_event_type): Use gdb_file_up.
15339 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
15340 scoped_fd, and scoped_mmap.
15342 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15344 * common/scoped_mmap.h: New.
15345 * unittests/scoped_mmap-selftest.c: New.
15346 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15347 unittests/scoped_mmap-selftest.c.
15349 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15351 * common/scoped_fd.h: New.
15352 * unittests/scoped_fd-selftest.c: New.
15353 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15354 unittests/scoped_fd-selftest.c.
15356 2018-02-09 Tom Tromey <tom@tromey.com>
15358 * auto-load.c (auto_load_section_scripts): Use
15359 gdb::unique_xmalloc_ptr.
15361 2018-02-09 Tom Tromey <tom@tromey.com>
15363 * auto-load.c (execute_script_contents): Use std::string.
15365 2018-02-09 Joel Brobecker <brobecker@adacore.com>
15367 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
15368 Python function, rather than a new command.
15370 2018-02-08 Tom Tromey <tom@tromey.com>
15372 * solib.c (solib_find_1): Use std::string.
15373 (solib_bfd_fopen): Use unique_xmalloc_ptr.
15375 2018-02-08 Tom Tromey <tom@tromey.com>
15377 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
15379 2018-02-08 Tom Tromey <tom@tromey.com>
15381 * source.c (find_source_lines): Use gdb::def_vector.
15383 2018-02-08 Tom Tromey <tom@tromey.com>
15385 * macrocmd.c (struct temporary_macro_definition): New.
15386 (macro_define_command): Use temporary_macro_definition. Remove
15388 (free_macro_definition_ptr): Remove.
15390 2018-02-08 Tom Tromey <tom@tromey.com>
15392 * macroexp.c (maybe_expand): Use std::string.
15394 2018-02-08 Tom Tromey <tom@tromey.com>
15396 * macroexp.c (struct macro_buffer): Add initializers for some
15398 (init_buffer, init_shared_buffer, free_buffer)
15399 (free_buffer_return_text): Remove.
15400 (macro_buffer): New constructors.
15401 (~macro_buffer): New destructor.
15402 (macro_buffer::set_shared): New method.
15403 (macro_buffer::resize_buffer, macro_buffer::appendc)
15404 (macro_buffer::appendmem): Now methods, not free functions.
15405 (set_token, append_tokens_without_splicing, stringify)
15406 (macro_stringify): Update.
15407 (gather_arguments): Change return type. Remove argc_p argument,
15408 add args_ptr argument. Use std::vector.
15409 (substitute_args): Remove argc argument. Accept std::vector.
15410 (expand): Update. Use std::vector.
15411 (scan, macro_expand, macro_expand_next): Update.
15413 2018-02-08 Tom Tromey <tom@tromey.com>
15415 * symtab.c (default_collect_symbol_completion_matches_break_on):
15416 Use unique_xmalloc_ptr.
15417 * macroscope.h: (sal_macro_scope, user_macro_scope)
15418 (default_macro_scope): Return unique_xmalloc_ptr.
15419 * macroscope.c (sal_macro_scope, user_macro_scope)
15420 (default_macro_scope): Return unique_xmalloc_ptr.
15421 * macroexp.h (macro_expand, macro_expand_once): Return
15422 unique_xmalloc_ptr.
15423 * macroexp.c (macro_expand, macro_expand_once): Return
15424 unique_xmalloc_ptr.
15425 * macrocmd.c (macro_expand_command, macro_expand_once_command)
15426 (info_macro_command, info_macros_command): Use
15427 unique_xmalloc_ptr.
15428 * compile/compile-c-support.c (write_macro_definitions): Use
15429 unique_xmalloc_ptr.
15430 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
15432 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
15434 * value.c (value_static_field): Assign field type instead of
15435 containing type when returning an optimized out value.
15437 2018-02-06 Yao Qi <yao.qi@linaro.org>
15439 * ft32-tdep.c (ft32_read_pc): Remove.
15440 (ft32_write_pc): Remove.
15441 (ft32_gdbarch_init): Update.
15442 * m32r-tdep.c (m32r_read_pc): Remove.
15443 (m32r_gdbarch_init): Update.
15444 * mep-tdep.c (mep_read_pc): Remove.
15445 (mep_gdbarch_init): Update.
15446 * microblaze-tdep.c (microblaze_write_pc): Remove.
15447 (microblaze_gdbarch_init): Update.
15448 * mn10300-tdep.c (mn10300_read_pc): Remove.
15449 (mn10300_write_pc): Remove.
15450 (mn10300_gdbarch_init): Update.
15451 * moxie-tdep.c (moxie_read_pc): Remove.
15452 (moxie_write_pc): Remove.
15453 (moxie_gdbarch_init): Update.
15455 2018-02-06 Yao Qi <yao.qi@linaro.org>
15457 * expprint.c (print_subexp_standard): Handle
15458 OP_F77_UNDETERMINED_ARGLIST.
15459 (dump_subexp_body_standard): Likewise.
15461 2018-02-05 Alan Hayward <alan.hayward@arm.com>
15463 * target-descriptions.c (tdesc_element_visitor) Add empty
15465 (tdesc_type): Move make_gdb_type from here.
15466 (tdesc_type_builtin): Likewise.
15467 (tdesc_type_vector): Likewise.
15468 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
15469 (make_gdb_type_struct): Move from tdesc_type_with_fields.
15470 (make_gdb_type_union): Likewise.
15471 (make_gdb_type_flags): Likewise.
15472 (make_gdb_type_enum): Likewise.
15473 (make_gdb_type): New function.
15474 (tdesc_register_type): Use static make_gdb_type.
15476 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
15478 * infcmd.c (default_print_one_register_info): Align natural-format
15479 column values consistently one under another.
15480 (pad_to_column): New function.
15482 2018-02-05 Joel Brobecker <brobecker@adacore.com>
15484 * dwarf2read.c (dwarf2_physname): Move commment.
15486 2018-02-01 Leszek Swirski <leszeks@google.com>
15488 * varobj.c (varobj_formatted_print_options): Allow recursive
15489 pretty printing if pretty printing is enabled.
15491 2018-02-01 Leszek Swirski <leszeks@google.com>
15493 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
15494 names after a structop as a filename.
15496 2018-02-01 Yao Qi <yao.qi@linaro.org>
15498 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
15499 (arm_record_coproc_data_proc): Likewise.
15501 2018-02-01 Yao Qi <yao.qi@linaro.org>
15503 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
15505 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
15507 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
15508 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
15510 2018-01-31 Pedro Alves <palves@redhat.com>
15512 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
15513 * inflow.c (child_terminal_save_inferior): Wrap reference to
15514 tcgetpgrp in HAVE_TERMIOS_H.
15515 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
15517 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
15518 always iterate over all inferiors.
15519 (gdbsim_cntrl_c): Adjust.
15520 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
15522 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15524 * gdbtypes.c (lookup_array_range_type): Make sure the array's
15525 index type is objfile-owned if the element type is as well.
15527 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15531 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
15533 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
15534 "features/s390x-linux64.c".
15535 (_initialize_s390_linux_tdep): Remove initialization of tdescs
15536 s390_linux32 and s390x_linux64.
15537 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
15539 * s390-tdep.c: Include "features/s390-linux32.c" and
15540 "features/s390x-linux64.c".
15541 (s390_tdesc_valid): Add check for tdesc_has_registers.
15542 (s390_gdbarch_init): Make sure there is always a valid tdesc.
15543 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
15544 tdesc_s390x_linux64.
15545 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
15546 tdesc_s390x_linux64 to...
15547 * s390-tdep.h: ...here.
15549 2018-01-30 Pedro Alves <palves@redhat.com>
15552 * config.in, configure: Regenerate.
15553 * configure.ac: Check for getpgid.
15554 * go32-nat.c (go32_pass_ctrlc): New.
15555 (go32_target): Install it.
15556 * inf-child.c (inf_child_target): Install
15557 child_terminal_save_inferior, child_pass_ctrlc and
15559 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
15560 (inf_ptrace_target): No longer install it.
15561 * infcmd.c (interrupt_target_1): Adjust.
15562 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
15563 (child_interrupt): Declare.
15564 (inferior::terminal_state): New.
15565 * inflow.c (struct terminal_info): Update comments.
15566 (inferior_process_group): Delete.
15567 (terminal_is_ours): Delete.
15568 (gdb_tty_state): New.
15569 (child_terminal_init): Adjust.
15570 (is_gdb_terminal, sharing_input_terminal_1)
15571 (sharing_input_terminal): New functions.
15572 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
15573 Set the process's actual process group in the foreground if
15574 possible. Handle is_ours_for_output/is_ours distinction. Don't
15575 mark terminal as the inferior's if not sharing GDB's terminal.
15576 Don't check attach_flag.
15577 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
15578 pass down a target_terminal_state.
15579 (child_terminal_save_inferior): New, factored out from ...
15580 (child_terminal_ours_1): ... this. Handle
15581 target_terminal_state::is_ours_for_output.
15582 (child_interrupt, child_pass_ctrlc): New.
15583 (inflow_inferior_exit): Clear the inferior's terminal_state.
15584 (copy_terminal_info): Copy the inferior's terminal state.
15585 (_initialize_inflow): Remove reference to terminal_is_ours.
15586 * inflow.h (inferior_process_group): Delete.
15587 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
15588 * procfs.c (procfs_target): Don't install procfs_interrupt.
15589 (procfs_interrupt): Delete.
15590 * remote.c (remote_serial_quit_handler): Adjust.
15591 (remote_interrupt): Remove ptid parameter. Adjust.
15592 * target-delegates.c: Regenerate.
15593 * target.c: Include "terminal.h".
15594 (target_terminal::terminal_state): Rename to ...
15595 (target_terminal::m_terminal_state): ... this.
15596 (target_terminal::init): Adjust.
15597 (target_terminal::inferior): Adjust to per-inferior
15599 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
15600 (target_terminal::ours, target_terminal::ours_for_output): Use
15601 target_terminal_is_ours_kind.
15602 (target_interrupt): Remove ptid parameter. Adjust.
15603 (default_target_pass_ctrlc): Adjust.
15604 * target.h (target_ops::to_terminal_save_inferior): New field.
15605 (target_ops::to_interrupt): Remove ptid_t parameter.
15606 (target_interrupt): Remove ptid_t parameter. Update comment.
15607 (target_pass_ctrlc): Update comment.
15608 * target/target.h (target_terminal_state): New scoped enum,
15609 factored out of ...
15610 (target_terminal::terminal_state): ... here.
15611 (target_terminal::inferior): Update comments.
15612 (target_terminal::restore_inferior): New.
15613 (target_terminal::is_inferior, target_terminal::is_ours)
15614 (target_terminal::is_ours_for_output): Adjust.
15615 (target_terminal::scoped_restore_terminal_state): Adjust to
15616 rename, and call restore_inferior() instead of inferior().
15617 (target_terminal::scoped_restore_terminal_state::m_state): Change
15619 (target_terminal::terminal_state): Rename to ...
15620 (target_terminal::m_terminal_state): ... this and change type.
15622 2018-01-30 Pedro Alves <palves@redhat.com>
15624 * linux-nat.c (wait_for_signal): New function.
15625 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
15627 (async_terminal_is_ours)
15628 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
15629 (linux_nat_add_target): Don't override
15630 to_terminal_inferior/to_terminal_ours.
15632 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
15634 * remote.c (remote_follow_fork): Don't call "detach_inferior".
15636 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
15638 * dwarf2read.c (free_dwo_files): Add forward-declaration.
15639 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
15640 dwarf2_per_objfile_free here.
15641 (dwarf2_per_objfile_free): Remove.
15642 (_initialize_dwarf2_read): Don't register
15643 dwarf2_per_objfile_free as a registry cleanup.
15645 2018-01-27 Eli Zaretskii <eliz@gnu.org>
15647 Avoid compilation errors in MinGW native builds
15649 The error is triggered by including python-internal.h, and the
15652 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
15653 from build-gnulib/import/math.h:27,
15654 from d:/usr/Python26/include/pyport.h:235,
15655 from d:/usr/Python26/include/Python.h:58,
15656 from python/python-internal.h:94,
15657 from python/py-arch.c:24:
15658 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
15662 This happens because Python headers define 'hypot' to expand t
15663 '_hypot' in the Windows builds.
15664 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
15665 'hypoth'. This avoids a compilation error.
15667 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15669 * MAINTAINERS (Write After Approval): Fix ordering.
15671 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15673 * MAINTAINERS (Write After Approval): Add Alan Hayward.
15675 2018-01-26 Alan Modra <amodra@gmail.com>
15677 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
15678 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
15679 Remove nop. Make const. Comment.
15680 (powerpc32_plt_stub_so_2): New.
15681 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
15682 Correct count. Update uses.
15683 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
15684 Move common code reading PLT entry word. Correct
15685 powerpc32_plt_stub PLT address calculation.
15686 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
15687 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
15688 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
15689 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
15690 (ppc64_standard_linkage8): Likewise.
15691 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
15692 Correct insns description.
15693 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
15695 2018-01-24 Pedro Alves <palves@redhat.com>
15697 GCC PR libstdc++/83906
15698 * gdbtypes.c (operator==(const dynamic_prop &,
15699 const dynamic_prop &)): New.
15700 (operator==(const range_bounds &, const range_bounds &)): New.
15701 (check_types_equal): Use them instead of memcmp.
15702 * gdbtypes.h (operator==(const dynamic_prop &,
15703 const dynamic_prop &)): Declare.
15704 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
15705 (operator==(const range_bounds &, const range_bounds &)): Declare.
15706 (operator!=(const range_bounds &, const range_bounds &)): Declare.
15708 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15710 * s390-linux-tdep.c (s390_record_address_mask)
15711 (s390_record_calc_disp_common, s390_record_calc_disp)
15712 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15713 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15714 (s390_process_record): Move to s390-tdep.c.
15715 (s390_linux_init_abi_any): Adjust.
15716 * s390-tdep.c (s390_record_address_mask)
15717 (s390_record_calc_disp_common, s390_record_calc_disp)
15718 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15719 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15720 (s390_process_record): Moved from s390-linux-tdep.c
15721 (s390_gdbarch_init): Adjust.
15723 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15725 * s390-linux-nat.c (s390-tdep.h): New include.
15726 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
15727 (HFILES_NO_SRCDIR): Add s390-tdep.h.
15728 (ALLDEPFILES): Add s390-tdep.c.
15729 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
15730 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
15731 * s390-tdep.h: ...this. New file.
15732 * s390-linux-tdep.c (s390-tdep.h): New include.
15733 (_initialize_s390_tdep): Rename to...
15734 (_initialize_s390_linux_tdep): ...this and adjust.
15735 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
15736 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
15738 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
15739 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
15740 (s390_is_partial_instruction, s390_software_single_step)
15741 (is_non_branch_ril, s390_displaced_step_copy_insn)
15742 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
15743 (s390_prologue_data, s390_addr, s390_store, s390_load)
15744 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
15745 (s390_register_call_saved, s390_guess_tracepoint_registers)
15746 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
15747 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
15748 (s390_pseudo_register_name, s390_pseudo_register_type)
15749 (s390_pseudo_register_read, s390_pseudo_register_write)
15750 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
15751 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
15752 (s390_addr_bits_remove, s390_address_class_type_flags)
15753 (s390_address_class_type_flags_to_name)
15754 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
15755 (s390_function_arg_float, s390_function_arg_vector)
15756 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
15757 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
15758 (s390_frame_align, s390_register_return_value, s390_return_value)
15759 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
15760 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
15761 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
15762 (s390_trad_frame_prev_register, s390_unwind_cache)
15763 (s390_prologue_frame_unwind_cache)
15764 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
15765 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
15766 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
15767 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
15768 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
15769 (s390_frame_base_address, s390_local_base_address)
15770 (s390_frame_base, s390_gcc_target_options)
15771 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
15772 (s390_validate_reg_range, s390_tdesc_valid)
15773 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
15774 * s390-tdep.c: ...this. New file.
15776 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15778 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
15779 (s390_process_record, s390_gdbarch_tdep_alloc)
15780 (s390_linux_init_abi_any): Use/set new hook.
15782 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15784 * s390-linux-tdep.c (osabi.h): New include.
15785 (s390_linux_init_abi_31, s390_linux_init_abi_64)
15786 (s390_linux_init_abi_any): New functions.
15787 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
15789 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15791 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
15792 tdesc_has_registers check
15794 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15796 * s390-linux-tdep.c (s390_tdesc_valid): New function.
15797 (s390_validate_reg_range): New macro.
15798 (s390_gdbarch_init): Adjust.
15800 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15802 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
15803 (s390_gdbarch_tdep_alloc): Adjust.
15804 (s390_gdbarch_init): Adjust.
15806 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15808 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
15809 <have_tdb>: Change type to bool.
15810 (s390_gdbarch_tdep_alloc): Adjust.
15811 (s390_gdbarch_init): Adjust.
15813 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15815 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
15816 (gdbarch_tdep) <have_upper, have_vx>: New fields.
15817 (s390_gdbarch_tdep_alloc): New function.
15818 (s390_gdbarch_init): Allocate tdep at start and use its fields
15819 instead of separate variables.
15821 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15823 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
15824 when looking for cached gdbarch and add comment for remaining.
15826 2018-01-22 Pedro Alves <palves@redhat.com>
15827 Sergio Durigan Junior <sergiodj@redhat.com>
15829 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
15832 2018-01-22 Maciej W. Rozycki <macro@mips.com>
15834 * MAINTAINERS: Update my company e-mail address.
15836 2018-01-22 Yao Qi <yao.qi@linaro.org>
15838 * regcache.c (cooked_write_test): New function.
15839 (_initialize_regcache): Register the test.
15841 2018-01-22 Yao Qi <yao.qi@linaro.org>
15843 * ia64-tdep.c (ia64_pseudo_register_read): Call
15844 regcache->cooked_read instead of regcache_cooked_read_unsigned.
15845 * m32c-tdep.c (m32c_cat_read): Likewise.
15846 (m32c_r3r2r1r0_read): Likewise.
15847 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15848 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15850 2018-01-22 Yao Qi <yao.qi@linaro.org>
15852 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
15853 method raw_read instead of regcache_raw_read.
15854 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15855 * arm-tdep.c (arm_neon_quad_read): Likewise.
15856 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15857 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15858 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15859 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
15860 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15861 (i386_pseudo_register_read_into_value): Likewise.
15862 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15863 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15864 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15865 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
15866 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
15867 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15868 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15869 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15870 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
15872 2018-01-22 Yao Qi <yao.qi@linaro.org>
15874 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
15875 * configure.tgt: Remove target mt.
15876 * mt-tdep.c: Remove.
15877 * regcache.c (cooked_read_test): Remove the check for mt.
15879 2018-01-22 Yao Qi <yao.qi@linaro.org>
15881 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
15882 instead of gdbarch_pseudo_register_read_value.
15884 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15886 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
15889 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15891 * linespec.c (create_sals_line_offset): Remove code that preserved
15892 the symtab_and_line's line number.
15894 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15896 * varobj.c (varobj_create): Don't set valid_block when creating a
15899 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15901 * varobj.c (varobj_create): Remove out of date comment.
15903 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15906 * ada-exp.y (write_var_from_sym): Pass extra parameter when
15907 updating innermost block.
15908 * parse.c (innermost_block_tracker::update): Take extra type
15909 parameter, and check types match before updating innermost block.
15910 (write_dollar_variable): Update innermost block for registers.
15911 * parser-defs.h (enum innermost_block_tracker_type): New enum.
15912 (innermost_block_tracker::innermost_block_tracker): Initialise
15914 (innermost_block_tracker::reset): Take type parameter.
15915 (innermost_block_tracker::update): Take type parameter, and pass
15916 type through as needed.
15917 (innermost_block_tracker::m_types): New member.
15918 * varobj.c (varobj_create): Pass type when reseting innermost
15921 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15923 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
15924 * ada-lang.c (resolve_subexp): Likewise.
15925 * breakpoint.c (set_breakpoint_condition) Likewise.
15926 (watch_command_1) Likewise.
15927 * c-exp.y (variable): Likewise.
15928 * d-exp.y (PrimaryExpression): Likewise.
15929 * f-exp.y (variable): Likewise.
15930 * go-exp.y (variable): Likewise.
15931 * m2-exp.y (variable): Likewise.
15932 * objfiles.c (objfile::~objfile): Likewise.
15933 * p-exp.y (variable): Likewise.
15934 * parse.c (innermost_block): Change type.
15935 * parser-defs.h (class innermost_block_tracker): New.
15936 (innermost_block): Change to innermost_block_tracker.
15937 * printcmd.c (display_command): Switch to innermost_block API.
15938 (do_one_display): Likewise.
15939 * rust-exp.y (do_one_display): Likewise.
15940 * symfile.c (clear_symtab_users): Likewise.
15941 * varobj.c (varobj_create): Switch to innermost_block API, replace
15942 use of innermost_block with block stored on varobj object.
15944 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15946 * expression.h (innermost_block): Remove declaration.
15947 * varobj.c: Add 'parser-defs.h' include.
15949 2018-01-19 Tom Tromey <tom@tromey.com>
15951 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
15952 symbols in the static and global blocks.
15954 2018-01-19 James Clarke <jrtc27@jrtc27.com>
15956 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
15957 gdb_ptrace.h, and move including gdb_wait.h ...
15958 * nat/linux-ptrace.h: ... to here.
15960 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15962 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
15963 inf_ptrace_detach_success.
15964 (inf_ptrace_detach_success): Add inferior parameter, use it
15965 instead of inferior_ptid, pass it to detach_inferior.
15966 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
15968 * inferior.c (detach_inferior): Add overload that takes an
15970 * inferior.h (detach_inferior): Likewise.
15971 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
15972 use inferior_ptid, adjust call to inf_ptrace_detach_success.
15973 * linux-thread-db.c (thread_db_detach): Use inf parameter.
15975 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15977 * target.h (struct target_ops) <to_detach>: Add inferior
15979 (target_detach): Likewise.
15980 * target.c (dispose_inferior): Pass inferior down.
15981 (target_detach): Pass inferior down. Assert that it is equal to
15982 the current inferior.
15983 * aix-thread.c (aix_thread_detach): Pass inferior down.
15984 * corefile.c (core_file_command): Pass current_inferior() down.
15985 * corelow.c (core_detach): Add inferior parameter.
15986 * darwin-nat.c (darwin_detach): Likewise.
15987 * gnu-nat.c (gnu_detach): Likewise.
15988 * inf-ptrace.c (inf_ptrace_detach): Likewise.
15989 * infcmd.c (detach_command): Pass current_inferior() down to
15991 * infrun.c (follow_fork_inferior): Pass parent_inf to
15993 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
15995 * linux-nat.c (linux_nat_detach): Add inferior parameter.
15996 * linux-thread-db.c (thread_db_detach): Likewise.
15997 * nto-procfs.c (procfs_detach): Likewise.
15998 * procfs.c (procfs_detach): Likewise.
15999 * record.c (record_detach): Likewise.
16000 * record.h (struct inferior): Forward-declare.
16001 (record_detach): Add inferior parameter.
16002 * remote-sim.c (gdbsim_detach): Likewise.
16003 * remote.c (remote_detach_1): Likewise.
16004 (remote_detach): Likewise.
16005 (extended_remote_detach): Likewise.
16006 * sol-thread.c (sol_thread_detach): Likewise.
16007 * target-debug.h (target_debug_print_inferior_p): New macro.
16008 * target-delegates.c: Re-generate.
16009 * top.c (kill_or_detach): Pass inferior down to target_detach.
16010 * windows-nat.c (windows_detach): Add inferior parameter.
16012 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
16014 * target.h (struct target_ops) <to_detach>: Remove args
16016 (target_detach): Likewise.
16017 * target.c (dispose_inferior): Adjust.
16018 (target_detach): Remove args parameter, adjust.
16019 * aix-thread.c (aix_thread_detach): Adjust.
16020 * corefile.c (core_file_command): Adjust.
16021 * corelow.c (core_detach): Adjust.
16022 * darwin-nat.c (darwin_detach): Adjust.
16023 * gnu-nat.c (gnu_detach): Adjust.
16024 * inf-ptrace.c (inf_ptrace_detach): Adjust.
16025 * infcmd.c (detach_command): Adjust
16026 * infrun.c (follow_fork_inferior): Adjust.
16027 (handle_vfork_child_exec_or_exit): Adjust.
16028 * linux-fork.c (linux_fork_detach): Remove args parameter.
16029 * linux-fork.h (linux_fork_detach): Likewise.
16030 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
16031 * linux-thread-db.c (thread_db_detach): Likewise.
16032 * nto-procfs.c (procfs_detach): Likewise.
16033 * procfs.c (procfs_detach): Likewise.
16034 (do_detach): Remove signo parameter.
16035 * record.c (record_detach): Remove args parameter.
16036 * record.h (record_detach): Likewise.
16037 * remote-sim.c (gdbsim_detach): Likewise.
16038 * remote.c (remote_detach_1): Likewise.
16039 (remote_detach): Likewise.
16040 (extended_remote_detach): Likewise.
16041 * sol-thread.c (sol_thread_detach): Likewise.
16042 * target-delegates.c: Re-generate.
16043 * top.c (struct qt_args) <args>: Remove field.
16044 (kill_or_detach): Don't pass args.
16045 (quit_force): Don't set args.
16046 * windows-nat.c (windows_detach): Remove args parameter.
16048 2018-01-19 Yao Qi <yao.qi@linaro.org>
16050 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
16051 (arm_linux_init_abi): Install it.
16053 2018-01-19 Yao Qi <yao.qi@linaro.org>
16055 * osabi.c (gdb_osabi_names): Extend the regexp for
16056 arm-linux-gnueabihf.
16058 2018-01-18 Yao Qi <yao.qi@linaro.org>
16060 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
16062 (abbrev_table::add_abbrev): Update.
16063 (abbrev_table::lookup_abbrev): Update.
16065 2018-01-18 Yao Qi <yao.qi@linaro.org>
16067 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
16069 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
16071 * compile/compile.c (compile_to_object): Convert "triplet_rx"
16074 2018-01-17 Tom Tromey <tom@tromey.com>
16076 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
16078 2018-01-17 Tom Tromey <tom@tromey.com>
16080 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
16081 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
16082 (create_array_type_with_stride): Update.
16083 * dwarf2read.c (set_die_type): Update.
16085 2018-01-17 Tom Tromey <tom@tromey.com>
16087 * dwarf2read.c (delayed_method_info): Remove typedef.
16088 (dwarf2_cu::method_info): Now a std::vector.
16089 (add_to_method_list): Update.
16090 (free_delayed_list): Remove.
16091 (compute_delayed_physnames): Update.
16092 (process_full_comp_unit, process_full_type_unit): Clear the method
16093 list. Remove cleanups.
16094 (psymtab_include_file_name): Add name_holder parameter. Use
16095 unique_xmalloc_ptr.
16096 (dwarf_decode_lines): Update.
16098 2018-01-17 Tom Tromey <tom@tromey.com>
16099 Simon Marchi <simon.marchi@ericsson.com>
16101 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
16102 (dwarf2_per_objfile::free_cached_comp_units)
16103 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
16104 (init_cutu_and_read_dies_no_follow): Update.
16105 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
16106 (dwarf2_cu::~dwarf2_cu): New.
16107 (free_heap_comp_unit, free_stack_comp_unit): Remove.
16108 (age_cached_comp_units, free_one_cached_comp_unit): Update.
16110 2018-01-17 Tom Tromey <tom@tromey.com>
16111 Simon Marchi <simon.marchi@ericsson.com>
16113 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
16114 (struct die_reader_specs) <abbrev_table>: New member.
16115 (struct abbrev_table): Add constructor.
16116 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
16117 <abbrev_obstack>: Now an auto_obstack.
16118 (abbrev_table_up): New typedef.
16119 (init_cu_die_reader): Add abbrev_table parameter.
16120 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
16121 Add result_dwo_abbrev_table.
16122 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
16123 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
16125 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
16127 (skip_children): Update.
16128 (abbrev_table::alloc_abbrev): Rename from
16129 abbrev_table_alloc_abbrev.
16130 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
16131 (abbrev_table::lookup_abbrev): Rename from
16132 abbrev_table_lookup_abbrev.
16133 (abbrev_table_read_table): Return abbrev_table_up.
16134 (abbrev_table_free, abbrev_table_free_cleanup)
16135 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
16136 (load_partial_dies): Update.
16138 2018-01-17 Tom Tromey <tom@tromey.com>
16140 * dwarf2read.c (dwarf2_compute_name): Update comment.
16141 (read_func_scope, read_variable): Update.
16142 (new_symbol): Remove.
16143 (new_symbol_full): Rename to new_symbol.
16145 2018-01-17 Mike Gulick <mgulick@mathworks.com>
16148 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
16149 a warning instead of throwing an error, set section size to 0 and return
16151 * gdb_bfd.h (gdb_bfd_map_section): Update description.
16153 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
16155 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
16157 (linux_ptrace_attach_fail_reason_string): Likewise.
16158 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
16160 (linux_ptrace_attach_fail_reason_string): Likewise.
16161 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
16163 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
16165 * linux-nat.c (linux_nat_attach): Remove xstrdup.
16167 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
16170 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
16171 checking for fs_base/gs_base fields in struct user_regs_struct.
16172 * configure: Regenerate.
16174 2018-01-17 Yao Qi <yao.qi@linaro.org>
16176 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
16178 (aarch64_linux_init_abi): Install it to gdbarch hook
16179 gcc_target_options.
16181 2018-01-15 Pedro Alves <palves@redhat.com>
16183 * common/signals-state-save-restore.c
16184 (save_original_signals_state): Fix typos.
16186 2017-01-12 Tom Tromey <tom@tromey.com>
16187 Sergio Durigan Junior <sergiodj@redhat.com>
16189 * Makefile.in (install-only): Install gdb-add-index.
16191 2018-01-12 John Baldwin <jhb@FreeBSD.org>
16193 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
16195 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
16197 * infrun.c (keep_going_pass_signal): Clear step-over info when
16198 insert_breakpoints fails.
16200 2018-01-11 Pedro Alves <palves@redhat.com>
16203 * infrun.c (resume): Rename to ...
16204 (resume_1): ... this.
16205 (resume): Reimplement as wrapper around resume_1.
16207 2018-01-11 Pedro Alves <palves@redhat.com>
16210 * remote.c (remote_parse_stop_reply): Default to the last-set
16211 general thread instead of to 'magic_null_ptid'.
16213 2018-01-10 Pedro Alves <palves@redhat.com>
16215 * language.h (language_get_symbol_name_matcher): Rename ...
16216 (get_symbol_name_matcher): ... this.
16217 * language.c (language_get_symbol_name_matcher): Ditto.
16218 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
16221 2018-01-10 Pedro Alves <palves@redhat.com>
16225 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
16226 Adjust to use language_get_symbol_name_matcher instead of
16227 language_defn::la_get_symbol_name_matcher.
16228 * language.c (language_get_symbol_name_matcher): If in Ada mode
16229 and the lookup name is a verbatim match, return Ada's matcher.
16230 * language.h (language_get_symbol_name_matcher): Adjust comment.
16231 (ada_lookup_name_info::verbatim_p):: New method.
16233 2018-01-10 Pedro Alves <palves@redhat.com>
16236 * ada-lang.c (ada_collect_symbol_completion_matches): If the
16237 minsym's language is language_auto or language_cplus, pass down
16238 language_ada instead.
16239 * symtab.c (compare_symbol_name): Don't frob symbol language here.
16241 2018-01-10 Pedro Alves <palves@redhat.com>
16244 * minsyms.c (linkage_name_str): New function.
16245 (iterate_over_minimal_symbols): Use it.
16247 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16249 * NEWS: Document that 'info proc' now works on FreeBSD.
16251 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16253 * configure.ac: Check for kinfo_getfile in libutil.
16254 * configure: Regenerate.
16255 * config.in: Regenerate.
16256 * fbsd-nat.c: Include "fbsd-tdep.h".
16257 (fbsd_fetch_cmdline): New.
16258 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
16259 rather than calling error.
16260 (fbsd_info_proc): New.
16261 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
16262 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
16263 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
16265 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16267 * fbsd-nat.c (struct free_deleter): Remove.
16268 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
16270 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16272 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
16273 NULL for an empty pathname.
16275 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16277 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
16278 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
16279 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
16280 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
16281 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
16282 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
16283 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
16284 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
16285 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
16286 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
16287 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
16288 (fbsd_core_fetch_timeval, fbsd_print_sigset)
16289 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
16290 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
16291 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
16293 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
16295 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
16296 (gnu_xfer_auxv): New function.
16297 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
16298 TARGET_OBJECT_AUXV.
16300 2018-01-08 Yao Qi <yao.qi@linaro.org>
16301 Simon Marchi <simon.marchi@ericsson.com>
16303 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
16305 (COMMON_OBS): Remove selftest.o.
16306 * configure.ac: Append selftest-arch.c and common/selftest.c to
16307 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
16308 * configure: Re-generated.
16309 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
16311 (maintenance_info_selftests): Likewise.
16313 2018-01-08 Xavier Roirand <roirand@adacore.com>
16315 * ada-valprint.c (val_print_packed_array_elements): Use
16316 proper number of elements when printing an array indexed
16317 by an enumeration type.
16319 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16321 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
16322 (dw2_get_file_names_reader): Adjust.
16323 (lookup_dwo_signatured_type): Adjust.
16324 (lookup_dwp_signatured_type): Adjust.
16325 (lookup_signatured_type): Adjust.
16326 (create_type_unit_group): Adjust.
16327 (get_type_unit_group): Adjust.
16328 (process_psymtab_comp_unit_reader): Adjust.
16329 (build_type_psymtabs_reader): Adjust.
16330 (scan_partial_symbols): Adjust.
16331 (add_partial_symbol): Adjust.
16332 (add_partial_subprogram): Adjust.
16333 (peek_die_abbrev): Adjust.
16334 (fixup_go_packaging): Adjust.
16335 (process_imported_unit_die): Adjust.
16336 (dwarf2_compute_name): Adjust.
16337 (dwarf2_physname): Adjust.
16338 (read_import_statement): Adjust.
16339 (handle_DW_AT_stmt_list): Adjust.
16340 (read_file_scope): Adjust.
16341 (read_func_scope): Adjust.
16342 (read_lexical_block_scope): Adjust.
16343 (read_call_site_scope): Adjust.
16344 (read_variable): Adjust.
16345 (dwarf2_rnglists_process): Adjust.
16346 (dwarf2_ranges_process): Adjust.
16347 (dwarf2_ranges_read): Adjust.
16348 (dwarf2_get_pc_bounds): Adjust.
16349 (dwarf2_record_block_ranges): Adjust.
16350 (dwarf2_add_field): Adjust.
16351 (dwarf2_add_member_fn): Adjust.
16352 (read_structure_type): Adjust.
16353 (process_structure_scope): Adjust.
16354 (read_enumeration_type): Adjust.
16355 (read_array_type): Adjust.
16356 (mark_common_block_symbol_computed): Adjust.
16357 (read_common_block): Adjust.
16358 (read_namespace_type): Adjust.
16359 (read_namespace): Adjust.
16360 (read_module_type): Adjust.
16361 (read_tag_pointer_type): Adjust.
16362 (read_tag_ptr_to_member_type): Adjust.
16363 (read_tag_string_type): Adjust.
16364 (read_subroutine_type): Adjust.
16365 (read_typedef): Adjust.
16366 (read_base_type): Adjust.
16367 (attr_to_dynamic_prop): Adjust.
16368 (read_subrange_type): Adjust.
16369 (read_unspecified_type): Adjust.
16370 (dwarf2_read_abbrevs): Adjust.
16371 (load_partial_dies): Adjust.
16372 (read_partial_die): Adjust.
16373 (find_partial_die): Adjust.
16374 (guess_partial_die_structure_name): Adjust.
16375 (fixup_partial_die): Adjust.
16376 (read_attribute_value): Adjust.
16377 (read_addr_index): Adjust.
16378 (read_addr_index_from_leb128): Adjust.
16379 (read_str_index): Adjust.
16380 (dwarf2_string_attr): Adjust.
16381 (get_debug_line_section): Adjust.
16382 (dwarf_decode_line_header): Adjust.
16383 (lnp_state_machine::check_line_address): Adjust.
16384 (dwarf_decode_lines_1): Adjust.
16385 (dwarf_decode_lines): Adjust.
16386 (dwarf2_start_symtab): Adjust.
16387 (var_decode_location): Adjust.
16388 (new_symbol_full): Adjust.
16389 (dwarf2_const_value_data): Adjust.
16390 (dwarf2_const_value_attr): Adjust.
16391 (dwarf2_const_value): Adjust.
16392 (die_type): Adjust.
16393 (die_containing_type): Adjust.
16394 (build_error_marker_type): Adjust.
16395 (lookup_die_type): Adjust.
16396 (guess_full_die_structure_name): Adjust.
16397 (anonymous_struct_prefix): Adjust.
16398 (determine_prefix): Adjust.
16399 (dwarf2_name): Adjust.
16400 (follow_die_ref_or_sig): Adjust.
16401 (follow_die_offset): Adjust.
16402 (follow_die_ref): Adjust.
16403 (follow_die_sig_1): Adjust.
16404 (follow_die_sig): Adjust.
16405 (get_signatured_type): Adjust.
16406 (get_DW_AT_signature_type): Adjust.
16407 (decode_locdesc): Adjust.
16408 (dwarf_decode_macros): Adjust.
16409 (cu_debug_loc_section): Adjust.
16410 (fill_in_loclist_baton): Adjust.
16411 (dwarf2_symbol_mark_computed): Adjust.
16412 (init_one_comp_unit): Don't assign
16413 dwarf2_cu::dwarf2_per_objfile.
16414 (set_die_type): Adjust.
16416 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16418 * dwarf2read.c (struct mapped_debug_names): Add constructor.
16419 <dwarf2_per_objfile>: New field.
16420 (dwarf2_per_objfile): Remove global.
16421 (get_dwarf2_per_objfile): New function.
16422 (set_dwarf2_per_objfile): New function.
16423 (dwarf2_build_psymtabs_hard): Change objfile parameter to
16424 dwarf2_per_objfile.
16425 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16426 (read_abbrev_offset): Likewise.
16427 (read_indirect_string): Likewise.
16428 (read_indirect_line_string): Likewise.
16429 (read_indirect_string_at_offset): Likewise.
16430 (read_indirect_string_from_dwz): Likewise.
16431 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16432 dwarf2_per_objfile.
16433 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16434 (create_all_comp_units): Change objfile parameter to
16435 dwarf2_per_objfile.
16436 (create_all_type_units): Likewise.
16437 (process_queue): Add dwarf2_per_objfile parameter.
16438 (read_and_check_comp_unit_head): Likewise.
16439 (lookup_dwo_unit_in_dwp): Likewise.
16440 (get_dwp_file): Likewise.
16441 (process_cu_includes): Likewise.
16442 (struct free_dwo_file_cleanup_data): New struct.
16443 (dwarf2_has_info): Use get_dwarf2_per_objfile and
16444 set_dwarf2_per_objfile.
16445 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
16446 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
16447 context, adjust calls.
16448 (dw2_instantiate_symtab): Likewise.
16449 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
16450 (dw2_get_cu): Likewise.
16451 (create_cu_from_index_list): Change objfile parameter to
16452 dwarf2_per_objfile.
16453 (create_cus_from_index_list): Get dwarf2_per_objfile from
16454 context, adjust calls.
16455 (create_cus_from_index): Likewise.
16456 (create_signatured_type_table_from_index): Change objfile
16457 parameter to dwarf2_per_objfile.
16458 (create_signatured_type_table_from_debug_names): Change objfile
16459 parameter to dwarf2_per_objfile.
16460 (create_addrmap_from_index): Likewise.
16461 (create_addrmap_from_aranges): Likewise.
16462 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
16463 (dw2_setup): Remove.
16464 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
16466 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
16467 get_dwarf2_per_objfile.
16468 (dw2_forget_cached_source_info): Likewise.
16469 (dw2_map_symtabs_matching_filename): Likewise.
16470 (struct dw2_symtab_iterator) <index>: Remove.
16471 <dwarf2_per_objfile>: New field.
16472 (dw2_symtab_iter_init): Replace index parameter with
16473 dwarf2_per_objfile.
16474 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
16475 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
16476 (dw2_print_stats): Likewise.
16477 (dw2_dump): Likewise.
16478 (dw2_expand_symtabs_for_function): Likewise.
16479 (dw2_expand_all_symtabs): Likewise.
16480 (dw2_expand_symtabs_with_fullname): Likewise.
16481 (dw2_expand_marked_cus): Replace index and objfile parameters
16482 with dwarf2_per_objfile.
16483 (dw_expand_symtabs_matching_file_matcher): Add
16484 dwarf2_per_objfile parameter and adjust calls.
16485 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
16487 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
16488 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
16490 (create_cus_from_debug_names_list): Replace objfile parameter
16491 with dwarf2_per_objfile and adjust calls.
16492 (create_cus_from_debug_names): Likewise.
16493 (dwarf2_read_debug_names): Likewise.
16494 (mapped_debug_names::namei_to_name): Adjust call.
16495 (dw2_debug_names_iterator::next): Likewise.
16496 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
16497 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
16498 (dw2_debug_names_dump): Likewise.
16499 (dw2_debug_names_expand_symtabs_for_function): Likewise.
16500 (dw2_debug_names_expand_symtabs_matching): Likewise.
16501 (dwarf2_initialize_objfile): Likewise.
16502 (dwarf2_build_psymtabs): Likewise.
16503 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
16505 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
16506 (read_and_check_comp_unit_head): Likewise.
16507 (read_abbrev_offset): Likewise.
16508 (create_debug_type_hash_table): Likewise.
16509 (create_debug_types_hash_table): Likewise.
16510 (create_all_type_units): Replace objfile parameter with
16511 dwarf2_per_objfile.
16512 (add_type_unit): Add dwarf2_per_objfile parameter.
16513 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
16514 with dwarf2_per_objfile.
16515 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
16516 (lookup_dwp_signatured_type): Likewise.
16517 (lookup_signatured_type): Likewise.
16518 (read_cutu_die_from_dwo): Likewise.
16519 (init_tu_and_read_dwo_dies): Likewise.
16520 (init_cutu_and_read_dies): Likewise.
16521 (init_cutu_and_read_dies_no_follow): Likewise.
16522 (allocate_type_unit_groups_table): Add objfile parameter.
16523 (create_type_unit_group): Use dwarf2_per_objfile from cu.
16524 (get_type_unit_group): Likewise.
16525 (process_psymtab_comp_unit): Update call.
16526 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
16527 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
16528 (print_tu_stats): Likewise.
16529 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
16530 in void* parameter.
16531 (build_type_psymtabs): Change objfile parameter to
16532 dwarf2_per_objfile.
16533 (process_skeletonless_type_unit): Use dwarf2_per_objfile
16534 passed in void* parameter.
16535 (process_skeletonless_type_units): Change objfile parameter to
16536 dwarf2_per_objfile.
16537 (set_partial_user): Likewise.
16538 (dwarf2_build_psymtabs_hard): Likewise.
16539 (read_comp_units_from_section): Likewise.
16540 (create_all_comp_units): Likewise.
16541 (scan_partial_symbols): Update calls.
16542 (add_partial_symbol): Likewise.
16543 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
16544 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
16545 (process_queue): Add dwarf2_per_objfile parameter.
16546 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
16547 (compute_compunit_symtab_includes): Likewise.
16548 (process_cu_includes): Add dwarf2_per_objfile parameter.
16549 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
16550 (process_full_type_unit): Likewise.
16551 (process_imported_unit_die): Update call.
16552 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
16553 (read_file_scope): Likewise.
16554 (allocate_dwo_file_hash_table): Add objfile parameter.
16555 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
16556 (create_cus_hash_table): Likewise.
16557 (create_dwp_hash_table): Likewise.
16558 (create_dwo_unit_in_dwp_v1): Likewise.
16559 (create_dwp_v2_section): Likewise.
16560 (create_dwo_unit_in_dwp_v2): Likewise.
16561 (lookup_dwo_unit_in_dwp): Likewise.
16562 (try_open_dwop_file): Likewise.
16563 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
16564 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
16565 cleanup to include a reference to dwarf2_per_objfile.
16566 (open_dwp_file): Add dwarf2_per_objfile parameter.
16567 (open_and_init_dwp_file): Likewise.
16568 (get_dwp_file): Likewise.
16569 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
16570 (queue_and_load_all_dwo_tus): Update call.
16571 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
16573 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
16574 (dwarf2_ranges_process): Likewise.
16575 (dwarf2_get_pc_bounds): Likewise.
16576 (mark_common_block_symbol_computed): Likewise.
16577 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16578 (dwarf2_read_abbrevs): Update call.
16579 (read_partial_die): Use dwarf2_per_objfile from cu.
16580 (find_partial_die): Likewise.
16581 (fixup_partial_die): Likewise.
16582 (read_attribute_value): Likewise.
16583 (read_indirect_string_at_offset_from): Add objfile parameter.
16584 (read_indirect_string_at_offset): Add dwarf2_per_objfile
16586 (read_indirect_string_from_dwz): Add objfile parameter.
16587 (read_indirect_string): Add objfile parameter.
16588 (read_addr_index_1): Add dwarf2_per_objfile parameter.
16589 (read_addr_index): Use dwarf2_per_objfile from cu.
16590 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
16592 (read_str_index): Use dwarf2_per_objfile from cu.
16593 (get_debug_line_section): Likewise.
16594 (read_formatted_entries): Add dwarf2_per_objfile parameter.
16595 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
16596 (new_symbol_full): Use dwarf2_per_objfile from cu.
16597 (build_error_marker_type): Likewise.
16598 (lookup_die_type): Likewise.
16599 (determine_prefix): Likewise.
16600 (follow_die_offset): Likewise.
16601 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
16602 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
16603 (dwarf2_fetch_die_type_sect_off): Likewise.
16604 (dwarf2_get_die_type): Likewise.
16605 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
16606 (get_signatured_type): Likewise.
16607 (get_DW_AT_signature_type): Likewise.
16608 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
16609 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
16610 (cu_debug_loc_section): Likewise.
16611 (fill_in_loclist_baton): Likewise.
16612 (dwarf2_symbol_mark_computed): Likewise.
16613 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16614 dwarf2_per_objfile.
16615 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
16617 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16618 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
16619 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
16620 (set_die_type): Use dwarf2_free_objfile from cu.
16621 (get_die_type_at_offset): Likewise.
16622 (dwarf2_per_objfile_free): Don't assign global variable.
16623 (debug_names) <constructor>: Add dwarf2_per_objfile
16624 parameter, update m_debugstrlookup construction.
16625 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
16627 <m_dwarf2_per_objfile>: New field.
16628 <lookup>: Use m_dwarf2_per_objfile.
16629 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
16630 (psyms_seen_size): Likewise.
16631 (write_gdbindex): Replace objfile parameter with
16632 dwarf2_per_objfile.
16633 (write_debug_names): Likewise.
16634 (write_psymtabs_to_index): Likewise.
16635 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
16638 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16640 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
16641 <dwarf2_per_objfile>: New field.
16642 (struct dwarf2_per_cu_data) <objfile>: Remove.
16643 <dwarf2_per_objfile>: New field.
16644 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
16646 (create_signatured_type_table_from_index): Likewise.
16647 (create_debug_type_hash_table): Likewise.
16648 (fill_in_sig_entry_from_dwo_entry): Likewise.
16649 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
16650 (create_type_unit_group): Assign dwarf2_per_objfile instead of
16652 (create_partial_symtab): Access objfile through
16653 dwarf2_per_objfile.
16654 (process_psymtab_comp_unit_reader): Likewise.
16655 (read_comp_units_from_section): Likewise.
16656 (scan_partial_symbols): Likewise.
16657 (add_partial_symbol): Likewise.
16658 (add_partial_subprogram): Likewise.
16659 (peek_die_abbrev): Likewise.
16660 (fixup_go_packaging): Likewise.
16661 (process_full_comp_unit): Likewise.
16662 (process_full_type_unit): Likewise.
16663 (process_imported_unit_die): Likewise.
16664 (dwarf2_compute_name): Likewise.
16665 (dwarf2_physname): Likewise.
16666 (read_import_statement): Likewise.
16667 (create_cus_hash_table): Assign dwarf2_physname instead of
16669 (read_func_scope): Access objfile through dwarf2_per_objfile.
16670 (read_lexical_block_scope): Likewise.
16671 (read_call_site_scope): Likewise.
16672 (read_variable): Likewise.
16673 (dwarf2_rnglists_process): Likewise.
16674 (dwarf2_ranges_process): Likewise.
16675 (dwarf2_ranges_read): Likewise.
16676 (dwarf2_record_block_ranges): Likewise.
16677 (dwarf2_add_field): Likewise.
16678 (dwarf2_add_member_fn): Likewise.
16679 (read_structure_type): Likewise.
16680 (process_structure_scope): Likewise.
16681 (read_enumeration_type): Likewise.
16682 (read_array_type): Likewise.
16683 (read_common_block): Likewise.
16684 (read_namespace_type): Likewise.
16685 (read_namespace): Likewise.
16686 (read_module_type): Likewise.
16687 (read_tag_pointer_type): Likewise.
16688 (read_tag_ptr_to_member_type): Likewise.
16689 (read_tag_string_type): Likewise.
16690 (read_subroutine_type): Likewise.
16691 (read_typedef): Likewise.
16692 (read_base_type): Likewise.
16693 (attr_to_dynamic_prop): Likewise.
16694 (read_subrange_type): Likewise.
16695 (read_unspecified_type): Likewise.
16696 (load_partial_dies): Likewise.
16697 (read_partial_die): Likewise.
16698 (find_partial_die): Likewise.
16699 (guess_partial_die_structure_name): Likewise.
16700 (fixup_partial_die): Likewise.
16701 (read_attribute_value): Likewise.
16702 (read_addr_index_from_leb128): Likewise.
16703 (dwarf2_read_addr_index): Likewise.
16704 (dwarf2_string_attr): Likewise.
16705 (lnp_state_machine::check_line_address): Likewise.
16706 (dwarf_decode_lines_1): Likewise.
16707 (dwarf_decode_lines): Likewise.
16708 (dwarf2_start_symtab): Likewise.
16709 (var_decode_location): Likewise.
16710 (new_symbol_full): Likewise.
16711 (dwarf2_const_value_data): Likewise.
16712 (dwarf2_const_value_attr): Likewise.
16713 (dwarf2_const_value): Likewise.
16714 (die_type): Likewise.
16715 (die_containing_type): Likewise.
16716 (lookup_die_type): Likewise.
16717 (guess_full_die_structure_name): Likewise.
16718 (anonymous_struct_prefix): Likewise.
16719 (dwarf2_name): Likewise.
16720 (follow_die_ref_or_sig): Likewise.
16721 (follow_die_offset): Likewise.
16722 (follow_die_ref): Likewise.
16723 (dwarf2_fetch_die_loc_sect_off): Likewise.
16724 (dwarf2_fetch_constant_bytes): Likewise.
16725 (dwarf2_fetch_die_type_sect_off): Likewise.
16726 (dwarf2_get_die_type): Likewise.
16727 (follow_die_sig): Likewise.
16728 (decode_locdesc): Likewise.
16729 (dwarf2_per_cu_objfile): Likewise.
16730 (dwarf2_per_cu_text_offset): Likewise.
16731 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
16733 (set_die_type): Access objfile through
16734 dwarf2_per_objfile.
16736 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16738 * valprint.c (converted_character_d): Remove typedef.
16739 (DEF_VEC_O (converted_character_d)): Remove.
16740 (count_next_character): Use std::vector.
16741 (print_converted_chars_to_obstack): Likewise.
16742 (generic_printstr): Likewise.
16744 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16746 * xml-support.h (struct gdb_xml_value): Add constructor.
16747 <value>: Change type to unique_xmalloc_ptr.
16748 (gdb_xml_value_s): Remove typedef.
16749 (DEF_VEC_O (gdb_xml_value_s)): Remove.
16750 (gdb_xml_element_start_handler): Change parameter type to
16752 (xml_find_attribute): Likewise.
16753 * xml-support.c (xml_find_attribute): Change parameter type to
16754 std::vector and adjust.
16755 (gdb_xml_values_cleanup): Remove.
16756 (gdb_xml_parser::start_element): Adjust to std::vector.
16757 (xinclude_start_include): Change paraeter type to std::vector
16759 * btrace.c (check_xml_btrace_version): Likewise.
16760 (parse_xml_btrace_block): Likewise.
16761 (parse_xml_btrace_pt_config_cpu): Likewise.
16762 (parse_xml_btrace_pt): Likewise.
16763 (parse_xml_btrace_conf_bts): Likewise.
16764 (parse_xml_btrace_conf_pt): Likewise.
16765 * memory-map.c (memory_map_start_memory): Likewise.
16766 (memory_map_start_property): Likewise.
16767 * osdata.c (osdata_start_osdata): Likewise.
16768 (osdata_start_item): Likewise.
16769 (osdata_start_column): Likewise.
16770 * remote.c (start_thread): Likewise.
16771 * solib-aix.c (library_list_start_library): Likewise.
16772 (library_list_start_list): Likewise.
16773 * solib-svr4.c (library_list_start_library): Likewise.
16774 (svr4_library_list_start_list): Likewise.
16775 * solib-target.c (library_list_start_segment): Likewise.
16776 (library_list_start_section): Likewise.
16777 (library_list_start_library): Likewise.
16778 (library_list_start_list): Likewise.
16779 * tracepoint.c (traceframe_info_start_memory): Likewise.
16780 (traceframe_info_start_tvar): Likewise.
16781 * xml-syscall.c (syscall_start_syscall): Likewise.
16782 * xml-tdesc.c (tdesc_start_target): Likewise.
16783 (tdesc_start_feature): Likewise.
16784 (tdesc_start_reg): Likewise.
16785 (tdesc_start_union): Likewise.
16786 (tdesc_start_struct): Likewise.
16787 (tdesc_start_flags): Likewise.
16788 (tdesc_start_enum): Likewise.
16789 (tdesc_start_field): Likewise.
16790 (tdesc_start_enum_value): Likewise.
16791 (tdesc_start_vector): Likewise.
16793 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16795 * extension.h (struct xmethod_worker) <clone>: Remove.
16796 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
16798 (python_xmethod_worker::clone): Remove.
16799 * valops.c (find_overload_match): Use std::move instead of
16802 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16804 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
16805 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
16806 <free_xmethod_worker_data>: Remove.
16807 <get_matching_xmethod_workers>: Chance VEC to std::vector.
16808 <get_xmethod_arg_types>: Remove.
16809 <get_xmethod_result_type>: Remove.
16810 <invoke_xmethod>: Remove.
16811 * extension.c (new_xmethod_worker): Remove.
16812 (clone_xmethod_worker): Remove.
16813 (get_matching_xmethod_workers): Return void, pass std::vector by
16815 (get_xmethod_arg_types): Rename to...
16816 (xmethod_worker::get_arg_types): ... this, and adjust.
16817 (get_xmethod_result_type): Rename to...
16818 (xmethod_worker::get_result_type): ... this, and adjust.
16819 (invoke_xmethod): Remove.
16820 (free_xmethod_worker): Remove.
16821 (free_xmethod_worker_vec): Remove.
16822 * extension.h (enum ext_lang_rc): Move here from
16824 (struct xmethod_worker): Add constructor and destructor.
16827 <invoke, clone, do_get_result_type, do_get_arg_types>: New
16828 virtual pure methods.
16829 <get_arg_types, get_result_type>: New methods.
16830 (xmethod_worker_ptr): Remove typedef.
16831 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
16832 (xmethod_worker_vec): Remove typedef.
16833 (xmethod_worker_up): New typedef.
16834 (invoke_xmethod): Remove.
16835 (clone_xmethod_worker): Remove.
16836 (free_xmethod_worker): Remove.
16837 (free_xmethod_worker_vec): Remove.
16838 (get_xmethod_arg_types): Remove.
16839 (get_xmethod_result_type): Remove.
16840 * valops.c (find_method_list): Use std::vector, don't use
16841 intermediate vector.
16842 (value_find_oload_method_list): Use std::vector.
16843 (find_overload_match): Use std::vector.
16844 (find_oload_champ): Use std::vector.
16845 * value.c (value_free): Use operator delete.
16846 (value_of_xmethod): Rename to...
16847 (value_from_xmethod): ... this. Don't assign
16848 xmethod_worker::value, take rvalue-reference.
16849 (result_type_of_xmethod): Adjust.
16850 (call_xmethod): Adjust.
16851 * value.h: Include extension.h.
16852 (struct xmethod_worker): Don't forward-declare.
16853 (value_of_xmethod): Rename to...
16854 (value_from_xmethod): ... this, take rvalue-reference.
16855 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
16856 (struct python_xmethod_worker): ... this, add constructor and
16858 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
16859 (gdbpy_free_xmethod_worker_data): Rename to...
16860 (python_xmethod_worker::~python_xmethod_worker): ... this and
16862 (gdbpy_clone_xmethod_worker_data): Rename to...
16863 (python_xmethod_worker::clone): ... this and adjust.
16864 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
16866 (gdbpy_get_xmethod_arg_types): Rename to...
16867 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
16868 (gdbpy_get_xmethod_result_type): Rename to...
16869 (python_xmethod_worker::do_get_result_type): ... this and
16871 (gdbpy_invoke_xmethod): Rename to...
16872 (python_xmethod_worker::invoke): ... this and adjust.
16873 (new_python_xmethod_worker): Rename to...
16874 (python_xmethod_worker::python_xmethod_worker): ... this and
16876 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
16878 (gdbpy_free_xmethod_worker_data): Remove.
16879 (gdbpy_get_matching_xmethod_workers): Use std::vector.
16880 (gdbpy_get_xmethod_arg_types): Remove.
16881 (gdbpy_get_xmethod_result_type): Remove.
16882 (gdbpy_invoke_xmethod): Remove.
16883 * python/python.c (python_extension_ops): Remove obsolete
16886 2018-01-05 Pedro Alves <palves@redhat.com>
16889 * common/signals-state-save-restore.c
16890 (save_original_signals_state): New parameter 'quiet'. Warn if we
16891 find a custom handler preinstalled, instead of internal erroring.
16892 But only warn if !quiet.
16893 * common/signals-state-save-restore.h
16894 (save_original_signals_state): New parameter 'quiet'.
16895 * main.c (captured_main_1): Move save_original_signals_state call
16896 after option handling, and pass QUIET.
16898 2018-01-05 Pedro Alves <palves@redhat.com>
16900 * spu-tdep.c (spu_catch_start): Pass
16901 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
16903 2018-01-05 Pedro Alves <palves@redhat.com>
16906 * ada-lang.c (literal_symbol_name_matcher): New function.
16907 (ada_get_symbol_name_matcher): Use it for
16908 symbol_name_match_type::SEARCH_NAME.
16909 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
16910 it down instead of assuming symbol_name_match_type::FULL.
16911 * block.h (block_lookup_symbol): New parameter 'match_type'.
16912 * c-valprint.c (print_unpacked_pointer): Use
16913 lookup_symbol_search_name instead of lookup_symbol.
16914 * compile/compile-object-load.c (get_out_value_type): Pass down
16915 symbol_name_match_type::SEARCH_NAME.
16916 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
16917 symbol_name_match_type::FULL.
16918 * cp-support.c (cp_get_symbol_name_matcher): Handle
16919 symbol_name_match_type::SEARCH_NAME.
16920 * infrun.c (insert_exception_resume_breakpoint): Use
16921 lookup_symbol_search_name.
16922 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
16923 * psymtab.c (maintenance_check_psymtabs): Use
16924 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
16925 * stack.c (print_frame_args): Use lookup_symbol_search_name and
16926 SYMBOL_SEARCH_NAME.
16927 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
16928 if symbol_name_match_type::SEARCH_NAME.
16929 (lookup_symbol_in_language): Pass down
16930 symbol_name_match_type::FULL.
16931 (lookup_symbol_search_name): New.
16932 (lookup_language_this): Pass down
16933 symbol_name_match_type::SEARCH_NAME.
16934 (lookup_symbol_aux, lookup_local_symbol): New parameter
16935 'match_type'. Pass it down.
16936 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
16937 (lookup_symbol_search_name): New declaration.
16938 (lookup_symbol_in_block): New 'match_type' parameter.
16940 2018-01-05 Pedro Alves <palves@redhat.com>
16943 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
16945 (ada_lookup_symbol): Reimplement in terms of
16946 ada_lookup_symbol_list, bits factored out from
16947 ada_lookup_encoded_symbol.
16949 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16951 * ada-exp.y (write_object_renaming): When subscripting an array
16952 using a symbol as the index, pass the block in call to
16953 ada_lookup_encoded_symbol when looking that symbol up.
16955 2018-01-05 Jerome Guitton <guitton@adacore.com>
16957 * ada-lang.c (ada_array_length): Use ada_index_type instead of
16960 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16962 * ada-lang.c (ada_to_fixed_value_create): Add handling of
16963 the case where VALUE_LVAL (val0) is not lval_memory.
16965 2018-01-05 Xavier Roirand <roirand@adacore.com>
16967 * ada-valprint.c (print_optional_low_bound): Handle
16968 character-indexed array printing like boolean-indexed array
16971 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16973 * NEWS: Create a new section for the next release branch.
16974 Rename the section of the current branch, now that it has
16977 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16979 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
16980 * version.in: Bump version to 8.1.50.DATE-git.
16982 2018-01-03 Xavier Roirand <roirand@adacore.com>
16984 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
16986 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
16988 (default_exception_support_info) <catch_handlers_sym>: Add field.
16989 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
16990 (ada_exception_name_addr_1): Add "catch handlers" handling.
16991 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
16992 Update all callers.
16993 (create_excep_cond_exprs) <ex>: Add parameter.
16994 (re_set_exception): Update create_excep_cond_exprs call.
16995 (print_it_exception, print_one_exception, print_mention_exception)
16996 (print_recreate_exception): Add "catch handler" handling.
16997 (allocate_location_catch_handlers, re_set_catch_handlers)
16998 (check_status_catch_handlers, print_it_catch_handlers)
16999 (print_one_catch_handlers, print_mention_catch_handlers)
17000 (print_recreate_catch_handlers): New function.
17001 (catch_handlers_breakpoint_ops): New variable.
17002 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
17003 Add parameter. Add "catch handler" handling.
17004 (ada_exception_sym_name, ada_exception_breakpoint_ops):
17005 Add "catch handler" handling.
17006 (ada_exception_catchpoint_cond_string): Add "catch handler"
17008 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
17010 (catch_ada_handlers_command): New function.
17011 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
17012 operations structure.
17013 (_initialize_ada_language): Add "catch handlers" command entry.
17014 * NEWS: Document "catch handlers" feature.
17016 2018-01-02 Joel Brobecker <brobecker@adacore.com>
17018 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
17019 account when creating the array type of the slice.
17020 (ada_value_slice): Likewise.
17022 2018-01-02 Joel Brobecker <brobecker@adacore.com>
17024 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
17026 (create_array_type_with_stride): Add byte_stride_prop parameter.
17027 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
17028 New parameter. Update all callers in this file.
17029 (array_type_has_dynamic_stride): New function.
17030 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
17031 of arrays with dynamic byte strides.
17032 * dwarf2read.c (read_array_type): Add support for dynamic
17033 DW_AT_byte_stride attributes.
17035 2018-01-02 Joel Brobecker <brobecker@adacore.com>
17037 * dwarf2read.c (read_unspecified_type): Treat
17038 DW_TAG_enumeration_type DIEs from Ada units as stubs.
17040 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17042 Update copyright year range in all GDB files.
17044 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
17046 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
17047 and gdb/testsuite/gdb.base/step-line.c.
17049 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17051 * copyright.py (main): Dump the contents of
17052 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
17053 even if BY_HAND is empty.
17055 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17057 * top.c (print_gdb_version): Update Copyright year in version
17060 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17062 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
17064 For older changes see ChangeLog-2017.
17070 version-control: never