1 2018-10-04 Tom Tromey <tom@tromey.com>
3 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
4 declaration of "block".
6 2018-10-04 Tom Tromey <tom@tromey.com>
8 * common/filestuff.c (fdwalk): Remove inner declaration of
11 2018-10-04 Tom Tromey <tom@tromey.com>
13 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
14 "structs_addr" and hoist declaration.
16 2018-10-04 Tom Tromey <tom@tromey.com>
18 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
21 2018-10-04 Tom Tromey <tom@tromey.com>
23 * mdebugread.c (parse_partial_symbols): Use std::string.
25 2018-10-04 Tom Tromey <tom@tromey.com>
27 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
28 * p-valprint.c (pascal_val_print): Split inner "i" variable.
29 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
31 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
33 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
34 * varobj.c (varobj_update): Rename inner "newobj",
36 * valprint.c (generic_emit_char): Rename inner "buf".
37 * valops.c (find_overload_match): Rename inner "temp".
38 (value_struct_elt_for_reference): Declare "v" in more inner
40 * v850-tdep.c (v850_push_dummy_call): Rename "len".
41 * unittests/array-view-selftests.c (run_tests): Rename inner
43 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
45 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
46 "tsv" in more inner scope.
47 (print_one_static_tracepoint_marker): Rename inner
49 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
50 (tic6x_push_dummy_call): Don't redeclare "addr".
51 * target-float.c: Declare "dto" lower.
52 * symtab.c (lookup_local_symbol): Rename inner "sym".
53 (find_pc_sect_line): Rename inner "pc".
54 * stack.c (print_frame): Don't redeclare "gdbarch".
55 (return_command): Rename inner "gdbarch".
56 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
58 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
60 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
61 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
63 * remote.c (remote_target::update_thread_list): Don't redeclare
65 (remote_target::process_initial_stop_replies): Rename inner
67 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
68 (remote_target::wait_as): Don't redeclare "stop_reply".
69 (remote_target::get_thread_local_address): Rename inner
71 (remote_target::get_tib_address): Likewise.
73 * regcache.c (cooked_read_test): Rename "regnum".
74 * record-btrace.c (cmd_record_btrace_start): Rename inner
76 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
78 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
80 (ppu2spu_sniffer): Rename inner "buf".
81 * parse.c (operator_check_standard): Rename inner "type",
83 * p-valprint.c (pascal_val_print): Introduce new scope for
84 "low_bound", "high_bound".
85 * p-exp.y (yylex): Declare "i" in loop header.
86 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
87 Lower declaration of "s".
88 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
90 (nios2_push_dummy_call): Rename "len".
91 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
93 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
94 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
95 (linux_xfer_osdata_modules): Likewise.
96 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
97 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
98 (mips_o64_push_dummy_call): Likewise.
99 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
101 * mi/mi-main.c (list_available_thread_groups): Rename inner
103 (mi_cmd_data_read_memory): Rename inner "opts".
104 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
106 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
107 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
109 (parse_partial_symbols): Rename inner "pst", "p", "name"
110 * main.c (captured_main_1): Rename inner "i"s.
111 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
113 * linux-tdep.c (linux_info_proc): Rename inner "filename".
114 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
115 * infrun.c (handle_no_resumed): Don't redeclare "thread".
116 (handle_signal_stop): Rename inner "gdbarch".
117 (handle_command): Declare "signum" in loop header.
118 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
120 (examine_prologue): Rename inner "sol" and "sof".
121 (ia64_extract_return_value): Rename inner "val". Declare another
122 "val" in a more inner scope.
123 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
125 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
127 * findvar.c (default_read_var_value): Don't redeclare "addr".
128 * f-exp.y (yylex): Declare "i" in loop header.
129 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
130 Rename inner "type", "expect_type".
131 (evaluate_subexp_for_sizeof): Rename inner "pc".
132 * elfread.c (elf_symfile_read): Rename inner "abfd".
133 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
135 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
136 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
137 (dwarf_decode_line_header): Rename inner "lh".
138 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
139 "offset". Declare "i" in loop header.
140 (disassemble_dwarf_expression): Rename inner "addr_size".
141 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
143 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
144 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
145 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
146 "inner_list_emitter".
147 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
148 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
149 declaration in a block.
150 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
151 * cp-valprint.c (cp_print_value_fields): Don't redeclare
152 "obstack_final_size".
153 * cp-support.c (inspect_type): Declare "i" in loop header.
154 * compile/compile.c (compile_instance::insert_symbol_error):
156 * common/agent.c (agent_run_command): Remove inner "ret"
158 * coffread.c (coff_symfile_read): Rename inner "name".
159 (coff_symfile_read): Rename inner "abfd".
160 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
161 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
163 * c-exp.y (lex_one_token): Move "len" declaration lower.
164 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
166 (create_exception_master_breakpoint): Likewise. Don't redeclare
168 (watch_command_1): Declare "mark" later.
169 (clear_command): Don't shadow "a" or "b".
170 (delete_command): Rename inner "b".
171 (delete_trace_command): Likewise.
172 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
174 (arm_gdbarch_init): Remove inner "e_flags".
175 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
176 "offset" in inner blocks.
178 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
180 * dwarf-index-write.c (file_write): Don't write if the vector is
183 2018-10-05 Tom de Vries <tdevries@suse.de>
185 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
186 PyArg_ParseTuple call.
188 2018-10-05 Tom de Vries <tdevries@suse.de>
190 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
191 PyArg_ParseTuple call.
193 2018-10-04 Joel Brobecker <brobecker@adacore.com>
195 * psymtab.c (recursively_search_psymtabs): Reformat parameters
196 to avoid exceeding 80 characters per line limit.
198 2018-10-04 Tom Tromey <tom@tromey.com>
200 * symfile.c (syms_from_objfile_1, finish_new_objfile)
201 (reread_symbols): Update.
202 * complaints.h (clear_complaints): Remove argument.
203 * complaints.c (enum complaint_series): Remove.
204 (series): Remove global.
205 (complaint_internal): Update.
206 (clear_complaints): Remove argument.
208 2018-10-04 Tom Tromey <tom@tromey.com>
210 * symfile.c (symbol_file_add_with_addrs): Do not print "no
211 debugging symbols" message if there is a separate debug objfile.
213 2018-10-04 Tom Tromey <tom@tromey.com>
216 * symfile.c (symbol_file_add_with_addrs): Update output.
217 * psymtab.c (require_partial_symbols): Update output.
219 2018-10-04 Tom Tromey <tom@tromey.com>
222 * complaints.c: Emit \n.
224 2018-10-04 Tom Tromey <tom@tromey.com>
226 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
227 (separate_debug_file_exists, find_separate_debug_file)
228 (add_symbol_file_command, reread_symbols, allocate_symtab)
229 (allocate_compunit_symtab): Use filtered printing, not
231 * psymtab.c (require_partial_symbols, dump_psymtab)
232 (allocate_psymtab): Use filtered printing, not unfiltered.
234 2018-10-04 Tom Tromey <tom@tromey.com>
236 * complaints.c (complaint_internal): Correctly check complaint
239 2018-10-04 Tom Tromey <tom@tromey.com>
241 * complaints.h (struct complaints): Remove declaration.
242 * complaints.c (clear_complaints): Remove an unused variable.
244 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
246 * MAINTAINERS (Write After Approval): Add self.
248 2018-10-03 Tom Tromey <tom@tromey.com>
250 * guile/scm-value.c (gdbscm_value_to_string): Initialize
252 * coffread.c (coff_symtab_read): Initialize "newobj".
254 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
256 * dwarf2read.c (read_func_scope): Remove struct keyword in
259 2018-10-03 Tom Tromey <tom@tromey.com>
261 * README: Mention --enable-ubsan.
262 * NEWS: Mention --enable-ubsan.
263 * acinclude.m4: Include sanitize.m4.
264 * configure: Rebuild.
265 * configure.ac: Call AM_GDB_UBSAN.
266 * sanitize.m4: New file.
268 2018-10-03 Tom Tromey <tom@tromey.com>
270 * expression.h (enum exp_opcode): Use uint8_t as base type.
271 * expprint.c (op_name): Handle invalid opcodes.
273 2018-10-03 Tom Tromey <tom@tromey.com>
275 * parse.c (prefixify_expression): Add assert.
276 (parse_exp_in_context_1): Throw exception if the expression is
279 2018-10-03 Tom Tromey <tom@tromey.com>
281 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
283 2018-10-03 Tom Tromey <tom@tromey.com>
285 * c-exp.y (parse_number): Work in unsigned. Remove casts.
287 2018-10-03 Tom Tromey <tom@tromey.com>
289 * dwarf2read.c (read_subrange_type): Make "negative_mask"
292 2018-10-03 Tom Tromey <tom@tromey.com>
294 * findvar.c (extract_integer): Do work in an unsigned type.
296 2018-10-03 Tom Tromey <tom@tromey.com>
298 * common/enum-flags.h (enum_flags::operator~): Add static assert.
299 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
301 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
302 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
304 * c-lang.h (enum c_string_type_values): Use unsigned as base
306 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
308 2018-10-03 Tom Tromey <tom@tromey.com>
310 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
311 <~dwarf2_frame_state_reg_info>: Update.
312 <dwarf2_frame_state_reg_info>: Update.
313 <alloc_regs>: Add assertion. Update.
314 <reg>: Now a std::vector.
317 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
318 (execute_cfa_program_test, dwarf2_frame_cache): Update.
320 2018-10-03 Tom Tromey <tom@tromey.com>
322 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
324 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
326 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
328 2018-10-02 Tom Tromey <tom@tromey.com>
330 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
332 2018-10-02 John Darrington <john@darrington.wattle.id.au>
334 * NEWS: Mention changed commands.
335 * ser-uds.c: New file.
336 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
337 * configure: Regenerate.
338 * Makefile.in: Add new file.
339 * serial.c (serial_open): Check if filename is a socket
340 and lookup the appropriate interface accordingly.
342 2018-10-01 Alan Hayward <alan.hayward@arm.com>
344 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
346 (AARCH64_EXTRA_MAGIC): Likewise.
347 (AARCH64_FPSIMD_MAGIC): Likewise.
348 (AARCH64_SVE_MAGIC): Likewise.
349 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
350 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
351 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
352 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
353 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
354 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
355 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
356 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
357 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
358 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
359 (read_aarch64_ctx): Add function.
360 (aarch64_linux_sigframe_init): Detect FP registers.
362 2018-10-01 Alan Hayward <alan.hayward@arm.com>
364 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
365 (AARCH64_D0_REGNUM): Likewise.
366 (AARCH64_S0_REGNUM): Likewise.
367 (AARCH64_H0_REGNUM): Likewise.
368 (AARCH64_B0_REGNUM): Likewise.
369 (AARCH64_SVE_V0_REGNUM): Likewise.
370 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
371 (AARCH64_D0_REGNUM): Likewise.
372 (AARCH64_S0_REGNUM): Likewise.
373 (AARCH64_H0_REGNUM): Likewise.
374 (AARCH64_B0_REGNUM): Likewise.
375 (AARCH64_SVE_V0_REGNUM): Likewise.
377 2018-10-01 Gary Benson <gbenson@redhat.com>
379 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
380 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
381 prfpregset_t instead of gdb_prfpregset_t.
382 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
383 * configure, config.in: Rebuild.
385 2018-10-01 Gary Benson <gbenson@redhat.com>
387 * common/gdb_proc_service.h: New file, factored out from...
388 * gdb_proc_service.h: Moved common code to the above file.
389 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
391 2018-10-01 Gary Benson <gbenson@redhat.com>
393 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
394 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
396 2018-10-01 Gary Benson <gbenson@redhat.com>
398 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
399 (AC_CHECK_HEADERS): Check for linux/elf.h.
400 * configure, config.in: Rebuild.
401 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
402 doesn't define elf_fpregset_t.
404 2018-10-01 Gary Benson <gbenson@redhat.com>
406 * gdb_proc_service.h: Whitespace change.
408 2018-10-01 Tom Tromey <tom@tromey.com>
410 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
411 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
412 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
414 2018-10-01 Tom Tromey <tom@tromey.com>
416 * README: Minor change.
418 2018-09-30 Pedro Alves <palves@redhat.com>
420 * darwin-nat-info.c (darwin_debug_regions_recurse)
421 (info_mach_exceptions_command): Remove unused local variables.
422 * darwin-nat.c (darwin_decode_notify_message)
423 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
424 (darwin_stop_inferior, darwin_setup_exceptions)
425 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
426 (darwin_nat_target::attach, darwin_nat_target::detach)
427 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
429 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
432 2018-09-29 Tom Tromey <tom@tromey.com>
434 * README: Remove some leftover text.
436 2018-09-29 Tom Tromey <tom@tromey.com>
441 2018-09-28 John Baldwin <jhb@FreeBSD.org>
443 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
444 case with explicit breakpoint kind.
445 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
446 'additional_info' and related logic.
447 (riscv_debug_breakpoints): New variable.
448 (riscv_breakpoint_kind_from_pc): Use the length of the existing
449 instruction to determine the breakpoint kind.
450 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
451 flag. Update description of 'set/show riscv
452 use-compressed-breakpoints' flag.
454 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
456 (NEWS): Mention changes to frame related commands.
457 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
458 (add_prefix_cmd_suppress_notification): New function.
459 (add_com_suppress_notification): Call
460 add_cmd_suppress_notification.
461 * command.h (add_cmd_suppress_notification): Declare.
462 (add_prefix_cmd_suppress_notification): Declare.
463 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
464 (parse_frame_specification): Moved from stack.c, with
465 simplification to handle a single argument.
466 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
467 switch to the selected frame. Add a header comment.
468 * stack.c: Remove 'safe-ctype.h' include.
469 (find_frame_for_function): Add declaration.
470 (find_frame_for_address): New function.
471 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
472 (frame_selection_by_function_completer): New function.
473 (info_frame_command): Rename to...
474 (info_frame_command_core): ...this, and update parameter types.
475 (select_frame_command): Rename to...
476 (select_frame_command_core): ...this, and update parameter types.
477 (frame_command): Rename to...
478 (frame_command_core): ...this, and update parameter types.
479 (class frame_command_helper): New class to wrap implementations of
480 frame related sub-commands.
481 (frame_apply_cmd_list): New static global.
482 (frame_cmd_list): Make static.
483 (select_frame_cmd_list): New global for sub-commands.
484 (info_frame_cmd_list): New global for sub-commands.
485 (_initialize_stack): Register sub-commands for 'frame',
486 'select-frame', and 'info frame'. Update 'frame apply' commands
487 to use frame_apply_cmd_list. Move function local static
488 frame_apply_list to file static frame_apply_cmd_list for
490 * stack.h (select_frame_command): Delete declarationn.
491 (select_frame_for_mi): Declare new function.
493 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
495 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
496 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
499 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
501 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
503 2018-09-26 Tom Tromey <tom@tromey.com>
505 * valops.c (auto_abandon): Remove dead code.
507 2018-09-26 Tom Tromey <tom@tromey.com>
509 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
511 2018-09-24 Tom Tromey <tom@tromey.com>
513 * common/pathstuff.c (get_standard_cache_dir): Make
514 "xdg_cache_home" and "home" const.
515 * top.c (init_history): Make "tmpenv" const.
516 * main.c (get_init_files): Make "homedir" const.
518 2018-09-23 Tom Tromey <tom@tromey.com>
521 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
523 2018-09-23 Tom Tromey <tom@tromey.com>
525 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
526 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
527 * python/python-internal.h (gdbpy_handle_exception): Declare.
528 * python/py-utils.c (gdbpy_handle_exception): New function.
530 2018-09-23 Tom Tromey <tom@tromey.com>
533 * python/py-type.c (typy_template_argument): Check for negative
536 2018-09-23 Tom Tromey <tom@tromey.com>
539 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
541 2018-09-23 Tom Tromey <tom@tromey.com>
544 * python/py-value.c (valpy_int): Allow conversion from pointer
547 2018-09-23 Tom Tromey <tom@tromey.com>
550 * python/py-value.c (valpy_int): Respect type sign.
552 2018-09-23 Tom Tromey <tom@tromey.com>
555 * python/py-value.c (valpy_float): Allow conversions from int or
557 (valpy_int, valpy_long): Allow conversions from float.
559 2018-09-23 Tom Tromey <tom@tromey.com>
561 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
562 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
564 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
566 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
568 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
570 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
572 * windows-nat.c (windows_nat_target::wait): Remove a spurious
573 target_terminal::ours().
575 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
577 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
580 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
582 * breakpoint.c (update_inserted_breakpoint_locations): Remove
585 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
587 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
589 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
590 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
591 * sol-thread.c (ps_pdmodel): Don't guard definition.
593 * procfs.c: Fix formatting.
595 * procfs.c (sysset_t_alloc): Remove.
596 (create_procinfo): Use XNEW instead of sysset_t_alloc.
597 (procfs_debug_inferior): Likewise.
598 (procfs_set_exec_trap): Likewise.
599 (proc_set_traced_sysentry): Don't allocate argp dynamically.
600 (proc_set_traced_sysexit): Likewise.
602 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
603 (dead_procinfo): Likewise.
604 (proc_warn): Likewise.
605 (proc_error): Likewise.
606 (proc_get_LDT_entry): Likewise.
607 (do_attach): Likewise.
608 (procfs_target::pid_to_str): Likewise.
609 (iterate_over_mappings): Likewise.
611 * procfs.c (create_procinfo): Fix ARI warning.
612 (proc_get_status): Likewise.
613 (proc_stop_process): Likewise.
614 (proc_run_process): Likewise.
615 (proc_kill): Likewise.
616 (proc_get_LDT_entry): Likewise.
617 (procfs_find_LDT_entry): Likewise.
618 (proc_update_threads): Likewise.
619 (proc_iterate_over_threads): Likewise.
620 (do_attach): Likewise.
621 (procfs_xfer_memory): Likewise.
622 (invalidate_cache): Likewise.
623 (procfs_target::resume): Likewise.
624 (procfs_init_inferior): Likewise.
625 (procfs_set_exec_trap): Likewise.
626 (procfs_target::thread_alive): Likewise.
627 (procfs_target::pid_to_exec_file): Likewise.
628 (iterate_over_mappings): Likewise.
629 (procfs_target::make_corefile_notes): Likewise.
630 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
632 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
633 (procfs_find_LDT_entry): Likewise.
634 * sol-thread.c (ps_lgetLDT): Likewise.
636 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
639 * procfs.c (procfs_target): Declare pid_to_exec_file.
640 (procfs_target::pid_to_exec_file): New.
642 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
644 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
646 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
647 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
649 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
651 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
652 (supply_fpregset, fill_fpregset): Move ...
653 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
654 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
655 Remove references to ioctl-based procfs.
657 Remove PR_MODEL_NATIVE guards.
658 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
659 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
661 2018-09-19 Xavier Roirand <roirand@adacore.com>
664 * solib-darwin.c (darwin_get_dyld_bfd): New function.
665 (darwin_solib_get_all_image_info_addr_at_init): Update call.
666 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
668 2018-09-19 John Baldwin <jhb@FreeBSD.org>
670 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
671 (fbsd_print_sockaddr_in6): Likewise.
673 2018-09-19 Richard Bunt <richard.bunt@arm.com>
674 Chris January <chris.january@arm.com>
676 * eval.c (skip_undetermined_arglist): Skip argument list helper.
677 (evaluate_subexp_standard): Return a dummy type when
678 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
679 OP_F77_UNDETERMINED_ARGLIST case.
680 * expression.h (enum noside): Update comment.
682 2018-09-19 George Vasick <george.vasick@oracle.com>
684 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
686 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
687 April Chin <april.chin@oracle.com>
688 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
690 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
692 (create_procinfo): Print pids in /proc without leading zeros.
694 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
696 * nios2-tdep.c (nios2_gcc_target_options): New.
697 (nios2_gdb_arch_init): Install new hook.
699 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
701 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
703 * update-gnulib.sh: Apply patch.
704 * configure: Re-generate.
706 2018-09-18 John Baldwin <jhb@FreeBSD.org>
708 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
709 description. Make "info proc" command descriptions more
712 2018-09-18 John Baldwin <jhb@FreeBSD.org>
714 * NEWS: Mention 'info proc files' command.
716 2018-09-18 John Baldwin <jhb@FreeBSD.org>
718 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
719 descriptors for IP_FILES and IP_ALL.
721 2018-09-18 John Baldwin <jhb@FreeBSD.org>
723 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
724 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
725 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
726 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
727 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
728 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
729 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
730 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
731 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
732 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
733 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
734 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
735 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
736 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
737 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
738 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
739 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
740 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
741 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
742 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
743 (struct fbsd_sockaddr_un): New types.
744 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
745 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
746 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
747 (fbsd_core_info_proc_files): New functions.
748 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
750 * fbsd-tdep.h (fbsd_info_proc_files_header)
751 (fbsd_info_proc_files_entry): New.
753 2018-09-18 John Baldwin <jhb@FreeBSD.org>
755 * defs.h (enum info_proc_what) [IP_FILES]: New value.
756 * infcmd.c (info_proc_cmd_files): New function.
757 (_initialize_infcmd): Register 'info proc files' command.
759 2018-09-18 John Baldwin <jhb@FreeBSD.org>
761 * gnulib/aclocal-m4-deps.mk: Re-generate.
762 * gnulib/aclocal.m4: Re-generate.
763 * gnulib/config.in: Re-generate.
764 * gnulib/configure: Re-generate.
765 * gnulib/import/Makefile.am: Re-generate.
766 * gnulib/import/Makefile.in: Re-generate.
767 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
768 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
769 * gnulib/import/arpa_inet.in.h: New file.
770 * gnulib/import/inet_ntop.c: New file.
771 * gnulib/import/m4/arpa_inet_h.m4: New file.
772 * gnulib/import/m4/inet_ntop.m4: New file.
773 * gnulib/import/m4/netinet_in_h.m4: New file.
774 * gnulib/import/m4/socklen.m4: New file.
775 * gnulib/import/m4/sockpfaf.m4: New file.
776 * gnulib/import/m4/stdalign.m4: New file.
777 * gnulib/import/m4/sys_uio_h.m4: New file.
778 * gnulib/import/netinet_in.in.h: New file.
779 * gnulib/import/stdalign.in.h: New file.
780 * gnulib/import/sys_socket.c: New file.
781 * gnulib/import/sys_socket.in.h: New file.
782 * gnulib/import/sys_uio.in.h: New file.
783 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
786 2018-09-18 John Baldwin <jhb@FreeBSD.org>
788 * gnulib/aclocal-m4-deps.mk: New file.
789 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
792 2018-09-18 John Baldwin <jhb@FreeBSD.org>
794 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
797 2018-09-18 Tom Tromey <tom@tromey.com>
799 * compile/compile-object-load.c (struct
800 link_hash_table_cleanup_data): Add constructor and destructor.
801 Use DISABLE_COPY_AND_ASSIGN.
802 (~link_hash_table_cleanup_data): Rename from
803 link_hash_table_free. Now a destructor.
804 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
806 2018-09-18 Tom Tromey <tom@tromey.com>
808 * compile/compile-object-run.c (do_module_cleanup): Use delete.
809 * compile/compile-object-load.c (struct munmap_list): Move to
811 (munmap_list::add): Rename from munmap_list_add; rewrite.
812 (munmap_list::~munmap_list): Rename from munmap_list_free.
813 (munmap_listp_free_cleanup): Remove.
814 (compile_object_load): Update.
815 * compile/compile-object-load.h (struct munmap_list): Move from
816 compile-object-load.c. Rewrite.
818 2018-09-18 Alan Hayward <alan.hayward@arm.com>
820 * aarch64-tdep.c (pass_in_v): Use register size.
821 (aarch64_extract_return_value): Likewise.
822 (aarch64_store_return_value): Likewise.
824 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
826 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
829 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
831 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
834 2018-09-17 Tom Tromey <tom@tromey.com>
837 * configure: Rebuild.
838 * configure.ac: Conditionally use -DNDEBUG for Python.
840 2018-09-17 Tom Tromey <tom@tromey.com>
842 * configure: Rebuild.
843 * configure.ac: Use gmp as a library dependency when checking for
846 2018-09-17 Pedro Alves <palves@redhat.com>
848 * python/py-inferior.c (find_inferior_object): Delete.
850 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
852 * compile/compile-cplus-types.c
853 (compile_cplus_instance::enter_scope): Don't use new_scope after
856 2018-09-17 Tom Tromey <tom@tromey.com>
858 * common/pathstuff.c (get_standard_cache_dir): Use
859 ~/Library/Caches on macOS.
860 * common/pathstuff.h (get_standard_cache_dir): Update comment.
862 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
865 * breakpoint.c (commands_cmd_element): New.
866 (_initialize_breakpoint): Assign commands_cmd_element.
867 * breakpoint.h (commands_cmd_element): New.
868 * cli/cli-script.c (while_cmd_element, if_command,
869 define_cmd_element): New.
870 (command_name_equals): Remove.
871 (process_next_line): Compare commands by pointer, not by name.
872 (_initialize_cli_script): Assign the various cmd_list_element
874 * compile/compile.c (compile_cmd_element): New.
875 (_initialize_compile): Assign compile_cmd_element.
876 * compile/compile.h (compile_cmd_element): New.
877 * guile/guile.c (guile_cmd_element): New.
878 (install_gdb_commands): Assign guile_cmd_element.
879 * guile/guile.h (guile_cmd_element): New.
880 * python/python.c (python_cmd_element): New.
881 (_initialize_python): Assign python_cmd_element.
882 * python/python.h (python_cmd_element): New.
883 * tracepoint.c (while_stepping_cmd_element): New.
884 (_initialize_tracepoint): Assign while_stepping_cmd_element.
885 * tracepoint.h (while_stepping_cmd_element): New.
887 2018-09-17 Tom Tromey <tom@tromey.com>
889 * infrun.c (save_infcall_suspend_state): Return
890 infcall_suspend_state_up.
891 (save_infcall_control_state): Return infcall_control_state_up.
892 * inferior.h (save_infcall_suspend_state)
893 (save_infcall_control_state): Declare later. Return unique
896 2018-09-17 Tom Tromey <tom@tromey.com>
898 * infrun.c (struct stop_context): Declare constructor,
899 destructor, "changed" method.
900 (stop_context::stop_context): Rename from save_stop_context.
901 (stop_context::~stop_context): Rename from
902 release_stop_context_cleanup.
903 (normal_stop): Update.
904 (stop_context::changed): Rename from stop_context_changed. Return
907 2018-09-17 Tom Tromey <tom@tromey.com>
909 * inferior.h (struct infcall_suspend_state_deleter): New.
910 (infcall_suspend_state_up): New typedef.
911 (struct infcall_control_state_deleter): New.
912 (infcall_control_state_up): New typedef.
913 (make_cleanup_restore_infcall_suspend_state)
914 (make_cleanup_restore_infcall_control_state): Don't declare.
915 * infcall.c (call_function_by_hand_dummy): Update.
916 * infrun.c (do_restore_infcall_suspend_state_cleanup)
917 (make_cleanup_restore_infcall_suspend_state): Remove.
918 (do_restore_infcall_control_state_cleanup)
919 (make_cleanup_restore_infcall_control_state): Remove.
921 2018-09-17 Tom Tromey <tom@tromey.com>
923 * gdbthread.h (struct thread_control_state): Add initializer.
924 (class thread_info) <control>: Remove initializer.
925 * inferior.h (struct inferior_control_state): Add initializer.
926 (class inferior) <control>: Remove initializer.
927 (exit_inferior_1): Update.
928 * infrun.c (struct infcall_control_state): Add constructors.
929 (save_infcall_control_state): Use new.
930 (restore_infcall_control_state, discard_infcall_control_state):
933 2018-09-17 Tom Tromey <tom@tromey.com>
935 * infrun.c (struct infcall_suspend_state) <registers>: Now a
937 <siginfo_data>: Now a unique_xmalloc_ptr.
938 (save_infcall_suspend_state, restore_infcall_suspend_state)
939 (discard_infcall_suspend_state)
940 (get_infcall_suspend_state_regcache): Update.
942 2018-09-17 Tom Tromey <tom@tromey.com>
944 * gdbthread.h (struct thread_suspend_state): Add initializers.
945 (class thread_info) <suspend>: Remove initializer.
946 * infrun.c (struct infcall_suspend_state): Add initializers.
947 (save_infcall_suspend_state): Use new.
948 (discard_infcall_suspend_state): Use delete.
950 2018-09-16 Tom Tromey <tom@tromey.com>
952 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
954 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
955 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
956 (py_varobj_iter_new): Likewise.
957 (py_varobj_get_iterator): Use gdbpy_ref.
959 2018-09-16 Tom Tromey <tom@tromey.com>
961 * python/py-threadevent.c (py_get_event_thread): Simplify.
962 * python/py-inferior.c (infpy_thread_from_thread_handle):
963 Return immediately after calling thread_to_thread_object. Use
965 (thread_to_thread_object): Set the exception on a NULL return.
967 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
969 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
971 2018-09-16 Tom Tromey <tom@tromey.com>
973 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
976 2018-09-16 Tom Tromey <tom@tromey.com>
978 * python/python-internal.h (thread_to_thread_object): Change
980 * python/py-inferior.c (thread_to_thread_object): Return a new
982 (infpy_thread_from_thread_handle): Update.
983 * python/py-infthread.c (gdbpy_selected_thread): Update.
984 * python/py-stopevent.c (create_stop_event_object): Update.
985 * python/py-threadevent.c (py_get_event_thread): Return a new
987 (py_get_event_thread): Update.
988 * python/py-event.h (py_get_event_thread): Change return type.
989 * python/py-continueevent.c (create_continue_event_object):
992 2018-09-16 Tom Tromey <tom@tromey.com>
994 * python/py-progspace.c (pspy_get_objfiles): Update.
995 * python/python-internal.h (objfile_to_objfile_object): Change
997 * python/py-newobjfileevent.c (create_new_objfile_event_object):
999 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1001 * python/python.c (gdbpy_get_current_objfile): Update.
1002 (gdbpy_objfiles): Update.
1003 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
1005 (objfile_to_objfile_object): Return a new reference.
1006 * python/py-symtab.c (stpy_get_objfile): Update.
1007 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
1010 2018-09-16 Tom Tromey <tom@tromey.com>
1012 * python/py-inferior.c (infpy_get_progspace): Update.
1013 * python/python-internal.h (pspace_to_pspace_object): Change
1015 * python/py-newobjfileevent.c
1016 (create_clear_objfiles_event_object): Update.
1017 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1019 * python/python.c (gdbpy_get_current_progspace): Update.
1020 (gdbpy_progspaces): Update.
1021 * python/py-progspace.c (pspace_to_pspace_object): Return a new
1023 * python/py-objfile.c (objfpy_get_progspace): Update.
1024 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
1027 2018-09-16 Tom Tromey <tom@tromey.com>
1029 * python/lib/gdb/__init__.py (current_progspace, objfiles)
1030 (solib_name, block_for_pc, find_pc_line): New functions.
1031 (execute_unwinders): Update.
1032 * python/py-block.c (gdbpy_block_for_pc): Remove.
1033 * python/py-inferior.c (infpy_get_progspace): New function.
1034 (inferior_object_getset) <progspace>: Add.
1035 * python/py-progspace.c (pspy_objfiles): Rewrite.
1036 (pspy_solib_name, pspy_block_for_pc)
1037 (pspy_find_pc_line, pspy_is_valid): New functions.
1038 (progspace_object_methods): Add entries for solib_name,
1039 block_for_pc, find_pc_line, is_valid.
1040 * python/python-internal.h (gdbpy_block_for_pc)
1041 (build_objfiles_list): Don't declare.
1042 * python/python.c: Don't include solib.h.
1043 (gdbpy_solib_name, gdbpy_find_pc_line)
1044 (gdbpy_get_current_progspace, build_objfiles_list)
1045 (gdbpy_objfiles): Remove.
1046 (GdbMethods) <current_progspace, objfiles, block_for_pc,
1047 solib_name, find_pc_line>: Remove entries.
1049 2018-09-16 Tom Tromey <tom@tromey.com>
1051 * top.c (new_ui_command): Use GNU style for metasyntactic
1053 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
1055 * maint.c (maintenance_translate_address): Remove "<>" around
1057 * interps.c (interpreter_exec_cmd): Use GNU style for
1058 metasyntactic variables.
1059 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
1060 metasyntactic variables.
1061 * tracepoint.c (tfind_range_command): Use GNU style for
1062 metasyntactic variables.
1063 (tfind_outside_command): Likewise.
1064 (_initialize_tracepoint): Likewise.
1065 * remote.c (extended_remote_target::create_inferior): Use GNU
1066 style for metasyntactic variables.
1067 * sparc64-tdep.c (adi_examine_command): Use GNU style for
1068 metasyntactic variables.
1069 (adi_assign_command): Likewise.
1071 2018-09-16 Tom Tromey <tom@tromey.com>
1073 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
1074 metasyntactic variables. Print message if no disassembler options
1077 2018-09-15 Tom Tromey <tom@tromey.com>
1079 * infcmd.c (get_inferior_args): Return const char *.
1080 * inferior.h (get_inferior_args): Return type now const.
1081 * linux-tdep.c (linux_fill_prpsinfo): Update.
1082 * procfs.c (procfs_target::make_corefile_notes): Update.
1084 2018-09-07 Tom Tromey <tom@tromey.com>
1086 * python/python.c (execute_gdb_command): Call bpstat_do_actions
1089 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
1091 * nios2-tdep.c (nios2_type_align): New.
1092 (nios2_gdb_arch_init): Install type_align hook.
1094 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1096 * eval.c (fake_method::fake_method): Call xzalloc directly for a
1097 type that is neither object file owned, nor gdbarch owned.
1098 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
1099 gdbarch is non-NULL.
1100 (alloc_type_instance): Allocate non-objfile owned types on the
1102 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
1103 using TYPE_ALLOC to ensure memory is allocated on the correct
1105 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
1106 obstack, or the gdbarch obstack.
1107 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
1109 2018-09-14 Tom Tromey <tom@tromey.com>
1111 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
1114 2018-09-14 Tom Tromey <tom@tromey.com>
1116 * nat/fork-inferior.c (get_startup_shell): Remove "static".
1118 2018-09-13 Tom Tromey <tom@tromey.com>
1120 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
1123 2018-09-13 Tom Tromey <tom@tromey.com>
1125 * exec.c (try_open_exec_file): Use std::string.
1127 2018-09-13 Tom Tromey <tom@tromey.com>
1129 * utils.h (gdb_bfd_errmsg): Return std::string.
1130 * exec.c (exec_file_attach): Update.
1131 * compile/compile-object-load.c (compile_object_load): Update.
1132 * utils.c (gdb_bfd_errmsg): Return std::string.
1134 2018-09-13 Tom Tromey <tom@tromey.com>
1136 * procfs.c (struct procinfo_deleter): New.
1137 (procinfo_up): New typedef.
1138 (do_destroy_procinfo_cleanup): Remove.
1139 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
1141 2018-09-13 Tom Tromey <tom@tromey.com>
1143 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
1145 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1146 2018-09-13 Tom Tromey <tom@tromey.com>
1148 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
1149 (pspy_get_objfiles): New function.
1150 (progspace_object_methods): New.
1151 (pspace_object_type): Add tp_methods callback.
1152 * python/python-internal.h (build_objfiles_list): New
1154 * python/python.c (build_objfiles_list): New function.
1155 (gdbpy_objfiles): Implement using build_objfiles_list.
1156 * NEWS: Mention the Progspace.objfiles method.
1158 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1160 * python/py-inferior.c (infpy_get_progspace): New function.
1161 (inferior_object_getset): Add progspace property.
1162 * NEWS: Mention the new property.
1164 2018-09-13 Tom Tromey <tom@tromey.com>
1167 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
1169 2018-09-13 Tom Tromey <tom@tromey.com>
1172 * rust-lang.c (rust_enum_variant): Now static.
1173 (rust_empty_enum_p): New function.
1174 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
1177 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1179 * python/py-inferior.c (infpy_repr): New.
1180 (inferior_object_type): Register infpy_repr.
1181 * python/py-objfile.c (objfpy_repr): New.
1182 (objfile_object_type): Register objfpy_repr.
1184 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1186 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
1188 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1190 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
1193 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
1195 * common/common-utils.c: Don't include '<sys/stat.h>'.
1196 (is_regular_file): Move to...
1197 * common/filestuff.c (is_regular_file): ... here.
1198 * common/common-utils.h (is_regular_file): Move to...
1199 * common/filestuff.h (is_regular_file): ... here.
1201 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
1203 * skip.c (debug_skip): New variable.
1204 (skiplist_entry::do_skip_file_p): Add debug output.
1205 (skiplist_entry::do_skip_gfile_p): Likewise.
1206 (skiplist_entry::skip_function_p): Likewise.
1207 (_initialize_step_skip): Create debug command.
1208 * NEWS: Mention set/show debug skip.
1210 2018-09-11 Xavier Roirand <roirand@adacore.com>
1212 * darwin-nat.c (should_disable_startup_with_shell):
1214 (darwin_nat_target::create_inferior): Add call.
1216 2018-09-11 Xavier Roirand <roirand@adacore.com>
1218 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
1219 inf_port, msg_state>: Initialize.
1220 (struct darwin_thread_info) <signaled, single_step>: Change
1221 type and initialize.
1222 (struct darwin_thread_info) <event>: Initialize.
1224 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1228 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
1231 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1234 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1238 * gnulib/aclocal.m4: Regenerate.
1239 * gnulib/config.in: Regenerate.
1240 * gnulib/configure: Regenerate.
1241 * gnulib/import/Makefile.am: Update.
1242 * gnulib/import/Makefile.in: Update.
1243 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1244 * gnulib/import/_Noreturn.h: ... this.
1245 * gnulib/import/alloca.in.h: Update.
1246 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1247 * gnulib/import/arg-nonnull.h: ... this.
1248 * gnulib/import/assure.h: Update.
1249 * gnulib/import/at-func.c: Update.
1250 * gnulib/import/basename-lgpl.c: Update.
1251 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1252 * gnulib/import/c++defs.h: ... this.
1253 * gnulib/import/canonicalize-lgpl.c: Update.
1254 * gnulib/import/cdefs.h: Update.
1255 * gnulib/import/chdir-long.c: Update.
1256 * gnulib/import/chdir-long.h: Update.
1257 * gnulib/import/cloexec.c: Update.
1258 * gnulib/import/cloexec.h: Update.
1259 * gnulib/import/close.c: Update.
1260 * gnulib/import/closedir.c: Update.
1261 * gnulib/import/config.charset: Update.
1262 * gnulib/import/dirent-private.h: Update.
1263 * gnulib/import/dirent.in.h: Update.
1264 * gnulib/import/dirfd.c: Update.
1265 * gnulib/import/dirname-lgpl.c: Update.
1266 * gnulib/import/dirname.h: Update.
1267 * gnulib/import/dosname.h: Update.
1268 * gnulib/import/dup-safer-flag.c: Update.
1269 * gnulib/import/dup-safer.c: Update.
1270 * gnulib/import/dup.c: Update.
1271 * gnulib/import/dup2.c: Update.
1272 * gnulib/import/errno.in.h: Update.
1273 * gnulib/import/error.c: Update.
1274 * gnulib/import/error.h: Update.
1275 * gnulib/import/exitfail.c: Update.
1276 * gnulib/import/exitfail.h: Update.
1277 * gnulib/import/extra/update-copyright: Update.
1278 * gnulib/import/fchdir.c: Update.
1279 * gnulib/import/fcntl.c: Update.
1280 * gnulib/import/fcntl.in.h: Update.
1281 * gnulib/import/fd-hook.c: Update.
1282 * gnulib/import/fd-hook.h: Update.
1283 * gnulib/import/fd-safer-flag.c: Update.
1284 * gnulib/import/fd-safer.c: Update.
1285 * gnulib/import/fdopendir.c: Update.
1286 * gnulib/import/filename.h: Update.
1287 * gnulib/import/filenamecat-lgpl.c: Update.
1288 * gnulib/import/filenamecat.h: Update.
1289 * gnulib/import/flexmember.h: Update.
1290 * gnulib/import/float+.h: Update.
1291 * gnulib/import/float.c: Update.
1292 * gnulib/import/float.in.h: Update.
1293 * gnulib/import/fnmatch.c: Update.
1294 * gnulib/import/fnmatch.in.h: Update.
1295 * gnulib/import/fnmatch_loop.c: Update.
1296 * gnulib/import/fpucw.h: Update.
1297 * gnulib/import/frexp.c: Update.
1298 * gnulib/import/frexpl.c: Update.
1299 * gnulib/import/fstat.c: Update.
1300 * gnulib/import/fstatat.c: Update.
1301 * gnulib/import/getcwd-lgpl.c: Update.
1302 * gnulib/import/getcwd.c: Update.
1303 * gnulib/import/getdtablesize.c: Update.
1304 * gnulib/import/getlogin_r.c: Update.
1305 * gnulib/import/getprogname.c: Update.
1306 * gnulib/import/getprogname.h: Update.
1307 * gnulib/import/gettext.h: Update.
1308 * gnulib/import/gettimeofday.c: Update.
1309 * gnulib/import/glob-libc.h: Update.
1310 * gnulib/import/glob.c: Update.
1311 * gnulib/import/glob.in.h: Update.
1312 * gnulib/import/glob_internal.h: Update.
1313 * gnulib/import/glob_pattern_p.c: Update.
1314 * gnulib/import/globfree.c: Update.
1315 * gnulib/import/hard-locale.c: Update.
1316 * gnulib/import/hard-locale.h: Update.
1317 * gnulib/import/intprops.h: Update.
1318 * gnulib/import/inttypes.in.h: Update.
1319 * gnulib/import/isnan.c: Update.
1320 * gnulib/import/isnand-nolibm.h: Update.
1321 * gnulib/import/isnand.c: Update.
1322 * gnulib/import/isnanl-nolibm.h: Update.
1323 * gnulib/import/isnanl.c: Update.
1324 * gnulib/import/itold.c: Update.
1325 * gnulib/import/libc-config.h: Update.
1326 * gnulib/import/limits.in.h: Update.
1327 * gnulib/import/localcharset.c: Update.
1328 * gnulib/import/localcharset.h: Update.
1329 * gnulib/import/localtime-buffer.c: Update.
1330 * gnulib/import/localtime-buffer.h: Update.
1331 * gnulib/import/lstat.c: Update.
1332 * gnulib/import/m4/00gnulib.m4: Update.
1333 * gnulib/import/m4/__inline.m4: Update.
1334 * gnulib/import/m4/absolute-header.m4: Update.
1335 * gnulib/import/m4/alloca.m4: Update.
1336 * gnulib/import/m4/builtin-expect.m4: Update.
1337 * gnulib/import/m4/canonicalize.m4: Update.
1338 * gnulib/import/m4/chdir-long.m4: Update.
1339 * gnulib/import/m4/close.m4: Update.
1340 * gnulib/import/m4/closedir.m4: Update.
1341 * gnulib/import/m4/configmake.m4: Update.
1342 * gnulib/import/m4/d-ino.m4: Update.
1343 * gnulib/import/m4/d-type.m4: Update.
1344 * gnulib/import/m4/dirent_h.m4: Update.
1345 * gnulib/import/m4/dirfd.m4: Update.
1346 * gnulib/import/m4/dirname.m4: Update.
1347 * gnulib/import/m4/double-slash-root.m4: Update.
1348 * gnulib/import/m4/dup.m4: Update.
1349 * gnulib/import/m4/dup2.m4: Update.
1350 * gnulib/import/m4/eealloc.m4: Update.
1351 * gnulib/import/m4/environ.m4: Update.
1352 * gnulib/import/m4/errno_h.m4: Update.
1353 * gnulib/import/m4/error.m4: Update.
1354 * gnulib/import/m4/exponentd.m4: Update.
1355 * gnulib/import/m4/exponentl.m4: Update.
1356 * gnulib/import/m4/extensions.m4: Update.
1357 * gnulib/import/m4/extern-inline.m4: Update.
1358 * gnulib/import/m4/fchdir.m4: Update.
1359 * gnulib/import/m4/fcntl-o.m4: Update.
1360 * gnulib/import/m4/fcntl.m4: Update.
1361 * gnulib/import/m4/fcntl_h.m4: Update.
1362 * gnulib/import/m4/fdopendir.m4: Update.
1363 * gnulib/import/m4/filenamecat.m4: Update.
1364 * gnulib/import/m4/flexmember.m4: Update.
1365 * gnulib/import/m4/float_h.m4: Update.
1366 * gnulib/import/m4/fnmatch.m4: Update.
1367 * gnulib/import/m4/fnmatch_h.m4: Update.
1368 * gnulib/import/m4/fpieee.m4: Update.
1369 * gnulib/import/m4/frexp.m4: Update.
1370 * gnulib/import/m4/frexpl.m4: Update.
1371 * gnulib/import/m4/fstat.m4: Update.
1372 * gnulib/import/m4/fstatat.m4: Update.
1373 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1374 * gnulib/import/m4/getcwd-path-max.m4: Update.
1375 * gnulib/import/m4/getcwd.m4: Update.
1376 * gnulib/import/m4/getdtablesize.m4: Update.
1377 * gnulib/import/m4/getlogin.m4: Update.
1378 * gnulib/import/m4/getlogin_r.m4: Update.
1379 * gnulib/import/m4/getpagesize.m4: Update.
1380 * gnulib/import/m4/getprogname.m4: Update.
1381 * gnulib/import/m4/gettimeofday.m4: Update.
1382 * gnulib/import/m4/glibc21.m4: Update.
1383 * gnulib/import/m4/glob.m4: Update.
1384 * gnulib/import/m4/glob_h.m4: Update.
1385 * gnulib/import/m4/gnulib-cache.m4: Update.
1386 * gnulib/import/m4/gnulib-common.m4: Update.
1387 * gnulib/import/m4/gnulib-comp.m4: Update.
1388 * gnulib/import/m4/gnulib-tool.m4: Update.
1389 * gnulib/import/m4/hard-locale.m4: Update.
1390 * gnulib/import/m4/include_next.m4: Update.
1391 * gnulib/import/m4/inttypes-pri.m4: Update.
1392 * gnulib/import/m4/inttypes.m4: Update.
1393 * gnulib/import/m4/isnand.m4: Update.
1394 * gnulib/import/m4/isnanl.m4: Update.
1395 * gnulib/import/m4/largefile.m4: Update.
1396 * gnulib/import/m4/limits-h.m4: Update.
1397 * gnulib/import/m4/localcharset.m4: Update.
1398 * gnulib/import/m4/locale-fr.m4: Update.
1399 * gnulib/import/m4/locale-ja.m4: Update.
1400 * gnulib/import/m4/locale-zh.m4: Update.
1401 * gnulib/import/m4/localtime-buffer.m4: Update.
1402 * gnulib/import/m4/longlong.m4: Update.
1403 * gnulib/import/m4/lstat.m4: Update.
1404 * gnulib/import/m4/malloc.m4: Update.
1405 * gnulib/import/m4/malloca.m4: Update.
1406 * gnulib/import/m4/math_h.m4: Update.
1407 * gnulib/import/m4/mbrtowc.m4: Update.
1408 * gnulib/import/m4/mbsinit.m4: Update.
1409 * gnulib/import/m4/mbsrtowcs.m4: Update.
1410 * gnulib/import/m4/mbstate_t.m4: Update.
1411 * gnulib/import/m4/memchr.m4: Update.
1412 * gnulib/import/m4/memmem.m4: Update.
1413 * gnulib/import/m4/mempcpy.m4: Update.
1414 * gnulib/import/m4/memrchr.m4: Update.
1415 * gnulib/import/m4/mkdir.m4: Update.
1416 * gnulib/import/m4/mkstemp.m4: Update.
1417 * gnulib/import/m4/mmap-anon.m4: Update.
1418 * gnulib/import/m4/mode_t.m4: Update.
1419 * gnulib/import/m4/msvc-inval.m4: Update.
1420 * gnulib/import/m4/msvc-nothrow.m4: Update.
1421 * gnulib/import/m4/multiarch.m4: Update.
1422 * gnulib/import/m4/nocrash.m4: Update.
1423 * gnulib/import/m4/off_t.m4: Update.
1424 * gnulib/import/m4/onceonly.m4: Update.
1425 * gnulib/import/m4/open-cloexec.m4: Update.
1426 * gnulib/import/m4/open.m4: Update.
1427 * gnulib/import/m4/openat.m4: Update.
1428 * gnulib/import/m4/opendir.m4: Update.
1429 * gnulib/import/m4/pathmax.m4: Update.
1430 * gnulib/import/m4/rawmemchr.m4: Update.
1431 * gnulib/import/m4/readdir.m4: Update.
1432 * gnulib/import/m4/readlink.m4: Update.
1433 * gnulib/import/m4/realloc.m4: Update.
1434 * gnulib/import/m4/rename.m4: Update.
1435 * gnulib/import/m4/rewinddir.m4: Update.
1436 * gnulib/import/m4/rmdir.m4: Update.
1437 * gnulib/import/m4/save-cwd.m4: Update.
1438 * gnulib/import/m4/secure_getenv.m4: Update.
1439 * gnulib/import/m4/setenv.m4: Update.
1440 * gnulib/import/m4/signal_h.m4: Update.
1441 * gnulib/import/m4/ssize_t.m4: Update.
1442 * gnulib/import/m4/stat-time.m4: Update.
1443 * gnulib/import/m4/stat.m4: Update.
1444 * gnulib/import/m4/std-gnu11.m4: Update.
1445 * gnulib/import/m4/stdbool.m4: Update.
1446 * gnulib/import/m4/stddef_h.m4: Update.
1447 * gnulib/import/m4/stdint.m4: Update.
1448 * gnulib/import/m4/stdio_h.m4: Update.
1449 * gnulib/import/m4/stdlib_h.m4: Update.
1450 * gnulib/import/m4/strchrnul.m4: Update.
1451 * gnulib/import/m4/strdup.m4: Update.
1452 * gnulib/import/m4/strerror.m4: Update.
1453 * gnulib/import/m4/string_h.m4: Update.
1454 * gnulib/import/m4/strstr.m4: Update.
1455 * gnulib/import/m4/strtok_r.m4: Update.
1456 * gnulib/import/m4/sys_socket_h.m4: Update.
1457 * gnulib/import/m4/sys_stat_h.m4: Update.
1458 * gnulib/import/m4/sys_time_h.m4: Update.
1459 * gnulib/import/m4/sys_types_h.m4: Update.
1460 * gnulib/import/m4/tempname.m4: Update.
1461 * gnulib/import/m4/time_h.m4: Update.
1462 * gnulib/import/m4/unistd-safer.m4: Update.
1463 * gnulib/import/m4/unistd_h.m4: Update.
1464 * gnulib/import/m4/warn-on-use.m4: Update.
1465 * gnulib/import/m4/wchar_h.m4: Update.
1466 * gnulib/import/m4/wchar_t.m4: Update.
1467 * gnulib/import/m4/wctype_h.m4: Update.
1468 * gnulib/import/m4/wint_t.m4: Update.
1469 * gnulib/import/malloc.c: Update.
1470 * gnulib/import/malloc/scratch_buffer.h: Update.
1471 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1472 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1473 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1474 * gnulib/import/malloca.c: Update.
1475 * gnulib/import/malloca.h: Update.
1476 * gnulib/import/malloca.valgrind: Update.
1477 * gnulib/import/math.in.h: Update.
1478 * gnulib/import/mbrtowc.c: Update.
1479 * gnulib/import/mbsinit.c: Update.
1480 * gnulib/import/mbsrtowcs-impl.h: Update.
1481 * gnulib/import/mbsrtowcs-state.c: Update.
1482 * gnulib/import/mbsrtowcs.c: Update.
1483 * gnulib/import/memchr.c: Update.
1484 * gnulib/import/memmem.c: Update.
1485 * gnulib/import/mempcpy.c: Update.
1486 * gnulib/import/memrchr.c: Update.
1487 * gnulib/import/mkdir.c: Update.
1488 * gnulib/import/mkstemp.c: Update.
1489 * gnulib/import/msvc-inval.c: Update.
1490 * gnulib/import/msvc-inval.h: Update.
1491 * gnulib/import/msvc-nothrow.c: Update.
1492 * gnulib/import/msvc-nothrow.h: Update.
1493 * gnulib/import/open.c: Update.
1494 * gnulib/import/openat-die.c: Update.
1495 * gnulib/import/openat-priv.h: Update.
1496 * gnulib/import/openat-proc.c: Update.
1497 * gnulib/import/openat.c: Update.
1498 * gnulib/import/openat.h: Update.
1499 * gnulib/import/opendir.c: Update.
1500 * gnulib/import/pathmax.h: Update.
1501 * gnulib/import/pipe-safer.c: Update.
1502 * gnulib/import/rawmemchr.c: Update.
1503 * gnulib/import/readdir.c: Update.
1504 * gnulib/import/readlink.c: Update.
1505 * gnulib/import/realloc.c: Update.
1506 * gnulib/import/ref-add.sin: Update.
1507 * gnulib/import/ref-del.sin: Update.
1508 * gnulib/import/rename.c: Update.
1509 * gnulib/import/rewinddir.c: Update.
1510 * gnulib/import/rmdir.c: Update.
1511 * gnulib/import/same-inode.h: Update.
1512 * gnulib/import/save-cwd.c: Update.
1513 * gnulib/import/save-cwd.h: Update.
1514 * gnulib/import/scratch_buffer.h: Update.
1515 * gnulib/import/secure_getenv.c: Update.
1516 * gnulib/import/setenv.c: Update.
1517 * gnulib/import/signal.in.h: Update.
1518 * gnulib/import/stat-time.c: Update.
1519 * gnulib/import/stat-time.h: Update.
1520 * gnulib/import/stat-w32.c: Update.
1521 * gnulib/import/stat-w32.h: Update.
1522 * gnulib/import/stat.c: Update.
1523 * gnulib/import/stdbool.in.h: Update.
1524 * gnulib/import/stddef.in.h: Update.
1525 * gnulib/import/stdint.in.h: Update.
1526 * gnulib/import/stdio.in.h: Update.
1527 * gnulib/import/stdlib.in.h: Update.
1528 * gnulib/import/str-two-way.h: Update.
1529 * gnulib/import/strchrnul.c: Update.
1530 * gnulib/import/strdup.c: Update.
1531 * gnulib/import/streq.h: Update.
1532 * gnulib/import/strerror-override.c: Update.
1533 * gnulib/import/strerror-override.h: Update.
1534 * gnulib/import/strerror.c: Update.
1535 * gnulib/import/string.in.h: Update.
1536 * gnulib/import/stripslash.c: Update.
1537 * gnulib/import/strnlen1.c: Update.
1538 * gnulib/import/strnlen1.h: Update.
1539 * gnulib/import/strstr.c: Update.
1540 * gnulib/import/strtok_r.c: Update.
1541 * gnulib/import/sys_stat.in.h: Update.
1542 * gnulib/import/sys_time.in.h: Update.
1543 * gnulib/import/sys_types.in.h: Update.
1544 * gnulib/import/tempname.c: Update.
1545 * gnulib/import/tempname.h: Update.
1546 * gnulib/import/time.in.h: Update.
1547 * gnulib/import/unistd--.h: Update.
1548 * gnulib/import/unistd-safer.h: Update.
1549 * gnulib/import/unistd.in.h: Update.
1550 * gnulib/import/unsetenv.c: Update.
1551 * gnulib/import/verify.h: Update.
1552 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1553 * gnulib/import/wchar.in.h: Update.
1554 * gnulib/import/wctype.in.h: Update.
1555 * gnulib/import/xalloc-oversized.h: Update.
1556 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1557 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1559 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
1561 * record-btrace.c (get_thread_current_frame): Remove
1564 2018-09-10 Jerome Guitton <guitton@adacore.com>
1566 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
1567 with check_tag to 1 if and only if the type is tagged and the
1568 component being searched cannot been found in the current
1569 view. Otherwise, always call ada_to_fixed_type with
1572 2018-09-10 Xavier Roirand <roirand@adacore.com>
1574 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
1576 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
1577 * ada-varobj.c (ada_varobj_get_number_of_children,
1578 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
1580 2018-09-10 Xavier Roirand <roirand@adacore.com>
1582 * ada-valprint.c (ada_value_print): Use type instead of
1585 2018-09-10 Xavier Roirand <roirand@adacore.com>
1587 * ada-lang.c (ada_value_subscript): Handle case when parameter is
1588 an array of access to unconstrained array.
1590 2018-09-10 Xavier Roirand <roirand@adacore.com>
1592 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
1593 (ada_check_typedef): Use it.
1595 2018-09-10 Xavier Roirand <roirand@adacore.com>
1597 * ada-varobj.c (ada_varobj_describe_struct_child)
1598 (ada_varobj_describe_child): Handle union case like struct one.
1600 2018-09-10 Tom Tromey <tom@tromey.com>
1603 * python/python.c (_initialize_python): Make example in "python"
1604 help work in Python 3.
1606 2018-09-10 Eli Zaretskii <eliz@gnu.org>
1608 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
1609 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
1610 $(EXEEXT) to the script, as it is not a program.
1612 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
1614 * python/py-prettyprint.c (pretty_print_one_value): Return
1616 (print_string_repr): Adjust.
1617 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
1618 * python/python-internal.h (apply_varobj_pretty_printer): Return
1620 * varobj.c (varobj_value_get_print_value): Adjust.
1622 2018-09-08 Tom Tromey <tom@tromey.com>
1625 * python/py-prettyprint.c (pretty_print_one_value): Check for
1628 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1630 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
1631 replace_operator_with_call.
1633 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1635 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
1637 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1639 * ada-typeprint.c (print_range): Print the bounds using TYPE
1640 rather than its TYPE_TARGET_TYPE.
1642 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1644 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
1645 call to ada_to_fixed_value_create.
1647 2018-09-08 Jerome Guitton <guitton@adacore.com>
1649 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
1651 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1653 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
1656 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1658 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
1659 Move update of loop variable "fi".
1661 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1663 * ada-lang.c (value_assign_to_component): In the case of
1664 big-endian targets, extract the bits of the given VAL
1665 using an src_offset of zero if container is not a scalar.
1667 2018-09-06 Simon Ser <contact@emersion.fr>
1670 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
1671 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1672 * fbsd-tdep.c (fbsd_make_note_desc): New.
1673 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
1674 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
1675 * target.h (enum target_object) Add FreeBSD-specific
1676 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1678 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1680 * compile/compile-c.h (generate_c_for_variable_locations):
1681 Change reference to pointer.
1682 * compile/compile-c-support.c (compile_program) <compute>:
1684 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
1685 (generate_c_for_for_one_variable): Likewise
1686 (generate_c_for_variable_locations): Likewise
1687 * compile/compile-c-types.c (compile_c_instance::convert_type):
1689 * compile/compile-cplus-symbols.c (convert_one_symbol):
1690 std::move the scope passed to enter_scope.
1691 * compile/compile-cplus-types.c
1692 (compile_cplus_instance::enter_scope): Make parameter
1694 (compile_cplus_instance::new_scope): Change reference to
1696 (compile_cplus_instance::convert_type): Likewise
1697 (compile_cplus_convert_typedef): std::move the scope passed to
1699 (compile_cplus_convert_struct_or_union): Likewise.
1700 (compile_cplus_convert_enum): Likewise.
1701 (compile_cplus_convert_namespace): Likewise.
1702 * compile/compile-cplus.h (compile_cplus_instance)
1703 <enter_scope>: Make parameter rvalue-reference.
1704 * compile/compile-internal.h (compile_instance)
1705 <get_cached_type>: Likewise
1706 * compile/compile-loc2c.c (push): Likewise
1710 (print_label): Likewise
1711 (pushf_register_address): Likewise
1712 (pushf_register): Likewise
1713 (do_compile_dwarf_expr_to_c): Likewise
1714 (compile_dwarf_expr_to_c): Likewise
1715 (compile_dwarf_bounds_to_c): Likewise
1716 * compile/compile.c (compile_instance::get_cached_type):
1718 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
1719 (compile_dwarf_bounds_to_c): Likewise
1720 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
1721 (dwarf2_compile_property_to_c): Likewise
1722 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
1723 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1726 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1728 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
1729 * tui/tui-data.c (init_content_element): Don't initialize it.
1731 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1733 * tui/tui-data.h (struct tui_win_info)
1734 <detail::opaque>: Remove.
1735 * tui/tui-data.c (init_win_info): Remove assignment.
1737 2018-09-05 Tom Tromey <tom@tromey.com>
1739 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
1740 -Wformat-nonliteral.
1741 * target-float.c (host_float_ops<T>::to_string)
1742 (host_float_ops<T>::from_string): Use
1743 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1744 * configure: Rebuild.
1746 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
1748 * printcmd.c (printf_c_string): Use
1749 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1750 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
1752 2018-09-05 Tom Tromey <tom@tromey.com>
1754 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
1756 2018-09-05 Tom de Vries <tdevries@suse.de>
1758 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1759 with resolve_abstract_p == true.
1760 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1761 defaulting to false. Propagate resolve_abstract_p to
1762 dwarf2_fetch_die_loc_sect_off.
1763 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1764 parameter, defaulting to false.
1765 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1766 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1768 * dwarf2read.h (struct die_info): Forward-declare.
1769 (die_info_ptr): New typedef.
1770 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1772 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1776 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1777 Pedro Alves <palves@redhat.com>
1779 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1780 "aclocal-m4-deps.mk". Include file here.
1781 $(srcdir)/aclocal.m4: Add "configure.ac".
1782 * gnulib/aclocal-m4-deps.mk: New file.
1783 * gnulib/update-gnulib.sh: Automatically update
1784 "aclocal-m4-deps.mk".
1786 2018-09-04 Tom Tromey <tom@tromey.com>
1788 * configure: Rebuild.
1789 * configure.ac: Remove multi-ice code.
1791 2018-09-04 Tom Tromey <tom@tromey.com>
1793 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
1794 (ada-exp.o): Update.
1796 2018-09-04 Tom Tromey <tom@tromey.com>
1798 * Makefile.in (printcmd.o, target-float.o): Remove.
1799 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
1801 2018-09-04 Tom Tromey <tom@tromey.com>
1803 * gnulib/Makefile.in: Remove obsolete comment.
1804 * Makefile.in: Remove obsolete comment.
1806 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
1808 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
1811 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1813 * riscv-tdep.c: Add 'prologue-value.h' include.
1814 (struct riscv_unwind_cache): New struct.
1815 (riscv_debug_unwinder): New global.
1816 (riscv_scan_prologue): Update arguments, capture register details
1818 (riscv_skip_prologue): Reformat arguments line, move end of
1819 prologue calculation into riscv_scan_prologue.
1820 (riscv_frame_cache): Update return type, create
1821 riscv_unwind_cache, scan the prologue, and fill in remaining cache
1823 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
1824 (riscv_frame_prev_register): Use the trad_frame within the
1826 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
1829 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1831 * trad-frame.h (trad_frame_set_realreg): Declare.
1832 (trad_frame_set_addr): Declare.
1833 * trad-frame.c (trad_frame_set_realreg): Define new function.
1834 (trad_frame_set_addr): Define new function.
1835 (trad_frame_set_reg_realreg): Use new function.
1836 (trad_frame_set_reg_addr): Use new function.
1838 2018-09-01 Keith Seitz <keiths@redhat.com>
1840 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
1841 pulongest instead of "%lld".
1842 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
1845 2018-08-31 Tom Tromey <tom@tromey.com>
1847 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
1850 2018-08-31 Pedro Alves <palves@redhat.com>
1852 * gdbarch.h: Regenerate.
1854 2018-08-31 Pedro Alves <palves@redhat.com>
1856 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
1857 * target.h (Hardware watchpoint interfaces): Describe
1858 continuable/steppable/non-steppable watchpoints.
1859 * gdbarch.h, gdbarch.c: Regenerate.
1861 2018-08-31 Pedro Alves <palves@redhat.com>
1863 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
1866 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
1867 * target.h (target_ops::have_continuable_watchpoint): Delete.
1868 (target_have_continuable_watchpoint): Delete.
1869 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
1870 * target-delegates.c: Regenerate.
1872 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1874 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
1875 the files present in "gnulib/import/m4/".
1877 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1879 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
1880 c.sw, c.swsp, and c.sdsp.
1882 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1884 * riscv-tdep.c (struct riscv_inferior_data): Delete.
1885 (riscv_read_misa_reg): Don't cache value read into inferior data.
1886 (riscv_new_inferior_data): Delete.
1887 (riscv_inferior_data_cleanup): Delete.
1888 (riscv_inferior_data): Delete.
1889 (riscv_invalidate_inferior_data): Delete.
1890 (_initialize_riscv_tdep): Remove initialisation of inferior data.
1892 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
1894 * compile/compile-cplus-types.c
1895 (compile_cplus_instance::leave_scope): Take the address of scope
1897 (compile_cplus_instance::convert_qualified_base): Compare quals
1900 2018-08-30 Keith Seitz <keiths@redhat.com>
1902 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
1903 Use "%s" and host_address_to_string instead of "%p" in printf.
1905 2018-08-29 Keith Seitz <keiths@redhat.com>
1907 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
1908 and compile-cplus-types.c.
1909 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
1910 * c-lang.c (cplus_language_defn): Set C++ compile functions.
1911 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
1913 * compile/compile-c-support.c: Include compile-cplus.h.
1914 (load_libcompile): Templatize.
1915 (get_compile_context): "New" function.
1916 (c_get_compile_context): Use get_compile_context.
1917 (cplus_get_compile_context): New function.
1918 (cplus_push_user_expression, cplus_pop_user_expression)
1919 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
1920 (cplus_compute_program): Define new structs/functions.
1921 * compile/compile-cplus-symmbols.c: New file.
1922 * compile/compile-cplus-types.c: New file.
1923 * compile/compile-cplus.h: New file.
1924 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
1926 * compile/compile-object-load.c (get_out_value_type): Use
1927 strncmp_iw when comparing symbol names.
1928 (compile_object_load): Add mst_bss and mst_data.
1929 * compile/compile.c (_initialize_compile): Remove
1930 -Wno-implicit-function-declaration from `compile_args'.
1931 * compile/gcc-cp-plugin.h: New file.
1932 * NEWS: Mention C++ compile support and new debug options.
1934 2018-08-29 Keith Seitz <keiths@redhat.com>
1936 * linespec.c (collect_info::add_symbol): Make virtual.
1937 (struct symbol_searcher_collect_info): New struct.
1938 (symbol_searcher::find_all_symbols): New method.
1939 * symtab.h (class symbol_searcher): New class.
1941 2018-08-29 Keith Seitz <keiths@redhat.com>
1943 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1944 Change to vector of block_symbol. Update all users.
1945 (struct collect_info) <symbols>: Likewise.
1946 (collect_info::add_symbol): Take block_symbol as argument.
1948 (decode_compound_collector) <m_symbols>: Change type to vector
1949 of block_symbol. Update all users.
1950 (decode_compound_collector::operator ()): Change parameter type
1952 (find_method, find_function_symbols, find_linespec_symbols)
1953 (find_label_symbols_in_block, find_label_symbols): Change symbol
1954 vectors to block_symbol vectors.
1955 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1958 2018-08-29 Keith Seitz <keiths@redhat.com>
1960 * linespec.c (symbolp): Remove typedef and VEC definitions.
1961 (bound_minimal_symbol_d): Likewise.
1963 2018-08-29 Keith Seitz <keiths@redhat.com>
1965 * linespec.c (decode_compound_collector::decode_compound_collector):
1966 Remove initialization for `m_symtabs'.
1967 (decode_compound_collector::release_symbols): Change return type
1968 to std::vector. Update all callers.
1969 (class decode_compound_collector) <m_symbols>: Change type to
1971 (lookup_prefix_sym): Change return type to std::vector. Update all
1973 (compare_symbols): Remove.
1974 (std_compare_symbols): Rename to `compare_symbols'.
1975 (find_method): Change `sym_classes' parameter to std::vector.
1976 Update all callers. Use std::sort to sort sym_classes.
1977 (find_linespec_symbols): Remove cleanup.
1979 2018-08-29 Keith Seitz <keiths@redhat.com>
1981 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1982 std::vector. Update all users.
1983 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1984 (struct collect_info) <minimal_symbols>: Likewise.
1985 (compare_msymbols): Return bool. Change parameters to const
1986 bound_minimal_symbol references.
1987 (find_method, find_function_symbols, find_linespec_symbols): Change
1988 `minsyms' parameter to std::vector. Update all callers.
1990 2018-08-29 Keith Seitz <keiths@redhat.com>
1992 * linespec.c (struct linespec) <label_symbols>: Change type to
1993 std::vector. Update all users.
1994 (find_label_symbols_in_block): Change `result' parameter to
1995 std::vector. Update all callers.
1996 (find_label_symbols): Return std::vector. Update all callers.
1998 2018-08-29 Keith Seitz <keiths@redhat.com>
2000 * linespec.c (struct linespec) <function_symbols>: Change type to
2001 std::vector. Update all users.
2002 (struct collect_info) <function_symbols>: Likewise.
2003 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
2004 (std_compare_symbols): New function.
2005 (find_method, find_function_symbols, find_linespec_symbols)
2006 (find_label_symbols_in_block): Change `symbols' parameter to
2007 std::vector. Update all callers.
2008 (find_label_symbols): Likewise for `function_symbols' and
2011 2018-08-29 Keith Seitz <keiths@redhat.com>
2013 * linespec.c (symtab_vector_up): Define.
2014 (struct linespec) <file_symtabs>: Change type to std::vector *.
2016 (struct collect_info) <file_symtabs>: Likewise.
2017 (collect_symtabs_from_filename): Return symtab_vector_up.
2019 (decode_objc): Remove cleanup.
2020 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
2021 (symtab_collector::release_symtabs): Return symtab_vector_up.
2023 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
2025 (collect_symtabs_from_filename, symtabs_from_filename): Return
2026 symtab_vector_up. Update all callers.
2028 2018-08-29 Tom Tromey <tom@tromey.com>
2030 * csky-tdep.c (csky_analyze_prologue): Use
2031 core_addr_to_string_nz.
2033 2018-08-29 Tom Tromey <tom@tromey.com>
2035 * windows-nat.c (struct xlate_exception) <them>: Change type to
2037 (xlate): Fix formatting. Remove last entry.
2038 (struct xlate_exception, xlate): Comment out.
2039 (windows_nat_target::resume): Use ranged for.
2041 2018-08-29 Jim Wilson <jimw@sifive.com>
2043 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
2044 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
2046 (riscv_linux_nat_target::store_registers): Likewise.
2048 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
2052 * gnulib/aclocal.m4: Regenerate.
2053 * gnulib/config.in: Regenerate.
2054 * gnulib/configure: Regenerate.
2055 * gnulib/import/Makefile.am: Update.
2056 * gnulib/import/Makefile.in: Update.
2057 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
2058 * gnulib/import/_Noreturn.h: ... this.
2059 * gnulib/import/alloca.in.h: Update.
2060 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
2061 * gnulib/import/arg-nonnull.h: ... this.
2062 * gnulib/import/assure.h: Update.
2063 * gnulib/import/at-func.c: Update.
2064 * gnulib/import/basename-lgpl.c: Update.
2065 * gnulib/import/extra/snippet/c++defs.h: Rename to...
2066 * gnulib/import/c++defs.h: ... this.
2067 * gnulib/import/canonicalize-lgpl.c: Update.
2068 * gnulib/import/cdefs.h: Update.
2069 * gnulib/import/chdir-long.c: Update.
2070 * gnulib/import/chdir-long.h: Update.
2071 * gnulib/import/cloexec.c: Update.
2072 * gnulib/import/cloexec.h: Update.
2073 * gnulib/import/close.c: Update.
2074 * gnulib/import/closedir.c: Update.
2075 * gnulib/import/config.charset: Update.
2076 * gnulib/import/dirent-private.h: Update.
2077 * gnulib/import/dirent.in.h: Update.
2078 * gnulib/import/dirfd.c: Update.
2079 * gnulib/import/dirname-lgpl.c: Update.
2080 * gnulib/import/dirname.h: Update.
2081 * gnulib/import/dosname.h: Update.
2082 * gnulib/import/dup-safer-flag.c: Update.
2083 * gnulib/import/dup-safer.c: Update.
2084 * gnulib/import/dup.c: Update.
2085 * gnulib/import/dup2.c: Update.
2086 * gnulib/import/errno.in.h: Update.
2087 * gnulib/import/error.c: Update.
2088 * gnulib/import/error.h: Update.
2089 * gnulib/import/exitfail.c: Update.
2090 * gnulib/import/exitfail.h: Update.
2091 * gnulib/import/extra/update-copyright: Update.
2092 * gnulib/import/fchdir.c: Update.
2093 * gnulib/import/fcntl.c: Update.
2094 * gnulib/import/fcntl.in.h: Update.
2095 * gnulib/import/fd-hook.c: Update.
2096 * gnulib/import/fd-hook.h: Update.
2097 * gnulib/import/fd-safer-flag.c: Update.
2098 * gnulib/import/fd-safer.c: Update.
2099 * gnulib/import/fdopendir.c: Update.
2100 * gnulib/import/filename.h: Update.
2101 * gnulib/import/filenamecat-lgpl.c: Update.
2102 * gnulib/import/filenamecat.h: Update.
2103 * gnulib/import/flexmember.h: Update.
2104 * gnulib/import/float+.h: Update.
2105 * gnulib/import/float.c: Update.
2106 * gnulib/import/float.in.h: Update.
2107 * gnulib/import/fnmatch.c: Update.
2108 * gnulib/import/fnmatch.in.h: Update.
2109 * gnulib/import/fnmatch_loop.c: Update.
2110 * gnulib/import/fpucw.h: Update.
2111 * gnulib/import/frexp.c: Update.
2112 * gnulib/import/frexpl.c: Update.
2113 * gnulib/import/fstat.c: Update.
2114 * gnulib/import/fstatat.c: Update.
2115 * gnulib/import/getcwd-lgpl.c: Update.
2116 * gnulib/import/getcwd.c: Update.
2117 * gnulib/import/getdtablesize.c: Update.
2118 * gnulib/import/getlogin_r.c: Update.
2119 * gnulib/import/getprogname.c: Update.
2120 * gnulib/import/getprogname.h: Update.
2121 * gnulib/import/gettext.h: Update.
2122 * gnulib/import/gettimeofday.c: Update.
2123 * gnulib/import/glob-libc.h: Update.
2124 * gnulib/import/glob.c: Update.
2125 * gnulib/import/glob.in.h: Update.
2126 * gnulib/import/glob_internal.h: Update.
2127 * gnulib/import/glob_pattern_p.c: Update.
2128 * gnulib/import/globfree.c: Update.
2129 * gnulib/import/hard-locale.c: Update.
2130 * gnulib/import/hard-locale.h: Update.
2131 * gnulib/import/intprops.h: Update.
2132 * gnulib/import/inttypes.in.h: Update.
2133 * gnulib/import/isnan.c: Update.
2134 * gnulib/import/isnand-nolibm.h: Update.
2135 * gnulib/import/isnand.c: Update.
2136 * gnulib/import/isnanl-nolibm.h: Update.
2137 * gnulib/import/isnanl.c: Update.
2138 * gnulib/import/itold.c: Update.
2139 * gnulib/import/libc-config.h: Update.
2140 * gnulib/import/limits.in.h: Update.
2141 * gnulib/import/localcharset.c: Update.
2142 * gnulib/import/localcharset.h: Update.
2143 * gnulib/import/localtime-buffer.c: Update.
2144 * gnulib/import/localtime-buffer.h: Update.
2145 * gnulib/import/lstat.c: Update.
2146 * gnulib/import/m4/00gnulib.m4: Update.
2147 * gnulib/import/m4/__inline.m4: Update.
2148 * gnulib/import/m4/absolute-header.m4: Update.
2149 * gnulib/import/m4/alloca.m4: Update.
2150 * gnulib/import/m4/builtin-expect.m4: Update.
2151 * gnulib/import/m4/canonicalize.m4: Update.
2152 * gnulib/import/m4/chdir-long.m4: Update.
2153 * gnulib/import/m4/close.m4: Update.
2154 * gnulib/import/m4/closedir.m4: Update.
2155 * gnulib/import/m4/configmake.m4: Update.
2156 * gnulib/import/m4/d-ino.m4: Update.
2157 * gnulib/import/m4/d-type.m4: Update.
2158 * gnulib/import/m4/dirent_h.m4: Update.
2159 * gnulib/import/m4/dirfd.m4: Update.
2160 * gnulib/import/m4/dirname.m4: Update.
2161 * gnulib/import/m4/double-slash-root.m4: Update.
2162 * gnulib/import/m4/dup.m4: Update.
2163 * gnulib/import/m4/dup2.m4: Update.
2164 * gnulib/import/m4/eealloc.m4: Update.
2165 * gnulib/import/m4/environ.m4: Update.
2166 * gnulib/import/m4/errno_h.m4: Update.
2167 * gnulib/import/m4/error.m4: Update.
2168 * gnulib/import/m4/exponentd.m4: Update.
2169 * gnulib/import/m4/exponentl.m4: Update.
2170 * gnulib/import/m4/extensions.m4: Update.
2171 * gnulib/import/m4/extern-inline.m4: Update.
2172 * gnulib/import/m4/fchdir.m4: Update.
2173 * gnulib/import/m4/fcntl-o.m4: Update.
2174 * gnulib/import/m4/fcntl.m4: Update.
2175 * gnulib/import/m4/fcntl_h.m4: Update.
2176 * gnulib/import/m4/fdopendir.m4: Update.
2177 * gnulib/import/m4/filenamecat.m4: Update.
2178 * gnulib/import/m4/flexmember.m4: Update.
2179 * gnulib/import/m4/float_h.m4: Update.
2180 * gnulib/import/m4/fnmatch.m4: Update.
2181 * gnulib/import/m4/fnmatch_h.m4: Update.
2182 * gnulib/import/m4/fpieee.m4: Update.
2183 * gnulib/import/m4/frexp.m4: Update.
2184 * gnulib/import/m4/frexpl.m4: Update.
2185 * gnulib/import/m4/fstat.m4: Update.
2186 * gnulib/import/m4/fstatat.m4: Update.
2187 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
2188 * gnulib/import/m4/getcwd-path-max.m4: Update.
2189 * gnulib/import/m4/getcwd.m4: Update.
2190 * gnulib/import/m4/getdtablesize.m4: Update.
2191 * gnulib/import/m4/getlogin.m4: Update.
2192 * gnulib/import/m4/getlogin_r.m4: Update.
2193 * gnulib/import/m4/getpagesize.m4: Update.
2194 * gnulib/import/m4/getprogname.m4: Update.
2195 * gnulib/import/m4/gettimeofday.m4: Update.
2196 * gnulib/import/m4/glibc21.m4: Update.
2197 * gnulib/import/m4/glob.m4: Update.
2198 * gnulib/import/m4/glob_h.m4: Update.
2199 * gnulib/import/m4/gnulib-cache.m4: Update.
2200 * gnulib/import/m4/gnulib-common.m4: Update.
2201 * gnulib/import/m4/gnulib-comp.m4: Update.
2202 * gnulib/import/m4/gnulib-tool.m4: Update.
2203 * gnulib/import/m4/hard-locale.m4: Update.
2204 * gnulib/import/m4/include_next.m4: Update.
2205 * gnulib/import/m4/inttypes-pri.m4: Update.
2206 * gnulib/import/m4/inttypes.m4: Update.
2207 * gnulib/import/m4/isnand.m4: Update.
2208 * gnulib/import/m4/isnanl.m4: Update.
2209 * gnulib/import/m4/largefile.m4: Update.
2210 * gnulib/import/m4/limits-h.m4: Update.
2211 * gnulib/import/m4/localcharset.m4: Update.
2212 * gnulib/import/m4/locale-fr.m4: Update.
2213 * gnulib/import/m4/locale-ja.m4: Update.
2214 * gnulib/import/m4/locale-zh.m4: Update.
2215 * gnulib/import/m4/localtime-buffer.m4: Update.
2216 * gnulib/import/m4/longlong.m4: Update.
2217 * gnulib/import/m4/lstat.m4: Update.
2218 * gnulib/import/m4/malloc.m4: Update.
2219 * gnulib/import/m4/malloca.m4: Update.
2220 * gnulib/import/m4/math_h.m4: Update.
2221 * gnulib/import/m4/mbrtowc.m4: Update.
2222 * gnulib/import/m4/mbsinit.m4: Update.
2223 * gnulib/import/m4/mbsrtowcs.m4: Update.
2224 * gnulib/import/m4/mbstate_t.m4: Update.
2225 * gnulib/import/m4/memchr.m4: Update.
2226 * gnulib/import/m4/memmem.m4: Update.
2227 * gnulib/import/m4/mempcpy.m4: Update.
2228 * gnulib/import/m4/memrchr.m4: Update.
2229 * gnulib/import/m4/mkdir.m4: Update.
2230 * gnulib/import/m4/mkstemp.m4: Update.
2231 * gnulib/import/m4/mmap-anon.m4: Update.
2232 * gnulib/import/m4/mode_t.m4: Update.
2233 * gnulib/import/m4/msvc-inval.m4: Update.
2234 * gnulib/import/m4/msvc-nothrow.m4: Update.
2235 * gnulib/import/m4/multiarch.m4: Update.
2236 * gnulib/import/m4/nocrash.m4: Update.
2237 * gnulib/import/m4/off_t.m4: Update.
2238 * gnulib/import/m4/onceonly.m4: Update.
2239 * gnulib/import/m4/open-cloexec.m4: Update.
2240 * gnulib/import/m4/open.m4: Update.
2241 * gnulib/import/m4/openat.m4: Update.
2242 * gnulib/import/m4/opendir.m4: Update.
2243 * gnulib/import/m4/pathmax.m4: Update.
2244 * gnulib/import/m4/rawmemchr.m4: Update.
2245 * gnulib/import/m4/readdir.m4: Update.
2246 * gnulib/import/m4/readlink.m4: Update.
2247 * gnulib/import/m4/realloc.m4: Update.
2248 * gnulib/import/m4/rename.m4: Update.
2249 * gnulib/import/m4/rewinddir.m4: Update.
2250 * gnulib/import/m4/rmdir.m4: Update.
2251 * gnulib/import/m4/save-cwd.m4: Update.
2252 * gnulib/import/m4/secure_getenv.m4: Update.
2253 * gnulib/import/m4/setenv.m4: Update.
2254 * gnulib/import/m4/signal_h.m4: Update.
2255 * gnulib/import/m4/ssize_t.m4: Update.
2256 * gnulib/import/m4/stat-time.m4: Update.
2257 * gnulib/import/m4/stat.m4: Update.
2258 * gnulib/import/m4/std-gnu11.m4: Update.
2259 * gnulib/import/m4/stdbool.m4: Update.
2260 * gnulib/import/m4/stddef_h.m4: Update.
2261 * gnulib/import/m4/stdint.m4: Update.
2262 * gnulib/import/m4/stdio_h.m4: Update.
2263 * gnulib/import/m4/stdlib_h.m4: Update.
2264 * gnulib/import/m4/strchrnul.m4: Update.
2265 * gnulib/import/m4/strdup.m4: Update.
2266 * gnulib/import/m4/strerror.m4: Update.
2267 * gnulib/import/m4/string_h.m4: Update.
2268 * gnulib/import/m4/strstr.m4: Update.
2269 * gnulib/import/m4/strtok_r.m4: Update.
2270 * gnulib/import/m4/sys_socket_h.m4: Update.
2271 * gnulib/import/m4/sys_stat_h.m4: Update.
2272 * gnulib/import/m4/sys_time_h.m4: Update.
2273 * gnulib/import/m4/sys_types_h.m4: Update.
2274 * gnulib/import/m4/tempname.m4: Update.
2275 * gnulib/import/m4/time_h.m4: Update.
2276 * gnulib/import/m4/unistd-safer.m4: Update.
2277 * gnulib/import/m4/unistd_h.m4: Update.
2278 * gnulib/import/m4/warn-on-use.m4: Update.
2279 * gnulib/import/m4/wchar_h.m4: Update.
2280 * gnulib/import/m4/wchar_t.m4: Update.
2281 * gnulib/import/m4/wctype_h.m4: Update.
2282 * gnulib/import/m4/wint_t.m4: Update.
2283 * gnulib/import/malloc.c: Update.
2284 * gnulib/import/malloc/scratch_buffer.h: Update.
2285 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
2286 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
2287 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
2288 * gnulib/import/malloca.c: Update.
2289 * gnulib/import/malloca.h: Update.
2290 * gnulib/import/malloca.valgrind: Update.
2291 * gnulib/import/math.in.h: Update.
2292 * gnulib/import/mbrtowc.c: Update.
2293 * gnulib/import/mbsinit.c: Update.
2294 * gnulib/import/mbsrtowcs-impl.h: Update.
2295 * gnulib/import/mbsrtowcs-state.c: Update.
2296 * gnulib/import/mbsrtowcs.c: Update.
2297 * gnulib/import/memchr.c: Update.
2298 * gnulib/import/memmem.c: Update.
2299 * gnulib/import/mempcpy.c: Update.
2300 * gnulib/import/memrchr.c: Update.
2301 * gnulib/import/mkdir.c: Update.
2302 * gnulib/import/mkstemp.c: Update.
2303 * gnulib/import/msvc-inval.c: Update.
2304 * gnulib/import/msvc-inval.h: Update.
2305 * gnulib/import/msvc-nothrow.c: Update.
2306 * gnulib/import/msvc-nothrow.h: Update.
2307 * gnulib/import/open.c: Update.
2308 * gnulib/import/openat-die.c: Update.
2309 * gnulib/import/openat-priv.h: Update.
2310 * gnulib/import/openat-proc.c: Update.
2311 * gnulib/import/openat.c: Update.
2312 * gnulib/import/openat.h: Update.
2313 * gnulib/import/opendir.c: Update.
2314 * gnulib/import/pathmax.h: Update.
2315 * gnulib/import/pipe-safer.c: Update.
2316 * gnulib/import/rawmemchr.c: Update.
2317 * gnulib/import/readdir.c: Update.
2318 * gnulib/import/readlink.c: Update.
2319 * gnulib/import/realloc.c: Update.
2320 * gnulib/import/ref-add.sin: Update.
2321 * gnulib/import/ref-del.sin: Update.
2322 * gnulib/import/rename.c: Update.
2323 * gnulib/import/rewinddir.c: Update.
2324 * gnulib/import/rmdir.c: Update.
2325 * gnulib/import/same-inode.h: Update.
2326 * gnulib/import/save-cwd.c: Update.
2327 * gnulib/import/save-cwd.h: Update.
2328 * gnulib/import/scratch_buffer.h: Update.
2329 * gnulib/import/secure_getenv.c: Update.
2330 * gnulib/import/setenv.c: Update.
2331 * gnulib/import/signal.in.h: Update.
2332 * gnulib/import/stat-time.c: Update.
2333 * gnulib/import/stat-time.h: Update.
2334 * gnulib/import/stat-w32.c: Update.
2335 * gnulib/import/stat-w32.h: Update.
2336 * gnulib/import/stat.c: Update.
2337 * gnulib/import/stdbool.in.h: Update.
2338 * gnulib/import/stddef.in.h: Update.
2339 * gnulib/import/stdint.in.h: Update.
2340 * gnulib/import/stdio.in.h: Update.
2341 * gnulib/import/stdlib.in.h: Update.
2342 * gnulib/import/str-two-way.h: Update.
2343 * gnulib/import/strchrnul.c: Update.
2344 * gnulib/import/strdup.c: Update.
2345 * gnulib/import/streq.h: Update.
2346 * gnulib/import/strerror-override.c: Update.
2347 * gnulib/import/strerror-override.h: Update.
2348 * gnulib/import/strerror.c: Update.
2349 * gnulib/import/string.in.h: Update.
2350 * gnulib/import/stripslash.c: Update.
2351 * gnulib/import/strnlen1.c: Update.
2352 * gnulib/import/strnlen1.h: Update.
2353 * gnulib/import/strstr.c: Update.
2354 * gnulib/import/strtok_r.c: Update.
2355 * gnulib/import/sys_stat.in.h: Update.
2356 * gnulib/import/sys_time.in.h: Update.
2357 * gnulib/import/sys_types.in.h: Update.
2358 * gnulib/import/tempname.c: Update.
2359 * gnulib/import/tempname.h: Update.
2360 * gnulib/import/time.in.h: Update.
2361 * gnulib/import/unistd--.h: Update.
2362 * gnulib/import/unistd-safer.h: Update.
2363 * gnulib/import/unistd.in.h: Update.
2364 * gnulib/import/unsetenv.c: Update.
2365 * gnulib/import/verify.h: Update.
2366 * gnulib/import/extra/snippet/warn-on-use.h: Update.
2367 * gnulib/import/wchar.in.h: Update.
2368 * gnulib/import/wctype.in.h: Update.
2369 * gnulib/import/xalloc-oversized.h: Update.
2370 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
2371 "53e2c179f26a890fa6685af4b6c1397ee370433b".
2373 2018-08-16 Gary Benson <gbenson@redhat.com>
2376 * gdb/main.c (captured_main_1): Exit with nonzero status
2377 in batch mode if the last command to be executed failed.
2378 * NEWS: Mention the above.
2380 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
2382 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
2383 end of warning message.
2385 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2388 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
2389 (aarch64_extract_return_value): Use
2390 aapcs_is_vfp_call_or_return_candidate.
2391 (aarch64_return_in_memory): Likewise.
2392 (aarch64_store_return_value): Likewise.
2394 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2397 (aapcs_is_vfp_call_or_return_candidate): Make static
2398 (pass_in_v_or_stack): Remove function.
2399 (pass_in_v_vfp_candidate): New function.
2400 (aarch64_push_dummy_call): Check for float register candidates.
2402 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2404 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
2405 (aapcs_is_vfp_call_or_return_candidate_1): New function.
2406 (aapcs_is_vfp_call_or_return_candidate): Likewise.
2408 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2411 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
2412 (struct ipa_sym_addresses): Rename to...
2413 (struct ipa_sym_addresses_common): ... this.
2414 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
2416 2018-08-28 Tom Tromey <tom@tromey.com>
2418 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2419 (token_fifo): Now a std::vector.
2420 (yylex, c_parse): Update.
2421 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2422 (token_fifo): Now a std::vector.
2423 (yylex, d_parse): Update.
2424 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2425 (token_fifo): Now a std::vector.
2426 (yylex, go_parse): Update.
2428 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
2430 * parser-defs.h (struct type_stack) <elements>: Change type to
2431 std::vector<union type_stack_elt>.
2432 <depth, size>: Remove.
2433 * parse.c (parse_exp_in_context_1): Adjust.
2434 (type_stack_reserve): Remove.
2435 (check_type_stack_depth): Remove.
2436 (insert_into_type_stack): Adjust to std::vector.
2437 (insert_type): Likewise.
2438 (push_type): Likewise.
2439 (push_type_int): Likewise.
2440 (insert_type_address_space): Likewise.
2441 (pop_type): Likewise.
2442 (pop_type_int): Likewise.
2443 (pop_typelist): Likewise.
2444 (pop_type_stack): Likewise.
2445 (append_type_stack): Likewise.
2446 (push_type_stack): Likewise.
2447 (get_type_stack): Likewise.
2448 (type_stack_cleanup): Likewise.
2449 (push_typelist): Likewise.
2450 (follow_types): Likewise.
2451 (_initialize_parse): Likewise.
2453 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
2455 * NEWS: Mention csky target.
2457 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
2458 Hafiz Abid Qadeer <abidh@codesourcery.com>
2459 Don Breazeal <donb@codesourcery.com>
2461 * csky-linux-tdep.c: New file.
2462 * csky-tdep.c: Likewise.
2463 * csky-tdep.h: Likewise.
2464 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
2466 (HFILES_NO_SRCDIR): Add csky-tdep.h.
2467 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
2468 * configure.tgt: Add csky support.
2470 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
2472 * python/py-framefilter.c (py_print_frame): Print frame architecture
2473 when printing on an MI output.
2475 2018-08-27 Tom Tromey <tom@tromey.com>
2478 * configure: Rebuild.
2479 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
2481 2018-08-27 Tom Tromey <tom@tromey.com>
2483 * aarch64-linux-tdep.c
2484 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
2487 2018-08-27 Tom Tromey <tom@tromey.com>
2489 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
2491 (ppc64_standard_linkage1, ppc64_standard_linkage2)
2492 (ppc64_standard_linkage3, ppc64_standard_linkage4)
2493 (ppc64_standard_linkage5, ppc64_standard_linkage6)
2494 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
2497 2018-08-27 Tom Tromey <tom@tromey.com>
2499 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
2500 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
2502 2018-08-27 Tom Tromey <tom@tromey.com>
2504 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
2505 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
2507 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
2509 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
2511 * sparc-linux-tdep.c (sparc32_linux_sigframe)
2512 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
2513 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
2515 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
2516 (ppc64_linux_sigaction_tramp_frame)
2517 (ppc32_linux_sighandler_tramp_frame)
2518 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
2519 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
2520 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
2521 * mn10300-linux-tdep.c (am33_linux_sigframe)
2522 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
2523 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
2524 * mips-linux-tdep.c (mips_linux_o32_sigframe)
2525 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
2526 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
2527 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
2528 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
2529 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
2530 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
2531 * microblaze-linux-tdep.c
2532 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
2533 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
2534 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
2535 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
2536 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
2537 * common/common-types.h (ULONGEST_MAX): New define.
2538 (CORE_ADDR_MAX): Fix formatting.
2539 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
2540 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
2541 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
2542 (arm_linux_rt_sigreturn_tramp_frame)
2543 (arm_eabi_linux_sigreturn_tramp_frame)
2544 (arm_eabi_linux_rt_sigreturn_tramp_frame)
2545 (thumb2_eabi_linux_sigreturn_tramp_frame)
2546 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
2547 (arm_linux_restart_syscall_tramp_frame)
2548 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
2549 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
2550 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
2552 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
2554 2018-08-27 Tom Tromey <tom@tromey.com>
2556 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
2558 * mips-tdep.c (mips_deal_with_atomic_sequence)
2559 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
2560 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
2561 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
2562 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
2564 * aarch64-tdep.c (aarch64_software_single_step): Use
2567 2018-08-27 Tom Tromey <tom@tromey.com>
2569 * linespec.c (complete_linespec_component): Add cast to "char".
2570 * completer.c (completion_tracker::build_completion_result): Add
2573 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2575 * solist.h (struct solist, struct target_so_ops): Fix
2578 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2580 * ada-tasks.c (ada_task_info_s): Remove typedef.
2581 (DEF_VEC_O(ada_task_info_s)): Remove.
2582 (struct ada_tasks_inferior_data): Initialize fields.
2583 <task_list>: Make an std::vector.
2584 (get_ada_tasks_inferior_data): Allocate with new.
2585 (ada_get_task_number): Adjust.
2586 (get_task_number_from_id): Likewise.
2587 (valid_task_id): Likewise.
2588 (ada_get_task_info_from_ptid): Likewise.
2589 (iterate_over_live_ada_tasks): Likewise.
2590 (add_ada_task): Likewise.
2591 (read_known_tasks): Likewise.
2592 (ada_build_task_list): Likewise.
2593 (print_ada_task_info): Likewise.
2594 (info_task): Likewise.
2595 (task_command_1): Likewise.
2597 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2599 * ada-lang.c (add_angle_brackets): Return std::string.
2601 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
2603 * python/py-threadevent.c (py_get_event_thread): Initialize
2606 2018-08-24 Pedro Alves <palves@redhat.com>
2608 * python/py-bpevent.c (create_breakpoint_event_object): Use
2609 copy-initialization.
2610 * python/py-continueevent.c (emit_continue_event): Use
2611 copy-initialization.
2612 * python/py-exitedevent.c (create_exited_event_object): Return a
2614 (emit_exited_event): Use copy-initialization.
2615 * python/py-inferior.c (python_new_inferior)
2616 (python_inferior_deleted, add_thread_object): Use
2617 copy-initialization.
2618 * python/py-infevents.c (create_inferior_call_event_object)
2619 (create_register_changed_event_object)
2620 (create_memory_changed_event_object): Return a gdbpy_ref<>.
2621 (emit_inferior_call_event, emit_memory_changed_event)
2622 (emit_register_changed_event): Use copy-initialization.
2623 * python/py-newobjfileevent.c (create_new_objfile_event_object):
2624 Return a gdbpy_ref<>.
2625 (emit_new_objfile_event): Use copy-initialization.
2626 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
2627 (emit_clear_objfiles_event): Use copy-initialization.
2628 * python/py-signalevent.c (create_signal_event_object): Use
2629 copy-initialization.
2630 * python/py-threadevent.c (create_thread_event_object): Use
2631 copy-initialization.
2633 2018-08-24 Pedro Alves <palves@redhat.com>
2634 Simon Marchi <simon.marchi@ericsson.com>
2637 * python/py-continueevent.c: Include "gdbthread.h".
2638 (create_continue_event_object): Add intro comment. Add 'ptid'
2639 parameter. Use it to find thread to pass to
2640 create_thread_event_object.
2641 (emit_continue_event): Pass PTID down to
2642 create_continue_event_object.
2643 * python/py-event.h (py_get_event_thread): Declare.
2644 (create_thread_event_object): Remove default from 'thread'
2646 * python/py-stopevent.c (create_stop_event_object): Use
2647 py_get_event_thread.
2648 * python/py-threadevent.c (get_event_thread): Rename to ...
2649 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
2650 and use it to find the thread.
2651 (create_thread_event_object): Assert that THREAD isn't null.
2652 Don't find the event thread here.
2654 2018-08-23 Kevin Buettner <kevinb@redhat.com>
2656 * block.h (blockrange, blockranges): New struct declarations.
2657 (struct block): Add new field named `ranges'.
2658 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
2659 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
2660 macros for accessing ranges in struct block.
2661 (make_blockranges): New declaration.
2662 block.c (make_blockranges): New function.
2663 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
2665 * symtab.h (find_pc_partial_function): Add new parameter `block'.
2666 * blockframe.c (cache_pc_function_block): New static global.
2667 (clear_pc_function_cache): Clear cache_pc_function_block.
2668 (find_pc_partial_function): Move comment to symtab.h. Add
2669 support for non-contiguous blocks.
2670 * cli/cli-cmds.c (block.h): Include.
2671 (print_disassembly): Handle printing of non-contiguous blocks.
2672 (disassemble_current_function): Likewise.
2673 (disassemble_command): Likewise.
2675 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
2677 * blockframe.c (get_pc_function_start): Likewise.
2678 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
2679 (gcc_symbol_address): Likewise.
2680 * compile/compile-object-run.c (compile_object_run): Likewise.
2681 * compile/compile.c (get_expr_block_and_pc): Likewise.
2682 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
2683 (func_addr_to_tail_call_list): Likewise.
2684 * findvar.c (default_read_var_value): Likewise.
2685 * inline-frame.c (inline_frame_this_id): Likewise.
2686 (skip-inline_frames): Likewise.
2687 * infcmd.c (until_next_command): Likewise.
2688 * linespec.c (convert_linespec_to_sals): Likewise.
2689 * parse.c (parse_exp_in_context_1): Likewise.
2690 * printcmd.c (build_address_symbolic): likewise.
2691 (info_address_command): Likewise.
2692 symtab.c (find_function_start_sal): Likewise.
2693 (skip_prologue_sal): Likewise.
2694 (find_function_alias_target): Likewise.
2695 (find_gnu_ifunc): Likewise.
2696 * stack.c (find_frame_funname): Likewise.
2697 * symtab.c (fixup_symbol_section): Likewise.
2698 (find_function_start_sal): Likewise.
2699 (skip_prologue_sal): Likewsie.
2700 (find_function_alias_target): Likewise.
2701 (find_gnu_ifunc): Likewise.
2702 * tracepoint.c (info_scope_command): Likewise.
2703 * value.c (value_fn_field): Likewise.
2705 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
2706 in place of find_pc_partial_function.
2707 * blockframe.c (find_function_entry_range_from_pc): New function.
2708 * symtab.h (find_function_entry_range_from_pc): Declare and document.
2709 * objfiles.c (objfile_relocate1): Relocate start and end addresses
2710 for each range in a block.
2713 2018-08-23 Xavier Roirand <roirand@adacore.com>
2715 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
2718 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2720 * solib-svr4.c (read_program_headers_from_bfd): Return
2721 gdb::optional<gdb::byte_vector>.
2722 (svr4_exec_displacement): Adjust.
2724 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2726 * solib-svr4.c (read_program_header): Return
2727 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
2728 (find_program_interpreter): Return
2729 gdb::optional<gdb::byte_vector>.
2730 (scan_dyntag_auxv): Adjust.
2731 (enable_break): Adjust.
2732 (svr4_exec_displacement): Adjust.
2734 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2736 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
2737 * inf-child.c (inf_child_target::terminal_save_inferior): New.
2739 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2741 * guile/scm-string.c (gdbscm_scm_from_printf): Use
2743 * guile/scm-utils.c (gdbscm_printf): Likewise.
2744 * serial.c (serial_printf): Likewise.
2745 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
2747 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
2749 * stack.c (print_frame): Print frame architecture when printing on
2751 * NEWS: Mention new "arch" attribute in frame output.
2753 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2755 * arch/aarch64.h (aarch64_regnum): Update comment.
2757 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2759 * NEWS: Add SVE to 8.2 section.
2761 2018-08-21 Pedro Alves <palves@redhat.com>
2763 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2764 out from gdbscm_parse_function_args.
2765 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2766 gdbscm_parse_function_args_1.
2768 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2771 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2774 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2776 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2778 2018-08-19 Michael Spang <spang@google.com>
2781 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2782 for PT_TLS segments.
2784 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2786 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2787 dwarf_variable_value.
2788 * dwarf2-frame.c (class dwarf_expr_executor):
2789 Add override for dwarf_variable_value.
2790 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2791 (class symbol_needs_eval_context): Likewise.
2792 (indirect_synthetic_pointer): Add forward declaration.
2793 (sect_variable_value): New function.
2794 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
2795 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
2796 for DW_OP_GNU_variable_value.
2798 2018-08-16 Tom Tromey <tom@tromey.com>
2800 * top.c (read_command_file): Update.
2801 (command_line_input): Remove "repeat" argument.
2802 * ada-lang.c (get_selections): Update.
2803 * linespec.c (decode_line_2): Update.
2804 * defs.h (command_line_input): Remove argument.
2805 * cli/cli-script.c (read_next_line): Update.
2806 * python/py-gdb-readline.c: Update.
2808 2018-08-17 Tom Tromey <tom@tromey.com>
2810 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
2813 2018-08-15 Tom Tromey <tom@tromey.com>
2815 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
2817 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
2819 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
2820 If used, use find_pc_partial_function to find address range
2822 * mi/mi-main.c (mi_cmd_list_features): Report
2823 "data-disassemble-a-option" feature.
2824 * NEWS: Mention new -data-disassemble option -a.
2826 2018-08-13 Tom Tromey <tom@tromey.com>
2828 * common/common-defs.h (_FORTIFY_SOURCE): Define.
2830 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2832 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
2833 (aarch64_linux_collect_sve_regset): Likewise.
2834 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
2835 * regcache.h (regcache_map_entry_size): New function.
2837 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2839 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
2840 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
2841 (SVE_HEADER_VL_LENGTH): Likewise.
2842 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
2843 (SVE_HEADER_FLAGS_LENGTH): Likewise.
2844 (SVE_HEADER_RESERVED_LENGTH): Likewise.
2845 (SVE_HEADER_SIZE_OFFSET): Likewise.
2846 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
2847 (SVE_HEADER_VL_OFFSET): Likewise.
2848 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
2849 (SVE_HEADER_FLAGS_OFFSET): Likewise.
2850 (SVE_HEADER_RESERVED_OFFSET): Likewise.
2851 (SVE_HEADER_SIZE): Likewise.
2852 (aarch64_linux_core_read_vq): Add function.
2853 (aarch64_linux_core_read_description): Check for SVE section.
2855 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2857 * aarch64-fbsd-tdep.c
2858 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
2860 * aarch64-linux-tdep.c
2861 (aarch64_linux_iterate_over_regset_sections): Likewise.
2862 * alpha-linux-tdep.c
2863 (alpha_linux_iterate_over_regset_sections):
2865 (alphanbsd_iterate_over_regset_sections): Likewise.
2867 (amd64fbsd_iterate_over_regset_sections): Likewise.
2868 * amd64-linux-tdep.c
2869 (amd64_linux_iterate_over_regset_sections): Likewise.
2871 (armbsd_iterate_over_regset_sections): Likewise.
2873 (arm_fbsd_iterate_over_regset_sections): Likewise.
2875 (arm_linux_iterate_over_regset_sections): Likewise.
2876 * corelow.c (get_core_registers_cb): Likewise.
2877 (core_target::fetch_registers): Likewise.
2878 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
2879 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
2880 * gdbarch.h (void): Regenerate.
2881 * gdbarch.sh: Add supply_size and collect_size.
2882 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
2883 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
2884 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
2885 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
2886 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
2887 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
2888 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
2889 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
2890 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
2891 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
2892 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
2893 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
2894 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
2895 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
2896 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
2897 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
2898 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
2899 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
2900 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
2901 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
2902 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
2903 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
2904 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
2905 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
2906 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
2907 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
2908 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
2909 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
2910 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
2911 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
2913 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
2915 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
2918 2018-08-10 Keith Seitz <keiths@redhat.com>
2920 * compile/compile-c-support.c (add_code_header, add_code_footer):
2921 Move into policy class.
2922 (c_push_user_expression, pop_user_expression_nop)
2923 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
2924 (compile_program): New host class.
2925 (c_compile_program): New typedef.
2926 (c_compute_porgram): Use c_compile_program.
2928 2018-08-10 Keith Seitz <keiths@redhat.com>
2930 * compile/compile-internal.h (compile_instance::~compile_instance):
2931 Remove calls to htab_delete.
2932 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
2933 * compile.c (compile_instance::compile_instance): Initialize
2934 htab unique pointers.
2935 (compile_instance::get_cached_type, compile_instance::insert_type)
2936 (compile_instance::error_symbol_once): Update for unique_ptr.
2938 2018-08-10 Keith Seitz <keiths@redhat.com>
2940 * compile/compile-c-symbols.c (struct symbol_error)
2941 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2942 (compile_instance::insert_symbol_error)
2943 (compile_instance::error_symbol_once): Move to ...
2944 * compile/compile.c: ... here.
2946 2018-08-10 Keith Seitz <keiths@redhat.com>
2948 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2949 instead of `new_compile_instance'.
2950 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2952 If the symbol error map is not initialized, create it.
2953 (generate_c_for_for_one_symbol): Do not check/initialize
2954 the symbol error map.
2955 * compile/compile-c-types.c (compile_c_instance): Make a class.
2957 (compile_instance::compile_instance): Initialize the type cache.
2958 (get_cached_type): New function.
2959 (insert_type): Update description.
2960 (compile_c_instance::m_default_cflags): Define.
2961 (convert_type): Update description. Use get_cached_type.
2962 (delete_instance): Moved to destructor.
2963 (new_compile_instance): Moved to constructor.
2964 * compile/compile-c.h (compile_c_instance): Make class inheriting
2965 from compile_instance.
2966 <base>: Remove field.
2967 <type_map, symbol_err_map>: Move to base class.
2968 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2969 * compile/compile-internal.h (compile_instance): Make class.
2970 <type_map_t, symbol_err_map_t>: Define.
2971 <fe>: Rename to `m_gcc_fe'.
2972 <scope, block, gcc_target_options>: Add `m_' prefix.
2973 <m_type_map, m_symbol_err_map>: New fields, moved from
2976 (convert_type, new_compile_instance): Remove.
2977 * compile/compile.c (cleanup_compile_instance): Remove.
2978 (compile_to_object): Use unique_ptr to eliminate cleanups.
2979 (compile_instance::set_print_callback, compile_instance::version)
2980 (compile_instance::set_verbose)
2981 (compile_instance::set_driver_filename)
2982 (compile_instance::set_triplet_regexp)
2983 (compile_instance::set_arguments)
2984 (compile_instance::set_source_file)
2985 (compile_instance::compile): Define.
2987 2018-08-10 Keith Seitz <keiths@redhat.com>
2989 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2990 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2991 gcc-c-fe.def to define C plugin.
2992 (delete_instance): Delete `c_plugin'.
2993 (new_compile_instance): Initialize `c_plugin'.
2994 * compile/compile-c.h: Include gcc_c_plugin.h.
2995 (struct compile_c_instance) <c_plugin>: New member.
2996 * gcc-c-plugin.h: New file.
2997 Update all callers with API change.
2999 2018-08-10 Keith Seitz <keiths@redhat.com>
3001 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
3002 (HFILES_NO_SRCDIR): ... to here.
3003 Add compile-internal.h and compile-c.h.
3004 * compile/compile-c-support.c: Include compile-c.h.
3005 * compile/compile-c-symbols.c: Include compile-c.h.
3006 (generate_c_for_variable_locations): Update comment.
3007 * compile/compile-c-types.c: Include compile-c.h.
3008 * compile/compile-c.h: New file -- moved C language declarations
3009 from other files here.
3010 * compile/compile-internal.h: Do not include hashtab.h or
3011 common/enum-flags.h.
3012 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
3013 (gcc_convert_symbol, gcc_symbol_address)
3014 (generate_c_for_variable_locations, c_get_mode_for_size)
3015 (c_get_range_decl_name): Definitions moved to compile-c.h.
3016 * compile/compile-loc2c.c: Include compile-c.h.
3018 2018-08-10 Keith Seitz <keiths@redhat.com>
3020 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
3021 (c_symbol_substitution_name): ... this.
3024 2018-08-10 Keith Seitz <keiths@redhat.com>
3026 * compile/compile-c-support.c (c_compute_program): Use
3027 unique_xmalloc_ptr to eliminate cleanup.
3028 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
3029 Return a unique_xmalloc_ptr and eliminate cleanup.
3030 * compile/compile-internal.h (generate_c_for_variable_locations):
3031 Return unique_xmalloc_ptr and update description.
3033 2018-08-10 Alan Hayward <alan.hayward@arm.com>
3035 * corelow.c (core_target::get_core_register_section): Rename
3036 min_size to section_min_size.
3038 2018-08-09 Jim Wilson <jimw@sifive.com>
3040 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
3041 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
3042 * NEWS: Mention new GNU/Linux RISC-V target.
3043 * configure.host: Add riscv*-*-linux*.
3044 * configure.nat: Add riscv*.
3045 * configure.tgt: Add riscv*-*-linux*.
3046 * riscv-linux-nat.c: New file.
3047 * riscv-linux-tdep.c: New file.
3049 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3051 * infrun.c (resume): Make static, add forward declaration.
3052 (proceed): Update header comment.
3053 * infrun.h (resume): Delete declaration.
3055 2018-08-09 Tom Tromey <tom@tromey.com>
3057 * riscv-tdep.h: Minor formatting fixes.
3059 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
3061 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
3062 * dwarf-index-cache.c (create_dir_and_check): Likewise.
3063 (test_mkdir_recursive): Likewise.
3064 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
3066 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3068 * valarith.c (value_subscripted_rvalue): If an array is not in
3069 memory, and we don't know the upper bound, then we can't know that
3070 the requested element exists or not.
3072 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
3074 * target.c (str_comma_list_concat_elem): Fix typo in comment.
3075 (target_options_to_string): Add comment.
3077 2018-08-08 Tom Tromey <tom@tromey.com>
3079 * unittests/scoped_mmap-selftests.c: Check result of "write".
3081 2018-08-08 Jim Wilson <jimw@sifive.com>
3083 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
3084 (decode_register_index_short): New.
3085 (decode_j_type_insn, decode_cj_type_insn): New.
3086 (decode_b_type_insn, decode_cb_type_insn): New.
3087 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
3088 local xlen. Check xlen when decoding ambiguous compressed insns. In
3089 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
3090 is_c_sw_insn instead of is_sw_insn.
3091 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
3092 (riscv_software_single_step): New.
3093 * riscv-tdep.h (riscv_software_single_step): Declare.
3095 * riscv-tdep.c (riscv_isa_xlen): Drop static.
3096 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
3098 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
3101 * target.c (dispose_inferior): Don't dispose of inferiors that are
3104 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
3106 * remote.c (remote_target::download_tracepoint): Change char* to
3109 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
3111 * target.h (target_options_to_string): Return an std::string.
3112 * target.c (str_comma_list_concat_elem): Return void, use
3114 (do_option): Likewise.
3115 (target_options_to_string): Return an std::string.
3116 * linux-nat.c (linux_nat_target::wait): Adjust.
3117 * target-debug.h (target_debug_print_options): Adjust.
3119 2018-08-07 Tom Tromey <tom@tromey.com>
3121 * Makefile.in (CPPFLAGS): New variable.
3122 (INTERNAL_CPPFLAGS): Use it.
3124 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3126 * NEWS: Mention the index cache.
3128 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3130 * common/pathstuff.h (get_standard_cache_dir): New.
3131 * common/pathstuff.c (get_standard_cache_dir): New.
3132 * build-id.h (build_id_to_string): New.
3133 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
3134 DEBUG_STR_SUFFIX): Move to here.
3135 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
3136 DEBUG_STR_SUFFIX): Move from there.
3137 (write_psymtabs_to_index): Make non-static, add basename
3138 parameter. Write to temporary files, rename when done.
3139 (save_gdb_index_command): Adjust call to
3140 write_psymtabs_to_index.
3141 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
3143 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
3144 (get_gdb_index_contents_from_cache): New.
3145 (get_gdb_index_contents_from_cache_dwz): New.
3146 (dwarf2_initialize_objfile): Read index from cache.
3147 (dwarf2_build_psymtabs): Save to index.
3148 * dwarf-index-cache.h: New file.
3149 * dwarf-index-cache.c: New file.
3150 * dwarf-index-write.h: New file.
3152 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3154 * gnulib/aclocal.m4: Re-generate.
3155 * gnulib/config.in: Re-generate.
3156 * gnulib/configure: Re-generate.
3157 * gnulib/import/Makefile.am: Re-generate.
3158 * gnulib/import/Makefile.in: Re-generate.
3159 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3160 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3161 * gnulib/import/m4/mkdir.m4: New file.
3162 * gnulib/import/mkdir.c: New file.
3163 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
3166 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3168 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
3169 * common/scoped_mmap.c: New file.
3170 * common/scoped_mmap.h (destroy): New method.
3171 (~scoped_mmap, reset): Use destroy.
3172 (scoped_mmap): New move constructor.
3173 (mmap_file): New declaration.
3174 * unittests/scoped_mmap-selftests.c (test_normal,
3175 test_invalid_filename, run_tests): New functions.
3176 (_initialize_scoped_mmap_selftests): Register selftest.
3178 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3180 * dwarf2read.c (read_gdb_index_from_section): Rename to...
3181 (read_gdb_index_from_buffer): ... this. Remove section
3182 parameter, add buffer parameter.
3183 (get_gdb_index_contents_ftype,
3184 get_gdb_index_contents_dwz_ftype): New typedefs.
3185 (dwarf2_read_gdb_index): Add callback parameters to get the
3187 (get_gdb_index_contents_from_section): New.
3188 (dwarf2_initialize_objfile): Update call to
3189 dwarf2_read_gdb_index.
3191 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3193 * common/filestuff.h (gdb_fopen_cloexec): New overload.
3194 (gdb_open_cloexec): Likewise.
3195 * nat/linux-osdata.c (command_from_pid): Use string_printf.
3196 (commandline_from_pid): Likewise.
3197 (linux_xfer_osdata_threads): Likewise.
3198 (linux_xfer_osdata_fds): Likewise.
3199 * ada-lang.c (is_package_name): Likewise.
3200 * auxv.c (procfs_xfer_auxv): Likewise.
3201 * breakpoint.c (print_one_breakpoint_location): Use
3203 (print_one_catch_solib): Use string_printf.
3204 * coff-pe-read.c (add_pe_exported_sym): Likewise.
3205 (add_pe_forwarded_sym): Likewise.
3206 * dwarf2read.c (create_type_unit_group): Likewise.
3207 (build_error_marker_type): Likewise.
3208 * infcall.c (get_function_name): Likewise.
3209 * valprint.c (print_converted_chars_to_obstack): Likewise.
3210 * xtensa-tdep.c (xtensa_register_type): Likewise.
3212 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
3214 * remote.c (remote_target::download_tracepoint): Fix format
3217 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3219 * tracefile.c: Include common/byte-vector.h.
3220 (trace_save): Change type of buf to gdb::byte_vector. Initialize
3221 with trace_regblock_size if needed. Update uses of buf.
3223 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3225 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
3226 std::vector<unsigned char>.
3227 * tracepoint.c (collection_list::collection_list): Remove
3228 m_regs_mask initializer from initializer list. Resize
3229 m_regs_mask using the largest remote register number.
3230 (collection_list::add_remote_register): Remove size check on
3231 m_regs_mask. Use at to access element.
3232 (collection_list::stringify): Change type of temp_buf to
3233 gdb::char_vector. Update uses of temp_buf. Resize if needed to
3234 stringify the register mask. Use pack_hex_byte for the register
3237 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3239 * tracepoint.h (class collection_list) <add_register>: Remove.
3240 <add_remote_register, add_ax_registers, add_local_register>:
3242 <add_memrange>: Add scope parameter.
3243 * tracepoint.c (encode_actions_1): Likewise.
3244 (collection_list::add_register): Rename to ...
3245 (collection_list::add_remote_register): ... this. Update
3247 (collection_list::add_ax_registers, add_local_register): New
3249 (collection_list::add_memrange): Add scope parameter. Call
3250 add_local_register instead of add_register.
3251 (finalize_tracepoint_aexpr): New function.
3252 (collection_list::collect_symbol): Update calls to add_memrange.
3253 Call add_local_register instead of add_register. Call
3254 add_ax_registers. Call finalize_tracepoint_aexpr.
3255 (encode_actions_1): Get remote regnos for $reg action. Call
3256 add_remote_register, add_ax_registers, and add_local_register.
3257 Update call to add_memrange. Call finalize_tracepoint_aexpr.
3258 (validate_actionline): Call finalize_tracepoint_aexpr.
3260 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3262 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
3263 Replace array buf with gdb::char_vector buf, of size
3264 get_remote_packet_size (). Replace references to buf and
3265 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
3266 and xsnprintf with snprintf. Raise errors if the buffer is too
3269 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3271 * remote.c (remote_target::download_tracepoint): Fix the has_more
3272 predicate in the QTDP action list iteration.
3274 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3276 * remote.c (remote_target::download_tracepoint): Fix indentation
3279 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3281 * proc-api.c (_initialize_proc_api): Remove c, unused.
3282 * procfs.c (procfs_init_inferior): Remove signals, unused.
3283 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
3286 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
3287 Andrew Burgess <andrew.burgess@embecosm.com>
3289 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
3290 'W_STOPCODE (0)' as this could be ambiguous.
3292 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
3294 * ser-tcp.c (net_open): Fix thinko when deciding whether to
3295 disable TCP's Nagle algorithm (use "ai_protocol" instead of
3298 2018-08-02 Tom Tromey <tom@tromey.com>
3301 * dwarf2read.c (read_func_scope): Set symtab on template parameter
3303 (process_structure_scope): Likewise.
3305 2018-08-02 Xavier Roirand <roirand@adacore.com>
3308 * darwin-nat.c (darwin_kill_inferior): Fix handling of
3311 2018-08-02 Tom Tromey <tom@tromey.com>
3313 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
3314 (darwin_suspend_inferior, darwin_resume_inferior)
3315 (darwin_decode_notify_message, darwin_resume_inferior_threads)
3316 (darwin_check_new_threads): Check result of get_darwin_inferior.
3318 2018-07-31 Joel Brobecker <brobecker@adacore.com>
3322 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
3324 * varobj.c (varobj_get_path_expr_parent): Report an error if
3325 parent is a dynamic varobj.
3327 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3329 * gnulib/aclocal.m4: Re-generate.
3330 * gnulib/config.in: Re-generate.
3331 * gnulib/configure: Re-generate.
3332 * gnulib/import/Makefile.in: Re-generate.
3333 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3334 * gnulib/import/m4/onceonly.m4: Re-generate.
3336 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3338 * target-descriptions.c (struct xml_test_tdesc): New.
3339 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
3340 (record_xml_tdesc): Update.
3341 (maintenance_check_xml_descriptions): Update.
3342 * target-descriptions.h (record_xml_tdesc): Update comment.
3344 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
3346 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
3347 checking array bounds are defined.
3349 2018-07-30 Tom Tromey <tom@tromey.com>
3351 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
3352 irreflexivity violation.
3354 2018-07-30 Tom Tromey <tom@tromey.com>
3356 * cli/cli-decode.c (lookup_cmd): Remove lint code.
3357 * value.c (unpack_long): Remove lint code.
3358 * valops.c (value_ind): Remove lint code.
3359 * valarith.c (value_x_binop, value_x_unop, value_equal)
3360 (value_pos): Remove lint code.
3362 2018-07-28 Tom de Vries <tdevries@suse.de>
3364 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
3365 with undefined upper bound as <optimized out>.
3367 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
3369 * gcore.in: Rename variable "name" to "prefix". Expand
3372 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
3374 * windows-nat.c (windows_nat_target::create_inferior): Update to
3375 call close() in global namespace.
3377 2018-07-26 Tom Tromey <tom@tromey.com>
3379 * dwarf-index-write.c (add_address_entry): Don't add objfile
3381 * dbxread.c (find_stab_function): Rename from
3382 find_stab_function_addr. Return a bound_minimal_symbol.
3383 (read_dbx_symtab): Use raw_text_low, raw_text_high.
3384 Don't add objfile offsets.
3385 (end_psymtab): Use raw_text_low, raw_text_high,
3386 MSYMBOL_VALUE_RAW_ADDRESS.
3387 (read_ofile_symtab): Update.
3388 (process_one_symbol): Update.
3389 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
3391 (dw2_relocate): Remove.
3392 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
3394 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
3396 (process_psymtab_comp_unit_reader, add_partial_symbol)
3397 (add_partial_subprogram, dwarf2_ranges_read): Update.
3398 (load_partial_dies): Update.
3399 (add_address_entry): Don't add objfile offsets.
3400 (dwarf2_build_include_psymtabs): Update.
3401 (create_addrmap_from_aranges): Don't add objfile offsets.
3402 (dw2_find_pc_sect_compunit_symtab): Update.
3403 * mdebugread.c (parse_symbol): Don't add objfile offsets.
3404 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
3406 (parse_partial_symbols): Don't add objfile offsets. Use
3407 raw_text_low, raw_text_high. Update.
3408 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
3409 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
3410 or call 'relocate' quick function. Clear psymbol_map.
3411 * psympriv.h (struct partial_symbol) <address>: Add section
3413 <set_unrelocated_address>: Rename from set_address.
3414 <raw_text_low, raw_text_high>: New methods.
3415 <text_low, text_high>: Add objfile parameter.
3416 (add_psymbol_to_bcache): Add 'section' parameter. Call
3417 set_unrelocated_address.
3418 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3419 (find_pc_psymbol): Update.
3420 (fixup_psymbol_section, relocate_psymtabs): Remove.
3421 (dump_psymtab, psym_functions): Update.
3422 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
3424 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
3425 (start_psymtab_common): Update.
3426 * symfile-debug.c (debug_qf_relocate): Remove.
3427 (debug_sym_quick_functions): Update.
3428 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
3429 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
3432 2018-07-26 Tom Tromey <tromey@redhat.com>
3434 * dbxread.c (end_psymtab): Use text_high_valid and
3436 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
3437 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
3438 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
3440 <text_low_valid, text_high_valid>: New fields.
3441 <set_text_low, set_text_high>: Update.
3442 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
3444 2018-07-26 Tom Tromey <tom@tromey.com>
3446 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
3448 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
3449 textlow and texthigh fields.
3450 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
3452 * mdebugread.c (parse_lines, parse_partial_symbols)
3453 (psymtab_to_symtab_1): Update.
3454 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
3455 Rename fields. Update comment. Now private.
3456 <text_low, text_high, set_text_low, set_text_high>: New methods.
3457 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3458 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
3459 (start_psymtab_common, maintenance_info_psymtabs)
3460 (maintenance_check_psymtabs): Update.
3461 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
3463 (scan_xcoff_symtab): Update.
3465 2018-07-26 Tom Tromey <tromey@redhat.com>
3467 * psympriv.h (struct partial_symbol) <unrelocated_address,
3468 address, set_address>: New methods.
3469 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
3470 (fixup_psymbol_section, relocate_psymtabs): Update.
3471 (print_partial_symbols): Add 'objfile' parameter. Update.
3472 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
3475 2018-07-26 Tom Tromey <tom@tromey.com>
3477 * dwarf-index-write.c (write_psymbols, debug_names::insert)
3478 (debug_names::write_psymbols): Update.
3479 * psympriv.h (struct partial_symbol): Derive from
3480 general_symbol_info.
3481 <obj_section>: New method.
3482 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
3483 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3484 (find_pc_sect_psymbol, fixup_psymbol_section)
3485 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
3486 (print_partial_symbols, recursively_search_psymtabs)
3487 (compare_psymbols, psymbol_hash, psymbol_compare)
3488 (add_psymbol_to_bcache, maintenance_check_psymtabs)
3489 (psymbol_name_matches, psym_fill_psymbol_map): Update.
3491 2018-07-26 Tom Tromey <tromey@redhat.com>
3493 * dbxread.c (end_psymtab): Remove dead code.
3495 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
3497 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
3498 DWARF unwinders are disabled.
3499 * dwarf2-frame.c: Add dwarf2read.h include.
3500 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
3502 (dwarf2_frame_unwinders_enabled_p): Define.
3503 (show_dwarf_unwinders_enabled_p): New function.
3504 (_initialize_dwarf2_frame): Register switch to control DWARF
3506 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
3507 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
3508 (show_dwarf_cmdlist): Remove static keyword.
3509 * dwarf2read.h (set_dwarf_cmdlist): Declare.
3510 (show_dwarf_cmdlist): Declare.
3511 * NEWS: Document new feature.
3513 2018-07-26 Tom de Vries <tdevries@suse.de>
3515 PR breakpoints/23366
3516 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
3518 2018-07-26 Tom de Vries <tdevries@suse.de>
3520 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
3521 DW_AT_count can't be translated to a dynamic prop.
3523 2018-07-25 Tom de Vries <tdevries@suse.de>
3525 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
3528 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
3530 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
3532 2018-07-25 Joel Brobecker <brobecker@adacore.com>
3534 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
3536 2018-07-24 Keith Seitz <keiths@redhat.comt
3539 * dwarf2read.c (dw2_add_symbol_to_list): New function.
3540 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
3541 instead of add_symbol_to_list.
3542 (read_file_scope): Call prepare_one_comp_unit before reading
3545 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
3547 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
3549 2018-07-24 Tom Tromey <tom@tromey.com>
3551 * utils.c (malloc, realloc, free): Don't declare.
3552 * configure, config.in: Rebuild.
3553 * configure.ac: Don't check for declarations of free, malloc, or
3556 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3558 * aarch64-linux-nat.c
3559 (aarch64_linux_nat_target::stopped_data_address): Remove unused
3561 * arm-linux-nat.c (fetch_regs): Likewise.
3562 (store_regs): Likewise.
3563 (fetch_vfp_regs): Likewise.
3564 (store_vfp_regs): Likewise.
3565 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
3566 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
3567 (arm_linux_nat_target::insert_watchpoint): Likewise.
3568 (arm_linux_nat_target::remove_watchpoint): Likewise.
3569 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
3571 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
3573 * ppc-linux-nat.c (fetch_register): Likewise.
3574 (fetch_all_gp_regs): Likewise.
3575 (fetch_ppc_registers): Likewise.
3576 (store_all_gp_regs): Likewise.
3577 (store_ppc_registers): Likewise.
3578 (hwdebug_insert_point): Likewise.
3579 (can_use_watchpoint_cond_accel): Likewise.
3580 * remote-sim.c (gdb_os_write_stdout): Likewise.
3582 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3583 Tom Tromey <tom@tromey.com>
3585 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
3587 * configure: Rebuild.
3589 2018-07-22 Tom Tromey <tom@tromey.com>
3591 * regformats/regdat.sh: Define xmltarget_${name} inside
3592 #ifndef IN_PROCESS_AGENT.
3594 2018-07-22 Tom Tromey <tom@tromey.com>
3596 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
3598 2018-07-22 Tom Tromey <tom@tromey.com>
3600 * symfile.c (reread_symbols): Notify iter, not objfile.
3602 2018-07-22 Tom Tromey <tom@tromey.com>
3604 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
3606 (ravenscar_thread_target::prepare_to_store): Likewise.
3608 2018-07-22 Tom Tromey <tom@tromey.com>
3610 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
3611 unused variable. Call value_fetch_lazy when needed.
3612 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
3613 Remove unused variable. Call value_fetch_lazy when needed.
3615 2018-07-22 Tom Tromey <tom@tromey.com>
3617 * m32c-tdep.c (mark_dma): Return void.
3618 (make_regs): Remove unused declarations.
3620 2018-07-22 Tom Tromey <tom@tromey.com>
3622 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
3623 cmdscm_get_valid_command_smob_arg_unsafe for effect.
3624 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
3625 bkscm_get_valid_block_smob_arg_unsafe for effect.
3627 2018-07-22 Tom Tromey <tom@tromey.com>
3629 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
3632 2018-07-22 Tom Tromey <tom@tromey.com>
3634 * windows-nat.c (saved_context): Conditionally define.
3635 * remote.c (remote_target::remote_btrace_maybe_reopen):
3636 Conditionally declare "warned".
3637 * inflow.c (sigquit_ours): Conditionally define.
3638 (new_tty): Move "tty" declaration inside #if.
3639 * guile/guile.c (guile_datadir): Conditionally define.
3640 * charset.c (set_be_le_names): Move some declarations inside #if.
3641 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
3643 (parse_xml_btrace_conf): Likewise.
3645 2018-07-22 Tom Tromey <tom@tromey.com>
3647 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
3649 2018-07-22 Tom Tromey <tom@tromey.com>
3651 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
3652 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
3653 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
3654 * buildsym-legacy.c (get_macro_table): Remove unused variable.
3655 * stack.c (frame_apply_level_command): Remove unused variable.
3656 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
3657 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
3658 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
3660 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
3661 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
3662 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
3664 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
3665 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
3667 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
3668 Remove unused variable.
3669 * cli/cli-script.c (recurse_read_control_structure): Remove unused
3671 * common/tdesc.c (print_xml_feature::visit): Remove unused
3673 * compile/compile-object-load.c (store_regs): Remove unused
3675 * complaints.c (clear_complaints): Remove unused variable.
3676 * corelow.c (core_target_open): Remove unused variable.
3677 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
3679 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
3681 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
3683 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
3685 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
3687 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
3689 * ia64-tdep.c (examine_prologue): Remove unused variable.
3690 * infcall.c (run_inferior_call): Remove unused variable.
3691 * inferior.c (exit_inferior): Remove unused variable.
3692 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
3693 * linespec.c (decode_line_2): Remove unused variable.
3694 * linux-nat.c (super_close): Remove.
3695 * linux-tdep.c (linux_info_proc): Remove unused variable.
3696 * mi/mi-main.c (mi_execute_command): Remove unused variable.
3697 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
3698 Remove unused variable.
3699 * parse.c (find_minsym_type_and_address): Remove unused variable.
3700 * printcmd.c (info_symbol_command, printf_floating): Remove unused
3702 * python/py-breakpoint.c (bppy_set_commands): Remove unused
3704 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
3706 * record-btrace.c (record_btrace_target::store_registers): Remove
3708 (cmd_show_record_btrace_cpu): Remove unused variable.
3709 * riscv-tdep.c (riscv_register_reggroup_p)
3710 (riscv_push_dummy_call, riscv_return_value): Remove unused
3712 * rust-exp.y (literal): Remove unused variable.
3713 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
3715 <STRUCTOP_ANONYMOUS>: Likewise.
3716 * s390-linux-tdep.c (s390_linux_init_abi_31)
3717 (s390_linux_init_abi_64): Remove unused variable.
3718 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
3719 (file_select_thread, net_windows_open, _initialize_ser_windows):
3720 Remove unused variables.
3721 * symtab.c (find_pc_sect_line): Remove unused variable.
3722 * target-memory.c (compute_garbled_blocks): Remove unused
3724 (target_write_memory_blocks): Remove unused variable.
3725 * target.c (target_stack::unpush): Remove unused variables.
3726 * tracepoint.c (start_tracing, all_tracepoint_actions)
3727 (merge_uploaded_trace_state_variables)
3728 (print_one_static_tracepoint_marker): Remove unused variable.
3729 * unittests/basic_string_view/element_access/char/1.cc (test01):
3730 Remove unused variable.
3731 * windows-nat.c (windows_continue, windows_add_all_dlls)
3732 (do_initial_windows_stuff, windows_nat_target::create_inferior):
3733 Remove unused variables.
3735 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
3737 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
3738 attr_profile in HAVE_ELF.
3739 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
3742 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
3744 * frame.c (frame_register_unwind): Change parameter name.
3745 (frame_unwind_register): Likewise.
3746 (frame_unwind_register_value): Likewise.
3747 (frame_unwind_register_signed): Likewise.
3748 (frame_unwind_register_unsigned): Likewise.
3749 * frame.h (frame_register_unwind): Likewise.
3750 (frame_unwind_register): Likewise.
3751 (frame_unwind_register_value): Likewise.
3752 (frame_unwind_register_signed): Likewise.
3753 (frame_unwind_register_unsigned): Likewise.
3754 (frame_unwind_arch): Likewise.
3756 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3758 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3761 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3763 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3764 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3767 2018-07-20 Keith Seitz <keiths@redhat.com>
3769 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3770 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3771 m_compunit_symtab, m_language>: Add "m_" prefix.
3773 * buildsym.c: Update all uses.
3775 2018-07-20 Tom Tromey <tom@tromey.com>
3777 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3778 * buildsym.h (record_line_ftype): Remove typedef.
3780 2018-07-20 Tom Tromey <tom@tromey.com>
3782 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3783 (end_expandable_symtab): Likewise.
3784 (end_symtab_get_static_block): Likewise.
3785 (end_symtab_from_static_block): Likewise.
3786 * buildsym-legacy.c (augment_type_symtab): Remove.
3787 (end_expandable_symtab): Remove.
3788 (end_symtab_get_static_block): Remove.
3789 (end_symtab_from_static_block): Remove.
3791 2018-07-20 Tom Tromey <tom@tromey.com>
3793 * dwarf2read.c: Include buildsym.h.
3794 (struct dwarf2_cu) <builder>: New method.
3795 (fixup_go_packaging): Update.
3796 (process_full_comp_unit, process_full_type_unit): Update. Don't
3797 use scoped_free_pendings.
3798 (using_directives): Add "cu" parameter, remove "language".
3799 (read_import_statement, setup_type_unit_groups, )
3800 (read_func_scope, read_lexical_block_scope)
3801 (dwarf2_record_block_ranges, read_namespace): Update.
3802 (lnp_state_machine::lnp_state_machine): Add cu parameter.
3803 (lnp_state_machine::handle_end_sequence): Update.
3804 (class lnp_state_machine) <m_cu>: New member.
3805 <m_record_line_callback>: Remove.
3806 <m_currently_recording_lines>: New member.
3807 (lnp_state_machine::handle_set_file): Update.
3808 (noop_record_line): Remove.
3809 (dwarf_record_line_p): Add cu parameter.
3810 (dwarf_record_line_1, dwarf_finish_line): Likewise.
3811 (lnp_state_machine::record_line)
3812 (lnp_state_machine::lnp_state_machine)
3813 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3814 (dwarf_decode_lines): Update.
3815 (dwarf2_start_subfile): Add cu parameter.
3816 (dwarf2_start_symtab, new_symbol): Update.
3817 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
3818 Remove dwarf2_per_objfile parameter.
3819 (dwarf_decode_macros): Update.
3821 2018-07-20 Tom Tromey <tom@tromey.com>
3823 * stabsread.c (define_symbol): Update.
3824 * buildsym-legacy.h (get_buildsym_compunit): Declare.
3825 * dwarf2read.c (new_symbol): Update.
3826 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
3827 * cp-namespace.c: Include buildsym.h.
3828 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
3829 * buildsym-legacy.c (get_buildsym_compunit): New function.
3831 2018-07-20 Tom Tromey <tom@tromey.com>
3833 * xcoffread.c: Include buildsym-legacy.h.
3834 * windows-nat.c: Include buildsym-legacy.h.
3835 * stabsread.c: Include buildsym-legacy.h.
3836 * mdebugread.c: Include buildsym-legacy.h.
3837 * buildsym-legacy.h: New file.
3838 * buildsym-legacy.c: New file, from buildsym.c.
3839 * go32-nat.c: Include buildsym-legacy.h.
3840 * dwarf2read.c: Include buildsym-legacy.h.
3841 * dbxread.c: Include buildsym-legacy.h.
3842 * cp-namespace.c: Include buildsym-legacy.h.
3843 * coffread.c: Include buildsym-legacy.h.
3844 * buildsym.h: Move some contents to buildsym-legacy.h.
3845 * buildsym.c: Include buildsym-legacy.h. Move many functions to
3847 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
3849 2018-07-20 Tom Tromey <tom@tromey.com>
3851 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
3852 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
3853 (buildsym_compunit::buildsym_compunit)
3854 (buildsym_compunit::~buildsym_compunit)
3855 (buildsym_compunit::get_macro_table): Define.
3857 2018-07-20 Tom Tromey <tom@tromey.com>
3859 * buildsym.c (reset_symtab_globals): Remove.
3860 (buildsym_compunit::end_symtab_from_static_block): Update.
3861 (buildsym_compunit::augment_type_symtab): Update.
3862 (end_symtab_from_static_block): Call free_buildsym_compunit.
3863 (augment_type_symtab, end_symtab, end_expandable_symtab):
3866 2018-07-20 Tom Tromey <tom@tromey.com>
3868 * arch-utils.c: Do not include buildsym.h.
3869 * mipsread.c: Do not include buildsym.h.
3870 * machoread.c: Do not include buildsym.h.
3871 * elfread.c: Do not include buildsym.h.
3873 2018-07-20 Tom Tromey <tom@tromey.com>
3875 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
3877 (buildsym_compunit): Add new constructor.
3878 (struct buildsym_compunit) <get_last_source_file, finish_block,
3879 record_block_range, start_subfile, patch_subfile_names,
3880 push_subfile, pop_subfile, record_line, get_compunit_symtab,
3881 set_last_source_start_addr, get_last_source_start_addr,
3882 get_local_using_directives, set_local_using_directives,
3883 get_global_using_directives, outermost_context_p,
3884 get_current_context_stack, get_context_stack_depth,
3885 get_current_subfile, get_local_symbols, get_file_symbols,
3886 get_global_symbols, record_debugformat, record_producer,
3887 push_context, pop_context, end_symtab_get_static_block,
3888 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
3890 <record_pending_block, finish_block_internal, make_blockvector,
3891 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
3895 2018-05-22 Tom Tromey <tom@tromey.com>
3897 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3899 (finish_block_internal): Update.
3901 2018-07-20 Tom Tromey <tom@tromey.com>
3903 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3905 (finish_block_internal): Update.
3907 2018-07-20 Tom Tromey <tom@tromey.com>
3909 * buildsym.h (EXTERN): Don't define or undef.
3910 * buildsym.c (EXTERN): Don't define.
3912 2018-07-20 Tom Tromey <tom@tromey.com>
3914 * buildsym.c: Remove TODO comment.
3916 2018-07-20 Tom Tromey <tom@tromey.com>
3918 * coffread.c (coff_symtab_read): Update.
3919 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3920 (xcoff_new_init): Update.
3921 * mipsread.c (mipscoff_new_init): Update.
3922 * mdebugread.c (mdebug_build_psymtabs): Update.
3923 * elfread.c (elf_new_init): Update.
3924 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3926 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
3927 (coffstab_build_psymtabs, elfstab_build_psymtabs)
3928 (stabsect_build_psymtabs): Update.
3929 * buildsym.h (buildsym_init): Don't declare.
3930 * buildsym.c: Update comment.
3931 (prepare_for_building): Remove.
3932 (start_symtab, restart_symtab): Update.
3933 (reset_symtab_globals): Update comment.
3934 (buildsym_init): Remove.
3936 2018-07-20 Tom Tromey <tom@tromey.com>
3938 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
3939 * stabsread.c (patch_block_stabs, define_symbol, read_type)
3940 (read_enum_type, common_block_start, common_block_end)
3941 (cleanup_undefined_types_1, finish_global_stabs): Update.
3942 * mdebugread.c (psymtab_to_symtab_1): Update.
3943 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3944 (read_lexical_block_scope, new_symbol): Update.
3945 * dbxread.c (process_one_symbol): Update.
3946 * coffread.c (coff_symtab_read, process_coff_symbol)
3947 (coff_read_enum_type): Update.
3948 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3950 (get_local_symbols, get_file_symbols, get_global_symbols): New
3952 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3954 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3955 (~scoped_free_pendings): Update.
3956 (finish_block, prepare_for_building, reset_symtab_globals)
3957 (end_symtab_get_static_block, end_symtab_with_blockvector)
3958 (augment_type_symtab, push_context): Update.
3959 (get_local_symbols, get_file_symbols, get_global_symbols): New
3961 (buildsym_init): Update.
3963 2018-07-20 Tom Tromey <tom@tromey.com>
3965 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3966 (process_full_type_unit): Likewise.
3967 (dwarf2_start_symtab): Set list_in_scope.
3969 2018-07-20 Tom Tromey <tom@tromey.com>
3971 * dwarf2read.c (process_psymtab_comp_unit_reader)
3972 (build_type_psymtabs_reader): Do not set list_in_scope.
3974 2018-07-20 Tom Tromey <tom@tromey.com>
3976 * buildsym.c (free_pendings): Remove.
3977 (add_symbol_to_list, scoped_free_pendings)
3978 (finish_block_internal, buildsym_init): Update.
3980 2018-07-20 Tom Tromey <tom@tromey.com>
3982 * xcoffread.c (read_xcoff_symtab): Update.
3983 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3985 * dbxread.c (process_one_symbol): Update.
3986 * coffread.c (coff_symtab_read): Update.
3987 * buildsym.h (finish_block): Update.
3988 * buildsym.c (finish_block): Remove "listhead" argument.
3989 (end_symtab_get_static_block): Update.
3991 2018-07-20 Tom Tromey <tom@tromey.com>
3993 * buildsym.h (class scoped_free_pendings): Remove constructor.
3994 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3996 <m_pending_block_obstack, m_pending_blocks>: New members.
3997 (pending_block_obstack, pending_blocks): Remove.
3998 (scoped_free_pendings::scoped_free_pendings): Default.
3999 (~scoped_free_pendings): Update.
4000 (free_pending_blocks): Remove.
4001 (finish_block_internal, record_pending_block, make_blockvector)
4002 (end_symtab_get_static_block, augment_type_symtab, push_context)
4003 (buildsym_init): Update.
4005 2018-07-20 Tom Tromey <tom@tromey.com>
4007 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
4008 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
4010 (pending_addrmap, pending_addrmap_obstack)
4011 (pending_addrmap_interesting): Remove.
4012 (scoped_free_pendings, record_block_range, make_blockvector)
4013 (prepare_for_building, reset_symtab_globals, buildsym_init):
4016 2018-07-20 Tom Tromey <tom@tromey.com>
4018 * xcoffread.c (process_linenos): Update.
4019 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
4020 * mdebugread.c (psymtab_to_symtab_1): Update.
4021 * dwarf2read.c (setup_type_unit_groups)
4022 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
4023 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
4024 * dbxread.c (process_one_symbol): Update.
4025 * coffread.c (coff_symtab_read, enter_linenos)
4026 (process_coff_symbol): Update.
4027 * buildsym.h (current_subfile): Don't declare.
4028 (get_current_subfile): Declare.
4029 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
4031 (start_subfile, free_buildsym_compunit, push_subfile)
4032 (prepare_for_building, start_symtab): Update.
4033 (get_current_subfile): New function.
4035 2018-07-20 Tom Tromey <tom@tromey.com>
4037 * coffread.c (coff_symtab_read): Update.
4038 * xcoffread.c (read_xcoff_symtab): Update.
4039 * dwarf2read.c (new_symbol): Update.
4040 (read_func_scope, read_lexical_block_scope): Update.
4041 * dbxread.c (process_one_symbol): Update.
4042 * buildsym.h (context_stack, context_stack_depth): Don't declare.
4043 (outermost_context_p): Remove macro.
4044 (outermost_context_p, get_current_context_stack)
4045 (get_context_stack_depth): Declare.
4046 (pop_context): Return struct context_stack.
4047 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
4049 (context_stack_size): Remove.
4050 (INITIAL_CONTEXT_STACK_SIZE): Remove.
4051 (prepare_for_building, end_symtab_get_static_block)
4052 (augment_type_symtab, push_context): Update.
4053 (pop_context): Return struct context_stack.
4054 (outermost_context_p, get_current_context_stack)
4055 (get_context_stack_depth): New functions.
4056 (buildsym_init): Update.
4058 2018-07-20 Tom Tromey <tom@tromey.com>
4060 * rust-exp.y: Now a pure parser. Update all rules.
4061 (%union): Move earlier.
4062 (current_parser, work_obstack): Remove globals.
4063 (rust_parser, ~rust_parser): Update.
4064 (class rust_parser) <copy_name, concat3, crate_name, super_name,
4065 lex_character, lex_number, lex_string, lex_identifier,
4066 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
4067 convert_name, convert_params_to_expression,
4068 convert_ast_to_expression, ast_basic_type, ast_operation,
4069 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
4070 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
4071 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
4072 ast_array_type, ast_slice_type, ast_reference_type,
4073 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
4074 (rust_parse): Update.
4075 (rustyyerror, rustyylex): Add parser parameter.
4076 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
4077 (rust_lex_stringish_test, rust_lex_test_sequence)
4078 (rust_lex_test_trailing_dot, rust_lex_test_completion)
4079 (rust_lex_test_push_back, rust_lex_tests): Update.
4081 2018-07-19 Pedro Alves <palves@redhat.com>
4083 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
4084 gdb::unique_xmalloc_ptr.
4085 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
4086 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
4087 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
4088 copy-initialization.
4089 * guile/scm-pretty-print.c (ppscm_print_children): Use
4090 gdb::unique_xmalloc_ptr instead of cleanups.
4091 (gdbscm_apply_val_pretty_printer): Remove cleanups.
4092 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
4093 gdb::unique_xmalloc_ptr.
4094 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4095 Adjust to use gdb::unique_xmalloc_ptr.
4096 * guile/scm-utils.c (extract_arg): Adjust.
4097 * guile/scm-value.c (gdbscm_value_field): Adjust to use
4098 gdb::unique_xmalloc_ptr instead of a cleanup.
4100 2018-07-19 Tom Tromey <tom@tromey.com>
4102 * utils.c (do_value_free_to_mark)
4103 (make_cleanup_value_free_to_mark): Remove.
4104 * utils.h (make_cleanup_value_free_to_mark): Remove.
4106 2018-07-19 Pedro Alves <palves@redhat.com>
4108 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
4109 forwarding reference.
4111 2018-07-18 Pedro Alves <palves@redhat.com>
4113 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
4114 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
4117 2018-07-18 Pedro Alves <palves@redhat.com>
4119 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
4121 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
4123 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
4124 directly instead of a cleanup.
4125 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
4126 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
4127 (vlscm_binop_gdbthrow): New, factored out from ...
4128 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
4129 (vlscm_rich_compare): Use gdbscm_wrap.
4130 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
4131 instead of a cleanup.
4132 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
4134 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4135 Use xfree directly instead of a cleanup.
4136 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
4137 Adjust to use gdbscm_wrap and scoped_value_mark.
4138 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
4139 (gdbscm_value_address, gdbscm_value_dereference)
4140 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
4142 (gdbscm_value_dynamic_type): Use scoped_value_mark.
4143 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
4145 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
4146 gdbscm_wrap and scoped_value_mark.
4147 (gdbscm_value_to_string): Use xfree directly instead of a
4148 cleanup. Move 'buffer' unique_ptr to TRY scope.
4149 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
4150 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
4152 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
4153 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
4155 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
4158 2018-07-18 Tom de Vries <tdevries@suse.de>
4160 * findvar.c (default_read_var_value): Also resolve dynamic type for
4161 LOC_OPTIMIZED_OUT vars.
4163 2018-07-18 Maciej W. Rozycki <macro@mips.com>
4165 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
4168 2018-07-17 Tom Tromey <tom@tromey.com>
4170 * guile/scm-param.c (pascm_set_func, pascm_show_func)
4171 (compute_enum_list, pascm_set_param_value_x)
4172 (gdbscm_parameter_value): Update.
4173 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
4174 (gdbscm_scm_to_host_string): Update.
4175 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
4177 * guile/scm-cmd.c (cmdscm_add_completion): Update.
4178 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
4179 * guile/scm-string.c (gdbscm_scm_to_string): Return
4181 (gdbscm_scm_to_host_string): Likewise.
4183 2018-07-17 Tom Tromey <tom@tromey.com>
4185 * guile/guile.c (gdbscm_eval_from_control_command): Update.
4186 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
4187 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
4188 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
4191 2018-07-17 Tom Tromey <tom@tromey.com>
4193 * guile/scm-param.c (pascm_signal_setshow_error): Update.
4194 * guile/guile-internal.h (gdbscm_exception_message_to_string):
4196 * guile/scm-cmd.c (cmdscm_function): Update.
4197 * guile/scm-pretty-print.c
4198 (ppscm_print_exception_unless_memory_error): Update.
4199 * guile/scm-exception.c (gdbscm_exception_message_to_string):
4200 Return unique_xmalloc_ptr.
4202 2018-07-17 Tom Tromey <tom@tromey.com>
4204 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
4207 2018-07-17 Jim Wilson <jimw@sifive.com>
4209 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
4210 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
4211 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
4212 unecessary braces after EF_RISCV_RVC test. Delete call to
4213 set_gdbarch_decr_pc_after_break.
4215 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
4216 RISCV_LAST_FP_REGNUM + 1.
4217 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
4219 2018-07-17 Tom Tromey <tom@tromey.com>
4221 * configure.ac: Remove --disable-gdbcli.
4222 * configure: Rebuild.
4223 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
4224 (SUBDIR_CLI_CFLAGS): Remove.
4225 (SFILES): Use SUBDIR_CLI_SRCS.
4226 (COMMON_OBS): Use SUBDIR_CLI_OBS.
4228 2018-07-17 Tom Tromey <tom@tromey.com>
4231 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
4233 2018-07-16 Jim Wilson <jimw@sifive.com>
4235 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
4237 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4239 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
4241 (libunwind_frame_sniffer): Likewise.
4242 (libunwind_frame_prev_register): Likewise.
4243 (libunwind_sigtramp_frame_sniffer): Likewise.
4244 * ia64-tdep.c (ia64_access_reg): Likewise.
4245 (ia64_access_rse_reg): Likewise.
4246 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
4247 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
4249 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4251 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
4253 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4255 * remote-sim.c (gdbsim_target::close,
4256 gdbsim_target::mourn_inferior): Remove unused variables.
4258 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
4260 * ia64-tdep.c (ktab_buf): New global.
4261 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
4262 (get_kernel_table): Adjust.
4264 2018-07-16 Tom Tromey <tom@tromey.com>
4266 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
4267 * dwarf2read.c (using_directives, new_symbol): Use
4268 outermost_context_p.
4269 * dbxread.c (process_one_symbol): Use outermost_context_p.
4270 * coffread.c (coff_symtab_read): Use outermost_context_p.
4272 2018-07-16 Tom Tromey <tom@tromey.com>
4274 * dwarf2read.c (using_directives, read_func_scope)
4275 (read_lexical_block_scope): Update.
4276 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
4277 * buildsym.h (local_using_directives, global_using_directives):
4279 (get_local_using_directives, set_local_using_directives)
4280 (get_global_using_directives): Declare.
4281 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
4282 m_global_using_directives>: New members.
4283 (finish_block_internal, prepare_for_building)
4284 (reset_symtab_globals, end_symtab_get_static_block)
4285 (push_context): Update.
4286 (get_local_using_directives, set_local_using_directives)
4287 (get_global_using_directives): New functions.
4288 (buildsym_init): Update.
4290 2018-07-16 Tom Tromey <tom@tromey.com>
4292 * xcoffread.c (xcoff_initial_scan): Don't call
4293 free_pending_blocks.
4294 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
4295 * buildsym.h (class scoped_free_pendings): Add constructor.
4296 (free_pending_blocks): Don't declare.
4297 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
4298 (free_pending_blocks): Now static.
4300 2018-07-16 Tom Tromey <tom@tromey.com>
4302 * buildsym.h (push_subfile, pop_subfile): Update declarations.
4303 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
4305 (struct subfile_stack): Remove.
4306 (subfile_stack): Remove.
4307 (push_subfile, pop_subfile, buildsym_init): Update.
4309 2018-07-16 Tom Tromey <tom@tromey.com>
4311 * buildsym.c (push_subfile): Use gdb_assert.
4312 (pop_subfile): Use gdb_assert.
4314 2018-07-16 Tom Tromey <tom@tromey.com>
4316 * buildsym.h (merge_symbol_lists): Remove.
4317 * buildsym.c (merge_symbol_lists): Remove.
4319 2018-07-16 Tom Tromey <tom@tromey.com>
4321 * stabsread.c (scan_file_globals): Update comment.
4322 * stabsread.h (scan_file_globals): Move from buildsym.h.
4323 * buildsym.h (scan_file_globals): Move to stabsread.h.
4325 2018-07-16 Tom Tromey <tom@tromey.com>
4327 * xcoffread.c (xcoff_new_init): Update.
4328 * mipsread.c (mipscoff_new_init): Update.
4329 * mdebugread.c (mdebug_build_psymtabs): Update.
4330 * elfread.c (elf_new_init): Update.
4331 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
4332 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
4333 * buildsym.h (buildsym_new_init): Don't declare.
4334 * buildsym.c (buildsym_new_init): Remove.
4336 2018-07-16 Tom Tromey <tom@tromey.com>
4338 * stabsread.h (within_function): Move from buildsym.h.
4339 * stabsread.c (start_stabs): Clear within_function.
4340 * coffread.c (coff_start_symtab): Clear within_function.
4341 * buildsym.h (within_function): Move to stabsread.h.
4342 * buildsym.c (prepare_for_building): Update.
4344 2018-07-16 Tom Tromey <tom@tromey.com>
4346 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
4347 * dwarf2read.c (dwarf2_start_symtab): Don't set
4348 processing_gcc_compilation.
4349 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
4351 2018-07-16 Tom Tromey <tom@tromey.com>
4353 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
4354 (next_symbol_text_func): Move from buildsym.h.
4355 * stabsread.c (hashname): Move from buildsym.c.
4356 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
4357 (next_symbol_text_func, hashname): Move to stabsread.h.
4358 * buildsym.c: Don't include bcache.h
4359 (hashname): Move to stasbread.c.
4361 2018-07-16 Tom Tromey <tom@tromey.com>
4363 * buildsym.h (context_stack_size): Don't declare.
4364 * buildsym.c (context_stack_size): New global.
4366 2018-07-16 Tom Tromey <tom@tromey.com>
4368 * dbxread.c (processing_acc_compilation): New global.
4369 * buildsym.h (processing_acc_compilation): Don't declare.
4371 2018-07-16 Tom Tromey <tom@tromey.com>
4373 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
4374 * dbxread.c (read_ofile_symtab): Update.
4375 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
4376 * buildsym.h (last_source_start_addr): Remove.
4377 (set_last_source_start_addr, get_last_source_start_addr):
4379 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
4381 (struct buildsym_compunit) <m_last_source_start_addr>: New
4383 (prepare_for_building): Remove start_addr parameter.
4384 (start_symtab, restart_symtab, end_symtab_get_static_block)
4385 (end_symtab_with_blockvector): Update.
4386 (set_last_source_start_addr, get_last_source_start_addr): New
4389 2018-07-16 Tom Tromey <tom@tromey.com>
4391 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
4393 (have_line_numbers): Remove.
4394 (record_line, prepare_for_building, end_symtab_get_static_block)
4395 (augment_type_symtab): Update.
4397 2018-07-16 Tom Tromey <tom@tromey.com>
4399 * buildsym.c (~buildsym_compunit): Free the macro table.
4400 (struct buildsym_compunit) <get_macro_table, release_macros>: New
4402 <m_pending_macros>: New member.
4403 (pending_macros): Remove.
4404 (~scoped_free_pendings, get_macro_table, prepare_for_building)
4405 (reset_symtab_globals, end_symtab_get_static_block)
4406 (end_symtab_with_blockvector, augment_type_symtab)
4407 (buildsym_init): Update.
4409 2018-07-16 Tom Tromey <tom@tromey.com>
4411 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
4413 (buildsym_compunit::set_last_source_file): New method.
4414 <m_last_source_file>: New member.
4415 (prepare_for_building): Remove "name" parameter.
4416 (start_symtab, restart_symtab, reset_symtab_globals): Update.
4417 (last_source_file): Remove.
4418 (set_last_source_file, get_last_source_file): Update.
4420 2018-07-16 Tom Tromey <tom@tromey.com>
4422 * buildsym.c (prepare_for_building): Add assert.
4424 2018-07-16 Tom Tromey <tom@tromey.com>
4426 * buildsym.c (~buildsym_compunit): Update.
4427 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
4428 (start_subfile, patch_subfile_names)
4429 (end_symtab_with_blockvector): Update.
4431 2018-07-16 Tom Tromey <tom@tromey.com>
4433 * buildsym.c (struct buildsym_compunit): Add constructor,
4434 destructor, initializers.
4435 (start_buildsym_compunit): Remove.
4436 (free_buildsym_compunit): Use "delete".
4437 (start_symtab, restart_symtab): Use "new".
4439 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
4441 * symfile.c (set_objfile_default_section_offset): Remove struct
4444 2018-07-14 Stafford Horne <shorne@gmail.com>
4446 * (Responsible Maintainers): Add myself as or1k maintainer.
4448 2018-07-13 Tom Tromey <tom@tromey.com>
4450 * symfile.c (set_objfile_default_section_offset): Use extra braces
4453 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4455 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
4458 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4460 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4461 unittests/cli-utils-selftests.c
4462 * unittests/cli-utils-selftests.c: New file.
4464 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4466 * NEWS: Mention new commands. Mention change to 'thread apply'.
4468 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4470 * thread.c (thr_try_catch_cmd): New function.
4471 (thread_apply_all_command): Handle qcs flags.
4472 (thread_apply_command): Handle qcs flags.
4473 (taas_command): New function.
4474 (tfaas_command): New function.
4475 (_initialize_thread): Update to setup the new commands 'taas
4476 and 'tfaas'. Change doc string for 'thread apply'.
4478 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4480 * stack.c: (trailing_outermost_frame): New function, mostly
4481 extracted from backtrace_command_1.
4482 (leading_innermost_frame): New function.
4483 (backtrace_command_1): Update to call trailing_outermost_frame.
4484 (frame_apply_command_count): New function.
4485 (frame_apply_level_command): New function.
4486 (frame_apply_all_command): New function.
4487 (frame_apply_command): New function.
4488 (faas_command): New function.
4489 (frame_cmd_list): New variable.
4490 (_initialize_stack): Update to setup the new commands 'frame apply'
4493 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4495 * cli-utils.c (number_or_range_parser::get_number): Only handle
4496 numbers or convenience var as numbers.
4497 (parse_flags): New function.
4498 (parse_flags_qcs): New function.
4499 (number_or_range_parser::finished): Ensure parsing end is detected
4500 before end of string.
4501 * cli-utils.h (parse_flags): New function.
4502 (parse_flags_qcs): New function.
4503 (number_or_range_parser): Remove m_finished bool.
4504 (number_or_range_parser::skip_range): Set m_in_range to false.
4506 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
4508 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
4511 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4512 Jan Kratochvil <jan.kratochvil@redhat.com>
4513 Paul Fertser <fercerpav@gmail.com>
4514 Tsutomu Seki <sekiriki@gmail.com>
4515 Pedro Alves <palves@redhat.com>
4517 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4518 'unittests/parse-connection-spec-selftests.c'.
4519 (COMMON_SFILES): Add 'common/netstuff.c'.
4520 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
4521 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
4522 * common/netstuff.c: New file.
4523 * common/netstuff.h: New file.
4524 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
4525 (wait_for_connect): Update comment. New parameter
4526 'gdb::optional<int> sock' instead of 'struct serial *scb'.
4527 Use 'sock' directly instead of 'scb->fd'.
4528 (try_connect): New function, with code from 'net_open'.
4529 (net_open): Rewrite main loop to deal with multiple
4530 sockets/addresses. Handle IPv6-style hostnames; implement
4531 support for IPv6 connections.
4532 * unittests/parse-connection-spec-selftests.c: New file.
4534 2018-07-11 Pedro Alves <palves@redhat.com>
4537 * remote.c (remote_target::remote_detach_pid): Call
4538 set_current_process.
4540 2018-07-11 Pedro Alves <palves@redhat.com>
4542 * h8300-tdep.c (h8300_gdbarch_init): Remove
4543 set_gdbarch_ecoff_reg_to_regnum calls.
4545 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4548 * c-typeprint.c (c_type_print_base_struct_union): Don't print
4549 offsets/sizes for static members of a class/struct.
4551 2018-07-11 Alan Hayward <alan.hayward@arm.com>
4553 * target-descriptions.c (tdesc_register_bitsize): Rename.
4554 * target-descriptions.h (tdesc_register_bitsize): Likewise.
4555 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
4556 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
4558 2018-07-10 Tom Tromey <tom@tromey.com>
4560 * breakpoint.c (moribund_locations): Now static and a
4562 (breakpoint_init_inferior, moribund_breakpoint_here_p)
4563 (build_bpstat_chain, update_global_location_list)
4564 (breakpoint_retire_moribund): Update.
4565 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
4568 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4570 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
4571 (riscv_register_reggroup_p): Use new function, remove unneeded
4573 (riscv_push_dummy_call): Extend assert to compare against xlen or
4574 flen based on register type.
4576 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4578 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
4580 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
4582 * remote.c (show_hardware_watchpoint_limit): New function.
4583 (show_hardware_watchpoint_length_limit): New function.
4584 (show_hardware_breakpoint_limit): New function.
4585 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
4586 where appropriate, update help text.
4588 2018-07-09 Tom Tromey <tom@tromey.com>
4590 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
4591 (CLIBS): Don't mention NAT_CLIBS.
4593 2018-07-09 Tom Tromey <tom@tromey.com>
4595 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
4596 (LIBGDB_OBS, clean mostlyclean): Update.
4597 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
4599 2018-07-09 Tom Tromey <tom@tromey.com>
4601 * Makefile.in (%.c: %.y): Use ECHO_YACC.
4602 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
4603 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
4605 2018-07-09 Tom Tromey <tom@tromey.com>
4607 * Makefile.in (ALLDEPFILES): Remove exec.c.
4608 (COMMON_OBS): Remove exec.o.
4609 (COMMON_SFILES): Add exec.c.
4611 2018-07-09 Tom Tromey <tom@tromey.com>
4613 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
4615 2018-07-09 Tom Tromey <tom@tromey.com>
4617 * Makefile.in (clean mostlyclean): Remove stamp-version.
4618 (version.c): Depend on stamp-version.
4619 (stamp-version): New rule, from version.c rule.
4621 2018-07-09 Tom Tromey <tom@tromey.com>
4623 * Makefile.in (init.c): Depend on stamp-init.
4624 (stamp-init): New rule, from init.c rule.
4625 (clean mostlyclean): Remove stamp-init.
4627 2018-07-09 Tom Tromey <tom@tromey.com>
4629 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
4630 SUBDIR_GCC_COMPILE_SRCS.
4632 2018-07-09 Tom Tromey <tom@tromey.com>
4634 * Makefile.in (init.c): Remove some unused sed rules.
4636 2018-07-09 Tom Tromey <tom@tromey.com>
4638 * Makefile.in (TSOBS): Remove.
4639 (INIT_FILES): Update.
4640 (LIBGDB_OBS): Update.
4641 (COMMON_SFILES): Add inflow.c.
4642 (SFILES): Remove inflow.c.
4644 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
4646 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
4648 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
4650 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
4651 get_saveloc_name, is_signal_frame_name, step_name,
4652 init_remote_name, create_addr_space_name,
4653 destroy_addr_space_name, search_unwind_table_name,
4654 find_dyn_list_name): Constify.
4656 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
4658 * darwin-nat.c (darwin_pthread_kill): New function.
4659 (darwin_resume_thread): Use darwin_pthread_kill.
4661 2018-07-05 Tom de Vries <tdevries@suse.de>
4663 * macroexp.c (macro_buffer) <operator=>: New member function.
4665 2018-07-04 Tom Tromey <tom@tromey.com>
4667 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
4669 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
4671 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
4672 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
4673 * maint.c: Likewise.
4676 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4678 * NEWS: Create a new section for the next release branch.
4679 Rename the section of the current branch, now that it has
4682 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4684 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
4685 * version.in: Bump version to 8.2.50.DATE-git.
4687 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4688 Pedro Alves <palves@redhat.com>
4690 * linux-nat.c (linux_init_ptrace): Rename to ...
4691 (linux_init_ptrace_procfs): ... this. Call
4692 linux_proc_init_warnings.
4693 (linux_nat_target::post_attach)
4694 (linux_nat_target::post_startup_inferior): Adjust.
4695 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
4696 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
4698 2018-07-04 Tom de Vries <tdevries@suse.de>
4700 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
4702 (read_comp_unit_head): ... here.
4704 2018-07-03 Tom Tromey <tom@tromey.com>
4706 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
4707 (stop_tracing, tstatus_command)
4708 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
4709 (print_one_static_tracepoint_marker): Update.
4710 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
4712 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
4714 (all_tracepoints, static_tracepoints_here): Return std::vector.
4716 2018-07-03 Tom Tromey <tom@tromey.com>
4718 * common/ptid.c (ptid_equal): Remove.
4719 * common/ptid.h (ptid_equal): Don't declare.
4720 * ada-tasks.c: Update.
4721 * breakpoint.c: Update.
4722 * common/agent.c: Update.
4723 * corelow.c: Update.
4724 * darwin-nat-info.c: Update.
4725 * darwin-nat.c: Update.
4727 * dtrace-probe.c: Update.
4728 * dummy-frame.c: Update.
4729 * fbsd-nat.c: Update.
4731 * gdbthread.h: Update.
4732 * gnu-nat.c: Update.
4733 * go32-nat.c: Update.
4734 * inf-loop.c: Update.
4735 * inf-ptrace.c: Update.
4736 * infcall.c: Update.
4740 * linux-fork.c: Update.
4741 * linux-nat.c: Update.
4742 * linux-thread-db.c: Update.
4743 * mi/mi-cmd-var.c: Update.
4744 * mi/mi-interp.c: Update.
4745 * mi/mi-main.c: Update.
4746 * nto-procfs.c: Update.
4747 * ppc-linux-tdep.c: Update.
4749 * python/py-inferior.c: Update.
4750 * python/py-record-btrace.c: Update.
4751 * python/py-record.c: Update.
4752 * ravenscar-thread.c: Update.
4753 * regcache.c: Update.
4754 * remote-sim.c: Update.
4756 * sol-thread.c: Update.
4759 * tui/tui-stack.c: Update.
4761 * windows-nat.c: Update.
4762 * windows-tdep.c: Update.
4764 2018-07-03 Tom Tromey <tom@tromey.com>
4766 * common/ptid.c (ptid_match): Remove.
4767 * common/ptid.h (ptid_match): Don't declare.
4768 * fbsd-nat.c: Update.
4771 * linux-nat.c: Update.
4772 * record-btrace.c: Update.
4773 * regcache.c: Update.
4776 2018-07-03 Tom Tromey <tom@tromey.com>
4778 * common/ptid.c (ptid_tid_p): Remove.
4779 * common/ptid.h (ptid_tid_p): Don't declare.
4780 * sol-thread.c: Update.
4782 2018-07-03 Tom Tromey <tom@tromey.com>
4784 * common/ptid.c (ptid_lwp_p): Remove.
4785 * common/ptid.h (ptid_lwp_p): Don't declare.
4786 * fbsd-nat.c: Update.
4787 * linux-nat.c: Update.
4788 * nat/linux-procfs.c: Update.
4789 * nat/x86-linux-dregs.c: Update.
4790 * sol-thread.c: Update.
4792 2018-07-03 Tom Tromey <tom@tromey.com>
4794 * common/ptid.c (ptid_is_pid): Remove.
4795 * common/ptid.h (ptid_is_pid): Don't declare.
4797 * linux-nat.c: Update.
4798 * mi/mi-interp.c: Update.
4802 2018-07-03 Tom Tromey <tom@tromey.com>
4804 * common/ptid.c (ptid_get_tid): Remove.
4805 * common/ptid.h (ptid_get_tid): Don't declare.
4806 * ada-tasks.c: Update.
4807 * aix-thread.c: Update.
4808 * bsd-uthread.c: Update.
4809 * darwin-nat.c: Update.
4810 * fbsd-nat.c: Update.
4811 * i386-darwin-nat.c: Update.
4813 * linux-tdep.c: Update.
4814 * nto-procfs.c: Update.
4815 * ppc-ravenscar-thread.c: Update.
4816 * python/py-infthread.c: Update.
4817 * ravenscar-thread.c: Update.
4818 * sol-thread.c: Update.
4819 * sparc-ravenscar-thread.c: Update.
4820 * windows-nat.c: Update.
4822 2018-07-03 Tom Tromey <tom@tromey.com>
4824 * common/ptid.c (ptid_get_lwp): Remove.
4825 * common/ptid.h (ptid_get_lwp): Don't declare.
4826 * aarch64-linux-nat.c: Update.
4827 * ada-tasks.c: Update.
4828 * aix-thread.c: Update.
4829 * amd64-linux-nat.c: Update.
4830 * arm-linux-nat.c: Update.
4831 * corelow.c: Update.
4832 * fbsd-nat.c: Update.
4833 * fbsd-tdep.c: Update.
4834 * gnu-nat.c: Update.
4835 * i386-cygwin-tdep.c: Update.
4836 * i386-gnu-nat.c: Update.
4837 * i386-linux-nat.c: Update.
4838 * ia64-linux-nat.c: Update.
4839 * inf-ptrace.c: Update.
4841 * linux-fork.c: Update.
4842 * linux-nat.c: Update.
4843 * linux-tdep.c: Update.
4844 * linux-thread-db.c: Update.
4845 * mips-linux-nat.c: Update.
4846 * nat/aarch64-linux-hw-point.c: Update.
4847 * nat/aarch64-linux.c: Update.
4848 * nat/linux-btrace.c: Update.
4849 * nat/linux-osdata.c: Update.
4850 * nat/linux-procfs.c: Update.
4851 * nat/x86-linux-dregs.c: Update.
4852 * obsd-nat.c: Update.
4853 * ppc-fbsd-nat.c: Update.
4854 * ppc-linux-nat.c: Update.
4856 * python/py-infthread.c: Update.
4857 * ravenscar-thread.c: Update.
4859 * s390-linux-nat.c: Update.
4860 * sol-thread.c: Update.
4861 * sol2-tdep.c: Update.
4862 * spu-linux-nat.c: Update.
4863 * x86-linux-nat.c: Update.
4864 * xtensa-linux-nat.c: Update.
4866 2018-07-03 Tom Tromey <tom@tromey.com>
4868 * common/ptid.c (ptid_get_pid): Remove.
4869 * common/ptid.h (ptid_get_pid): Don't declare.
4870 * aarch64-linux-nat.c: Update.
4871 * ada-lang.c: Update.
4872 * aix-thread.c: Update.
4873 * alpha-bsd-nat.c: Update.
4874 * amd64-fbsd-nat.c: Update.
4875 * amd64-linux-nat.c: Update.
4876 * arm-linux-nat.c: Update.
4877 * arm-nbsd-nat.c: Update.
4879 * break-catch-syscall.c: Update.
4880 * breakpoint.c: Update.
4881 * bsd-uthread.c: Update.
4882 * corelow.c: Update.
4884 * darwin-nat.c: Update.
4885 * fbsd-nat.c: Update.
4886 * fbsd-tdep.c: Update.
4888 * gnu-nat.c: Update.
4889 * hppa-nbsd-nat.c: Update.
4890 * hppa-obsd-nat.c: Update.
4891 * i386-fbsd-nat.c: Update.
4892 * ia64-linux-nat.c: Update.
4893 * inf-ptrace.c: Update.
4895 * inferior.c: Update.
4896 * inferior.h: Update.
4899 * linux-fork.c: Update.
4900 * linux-nat.c: Update.
4901 * linux-tdep.c: Update.
4902 * linux-thread-db.c: Update.
4903 * m68k-bsd-nat.c: Update.
4904 * mi/mi-interp.c: Update.
4905 * mi/mi-main.c: Update.
4906 * mips-linux-nat.c: Update.
4907 * mips-nbsd-nat.c: Update.
4908 * mips64-obsd-nat.c: Update.
4909 * nat/aarch64-linux-hw-point.c: Update.
4910 * nat/aarch64-linux.c: Update.
4911 * nat/linux-btrace.c: Update.
4912 * nat/linux-osdata.c: Update.
4913 * nat/linux-procfs.c: Update.
4914 * nat/x86-linux-dregs.c: Update.
4915 * nto-procfs.c: Update.
4916 * obsd-nat.c: Update.
4917 * ppc-linux-nat.c: Update.
4918 * ppc-nbsd-nat.c: Update.
4919 * ppc-obsd-nat.c: Update.
4920 * proc-service.c: Update.
4922 * python/py-inferior.c: Update.
4923 * python/py-infthread.c: Update.
4924 * ravenscar-thread.c: Update.
4926 * remote-sim.c: Update.
4928 * rs6000-nat.c: Update.
4929 * s390-linux-nat.c: Update.
4930 * sh-nbsd-nat.c: Update.
4931 * sol-thread.c: Update.
4932 * sparc-nat.c: Update.
4933 * sparc64-tdep.c: Update.
4934 * spu-linux-nat.c: Update.
4935 * spu-tdep.c: Update.
4936 * target-debug.h: Update.
4939 * tid-parse.c: Update.
4940 * tracefile-tfile.c: Update.
4941 * vax-bsd-nat.c: Update.
4942 * windows-nat.c: Update.
4943 * x86-linux-nat.c: Update.
4944 * x86-nat.c: Update.
4946 2018-07-03 Tom Tromey <tom@tromey.com>
4948 * common/ptid.c (pid_to_ptid): Remove.
4949 * common/ptid.h (pid_to_ptid): Don't declare.
4950 * aix-thread.c: Update.
4951 * arm-linux-nat.c: Update.
4952 * common/ptid.c: Update.
4953 * common/ptid.h: Update.
4954 * corelow.c: Update.
4956 * darwin-nat.c: Update.
4957 * fbsd-nat.c: Update.
4958 * fork-child.c: Update.
4959 * gnu-nat.c: Update.
4960 * go32-nat.c: Update.
4961 * inf-ptrace.c: Update.
4963 * inferior.c: Update.
4965 * linux-fork.c: Update.
4966 * linux-nat.c: Update.
4967 * nat/aarch64-linux-hw-point.c: Update.
4968 * nat/fork-inferior.c: Update.
4969 * nat/x86-linux-dregs.c: Update.
4970 * nto-procfs.c: Update.
4971 * obsd-nat.c: Update.
4973 * progspace.c: Update.
4975 * rs6000-nat.c: Update.
4976 * s390-linux-nat.c: Update.
4977 * sol-thread.c: Update.
4978 * spu-linux-nat.c: Update.
4981 * tracefile-tfile.c: Update.
4982 * windows-nat.c: Update.
4984 2018-07-03 Tom Tromey <tom@tromey.com>
4986 * common/ptid.h (ptid_build): Don't declare.
4987 * common/ptid.c (ptid_build): Remove.
4988 * aix-thread.c: Update.
4989 * bsd-kvm.c: Update.
4990 * bsd-uthread.c: Update.
4991 * common/agent.c: Update.
4992 * common/ptid.c: Update.
4993 * common/ptid.h: Update.
4994 * corelow.c: Update.
4995 * darwin-nat.c: Update.
4996 * fbsd-nat.c: Update.
4997 * gnu-nat.c: Update.
4998 * linux-fork.c: Update.
4999 * linux-nat.c: Update.
5000 * linux-thread-db.c: Update.
5001 * nat/linux-osdata.c: Update.
5002 * nat/linux-procfs.c: Update.
5003 * nto-procfs.c: Update.
5004 * obsd-nat.c: Update.
5005 * proc-service.c: Update.
5007 * ravenscar-thread.c: Update.
5008 * remote-sim.c: Update.
5010 * sol-thread.c: Update.
5012 * windows-nat.c: Update.
5014 2018-07-03 Tom Tromey <tom@tromey.com>
5016 * infrun.c (follow_exec): Use exit_inferior_silent.
5017 * inferior.c (exit_inferior_num_silent): Remove.
5018 * inferior.h (exit_inferior_num_silent): Don't declare.
5020 2018-07-03 Tom Tromey <tom@tromey.com>
5023 * darwin-nat.c (darwin_attach_pid): Reset inferior and
5024 inferior_ptid on error.
5026 2018-07-02 Maciej W. Rozycki <macro@mips.com>
5027 Simon Marchi <simon.marchi@polymtl.ca>
5030 * disasm.h (gdb_disassembler): Add
5031 `m_disassembler_options_holder'. member
5032 * disasm.c (get_all_disassembler_options): New function.
5033 (gdb_disassembler::gdb_disassembler): Use it.
5034 (gdb_buffered_insn_length_init_dis): Likewise.
5035 (gdb_buffered_insn_length): Adjust accordingly.
5036 (set_disassembler_options): Handle options with arguments.
5037 (show_disassembler_options_sfunc): Likewise. Add a leading new
5038 line if showing options with descriptions.
5039 (disassembler_options_completer): Adapt to using the
5040 `disasm_options_and_args_t' structure.
5041 * mips-tdep.c (mips_disassembler_options): New variable.
5042 (mips_disassembler_options_o32): Likewise.
5043 (mips_disassembler_options_n32): Likewise.
5044 (mips_disassembler_options_n64): Likewise.
5045 (gdb_print_insn_mips): Don't set `disassembler_options'.
5046 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
5048 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
5049 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
5050 `gdbarch_disassembler_options_implicit' and
5051 `gdbarch_valid_disassembler_options'.
5052 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
5053 `disasm_options_and_args_t' structure.
5054 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
5056 (valid_disassembler_options): Switch from `disasm_options_t' to
5057 the `disasm_options_and_args_t' structure.
5058 * NEWS: Document `set disassembler-options' support for the MIPS
5060 * gdbarch.h: Regenerate.
5061 * gdbarch.c: Regenerate.
5063 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
5065 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
5067 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5069 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
5070 parameter in call to amd64_target_description.
5071 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
5072 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
5073 (amd64fbsd_init_abi): Likewise.
5074 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5075 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
5076 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
5077 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
5079 2018-06-29 Pedro Alves <palves@redhat.com>
5081 * gdb/amd64-tdep.h (amd64_create_target_description): Add
5082 "segments" parameter.
5083 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
5084 (_initialize_amd64_tdep): Update call to
5085 amd64_create_target_description.
5086 (amd64_target_description): Add "segments" parameter. Adjust
5087 the implementation to use it.
5088 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
5089 call to amd64_create_target_description.
5090 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
5091 * gdb/arch/amd64.h (amd64_create_target_description): Add
5092 "segments" register.
5093 * gdb/arch/amd64.c (amd64_create_target_description): Add
5094 "segments" parameter. Call create_feature_i386_64bit_segments
5095 only if SEGMENTS is true.
5096 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
5097 call to amd64_create_target_description.
5099 2018-06-29 Pedro Alves <palves@redhat.com>
5101 * thread.c (thread_target_id_str): New, factored out from ...
5102 (print_thread_info_1): ... here. Use it to compute the max
5103 "Target Id" column width.
5105 2018-06-29 Pedro Alves <palves@redhat.com>
5107 * remote.c (remote_target::extra_thread_info): Delete
5108 'display_buf' and 'n' locals. from the cache, regardless of
5109 packet mechanims is in use. Use cache for qThreadExtra and qP
5112 2018-06-29 Pedro Alves <palves@redhat.com>
5114 * blockframe.c (find_pc_sect_containing_function): New function.
5115 * breakpoint.c (print_breakpoint_location): Don't call
5116 find_pc_sect_function.
5117 * linespec.c (create_sals_line_offset): Record the location's
5119 * linespec.c (convert_address_location_to_sals): Fill in sal's
5120 symbol with find_pc_sect_containing_function.
5121 * symtab.c (find_function_start_sal): Rename to ...
5122 (find_function_start_sal_1): ... this.
5123 (find_function_start_sal): Reimplement as wrapper around
5124 find_function_start_sal_1, and use
5125 find_pc_sect_containing_function to fill in the sal's symbol.
5126 (find_function_start_sal(symbol*, bool)): Adjust.
5127 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
5129 (find_pc_sect_containing_function): Declare.
5131 2018-06-29 Pedro Alves <palves@redhat.com>
5133 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
5134 true if the the location has no symbol.
5136 2018-06-28 Tom Tromey <tom@tromey.com>
5138 * NEWS: Mention --enable-codesign.
5139 * silent-rules.mk (ECHO_SIGN): New variable.
5140 * configure.ac: Add --enable-codesign.
5141 * configure: Rebuild.
5142 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
5143 (gdb$(EXEEXT)): Optionally invoke codesign.
5145 2018-06-28 Pedro Alves <palves@redhat.com>
5147 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
5149 (switch_to_thread_no_regs): Adjust comment.
5150 * infcmd.c (stop_pc): Delete.
5151 (post_create_inferior, info_program_command): Replace references
5152 to stop_pc with references to thread_info->suspend.stop_pc.
5153 * inferior.h (stop_pc): Delete declaration.
5154 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
5155 (handle_inferior_event_1, handle_signal_stop)
5156 (process_event_stop_test, keep_going_stepped_thread)
5157 (handle_step_into_function, handle_step_into_function_backward)
5158 (print_stop_location): Replace references to stop_pc with
5159 references to thread_info->suspend.stop_pc.
5160 (struct infcall_suspend_state) <stop_pc>: Delete field.
5161 (save_infcall_suspend_state, restore_infcall_suspend_state):
5162 Remove references to inf_stat->stop_pc.
5163 * linux-fork.c (fork_load_infrun_state): Likewise.
5164 * record-btrace.c (record_btrace_set_replay): Likewise.
5165 * record-full.c (record_full_goto_entry): Likewise.
5166 * remote.c (print_one_stopped_thread): Likewise.
5167 * target.c (target_resume): Extend comment.
5168 * thread.c (set_executing_thread): New.
5169 (set_executing): Use it.
5170 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
5171 Remove references to stop_pc.
5173 2018-06-28 Pedro Alves <palves@redhat.com>
5175 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
5176 Moving fetching stop_pc until after ecs->event_thread is refreshed.
5178 2018-06-28 Tom Tromey <tom@tromey.com>
5180 * coffread.c (coff_symfile_finish): Update.
5181 * xcoffread.c (xcoff_symfile_finish): Update.
5182 * elfread.c (elf_symfile_finish): Update.
5183 * symfile.h (dwarf2_free_objfile): Don't declare.
5184 * dwarf2read.c (_initialize_dwarf2_read): Use
5185 register_objfile_data_with_cleanup.
5186 (dwarf2_free_objfile): Now static. Change signature.
5188 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5190 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
5191 option "-o" to add-symbol-file-load to add an offset to each
5192 section's load address.
5193 * symfile.c (set_objfile_default_section_offset): New function.
5195 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5197 * symfile.c (add_symbol_file_command): Make sure that sections
5198 with the same name are sorted in the same order.
5200 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5202 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
5203 require the second argument. If omitted, load sections at the
5204 addresses specified in the file.
5206 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5208 * symfile.c (symbol_file_command, symbol_file_add_main_1)
5209 (_initialize_symfile): Add option "-o" to symbol-file to add an
5210 offset to each section of the symbol file.
5212 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5214 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
5216 2018-06-27 Tom Tromey <tom@tromey.com>
5218 * stack.c (_initialize_stack): Update "func" help text.
5220 2018-06-27 Tom Tromey <tom@tromey.com>
5222 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
5224 (unwind_infopy_str, pyuw_create_unwind_info)
5225 (unwind_infopy_add_saved_register, pyuw_sniffer)
5226 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
5228 (struct saved_reg): Add constructor.
5229 <value>: Now a gdbpy_ref<>.
5231 2018-06-27 Tom Tromey <tom@tromey.com>
5233 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
5235 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5237 * gdb-gdb.py.in: Format using autopep8.
5239 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5241 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
5242 (type_lookup_function): Recognize CORE_ADDR values.
5244 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5246 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
5249 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5251 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
5254 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5256 * gdb-gdb.py: Move to...
5257 * gdb-gdb.py.in: ... here.
5258 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
5259 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
5261 (distclean): Remove gdb-gdb.py when cleaning.
5262 (gdb-gdb.py, gdb-gdb.gdb): New rules.
5263 * configure: Re-generate.
5265 2018-06-27 Pedro Alves <palves@redhat.com>
5267 * proc-service.c (get_ps_regcache): New.
5268 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
5269 (ps_lsetfpregs): Use it.
5271 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
5274 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
5275 (dwarf_decode_lines_1): Adjust.
5277 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5279 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
5281 <info_proc>: Likewise.
5283 2018-06-26 Joel Brobecker <brobecker@adacore.com>
5285 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
5286 to windows_fetch_one_register, and only handle the case of
5287 fetching one register. Move the code that reloads the context
5288 and iterates over all registers if R is negative to...
5289 (windows_nat_target::fetch_registers): ... here.
5290 (do_windows_store_inferior_registers): Rename to
5291 windows_store_one_register, and only handle the case of storing
5292 one register. Move the code that handles the case where r is
5294 (windows_nat_target::store_registers) ... here.
5296 2018-06-26 Tom Tromey <tom@tromey.com>
5299 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
5300 * rust-lang.c (rust_print_struct_def): Add podata parameter.
5302 (rust_internal_print_type): Add podata parameter.
5303 (rust_print_type): Update.
5305 2018-06-26 Tom Tromey <tom@tromey.com>
5307 * typeprint.h (struct print_offset_data) <update, finish,
5308 maybe_print_hole>: New methods.
5309 <indentation>: New constant.
5310 * typeprint.c (print_offset_data::indentation): Define.
5311 (print_offset_data::maybe_print_hole, print_offset_data::update)
5312 (print_offset_data::finish): Move from c-typeprint.c and rename.
5313 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
5314 (print_spaces_filtered_with_print_options): Update.
5315 (c_print_type_union_field_offset, maybe_print_hole)
5316 (c_print_type_struct_field_offset): Move to typeprint.c and
5318 (c_type_print_base_struct_union): Update.
5320 2018-06-25 Pedro Alves <palves@redhat.com>
5322 * gdbthread.h (thread_info_ref, delete_thread)
5323 (delete_thread_silent, first_thread_of_inferior)
5324 (any_thread_of_inferior, switch_to_thread)
5325 (enable_thread_stack_temporaries)
5326 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5327 (get_last_thread_stack_temporary)
5328 (value_in_thread_stack_temporaries, can_access_registers_thread):
5329 Spell out "struct thread_info" instead of just "thread_info".
5330 * inferior.h (notice_new_inferior): Likewise.
5332 2018-06-25 Pedro Alves <palves@redhat.com>
5334 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5335 pass thread_info pointer to delete_thread.
5336 (windows_nat_target::detach): Pass inferior pointer to
5338 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
5340 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
5341 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
5342 and pass a thread_info pointer to delete_thread.
5343 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
5344 pass thread_info pointer to delete_thread.
5345 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
5346 delete_thread_silent call.
5347 * procfs.c (procfs_target::detach): Pass inferior pointer to
5349 (procfs_target::wait): Pass thread_info pointer to delete_thread.
5350 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
5351 delete_thread_silent call.
5352 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5353 pass thread_info pointer to delete_thread.
5354 (windows_nat_target::detach): Pass inferior pointer to
5357 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5359 * regcache.c (readable_regcache::read_part): Fix asserts.
5360 (reg_buffer::raw_collect_part): New function.
5361 (regcache::write_part): Fix asserts.
5362 (reg_buffer::raw_supply_part): New function.
5363 (regcache::transfer_regset_register): New helper function.
5364 (regcache::transfer_regset): Call new functions.
5365 (regcache_supply_regset): Use gdb_byte*.
5366 (regcache::supply_regset): Likewise.
5367 (regcache_collect_regset): Likewise.
5368 (regcache::collect_regset): Likewise.
5369 * regcache.h (reg_buffer::raw_collect_part): New declaration.
5370 (reg_buffer::raw_supply_part): Likewise.
5371 (regcache::transfer_regset_register): Likewise.
5372 (regcache::transfer_regset): Use gdb_byte*.
5374 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5376 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
5378 2018-06-21 Pedro Alves <palves@redhat.com>
5380 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
5381 instead of a ptid_t. All callers adjusted.
5382 * ada-tasks.c (ada_get_task_number): Likewise. All callers
5384 (print_ada_task_info, display_current_task_id, task_command_1):
5386 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
5388 (breakpoint_kind): Adjust.
5389 (remove_breakpoints_pid): Rename to ...
5390 (remove_breakpoints_inf): ... this. Adjust to take an inferior
5391 pointer. All callers adjusted.
5392 (bpstat_clear_actions): Use inferior_thread.
5393 (get_bpstat_thread): New.
5394 (bpstat_do_actions): Use it.
5395 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
5396 to take a thread_info pointer. All callers adjusted.
5397 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
5398 (breakpoint_re_set_thread): Use inferior_thread.
5399 * breakpoint.h (struct inferior): Forward declare.
5400 (bpstat_stop_status): Update.
5401 (remove_breakpoints_pid): Delete.
5402 (remove_breakpoints_inf): New.
5403 * bsd-uthread.c (bsd_uthread_target::wait)
5404 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
5405 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
5406 (maint_btrace_packet_history_cmd)
5407 (maint_btrace_clear_packet_history_cmd): Adjust.
5408 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
5410 * cli/cli-interp.c: Include "inferior.h".
5411 * common/refcounted-object.h (struct
5412 refcounted_object_ref_policy): New.
5413 * compile/compile-object-load.c: Include gdbthread.h.
5414 (store_regs): Use inferior_thread.
5415 * corelow.c (core_target::close): Use current_inferior.
5416 (core_target_open): Adjust to use first_thread_of_inferior and use
5417 the current inferior.
5418 * ctf.c (ctf_target::close): Adjust to use current_inferior.
5419 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
5420 <thread>: ... this new field. All references adjusted.
5421 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
5422 Take a thread_info pointer instead of a ptid_t.
5423 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
5424 (dummy_frame_discard, register_dummy_frame_dtor): Take a
5425 thread_info pointer instead of a ptid_t.
5426 * elfread.c: Include "inferior.h".
5427 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
5428 Use inferior_thread.
5429 * eval.c (evaluate_subexp): Likewise.
5430 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
5432 * gdb_proc_service.h (struct thread_info): Forward declare.
5433 (struct ps_prochandle) <ptid>: Delete, replaced by ...
5434 <thread>: ... this new field. All references adjusted.
5435 * gdbarch.h, gdbarch.c: Regenerate.
5436 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
5437 'thread' parameter. All implementations and callers adjusted.
5438 * gdbthread.h (thread_info) <set_running>: New method.
5439 (delete_thread, delete_thread_silent): Take a thread_info pointer
5441 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
5442 (first_thread_of_process): Delete, replaced by ...
5443 (first_thread_of_inferior): ... this new function. All callers
5445 (any_live_thread_of_process): Delete, replaced by ...
5446 (any_live_thread_of_inferior): ... this new function. All callers
5448 (switch_to_thread, switch_to_no_thread): Declare.
5449 (is_executing): Delete.
5450 (enable_thread_stack_temporaries): Update comment.
5451 <enable_thread_stack_temporaries>: Take a thread_info pointer
5452 instead of a ptid_t. Incref the thread.
5453 <~enable_thread_stack_temporaries>: Decref the thread.
5456 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5457 (get_last_thread_stack_temporary)
5458 (value_in_thread_stack_temporaries, can_access_registers_thread):
5459 Take a thread_info pointer instead of a ptid_t. All callers
5461 * infcall.c (get_call_return_value): Use inferior_thread.
5462 (run_inferior_call): Work with thread pointers instead of ptid_t.
5463 (call_function_by_hand_dummy): Work with thread pointers instead
5464 of ptid_t. Use thread_info_ref.
5465 * infcmd.c (proceed_thread_callback): Access thread's state
5467 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
5468 access thread's state directly.
5469 (continue_command): Use inferior_thread.
5470 (info_program_command): Use find_thread_ptid and access thread
5472 (proceed_after_attach_callback): Use thread state directly.
5473 (notice_new_inferior): Take a thread_info pointer instead of a
5474 ptid_t. All callers adjusted.
5475 (exit_inferior): Take an inferior pointer instead of a pid. All
5477 (exit_inferior_silent): New.
5478 (detach_inferior): Delete.
5479 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
5480 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
5481 (detach_inferior_command, kill_inferior_command): Use
5482 find_inferior_id instead of valid_gdb_inferior_id and
5483 gdb_inferior_id_to_pid.
5484 (inferior_command): Use inferior and thread pointers.
5485 * inferior.h (struct thread_info): Forward declare.
5486 (notice_new_inferior): Take a thread_info pointer instead of a
5487 ptid_t. All callers adjusted.
5488 (detach_inferior): Delete declaration.
5489 (exit_inferior, exit_inferior_silent): Take an inferior pointer
5490 instead of a pid. All callers adjusted.
5491 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
5492 (valid_gdb_inferior_id): Delete.
5493 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
5494 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
5495 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
5497 <inf>: ... this new field.
5498 <step_ptid>: Delete, replaced by ...
5499 <step_thread>: ... this new field.
5500 (get_displaced_stepping_state): Take an inferior pointer instead
5501 of a pid. All callers adjusted.
5502 (displaced_step_in_progress_any_inferior): Adjust.
5503 (displaced_step_in_progress_thread): Take a thread pointer instead
5504 of a ptid_t. All callers adjusted.
5505 (displaced_step_in_progress, add_displaced_stepping_state): Take
5506 an inferior pointer instead of a pid. All callers adjusted.
5507 (get_displaced_step_closure_by_addr): Adjust.
5508 (remove_displaced_stepping_state): Take an inferior pointer
5509 instead of a pid. All callers adjusted.
5510 (displaced_step_prepare_throw, displaced_step_prepare)
5511 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
5512 All callers adjusted.
5513 (start_step_over): Adjust.
5514 (infrun_thread_ptid_changed): Remove bit updating ptids in the
5515 displaced step queue.
5516 (do_target_resume): Adjust.
5517 (fetch_inferior_event): Use inferior_thread.
5518 (context_switch, get_inferior_stop_soon): Take an
5519 execution_control_state pointer instead of a ptid_t. All callers
5521 (switch_to_thread_cleanup): Delete.
5522 (stop_all_threads): Use scoped_restore_current_thread.
5523 * inline-frame.c: Include "gdbthread.h".
5524 (inline_state) <inline_state>: Take a thread pointer instead of a
5525 ptid_t. All callers adjusted.
5526 <ptid>: Delete, replaced by ...
5527 <thread>: ... this new field.
5528 (find_inline_frame_state): Take a thread pointer instead of a
5529 ptid_t. All callers adjusted.
5530 (skip_inline_frames, step_into_inline_frame)
5531 (inline_skipped_frames, inline_skipped_symbol): Take a thread
5532 pointer instead of a ptid_t. All callers adjusted.
5533 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
5534 (inline_skipped_frames, inline_skipped_symbol): Likewise.
5535 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
5537 * linux-nat.c (get_detach_signal): Likewise.
5538 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
5539 (thread_db_notice_clone): Adjust.
5540 (thread_db_find_new_threads_silently)
5541 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
5542 a thread pointer instead of a ptid_t. All callers adjusted.
5543 * mi/mi-cmd-var.c: Include "inferior.h".
5544 (mi_cmd_var_update_iter): Update to use thread pointers.
5545 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
5547 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
5549 (mi_output_running): ... this new function.
5550 (mi_on_resume_1): Adjust to use it.
5551 (mi_user_selected_context_changed): Adjust to use inferior_thread.
5552 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
5554 (interrupt_thread_callback): : Adjust to use thread and inferior
5556 * proc-service.c: Include "gdbthread.h".
5557 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
5558 * progspace-and-thread.c: Include "inferior.h".
5559 * progspace.c: Include "inferior.h".
5560 * python/py-exitedevent.c (create_exited_event_object): Adjust to
5561 hold a reference to an inferior_object.
5562 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
5564 * python/py-inferior.c (struct inferior_object): Give the type a
5565 tag name instead of a typedef.
5566 (python_on_normal_stop): No need to check if the current thread is
5568 (inferior_to_inferior_object): Change return type to
5569 inferior_object. All callers adjusted.
5570 (find_thread_object): Delete, bits factored out to ...
5571 (thread_to_thread_object): ... this new function.
5572 * python/py-infthread.c (create_thread_object): Use
5573 inferior_to_inferior_object.
5574 (thpy_is_stopped): Use thread pointer directly.
5575 (gdbpy_selected_thread): Use inferior_thread.
5576 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
5577 field, replaced with ...
5578 <thread>: ... this new field. All users adjusted.
5579 (btpy_insn_or_gap_new): Drop const.
5580 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
5582 * python/py-record.c: Include "gdbthread.h".
5583 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5584 a ptid_t. All callers adjusted.
5585 (gdbpy_current_recording): Use inferior_thread.
5586 * python/py-record.h (recpy_record_object) <ptid>: Delete
5587 field, replaced with ...
5588 <thread>: ... this new field. All users adjusted.
5589 (recpy_element_object) <ptid>: Delete
5590 field, replaced with ...
5591 <thread>: ... this new field. All users adjusted.
5592 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5593 a ptid_t. All callers adjusted.
5594 * python/py-threadevent.c: Include "gdbthread.h".
5595 (get_event_thread): Use thread_to_thread_object.
5596 * python/python-internal.h (struct inferior_object): Forward
5598 (find_thread_object, find_inferior_object): Delete declarations.
5599 (thread_to_thread_object, inferior_to_inferior_object): New
5601 * record-btrace.c: Include "inferior.h".
5602 (require_btrace_thread): Use inferior_thread.
5603 (record_btrace_frame_sniffer)
5604 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
5605 (get_thread_current_frame): Use scoped_restore_current_thread and
5607 (get_thread_current_frame): Use thread pointer directly.
5608 (record_btrace_replay_at_breakpoint): Use thread's inferior
5610 * record-full.c: Include "inferior.h".
5611 * regcache.c: Include "gdbthread.h".
5612 (get_thread_arch_regcache): Use the inferior's address space
5614 (get_thread_regcache, registers_changed_thread): New.
5615 * regcache.h (get_thread_regcache(thread_info *thread)): New
5617 (registers_changed_thread): New.
5618 (remote_target) <remote_detach_1>: Swap order of parameters.
5619 (remote_add_thread): <remote_add_thread>: Return the new thread.
5620 (get_remote_thread_info(ptid_t)): New overload.
5621 (remote_target::remote_notice_new_inferior): Use thread pointers
5623 (remote_target::process_initial_stop_replies): Use
5624 thread_info::set_running.
5625 (remote_target::remote_detach_1, remote_target::detach)
5626 (extended_remote_target::detach): Adjust.
5627 * stack.c (frame_show_address): Use inferior_thread.
5628 * target-debug.h (target_debug_print_thread_info_pp): New.
5629 * target-delegates.c: Regenerate.
5630 * target.c (default_thread_address_space): Delete.
5631 (memory_xfer_partial_1): Use current_inferior.
5632 (target_detach): Use current_inferior.
5633 (target_thread_address_space): Delete.
5634 (generic_mourn_inferior): Use current_inferior.
5635 * target.h (struct target_ops) <thread_address_space>: Delete.
5636 (target_thread_address_space): Delete.
5637 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
5639 (delete_thread_1, delete_thread, delete_thread_silent): Take a
5640 thread pointer instead of a ptid_t. Adjust all callers.
5641 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
5642 (first_thread_of_process): Delete, replaced by ...
5643 (first_thread_of_inferior): ... this new function. All callers
5645 (any_thread_of_process): Rename to ...
5646 (any_thread_of_inferior): ... this, and take an inferior pointer.
5647 (any_live_thread_of_process): Rename to ...
5648 (any_live_thread_of_inferior): ... this, and take an inferior
5650 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5651 (value_in_thread_stack_temporaries)
5652 (get_last_thread_stack_temporary): Take a thread pointer instead
5653 of a ptid_t. Adjust all callers.
5654 (thread_info::set_running): New.
5655 (validate_registers_access): Use inferior_thread.
5656 (can_access_registers_ptid): Rename to ...
5657 (can_access_registers_thread): ... this, and take a thread
5659 (print_thread_info_1): Adjust to compare thread pointers instead
5661 (switch_to_no_thread, switch_to_thread): Make extern.
5662 (scoped_restore_current_thread::~scoped_restore_current_thread):
5663 Use m_thread pointer directly.
5664 (scoped_restore_current_thread::scoped_restore_current_thread):
5665 Use inferior_thread.
5666 (thread_command): Use thread pointer directly.
5667 (thread_num_make_value_helper): Use inferior_thread.
5668 * top.c (execute_command): Use inferior_thread.
5669 * tui/tui-interp.c: Include "inferior.h".
5670 * varobj.c (varobj_create): Use inferior_thread.
5671 (value_of_root_1): Use find_thread_global_id instead of
5672 global_thread_id_to_ptid.
5674 2018-06-21 Alan Hayward <alan.hayward@arm.com>
5676 * regcache.c (readable_regcache::read_part): Avoid memcpy when
5678 (regcache::write_part): Likewise.
5679 (readable_regcache::cooked_read_part): Update comment.
5680 (readable_regcache::cooked_write_part): Likewise.
5681 * regcache.h: (readable_regcache::read_part): Likewise.
5682 (regcache::write_part): Likewise.
5684 2018-06-21 Richard Bunt <richard.bunt@arm.com>
5685 Dirk Schubert <dirk.schubert@arm.com>
5687 * aarch64-linux-nat.c (post_attach): New.
5688 (aarch64_linux_nat_target::post_attach): Override post_attach to
5689 record the number of hardware debug registers.
5691 2018-06-20 Tom Tromey <tom@tromey.com>
5693 * python/py-param.c (add_setshow_generic): Make parameters const.
5694 (parmpy_init): Update.
5696 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5698 * regcache.h (regcache_cooked_read_ftype): Rename to...
5699 (register_read_ftype): ...this, change type to function_view.
5700 (class reg_buffer) <save>: Remove src parameter.
5701 (readonly_detached_regcache) <readonly_detached_regcache>: Make
5702 parameter non-const in first overload. Remove src parameter in
5704 * regcache.c (do_cooked_read): Remove.
5705 (readonly_detached_regcache::readonly_detached_regcache): Make
5706 parameter non-const, adjust call to other constructor.
5707 (reg_buffer::save): Remove src parameter.
5708 * frame.c (do_frame_register_read): Remove.
5709 (frame_save_as_regcache): Use lambda function.
5710 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
5711 parameter to ppu2spu_data *.
5712 (ppu2spu_sniffer): Use lambda function.
5714 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5716 * record-full.c (record_full_target::insert_breakpoint): Remove
5717 "struct" keyword, add const.
5719 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5721 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
5722 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
5723 * configure.ac: Remove AC_PREREQ, add missing quoting.
5724 * gnulib/configure.ac: Modernize usage of
5725 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
5726 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
5727 (AUTOMAKE_VERSION): Bump to 1.15.1.
5728 * configure: Re-generate.
5729 * config.in: Re-generate.
5730 * aclocal.m4: Re-generate.
5731 * gnulib/aclocal.m4: Re-generate.
5732 * gnulib/config.in: Re-generate.
5733 * gnulib/configure: Re-generate.
5734 * gnulib/import/Makefile.in: Re-generate.
5736 2018-06-19 Pedro Alves <palves@redhat.com>
5738 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
5739 (lookup_minimal_symbol_by_pc_section): ... here with
5740 gdb_assert_not_reached added.
5742 2018-06-19 Pedro Alves <palves@redhat.com>
5744 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
5745 parameter with a block parameter. Compare location's block symbol
5746 with the frame's block instead of addresses.
5747 (skip_inline_frames): Pass the current block instead of the
5748 frame's address. Break out as soon as we determine the frame
5749 should not be skipped.
5751 2018-06-18 Tom Tromey <tom@tromey.com>
5753 * solib-aix.c (solib_aix_get_section_offsets): Return
5755 (solib_aix_solib_create_inferior_hook): Update.
5757 2018-06-18 Tom Tromey <tom@tromey.com>
5759 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5761 2018-06-18 Tom Tromey <tom@tromey.com>
5763 * solib-frv.c (frv_relocate_main_executable): Use
5765 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5768 2018-06-18 Tom Tromey <tom@tromey.com>
5770 * objfiles.h (inhibit_section_map_updates): Update.
5771 (resume_section_map_updates, resume_section_map_updates_cleanup):
5773 * solib-svr4.c (svr4_handle_solib_event): Update.
5774 * objfiles.c (inhibit_section_map_updates): Return
5775 scoped_restore_tmpl<int>.
5776 (resume_section_map_updates, resume_section_map_updates_cleanup):
5779 2018-06-18 Tom Tromey <tom@tromey.com>
5781 * valprint.h (read_string): Update.
5782 * valprint.c (read_string): Change type of "buffer".
5783 (val_print_string): Update.
5784 * python/py-value.c (valpy_string): Update.
5785 * language.h (struct language_defn) <la_get_string>: Change
5787 (default_get_string, c_get_string): Update.
5788 * language.c (default_get_string): Change type of "buffer".
5789 * guile/scm-value.c (gdbscm_value_to_string): Update.
5790 * c-lang.c (c_get_string): Change type of "buffer".
5792 2018-06-18 Tom Tromey <tom@tromey.com>
5794 * ser-mingw.c (struct pipe_state_destroyer): New.
5795 (pipe_state_up): New typedef.
5796 (cleanup_pipe_state): Remove.
5797 (pipe_windows_open): Use pipe_state_up. Don't release argv.
5799 2018-06-18 Tom Tromey <tom@tromey.com>
5801 * rust-lang.h (rust_yyerror): Don't declare.
5802 * rust-lang.c (rust_language_defn): Update.
5803 * rust-exp.y (yyerror): Now static.
5804 * parse.c (parse_exp_in_context_1): Update.
5805 * p-lang.h (p_yyerror): Don't declare.
5806 * p-lang.c (p_language_defn): Update.
5807 * p-exp.y (yyerror): Now static.
5808 * opencl-lang.c (opencl_language_defn): Update.
5809 * objc-lang.c (objc_language_defn): Update.
5810 * m2-lang.h (m2_yyerror): Don't declare.
5811 * m2-lang.c (m2_language_defn): Update.
5812 * m2-exp.y (yyerror): Now static.
5813 * language.h (struct language_defn) <la_error>: Remove.
5814 * language.c (unk_lang_error): Remove.
5815 (unknown_language_defn, auto_language_defn): Remove.
5816 * go-lang.h (go_yyerror): Don't declare.
5817 * go-lang.c (go_language_defn): Update.
5818 * go-exp.y (yyerror): Now static.
5819 * f-lang.h (f_yyerror): Don't declare.
5820 * f-lang.c (f_language_defn): Update.
5821 * f-exp.y (yyerror): Now static.
5822 * d-lang.h (d_yyerror): Don't declare.
5823 * d-lang.c (d_language_defn): Update.
5824 * d-exp.y (yyerror): Now static.
5825 * c-lang.h (c_yyerror): Don't declare.
5826 * c-lang.c (c_language_defn, cplus_language_defn)
5827 (asm_language_defn, minimal_language_defn): Update.
5828 * c-exp.y (yyerror): Now static.
5829 * ada-lang.h (ada_yyerror): Don't declare.
5830 * ada-lang.c (ada_language_defn): Update.
5831 * ada-exp.y (yyerror): Now static.
5833 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5835 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
5836 (store_sveregs_to_thread): Likewise.
5837 (aarch64_linux_fetch_inferior_registers): Check for SVE.
5838 (aarch64_linux_store_inferior_registers): Likewise.
5839 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
5841 (aarch64_sve_regs_copy_to_regcache): Likewise.
5842 (aarch64_sve_regs_copy_from_regcache): Likewise.
5843 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
5845 (aarch64_sve_regs_copy_to_regcache): Likewise.
5846 (aarch64_sve_regs_copy_from_regcache): Likewise.
5847 (sve_context): Structure from Linux headers.
5848 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
5849 (SVE_SIG_ZREG_SIZE): Likewise.
5850 (SVE_SIG_PREG_SIZE): Likewise.
5851 (SVE_SIG_FFR_SIZE): Likewise.
5852 (SVE_SIG_REGS_OFFSET): Likewise.
5853 (SVE_SIG_ZREGS_OFFSET): Likewise.
5854 (SVE_SIG_ZREG_OFFSET): Likewise.
5855 (SVE_SIG_ZREGS_SIZE): Likewise.
5856 (SVE_SIG_PREGS_OFFSET): Likewise.
5857 (SVE_SIG_PREG_OFFSET): Likewise.
5858 (SVE_SIG_PREGS_SIZE): Likewise.
5859 (SVE_SIG_FFR_OFFSET): Likewise.
5860 (SVE_SIG_REGS_SIZE): Likewise.
5861 (SVE_SIG_CONTEXT_SIZE): Likewise.
5862 (SVE_PT_REGS_MASK): Likewise.
5863 (SVE_PT_REGS_FPSIMD): Likewise.
5864 (SVE_PT_REGS_SVE): Likewise.
5865 (SVE_PT_VL_INHERIT): Likewise.
5866 (SVE_PT_VL_ONEXEC): Likewise.
5867 (SVE_PT_REGS_OFFSET): Likewise.
5868 (SVE_PT_FPSIMD_OFFSET): Likewise.
5869 (SVE_PT_FPSIMD_SIZE): Likewise.
5870 (SVE_PT_SVE_ZREG_SIZE): Likewise.
5871 (SVE_PT_SVE_PREG_SIZE): Likewise.
5872 (SVE_PT_SVE_FFR_SIZE): Likewise.
5873 (SVE_PT_SVE_FPSR_SIZE): Likewise.
5874 (SVE_PT_SVE_FPCR_SIZE): Likewise.
5875 (__SVE_SIG_TO_PT): Likewise.
5876 (SVE_PT_SVE_OFFSET): Likewise.
5877 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
5878 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
5879 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
5880 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
5881 (SVE_PT_SVE_PREG_OFFSET): Likewise.
5882 (SVE_PT_SVE_PREGS_SIZE): Likewise.
5883 (SVE_PT_SVE_FFR_OFFSET): Likewise.
5884 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
5885 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
5886 (SVE_PT_SVE_SIZE): Likewise.
5887 (SVE_PT_SIZE): Likewise.
5888 (HAS_SVE_STATE): New define.
5890 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5892 * nat/aarch64-sve-linux-sigcontext.h: New file.
5893 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
5895 (SVE_VQ_MIN): Likewise.
5896 (SVE_VQ_MAX): Likewise.
5897 (SVE_VL_MIN): Likewise.
5898 (SVE_VL_MAX): Likewise.
5899 (SVE_NUM_ZREGS): Likewise.
5900 (SVE_NUM_PREGS): Likewise.
5901 (sve_vl_valid): Likewise.
5902 (struct user_sve_header): Likewise.
5904 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
5905 Richard Bunt <Richard.Bunt@arm.com>
5907 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
5908 was requested by GDB.
5910 2018-06-15 Tom de Vries <tdevries@suse.de>
5912 * MAINTAINERS (Write After Approval): Add Tom de Vries.
5914 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
5916 * gnulib/update-gnulib.sh: Print expected versions of
5919 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
5921 * arch-utils.c (default_type_align): Use type_length_units.
5922 * gdbtypes.c (type_align): Use type_length_units.
5924 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5926 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
5927 of 'define' command.
5929 2018-06-14 Tom de Vries <tdevries@suse.de>
5932 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5933 get_no_prettyformat_print_options.
5935 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
5937 * sparc-nat.h: Include target.h.
5938 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
5939 <fetch_registers>: Remove this argument in function call.
5940 <store_registers>: Remove this argument in function call, remove
5942 <low_forget_process>: Call sparc64_forget_process instead of
5943 sparc_forget_process.
5945 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5947 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5948 (procfs_target::make_corefile_notes): Adjust to new
5949 target_read_alloc return type.
5951 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5952 Stephen Roberts <stephen.roberts@arm.com>
5955 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5956 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5957 Move should_notify_stop local into more inner scope.
5959 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5960 Stephen Roberts <stephen.roberts@arm.com>
5963 * infrun.c (resume_1): Add call to mark_async_event_handler.
5965 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5967 * infrun.c (do_target_wait): Change old version of $pc printed.
5969 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5971 * dwarf2read.c (read_index_from_section): Rename to...
5972 (read_gdb_index_from_section): ... this, update all callers.
5973 (dwarf2_read_index): Rename to...
5974 (dwarf2_read_gdb_index): ... this, update all callers.
5976 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5978 * gdb/hppa-linux-nat.c
5979 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5980 hppa_linux_nat_target::fetch_registers.
5982 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5984 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5985 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5986 (AARCH64_DWARF_SVE_FFR): Likewise.
5987 (AARCH64_DWARF_SVE_P0): Likewise.
5988 (AARCH64_DWARF_SVE_Z0): Likewise.
5990 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5992 * common/common-regcache.h (raw_compare): New function.
5993 * regcache.c (regcache::raw_compare): Likewise.
5994 * regcache.h (regcache::raw_compare): New declaration.
5996 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5998 * common/common-regcache.h (reg_buffer_common): New structure.
5999 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
6000 (reg_buffer::raw_supply): Likewise.
6001 (reg_buffer::raw_supply_integer): Likewise.
6002 (reg_buffer::raw_supply_zeroed): Likewise.
6003 (reg_buffer::raw_collect): Likewise.
6004 (reg_buffer::raw_collect_integer): Likewise.
6005 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
6006 (reg_buffer::raw_supply): Likewise.
6007 (reg_buffer::raw_supply_integer): Likewise.
6008 (reg_buffer::raw_supply_zeroed): Likewise.
6009 (reg_buffer::raw_collect): Likewise.
6010 (reg_buffer::raw_collect_integer): Likewise.
6012 2018-06-10 Tom Tromey <tom@tromey.com>
6014 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
6015 (class remote_state) <stop_reply_queue>: Now std::vector.
6016 (remote_state::~remote_state)
6017 (remote_target::stop_reply_queue_length): Update.
6018 (struct queue_iter_param, remove_child_of_pending_fork)
6019 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
6020 (check_pending_event_prevents_wildcard_vcont_callback)
6021 (remove_stop_reply_for_inferior)
6022 (remove_stop_reply_of_remote_state)
6023 (remote_notif_remove_once_on_match)
6024 (stop_reply_match_ptid_and_ws)
6025 (remote_kill_child_of_pending_fork): Remove.
6026 (remote_target::remove_new_fork_children)
6027 (remote_target::check_pending_events_prevent_wildcard_vcont)
6028 (remote_target::discard_pending_stop_replies)
6029 (remote_target::discard_pending_stop_replies_in_queue)
6030 (remote_target::remote_notif_remove_queued_reply)
6031 (remote_target::queued_stop_reply)
6032 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
6033 (remote_target::wait, remote_target::kill_new_fork_children)
6034 (remote_target::async): Update.
6036 2018-06-10 Tom Tromey <tom@tromey.com>
6038 * record-full.c (record_full_arch_list_cleanups): Remove.
6039 (record_full_message): Use try/catch.
6040 (record_full_wait_cleanups): Remove.
6041 (record_full_wait_1): Use try/catch.
6042 (record_full_restore): Likewise.
6044 2018-06-10 Tom Tromey <tom@tromey.com>
6046 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
6047 declare VEC. Add constructor.
6048 <in_target_beneath>: Now bool.
6049 (record_full_breakpoints): Now a std::vector, static.
6050 (record_full_sync_record_breakpoints)
6051 (record_full_init_record_breakpoints)
6052 (record_full_target::insert_breakpoint)
6053 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
6055 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
6057 * dwarf2read.c (process_cu_includes): Remove struct keyword.
6058 * serial.c (serial_interface_lookup): Remove struct keyword.
6060 2018-06-10 Tom Tromey <tom@tromey.com>
6062 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
6064 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
6066 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
6068 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
6069 "beneath" as a method.
6070 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
6071 Use "beneath" as a method.
6073 2018-06-10 Tom Tromey <tom@tromey.com>
6075 * tracefile.c (struct trace_file_writer_deleter): New.
6076 <operator()>: Rename from trace_file_writer_xfree.
6077 (trace_file_writer_up): New typedef.
6078 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
6080 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6082 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
6083 <m_registers, m_register_status>: Change type to
6085 * regcache.c (reg_buffer::reg_buffer): Use new instead of
6088 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6090 * common/common-regcache.h (enum register_status): Add
6091 underlying type "signed char".
6092 * regcache.h (reg_buffer) <m_register_status>: Change type to
6094 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
6095 register_status instead of signed char.
6096 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
6097 (reg_buffer::get_register_status): Remove cast.
6098 (readable_regcache::raw_read): Remove cast.
6099 (readable_regcache::cooked_read): Remove cast.
6101 2018-06-09 Tom Tromey <tom@tromey.com>
6103 * source.c (reverse_search_command, forward_search_command): Use
6106 2018-06-09 Tom Tromey <tom@tromey.com>
6108 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
6109 (serial_ops_list): Now static, std::vector.
6110 (serial_interface_lookup, serial_add_interface): Update.
6112 2018-06-09 Tom Tromey <tom@tromey.com>
6114 * dwarf2read.c (process_cu_includes): Update.
6115 (process_full_comp_unit): Update.
6116 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
6119 2018-06-08 Paul Koning <paul_koning@dell.com>
6123 * python/python.c (do_start_initialization):
6124 Avoid call to internal Python API.
6125 (init__gdb_module): New function.
6127 2018-06-08 Gary Benson <gbenson@redhat.com>
6129 * linux-thread-db.c (valprint.h): New include.
6130 (struct check_thread_db_info): New structure.
6131 (check_thread_db_on_load, tdb_testinfo): New static globals.
6132 (check_thread_db, check_thread_db_callback): New functions.
6133 (try_thread_db_load_1): Run integrity checks if requested.
6134 (maintenance_check_libthread_db): New function.
6135 (_initialize_thread_db): Register "maint check libthread-db"
6136 and "maint set/show check-libthread-db".
6137 * NEWS: Mention the above new commands.
6139 2018-06-08 Tom Tromey <tom@tromey.com>
6141 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
6144 2018-06-08 Tom Tromey <tom@tromey.com>
6146 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
6148 2018-06-08 Tom Tromey <tom@tromey.com>
6150 * common/btrace-common.h (struct btrace_data): Add constructor,
6151 destructor, move assignment operator.
6152 <empty, clear, fini>: New methods.
6153 <format>: Initialize.
6154 (btrace_data_init, btrace_data_fini, btrace_data_clear)
6155 (btrace_data_empty): Don't declare.
6156 * common/btrace-common.c (btrace_data_init): Remove.
6157 (btrace_data::fini): Rename from btrace_data_fini.
6158 (btrace_data::empty): Rename from btrace_data_empty.
6159 (btrace_data::clear): Rename from btrace_data_clear. Return
6161 * btrace.h (make_cleanup_btrace_data): Don't declare.
6162 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
6163 (parse_xml_btrace): Update.
6164 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
6165 (maint_btrace_clear_packet_history_cmd): Update.
6167 2018-06-07 Pedro Alves <palves@redhat.com>
6169 * target.h (target_ops) <beneath>: Now a method. All references
6171 (class target_stack): New.
6172 * target.c (g_target_stack): New.
6173 (g_current_top_target): Delete.
6174 (current_top_target): Get the top target out of g_target_stack.
6175 (target_stack::push, target_stack::unpush): New.
6176 (push_target, unpush_target): Reimplement.
6177 (target_is_pushed): Reimplement in terms of g_target_stack.
6178 (target_ops::beneath, target_stack::find_beneath): New.
6180 2018-06-07 Pedro Alves <palves@redhat.com>
6182 * target.h (find_target_beneath): Delete declaration.
6183 * target.c (find_target_beneath): Delete definition.
6184 * aix-thread.c: All callers of find_target_beneath adjusted to
6185 call target_ops::beneath instead.
6186 * bsd-uthread.c: Likewise.
6187 * linux-thread-db.c: Likewise.
6188 * ravenscar-thread.c: Likewise.
6189 * sol-thread.c: Likewise.
6190 * spu-multiarch.c: Likewise.
6192 2018-06-07 Pedro Alves <palves@redhat.com>
6194 * target.h (target_ops) <beneath>: Now a method. All references
6196 (target_ops) <m_beneath>: New.
6197 * target.c (target_ops::beneath): New.
6198 * corelow.c: Adjust all references to target_ops::beneath.
6199 * linux-thread-db.c: Likewise.
6200 * make-target-delegates: Likewise.
6201 * record-btrace.c: Likewise.
6202 * record-full.c: Likewise.
6203 * remote.c: Likewise.
6204 * target.c: Likewise.
6205 * target-delegates.c: Regenerate.
6207 2018-06-07 Pedro Alves <palves@redhat.com>
6209 * target.h (target_stack): Delete.
6210 (current_top_target): Declare function.
6211 * target.c (target_stack): Delete.
6212 (g_current_top_target): New.
6213 (current_top_target): New function.
6214 * auxv.c: Use current_top_target instead of target_stack
6216 * avr-tdep.c: Likewise.
6217 * breakpoint.c: Likewise.
6218 * corefile.c: Likewise.
6219 * elfread.c: Likewise.
6221 * exceptions.c: Likewise.
6222 * frame.c: Likewise.
6223 * gdbarch-selftests.c: Likewise.
6224 * gnu-v3-abi.c: Likewise.
6225 * ia64-tdep.c: Likewise.
6226 * ia64-vms-tdep.c: Likewise.
6227 * infcall.c: Likewise.
6228 * infcmd.c: Likewise.
6229 * infrun.c: Likewise.
6230 * linespec.c: Likewise.
6231 * linux-tdep.c: Likewise.
6232 * minsyms.c: Likewise.
6233 * ppc-linux-nat.c: Likewise.
6234 * ppc-linux-tdep.c: Likewise.
6235 * procfs.c: Likewise.
6236 * regcache.c: Likewise.
6237 * remote.c: Likewise.
6238 * rs6000-tdep.c: Likewise.
6239 * s390-linux-nat.c: Likewise.
6240 * s390-tdep.c: Likewise.
6241 * solib-aix.c: Likewise.
6242 * solib-darwin.c: Likewise.
6243 * solib-dsbt.c: Likewise.
6244 * solib-spu.c: Likewise.
6245 * solib-svr4.c: Likewise.
6246 * solib-target.c: Likewise.
6247 * sparc-tdep.c: Likewise.
6248 * sparc64-tdep.c: Likewise.
6249 * spu-tdep.c: Likewise.
6250 * symfile.c: Likewise.
6251 * symtab.c: Likewise.
6252 * target-descriptions.c: Likewise.
6253 * target-memory.c: Likewise.
6254 * target.c: Likewise.
6255 * target.h: Likewise.
6256 * tracefile-tfile.c: Likewise.
6257 * tracepoint.c: Likewise.
6258 * valops.c: Likewise.
6259 * valprint.c: Likewise.
6260 * value.c: Likewise.
6261 * windows-tdep.c: Likewise.
6262 * mi/mi-main.c: Likewise.
6264 2018-06-07 Tom Tromey <tom@tromey.com>
6266 * valprint.h (build_address_symbolic): Declare.
6267 * printcmd.c (print_address_symbolic): Update.
6268 (build_address_symbolic): Change "name" and "filename" to
6270 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
6272 * defs.h (build_address_symbolic): Remove declaration.
6274 2018-06-07 Alan Hayward <alan.hayward@arm.com>
6276 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
6277 (aarch64_vnv_type): Add function.
6278 (aarch64_pseudo_register_name): Add V regs for SVE.
6279 (aarch64_pseudo_register_type): Likewise.
6280 (aarch64_pseudo_register_reggroup_p): Likewise.
6281 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
6282 (aarch64_pseudo_read_value): Add V regs for SVE.
6283 (aarch64_pseudo_write_2): Use V0 offset for SVE
6284 (aarch64_pseudo_write): Add V regs for SVE.
6285 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
6287 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
6289 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
6290 (sve_vl_from_vq): Likewise.
6292 2018-06-05 Tom Tromey <tom@tromey.com>
6294 * cli/cli-cmds.c (show_version): Update.
6295 * top.c (print_gdb_version): Add "interactive" parameter.
6297 * main.c (captured_main_1): Update.
6298 * top.h (print_gdb_version): Add "interactive" parameter and a
6301 2018-06-05 David Malcolm <dmalcolm@redhat.com>
6303 * common/enum-flags.h: Add trailing semicolon to example in
6306 2018-06-05 Tom Tromey <tom@tromey.com>
6309 * NEWS: Add entry about pager.
6310 * utils.c (pagination_disabled_for_command): New global.
6311 (prompt_for_continue): Allow "c" response to prompt.
6312 (reinitialize_more_filter): Clear
6313 pagination_disabled_for_command.
6314 (fputs_maybe_filtered): Check pagination_disabled_for_command.
6316 2018-06-04 Tom Tromey <tom@tromey.com>
6318 * ada-lang.h (ada_lookup_symbol_list): Update.
6319 * ada-lang.c (resolve_subexp): Update.
6320 (symbols_are_identical_enums): Change type of syms. Remove nsyms
6322 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
6323 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
6324 results parameter to std::vector.
6325 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
6327 * ada-exp.y (block_lookup): Update.
6328 (select_possible_type_sym): Change type of syms. Remove nsyms
6330 (write_var_or_type, write_name_assoc): Update.
6332 2018-06-04 Joel Brobecker <brobecker@adacore.com>
6334 * windows-nat.c (windows_nat_target::xfer_partial): Return
6335 TARGET_XFER_E_IO if we need to delegate to the target beneath
6336 but BENEATH is NULL.
6338 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
6340 * Makefile.in (config.status): Add configure.nat as a
6343 2018-06-04 Tom Tromey <tom@tromey.com>
6345 * cp-name-parser.y (cpname_state): Add method declarations.
6346 (HANDLE_QUAL): Update.
6347 (cpname_state::d_grab, cpname_state::fill_comp)
6348 (cpname_state::make_operator, cpname_state::make_dtor)
6349 (cpname_state::make_builtin_type, cpname_state::make_name)
6350 (cpname_state::d_qualify, cpname_state::d_int_type)
6351 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
6352 (%union): Move earlier.
6354 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6356 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
6358 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6360 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
6361 (aarch64_pseudo_write_1): Likewise.
6362 (aarch64_pseudo_read_value): Use helper.
6363 (aarch64_pseudo_write): Likewise.
6365 2018-06-04 Pedro Alves <palves@redhat.com>
6367 * darwin-nat.c (darwin_ops): Delete.
6368 (darwin_attach_pid): Use get_native_target.
6370 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6372 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
6373 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
6375 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6377 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
6378 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
6379 (aarch64_gdbarch_init): Check for SVE.
6380 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
6382 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6384 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
6385 * aarch64-tdep.h (aarch64_read_description): Likewise.
6386 * arch/aarch64.c (aarch64_create_target_description): Likewise.
6387 * arch/aarch64.h (aarch64_create_target_description): Likewise.
6388 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
6389 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
6390 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
6392 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
6394 * value.c (value_fetch_lazy_bitfield): New.
6395 (value_fetch_lazy_memory): New.
6396 (value_fetch_lazy_register): New.
6397 (value_fetch_lazy): Factor out to smaller functions.
6399 2018-06-01 Tom Tromey <tom@tromey.com>
6401 * cp-name-parser.y (backslashable, represented): Now const.
6403 2018-06-01 Tom Tromey <tom@tromey.com>
6405 * cp-name-parser.y: Include parser-defs.h.
6406 (parser_fprintf): Remove declaration.
6408 2018-06-01 Tom Tromey <tom@tromey.com>
6410 * cp-name-parser.y: Use %pure-parser, %lex-param, and
6412 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
6413 (global_result): Remove globals.
6414 (struct cpname_state): New.
6415 (yyparse): Don't declare.
6416 (yylex, yyerror): Move declarations after %union.
6417 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
6418 (make_name): Add state parameter.
6420 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
6422 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
6424 (yylex): Add lvalp, state parameters.
6425 (yyerror): Add state parameter.
6426 (cp_demangled_name_to_comp): Update.
6428 2018-06-01 Tom Tromey <tom@tromey.com>
6430 * cp-name-parser.y (parser_fprintf): Declare.
6431 (GDB_YY_REMAP_PREFIX): Define.
6432 Include yy-remap.h. Don't redefine yy* identifiers.
6434 2018-06-01 Tom Tromey <tom@tromey.com>
6436 * python/py-type.c (typy_legacy_template_argument): Update.
6437 * cp-support.h (cp_demangled_name_to_comp): Update.
6438 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
6439 parameter to be a "std::string *".
6442 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
6444 * ada-lex.l: Include "diagnostics.h" instead of
6445 "common/diagnostics.h".
6446 * unittests/environ-selftests.c: Likewise.
6447 * common/diagnostics.h: Moved to ../include.
6449 2018-06-01 Joel Brobecker <brobecker@adacore.com>
6451 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
6452 to language_mode_manual while calling breakpoint_re_set_one.
6454 2018-06-01 Tom Tromey <tom@tromey.com>
6456 * valops.c (value_cast_structs, destructor_name_p): Update.
6457 * symtab.c (gdb_mangle_name): Update.
6458 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
6460 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
6461 (pascal_object_print_value_fields, pascal_object_print_value):
6463 * p-typeprint.c (pascal_type_print_derivation_info): Update.
6464 * linespec.c (find_methods): Update.
6465 * gdbtypes.h (type_name_no_tag): Remove.
6466 (type_name_or_error): Rename from type_name_no_tag_or_error.
6467 * gdbtypes.c (type_name_no_tag): Remove.
6468 (type_name_or_error): Rename from type_name_no_tag_or_error.
6469 (lookup_struct_elt_type, check_typedef): Update.
6470 * expprint.c (print_subexp_standard): Update.
6471 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
6472 * d-namespace.c (d_lookup_nested_symbol): Update.
6473 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
6474 (cp_print_class_member): Update.
6475 * cp-namespace.c (cp_lookup_nested_symbol): Update.
6476 * completer.c (add_struct_fields): Update.
6477 * c-typeprint.c (cp_type_print_derivation_info)
6478 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
6480 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
6481 (ada_prefer_type, ada_is_exception_sym): Update.
6483 2018-06-01 Tom Tromey <tom@tromey.com>
6485 * valops.c (enum_constant_from_type, value_namespace_elt)
6486 (value_maybe_namespace_elt): Update.
6487 * valarith.c (find_size_for_pointer_math): Update.
6488 * target-descriptions.c (make_gdb_type): Update.
6489 * symmisc.c (print_symbol): Update.
6490 * stabsread.c (define_symbol, read_type)
6491 (complain_about_struct_wipeout, add_undefined_type)
6492 (cleanup_undefined_types_1): Update.
6493 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
6494 (rust_range_type_p, val_print_struct, rust_print_struct_def)
6495 (rust_internal_print_type, rust_composite_type)
6496 (rust_evaluate_funcall, rust_evaluate_subexp)
6497 (rust_inclusive_range_type_p): Update.
6498 * python/py-type.c (typy_get_tag): Update.
6499 * p-typeprint.c (pascal_type_print_base): Update.
6500 * mdebugread.c (parse_symbol, parse_type): Update.
6501 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
6503 * guile/scm-type.c (gdbscm_type_tag): Update.
6504 * go-lang.c (sixg_string_p): Update.
6505 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
6507 * gdbtypes.h (struct main_type) <tag_name>: Remove.
6508 (TYPE_TAG_NAME): Remove.
6509 * gdbtypes.c (type_name_no_tag): Simplify.
6510 (check_typedef, check_types_equal, recursive_dump_type)
6511 (copy_type_recursive, arch_composite_type): Update.
6512 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
6513 in summary mode when needed.
6514 * eval.c (evaluate_funcall): Update.
6515 * dwarf2read.c (fixup_go_packaging, read_structure_type)
6516 (process_structure_scope, read_enumeration_type)
6517 (read_namespace_type, read_module_type, determine_prefix): Update.
6518 * cp-support.c (inspect_type): Update.
6519 * coffread.c (process_coff_symbol, decode_base_type): Update.
6520 * c-varobj.c (c_is_path_expr_parent): Update.
6521 * c-typeprint.c (c_type_print_base_struct_union): Update.
6522 (c_type_print_base_1): Update. Print struct/class/union/enum in
6523 summary when using C language.
6524 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
6525 (gen_maybe_namespace_elt): Update.
6526 * ada-lang.c (ada_type_name): Simplify.
6527 (empty_record, ada_template_to_fixed_record_type_1)
6528 (template_to_static_fixed_type)
6529 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
6531 2018-06-01 Tom Tromey <tom@tromey.com>
6533 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
6535 * c-typeprint.c (c_print_type_1): Add "language" parameter.
6536 (c_print_type): Update.
6537 (c_print_type): New overload.
6538 (c_type_print_varspec_prefix, c_type_print_args)
6539 (c_type_print_varspec_suffix, c_print_type_no_offsets)
6540 (c_type_print_base_struct_union, c_type_print_base_1)
6541 (cp_type_print_method_args): Add "language" parameter.
6542 (c_type_print_base): Update.
6543 * c-lang.h (c_print_type): Add new overload.
6545 2018-06-01 Tom Tromey <tom@tromey.com>
6547 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
6548 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
6550 2018-06-01 Alan Hayward <alan.hayward@arm.com>
6552 * aarch64-tdep.c (aarch64_sve_register_names): New const
6554 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
6555 (AARCH64_SVE_Z_REGS_NUM): New define.
6556 (AARCH64_SVE_P_REGS_NUM): Likewise.
6557 (AARCH64_SVE_NUM_REGS): Likewise.
6559 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
6561 * nat/linux-ptrace.h [__alpha__]
6562 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
6565 2018-05-31 Maciej W. Rozycki <macro@mips.com>
6567 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
6568 the endianness selected.
6569 * NEWS: Document `set endian auto' mode operation update.
6571 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6573 * Makefile.in: Add new header.
6574 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
6575 (sve_vl_from_vg): Likewise.
6576 (sve_vq_from_vl): Likewise.
6577 (sve_vl_from_vq): Likewise.
6578 (sve_vq_from_vg): Likewise.
6579 (sve_vg_from_vq): Likewise.
6580 * configure.nat: Add new c file.
6581 * nat/aarch64-sve-linux-ptrace.c: New file.
6582 * nat/aarch64-sve-linux-ptrace.h: New file.
6584 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6586 * aarch64-linux-nat.c (aarch64_linux_read_description):
6588 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
6590 * aarch64-tdep.c (tdesc_aarch64_list): Add.
6591 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
6592 (aarch64_gdbarch_init): Add parmeter zero.
6593 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
6594 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
6595 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
6597 * doc/gdb.texinfo: Describe SVE feature
6598 * features/aarch64-sve.c: New file.
6600 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
6603 * gdbarch.sh (significant_addr_bit): Default to zero when
6604 not set by target architecture.
6605 * gdbarch.c: Re-generated.
6606 * utils.c (address_significant): Update.
6608 2018-05-30 Joel Brobecker <brobecker@adacore.com>
6610 * stack.c (func_command): Remove trailing newline in call to error.
6612 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6614 * regcache.h (regcache_raw_collect): Remove, update callers to
6615 use regcache::raw_collect.
6616 * regcache.c (regcache_raw_collect): Remove.
6618 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6620 * regcache.h (regcache_raw_supply): Remove, update callers to
6621 use detached_regcache::raw_supply.
6622 * regcache.c (regcache_raw_supply): Remove.
6624 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6626 * regcache.h (regcache_cooked_write_part): Remove, update
6627 callers to use regcache::cooked_write_part.
6628 * regcache.c (regcache_cooked_write_part): Remove.
6630 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6632 * regcache.h (regcache_cooked_read_part): Remove, update callers
6633 to use readable_regcache::cooked_read_part.
6634 * regcache.c (regcache_cooked_read_part): Remove.
6636 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6638 * regcache.h (regcache_cooked_read_value): Remove, update
6639 callers to use readable_regcache::cooked_read_value.
6640 * regcache.c (regcache_cooked_read_value): Remove.
6642 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6644 * regcache.h (regcache_cooked_write): Remove, update callers to
6645 use regcache::cooked_write.
6646 * regcache.c (regcache_cooked_write): Remove.
6648 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6650 * regcache.h (regcache_invalidate): Remove, update callers to
6651 use detached_regcache::invalidate instead.
6652 * regcache.c (regcache_invalidate): Remove.
6654 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6656 * regcache.h (regcache_raw_write_part): Remove, update callers
6657 to use regcache::raw_write_part instead.
6658 * regcache.c (regcache_raw_write_part): Remove.
6660 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6662 * regcache.h (regcache_raw_read_part): Remove, update callers to
6663 use readable_regcache::raw_read_part instead.
6664 * regcache.c (regcache_raw_read_part): Remove.
6666 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6668 * regcache.h (regcache_cooked_read): Remove, update callers to
6669 use readable_regcache::cooked_read instead.
6670 * regcache.c (regcache_cooked_read): Remove.
6672 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6674 * regcache.h (regcache_raw_write): Remove, update callers to use
6675 regcache::raw_write instead.
6676 * regcache.c (regcache_raw_write): Remove.
6678 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6680 * regcache.h (regcache_raw_read): Remove, update callers to use
6681 readable_regcache::raw_read instead.
6682 * regcache.c (regcache_raw_read): Remove.
6684 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6686 * regcache.h (regcache_raw_update): Remove, update callers to
6687 use readable_regcache::raw_update instead.
6688 * regcache.c (regcache_raw_update): Remove.
6690 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6692 * regcache.h (regcache_register_status): Remove, update callers
6693 to use reg_buffer::get_register_status directly instead.
6694 * regcache.c (regcache_register_status): Remove.
6696 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6698 * regcache.h (regcache_get_ptid): Remove, update all callers to
6699 call regcache::ptid instead.
6700 * regcache.c (regcache_get_ptid): Remove.
6702 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6704 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
6706 2018-05-30 Pedro Alves <palves@redhat.com>
6708 * common/common-exceptions.h (exception_rethrow): Use
6711 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
6713 * breakpoint.c (print_solib_event, check_status_catch_solib):
6714 Remove struct keyword in range-based for loops.
6715 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
6716 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
6718 * linespec.c (find_superclass_methods, search_minsyms_for_name):
6720 * symfile.c (addr_info_make_relative): Likewise.
6721 * thread.c (value_in_thread_stack_temporaries): Likewise.
6723 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
6726 * valops.c (value_struct_elt_for_reference): Call check_typedef on
6727 aggregate type to get its real type before accessing it.
6729 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
6731 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
6732 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
6733 * coff-pe-read.c (add_pe_forwarded_sym): Replace
6734 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
6735 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
6736 * jit.c (jit_breakpoint_re_set_internal): Likewise.
6737 * printcmd.c (info_address_command): Likewise.
6739 2018-05-29 Tom Tromey <tom@tromey.com>
6741 * windows-nat.c (handle_exception): Update fall-through comment.
6743 2018-05-29 Tom Tromey <tom@tromey.com>
6745 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
6746 (struct program_space) <added_solibs>: Now a std::vector.
6747 * breakpoint.c (print_solib_event): Update.
6748 (check_status_catch_solib): Update.
6749 * progspace.c (clear_program_space_solib_cache): Update.
6750 * solib.c (update_solib_list): Update.
6752 2018-05-29 Tom Tromey <tom@tromey.com>
6754 * python/py-type.c (typy_richcompare): Update.
6755 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
6756 * gdbtypes.h (types_deeply_equal): Return bool.
6757 (types_equal): Likewise.
6758 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6760 (check_types_equal): Change worklist to std::vector. Return
6762 (struct type_equality_entry): Add constructor.
6763 (compare_maybe_null_strings): Return bool.
6764 (check_types_worklist): Return bool. Change worklist to
6766 (types_deeply_equal): Use std::vector.
6767 (types_equal): Return bool.
6768 (compare_maybe_null_strings): Simplify.
6770 2018-05-29 Tom Tromey <tom@tromey.com>
6772 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6774 2018-05-29 Tom Tromey <tom@tromey.com>
6776 * objc-lang.h: Don't include cp-support.h.
6777 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6780 2018-05-27 Tom Tromey <tom@tromey.com>
6782 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6784 2018-05-25 Tom Tromey <tom@tromey.com>
6786 * value.c (value::location): Initialize.
6788 2018-05-25 Tom Tromey <tom@tromey.com>
6790 * dbxread.c (init_bincl_list): Remove.
6791 (bincl_list): Now a std::vector.
6792 (bincls_allocated, next_bincl): Remove.
6793 (free_bincl_list, do_free_bincl_list_cleanup)
6794 (make_cleanup_free_bincl_list): Remove.
6795 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
6797 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
6798 (struct header_file_location): Add constructor.
6799 (add_bincl_to_list): Remove.
6801 2018-05-25 Tom Tromey <tom@tromey.com>
6803 * tui/tui.c (tui_enable): Update.
6804 * mi/mi-interp.c (mi_interp::init): Update.
6805 * interps.h (class interp) <name>: New method.
6806 <m_name>: Rename from name.
6807 (~scoped_restore_interp): Update.
6808 * interps.c (interp::interp): Update.
6809 (interp_add, interp_set, interp_lookup_existing)
6810 (current_interp_named_p): Update.
6812 2018-05-25 Tom Tromey <tom@tromey.com>
6814 * interps.c (interp_name): Remove.
6815 * mi/mi-interp.c (mi_interp::init): Update.
6816 * interps.h (interp_name): Remove.
6817 (~scoped_restore_interp): Update.
6818 * tui/tui.c (tui_enable): Update.
6820 2018-05-25 Tom Tromey <tom@tromey.com>
6822 * utils.c (fputs_maybe_filtered): Update.
6823 * linespec.c (decode_line_full): Update.
6824 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
6825 (mi_print_breakpoint_for_event, mi_solib_loaded)
6826 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6827 (mi_user_selected_context_changed): Update.
6828 * mi/mi-main.c (mi_execute_command): Update.
6829 * cli/cli-script.c (execute_control_command): Update.
6830 * python/python.c (execute_gdb_command): Update.
6831 * solib.c (info_sharedlibrary_command): Update.
6832 * interps.c (interp_ui_out): Remove.
6833 * interps.h (interp_ui_out): Remove.
6835 2018-05-25 Tom Tromey <tom@tromey.com>
6837 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
6838 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
6839 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
6841 2018-05-25 Tom Tromey <tom@tromey.com>
6843 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
6844 * interps.c (interp_exec): Use scoped_restore.
6846 2018-05-25 Tom Tromey <tom@tromey.com>
6848 * remote.c (remote_target::remote_file_get): Use
6850 (remote_target::remote_file_put): Likewise.
6852 2018-05-25 Tom Tromey <tom@tromey.com>
6854 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
6856 (get_pe_section_index, add_pe_exported_sym): Update.
6857 (read_pe_exported_syms): Use gdb::def_vector.
6859 2018-05-25 Tom Tromey <tom@tromey.com>
6861 * frame.c (remove_prev_frame): Remove.
6862 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
6864 2018-05-25 Maciej W. Rozycki <macro@mips.com>
6866 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
6868 * mips-linux-nat.c (supply_fpregset): Always call
6869 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
6870 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
6871 `mips_fill_fpregset'.
6872 * mips-linux-tdep.c (mips_supply_fpregset)
6873 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
6874 (mips_fill_fpregset_wrapper): Remove functions.
6875 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
6876 (mips_linux_fpregset): Remove variable.
6877 (mips_linux_iterate_over_regset_sections): Use
6878 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
6879 (mips_linux_o32_sigframe_init): Remove comment.
6881 2018-05-25 Pedro Alves <palves@redhat.com>
6883 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
6884 (struct readahead_cache, struct packet_reg, struct
6885 remote_arch_state, class remote_state): Move higher up in the
6887 (remote_target::m_remote_state): Now an object instead of a pointer.
6888 (remote_target::get_remote_state): Adjust.
6890 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6892 * stack.c (select_and_print_frame): Delete.
6893 (struct function_bounds): Move struct within function.
6894 (func_command): Most content moved into new function
6895 find_frame_for_function, use new function, print result, add
6897 (find_frame_for_function): New function, now returns a result.
6899 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6901 * stack.c (iterate_over_block_arg_vars): Fix comment.
6902 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
6904 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6908 (scoped_restore_selected_frame::scoped_restore_selected_frame):
6910 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
6912 * frame.h (class scoped_restore_selected_frame): New class.
6913 * stack.c (print_frame_local_vars): Remove catching and rethrowing
6914 of any exception, use scoped_restore_selected_frame to restore the
6917 2018-05-24 Pedro Alves <palves@redhat.com>
6919 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
6922 2018-05-23 Tom Tromey <tom@tromey.com>
6924 * complaints.c (struct complaints): Remove.
6925 (symfile_complaint_book): Remove.
6926 (series): New global.
6927 (complaint_internal): Update.
6928 (clear_complaints): Update.
6930 2018-05-23 Tom Tromey <tom@tromey.com>
6932 * complaints.c (counters): New global.
6933 (struct complain): Remove.
6934 (struct complaints) <root>: Remove.
6935 (complaint_sentinel): Remove.
6936 (symfile_complaint_book): Update.
6937 (find_complaint) Remove.
6938 (complaint_internal, clear_complaints): Update.
6940 2018-05-23 Tom Tromey <tom@tromey.com>
6942 * complaints.c (struct complain) <file, line>: Remove.
6943 (find_complaint): Remove file, line parameters.
6944 (complaint_internal): Update.
6946 2018-05-23 Tom Tromey <tom@tromey.com>
6948 * complaints.c (vcomplaint): Remove.
6949 (complaint_internal) Merge in contents of vcomplaint.
6951 2018-05-23 Tom Tromey <tom@tromey.com>
6953 * complaints.c (struct complaints) <explanation>: Remove.
6954 (symfile_explanations): Remove.
6955 (symfile_complaint_book): Update.
6956 (vcomplaint): Update.
6957 (struct explanation): Remove.
6959 2018-05-23 Tom Tromey <tom@tromey.com>
6961 * complaints.c (symfile_complaints): Remove.
6962 (complaint_internal): Remove "complaints" parameter.
6963 (clear_complaints, vcomplaint): Remove "c" parameter.
6964 (get_complaints): Remove.
6965 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6966 (dwarf2_debug_line_missing_file_complaint)
6967 (dwarf2_debug_line_missing_end_sequence_complaint)
6968 (dwarf2_complex_location_expr_complaint)
6969 (dwarf2_const_value_length_mismatch_complaint)
6970 (dwarf2_section_buffer_overflow_complaint)
6971 (dwarf2_macro_malformed_definition_complaint)
6972 (dwarf2_invalid_attrib_class_complaint)
6973 (create_addrmap_from_index, dw2_symtab_iter_next)
6974 (dw2_expand_marked_cus)
6975 (dw2_debug_names_iterator::find_vec_in_debug_names)
6976 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6977 (create_debug_type_hash_table, init_cutu_and_read_dies)
6978 (partial_die_parent_scope, add_partial_enumeration)
6979 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6980 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6981 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6982 (create_cus_hash_table, create_dwp_hash_table)
6983 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6984 (dwarf2_rnglists_process, dwarf2_ranges_process)
6985 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6986 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6987 (handle_struct_member_die, process_structure_scope)
6988 (read_array_type, read_common_block, read_module_type)
6989 (read_tag_pointer_type, read_typedef, read_base_type)
6990 (read_subrange_type, load_partial_dies, partial_die_info::read)
6991 (partial_die_info::read, partial_die_info::read)
6992 (partial_die_info::read, read_checked_initial_length_and_offset)
6993 (dwarf2_string_attr, read_formatted_entries)
6994 (dwarf_decode_line_header)
6995 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6996 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6997 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6998 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6999 (get_signatured_type, get_DW_AT_signature_type)
7000 (decode_locdesc, file_file_name, consume_improper_spaces)
7001 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
7002 (dwarf_decode_macro_bytes, dwarf_decode_macros)
7003 (dwarf2_symbol_mark_computed, set_die_type)
7004 (read_attribute_value): Update.
7005 * stap-probe.c (handle_stap_probe, get_stap_base_address):
7007 * dbxread.c (unknown_symtype_complaint)
7008 (lbrac_mismatch_complaint, repeated_header_complaint)
7009 (set_namestring, function_outside_compilation_unit_complaint)
7010 (read_dbx_symtab, process_one_symbol): Update.
7011 * gdbtypes.c (stub_noname_complaint): Update.
7012 * windows-nat.c (handle_unload_dll): Update.
7013 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
7014 (decode_base_type): Update.
7015 * xcoffread.c (bf_notfound_complaint, ef_complaint)
7016 (eb_complaint, record_include_begin, record_include_end)
7017 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
7018 (process_xcoff_symbol, read_symbol)
7019 (function_outside_compilation_unit_complaint)
7020 (scan_xcoff_symtab): Update.
7021 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
7022 * buildsym.c (finish_block_internal, make_blockvector)
7023 (end_symtab_get_static_block, augment_type_symtab): Update.
7024 * dtrace-probe.c (dtrace_process_dof)
7025 (dtrace_static_probe_ops::get_probes): Update.
7026 * complaints.h (struct complaint): Don't declare.
7027 (symfile_complaints): Remove.
7028 (complaint_internal): Remove "complaints" parameter.
7029 (complaint): Likewise.
7030 (clear_complaints): Likewise.
7031 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7032 (reread_symbols): Update.
7033 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
7034 (dwarf2_frame_cache, decode_frame_entry): Update.
7035 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
7036 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7037 (info_selectors_command): Update.
7038 * macrotab.c (macro_include, check_for_redefinition)
7039 (macro_undef): Update.
7040 * objfiles.c (filter_overlapping_sections): Update.
7041 * stabsread.c (invalid_cpp_abbrev_complaint)
7042 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
7043 (define_symbol, error_type, read_type, rs6000_builtin_type)
7044 (stabs_method_name_from_physname, read_member_functions)
7045 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
7046 (attach_fields_to_type, complain_about_struct_wipeout)
7047 (read_range_type, read_args, common_block_start)
7048 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
7050 * mdebugread.c (index_complaint, unknown_ext_complaint)
7051 (basic_type_complaint, bad_tag_guess_complaint)
7052 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
7053 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
7054 (parse_procedure, parse_lines)
7055 (function_outside_compilation_unit_complaint)
7056 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
7057 (bad_tag_guess_complaint, reg_value_complaint): Update.
7058 * cp-support.c (demangled_name_complaint): Update.
7059 * macroscope.c (sal_macro_scope): Update.
7060 * dwarf-index-write.c (class debug_names): Update.
7062 2018-05-23 Tom Tromey <tom@tromey.com>
7064 * complaints.c (clear_complaints): Remove "noisy" parameter.
7065 * complaints.h (clear_complaints): Update.
7066 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7067 (reread_symbols): Update.
7069 2018-05-23 Tom Tromey <tom@tromey.com>
7071 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
7073 (vcomplaint, clear_complaints): Update.
7074 (symfile_explanations): Remove some messages.
7076 2018-05-23 Tom Tromey <tom@tromey.com>
7078 * complaints.c (internal_complaint): Remove.
7079 * complaints.h (internal_complaint): Remove.
7081 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7083 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
7085 2018-05-22 Pedro Alves <palves@redhat.com>
7087 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
7088 (remote_fileio_badfd, remote_fileio_return_errno)
7089 (remote_fileio_return_success, remote_fileio_func_open)
7090 (remote_fileio_func_open, remote_fileio_func_close)
7091 (remote_fileio_func_read, remote_fileio_func_write)
7092 (remote_fileio_func_lseek, remote_fileio_func_rename)
7093 (remote_fileio_func_unlink, remote_fileio_func_stat)
7094 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
7095 (remote_fileio_func_isatty, remote_fileio_func_system): Add
7096 remote_target parameter.
7097 (remote_fio_func_map) <func>: Add remote_target parameter.
7098 (do_remote_fileio_request, remote_fileio_request):
7099 * remote-fileio.h (remote_fileio_request):
7100 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
7101 remote_target parameter.
7102 (remote_notif_process, handle_notification): Adjust to pass down
7104 (remote_notif_state_allocate): Add remote_target parameter. Save
7106 * remote-notif.h (struct remote_target): Forward declare.
7107 (struct notif_client) <parse, ack, can_get_pending_events>: Add
7108 remote_target parameter.
7109 (struct remote_notif_state) <remote>: New field.
7110 (remote_notif_ack, remote_notif_parse): Add remote_target
7112 (remote_notif_state_allocate, remote_notif_state_allocate): Add
7113 remote_target parameter.
7114 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
7115 (threads_listing_context, rmt_thread_action, protocol_feature)
7116 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
7117 (packet_result, struct threads_listing_context, remote_state):
7118 Move definitions and declarations higher up.
7119 (remote_target) <~remote_target>: Declare.
7120 (remote_download_command_source, remote_file_put, remote_file_get)
7121 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
7122 (remote_hostio_pread_vFile, remote_hostio_send_command)
7123 (remote_hostio_set_filesystem, remote_hostio_open)
7124 (remote_hostio_close, remote_hostio_unlink, remote_state)
7125 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
7126 (get_memory_write_packet_size, get_memory_read_packet_size)
7127 (append_pending_thread_resumptions, remote_detach_1)
7128 (append_resumption, remote_resume_with_vcont)
7129 (add_current_inferior_and_thread, wait_ns, wait_as)
7130 (process_stop_reply, remote_notice_new_inferior)
7131 (process_initial_stop_replies, remote_add_thread)
7132 (btrace_sync_conf, remote_btrace_maybe_reopen)
7133 (remove_new_fork_children, kill_new_fork_children)
7134 (discard_pending_stop_replies, stop_reply_queue_length)
7135 (check_pending_events_prevent_wildcard_vcont)
7136 (discard_pending_stop_replies_in_queue, stop_reply)
7137 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
7138 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
7139 (remote_interrupt_as, remote_interrupt_ns)
7140 (remote_get_noisy_reply, remote_query_attached)
7141 (remote_add_inferior, remote_current_thread, get_current_thread)
7142 (set_thread, set_general_thread, set_continue_thread)
7143 (set_general_process, write_ptid)
7144 (remote_unpack_thread_info_response, remote_get_threadinfo)
7145 (parse_threadlist_response, remote_get_threadlist)
7146 (remote_threadlist_iterator, remote_get_threads_with_ql)
7147 (remote_get_threads_with_qxfer)
7148 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
7149 (get_offsets, remote_check_symbols, remote_supported_packet)
7150 (remote_query_supported, remote_packet_size)
7151 (remote_serial_quit_handler, remote_detach_pid)
7152 (remote_vcont_probe, remote_resume_with_hc)
7153 (send_interrupt_sequence, interrupt_query)
7154 (remote_notif_get_pending_events, fetch_register_using_p)
7155 (send_g_packet, process_g_packet, fetch_registers_using_g)
7156 (store_register_using_P, store_registers_using_G)
7157 (set_remote_traceframe, check_binary_download)
7158 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
7159 (remote_xfer_live_readonly_partial, remote_read_bytes)
7160 (remote_send_printf, remote_flash_write, readchar)
7161 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
7162 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
7163 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
7164 (extended_remote_disable_randomization, extended_remote_run)
7165 (send_environment_packet, extended_remote_environment_support)
7166 (extended_remote_set_inferior_cwd, remote_write_qxfer)
7167 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
7168 (packet_command): Now methods of ...
7169 (remote_target): ... this class.
7170 (m_remote_state) <remote_target>: New field.
7171 (struct remote_state) <stop_reply_queue,
7172 remote_async_inferior_event_token, wait_forever_enabled_p>: New
7174 (remote_state::remote_state): Allocate stop_reply_queue.
7175 (remote_state): Delete global.
7176 (get_remote_state_raw): Delete.
7177 (remote_target::get_remote_state): Allocate m_remote_state on
7179 (get_current_remote_target): New.
7180 (remote_ops, extended_remote_ops): Delete.
7181 (wait_forever_enabled_p, remote_async_inferior_event_token):
7182 Delete, moved to struct remote_state.
7183 (remote_target::close): Delete self. Destruction bits split to
7185 (remote_target::~remote_target): ... this.
7186 (show_memory_packet_size): Adjust to use
7187 get_current_remote_target.
7188 (struct protocol_feature) <func>: Add remote_target parameter.
7189 All callers adjusted.
7190 (curr_quit_handler_target): New.
7191 (remote_serial_quit_handler): Reimplement.
7192 (remote_target::open_1): Adjust to use get_current_remote_target.
7193 Heap-allocate remote_target/extended_remote_target instances.
7194 (vcont_builder::vcont_builder): Add remote_target parameter, and
7195 save it in m_remote. All callers adjusted.
7196 (vcont_builder::m_remote): New field.
7197 (vcont_builder::restart, vcont_builder::flush)
7198 (vcont_builder::push_action): Use it.
7199 (remote_target::commit_resume): Use it.
7200 (struct queue_iter_param) <remote>: New field.
7201 (remote_target::remove_new_fork_children): Fill in 'remote' field.
7202 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
7203 (check_pending_event_prevents_wildcard_vcont_callback)
7204 (remote_target::check_pending_events_prevent_wildcard_vcont)
7205 (remote_target::discard_pending_stop_replies)
7206 (remote_target::discard_pending_stop_replies_in_queue)
7207 (remote_target::remote_notif_remove_queued_reply): Fill in
7209 (remote_notif_get_pending_events): New.
7210 (remote_target::readchar, remote_target::remote_serial_write):
7211 Save/restore curr_quit_handler_target.
7213 (kill_new_fork_children): Fill in 'remote' field.
7214 (packet_command): Use get_current_remote_target, defer to
7215 remote_target method of same name.
7216 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
7217 parameter, and save it in m_remote. All callers adjusted.
7218 (scoped_remote_fd::release): Use m_remote.
7219 (scoped_remote_fd::m_remote): New field.
7220 (remote_file_put, remote_file_get, remote_file_delete): Use
7221 get_current_remote_target, defer to remote_target method of same
7223 (remote_btrace_reset): Add remote_state paremeter. Update all
7225 (remote_async_inferior_event_handler). Pass down 'data'.
7226 (remote_new_objfile): Use get_current_remote_target.
7227 (remote_target::vcont_r_supported): New.
7228 (set_range_stepping): Use get_current_remote_target and
7229 remote_target::vcont_r_supported.
7230 (_initialize_remote): Don't allocate 'remote_state' and
7231 'stop_reply_queue' globals.
7232 * remote.h (struct remote_target): Forward declare.
7233 (getpkt, putpkt, remote_notif_get_pending_events): Add
7234 'remote_target' parameter.
7236 2018-05-22 Pedro Alves <palves@redhat.com>
7238 * remote.c (vcont_builder): Now a class. Make all data members
7240 (vcont_builder) <vcont_builder, restart, flush, push_action>:
7242 (vcont_builder_restart): Rename to ...
7243 (vcont_builder::restart): ... this.
7244 (vcont_builder_flush): Rename to ...
7245 (vcont_builder::flush): ... this.
7246 (vcont_builder_push_action): Rename to ...
7247 (vcont_builder::push_action): ... this.
7248 (remote_target::commit_resume): Adjust.
7250 2018-05-22 Pedro Alves <palves@redhat.com>
7252 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
7253 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
7254 (get_fixed_memory_packet_size): New.
7255 (get_memory_packet_size): Use it.
7256 (set_memory_packet_size): Don't override the config size with
7257 DEFAULT_MAX_MEMORY_PACKET_SIZE.
7258 (show_memory_packet_size): Use get_fixed_memory_packet_size.
7259 Don't refer to get_memory_packet_size if not connected to a remote
7260 target. Show "(default)" if configured size is 0.
7262 2018-05-22 Pedro Alves <palves@redhat.com>
7264 * remote.c (remote_target::mourn_inferior): Move
7265 discard_pending_stop_replies call here from ...
7266 (_initialize_remote): ... here.
7268 2018-05-22 Pedro Alves <palves@redhat.com>
7270 * remote.c (compare_section_command): Remove set_general_process
7273 2018-05-22 Pedro Alves <palves@redhat.com>
7275 * remote.c (struct packet_reg, struct remote_arch_state):
7276 Move higher up in the file.
7277 (remote_state) <m_arch_states>: Store remote_arch_state values
7278 instead of remote_arch_state pointers.
7279 (remote_state::get_remote_arch_state): Adjust.
7281 2018-05-22 Pedro Alves <palves@redhat.com>
7283 * remote.c: Include <unordered_map>.
7284 (remote_state): Now a class.
7285 (remote_state) <get_remote_arch_state>: Declare method.
7286 <get_remote_arch_state>: New field.
7287 (remote_arch_state) <remote_arch_state>: Declare ctor.
7288 <regs>: Now a unique_ptr.
7289 (remote_gdbarch_data_handle): Delete.
7290 (get_remote_arch_state): Delete.
7291 (remote_state::get_remote_arch_state): New.
7292 (get_remote_state): Adjust to call remote_state's
7293 get_remote_arch_state method.
7294 (init_remote_state): Delete, bits factored out to ...
7295 (remote_arch_state::remote_arch_state): ... this new method.
7296 (get_remote_packet_size, get_memory_packet_size)
7297 (process_g_packet, remote_target::fetch_registers)
7298 (remote_target::prepare_to_store, store_registers_using_G)
7299 (remote_target::store_registers, remote_target::get_trace_status):
7300 Adjust to call remote_state's method.
7301 (_initialize_remote): Remove reference to
7302 remote_gdbarch_data_handle.
7304 2018-05-22 Pedro Alves <palves@redhat.com>
7306 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
7307 pread>: New method declarations.
7308 (remote_target::open_1): Adjust.
7309 (readahead_cache_invalidate): Rename to ...
7310 (readahead_cache::invalidate): ... this, and adjust to be a class
7312 (readahead_cache_invalidate_fd): Rename to ...
7313 (readahead_cache::invalidate_fd): ... this, and adjust to be a
7315 (remote_hostio_pwrite): Adjust.
7316 (remote_hostio_pread_from_cache): Rename to ...
7317 (readahead_cache::pread): ... this, and adjust to be a class
7319 (remote_hostio_close): Adjust.
7321 2018-05-22 Pedro Alves <palves@redhat.com>
7323 * remote.c (remote_hostio_close_cleanup): Delete.
7324 (class scoped_remote_fd): New.
7325 (remote_file_put, remote_file_get): Use it.
7327 2018-05-22 Pedro Alves <palves@redhat.com>
7329 (struct vCont_action_support): Use bool and initialize all fields.
7330 (struct readahead_cache): Initialize all fields.
7331 (remote_state): Use bool and initialize all fields.
7332 (remote_state::remote_state, remote_state::~remote_state): New.
7333 (new_remote_state): Delete.
7334 (_initialize_remote): Use new to allocate remote_state.
7336 2018-05-22 Pedro Alves <palves@redhat.com>
7340 * c-exp.y: Include "c-support.h".
7341 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
7342 of tolower. Use c_ident_is_alpha to scan names.
7343 * c-lang.c: Include "c-support.h".
7344 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
7345 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
7346 * c-support.h: New file, with bits factored out from ...
7347 * cp-name-parser.y: ... this file.
7348 Include "c-support.h".
7349 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
7350 c-support.h and renamed.
7351 (symbol_end, yylex): Adjust.
7353 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7355 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
7356 parameter type to CORE_ADDR.
7357 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
7358 parameter type in declaration to CORE_ADDR.
7359 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
7360 target_auxv_search to get AT_HWCAP and use the result to get the
7362 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
7363 to CORE_ADDR. Remove the cast of the return value to unsigned
7364 long. Fix error predicate of target_auxv_search.
7365 (ppc_linux_nat_target::read_description): Change the type of the
7366 hwcap variable to CORE_ADDR.
7368 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7370 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
7371 if the size of fpscr is larger than 32 bits.
7373 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7375 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
7376 (ppc32_linux_vsxregmap): New global.
7377 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
7378 regcache_supply_regset, and regcache_collect_regset.
7379 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
7380 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
7381 (fetch_vsx_register, store_vsx_register): Remove.
7382 (fetch_vsx_registers): Add regno parameter. Get regset using
7383 ppc_linux_vsxregset. Use regset to supply registers.
7384 (store_vsx_registers): Add regno parameter. Get regset using
7385 ppc_linux_vsxregset. Use regset to collect registers.
7386 (fetch_register): Call fetch_vsx_registers instead of
7388 (store_register): Call store_vsx_registers instead of
7390 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
7391 new regno parameter.
7392 (store_ppc_registers): Call store_vsx_registers with -1 for the
7393 new regno parameter.
7394 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
7395 (ppc_collect_vsxregset): Remove.
7397 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7399 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
7401 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
7402 for vector register offset fields.
7403 (ppc64_fbsd_reg_offsets): Likewise.
7404 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7405 to vector register offset fields.
7406 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7407 to vector register offset fields.
7408 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
7409 vector register offset fields.
7410 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
7411 initializers for vector register offset fields.
7412 (rs6000_aix64_reg_offsets): Likewise.
7413 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
7414 (ppc_supply_vrregset): Remove.
7415 (ppc_collect_vrregset): Remove.
7416 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
7417 (ppc_linux_vrregset) : New function.
7418 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
7419 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
7420 (ppc32_linux_vrregset): Remove.
7421 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
7422 and use result instead of ppc32_linux_vrregset.
7423 (ppc32_linux_reg_offsets): Remove initializers for vector register
7425 (ppc64_linux_reg_offsets): Likewise.
7426 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
7427 * ppc-linux-nat.c: Include regset.h.
7428 (gdb_vrregset_t): Adjust comment to account for little-endian
7430 (supply_vrregset, fill_vrregset): Remove.
7431 (fetch_altivec_register, store_altivec_register): Remove.
7432 (fetch_altivec_registers): Add regno parameter. Get regset using
7433 ppc_linux_vrregset. Use regset to supply registers.
7434 (store_altivec_registers): Add regno parameter. Get regset using
7435 ppc_linux_vrregset. Use regset to collect registers.
7436 (fetch_register): Call fetch_altivec_registers instead of
7437 fetch_altivec_register.
7438 (store_register): Call store_altivec_registers instead of
7439 store_altivec_register.
7440 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
7441 the new regno parameter.
7442 (store_ppc_registers): Call store_altivec_registers with -1 for
7443 the new regno parameter.
7445 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7447 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
7448 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
7449 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
7450 (gdb_vrregset_t): Change array type size to
7451 PPC_LINUX_SIZEOF_VRREGSET.
7452 (gdb_vsxregset_t): Change array type size to
7453 PPC_LINUX_SIZEOF_VSXREGSET.
7454 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
7455 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
7456 PPC_LINUX_SIZEOF_VSXREGSET.
7458 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7460 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
7461 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
7463 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
7464 ppc_linux_target_wordsize with tid.
7465 (ppc_linux_nat_target::read_description): Call ppc_linux_target
7467 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
7468 (ppc64_64bit_inferior_p): Add static and inline specifiers.
7469 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
7470 tid parameter. Remove static specifier.
7471 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
7472 (ppc_linux_target_wordsize): New declaration.
7474 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7476 * arch/ppc-linux-common.c: New file.
7477 * arch/ppc-linux-common.h: New file.
7478 * arch/ppc-linux-tdesc.h: New file.
7479 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
7480 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
7481 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
7482 arch/ppc-linux-tdesc.h.
7483 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
7484 arch/ppc-linux-tdesc.h.
7485 (ppc_linux_nat_target::read_description): Remove target
7486 description matching code. Fill a ppc_linux_features struct and
7487 call ppc_linux_match_description with it. Move comment about ISA
7488 2.05 to ppc-linux-common.c.
7489 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
7490 arch/ppc-linux-tdesc.h.
7491 (ppc_linux_core_read_description): Remove target description
7492 matching code. Fill a ppc_linux_features struct and call
7493 ppc_linux_match_description with it.
7494 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
7495 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
7496 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
7497 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
7498 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
7499 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
7500 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
7501 (tdesc_powerpc_e500l): Remove.
7503 2018-05-22 Joel Brobecker <brobecker@adacore.com>
7505 * ada-lang.c (catch_assert_command): Pass empty string instead
7506 of NULL for excep_string argument.
7508 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7510 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
7511 the width of the requested register exceeds the width of the
7514 2018-05-21 Tom Tromey <tom@tromey.com>
7516 * printcmd.c (output_command): Remove.
7517 (output_command_const): Rename to output_command.
7518 * valprint.h (output_command): Rename from output_command_const.
7519 * tracepoint.c (trace_dump_actions): Call output_command.
7521 2018-05-21 Tom Tromey <tom@tromey.com>
7523 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7524 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
7525 * ada-lang.h (create_ada_exception_catchpoint): Update.
7526 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
7528 (create_excep_cond_exprs, ~ada_catchpoint)
7529 (should_stop_exception, print_one_exception)
7530 (print_mention_exception, print_recreate_exception): Update.
7531 (ada_get_next_arg): Remove.
7532 (catch_ada_exception_command_split): Use std::string. Change type
7533 of "excep_string", "cond_string".
7534 (catch_ada_exception_command): Update.
7535 (create_ada_exception_catchpoint): Change type of excep_string.
7536 (ada_exception_sal): Remove excep_string parameter.
7537 (~ada_catchpoint): Remove.
7539 2018-05-21 Tom Tromey <tom@tromey.com>
7541 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
7544 2018-05-21 Tom Tromey <tom@tromey.com>
7546 * ada-lang.c (ada_exception_message_1, ada_exception_message):
7547 Return unique_xmalloc_ptr.
7548 (print_it_exception): Update.
7550 2018-05-21 Tom Tromey <tom@tromey.com>
7552 * tracepoint.c (trace_dump_actions): Use std::string.
7554 2018-05-21 Tom Tromey <tom@tromey.com>
7556 * symfile.c (reread_symbols): Use std::string for original_name.
7558 2018-05-21 Tom Tromey <tom@tromey.com>
7560 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
7561 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
7564 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
7566 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
7568 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
7569 * objfiles.c (get_objfile_bfd_data): Allocate
7570 objfile_per_bfd_storage with obstack_new when allocating on
7573 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7575 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
7577 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
7578 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
7579 * mdebugread.c (mdebug_build_psymtabs): Likewise.
7580 (add_pending): Likewise.
7581 (parse_symbol): Likewise.
7582 (parse_partial_symbols): Likewise.
7583 (psymtab_to_symtab_1): Likewise.
7584 (new_psymtab): Likewise.
7585 (elfmdebug_build_psymtabs): Likewise.
7586 * minsyms.c (terminate_minimal_symbol_table): Likewise.
7587 * objfiles.c (get_objfile_bfd_data): Likewise.
7588 (objfile_register_static_link): Likewise.
7589 * psymtab.c (allocate_psymtab): Likewise.
7590 * stabsread.c (read_member_functions): Likewise.
7591 * xcoffread.c (xcoff_end_psymtab): Likewise.
7593 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7595 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
7596 compiler supports std::is_trivially_constructible.
7597 * common/poison.h: Include obstack.h.
7598 (IsMallocable): Define to is_trivially_constructible if the
7599 compiler supports it, define to true_type otherwise.
7603 (XOBNEWVEC): Redefine.
7604 * gdb_obstack.h (obstack_zalloc): New.
7605 (OBSTACK_ZALLOC): Redefine.
7606 (obstack_calloc): New.
7607 (OBSTACK_CALLOC): Redefine.
7609 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
7610 (gdbarch_obstack): New declaration in gdbarch.h, definition in
7612 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
7613 obstack_calloc/obstack_zalloc.
7614 (gdbarch_obstack_zalloc): Remove.
7615 * target-descriptions.c (tdesc_data_init): Use obstack_new.
7617 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7619 * stack.c (backtrace_command_1): Remove useless variable int i.
7621 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7623 * stack.c (print_frame_info): Fix comment.
7625 2018-05-18 Tom Tromey <tom@tromey.com>
7627 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
7628 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
7629 (~dwarf2_per_objfile): Update
7630 (dwarf2_get_dwz_file): Use new.
7631 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
7634 2018-05-18 Tom Tromey <tom@tromey.com>
7636 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
7638 * dwarf2read.c (struct dwp_file): Add constructor and
7640 (open_and_init_dwp_file): Return a unique_ptr.
7641 (dwarf2_per_objfile, create_dwp_hash_table)
7642 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
7643 (lookup_dwo_unit_in_dwp): Update.
7644 (open_and_init_dwp_file, get_dwp_file): Update.
7646 2018-05-18 Tom Tromey <tom@tromey.com>
7648 * dwarf2read.c (dwarf2_per_objfile): Update.
7649 (struct mapped_index): Add initializers.
7650 (dwarf2_read_index): Use new.
7651 (dw2_symtab_iter_init): Update.
7652 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
7655 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7657 * dwarf2read.c (mapped_index) <total_size>: Remove.
7659 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7661 * unittests/format_pieces-selftests.c (test_format_specifier):
7664 2018-05-18 Tom Tromey <tom@tromey.com>
7666 * c-typeprint.c (maybe_print_hole): New function.
7667 (c_print_type_struct_field_offset): Update.
7668 (c_type_print_base_struct_union): Call maybe_print_hole.
7670 2018-05-17 Keith Seitz <keiths@redhat.com>
7672 * breakpoint.c (build_bpstat_chain): New function, moved from
7674 (bpstat_stop_status): Add optional parameter, `stop_chain'.
7675 If no stop chain is passed, call build_bpstat_chain to build it.
7676 * breakpoint.h (build_bpstat_chain): Declare.
7677 (bpstat_stop_status): Move documentation here from breakpoint.c.
7678 * infrun.c (handle_signal_stop): Before eliding inlined frames,
7679 build the stop chain and pass it to skip_inline_frames.
7680 Pass this stop chain to bpstat_stop_status.
7681 * inline-frame.c: Include breakpoint.h.
7682 (stopped_by_user_bp_inline_frame): New function.
7683 (skip_inline_frames): Add parameter `stop_chain'.
7684 Move documention to inline-frame.h.
7685 If non-NULL, use stopped_by_user_bp_inline_frame to determine
7686 whether the frame should be elided.
7687 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
7688 Add moved documentation and update for new parameter.
7690 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7693 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7694 unittests/format_pieces-selftests.c.
7695 * common/format.h (format_piece) <operator==>: New.
7696 (format_pieces) <operator[]>: Remove.
7697 * common/format.c (format_pieces::format_pieces): Handle \e.
7698 * unittests/format_pieces-selftests.c: New.
7700 2018-05-17 Tom Tromey <tom@tromey.com>
7703 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
7704 (dw2_instantiate_symtab): Add skip_partial parameter.
7705 (dw2_find_last_source_symtab, dw2_map_expand_apply)
7706 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
7707 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
7708 (dw2_expand_symtabs_matching_one)
7709 (dw2_find_pc_sect_compunit_symtab)
7710 (dw2_debug_names_lookup_symbol)
7711 (dw2_debug_names_expand_symtabs_for_function): Update.
7712 (init_cutu_and_read_dies): Add skip_partial parameter.
7713 (process_psymtab_comp_unit, build_type_psymtabs_1)
7714 (process_skeletonless_type_unit, load_partial_comp_unit)
7715 (psymtab_to_symtab_1): Update.
7716 (load_full_comp_unit): Add skip_partial parameter.
7717 (process_imported_unit_die, dwarf2_read_addr_index)
7718 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
7719 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
7720 (read_signatured_type): Update.
7722 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7724 * value.c (release_value): Remove unused variable.
7725 (record_latest_value): Likewise.
7726 (access_value_history): Likewise.
7727 (preserve_values): Likewise.
7729 2018-05-17 Tom Tromey <tom@tromey.com>
7731 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
7734 2018-05-16 Maciej W. Rozycki <macro@mips.com>
7737 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
7738 Also handle registers whose width is not a multiple of
7740 (linux_nat_trad_target::store_register): Likewise.
7742 2018-05-16 Tom Tromey <tom@tromey.com>
7744 * gdbcore.h (core_bfd): Redefine.
7745 * corelow.c (core_target::close): Update.
7746 (core_target_open): Update.
7747 * progspace.h (struct program_space) <cbfd>: Now a
7750 2018-05-16 Tom Tromey <tom@tromey.com>
7753 * symfile-add-flags.h (enum symfile_add_flags)
7754 <SYMFILE_NOT_FILENAME>: New constant.
7755 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
7756 objfile name from BFD.
7757 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7758 * minidebug.c (find_separate_debug_file_in_section): Put
7759 ".gnu_debugdata" into BFD's file name.
7761 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7763 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7766 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7769 * aarch64-tdep.c (aarch64_analyze_prologue,
7770 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7771 Indicate not interested in errors.
7773 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7775 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7776 Supply the MIPS_ZERO_REGNUM register.
7778 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7780 * mips-tdep.c (mask_address_var): Make variable static.
7782 2018-05-14 Tom Tromey <tom@tromey.com>
7784 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7786 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7788 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7789 FXSAVE_ADDR for the mxcsr register.
7791 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7793 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
7795 2018-05-11 Pedro Alves <palves@redhat.com>
7797 * corelow.c (core_target) <core_target>: No longer inline.
7798 Initialize m_core_gdbarch, m_core_vec and build the section table
7800 <~core_target>: New.
7801 <core_gdbarch, get_core_register_section>: New methods.
7802 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
7803 factored out from ...
7804 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
7806 (sniff_core_bfd): Add gdbarch parameter.
7807 (core_close): Delete, merged into ...
7808 (core_target::close): ... here. Delete self.
7809 (core_close_cleanup): Delete.
7810 (core_target_open): Allocate a core_target on the heap. Use a
7811 unique_ptr instead of a cleanup. Bits moved into the core_target
7812 ctor. Adjust to use core_target methods instead of globals.
7813 (get_core_register_section): Rename to ...
7814 (core_target::get_core_register_section): ... this and adjust.
7815 (struct get_core_registers_cb_data): New.
7816 (get_core_registers_cb): Use it. Use bool.
7817 (core_target::fetch_registers, core_target::files_info)
7818 (core_target::xfer_partial, core_target::read_description)
7819 (core_target::pid_to, core_target::thread_name): Adjust to
7820 reference class fields instead of globals.
7821 * target.h (struct target_ops_deleter, target_ops_up): New.
7823 2018-05-11 Pedro Alves <palves@redhat.com>
7825 * corefile.c (core_file_command): Move to corelow.c.
7826 * corelow.c (the_core_target): Delete.
7827 (core_file_command): Moved from corefile.c. Check exec_bfd
7828 instead of the_core_target. Use target_detach instead of calling
7829 into the_core_target directly.
7830 (maybe_say_no_core_file_now): New.
7831 (core_target::detach): Use it.
7832 (_initialize_corelow): Remove references to the_core_target.
7833 * gdbcore.h (the_core_target): Delete.
7835 2018-05-11 Tom Tromey <tromey@redhat.com>
7836 Pedro Alves <palves@redhat.com>
7838 * corefile.c (core_bfd): Remove.
7839 * gdbcore.h (core_bfd): Now a macro.
7840 * progspace.h (struct program_space) <cbfd>: New field.
7842 2018-05-11 Tom Tromey <tom@tromey.com>
7844 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
7847 2018-05-10 Tom Tromey <tom@tromey.com>
7849 * configure: Rebuild.
7850 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
7852 2018-05-10 Joel Brobecker <brobecker@adacore.com>
7855 * regformats/regdat.sh: Adjust script, following the addition
7856 of the new expedite_regs parameter to init_target_desc.
7858 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
7861 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
7862 set_gdbarch_significant_addr_bit.
7863 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
7864 set_gdbarch_significant_addr_bit.
7865 * utils.c (address_significant): Update to sign extend addr.
7867 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
7869 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
7870 (xtensa_linux_init_abi): Limit tdep->num_regs by
7871 tdep->num_nopriv_regs.
7872 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
7873 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
7876 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
7878 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
7880 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
7882 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
7883 (I387_MXCSR_INIT_VAL): New constant.
7884 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
7885 buffer if it was supplied by the inferior.
7886 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
7887 (i387_xsave_get_clear_bv): New function.
7888 (i387_supply_xsave): Only read x87 control registers from the
7889 xsave buffer if the feature is enabled, and the state will have
7890 been written, otherwise, provide a suitable default.
7891 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
7892 including x87 control registers. Update control registers if they
7893 have changed from the default value, and mark features as enabled
7895 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
7897 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
7899 * spu-tdep.c (info_spu_event_command): Fix output formatting.
7901 2018-05-07 Tom Tromey <tom@tromey.com>
7903 * configure: Rebuild.
7904 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
7906 2018-05-07 Tom Tromey <tom@tromey.com>
7909 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
7910 bit. Use correct value for VDIV.
7912 2018-05-04 Tom Tromey <tom@tromey.com>
7914 * configure: Rebuild.
7915 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
7917 2018-05-04 Tom Tromey <tom@tromey.com>
7919 * linux-record.c (record_linux_system_call) <case
7920 RECORD_SYS_RECVFROM>: Add "break".
7922 2018-05-04 Tom Tromey <tom@tromey.com>
7924 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
7925 Add missing "break".
7926 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
7927 Add missing "break".
7929 2018-05-04 Tom Tromey <tom@tromey.com>
7931 * rs6000-tdep.c (ppc_process_record_op4)
7932 (ppc_process_record_op63): Add fall-through comment.
7934 2018-05-04 Tom Tromey <tom@tromey.com>
7936 * i386-tdep.c (i386_process_record): Add fall-through comment.
7938 2018-05-04 Tom Tromey <tom@tromey.com>
7940 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7943 2018-05-04 Tom Tromey <tom@tromey.com>
7945 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7946 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7947 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7949 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7951 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7954 2018-05-04 Tom Tromey <tom@tromey.com>
7956 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7958 2018-05-04 Tom Tromey <tom@tromey.com>
7960 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7961 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7962 * symfile.c (section_is_mapped): Fix fall-through comment.
7963 * stabsread.c (define_symbol, read_member_functions): Fix
7964 fall-through comment.
7965 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7967 * remote.c (remote_wait_as): Fix fall-through comment.
7968 * p-exp.y (yylex): Fix fall-through comment.
7969 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7971 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7972 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7973 * jv-exp.y (yylex): Fix fall-through comment.
7974 * go-exp.y (lex_one_token): Fix fall-through comment.
7975 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7976 fall-through comment.
7977 * f-exp.y (yylex): Fix fall-through comment.
7978 * dwarf2read.c (process_die): Fix fall-through comments.
7979 * dbxread.c (process_one_symbol): Fix fall-through comment.
7980 * d-exp.y (lex_one_token): Fix fall-through comment.
7981 * cp-name-parser.y (yylex): Fix fall-through comment.
7982 * coffread.c (coff_symtab_read): Fix fall-through comment.
7983 * c-exp.y (lex_one_token): Fix fall-through comment.
7984 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7986 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7989 2018-05-04 Tom Tromey <tom@tromey.com>
7992 * NEWS: Mention gdb.execute change.
7993 * gdbcmd.h (execute_control_command): Don't declare.
7994 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7995 execute_control_commands, execute_control_commands_to_string.
7996 * cli/cli-script.h (execute_control_commands)
7997 (execute_control_commands_to_string): Declare.
7998 (execute_control_command): Add from_tty parameter.
7999 * cli/cli-script.c (execute_control_commands)
8000 (execute_control_commands_to_string): New functions.
8001 (execute_user_command): Use execute_control_commands.
8002 (execute_control_command_1): Add "from_tty" parameter. Update.
8003 (execute_control_command): Likewise.
8005 2018-05-04 Tom Tromey <tom@tromey.com>
8008 * NEWS: Mention that breakpoint commands are writable.
8009 * python/py-breakpoint.c (bppy_set_commands): New function.
8010 (breakpoint_object_getset) <"commands">: Use it.
8012 2018-05-04 Tom Tromey <tom@tromey.com>
8014 * tracepoint.c (actions_command): Update.
8015 * mi/mi-cmd-break.c (mi_command_line_array)
8016 (mi_command_line_array_cnt, mi_command_line_array_ptr)
8017 (mi_read_next_line): Remove.
8018 (mi_cmd_break_commands): Update.
8019 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
8021 * cli/cli-script.c (get_command_line): Update.
8022 (process_next_line): Use function_view. Constify.
8023 (recurse_read_control_structure, read_command_lines)
8024 (read_command_lines_1): Change argument types to function_view.
8025 (do_define_command, document_command): Update.
8026 * breakpoint.h (check_tracepoint_command): Don't declare.
8027 * breakpoint.c (check_tracepoint_command): Remove.
8028 (commands_command_1, create_tracepoint_from_upload): Update.
8030 2018-05-04 Tom Tromey <tom@tromey.com>
8033 * cli/cli-script.h (enum command_control_type) <define_control>:
8035 * cli/cli-script.c (multi_line_command_p): Handle define_control.
8036 (build_command_line, execute_control_command_1)
8037 (process_next_line): Likewise.
8038 (do_define_command): New function, extracted from define_command.
8039 (define_command): Use it.
8041 2018-05-04 Tom Tromey <tom@tromey.com>
8043 * tracepoint.c (actions_command): Update.
8044 * cli/cli-script.h (read_command_lines): Update.
8045 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
8046 (MAX_TMPBUF): Remove define.
8047 (define_command): Use string_printf.
8048 (document_command): Likewise.
8049 * breakpoint.c (commands_command_1): Update.
8051 2018-05-04 Tom Tromey <tom@tromey.com>
8053 * top.c (execute_command): Update.
8054 * cli/cli-script.h (print_command_lines): Now varargs.
8055 * cli/cli-script.c (print_command_lines): Now varargs.
8056 (execute_control_command_1) <case while_control, case if_control>:
8059 2018-05-04 Tom Tromey <tom@tromey.com>
8061 * tracepoint.c (all_tracepoint_actions): Rename from
8062 all_tracepoint_actions_and_cleanup. Change return type.
8063 (actions_command, encode_actions_1, encode_actions)
8064 (trace_dump_actions, tdump_command): Update.
8065 * remote.c (remote_download_command_source): Update.
8066 * python/python.c (gdbpy_eval_from_control_command)
8067 (python_command, python_interactive_command): Update.
8068 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8069 * guile/guile.c (guile_command)
8070 (gdbscm_eval_from_control_command, guile_command): Update.
8071 * compile/compile.c (compile_code_command)
8072 (compile_print_command, compile_to_object): Update.
8073 * cli/cli-script.h (struct command_lines_deleter): New.
8074 (counted_command_line): New typedef.
8075 (struct command_line): Add constructor, destructor.
8076 <body_list>: Remove.
8077 <body_list_0, body_list_1>: New members.
8078 (command_line_up): Remove typedef.
8079 (read_command_lines, read_command_lines_1, get_command_line):
8081 (copy_command_lines): Don't declare.
8082 * cli/cli-script.c (build_command_line): Use "new".
8083 (get_command_line): Return counted_command_line.
8084 (print_command_lines, execute_user_command)
8085 (execute_control_command_1, while_command, if_command): Update.
8086 (realloc_body_list): Remove.
8087 (process_next_line, recurse_read_control_structure): Update.
8088 (read_command_lines, read_command_lines_1): Return counted_command_line.
8089 (free_command_lines): Use "delete".
8090 (copy_command_lines): Remove.
8091 (define_command, document_command, show_user_1): Update.
8092 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
8093 a counted_command_line.
8094 * breakpoint.h (counted_command_line): Remove typedef.
8095 (breakpoint_set_commands): Update.
8096 * breakpoint.c (check_no_tracepoint_commands)
8097 (validate_commands_for_breakpoint): Update.
8098 (breakpoint_set_commands): Change commands to be a
8099 counted_command_line.
8100 (commands_command_1, update_dprintf_command_list)
8101 (create_tracepoint_from_upload): Update.
8103 2018-05-04 Tom Tromey <tom@tromey.com>
8105 * cli/cli-decode.h (cmd_list_element): New constructor.
8106 (~cmd_list_element): New destructor.
8107 (struct cmd_list_element): Add initializers.
8108 * cli/cli-decode.c (do_add_cmd): Use "new".
8109 (delete_cmd): Use "delete".
8111 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
8112 Pedro Alves <palves@redhat.com>
8114 PR breakpoints/19806 and support for PR external/20207.
8115 * NEWS: Mention Aarch64 watchpoint improvements.
8116 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
8117 watchpoints and PR external/20207 watchpoints.
8118 * nat/aarch64-linux-hw-point.c
8119 (kernel_supports_any_contiguous_range): New.
8120 (aarch64_watchpoint_offset): New.
8121 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
8122 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
8123 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
8124 (aarch64_align_watchpoint): New parameters aligned_offset_p and
8125 next_addr_orig_p. Support PR external/20207 watchpoints.
8126 (aarch64_downgrade_regs): New.
8127 (aarch64_dr_state_insert_one_point): New parameters offset and
8129 (aarch64_dr_state_remove_one_point): Likewise.
8130 (aarch64_handle_breakpoint): Update caller.
8131 (aarch64_handle_aligned_watchpoint): Likewise.
8132 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
8134 (aarch64_linux_set_debug_regs): Remove const from state. Call
8135 aarch64_downgrade_regs.
8136 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
8137 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
8138 (DR_CONTROL_MASK): ... this.
8139 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
8140 (unsigned int aarch64_watchpoint_offset): New prototype.
8141 (aarch64_linux_set_debug_regs): Remove const from state.
8142 * utils.c (align_up, align_down): Move to ...
8143 * common/common-utils.c (align_up, align_down): ... here.
8144 * utils.h (align_up, align_down): Move to ...
8145 * common/common-utils.h (align_up, align_down): ... here.
8147 2018-05-04 Joel Brobecker <brobecker@adacore.com>
8149 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
8150 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
8151 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
8152 Re-implement to match the ABI as summarized in GCC's
8153 gcc/config/sparc/sparc.c. All callers updated.
8154 (sparc32_store_arguments): Remove assertion.
8156 2018-05-04 Tom Tromey <tom@tromey.com>
8158 * printcmd.c: Don't include tui.h.
8159 (decode_format): Use skip_spaces.
8161 2018-05-04 Tom Tromey <tom@tromey.com>
8164 * printcmd.c (last_count): New global.
8165 (x_command): Use saved count when repeating.
8167 2018-05-04 Tom Tromey <tom@tromey.com>
8169 * nto-procfs.c (do_closedir_cleanup): Remove.
8170 (procfs_pidlist): Use gdb_dir_up.
8171 * procfs.c (do_closedir_cleanup): Remove.
8172 (proc_update_threads): Use gdb_dir_up.
8173 * common/filestuff.h (struct gdb_dir_deleter): New.
8174 (gdb_dir_up): New typedef.
8176 2018-05-04 Tom Tromey <tom@tromey.com>
8178 * ada-lang.c (print_mention_exception): Use std::string.
8180 2018-05-04 Tom Tromey <tom@tromey.com>
8182 * ada-lang.c (create_excep_cond_exprs): Update.
8183 (ada_exception_catchpoint_cond_string): Use std::string.
8185 2018-05-04 Tom Tromey <tom@tromey.com>
8187 * ada-lang.c (xget_renaming_scope): Return std::string.
8188 (old_renaming_is_invisible): Update.
8190 2018-05-04 Tom Tromey <tom@tromey.com>
8192 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
8193 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
8195 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
8197 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
8199 2018-05-04 Tom Tromey <tom@tromey.com>
8201 * remote.c (remote_query_supported_append): Change type.
8202 (remote_check_symbols): Update.
8204 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
8207 * configure.ac: Prepend libpython.
8208 * python/python-config.py: Likewise.
8209 * configure: Regenerate.
8211 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
8213 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
8215 2018-05-03 Pedro Alves <palves@redhat.com>
8218 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
8219 override. Write 'true' instead of '1'.
8220 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
8223 2018-05-02 Pedro Alves <palves@redhat.com>
8225 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
8226 add_inf_child_target.
8227 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
8228 add_inf_child_target.
8229 * aix-thread.c (aix_thread_target_info): New.
8230 (aix_thread_target) <shortname, longname, doc>: Delete.
8232 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
8233 add_inf_child_target.
8234 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
8235 add_inf_child_target.
8236 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
8237 add_inf_child_target.
8238 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
8239 add_inf_child_target.
8240 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
8241 add_inf_child_target.
8242 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
8243 add_inf_child_target.
8244 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
8245 add_inf_child_target.
8246 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
8247 add_inf_child_target.
8248 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
8249 add_inf_child_target.
8250 * bfd-target.c (target_bfd_target_info): New.
8251 (target_bfd) <shortname, longname, doc>: Delete.
8253 * bsd-kvm.c (bsd_kvm_target_info): New.
8254 (bsd_kvm_target) <shortname, longname, doc>: Delete.
8256 (bsd_kvm_target::open): Rename to ...
8257 (bsd_kvm_target_open): ... this. Adjust.
8258 * bsd-uthread.c (bsd_uthread_target_info): New.
8259 (bsd_uthread_target) <shortname, longname, doc>: Delete.
8261 * corefile.c (core_file_command): Adjust.
8262 * corelow.c (core_target_info): New.
8263 (core_target) <shortname, longname, doc>: Delete.
8265 (core_target::open): Rename to ...
8266 (core_target_open): ... this. Adjust.
8267 * ctf.c (ctf_target_info): New.
8268 (ctf_target) <shortname, longname, doc>: Delete.
8270 (ctf_target::open): Rename to ...
8271 (ctf_target_open): ... this.
8272 (_initialize_ctf): Adjust.
8273 * exec.c (exec_target_info): New.
8274 (exec_target) <shortname, longname, doc>: Delete.
8276 (exec_target::open): Rename to ...
8277 (exec_target_open): ... this.
8278 * gdbcore.h (core_target_open): Declare.
8279 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
8280 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
8281 add_inf_child_target.
8282 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
8283 add_inf_child_target.
8284 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
8285 add_inf_child_target.
8286 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
8287 add_inf_child_target.
8288 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
8289 add_inf_child_target.
8290 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
8291 add_inf_child_target.
8292 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
8293 add_inf_child_target.
8294 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
8295 add_inf_child_target.
8296 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
8297 add_inf_child_target.
8298 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
8299 add_inf_child_target.
8300 * inf-child.c (inf_child_target_info): New.
8301 (inf_child_target::info): New.
8302 (inf_child_open_target): Remove 'target' parameter. Use
8303 get_native_target instead.
8304 (inf_child_target::open): Delete.
8305 (add_inf_child_target): New.
8306 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
8309 (add_inf_child_target): Declare.
8310 (inf_child_open_target): Declare.
8311 * linux-thread-db.c (thread_db_target_info): New.
8312 (thread_db_target) <shortname, longname, doc>: Delete.
8314 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
8315 add_inf_child_target.
8316 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
8317 add_inf_child_target.
8318 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
8319 add_inf_child_target.
8320 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
8321 add_inf_child_target.
8322 * make-target-delegates (print_class): Adjust.
8323 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
8324 add_inf_child_target.
8325 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
8326 add_inf_child_target.
8327 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
8328 add_inf_child_target.
8329 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
8330 add_inf_child_target.
8331 * nto-procfs.c (nto_native_target_info): New.
8332 (nto_procfs_target_native) <shortname, longname, doc>:
8335 (nto_procfs_target_info): New.
8336 (nto_procfs_target_procfs) <shortname, longname, doc>:
8339 (init_procfs_targets): Adjust.
8340 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
8341 add_inf_child_target.
8342 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
8343 add_inf_child_target.
8344 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
8345 add_inf_child_target.
8346 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
8347 add_inf_child_target.
8348 * ravenscar-thread.c (ravenscar_target_info): New.
8349 (ravenscar_thread_target) <shortname, longname, doc>:
8352 * record-btrace.c (record_btrace_target_info):
8353 (record_btrace_target) <shortname, longname, doc>: Delete.
8355 (record_btrace_target::open): Rename to ...
8356 (record_btrace_target_open): ... this. Adjust.
8357 * record-full.c (record_longname, record_doc): New.
8358 (record_full_base_target) <shortname, longname, doc>: Delete.
8360 (record_full_target_info): New.
8361 (record_full_target): <shortname>: Delete.
8363 (record_full_core_open_1, record_full_open_1): Update comments.
8364 (record_full_base_target::open): Rename to ...
8365 (record_full_open): ... this.
8366 (cmd_record_full_restore): Update.
8367 (_initialize_record_full): Update.
8368 * remote-sim.c (remote_sim_target_info): New.
8369 (gdbsim_target) <shortname, longname, doc>: Delete.
8371 (gdbsim_target::open): Rename to ...
8372 (gdbsim_target_open): ... this.
8373 (_initialize_remote_sim): Adjust.
8374 * remote.c (remote_doc): New.
8375 (remote_target_info): New.
8376 (remote_target) <shortname, longname, doc>: Delete.
8378 (extended_remote_target_info): New.
8379 (extended_remote_target) <shortname, longname, doc>: Delete.
8381 (remote_target::open_1): Make static. Adjust.
8382 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
8383 * s390-linux-nat.c (_initialize_s390_nat): Use
8384 add_inf_child_target.
8385 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
8386 add_inf_child_target.
8387 * sol-thread.c (thread_db_target_info): New.
8388 (sol_thread_target) <shortname, longname, doc>: Delete.
8390 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
8391 add_inf_child_target.
8392 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
8393 add_inf_child_target.
8394 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
8395 add_inf_child_target.
8396 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
8397 add_inf_child_target.
8398 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
8399 add_inf_child_target.
8400 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
8401 add_inf_child_target.
8402 * spu-linux-nat.c (_initialize_spu_nat): Use
8403 add_inf_child_target.
8404 * spu-multiarch.c (spu_multiarch_target_info): New.
8405 (spu_multiarch_target) <shortname, longname, doc>: Delete.
8407 * target-delegates.c: Regenerate.
8408 * target.c: Include <unordered_map>.
8409 (target_ops_p): Delete.
8410 (DEF_VEC_P(target_ops_p)): Delete.
8411 (target_factories): New.
8412 (test_target_info): New.
8413 (test_target_ops::info): New.
8414 (open_target): Adjust to use target_factories.
8415 (add_target_with_completer): Rename to ...
8416 (add_target): ... this. Change prototype. Register target_info
8417 and open callback in target_factories. Register target_info in
8418 command context instead of target_ops.
8419 (add_target): Delete old implementation.
8420 (add_deprecated_target_alias): Change prototype. Adjust.
8421 (the_native_target): New.
8422 (set_native_target, get_native_target): New.
8423 (find_default_run_target): Use the_native_target.
8424 (find_attach_target, find_run_target): Simplify.
8425 (target_ops::open): Delete.
8426 (dummy_target_info): New.
8427 (dummy_target::shortname, dummy_target::longname)
8428 (dummy_target::doc): Delete.
8429 (dummy_target::info): New.
8430 (debug_target::shortname, debug_target::longname)
8431 (debug_target::doc): Delete.
8432 (debug_target::info): New.
8433 * target.h (struct target_info): New.
8434 (target_ops::~target_ops): Add comment.
8435 (target_ops::info): New.
8436 (target_ops::shortname, target_ops::longname, target_ops::doc): No
8437 longer virtual. Implement in terms of target_info.
8438 (set_native_target, get_native_target): Declare.
8439 (target_open_ftype): New.
8440 (add_target, add_target_with_completer)
8441 (add_deprecated_target_alias): Change prototype.
8442 (test_target) <shortname, longname, doc>: Delete.
8444 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
8445 add_inf_child_target.
8446 * tracefile-tfile.c (tfile_target_info): New.
8447 (tfile_target) <shortname, longname, doc>: Delete.
8449 (tfile_target::open): Rename to ...
8450 (tfile_target_open): ... this.
8451 (_initialize_tracefile_tfile): Adjust.
8452 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
8453 add_inf_child_target.
8454 * windows-nat.c (_initialize_windows_nat): Use
8455 add_inf_child_target.
8456 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
8457 add_inf_child_target.
8459 2018-05-02 Pedro Alves <palves@redhat.com>
8461 * linux-nat.h (linux_nat_target) <low_new_thread,
8462 low_delete_thread, low_new_fork, low_forget_process,
8463 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
8464 New virtual methods.
8465 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
8466 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
8467 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
8468 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
8469 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
8471 * linux-fork.c (delete_fork): Adjust to call low method.
8472 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
8473 (linux_nat_new_fork, linux_nat_forget_process_hook)
8474 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
8475 (linux_nat_status_is_event):
8476 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
8477 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
8479 (sigtrap_is_event): Rename to ...
8480 (linux_nat_target::low_status_is_event): ... this.
8481 (linux_nat_set_status_is_event): Delete.
8482 (save_stop_reason, linux_nat_wait_1)
8483 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
8485 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
8486 (linux_nat_set_new_fork, linux_nat_set_forget_process)
8487 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
8488 (linux_nat_set_prepare_to_resume): Delete.
8489 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
8490 low virtual methods.
8491 * amd64-linux-nat.c: Likewise.
8492 * arm-linux-nat.c: Likewise.
8493 * i386-linux-nat.c: Likewise.
8494 * ia64-linux-nat.c: Likewise.
8495 * mips-linux-nat.c: Likewise.
8496 * ppc-linux-nat.c: Likewise.
8497 * s390-linux-nat.c: Likewise.
8498 * sparc64-linux-nat.c: Likewise.
8499 * x86-linux-nat.c: Likewise.
8500 * x86-linux-nat.h: Include "nat/x86-linux.h".
8501 (x86_linux_nat_target) <low_new_fork, low_forget_process,
8502 low_prepare_to_resume, low_new_thread, low_delete_thread>:
8505 2018-05-02 Pedro Alves <palves@redhat.com>
8507 * target.h (target_ops)
8508 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8509 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
8510 stopped_by_watchpoint, have_continuable_watchpoint,
8511 stopped_data_address, watchpoint_addr_within_range,
8512 can_accel_watchpoint_condition, can_run, thread_alive,
8513 has_all_memory, has_memory, has_stack, has_registers,
8514 has_execution, can_async_p, is_async_p, supports_non_stop,
8515 always_non_stop_p, can_execute_reverse, supports_multi_process,
8516 supports_enable_disable_tracepoint,
8517 supports_disable_randomization, supports_string_tracing,
8518 supports_evaluation_of_breakpoint_conditions,
8519 can_run_breakpoint_commands, filesystem_is_local,
8520 can_download_tracepoint, get_trace_state_variable_value,
8521 set_trace_notes, get_tib_address, use_agent, can_use_agent,
8522 record_is_replaying, record_will_replay,
8523 augmented_libraries_svr4_read>: Adjust to return bool.
8524 * aarch64-linux-nat.c: All implementations adjusted.
8525 * aix-thread.c: All implementations adjusted.
8526 * arm-linux-nat.c: All implementations adjusted.
8527 * breakpoint.c: All implementations adjusted.
8528 * bsd-kvm.c: All implementations adjusted.
8529 * bsd-uthread.c: All implementations adjusted.
8530 * corelow.c: All implementations adjusted.
8531 * ctf.c: All implementations adjusted.
8532 * darwin-nat.c: All implementations adjusted.
8533 * darwin-nat.h: All implementations adjusted.
8534 * exec.c: All implementations adjusted.
8535 * fbsd-nat.c: All implementations adjusted.
8536 * fbsd-nat.h: All implementations adjusted.
8537 * gnu-nat.c: All implementations adjusted.
8538 * gnu-nat.h: All implementations adjusted.
8539 * go32-nat.c: All implementations adjusted.
8540 * ia64-linux-nat.c: All implementations adjusted.
8541 * inf-child.c: All implementations adjusted.
8542 * inf-child.h: All implementations adjusted.
8543 * inf-ptrace.c: All implementations adjusted.
8544 * inf-ptrace.h: All implementations adjusted.
8545 * linux-nat.c: All implementations adjusted.
8546 * linux-nat.h: All implementations adjusted.
8547 * mips-linux-nat.c: All implementations adjusted.
8548 * nto-procfs.c: All implementations adjusted.
8549 * ppc-linux-nat.c: All implementations adjusted.
8550 * procfs.c: All implementations adjusted.
8551 * ravenscar-thread.c: All implementations adjusted.
8552 * record-btrace.c: All implementations adjusted.
8553 * record-full.c: All implementations adjusted.
8554 * remote-sim.c: All implementations adjusted.
8555 * remote.c: All implementations adjusted.
8556 * s390-linux-nat.c: All implementations adjusted.
8557 * sol-thread.c: All implementations adjusted.
8558 * spu-multiarch.c: All implementations adjusted.
8559 * target-delegates.c: All implementations adjusted.
8560 * target.c: All implementations adjusted.
8561 * target.h: All implementations adjusted.
8562 * tracefile-tfile.c: All implementations adjusted.
8563 * tracefile.c: All implementations adjusted.
8564 * tracefile.h: All implementations adjusted.
8565 * windows-nat.c: All implementations adjusted.
8566 * x86-linux-nat.h: All implementations adjusted.
8567 * x86-nat.h: All implementations adjusted.
8569 2018-05-02 Pedro Alves <palves@redhat.com>
8571 * make-target-delegates (scan_target_h): Don't trim lines here.
8572 Replace sequences of tabs and/or whitespace with a single
8574 (top level, parsing methods): Trim each line before processing it
8577 2018-05-02 Pedro Alves <palves@redhat.com>
8578 John Baldwin <jhb@freebsd.org>
8580 * target.h (enum strata) <debug_stratum>: New.
8581 (struct target_ops) <all delegation methods>: Replace by C++
8582 virtual methods, and drop "to_" prefix. All references updated
8584 <to_shortname, to_longname, to_doc, to_data,
8585 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
8586 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
8587 virtual methods. All references updated throughout.
8588 <can_attach, supports_terminal_ours, can_create_inferior,
8589 get_thread_control_capabilities, attach_no_wait>: New
8591 <insert_breakpoint, remove_breakpoint>: Now
8592 TARGET_DEFAULT_NORETURN methods.
8593 <info_proc>: Now returns bool.
8595 (OPS_MAGIC): Delete.
8596 (current_target): Delete. All references replaced by references
8598 (target_stack): ... this. New.
8599 (target_shortname, target_longname): Adjust.
8600 (target_can_run): Now a function declaration.
8601 (default_child_has_all_memory, default_child_has_memory)
8602 (default_child_has_stack, default_child_has_registers)
8603 (default_child_has_execution): Remove target_ops parameter.
8604 (complete_target_initialization): Delete.
8605 (memory_breakpoint_target): New template class.
8606 (test_target_ops): Refactor as a C++ class with virtual methods.
8607 * make-target-delegates (NAME_PART): Tighten.
8608 (POINTER_PART, CP_SYMBOL): New.
8609 (SIMPLE_RETURN_PART): Reimplement.
8610 (VEC_RETURN_PART): Expect less.
8611 (RETURN_PART, VIRTUAL_PART): New.
8612 (METHOD): Adjust to C++ virtual methods.
8613 (scan_target_h): Remove reference to C99.
8614 (dname): Output "target_ops::" prefix.
8615 (write_function_header): Adjust to output a C++ class method.
8616 (write_declaration): New.
8617 (write_delegator): Adjust to output a C++ class method.
8618 (tdname): Output "dummy_target::" prefix.
8619 (write_tdefault, write_debugmethod): Adjust to output a C++ class
8621 (tdefault_names, debug_names): Delete.
8622 (return_types, tdefaults, styles, argtypes_array): New.
8623 (top level): All methods are delegators.
8625 (top level): Print dummy_target and debug_target classes.
8626 * target-delegates.c: Regenerate.
8627 * target-debug.h (target_debug_print_enum_info_proc_what)
8628 (target_debug_print_thread_control_capabilities)
8629 (target_debug_print_thread_info_p): New.
8630 * target.c (dummy_target): Delete.
8631 (the_dummy_target, the_debug_target): New.
8632 (target_stack): Now extern.
8633 (set_targetdebug): Push/unpush debug target.
8634 (default_child_has_all_memory, default_child_has_memory)
8635 (default_child_has_stack, default_child_has_registers)
8636 (default_child_has_execution): Remove target_ops parameter.
8637 (complete_target_initialization): Delete.
8638 (add_target_with_completer): No longer call
8639 complete_target_initialization.
8640 (target_supports_terminal_ours): Use regular delegation.
8641 (update_current_target): Delete.
8642 (push_target): No longer check magic number. Don't call
8643 update_current_target.
8644 (unpush_target): Don't call update_current_target.
8645 (target_is_pushed): No longer check magic number.
8646 (target_require_runnable): Skip for all stratums over
8648 (target_ops::info_proc): New.
8649 (target_info_proc): Use find_target_at and
8650 find_default_run_target.
8651 (target_supports_disable_randomization): Use regular delegation.
8652 (target_get_osdata): Use find_target_at.
8653 (target_ops::open, target_ops::close, target_ops::can_attach)
8654 (target_ops::attach, target_ops::can_create_inferior)
8655 (target_ops::create_inferior, target_ops::can_run)
8656 (target_can_run): New.
8657 (default_fileio_target): Use regular delegation.
8658 (target_ops::fileio_open, target_ops::fileio_pwrite)
8659 (target_ops::fileio_pread, target_ops::fileio_fstat)
8660 (target_ops::fileio_close, target_ops::fileio_unlink)
8661 (target_ops::fileio_readlink): New.
8662 (target_fileio_open_1, target_fileio_unlink)
8663 (target_fileio_readlink): Always call the target method. Handle
8665 (return_zero, return_zero_has_execution): Delete.
8666 (init_dummy_target): Delete.
8667 (dummy_target::dummy_target, dummy_target::shortname)
8668 (dummy_target::longname, dummy_target::doc)
8669 (debug_target::debug_target, debug_target::shortname)
8670 (debug_target::longname, debug_target::doc): New.
8671 (target_supports_delete_record): Use regular delegation.
8672 (setup_target_debug): Delete.
8673 (maintenance_print_target_stack): Skip debug_stratum.
8674 (initialize_targets): Instantiate the_dummy_target and
8676 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
8678 (target_auxv_search, fprint_target_auxv): Adjust.
8679 (info_auxv_command): Adjust to use target_stack.
8680 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
8681 * exceptions.c (print_flush): Handle a NULL target_stack.
8682 * regcache.c (target_ops_no_register): Refactor as class with
8685 * exec.c (exec_target): New class.
8686 (exec_ops): Now an exec_target.
8687 (exec_open, exec_close_1, exec_get_section_table)
8688 (exec_xfer_partial, exec_files_info, exec_has_memory)
8689 (exec_make_note_section): Refactor as exec_target methods.
8690 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
8692 (exec_target::find_memory_regions): New.
8693 (_initialize_exec): Don't call init_exec_ops.
8694 * gdbcore.h (exec_file_clear): Delete.
8696 * corefile.c (core_target): Delete.
8697 (core_file_command): Adjust.
8698 * corelow.c (core_target): New class.
8699 (the_core_target): New.
8700 (core_close): Remove target_ops parameter.
8701 (core_close_cleanup): Adjust.
8702 (core_target::close): New.
8703 (core_open, core_detach, get_core_registers, core_files_info)
8704 (core_xfer_partial, core_thread_alive, core_read_description)
8705 (core_pid_to_str, core_thread_name, core_has_memory)
8706 (core_has_stack, core_has_registers, core_info_proc): Rework as
8707 core_target methods.
8708 (ignore, core_remove_breakpoint, init_core_ops): Delete.
8709 (_initialize_corelow): Initialize the_core_target.
8710 * gdbcore.h (core_target): Delete.
8711 (the_core_target): New.
8713 * ctf.c: (ctf_target): New class.
8714 (ctf_ops): Now a ctf_target.
8715 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
8716 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
8717 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
8719 (init_ctf_ops): Delete.
8720 (_initialize_ctf): Don't call it.
8721 * tracefile-tfile.c (tfile_target): New class.
8722 (tfile_ops): Now a tfile_target.
8723 (tfile_open, tfile_close, tfile_files_info)
8724 (tfile_get_tracepoint_status, tfile_trace_find)
8725 (tfile_fetch_registers, tfile_xfer_partial)
8726 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
8727 Refactor as tfile_target methods.
8728 (tfile_xfer_partial_features): Remove target_ops parameter.
8729 (init_tfile_ops): Delete.
8730 (_initialize_tracefile_tfile): Don't call it.
8731 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
8732 (tracefile_has_stack, tracefile_has_registers)
8733 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
8734 tracefile_target methods.
8735 (init_tracefile_ops): Delete.
8736 (tracefile_target::tracefile_target): New.
8737 * tracefile.h: Include "target.h".
8738 (tracefile_target): New class.
8739 (init_tracefile_ops): Delete.
8741 * spu-multiarch.c (spu_multiarch_target): New class.
8742 (spu_ops): Now a spu_multiarch_target.
8743 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
8744 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
8745 (spu_search_memory, spu_mourn_inferior): Refactor as
8746 spu_multiarch_target methods.
8747 (init_spu_ops): Delete.
8748 (_initialize_spu_multiarch): Remove references to init_spu_ops,
8749 complete_target_initialization.
8751 * ravenscar-thread.c (ravenscar_thread_target): New class.
8752 (ravenscar_ops): Now a ravenscar_thread_target.
8753 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
8754 (ravenscar_thread_alive, ravenscar_pid_to_str)
8755 (ravenscar_fetch_registers, ravenscar_store_registers)
8756 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
8757 (ravenscar_stopped_by_hw_breakpoint)
8758 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8759 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8760 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8762 (init_ravenscar_thread_ops): Delete.
8763 (_initialize_ravenscar): Remove references to
8764 init_ravenscar_thread_ops and complete_target_initialization.
8766 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8767 (bsd_uthread_target): New class.
8768 (bsd_uthread_ops): Now a bsd_uthread_target.
8769 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8770 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8771 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8772 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8773 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8774 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8775 (bsd_uthread_target): Delete function.
8776 (_initialize_bsd_uthread): Remove reference to
8777 complete_target_initialization.
8779 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8780 (target_bfd): ... this new class.
8781 (target_bfd_xfer_partial, target_bfd_get_section_table)
8782 (target_bfd_close): Refactor as target_bfd methods.
8783 (target_bfd::~target_bfd): New.
8784 (target_bfd_reopen): Adjust.
8785 (target_bfd::close): New.
8787 * record-btrace.c (record_btrace_target): New class.
8788 (record_btrace_ops): Now a record_btrace_target.
8789 (record_btrace_open, record_btrace_stop_recording)
8790 (record_btrace_disconnect, record_btrace_close)
8791 (record_btrace_async, record_btrace_info)
8792 (record_btrace_insn_history, record_btrace_insn_history_range)
8793 (record_btrace_insn_history_from, record_btrace_call_history)
8794 (record_btrace_call_history_range)
8795 (record_btrace_call_history_from, record_btrace_record_method)
8796 (record_btrace_is_replaying, record_btrace_will_replay)
8797 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
8798 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
8799 (record_btrace_store_registers, record_btrace_prepare_to_store)
8800 (record_btrace_to_get_unwinder)
8801 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
8802 (record_btrace_commit_resume, record_btrace_wait)
8803 (record_btrace_stop, record_btrace_can_execute_reverse)
8804 (record_btrace_stopped_by_sw_breakpoint)
8805 (record_btrace_supports_stopped_by_sw_breakpoint)
8806 (record_btrace_stopped_by_hw_breakpoint)
8807 (record_btrace_supports_stopped_by_hw_breakpoint)
8808 (record_btrace_update_thread_list, record_btrace_thread_alive)
8809 (record_btrace_goto_begin, record_btrace_goto_end)
8810 (record_btrace_goto, record_btrace_stop_replaying_all)
8811 (record_btrace_execution_direction)
8812 (record_btrace_prepare_to_generate_core)
8813 (record_btrace_done_generating_core): Refactor as
8814 record_btrace_target methods.
8815 (init_record_btrace_ops): Delete.
8816 (_initialize_record_btrace): Remove reference to
8817 init_record_btrace_ops.
8818 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
8819 the execution_direction global.
8820 (record_full_base_target, record_full_target)
8821 (record_full_core_target): New classes.
8822 (record_full_ops): Now a record_full_target.
8823 (record_full_core_ops): Now a record_full_core_target.
8824 (record_full_target::detach, record_full_target::disconnect)
8825 (record_full_core_target::disconnect)
8826 (record_full_target::mourn_inferior, record_full_target::kill):
8828 (record_full_open, record_full_close, record_full_async): Refactor
8829 as methods of the record_full_base_target class.
8830 (record_full_resume, record_full_commit_resume): Refactor
8831 as methods of the record_full_target class.
8832 (record_full_wait, record_full_stopped_by_watchpoint)
8833 (record_full_stopped_data_address)
8834 (record_full_stopped_by_sw_breakpoint)
8835 (record_full_supports_stopped_by_sw_breakpoint)
8836 (record_full_stopped_by_hw_breakpoint)
8837 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
8838 methods of the record_full_base_target class.
8839 (record_full_store_registers, record_full_xfer_partial)
8840 (record_full_insert_breakpoint, record_full_remove_breakpoint):
8841 Refactor as methods of the record_full_target class.
8842 (record_full_can_execute_reverse, record_full_get_bookmark)
8843 (record_full_goto_bookmark, record_full_execution_direction)
8844 (record_full_record_method, record_full_info, record_full_delete)
8845 (record_full_is_replaying, record_full_will_replay)
8846 (record_full_goto_begin, record_full_goto_end, record_full_goto)
8847 (record_full_stop_replaying): Refactor as methods of the
8848 record_full_base_target class.
8849 (record_full_core_resume, record_full_core_kill)
8850 (record_full_core_fetch_registers)
8851 (record_full_core_prepare_to_store)
8852 (record_full_core_store_registers, record_full_core_xfer_partial)
8853 (record_full_core_insert_breakpoint)
8854 (record_full_core_remove_breakpoint)
8855 (record_full_core_has_execution): Refactor
8856 as methods of the record_full_core_target class.
8857 (record_full_base_target::supports_delete_record): New.
8858 (init_record_full_ops): Delete.
8859 (init_record_full_core_ops): Delete.
8860 (record_full_save): Refactor as method of the
8861 record_full_base_target class.
8862 (_initialize_record_full): Remove references to
8863 init_record_full_ops and init_record_full_core_ops.
8865 * remote.c (remote_target, extended_remote_target): New classes.
8866 (remote_ops): Now a remote_target.
8867 (extended_remote_ops): Now an extended_remote_target.
8868 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
8869 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
8870 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
8871 (remote_pass_signals, remote_set_syscall_catchpoint)
8872 (remote_program_signals, )
8873 (remote_thread_always_alive): Remove target_ops parameter.
8874 (remote_thread_alive, remote_thread_name)
8875 (remote_update_thread_list, remote_threads_extra_info)
8876 (remote_static_tracepoint_marker_at)
8877 (remote_static_tracepoint_markers_by_strid)
8878 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
8879 (remote_open): Refactor as methods of remote_target.
8880 (extended_remote_open, extended_remote_detach)
8881 (extended_remote_attach, extended_remote_post_attach):
8882 (extended_remote_supports_disable_randomization)
8883 (extended_remote_create_inferior): : Refactor as method of
8884 extended_remote_target.
8885 (remote_set_permissions, remote_open_1, remote_detach)
8886 (remote_follow_fork, remote_follow_exec, remote_disconnect)
8887 (remote_resume, remote_commit_resume, remote_stop)
8888 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
8889 (remote_terminal_ours, remote_wait, remote_fetch_registers)
8890 (remote_prepare_to_store, remote_store_registers)
8891 (remote_flash_erase, remote_flash_done, remote_files_info)
8892 (remote_kill, remote_mourn, remote_insert_breakpoint)
8893 (remote_remove_breakpoint, remote_insert_watchpoint)
8894 (remote_watchpoint_addr_within_range)
8895 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
8896 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
8897 (remote_supports_stopped_by_sw_breakpoint)
8898 (remote_stopped_by_hw_breakpoint)
8899 (remote_supports_stopped_by_hw_breakpoint)
8900 (remote_stopped_by_watchpoint, remote_stopped_data_address)
8901 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
8902 (remote_verify_memory): Refactor as methods of remote_target.
8903 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
8905 (remote_xfer_partial, remote_get_memory_xfer_limit)
8906 (remote_search_memory, remote_rcmd, remote_memory_map)
8907 (remote_pid_to_str, remote_get_thread_local_address)
8908 (remote_get_tib_address, remote_read_description): Refactor as
8909 methods of remote_target.
8910 (remote_target::fileio_open, remote_target::fileio_pwrite)
8911 (remote_target::fileio_pread, remote_target::fileio_close): New.
8912 (remote_hostio_readlink, remote_hostio_fstat)
8913 (remote_filesystem_is_local, remote_can_execute_reverse)
8914 (remote_supports_non_stop, remote_supports_disable_randomization)
8915 (remote_supports_multi_process, remote_supports_cond_breakpoints)
8916 (remote_supports_enable_disable_tracepoint)
8917 (remote_supports_string_tracing)
8918 (remote_can_run_breakpoint_commands, remote_trace_init)
8919 (remote_download_tracepoint, remote_can_download_tracepoint)
8920 (remote_download_trace_state_variable, remote_enable_tracepoint)
8921 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
8922 (remote_trace_start, remote_get_trace_status)
8923 (remote_get_tracepoint_status, remote_trace_stop)
8924 (remote_trace_find, remote_get_trace_state_variable_value)
8925 (remote_save_trace_data, remote_get_raw_trace_data)
8926 (remote_set_disconnected_tracing, remote_core_of_thread)
8927 (remote_set_circular_trace_buffer, remote_traceframe_info)
8928 (remote_get_min_fast_tracepoint_insn_len)
8929 (remote_set_trace_buffer_size, remote_set_trace_notes)
8930 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
8931 (remote_disable_btrace, remote_teardown_btrace)
8932 (remote_read_btrace, remote_btrace_conf)
8933 (remote_augmented_libraries_svr4_read, remote_load)
8934 (remote_pid_to_exec_file, remote_can_do_single_step)
8935 (remote_execution_direction, remote_thread_handle_to_thread_info):
8936 Refactor as methods of remote_target.
8937 (init_remote_ops, init_extended_remote_ops): Delete.
8938 (remote_can_async_p, remote_is_async_p, remote_async)
8939 (remote_thread_events, remote_upload_tracepoints)
8940 (remote_upload_trace_state_variables): Refactor as methods of
8942 (_initialize_remote): Remove references to init_remote_ops and
8943 init_extended_remote_ops.
8945 * remote-sim.c (gdbsim_target): New class.
8946 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8947 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8948 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8949 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8950 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8951 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8952 Refactor as methods of gdbsim_target.
8953 (gdbsim_ops): Now a gdbsim_target.
8954 (init_gdbsim_ops): Delete.
8955 (gdbsim_cntrl_c): Adjust.
8956 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8958 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8959 (the_amd64_linux_nat_target): New.
8960 (amd64_linux_fetch_inferior_registers)
8961 (amd64_linux_store_inferior_registers): Refactor as methods of
8962 amd64_linux_nat_target.
8963 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8964 * i386-linux-nat.c: Don't include "linux-nat.h".
8965 (i386_linux_nat_target): New class.
8966 (the_i386_linux_nat_target): New.
8967 (i386_linux_fetch_inferior_registers)
8968 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8969 as methods of i386_linux_nat_target.
8970 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8971 * inf-child.c (inf_child_ops): Delete.
8972 (inf_child_fetch_inferior_registers)
8973 (inf_child_store_inferior_registers): Delete.
8974 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8975 methods of inf_child_target.
8976 (inf_child_target::supports_terminal_ours)
8977 (inf_child_target::terminal_init)
8978 (inf_child_target::terminal_inferior)
8979 (inf_child_target::terminal_ours_for_output)
8980 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8981 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8983 (inf_child_open, inf_child_disconnect, inf_child_close)
8984 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8985 (inf_child_post_startup_inferior, inf_child_can_run)
8986 (inf_child_pid_to_exec_file): Refactor as methods of
8988 (inf_child_follow_fork): Delete.
8989 (inf_child_target::can_create_inferior)
8990 (inf_child_target::can_attach): New.
8991 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8992 (inf_child_target::has_stack, inf_child_target::has_registers)
8993 (inf_child_target::has_execution): New.
8994 (inf_child_fileio_open, inf_child_fileio_pwrite)
8995 (inf_child_fileio_pread, inf_child_fileio_fstat)
8996 (inf_child_fileio_close, inf_child_fileio_unlink)
8997 (inf_child_fileio_readlink, inf_child_use_agent)
8998 (inf_child_can_use_agent): Refactor as methods of
9000 (return_zero, inf_child_target): Delete.
9001 (inf_child_target::inf_child_target): New.
9002 * inf-child.h: Include "target.h".
9003 (inf_child_target): Delete function prototype.
9004 (inf_child_target): New class.
9005 (inf_child_open_target, inf_child_mourn_inferior)
9006 (inf_child_maybe_unpush_target): Delete.
9007 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
9008 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
9009 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
9010 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
9011 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
9012 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
9013 (inf_ptrace_wait, inf_ptrace_xfer_partial)
9014 (inf_ptrace_thread_alive, inf_ptrace_files_info)
9015 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
9016 methods of inf_ptrace_target.
9017 (inf_ptrace_target): Delete function.
9018 * inf-ptrace.h: Include "inf-child.h".
9019 (inf_ptrace_target): Delete function declaration.
9020 (inf_ptrace_target): New class.
9021 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
9022 * linux-nat.c (linux_target): New.
9023 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
9024 (linux_nat_target::~linux_nat_target): New.
9025 (linux_child_post_attach, linux_child_post_startup_inferior)
9026 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
9027 (linux_child_remove_fork_catchpoint)
9028 (linux_child_insert_vfork_catchpoint)
9029 (linux_child_remove_vfork_catchpoint)
9030 (linux_child_insert_exec_catchpoint)
9031 (linux_child_remove_exec_catchpoint)
9032 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
9033 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
9034 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
9035 (linux_nat_stopped_data_address)
9036 (linux_nat_stopped_by_sw_breakpoint)
9037 (linux_nat_supports_stopped_by_sw_breakpoint)
9038 (linux_nat_stopped_by_hw_breakpoint)
9039 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
9040 (linux_nat_kill, linux_nat_mourn_inferior)
9041 (linux_nat_xfer_partial, linux_nat_thread_alive)
9042 (linux_nat_update_thread_list, linux_nat_pid_to_str)
9043 (linux_nat_thread_name, linux_child_pid_to_exec_file)
9044 (linux_child_static_tracepoint_markers_by_strid)
9045 (linux_nat_is_async_p, linux_nat_can_async_p)
9046 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
9047 (linux_nat_supports_multi_process)
9048 (linux_nat_supports_disable_randomization, linux_nat_async)
9049 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
9050 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
9051 (linux_nat_fileio_open, linux_nat_fileio_readlink)
9052 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
9053 methods of linux_nat_target.
9054 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
9055 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
9057 (check_stopped_by_watchpoint): Adjust.
9058 (linux_xfer_partial): Delete.
9059 (linux_target_install_ops, linux_target, linux_nat_add_target):
9061 (linux_nat_target::linux_nat_target): New.
9062 * linux-nat.h: Include "inf-ptrace.h".
9063 (linux_nat_target): New.
9064 (linux_target, linux_target_install_ops, linux_nat_add_target):
9065 Delete function declarations.
9066 (linux_target): Declare global.
9067 * linux-thread-db.c (thread_db_target): New.
9068 (thread_db_target::thread_db_target): New.
9069 (thread_db_ops): Delete.
9070 (the_thread_db_target): New.
9071 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
9072 (thread_db_update_thread_list, thread_db_pid_to_str)
9073 (thread_db_extra_thread_info)
9074 (thread_db_thread_handle_to_thread_info)
9075 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
9076 (thread_db_resume): Refactor as methods of thread_db_target.
9077 (init_thread_db_ops): Delete.
9078 (_initialize_thread_db): Remove reference to init_thread_db_ops.
9079 * x86-linux-nat.c: Don't include "linux-nat.h".
9080 (super_post_startup_inferior): Delete.
9081 (x86_linux_nat_target::~x86_linux_nat_target): New.
9082 (x86_linux_child_post_startup_inferior)
9083 (x86_linux_read_description, x86_linux_enable_btrace)
9084 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
9085 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
9086 methods of x86_linux_nat_target.
9087 (x86_linux_create_target): Delete. Bits folded ...
9088 (x86_linux_add_target): ... here. Now takes a linux_nat_target
9090 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
9091 (x86_linux_nat_target): New class.
9092 (x86_linux_create_target): Delete.
9093 (x86_linux_add_target): Now takes a linux_nat_target pointer.
9094 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
9095 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
9096 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
9097 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
9098 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
9100 (x86_use_watchpoints): Delete.
9101 * x86-nat.h: Include "breakpoint.h" and "target.h".
9102 (x86_use_watchpoints): Delete.
9103 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
9104 (x86_stopped_by_watchpoint, x86_stopped_data_address)
9105 (x86_insert_watchpoint, x86_remove_watchpoint)
9106 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
9107 (x86_stopped_by_hw_breakpoint): New declarations.
9108 (x86_nat_target): New template class.
9110 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
9111 (the_ppc_linux_nat_target): New.
9112 (ppc_linux_fetch_inferior_registers)
9113 (ppc_linux_can_use_hw_breakpoint)
9114 (ppc_linux_region_ok_for_hw_watchpoint)
9115 (ppc_linux_ranged_break_num_registers)
9116 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
9117 (ppc_linux_insert_mask_watchpoint)
9118 (ppc_linux_remove_mask_watchpoint)
9119 (ppc_linux_can_accel_watchpoint_condition)
9120 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
9121 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
9122 (ppc_linux_watchpoint_addr_within_range)
9123 (ppc_linux_masked_watch_num_registers)
9124 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
9125 (ppc_linux_read_description): Refactor as methods of
9126 ppc_linux_nat_target.
9127 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
9129 * procfs.c (procfs_xfer_partial): Delete forward declaration.
9130 (procfs_target): New class.
9131 (the_procfs_target): New.
9132 (procfs_target): Delete function.
9133 (procfs_auxv_parse, procfs_attach, procfs_detach)
9134 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
9135 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
9136 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
9137 (procfs_create_inferior, procfs_update_thread_list)
9138 (procfs_thread_alive, procfs_pid_to_str)
9139 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
9140 (procfs_stopped_data_address, procfs_insert_watchpoint)
9141 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
9142 (proc_find_memory_regions, procfs_info_proc)
9143 (procfs_make_note_section): Refactor as methods of procfs_target.
9144 (_initialize_procfs): Adjust.
9145 * sol-thread.c (sol_thread_target): New class.
9146 (sol_thread_ops): Now a sol_thread_target.
9147 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
9148 (sol_thread_fetch_registers, sol_thread_store_registers)
9149 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
9150 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
9151 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
9152 (init_sol_thread_ops): Delete.
9153 (_initialize_sol_thread): Adjust. Remove references to
9154 init_sol_thread_ops and complete_target_initialization.
9156 * windows-nat.c (windows_nat_target): New class.
9157 (windows_fetch_inferior_registers)
9158 (windows_store_inferior_registers, windows_resume, windows_wait)
9159 (windows_attach, windows_detach, windows_pid_to_exec_file)
9160 (windows_files_info, windows_create_inferior)
9161 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
9162 (windows_close, windows_pid_to_str, windows_xfer_partial)
9163 (windows_get_tib_address, windows_get_ada_task_ptid)
9164 (windows_thread_name, windows_thread_alive): Refactor as
9165 windows_nat_target methods.
9166 (do_initial_windows_stuff): Adjust.
9167 (windows_target): Delete function.
9168 (_initialize_windows_nat): Adjust.
9170 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
9171 (darwin_mourn_inferior, darwin_kill_inferior)
9172 (darwin_create_inferior, darwin_attach, darwin_detach)
9173 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
9174 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
9175 (darwin_supports_multi_process): Refactor as darwin_nat_target
9177 (darwin_resume_to, darwin_files_info): Delete.
9178 (_initialize_darwin_inferior): Rename to ...
9179 (_initialize_darwin_nat): ... this. Adjust to C++ification.
9180 * darwin-nat.h: Include "inf-child.h".
9181 (darwin_nat_target): New class.
9182 (darwin_complete_target): Delete.
9183 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
9184 (darwin_target): New.
9185 (i386_darwin_fetch_inferior_registers)
9186 (i386_darwin_store_inferior_registers): Refactor as methods of
9188 (darwin_complete_target): Delete, with ...
9189 (_initialize_i386_darwin_nat): ... bits factored out here.
9191 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
9192 (the_alpha_linux_nat_target): New.
9193 (alpha_linux_register_u_offset): Refactor as
9194 alpha_linux_nat_target method.
9195 (_initialize_alpha_linux_nat): Adjust.
9196 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
9197 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9198 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
9199 methods of linux_nat_trad_target.
9200 (linux_trad_target): Delete.
9201 * linux-nat-trad.h (linux_trad_target): Delete function.
9202 (linux_nat_trad_target): New class.
9203 * mips-linux-nat.c (mips_linux_nat_target): New class.
9204 (super_fetch_registers, super_store_registers, super_close):
9206 (the_mips_linux_nat_target): New.
9207 (mips64_linux_regsets_fetch_registers)
9208 (mips64_linux_regsets_store_registers)
9209 (mips64_linux_fetch_registers, mips64_linux_store_registers)
9210 (mips_linux_register_u_offset, mips_linux_read_description)
9211 (mips_linux_can_use_hw_breakpoint)
9212 (mips_linux_stopped_by_watchpoint)
9213 (mips_linux_stopped_data_address)
9214 (mips_linux_region_ok_for_hw_watchpoint)
9215 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
9216 (mips_linux_close): Refactor as methods of mips_linux_nat.
9217 (_initialize_mips_linux_nat): Adjust to C++ification.
9219 * aix-thread.c (aix_thread_target): New class.
9220 (aix_thread_ops): Now an aix_thread_target.
9221 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
9222 (aix_thread_fetch_registers, aix_thread_store_registers)
9223 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
9224 (aix_thread_thread_alive, aix_thread_pid_to_str)
9225 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
9226 Refactor as methods of aix_thread_target.
9227 (init_aix_thread_ops): Delete.
9228 (_initialize_aix_thread): Remove references to init_aix_thread_ops
9229 and complete_target_initialization.
9230 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
9231 (rs6000_nat_target): New class.
9232 (the_rs6000_nat_target): New.
9233 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
9234 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
9235 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
9236 (super_create_inferior): Delete.
9237 (_initialize_rs6000_nat): Adjust to C++ification.
9239 * arm-linux-nat.c (arm_linux_nat_target): New class.
9240 (the_arm_linux_nat_target): New.
9241 (arm_linux_fetch_inferior_registers)
9242 (arm_linux_store_inferior_registers, arm_linux_read_description)
9243 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
9244 (arm_linux_remove_hw_breakpoint)
9245 (arm_linux_region_ok_for_hw_watchpoint)
9246 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
9247 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
9248 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
9249 arm_linux_nat_target.
9250 (_initialize_arm_linux_nat): Adjust to C++ification.
9252 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
9253 (the_aarch64_linux_nat_target): New.
9254 (aarch64_linux_fetch_inferior_registers)
9255 (aarch64_linux_store_inferior_registers)
9256 (aarch64_linux_child_post_startup_inferior)
9257 (aarch64_linux_read_description)
9258 (aarch64_linux_can_use_hw_breakpoint)
9259 (aarch64_linux_insert_hw_breakpoint)
9260 (aarch64_linux_remove_hw_breakpoint)
9261 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
9262 (aarch64_linux_region_ok_for_hw_watchpoint)
9263 (aarch64_linux_stopped_data_address)
9264 (aarch64_linux_stopped_by_watchpoint)
9265 (aarch64_linux_watchpoint_addr_within_range)
9266 (aarch64_linux_can_do_single_step): Refactor as methods of
9267 aarch64_linux_nat_target.
9268 (super_post_startup_inferior): Delete.
9269 (_initialize_aarch64_linux_nat): Adjust to C++ification.
9271 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
9272 (the_hppa_linux_nat_target): New.
9273 (hppa_linux_fetch_inferior_registers)
9274 (hppa_linux_store_inferior_registers): Refactor as methods of
9275 hppa_linux_nat_target.
9276 (_initialize_hppa_linux_nat): Adjust to C++ification.
9278 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
9279 (the_ia64_linux_nat_target): New.
9280 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
9281 (ia64_linux_stopped_data_address)
9282 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
9283 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
9284 ia64_linux_nat_target methods.
9285 (super_xfer_partial): Delete.
9286 (_initialize_ia64_linux_nat): Adjust to C++ification.
9288 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
9289 (the_m32r_linux_nat_target): New.
9290 (m32r_linux_fetch_inferior_registers)
9291 (m32r_linux_store_inferior_registers): Refactor as
9292 m32r_linux_nat_target methods.
9293 (_initialize_m32r_linux_nat): Adjust to C++ification.
9295 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
9296 (the_m68k_linux_nat_target): New.
9297 (m68k_linux_fetch_inferior_registers)
9298 (m68k_linux_store_inferior_registers): Refactor as
9299 m68k_linux_nat_target methods.
9300 (_initialize_m68k_linux_nat): Adjust to C++ification.
9302 * s390-linux-nat.c (s390_linux_nat_target): New class.
9303 (the_s390_linux_nat_target): New.
9304 (s390_linux_fetch_inferior_registers)
9305 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
9306 (s390_insert_watchpoint, s390_remove_watchpoint)
9307 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
9308 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
9309 (s390_auxv_parse, s390_read_description): Refactor as methods of
9310 s390_linux_nat_target.
9311 (_initialize_s390_nat): Adjust to C++ification.
9313 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
9314 (the_sparc_linux_nat_target): New.
9315 (_initialize_sparc_linux_nat): Adjust to C++ification.
9316 * sparc-nat.c (sparc_fetch_inferior_registers)
9317 (sparc_store_inferior_registers): Remove target_ops parameter.
9318 * sparc-nat.h (sparc_fetch_inferior_registers)
9319 (sparc_store_inferior_registers): Remove target_ops parameter.
9320 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
9321 (the_sparc64_linux_nat_target): New.
9322 (_initialize_sparc64_linux_nat): Adjust to C++ification.
9324 * spu-linux-nat.c (spu_linux_nat_target): New class.
9325 (the_spu_linux_nat_target): New.
9326 (spu_child_post_startup_inferior, spu_child_post_attach)
9327 (spu_child_wait, spu_fetch_inferior_registers)
9328 (spu_store_inferior_registers, spu_xfer_partial)
9329 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
9331 (_initialize_spu_nat): Adjust to C++ification.
9333 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
9334 (the_tilegx_linux_nat_target): New.
9335 (fetch_inferior_registers, store_inferior_registers):
9336 Refactor as methods.
9337 (_initialize_tile_linux_nat): Adjust to C++ification.
9339 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
9340 (the_xtensa_linux_nat_target): New.
9341 (xtensa_linux_fetch_inferior_registers)
9342 (xtensa_linux_store_inferior_registers): Refactor as
9343 xtensa_linux_nat_target methods.
9344 (_initialize_xtensa_linux_nat): Adjust to C++ification.
9346 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
9347 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
9348 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
9349 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
9350 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
9351 (fbsd_stopped_by_sw_breakpoint)
9352 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
9353 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
9354 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
9355 (fbsd_post_startup_inferior, fbsd_post_attach)
9356 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
9357 (fbsd_set_syscall_catchpoint)
9358 (super_xfer_partial, super_resume, super_wait)
9359 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
9360 (fbsd_handle_debug_trap): Remove target_ops parameter.
9361 (fbsd_nat_add_target): Delete.
9362 * fbsd-nat.h: Include "inf-ptrace.h".
9363 (fbsd_nat_add_target): Delete.
9364 (USE_SIGTRAP_SIGINFO): Define.
9365 (fbsd_nat_target): New class.
9367 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
9368 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
9369 (amd64bsd_target): Delete.
9370 * amd64-bsd-nat.h: New file.
9371 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
9373 (amd64_fbsd_nat_target): New class.
9374 (the_amd64_fbsd_nat_target): New.
9375 (amd64fbsd_read_description): Refactor as method of
9376 amd64_fbsd_nat_target.
9377 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9378 (_initialize_amd64fbsd_nat): Adjust to C++ification.
9379 * amd64-nat.h (amd64bsd_target): Delete function declaration.
9380 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
9381 (i386bsd_store_inferior_registers): Remove target_ops parameter.
9382 (i386bsd_target): Delete.
9383 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
9384 (i386bsd_fetch_inferior_registers)
9385 (i386bsd_store_inferior_registers): Declare.
9386 (i386_bsd_nat_target): New class.
9387 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
9388 (the_i386_fbsd_nat_target): New.
9389 (i386fbsd_resume, i386fbsd_read_description): Refactor as
9390 i386_fbsd_nat_target methods.
9391 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9392 (_initialize_i386fbsd_nat): Adjust to C++ification.
9393 * x86-bsd-nat.c (super_mourn_inferior): Delete.
9394 (x86bsd_mourn_inferior, x86bsd_target): Delete.
9395 (_initialize_x86_bsd_nat): Adjust to C++ification.
9396 * x86-bsd-nat.h: Include "x86-nat.h".
9397 (x86bsd_target): Delete declaration.
9398 (x86bsd_nat_target): New class.
9400 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
9401 (the_aarch64_fbsd_nat_target): New.
9402 (aarch64_fbsd_fetch_inferior_registers)
9403 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
9404 aarch64_fbsd_nat_target.
9405 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
9406 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
9407 (the_alpha_bsd_nat_target): New.
9408 (alphabsd_fetch_inferior_registers)
9409 (alphabsd_store_inferior_registers): Refactor as
9410 alpha_bsd_nat_target methods.
9411 (_initialize_alphabsd_nat): Refactor as methods of
9412 alpha_bsd_nat_target.
9413 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
9414 (the_amd64_nbsd_nat_target): New.
9415 (_initialize_amd64nbsd_nat): Adjust to C++ification.
9416 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
9417 (the_amd64_obsd_nat_target): New.
9418 (_initialize_amd64obsd_nat): Adjust to C++ification.
9419 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
9420 (the_arm_fbsd_nat_target): New.
9421 (arm_fbsd_fetch_inferior_registers)
9422 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
9423 (_initialize_arm_fbsd_nat): Refactor as methods of
9424 arm_fbsd_nat_target.
9425 (_initialize_arm_fbsd_nat): Adjust to C++ification.
9426 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
9427 (the_arm_netbsd_nat_target): New.
9428 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
9429 arm_netbsd_nat_target.
9430 (_initialize_arm_netbsd_nat): Adjust to C++ification.
9431 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
9432 (the_hppa_nbsd_nat_target): New.
9433 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
9434 hppa_nbsd_nat_target methods.
9435 (_initialize_hppanbsd_nat): Adjust to C++ification.
9436 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
9437 (the_hppa_obsd_nat_target): New.
9438 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
9439 methods of hppa_obsd_nat_target.
9440 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
9442 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
9443 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
9445 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
9446 (_initialize_i386obsd_nat): Use add_target.
9447 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
9448 (the_m68k_bsd_nat_target): New.
9449 (m68kbsd_fetch_inferior_registers)
9450 (m68kbsd_store_inferior_registers): Refactor as methods of
9451 m68k_bsd_nat_target.
9452 (_initialize_m68kbsd_nat): Adjust to C++ification.
9453 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
9454 (the_mips_fbsd_nat_target): New.
9455 (mips_fbsd_fetch_inferior_registers)
9456 (mips_fbsd_store_inferior_registers): Refactor as methods of
9457 mips_fbsd_nat_target.
9458 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
9460 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
9461 (the_mips_nbsd_nat_target): New.
9462 (mipsnbsd_fetch_inferior_registers)
9463 (mipsnbsd_store_inferior_registers): Refactor as methods of
9464 mips_nbsd_nat_target.
9465 (_initialize_mipsnbsd_nat): Adjust to C++ification.
9466 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
9467 (the_mips64_obsd_nat_target): New.
9468 (mips64obsd_fetch_inferior_registers)
9469 (mips64obsd_store_inferior_registers): Refactor as methods of
9470 mips64_obsd_nat_target.
9471 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
9473 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
9475 * nbsd-nat.h: Include "inf-ptrace.h".
9476 (nbsd_nat_target): New class.
9477 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
9478 (obsd_wait): Refactor as methods of obsd_nat_target.
9479 (obsd_add_target): Delete.
9480 * obsd-nat.h: Include "inf-ptrace.h".
9481 (obsd_nat_target): New class.
9482 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
9483 (the_ppc_fbsd_nat_target): New.
9484 (ppcfbsd_fetch_inferior_registers)
9485 (ppcfbsd_store_inferior_registers): Refactor as methods of
9486 ppc_fbsd_nat_target.
9487 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
9489 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
9490 (the_ppc_nbsd_nat_target): New.
9491 (ppcnbsd_fetch_inferior_registers)
9492 (ppcnbsd_store_inferior_registers): Refactor as methods of
9493 ppc_nbsd_nat_target.
9494 (_initialize_ppcnbsd_nat): Adjust to C++ification.
9495 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
9496 (the_ppc_obsd_nat_target): New.
9497 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
9498 methods of ppc_obsd_nat_target.
9499 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
9501 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
9502 (the_sh_nbsd_nat_target): New.
9503 (shnbsd_fetch_inferior_registers)
9504 (shnbsd_store_inferior_registers): Refactor as methods of
9506 (_initialize_shnbsd_nat): Adjust to C++ification.
9507 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
9508 (inf_ptrace_xfer_partial): Delete.
9509 (sparc_xfer_partial, sparc_target): Delete.
9510 * sparc-nat.h (sparc_fetch_inferior_registers)
9511 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
9512 (sparc_target): Delete function declaration.
9513 (sparc_target): New template class.
9514 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
9515 (_initialize_sparcnbsd_nat): Adjust to C++ification.
9516 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
9517 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
9519 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
9520 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
9521 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
9522 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
9524 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
9525 (the_vax_bsd_nat_target): New.
9526 (vaxbsd_fetch_inferior_registers)
9527 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
9529 (_initialize_vaxbsd_nat): Adjust to C++ification.
9531 * bsd-kvm.c (bsd_kvm_target): New class.
9532 (bsd_kvm_ops): Now a bsd_kvm_target.
9533 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
9534 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
9535 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
9537 (bsd_kvm_return_one): Delete.
9538 (bsd_kvm_add_target): Adjust to C++ification.
9540 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
9541 (nto_procfs_target_procfs): New classes.
9542 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
9543 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
9544 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
9545 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
9546 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
9547 (procfs_remove_hw_breakpoint, procfs_resume)
9548 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
9549 (procfs_kill_inferior, procfs_store_registers)
9550 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
9551 as methods of nto_procfs_target.
9552 (nto_procfs_ops): Now an nto_procfs_target_procfs.
9553 (nto_native_ops): Delete.
9554 (procfs_open, procfs_native_open): Delete.
9555 (nto_native_ops): Now an nto_procfs_target_native.
9556 (init_procfs_targets): Adjust to C++ification.
9557 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
9558 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
9559 Refactor as methods of nto_procfs_target.
9561 * go32-nat.c (go32_nat_target): New class.
9562 (the_go32_nat_target): New.
9563 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
9564 (go32_store_registers, go32_xfer_partial, go32_files_info)
9565 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
9566 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
9567 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
9568 (go32_pid_to_str): Refactor as methods of go32_nat_target.
9569 (go32_target): Delete.
9570 (_initialize_go32_nat): Adjust to C++ification.
9572 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
9573 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
9574 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
9575 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
9577 (gnu_target): Delete.
9578 * gnu-nat.h (gnu_target): Delete.
9579 (gnu_nat_target): New class.
9580 * i386-gnu-nat.c (gnu_base_target): New.
9581 (i386_gnu_nat_target): New class.
9582 (the_i386_gnu_nat_target): New.
9583 (_initialize_i386gnu_nat): Adjust to C++ification.
9585 2018-05-02 Pedro Alves <palves@redhat.com>
9587 * bfd-target.c (target_bfd_xclose): Rename to ...
9588 (target_bfd_close): ... this.
9589 (target_bfd_reopen): Adjust.
9590 * target.c (target_close): Remove references to to_xclose.
9591 * target.h (target_ops::to_xclose): Delete.
9592 (target_ops::to_close): Update comments.
9594 2018-05-02 Pedro Alves <palves@redhat.com>
9596 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
9598 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
9599 * inf-ptrace.c (inf_ptrace_register_u_offset)
9600 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9601 (inf_ptrace_store_register, inf_ptrace_store_registers)
9602 (inf_ptrace_trad_target): Move to ...
9603 * linux-nat-trad.c: ... this new file.
9604 * linux-nat-trad.h: New file.
9605 * linux-nat.c (linux_target_install_ops): Make extern.
9606 (linux_trad_target): Delete.
9607 * linux-nat.h (linux_trad_target): Delete declaration.
9608 (linux_target_install_ops): Declare.
9609 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
9612 2018-05-02 Pedro Alves <palves@redhat.com>
9614 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9615 procfs_target/add_target here.
9616 * procfs.c (procfs_target): Make static.
9617 (_initialize_procfs): Call add_target here.
9618 * procfs.h (struct target_ops): Remove forward declaration.
9619 (procfs_target): Remove declaration.
9620 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
9622 2018-05-02 Pedro Alves <palves@redhat.com>
9624 * procfs.c (procfs_stopped_by_watchpoint)
9625 (procfs_insert_watchpoint, procfs_remove_watchpoint)
9626 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
9628 (procfs_use_watchpoints): Delete, move contents...
9629 (procfs_target): ... here.
9630 * procfs.h (procfs_use_watchpoints): Delete declaration.
9631 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9632 procfs_use_watchpoints.
9633 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
9634 procfs_use_watchpoints.
9636 2018-05-02 Tom Tromey <tom@tromey.com>
9639 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
9640 and var_zuinteger_unlimited.
9641 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
9642 and PARAM_ZUINTEGER_UNLIMITED.
9643 (set_parameter_value): Handle var_zuinteger and
9644 var_zuinteger_unlimited.
9645 (add_setshow_generic): Likewise.
9646 (parmpy_init): Likewise.
9648 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
9651 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
9652 pointer is not null before dereferencing it.
9654 2018-04-30 Tom Tromey <tom@tromey.com>
9656 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
9659 2018-04-30 Tom Tromey <tom@tromey.com>
9661 * breakpoint.c (mention): Remove use of is_mi_like_p.
9662 (print_mention_ranged_breakpoint): Likewise.
9663 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
9666 2018-04-30 Tom Tromey <tom@tromey.com>
9668 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
9670 2018-04-30 Tom Tromey <tom@tromey.com>
9672 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
9673 (info_spu_event_command): Remove some uses of is_mi_like_p.
9675 2018-04-30 Tom Tromey <tom@tromey.com>
9677 * python/py-framefilter.c (py_print_single_arg)
9678 (enumerate_locals, py_print_args, py_print_frame): Remove some
9679 uses of is_mi_like_p.
9681 2018-04-30 Tom Tromey <tom@tromey.com>
9684 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
9685 * ui-out.h (ui_out::is_mi_like_p): Now const.
9686 (ui_out::do_is_mi_like_p): Now const.
9687 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
9689 2018-04-30 Tom Tromey <tom@tromey.com>
9691 * varobj.c (varobj_set_visualizer): Use new_reference.
9692 * python/python.c (gdbpy_decode_line): Use new_reference.
9693 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
9696 2018-04-30 Tom Tromey <tom@tromey.com>
9698 * varobj.c (install_new_value): Use new_reference.
9699 * value.h (value_incref): Return void. Swap intro comment with
9701 * value.c (set_value_parent): Use new_reference.
9702 (value_incref): Return void. Update intro comment.
9703 (release_value): Use new_reference.
9704 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
9706 2018-04-30 Tom Tromey <tom@tromey.com>
9708 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
9709 * gdb_bfd.h (new_bfd_ref): Remove.
9710 (gdb_bfd_open): Update comment.
9711 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
9712 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
9713 (gdb_bfd_fdopenr): Use new_reference.
9714 * exec.c (exec_file_attach): Use new_reference.
9716 2018-04-30 Tom Tromey <tom@tromey.com>
9718 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
9721 2018-04-30 Tom Tromey <tom@tromey.com>
9723 * jit.c (jit_read_code_entry): Use type_align.
9724 * i386-tdep.c (i386_gdbarch_init): Don't call
9725 set_gdbarch_long_long_align_bit.
9726 * gdbarch.sh: Remove long_long_align_bit.
9727 * gdbarch.c, gdbarch.h: Rebuild.
9728 * arc-tdep.c (arc_type_align): New function.
9729 (arc_gdbarch_init): Use arc_type_align. Don't call
9730 set_gdbarch_long_long_align_bit.
9732 2018-04-30 Tom Tromey <tom@tromey.com>
9734 * rust-lang.c (rust_type_alignment): Remove.
9735 (rust_composite_type): Use type_align.
9737 2018-04-30 Tom Tromey <tom@tromey.com>
9739 * NEWS: Mention Type.align.
9740 * python/py-type.c (typy_get_alignof): New function.
9741 (type_object_getset): Add "alignof".
9743 2018-04-30 Tom Tromey <tom@tromey.com>
9747 * std-operator.def (UNOP_ALIGNOF): New operator.
9748 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
9750 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
9751 * c-lang.c (c_op_print_tab): Add alignof.
9752 * c-exp.y (ALIGNOF): New token.
9753 (exp): Add "ALIGNOF" production.
9754 (ident_tokens): Add _Alignof and alignof.
9756 2018-04-30 Tom Tromey <tom@tromey.com>
9758 * i386-tdep.c (i386_type_align): New function.
9759 (i386_gdbarch_init): Update.
9760 * gdbarch.sh (type_align): New method.
9761 * gdbarch.c, gdbarch.h: Rebuild.
9762 * arch-utils.h (default_type_align): Declare.
9763 * arch-utils.c (default_type_align): New function.
9764 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9765 (struct type) <align_log2>: New field.
9766 <instance_flags>: Now a bitfield.
9767 (TYPE_RAW_ALIGN): New macro.
9768 (type_align, type_raw_align, set_type_align): Declare.
9769 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9771 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9772 (get_alignment, maybe_set_alignment): New functions.
9773 (read_structure_type, read_enumeration_type, read_array_type)
9774 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9775 (read_subrange_type, read_base_type): Set type alignment.
9777 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9779 * dwarf2read.c (read_index_from_section): Use bool.
9781 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9784 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9787 2018-04-29 John Reiser <jreiser@BitWagon.com>
9790 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9791 last step, and do it atomically.
9793 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
9795 * compile/compile-c-types.c (convert_int, convert_float):
9798 2018-04-27 Tom Tromey <tom@tromey.com>
9801 * rust-lang.c (rust_inclusive_range_type_p): New function.
9802 (rust_range): Handle inclusive ranges.
9803 (rust_compute_range): Likewise.
9804 * rust-exp.y (struct rust_op) <inclusive>: New field.
9805 (DOTDOTEQ): New constant.
9806 (range_expr): Add "..=" productions.
9807 (operator_tokens): Add "..=" token.
9808 (ast_range): Add "inclusive" parameter.
9809 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
9811 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
9813 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
9814 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
9816 * expprint.c (print_subexp_standard): Handle new bounds values.
9817 (dump_subexp_body_standard): Likewise.
9819 2018-04-27 Tom Tromey <tom@tromey.com>
9821 * configure: Rebuild.
9822 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
9823 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
9825 (class symbol_needs_eval_context): Likewise.
9826 * dwarf2read.c (mock_mapped_index::symbol_name_count)
9827 (mock_mapped_index::symbol_name_at): Use "override". Remove
9829 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
9831 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
9832 * aarch64-tdep.c (instruction_reader::read): Use "override".
9833 (instruction_reader_test::read): Likewise.
9834 * arm-tdep.c (instruction_reader::read): Use "override".
9835 (instruction_reader_thumb::read): Likewise.
9837 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
9840 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
9841 instead of remote_send.
9842 (remote_send): Remove.
9844 2018-04-26 Pedro Alves <palves@redhat.com>
9846 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
9847 find_function_start_sal instead of find_pc_line.
9849 2018-04-26 Pedro Alves <palves@redhat.com>
9851 * breakpoint.c (set_breakpoint_location_function): Handle
9853 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
9854 * elfread.c (elf_symtab_read): Give data symbols with
9855 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
9856 (elf_rel_plt_read): Update comment.
9857 * linespec.c (convert_linespec_to_sals): Handle
9859 (minsym_found): Handle mst_data_gnu_ifunc.
9860 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
9861 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
9862 * parse.c (find_minsym_type_and_address): Handle
9864 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
9865 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
9866 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
9868 <mst_data_gnu_ifunc>: New enumerator.
9870 2018-04-26 Pedro Alves <palves@redhat.com>
9872 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
9873 (lookup_minimal_symbol_by_pc_section): ... this. Replace
9874 'want_trampoline' parameter by a lookup_msym_prefer parameter.
9876 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
9877 (lookup_minimal_symbol_by_pc): Adjust.
9878 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
9879 (lookup_solib_trampoline_symbol_by_pc): Adjust.
9880 * minsyms.h (lookup_msym_prefer): New enum.
9881 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9882 parameter by a lookup_msym_prefer parameter.
9884 2018-04-26 Pedro Alves <palves@redhat.com>
9886 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
9887 ends in "@plt" instead of looking at the symbol's section.
9889 2018-04-26 Pedro Alves <palves@redhat.com>
9891 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
9893 (find_pc_partial_function_gnu_ifunc): Rename to ...
9894 (find_pc_partial_function): ... this, and remove references to
9896 (find_pc_partial_function): Delete old implementation.
9897 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
9899 2018-04-26 Pedro Alves <palves@redhat.com>
9901 * linespec.c (struct bound_minimal_symbol_search_key): New.
9902 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
9903 skip first line if we found a GNU ifunc minimal symbol by name.
9904 (compare_msymbols): Change parameters to work with a destructured
9906 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
9909 2018-04-26 Pedro Alves <palves@redhat.com>
9911 * breakpoint.c (set_breakpoint_location_function): Don't resolve
9912 ifunc targets here. Instead, if we have an ifunc minsym, use its
9914 (add_location_to_breakpoint): Store the minsym and the objfile in
9915 the breakpoint location.
9916 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
9917 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
9918 Record the minsym in the sal.
9919 * symtab.h (symtab_and_line) <msymbol>: New field.
9921 2018-04-26 Pedro Alves <palves@redhat.com>
9923 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
9924 unless we actually resolved the ifunc.
9926 2018-04-26 Pedro Alves <palves@redhat.com>
9928 * c-exp.y (variable production): Prefer ifunc minsyms over
9929 regular function symbols.
9930 * symtab.c (find_gnu_ifunc): New function.
9931 * minsyms.h (lookup_msym_prefer): New enum.
9932 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9933 parameter by a lookup_msym_prefer parameter.
9934 * symtab.h (find_gnu_ifunc): New declaration.
9936 2018-04-26 Pedro Alves <palves@redhat.com>
9938 * blockframe.c (find_gnu_ifunc_target_type): New function.
9939 (find_function_type): New.
9940 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9941 return a value with a memory address.
9942 (eval_call): For calls to GNU ifunc functions, try to find the
9943 type of the target function from the type that the resolver
9945 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9947 * infcall.c (find_function_return_type): Delete.
9948 (find_function_addr): Add 'function_type' parameter. For calls to
9949 GNU ifunc functions, try to find the type of the target function
9950 from the type that the resolver returns, and return it via
9952 (call_function_by_hand_dummy): Adjust to use the function type
9953 returned by find_function_addr.
9954 (find_function_addr): Add 'function_type' parameter and move
9956 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9959 2018-04-26 Pedro Alves <palves@redhat.com>
9961 * c-exp.y (variable production): Skip finding an alias for ifunc
9964 2018-04-26 Pedro Alves <palves@redhat.com>
9966 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9968 2018-04-25 Pedro Alves <palves@redhat.com>
9970 * infcmd.c (kill_command): Print the pid as string, not the whole
9971 thread's ptid. Add comment. s/has been killed/killed/ in output
9973 * remote.c (remote_detach_1): Print the pid as string, not the
9974 whole thread's ptid.
9976 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9977 Sergio Durigan Junior <sergiodj@redhat.com>
9978 Pedro Alves <palves@redhat.com>
9980 * infcmd.c (kill_command): Print message when inferior has
9982 * inferior.c (print_inferior_events): Remove 'static'. Set as
9984 (add_inferior): Improve message printed when
9985 'print_inferior_events' is on.
9986 (exit_inferior): Remove message printed when
9987 'print_inferior_events' is on.
9988 (detach_inferior): Improve message printed when
9989 'print_inferior_events' is on.
9990 (initialize_inferiors): Use 'add_inferior_silent' to set
9991 'current_inferior_'.
9992 * inferior.h (print_inferior_events): Declare here as
9994 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9995 '[Detaching...]' messages when 'print_inferior_events' is on.
9996 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9997 as prefix/suffix for messages. Remove periods. Fix erroneous
9998 'Detaching after fork from child...', replace it by '... from
10000 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
10001 prefix/suffix when printing 'Detaching...' messages. Print
10002 them when 'print_inferior_events' is on.
10003 * remote.c (remote_detach_1): Print message when detaching
10004 from inferior and '!is_fork_parent'.
10006 2018-04-24 Tom Tromey <tom@tromey.com>
10008 * cli-out.h: Reindent.
10010 2018-04-24 Tom Tromey <tom@tromey.com>
10012 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
10013 (cli_ui_out::do_field_string): Use fputs_filtered.
10014 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
10016 2018-04-23 Tom Tromey <tom@tromey.com>
10018 * guile/scm-frame.c (gdbscm_frame_read_var): Use
10019 gdb::unique_xmalloc_ptr.
10021 2018-04-23 Tom Tromey <tom@tromey.com>
10023 * configure: Rebuild.
10025 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
10028 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
10029 prepare_for_testing. Set normal_bp to r_debug_state if target
10032 2018-04-21 Pedro Alves <palves@redhat.com>
10033 Rajendra SY <rajendra.sy@gmail.com>
10035 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
10036 * remote.c (extended_remote_attach): In all-stop mode, mark the
10037 thread as executing.
10039 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10041 * thread.c (thread_apply_all_command): Fix comment.
10042 (thread_command): Fix comment.
10044 2018-04-10 Alan Hayward <alan.hayward@arm.com>
10046 * common/tdesc.h (tdesc_create_feature): Remove xml filename
10048 * features/aarch64-core.c (create_feature_aarch64_core):
10050 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
10052 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
10054 * features/i386/32bit-avx512.c
10055 (create_feature_i386_32bit_avx512): Likewise.
10056 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
10058 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
10060 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
10062 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
10064 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
10066 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
10068 * features/i386/64bit-avx512.c
10069 (create_feature_i386_64bit_avx512): Likewise.
10070 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
10072 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
10074 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
10076 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
10078 * features/i386/64bit-segments.c
10079 (create_feature_i386_64bit_segments): Likewise.
10080 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
10082 * features/i386/x32-core.c
10083 (create_feature_i386_x32_core): Likewise.
10084 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
10085 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
10086 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
10087 * target-descriptions.c: In generated code, don't pass xml
10090 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10092 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
10093 (print_xml_feature::visit_post): Likewise.
10094 (print_xml_feature::visit): Likewise.
10095 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
10096 (print_xml_feature): Add new class.
10097 * regformats/regdat.sh: Null xmltarget on feature targets.
10098 * target-descriptions.c (struct target_desc): Add xmltarget.
10099 (maintenance_check_tdesc_xml_convert): Add unittest function.
10100 (tdesc_get_features_xml): Add function to get xml.
10101 (maintenance_check_xml_descriptions): Test xml generation.
10102 * xml-tdesc.c (string_read_description_xml): Add function.
10103 * xml-tdesc.h (string_read_description_xml): Add declaration.
10105 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10107 * features/Makefile: Add feature marker to targets with new style
10108 target descriptions.
10109 * regformats/aarch64.dat: Regenerate.
10110 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
10111 * regformats/i386/amd64-avx-linux.dat: Likewise.
10112 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
10113 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
10114 * regformats/i386/amd64-linux.dat: Likewise.
10115 * regformats/i386/amd64-mpx-linux.dat: Likewise.
10116 * regformats/i386/amd64.dat: Likewise.
10117 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
10118 * regformats/i386/i386-avx-linux.dat: Likewise.
10119 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
10120 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
10121 * regformats/i386/i386-linux.dat: Likewise.
10122 * regformats/i386/i386-mmx-linux.dat: Likewise.
10123 * regformats/i386/i386-mpx-linux.dat: Likewise.
10124 * regformats/i386/i386.dat: Likewise.
10125 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
10126 * regformats/i386/x32-avx-linux.dat: Likewise.
10127 * regformats/i386/x32-linux.dat: Likewise.
10128 * regformats/tic6x-c62x-linux.dat: Likewise.
10129 * regformats/tic6x-c64x-linux.dat: Likewise.
10130 * regformats/tic6x-c64xp-linux.dat: Likewise.
10131 * regformats/regdat.sh: Parse feature marker.
10133 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10135 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
10136 (tdesc_osabi_name): Likewise.
10137 * target-descriptions.c (tdesc_architecture_name): Add new
10139 (tdesc_osabi_name): Likewise.
10141 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10143 * common/tdesc.c (tdesc_predefined_type): Move to here.
10144 (tdesc_named_type): Likewise.
10145 (tdesc_create_vector): Likewise.
10146 (tdesc_create_struct): Likewise.
10147 (tdesc_set_struct_size): Likewise.
10148 (tdesc_create_union): Likewise.
10149 (tdesc_create_flags): Likewise.
10150 (tdesc_create_enum): Likewise.
10151 (tdesc_add_field): Likewise.
10152 (tdesc_add_typed_bitfield): Likewise.
10153 (tdesc_add_bitfield): Likewise.
10154 (tdesc_add_flag): Likewise.
10155 (tdesc_add_enum_value): Likewise.
10156 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
10157 (struct tdesc_type_vector): Likewise.
10158 (struct tdesc_type_field): Likewise.
10159 (struct tdesc_type_with_fields): Likewise.
10160 (tdesc_create_enum): Add declaration.
10161 (tdesc_add_typed_bitfield): Likewise.
10162 (tdesc_add_enum_value): Likewise.
10163 * target-descriptions.c (tdesc_type_field): Move from here.
10164 (tdesc_type_builtin): Likewise.
10165 (tdesc_type_vector): Likewise.
10166 (tdesc_type_with_fields): Likewise.
10167 (tdesc_predefined_types): Likewise.
10168 (tdesc_named_type): Likewise.
10169 (tdesc_create_vector): Likewise.
10170 (tdesc_create_struct): Likewise.
10171 (tdesc_set_struct_size): Likewise.
10172 (tdesc_create_union): Likewise.
10173 (tdesc_create_flags): Likewise.
10174 (tdesc_create_enum): Likewise.
10175 (tdesc_add_field): Likewise.
10176 (tdesc_add_typed_bitfield): Likewise.
10177 (tdesc_add_bitfield): Likewise.
10178 (tdesc_add_flag): Likewise.
10179 (tdesc_add_enum_value): Likewise.
10180 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
10181 (tdesc_add_typed_bitfield): Likewise.
10182 (tdesc_add_enum_value): Likewise.
10184 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10186 * common/tdesc.c (tdesc_feature::accept): Move to here.
10187 (tdesc_feature::operator==): Likewise.
10188 (tdesc_create_reg): Likewise.
10189 * common/tdesc.h (tdesc_type_kind): Likewise.
10190 (struct tdesc_type): Likewise.
10191 (struct tdesc_feature): Likewise.
10192 * regformats/regdat.sh: Create a feature.
10193 * target-descriptions.c (tdesc_type_kind): Move from here.
10194 (tdesc_type): Likewise.
10195 (tdesc_type_up): Likewise.
10196 (tdesc_feature): Likewise.
10197 (tdesc_create_reg): Likewise.
10199 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10201 * Makefile.in: Add arch/tdesc.c
10202 * common/tdesc.c: New file.
10203 * common/tdesc.h (tdesc_element_visitor): Move to here.
10204 (tdesc_element): Likewise.
10205 (tdesc_reg): Likewise.
10206 (tdesc_reg_up): Likewise.
10207 * regformats/regdef.h (reg): Add offset to constructors.
10208 * target-descriptions.c (tdesc_element_visitor): Move from here.
10209 (tdesc_element): Likewise.
10210 (tdesc_reg): Likewise.
10211 (tdesc_reg_up): Likewise.
10213 2018-04-17 Tom Tromey <tom@tromey.com>
10215 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
10216 discriminant field.
10218 2018-04-17 Tom Tromey <tom@tromey.com>
10220 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
10222 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
10224 * symtab.c (print_symbol_info): Skip printing filename and line
10225 number when `last' is NULL.
10226 (symtab_symbol_info): Use empty string instead of NULL for first
10227 invocation of print_symbol_info.
10228 (rbreak_command): Pass NULL to `last' parameter of
10231 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
10233 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
10234 instead of nullptr.
10236 2018-04-16 Pedro Alves <palves@redhat.com>
10238 * MAINTAINERS (sh): Remove.
10239 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
10240 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
10241 (ALLDEPFILES): Remove sh64-tdep.c.
10242 * NEWS: Mentions that support for SH-5/SH64 is removed.
10243 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
10244 (sh*-*-openbsd*): Ditto.
10245 (sh64-*-elf*): Remove.
10247 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
10248 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
10249 * sh-tdep.c: No longer include "sh64-tdep.h".
10250 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
10251 * sh64-tdep.c, sh64-tdep.h: Remove files.
10253 2018-04-16 Pedro Alves <palves@redhat.com>
10255 * MAINTAINERS: Remove m88k.
10256 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
10257 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
10258 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
10259 * NEWS: Mention that support for m88k was removed.
10260 * configure.host (m88*-*-*): Remove support.
10261 * configure.nat (m88k-*-*): Remove support.
10262 * configure.tgt (m88*-*-openbsd*): Remove.
10263 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
10265 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
10267 * configure.tgt (x86_tobjs): New variable.
10268 (amd64_tobjs, i386_tobjs): Use it.
10270 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10272 * symtab.c (print_symbol_info): Precede the symbol definition by
10273 the line number when available.
10274 * NEWS: Advertise this enhancement.
10276 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10278 * NEWS (New options): announce set/show record btrace cpu.
10279 * btrace.c: Include record-btrace.h.
10280 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
10281 the vendor is unknown.
10282 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
10283 Maybe overwrite the btrace configuration's cpu.
10284 (btrace_compute_ftrace): Add cpu parameter. Update callers.
10285 (btrace_fetch): Add cpu parameter. Update callers.
10286 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
10287 Maybe overwrite the btrace configuration's cpu. Skip enabling
10288 errata workarounds if the vendor is unknown.
10289 * python/py-record-btrace.c: Include record-btrace.h.
10290 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
10291 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
10292 * record-btrace.c (record_btrace_cpu_state_kind): New.
10293 (record_btrace_cpu): New.
10294 (set_record_btrace_cpu_cmdlist): New.
10295 (record_btrace_get_cpu): New.
10296 (require_btrace_thread, record_btrace_info)
10297 (record_btrace_resume_thread): Call record_btrace_get_cpu.
10298 (cmd_set_record_btrace_cpu_none): New.
10299 (cmd_set_record_btrace_cpu_auto): New.
10300 (cmd_set_record_btrace_cpu): New.
10301 (cmd_show_record_btrace_cpu): New.
10302 (_initialize_record_btrace): Initialize set/show record btrace cpu
10304 * record-btrace.h (record_btrace_get_cpu): New.
10306 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10308 * record.c (set_record_command): Fix typo in message.
10310 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10312 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
10314 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10316 * infrun.c (process_event_stop_test): Call
10317 gdbarch_in_indirect_branch_thunk.
10318 * gdbarch.sh (in_indirect_branch_thunk): New.
10319 * gdbarch.c: Regenerated.
10320 * gdbarch.h: Regenerated.
10323 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
10324 (HFILES_NO_SRCDIR): Add x86-tdep.h.
10325 (ALLDEPFILES): Add x86-tdep.c.
10326 * arch-utils.h (default_in_indirect_branch_thunk): New.
10327 * arch-utils.c (default_in_indirect_branch_thunk): New.
10328 * i386-tdep: Include x86-tdep.h.
10329 (i386_in_indirect_branch_thunk): New.
10330 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
10332 * amd64-tdep: Include x86-tdep.h.
10333 (amd64_in_indirect_branch_thunk): New.
10334 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
10336 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10339 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
10340 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
10341 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
10344 2018-04-12 Tom Tromey <tom@tromey.com>
10346 * rust-lang.c (rust_print_struct_def): Remove univariant code.
10347 (rust_evaluate_subexp): Likewise.
10349 2018-04-12 Pedro Alves <palves@redhat.com>
10351 * procfs.c (procfs_detach): Make forward declaration's prototype
10352 match definition's protototype.
10353 (proc_get_LDT_entry): Remove stale do_cleanups call.
10355 2018-04-12 Pedro Alves <palves@redhat.com>
10357 * target.h (target_ops::to_has_exited): Delete.
10358 (target_has_exited): Delete.
10359 * target-delegates.c: Regenerate.
10361 2018-04-11 Pedro Alves <palves@redhat.com>
10363 * target.c (fileio_fh_t::t): Add comment.
10364 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10365 (target_fileio_close): Handle a NULL target.
10366 (invalidate_fileio_fh): New.
10367 (target_close): Call it.
10368 * remote.c (remote_hostio_send_command): No longer check whether
10369 remote_desc is open.
10371 2018-04-11 Pedro Alves <palves@redhat.com>
10373 * target.c (fileio_fh_t): Make it a named struct instead of a
10375 (fileio_fh_t::is_closed): New method.
10376 (DEF_VEC_O (fileio_fh_t)): Remove.
10377 (fileio_fhandles): Now a std::vector.
10378 (is_closed_fileio_fh): Delete.
10379 (acquire_fileio_fd): Adjust. Rename parameters.
10380 (release_fileio_fd): Adjust.
10381 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
10382 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10383 (target_fileio_close): Adjust.
10385 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
10387 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
10390 2018-04-10 Pedro Alves <palves@redhat.com>
10392 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
10393 (scoped_finish_thread_state): New class.
10394 * infcmd.c (run_command_1): Use it instead of finish_thread_state
10396 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
10397 (fetch_inferior_event, normal_stop): Likewise.
10398 * thread.c (finish_thread_state_cleanup): Delete.
10400 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10401 Pedro Alves <palves@redhat.com>
10403 * value.c: Include "selftest.h" and "common/array-view.h".
10404 (struct range) <operator ==>: New.
10405 (test_ranges_contain): New.
10406 (check_ranges_vector): New.
10407 (test_insert_into_bit_range_vector): New.
10408 (_initialize_values): Register selftests.
10409 * common/array-view.h (operator==, operator!=): New.
10411 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10413 * common/gdb_vecs.h (unordered_remove): Add overload that takes
10415 * inline-frame.c: Include <algorithm>.
10416 (struct inline_state): Add constructor.
10417 (inline_state_s): Remove.
10418 (DEF_VEC_O(inline_state_s)): Remove.
10419 (inline_states): Change type to std::vector.
10420 (find_inline_frame_state): Adjust to std::vector.
10421 (allocate_inline_frame_state): Remove.
10422 (clear_inline_frame_state): Adjust to std::vector.
10423 (skip_inline_frames): Adjust to std::vector.
10425 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10427 * tracepoint.h (struct trace_state_variable): Add constructor.
10428 <name>: Change type to std::string.
10429 * tracepoint.c (tsv_s): Remove.
10430 (DEF_VEC_O(tsv_s)): Remove.
10431 (tvariables): Change to std::vector.
10432 (create_trace_state_variable): Adjust to std::vector.
10433 (find_trace_state_variable): Likewise.
10434 (find_trace_state_variable_by_number): Likewise.
10435 (delete_trace_state_variable): Likewise.
10436 (trace_variable_command): Adjust to std::string.
10437 (delete_trace_variable_command): Likewise.
10438 (tvariables_info_1): Adjust to std::vector.
10439 (save_trace_state_variables): Likewise.
10440 (start_tracing): Likewise.
10441 (merge_uploaded_trace_state_variables): Adjust to std::vector
10443 * target.h (struct target_ops)
10444 <to_download_trace_state_variable>: Pass reference to
10445 trace_state_variable.
10446 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
10447 * target-delegates.c: Re-generate.
10448 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
10449 (mi_tsv_deleted): Likewise.
10450 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
10451 * remote.c (remote_download_trace_state_variable): Change
10452 pointer to reference and adjust.
10453 * make-target-delegates (parse_argtypes): Handle references.
10454 (write_function_header): Likewise.
10455 (munge_type): Likewise.
10457 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10459 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10460 string_view-selftests.c.
10461 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
10463 * unittests/basic_string_view/cons/char/1.cc: Likewise.
10464 * unittests/basic_string_view/cons/char/2.cc: Likewise.
10465 * unittests/basic_string_view/cons/char/3.cc: Likewise.
10466 * unittests/basic_string_view/element_access/char/1.cc:
10468 * unittests/basic_string_view/element_access/char/empty.cc:
10470 * unittests/basic_string_view/element_access/char/front_back.cc:
10472 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
10473 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
10475 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
10477 * unittests/basic_string_view/modifiers/swap/char/1.cc:
10479 * unittests/basic_string_view/operations/compare/char/1.cc:
10481 * unittests/basic_string_view/operations/compare/char/13650.cc:
10483 * unittests/basic_string_view/operations/copy/char/1.cc:
10485 * unittests/basic_string_view/operations/data/char/1.cc:
10487 * unittests/basic_string_view/operations/find/char/1.cc:
10489 * unittests/basic_string_view/operations/find/char/2.cc:
10491 * unittests/basic_string_view/operations/find/char/3.cc:
10493 * unittests/basic_string_view/operations/find/char/4.cc:
10495 * unittests/basic_string_view/operations/rfind/char/1.cc:
10497 * unittests/basic_string_view/operations/rfind/char/2.cc:
10499 * unittests/basic_string_view/operations/rfind/char/3.cc:
10501 * unittests/basic_string_view/operations/substr/char/1.cc:
10503 * unittests/basic_string_view/operators/char/2.cc: Likewise.
10504 * unittests/string_view-selftests.c: New file.
10506 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10508 * unittests/basic_string_view/capacity/1.cc: New file.
10509 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
10510 * unittests/basic_string_view/cons/char/1.cc: New file.
10511 * unittests/basic_string_view/cons/char/2.cc: New file.
10512 * unittests/basic_string_view/cons/char/3.cc: New file.
10513 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
10514 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
10515 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
10516 * unittests/basic_string_view/element_access/char/1.cc: New file.
10517 * unittests/basic_string_view/element_access/char/2.cc: New file.
10518 * unittests/basic_string_view/element_access/char/empty.cc: New file.
10519 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
10520 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
10521 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
10522 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
10523 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
10524 * unittests/basic_string_view/include.cc: New file.
10525 * unittests/basic_string_view/inserters/char/1.cc: New file.
10526 * unittests/basic_string_view/inserters/char/2.cc: New file.
10527 * unittests/basic_string_view/inserters/char/3.cc: New file.
10528 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
10529 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
10530 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
10531 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
10532 * unittests/basic_string_view/literals/types.cc: New file.
10533 * unittests/basic_string_view/literals/values.cc: New file.
10534 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
10535 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
10536 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
10537 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
10538 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
10539 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
10540 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
10541 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
10542 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
10543 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
10544 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
10545 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
10546 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
10547 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
10548 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
10549 * unittests/basic_string_view/operations/data/char/1.cc: New file.
10550 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
10551 * unittests/basic_string_view/operations/find/char/1.cc: New file.
10552 * unittests/basic_string_view/operations/find/char/2.cc: New file.
10553 * unittests/basic_string_view/operations/find/char/3.cc: New file.
10554 * unittests/basic_string_view/operations/find/char/4.cc: New file.
10555 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
10556 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
10557 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
10558 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
10559 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
10560 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
10561 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
10562 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
10563 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
10564 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
10565 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
10566 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
10567 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
10568 * unittests/basic_string_view/operators/char/2.cc: New file.
10569 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
10570 * unittests/basic_string_view/range_access/char/1.cc: New file.
10571 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
10572 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
10573 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
10574 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
10575 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
10576 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
10577 * unittests/basic_string_view/requirements/typedefs.cc: New file.
10578 * unittests/basic_string_view/typedefs.cc: New file.
10579 * unittests/basic_string_view/types/1.cc: New file.
10581 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10583 * common/gdb_string_view.h: Remove libstdc++ implementation
10584 details, adjust to gdb reality.
10585 * common/gdb_string_view.tcc: Likewise.
10586 * cli/cli-script.c (struct string_view): Remove.
10587 (user_args) <m_args>: Change element type to gdb::string_view.
10588 (user_args::insert_args): Adjust.
10590 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10592 * common/gdb_string_view.h: New file.
10593 * common/gdb_string_view.tcc: New file.
10595 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10597 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
10598 * configure: Re-generate.
10600 2018-04-09 Pedro Alves <palves@redhat.com>
10602 * gdbarch.sh: Include "observable.h" instead of "observer.h".
10603 (set_target_gdbarch): Call
10604 gdb::observers::architecture_changed.notify instead of
10605 observer_notify_architecture_changed.
10607 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10609 * tracepoint.c (struct current_traceframe_cleanup): Remove.
10610 (do_restore_current_traceframe_cleanup): Remove.
10611 (restore_current_traceframe_cleanup_dtor): Remove.
10612 (make_cleanup_restore_current_traceframe): Remove.
10613 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
10615 * tracepoint.h (struct scoped_restore_current_traceframe): New.
10616 * infrun.c (fetch_inferior_event): Use
10617 scoped_restore_current_traceframe.
10619 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10621 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
10623 <n_allocated_type_units>: Remove.
10624 <all_type_units>: Change to std::vector.
10625 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10626 to std::vector change.
10627 (dwarf2_per_objfile::get_cutu): Likewise.
10628 (dwarf2_per_objfile::get_tu): Likewise.
10629 (create_signatured_type_table_from_index): Likewise.
10630 (create_signatured_type_table_from_debug_names): Likewise.
10631 (dw2_symtab_iter_next): Likewise.
10632 (dw2_print_stats): Likewise.
10633 (dw2_expand_all_symtabs): Likewise.
10634 (dw2_expand_marked_cus): Likewise.
10635 (dw2_debug_names_iterator::next): Likewise.
10636 (dwarf2_initialize_objfile): Likewise.
10637 (add_signatured_type_cu_to_table): Likewise.
10638 (create_all_type_units): Likewise.
10639 (add_type_unit): Likewise.
10640 (struct tu_abbrev_offset): Add constructor.
10641 (build_type_psymtabs_1): Adjust to std::vector change.
10642 (print_tu_stats): Likewise.
10643 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10644 (write_debug_names): Likewise.
10646 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10648 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
10649 Make an std::vector.
10650 <n_comp_units>: Remove.
10651 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10652 to std::vector change.
10653 (dwarf2_per_objfile::get_cutu): Likewise.
10654 (dwarf2_per_objfile::get_cu): Likewise.
10655 (create_cus_from_index): Likewise.
10656 (create_addrmap_from_index): Likewise.
10657 (create_addrmap_from_aranges): Likewise.
10658 (dwarf2_read_index): Likewise.
10659 (dw2_find_last_source_symtab): Likewise.
10660 (dw2_map_symtabs_matching_filename): Likewise.
10661 (dw2_symtab_iter_next): Likewise.
10662 (dw2_print_stats): Likewise.
10663 (dw2_expand_all_symtabs): Likewise.
10664 (dw2_expand_symtabs_with_fullname): Likewise.
10665 (dw2_expand_marked_cus): Likewise.
10666 (dw2_map_symbol_filenames): Likewise.
10667 (create_cus_from_debug_names): Likewise.
10668 (dwarf2_read_debug_names): Likewise.
10669 (dw2_debug_names_iterator::next): Likewise.
10670 (dwarf2_initialize_objfile): Likewise.
10671 (set_partial_user): Likewise.
10672 (dwarf2_build_psymtabs_hard): Likewise.
10673 (read_comp_units_from_section): Remove arguments, adjust to
10674 std::vector change.
10675 (create_all_comp_units): Adjust to std::vector and
10676 read_comp_units_from_section changes.
10677 (dwarf2_find_containing_comp_unit): Adjust to std::vector
10679 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10680 (psyms_seen_size): Likewise.
10681 (write_gdbindex): Likewise.
10682 (write_debug_names): Likewise.
10684 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10686 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
10687 with dwarf2_per_objfile.
10688 (create_cus_from_index): Likewise.
10689 (create_signatured_type_table_from_index): Likewise.
10690 (dwarf2_read_index): Likewise.
10691 (dwarf2_initialize_objfile): Likewise.
10692 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
10693 per_cu rather than get_dwarf2_per_objfile.
10695 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10697 * dwarf2read.h (struct signatured_type): Forward declare.
10698 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
10700 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
10701 (dw2_get_cutu): ...this.
10702 (dwarf2_per_objfile::get_cu): Rename from...
10703 (dw2_get_cu): ...this.
10704 (dwarf2_per_objfile::get_tu): New.
10705 (create_addrmap_from_index): Adjust.
10706 (create_addrmap_from_aranges): Adjust.
10707 (dw2_find_last_source_symtab): Adjust.
10708 (dw2_map_symtabs_matching_filename): Adjust.
10709 (dw2_symtab_iter_next): Adjust.
10710 (dw2_print_stats): Adjust.
10711 (dw2_expand_all_symtabs): Adjust.
10712 (dw2_expand_symtabs_with_fullname): Adjust.
10713 (dw2_expand_marked_cus): Adjust.
10714 (dw_expand_symtabs_matching_file_matcher): Adjust.
10715 (dw2_map_symbol_filenames): Adjust.
10716 (dw2_debug_names_iterator::next): Adjust.
10717 (dwarf2_initialize_objfile): Adjust.
10718 (set_partial_user): Adjust.
10719 (dwarf2_build_psymtabs_hard): Adjust.
10721 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10723 * dwarf2read.c (create_signatured_type_table_from_debug_names):
10724 Remove unused variables.
10725 (dw2_map_symtabs_matching_filename): Likewise.
10726 (dwarf2_record_block_ranges): Likewise.
10727 (dwarf2_read_addr_index): Likewise.
10728 (follow_die_offset): Likewise.
10730 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10732 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
10733 to symbol_file_add_main.
10735 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10738 * mi/mi-console.c (do_fputc_async_safe): New.
10739 (mi_console_file::write_async_safe): New.
10740 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
10741 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
10743 * ui-file.c (ui_file::putstrn): Adjust call to
10744 fputstrn_unfiltered.
10745 * utils.c (printchar): Replace do_fputs and do_fprintf
10746 parameters by do_fputc.
10747 (fputstr_filtered): Adjust call to printchar.
10748 (fputstr_unfiltered): Likewise.
10749 (fputstrn_filtered): Likewise.
10750 (fputstrn_unfiltered): Add do_fputc parameter, pass to
10752 * utils.h (do_fputc_ftype): New typedef.
10753 (fputstrn_unfiltered): Add do_fputc parameter.
10755 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10757 * regformats/i386/i386-avx.dat: Remove.
10759 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10762 * amd64-tdep.c (amd64_none_init_abi): New function.
10763 (amd64_x32_none_init_abi): New function.
10764 (_initialize_amd64_tdep): Register handlers for x86-64 and
10765 x64_32 with GDB_OSABI_NONE.
10766 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10767 GDB_OSABI_NONE osabi.
10769 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10772 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10774 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10775 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10777 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10779 * common/byte-vector.h (char_vector): New type.
10780 * target.h (target_read_alloc): Return
10781 gdb::optional<byte_vector>.
10782 (target_read_stralloc): Return gdb::optional<char_vector>.
10783 (target_get_osdata): Return gdb::optional<char_vector>.
10784 * target.c (target_read_alloc_1): Templatize. Replacement
10785 manual memory management with vector.
10786 (target_read_alloc): Change return type, adjust.
10787 (target_read_stralloc): Change return type, adjust.
10788 (target_get_osdata): Change return type, adjust.
10789 * auxv.c (struct auxv_info) <length>: Remove.
10790 <data>: Change type to gdb::optional<byte_vector>.
10791 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10792 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
10793 (target_auxv_search): Adjust.
10794 (fprint_target_auxv): Adjust.
10795 * avr-tdep.c (avr_io_reg_read_command): Adjust.
10796 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
10797 (linux_make_corefile_notes): Adjust.
10798 * osdata.c (get_osdata): Adjust.
10799 * remote.c (remote_get_threads_with_qxfer): Adjust.
10800 (remote_memory_map): Adjust.
10801 (remote_traceframe_info): Adjust.
10802 (btrace_read_config): Adjust.
10803 (remote_read_btrace): Adjust.
10804 (remote_pid_to_exec_file): Adjust.
10805 * solib-aix.c (solib_aix_get_library_list): Adjust.
10806 * solib-dsbt.c (decode_loadmap): Don't free buf.
10807 (dsbt_get_initial_loadmaps): Adjust.
10808 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
10809 * solib-target.c (solib_target_current_sos): Adjust.
10810 * tracepoint.c (sdata_make_value): Adjust.
10811 * xml-support.c (xinclude_start_include): Adjust.
10812 (xml_fetch_content_from_file): Adjust.
10813 * xml-support.h (xml_fetch_another): Change return type.
10814 (xml_fetch_content_from_file): Change return type.
10815 * xml-syscall.c (xml_init_syscalls_info): Adjust.
10816 * xml-tdesc.c (file_read_description_xml): Adjust.
10817 (fetch_available_features_from_target): Change return type.
10818 (target_fetch_description_xml): Adjust.
10819 (target_read_description_xml): Adjust.
10821 2018-04-06 Tom Tromey <tom@tromey.com>
10823 * value.c (~value): Update.
10824 (struct value) <contents>: Now unique_xmalloc_ptr.
10825 (value_contents_bits_eq, allocate_value_contents)
10826 (value_contents_raw, value_contents_all_raw)
10827 (value_contents_for_printing, value_contents_for_printing_const)
10828 (set_value_enclosing_type): Update.
10830 2018-04-06 Tom Tromey <tom@tromey.com>
10832 * value.c (range_s): Remove typedef, VEC.
10833 (struct range): Add operator<.
10834 (range_lessthan): Remove.
10835 (ranges_contain): Change type.
10837 (struct value) <unavailable, optimized_out>: Now std::vector.
10838 (value_entirely_available)
10839 (value_entirely_covered_by_range_vector)
10840 (value_entirely_unavailable, value_entirely_optimized_out):
10842 (insert_into_bit_range_vector): Change argument type.
10843 (find_first_range_overlap): Likewise.
10844 (struct ranges_and_idx, value_contents_bits_eq)
10845 (require_not_optimized_out, require_available): Update.
10846 (ranges_copy_adjusted): Change argument types.
10847 (value_optimized_out, value_copy, value_fetch_lazy): Update.
10849 2018-04-06 Tom Tromey <tom@tromey.com>
10851 * value.c (~value): Update.
10852 (struct value) <parent>: Now a value_ref_ptr.
10853 (value_parent, set_value_parent, value_address, value_copy):
10856 2018-04-06 Tom Tromey <tom@tromey.com>
10858 * value.c (struct value): Add constructor, destructor, and member
10860 (allocate_value_lazy, value_decref): Update.
10862 2018-04-06 Tom Tromey <tom@tromey.com>
10864 * value.c (struct value) <released, next>: Remove.
10865 (all_values): Now a std::vector.
10866 (allocate_value_lazy): Update.
10867 (value_next): Remove.
10868 (value_mark, value_free_to_mark, release_value)
10869 (value_release_to_mark): Update.
10871 2018-04-06 Tom Tromey <tom@tromey.com>
10873 * value.h (fetch_subexp_value, value_release_to_mark): Update.
10874 (free_value_chain): Remove.
10875 * value.c (free_value_chain): Remove.
10876 (value_release_to_mark): Return a std::vector.
10877 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
10879 (check_condition): Update.
10880 * eval.c (fetch_subexp_value): Change "val_chain" to a
10882 * breakpoint.c (update_watchpoint): Update.
10883 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
10885 2018-04-06 Tom Tromey <tom@tromey.com>
10887 * value.h (free_all_values): Remove.
10888 * value.c (free_all_values): Remove.
10890 2018-04-06 Tom Tromey <tom@tromey.com>
10892 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
10893 (value_history_chain, value_history_count): Remove.
10894 (value_history): New global.
10895 (record_latest_value, access_value_history, show_values)
10896 (preserve_values): Update.
10898 2018-04-06 Tom Tromey <tom@tromey.com>
10900 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
10901 * varobj.c (varobj_set_display_format, varobj_set_value)
10902 (install_default_visualizer, construct_visualizer)
10903 (install_new_value, ~varobj, varobj_get_value_type)
10904 (my_value_of_variable, varobj_editable_p): Update.
10905 * c-varobj.c (c_describe_child, c_value_of_variable)
10906 (cplus_number_of_children, cplus_describe_child): Update.
10907 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
10908 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
10909 (ada_value_of_variable, ada_value_is_changeable_p): Update.
10911 2018-04-06 Tom Tromey <tom@tromey.com>
10913 * printcmd.c (last_examine_address): Change type to
10915 (do_examine, x_command): Update.
10917 2018-04-06 Tom Tromey <tom@tromey.com>
10919 * value.c (release_value): Update.
10920 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
10921 (struct bpstats) <val>: Now a value_ref_ptr.
10922 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10923 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10924 (~watchpoint, print_it_watchpoint, watch_command_1)
10925 (invalidate_bp_value_on_memory_change): Update.
10927 2018-04-06 Tom Tromey <tom@tromey.com>
10929 * varobj.c (varobj_clear_saved_item)
10930 (update_dynamic_varobj_children, install_new_value, ~varobj):
10932 * value.h (value_incref): Move declaration earlier.
10933 (value_decref): Rename from value_free.
10934 (struct value_ref_policy): New.
10935 (value_ref_ptr): New typedef.
10936 (struct value_deleter): Remove.
10937 (gdb_value_up): Remove typedef.
10938 (release_value): Change return type.
10939 (release_value_or_incref): Remove.
10940 * value.c (set_value_parent): Update.
10941 (value_incref): Change return type.
10942 (value_decref): Rename from value_free.
10943 (value_free_to_mark, free_all_values, free_value_chain): Update.
10944 (release_value): Return value_ref_ptr.
10945 (release_value_or_incref): Remove.
10946 (record_latest_value, set_internalvar, clear_internalvar):
10948 * stack.c (info_frame_command): Don't call value_free.
10949 * python/py-value.c (valpy_dealloc, valpy_new)
10950 (value_to_value_object): Update.
10951 * printcmd.c (do_examine): Update.
10952 * opencl-lang.c (lval_func_free_closure): Update.
10953 * mi/mi-main.c (register_changed_p): Don't call value_free.
10954 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10955 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10956 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10958 * guile/scm-value.c (vlscm_free_value_smob)
10959 (vlscm_scm_from_value): Update.
10960 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10961 (frame_unwind_register_unsigned, get_frame_register_bytes)
10962 (put_frame_register_bytes): Don't call value_free.
10963 * findvar.c (address_from_register): Don't call value_free.
10964 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10965 * dwarf2loc.c (entry_data_value_free_closure)
10966 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10967 (dwarf2_evaluate_loc_desc_full): Update.
10968 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10969 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10970 (~watchpoint, watch_command_1)
10971 (invalidate_bp_value_on_memory_change): Update.
10972 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10974 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10977 * warning.m4: Add -Wno-error=deprecated-register.
10978 * configure: Re-generate.
10980 2018-04-05 Tom Tromey <tom@tromey.com>
10982 * linespec.h: Remove include of "vec.h".
10984 2018-04-05 Tom Tromey <tom@tromey.com>
10986 * linespec.c (typep): Remove typedef.
10987 (find_methods, find_superclass_methods): Take a std::vector.
10988 (find_method): Use std::vector.
10990 2018-04-05 Tom Tromey <tom@tromey.com>
10992 * utils.c (compare_strings): Remove.
10993 * utils.h (compare_strings): Remove.
10994 * objc-lang.h (find_imps): Update.
10995 * objc-lang.c (find_methods): Take a std::vector.
10996 (uniquify_strings, find_imps): Likewise.
10997 * linespec.c (find_methods): Take a std::vector.
10998 (decode_objc): Use std::vector.
10999 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
11001 (find_method, find_function_symbols): Use std::vector.
11003 2018-04-05 Tom Tromey <tom@tromey.com>
11005 * completer.c (completion_tracker::completion_tracker): Remove
11007 (completion_tracker::discard_completions): Likewise.
11008 * breakpoint.c (ambiguous_names_p): Remove cast.
11009 * ada-lang.c (_initialize_ada_language): Remove cast.
11010 * utils.h (streq): Update.
11011 (streq_hash): Add new declaration.
11012 * utils.c (streq): Return bool.
11013 (streq_hash): New function.
11015 2018-04-05 Tom Tromey <tom@tromey.com>
11017 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
11018 Remove a string copy.
11020 2018-04-05 Tom Tromey <tom@tromey.com>
11022 * linespec.c (filter_results): Use std::vector.
11023 (decode_line_2, decode_line_full): Update.
11025 2018-04-05 Tom Tromey <tom@tromey.com>
11027 * linespec.c (canonical_to_fullform): Return std::string.
11028 (filter_results): Update.
11029 (struct decode_line_2_item): Add constructor.
11030 <fullform, displayform>: Now std::string.
11031 (decode_line_2_compare_items): Now a std::sort comparator.
11032 (decode_line_2): Update.
11034 2018-04-05 Tom Tromey <tom@tromey.com>
11036 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
11037 (unexpected_linespec_error): Update.
11038 (linespec_parse_basic, parse_linespec): Update.
11040 2018-04-05 Tom Tromey <tom@tromey.com>
11042 * linespec.c (linespec_parse_basic): Reindent.
11044 2018-04-05 Tom Tromey <tom@tromey.com>
11046 * minsyms.h (iterate_over_minimal_symbols): Update.
11047 * minsyms.c (iterate_over_minimal_symbols): Take a
11048 gdb::function_view.
11049 * linespec.c (struct collect_minsyms): Remove.
11050 (compare_msyms): Now a std::sort comparator.
11051 (add_minsym): Add parameters.
11052 (search_minsyms_for_name): Update. Use std::vector.
11054 2018-04-03 Tom Tromey <tom@tromey.com>
11056 * mipsread.c (read_alphacoff_dynamic_symtab): Use
11059 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11061 * MAINTAINERS (Write After Approval): Add Weimin Pan.
11063 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11066 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
11067 printing static type.
11069 2018-04-01 Tom Tromey <tom@tromey.com>
11071 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
11072 (rs6000_xfer_shared_libraries): Update.
11074 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
11076 * common/gdb_vecs.h (char_ptr): Remove.
11077 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
11079 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11081 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
11083 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
11085 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11087 * tracepoint.h (struct uploaded_tp): Initialize fields.
11088 <actions, step_actions, cmd_strings>: Change type to
11089 std::vector<char *>.
11090 * tracepoint.c (get_uploaded_tp): Allocate with new.
11091 (free_uploaded_tps): Free with delete.
11092 (parse_tracepoint_definition): Adjust to std::vector change.
11093 * breakpoint.c (read_uploaded_action): Likewise.
11094 (create_tracepoint_from_upload): Likewise.
11095 * ctf.c (ctf_write_uploaded_tp): Likewise.
11096 (SET_ARRAY_FIELD): Likewise.
11097 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
11099 2018-03-30 Tom Tromey <tom@tromey.com>
11101 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
11103 (svr4_keep_data_in_core): Update.
11104 (svr4_read_so_list): Update.
11106 2018-03-30 Tom Tromey <tom@tromey.com>
11108 * windows-nat.c (handle_output_debug_string, handle_exception):
11110 * target.h (target_read_string): Update.
11111 * target.c (target_read_string): Change "string" to
11112 unique_xmalloc_ptr.
11113 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
11115 * solib-frv.c (frv_current_sos): Update.
11116 * solib-dsbt.c (dsbt_current_sos): Update.
11117 * solib-darwin.c (darwin_current_sos): Update.
11118 * linux-thread-db.c (inferior_has_bug): Update.
11119 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
11120 Update. Remove alloca.
11121 * ada-lang.c (ada_main_name): Update.
11123 2018-03-30 Tom Tromey <tom@tromey.com>
11125 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
11126 (struct dwo_file_deleter): New.
11127 (dwo_file_up): New typedef.
11128 (open_and_init_dwo_file): Use dwo_file_up.
11129 (free_dwo_file_cleanup): Remove.
11131 2018-03-30 Tom Tromey <tom@tromey.com>
11133 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
11134 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
11136 2018-03-30 Tom Tromey <tom@tromey.com>
11138 * dwarf2read.c (class free_cached_comp_units): New class.
11139 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
11140 (free_cached_comp_units): Remove function.
11142 2018-03-30 Tom Tromey <tom@tromey.com>
11144 * utils.h (make_cleanup_unpush_target): Remove.
11145 * inf-ptrace.c (struct target_unpusher): New.
11146 (target_unpush_up) New typedef.
11147 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
11149 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
11151 2018-03-27 Tom Tromey <tom@tromey.com>
11153 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
11155 2018-03-27 Pedro Alves <palves@redhat.com>
11156 Tom Tromey <tom@tromey.com>
11158 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
11159 destructor. Now a class.
11160 (gdb_readline_wrapper_cleanup): Remove function.
11161 (gdb_readline_wrapper): Remove cleanups.
11163 2018-03-27 Tom Tromey <tom@tromey.com>
11165 * typeprint.h (struct type_print_options) <local_typedefs,
11166 global_typedefs>: Remove "struct" keyword.
11167 (class typedef_hash_table): New class.
11168 (recursively_update_typedef_hash, add_template_parameters)
11169 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
11170 (find_typedef_in_hash): Don't declare.
11171 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
11172 (typedef_hash_table::recursively_update): Rename from
11173 recursively_update_typedef_hash. Now a member.
11174 (typedef_hash_table::add_template_parameters): Rename from
11175 add_template_parameters. Now a member.
11176 (typedef_hash_table::typedef_hash_table): Now a constructor;
11177 rename from create_typedef_hash.
11178 (typedef_hash_table::~typedef_hash_table): Now a destructor;
11179 rename from free_typedef_hash.
11180 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
11181 (do_free_global_table): Remove.
11182 (typedef_hash_table::typedef_hash_table): New constructor; renamed
11183 from copy_type_recursive.
11184 (create_global_typedef_table): Remove.
11185 (typedef_hash_table::find_global_typedef): Now a member of
11186 typedef_hash_table.
11187 (typedef_hash_table::find_typedef): Rename from
11188 find_typedef_in_hash; now a member.
11189 (whatis_exp): Update.
11190 * extension.h (struct ext_lang_type_printers): Add constructor and
11192 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
11194 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
11195 Now a constructor; rename from start_ext_lang_type_printers.
11196 (ext_lang_type_printers): Now a destructor; rename from
11197 free_ext_lang_type_printers.
11198 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
11200 (c_type_print_base_struct_union): Update. Remove cleanups.
11202 2018-03-27 Tom Tromey <tom@tromey.com>
11204 * dwarf-index-write.c: Include <cmath>.
11206 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11208 * NEWS: Add entry describing new "set|show varsize-limit" command.
11209 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
11211 * printcmd.c (_initialize_printcmd): Add "set var" alias of
11214 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
11216 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
11217 dwarf-index-write.c
11218 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
11219 * dwarf-index-common.c: New file.
11220 * dwarf-index-common.h: New file.
11221 * dwarf-index-write.c: New file.
11222 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
11223 (struct dwarf2_section_info): Move from here.
11224 (dwarf2_section_info_def): Likewise.
11225 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
11226 (offset_type): Likewise.
11227 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
11228 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
11229 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
11230 (byte_swap): Likewise.
11231 (MAYBE_SWAP): Likewise.
11232 (dwarf2_per_cu_ptr): Likewise.
11233 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
11234 (struct tu_stats): Likewise.
11235 (struct dwarf2_per_objfile): Likewise.
11236 (struct dwarf2_per_cu_data): Likewise.
11237 (struct signatured_type): Likewise.
11238 (sig_type_ptr): Likewise.
11239 (DEF_VEC_P (sig_type_ptr)): Likewise.
11240 (INDEX4_SUFFIX): Likewise.
11241 (INDEX5_SUFFIX): Likewise.
11242 (DEBUG_STR_SUFFIX): Likewise.
11243 (dwarf2_read_section): Make non-static.
11244 (mapped_index_string_hash): Move from here.
11245 (dwarf5_djb_hash): Likewise.
11246 (file_write): Likewise.
11247 (class data_buf): Likewise.
11248 (struct symtab_index_entry): Likewise.
11249 (struct mapped_symtab): Likewise.
11250 (find_slot): Likewise.
11251 (hash_expand): Likewise.
11252 (add_index_entry): Likewise.
11253 (uniquify_cu_indices): Likewise.
11254 (class c_str_view): Likewise.
11255 (class c_str_view_hasher): Likewise.
11256 (class vector_hasher): Likewise.
11257 (write_hash_table): Likewise.
11258 (psym_index_map): Likewise.
11259 (struct addrmap_index_data): Likewise.
11260 (add_address_entry): Likewise.
11261 (add_address_entry_worker): Likewise.
11262 (write_address_map): Likewise.
11263 (symbol_kind): Likewise.
11264 (write_psymbols): Likewise.
11265 (struct signatured_type_index_data): Likewise.
11266 (write_one_signatured_type): Likewise.
11267 (recursively_count_psymbols): Likewise.
11268 (recursively_write_psymbols): Likewise.
11269 (class debug_names): Likewise.
11270 (check_dwarf64_offsets): Likewise.
11271 (psyms_seen_size): Likewise.
11272 (write_gdbindex): Likewise.
11273 (write_debug_names): Likewise.
11274 (assert_file_size): Likewise.
11275 (write_psymtabs_to_index): Likewise.
11276 (save_gdb_index_command): Likewise.
11277 (_initialize_dwarf2_read): Don't register the "save gdb-index"
11279 * dwarf2read.h: New file.
11281 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11284 * dwarf2read.c (dwarf2_physname): Do not return the demangled
11285 symbol name if the CU's language stores symbol names in linkage
11287 * language.h (struct language_defn)
11288 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
11289 all instances of this struct.
11291 2018-03-26 Tom Tromey <tom@tromey.com>
11293 * stack.c (backtrace_command_1): Remove verbose code.
11295 2018-03-26 Tom Tromey <tom@tromey.com>
11297 * python/py-framefilter.c (py_print_type): Don't catch
11298 exceptions. Return void.
11299 (py_print_value): Likewise.
11300 (py_print_single_arg): Likewise.
11301 (enumerate_args): Don't catch exceptions.
11302 (py_print_args): Likewise.
11303 (py_print_frame): Likewise.
11304 (gdbpy_apply_frame_filter): Catch exceptions here.
11306 2018-03-26 Tom Tromey <tom@tromey.com>
11308 * stack.c (_initialize_stack): Remove trailing newlines from help
11309 text. Add "Usage" line to "backtrace" help.
11311 2018-03-26 Tom Tromey <tom@tromey.com>
11314 * python/py-framefilter.c (py_print_args): Call wrap_hint.
11316 2018-03-26 Tom Tromey <tom@tromey.com>
11318 * python/py-framefilter.c (py_print_single_arg): Return
11319 EXT_LANG_BT_ERROR from catch.
11321 2018-03-26 Tom Tromey <tom@tromey.com>
11323 PR backtrace/15584:
11324 * stack.c (backtrace_command_1): Move some code into no-filters
11327 2018-03-26 Tom Tromey <tom@tromey.com>
11329 * python/py-framefilter.c (throw_quit_or_print_exception): New
11331 (gdbpy_apply_frame_filter): Use it.
11333 2018-03-26 Tom Tromey <tom@tromey.com>
11336 * python/py-framefilter.c (py_print_type, py_print_value)
11337 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
11340 2018-03-26 Tom Tromey <tom@tromey.com>
11342 * python/py-framefilter.c (enumerate_args): Use
11343 gdb::unique_xmalloc_ptr.
11345 2018-03-26 Tom Tromey <tom@tromey.com>
11347 * python/py-framefilter.c (py_print_frame): Return
11349 (gdbpy_apply_frame_filter): Update comment.
11350 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
11352 <EXT_LANG_BT_NO_FILTERS>: Change value.
11354 2018-03-26 Tom Tromey <tom@tromey.com>
11356 PR backtrace/15582:
11357 * stack.c (backtrace_command): Parse "hide" argument.
11358 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
11359 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
11362 2018-03-26 Tom Tromey <tom@tromey.com>
11364 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
11366 (backtrace_command): Remove "fulltrace", add "flags".
11368 2018-03-26 Tom Tromey <tom@tromey.com>
11370 * stack.c (backtrace_command): Rewrite command line parsing.
11372 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11374 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
11376 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11378 * filename-seen-cache.h: Add include guard.
11380 2018-03-26 Keith Seitz <keiths@redhat.com>
11382 * symfile.c (place_section): Remove "struct" from section_addr_info
11384 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
11385 "struct" keyword from section_addr_info.
11387 2018-03-26 Alan Hayward <alan.hayward@arm.com>
11389 * regformats/regdef.h (reg): Add constructors.
11391 2018-03-25 Pedro Alves <palves@redhat.com>
11393 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
11394 if then/else bodies in var_func_name extraction.
11396 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
11398 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
11399 lookup_minimal_symbol() to find symbol entry.
11400 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
11402 2018-03-23 Keith Seitz <keiths@redhat.com>
11405 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
11406 nested type definitions for C++, too.
11408 2018-03-23 Tom Tromey <tom@tromey.com>
11410 * machoread.c (struct oso_el): Add a constructor. Don't define as
11412 (macho_register_oso): Remove.
11413 (macho_symtab_read): Take a std::vector.
11414 (oso_el_compare_name): Now a std::sort comparator.
11415 (macho_symfile_read_all_oso): Take a std::vector.
11416 (macho_symfile_read): Use std::vector. Remove cleanups.
11418 2018-03-22 Tom Tromey <tom@tromey.com>
11420 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
11421 (record_full_goto_bookmark): Use std::string.
11423 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11426 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
11429 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11431 * rs6000-tdep.c (store_insn_p): New function.
11432 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
11433 and cr_reg to their unshifted values. Use store_insn_p to
11434 match LR saves using either R1 or fdata->alloca_reg. Use
11435 store_insn_p to match CR saves. Set alloca_reg_offset
11436 when alloca_reg and framep are set. Remove lr_reg shift
11437 when assigning to fdata->lr_register.
11439 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
11441 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
11442 command line args instead of emitting a warning.
11444 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11446 * tracepoint.h (struct static_tracepoint_marker): Initialize
11447 fields, define default constructor, move constructor and move
11448 assignment, disable the rest.
11449 <str_id, extra>: Make std::string.
11450 (release_static_tracepoint_marker): Remove.
11451 (free_current_marker): Remove.
11452 * tracepoint.c (free_current_marker): Remove.
11453 (parse_static_tracepoint_marker_definition): Adjust to
11454 std::string, use new hex2str overload.
11455 (release_static_tracepoint_marker): Remove.
11456 (print_one_static_tracepoint_marker): Get marker by reference
11457 and adjust to std::string.
11458 (info_static_tracepoint_markers_command): Adjust to std::vector
11460 * target.h (static_tracepoint_marker_p): Remove typedef.
11461 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
11462 (struct target_ops) <to_static_tracepoint_marker_at>: Return
11464 <to_static_tracepoint_markers_by_strid>: Return std::vector.
11466 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
11467 (target_debug_print_std_vector_static_tracepoint_marker): New.
11468 (target_debug_print_struct_static_tracepoint_marker_p): Rename
11470 (target_debug_print_static_tracepoint_marker_p): ... this.
11471 * target-delegates.c: Re-generate.
11472 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
11474 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
11475 (decode_static_tracepoint_spec): Adjust to std::vector.
11476 (tracepoint_print_one_detail): Adjust to std::string.
11477 (strace_marker_decode_location): Adjust to std::string.
11478 (update_static_tracepoint): Adjust to std::string, remove call
11479 to release_static_tracepoint_marker.
11480 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
11481 Adjust to std::vector.
11482 * remote.c (remote_static_tracepoint_marker_at): Return bool.
11483 (remote_static_tracepoint_markers_by_strid): Adjust to
11485 * common/rsp-low.h (hex2str): New overload with explicit count
11487 * common/rsp-low.c (hex2str): New overload with explicit count
11489 * unittests/rsp-low-selftests.c (test_hex2str): New function.
11490 (_initialize_rsp_low_selftests): Add test_hex2str test.
11491 * unittests/tracepoint-selftests.c
11492 (test_parse_static_tracepoint_marker_definition): Adjust to
11495 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11497 * tracepoint.c (parse_static_tracepoint_marker_definition):
11498 Consider case where the definition is followed by more
11500 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11501 tracepoint-selftests.c.
11502 * unittests/tracepoint-selftests.c: New.
11504 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11506 * MAINTAINERS (Write After Approval): Add Pedro Franco de
11509 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
11511 * symtab.c (find_pc_sect_line): fixed indentation.
11513 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
11515 * symtab.c (find_pc_sect_line): now uses binary search.
11517 2018-03-19 Tom Tromey <tom@tromey.com>
11519 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
11520 "IDENT" production.
11522 2018-03-19 Pedro Alves <palves@redhat.com>
11523 Tom Tromey <tom@tromey.com>
11525 * unittests/observable-selftests.c: New file.
11526 * common/observable.h: New file.
11527 * observable.h: New file.
11528 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
11529 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
11530 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
11531 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
11532 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
11533 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
11534 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
11535 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
11536 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
11537 python/py-breakpoint.c, python/py-finishbreakpoint.c,
11538 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
11539 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
11540 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
11541 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
11542 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
11543 tui/tui-interp.c, valops.c: Update all users.
11544 * tui/tui-hooks.c (tui_bp_created_observer)
11545 (tui_bp_deleted_observer, tui_bp_modified_observer)
11546 (tui_inferior_exit_observer, tui_before_prompt_observer)
11547 (tui_normal_stop_observer, tui_register_changed_observer):
11549 (tui_observers_token): New global.
11550 (attach_or_detach, tui_attach_detach_observers): New functions.
11551 (tui_install_hooks, tui_remove_hooks): Use
11552 tui_attach_detach_observers.
11553 * record-btrace.c (record_btrace_thread_observer): Remove.
11554 (record_btrace_thread_observer_token): New global.
11555 * observer.sh: Remove.
11556 * observer.c: Rename to observable.c.
11557 * observable.c (namespace gdb_observers): Define new objects.
11558 (observer_debug): Move into gdb_observers namespace.
11559 (struct observer, struct observer_list, xalloc_observer_list_node)
11560 (xfree_observer_list_node, generic_observer_attach)
11561 (generic_observer_detach, generic_observer_notify): Remove.
11562 (_initialize_observer): Update.
11563 Don't include observer.inc.
11564 * Makefile.in (generated_files): Remove observer.h, observer.inc.
11565 (clean mostlyclean): Likewise.
11566 (observer.h, observer.inc): Remove targets.
11567 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
11568 (COMMON_SFILES): Use observable.c, not observer.c.
11569 * .gitignore: Remove observer.h.
11571 2018-03-18 Tom Tromey <tom@tromey.com>
11573 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
11575 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
11577 2018-03-17 Tom Tromey <tom@tromey.com>
11579 * auto-load.c (auto_load_objfile_script_1): Use std::string.
11581 2018-03-17 Tom Tromey <tom@tromey.com>
11583 * target.c (class scoped_target_fd): New.
11584 (target_fileio_close_cleanup): Remove.
11585 (target_fileio_read_alloc_1): Use scoped_target_fd.
11587 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
11589 * silent-rules.mk: New.
11590 * Makefile.in: Include silent-rules.mk
11591 (srcdir, VPATH, top_srcdir): Move up.
11592 (COMPILE): Add ECHO_CXX.
11593 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
11594 (init.c): Add ECHO_INIT_C.
11595 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
11596 (version.c): Add ECHO_GEN.
11597 (printcmd.o): Add ECHO_CXX.
11598 (target-float.o): Add ECHO_CXX.
11599 (ada-exp.o): Add ECHO_CXX.
11600 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
11601 (insight$(EXEEXT)): Add ECHO_CXXLD.
11602 * gnulib/configure.ac: Add AM_SILENT_RULES.
11603 * gnulib/aclocal.m4: Re-generate.
11604 * gnulib/configure: Re-generate.
11605 * gnulib/import/Makefile.in: Re-generate.
11607 2018-03-16 Tom Tromey <tom@tromey.com>
11609 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
11610 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
11611 * utils.c (do_free_section_addr_info)
11612 (make_cleanup_free_section_addr_info): Remove.
11613 * symfile.h (struct other_sections): Add constructor.
11614 (struct section_addr_info): Remove.
11615 (section_addr_info): New typedef.
11616 (struct sym_fns) <sym_offsets>: Change type of parameter.
11617 (build_section_addr_info_from_objfile)
11618 (relative_addr_info_to_section_offsets, addr_info_make_relative)
11619 (default_symfile_offsets, symbol_file_add)
11620 (symbol_file_add_from_bfd)
11621 (build_section_addr_info_from_section_table): Update.
11622 (alloc_section_addr_info, free_section_addr_info): Don't declare.
11623 * symfile.c (alloc_section_addr_info): Remove.
11624 (build_section_addr_info_from_section_table): Change return type.
11626 (build_section_addr_info_from_bfd)
11627 (build_section_addr_info_from_objfile): Likewise.
11628 (free_section_addr_info): Remove.
11629 (relative_addr_info_to_section_offsets): Change type of "addrs".
11630 (addrs_section_compar): Now a std::sort comparator.
11631 (addrs_section_sort): Change return type.
11632 (addr_info_make_relative): Change type of "addrs". Update.
11633 (default_symfile_offsets, syms_from_objfile_1)
11634 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
11635 (symbol_file_add_separate): Update.
11636 (symbol_file_add): Change type of "addrs". Update.
11637 (add_symbol_file_command): Update. Remove cleanups.
11638 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
11640 * symfile-debug.c (debug_sym_offsets): Change type of "info".
11641 * solib.c (solib_read_symbols): Update.
11642 * objfiles.c (objfile_relocate): Update. Remove cleanups.
11643 * machoread.c (macho_symfile_offsets): Update.
11644 * jit.c (jit_bfd_try_read_symtab): Update.
11646 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
11648 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11649 unittests/utils-selftests.c.
11650 * unittests/utils-selftests.c: New file.
11652 2018-03-14 Tom Tromey <tom@tromey.com>
11655 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
11658 2018-03-14 Tom Tromey <tom@tromey.com>
11661 * printcmd.c (printf_pointer): Allow "-" in format.
11663 2018-03-14 Tom Tromey <tom@tromey.com>
11665 * printcmd.c (_initialize_printcmd): Add usage to printf.
11667 2018-03-14 Yao Qi <qiyao@sourceware.org>
11669 * MAINTAINERS: Update my email address.
11671 2018-03-13 Tom Tromey <tom@tromey.com>
11673 * machoread.c (macho_check_dsym): Change filenamep to a
11675 (macho_symfile_read): Update.
11676 * symfile.c (load_command): Use std::string.
11678 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
11680 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
11681 to error message string.
11682 (riscv_register_name): Use xsnprintf instead of sprintf.
11683 (riscv_insn::fetch_instruction): Use gdb_assert instead of
11685 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
11687 (riscv_push_dummy_call): Likewise.
11689 2018-03-12 Tom Tromey <tom@tromey.com>
11691 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
11692 Use gdb::byte_vector.
11693 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
11695 2018-03-12 Yao Qi <yao.qi@linaro.org>
11697 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
11698 parameter type to readable_regcache.
11699 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
11702 2018-03-11 Tom Tromey <tom@tromey.com>
11704 * dwarf2read.c (struct nextfield): Add initializers.
11705 (struct nextfnfield): Remove.
11706 (struct fnfieldlist): Add initializers. Remove "length" and
11707 "head", use std::vector.
11708 (struct decl_field_list): Remove.
11709 (struct field_info): Add initializers.
11710 <fields, baseclasses>: Now std::vector.
11711 <nbaseclasses, nfnfields, typedef_field_list_count,
11712 nested_types_list_count>: Remove.
11713 (dwarf2_add_field, dwarf2_add_type_defn)
11714 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
11715 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
11716 (process_structure_scope): Update.
11718 2018-03-11 Tom Tromey <tom@tromey.com>
11720 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
11721 for use by std::sort.
11722 (build_type_psymtabs_1): Use std::vector.
11724 2018-03-09 Eli Zaretskii <eliz@gnu.org>
11726 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
11727 and LIBMPFR in the printed configuration.
11729 2018-03-08 Tom Tromey <tom@tromey.com>
11731 * source.c (get_filename_and_charpos): Use scoped_fd.
11732 * nto-procfs.c (procfs_open_1): Use scoped_fd.
11733 (procfs_pidlist): Likewise.
11734 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
11735 (iterate_over_mappings): Likewise.
11737 2018-03-08 Tom Tromey <tom@tromey.com>
11739 * infcall.c (struct call_return_meta_info)
11740 <stack_temporaries_enabled>: Remove.
11741 (get_call_return_value, call_function_by_hand_dummy): Update.
11742 * thread.c (disable_thread_stack_temporaries): Remove.
11743 (enable_thread_stack_temporaries): Remove.
11744 (thread_stack_temporaries_enabled_p): Return bool.
11745 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
11746 (get_last_thread_stack_temporary): Update.
11747 * eval.c (evaluate_subexp): Update.
11748 * gdbthread.h (class enable_thread_stack_temporaries): Now a
11749 class, not a function.
11750 (value_ptr, value_vec): Remove typedefs.
11751 (class thread_info) <stack_temporaries_enabled>: Now bool.
11752 <stack_temporaries>: Now a std::vector.
11753 (thread_stack_temporaries_enabled_p)
11754 (value_in_thread_stack_temporaries): Return bool.
11756 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
11758 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11759 (getpkt_or_notif_sane_1): Likewise.
11761 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11763 * build-id.c (build_id_to_debug_bfd): Use std::string.
11765 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11767 * build-id.c (find_separate_debug_file_by_buildid): Return
11769 * build-id.h (find_separate_debug_file_by_buildid): Return
11771 * coffread.c (coff_symfile_read): Adjust to std::string.
11772 * elfread.c (elf_symfile_read): Adjust to std::string.
11773 * symfile.c (separate_debug_file_exists): Change parameter to
11775 (find_separate_debug_file): Return std::string.
11776 (find_separate_debug_file_by_debuglink): Return std::string.
11777 * symfile.h (find_separate_debug_file_by_debuglink): Return
11780 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11782 * common/xml-utils.c (xml_escape_text): Move code to...
11783 (xml_escape_text_append): ... this new function.
11784 * common/xml-utils.h (xml_escape_text_append): New declaration.
11785 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11787 (_initialize_xml_utils): register test_xml_escape_text_append as
11790 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11792 * defs.h: Remove MAX_REGISTER_SIZE.
11793 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
11795 * python/py-unwind.c (pyuw_sniffer): Likewise.
11797 2018-03-07 Tom Tromey <tom@tromey.com>
11799 * linux-tdep.c (linux_info_proc): Update.
11800 * target.h (struct target_ops) <to_fileio_readlink>: Return
11802 (target_fileio_readlink): Return optional<string>.
11803 * remote.c (remote_hostio_readlink): Return optional<string>.
11804 * inf-child.c (inf_child_fileio_readlink): Return
11806 * target.c (target_fileio_readlink): Return optional<string>.
11808 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
11810 * regcache.c (cooked_read_test): Add riscv to the list of
11811 architectures that have a save_reggroup.
11813 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
11815 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
11816 value is not a dynamic class object.
11818 2018-03-06 Tom Tromey <tom@tromey.com>
11820 * rust-exp.y: Formatting fixes.
11822 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11824 * riscv-tdep.c (riscv_register_name): Remove target description
11826 (riscv_gdbarch_init): Remove target description check.
11828 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11830 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
11832 * riscv-tdep.h: Likewise.
11834 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11836 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
11837 (riscv_pseudo_register_write): Delete.
11838 (riscv_gdbarch_init): Remove all use of pseudo registers.
11840 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11842 * record-btrace.c (btrace_print_lines): Replace cleanup
11843 parameter with RAII equivalents.
11844 (btrace_insn_history): Replace cleanup with RAII equivalents.
11845 * ui-out.h (make_cleanup_ui_out_list_begin_end,
11846 make_cleanup_ui_out_tuple_begin_end): Remove.
11847 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
11848 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
11849 make_cleanup_ui_out_list_begin_end): Remove.
11851 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11853 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
11854 parameter types to std::vector. Use bool.
11855 (record_btrace_wait): Replace VEC(tp_t) with
11856 std::vector<thread_info *>.
11857 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
11859 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11861 * record-btrace.c (record_btrace_disable_callback): Remove.
11862 (struct scoped_btrace_disable): New.
11863 (record_btrace_open): Use scoped_btrace_disable.
11865 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11867 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
11868 reading values from registers.
11870 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11872 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
11875 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11877 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
11878 change parameter type. Use GDB's print functions, and use
11879 core_addr_to_string where appropriate.
11880 (riscv_push_dummy_call): Use core_addr_to_string where
11881 appropriate, update call to riscv_print_arg_location, and reindent
11883 (riscv_return_value): Update call to riscv_print_arg_location.
11885 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11886 Tim Newsome <tim@sifive.com>
11887 Albert Ou <a0u@eecs.berkeley.edu>
11888 Darius Rad <darius@bluespec.com>
11890 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
11891 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
11892 (ALLDEPFILES): Add riscv-tdep.c
11893 * configure.tgt: Add riscv support.
11894 * riscv-tdep.c: New file.
11895 * riscv-tdep.h: New file.
11896 * NEWS: Mention new target.
11897 * MAINTAINERS: Add entry for riscv.
11899 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11901 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
11902 fields within aggregates.
11904 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
11906 * record-btrace.c (btrace_print_lines): Change type of flags to
11907 gdb_disassembly_flags.
11909 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11911 * fbsd-nat.c: Include "inf-ptrace.h".
11912 (USE_SIGTRAP_SIGINFO): Conditionally define.
11913 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
11914 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
11915 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
11917 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
11919 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
11921 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
11922 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
11923 "supports_stopped_by_hw_breakpoint" target methods.
11925 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11927 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
11928 * fbsd-nat.c (debug_fbsd_nat): New variable.
11929 (show_fbsd_nat_debug): New function.
11930 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
11931 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
11933 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11935 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
11936 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
11938 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
11939 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11942 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11944 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11945 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11947 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11949 * charset.c (struct charset_vector): New.
11950 (charsets): Change type to charset_vector.
11951 (find_charset_names): Adjust.
11953 (_initialize_charset): Adjust.
11955 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11957 * progspace.h (struct program_space) <deleted_solibs>: Change
11958 type to std::vector<std::string>.
11959 * progspace.c (clear_program_space_solib_cache): Adjust.
11960 * breakpoint.c (print_solib_event): Adjust.
11961 (check_status_catch_solib): Adjust.
11962 * solib.c (update_solib_list): Adjust.
11963 * ui-out.h (class ui_out) <field_string>: New overload.
11964 * ui-out.c (ui_out::field_string): New overload.
11966 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11968 * progspace.h (struct program_space): Add constructor and
11969 destructor, initialize fields.
11970 (add_program_space): Remove.
11971 * progspace.c (add_program_space): Rename to...
11972 (program_space::program_space): ... this.
11973 (release_program_space): Rename to...
11974 (program_space::~program_space): ... this.
11975 (delete_program_space): Use delete to delete program_space.
11976 (initialize_progspace): Use new to allocate program_space.
11977 * inferior.c (add_inferior_with_spaces): Likewise.
11978 (clone_inferior_command): Likewise.
11979 * infrun.c (follow_fork_inferior): Likewise.
11980 (handle_vfork_child_exec_or_exit): Likewise.
11982 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11984 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11985 (delim_string_to_char_ptr_vec): Return std::vector of
11986 gdb::unique_xmalloc_ptr.
11987 (dirnames_to_char_ptr_vec_append): Take std::vector of
11988 gdb::unique_xmalloc_ptr.
11989 (dirnames_to_char_ptr_vec): Return std::vector of
11990 gdb::unique_xmalloc_ptr.
11991 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11992 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11993 (delim_string_to_char_ptr_vec): Return an std::vector of
11994 gdb::unique_xmalloc_ptr, adjust the code.
11995 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11996 gdb::unique_xmalloc_ptr, adjust the code.
11997 (dirnames_to_char_ptr_vec): Return an std::vector of
11998 gdb::unique_xmalloc_ptr, adjust the code.
11999 * auto-load.c (auto_load_safe_path_vec): Change type to
12000 std::vector of gdb::unique_xmalloc_ptr.
12001 (auto_load_expand_dir_vars): Return an std::vector of
12002 gdb::unique_xmalloc_ptr, adjust the code.
12003 (auto_load_safe_path_vec_update): Adjust.
12004 (filename_is_in_auto_load_safe_path_vec): Adjust.
12005 (auto_load_objfile_script_1): Adjust.
12006 * build-id.c (build_id_to_debug_bfd): Adjust.
12007 * linux-thread-db.c (thread_db_load_search): Adjust.
12008 * source.c (add_path): Adjust.
12010 * symfile.c (find_separate_debug_file): Adjust.
12011 * utils.c (do_free_char_ptr_vec): Remove.
12012 (make_cleanup_free_char_ptr_vec): Remove.
12014 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
12017 * common/pathstuff.c: Conditionally include "<windows.h>".
12019 2018-03-01 Georg Sauthoff <mail@georg.so>
12022 * gcore.in: Quote variables and switch interpreter to bash.
12024 2018-03-01 Tom Tromey <tom@tromey.com>
12026 * dwarf2read.c (alloc_discriminant_info): Fix default_index
12027 assertion. Add assertion for discriminant_index.
12028 (quirk_rust_enum): Use correct base type name in univariant case.
12030 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
12032 * record.c (get_call_history_modifiers): Return a
12033 record_print_flags.
12034 (cmd_record_call_history): Adjust.
12035 * record-btrace.c (record_btrace_call_history): Adjust.
12036 (record_btrace_call_history_range): Adjust.
12037 (record_btrace_call_history_from): Adjust.
12038 * target-debug.h (target_debug_print_record_print_flags): New.
12039 * target-delegates.c: Re-generate.
12040 * target.c (target_call_history): Change flags type.
12041 (target_call_history_from): Likewise.
12042 (target_call_history_range): Likewise.
12043 * target.h (struct target_ops) <target_call_history>: Likewise.
12044 (target_call_history_from): Likewise.
12045 (target_call_history_range): Likewise.
12047 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12048 Simon Marchi <simon.marchi@polymtl.ca>
12050 * common/common-utils.c: Include "sys/stat.h".
12051 (is_regular_file): Move here from "source.c"; change return
12053 * common/common-utils.h (is_regular_file): New prototype.
12054 * common/pathstuff.c (contains_dir_separator): New function.
12055 * common/pathstuff.h (contains_dir_separator): New prototype.
12056 * source.c: Don't include "sys/stat.h".
12057 (is_regular_file): Move to "common/common-utils.c".
12059 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12061 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
12062 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
12063 * auto-load.c: Include "common/pathstuff.h".
12064 * common/common-def.h (current_directory): Move here.
12065 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
12067 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
12069 * common/pathstuff.c: New file.
12070 * common/pathstuff.h: New file.
12071 * compile/compile.c: Include "common/pathstuff.h".
12072 * defs.h (current_directory): Move to "common/common-defs.h".
12073 * dwarf2read.c: Include "common/pathstuff.h".
12074 * exec.c: Likewise.
12075 * guile/scm-safe-call.c: Likewise.
12076 * linux-thread-db.c: Likewise.
12077 * main.c: Likewise.
12078 * nto-tdep.c: Likewise.
12079 * objfiles.c: Likewise.
12080 * source.c: Likewise.
12081 * symtab.c: Likewise.
12082 * utils.c: Include "common/pathstuff.h".
12083 (gdb_realpath): Move to "common/pathstuff.c".
12084 (gdb_realpath_keepfile): Likewise.
12085 (gdb_abspath): Likewise.
12086 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
12087 (gdb_realpath_keepfile): Likewise.
12088 (gdb_abspath): Likewise.
12090 2018-02-28 John Baldwin <jhb@FreeBSD.org>
12092 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
12093 wildcard process pid for super_resume for kernels with a
12096 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
12098 * compile/compile.c (get_args): Add additional comments
12099 explaining function.
12101 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
12102 Tom Tromey <tom@tromey.com>
12104 * target.h (memory_write_request_s): Remove typedef. Don't define
12106 (target_write_memory_blocks): Change argument to std::vector.
12107 (struct memory_write_request): Add constructor.
12108 * target-memory.c (compare_block_starting_address): Return bool.
12109 Change argument types.
12110 (claim_memory): Change arguments to use std::vector.
12111 (split_regular_and_flash_blocks, blocks_to_erase)
12112 (compute_garbled_blocks): Likewise.
12113 (cleanup_request_data, cleanup_write_requests_vector): Remove.
12114 (target_write_memory_blocks): Change argument to std::vector.
12115 * symfile.c (struct load_section_data): Add constructor and
12116 destructor. Use std::vector for "requests".
12117 (struct load_progress_data): Add initializers.
12118 (load_section_callback): Update. Use "new".
12119 (clear_memory_write_data): Remove.
12120 (generic_load): Update.
12122 2018-02-27 Alan Hayward <alan.hayward@arm.com>
12124 * arch/aarch64.h: Use common/tdesc.h.
12126 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12128 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
12129 architecture with a 64-bit ABI.
12131 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12133 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
12134 ahead of target description loading.
12136 2018-02-26 Tom Tromey <tom@tromey.com>
12138 * stack.c (backtrace_command_1): Update.
12139 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
12141 * python/py-framefilter.c (py_print_frame)
12142 (gdbpy_apply_frame_filter): Change type of "flags".
12143 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
12145 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
12146 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
12147 * extension.h (enum frame_filter_flag): Rename from
12148 frame_filter_flags.
12149 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
12150 (apply_ext_lang_frame_filter): Change type of "flags".
12151 * extension.c (apply_ext_lang_frame_filter): Change type of
12153 * extension-priv.h (struct extension_language_ops)
12154 <apply_frame_filter>: Change type of "flags".
12156 2018-02-26 Tom Tromey <tom@tromey.com>
12159 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
12160 off-by-one in py_end computation.
12161 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
12163 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
12166 2018-02-26 Tom Tromey <tom@tromey.com>
12168 * dwarf2read.c (struct variant_field): New.
12169 (struct nextfield) <variant>: New field.
12170 (dwarf2_add_field): Handle DW_TAG_variant_part.
12171 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
12172 discriminated union.
12173 (read_structure_type): Handle DW_TAG_variant_part.
12174 (handle_struct_member_die): New function, extracted from
12175 process_structure_scope. Handle DW_TAG_variant.
12176 (process_structure_scope): Handle discriminated unions. Call
12177 handle_struct_member_die.
12179 2018-02-26 Tom Tromey <tom@tromey.com>
12181 * rust-lang.h (rust_last_path_segment): Declare.
12182 * rust-lang.c (rust_last_path_segment): Now public. Change
12184 (struct disr_info): Remove.
12185 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
12186 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
12187 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
12188 (rust_enum_p, rust_enum_variant): New function.
12189 (rust_underscore_fields): Remove "offset" parameter.
12190 (rust_print_enum): New function.
12191 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
12192 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
12193 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
12195 (rust_internal_print_type): New function, from rust_print_type.
12197 (rust_print_type): Call rust_internal_print_type.
12198 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
12199 Update enum handling.
12200 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
12201 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
12202 (rust_union_quirks): New functions.
12203 (process_full_comp_unit, process_full_type_unit): Call
12205 (process_structure_scope): Update rust_unions if necessary.
12207 2018-02-26 Tom Tromey <tom@tromey.com>
12209 * value.h (value_union_variant): Declare.
12210 * valops.c (value_union_variant): New function.
12211 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
12212 (struct discriminant_info): New.
12213 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
12215 (struct main_type) <flag_discriminated_union>: New field.
12217 2018-02-26 Tom Tromey <tom@tromey.com>
12219 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12220 unittests/unpack-selftests.c.
12221 * unittests/unpack-selftests.c: New file.
12222 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
12224 2018-02-26 Yao Qi <yao.qi@linaro.org>
12226 * dwarf2read.c (struct partial_die_info) <read>: New method.
12227 (read_partial_die): Remove the declaration.
12228 (load_partial_dies): Update.
12229 (partial_die_info::partial_die_info):
12230 (read_partial_die): Change it to partial_die_info::read.
12232 2018-02-26 Yao Qi <yao.qi@linaro.org>
12234 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
12235 (fixup_partial_die): Remove declaration.
12236 (scan_partial_symbols): Update.
12237 (partial_die_parent_scope): Likewise.
12238 (partial_die_full_name): Likewise.
12239 (fixup_partial_die): Change it to partial_die_info::fixup.
12241 2018-02-26 Yao Qi <yao.qi@linaro.org>
12243 * dwarf2read.c (read_partial_die): Update the declaration.
12244 (load_partial_dies): Caller update.
12245 (read_partial_die): Remove one argument abbrev_len.
12247 2018-02-26 Yao Qi <yao.qi@linaro.org>
12249 * dwarf2read.c (struct partial_die_info): Add ctor, delete
12250 assignment operator.
12251 (load_partial_dies): Use ctor and copy ctor.
12252 (read_partial_die): Update.
12253 (dwarf2_cu::find_partial_die): Use ctor.
12255 2018-02-26 Yao Qi <yao.qi@linaro.org>
12257 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
12258 (find_partial_die_in_comp_unit): Change it to
12259 dwarf2_cu::find_partial_die.
12260 (find_partial_die): Update.
12262 2018-02-26 Yao Qi <yao.qi@linaro.org>
12264 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
12267 2018-02-26 Yao Qi <yao.qi@linaro.org>
12269 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
12271 2018-02-26 Alan Hayward <alan.hayward@arm.com>
12273 * arch/amd64.h: Use common/tdesc.h.
12274 * arch/i386.c: Likewise.
12275 * arch/i386.h: Likewise.
12276 * arch/tic6x.c: Likewise.
12277 * arch/tdesc.h: Move file from here...
12278 * common/tdesc.h: ...to here.
12279 * features/aarch64-core.c: Regenerate.
12280 * features/aarch64-fpu.c: Regenerate.
12281 * features/i386/32bit-avx.c: Regenerate.
12282 * features/i386/32bit-avx512.c: Regenerate.
12283 * features/i386/32bit-core.c: Regenerate.
12284 * features/i386/32bit-linux.c: Regenerate.
12285 * features/i386/32bit-mpx.c: Regenerate.
12286 * features/i386/32bit-pkeys.c: Regenerate.
12287 * features/i386/32bit-sse.c: Regenerate.
12288 * features/i386/64bit-avx.c: Regenerate.
12289 * features/i386/64bit-avx512.c: Regenerate.
12290 * features/i386/64bit-core.c: Regenerate.
12291 * features/i386/64bit-linux.c: Regenerate.
12292 * features/i386/64bit-mpx.c: Regenerate.
12293 * features/i386/64bit-pkeys.c: Regenerate.
12294 * features/i386/64bit-segments.c: Regenerate.
12295 * features/i386/64bit-sse.c: Regenerate.
12296 * features/i386/x32-core.c: Regenerate.
12297 * features/tic6x-c6xp.c: Regenerate.
12298 * features/tic6x-core.c: Regenerate.
12299 * features/tic6x-gp.c: Regenerate.
12300 * target-descriptions.c: Use common/tdesc.h.
12301 * target-descriptions.h: Likewise.
12303 2018-02-24 Tom Tromey <tom@tromey.com>
12305 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
12306 (try_thread_db_load_from_dir, thread_db_load_search): Use
12308 (info_auto_load_libthread_db_compare): Return bool. Change
12310 (info_auto_load_libthread_db): Use std::vector, std::string.
12313 2018-02-24 Tom Tromey <tom@tromey.com>
12315 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
12317 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
12319 * gdbarch.c: Rebuild.
12320 * gdbarch.h: Rebuild.
12321 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
12322 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
12323 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
12326 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
12328 * gdbtypes.h (sect_offset): Change type to uint64_t.
12329 (sect_offset_str): New function.
12330 * dwarf2read.c (create_addrmap_from_aranges): Use
12332 (error_check_comp_unit_head): Likewise.
12333 (create_debug_type_hash_table): Likewise.
12334 (read_cutu_die_from_dwo): Likewise.
12335 (init_cutu_and_read_dies): Likewise.
12336 (init_cutu_and_read_dies_no_follow): Likewise.
12337 (process_psymtab_comp_unit_reader): Likewise.
12338 (partial_die_parent_scope): Likewise.
12339 (peek_die_abbrev): Likewise.
12340 (process_queue): Likewise.
12341 (dwarf2_physname): Likewise.
12342 (read_namespace_alias): Likewise.
12343 (read_import_statement): Likewise.
12344 (create_dwo_cu_reader): Likewise.
12345 (create_cus_hash_table): Likewise.
12346 (lookup_dwo_cutu): Likewise.
12347 (inherit_abstract_dies): Likewise.
12348 (read_func_scope): Likewise.
12349 (read_call_site_scope): Likewise.
12350 (dwarf2_add_member_fn): Likewise.
12351 (read_common_block): Likewise.
12352 (read_module_type): Likewise.
12353 (read_typedef): Likewise.
12354 (read_subrange_type): Likewise.
12355 (load_partial_dies): Likewise.
12356 (read_partial_die): Likewise.
12357 (find_partial_die): Likewise.
12358 (read_str_index): Likewise.
12359 (dwarf2_string_attr): Likewise.
12360 (build_error_marker_type): Likewise.
12361 (lookup_die_type): Likewise.
12362 (dump_die_shallow): Likewise.
12363 (follow_die_ref): Likewise.
12364 (dwarf2_fetch_die_loc_sect_off): Likewise.
12365 (dwarf2_fetch_constant_bytes): Likewise.
12366 (follow_die_sig): Likewise.
12367 (get_signatured_type): Likewise.
12368 (get_DW_AT_signature_type): Likewise.
12369 (dwarf2_find_containing_comp_unit): Likewise.
12370 (set_die_type): Likewise.
12372 2018-02-21 John Baldwin <jhb@FreeBSD.org>
12374 * arch/aarch64.c: Include "common-defs.h".
12375 * arch/amd64.c: Likewise.
12376 * arch/i386.c: Likewise.
12378 2018-02-21 Tom Tromey <tom@tromey.com>
12380 * value.h: (extract_field_op): Update.
12381 * eval.c (extract_field_op): Return a const char *.
12382 * expression.h (parse_expression_for_completion): Update.
12383 * completer.c (complete_expression): Update.
12384 (add_struct_fields): Make fieldname const.
12385 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
12386 (mark_completion_tag, parse_exp_in_context_1): Update.
12387 (parse_expression_for_completion): Change "name" to
12388 unique_xmalloc_ptr*.
12390 2018-02-21 Tom Tromey <tom@tromey.com>
12392 * infcall.c (call_function_by_hand_dummy): Use std::vector.
12394 2018-02-21 Yao Qi <yao.qi@linaro.org>
12396 * avr-tdep.c (avr_read_pc): Change parameter type to
12398 * gdbarch.sh (read_pc): Likewise.
12399 * gdbarch.c: Re-generated.
12400 * gdbarch.h: Re-generated.
12401 * hppa-tdep.c (hppa_read_pc): Change parameter type to
12403 * ia64-tdep.c (ia64_read_pc): Likewise.
12404 * mips-tdep.c (mips_read_pc): Likewise.
12405 * spu-tdep.c (spu_read_pc): Likewise.
12407 2018-02-21 Yao Qi <yao.qi@linaro.org>
12409 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
12410 * regcache-dump.c: New file.
12411 * regcache.c: Move register_dump to regcache-dump.c.
12412 (maintenance_print_registers): Likewise.
12413 (maintenance_print_raw_registers): Likewise.
12414 (maintenance_print_cooked_registers): Likewise.
12415 (maintenance_print_register_groups): Likewise.
12416 (maintenance_print_remote_registers): Likewise.
12417 (_initialize_regcache): Likewise.
12418 * regcache.h (register_dump): Moved from regcache.c.
12420 2018-02-21 Yao Qi <yao.qi@linaro.org>
12422 * regcache.c (regcache::regcache): Update.
12423 (regcache::invalidate): Move it to detached_regcache::invalidate.
12424 (get_thread_arch_aspace_regcache): Update.
12425 (regcache::raw_update): Update.
12426 (regcache::cooked_read): Remove some code.
12427 (regcache::cooked_read_value): Likewise.
12428 (regcache::raw_write): Remove assert on m_readonly_p.
12429 (regcache::raw_supply_integer): Move it to
12430 detached_regcache::raw_supply_integer.
12431 (regcache::raw_supply_zeroed): Likewise.
12432 * regcache.h (detached_regcache) <raw_supply_integer>: New
12434 <raw_supply_zeroed, invalidate>: Likewise.
12435 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
12436 <invalidate>: Likewise.
12437 <m_readonly_p>: Removed.
12439 2018-02-21 Yao Qi <yao.qi@linaro.org>
12441 * infcmd.c (get_return_value): Let stop_regs point to
12442 get_current_regcache.
12443 * regcache.c (regcache::regcache): Remove.
12444 (register_dump_reg_buffer): New class.
12445 (regcache_print): Adjust.
12446 * regcache.h (regcache): Remove constructors.
12448 2018-02-21 Yao Qi <yao.qi@linaro.org>
12450 * regcache.c (class register_dump): New class.
12451 (register_dump_regcache, register_dump_none): New class.
12452 (register_dump_remote, register_dump_groups): New class.
12453 (regcache_print): Update.
12454 * regcache.h (regcache_dump_what): Move it to regcache.c.
12455 (regcache) <dump>: Remove.
12457 2018-02-21 Yao Qi <yao.qi@linaro.org>
12459 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
12461 (jit_unwind_reg_set_impl): Call raw_supply.
12462 (jit_frame_sniffer): Use reg_buffer_rw.
12463 * record-full.c (record_full_core_regbuf): Change its type.
12464 (record_full_core_open_1): Use reg_buffer_rw.
12465 (record_full_close): Likewise.
12466 (record_full_core_fetch_registers): Use regcache->raw_supply.
12467 (record_full_core_store_registers): Likewise.
12468 * regcache.c (regcache::get_register_status): Move it to
12470 (regcache_raw_set_cached_value): Remove.
12471 (regcache::raw_set_cached_value): Remove.
12472 (regcache::raw_write): Call raw_supply.
12473 (regcache::raw_supply): Move it to reg_buffer_rw.
12474 * regcache.h (regcache_raw_set_cached_value): Remove.
12475 (reg_buffer_rw): New class.
12477 2018-02-21 Yao Qi <yao.qi@linaro.org>
12479 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
12480 readonly_detached_regcache.
12481 (dummy_frame_prev_register): Use regcache->cooked_read.
12482 * frame.c (frame_save_as_regcache): Change return type.
12483 (frame_pop): Update.
12484 * frame.h (frame_save_as_regcache): Update declaration.
12485 * inferior.h (get_infcall_suspend_state_regcache): Update
12487 * infrun.c (infcall_suspend_state) <registers>: use
12488 readonly_detached_regcache.
12489 (save_infcall_suspend_state): Don't use regcache_dup.
12490 (get_infcall_suspend_state_regcache): Change return type.
12491 * linux-fork.c (struct fork_info) <savedregs>: Change to
12492 readonly_detached_regcache.
12494 (fork_save_infrun_state): Don't use regcache_dup.
12495 (info_checkpoints_command): Adjust.
12496 * mi/mi-main.c (register_changed_p): Update declaration.
12497 (mi_cmd_data_list_changed_registers): Use
12498 readonly_detached_regcache.
12499 (register_changed_p): Change parameter type to
12500 readonly_detached_regcache.
12501 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
12502 readonly_detached_regcache.
12503 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
12504 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
12506 (regcache::save): Move it to reg_buffer.
12507 (regcache::restore): Change parameter type.
12508 (regcache_dup): Remove.
12509 * regcache.h (reg_buffer) <save>: New method.
12510 (readonly_detached_regcache): New class.
12511 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
12512 readonly_detached_regcache.
12513 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
12515 2018-02-21 Yao Qi <yao.qi@linaro.org>
12517 * frame.c (frame_save_as_regcache): Use regcache method save.
12518 (frame_pop): Use regcache method restore.
12519 * infrun.c (restore_infcall_suspend_state): Likewise.
12520 * linux-fork.c (fork_load_infrun_state): Likewise.
12521 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
12523 * regcache.c (regcache_save): Remove.
12524 (regcache::restore): More asserts.
12525 (regcache_cpy): Remove.
12526 * regcache.h (regcache_save): Remove the declaration.
12527 (regcache::restore): Move from private to public.
12528 Remove the friend declaration of regcache_cpy.
12529 (regcache_cpy): Remove declaration.
12531 2018-02-21 Yao Qi <yao.qi@linaro.org>
12533 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
12534 parameter type to 'readable_regcache *'.
12535 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12536 * arm-tdep.c (arm_neon_quad_read): Likewise.
12537 (arm_pseudo_read): Likewise.
12538 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12539 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12540 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12541 * gdbarch.c: Re-generated.
12542 * gdbarch.h: Re-generated.
12543 * gdbarch.sh (pseudo_register_read): Change parameter type to
12544 'readable_regcache *'.
12545 (pseudo_register_read_value): Likewise.
12546 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
12547 (h8300_pseudo_register_read): Likewise.
12548 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
12549 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12550 (i386_pseudo_register_read_into_value): Likewise.
12551 (i386_pseudo_register_read_value): Likewise.
12552 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
12554 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
12555 * m32c-tdep.c (m32c_raw_read): Likewise.
12556 (m32c_read_flg): Likewise.
12557 (m32c_banked_register): Likewise.
12558 (m32c_banked_read): Likewise.
12559 (m32c_sb_read): Likewise.
12560 (m32c_part_read): Likewise.
12561 (m32c_cat_read): Likewise.
12562 (m32c_r3r2r1r0_read): Likewise.
12563 (m32c_pseudo_register_read): Likewise.
12564 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12565 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12566 (mep_pseudo_cr64_read): Likewise.
12567 (mep_pseudo_register_read): Likewise.
12568 * mips-tdep.c (mips_pseudo_register_read): Likewise.
12569 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12570 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12571 * regcache.c (regcache::raw_read): Move it to readable_regcache.
12572 (regcache::cooked_read): Likewise.
12573 (regcache::cooked_read_value): Likewise.
12574 (regcache_cooked_read_signed):
12575 (regcache::cooked_read): Likewise.
12576 * regcache.h (readable_regcache): New class.
12577 (regcache): Inherit readable_regcache. Move some methods to
12579 * rl78-tdep.c (rl78_pseudo_register_read): Change
12580 parameter type to 'readable_regcache *'.
12581 * rs6000-tdep.c (do_regcache_raw_read): Remove.
12582 (e500_pseudo_register_read): Change parameter type to
12583 'readable_regcache *'.
12584 (dfp_pseudo_register_read): Likewise.
12585 (vsx_pseudo_register_read): Likewise.
12586 (efpr_pseudo_register_read): Likewise.
12587 * s390-tdep.c (s390_pseudo_register_read): Likewise.
12588 * sh-tdep.c (sh_pseudo_register_read): Likewise.
12589 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
12590 (sh64_pseudo_register_read): Likewise.
12591 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12592 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12593 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12594 (spu_pseudo_register_read): Likewise.
12595 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12596 (xtensa_pseudo_register_read): Likewise.
12598 2018-02-21 Yao Qi <yao.qi@linaro.org>
12600 * regcache.c (regcache::regcache): Call reg_buffer ctor.
12601 (regcache::arch): Move it to reg_buffer::arch.
12602 (regcache::register_buffer): Likewise.
12603 (regcache::assert_regnum): Likewise.
12604 (regcache::num_raw_registers): Likewise.
12605 * regcache.h (reg_buffer): New class.
12606 (regcache): Inherit reg_buffer.
12608 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
12610 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
12611 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
12613 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
12615 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
12617 2018-02-19 Alan Hayward <alan.hayward@arm.com>
12619 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
12620 (SFILES): Remove common/*.c files.
12621 (COMMON_OBS): Remove some *.o files built from common/*.c files.
12622 * common/common.host: Add common reference.
12623 * configure.ac: Likewise.
12624 * configure: Regenerate.
12626 2018-02-16 Yao Qi <yao.qi@linaro.org>
12628 * block.c (block_namespace_info): Inherit allocate_on_obstack.
12629 (block_initialize_namespace): Use new.
12630 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
12631 (dwarf2_free_objfile): Use delete.
12632 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
12633 (copy_type_recursive): Use new.
12634 * gdb_obstack.h (allocate_on_obstack): New.
12636 2018-02-15 Yao Qi <yao.qi@linaro.org>
12639 * inferior.c (exit_inferior_1): Reset inf->control.
12641 2018-02-15 Joel Brobecker <brobecker@adacore.com>
12643 * ada-lang.c (ada_to_fixed_value_create): Delete advance
12646 2018-02-14 Pedro Alves <palves@redhat.com>
12648 * frame-unwind.c (frame_unwind_try_unwinder): Always call
12649 frame_cleanup_after_sniffer on exception.
12651 2018-02-14 Tom Tromey <tom@tromey.com>
12653 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
12655 (solib_bfd_open): Make pathname const.
12656 * solib.c (solib_bfd_open): Make pathname const.
12657 * solib-spu.c (spu_bfd_fopen): Make name const.
12658 (spu_bfd_open): Make pathname const.
12659 * solib-darwin.c (darwin_bfd_open): Make pathname const.
12660 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
12662 2018-02-14 Tom Tromey <tom@tromey.com>
12664 * symfile.c (symfile_bfd_open): Update.
12665 * source.h (openp, source_full_path_of, find_and_open_source):
12666 Change argument type to unique_xmalloc_ptr.
12667 * source.c (openp): Take a unique_xmalloc_ptr.
12668 (source_full_path_of, find_and_open_source): Likewise.
12669 (open_source_file, symtab_to_fullname): Update.
12670 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
12671 unique_xmalloc_ptr.
12672 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
12673 (exec_file_find): Update.
12674 * psymtab.c (psymtab_to_fullname): Update.
12675 * nto-tdep.h (nto_find_and_open_solib): Update.
12676 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
12677 unique_xmalloc_ptr.
12678 * exec.c (exec_file_attach): Update.
12679 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
12680 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
12682 2018-02-14 Tom Tromey <tom@tromey.com>
12684 * solib.c: Include source.h.
12685 * nto-tdep.c: Include source.h.
12686 * mi/mi-cmd-env.c: Include source.h.
12687 * infcmd.c: Include source.h.
12688 * exec.c: Include source.h.
12689 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
12690 (add_path, directory_switch, source_path, init_source_path): Move
12692 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
12693 (add_path, directory_switch, source_path, init_source_path):
12696 2018-02-14 Tom Tromey <tom@tromey.com>
12698 * solist.h (exec_file_find, solib_find): Return
12699 unique_xmalloc_ptr.
12700 (solib_bfd_fopen): Take a const char *.
12701 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
12702 (exec_file_find, solib_find): Likewise.
12703 (solib_bfd_fopen): Do not take ownership of "pathname".
12704 (solib_bfd_open): Use unique_xmalloc_ptr.
12705 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
12706 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
12707 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
12708 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
12710 2018-02-14 Joel Brobecker <brobecker@adacore.com>
12712 * ada-lang.c (name_match_type_from_name): Remove reference to
12713 ada_name_for_lookup in function's documentation.
12714 * ada-lang.h (ada_name_for_lookup): Delete declaration.
12716 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12718 * defs.h (enum openp_flags): New enum.
12719 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
12720 Move to enum openp_flags.
12721 (openp_flags): New enum flags.
12722 (openp): Change parameter type to openp_flags.
12723 * source.c (openp): Change parameter type to openp_flags.
12724 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
12725 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
12727 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12729 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
12732 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
12734 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
12736 (class dwarf2_queue_guard): ...the destructor of this new class.
12737 (dw2_do_instantiate_symtab): Create instance of the new class
12738 dwarf2_queue_guard, remove cleanup.
12740 2018-02-09 Tom Tromey <tom@tromey.com>
12742 * source.c (find_source_lines): Don't reference past the end of
12745 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12747 * remote.c (remote_btrace_maybe_reopen): Change error message.
12748 * btrace.c (btrace_enable): Likewise.
12749 (parse_xml_btrace): Likewise.
12750 (parse_xml_btrace_conf): Likewise.
12752 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12754 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
12755 (linux_enable_pt, linux_enable_bts): Call
12756 diagnose_perf_event_open_fail.
12758 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12760 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12761 Remove parameter and change return type. Update callers. Move it.
12762 (linux_enable_bts, linux_enable_pt): Improve error message.
12763 (linux_enable_pt): Remove zero buffer size check.
12764 (linux_enable_btrace): Improve error messages. Remove NULL return
12767 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12769 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12770 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12771 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12772 (linux_supports_pt, linux_supports_btrace): Remove.
12773 (linux_enable_bts): Call cpu_supports_bts.
12774 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12775 * remote.c (remote_supports_btrace): Remove.
12776 (init_remote_ops): Remove remote_supports_btrace.
12777 * target-delegates.c: Regenerated.
12778 * target.c (target_supports_btrace): Remove.
12779 * target.h (target_ops) <to_supports_btrace>: Remove
12780 (target_supports_btrace): Remove.
12781 * x86-linux-nat.c (x86_linux_create_target): Remove
12782 linux_supports_btrace.
12784 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12786 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12788 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12789 exception and use message in own exception.
12791 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12793 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
12794 (perf_event_pt_event_type): Use gdb_file_up.
12795 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
12796 scoped_fd, and scoped_mmap.
12798 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12800 * common/scoped_mmap.h: New.
12801 * unittests/scoped_mmap-selftest.c: New.
12802 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12803 unittests/scoped_mmap-selftest.c.
12805 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12807 * common/scoped_fd.h: New.
12808 * unittests/scoped_fd-selftest.c: New.
12809 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12810 unittests/scoped_fd-selftest.c.
12812 2018-02-09 Tom Tromey <tom@tromey.com>
12814 * auto-load.c (auto_load_section_scripts): Use
12815 gdb::unique_xmalloc_ptr.
12817 2018-02-09 Tom Tromey <tom@tromey.com>
12819 * auto-load.c (execute_script_contents): Use std::string.
12821 2018-02-09 Joel Brobecker <brobecker@adacore.com>
12823 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
12824 Python function, rather than a new command.
12826 2018-02-08 Tom Tromey <tom@tromey.com>
12828 * solib.c (solib_find_1): Use std::string.
12829 (solib_bfd_fopen): Use unique_xmalloc_ptr.
12831 2018-02-08 Tom Tromey <tom@tromey.com>
12833 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
12835 2018-02-08 Tom Tromey <tom@tromey.com>
12837 * source.c (find_source_lines): Use gdb::def_vector.
12839 2018-02-08 Tom Tromey <tom@tromey.com>
12841 * macrocmd.c (struct temporary_macro_definition): New.
12842 (macro_define_command): Use temporary_macro_definition. Remove
12844 (free_macro_definition_ptr): Remove.
12846 2018-02-08 Tom Tromey <tom@tromey.com>
12848 * macroexp.c (maybe_expand): Use std::string.
12850 2018-02-08 Tom Tromey <tom@tromey.com>
12852 * macroexp.c (struct macro_buffer): Add initializers for some
12854 (init_buffer, init_shared_buffer, free_buffer)
12855 (free_buffer_return_text): Remove.
12856 (macro_buffer): New constructors.
12857 (~macro_buffer): New destructor.
12858 (macro_buffer::set_shared): New method.
12859 (macro_buffer::resize_buffer, macro_buffer::appendc)
12860 (macro_buffer::appendmem): Now methods, not free functions.
12861 (set_token, append_tokens_without_splicing, stringify)
12862 (macro_stringify): Update.
12863 (gather_arguments): Change return type. Remove argc_p argument,
12864 add args_ptr argument. Use std::vector.
12865 (substitute_args): Remove argc argument. Accept std::vector.
12866 (expand): Update. Use std::vector.
12867 (scan, macro_expand, macro_expand_next): Update.
12869 2018-02-08 Tom Tromey <tom@tromey.com>
12871 * symtab.c (default_collect_symbol_completion_matches_break_on):
12872 Use unique_xmalloc_ptr.
12873 * macroscope.h: (sal_macro_scope, user_macro_scope)
12874 (default_macro_scope): Return unique_xmalloc_ptr.
12875 * macroscope.c (sal_macro_scope, user_macro_scope)
12876 (default_macro_scope): Return unique_xmalloc_ptr.
12877 * macroexp.h (macro_expand, macro_expand_once): Return
12878 unique_xmalloc_ptr.
12879 * macroexp.c (macro_expand, macro_expand_once): Return
12880 unique_xmalloc_ptr.
12881 * macrocmd.c (macro_expand_command, macro_expand_once_command)
12882 (info_macro_command, info_macros_command): Use
12883 unique_xmalloc_ptr.
12884 * compile/compile-c-support.c (write_macro_definitions): Use
12885 unique_xmalloc_ptr.
12886 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
12888 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
12890 * value.c (value_static_field): Assign field type instead of
12891 containing type when returning an optimized out value.
12893 2018-02-06 Yao Qi <yao.qi@linaro.org>
12895 * ft32-tdep.c (ft32_read_pc): Remove.
12896 (ft32_write_pc): Remove.
12897 (ft32_gdbarch_init): Update.
12898 * m32r-tdep.c (m32r_read_pc): Remove.
12899 (m32r_gdbarch_init): Update.
12900 * mep-tdep.c (mep_read_pc): Remove.
12901 (mep_gdbarch_init): Update.
12902 * microblaze-tdep.c (microblaze_write_pc): Remove.
12903 (microblaze_gdbarch_init): Update.
12904 * mn10300-tdep.c (mn10300_read_pc): Remove.
12905 (mn10300_write_pc): Remove.
12906 (mn10300_gdbarch_init): Update.
12907 * moxie-tdep.c (moxie_read_pc): Remove.
12908 (moxie_write_pc): Remove.
12909 (moxie_gdbarch_init): Update.
12911 2018-02-06 Yao Qi <yao.qi@linaro.org>
12913 * expprint.c (print_subexp_standard): Handle
12914 OP_F77_UNDETERMINED_ARGLIST.
12915 (dump_subexp_body_standard): Likewise.
12917 2018-02-05 Alan Hayward <alan.hayward@arm.com>
12919 * target-descriptions.c (tdesc_element_visitor) Add empty
12921 (tdesc_type): Move make_gdb_type from here.
12922 (tdesc_type_builtin): Likewise.
12923 (tdesc_type_vector): Likewise.
12924 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
12925 (make_gdb_type_struct): Move from tdesc_type_with_fields.
12926 (make_gdb_type_union): Likewise.
12927 (make_gdb_type_flags): Likewise.
12928 (make_gdb_type_enum): Likewise.
12929 (make_gdb_type): New function.
12930 (tdesc_register_type): Use static make_gdb_type.
12932 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
12934 * infcmd.c (default_print_one_register_info): Align natural-format
12935 column values consistently one under another.
12936 (pad_to_column): New function.
12938 2018-02-05 Joel Brobecker <brobecker@adacore.com>
12940 * dwarf2read.c (dwarf2_physname): Move commment.
12942 2018-02-01 Leszek Swirski <leszeks@google.com>
12944 * varobj.c (varobj_formatted_print_options): Allow recursive
12945 pretty printing if pretty printing is enabled.
12947 2018-02-01 Leszek Swirski <leszeks@google.com>
12949 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12950 names after a structop as a filename.
12952 2018-02-01 Yao Qi <yao.qi@linaro.org>
12954 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12955 (arm_record_coproc_data_proc): Likewise.
12957 2018-02-01 Yao Qi <yao.qi@linaro.org>
12959 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12961 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12963 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12964 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12966 2018-01-31 Pedro Alves <palves@redhat.com>
12968 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12969 * inflow.c (child_terminal_save_inferior): Wrap reference to
12970 tcgetpgrp in HAVE_TERMIOS_H.
12971 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12973 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12974 always iterate over all inferiors.
12975 (gdbsim_cntrl_c): Adjust.
12976 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12978 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12980 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12981 index type is objfile-owned if the element type is as well.
12983 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12987 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12989 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12990 "features/s390x-linux64.c".
12991 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12992 s390_linux32 and s390x_linux64.
12993 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12995 * s390-tdep.c: Include "features/s390-linux32.c" and
12996 "features/s390x-linux64.c".
12997 (s390_tdesc_valid): Add check for tdesc_has_registers.
12998 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12999 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
13000 tdesc_s390x_linux64.
13001 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
13002 tdesc_s390x_linux64 to...
13003 * s390-tdep.h: ...here.
13005 2018-01-30 Pedro Alves <palves@redhat.com>
13008 * config.in, configure: Regenerate.
13009 * configure.ac: Check for getpgid.
13010 * go32-nat.c (go32_pass_ctrlc): New.
13011 (go32_target): Install it.
13012 * inf-child.c (inf_child_target): Install
13013 child_terminal_save_inferior, child_pass_ctrlc and
13015 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
13016 (inf_ptrace_target): No longer install it.
13017 * infcmd.c (interrupt_target_1): Adjust.
13018 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
13019 (child_interrupt): Declare.
13020 (inferior::terminal_state): New.
13021 * inflow.c (struct terminal_info): Update comments.
13022 (inferior_process_group): Delete.
13023 (terminal_is_ours): Delete.
13024 (gdb_tty_state): New.
13025 (child_terminal_init): Adjust.
13026 (is_gdb_terminal, sharing_input_terminal_1)
13027 (sharing_input_terminal): New functions.
13028 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
13029 Set the process's actual process group in the foreground if
13030 possible. Handle is_ours_for_output/is_ours distinction. Don't
13031 mark terminal as the inferior's if not sharing GDB's terminal.
13032 Don't check attach_flag.
13033 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
13034 pass down a target_terminal_state.
13035 (child_terminal_save_inferior): New, factored out from ...
13036 (child_terminal_ours_1): ... this. Handle
13037 target_terminal_state::is_ours_for_output.
13038 (child_interrupt, child_pass_ctrlc): New.
13039 (inflow_inferior_exit): Clear the inferior's terminal_state.
13040 (copy_terminal_info): Copy the inferior's terminal state.
13041 (_initialize_inflow): Remove reference to terminal_is_ours.
13042 * inflow.h (inferior_process_group): Delete.
13043 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
13044 * procfs.c (procfs_target): Don't install procfs_interrupt.
13045 (procfs_interrupt): Delete.
13046 * remote.c (remote_serial_quit_handler): Adjust.
13047 (remote_interrupt): Remove ptid parameter. Adjust.
13048 * target-delegates.c: Regenerate.
13049 * target.c: Include "terminal.h".
13050 (target_terminal::terminal_state): Rename to ...
13051 (target_terminal::m_terminal_state): ... this.
13052 (target_terminal::init): Adjust.
13053 (target_terminal::inferior): Adjust to per-inferior
13055 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
13056 (target_terminal::ours, target_terminal::ours_for_output): Use
13057 target_terminal_is_ours_kind.
13058 (target_interrupt): Remove ptid parameter. Adjust.
13059 (default_target_pass_ctrlc): Adjust.
13060 * target.h (target_ops::to_terminal_save_inferior): New field.
13061 (target_ops::to_interrupt): Remove ptid_t parameter.
13062 (target_interrupt): Remove ptid_t parameter. Update comment.
13063 (target_pass_ctrlc): Update comment.
13064 * target/target.h (target_terminal_state): New scoped enum,
13065 factored out of ...
13066 (target_terminal::terminal_state): ... here.
13067 (target_terminal::inferior): Update comments.
13068 (target_terminal::restore_inferior): New.
13069 (target_terminal::is_inferior, target_terminal::is_ours)
13070 (target_terminal::is_ours_for_output): Adjust.
13071 (target_terminal::scoped_restore_terminal_state): Adjust to
13072 rename, and call restore_inferior() instead of inferior().
13073 (target_terminal::scoped_restore_terminal_state::m_state): Change
13075 (target_terminal::terminal_state): Rename to ...
13076 (target_terminal::m_terminal_state): ... this and change type.
13078 2018-01-30 Pedro Alves <palves@redhat.com>
13080 * linux-nat.c (wait_for_signal): New function.
13081 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
13083 (async_terminal_is_ours)
13084 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
13085 (linux_nat_add_target): Don't override
13086 to_terminal_inferior/to_terminal_ours.
13088 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
13090 * remote.c (remote_follow_fork): Don't call "detach_inferior".
13092 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
13094 * dwarf2read.c (free_dwo_files): Add forward-declaration.
13095 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
13096 dwarf2_per_objfile_free here.
13097 (dwarf2_per_objfile_free): Remove.
13098 (_initialize_dwarf2_read): Don't register
13099 dwarf2_per_objfile_free as a registry cleanup.
13101 2018-01-27 Eli Zaretskii <eliz@gnu.org>
13103 Avoid compilation errors in MinGW native builds
13105 The error is triggered by including python-internal.h, and the
13108 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
13109 from build-gnulib/import/math.h:27,
13110 from d:/usr/Python26/include/pyport.h:235,
13111 from d:/usr/Python26/include/Python.h:58,
13112 from python/python-internal.h:94,
13113 from python/py-arch.c:24:
13114 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
13118 This happens because Python headers define 'hypot' to expand t
13119 '_hypot' in the Windows builds.
13120 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
13121 'hypoth'. This avoids a compilation error.
13123 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13125 * MAINTAINERS (Write After Approval): Fix ordering.
13127 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13129 * MAINTAINERS (Write After Approval): Add Alan Hayward.
13131 2018-01-26 Alan Modra <amodra@gmail.com>
13133 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
13134 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
13135 Remove nop. Make const. Comment.
13136 (powerpc32_plt_stub_so_2): New.
13137 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
13138 Correct count. Update uses.
13139 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
13140 Move common code reading PLT entry word. Correct
13141 powerpc32_plt_stub PLT address calculation.
13142 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
13143 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
13144 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
13145 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
13146 (ppc64_standard_linkage8): Likewise.
13147 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
13148 Correct insns description.
13149 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
13151 2018-01-24 Pedro Alves <palves@redhat.com>
13153 GCC PR libstdc++/83906
13154 * gdbtypes.c (operator==(const dynamic_prop &,
13155 const dynamic_prop &)): New.
13156 (operator==(const range_bounds &, const range_bounds &)): New.
13157 (check_types_equal): Use them instead of memcmp.
13158 * gdbtypes.h (operator==(const dynamic_prop &,
13159 const dynamic_prop &)): Declare.
13160 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
13161 (operator==(const range_bounds &, const range_bounds &)): Declare.
13162 (operator!=(const range_bounds &, const range_bounds &)): Declare.
13164 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13166 * s390-linux-tdep.c (s390_record_address_mask)
13167 (s390_record_calc_disp_common, s390_record_calc_disp)
13168 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13169 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13170 (s390_process_record): Move to s390-tdep.c.
13171 (s390_linux_init_abi_any): Adjust.
13172 * s390-tdep.c (s390_record_address_mask)
13173 (s390_record_calc_disp_common, s390_record_calc_disp)
13174 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13175 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13176 (s390_process_record): Moved from s390-linux-tdep.c
13177 (s390_gdbarch_init): Adjust.
13179 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13181 * s390-linux-nat.c (s390-tdep.h): New include.
13182 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
13183 (HFILES_NO_SRCDIR): Add s390-tdep.h.
13184 (ALLDEPFILES): Add s390-tdep.c.
13185 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
13186 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
13187 * s390-tdep.h: ...this. New file.
13188 * s390-linux-tdep.c (s390-tdep.h): New include.
13189 (_initialize_s390_tdep): Rename to...
13190 (_initialize_s390_linux_tdep): ...this and adjust.
13191 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
13192 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
13194 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
13195 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
13196 (s390_is_partial_instruction, s390_software_single_step)
13197 (is_non_branch_ril, s390_displaced_step_copy_insn)
13198 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
13199 (s390_prologue_data, s390_addr, s390_store, s390_load)
13200 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
13201 (s390_register_call_saved, s390_guess_tracepoint_registers)
13202 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
13203 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
13204 (s390_pseudo_register_name, s390_pseudo_register_type)
13205 (s390_pseudo_register_read, s390_pseudo_register_write)
13206 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
13207 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
13208 (s390_addr_bits_remove, s390_address_class_type_flags)
13209 (s390_address_class_type_flags_to_name)
13210 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
13211 (s390_function_arg_float, s390_function_arg_vector)
13212 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
13213 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
13214 (s390_frame_align, s390_register_return_value, s390_return_value)
13215 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
13216 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
13217 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
13218 (s390_trad_frame_prev_register, s390_unwind_cache)
13219 (s390_prologue_frame_unwind_cache)
13220 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
13221 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
13222 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
13223 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
13224 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
13225 (s390_frame_base_address, s390_local_base_address)
13226 (s390_frame_base, s390_gcc_target_options)
13227 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
13228 (s390_validate_reg_range, s390_tdesc_valid)
13229 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
13230 * s390-tdep.c: ...this. New file.
13232 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13234 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
13235 (s390_process_record, s390_gdbarch_tdep_alloc)
13236 (s390_linux_init_abi_any): Use/set new hook.
13238 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13240 * s390-linux-tdep.c (osabi.h): New include.
13241 (s390_linux_init_abi_31, s390_linux_init_abi_64)
13242 (s390_linux_init_abi_any): New functions.
13243 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
13245 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13247 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
13248 tdesc_has_registers check
13250 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13252 * s390-linux-tdep.c (s390_tdesc_valid): New function.
13253 (s390_validate_reg_range): New macro.
13254 (s390_gdbarch_init): Adjust.
13256 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13258 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
13259 (s390_gdbarch_tdep_alloc): Adjust.
13260 (s390_gdbarch_init): Adjust.
13262 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13264 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
13265 <have_tdb>: Change type to bool.
13266 (s390_gdbarch_tdep_alloc): Adjust.
13267 (s390_gdbarch_init): Adjust.
13269 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13271 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
13272 (gdbarch_tdep) <have_upper, have_vx>: New fields.
13273 (s390_gdbarch_tdep_alloc): New function.
13274 (s390_gdbarch_init): Allocate tdep at start and use its fields
13275 instead of separate variables.
13277 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13279 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
13280 when looking for cached gdbarch and add comment for remaining.
13282 2018-01-22 Pedro Alves <palves@redhat.com>
13283 Sergio Durigan Junior <sergiodj@redhat.com>
13285 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
13288 2018-01-22 Maciej W. Rozycki <macro@mips.com>
13290 * MAINTAINERS: Update my company e-mail address.
13292 2018-01-22 Yao Qi <yao.qi@linaro.org>
13294 * regcache.c (cooked_write_test): New function.
13295 (_initialize_regcache): Register the test.
13297 2018-01-22 Yao Qi <yao.qi@linaro.org>
13299 * ia64-tdep.c (ia64_pseudo_register_read): Call
13300 regcache->cooked_read instead of regcache_cooked_read_unsigned.
13301 * m32c-tdep.c (m32c_cat_read): Likewise.
13302 (m32c_r3r2r1r0_read): Likewise.
13303 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
13304 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
13306 2018-01-22 Yao Qi <yao.qi@linaro.org>
13308 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
13309 method raw_read instead of regcache_raw_read.
13310 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
13311 * arm-tdep.c (arm_neon_quad_read): Likewise.
13312 * avr-tdep.c (avr_pseudo_register_read): Likewise.
13313 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
13314 * frv-tdep.c (frv_pseudo_register_read): Likewise.
13315 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
13316 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
13317 (i386_pseudo_register_read_into_value): Likewise.
13318 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
13319 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
13320 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
13321 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
13322 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
13323 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
13324 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
13325 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
13326 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
13328 2018-01-22 Yao Qi <yao.qi@linaro.org>
13330 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
13331 * configure.tgt: Remove target mt.
13332 * mt-tdep.c: Remove.
13333 * regcache.c (cooked_read_test): Remove the check for mt.
13335 2018-01-22 Yao Qi <yao.qi@linaro.org>
13337 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
13338 instead of gdbarch_pseudo_register_read_value.
13340 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13342 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
13345 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13347 * linespec.c (create_sals_line_offset): Remove code that preserved
13348 the symtab_and_line's line number.
13350 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13352 * varobj.c (varobj_create): Don't set valid_block when creating a
13355 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13357 * varobj.c (varobj_create): Remove out of date comment.
13359 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13362 * ada-exp.y (write_var_from_sym): Pass extra parameter when
13363 updating innermost block.
13364 * parse.c (innermost_block_tracker::update): Take extra type
13365 parameter, and check types match before updating innermost block.
13366 (write_dollar_variable): Update innermost block for registers.
13367 * parser-defs.h (enum innermost_block_tracker_type): New enum.
13368 (innermost_block_tracker::innermost_block_tracker): Initialise
13370 (innermost_block_tracker::reset): Take type parameter.
13371 (innermost_block_tracker::update): Take type parameter, and pass
13372 type through as needed.
13373 (innermost_block_tracker::m_types): New member.
13374 * varobj.c (varobj_create): Pass type when reseting innermost
13377 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13379 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
13380 * ada-lang.c (resolve_subexp): Likewise.
13381 * breakpoint.c (set_breakpoint_condition) Likewise.
13382 (watch_command_1) Likewise.
13383 * c-exp.y (variable): Likewise.
13384 * d-exp.y (PrimaryExpression): Likewise.
13385 * f-exp.y (variable): Likewise.
13386 * go-exp.y (variable): Likewise.
13387 * m2-exp.y (variable): Likewise.
13388 * objfiles.c (objfile::~objfile): Likewise.
13389 * p-exp.y (variable): Likewise.
13390 * parse.c (innermost_block): Change type.
13391 * parser-defs.h (class innermost_block_tracker): New.
13392 (innermost_block): Change to innermost_block_tracker.
13393 * printcmd.c (display_command): Switch to innermost_block API.
13394 (do_one_display): Likewise.
13395 * rust-exp.y (do_one_display): Likewise.
13396 * symfile.c (clear_symtab_users): Likewise.
13397 * varobj.c (varobj_create): Switch to innermost_block API, replace
13398 use of innermost_block with block stored on varobj object.
13400 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13402 * expression.h (innermost_block): Remove declaration.
13403 * varobj.c: Add 'parser-defs.h' include.
13405 2018-01-19 Tom Tromey <tom@tromey.com>
13407 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
13408 symbols in the static and global blocks.
13410 2018-01-19 James Clarke <jrtc27@jrtc27.com>
13412 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
13413 gdb_ptrace.h, and move including gdb_wait.h ...
13414 * nat/linux-ptrace.h: ... to here.
13416 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13418 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
13419 inf_ptrace_detach_success.
13420 (inf_ptrace_detach_success): Add inferior parameter, use it
13421 instead of inferior_ptid, pass it to detach_inferior.
13422 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
13424 * inferior.c (detach_inferior): Add overload that takes an
13426 * inferior.h (detach_inferior): Likewise.
13427 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
13428 use inferior_ptid, adjust call to inf_ptrace_detach_success.
13429 * linux-thread-db.c (thread_db_detach): Use inf parameter.
13431 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13433 * target.h (struct target_ops) <to_detach>: Add inferior
13435 (target_detach): Likewise.
13436 * target.c (dispose_inferior): Pass inferior down.
13437 (target_detach): Pass inferior down. Assert that it is equal to
13438 the current inferior.
13439 * aix-thread.c (aix_thread_detach): Pass inferior down.
13440 * corefile.c (core_file_command): Pass current_inferior() down.
13441 * corelow.c (core_detach): Add inferior parameter.
13442 * darwin-nat.c (darwin_detach): Likewise.
13443 * gnu-nat.c (gnu_detach): Likewise.
13444 * inf-ptrace.c (inf_ptrace_detach): Likewise.
13445 * infcmd.c (detach_command): Pass current_inferior() down to
13447 * infrun.c (follow_fork_inferior): Pass parent_inf to
13449 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
13451 * linux-nat.c (linux_nat_detach): Add inferior parameter.
13452 * linux-thread-db.c (thread_db_detach): Likewise.
13453 * nto-procfs.c (procfs_detach): Likewise.
13454 * procfs.c (procfs_detach): Likewise.
13455 * record.c (record_detach): Likewise.
13456 * record.h (struct inferior): Forward-declare.
13457 (record_detach): Add inferior parameter.
13458 * remote-sim.c (gdbsim_detach): Likewise.
13459 * remote.c (remote_detach_1): Likewise.
13460 (remote_detach): Likewise.
13461 (extended_remote_detach): Likewise.
13462 * sol-thread.c (sol_thread_detach): Likewise.
13463 * target-debug.h (target_debug_print_inferior_p): New macro.
13464 * target-delegates.c: Re-generate.
13465 * top.c (kill_or_detach): Pass inferior down to target_detach.
13466 * windows-nat.c (windows_detach): Add inferior parameter.
13468 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13470 * target.h (struct target_ops) <to_detach>: Remove args
13472 (target_detach): Likewise.
13473 * target.c (dispose_inferior): Adjust.
13474 (target_detach): Remove args parameter, adjust.
13475 * aix-thread.c (aix_thread_detach): Adjust.
13476 * corefile.c (core_file_command): Adjust.
13477 * corelow.c (core_detach): Adjust.
13478 * darwin-nat.c (darwin_detach): Adjust.
13479 * gnu-nat.c (gnu_detach): Adjust.
13480 * inf-ptrace.c (inf_ptrace_detach): Adjust.
13481 * infcmd.c (detach_command): Adjust
13482 * infrun.c (follow_fork_inferior): Adjust.
13483 (handle_vfork_child_exec_or_exit): Adjust.
13484 * linux-fork.c (linux_fork_detach): Remove args parameter.
13485 * linux-fork.h (linux_fork_detach): Likewise.
13486 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
13487 * linux-thread-db.c (thread_db_detach): Likewise.
13488 * nto-procfs.c (procfs_detach): Likewise.
13489 * procfs.c (procfs_detach): Likewise.
13490 (do_detach): Remove signo parameter.
13491 * record.c (record_detach): Remove args parameter.
13492 * record.h (record_detach): Likewise.
13493 * remote-sim.c (gdbsim_detach): Likewise.
13494 * remote.c (remote_detach_1): Likewise.
13495 (remote_detach): Likewise.
13496 (extended_remote_detach): Likewise.
13497 * sol-thread.c (sol_thread_detach): Likewise.
13498 * target-delegates.c: Re-generate.
13499 * top.c (struct qt_args) <args>: Remove field.
13500 (kill_or_detach): Don't pass args.
13501 (quit_force): Don't set args.
13502 * windows-nat.c (windows_detach): Remove args parameter.
13504 2018-01-19 Yao Qi <yao.qi@linaro.org>
13506 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
13507 (arm_linux_init_abi): Install it.
13509 2018-01-19 Yao Qi <yao.qi@linaro.org>
13511 * osabi.c (gdb_osabi_names): Extend the regexp for
13512 arm-linux-gnueabihf.
13514 2018-01-18 Yao Qi <yao.qi@linaro.org>
13516 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
13518 (abbrev_table::add_abbrev): Update.
13519 (abbrev_table::lookup_abbrev): Update.
13521 2018-01-18 Yao Qi <yao.qi@linaro.org>
13523 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
13525 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
13527 * compile/compile.c (compile_to_object): Convert "triplet_rx"
13530 2018-01-17 Tom Tromey <tom@tromey.com>
13532 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
13534 2018-01-17 Tom Tromey <tom@tromey.com>
13536 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
13537 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
13538 (create_array_type_with_stride): Update.
13539 * dwarf2read.c (set_die_type): Update.
13541 2018-01-17 Tom Tromey <tom@tromey.com>
13543 * dwarf2read.c (delayed_method_info): Remove typedef.
13544 (dwarf2_cu::method_info): Now a std::vector.
13545 (add_to_method_list): Update.
13546 (free_delayed_list): Remove.
13547 (compute_delayed_physnames): Update.
13548 (process_full_comp_unit, process_full_type_unit): Clear the method
13549 list. Remove cleanups.
13550 (psymtab_include_file_name): Add name_holder parameter. Use
13551 unique_xmalloc_ptr.
13552 (dwarf_decode_lines): Update.
13554 2018-01-17 Tom Tromey <tom@tromey.com>
13555 Simon Marchi <simon.marchi@ericsson.com>
13557 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
13558 (dwarf2_per_objfile::free_cached_comp_units)
13559 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13560 (init_cutu_and_read_dies_no_follow): Update.
13561 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
13562 (dwarf2_cu::~dwarf2_cu): New.
13563 (free_heap_comp_unit, free_stack_comp_unit): Remove.
13564 (age_cached_comp_units, free_one_cached_comp_unit): Update.
13566 2018-01-17 Tom Tromey <tom@tromey.com>
13567 Simon Marchi <simon.marchi@ericsson.com>
13569 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
13570 (struct die_reader_specs) <abbrev_table>: New member.
13571 (struct abbrev_table): Add constructor.
13572 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
13573 <abbrev_obstack>: Now an auto_obstack.
13574 (abbrev_table_up): New typedef.
13575 (init_cu_die_reader): Add abbrev_table parameter.
13576 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
13577 Add result_dwo_abbrev_table.
13578 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13579 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
13581 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
13583 (skip_children): Update.
13584 (abbrev_table::alloc_abbrev): Rename from
13585 abbrev_table_alloc_abbrev.
13586 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
13587 (abbrev_table::lookup_abbrev): Rename from
13588 abbrev_table_lookup_abbrev.
13589 (abbrev_table_read_table): Return abbrev_table_up.
13590 (abbrev_table_free, abbrev_table_free_cleanup)
13591 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
13592 (load_partial_dies): Update.
13594 2018-01-17 Tom Tromey <tom@tromey.com>
13596 * dwarf2read.c (dwarf2_compute_name): Update comment.
13597 (read_func_scope, read_variable): Update.
13598 (new_symbol): Remove.
13599 (new_symbol_full): Rename to new_symbol.
13601 2018-01-17 Mike Gulick <mgulick@mathworks.com>
13604 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
13605 a warning instead of throwing an error, set section size to 0 and return
13607 * gdb_bfd.h (gdb_bfd_map_section): Update description.
13609 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13611 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
13613 (linux_ptrace_attach_fail_reason_string): Likewise.
13614 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
13616 (linux_ptrace_attach_fail_reason_string): Likewise.
13617 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
13619 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13621 * linux-nat.c (linux_nat_attach): Remove xstrdup.
13623 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
13626 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
13627 checking for fs_base/gs_base fields in struct user_regs_struct.
13628 * configure: Regenerate.
13630 2018-01-17 Yao Qi <yao.qi@linaro.org>
13632 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
13634 (aarch64_linux_init_abi): Install it to gdbarch hook
13635 gcc_target_options.
13637 2018-01-15 Pedro Alves <palves@redhat.com>
13639 * common/signals-state-save-restore.c
13640 (save_original_signals_state): Fix typos.
13642 2017-01-12 Tom Tromey <tom@tromey.com>
13643 Sergio Durigan Junior <sergiodj@redhat.com>
13645 * Makefile.in (install-only): Install gdb-add-index.
13647 2018-01-12 John Baldwin <jhb@FreeBSD.org>
13649 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
13651 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
13653 * infrun.c (keep_going_pass_signal): Clear step-over info when
13654 insert_breakpoints fails.
13656 2018-01-11 Pedro Alves <palves@redhat.com>
13659 * infrun.c (resume): Rename to ...
13660 (resume_1): ... this.
13661 (resume): Reimplement as wrapper around resume_1.
13663 2018-01-11 Pedro Alves <palves@redhat.com>
13666 * remote.c (remote_parse_stop_reply): Default to the last-set
13667 general thread instead of to 'magic_null_ptid'.
13669 2018-01-10 Pedro Alves <palves@redhat.com>
13671 * language.h (language_get_symbol_name_matcher): Rename ...
13672 (get_symbol_name_matcher): ... this.
13673 * language.c (language_get_symbol_name_matcher): Ditto.
13674 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
13677 2018-01-10 Pedro Alves <palves@redhat.com>
13681 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
13682 Adjust to use language_get_symbol_name_matcher instead of
13683 language_defn::la_get_symbol_name_matcher.
13684 * language.c (language_get_symbol_name_matcher): If in Ada mode
13685 and the lookup name is a verbatim match, return Ada's matcher.
13686 * language.h (language_get_symbol_name_matcher): Adjust comment.
13687 (ada_lookup_name_info::verbatim_p):: New method.
13689 2018-01-10 Pedro Alves <palves@redhat.com>
13692 * ada-lang.c (ada_collect_symbol_completion_matches): If the
13693 minsym's language is language_auto or language_cplus, pass down
13694 language_ada instead.
13695 * symtab.c (compare_symbol_name): Don't frob symbol language here.
13697 2018-01-10 Pedro Alves <palves@redhat.com>
13700 * minsyms.c (linkage_name_str): New function.
13701 (iterate_over_minimal_symbols): Use it.
13703 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13705 * NEWS: Document that 'info proc' now works on FreeBSD.
13707 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13709 * configure.ac: Check for kinfo_getfile in libutil.
13710 * configure: Regenerate.
13711 * config.in: Regenerate.
13712 * fbsd-nat.c: Include "fbsd-tdep.h".
13713 (fbsd_fetch_cmdline): New.
13714 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
13715 rather than calling error.
13716 (fbsd_info_proc): New.
13717 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
13718 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
13719 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
13721 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13723 * fbsd-nat.c (struct free_deleter): Remove.
13724 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
13726 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13728 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
13729 NULL for an empty pathname.
13731 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13733 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
13734 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
13735 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
13736 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
13737 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
13738 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
13739 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
13740 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
13741 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
13742 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
13743 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
13744 (fbsd_core_fetch_timeval, fbsd_print_sigset)
13745 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
13746 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
13747 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
13749 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
13751 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
13752 (gnu_xfer_auxv): New function.
13753 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
13754 TARGET_OBJECT_AUXV.
13756 2018-01-08 Yao Qi <yao.qi@linaro.org>
13757 Simon Marchi <simon.marchi@ericsson.com>
13759 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13761 (COMMON_OBS): Remove selftest.o.
13762 * configure.ac: Append selftest-arch.c and common/selftest.c to
13763 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13764 * configure: Re-generated.
13765 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13767 (maintenance_info_selftests): Likewise.
13769 2018-01-08 Xavier Roirand <roirand@adacore.com>
13771 * ada-valprint.c (val_print_packed_array_elements): Use
13772 proper number of elements when printing an array indexed
13773 by an enumeration type.
13775 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13777 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13778 (dw2_get_file_names_reader): Adjust.
13779 (lookup_dwo_signatured_type): Adjust.
13780 (lookup_dwp_signatured_type): Adjust.
13781 (lookup_signatured_type): Adjust.
13782 (create_type_unit_group): Adjust.
13783 (get_type_unit_group): Adjust.
13784 (process_psymtab_comp_unit_reader): Adjust.
13785 (build_type_psymtabs_reader): Adjust.
13786 (scan_partial_symbols): Adjust.
13787 (add_partial_symbol): Adjust.
13788 (add_partial_subprogram): Adjust.
13789 (peek_die_abbrev): Adjust.
13790 (fixup_go_packaging): Adjust.
13791 (process_imported_unit_die): Adjust.
13792 (dwarf2_compute_name): Adjust.
13793 (dwarf2_physname): Adjust.
13794 (read_import_statement): Adjust.
13795 (handle_DW_AT_stmt_list): Adjust.
13796 (read_file_scope): Adjust.
13797 (read_func_scope): Adjust.
13798 (read_lexical_block_scope): Adjust.
13799 (read_call_site_scope): Adjust.
13800 (read_variable): Adjust.
13801 (dwarf2_rnglists_process): Adjust.
13802 (dwarf2_ranges_process): Adjust.
13803 (dwarf2_ranges_read): Adjust.
13804 (dwarf2_get_pc_bounds): Adjust.
13805 (dwarf2_record_block_ranges): Adjust.
13806 (dwarf2_add_field): Adjust.
13807 (dwarf2_add_member_fn): Adjust.
13808 (read_structure_type): Adjust.
13809 (process_structure_scope): Adjust.
13810 (read_enumeration_type): Adjust.
13811 (read_array_type): Adjust.
13812 (mark_common_block_symbol_computed): Adjust.
13813 (read_common_block): Adjust.
13814 (read_namespace_type): Adjust.
13815 (read_namespace): Adjust.
13816 (read_module_type): Adjust.
13817 (read_tag_pointer_type): Adjust.
13818 (read_tag_ptr_to_member_type): Adjust.
13819 (read_tag_string_type): Adjust.
13820 (read_subroutine_type): Adjust.
13821 (read_typedef): Adjust.
13822 (read_base_type): Adjust.
13823 (attr_to_dynamic_prop): Adjust.
13824 (read_subrange_type): Adjust.
13825 (read_unspecified_type): Adjust.
13826 (dwarf2_read_abbrevs): Adjust.
13827 (load_partial_dies): Adjust.
13828 (read_partial_die): Adjust.
13829 (find_partial_die): Adjust.
13830 (guess_partial_die_structure_name): Adjust.
13831 (fixup_partial_die): Adjust.
13832 (read_attribute_value): Adjust.
13833 (read_addr_index): Adjust.
13834 (read_addr_index_from_leb128): Adjust.
13835 (read_str_index): Adjust.
13836 (dwarf2_string_attr): Adjust.
13837 (get_debug_line_section): Adjust.
13838 (dwarf_decode_line_header): Adjust.
13839 (lnp_state_machine::check_line_address): Adjust.
13840 (dwarf_decode_lines_1): Adjust.
13841 (dwarf_decode_lines): Adjust.
13842 (dwarf2_start_symtab): Adjust.
13843 (var_decode_location): Adjust.
13844 (new_symbol_full): Adjust.
13845 (dwarf2_const_value_data): Adjust.
13846 (dwarf2_const_value_attr): Adjust.
13847 (dwarf2_const_value): Adjust.
13848 (die_type): Adjust.
13849 (die_containing_type): Adjust.
13850 (build_error_marker_type): Adjust.
13851 (lookup_die_type): Adjust.
13852 (guess_full_die_structure_name): Adjust.
13853 (anonymous_struct_prefix): Adjust.
13854 (determine_prefix): Adjust.
13855 (dwarf2_name): Adjust.
13856 (follow_die_ref_or_sig): Adjust.
13857 (follow_die_offset): Adjust.
13858 (follow_die_ref): Adjust.
13859 (follow_die_sig_1): Adjust.
13860 (follow_die_sig): Adjust.
13861 (get_signatured_type): Adjust.
13862 (get_DW_AT_signature_type): Adjust.
13863 (decode_locdesc): Adjust.
13864 (dwarf_decode_macros): Adjust.
13865 (cu_debug_loc_section): Adjust.
13866 (fill_in_loclist_baton): Adjust.
13867 (dwarf2_symbol_mark_computed): Adjust.
13868 (init_one_comp_unit): Don't assign
13869 dwarf2_cu::dwarf2_per_objfile.
13870 (set_die_type): Adjust.
13872 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13874 * dwarf2read.c (struct mapped_debug_names): Add constructor.
13875 <dwarf2_per_objfile>: New field.
13876 (dwarf2_per_objfile): Remove global.
13877 (get_dwarf2_per_objfile): New function.
13878 (set_dwarf2_per_objfile): New function.
13879 (dwarf2_build_psymtabs_hard): Change objfile parameter to
13880 dwarf2_per_objfile.
13881 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13882 (read_abbrev_offset): Likewise.
13883 (read_indirect_string): Likewise.
13884 (read_indirect_line_string): Likewise.
13885 (read_indirect_string_at_offset): Likewise.
13886 (read_indirect_string_from_dwz): Likewise.
13887 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13888 dwarf2_per_objfile.
13889 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13890 (create_all_comp_units): Change objfile parameter to
13891 dwarf2_per_objfile.
13892 (create_all_type_units): Likewise.
13893 (process_queue): Add dwarf2_per_objfile parameter.
13894 (read_and_check_comp_unit_head): Likewise.
13895 (lookup_dwo_unit_in_dwp): Likewise.
13896 (get_dwp_file): Likewise.
13897 (process_cu_includes): Likewise.
13898 (struct free_dwo_file_cleanup_data): New struct.
13899 (dwarf2_has_info): Use get_dwarf2_per_objfile and
13900 set_dwarf2_per_objfile.
13901 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
13902 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
13903 context, adjust calls.
13904 (dw2_instantiate_symtab): Likewise.
13905 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
13906 (dw2_get_cu): Likewise.
13907 (create_cu_from_index_list): Change objfile parameter to
13908 dwarf2_per_objfile.
13909 (create_cus_from_index_list): Get dwarf2_per_objfile from
13910 context, adjust calls.
13911 (create_cus_from_index): Likewise.
13912 (create_signatured_type_table_from_index): Change objfile
13913 parameter to dwarf2_per_objfile.
13914 (create_signatured_type_table_from_debug_names): Change objfile
13915 parameter to dwarf2_per_objfile.
13916 (create_addrmap_from_index): Likewise.
13917 (create_addrmap_from_aranges): Likewise.
13918 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
13919 (dw2_setup): Remove.
13920 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
13922 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
13923 get_dwarf2_per_objfile.
13924 (dw2_forget_cached_source_info): Likewise.
13925 (dw2_map_symtabs_matching_filename): Likewise.
13926 (struct dw2_symtab_iterator) <index>: Remove.
13927 <dwarf2_per_objfile>: New field.
13928 (dw2_symtab_iter_init): Replace index parameter with
13929 dwarf2_per_objfile.
13930 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
13931 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
13932 (dw2_print_stats): Likewise.
13933 (dw2_dump): Likewise.
13934 (dw2_expand_symtabs_for_function): Likewise.
13935 (dw2_expand_all_symtabs): Likewise.
13936 (dw2_expand_symtabs_with_fullname): Likewise.
13937 (dw2_expand_marked_cus): Replace index and objfile parameters
13938 with dwarf2_per_objfile.
13939 (dw_expand_symtabs_matching_file_matcher): Add
13940 dwarf2_per_objfile parameter and adjust calls.
13941 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13943 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13944 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13946 (create_cus_from_debug_names_list): Replace objfile parameter
13947 with dwarf2_per_objfile and adjust calls.
13948 (create_cus_from_debug_names): Likewise.
13949 (dwarf2_read_debug_names): Likewise.
13950 (mapped_debug_names::namei_to_name): Adjust call.
13951 (dw2_debug_names_iterator::next): Likewise.
13952 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13953 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13954 (dw2_debug_names_dump): Likewise.
13955 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13956 (dw2_debug_names_expand_symtabs_matching): Likewise.
13957 (dwarf2_initialize_objfile): Likewise.
13958 (dwarf2_build_psymtabs): Likewise.
13959 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13961 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13962 (read_and_check_comp_unit_head): Likewise.
13963 (read_abbrev_offset): Likewise.
13964 (create_debug_type_hash_table): Likewise.
13965 (create_debug_types_hash_table): Likewise.
13966 (create_all_type_units): Replace objfile parameter with
13967 dwarf2_per_objfile.
13968 (add_type_unit): Add dwarf2_per_objfile parameter.
13969 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13970 with dwarf2_per_objfile.
13971 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13972 (lookup_dwp_signatured_type): Likewise.
13973 (lookup_signatured_type): Likewise.
13974 (read_cutu_die_from_dwo): Likewise.
13975 (init_tu_and_read_dwo_dies): Likewise.
13976 (init_cutu_and_read_dies): Likewise.
13977 (init_cutu_and_read_dies_no_follow): Likewise.
13978 (allocate_type_unit_groups_table): Add objfile parameter.
13979 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13980 (get_type_unit_group): Likewise.
13981 (process_psymtab_comp_unit): Update call.
13982 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13983 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13984 (print_tu_stats): Likewise.
13985 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13986 in void* parameter.
13987 (build_type_psymtabs): Change objfile parameter to
13988 dwarf2_per_objfile.
13989 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13990 passed in void* parameter.
13991 (process_skeletonless_type_units): Change objfile parameter to
13992 dwarf2_per_objfile.
13993 (set_partial_user): Likewise.
13994 (dwarf2_build_psymtabs_hard): Likewise.
13995 (read_comp_units_from_section): Likewise.
13996 (create_all_comp_units): Likewise.
13997 (scan_partial_symbols): Update calls.
13998 (add_partial_symbol): Likewise.
13999 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
14000 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
14001 (process_queue): Add dwarf2_per_objfile parameter.
14002 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
14003 (compute_compunit_symtab_includes): Likewise.
14004 (process_cu_includes): Add dwarf2_per_objfile parameter.
14005 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
14006 (process_full_type_unit): Likewise.
14007 (process_imported_unit_die): Update call.
14008 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
14009 (read_file_scope): Likewise.
14010 (allocate_dwo_file_hash_table): Add objfile parameter.
14011 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
14012 (create_cus_hash_table): Likewise.
14013 (create_dwp_hash_table): Likewise.
14014 (create_dwo_unit_in_dwp_v1): Likewise.
14015 (create_dwp_v2_section): Likewise.
14016 (create_dwo_unit_in_dwp_v2): Likewise.
14017 (lookup_dwo_unit_in_dwp): Likewise.
14018 (try_open_dwop_file): Likewise.
14019 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
14020 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
14021 cleanup to include a reference to dwarf2_per_objfile.
14022 (open_dwp_file): Add dwarf2_per_objfile parameter.
14023 (open_and_init_dwp_file): Likewise.
14024 (get_dwp_file): Likewise.
14025 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
14026 (queue_and_load_all_dwo_tus): Update call.
14027 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
14029 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
14030 (dwarf2_ranges_process): Likewise.
14031 (dwarf2_get_pc_bounds): Likewise.
14032 (mark_common_block_symbol_computed): Likewise.
14033 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14034 (dwarf2_read_abbrevs): Update call.
14035 (read_partial_die): Use dwarf2_per_objfile from cu.
14036 (find_partial_die): Likewise.
14037 (fixup_partial_die): Likewise.
14038 (read_attribute_value): Likewise.
14039 (read_indirect_string_at_offset_from): Add objfile parameter.
14040 (read_indirect_string_at_offset): Add dwarf2_per_objfile
14042 (read_indirect_string_from_dwz): Add objfile parameter.
14043 (read_indirect_string): Add objfile parameter.
14044 (read_addr_index_1): Add dwarf2_per_objfile parameter.
14045 (read_addr_index): Use dwarf2_per_objfile from cu.
14046 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
14048 (read_str_index): Use dwarf2_per_objfile from cu.
14049 (get_debug_line_section): Likewise.
14050 (read_formatted_entries): Add dwarf2_per_objfile parameter.
14051 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
14052 (new_symbol_full): Use dwarf2_per_objfile from cu.
14053 (build_error_marker_type): Likewise.
14054 (lookup_die_type): Likewise.
14055 (determine_prefix): Likewise.
14056 (follow_die_offset): Likewise.
14057 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
14058 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
14059 (dwarf2_fetch_die_type_sect_off): Likewise.
14060 (dwarf2_get_die_type): Likewise.
14061 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
14062 (get_signatured_type): Likewise.
14063 (get_DW_AT_signature_type): Likewise.
14064 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
14065 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
14066 (cu_debug_loc_section): Likewise.
14067 (fill_in_loclist_baton): Likewise.
14068 (dwarf2_symbol_mark_computed): Likewise.
14069 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14070 dwarf2_per_objfile.
14071 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
14073 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14074 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
14075 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
14076 (set_die_type): Use dwarf2_free_objfile from cu.
14077 (get_die_type_at_offset): Likewise.
14078 (dwarf2_per_objfile_free): Don't assign global variable.
14079 (debug_names) <constructor>: Add dwarf2_per_objfile
14080 parameter, update m_debugstrlookup construction.
14081 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
14083 <m_dwarf2_per_objfile>: New field.
14084 <lookup>: Use m_dwarf2_per_objfile.
14085 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
14086 (psyms_seen_size): Likewise.
14087 (write_gdbindex): Replace objfile parameter with
14088 dwarf2_per_objfile.
14089 (write_debug_names): Likewise.
14090 (write_psymtabs_to_index): Likewise.
14091 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
14094 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14096 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
14097 <dwarf2_per_objfile>: New field.
14098 (struct dwarf2_per_cu_data) <objfile>: Remove.
14099 <dwarf2_per_objfile>: New field.
14100 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
14102 (create_signatured_type_table_from_index): Likewise.
14103 (create_debug_type_hash_table): Likewise.
14104 (fill_in_sig_entry_from_dwo_entry): Likewise.
14105 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
14106 (create_type_unit_group): Assign dwarf2_per_objfile instead of
14108 (create_partial_symtab): Access objfile through
14109 dwarf2_per_objfile.
14110 (process_psymtab_comp_unit_reader): Likewise.
14111 (read_comp_units_from_section): Likewise.
14112 (scan_partial_symbols): Likewise.
14113 (add_partial_symbol): Likewise.
14114 (add_partial_subprogram): Likewise.
14115 (peek_die_abbrev): Likewise.
14116 (fixup_go_packaging): Likewise.
14117 (process_full_comp_unit): Likewise.
14118 (process_full_type_unit): Likewise.
14119 (process_imported_unit_die): Likewise.
14120 (dwarf2_compute_name): Likewise.
14121 (dwarf2_physname): Likewise.
14122 (read_import_statement): Likewise.
14123 (create_cus_hash_table): Assign dwarf2_physname instead of
14125 (read_func_scope): Access objfile through dwarf2_per_objfile.
14126 (read_lexical_block_scope): Likewise.
14127 (read_call_site_scope): Likewise.
14128 (read_variable): Likewise.
14129 (dwarf2_rnglists_process): Likewise.
14130 (dwarf2_ranges_process): Likewise.
14131 (dwarf2_ranges_read): Likewise.
14132 (dwarf2_record_block_ranges): Likewise.
14133 (dwarf2_add_field): Likewise.
14134 (dwarf2_add_member_fn): Likewise.
14135 (read_structure_type): Likewise.
14136 (process_structure_scope): Likewise.
14137 (read_enumeration_type): Likewise.
14138 (read_array_type): Likewise.
14139 (read_common_block): Likewise.
14140 (read_namespace_type): Likewise.
14141 (read_namespace): Likewise.
14142 (read_module_type): Likewise.
14143 (read_tag_pointer_type): Likewise.
14144 (read_tag_ptr_to_member_type): Likewise.
14145 (read_tag_string_type): Likewise.
14146 (read_subroutine_type): Likewise.
14147 (read_typedef): Likewise.
14148 (read_base_type): Likewise.
14149 (attr_to_dynamic_prop): Likewise.
14150 (read_subrange_type): Likewise.
14151 (read_unspecified_type): Likewise.
14152 (load_partial_dies): Likewise.
14153 (read_partial_die): Likewise.
14154 (find_partial_die): Likewise.
14155 (guess_partial_die_structure_name): Likewise.
14156 (fixup_partial_die): Likewise.
14157 (read_attribute_value): Likewise.
14158 (read_addr_index_from_leb128): Likewise.
14159 (dwarf2_read_addr_index): Likewise.
14160 (dwarf2_string_attr): Likewise.
14161 (lnp_state_machine::check_line_address): Likewise.
14162 (dwarf_decode_lines_1): Likewise.
14163 (dwarf_decode_lines): Likewise.
14164 (dwarf2_start_symtab): Likewise.
14165 (var_decode_location): Likewise.
14166 (new_symbol_full): Likewise.
14167 (dwarf2_const_value_data): Likewise.
14168 (dwarf2_const_value_attr): Likewise.
14169 (dwarf2_const_value): Likewise.
14170 (die_type): Likewise.
14171 (die_containing_type): Likewise.
14172 (lookup_die_type): Likewise.
14173 (guess_full_die_structure_name): Likewise.
14174 (anonymous_struct_prefix): Likewise.
14175 (dwarf2_name): Likewise.
14176 (follow_die_ref_or_sig): Likewise.
14177 (follow_die_offset): Likewise.
14178 (follow_die_ref): Likewise.
14179 (dwarf2_fetch_die_loc_sect_off): Likewise.
14180 (dwarf2_fetch_constant_bytes): Likewise.
14181 (dwarf2_fetch_die_type_sect_off): Likewise.
14182 (dwarf2_get_die_type): Likewise.
14183 (follow_die_sig): Likewise.
14184 (decode_locdesc): Likewise.
14185 (dwarf2_per_cu_objfile): Likewise.
14186 (dwarf2_per_cu_text_offset): Likewise.
14187 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
14189 (set_die_type): Access objfile through
14190 dwarf2_per_objfile.
14192 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14194 * valprint.c (converted_character_d): Remove typedef.
14195 (DEF_VEC_O (converted_character_d)): Remove.
14196 (count_next_character): Use std::vector.
14197 (print_converted_chars_to_obstack): Likewise.
14198 (generic_printstr): Likewise.
14200 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14202 * xml-support.h (struct gdb_xml_value): Add constructor.
14203 <value>: Change type to unique_xmalloc_ptr.
14204 (gdb_xml_value_s): Remove typedef.
14205 (DEF_VEC_O (gdb_xml_value_s)): Remove.
14206 (gdb_xml_element_start_handler): Change parameter type to
14208 (xml_find_attribute): Likewise.
14209 * xml-support.c (xml_find_attribute): Change parameter type to
14210 std::vector and adjust.
14211 (gdb_xml_values_cleanup): Remove.
14212 (gdb_xml_parser::start_element): Adjust to std::vector.
14213 (xinclude_start_include): Change paraeter type to std::vector
14215 * btrace.c (check_xml_btrace_version): Likewise.
14216 (parse_xml_btrace_block): Likewise.
14217 (parse_xml_btrace_pt_config_cpu): Likewise.
14218 (parse_xml_btrace_pt): Likewise.
14219 (parse_xml_btrace_conf_bts): Likewise.
14220 (parse_xml_btrace_conf_pt): Likewise.
14221 * memory-map.c (memory_map_start_memory): Likewise.
14222 (memory_map_start_property): Likewise.
14223 * osdata.c (osdata_start_osdata): Likewise.
14224 (osdata_start_item): Likewise.
14225 (osdata_start_column): Likewise.
14226 * remote.c (start_thread): Likewise.
14227 * solib-aix.c (library_list_start_library): Likewise.
14228 (library_list_start_list): Likewise.
14229 * solib-svr4.c (library_list_start_library): Likewise.
14230 (svr4_library_list_start_list): Likewise.
14231 * solib-target.c (library_list_start_segment): Likewise.
14232 (library_list_start_section): Likewise.
14233 (library_list_start_library): Likewise.
14234 (library_list_start_list): Likewise.
14235 * tracepoint.c (traceframe_info_start_memory): Likewise.
14236 (traceframe_info_start_tvar): Likewise.
14237 * xml-syscall.c (syscall_start_syscall): Likewise.
14238 * xml-tdesc.c (tdesc_start_target): Likewise.
14239 (tdesc_start_feature): Likewise.
14240 (tdesc_start_reg): Likewise.
14241 (tdesc_start_union): Likewise.
14242 (tdesc_start_struct): Likewise.
14243 (tdesc_start_flags): Likewise.
14244 (tdesc_start_enum): Likewise.
14245 (tdesc_start_field): Likewise.
14246 (tdesc_start_enum_value): Likewise.
14247 (tdesc_start_vector): Likewise.
14249 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14251 * extension.h (struct xmethod_worker) <clone>: Remove.
14252 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
14254 (python_xmethod_worker::clone): Remove.
14255 * valops.c (find_overload_match): Use std::move instead of
14258 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14260 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
14261 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
14262 <free_xmethod_worker_data>: Remove.
14263 <get_matching_xmethod_workers>: Chance VEC to std::vector.
14264 <get_xmethod_arg_types>: Remove.
14265 <get_xmethod_result_type>: Remove.
14266 <invoke_xmethod>: Remove.
14267 * extension.c (new_xmethod_worker): Remove.
14268 (clone_xmethod_worker): Remove.
14269 (get_matching_xmethod_workers): Return void, pass std::vector by
14271 (get_xmethod_arg_types): Rename to...
14272 (xmethod_worker::get_arg_types): ... this, and adjust.
14273 (get_xmethod_result_type): Rename to...
14274 (xmethod_worker::get_result_type): ... this, and adjust.
14275 (invoke_xmethod): Remove.
14276 (free_xmethod_worker): Remove.
14277 (free_xmethod_worker_vec): Remove.
14278 * extension.h (enum ext_lang_rc): Move here from
14280 (struct xmethod_worker): Add constructor and destructor.
14283 <invoke, clone, do_get_result_type, do_get_arg_types>: New
14284 virtual pure methods.
14285 <get_arg_types, get_result_type>: New methods.
14286 (xmethod_worker_ptr): Remove typedef.
14287 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
14288 (xmethod_worker_vec): Remove typedef.
14289 (xmethod_worker_up): New typedef.
14290 (invoke_xmethod): Remove.
14291 (clone_xmethod_worker): Remove.
14292 (free_xmethod_worker): Remove.
14293 (free_xmethod_worker_vec): Remove.
14294 (get_xmethod_arg_types): Remove.
14295 (get_xmethod_result_type): Remove.
14296 * valops.c (find_method_list): Use std::vector, don't use
14297 intermediate vector.
14298 (value_find_oload_method_list): Use std::vector.
14299 (find_overload_match): Use std::vector.
14300 (find_oload_champ): Use std::vector.
14301 * value.c (value_free): Use operator delete.
14302 (value_of_xmethod): Rename to...
14303 (value_from_xmethod): ... this. Don't assign
14304 xmethod_worker::value, take rvalue-reference.
14305 (result_type_of_xmethod): Adjust.
14306 (call_xmethod): Adjust.
14307 * value.h: Include extension.h.
14308 (struct xmethod_worker): Don't forward-declare.
14309 (value_of_xmethod): Rename to...
14310 (value_from_xmethod): ... this, take rvalue-reference.
14311 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
14312 (struct python_xmethod_worker): ... this, add constructor and
14314 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
14315 (gdbpy_free_xmethod_worker_data): Rename to...
14316 (python_xmethod_worker::~python_xmethod_worker): ... this and
14318 (gdbpy_clone_xmethod_worker_data): Rename to...
14319 (python_xmethod_worker::clone): ... this and adjust.
14320 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
14322 (gdbpy_get_xmethod_arg_types): Rename to...
14323 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
14324 (gdbpy_get_xmethod_result_type): Rename to...
14325 (python_xmethod_worker::do_get_result_type): ... this and
14327 (gdbpy_invoke_xmethod): Rename to...
14328 (python_xmethod_worker::invoke): ... this and adjust.
14329 (new_python_xmethod_worker): Rename to...
14330 (python_xmethod_worker::python_xmethod_worker): ... this and
14332 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
14334 (gdbpy_free_xmethod_worker_data): Remove.
14335 (gdbpy_get_matching_xmethod_workers): Use std::vector.
14336 (gdbpy_get_xmethod_arg_types): Remove.
14337 (gdbpy_get_xmethod_result_type): Remove.
14338 (gdbpy_invoke_xmethod): Remove.
14339 * python/python.c (python_extension_ops): Remove obsolete
14342 2018-01-05 Pedro Alves <palves@redhat.com>
14345 * common/signals-state-save-restore.c
14346 (save_original_signals_state): New parameter 'quiet'. Warn if we
14347 find a custom handler preinstalled, instead of internal erroring.
14348 But only warn if !quiet.
14349 * common/signals-state-save-restore.h
14350 (save_original_signals_state): New parameter 'quiet'.
14351 * main.c (captured_main_1): Move save_original_signals_state call
14352 after option handling, and pass QUIET.
14354 2018-01-05 Pedro Alves <palves@redhat.com>
14356 * spu-tdep.c (spu_catch_start): Pass
14357 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
14359 2018-01-05 Pedro Alves <palves@redhat.com>
14362 * ada-lang.c (literal_symbol_name_matcher): New function.
14363 (ada_get_symbol_name_matcher): Use it for
14364 symbol_name_match_type::SEARCH_NAME.
14365 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
14366 it down instead of assuming symbol_name_match_type::FULL.
14367 * block.h (block_lookup_symbol): New parameter 'match_type'.
14368 * c-valprint.c (print_unpacked_pointer): Use
14369 lookup_symbol_search_name instead of lookup_symbol.
14370 * compile/compile-object-load.c (get_out_value_type): Pass down
14371 symbol_name_match_type::SEARCH_NAME.
14372 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
14373 symbol_name_match_type::FULL.
14374 * cp-support.c (cp_get_symbol_name_matcher): Handle
14375 symbol_name_match_type::SEARCH_NAME.
14376 * infrun.c (insert_exception_resume_breakpoint): Use
14377 lookup_symbol_search_name.
14378 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
14379 * psymtab.c (maintenance_check_psymtabs): Use
14380 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
14381 * stack.c (print_frame_args): Use lookup_symbol_search_name and
14382 SYMBOL_SEARCH_NAME.
14383 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
14384 if symbol_name_match_type::SEARCH_NAME.
14385 (lookup_symbol_in_language): Pass down
14386 symbol_name_match_type::FULL.
14387 (lookup_symbol_search_name): New.
14388 (lookup_language_this): Pass down
14389 symbol_name_match_type::SEARCH_NAME.
14390 (lookup_symbol_aux, lookup_local_symbol): New parameter
14391 'match_type'. Pass it down.
14392 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
14393 (lookup_symbol_search_name): New declaration.
14394 (lookup_symbol_in_block): New 'match_type' parameter.
14396 2018-01-05 Pedro Alves <palves@redhat.com>
14399 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
14401 (ada_lookup_symbol): Reimplement in terms of
14402 ada_lookup_symbol_list, bits factored out from
14403 ada_lookup_encoded_symbol.
14405 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14407 * ada-exp.y (write_object_renaming): When subscripting an array
14408 using a symbol as the index, pass the block in call to
14409 ada_lookup_encoded_symbol when looking that symbol up.
14411 2018-01-05 Jerome Guitton <guitton@adacore.com>
14413 * ada-lang.c (ada_array_length): Use ada_index_type instead of
14416 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14418 * ada-lang.c (ada_to_fixed_value_create): Add handling of
14419 the case where VALUE_LVAL (val0) is not lval_memory.
14421 2018-01-05 Xavier Roirand <roirand@adacore.com>
14423 * ada-valprint.c (print_optional_low_bound): Handle
14424 character-indexed array printing like boolean-indexed array
14427 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14429 * NEWS: Create a new section for the next release branch.
14430 Rename the section of the current branch, now that it has
14433 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14435 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
14436 * version.in: Bump version to 8.1.50.DATE-git.
14438 2018-01-03 Xavier Roirand <roirand@adacore.com>
14440 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
14442 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
14444 (default_exception_support_info) <catch_handlers_sym>: Add field.
14445 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
14446 (ada_exception_name_addr_1): Add "catch handlers" handling.
14447 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
14448 Update all callers.
14449 (create_excep_cond_exprs) <ex>: Add parameter.
14450 (re_set_exception): Update create_excep_cond_exprs call.
14451 (print_it_exception, print_one_exception, print_mention_exception)
14452 (print_recreate_exception): Add "catch handler" handling.
14453 (allocate_location_catch_handlers, re_set_catch_handlers)
14454 (check_status_catch_handlers, print_it_catch_handlers)
14455 (print_one_catch_handlers, print_mention_catch_handlers)
14456 (print_recreate_catch_handlers): New function.
14457 (catch_handlers_breakpoint_ops): New variable.
14458 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
14459 Add parameter. Add "catch handler" handling.
14460 (ada_exception_sym_name, ada_exception_breakpoint_ops):
14461 Add "catch handler" handling.
14462 (ada_exception_catchpoint_cond_string): Add "catch handler"
14464 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
14466 (catch_ada_handlers_command): New function.
14467 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
14468 operations structure.
14469 (_initialize_ada_language): Add "catch handlers" command entry.
14470 * NEWS: Document "catch handlers" feature.
14472 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14474 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
14475 account when creating the array type of the slice.
14476 (ada_value_slice): Likewise.
14478 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14480 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
14482 (create_array_type_with_stride): Add byte_stride_prop parameter.
14483 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
14484 New parameter. Update all callers in this file.
14485 (array_type_has_dynamic_stride): New function.
14486 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
14487 of arrays with dynamic byte strides.
14488 * dwarf2read.c (read_array_type): Add support for dynamic
14489 DW_AT_byte_stride attributes.
14491 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14493 * dwarf2read.c (read_unspecified_type): Treat
14494 DW_TAG_enumeration_type DIEs from Ada units as stubs.
14496 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14498 Update copyright year range in all GDB files.
14500 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
14502 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
14503 and gdb/testsuite/gdb.base/step-line.c.
14505 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14507 * copyright.py (main): Dump the contents of
14508 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
14509 even if BY_HAND is empty.
14511 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14513 * top.c (print_gdb_version): Update Copyright year in version
14516 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14518 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
14520 For older changes see ChangeLog-2017.
14526 version-control: never