1 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2 Simon Marchi <simark@simark.ca>
4 * README (`configure' options): Add documentation for new
5 "--enable-unit-tests" option.
6 * acinclude.m4: Include "selftest.m4".
7 * configure: Regenerate.
8 * configure.ac: Use "GDB_AC_SELFTEST".
9 * maint.c (maintenance_selftest): Update message informing
10 that selftests have been disabled.
11 (maintenance_info_selftests): Likewise.
12 * selftest.m4: New file.
14 2018-10-10 Gary Benson <gbenson@redhat.com>
16 * remote.c (remote_target::remote_send_printf): Add
17 missing va_end found by Coverity.
19 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
21 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
23 2018-10-09 Tom Tromey <tom@tromey.com>
26 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
27 * NEWS: Update --enable-ubsan documentation.
29 2018-10-09 Gary Benson <gbenson@redhat.com>
31 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
34 2018-10-08 Tom Tromey <tom@tromey.com>
36 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
38 (riscv_fbsd_init_abi): Likewise.
40 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
41 * valops.c (value_struct_elt_for_reference): Rename local variable
42 to work around the shadowing a previous local warning.
44 2018-10-08 John Baldwin <jhb@FreeBSD.org>
46 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
47 * NEWS: Mention new FreeBSD/riscv native configuration.
48 * configure.host: Add riscv*-*-freebsd*.
49 * configure.nat: Likewise.
50 * riscv-fbsd-nat.c: New file.
52 2018-10-08 John Baldwin <jhb@FreeBSD.org>
54 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
55 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
56 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
57 * NEWS: Mention new FreeBSD/riscv target.
58 * configure.tgt: Add riscv*-*-freebsd*.
59 * riscv-fbsd-tdep.c: New file.
60 * riscv-fbsd-tdep.h: New file.
62 2018-10-08 John Baldwin <jhb@FreeBSD.org>
64 * regcache.h (struct regcache_map_entry): Note that this type can
65 be used with traditional frame caches.
66 * trad-frame.c (trad_frame_set_reg_regmap): New.
67 * trad-frame.h (trad_frame_set_reg_regmap): New.
69 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
72 * valops.c (get_virtual_base_offset): New function.
73 (value_struct_elt_for_reference): Use it to get virtual base offset
74 and add it in calculating class member address.
76 2018-10-08 John Darrington <john@darrington.wattle.id.au>
78 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
79 (check_producer): Check if the producer is codewarrior.
80 (producer_is_codewarrior): New function.
81 (lnp_state_machine::record_line): Ignore is_stmt flag for records
82 produced by codewarrior.
83 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
85 2018-10-06 Tom Tromey <tom@tromey.com>
88 * python/py-inferior.c: Add "architecture" entry.
89 (infpy_architecture): New function.
91 2018-10-06 Tom Tromey <tom@tromey.com>
94 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
95 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
96 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
97 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
99 2018-10-06 Tom Tromey <tom@tromey.com>
102 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
103 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
104 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
107 2018-10-06 Tom Tromey <tom@tromey.com>
109 * python/py-breakpoint.c (bppy_get_location): Handle a
110 bp_breakpoint without a location.
112 2018-10-06 Tom Tromey <tom@tromey.com>
114 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
115 (_RegEx): Reformat help text.
116 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
117 (AnyCallerIs, AnyCallerMatches): Reformat help text.
118 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
120 * python/lib/gdb/command/xmethods.py (InfoXMethod)
121 (EnableXMethod, DisableXMethod): Remove help indentation.
122 Capitalize meta-syntactic variables.
123 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
124 (EnableUnwinder, DisableUnwinder): Remove help indentation.
125 Capitalize meta-syntactic variables.
126 * python/lib/gdb/command/explore.py (ExploreCommand)
127 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
128 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
129 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
130 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
131 Remove help indentation.
132 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
133 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
134 (DisableFrameFilter, SetFrameFilterPriority)
135 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
137 2018-10-06 Tom Tromey <tom@tromey.com>
140 * tui/tui-io.c (gdb_wgetch): New function.
141 (tui_mld_getc, tui_getc): Use it.
143 2018-10-05 Tom Tromey <tom@tromey.com>
145 * sol-thread.c (sol_thread_target::wait): Rename inner
148 2018-10-04 Tom Tromey <tom@tromey.com>
150 * configure: Rebuild.
151 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
153 2018-10-04 Tom Tromey <tom@tromey.com>
155 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
156 declaration of "block".
158 2018-10-04 Tom Tromey <tom@tromey.com>
160 * common/filestuff.c (fdwalk): Remove inner declaration of
163 2018-10-04 Tom Tromey <tom@tromey.com>
165 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
166 "structs_addr" and hoist declaration.
168 2018-10-04 Tom Tromey <tom@tromey.com>
170 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
173 2018-10-04 Tom Tromey <tom@tromey.com>
175 * mdebugread.c (parse_partial_symbols): Use std::string.
177 2018-10-04 Tom Tromey <tom@tromey.com>
179 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
180 * p-valprint.c (pascal_val_print): Split inner "i" variable.
181 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
183 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
185 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
186 * varobj.c (varobj_update): Rename inner "newobj",
188 * valprint.c (generic_emit_char): Rename inner "buf".
189 * valops.c (find_overload_match): Rename inner "temp".
190 (value_struct_elt_for_reference): Declare "v" in more inner
192 * v850-tdep.c (v850_push_dummy_call): Rename "len".
193 * unittests/array-view-selftests.c (run_tests): Rename inner
195 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
197 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
198 "tsv" in more inner scope.
199 (print_one_static_tracepoint_marker): Rename inner
201 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
202 (tic6x_push_dummy_call): Don't redeclare "addr".
203 * target-float.c: Declare "dto" lower.
204 * symtab.c (lookup_local_symbol): Rename inner "sym".
205 (find_pc_sect_line): Rename inner "pc".
206 * stack.c (print_frame): Don't redeclare "gdbarch".
207 (return_command): Rename inner "gdbarch".
208 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
210 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
212 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
213 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
215 * remote.c (remote_target::update_thread_list): Don't redeclare
217 (remote_target::process_initial_stop_replies): Rename inner
219 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
220 (remote_target::wait_as): Don't redeclare "stop_reply".
221 (remote_target::get_thread_local_address): Rename inner
223 (remote_target::get_tib_address): Likewise.
225 * regcache.c (cooked_read_test): Rename "regnum".
226 * record-btrace.c (cmd_record_btrace_start): Rename inner
228 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
230 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
232 (ppu2spu_sniffer): Rename inner "buf".
233 * parse.c (operator_check_standard): Rename inner "type",
235 * p-valprint.c (pascal_val_print): Introduce new scope for
236 "low_bound", "high_bound".
237 * p-exp.y (yylex): Declare "i" in loop header.
238 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
239 Lower declaration of "s".
240 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
242 (nios2_push_dummy_call): Rename "len".
243 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
245 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
246 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
247 (linux_xfer_osdata_modules): Likewise.
248 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
249 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
250 (mips_o64_push_dummy_call): Likewise.
251 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
253 * mi/mi-main.c (list_available_thread_groups): Rename inner
255 (mi_cmd_data_read_memory): Rename inner "opts".
256 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
258 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
259 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
261 (parse_partial_symbols): Rename inner "pst", "p", "name"
262 * main.c (captured_main_1): Rename inner "i"s.
263 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
265 * linux-tdep.c (linux_info_proc): Rename inner "filename".
266 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
267 * infrun.c (handle_no_resumed): Don't redeclare "thread".
268 (handle_signal_stop): Rename inner "gdbarch".
269 (handle_command): Declare "signum" in loop header.
270 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
272 (examine_prologue): Rename inner "sol" and "sof".
273 (ia64_extract_return_value): Rename inner "val". Declare another
274 "val" in a more inner scope.
275 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
277 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
279 * findvar.c (default_read_var_value): Don't redeclare "addr".
280 * f-exp.y (yylex): Declare "i" in loop header.
281 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
282 Rename inner "type", "expect_type".
283 (evaluate_subexp_for_sizeof): Rename inner "pc".
284 * elfread.c (elf_symfile_read): Rename inner "abfd".
285 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
287 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
288 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
289 (dwarf_decode_line_header): Rename inner "lh".
290 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
291 "offset". Declare "i" in loop header.
292 (disassemble_dwarf_expression): Rename inner "addr_size".
293 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
295 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
296 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
297 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
298 "inner_list_emitter".
299 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
300 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
301 declaration in a block.
302 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
303 * cp-valprint.c (cp_print_value_fields): Don't redeclare
304 "obstack_final_size".
305 * cp-support.c (inspect_type): Declare "i" in loop header.
306 * compile/compile.c (compile_instance::insert_symbol_error):
308 * common/agent.c (agent_run_command): Remove inner "ret"
310 * coffread.c (coff_symfile_read): Rename inner "name".
311 (coff_symfile_read): Rename inner "abfd".
312 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
313 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
315 * c-exp.y (lex_one_token): Move "len" declaration lower.
316 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
318 (create_exception_master_breakpoint): Likewise. Don't redeclare
320 (watch_command_1): Declare "mark" later.
321 (clear_command): Don't shadow "a" or "b".
322 (delete_command): Rename inner "b".
323 (delete_trace_command): Likewise.
324 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
326 (arm_gdbarch_init): Remove inner "e_flags".
327 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
328 "offset" in inner blocks.
330 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
332 * dwarf-index-write.c (file_write): Don't write if the vector is
335 2018-10-05 Tom de Vries <tdevries@suse.de>
337 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
338 PyArg_ParseTuple call.
340 2018-10-05 Tom de Vries <tdevries@suse.de>
342 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
343 PyArg_ParseTuple call.
345 2018-10-04 Joel Brobecker <brobecker@adacore.com>
347 * psymtab.c (recursively_search_psymtabs): Reformat parameters
348 to avoid exceeding 80 characters per line limit.
350 2018-10-04 Tom Tromey <tom@tromey.com>
352 * symfile.c (syms_from_objfile_1, finish_new_objfile)
353 (reread_symbols): Update.
354 * complaints.h (clear_complaints): Remove argument.
355 * complaints.c (enum complaint_series): Remove.
356 (series): Remove global.
357 (complaint_internal): Update.
358 (clear_complaints): Remove argument.
360 2018-10-04 Tom Tromey <tom@tromey.com>
362 * symfile.c (symbol_file_add_with_addrs): Do not print "no
363 debugging symbols" message if there is a separate debug objfile.
365 2018-10-04 Tom Tromey <tom@tromey.com>
368 * symfile.c (symbol_file_add_with_addrs): Update output.
369 * psymtab.c (require_partial_symbols): Update output.
371 2018-10-04 Tom Tromey <tom@tromey.com>
374 * complaints.c: Emit \n.
376 2018-10-04 Tom Tromey <tom@tromey.com>
378 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
379 (separate_debug_file_exists, find_separate_debug_file)
380 (add_symbol_file_command, reread_symbols, allocate_symtab)
381 (allocate_compunit_symtab): Use filtered printing, not
383 * psymtab.c (require_partial_symbols, dump_psymtab)
384 (allocate_psymtab): Use filtered printing, not unfiltered.
386 2018-10-04 Tom Tromey <tom@tromey.com>
388 * complaints.c (complaint_internal): Correctly check complaint
391 2018-10-04 Tom Tromey <tom@tromey.com>
393 * complaints.h (struct complaints): Remove declaration.
394 * complaints.c (clear_complaints): Remove an unused variable.
396 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
398 * MAINTAINERS (Write After Approval): Add self.
400 2018-10-03 Tom Tromey <tom@tromey.com>
402 * guile/scm-value.c (gdbscm_value_to_string): Initialize
404 * coffread.c (coff_symtab_read): Initialize "newobj".
406 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
408 * dwarf2read.c (read_func_scope): Remove struct keyword in
411 2018-10-03 Tom Tromey <tom@tromey.com>
413 * README: Mention --enable-ubsan.
414 * NEWS: Mention --enable-ubsan.
415 * acinclude.m4: Include sanitize.m4.
416 * configure: Rebuild.
417 * configure.ac: Call AM_GDB_UBSAN.
418 * sanitize.m4: New file.
420 2018-10-03 Tom Tromey <tom@tromey.com>
422 * expression.h (enum exp_opcode): Use uint8_t as base type.
423 * expprint.c (op_name): Handle invalid opcodes.
425 2018-10-03 Tom Tromey <tom@tromey.com>
427 * parse.c (prefixify_expression): Add assert.
428 (parse_exp_in_context_1): Throw exception if the expression is
431 2018-10-03 Tom Tromey <tom@tromey.com>
433 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
435 2018-10-03 Tom Tromey <tom@tromey.com>
437 * c-exp.y (parse_number): Work in unsigned. Remove casts.
439 2018-10-03 Tom Tromey <tom@tromey.com>
441 * dwarf2read.c (read_subrange_type): Make "negative_mask"
444 2018-10-03 Tom Tromey <tom@tromey.com>
446 * findvar.c (extract_integer): Do work in an unsigned type.
448 2018-10-03 Tom Tromey <tom@tromey.com>
450 * common/enum-flags.h (enum_flags::operator~): Add static assert.
451 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
453 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
454 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
456 * c-lang.h (enum c_string_type_values): Use unsigned as base
458 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
460 2018-10-03 Tom Tromey <tom@tromey.com>
462 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
463 <~dwarf2_frame_state_reg_info>: Update.
464 <dwarf2_frame_state_reg_info>: Update.
465 <alloc_regs>: Add assertion. Update.
466 <reg>: Now a std::vector.
469 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
470 (execute_cfa_program_test, dwarf2_frame_cache): Update.
472 2018-10-03 Tom Tromey <tom@tromey.com>
474 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
476 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
478 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
480 2018-10-02 Tom Tromey <tom@tromey.com>
482 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
484 2018-10-02 John Darrington <john@darrington.wattle.id.au>
486 * NEWS: Mention changed commands.
487 * ser-uds.c: New file.
488 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
489 * configure: Regenerate.
490 * Makefile.in: Add new file.
491 * serial.c (serial_open): Check if filename is a socket
492 and lookup the appropriate interface accordingly.
494 2018-10-01 Alan Hayward <alan.hayward@arm.com>
496 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
498 (AARCH64_EXTRA_MAGIC): Likewise.
499 (AARCH64_FPSIMD_MAGIC): Likewise.
500 (AARCH64_SVE_MAGIC): Likewise.
501 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
502 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
503 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
504 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
505 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
506 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
507 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
508 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
509 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
510 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
511 (read_aarch64_ctx): Add function.
512 (aarch64_linux_sigframe_init): Detect FP registers.
514 2018-10-01 Alan Hayward <alan.hayward@arm.com>
516 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
517 (AARCH64_D0_REGNUM): Likewise.
518 (AARCH64_S0_REGNUM): Likewise.
519 (AARCH64_H0_REGNUM): Likewise.
520 (AARCH64_B0_REGNUM): Likewise.
521 (AARCH64_SVE_V0_REGNUM): Likewise.
522 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
523 (AARCH64_D0_REGNUM): Likewise.
524 (AARCH64_S0_REGNUM): Likewise.
525 (AARCH64_H0_REGNUM): Likewise.
526 (AARCH64_B0_REGNUM): Likewise.
527 (AARCH64_SVE_V0_REGNUM): Likewise.
529 2018-10-01 Gary Benson <gbenson@redhat.com>
531 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
532 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
533 prfpregset_t instead of gdb_prfpregset_t.
534 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
535 * configure, config.in: Rebuild.
537 2018-10-01 Gary Benson <gbenson@redhat.com>
539 * common/gdb_proc_service.h: New file, factored out from...
540 * gdb_proc_service.h: Moved common code to the above file.
541 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
543 2018-10-01 Gary Benson <gbenson@redhat.com>
545 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
546 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
548 2018-10-01 Gary Benson <gbenson@redhat.com>
550 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
551 (AC_CHECK_HEADERS): Check for linux/elf.h.
552 * configure, config.in: Rebuild.
553 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
554 doesn't define elf_fpregset_t.
556 2018-10-01 Gary Benson <gbenson@redhat.com>
558 * gdb_proc_service.h: Whitespace change.
560 2018-10-01 Tom Tromey <tom@tromey.com>
562 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
563 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
564 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
566 2018-10-01 Tom Tromey <tom@tromey.com>
568 * README: Minor change.
570 2018-09-30 Pedro Alves <palves@redhat.com>
572 * darwin-nat-info.c (darwin_debug_regions_recurse)
573 (info_mach_exceptions_command): Remove unused local variables.
574 * darwin-nat.c (darwin_decode_notify_message)
575 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
576 (darwin_stop_inferior, darwin_setup_exceptions)
577 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
578 (darwin_nat_target::attach, darwin_nat_target::detach)
579 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
581 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
584 2018-09-29 Tom Tromey <tom@tromey.com>
586 * README: Remove some leftover text.
588 2018-09-29 Tom Tromey <tom@tromey.com>
593 2018-09-28 John Baldwin <jhb@FreeBSD.org>
595 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
596 case with explicit breakpoint kind.
597 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
598 'additional_info' and related logic.
599 (riscv_debug_breakpoints): New variable.
600 (riscv_breakpoint_kind_from_pc): Use the length of the existing
601 instruction to determine the breakpoint kind.
602 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
603 flag. Update description of 'set/show riscv
604 use-compressed-breakpoints' flag.
606 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
608 (NEWS): Mention changes to frame related commands.
609 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
610 (add_prefix_cmd_suppress_notification): New function.
611 (add_com_suppress_notification): Call
612 add_cmd_suppress_notification.
613 * command.h (add_cmd_suppress_notification): Declare.
614 (add_prefix_cmd_suppress_notification): Declare.
615 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
616 (parse_frame_specification): Moved from stack.c, with
617 simplification to handle a single argument.
618 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
619 switch to the selected frame. Add a header comment.
620 * stack.c: Remove 'safe-ctype.h' include.
621 (find_frame_for_function): Add declaration.
622 (find_frame_for_address): New function.
623 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
624 (frame_selection_by_function_completer): New function.
625 (info_frame_command): Rename to...
626 (info_frame_command_core): ...this, and update parameter types.
627 (select_frame_command): Rename to...
628 (select_frame_command_core): ...this, and update parameter types.
629 (frame_command): Rename to...
630 (frame_command_core): ...this, and update parameter types.
631 (class frame_command_helper): New class to wrap implementations of
632 frame related sub-commands.
633 (frame_apply_cmd_list): New static global.
634 (frame_cmd_list): Make static.
635 (select_frame_cmd_list): New global for sub-commands.
636 (info_frame_cmd_list): New global for sub-commands.
637 (_initialize_stack): Register sub-commands for 'frame',
638 'select-frame', and 'info frame'. Update 'frame apply' commands
639 to use frame_apply_cmd_list. Move function local static
640 frame_apply_list to file static frame_apply_cmd_list for
642 * stack.h (select_frame_command): Delete declarationn.
643 (select_frame_for_mi): Declare new function.
645 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
647 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
648 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
651 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
653 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
655 2018-09-26 Tom Tromey <tom@tromey.com>
657 * valops.c (auto_abandon): Remove dead code.
659 2018-09-26 Tom Tromey <tom@tromey.com>
661 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
663 2018-09-24 Tom Tromey <tom@tromey.com>
665 * common/pathstuff.c (get_standard_cache_dir): Make
666 "xdg_cache_home" and "home" const.
667 * top.c (init_history): Make "tmpenv" const.
668 * main.c (get_init_files): Make "homedir" const.
670 2018-09-23 Tom Tromey <tom@tromey.com>
673 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
675 2018-09-23 Tom Tromey <tom@tromey.com>
677 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
678 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
679 * python/python-internal.h (gdbpy_handle_exception): Declare.
680 * python/py-utils.c (gdbpy_handle_exception): New function.
682 2018-09-23 Tom Tromey <tom@tromey.com>
685 * python/py-type.c (typy_template_argument): Check for negative
688 2018-09-23 Tom Tromey <tom@tromey.com>
691 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
693 2018-09-23 Tom Tromey <tom@tromey.com>
696 * python/py-value.c (valpy_int): Allow conversion from pointer
699 2018-09-23 Tom Tromey <tom@tromey.com>
702 * python/py-value.c (valpy_int): Respect type sign.
704 2018-09-23 Tom Tromey <tom@tromey.com>
707 * python/py-value.c (valpy_float): Allow conversions from int or
709 (valpy_int, valpy_long): Allow conversions from float.
711 2018-09-23 Tom Tromey <tom@tromey.com>
713 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
714 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
716 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
718 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
720 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
722 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
724 * windows-nat.c (windows_nat_target::wait): Remove a spurious
725 target_terminal::ours().
727 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
729 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
732 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
734 * breakpoint.c (update_inserted_breakpoint_locations): Remove
737 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
739 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
741 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
742 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
743 * sol-thread.c (ps_pdmodel): Don't guard definition.
745 * procfs.c: Fix formatting.
747 * procfs.c (sysset_t_alloc): Remove.
748 (create_procinfo): Use XNEW instead of sysset_t_alloc.
749 (procfs_debug_inferior): Likewise.
750 (procfs_set_exec_trap): Likewise.
751 (proc_set_traced_sysentry): Don't allocate argp dynamically.
752 (proc_set_traced_sysexit): Likewise.
754 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
755 (dead_procinfo): Likewise.
756 (proc_warn): Likewise.
757 (proc_error): Likewise.
758 (proc_get_LDT_entry): Likewise.
759 (do_attach): Likewise.
760 (procfs_target::pid_to_str): Likewise.
761 (iterate_over_mappings): Likewise.
763 * procfs.c (create_procinfo): Fix ARI warning.
764 (proc_get_status): Likewise.
765 (proc_stop_process): Likewise.
766 (proc_run_process): Likewise.
767 (proc_kill): Likewise.
768 (proc_get_LDT_entry): Likewise.
769 (procfs_find_LDT_entry): Likewise.
770 (proc_update_threads): Likewise.
771 (proc_iterate_over_threads): Likewise.
772 (do_attach): Likewise.
773 (procfs_xfer_memory): Likewise.
774 (invalidate_cache): Likewise.
775 (procfs_target::resume): Likewise.
776 (procfs_init_inferior): Likewise.
777 (procfs_set_exec_trap): Likewise.
778 (procfs_target::thread_alive): Likewise.
779 (procfs_target::pid_to_exec_file): Likewise.
780 (iterate_over_mappings): Likewise.
781 (procfs_target::make_corefile_notes): Likewise.
782 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
784 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
785 (procfs_find_LDT_entry): Likewise.
786 * sol-thread.c (ps_lgetLDT): Likewise.
788 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
791 * procfs.c (procfs_target): Declare pid_to_exec_file.
792 (procfs_target::pid_to_exec_file): New.
794 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
796 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
798 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
799 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
801 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
803 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
804 (supply_fpregset, fill_fpregset): Move ...
805 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
806 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
807 Remove references to ioctl-based procfs.
809 Remove PR_MODEL_NATIVE guards.
810 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
811 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
813 2018-09-19 Xavier Roirand <roirand@adacore.com>
816 * solib-darwin.c (darwin_get_dyld_bfd): New function.
817 (darwin_solib_get_all_image_info_addr_at_init): Update call.
818 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
820 2018-09-19 John Baldwin <jhb@FreeBSD.org>
822 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
823 (fbsd_print_sockaddr_in6): Likewise.
825 2018-09-19 Richard Bunt <richard.bunt@arm.com>
826 Chris January <chris.january@arm.com>
828 * eval.c (skip_undetermined_arglist): Skip argument list helper.
829 (evaluate_subexp_standard): Return a dummy type when
830 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
831 OP_F77_UNDETERMINED_ARGLIST case.
832 * expression.h (enum noside): Update comment.
834 2018-09-19 George Vasick <george.vasick@oracle.com>
836 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
838 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
839 April Chin <april.chin@oracle.com>
840 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
842 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
844 (create_procinfo): Print pids in /proc without leading zeros.
846 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
848 * nios2-tdep.c (nios2_gcc_target_options): New.
849 (nios2_gdb_arch_init): Install new hook.
851 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
853 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
855 * update-gnulib.sh: Apply patch.
856 * configure: Re-generate.
858 2018-09-18 John Baldwin <jhb@FreeBSD.org>
860 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
861 description. Make "info proc" command descriptions more
864 2018-09-18 John Baldwin <jhb@FreeBSD.org>
866 * NEWS: Mention 'info proc files' command.
868 2018-09-18 John Baldwin <jhb@FreeBSD.org>
870 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
871 descriptors for IP_FILES and IP_ALL.
873 2018-09-18 John Baldwin <jhb@FreeBSD.org>
875 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
876 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
877 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
878 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
879 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
880 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
881 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
882 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
883 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
884 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
885 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
886 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
887 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
888 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
889 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
890 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
891 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
892 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
893 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
894 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
895 (struct fbsd_sockaddr_un): New types.
896 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
897 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
898 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
899 (fbsd_core_info_proc_files): New functions.
900 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
902 * fbsd-tdep.h (fbsd_info_proc_files_header)
903 (fbsd_info_proc_files_entry): New.
905 2018-09-18 John Baldwin <jhb@FreeBSD.org>
907 * defs.h (enum info_proc_what) [IP_FILES]: New value.
908 * infcmd.c (info_proc_cmd_files): New function.
909 (_initialize_infcmd): Register 'info proc files' command.
911 2018-09-18 John Baldwin <jhb@FreeBSD.org>
913 * gnulib/aclocal-m4-deps.mk: Re-generate.
914 * gnulib/aclocal.m4: Re-generate.
915 * gnulib/config.in: Re-generate.
916 * gnulib/configure: Re-generate.
917 * gnulib/import/Makefile.am: Re-generate.
918 * gnulib/import/Makefile.in: Re-generate.
919 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
920 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
921 * gnulib/import/arpa_inet.in.h: New file.
922 * gnulib/import/inet_ntop.c: New file.
923 * gnulib/import/m4/arpa_inet_h.m4: New file.
924 * gnulib/import/m4/inet_ntop.m4: New file.
925 * gnulib/import/m4/netinet_in_h.m4: New file.
926 * gnulib/import/m4/socklen.m4: New file.
927 * gnulib/import/m4/sockpfaf.m4: New file.
928 * gnulib/import/m4/stdalign.m4: New file.
929 * gnulib/import/m4/sys_uio_h.m4: New file.
930 * gnulib/import/netinet_in.in.h: New file.
931 * gnulib/import/stdalign.in.h: New file.
932 * gnulib/import/sys_socket.c: New file.
933 * gnulib/import/sys_socket.in.h: New file.
934 * gnulib/import/sys_uio.in.h: New file.
935 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
938 2018-09-18 John Baldwin <jhb@FreeBSD.org>
940 * gnulib/aclocal-m4-deps.mk: New file.
941 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
944 2018-09-18 John Baldwin <jhb@FreeBSD.org>
946 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
949 2018-09-18 Tom Tromey <tom@tromey.com>
951 * compile/compile-object-load.c (struct
952 link_hash_table_cleanup_data): Add constructor and destructor.
953 Use DISABLE_COPY_AND_ASSIGN.
954 (~link_hash_table_cleanup_data): Rename from
955 link_hash_table_free. Now a destructor.
956 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
958 2018-09-18 Tom Tromey <tom@tromey.com>
960 * compile/compile-object-run.c (do_module_cleanup): Use delete.
961 * compile/compile-object-load.c (struct munmap_list): Move to
963 (munmap_list::add): Rename from munmap_list_add; rewrite.
964 (munmap_list::~munmap_list): Rename from munmap_list_free.
965 (munmap_listp_free_cleanup): Remove.
966 (compile_object_load): Update.
967 * compile/compile-object-load.h (struct munmap_list): Move from
968 compile-object-load.c. Rewrite.
970 2018-09-18 Alan Hayward <alan.hayward@arm.com>
972 * aarch64-tdep.c (pass_in_v): Use register size.
973 (aarch64_extract_return_value): Likewise.
974 (aarch64_store_return_value): Likewise.
976 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
978 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
981 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
983 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
986 2018-09-17 Tom Tromey <tom@tromey.com>
989 * configure: Rebuild.
990 * configure.ac: Conditionally use -DNDEBUG for Python.
992 2018-09-17 Tom Tromey <tom@tromey.com>
994 * configure: Rebuild.
995 * configure.ac: Use gmp as a library dependency when checking for
998 2018-09-17 Pedro Alves <palves@redhat.com>
1000 * python/py-inferior.c (find_inferior_object): Delete.
1002 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
1004 * compile/compile-cplus-types.c
1005 (compile_cplus_instance::enter_scope): Don't use new_scope after
1008 2018-09-17 Tom Tromey <tom@tromey.com>
1010 * common/pathstuff.c (get_standard_cache_dir): Use
1011 ~/Library/Caches on macOS.
1012 * common/pathstuff.h (get_standard_cache_dir): Update comment.
1014 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
1017 * breakpoint.c (commands_cmd_element): New.
1018 (_initialize_breakpoint): Assign commands_cmd_element.
1019 * breakpoint.h (commands_cmd_element): New.
1020 * cli/cli-script.c (while_cmd_element, if_command,
1021 define_cmd_element): New.
1022 (command_name_equals): Remove.
1023 (process_next_line): Compare commands by pointer, not by name.
1024 (_initialize_cli_script): Assign the various cmd_list_element
1026 * compile/compile.c (compile_cmd_element): New.
1027 (_initialize_compile): Assign compile_cmd_element.
1028 * compile/compile.h (compile_cmd_element): New.
1029 * guile/guile.c (guile_cmd_element): New.
1030 (install_gdb_commands): Assign guile_cmd_element.
1031 * guile/guile.h (guile_cmd_element): New.
1032 * python/python.c (python_cmd_element): New.
1033 (_initialize_python): Assign python_cmd_element.
1034 * python/python.h (python_cmd_element): New.
1035 * tracepoint.c (while_stepping_cmd_element): New.
1036 (_initialize_tracepoint): Assign while_stepping_cmd_element.
1037 * tracepoint.h (while_stepping_cmd_element): New.
1039 2018-09-17 Tom Tromey <tom@tromey.com>
1041 * infrun.c (save_infcall_suspend_state): Return
1042 infcall_suspend_state_up.
1043 (save_infcall_control_state): Return infcall_control_state_up.
1044 * inferior.h (save_infcall_suspend_state)
1045 (save_infcall_control_state): Declare later. Return unique
1048 2018-09-17 Tom Tromey <tom@tromey.com>
1050 * infrun.c (struct stop_context): Declare constructor,
1051 destructor, "changed" method.
1052 (stop_context::stop_context): Rename from save_stop_context.
1053 (stop_context::~stop_context): Rename from
1054 release_stop_context_cleanup.
1055 (normal_stop): Update.
1056 (stop_context::changed): Rename from stop_context_changed. Return
1059 2018-09-17 Tom Tromey <tom@tromey.com>
1061 * inferior.h (struct infcall_suspend_state_deleter): New.
1062 (infcall_suspend_state_up): New typedef.
1063 (struct infcall_control_state_deleter): New.
1064 (infcall_control_state_up): New typedef.
1065 (make_cleanup_restore_infcall_suspend_state)
1066 (make_cleanup_restore_infcall_control_state): Don't declare.
1067 * infcall.c (call_function_by_hand_dummy): Update.
1068 * infrun.c (do_restore_infcall_suspend_state_cleanup)
1069 (make_cleanup_restore_infcall_suspend_state): Remove.
1070 (do_restore_infcall_control_state_cleanup)
1071 (make_cleanup_restore_infcall_control_state): Remove.
1073 2018-09-17 Tom Tromey <tom@tromey.com>
1075 * gdbthread.h (struct thread_control_state): Add initializer.
1076 (class thread_info) <control>: Remove initializer.
1077 * inferior.h (struct inferior_control_state): Add initializer.
1078 (class inferior) <control>: Remove initializer.
1079 (exit_inferior_1): Update.
1080 * infrun.c (struct infcall_control_state): Add constructors.
1081 (save_infcall_control_state): Use new.
1082 (restore_infcall_control_state, discard_infcall_control_state):
1085 2018-09-17 Tom Tromey <tom@tromey.com>
1087 * infrun.c (struct infcall_suspend_state) <registers>: Now a
1089 <siginfo_data>: Now a unique_xmalloc_ptr.
1090 (save_infcall_suspend_state, restore_infcall_suspend_state)
1091 (discard_infcall_suspend_state)
1092 (get_infcall_suspend_state_regcache): Update.
1094 2018-09-17 Tom Tromey <tom@tromey.com>
1096 * gdbthread.h (struct thread_suspend_state): Add initializers.
1097 (class thread_info) <suspend>: Remove initializer.
1098 * infrun.c (struct infcall_suspend_state): Add initializers.
1099 (save_infcall_suspend_state): Use new.
1100 (discard_infcall_suspend_state): Use delete.
1102 2018-09-16 Tom Tromey <tom@tromey.com>
1104 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
1106 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
1107 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
1108 (py_varobj_iter_new): Likewise.
1109 (py_varobj_get_iterator): Use gdbpy_ref.
1111 2018-09-16 Tom Tromey <tom@tromey.com>
1113 * python/py-threadevent.c (py_get_event_thread): Simplify.
1114 * python/py-inferior.c (infpy_thread_from_thread_handle):
1115 Return immediately after calling thread_to_thread_object. Use
1117 (thread_to_thread_object): Set the exception on a NULL return.
1119 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1121 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
1123 2018-09-16 Tom Tromey <tom@tromey.com>
1125 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
1128 2018-09-16 Tom Tromey <tom@tromey.com>
1130 * python/python-internal.h (thread_to_thread_object): Change
1132 * python/py-inferior.c (thread_to_thread_object): Return a new
1134 (infpy_thread_from_thread_handle): Update.
1135 * python/py-infthread.c (gdbpy_selected_thread): Update.
1136 * python/py-stopevent.c (create_stop_event_object): Update.
1137 * python/py-threadevent.c (py_get_event_thread): Return a new
1139 (py_get_event_thread): Update.
1140 * python/py-event.h (py_get_event_thread): Change return type.
1141 * python/py-continueevent.c (create_continue_event_object):
1144 2018-09-16 Tom Tromey <tom@tromey.com>
1146 * python/py-progspace.c (pspy_get_objfiles): Update.
1147 * python/python-internal.h (objfile_to_objfile_object): Change
1149 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1151 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1153 * python/python.c (gdbpy_get_current_objfile): Update.
1154 (gdbpy_objfiles): Update.
1155 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
1157 (objfile_to_objfile_object): Return a new reference.
1158 * python/py-symtab.c (stpy_get_objfile): Update.
1159 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
1162 2018-09-16 Tom Tromey <tom@tromey.com>
1164 * python/py-inferior.c (infpy_get_progspace): Update.
1165 * python/python-internal.h (pspace_to_pspace_object): Change
1167 * python/py-newobjfileevent.c
1168 (create_clear_objfiles_event_object): Update.
1169 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1171 * python/python.c (gdbpy_get_current_progspace): Update.
1172 (gdbpy_progspaces): Update.
1173 * python/py-progspace.c (pspace_to_pspace_object): Return a new
1175 * python/py-objfile.c (objfpy_get_progspace): Update.
1176 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
1179 2018-09-16 Tom Tromey <tom@tromey.com>
1181 * python/lib/gdb/__init__.py (current_progspace, objfiles)
1182 (solib_name, block_for_pc, find_pc_line): New functions.
1183 (execute_unwinders): Update.
1184 * python/py-block.c (gdbpy_block_for_pc): Remove.
1185 * python/py-inferior.c (infpy_get_progspace): New function.
1186 (inferior_object_getset) <progspace>: Add.
1187 * python/py-progspace.c (pspy_objfiles): Rewrite.
1188 (pspy_solib_name, pspy_block_for_pc)
1189 (pspy_find_pc_line, pspy_is_valid): New functions.
1190 (progspace_object_methods): Add entries for solib_name,
1191 block_for_pc, find_pc_line, is_valid.
1192 * python/python-internal.h (gdbpy_block_for_pc)
1193 (build_objfiles_list): Don't declare.
1194 * python/python.c: Don't include solib.h.
1195 (gdbpy_solib_name, gdbpy_find_pc_line)
1196 (gdbpy_get_current_progspace, build_objfiles_list)
1197 (gdbpy_objfiles): Remove.
1198 (GdbMethods) <current_progspace, objfiles, block_for_pc,
1199 solib_name, find_pc_line>: Remove entries.
1201 2018-09-16 Tom Tromey <tom@tromey.com>
1203 * top.c (new_ui_command): Use GNU style for metasyntactic
1205 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
1207 * maint.c (maintenance_translate_address): Remove "<>" around
1209 * interps.c (interpreter_exec_cmd): Use GNU style for
1210 metasyntactic variables.
1211 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
1212 metasyntactic variables.
1213 * tracepoint.c (tfind_range_command): Use GNU style for
1214 metasyntactic variables.
1215 (tfind_outside_command): Likewise.
1216 (_initialize_tracepoint): Likewise.
1217 * remote.c (extended_remote_target::create_inferior): Use GNU
1218 style for metasyntactic variables.
1219 * sparc64-tdep.c (adi_examine_command): Use GNU style for
1220 metasyntactic variables.
1221 (adi_assign_command): Likewise.
1223 2018-09-16 Tom Tromey <tom@tromey.com>
1225 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
1226 metasyntactic variables. Print message if no disassembler options
1229 2018-09-15 Tom Tromey <tom@tromey.com>
1231 * infcmd.c (get_inferior_args): Return const char *.
1232 * inferior.h (get_inferior_args): Return type now const.
1233 * linux-tdep.c (linux_fill_prpsinfo): Update.
1234 * procfs.c (procfs_target::make_corefile_notes): Update.
1236 2018-09-07 Tom Tromey <tom@tromey.com>
1238 * python/python.c (execute_gdb_command): Call bpstat_do_actions
1241 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
1243 * nios2-tdep.c (nios2_type_align): New.
1244 (nios2_gdb_arch_init): Install type_align hook.
1246 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1248 * eval.c (fake_method::fake_method): Call xzalloc directly for a
1249 type that is neither object file owned, nor gdbarch owned.
1250 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
1251 gdbarch is non-NULL.
1252 (alloc_type_instance): Allocate non-objfile owned types on the
1254 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
1255 using TYPE_ALLOC to ensure memory is allocated on the correct
1257 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
1258 obstack, or the gdbarch obstack.
1259 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
1261 2018-09-14 Tom Tromey <tom@tromey.com>
1263 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
1266 2018-09-14 Tom Tromey <tom@tromey.com>
1268 * nat/fork-inferior.c (get_startup_shell): Remove "static".
1270 2018-09-13 Tom Tromey <tom@tromey.com>
1272 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
1275 2018-09-13 Tom Tromey <tom@tromey.com>
1277 * exec.c (try_open_exec_file): Use std::string.
1279 2018-09-13 Tom Tromey <tom@tromey.com>
1281 * utils.h (gdb_bfd_errmsg): Return std::string.
1282 * exec.c (exec_file_attach): Update.
1283 * compile/compile-object-load.c (compile_object_load): Update.
1284 * utils.c (gdb_bfd_errmsg): Return std::string.
1286 2018-09-13 Tom Tromey <tom@tromey.com>
1288 * procfs.c (struct procinfo_deleter): New.
1289 (procinfo_up): New typedef.
1290 (do_destroy_procinfo_cleanup): Remove.
1291 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
1293 2018-09-13 Tom Tromey <tom@tromey.com>
1295 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
1297 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1298 2018-09-13 Tom Tromey <tom@tromey.com>
1300 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
1301 (pspy_get_objfiles): New function.
1302 (progspace_object_methods): New.
1303 (pspace_object_type): Add tp_methods callback.
1304 * python/python-internal.h (build_objfiles_list): New
1306 * python/python.c (build_objfiles_list): New function.
1307 (gdbpy_objfiles): Implement using build_objfiles_list.
1308 * NEWS: Mention the Progspace.objfiles method.
1310 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1312 * python/py-inferior.c (infpy_get_progspace): New function.
1313 (inferior_object_getset): Add progspace property.
1314 * NEWS: Mention the new property.
1316 2018-09-13 Tom Tromey <tom@tromey.com>
1319 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
1321 2018-09-13 Tom Tromey <tom@tromey.com>
1324 * rust-lang.c (rust_enum_variant): Now static.
1325 (rust_empty_enum_p): New function.
1326 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
1329 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1331 * python/py-inferior.c (infpy_repr): New.
1332 (inferior_object_type): Register infpy_repr.
1333 * python/py-objfile.c (objfpy_repr): New.
1334 (objfile_object_type): Register objfpy_repr.
1336 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1338 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
1340 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1342 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
1345 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
1347 * common/common-utils.c: Don't include '<sys/stat.h>'.
1348 (is_regular_file): Move to...
1349 * common/filestuff.c (is_regular_file): ... here.
1350 * common/common-utils.h (is_regular_file): Move to...
1351 * common/filestuff.h (is_regular_file): ... here.
1353 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
1355 * skip.c (debug_skip): New variable.
1356 (skiplist_entry::do_skip_file_p): Add debug output.
1357 (skiplist_entry::do_skip_gfile_p): Likewise.
1358 (skiplist_entry::skip_function_p): Likewise.
1359 (_initialize_step_skip): Create debug command.
1360 * NEWS: Mention set/show debug skip.
1362 2018-09-11 Xavier Roirand <roirand@adacore.com>
1364 * darwin-nat.c (should_disable_startup_with_shell):
1366 (darwin_nat_target::create_inferior): Add call.
1368 2018-09-11 Xavier Roirand <roirand@adacore.com>
1370 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
1371 inf_port, msg_state>: Initialize.
1372 (struct darwin_thread_info) <signaled, single_step>: Change
1373 type and initialize.
1374 (struct darwin_thread_info) <event>: Initialize.
1376 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1380 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
1383 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1386 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1390 * gnulib/aclocal.m4: Regenerate.
1391 * gnulib/config.in: Regenerate.
1392 * gnulib/configure: Regenerate.
1393 * gnulib/import/Makefile.am: Update.
1394 * gnulib/import/Makefile.in: Update.
1395 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1396 * gnulib/import/_Noreturn.h: ... this.
1397 * gnulib/import/alloca.in.h: Update.
1398 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1399 * gnulib/import/arg-nonnull.h: ... this.
1400 * gnulib/import/assure.h: Update.
1401 * gnulib/import/at-func.c: Update.
1402 * gnulib/import/basename-lgpl.c: Update.
1403 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1404 * gnulib/import/c++defs.h: ... this.
1405 * gnulib/import/canonicalize-lgpl.c: Update.
1406 * gnulib/import/cdefs.h: Update.
1407 * gnulib/import/chdir-long.c: Update.
1408 * gnulib/import/chdir-long.h: Update.
1409 * gnulib/import/cloexec.c: Update.
1410 * gnulib/import/cloexec.h: Update.
1411 * gnulib/import/close.c: Update.
1412 * gnulib/import/closedir.c: Update.
1413 * gnulib/import/config.charset: Update.
1414 * gnulib/import/dirent-private.h: Update.
1415 * gnulib/import/dirent.in.h: Update.
1416 * gnulib/import/dirfd.c: Update.
1417 * gnulib/import/dirname-lgpl.c: Update.
1418 * gnulib/import/dirname.h: Update.
1419 * gnulib/import/dosname.h: Update.
1420 * gnulib/import/dup-safer-flag.c: Update.
1421 * gnulib/import/dup-safer.c: Update.
1422 * gnulib/import/dup.c: Update.
1423 * gnulib/import/dup2.c: Update.
1424 * gnulib/import/errno.in.h: Update.
1425 * gnulib/import/error.c: Update.
1426 * gnulib/import/error.h: Update.
1427 * gnulib/import/exitfail.c: Update.
1428 * gnulib/import/exitfail.h: Update.
1429 * gnulib/import/extra/update-copyright: Update.
1430 * gnulib/import/fchdir.c: Update.
1431 * gnulib/import/fcntl.c: Update.
1432 * gnulib/import/fcntl.in.h: Update.
1433 * gnulib/import/fd-hook.c: Update.
1434 * gnulib/import/fd-hook.h: Update.
1435 * gnulib/import/fd-safer-flag.c: Update.
1436 * gnulib/import/fd-safer.c: Update.
1437 * gnulib/import/fdopendir.c: Update.
1438 * gnulib/import/filename.h: Update.
1439 * gnulib/import/filenamecat-lgpl.c: Update.
1440 * gnulib/import/filenamecat.h: Update.
1441 * gnulib/import/flexmember.h: Update.
1442 * gnulib/import/float+.h: Update.
1443 * gnulib/import/float.c: Update.
1444 * gnulib/import/float.in.h: Update.
1445 * gnulib/import/fnmatch.c: Update.
1446 * gnulib/import/fnmatch.in.h: Update.
1447 * gnulib/import/fnmatch_loop.c: Update.
1448 * gnulib/import/fpucw.h: Update.
1449 * gnulib/import/frexp.c: Update.
1450 * gnulib/import/frexpl.c: Update.
1451 * gnulib/import/fstat.c: Update.
1452 * gnulib/import/fstatat.c: Update.
1453 * gnulib/import/getcwd-lgpl.c: Update.
1454 * gnulib/import/getcwd.c: Update.
1455 * gnulib/import/getdtablesize.c: Update.
1456 * gnulib/import/getlogin_r.c: Update.
1457 * gnulib/import/getprogname.c: Update.
1458 * gnulib/import/getprogname.h: Update.
1459 * gnulib/import/gettext.h: Update.
1460 * gnulib/import/gettimeofday.c: Update.
1461 * gnulib/import/glob-libc.h: Update.
1462 * gnulib/import/glob.c: Update.
1463 * gnulib/import/glob.in.h: Update.
1464 * gnulib/import/glob_internal.h: Update.
1465 * gnulib/import/glob_pattern_p.c: Update.
1466 * gnulib/import/globfree.c: Update.
1467 * gnulib/import/hard-locale.c: Update.
1468 * gnulib/import/hard-locale.h: Update.
1469 * gnulib/import/intprops.h: Update.
1470 * gnulib/import/inttypes.in.h: Update.
1471 * gnulib/import/isnan.c: Update.
1472 * gnulib/import/isnand-nolibm.h: Update.
1473 * gnulib/import/isnand.c: Update.
1474 * gnulib/import/isnanl-nolibm.h: Update.
1475 * gnulib/import/isnanl.c: Update.
1476 * gnulib/import/itold.c: Update.
1477 * gnulib/import/libc-config.h: Update.
1478 * gnulib/import/limits.in.h: Update.
1479 * gnulib/import/localcharset.c: Update.
1480 * gnulib/import/localcharset.h: Update.
1481 * gnulib/import/localtime-buffer.c: Update.
1482 * gnulib/import/localtime-buffer.h: Update.
1483 * gnulib/import/lstat.c: Update.
1484 * gnulib/import/m4/00gnulib.m4: Update.
1485 * gnulib/import/m4/__inline.m4: Update.
1486 * gnulib/import/m4/absolute-header.m4: Update.
1487 * gnulib/import/m4/alloca.m4: Update.
1488 * gnulib/import/m4/builtin-expect.m4: Update.
1489 * gnulib/import/m4/canonicalize.m4: Update.
1490 * gnulib/import/m4/chdir-long.m4: Update.
1491 * gnulib/import/m4/close.m4: Update.
1492 * gnulib/import/m4/closedir.m4: Update.
1493 * gnulib/import/m4/configmake.m4: Update.
1494 * gnulib/import/m4/d-ino.m4: Update.
1495 * gnulib/import/m4/d-type.m4: Update.
1496 * gnulib/import/m4/dirent_h.m4: Update.
1497 * gnulib/import/m4/dirfd.m4: Update.
1498 * gnulib/import/m4/dirname.m4: Update.
1499 * gnulib/import/m4/double-slash-root.m4: Update.
1500 * gnulib/import/m4/dup.m4: Update.
1501 * gnulib/import/m4/dup2.m4: Update.
1502 * gnulib/import/m4/eealloc.m4: Update.
1503 * gnulib/import/m4/environ.m4: Update.
1504 * gnulib/import/m4/errno_h.m4: Update.
1505 * gnulib/import/m4/error.m4: Update.
1506 * gnulib/import/m4/exponentd.m4: Update.
1507 * gnulib/import/m4/exponentl.m4: Update.
1508 * gnulib/import/m4/extensions.m4: Update.
1509 * gnulib/import/m4/extern-inline.m4: Update.
1510 * gnulib/import/m4/fchdir.m4: Update.
1511 * gnulib/import/m4/fcntl-o.m4: Update.
1512 * gnulib/import/m4/fcntl.m4: Update.
1513 * gnulib/import/m4/fcntl_h.m4: Update.
1514 * gnulib/import/m4/fdopendir.m4: Update.
1515 * gnulib/import/m4/filenamecat.m4: Update.
1516 * gnulib/import/m4/flexmember.m4: Update.
1517 * gnulib/import/m4/float_h.m4: Update.
1518 * gnulib/import/m4/fnmatch.m4: Update.
1519 * gnulib/import/m4/fnmatch_h.m4: Update.
1520 * gnulib/import/m4/fpieee.m4: Update.
1521 * gnulib/import/m4/frexp.m4: Update.
1522 * gnulib/import/m4/frexpl.m4: Update.
1523 * gnulib/import/m4/fstat.m4: Update.
1524 * gnulib/import/m4/fstatat.m4: Update.
1525 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1526 * gnulib/import/m4/getcwd-path-max.m4: Update.
1527 * gnulib/import/m4/getcwd.m4: Update.
1528 * gnulib/import/m4/getdtablesize.m4: Update.
1529 * gnulib/import/m4/getlogin.m4: Update.
1530 * gnulib/import/m4/getlogin_r.m4: Update.
1531 * gnulib/import/m4/getpagesize.m4: Update.
1532 * gnulib/import/m4/getprogname.m4: Update.
1533 * gnulib/import/m4/gettimeofday.m4: Update.
1534 * gnulib/import/m4/glibc21.m4: Update.
1535 * gnulib/import/m4/glob.m4: Update.
1536 * gnulib/import/m4/glob_h.m4: Update.
1537 * gnulib/import/m4/gnulib-cache.m4: Update.
1538 * gnulib/import/m4/gnulib-common.m4: Update.
1539 * gnulib/import/m4/gnulib-comp.m4: Update.
1540 * gnulib/import/m4/gnulib-tool.m4: Update.
1541 * gnulib/import/m4/hard-locale.m4: Update.
1542 * gnulib/import/m4/include_next.m4: Update.
1543 * gnulib/import/m4/inttypes-pri.m4: Update.
1544 * gnulib/import/m4/inttypes.m4: Update.
1545 * gnulib/import/m4/isnand.m4: Update.
1546 * gnulib/import/m4/isnanl.m4: Update.
1547 * gnulib/import/m4/largefile.m4: Update.
1548 * gnulib/import/m4/limits-h.m4: Update.
1549 * gnulib/import/m4/localcharset.m4: Update.
1550 * gnulib/import/m4/locale-fr.m4: Update.
1551 * gnulib/import/m4/locale-ja.m4: Update.
1552 * gnulib/import/m4/locale-zh.m4: Update.
1553 * gnulib/import/m4/localtime-buffer.m4: Update.
1554 * gnulib/import/m4/longlong.m4: Update.
1555 * gnulib/import/m4/lstat.m4: Update.
1556 * gnulib/import/m4/malloc.m4: Update.
1557 * gnulib/import/m4/malloca.m4: Update.
1558 * gnulib/import/m4/math_h.m4: Update.
1559 * gnulib/import/m4/mbrtowc.m4: Update.
1560 * gnulib/import/m4/mbsinit.m4: Update.
1561 * gnulib/import/m4/mbsrtowcs.m4: Update.
1562 * gnulib/import/m4/mbstate_t.m4: Update.
1563 * gnulib/import/m4/memchr.m4: Update.
1564 * gnulib/import/m4/memmem.m4: Update.
1565 * gnulib/import/m4/mempcpy.m4: Update.
1566 * gnulib/import/m4/memrchr.m4: Update.
1567 * gnulib/import/m4/mkdir.m4: Update.
1568 * gnulib/import/m4/mkstemp.m4: Update.
1569 * gnulib/import/m4/mmap-anon.m4: Update.
1570 * gnulib/import/m4/mode_t.m4: Update.
1571 * gnulib/import/m4/msvc-inval.m4: Update.
1572 * gnulib/import/m4/msvc-nothrow.m4: Update.
1573 * gnulib/import/m4/multiarch.m4: Update.
1574 * gnulib/import/m4/nocrash.m4: Update.
1575 * gnulib/import/m4/off_t.m4: Update.
1576 * gnulib/import/m4/onceonly.m4: Update.
1577 * gnulib/import/m4/open-cloexec.m4: Update.
1578 * gnulib/import/m4/open.m4: Update.
1579 * gnulib/import/m4/openat.m4: Update.
1580 * gnulib/import/m4/opendir.m4: Update.
1581 * gnulib/import/m4/pathmax.m4: Update.
1582 * gnulib/import/m4/rawmemchr.m4: Update.
1583 * gnulib/import/m4/readdir.m4: Update.
1584 * gnulib/import/m4/readlink.m4: Update.
1585 * gnulib/import/m4/realloc.m4: Update.
1586 * gnulib/import/m4/rename.m4: Update.
1587 * gnulib/import/m4/rewinddir.m4: Update.
1588 * gnulib/import/m4/rmdir.m4: Update.
1589 * gnulib/import/m4/save-cwd.m4: Update.
1590 * gnulib/import/m4/secure_getenv.m4: Update.
1591 * gnulib/import/m4/setenv.m4: Update.
1592 * gnulib/import/m4/signal_h.m4: Update.
1593 * gnulib/import/m4/ssize_t.m4: Update.
1594 * gnulib/import/m4/stat-time.m4: Update.
1595 * gnulib/import/m4/stat.m4: Update.
1596 * gnulib/import/m4/std-gnu11.m4: Update.
1597 * gnulib/import/m4/stdbool.m4: Update.
1598 * gnulib/import/m4/stddef_h.m4: Update.
1599 * gnulib/import/m4/stdint.m4: Update.
1600 * gnulib/import/m4/stdio_h.m4: Update.
1601 * gnulib/import/m4/stdlib_h.m4: Update.
1602 * gnulib/import/m4/strchrnul.m4: Update.
1603 * gnulib/import/m4/strdup.m4: Update.
1604 * gnulib/import/m4/strerror.m4: Update.
1605 * gnulib/import/m4/string_h.m4: Update.
1606 * gnulib/import/m4/strstr.m4: Update.
1607 * gnulib/import/m4/strtok_r.m4: Update.
1608 * gnulib/import/m4/sys_socket_h.m4: Update.
1609 * gnulib/import/m4/sys_stat_h.m4: Update.
1610 * gnulib/import/m4/sys_time_h.m4: Update.
1611 * gnulib/import/m4/sys_types_h.m4: Update.
1612 * gnulib/import/m4/tempname.m4: Update.
1613 * gnulib/import/m4/time_h.m4: Update.
1614 * gnulib/import/m4/unistd-safer.m4: Update.
1615 * gnulib/import/m4/unistd_h.m4: Update.
1616 * gnulib/import/m4/warn-on-use.m4: Update.
1617 * gnulib/import/m4/wchar_h.m4: Update.
1618 * gnulib/import/m4/wchar_t.m4: Update.
1619 * gnulib/import/m4/wctype_h.m4: Update.
1620 * gnulib/import/m4/wint_t.m4: Update.
1621 * gnulib/import/malloc.c: Update.
1622 * gnulib/import/malloc/scratch_buffer.h: Update.
1623 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1624 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1625 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1626 * gnulib/import/malloca.c: Update.
1627 * gnulib/import/malloca.h: Update.
1628 * gnulib/import/malloca.valgrind: Update.
1629 * gnulib/import/math.in.h: Update.
1630 * gnulib/import/mbrtowc.c: Update.
1631 * gnulib/import/mbsinit.c: Update.
1632 * gnulib/import/mbsrtowcs-impl.h: Update.
1633 * gnulib/import/mbsrtowcs-state.c: Update.
1634 * gnulib/import/mbsrtowcs.c: Update.
1635 * gnulib/import/memchr.c: Update.
1636 * gnulib/import/memmem.c: Update.
1637 * gnulib/import/mempcpy.c: Update.
1638 * gnulib/import/memrchr.c: Update.
1639 * gnulib/import/mkdir.c: Update.
1640 * gnulib/import/mkstemp.c: Update.
1641 * gnulib/import/msvc-inval.c: Update.
1642 * gnulib/import/msvc-inval.h: Update.
1643 * gnulib/import/msvc-nothrow.c: Update.
1644 * gnulib/import/msvc-nothrow.h: Update.
1645 * gnulib/import/open.c: Update.
1646 * gnulib/import/openat-die.c: Update.
1647 * gnulib/import/openat-priv.h: Update.
1648 * gnulib/import/openat-proc.c: Update.
1649 * gnulib/import/openat.c: Update.
1650 * gnulib/import/openat.h: Update.
1651 * gnulib/import/opendir.c: Update.
1652 * gnulib/import/pathmax.h: Update.
1653 * gnulib/import/pipe-safer.c: Update.
1654 * gnulib/import/rawmemchr.c: Update.
1655 * gnulib/import/readdir.c: Update.
1656 * gnulib/import/readlink.c: Update.
1657 * gnulib/import/realloc.c: Update.
1658 * gnulib/import/ref-add.sin: Update.
1659 * gnulib/import/ref-del.sin: Update.
1660 * gnulib/import/rename.c: Update.
1661 * gnulib/import/rewinddir.c: Update.
1662 * gnulib/import/rmdir.c: Update.
1663 * gnulib/import/same-inode.h: Update.
1664 * gnulib/import/save-cwd.c: Update.
1665 * gnulib/import/save-cwd.h: Update.
1666 * gnulib/import/scratch_buffer.h: Update.
1667 * gnulib/import/secure_getenv.c: Update.
1668 * gnulib/import/setenv.c: Update.
1669 * gnulib/import/signal.in.h: Update.
1670 * gnulib/import/stat-time.c: Update.
1671 * gnulib/import/stat-time.h: Update.
1672 * gnulib/import/stat-w32.c: Update.
1673 * gnulib/import/stat-w32.h: Update.
1674 * gnulib/import/stat.c: Update.
1675 * gnulib/import/stdbool.in.h: Update.
1676 * gnulib/import/stddef.in.h: Update.
1677 * gnulib/import/stdint.in.h: Update.
1678 * gnulib/import/stdio.in.h: Update.
1679 * gnulib/import/stdlib.in.h: Update.
1680 * gnulib/import/str-two-way.h: Update.
1681 * gnulib/import/strchrnul.c: Update.
1682 * gnulib/import/strdup.c: Update.
1683 * gnulib/import/streq.h: Update.
1684 * gnulib/import/strerror-override.c: Update.
1685 * gnulib/import/strerror-override.h: Update.
1686 * gnulib/import/strerror.c: Update.
1687 * gnulib/import/string.in.h: Update.
1688 * gnulib/import/stripslash.c: Update.
1689 * gnulib/import/strnlen1.c: Update.
1690 * gnulib/import/strnlen1.h: Update.
1691 * gnulib/import/strstr.c: Update.
1692 * gnulib/import/strtok_r.c: Update.
1693 * gnulib/import/sys_stat.in.h: Update.
1694 * gnulib/import/sys_time.in.h: Update.
1695 * gnulib/import/sys_types.in.h: Update.
1696 * gnulib/import/tempname.c: Update.
1697 * gnulib/import/tempname.h: Update.
1698 * gnulib/import/time.in.h: Update.
1699 * gnulib/import/unistd--.h: Update.
1700 * gnulib/import/unistd-safer.h: Update.
1701 * gnulib/import/unistd.in.h: Update.
1702 * gnulib/import/unsetenv.c: Update.
1703 * gnulib/import/verify.h: Update.
1704 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1705 * gnulib/import/wchar.in.h: Update.
1706 * gnulib/import/wctype.in.h: Update.
1707 * gnulib/import/xalloc-oversized.h: Update.
1708 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1709 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1711 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
1713 * record-btrace.c (get_thread_current_frame): Remove
1716 2018-09-10 Jerome Guitton <guitton@adacore.com>
1718 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
1719 with check_tag to 1 if and only if the type is tagged and the
1720 component being searched cannot been found in the current
1721 view. Otherwise, always call ada_to_fixed_type with
1724 2018-09-10 Xavier Roirand <roirand@adacore.com>
1726 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
1728 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
1729 * ada-varobj.c (ada_varobj_get_number_of_children,
1730 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
1732 2018-09-10 Xavier Roirand <roirand@adacore.com>
1734 * ada-valprint.c (ada_value_print): Use type instead of
1737 2018-09-10 Xavier Roirand <roirand@adacore.com>
1739 * ada-lang.c (ada_value_subscript): Handle case when parameter is
1740 an array of access to unconstrained array.
1742 2018-09-10 Xavier Roirand <roirand@adacore.com>
1744 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
1745 (ada_check_typedef): Use it.
1747 2018-09-10 Xavier Roirand <roirand@adacore.com>
1749 * ada-varobj.c (ada_varobj_describe_struct_child)
1750 (ada_varobj_describe_child): Handle union case like struct one.
1752 2018-09-10 Tom Tromey <tom@tromey.com>
1755 * python/python.c (_initialize_python): Make example in "python"
1756 help work in Python 3.
1758 2018-09-10 Eli Zaretskii <eliz@gnu.org>
1760 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
1761 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
1762 $(EXEEXT) to the script, as it is not a program.
1764 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
1766 * python/py-prettyprint.c (pretty_print_one_value): Return
1768 (print_string_repr): Adjust.
1769 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
1770 * python/python-internal.h (apply_varobj_pretty_printer): Return
1772 * varobj.c (varobj_value_get_print_value): Adjust.
1774 2018-09-08 Tom Tromey <tom@tromey.com>
1777 * python/py-prettyprint.c (pretty_print_one_value): Check for
1780 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1782 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
1783 replace_operator_with_call.
1785 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1787 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
1789 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1791 * ada-typeprint.c (print_range): Print the bounds using TYPE
1792 rather than its TYPE_TARGET_TYPE.
1794 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1796 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
1797 call to ada_to_fixed_value_create.
1799 2018-09-08 Jerome Guitton <guitton@adacore.com>
1801 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
1803 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1805 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
1808 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1810 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
1811 Move update of loop variable "fi".
1813 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1815 * ada-lang.c (value_assign_to_component): In the case of
1816 big-endian targets, extract the bits of the given VAL
1817 using an src_offset of zero if container is not a scalar.
1819 2018-09-06 Simon Ser <contact@emersion.fr>
1822 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
1823 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1824 * fbsd-tdep.c (fbsd_make_note_desc): New.
1825 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
1826 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
1827 * target.h (enum target_object) Add FreeBSD-specific
1828 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1830 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1832 * compile/compile-c.h (generate_c_for_variable_locations):
1833 Change reference to pointer.
1834 * compile/compile-c-support.c (compile_program) <compute>:
1836 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
1837 (generate_c_for_for_one_variable): Likewise
1838 (generate_c_for_variable_locations): Likewise
1839 * compile/compile-c-types.c (compile_c_instance::convert_type):
1841 * compile/compile-cplus-symbols.c (convert_one_symbol):
1842 std::move the scope passed to enter_scope.
1843 * compile/compile-cplus-types.c
1844 (compile_cplus_instance::enter_scope): Make parameter
1846 (compile_cplus_instance::new_scope): Change reference to
1848 (compile_cplus_instance::convert_type): Likewise
1849 (compile_cplus_convert_typedef): std::move the scope passed to
1851 (compile_cplus_convert_struct_or_union): Likewise.
1852 (compile_cplus_convert_enum): Likewise.
1853 (compile_cplus_convert_namespace): Likewise.
1854 * compile/compile-cplus.h (compile_cplus_instance)
1855 <enter_scope>: Make parameter rvalue-reference.
1856 * compile/compile-internal.h (compile_instance)
1857 <get_cached_type>: Likewise
1858 * compile/compile-loc2c.c (push): Likewise
1862 (print_label): Likewise
1863 (pushf_register_address): Likewise
1864 (pushf_register): Likewise
1865 (do_compile_dwarf_expr_to_c): Likewise
1866 (compile_dwarf_expr_to_c): Likewise
1867 (compile_dwarf_bounds_to_c): Likewise
1868 * compile/compile.c (compile_instance::get_cached_type):
1870 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
1871 (compile_dwarf_bounds_to_c): Likewise
1872 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
1873 (dwarf2_compile_property_to_c): Likewise
1874 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
1875 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1878 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1880 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
1881 * tui/tui-data.c (init_content_element): Don't initialize it.
1883 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1885 * tui/tui-data.h (struct tui_win_info)
1886 <detail::opaque>: Remove.
1887 * tui/tui-data.c (init_win_info): Remove assignment.
1889 2018-09-05 Tom Tromey <tom@tromey.com>
1891 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
1892 -Wformat-nonliteral.
1893 * target-float.c (host_float_ops<T>::to_string)
1894 (host_float_ops<T>::from_string): Use
1895 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1896 * configure: Rebuild.
1898 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
1900 * printcmd.c (printf_c_string): Use
1901 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1902 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
1904 2018-09-05 Tom Tromey <tom@tromey.com>
1906 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
1908 2018-09-05 Tom de Vries <tdevries@suse.de>
1910 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1911 with resolve_abstract_p == true.
1912 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1913 defaulting to false. Propagate resolve_abstract_p to
1914 dwarf2_fetch_die_loc_sect_off.
1915 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1916 parameter, defaulting to false.
1917 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1918 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1920 * dwarf2read.h (struct die_info): Forward-declare.
1921 (die_info_ptr): New typedef.
1922 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1924 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1928 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1929 Pedro Alves <palves@redhat.com>
1931 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1932 "aclocal-m4-deps.mk". Include file here.
1933 $(srcdir)/aclocal.m4: Add "configure.ac".
1934 * gnulib/aclocal-m4-deps.mk: New file.
1935 * gnulib/update-gnulib.sh: Automatically update
1936 "aclocal-m4-deps.mk".
1938 2018-09-04 Tom Tromey <tom@tromey.com>
1940 * configure: Rebuild.
1941 * configure.ac: Remove multi-ice code.
1943 2018-09-04 Tom Tromey <tom@tromey.com>
1945 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
1946 (ada-exp.o): Update.
1948 2018-09-04 Tom Tromey <tom@tromey.com>
1950 * Makefile.in (printcmd.o, target-float.o): Remove.
1951 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
1953 2018-09-04 Tom Tromey <tom@tromey.com>
1955 * gnulib/Makefile.in: Remove obsolete comment.
1956 * Makefile.in: Remove obsolete comment.
1958 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
1960 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
1963 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1965 * riscv-tdep.c: Add 'prologue-value.h' include.
1966 (struct riscv_unwind_cache): New struct.
1967 (riscv_debug_unwinder): New global.
1968 (riscv_scan_prologue): Update arguments, capture register details
1970 (riscv_skip_prologue): Reformat arguments line, move end of
1971 prologue calculation into riscv_scan_prologue.
1972 (riscv_frame_cache): Update return type, create
1973 riscv_unwind_cache, scan the prologue, and fill in remaining cache
1975 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
1976 (riscv_frame_prev_register): Use the trad_frame within the
1978 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
1981 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1983 * trad-frame.h (trad_frame_set_realreg): Declare.
1984 (trad_frame_set_addr): Declare.
1985 * trad-frame.c (trad_frame_set_realreg): Define new function.
1986 (trad_frame_set_addr): Define new function.
1987 (trad_frame_set_reg_realreg): Use new function.
1988 (trad_frame_set_reg_addr): Use new function.
1990 2018-09-01 Keith Seitz <keiths@redhat.com>
1992 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
1993 pulongest instead of "%lld".
1994 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
1997 2018-08-31 Tom Tromey <tom@tromey.com>
1999 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
2002 2018-08-31 Pedro Alves <palves@redhat.com>
2004 * gdbarch.h: Regenerate.
2006 2018-08-31 Pedro Alves <palves@redhat.com>
2008 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
2009 * target.h (Hardware watchpoint interfaces): Describe
2010 continuable/steppable/non-steppable watchpoints.
2011 * gdbarch.h, gdbarch.c: Regenerate.
2013 2018-08-31 Pedro Alves <palves@redhat.com>
2015 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
2018 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
2019 * target.h (target_ops::have_continuable_watchpoint): Delete.
2020 (target_have_continuable_watchpoint): Delete.
2021 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
2022 * target-delegates.c: Regenerate.
2024 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2026 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
2027 the files present in "gnulib/import/m4/".
2029 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2031 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
2032 c.sw, c.swsp, and c.sdsp.
2034 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2036 * riscv-tdep.c (struct riscv_inferior_data): Delete.
2037 (riscv_read_misa_reg): Don't cache value read into inferior data.
2038 (riscv_new_inferior_data): Delete.
2039 (riscv_inferior_data_cleanup): Delete.
2040 (riscv_inferior_data): Delete.
2041 (riscv_invalidate_inferior_data): Delete.
2042 (_initialize_riscv_tdep): Remove initialisation of inferior data.
2044 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
2046 * compile/compile-cplus-types.c
2047 (compile_cplus_instance::leave_scope): Take the address of scope
2049 (compile_cplus_instance::convert_qualified_base): Compare quals
2052 2018-08-30 Keith Seitz <keiths@redhat.com>
2054 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
2055 Use "%s" and host_address_to_string instead of "%p" in printf.
2057 2018-08-29 Keith Seitz <keiths@redhat.com>
2059 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
2060 and compile-cplus-types.c.
2061 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
2062 * c-lang.c (cplus_language_defn): Set C++ compile functions.
2063 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
2065 * compile/compile-c-support.c: Include compile-cplus.h.
2066 (load_libcompile): Templatize.
2067 (get_compile_context): "New" function.
2068 (c_get_compile_context): Use get_compile_context.
2069 (cplus_get_compile_context): New function.
2070 (cplus_push_user_expression, cplus_pop_user_expression)
2071 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
2072 (cplus_compute_program): Define new structs/functions.
2073 * compile/compile-cplus-symmbols.c: New file.
2074 * compile/compile-cplus-types.c: New file.
2075 * compile/compile-cplus.h: New file.
2076 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
2078 * compile/compile-object-load.c (get_out_value_type): Use
2079 strncmp_iw when comparing symbol names.
2080 (compile_object_load): Add mst_bss and mst_data.
2081 * compile/compile.c (_initialize_compile): Remove
2082 -Wno-implicit-function-declaration from `compile_args'.
2083 * compile/gcc-cp-plugin.h: New file.
2084 * NEWS: Mention C++ compile support and new debug options.
2086 2018-08-29 Keith Seitz <keiths@redhat.com>
2088 * linespec.c (collect_info::add_symbol): Make virtual.
2089 (struct symbol_searcher_collect_info): New struct.
2090 (symbol_searcher::find_all_symbols): New method.
2091 * symtab.h (class symbol_searcher): New class.
2093 2018-08-29 Keith Seitz <keiths@redhat.com>
2095 * linespec.c (struct linespec) <function_symbols, label_symbols>:
2096 Change to vector of block_symbol. Update all users.
2097 (struct collect_info) <symbols>: Likewise.
2098 (collect_info::add_symbol): Take block_symbol as argument.
2100 (decode_compound_collector) <m_symbols>: Change type to vector
2101 of block_symbol. Update all users.
2102 (decode_compound_collector::operator ()): Change parameter type
2104 (find_method, find_function_symbols, find_linespec_symbols)
2105 (find_label_symbols_in_block, find_label_symbols): Change symbol
2106 vectors to block_symbol vectors.
2107 * symtab.h (symbol_found_callback_ftype): Change parameter type to
2110 2018-08-29 Keith Seitz <keiths@redhat.com>
2112 * linespec.c (symbolp): Remove typedef and VEC definitions.
2113 (bound_minimal_symbol_d): Likewise.
2115 2018-08-29 Keith Seitz <keiths@redhat.com>
2117 * linespec.c (decode_compound_collector::decode_compound_collector):
2118 Remove initialization for `m_symtabs'.
2119 (decode_compound_collector::release_symbols): Change return type
2120 to std::vector. Update all callers.
2121 (class decode_compound_collector) <m_symbols>: Change type to
2123 (lookup_prefix_sym): Change return type to std::vector. Update all
2125 (compare_symbols): Remove.
2126 (std_compare_symbols): Rename to `compare_symbols'.
2127 (find_method): Change `sym_classes' parameter to std::vector.
2128 Update all callers. Use std::sort to sort sym_classes.
2129 (find_linespec_symbols): Remove cleanup.
2131 2018-08-29 Keith Seitz <keiths@redhat.com>
2133 * linespec.c (struct linespec) <minimal_symbols>: Change type to
2134 std::vector. Update all users.
2135 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
2136 (struct collect_info) <minimal_symbols>: Likewise.
2137 (compare_msymbols): Return bool. Change parameters to const
2138 bound_minimal_symbol references.
2139 (find_method, find_function_symbols, find_linespec_symbols): Change
2140 `minsyms' parameter to std::vector. Update all callers.
2142 2018-08-29 Keith Seitz <keiths@redhat.com>
2144 * linespec.c (struct linespec) <label_symbols>: Change type to
2145 std::vector. Update all users.
2146 (find_label_symbols_in_block): Change `result' parameter to
2147 std::vector. Update all callers.
2148 (find_label_symbols): Return std::vector. Update all callers.
2150 2018-08-29 Keith Seitz <keiths@redhat.com>
2152 * linespec.c (struct linespec) <function_symbols>: Change type to
2153 std::vector. Update all users.
2154 (struct collect_info) <function_symbols>: Likewise.
2155 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
2156 (std_compare_symbols): New function.
2157 (find_method, find_function_symbols, find_linespec_symbols)
2158 (find_label_symbols_in_block): Change `symbols' parameter to
2159 std::vector. Update all callers.
2160 (find_label_symbols): Likewise for `function_symbols' and
2163 2018-08-29 Keith Seitz <keiths@redhat.com>
2165 * linespec.c (symtab_vector_up): Define.
2166 (struct linespec) <file_symtabs>: Change type to std::vector *.
2168 (struct collect_info) <file_symtabs>: Likewise.
2169 (collect_symtabs_from_filename): Return symtab_vector_up.
2171 (decode_objc): Remove cleanup.
2172 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
2173 (symtab_collector::release_symtabs): Return symtab_vector_up.
2175 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
2177 (collect_symtabs_from_filename, symtabs_from_filename): Return
2178 symtab_vector_up. Update all callers.
2180 2018-08-29 Tom Tromey <tom@tromey.com>
2182 * csky-tdep.c (csky_analyze_prologue): Use
2183 core_addr_to_string_nz.
2185 2018-08-29 Tom Tromey <tom@tromey.com>
2187 * windows-nat.c (struct xlate_exception) <them>: Change type to
2189 (xlate): Fix formatting. Remove last entry.
2190 (struct xlate_exception, xlate): Comment out.
2191 (windows_nat_target::resume): Use ranged for.
2193 2018-08-29 Jim Wilson <jimw@sifive.com>
2195 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
2196 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
2198 (riscv_linux_nat_target::store_registers): Likewise.
2200 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
2204 * gnulib/aclocal.m4: Regenerate.
2205 * gnulib/config.in: Regenerate.
2206 * gnulib/configure: Regenerate.
2207 * gnulib/import/Makefile.am: Update.
2208 * gnulib/import/Makefile.in: Update.
2209 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
2210 * gnulib/import/_Noreturn.h: ... this.
2211 * gnulib/import/alloca.in.h: Update.
2212 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
2213 * gnulib/import/arg-nonnull.h: ... this.
2214 * gnulib/import/assure.h: Update.
2215 * gnulib/import/at-func.c: Update.
2216 * gnulib/import/basename-lgpl.c: Update.
2217 * gnulib/import/extra/snippet/c++defs.h: Rename to...
2218 * gnulib/import/c++defs.h: ... this.
2219 * gnulib/import/canonicalize-lgpl.c: Update.
2220 * gnulib/import/cdefs.h: Update.
2221 * gnulib/import/chdir-long.c: Update.
2222 * gnulib/import/chdir-long.h: Update.
2223 * gnulib/import/cloexec.c: Update.
2224 * gnulib/import/cloexec.h: Update.
2225 * gnulib/import/close.c: Update.
2226 * gnulib/import/closedir.c: Update.
2227 * gnulib/import/config.charset: Update.
2228 * gnulib/import/dirent-private.h: Update.
2229 * gnulib/import/dirent.in.h: Update.
2230 * gnulib/import/dirfd.c: Update.
2231 * gnulib/import/dirname-lgpl.c: Update.
2232 * gnulib/import/dirname.h: Update.
2233 * gnulib/import/dosname.h: Update.
2234 * gnulib/import/dup-safer-flag.c: Update.
2235 * gnulib/import/dup-safer.c: Update.
2236 * gnulib/import/dup.c: Update.
2237 * gnulib/import/dup2.c: Update.
2238 * gnulib/import/errno.in.h: Update.
2239 * gnulib/import/error.c: Update.
2240 * gnulib/import/error.h: Update.
2241 * gnulib/import/exitfail.c: Update.
2242 * gnulib/import/exitfail.h: Update.
2243 * gnulib/import/extra/update-copyright: Update.
2244 * gnulib/import/fchdir.c: Update.
2245 * gnulib/import/fcntl.c: Update.
2246 * gnulib/import/fcntl.in.h: Update.
2247 * gnulib/import/fd-hook.c: Update.
2248 * gnulib/import/fd-hook.h: Update.
2249 * gnulib/import/fd-safer-flag.c: Update.
2250 * gnulib/import/fd-safer.c: Update.
2251 * gnulib/import/fdopendir.c: Update.
2252 * gnulib/import/filename.h: Update.
2253 * gnulib/import/filenamecat-lgpl.c: Update.
2254 * gnulib/import/filenamecat.h: Update.
2255 * gnulib/import/flexmember.h: Update.
2256 * gnulib/import/float+.h: Update.
2257 * gnulib/import/float.c: Update.
2258 * gnulib/import/float.in.h: Update.
2259 * gnulib/import/fnmatch.c: Update.
2260 * gnulib/import/fnmatch.in.h: Update.
2261 * gnulib/import/fnmatch_loop.c: Update.
2262 * gnulib/import/fpucw.h: Update.
2263 * gnulib/import/frexp.c: Update.
2264 * gnulib/import/frexpl.c: Update.
2265 * gnulib/import/fstat.c: Update.
2266 * gnulib/import/fstatat.c: Update.
2267 * gnulib/import/getcwd-lgpl.c: Update.
2268 * gnulib/import/getcwd.c: Update.
2269 * gnulib/import/getdtablesize.c: Update.
2270 * gnulib/import/getlogin_r.c: Update.
2271 * gnulib/import/getprogname.c: Update.
2272 * gnulib/import/getprogname.h: Update.
2273 * gnulib/import/gettext.h: Update.
2274 * gnulib/import/gettimeofday.c: Update.
2275 * gnulib/import/glob-libc.h: Update.
2276 * gnulib/import/glob.c: Update.
2277 * gnulib/import/glob.in.h: Update.
2278 * gnulib/import/glob_internal.h: Update.
2279 * gnulib/import/glob_pattern_p.c: Update.
2280 * gnulib/import/globfree.c: Update.
2281 * gnulib/import/hard-locale.c: Update.
2282 * gnulib/import/hard-locale.h: Update.
2283 * gnulib/import/intprops.h: Update.
2284 * gnulib/import/inttypes.in.h: Update.
2285 * gnulib/import/isnan.c: Update.
2286 * gnulib/import/isnand-nolibm.h: Update.
2287 * gnulib/import/isnand.c: Update.
2288 * gnulib/import/isnanl-nolibm.h: Update.
2289 * gnulib/import/isnanl.c: Update.
2290 * gnulib/import/itold.c: Update.
2291 * gnulib/import/libc-config.h: Update.
2292 * gnulib/import/limits.in.h: Update.
2293 * gnulib/import/localcharset.c: Update.
2294 * gnulib/import/localcharset.h: Update.
2295 * gnulib/import/localtime-buffer.c: Update.
2296 * gnulib/import/localtime-buffer.h: Update.
2297 * gnulib/import/lstat.c: Update.
2298 * gnulib/import/m4/00gnulib.m4: Update.
2299 * gnulib/import/m4/__inline.m4: Update.
2300 * gnulib/import/m4/absolute-header.m4: Update.
2301 * gnulib/import/m4/alloca.m4: Update.
2302 * gnulib/import/m4/builtin-expect.m4: Update.
2303 * gnulib/import/m4/canonicalize.m4: Update.
2304 * gnulib/import/m4/chdir-long.m4: Update.
2305 * gnulib/import/m4/close.m4: Update.
2306 * gnulib/import/m4/closedir.m4: Update.
2307 * gnulib/import/m4/configmake.m4: Update.
2308 * gnulib/import/m4/d-ino.m4: Update.
2309 * gnulib/import/m4/d-type.m4: Update.
2310 * gnulib/import/m4/dirent_h.m4: Update.
2311 * gnulib/import/m4/dirfd.m4: Update.
2312 * gnulib/import/m4/dirname.m4: Update.
2313 * gnulib/import/m4/double-slash-root.m4: Update.
2314 * gnulib/import/m4/dup.m4: Update.
2315 * gnulib/import/m4/dup2.m4: Update.
2316 * gnulib/import/m4/eealloc.m4: Update.
2317 * gnulib/import/m4/environ.m4: Update.
2318 * gnulib/import/m4/errno_h.m4: Update.
2319 * gnulib/import/m4/error.m4: Update.
2320 * gnulib/import/m4/exponentd.m4: Update.
2321 * gnulib/import/m4/exponentl.m4: Update.
2322 * gnulib/import/m4/extensions.m4: Update.
2323 * gnulib/import/m4/extern-inline.m4: Update.
2324 * gnulib/import/m4/fchdir.m4: Update.
2325 * gnulib/import/m4/fcntl-o.m4: Update.
2326 * gnulib/import/m4/fcntl.m4: Update.
2327 * gnulib/import/m4/fcntl_h.m4: Update.
2328 * gnulib/import/m4/fdopendir.m4: Update.
2329 * gnulib/import/m4/filenamecat.m4: Update.
2330 * gnulib/import/m4/flexmember.m4: Update.
2331 * gnulib/import/m4/float_h.m4: Update.
2332 * gnulib/import/m4/fnmatch.m4: Update.
2333 * gnulib/import/m4/fnmatch_h.m4: Update.
2334 * gnulib/import/m4/fpieee.m4: Update.
2335 * gnulib/import/m4/frexp.m4: Update.
2336 * gnulib/import/m4/frexpl.m4: Update.
2337 * gnulib/import/m4/fstat.m4: Update.
2338 * gnulib/import/m4/fstatat.m4: Update.
2339 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
2340 * gnulib/import/m4/getcwd-path-max.m4: Update.
2341 * gnulib/import/m4/getcwd.m4: Update.
2342 * gnulib/import/m4/getdtablesize.m4: Update.
2343 * gnulib/import/m4/getlogin.m4: Update.
2344 * gnulib/import/m4/getlogin_r.m4: Update.
2345 * gnulib/import/m4/getpagesize.m4: Update.
2346 * gnulib/import/m4/getprogname.m4: Update.
2347 * gnulib/import/m4/gettimeofday.m4: Update.
2348 * gnulib/import/m4/glibc21.m4: Update.
2349 * gnulib/import/m4/glob.m4: Update.
2350 * gnulib/import/m4/glob_h.m4: Update.
2351 * gnulib/import/m4/gnulib-cache.m4: Update.
2352 * gnulib/import/m4/gnulib-common.m4: Update.
2353 * gnulib/import/m4/gnulib-comp.m4: Update.
2354 * gnulib/import/m4/gnulib-tool.m4: Update.
2355 * gnulib/import/m4/hard-locale.m4: Update.
2356 * gnulib/import/m4/include_next.m4: Update.
2357 * gnulib/import/m4/inttypes-pri.m4: Update.
2358 * gnulib/import/m4/inttypes.m4: Update.
2359 * gnulib/import/m4/isnand.m4: Update.
2360 * gnulib/import/m4/isnanl.m4: Update.
2361 * gnulib/import/m4/largefile.m4: Update.
2362 * gnulib/import/m4/limits-h.m4: Update.
2363 * gnulib/import/m4/localcharset.m4: Update.
2364 * gnulib/import/m4/locale-fr.m4: Update.
2365 * gnulib/import/m4/locale-ja.m4: Update.
2366 * gnulib/import/m4/locale-zh.m4: Update.
2367 * gnulib/import/m4/localtime-buffer.m4: Update.
2368 * gnulib/import/m4/longlong.m4: Update.
2369 * gnulib/import/m4/lstat.m4: Update.
2370 * gnulib/import/m4/malloc.m4: Update.
2371 * gnulib/import/m4/malloca.m4: Update.
2372 * gnulib/import/m4/math_h.m4: Update.
2373 * gnulib/import/m4/mbrtowc.m4: Update.
2374 * gnulib/import/m4/mbsinit.m4: Update.
2375 * gnulib/import/m4/mbsrtowcs.m4: Update.
2376 * gnulib/import/m4/mbstate_t.m4: Update.
2377 * gnulib/import/m4/memchr.m4: Update.
2378 * gnulib/import/m4/memmem.m4: Update.
2379 * gnulib/import/m4/mempcpy.m4: Update.
2380 * gnulib/import/m4/memrchr.m4: Update.
2381 * gnulib/import/m4/mkdir.m4: Update.
2382 * gnulib/import/m4/mkstemp.m4: Update.
2383 * gnulib/import/m4/mmap-anon.m4: Update.
2384 * gnulib/import/m4/mode_t.m4: Update.
2385 * gnulib/import/m4/msvc-inval.m4: Update.
2386 * gnulib/import/m4/msvc-nothrow.m4: Update.
2387 * gnulib/import/m4/multiarch.m4: Update.
2388 * gnulib/import/m4/nocrash.m4: Update.
2389 * gnulib/import/m4/off_t.m4: Update.
2390 * gnulib/import/m4/onceonly.m4: Update.
2391 * gnulib/import/m4/open-cloexec.m4: Update.
2392 * gnulib/import/m4/open.m4: Update.
2393 * gnulib/import/m4/openat.m4: Update.
2394 * gnulib/import/m4/opendir.m4: Update.
2395 * gnulib/import/m4/pathmax.m4: Update.
2396 * gnulib/import/m4/rawmemchr.m4: Update.
2397 * gnulib/import/m4/readdir.m4: Update.
2398 * gnulib/import/m4/readlink.m4: Update.
2399 * gnulib/import/m4/realloc.m4: Update.
2400 * gnulib/import/m4/rename.m4: Update.
2401 * gnulib/import/m4/rewinddir.m4: Update.
2402 * gnulib/import/m4/rmdir.m4: Update.
2403 * gnulib/import/m4/save-cwd.m4: Update.
2404 * gnulib/import/m4/secure_getenv.m4: Update.
2405 * gnulib/import/m4/setenv.m4: Update.
2406 * gnulib/import/m4/signal_h.m4: Update.
2407 * gnulib/import/m4/ssize_t.m4: Update.
2408 * gnulib/import/m4/stat-time.m4: Update.
2409 * gnulib/import/m4/stat.m4: Update.
2410 * gnulib/import/m4/std-gnu11.m4: Update.
2411 * gnulib/import/m4/stdbool.m4: Update.
2412 * gnulib/import/m4/stddef_h.m4: Update.
2413 * gnulib/import/m4/stdint.m4: Update.
2414 * gnulib/import/m4/stdio_h.m4: Update.
2415 * gnulib/import/m4/stdlib_h.m4: Update.
2416 * gnulib/import/m4/strchrnul.m4: Update.
2417 * gnulib/import/m4/strdup.m4: Update.
2418 * gnulib/import/m4/strerror.m4: Update.
2419 * gnulib/import/m4/string_h.m4: Update.
2420 * gnulib/import/m4/strstr.m4: Update.
2421 * gnulib/import/m4/strtok_r.m4: Update.
2422 * gnulib/import/m4/sys_socket_h.m4: Update.
2423 * gnulib/import/m4/sys_stat_h.m4: Update.
2424 * gnulib/import/m4/sys_time_h.m4: Update.
2425 * gnulib/import/m4/sys_types_h.m4: Update.
2426 * gnulib/import/m4/tempname.m4: Update.
2427 * gnulib/import/m4/time_h.m4: Update.
2428 * gnulib/import/m4/unistd-safer.m4: Update.
2429 * gnulib/import/m4/unistd_h.m4: Update.
2430 * gnulib/import/m4/warn-on-use.m4: Update.
2431 * gnulib/import/m4/wchar_h.m4: Update.
2432 * gnulib/import/m4/wchar_t.m4: Update.
2433 * gnulib/import/m4/wctype_h.m4: Update.
2434 * gnulib/import/m4/wint_t.m4: Update.
2435 * gnulib/import/malloc.c: Update.
2436 * gnulib/import/malloc/scratch_buffer.h: Update.
2437 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
2438 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
2439 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
2440 * gnulib/import/malloca.c: Update.
2441 * gnulib/import/malloca.h: Update.
2442 * gnulib/import/malloca.valgrind: Update.
2443 * gnulib/import/math.in.h: Update.
2444 * gnulib/import/mbrtowc.c: Update.
2445 * gnulib/import/mbsinit.c: Update.
2446 * gnulib/import/mbsrtowcs-impl.h: Update.
2447 * gnulib/import/mbsrtowcs-state.c: Update.
2448 * gnulib/import/mbsrtowcs.c: Update.
2449 * gnulib/import/memchr.c: Update.
2450 * gnulib/import/memmem.c: Update.
2451 * gnulib/import/mempcpy.c: Update.
2452 * gnulib/import/memrchr.c: Update.
2453 * gnulib/import/mkdir.c: Update.
2454 * gnulib/import/mkstemp.c: Update.
2455 * gnulib/import/msvc-inval.c: Update.
2456 * gnulib/import/msvc-inval.h: Update.
2457 * gnulib/import/msvc-nothrow.c: Update.
2458 * gnulib/import/msvc-nothrow.h: Update.
2459 * gnulib/import/open.c: Update.
2460 * gnulib/import/openat-die.c: Update.
2461 * gnulib/import/openat-priv.h: Update.
2462 * gnulib/import/openat-proc.c: Update.
2463 * gnulib/import/openat.c: Update.
2464 * gnulib/import/openat.h: Update.
2465 * gnulib/import/opendir.c: Update.
2466 * gnulib/import/pathmax.h: Update.
2467 * gnulib/import/pipe-safer.c: Update.
2468 * gnulib/import/rawmemchr.c: Update.
2469 * gnulib/import/readdir.c: Update.
2470 * gnulib/import/readlink.c: Update.
2471 * gnulib/import/realloc.c: Update.
2472 * gnulib/import/ref-add.sin: Update.
2473 * gnulib/import/ref-del.sin: Update.
2474 * gnulib/import/rename.c: Update.
2475 * gnulib/import/rewinddir.c: Update.
2476 * gnulib/import/rmdir.c: Update.
2477 * gnulib/import/same-inode.h: Update.
2478 * gnulib/import/save-cwd.c: Update.
2479 * gnulib/import/save-cwd.h: Update.
2480 * gnulib/import/scratch_buffer.h: Update.
2481 * gnulib/import/secure_getenv.c: Update.
2482 * gnulib/import/setenv.c: Update.
2483 * gnulib/import/signal.in.h: Update.
2484 * gnulib/import/stat-time.c: Update.
2485 * gnulib/import/stat-time.h: Update.
2486 * gnulib/import/stat-w32.c: Update.
2487 * gnulib/import/stat-w32.h: Update.
2488 * gnulib/import/stat.c: Update.
2489 * gnulib/import/stdbool.in.h: Update.
2490 * gnulib/import/stddef.in.h: Update.
2491 * gnulib/import/stdint.in.h: Update.
2492 * gnulib/import/stdio.in.h: Update.
2493 * gnulib/import/stdlib.in.h: Update.
2494 * gnulib/import/str-two-way.h: Update.
2495 * gnulib/import/strchrnul.c: Update.
2496 * gnulib/import/strdup.c: Update.
2497 * gnulib/import/streq.h: Update.
2498 * gnulib/import/strerror-override.c: Update.
2499 * gnulib/import/strerror-override.h: Update.
2500 * gnulib/import/strerror.c: Update.
2501 * gnulib/import/string.in.h: Update.
2502 * gnulib/import/stripslash.c: Update.
2503 * gnulib/import/strnlen1.c: Update.
2504 * gnulib/import/strnlen1.h: Update.
2505 * gnulib/import/strstr.c: Update.
2506 * gnulib/import/strtok_r.c: Update.
2507 * gnulib/import/sys_stat.in.h: Update.
2508 * gnulib/import/sys_time.in.h: Update.
2509 * gnulib/import/sys_types.in.h: Update.
2510 * gnulib/import/tempname.c: Update.
2511 * gnulib/import/tempname.h: Update.
2512 * gnulib/import/time.in.h: Update.
2513 * gnulib/import/unistd--.h: Update.
2514 * gnulib/import/unistd-safer.h: Update.
2515 * gnulib/import/unistd.in.h: Update.
2516 * gnulib/import/unsetenv.c: Update.
2517 * gnulib/import/verify.h: Update.
2518 * gnulib/import/extra/snippet/warn-on-use.h: Update.
2519 * gnulib/import/wchar.in.h: Update.
2520 * gnulib/import/wctype.in.h: Update.
2521 * gnulib/import/xalloc-oversized.h: Update.
2522 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
2523 "53e2c179f26a890fa6685af4b6c1397ee370433b".
2525 2018-08-16 Gary Benson <gbenson@redhat.com>
2528 * gdb/main.c (captured_main_1): Exit with nonzero status
2529 in batch mode if the last command to be executed failed.
2530 * NEWS: Mention the above.
2532 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
2534 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
2535 end of warning message.
2537 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2540 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
2541 (aarch64_extract_return_value): Use
2542 aapcs_is_vfp_call_or_return_candidate.
2543 (aarch64_return_in_memory): Likewise.
2544 (aarch64_store_return_value): Likewise.
2546 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2549 (aapcs_is_vfp_call_or_return_candidate): Make static
2550 (pass_in_v_or_stack): Remove function.
2551 (pass_in_v_vfp_candidate): New function.
2552 (aarch64_push_dummy_call): Check for float register candidates.
2554 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2556 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
2557 (aapcs_is_vfp_call_or_return_candidate_1): New function.
2558 (aapcs_is_vfp_call_or_return_candidate): Likewise.
2560 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2563 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
2564 (struct ipa_sym_addresses): Rename to...
2565 (struct ipa_sym_addresses_common): ... this.
2566 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
2568 2018-08-28 Tom Tromey <tom@tromey.com>
2570 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2571 (token_fifo): Now a std::vector.
2572 (yylex, c_parse): Update.
2573 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2574 (token_fifo): Now a std::vector.
2575 (yylex, d_parse): Update.
2576 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2577 (token_fifo): Now a std::vector.
2578 (yylex, go_parse): Update.
2580 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
2582 * parser-defs.h (struct type_stack) <elements>: Change type to
2583 std::vector<union type_stack_elt>.
2584 <depth, size>: Remove.
2585 * parse.c (parse_exp_in_context_1): Adjust.
2586 (type_stack_reserve): Remove.
2587 (check_type_stack_depth): Remove.
2588 (insert_into_type_stack): Adjust to std::vector.
2589 (insert_type): Likewise.
2590 (push_type): Likewise.
2591 (push_type_int): Likewise.
2592 (insert_type_address_space): Likewise.
2593 (pop_type): Likewise.
2594 (pop_type_int): Likewise.
2595 (pop_typelist): Likewise.
2596 (pop_type_stack): Likewise.
2597 (append_type_stack): Likewise.
2598 (push_type_stack): Likewise.
2599 (get_type_stack): Likewise.
2600 (type_stack_cleanup): Likewise.
2601 (push_typelist): Likewise.
2602 (follow_types): Likewise.
2603 (_initialize_parse): Likewise.
2605 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
2607 * NEWS: Mention csky target.
2609 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
2610 Hafiz Abid Qadeer <abidh@codesourcery.com>
2611 Don Breazeal <donb@codesourcery.com>
2613 * csky-linux-tdep.c: New file.
2614 * csky-tdep.c: Likewise.
2615 * csky-tdep.h: Likewise.
2616 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
2618 (HFILES_NO_SRCDIR): Add csky-tdep.h.
2619 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
2620 * configure.tgt: Add csky support.
2622 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
2624 * python/py-framefilter.c (py_print_frame): Print frame architecture
2625 when printing on an MI output.
2627 2018-08-27 Tom Tromey <tom@tromey.com>
2630 * configure: Rebuild.
2631 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
2633 2018-08-27 Tom Tromey <tom@tromey.com>
2635 * aarch64-linux-tdep.c
2636 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
2639 2018-08-27 Tom Tromey <tom@tromey.com>
2641 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
2643 (ppc64_standard_linkage1, ppc64_standard_linkage2)
2644 (ppc64_standard_linkage3, ppc64_standard_linkage4)
2645 (ppc64_standard_linkage5, ppc64_standard_linkage6)
2646 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
2649 2018-08-27 Tom Tromey <tom@tromey.com>
2651 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
2652 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
2654 2018-08-27 Tom Tromey <tom@tromey.com>
2656 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
2657 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
2659 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
2661 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
2663 * sparc-linux-tdep.c (sparc32_linux_sigframe)
2664 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
2665 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
2667 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
2668 (ppc64_linux_sigaction_tramp_frame)
2669 (ppc32_linux_sighandler_tramp_frame)
2670 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
2671 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
2672 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
2673 * mn10300-linux-tdep.c (am33_linux_sigframe)
2674 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
2675 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
2676 * mips-linux-tdep.c (mips_linux_o32_sigframe)
2677 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
2678 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
2679 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
2680 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
2681 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
2682 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
2683 * microblaze-linux-tdep.c
2684 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
2685 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
2686 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
2687 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
2688 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
2689 * common/common-types.h (ULONGEST_MAX): New define.
2690 (CORE_ADDR_MAX): Fix formatting.
2691 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
2692 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
2693 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
2694 (arm_linux_rt_sigreturn_tramp_frame)
2695 (arm_eabi_linux_sigreturn_tramp_frame)
2696 (arm_eabi_linux_rt_sigreturn_tramp_frame)
2697 (thumb2_eabi_linux_sigreturn_tramp_frame)
2698 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
2699 (arm_linux_restart_syscall_tramp_frame)
2700 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
2701 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
2702 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
2704 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
2706 2018-08-27 Tom Tromey <tom@tromey.com>
2708 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
2710 * mips-tdep.c (mips_deal_with_atomic_sequence)
2711 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
2712 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
2713 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
2714 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
2716 * aarch64-tdep.c (aarch64_software_single_step): Use
2719 2018-08-27 Tom Tromey <tom@tromey.com>
2721 * linespec.c (complete_linespec_component): Add cast to "char".
2722 * completer.c (completion_tracker::build_completion_result): Add
2725 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2727 * solist.h (struct solist, struct target_so_ops): Fix
2730 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2732 * ada-tasks.c (ada_task_info_s): Remove typedef.
2733 (DEF_VEC_O(ada_task_info_s)): Remove.
2734 (struct ada_tasks_inferior_data): Initialize fields.
2735 <task_list>: Make an std::vector.
2736 (get_ada_tasks_inferior_data): Allocate with new.
2737 (ada_get_task_number): Adjust.
2738 (get_task_number_from_id): Likewise.
2739 (valid_task_id): Likewise.
2740 (ada_get_task_info_from_ptid): Likewise.
2741 (iterate_over_live_ada_tasks): Likewise.
2742 (add_ada_task): Likewise.
2743 (read_known_tasks): Likewise.
2744 (ada_build_task_list): Likewise.
2745 (print_ada_task_info): Likewise.
2746 (info_task): Likewise.
2747 (task_command_1): Likewise.
2749 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2751 * ada-lang.c (add_angle_brackets): Return std::string.
2753 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
2755 * python/py-threadevent.c (py_get_event_thread): Initialize
2758 2018-08-24 Pedro Alves <palves@redhat.com>
2760 * python/py-bpevent.c (create_breakpoint_event_object): Use
2761 copy-initialization.
2762 * python/py-continueevent.c (emit_continue_event): Use
2763 copy-initialization.
2764 * python/py-exitedevent.c (create_exited_event_object): Return a
2766 (emit_exited_event): Use copy-initialization.
2767 * python/py-inferior.c (python_new_inferior)
2768 (python_inferior_deleted, add_thread_object): Use
2769 copy-initialization.
2770 * python/py-infevents.c (create_inferior_call_event_object)
2771 (create_register_changed_event_object)
2772 (create_memory_changed_event_object): Return a gdbpy_ref<>.
2773 (emit_inferior_call_event, emit_memory_changed_event)
2774 (emit_register_changed_event): Use copy-initialization.
2775 * python/py-newobjfileevent.c (create_new_objfile_event_object):
2776 Return a gdbpy_ref<>.
2777 (emit_new_objfile_event): Use copy-initialization.
2778 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
2779 (emit_clear_objfiles_event): Use copy-initialization.
2780 * python/py-signalevent.c (create_signal_event_object): Use
2781 copy-initialization.
2782 * python/py-threadevent.c (create_thread_event_object): Use
2783 copy-initialization.
2785 2018-08-24 Pedro Alves <palves@redhat.com>
2786 Simon Marchi <simon.marchi@ericsson.com>
2789 * python/py-continueevent.c: Include "gdbthread.h".
2790 (create_continue_event_object): Add intro comment. Add 'ptid'
2791 parameter. Use it to find thread to pass to
2792 create_thread_event_object.
2793 (emit_continue_event): Pass PTID down to
2794 create_continue_event_object.
2795 * python/py-event.h (py_get_event_thread): Declare.
2796 (create_thread_event_object): Remove default from 'thread'
2798 * python/py-stopevent.c (create_stop_event_object): Use
2799 py_get_event_thread.
2800 * python/py-threadevent.c (get_event_thread): Rename to ...
2801 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
2802 and use it to find the thread.
2803 (create_thread_event_object): Assert that THREAD isn't null.
2804 Don't find the event thread here.
2806 2018-08-23 Kevin Buettner <kevinb@redhat.com>
2808 * block.h (blockrange, blockranges): New struct declarations.
2809 (struct block): Add new field named `ranges'.
2810 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
2811 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
2812 macros for accessing ranges in struct block.
2813 (make_blockranges): New declaration.
2814 block.c (make_blockranges): New function.
2815 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
2817 * symtab.h (find_pc_partial_function): Add new parameter `block'.
2818 * blockframe.c (cache_pc_function_block): New static global.
2819 (clear_pc_function_cache): Clear cache_pc_function_block.
2820 (find_pc_partial_function): Move comment to symtab.h. Add
2821 support for non-contiguous blocks.
2822 * cli/cli-cmds.c (block.h): Include.
2823 (print_disassembly): Handle printing of non-contiguous blocks.
2824 (disassemble_current_function): Likewise.
2825 (disassemble_command): Likewise.
2827 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
2829 * blockframe.c (get_pc_function_start): Likewise.
2830 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
2831 (gcc_symbol_address): Likewise.
2832 * compile/compile-object-run.c (compile_object_run): Likewise.
2833 * compile/compile.c (get_expr_block_and_pc): Likewise.
2834 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
2835 (func_addr_to_tail_call_list): Likewise.
2836 * findvar.c (default_read_var_value): Likewise.
2837 * inline-frame.c (inline_frame_this_id): Likewise.
2838 (skip-inline_frames): Likewise.
2839 * infcmd.c (until_next_command): Likewise.
2840 * linespec.c (convert_linespec_to_sals): Likewise.
2841 * parse.c (parse_exp_in_context_1): Likewise.
2842 * printcmd.c (build_address_symbolic): likewise.
2843 (info_address_command): Likewise.
2844 symtab.c (find_function_start_sal): Likewise.
2845 (skip_prologue_sal): Likewise.
2846 (find_function_alias_target): Likewise.
2847 (find_gnu_ifunc): Likewise.
2848 * stack.c (find_frame_funname): Likewise.
2849 * symtab.c (fixup_symbol_section): Likewise.
2850 (find_function_start_sal): Likewise.
2851 (skip_prologue_sal): Likewsie.
2852 (find_function_alias_target): Likewise.
2853 (find_gnu_ifunc): Likewise.
2854 * tracepoint.c (info_scope_command): Likewise.
2855 * value.c (value_fn_field): Likewise.
2857 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
2858 in place of find_pc_partial_function.
2859 * blockframe.c (find_function_entry_range_from_pc): New function.
2860 * symtab.h (find_function_entry_range_from_pc): Declare and document.
2861 * objfiles.c (objfile_relocate1): Relocate start and end addresses
2862 for each range in a block.
2865 2018-08-23 Xavier Roirand <roirand@adacore.com>
2867 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
2870 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2872 * solib-svr4.c (read_program_headers_from_bfd): Return
2873 gdb::optional<gdb::byte_vector>.
2874 (svr4_exec_displacement): Adjust.
2876 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2878 * solib-svr4.c (read_program_header): Return
2879 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
2880 (find_program_interpreter): Return
2881 gdb::optional<gdb::byte_vector>.
2882 (scan_dyntag_auxv): Adjust.
2883 (enable_break): Adjust.
2884 (svr4_exec_displacement): Adjust.
2886 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2888 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
2889 * inf-child.c (inf_child_target::terminal_save_inferior): New.
2891 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2893 * guile/scm-string.c (gdbscm_scm_from_printf): Use
2895 * guile/scm-utils.c (gdbscm_printf): Likewise.
2896 * serial.c (serial_printf): Likewise.
2897 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
2899 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
2901 * stack.c (print_frame): Print frame architecture when printing on
2903 * NEWS: Mention new "arch" attribute in frame output.
2905 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2907 * arch/aarch64.h (aarch64_regnum): Update comment.
2909 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2911 * NEWS: Add SVE to 8.2 section.
2913 2018-08-21 Pedro Alves <palves@redhat.com>
2915 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2916 out from gdbscm_parse_function_args.
2917 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2918 gdbscm_parse_function_args_1.
2920 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2923 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2926 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2928 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2930 2018-08-19 Michael Spang <spang@google.com>
2933 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2934 for PT_TLS segments.
2936 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2938 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2939 dwarf_variable_value.
2940 * dwarf2-frame.c (class dwarf_expr_executor):
2941 Add override for dwarf_variable_value.
2942 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2943 (class symbol_needs_eval_context): Likewise.
2944 (indirect_synthetic_pointer): Add forward declaration.
2945 (sect_variable_value): New function.
2946 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
2947 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
2948 for DW_OP_GNU_variable_value.
2950 2018-08-16 Tom Tromey <tom@tromey.com>
2952 * top.c (read_command_file): Update.
2953 (command_line_input): Remove "repeat" argument.
2954 * ada-lang.c (get_selections): Update.
2955 * linespec.c (decode_line_2): Update.
2956 * defs.h (command_line_input): Remove argument.
2957 * cli/cli-script.c (read_next_line): Update.
2958 * python/py-gdb-readline.c: Update.
2960 2018-08-17 Tom Tromey <tom@tromey.com>
2962 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
2965 2018-08-15 Tom Tromey <tom@tromey.com>
2967 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
2969 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
2971 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
2972 If used, use find_pc_partial_function to find address range
2974 * mi/mi-main.c (mi_cmd_list_features): Report
2975 "data-disassemble-a-option" feature.
2976 * NEWS: Mention new -data-disassemble option -a.
2978 2018-08-13 Tom Tromey <tom@tromey.com>
2980 * common/common-defs.h (_FORTIFY_SOURCE): Define.
2982 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2984 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
2985 (aarch64_linux_collect_sve_regset): Likewise.
2986 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
2987 * regcache.h (regcache_map_entry_size): New function.
2989 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2991 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
2992 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
2993 (SVE_HEADER_VL_LENGTH): Likewise.
2994 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
2995 (SVE_HEADER_FLAGS_LENGTH): Likewise.
2996 (SVE_HEADER_RESERVED_LENGTH): Likewise.
2997 (SVE_HEADER_SIZE_OFFSET): Likewise.
2998 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
2999 (SVE_HEADER_VL_OFFSET): Likewise.
3000 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
3001 (SVE_HEADER_FLAGS_OFFSET): Likewise.
3002 (SVE_HEADER_RESERVED_OFFSET): Likewise.
3003 (SVE_HEADER_SIZE): Likewise.
3004 (aarch64_linux_core_read_vq): Add function.
3005 (aarch64_linux_core_read_description): Check for SVE section.
3007 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3009 * aarch64-fbsd-tdep.c
3010 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
3012 * aarch64-linux-tdep.c
3013 (aarch64_linux_iterate_over_regset_sections): Likewise.
3014 * alpha-linux-tdep.c
3015 (alpha_linux_iterate_over_regset_sections):
3017 (alphanbsd_iterate_over_regset_sections): Likewise.
3019 (amd64fbsd_iterate_over_regset_sections): Likewise.
3020 * amd64-linux-tdep.c
3021 (amd64_linux_iterate_over_regset_sections): Likewise.
3023 (armbsd_iterate_over_regset_sections): Likewise.
3025 (arm_fbsd_iterate_over_regset_sections): Likewise.
3027 (arm_linux_iterate_over_regset_sections): Likewise.
3028 * corelow.c (get_core_registers_cb): Likewise.
3029 (core_target::fetch_registers): Likewise.
3030 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
3031 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
3032 * gdbarch.h (void): Regenerate.
3033 * gdbarch.sh: Add supply_size and collect_size.
3034 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
3035 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
3036 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
3037 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
3038 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
3039 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
3040 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
3041 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
3042 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
3043 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
3044 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
3045 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
3046 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
3047 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
3048 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
3049 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
3050 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
3051 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
3052 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
3053 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
3054 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
3055 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
3056 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
3057 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
3058 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
3059 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
3060 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
3061 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
3062 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
3063 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
3065 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
3067 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
3070 2018-08-10 Keith Seitz <keiths@redhat.com>
3072 * compile/compile-c-support.c (add_code_header, add_code_footer):
3073 Move into policy class.
3074 (c_push_user_expression, pop_user_expression_nop)
3075 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
3076 (compile_program): New host class.
3077 (c_compile_program): New typedef.
3078 (c_compute_porgram): Use c_compile_program.
3080 2018-08-10 Keith Seitz <keiths@redhat.com>
3082 * compile/compile-internal.h (compile_instance::~compile_instance):
3083 Remove calls to htab_delete.
3084 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
3085 * compile.c (compile_instance::compile_instance): Initialize
3086 htab unique pointers.
3087 (compile_instance::get_cached_type, compile_instance::insert_type)
3088 (compile_instance::error_symbol_once): Update for unique_ptr.
3090 2018-08-10 Keith Seitz <keiths@redhat.com>
3092 * compile/compile-c-symbols.c (struct symbol_error)
3093 (hash_symbol_error, eq_symbol_error, del_symbol_error)
3094 (compile_instance::insert_symbol_error)
3095 (compile_instance::error_symbol_once): Move to ...
3096 * compile/compile.c: ... here.
3098 2018-08-10 Keith Seitz <keiths@redhat.com>
3100 * compile/compile-c-support.c (c_get_compile_context): Use `new'
3101 instead of `new_compile_instance'.
3102 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
3104 If the symbol error map is not initialized, create it.
3105 (generate_c_for_for_one_symbol): Do not check/initialize
3106 the symbol error map.
3107 * compile/compile-c-types.c (compile_c_instance): Make a class.
3109 (compile_instance::compile_instance): Initialize the type cache.
3110 (get_cached_type): New function.
3111 (insert_type): Update description.
3112 (compile_c_instance::m_default_cflags): Define.
3113 (convert_type): Update description. Use get_cached_type.
3114 (delete_instance): Moved to destructor.
3115 (new_compile_instance): Moved to constructor.
3116 * compile/compile-c.h (compile_c_instance): Make class inheriting
3117 from compile_instance.
3118 <base>: Remove field.
3119 <type_map, symbol_err_map>: Move to base class.
3120 <c_plugin>: Rename to `m_plugin' and remove pointer type.
3121 * compile/compile-internal.h (compile_instance): Make class.
3122 <type_map_t, symbol_err_map_t>: Define.
3123 <fe>: Rename to `m_gcc_fe'.
3124 <scope, block, gcc_target_options>: Add `m_' prefix.
3125 <m_type_map, m_symbol_err_map>: New fields, moved from
3128 (convert_type, new_compile_instance): Remove.
3129 * compile/compile.c (cleanup_compile_instance): Remove.
3130 (compile_to_object): Use unique_ptr to eliminate cleanups.
3131 (compile_instance::set_print_callback, compile_instance::version)
3132 (compile_instance::set_verbose)
3133 (compile_instance::set_driver_filename)
3134 (compile_instance::set_triplet_regexp)
3135 (compile_instance::set_arguments)
3136 (compile_instance::set_source_file)
3137 (compile_instance::compile): Define.
3139 2018-08-10 Keith Seitz <keiths@redhat.com>
3141 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
3142 * compile/compile-c-types.c: Define GCC_METHODN macros and include
3143 gcc-c-fe.def to define C plugin.
3144 (delete_instance): Delete `c_plugin'.
3145 (new_compile_instance): Initialize `c_plugin'.
3146 * compile/compile-c.h: Include gcc_c_plugin.h.
3147 (struct compile_c_instance) <c_plugin>: New member.
3148 * gcc-c-plugin.h: New file.
3149 Update all callers with API change.
3151 2018-08-10 Keith Seitz <keiths@redhat.com>
3153 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
3154 (HFILES_NO_SRCDIR): ... to here.
3155 Add compile-internal.h and compile-c.h.
3156 * compile/compile-c-support.c: Include compile-c.h.
3157 * compile/compile-c-symbols.c: Include compile-c.h.
3158 (generate_c_for_variable_locations): Update comment.
3159 * compile/compile-c-types.c: Include compile-c.h.
3160 * compile/compile-c.h: New file -- moved C language declarations
3161 from other files here.
3162 * compile/compile-internal.h: Do not include hashtab.h or
3163 common/enum-flags.h.
3164 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
3165 (gcc_convert_symbol, gcc_symbol_address)
3166 (generate_c_for_variable_locations, c_get_mode_for_size)
3167 (c_get_range_decl_name): Definitions moved to compile-c.h.
3168 * compile/compile-loc2c.c: Include compile-c.h.
3170 2018-08-10 Keith Seitz <keiths@redhat.com>
3172 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
3173 (c_symbol_substitution_name): ... this.
3176 2018-08-10 Keith Seitz <keiths@redhat.com>
3178 * compile/compile-c-support.c (c_compute_program): Use
3179 unique_xmalloc_ptr to eliminate cleanup.
3180 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
3181 Return a unique_xmalloc_ptr and eliminate cleanup.
3182 * compile/compile-internal.h (generate_c_for_variable_locations):
3183 Return unique_xmalloc_ptr and update description.
3185 2018-08-10 Alan Hayward <alan.hayward@arm.com>
3187 * corelow.c (core_target::get_core_register_section): Rename
3188 min_size to section_min_size.
3190 2018-08-09 Jim Wilson <jimw@sifive.com>
3192 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
3193 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
3194 * NEWS: Mention new GNU/Linux RISC-V target.
3195 * configure.host: Add riscv*-*-linux*.
3196 * configure.nat: Add riscv*.
3197 * configure.tgt: Add riscv*-*-linux*.
3198 * riscv-linux-nat.c: New file.
3199 * riscv-linux-tdep.c: New file.
3201 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3203 * infrun.c (resume): Make static, add forward declaration.
3204 (proceed): Update header comment.
3205 * infrun.h (resume): Delete declaration.
3207 2018-08-09 Tom Tromey <tom@tromey.com>
3209 * riscv-tdep.h: Minor formatting fixes.
3211 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
3213 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
3214 * dwarf-index-cache.c (create_dir_and_check): Likewise.
3215 (test_mkdir_recursive): Likewise.
3216 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
3218 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3220 * valarith.c (value_subscripted_rvalue): If an array is not in
3221 memory, and we don't know the upper bound, then we can't know that
3222 the requested element exists or not.
3224 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
3226 * target.c (str_comma_list_concat_elem): Fix typo in comment.
3227 (target_options_to_string): Add comment.
3229 2018-08-08 Tom Tromey <tom@tromey.com>
3231 * unittests/scoped_mmap-selftests.c: Check result of "write".
3233 2018-08-08 Jim Wilson <jimw@sifive.com>
3235 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
3236 (decode_register_index_short): New.
3237 (decode_j_type_insn, decode_cj_type_insn): New.
3238 (decode_b_type_insn, decode_cb_type_insn): New.
3239 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
3240 local xlen. Check xlen when decoding ambiguous compressed insns. In
3241 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
3242 is_c_sw_insn instead of is_sw_insn.
3243 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
3244 (riscv_software_single_step): New.
3245 * riscv-tdep.h (riscv_software_single_step): Declare.
3247 * riscv-tdep.c (riscv_isa_xlen): Drop static.
3248 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
3250 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
3253 * target.c (dispose_inferior): Don't dispose of inferiors that are
3256 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
3258 * remote.c (remote_target::download_tracepoint): Change char* to
3261 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
3263 * target.h (target_options_to_string): Return an std::string.
3264 * target.c (str_comma_list_concat_elem): Return void, use
3266 (do_option): Likewise.
3267 (target_options_to_string): Return an std::string.
3268 * linux-nat.c (linux_nat_target::wait): Adjust.
3269 * target-debug.h (target_debug_print_options): Adjust.
3271 2018-08-07 Tom Tromey <tom@tromey.com>
3273 * Makefile.in (CPPFLAGS): New variable.
3274 (INTERNAL_CPPFLAGS): Use it.
3276 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3278 * NEWS: Mention the index cache.
3280 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3282 * common/pathstuff.h (get_standard_cache_dir): New.
3283 * common/pathstuff.c (get_standard_cache_dir): New.
3284 * build-id.h (build_id_to_string): New.
3285 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
3286 DEBUG_STR_SUFFIX): Move to here.
3287 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
3288 DEBUG_STR_SUFFIX): Move from there.
3289 (write_psymtabs_to_index): Make non-static, add basename
3290 parameter. Write to temporary files, rename when done.
3291 (save_gdb_index_command): Adjust call to
3292 write_psymtabs_to_index.
3293 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
3295 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
3296 (get_gdb_index_contents_from_cache): New.
3297 (get_gdb_index_contents_from_cache_dwz): New.
3298 (dwarf2_initialize_objfile): Read index from cache.
3299 (dwarf2_build_psymtabs): Save to index.
3300 * dwarf-index-cache.h: New file.
3301 * dwarf-index-cache.c: New file.
3302 * dwarf-index-write.h: New file.
3304 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3306 * gnulib/aclocal.m4: Re-generate.
3307 * gnulib/config.in: Re-generate.
3308 * gnulib/configure: Re-generate.
3309 * gnulib/import/Makefile.am: Re-generate.
3310 * gnulib/import/Makefile.in: Re-generate.
3311 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3312 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3313 * gnulib/import/m4/mkdir.m4: New file.
3314 * gnulib/import/mkdir.c: New file.
3315 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
3318 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3320 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
3321 * common/scoped_mmap.c: New file.
3322 * common/scoped_mmap.h (destroy): New method.
3323 (~scoped_mmap, reset): Use destroy.
3324 (scoped_mmap): New move constructor.
3325 (mmap_file): New declaration.
3326 * unittests/scoped_mmap-selftests.c (test_normal,
3327 test_invalid_filename, run_tests): New functions.
3328 (_initialize_scoped_mmap_selftests): Register selftest.
3330 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3332 * dwarf2read.c (read_gdb_index_from_section): Rename to...
3333 (read_gdb_index_from_buffer): ... this. Remove section
3334 parameter, add buffer parameter.
3335 (get_gdb_index_contents_ftype,
3336 get_gdb_index_contents_dwz_ftype): New typedefs.
3337 (dwarf2_read_gdb_index): Add callback parameters to get the
3339 (get_gdb_index_contents_from_section): New.
3340 (dwarf2_initialize_objfile): Update call to
3341 dwarf2_read_gdb_index.
3343 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3345 * common/filestuff.h (gdb_fopen_cloexec): New overload.
3346 (gdb_open_cloexec): Likewise.
3347 * nat/linux-osdata.c (command_from_pid): Use string_printf.
3348 (commandline_from_pid): Likewise.
3349 (linux_xfer_osdata_threads): Likewise.
3350 (linux_xfer_osdata_fds): Likewise.
3351 * ada-lang.c (is_package_name): Likewise.
3352 * auxv.c (procfs_xfer_auxv): Likewise.
3353 * breakpoint.c (print_one_breakpoint_location): Use
3355 (print_one_catch_solib): Use string_printf.
3356 * coff-pe-read.c (add_pe_exported_sym): Likewise.
3357 (add_pe_forwarded_sym): Likewise.
3358 * dwarf2read.c (create_type_unit_group): Likewise.
3359 (build_error_marker_type): Likewise.
3360 * infcall.c (get_function_name): Likewise.
3361 * valprint.c (print_converted_chars_to_obstack): Likewise.
3362 * xtensa-tdep.c (xtensa_register_type): Likewise.
3364 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
3366 * remote.c (remote_target::download_tracepoint): Fix format
3369 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3371 * tracefile.c: Include common/byte-vector.h.
3372 (trace_save): Change type of buf to gdb::byte_vector. Initialize
3373 with trace_regblock_size if needed. Update uses of buf.
3375 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3377 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
3378 std::vector<unsigned char>.
3379 * tracepoint.c (collection_list::collection_list): Remove
3380 m_regs_mask initializer from initializer list. Resize
3381 m_regs_mask using the largest remote register number.
3382 (collection_list::add_remote_register): Remove size check on
3383 m_regs_mask. Use at to access element.
3384 (collection_list::stringify): Change type of temp_buf to
3385 gdb::char_vector. Update uses of temp_buf. Resize if needed to
3386 stringify the register mask. Use pack_hex_byte for the register
3389 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3391 * tracepoint.h (class collection_list) <add_register>: Remove.
3392 <add_remote_register, add_ax_registers, add_local_register>:
3394 <add_memrange>: Add scope parameter.
3395 * tracepoint.c (encode_actions_1): Likewise.
3396 (collection_list::add_register): Rename to ...
3397 (collection_list::add_remote_register): ... this. Update
3399 (collection_list::add_ax_registers, add_local_register): New
3401 (collection_list::add_memrange): Add scope parameter. Call
3402 add_local_register instead of add_register.
3403 (finalize_tracepoint_aexpr): New function.
3404 (collection_list::collect_symbol): Update calls to add_memrange.
3405 Call add_local_register instead of add_register. Call
3406 add_ax_registers. Call finalize_tracepoint_aexpr.
3407 (encode_actions_1): Get remote regnos for $reg action. Call
3408 add_remote_register, add_ax_registers, and add_local_register.
3409 Update call to add_memrange. Call finalize_tracepoint_aexpr.
3410 (validate_actionline): Call finalize_tracepoint_aexpr.
3412 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3414 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
3415 Replace array buf with gdb::char_vector buf, of size
3416 get_remote_packet_size (). Replace references to buf and
3417 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
3418 and xsnprintf with snprintf. Raise errors if the buffer is too
3421 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3423 * remote.c (remote_target::download_tracepoint): Fix the has_more
3424 predicate in the QTDP action list iteration.
3426 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3428 * remote.c (remote_target::download_tracepoint): Fix indentation
3431 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3433 * proc-api.c (_initialize_proc_api): Remove c, unused.
3434 * procfs.c (procfs_init_inferior): Remove signals, unused.
3435 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
3438 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
3439 Andrew Burgess <andrew.burgess@embecosm.com>
3441 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
3442 'W_STOPCODE (0)' as this could be ambiguous.
3444 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
3446 * ser-tcp.c (net_open): Fix thinko when deciding whether to
3447 disable TCP's Nagle algorithm (use "ai_protocol" instead of
3450 2018-08-02 Tom Tromey <tom@tromey.com>
3453 * dwarf2read.c (read_func_scope): Set symtab on template parameter
3455 (process_structure_scope): Likewise.
3457 2018-08-02 Xavier Roirand <roirand@adacore.com>
3460 * darwin-nat.c (darwin_kill_inferior): Fix handling of
3463 2018-08-02 Tom Tromey <tom@tromey.com>
3465 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
3466 (darwin_suspend_inferior, darwin_resume_inferior)
3467 (darwin_decode_notify_message, darwin_resume_inferior_threads)
3468 (darwin_check_new_threads): Check result of get_darwin_inferior.
3470 2018-07-31 Joel Brobecker <brobecker@adacore.com>
3474 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
3476 * varobj.c (varobj_get_path_expr_parent): Report an error if
3477 parent is a dynamic varobj.
3479 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3481 * gnulib/aclocal.m4: Re-generate.
3482 * gnulib/config.in: Re-generate.
3483 * gnulib/configure: Re-generate.
3484 * gnulib/import/Makefile.in: Re-generate.
3485 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3486 * gnulib/import/m4/onceonly.m4: Re-generate.
3488 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3490 * target-descriptions.c (struct xml_test_tdesc): New.
3491 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
3492 (record_xml_tdesc): Update.
3493 (maintenance_check_xml_descriptions): Update.
3494 * target-descriptions.h (record_xml_tdesc): Update comment.
3496 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
3498 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
3499 checking array bounds are defined.
3501 2018-07-30 Tom Tromey <tom@tromey.com>
3503 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
3504 irreflexivity violation.
3506 2018-07-30 Tom Tromey <tom@tromey.com>
3508 * cli/cli-decode.c (lookup_cmd): Remove lint code.
3509 * value.c (unpack_long): Remove lint code.
3510 * valops.c (value_ind): Remove lint code.
3511 * valarith.c (value_x_binop, value_x_unop, value_equal)
3512 (value_pos): Remove lint code.
3514 2018-07-28 Tom de Vries <tdevries@suse.de>
3516 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
3517 with undefined upper bound as <optimized out>.
3519 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
3521 * gcore.in: Rename variable "name" to "prefix". Expand
3524 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
3526 * windows-nat.c (windows_nat_target::create_inferior): Update to
3527 call close() in global namespace.
3529 2018-07-26 Tom Tromey <tom@tromey.com>
3531 * dwarf-index-write.c (add_address_entry): Don't add objfile
3533 * dbxread.c (find_stab_function): Rename from
3534 find_stab_function_addr. Return a bound_minimal_symbol.
3535 (read_dbx_symtab): Use raw_text_low, raw_text_high.
3536 Don't add objfile offsets.
3537 (end_psymtab): Use raw_text_low, raw_text_high,
3538 MSYMBOL_VALUE_RAW_ADDRESS.
3539 (read_ofile_symtab): Update.
3540 (process_one_symbol): Update.
3541 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
3543 (dw2_relocate): Remove.
3544 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
3546 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
3548 (process_psymtab_comp_unit_reader, add_partial_symbol)
3549 (add_partial_subprogram, dwarf2_ranges_read): Update.
3550 (load_partial_dies): Update.
3551 (add_address_entry): Don't add objfile offsets.
3552 (dwarf2_build_include_psymtabs): Update.
3553 (create_addrmap_from_aranges): Don't add objfile offsets.
3554 (dw2_find_pc_sect_compunit_symtab): Update.
3555 * mdebugread.c (parse_symbol): Don't add objfile offsets.
3556 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
3558 (parse_partial_symbols): Don't add objfile offsets. Use
3559 raw_text_low, raw_text_high. Update.
3560 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
3561 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
3562 or call 'relocate' quick function. Clear psymbol_map.
3563 * psympriv.h (struct partial_symbol) <address>: Add section
3565 <set_unrelocated_address>: Rename from set_address.
3566 <raw_text_low, raw_text_high>: New methods.
3567 <text_low, text_high>: Add objfile parameter.
3568 (add_psymbol_to_bcache): Add 'section' parameter. Call
3569 set_unrelocated_address.
3570 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3571 (find_pc_psymbol): Update.
3572 (fixup_psymbol_section, relocate_psymtabs): Remove.
3573 (dump_psymtab, psym_functions): Update.
3574 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
3576 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
3577 (start_psymtab_common): Update.
3578 * symfile-debug.c (debug_qf_relocate): Remove.
3579 (debug_sym_quick_functions): Update.
3580 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
3581 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
3584 2018-07-26 Tom Tromey <tromey@redhat.com>
3586 * dbxread.c (end_psymtab): Use text_high_valid and
3588 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
3589 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
3590 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
3592 <text_low_valid, text_high_valid>: New fields.
3593 <set_text_low, set_text_high>: Update.
3594 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
3596 2018-07-26 Tom Tromey <tom@tromey.com>
3598 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
3600 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
3601 textlow and texthigh fields.
3602 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
3604 * mdebugread.c (parse_lines, parse_partial_symbols)
3605 (psymtab_to_symtab_1): Update.
3606 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
3607 Rename fields. Update comment. Now private.
3608 <text_low, text_high, set_text_low, set_text_high>: New methods.
3609 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3610 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
3611 (start_psymtab_common, maintenance_info_psymtabs)
3612 (maintenance_check_psymtabs): Update.
3613 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
3615 (scan_xcoff_symtab): Update.
3617 2018-07-26 Tom Tromey <tromey@redhat.com>
3619 * psympriv.h (struct partial_symbol) <unrelocated_address,
3620 address, set_address>: New methods.
3621 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
3622 (fixup_psymbol_section, relocate_psymtabs): Update.
3623 (print_partial_symbols): Add 'objfile' parameter. Update.
3624 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
3627 2018-07-26 Tom Tromey <tom@tromey.com>
3629 * dwarf-index-write.c (write_psymbols, debug_names::insert)
3630 (debug_names::write_psymbols): Update.
3631 * psympriv.h (struct partial_symbol): Derive from
3632 general_symbol_info.
3633 <obj_section>: New method.
3634 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
3635 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3636 (find_pc_sect_psymbol, fixup_psymbol_section)
3637 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
3638 (print_partial_symbols, recursively_search_psymtabs)
3639 (compare_psymbols, psymbol_hash, psymbol_compare)
3640 (add_psymbol_to_bcache, maintenance_check_psymtabs)
3641 (psymbol_name_matches, psym_fill_psymbol_map): Update.
3643 2018-07-26 Tom Tromey <tromey@redhat.com>
3645 * dbxread.c (end_psymtab): Remove dead code.
3647 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
3649 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
3650 DWARF unwinders are disabled.
3651 * dwarf2-frame.c: Add dwarf2read.h include.
3652 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
3654 (dwarf2_frame_unwinders_enabled_p): Define.
3655 (show_dwarf_unwinders_enabled_p): New function.
3656 (_initialize_dwarf2_frame): Register switch to control DWARF
3658 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
3659 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
3660 (show_dwarf_cmdlist): Remove static keyword.
3661 * dwarf2read.h (set_dwarf_cmdlist): Declare.
3662 (show_dwarf_cmdlist): Declare.
3663 * NEWS: Document new feature.
3665 2018-07-26 Tom de Vries <tdevries@suse.de>
3667 PR breakpoints/23366
3668 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
3670 2018-07-26 Tom de Vries <tdevries@suse.de>
3672 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
3673 DW_AT_count can't be translated to a dynamic prop.
3675 2018-07-25 Tom de Vries <tdevries@suse.de>
3677 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
3680 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
3682 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
3684 2018-07-25 Joel Brobecker <brobecker@adacore.com>
3686 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
3688 2018-07-24 Keith Seitz <keiths@redhat.comt
3691 * dwarf2read.c (dw2_add_symbol_to_list): New function.
3692 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
3693 instead of add_symbol_to_list.
3694 (read_file_scope): Call prepare_one_comp_unit before reading
3697 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
3699 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
3701 2018-07-24 Tom Tromey <tom@tromey.com>
3703 * utils.c (malloc, realloc, free): Don't declare.
3704 * configure, config.in: Rebuild.
3705 * configure.ac: Don't check for declarations of free, malloc, or
3708 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3710 * aarch64-linux-nat.c
3711 (aarch64_linux_nat_target::stopped_data_address): Remove unused
3713 * arm-linux-nat.c (fetch_regs): Likewise.
3714 (store_regs): Likewise.
3715 (fetch_vfp_regs): Likewise.
3716 (store_vfp_regs): Likewise.
3717 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
3718 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
3719 (arm_linux_nat_target::insert_watchpoint): Likewise.
3720 (arm_linux_nat_target::remove_watchpoint): Likewise.
3721 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
3723 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
3725 * ppc-linux-nat.c (fetch_register): Likewise.
3726 (fetch_all_gp_regs): Likewise.
3727 (fetch_ppc_registers): Likewise.
3728 (store_all_gp_regs): Likewise.
3729 (store_ppc_registers): Likewise.
3730 (hwdebug_insert_point): Likewise.
3731 (can_use_watchpoint_cond_accel): Likewise.
3732 * remote-sim.c (gdb_os_write_stdout): Likewise.
3734 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3735 Tom Tromey <tom@tromey.com>
3737 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
3739 * configure: Rebuild.
3741 2018-07-22 Tom Tromey <tom@tromey.com>
3743 * regformats/regdat.sh: Define xmltarget_${name} inside
3744 #ifndef IN_PROCESS_AGENT.
3746 2018-07-22 Tom Tromey <tom@tromey.com>
3748 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
3750 2018-07-22 Tom Tromey <tom@tromey.com>
3752 * symfile.c (reread_symbols): Notify iter, not objfile.
3754 2018-07-22 Tom Tromey <tom@tromey.com>
3756 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
3758 (ravenscar_thread_target::prepare_to_store): Likewise.
3760 2018-07-22 Tom Tromey <tom@tromey.com>
3762 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
3763 unused variable. Call value_fetch_lazy when needed.
3764 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
3765 Remove unused variable. Call value_fetch_lazy when needed.
3767 2018-07-22 Tom Tromey <tom@tromey.com>
3769 * m32c-tdep.c (mark_dma): Return void.
3770 (make_regs): Remove unused declarations.
3772 2018-07-22 Tom Tromey <tom@tromey.com>
3774 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
3775 cmdscm_get_valid_command_smob_arg_unsafe for effect.
3776 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
3777 bkscm_get_valid_block_smob_arg_unsafe for effect.
3779 2018-07-22 Tom Tromey <tom@tromey.com>
3781 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
3784 2018-07-22 Tom Tromey <tom@tromey.com>
3786 * windows-nat.c (saved_context): Conditionally define.
3787 * remote.c (remote_target::remote_btrace_maybe_reopen):
3788 Conditionally declare "warned".
3789 * inflow.c (sigquit_ours): Conditionally define.
3790 (new_tty): Move "tty" declaration inside #if.
3791 * guile/guile.c (guile_datadir): Conditionally define.
3792 * charset.c (set_be_le_names): Move some declarations inside #if.
3793 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
3795 (parse_xml_btrace_conf): Likewise.
3797 2018-07-22 Tom Tromey <tom@tromey.com>
3799 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
3801 2018-07-22 Tom Tromey <tom@tromey.com>
3803 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
3804 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
3805 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
3806 * buildsym-legacy.c (get_macro_table): Remove unused variable.
3807 * stack.c (frame_apply_level_command): Remove unused variable.
3808 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
3809 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
3810 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
3812 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
3813 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
3814 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
3816 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
3817 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
3819 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
3820 Remove unused variable.
3821 * cli/cli-script.c (recurse_read_control_structure): Remove unused
3823 * common/tdesc.c (print_xml_feature::visit): Remove unused
3825 * compile/compile-object-load.c (store_regs): Remove unused
3827 * complaints.c (clear_complaints): Remove unused variable.
3828 * corelow.c (core_target_open): Remove unused variable.
3829 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
3831 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
3833 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
3835 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
3837 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
3839 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
3841 * ia64-tdep.c (examine_prologue): Remove unused variable.
3842 * infcall.c (run_inferior_call): Remove unused variable.
3843 * inferior.c (exit_inferior): Remove unused variable.
3844 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
3845 * linespec.c (decode_line_2): Remove unused variable.
3846 * linux-nat.c (super_close): Remove.
3847 * linux-tdep.c (linux_info_proc): Remove unused variable.
3848 * mi/mi-main.c (mi_execute_command): Remove unused variable.
3849 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
3850 Remove unused variable.
3851 * parse.c (find_minsym_type_and_address): Remove unused variable.
3852 * printcmd.c (info_symbol_command, printf_floating): Remove unused
3854 * python/py-breakpoint.c (bppy_set_commands): Remove unused
3856 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
3858 * record-btrace.c (record_btrace_target::store_registers): Remove
3860 (cmd_show_record_btrace_cpu): Remove unused variable.
3861 * riscv-tdep.c (riscv_register_reggroup_p)
3862 (riscv_push_dummy_call, riscv_return_value): Remove unused
3864 * rust-exp.y (literal): Remove unused variable.
3865 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
3867 <STRUCTOP_ANONYMOUS>: Likewise.
3868 * s390-linux-tdep.c (s390_linux_init_abi_31)
3869 (s390_linux_init_abi_64): Remove unused variable.
3870 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
3871 (file_select_thread, net_windows_open, _initialize_ser_windows):
3872 Remove unused variables.
3873 * symtab.c (find_pc_sect_line): Remove unused variable.
3874 * target-memory.c (compute_garbled_blocks): Remove unused
3876 (target_write_memory_blocks): Remove unused variable.
3877 * target.c (target_stack::unpush): Remove unused variables.
3878 * tracepoint.c (start_tracing, all_tracepoint_actions)
3879 (merge_uploaded_trace_state_variables)
3880 (print_one_static_tracepoint_marker): Remove unused variable.
3881 * unittests/basic_string_view/element_access/char/1.cc (test01):
3882 Remove unused variable.
3883 * windows-nat.c (windows_continue, windows_add_all_dlls)
3884 (do_initial_windows_stuff, windows_nat_target::create_inferior):
3885 Remove unused variables.
3887 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
3889 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
3890 attr_profile in HAVE_ELF.
3891 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
3894 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
3896 * frame.c (frame_register_unwind): Change parameter name.
3897 (frame_unwind_register): Likewise.
3898 (frame_unwind_register_value): Likewise.
3899 (frame_unwind_register_signed): Likewise.
3900 (frame_unwind_register_unsigned): Likewise.
3901 * frame.h (frame_register_unwind): Likewise.
3902 (frame_unwind_register): Likewise.
3903 (frame_unwind_register_value): Likewise.
3904 (frame_unwind_register_signed): Likewise.
3905 (frame_unwind_register_unsigned): Likewise.
3906 (frame_unwind_arch): Likewise.
3908 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3910 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3913 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3915 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3916 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3919 2018-07-20 Keith Seitz <keiths@redhat.com>
3921 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3922 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3923 m_compunit_symtab, m_language>: Add "m_" prefix.
3925 * buildsym.c: Update all uses.
3927 2018-07-20 Tom Tromey <tom@tromey.com>
3929 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3930 * buildsym.h (record_line_ftype): Remove typedef.
3932 2018-07-20 Tom Tromey <tom@tromey.com>
3934 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3935 (end_expandable_symtab): Likewise.
3936 (end_symtab_get_static_block): Likewise.
3937 (end_symtab_from_static_block): Likewise.
3938 * buildsym-legacy.c (augment_type_symtab): Remove.
3939 (end_expandable_symtab): Remove.
3940 (end_symtab_get_static_block): Remove.
3941 (end_symtab_from_static_block): Remove.
3943 2018-07-20 Tom Tromey <tom@tromey.com>
3945 * dwarf2read.c: Include buildsym.h.
3946 (struct dwarf2_cu) <builder>: New method.
3947 (fixup_go_packaging): Update.
3948 (process_full_comp_unit, process_full_type_unit): Update. Don't
3949 use scoped_free_pendings.
3950 (using_directives): Add "cu" parameter, remove "language".
3951 (read_import_statement, setup_type_unit_groups, )
3952 (read_func_scope, read_lexical_block_scope)
3953 (dwarf2_record_block_ranges, read_namespace): Update.
3954 (lnp_state_machine::lnp_state_machine): Add cu parameter.
3955 (lnp_state_machine::handle_end_sequence): Update.
3956 (class lnp_state_machine) <m_cu>: New member.
3957 <m_record_line_callback>: Remove.
3958 <m_currently_recording_lines>: New member.
3959 (lnp_state_machine::handle_set_file): Update.
3960 (noop_record_line): Remove.
3961 (dwarf_record_line_p): Add cu parameter.
3962 (dwarf_record_line_1, dwarf_finish_line): Likewise.
3963 (lnp_state_machine::record_line)
3964 (lnp_state_machine::lnp_state_machine)
3965 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3966 (dwarf_decode_lines): Update.
3967 (dwarf2_start_subfile): Add cu parameter.
3968 (dwarf2_start_symtab, new_symbol): Update.
3969 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
3970 Remove dwarf2_per_objfile parameter.
3971 (dwarf_decode_macros): Update.
3973 2018-07-20 Tom Tromey <tom@tromey.com>
3975 * stabsread.c (define_symbol): Update.
3976 * buildsym-legacy.h (get_buildsym_compunit): Declare.
3977 * dwarf2read.c (new_symbol): Update.
3978 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
3979 * cp-namespace.c: Include buildsym.h.
3980 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
3981 * buildsym-legacy.c (get_buildsym_compunit): New function.
3983 2018-07-20 Tom Tromey <tom@tromey.com>
3985 * xcoffread.c: Include buildsym-legacy.h.
3986 * windows-nat.c: Include buildsym-legacy.h.
3987 * stabsread.c: Include buildsym-legacy.h.
3988 * mdebugread.c: Include buildsym-legacy.h.
3989 * buildsym-legacy.h: New file.
3990 * buildsym-legacy.c: New file, from buildsym.c.
3991 * go32-nat.c: Include buildsym-legacy.h.
3992 * dwarf2read.c: Include buildsym-legacy.h.
3993 * dbxread.c: Include buildsym-legacy.h.
3994 * cp-namespace.c: Include buildsym-legacy.h.
3995 * coffread.c: Include buildsym-legacy.h.
3996 * buildsym.h: Move some contents to buildsym-legacy.h.
3997 * buildsym.c: Include buildsym-legacy.h. Move many functions to
3999 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
4001 2018-07-20 Tom Tromey <tom@tromey.com>
4003 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
4004 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
4005 (buildsym_compunit::buildsym_compunit)
4006 (buildsym_compunit::~buildsym_compunit)
4007 (buildsym_compunit::get_macro_table): Define.
4009 2018-07-20 Tom Tromey <tom@tromey.com>
4011 * buildsym.c (reset_symtab_globals): Remove.
4012 (buildsym_compunit::end_symtab_from_static_block): Update.
4013 (buildsym_compunit::augment_type_symtab): Update.
4014 (end_symtab_from_static_block): Call free_buildsym_compunit.
4015 (augment_type_symtab, end_symtab, end_expandable_symtab):
4018 2018-07-20 Tom Tromey <tom@tromey.com>
4020 * arch-utils.c: Do not include buildsym.h.
4021 * mipsread.c: Do not include buildsym.h.
4022 * machoread.c: Do not include buildsym.h.
4023 * elfread.c: Do not include buildsym.h.
4025 2018-07-20 Tom Tromey <tom@tromey.com>
4027 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
4029 (buildsym_compunit): Add new constructor.
4030 (struct buildsym_compunit) <get_last_source_file, finish_block,
4031 record_block_range, start_subfile, patch_subfile_names,
4032 push_subfile, pop_subfile, record_line, get_compunit_symtab,
4033 set_last_source_start_addr, get_last_source_start_addr,
4034 get_local_using_directives, set_local_using_directives,
4035 get_global_using_directives, outermost_context_p,
4036 get_current_context_stack, get_context_stack_depth,
4037 get_current_subfile, get_local_symbols, get_file_symbols,
4038 get_global_symbols, record_debugformat, record_producer,
4039 push_context, pop_context, end_symtab_get_static_block,
4040 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
4042 <record_pending_block, finish_block_internal, make_blockvector,
4043 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
4047 2018-05-22 Tom Tromey <tom@tromey.com>
4049 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4051 (finish_block_internal): Update.
4053 2018-07-20 Tom Tromey <tom@tromey.com>
4055 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4057 (finish_block_internal): Update.
4059 2018-07-20 Tom Tromey <tom@tromey.com>
4061 * buildsym.h (EXTERN): Don't define or undef.
4062 * buildsym.c (EXTERN): Don't define.
4064 2018-07-20 Tom Tromey <tom@tromey.com>
4066 * buildsym.c: Remove TODO comment.
4068 2018-07-20 Tom Tromey <tom@tromey.com>
4070 * coffread.c (coff_symtab_read): Update.
4071 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
4072 (xcoff_new_init): Update.
4073 * mipsread.c (mipscoff_new_init): Update.
4074 * mdebugread.c (mdebug_build_psymtabs): Update.
4075 * elfread.c (elf_new_init): Update.
4076 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
4078 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
4079 (coffstab_build_psymtabs, elfstab_build_psymtabs)
4080 (stabsect_build_psymtabs): Update.
4081 * buildsym.h (buildsym_init): Don't declare.
4082 * buildsym.c: Update comment.
4083 (prepare_for_building): Remove.
4084 (start_symtab, restart_symtab): Update.
4085 (reset_symtab_globals): Update comment.
4086 (buildsym_init): Remove.
4088 2018-07-20 Tom Tromey <tom@tromey.com>
4090 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
4091 * stabsread.c (patch_block_stabs, define_symbol, read_type)
4092 (read_enum_type, common_block_start, common_block_end)
4093 (cleanup_undefined_types_1, finish_global_stabs): Update.
4094 * mdebugread.c (psymtab_to_symtab_1): Update.
4095 * dwarf2read.c (fixup_go_packaging, read_func_scope)
4096 (read_lexical_block_scope, new_symbol): Update.
4097 * dbxread.c (process_one_symbol): Update.
4098 * coffread.c (coff_symtab_read, process_coff_symbol)
4099 (coff_read_enum_type): Update.
4100 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
4102 (get_local_symbols, get_file_symbols, get_global_symbols): New
4104 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
4106 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
4107 (~scoped_free_pendings): Update.
4108 (finish_block, prepare_for_building, reset_symtab_globals)
4109 (end_symtab_get_static_block, end_symtab_with_blockvector)
4110 (augment_type_symtab, push_context): Update.
4111 (get_local_symbols, get_file_symbols, get_global_symbols): New
4113 (buildsym_init): Update.
4115 2018-07-20 Tom Tromey <tom@tromey.com>
4117 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
4118 (process_full_type_unit): Likewise.
4119 (dwarf2_start_symtab): Set list_in_scope.
4121 2018-07-20 Tom Tromey <tom@tromey.com>
4123 * dwarf2read.c (process_psymtab_comp_unit_reader)
4124 (build_type_psymtabs_reader): Do not set list_in_scope.
4126 2018-07-20 Tom Tromey <tom@tromey.com>
4128 * buildsym.c (free_pendings): Remove.
4129 (add_symbol_to_list, scoped_free_pendings)
4130 (finish_block_internal, buildsym_init): Update.
4132 2018-07-20 Tom Tromey <tom@tromey.com>
4134 * xcoffread.c (read_xcoff_symtab): Update.
4135 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
4137 * dbxread.c (process_one_symbol): Update.
4138 * coffread.c (coff_symtab_read): Update.
4139 * buildsym.h (finish_block): Update.
4140 * buildsym.c (finish_block): Remove "listhead" argument.
4141 (end_symtab_get_static_block): Update.
4143 2018-07-20 Tom Tromey <tom@tromey.com>
4145 * buildsym.h (class scoped_free_pendings): Remove constructor.
4146 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
4148 <m_pending_block_obstack, m_pending_blocks>: New members.
4149 (pending_block_obstack, pending_blocks): Remove.
4150 (scoped_free_pendings::scoped_free_pendings): Default.
4151 (~scoped_free_pendings): Update.
4152 (free_pending_blocks): Remove.
4153 (finish_block_internal, record_pending_block, make_blockvector)
4154 (end_symtab_get_static_block, augment_type_symtab, push_context)
4155 (buildsym_init): Update.
4157 2018-07-20 Tom Tromey <tom@tromey.com>
4159 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
4160 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
4162 (pending_addrmap, pending_addrmap_obstack)
4163 (pending_addrmap_interesting): Remove.
4164 (scoped_free_pendings, record_block_range, make_blockvector)
4165 (prepare_for_building, reset_symtab_globals, buildsym_init):
4168 2018-07-20 Tom Tromey <tom@tromey.com>
4170 * xcoffread.c (process_linenos): Update.
4171 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
4172 * mdebugread.c (psymtab_to_symtab_1): Update.
4173 * dwarf2read.c (setup_type_unit_groups)
4174 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
4175 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
4176 * dbxread.c (process_one_symbol): Update.
4177 * coffread.c (coff_symtab_read, enter_linenos)
4178 (process_coff_symbol): Update.
4179 * buildsym.h (current_subfile): Don't declare.
4180 (get_current_subfile): Declare.
4181 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
4183 (start_subfile, free_buildsym_compunit, push_subfile)
4184 (prepare_for_building, start_symtab): Update.
4185 (get_current_subfile): New function.
4187 2018-07-20 Tom Tromey <tom@tromey.com>
4189 * coffread.c (coff_symtab_read): Update.
4190 * xcoffread.c (read_xcoff_symtab): Update.
4191 * dwarf2read.c (new_symbol): Update.
4192 (read_func_scope, read_lexical_block_scope): Update.
4193 * dbxread.c (process_one_symbol): Update.
4194 * buildsym.h (context_stack, context_stack_depth): Don't declare.
4195 (outermost_context_p): Remove macro.
4196 (outermost_context_p, get_current_context_stack)
4197 (get_context_stack_depth): Declare.
4198 (pop_context): Return struct context_stack.
4199 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
4201 (context_stack_size): Remove.
4202 (INITIAL_CONTEXT_STACK_SIZE): Remove.
4203 (prepare_for_building, end_symtab_get_static_block)
4204 (augment_type_symtab, push_context): Update.
4205 (pop_context): Return struct context_stack.
4206 (outermost_context_p, get_current_context_stack)
4207 (get_context_stack_depth): New functions.
4208 (buildsym_init): Update.
4210 2018-07-20 Tom Tromey <tom@tromey.com>
4212 * rust-exp.y: Now a pure parser. Update all rules.
4213 (%union): Move earlier.
4214 (current_parser, work_obstack): Remove globals.
4215 (rust_parser, ~rust_parser): Update.
4216 (class rust_parser) <copy_name, concat3, crate_name, super_name,
4217 lex_character, lex_number, lex_string, lex_identifier,
4218 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
4219 convert_name, convert_params_to_expression,
4220 convert_ast_to_expression, ast_basic_type, ast_operation,
4221 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
4222 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
4223 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
4224 ast_array_type, ast_slice_type, ast_reference_type,
4225 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
4226 (rust_parse): Update.
4227 (rustyyerror, rustyylex): Add parser parameter.
4228 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
4229 (rust_lex_stringish_test, rust_lex_test_sequence)
4230 (rust_lex_test_trailing_dot, rust_lex_test_completion)
4231 (rust_lex_test_push_back, rust_lex_tests): Update.
4233 2018-07-19 Pedro Alves <palves@redhat.com>
4235 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
4236 gdb::unique_xmalloc_ptr.
4237 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
4238 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
4239 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
4240 copy-initialization.
4241 * guile/scm-pretty-print.c (ppscm_print_children): Use
4242 gdb::unique_xmalloc_ptr instead of cleanups.
4243 (gdbscm_apply_val_pretty_printer): Remove cleanups.
4244 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
4245 gdb::unique_xmalloc_ptr.
4246 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4247 Adjust to use gdb::unique_xmalloc_ptr.
4248 * guile/scm-utils.c (extract_arg): Adjust.
4249 * guile/scm-value.c (gdbscm_value_field): Adjust to use
4250 gdb::unique_xmalloc_ptr instead of a cleanup.
4252 2018-07-19 Tom Tromey <tom@tromey.com>
4254 * utils.c (do_value_free_to_mark)
4255 (make_cleanup_value_free_to_mark): Remove.
4256 * utils.h (make_cleanup_value_free_to_mark): Remove.
4258 2018-07-19 Pedro Alves <palves@redhat.com>
4260 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
4261 forwarding reference.
4263 2018-07-18 Pedro Alves <palves@redhat.com>
4265 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
4266 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
4269 2018-07-18 Pedro Alves <palves@redhat.com>
4271 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
4273 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
4275 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
4276 directly instead of a cleanup.
4277 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
4278 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
4279 (vlscm_binop_gdbthrow): New, factored out from ...
4280 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
4281 (vlscm_rich_compare): Use gdbscm_wrap.
4282 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
4283 instead of a cleanup.
4284 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
4286 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4287 Use xfree directly instead of a cleanup.
4288 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
4289 Adjust to use gdbscm_wrap and scoped_value_mark.
4290 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
4291 (gdbscm_value_address, gdbscm_value_dereference)
4292 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
4294 (gdbscm_value_dynamic_type): Use scoped_value_mark.
4295 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
4297 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
4298 gdbscm_wrap and scoped_value_mark.
4299 (gdbscm_value_to_string): Use xfree directly instead of a
4300 cleanup. Move 'buffer' unique_ptr to TRY scope.
4301 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
4302 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
4304 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
4305 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
4307 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
4310 2018-07-18 Tom de Vries <tdevries@suse.de>
4312 * findvar.c (default_read_var_value): Also resolve dynamic type for
4313 LOC_OPTIMIZED_OUT vars.
4315 2018-07-18 Maciej W. Rozycki <macro@mips.com>
4317 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
4320 2018-07-17 Tom Tromey <tom@tromey.com>
4322 * guile/scm-param.c (pascm_set_func, pascm_show_func)
4323 (compute_enum_list, pascm_set_param_value_x)
4324 (gdbscm_parameter_value): Update.
4325 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
4326 (gdbscm_scm_to_host_string): Update.
4327 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
4329 * guile/scm-cmd.c (cmdscm_add_completion): Update.
4330 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
4331 * guile/scm-string.c (gdbscm_scm_to_string): Return
4333 (gdbscm_scm_to_host_string): Likewise.
4335 2018-07-17 Tom Tromey <tom@tromey.com>
4337 * guile/guile.c (gdbscm_eval_from_control_command): Update.
4338 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
4339 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
4340 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
4343 2018-07-17 Tom Tromey <tom@tromey.com>
4345 * guile/scm-param.c (pascm_signal_setshow_error): Update.
4346 * guile/guile-internal.h (gdbscm_exception_message_to_string):
4348 * guile/scm-cmd.c (cmdscm_function): Update.
4349 * guile/scm-pretty-print.c
4350 (ppscm_print_exception_unless_memory_error): Update.
4351 * guile/scm-exception.c (gdbscm_exception_message_to_string):
4352 Return unique_xmalloc_ptr.
4354 2018-07-17 Tom Tromey <tom@tromey.com>
4356 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
4359 2018-07-17 Jim Wilson <jimw@sifive.com>
4361 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
4362 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
4363 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
4364 unecessary braces after EF_RISCV_RVC test. Delete call to
4365 set_gdbarch_decr_pc_after_break.
4367 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
4368 RISCV_LAST_FP_REGNUM + 1.
4369 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
4371 2018-07-17 Tom Tromey <tom@tromey.com>
4373 * configure.ac: Remove --disable-gdbcli.
4374 * configure: Rebuild.
4375 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
4376 (SUBDIR_CLI_CFLAGS): Remove.
4377 (SFILES): Use SUBDIR_CLI_SRCS.
4378 (COMMON_OBS): Use SUBDIR_CLI_OBS.
4380 2018-07-17 Tom Tromey <tom@tromey.com>
4383 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
4385 2018-07-16 Jim Wilson <jimw@sifive.com>
4387 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
4389 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4391 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
4393 (libunwind_frame_sniffer): Likewise.
4394 (libunwind_frame_prev_register): Likewise.
4395 (libunwind_sigtramp_frame_sniffer): Likewise.
4396 * ia64-tdep.c (ia64_access_reg): Likewise.
4397 (ia64_access_rse_reg): Likewise.
4398 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
4399 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
4401 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4403 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
4405 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4407 * remote-sim.c (gdbsim_target::close,
4408 gdbsim_target::mourn_inferior): Remove unused variables.
4410 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
4412 * ia64-tdep.c (ktab_buf): New global.
4413 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
4414 (get_kernel_table): Adjust.
4416 2018-07-16 Tom Tromey <tom@tromey.com>
4418 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
4419 * dwarf2read.c (using_directives, new_symbol): Use
4420 outermost_context_p.
4421 * dbxread.c (process_one_symbol): Use outermost_context_p.
4422 * coffread.c (coff_symtab_read): Use outermost_context_p.
4424 2018-07-16 Tom Tromey <tom@tromey.com>
4426 * dwarf2read.c (using_directives, read_func_scope)
4427 (read_lexical_block_scope): Update.
4428 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
4429 * buildsym.h (local_using_directives, global_using_directives):
4431 (get_local_using_directives, set_local_using_directives)
4432 (get_global_using_directives): Declare.
4433 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
4434 m_global_using_directives>: New members.
4435 (finish_block_internal, prepare_for_building)
4436 (reset_symtab_globals, end_symtab_get_static_block)
4437 (push_context): Update.
4438 (get_local_using_directives, set_local_using_directives)
4439 (get_global_using_directives): New functions.
4440 (buildsym_init): Update.
4442 2018-07-16 Tom Tromey <tom@tromey.com>
4444 * xcoffread.c (xcoff_initial_scan): Don't call
4445 free_pending_blocks.
4446 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
4447 * buildsym.h (class scoped_free_pendings): Add constructor.
4448 (free_pending_blocks): Don't declare.
4449 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
4450 (free_pending_blocks): Now static.
4452 2018-07-16 Tom Tromey <tom@tromey.com>
4454 * buildsym.h (push_subfile, pop_subfile): Update declarations.
4455 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
4457 (struct subfile_stack): Remove.
4458 (subfile_stack): Remove.
4459 (push_subfile, pop_subfile, buildsym_init): Update.
4461 2018-07-16 Tom Tromey <tom@tromey.com>
4463 * buildsym.c (push_subfile): Use gdb_assert.
4464 (pop_subfile): Use gdb_assert.
4466 2018-07-16 Tom Tromey <tom@tromey.com>
4468 * buildsym.h (merge_symbol_lists): Remove.
4469 * buildsym.c (merge_symbol_lists): Remove.
4471 2018-07-16 Tom Tromey <tom@tromey.com>
4473 * stabsread.c (scan_file_globals): Update comment.
4474 * stabsread.h (scan_file_globals): Move from buildsym.h.
4475 * buildsym.h (scan_file_globals): Move to stabsread.h.
4477 2018-07-16 Tom Tromey <tom@tromey.com>
4479 * xcoffread.c (xcoff_new_init): Update.
4480 * mipsread.c (mipscoff_new_init): Update.
4481 * mdebugread.c (mdebug_build_psymtabs): Update.
4482 * elfread.c (elf_new_init): Update.
4483 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
4484 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
4485 * buildsym.h (buildsym_new_init): Don't declare.
4486 * buildsym.c (buildsym_new_init): Remove.
4488 2018-07-16 Tom Tromey <tom@tromey.com>
4490 * stabsread.h (within_function): Move from buildsym.h.
4491 * stabsread.c (start_stabs): Clear within_function.
4492 * coffread.c (coff_start_symtab): Clear within_function.
4493 * buildsym.h (within_function): Move to stabsread.h.
4494 * buildsym.c (prepare_for_building): Update.
4496 2018-07-16 Tom Tromey <tom@tromey.com>
4498 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
4499 * dwarf2read.c (dwarf2_start_symtab): Don't set
4500 processing_gcc_compilation.
4501 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
4503 2018-07-16 Tom Tromey <tom@tromey.com>
4505 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
4506 (next_symbol_text_func): Move from buildsym.h.
4507 * stabsread.c (hashname): Move from buildsym.c.
4508 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
4509 (next_symbol_text_func, hashname): Move to stabsread.h.
4510 * buildsym.c: Don't include bcache.h
4511 (hashname): Move to stasbread.c.
4513 2018-07-16 Tom Tromey <tom@tromey.com>
4515 * buildsym.h (context_stack_size): Don't declare.
4516 * buildsym.c (context_stack_size): New global.
4518 2018-07-16 Tom Tromey <tom@tromey.com>
4520 * dbxread.c (processing_acc_compilation): New global.
4521 * buildsym.h (processing_acc_compilation): Don't declare.
4523 2018-07-16 Tom Tromey <tom@tromey.com>
4525 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
4526 * dbxread.c (read_ofile_symtab): Update.
4527 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
4528 * buildsym.h (last_source_start_addr): Remove.
4529 (set_last_source_start_addr, get_last_source_start_addr):
4531 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
4533 (struct buildsym_compunit) <m_last_source_start_addr>: New
4535 (prepare_for_building): Remove start_addr parameter.
4536 (start_symtab, restart_symtab, end_symtab_get_static_block)
4537 (end_symtab_with_blockvector): Update.
4538 (set_last_source_start_addr, get_last_source_start_addr): New
4541 2018-07-16 Tom Tromey <tom@tromey.com>
4543 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
4545 (have_line_numbers): Remove.
4546 (record_line, prepare_for_building, end_symtab_get_static_block)
4547 (augment_type_symtab): Update.
4549 2018-07-16 Tom Tromey <tom@tromey.com>
4551 * buildsym.c (~buildsym_compunit): Free the macro table.
4552 (struct buildsym_compunit) <get_macro_table, release_macros>: New
4554 <m_pending_macros>: New member.
4555 (pending_macros): Remove.
4556 (~scoped_free_pendings, get_macro_table, prepare_for_building)
4557 (reset_symtab_globals, end_symtab_get_static_block)
4558 (end_symtab_with_blockvector, augment_type_symtab)
4559 (buildsym_init): Update.
4561 2018-07-16 Tom Tromey <tom@tromey.com>
4563 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
4565 (buildsym_compunit::set_last_source_file): New method.
4566 <m_last_source_file>: New member.
4567 (prepare_for_building): Remove "name" parameter.
4568 (start_symtab, restart_symtab, reset_symtab_globals): Update.
4569 (last_source_file): Remove.
4570 (set_last_source_file, get_last_source_file): Update.
4572 2018-07-16 Tom Tromey <tom@tromey.com>
4574 * buildsym.c (prepare_for_building): Add assert.
4576 2018-07-16 Tom Tromey <tom@tromey.com>
4578 * buildsym.c (~buildsym_compunit): Update.
4579 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
4580 (start_subfile, patch_subfile_names)
4581 (end_symtab_with_blockvector): Update.
4583 2018-07-16 Tom Tromey <tom@tromey.com>
4585 * buildsym.c (struct buildsym_compunit): Add constructor,
4586 destructor, initializers.
4587 (start_buildsym_compunit): Remove.
4588 (free_buildsym_compunit): Use "delete".
4589 (start_symtab, restart_symtab): Use "new".
4591 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
4593 * symfile.c (set_objfile_default_section_offset): Remove struct
4596 2018-07-14 Stafford Horne <shorne@gmail.com>
4598 * (Responsible Maintainers): Add myself as or1k maintainer.
4600 2018-07-13 Tom Tromey <tom@tromey.com>
4602 * symfile.c (set_objfile_default_section_offset): Use extra braces
4605 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4607 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
4610 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4612 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4613 unittests/cli-utils-selftests.c
4614 * unittests/cli-utils-selftests.c: New file.
4616 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4618 * NEWS: Mention new commands. Mention change to 'thread apply'.
4620 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4622 * thread.c (thr_try_catch_cmd): New function.
4623 (thread_apply_all_command): Handle qcs flags.
4624 (thread_apply_command): Handle qcs flags.
4625 (taas_command): New function.
4626 (tfaas_command): New function.
4627 (_initialize_thread): Update to setup the new commands 'taas
4628 and 'tfaas'. Change doc string for 'thread apply'.
4630 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4632 * stack.c: (trailing_outermost_frame): New function, mostly
4633 extracted from backtrace_command_1.
4634 (leading_innermost_frame): New function.
4635 (backtrace_command_1): Update to call trailing_outermost_frame.
4636 (frame_apply_command_count): New function.
4637 (frame_apply_level_command): New function.
4638 (frame_apply_all_command): New function.
4639 (frame_apply_command): New function.
4640 (faas_command): New function.
4641 (frame_cmd_list): New variable.
4642 (_initialize_stack): Update to setup the new commands 'frame apply'
4645 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4647 * cli-utils.c (number_or_range_parser::get_number): Only handle
4648 numbers or convenience var as numbers.
4649 (parse_flags): New function.
4650 (parse_flags_qcs): New function.
4651 (number_or_range_parser::finished): Ensure parsing end is detected
4652 before end of string.
4653 * cli-utils.h (parse_flags): New function.
4654 (parse_flags_qcs): New function.
4655 (number_or_range_parser): Remove m_finished bool.
4656 (number_or_range_parser::skip_range): Set m_in_range to false.
4658 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
4660 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
4663 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4664 Jan Kratochvil <jan.kratochvil@redhat.com>
4665 Paul Fertser <fercerpav@gmail.com>
4666 Tsutomu Seki <sekiriki@gmail.com>
4667 Pedro Alves <palves@redhat.com>
4669 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4670 'unittests/parse-connection-spec-selftests.c'.
4671 (COMMON_SFILES): Add 'common/netstuff.c'.
4672 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
4673 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
4674 * common/netstuff.c: New file.
4675 * common/netstuff.h: New file.
4676 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
4677 (wait_for_connect): Update comment. New parameter
4678 'gdb::optional<int> sock' instead of 'struct serial *scb'.
4679 Use 'sock' directly instead of 'scb->fd'.
4680 (try_connect): New function, with code from 'net_open'.
4681 (net_open): Rewrite main loop to deal with multiple
4682 sockets/addresses. Handle IPv6-style hostnames; implement
4683 support for IPv6 connections.
4684 * unittests/parse-connection-spec-selftests.c: New file.
4686 2018-07-11 Pedro Alves <palves@redhat.com>
4689 * remote.c (remote_target::remote_detach_pid): Call
4690 set_current_process.
4692 2018-07-11 Pedro Alves <palves@redhat.com>
4694 * h8300-tdep.c (h8300_gdbarch_init): Remove
4695 set_gdbarch_ecoff_reg_to_regnum calls.
4697 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4700 * c-typeprint.c (c_type_print_base_struct_union): Don't print
4701 offsets/sizes for static members of a class/struct.
4703 2018-07-11 Alan Hayward <alan.hayward@arm.com>
4705 * target-descriptions.c (tdesc_register_bitsize): Rename.
4706 * target-descriptions.h (tdesc_register_bitsize): Likewise.
4707 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
4708 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
4710 2018-07-10 Tom Tromey <tom@tromey.com>
4712 * breakpoint.c (moribund_locations): Now static and a
4714 (breakpoint_init_inferior, moribund_breakpoint_here_p)
4715 (build_bpstat_chain, update_global_location_list)
4716 (breakpoint_retire_moribund): Update.
4717 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
4720 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4722 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
4723 (riscv_register_reggroup_p): Use new function, remove unneeded
4725 (riscv_push_dummy_call): Extend assert to compare against xlen or
4726 flen based on register type.
4728 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4730 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
4732 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
4734 * remote.c (show_hardware_watchpoint_limit): New function.
4735 (show_hardware_watchpoint_length_limit): New function.
4736 (show_hardware_breakpoint_limit): New function.
4737 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
4738 where appropriate, update help text.
4740 2018-07-09 Tom Tromey <tom@tromey.com>
4742 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
4743 (CLIBS): Don't mention NAT_CLIBS.
4745 2018-07-09 Tom Tromey <tom@tromey.com>
4747 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
4748 (LIBGDB_OBS, clean mostlyclean): Update.
4749 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
4751 2018-07-09 Tom Tromey <tom@tromey.com>
4753 * Makefile.in (%.c: %.y): Use ECHO_YACC.
4754 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
4755 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
4757 2018-07-09 Tom Tromey <tom@tromey.com>
4759 * Makefile.in (ALLDEPFILES): Remove exec.c.
4760 (COMMON_OBS): Remove exec.o.
4761 (COMMON_SFILES): Add exec.c.
4763 2018-07-09 Tom Tromey <tom@tromey.com>
4765 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
4767 2018-07-09 Tom Tromey <tom@tromey.com>
4769 * Makefile.in (clean mostlyclean): Remove stamp-version.
4770 (version.c): Depend on stamp-version.
4771 (stamp-version): New rule, from version.c rule.
4773 2018-07-09 Tom Tromey <tom@tromey.com>
4775 * Makefile.in (init.c): Depend on stamp-init.
4776 (stamp-init): New rule, from init.c rule.
4777 (clean mostlyclean): Remove stamp-init.
4779 2018-07-09 Tom Tromey <tom@tromey.com>
4781 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
4782 SUBDIR_GCC_COMPILE_SRCS.
4784 2018-07-09 Tom Tromey <tom@tromey.com>
4786 * Makefile.in (init.c): Remove some unused sed rules.
4788 2018-07-09 Tom Tromey <tom@tromey.com>
4790 * Makefile.in (TSOBS): Remove.
4791 (INIT_FILES): Update.
4792 (LIBGDB_OBS): Update.
4793 (COMMON_SFILES): Add inflow.c.
4794 (SFILES): Remove inflow.c.
4796 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
4798 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
4800 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
4802 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
4803 get_saveloc_name, is_signal_frame_name, step_name,
4804 init_remote_name, create_addr_space_name,
4805 destroy_addr_space_name, search_unwind_table_name,
4806 find_dyn_list_name): Constify.
4808 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
4810 * darwin-nat.c (darwin_pthread_kill): New function.
4811 (darwin_resume_thread): Use darwin_pthread_kill.
4813 2018-07-05 Tom de Vries <tdevries@suse.de>
4815 * macroexp.c (macro_buffer) <operator=>: New member function.
4817 2018-07-04 Tom Tromey <tom@tromey.com>
4819 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
4821 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
4823 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
4824 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
4825 * maint.c: Likewise.
4828 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4830 * NEWS: Create a new section for the next release branch.
4831 Rename the section of the current branch, now that it has
4834 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4836 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
4837 * version.in: Bump version to 8.2.50.DATE-git.
4839 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4840 Pedro Alves <palves@redhat.com>
4842 * linux-nat.c (linux_init_ptrace): Rename to ...
4843 (linux_init_ptrace_procfs): ... this. Call
4844 linux_proc_init_warnings.
4845 (linux_nat_target::post_attach)
4846 (linux_nat_target::post_startup_inferior): Adjust.
4847 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
4848 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
4850 2018-07-04 Tom de Vries <tdevries@suse.de>
4852 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
4854 (read_comp_unit_head): ... here.
4856 2018-07-03 Tom Tromey <tom@tromey.com>
4858 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
4859 (stop_tracing, tstatus_command)
4860 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
4861 (print_one_static_tracepoint_marker): Update.
4862 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
4864 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
4866 (all_tracepoints, static_tracepoints_here): Return std::vector.
4868 2018-07-03 Tom Tromey <tom@tromey.com>
4870 * common/ptid.c (ptid_equal): Remove.
4871 * common/ptid.h (ptid_equal): Don't declare.
4872 * ada-tasks.c: Update.
4873 * breakpoint.c: Update.
4874 * common/agent.c: Update.
4875 * corelow.c: Update.
4876 * darwin-nat-info.c: Update.
4877 * darwin-nat.c: Update.
4879 * dtrace-probe.c: Update.
4880 * dummy-frame.c: Update.
4881 * fbsd-nat.c: Update.
4883 * gdbthread.h: Update.
4884 * gnu-nat.c: Update.
4885 * go32-nat.c: Update.
4886 * inf-loop.c: Update.
4887 * inf-ptrace.c: Update.
4888 * infcall.c: Update.
4892 * linux-fork.c: Update.
4893 * linux-nat.c: Update.
4894 * linux-thread-db.c: Update.
4895 * mi/mi-cmd-var.c: Update.
4896 * mi/mi-interp.c: Update.
4897 * mi/mi-main.c: Update.
4898 * nto-procfs.c: Update.
4899 * ppc-linux-tdep.c: Update.
4901 * python/py-inferior.c: Update.
4902 * python/py-record-btrace.c: Update.
4903 * python/py-record.c: Update.
4904 * ravenscar-thread.c: Update.
4905 * regcache.c: Update.
4906 * remote-sim.c: Update.
4908 * sol-thread.c: Update.
4911 * tui/tui-stack.c: Update.
4913 * windows-nat.c: Update.
4914 * windows-tdep.c: Update.
4916 2018-07-03 Tom Tromey <tom@tromey.com>
4918 * common/ptid.c (ptid_match): Remove.
4919 * common/ptid.h (ptid_match): Don't declare.
4920 * fbsd-nat.c: Update.
4923 * linux-nat.c: Update.
4924 * record-btrace.c: Update.
4925 * regcache.c: Update.
4928 2018-07-03 Tom Tromey <tom@tromey.com>
4930 * common/ptid.c (ptid_tid_p): Remove.
4931 * common/ptid.h (ptid_tid_p): Don't declare.
4932 * sol-thread.c: Update.
4934 2018-07-03 Tom Tromey <tom@tromey.com>
4936 * common/ptid.c (ptid_lwp_p): Remove.
4937 * common/ptid.h (ptid_lwp_p): Don't declare.
4938 * fbsd-nat.c: Update.
4939 * linux-nat.c: Update.
4940 * nat/linux-procfs.c: Update.
4941 * nat/x86-linux-dregs.c: Update.
4942 * sol-thread.c: Update.
4944 2018-07-03 Tom Tromey <tom@tromey.com>
4946 * common/ptid.c (ptid_is_pid): Remove.
4947 * common/ptid.h (ptid_is_pid): Don't declare.
4949 * linux-nat.c: Update.
4950 * mi/mi-interp.c: Update.
4954 2018-07-03 Tom Tromey <tom@tromey.com>
4956 * common/ptid.c (ptid_get_tid): Remove.
4957 * common/ptid.h (ptid_get_tid): Don't declare.
4958 * ada-tasks.c: Update.
4959 * aix-thread.c: Update.
4960 * bsd-uthread.c: Update.
4961 * darwin-nat.c: Update.
4962 * fbsd-nat.c: Update.
4963 * i386-darwin-nat.c: Update.
4965 * linux-tdep.c: Update.
4966 * nto-procfs.c: Update.
4967 * ppc-ravenscar-thread.c: Update.
4968 * python/py-infthread.c: Update.
4969 * ravenscar-thread.c: Update.
4970 * sol-thread.c: Update.
4971 * sparc-ravenscar-thread.c: Update.
4972 * windows-nat.c: Update.
4974 2018-07-03 Tom Tromey <tom@tromey.com>
4976 * common/ptid.c (ptid_get_lwp): Remove.
4977 * common/ptid.h (ptid_get_lwp): Don't declare.
4978 * aarch64-linux-nat.c: Update.
4979 * ada-tasks.c: Update.
4980 * aix-thread.c: Update.
4981 * amd64-linux-nat.c: Update.
4982 * arm-linux-nat.c: Update.
4983 * corelow.c: Update.
4984 * fbsd-nat.c: Update.
4985 * fbsd-tdep.c: Update.
4986 * gnu-nat.c: Update.
4987 * i386-cygwin-tdep.c: Update.
4988 * i386-gnu-nat.c: Update.
4989 * i386-linux-nat.c: Update.
4990 * ia64-linux-nat.c: Update.
4991 * inf-ptrace.c: Update.
4993 * linux-fork.c: Update.
4994 * linux-nat.c: Update.
4995 * linux-tdep.c: Update.
4996 * linux-thread-db.c: Update.
4997 * mips-linux-nat.c: Update.
4998 * nat/aarch64-linux-hw-point.c: Update.
4999 * nat/aarch64-linux.c: Update.
5000 * nat/linux-btrace.c: Update.
5001 * nat/linux-osdata.c: Update.
5002 * nat/linux-procfs.c: Update.
5003 * nat/x86-linux-dregs.c: Update.
5004 * obsd-nat.c: Update.
5005 * ppc-fbsd-nat.c: Update.
5006 * ppc-linux-nat.c: Update.
5008 * python/py-infthread.c: Update.
5009 * ravenscar-thread.c: Update.
5011 * s390-linux-nat.c: Update.
5012 * sol-thread.c: Update.
5013 * sol2-tdep.c: Update.
5014 * spu-linux-nat.c: Update.
5015 * x86-linux-nat.c: Update.
5016 * xtensa-linux-nat.c: Update.
5018 2018-07-03 Tom Tromey <tom@tromey.com>
5020 * common/ptid.c (ptid_get_pid): Remove.
5021 * common/ptid.h (ptid_get_pid): Don't declare.
5022 * aarch64-linux-nat.c: Update.
5023 * ada-lang.c: Update.
5024 * aix-thread.c: Update.
5025 * alpha-bsd-nat.c: Update.
5026 * amd64-fbsd-nat.c: Update.
5027 * amd64-linux-nat.c: Update.
5028 * arm-linux-nat.c: Update.
5029 * arm-nbsd-nat.c: Update.
5031 * break-catch-syscall.c: Update.
5032 * breakpoint.c: Update.
5033 * bsd-uthread.c: Update.
5034 * corelow.c: Update.
5036 * darwin-nat.c: Update.
5037 * fbsd-nat.c: Update.
5038 * fbsd-tdep.c: Update.
5040 * gnu-nat.c: Update.
5041 * hppa-nbsd-nat.c: Update.
5042 * hppa-obsd-nat.c: Update.
5043 * i386-fbsd-nat.c: Update.
5044 * ia64-linux-nat.c: Update.
5045 * inf-ptrace.c: Update.
5047 * inferior.c: Update.
5048 * inferior.h: Update.
5051 * linux-fork.c: Update.
5052 * linux-nat.c: Update.
5053 * linux-tdep.c: Update.
5054 * linux-thread-db.c: Update.
5055 * m68k-bsd-nat.c: Update.
5056 * mi/mi-interp.c: Update.
5057 * mi/mi-main.c: Update.
5058 * mips-linux-nat.c: Update.
5059 * mips-nbsd-nat.c: Update.
5060 * mips64-obsd-nat.c: Update.
5061 * nat/aarch64-linux-hw-point.c: Update.
5062 * nat/aarch64-linux.c: Update.
5063 * nat/linux-btrace.c: Update.
5064 * nat/linux-osdata.c: Update.
5065 * nat/linux-procfs.c: Update.
5066 * nat/x86-linux-dregs.c: Update.
5067 * nto-procfs.c: Update.
5068 * obsd-nat.c: Update.
5069 * ppc-linux-nat.c: Update.
5070 * ppc-nbsd-nat.c: Update.
5071 * ppc-obsd-nat.c: Update.
5072 * proc-service.c: Update.
5074 * python/py-inferior.c: Update.
5075 * python/py-infthread.c: Update.
5076 * ravenscar-thread.c: Update.
5078 * remote-sim.c: Update.
5080 * rs6000-nat.c: Update.
5081 * s390-linux-nat.c: Update.
5082 * sh-nbsd-nat.c: Update.
5083 * sol-thread.c: Update.
5084 * sparc-nat.c: Update.
5085 * sparc64-tdep.c: Update.
5086 * spu-linux-nat.c: Update.
5087 * spu-tdep.c: Update.
5088 * target-debug.h: Update.
5091 * tid-parse.c: Update.
5092 * tracefile-tfile.c: Update.
5093 * vax-bsd-nat.c: Update.
5094 * windows-nat.c: Update.
5095 * x86-linux-nat.c: Update.
5096 * x86-nat.c: Update.
5098 2018-07-03 Tom Tromey <tom@tromey.com>
5100 * common/ptid.c (pid_to_ptid): Remove.
5101 * common/ptid.h (pid_to_ptid): Don't declare.
5102 * aix-thread.c: Update.
5103 * arm-linux-nat.c: Update.
5104 * common/ptid.c: Update.
5105 * common/ptid.h: Update.
5106 * corelow.c: Update.
5108 * darwin-nat.c: Update.
5109 * fbsd-nat.c: Update.
5110 * fork-child.c: Update.
5111 * gnu-nat.c: Update.
5112 * go32-nat.c: Update.
5113 * inf-ptrace.c: Update.
5115 * inferior.c: Update.
5117 * linux-fork.c: Update.
5118 * linux-nat.c: Update.
5119 * nat/aarch64-linux-hw-point.c: Update.
5120 * nat/fork-inferior.c: Update.
5121 * nat/x86-linux-dregs.c: Update.
5122 * nto-procfs.c: Update.
5123 * obsd-nat.c: Update.
5125 * progspace.c: Update.
5127 * rs6000-nat.c: Update.
5128 * s390-linux-nat.c: Update.
5129 * sol-thread.c: Update.
5130 * spu-linux-nat.c: Update.
5133 * tracefile-tfile.c: Update.
5134 * windows-nat.c: Update.
5136 2018-07-03 Tom Tromey <tom@tromey.com>
5138 * common/ptid.h (ptid_build): Don't declare.
5139 * common/ptid.c (ptid_build): Remove.
5140 * aix-thread.c: Update.
5141 * bsd-kvm.c: Update.
5142 * bsd-uthread.c: Update.
5143 * common/agent.c: Update.
5144 * common/ptid.c: Update.
5145 * common/ptid.h: Update.
5146 * corelow.c: Update.
5147 * darwin-nat.c: Update.
5148 * fbsd-nat.c: Update.
5149 * gnu-nat.c: Update.
5150 * linux-fork.c: Update.
5151 * linux-nat.c: Update.
5152 * linux-thread-db.c: Update.
5153 * nat/linux-osdata.c: Update.
5154 * nat/linux-procfs.c: Update.
5155 * nto-procfs.c: Update.
5156 * obsd-nat.c: Update.
5157 * proc-service.c: Update.
5159 * ravenscar-thread.c: Update.
5160 * remote-sim.c: Update.
5162 * sol-thread.c: Update.
5164 * windows-nat.c: Update.
5166 2018-07-03 Tom Tromey <tom@tromey.com>
5168 * infrun.c (follow_exec): Use exit_inferior_silent.
5169 * inferior.c (exit_inferior_num_silent): Remove.
5170 * inferior.h (exit_inferior_num_silent): Don't declare.
5172 2018-07-03 Tom Tromey <tom@tromey.com>
5175 * darwin-nat.c (darwin_attach_pid): Reset inferior and
5176 inferior_ptid on error.
5178 2018-07-02 Maciej W. Rozycki <macro@mips.com>
5179 Simon Marchi <simon.marchi@polymtl.ca>
5182 * disasm.h (gdb_disassembler): Add
5183 `m_disassembler_options_holder'. member
5184 * disasm.c (get_all_disassembler_options): New function.
5185 (gdb_disassembler::gdb_disassembler): Use it.
5186 (gdb_buffered_insn_length_init_dis): Likewise.
5187 (gdb_buffered_insn_length): Adjust accordingly.
5188 (set_disassembler_options): Handle options with arguments.
5189 (show_disassembler_options_sfunc): Likewise. Add a leading new
5190 line if showing options with descriptions.
5191 (disassembler_options_completer): Adapt to using the
5192 `disasm_options_and_args_t' structure.
5193 * mips-tdep.c (mips_disassembler_options): New variable.
5194 (mips_disassembler_options_o32): Likewise.
5195 (mips_disassembler_options_n32): Likewise.
5196 (mips_disassembler_options_n64): Likewise.
5197 (gdb_print_insn_mips): Don't set `disassembler_options'.
5198 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
5200 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
5201 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
5202 `gdbarch_disassembler_options_implicit' and
5203 `gdbarch_valid_disassembler_options'.
5204 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
5205 `disasm_options_and_args_t' structure.
5206 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
5208 (valid_disassembler_options): Switch from `disasm_options_t' to
5209 the `disasm_options_and_args_t' structure.
5210 * NEWS: Document `set disassembler-options' support for the MIPS
5212 * gdbarch.h: Regenerate.
5213 * gdbarch.c: Regenerate.
5215 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
5217 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
5219 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5221 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
5222 parameter in call to amd64_target_description.
5223 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
5224 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
5225 (amd64fbsd_init_abi): Likewise.
5226 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5227 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
5228 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
5229 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
5231 2018-06-29 Pedro Alves <palves@redhat.com>
5233 * gdb/amd64-tdep.h (amd64_create_target_description): Add
5234 "segments" parameter.
5235 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
5236 (_initialize_amd64_tdep): Update call to
5237 amd64_create_target_description.
5238 (amd64_target_description): Add "segments" parameter. Adjust
5239 the implementation to use it.
5240 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
5241 call to amd64_create_target_description.
5242 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
5243 * gdb/arch/amd64.h (amd64_create_target_description): Add
5244 "segments" register.
5245 * gdb/arch/amd64.c (amd64_create_target_description): Add
5246 "segments" parameter. Call create_feature_i386_64bit_segments
5247 only if SEGMENTS is true.
5248 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
5249 call to amd64_create_target_description.
5251 2018-06-29 Pedro Alves <palves@redhat.com>
5253 * thread.c (thread_target_id_str): New, factored out from ...
5254 (print_thread_info_1): ... here. Use it to compute the max
5255 "Target Id" column width.
5257 2018-06-29 Pedro Alves <palves@redhat.com>
5259 * remote.c (remote_target::extra_thread_info): Delete
5260 'display_buf' and 'n' locals. from the cache, regardless of
5261 packet mechanims is in use. Use cache for qThreadExtra and qP
5264 2018-06-29 Pedro Alves <palves@redhat.com>
5266 * blockframe.c (find_pc_sect_containing_function): New function.
5267 * breakpoint.c (print_breakpoint_location): Don't call
5268 find_pc_sect_function.
5269 * linespec.c (create_sals_line_offset): Record the location's
5271 * linespec.c (convert_address_location_to_sals): Fill in sal's
5272 symbol with find_pc_sect_containing_function.
5273 * symtab.c (find_function_start_sal): Rename to ...
5274 (find_function_start_sal_1): ... this.
5275 (find_function_start_sal): Reimplement as wrapper around
5276 find_function_start_sal_1, and use
5277 find_pc_sect_containing_function to fill in the sal's symbol.
5278 (find_function_start_sal(symbol*, bool)): Adjust.
5279 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
5281 (find_pc_sect_containing_function): Declare.
5283 2018-06-29 Pedro Alves <palves@redhat.com>
5285 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
5286 true if the the location has no symbol.
5288 2018-06-28 Tom Tromey <tom@tromey.com>
5290 * NEWS: Mention --enable-codesign.
5291 * silent-rules.mk (ECHO_SIGN): New variable.
5292 * configure.ac: Add --enable-codesign.
5293 * configure: Rebuild.
5294 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
5295 (gdb$(EXEEXT)): Optionally invoke codesign.
5297 2018-06-28 Pedro Alves <palves@redhat.com>
5299 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
5301 (switch_to_thread_no_regs): Adjust comment.
5302 * infcmd.c (stop_pc): Delete.
5303 (post_create_inferior, info_program_command): Replace references
5304 to stop_pc with references to thread_info->suspend.stop_pc.
5305 * inferior.h (stop_pc): Delete declaration.
5306 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
5307 (handle_inferior_event_1, handle_signal_stop)
5308 (process_event_stop_test, keep_going_stepped_thread)
5309 (handle_step_into_function, handle_step_into_function_backward)
5310 (print_stop_location): Replace references to stop_pc with
5311 references to thread_info->suspend.stop_pc.
5312 (struct infcall_suspend_state) <stop_pc>: Delete field.
5313 (save_infcall_suspend_state, restore_infcall_suspend_state):
5314 Remove references to inf_stat->stop_pc.
5315 * linux-fork.c (fork_load_infrun_state): Likewise.
5316 * record-btrace.c (record_btrace_set_replay): Likewise.
5317 * record-full.c (record_full_goto_entry): Likewise.
5318 * remote.c (print_one_stopped_thread): Likewise.
5319 * target.c (target_resume): Extend comment.
5320 * thread.c (set_executing_thread): New.
5321 (set_executing): Use it.
5322 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
5323 Remove references to stop_pc.
5325 2018-06-28 Pedro Alves <palves@redhat.com>
5327 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
5328 Moving fetching stop_pc until after ecs->event_thread is refreshed.
5330 2018-06-28 Tom Tromey <tom@tromey.com>
5332 * coffread.c (coff_symfile_finish): Update.
5333 * xcoffread.c (xcoff_symfile_finish): Update.
5334 * elfread.c (elf_symfile_finish): Update.
5335 * symfile.h (dwarf2_free_objfile): Don't declare.
5336 * dwarf2read.c (_initialize_dwarf2_read): Use
5337 register_objfile_data_with_cleanup.
5338 (dwarf2_free_objfile): Now static. Change signature.
5340 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5342 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
5343 option "-o" to add-symbol-file-load to add an offset to each
5344 section's load address.
5345 * symfile.c (set_objfile_default_section_offset): New function.
5347 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5349 * symfile.c (add_symbol_file_command): Make sure that sections
5350 with the same name are sorted in the same order.
5352 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5354 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
5355 require the second argument. If omitted, load sections at the
5356 addresses specified in the file.
5358 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5360 * symfile.c (symbol_file_command, symbol_file_add_main_1)
5361 (_initialize_symfile): Add option "-o" to symbol-file to add an
5362 offset to each section of the symbol file.
5364 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5366 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
5368 2018-06-27 Tom Tromey <tom@tromey.com>
5370 * stack.c (_initialize_stack): Update "func" help text.
5372 2018-06-27 Tom Tromey <tom@tromey.com>
5374 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
5376 (unwind_infopy_str, pyuw_create_unwind_info)
5377 (unwind_infopy_add_saved_register, pyuw_sniffer)
5378 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
5380 (struct saved_reg): Add constructor.
5381 <value>: Now a gdbpy_ref<>.
5383 2018-06-27 Tom Tromey <tom@tromey.com>
5385 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
5387 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5389 * gdb-gdb.py.in: Format using autopep8.
5391 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5393 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
5394 (type_lookup_function): Recognize CORE_ADDR values.
5396 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5398 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
5401 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5403 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
5406 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5408 * gdb-gdb.py: Move to...
5409 * gdb-gdb.py.in: ... here.
5410 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
5411 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
5413 (distclean): Remove gdb-gdb.py when cleaning.
5414 (gdb-gdb.py, gdb-gdb.gdb): New rules.
5415 * configure: Re-generate.
5417 2018-06-27 Pedro Alves <palves@redhat.com>
5419 * proc-service.c (get_ps_regcache): New.
5420 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
5421 (ps_lsetfpregs): Use it.
5423 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
5426 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
5427 (dwarf_decode_lines_1): Adjust.
5429 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5431 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
5433 <info_proc>: Likewise.
5435 2018-06-26 Joel Brobecker <brobecker@adacore.com>
5437 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
5438 to windows_fetch_one_register, and only handle the case of
5439 fetching one register. Move the code that reloads the context
5440 and iterates over all registers if R is negative to...
5441 (windows_nat_target::fetch_registers): ... here.
5442 (do_windows_store_inferior_registers): Rename to
5443 windows_store_one_register, and only handle the case of storing
5444 one register. Move the code that handles the case where r is
5446 (windows_nat_target::store_registers) ... here.
5448 2018-06-26 Tom Tromey <tom@tromey.com>
5451 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
5452 * rust-lang.c (rust_print_struct_def): Add podata parameter.
5454 (rust_internal_print_type): Add podata parameter.
5455 (rust_print_type): Update.
5457 2018-06-26 Tom Tromey <tom@tromey.com>
5459 * typeprint.h (struct print_offset_data) <update, finish,
5460 maybe_print_hole>: New methods.
5461 <indentation>: New constant.
5462 * typeprint.c (print_offset_data::indentation): Define.
5463 (print_offset_data::maybe_print_hole, print_offset_data::update)
5464 (print_offset_data::finish): Move from c-typeprint.c and rename.
5465 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
5466 (print_spaces_filtered_with_print_options): Update.
5467 (c_print_type_union_field_offset, maybe_print_hole)
5468 (c_print_type_struct_field_offset): Move to typeprint.c and
5470 (c_type_print_base_struct_union): Update.
5472 2018-06-25 Pedro Alves <palves@redhat.com>
5474 * gdbthread.h (thread_info_ref, delete_thread)
5475 (delete_thread_silent, first_thread_of_inferior)
5476 (any_thread_of_inferior, switch_to_thread)
5477 (enable_thread_stack_temporaries)
5478 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5479 (get_last_thread_stack_temporary)
5480 (value_in_thread_stack_temporaries, can_access_registers_thread):
5481 Spell out "struct thread_info" instead of just "thread_info".
5482 * inferior.h (notice_new_inferior): Likewise.
5484 2018-06-25 Pedro Alves <palves@redhat.com>
5486 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5487 pass thread_info pointer to delete_thread.
5488 (windows_nat_target::detach): Pass inferior pointer to
5490 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
5492 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
5493 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
5494 and pass a thread_info pointer to delete_thread.
5495 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
5496 pass thread_info pointer to delete_thread.
5497 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
5498 delete_thread_silent call.
5499 * procfs.c (procfs_target::detach): Pass inferior pointer to
5501 (procfs_target::wait): Pass thread_info pointer to delete_thread.
5502 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
5503 delete_thread_silent call.
5504 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5505 pass thread_info pointer to delete_thread.
5506 (windows_nat_target::detach): Pass inferior pointer to
5509 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5511 * regcache.c (readable_regcache::read_part): Fix asserts.
5512 (reg_buffer::raw_collect_part): New function.
5513 (regcache::write_part): Fix asserts.
5514 (reg_buffer::raw_supply_part): New function.
5515 (regcache::transfer_regset_register): New helper function.
5516 (regcache::transfer_regset): Call new functions.
5517 (regcache_supply_regset): Use gdb_byte*.
5518 (regcache::supply_regset): Likewise.
5519 (regcache_collect_regset): Likewise.
5520 (regcache::collect_regset): Likewise.
5521 * regcache.h (reg_buffer::raw_collect_part): New declaration.
5522 (reg_buffer::raw_supply_part): Likewise.
5523 (regcache::transfer_regset_register): Likewise.
5524 (regcache::transfer_regset): Use gdb_byte*.
5526 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5528 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
5530 2018-06-21 Pedro Alves <palves@redhat.com>
5532 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
5533 instead of a ptid_t. All callers adjusted.
5534 * ada-tasks.c (ada_get_task_number): Likewise. All callers
5536 (print_ada_task_info, display_current_task_id, task_command_1):
5538 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
5540 (breakpoint_kind): Adjust.
5541 (remove_breakpoints_pid): Rename to ...
5542 (remove_breakpoints_inf): ... this. Adjust to take an inferior
5543 pointer. All callers adjusted.
5544 (bpstat_clear_actions): Use inferior_thread.
5545 (get_bpstat_thread): New.
5546 (bpstat_do_actions): Use it.
5547 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
5548 to take a thread_info pointer. All callers adjusted.
5549 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
5550 (breakpoint_re_set_thread): Use inferior_thread.
5551 * breakpoint.h (struct inferior): Forward declare.
5552 (bpstat_stop_status): Update.
5553 (remove_breakpoints_pid): Delete.
5554 (remove_breakpoints_inf): New.
5555 * bsd-uthread.c (bsd_uthread_target::wait)
5556 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
5557 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
5558 (maint_btrace_packet_history_cmd)
5559 (maint_btrace_clear_packet_history_cmd): Adjust.
5560 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
5562 * cli/cli-interp.c: Include "inferior.h".
5563 * common/refcounted-object.h (struct
5564 refcounted_object_ref_policy): New.
5565 * compile/compile-object-load.c: Include gdbthread.h.
5566 (store_regs): Use inferior_thread.
5567 * corelow.c (core_target::close): Use current_inferior.
5568 (core_target_open): Adjust to use first_thread_of_inferior and use
5569 the current inferior.
5570 * ctf.c (ctf_target::close): Adjust to use current_inferior.
5571 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
5572 <thread>: ... this new field. All references adjusted.
5573 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
5574 Take a thread_info pointer instead of a ptid_t.
5575 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
5576 (dummy_frame_discard, register_dummy_frame_dtor): Take a
5577 thread_info pointer instead of a ptid_t.
5578 * elfread.c: Include "inferior.h".
5579 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
5580 Use inferior_thread.
5581 * eval.c (evaluate_subexp): Likewise.
5582 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
5584 * gdb_proc_service.h (struct thread_info): Forward declare.
5585 (struct ps_prochandle) <ptid>: Delete, replaced by ...
5586 <thread>: ... this new field. All references adjusted.
5587 * gdbarch.h, gdbarch.c: Regenerate.
5588 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
5589 'thread' parameter. All implementations and callers adjusted.
5590 * gdbthread.h (thread_info) <set_running>: New method.
5591 (delete_thread, delete_thread_silent): Take a thread_info pointer
5593 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
5594 (first_thread_of_process): Delete, replaced by ...
5595 (first_thread_of_inferior): ... this new function. All callers
5597 (any_live_thread_of_process): Delete, replaced by ...
5598 (any_live_thread_of_inferior): ... this new function. All callers
5600 (switch_to_thread, switch_to_no_thread): Declare.
5601 (is_executing): Delete.
5602 (enable_thread_stack_temporaries): Update comment.
5603 <enable_thread_stack_temporaries>: Take a thread_info pointer
5604 instead of a ptid_t. Incref the thread.
5605 <~enable_thread_stack_temporaries>: Decref the thread.
5608 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5609 (get_last_thread_stack_temporary)
5610 (value_in_thread_stack_temporaries, can_access_registers_thread):
5611 Take a thread_info pointer instead of a ptid_t. All callers
5613 * infcall.c (get_call_return_value): Use inferior_thread.
5614 (run_inferior_call): Work with thread pointers instead of ptid_t.
5615 (call_function_by_hand_dummy): Work with thread pointers instead
5616 of ptid_t. Use thread_info_ref.
5617 * infcmd.c (proceed_thread_callback): Access thread's state
5619 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
5620 access thread's state directly.
5621 (continue_command): Use inferior_thread.
5622 (info_program_command): Use find_thread_ptid and access thread
5624 (proceed_after_attach_callback): Use thread state directly.
5625 (notice_new_inferior): Take a thread_info pointer instead of a
5626 ptid_t. All callers adjusted.
5627 (exit_inferior): Take an inferior pointer instead of a pid. All
5629 (exit_inferior_silent): New.
5630 (detach_inferior): Delete.
5631 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
5632 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
5633 (detach_inferior_command, kill_inferior_command): Use
5634 find_inferior_id instead of valid_gdb_inferior_id and
5635 gdb_inferior_id_to_pid.
5636 (inferior_command): Use inferior and thread pointers.
5637 * inferior.h (struct thread_info): Forward declare.
5638 (notice_new_inferior): Take a thread_info pointer instead of a
5639 ptid_t. All callers adjusted.
5640 (detach_inferior): Delete declaration.
5641 (exit_inferior, exit_inferior_silent): Take an inferior pointer
5642 instead of a pid. All callers adjusted.
5643 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
5644 (valid_gdb_inferior_id): Delete.
5645 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
5646 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
5647 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
5649 <inf>: ... this new field.
5650 <step_ptid>: Delete, replaced by ...
5651 <step_thread>: ... this new field.
5652 (get_displaced_stepping_state): Take an inferior pointer instead
5653 of a pid. All callers adjusted.
5654 (displaced_step_in_progress_any_inferior): Adjust.
5655 (displaced_step_in_progress_thread): Take a thread pointer instead
5656 of a ptid_t. All callers adjusted.
5657 (displaced_step_in_progress, add_displaced_stepping_state): Take
5658 an inferior pointer instead of a pid. All callers adjusted.
5659 (get_displaced_step_closure_by_addr): Adjust.
5660 (remove_displaced_stepping_state): Take an inferior pointer
5661 instead of a pid. All callers adjusted.
5662 (displaced_step_prepare_throw, displaced_step_prepare)
5663 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
5664 All callers adjusted.
5665 (start_step_over): Adjust.
5666 (infrun_thread_ptid_changed): Remove bit updating ptids in the
5667 displaced step queue.
5668 (do_target_resume): Adjust.
5669 (fetch_inferior_event): Use inferior_thread.
5670 (context_switch, get_inferior_stop_soon): Take an
5671 execution_control_state pointer instead of a ptid_t. All callers
5673 (switch_to_thread_cleanup): Delete.
5674 (stop_all_threads): Use scoped_restore_current_thread.
5675 * inline-frame.c: Include "gdbthread.h".
5676 (inline_state) <inline_state>: Take a thread pointer instead of a
5677 ptid_t. All callers adjusted.
5678 <ptid>: Delete, replaced by ...
5679 <thread>: ... this new field.
5680 (find_inline_frame_state): Take a thread pointer instead of a
5681 ptid_t. All callers adjusted.
5682 (skip_inline_frames, step_into_inline_frame)
5683 (inline_skipped_frames, inline_skipped_symbol): Take a thread
5684 pointer instead of a ptid_t. All callers adjusted.
5685 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
5686 (inline_skipped_frames, inline_skipped_symbol): Likewise.
5687 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
5689 * linux-nat.c (get_detach_signal): Likewise.
5690 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
5691 (thread_db_notice_clone): Adjust.
5692 (thread_db_find_new_threads_silently)
5693 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
5694 a thread pointer instead of a ptid_t. All callers adjusted.
5695 * mi/mi-cmd-var.c: Include "inferior.h".
5696 (mi_cmd_var_update_iter): Update to use thread pointers.
5697 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
5699 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
5701 (mi_output_running): ... this new function.
5702 (mi_on_resume_1): Adjust to use it.
5703 (mi_user_selected_context_changed): Adjust to use inferior_thread.
5704 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
5706 (interrupt_thread_callback): : Adjust to use thread and inferior
5708 * proc-service.c: Include "gdbthread.h".
5709 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
5710 * progspace-and-thread.c: Include "inferior.h".
5711 * progspace.c: Include "inferior.h".
5712 * python/py-exitedevent.c (create_exited_event_object): Adjust to
5713 hold a reference to an inferior_object.
5714 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
5716 * python/py-inferior.c (struct inferior_object): Give the type a
5717 tag name instead of a typedef.
5718 (python_on_normal_stop): No need to check if the current thread is
5720 (inferior_to_inferior_object): Change return type to
5721 inferior_object. All callers adjusted.
5722 (find_thread_object): Delete, bits factored out to ...
5723 (thread_to_thread_object): ... this new function.
5724 * python/py-infthread.c (create_thread_object): Use
5725 inferior_to_inferior_object.
5726 (thpy_is_stopped): Use thread pointer directly.
5727 (gdbpy_selected_thread): Use inferior_thread.
5728 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
5729 field, replaced with ...
5730 <thread>: ... this new field. All users adjusted.
5731 (btpy_insn_or_gap_new): Drop const.
5732 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
5734 * python/py-record.c: Include "gdbthread.h".
5735 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5736 a ptid_t. All callers adjusted.
5737 (gdbpy_current_recording): Use inferior_thread.
5738 * python/py-record.h (recpy_record_object) <ptid>: Delete
5739 field, replaced with ...
5740 <thread>: ... this new field. All users adjusted.
5741 (recpy_element_object) <ptid>: Delete
5742 field, replaced with ...
5743 <thread>: ... this new field. All users adjusted.
5744 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5745 a ptid_t. All callers adjusted.
5746 * python/py-threadevent.c: Include "gdbthread.h".
5747 (get_event_thread): Use thread_to_thread_object.
5748 * python/python-internal.h (struct inferior_object): Forward
5750 (find_thread_object, find_inferior_object): Delete declarations.
5751 (thread_to_thread_object, inferior_to_inferior_object): New
5753 * record-btrace.c: Include "inferior.h".
5754 (require_btrace_thread): Use inferior_thread.
5755 (record_btrace_frame_sniffer)
5756 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
5757 (get_thread_current_frame): Use scoped_restore_current_thread and
5759 (get_thread_current_frame): Use thread pointer directly.
5760 (record_btrace_replay_at_breakpoint): Use thread's inferior
5762 * record-full.c: Include "inferior.h".
5763 * regcache.c: Include "gdbthread.h".
5764 (get_thread_arch_regcache): Use the inferior's address space
5766 (get_thread_regcache, registers_changed_thread): New.
5767 * regcache.h (get_thread_regcache(thread_info *thread)): New
5769 (registers_changed_thread): New.
5770 (remote_target) <remote_detach_1>: Swap order of parameters.
5771 (remote_add_thread): <remote_add_thread>: Return the new thread.
5772 (get_remote_thread_info(ptid_t)): New overload.
5773 (remote_target::remote_notice_new_inferior): Use thread pointers
5775 (remote_target::process_initial_stop_replies): Use
5776 thread_info::set_running.
5777 (remote_target::remote_detach_1, remote_target::detach)
5778 (extended_remote_target::detach): Adjust.
5779 * stack.c (frame_show_address): Use inferior_thread.
5780 * target-debug.h (target_debug_print_thread_info_pp): New.
5781 * target-delegates.c: Regenerate.
5782 * target.c (default_thread_address_space): Delete.
5783 (memory_xfer_partial_1): Use current_inferior.
5784 (target_detach): Use current_inferior.
5785 (target_thread_address_space): Delete.
5786 (generic_mourn_inferior): Use current_inferior.
5787 * target.h (struct target_ops) <thread_address_space>: Delete.
5788 (target_thread_address_space): Delete.
5789 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
5791 (delete_thread_1, delete_thread, delete_thread_silent): Take a
5792 thread pointer instead of a ptid_t. Adjust all callers.
5793 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
5794 (first_thread_of_process): Delete, replaced by ...
5795 (first_thread_of_inferior): ... this new function. All callers
5797 (any_thread_of_process): Rename to ...
5798 (any_thread_of_inferior): ... this, and take an inferior pointer.
5799 (any_live_thread_of_process): Rename to ...
5800 (any_live_thread_of_inferior): ... this, and take an inferior
5802 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5803 (value_in_thread_stack_temporaries)
5804 (get_last_thread_stack_temporary): Take a thread pointer instead
5805 of a ptid_t. Adjust all callers.
5806 (thread_info::set_running): New.
5807 (validate_registers_access): Use inferior_thread.
5808 (can_access_registers_ptid): Rename to ...
5809 (can_access_registers_thread): ... this, and take a thread
5811 (print_thread_info_1): Adjust to compare thread pointers instead
5813 (switch_to_no_thread, switch_to_thread): Make extern.
5814 (scoped_restore_current_thread::~scoped_restore_current_thread):
5815 Use m_thread pointer directly.
5816 (scoped_restore_current_thread::scoped_restore_current_thread):
5817 Use inferior_thread.
5818 (thread_command): Use thread pointer directly.
5819 (thread_num_make_value_helper): Use inferior_thread.
5820 * top.c (execute_command): Use inferior_thread.
5821 * tui/tui-interp.c: Include "inferior.h".
5822 * varobj.c (varobj_create): Use inferior_thread.
5823 (value_of_root_1): Use find_thread_global_id instead of
5824 global_thread_id_to_ptid.
5826 2018-06-21 Alan Hayward <alan.hayward@arm.com>
5828 * regcache.c (readable_regcache::read_part): Avoid memcpy when
5830 (regcache::write_part): Likewise.
5831 (readable_regcache::cooked_read_part): Update comment.
5832 (readable_regcache::cooked_write_part): Likewise.
5833 * regcache.h: (readable_regcache::read_part): Likewise.
5834 (regcache::write_part): Likewise.
5836 2018-06-21 Richard Bunt <richard.bunt@arm.com>
5837 Dirk Schubert <dirk.schubert@arm.com>
5839 * aarch64-linux-nat.c (post_attach): New.
5840 (aarch64_linux_nat_target::post_attach): Override post_attach to
5841 record the number of hardware debug registers.
5843 2018-06-20 Tom Tromey <tom@tromey.com>
5845 * python/py-param.c (add_setshow_generic): Make parameters const.
5846 (parmpy_init): Update.
5848 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5850 * regcache.h (regcache_cooked_read_ftype): Rename to...
5851 (register_read_ftype): ...this, change type to function_view.
5852 (class reg_buffer) <save>: Remove src parameter.
5853 (readonly_detached_regcache) <readonly_detached_regcache>: Make
5854 parameter non-const in first overload. Remove src parameter in
5856 * regcache.c (do_cooked_read): Remove.
5857 (readonly_detached_regcache::readonly_detached_regcache): Make
5858 parameter non-const, adjust call to other constructor.
5859 (reg_buffer::save): Remove src parameter.
5860 * frame.c (do_frame_register_read): Remove.
5861 (frame_save_as_regcache): Use lambda function.
5862 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
5863 parameter to ppu2spu_data *.
5864 (ppu2spu_sniffer): Use lambda function.
5866 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5868 * record-full.c (record_full_target::insert_breakpoint): Remove
5869 "struct" keyword, add const.
5871 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5873 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
5874 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
5875 * configure.ac: Remove AC_PREREQ, add missing quoting.
5876 * gnulib/configure.ac: Modernize usage of
5877 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
5878 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
5879 (AUTOMAKE_VERSION): Bump to 1.15.1.
5880 * configure: Re-generate.
5881 * config.in: Re-generate.
5882 * aclocal.m4: Re-generate.
5883 * gnulib/aclocal.m4: Re-generate.
5884 * gnulib/config.in: Re-generate.
5885 * gnulib/configure: Re-generate.
5886 * gnulib/import/Makefile.in: Re-generate.
5888 2018-06-19 Pedro Alves <palves@redhat.com>
5890 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
5891 (lookup_minimal_symbol_by_pc_section): ... here with
5892 gdb_assert_not_reached added.
5894 2018-06-19 Pedro Alves <palves@redhat.com>
5896 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
5897 parameter with a block parameter. Compare location's block symbol
5898 with the frame's block instead of addresses.
5899 (skip_inline_frames): Pass the current block instead of the
5900 frame's address. Break out as soon as we determine the frame
5901 should not be skipped.
5903 2018-06-18 Tom Tromey <tom@tromey.com>
5905 * solib-aix.c (solib_aix_get_section_offsets): Return
5907 (solib_aix_solib_create_inferior_hook): Update.
5909 2018-06-18 Tom Tromey <tom@tromey.com>
5911 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5913 2018-06-18 Tom Tromey <tom@tromey.com>
5915 * solib-frv.c (frv_relocate_main_executable): Use
5917 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5920 2018-06-18 Tom Tromey <tom@tromey.com>
5922 * objfiles.h (inhibit_section_map_updates): Update.
5923 (resume_section_map_updates, resume_section_map_updates_cleanup):
5925 * solib-svr4.c (svr4_handle_solib_event): Update.
5926 * objfiles.c (inhibit_section_map_updates): Return
5927 scoped_restore_tmpl<int>.
5928 (resume_section_map_updates, resume_section_map_updates_cleanup):
5931 2018-06-18 Tom Tromey <tom@tromey.com>
5933 * valprint.h (read_string): Update.
5934 * valprint.c (read_string): Change type of "buffer".
5935 (val_print_string): Update.
5936 * python/py-value.c (valpy_string): Update.
5937 * language.h (struct language_defn) <la_get_string>: Change
5939 (default_get_string, c_get_string): Update.
5940 * language.c (default_get_string): Change type of "buffer".
5941 * guile/scm-value.c (gdbscm_value_to_string): Update.
5942 * c-lang.c (c_get_string): Change type of "buffer".
5944 2018-06-18 Tom Tromey <tom@tromey.com>
5946 * ser-mingw.c (struct pipe_state_destroyer): New.
5947 (pipe_state_up): New typedef.
5948 (cleanup_pipe_state): Remove.
5949 (pipe_windows_open): Use pipe_state_up. Don't release argv.
5951 2018-06-18 Tom Tromey <tom@tromey.com>
5953 * rust-lang.h (rust_yyerror): Don't declare.
5954 * rust-lang.c (rust_language_defn): Update.
5955 * rust-exp.y (yyerror): Now static.
5956 * parse.c (parse_exp_in_context_1): Update.
5957 * p-lang.h (p_yyerror): Don't declare.
5958 * p-lang.c (p_language_defn): Update.
5959 * p-exp.y (yyerror): Now static.
5960 * opencl-lang.c (opencl_language_defn): Update.
5961 * objc-lang.c (objc_language_defn): Update.
5962 * m2-lang.h (m2_yyerror): Don't declare.
5963 * m2-lang.c (m2_language_defn): Update.
5964 * m2-exp.y (yyerror): Now static.
5965 * language.h (struct language_defn) <la_error>: Remove.
5966 * language.c (unk_lang_error): Remove.
5967 (unknown_language_defn, auto_language_defn): Remove.
5968 * go-lang.h (go_yyerror): Don't declare.
5969 * go-lang.c (go_language_defn): Update.
5970 * go-exp.y (yyerror): Now static.
5971 * f-lang.h (f_yyerror): Don't declare.
5972 * f-lang.c (f_language_defn): Update.
5973 * f-exp.y (yyerror): Now static.
5974 * d-lang.h (d_yyerror): Don't declare.
5975 * d-lang.c (d_language_defn): Update.
5976 * d-exp.y (yyerror): Now static.
5977 * c-lang.h (c_yyerror): Don't declare.
5978 * c-lang.c (c_language_defn, cplus_language_defn)
5979 (asm_language_defn, minimal_language_defn): Update.
5980 * c-exp.y (yyerror): Now static.
5981 * ada-lang.h (ada_yyerror): Don't declare.
5982 * ada-lang.c (ada_language_defn): Update.
5983 * ada-exp.y (yyerror): Now static.
5985 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5987 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
5988 (store_sveregs_to_thread): Likewise.
5989 (aarch64_linux_fetch_inferior_registers): Check for SVE.
5990 (aarch64_linux_store_inferior_registers): Likewise.
5991 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
5993 (aarch64_sve_regs_copy_to_regcache): Likewise.
5994 (aarch64_sve_regs_copy_from_regcache): Likewise.
5995 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
5997 (aarch64_sve_regs_copy_to_regcache): Likewise.
5998 (aarch64_sve_regs_copy_from_regcache): Likewise.
5999 (sve_context): Structure from Linux headers.
6000 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
6001 (SVE_SIG_ZREG_SIZE): Likewise.
6002 (SVE_SIG_PREG_SIZE): Likewise.
6003 (SVE_SIG_FFR_SIZE): Likewise.
6004 (SVE_SIG_REGS_OFFSET): Likewise.
6005 (SVE_SIG_ZREGS_OFFSET): Likewise.
6006 (SVE_SIG_ZREG_OFFSET): Likewise.
6007 (SVE_SIG_ZREGS_SIZE): Likewise.
6008 (SVE_SIG_PREGS_OFFSET): Likewise.
6009 (SVE_SIG_PREG_OFFSET): Likewise.
6010 (SVE_SIG_PREGS_SIZE): Likewise.
6011 (SVE_SIG_FFR_OFFSET): Likewise.
6012 (SVE_SIG_REGS_SIZE): Likewise.
6013 (SVE_SIG_CONTEXT_SIZE): Likewise.
6014 (SVE_PT_REGS_MASK): Likewise.
6015 (SVE_PT_REGS_FPSIMD): Likewise.
6016 (SVE_PT_REGS_SVE): Likewise.
6017 (SVE_PT_VL_INHERIT): Likewise.
6018 (SVE_PT_VL_ONEXEC): Likewise.
6019 (SVE_PT_REGS_OFFSET): Likewise.
6020 (SVE_PT_FPSIMD_OFFSET): Likewise.
6021 (SVE_PT_FPSIMD_SIZE): Likewise.
6022 (SVE_PT_SVE_ZREG_SIZE): Likewise.
6023 (SVE_PT_SVE_PREG_SIZE): Likewise.
6024 (SVE_PT_SVE_FFR_SIZE): Likewise.
6025 (SVE_PT_SVE_FPSR_SIZE): Likewise.
6026 (SVE_PT_SVE_FPCR_SIZE): Likewise.
6027 (__SVE_SIG_TO_PT): Likewise.
6028 (SVE_PT_SVE_OFFSET): Likewise.
6029 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
6030 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
6031 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
6032 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
6033 (SVE_PT_SVE_PREG_OFFSET): Likewise.
6034 (SVE_PT_SVE_PREGS_SIZE): Likewise.
6035 (SVE_PT_SVE_FFR_OFFSET): Likewise.
6036 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
6037 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
6038 (SVE_PT_SVE_SIZE): Likewise.
6039 (SVE_PT_SIZE): Likewise.
6040 (HAS_SVE_STATE): New define.
6042 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6044 * nat/aarch64-sve-linux-sigcontext.h: New file.
6045 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
6047 (SVE_VQ_MIN): Likewise.
6048 (SVE_VQ_MAX): Likewise.
6049 (SVE_VL_MIN): Likewise.
6050 (SVE_VL_MAX): Likewise.
6051 (SVE_NUM_ZREGS): Likewise.
6052 (SVE_NUM_PREGS): Likewise.
6053 (sve_vl_valid): Likewise.
6054 (struct user_sve_header): Likewise.
6056 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
6057 Richard Bunt <Richard.Bunt@arm.com>
6059 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
6060 was requested by GDB.
6062 2018-06-15 Tom de Vries <tdevries@suse.de>
6064 * MAINTAINERS (Write After Approval): Add Tom de Vries.
6066 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
6068 * gnulib/update-gnulib.sh: Print expected versions of
6071 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
6073 * arch-utils.c (default_type_align): Use type_length_units.
6074 * gdbtypes.c (type_align): Use type_length_units.
6076 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6078 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
6079 of 'define' command.
6081 2018-06-14 Tom de Vries <tdevries@suse.de>
6084 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
6085 get_no_prettyformat_print_options.
6087 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
6089 * sparc-nat.h: Include target.h.
6090 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
6091 <fetch_registers>: Remove this argument in function call.
6092 <store_registers>: Remove this argument in function call, remove
6094 <low_forget_process>: Call sparc64_forget_process instead of
6095 sparc_forget_process.
6097 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6099 * procfs.c (_initialize_procfs): Use add_inf_child_target.
6100 (procfs_target::make_corefile_notes): Adjust to new
6101 target_read_alloc return type.
6103 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6104 Stephen Roberts <stephen.roberts@arm.com>
6107 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
6108 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
6109 Move should_notify_stop local into more inner scope.
6111 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6112 Stephen Roberts <stephen.roberts@arm.com>
6115 * infrun.c (resume_1): Add call to mark_async_event_handler.
6117 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6119 * infrun.c (do_target_wait): Change old version of $pc printed.
6121 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
6123 * dwarf2read.c (read_index_from_section): Rename to...
6124 (read_gdb_index_from_section): ... this, update all callers.
6125 (dwarf2_read_index): Rename to...
6126 (dwarf2_read_gdb_index): ... this, update all callers.
6128 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
6130 * gdb/hppa-linux-nat.c
6131 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
6132 hppa_linux_nat_target::fetch_registers.
6134 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6136 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
6137 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
6138 (AARCH64_DWARF_SVE_FFR): Likewise.
6139 (AARCH64_DWARF_SVE_P0): Likewise.
6140 (AARCH64_DWARF_SVE_Z0): Likewise.
6142 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6144 * common/common-regcache.h (raw_compare): New function.
6145 * regcache.c (regcache::raw_compare): Likewise.
6146 * regcache.h (regcache::raw_compare): New declaration.
6148 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6150 * common/common-regcache.h (reg_buffer_common): New structure.
6151 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
6152 (reg_buffer::raw_supply): Likewise.
6153 (reg_buffer::raw_supply_integer): Likewise.
6154 (reg_buffer::raw_supply_zeroed): Likewise.
6155 (reg_buffer::raw_collect): Likewise.
6156 (reg_buffer::raw_collect_integer): Likewise.
6157 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
6158 (reg_buffer::raw_supply): Likewise.
6159 (reg_buffer::raw_supply_integer): Likewise.
6160 (reg_buffer::raw_supply_zeroed): Likewise.
6161 (reg_buffer::raw_collect): Likewise.
6162 (reg_buffer::raw_collect_integer): Likewise.
6164 2018-06-10 Tom Tromey <tom@tromey.com>
6166 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
6167 (class remote_state) <stop_reply_queue>: Now std::vector.
6168 (remote_state::~remote_state)
6169 (remote_target::stop_reply_queue_length): Update.
6170 (struct queue_iter_param, remove_child_of_pending_fork)
6171 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
6172 (check_pending_event_prevents_wildcard_vcont_callback)
6173 (remove_stop_reply_for_inferior)
6174 (remove_stop_reply_of_remote_state)
6175 (remote_notif_remove_once_on_match)
6176 (stop_reply_match_ptid_and_ws)
6177 (remote_kill_child_of_pending_fork): Remove.
6178 (remote_target::remove_new_fork_children)
6179 (remote_target::check_pending_events_prevent_wildcard_vcont)
6180 (remote_target::discard_pending_stop_replies)
6181 (remote_target::discard_pending_stop_replies_in_queue)
6182 (remote_target::remote_notif_remove_queued_reply)
6183 (remote_target::queued_stop_reply)
6184 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
6185 (remote_target::wait, remote_target::kill_new_fork_children)
6186 (remote_target::async): Update.
6188 2018-06-10 Tom Tromey <tom@tromey.com>
6190 * record-full.c (record_full_arch_list_cleanups): Remove.
6191 (record_full_message): Use try/catch.
6192 (record_full_wait_cleanups): Remove.
6193 (record_full_wait_1): Use try/catch.
6194 (record_full_restore): Likewise.
6196 2018-06-10 Tom Tromey <tom@tromey.com>
6198 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
6199 declare VEC. Add constructor.
6200 <in_target_beneath>: Now bool.
6201 (record_full_breakpoints): Now a std::vector, static.
6202 (record_full_sync_record_breakpoints)
6203 (record_full_init_record_breakpoints)
6204 (record_full_target::insert_breakpoint)
6205 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
6207 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
6209 * dwarf2read.c (process_cu_includes): Remove struct keyword.
6210 * serial.c (serial_interface_lookup): Remove struct keyword.
6212 2018-06-10 Tom Tromey <tom@tromey.com>
6214 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
6216 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
6218 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
6220 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
6221 "beneath" as a method.
6222 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
6223 Use "beneath" as a method.
6225 2018-06-10 Tom Tromey <tom@tromey.com>
6227 * tracefile.c (struct trace_file_writer_deleter): New.
6228 <operator()>: Rename from trace_file_writer_xfree.
6229 (trace_file_writer_up): New typedef.
6230 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
6232 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6234 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
6235 <m_registers, m_register_status>: Change type to
6237 * regcache.c (reg_buffer::reg_buffer): Use new instead of
6240 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6242 * common/common-regcache.h (enum register_status): Add
6243 underlying type "signed char".
6244 * regcache.h (reg_buffer) <m_register_status>: Change type to
6246 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
6247 register_status instead of signed char.
6248 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
6249 (reg_buffer::get_register_status): Remove cast.
6250 (readable_regcache::raw_read): Remove cast.
6251 (readable_regcache::cooked_read): Remove cast.
6253 2018-06-09 Tom Tromey <tom@tromey.com>
6255 * source.c (reverse_search_command, forward_search_command): Use
6258 2018-06-09 Tom Tromey <tom@tromey.com>
6260 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
6261 (serial_ops_list): Now static, std::vector.
6262 (serial_interface_lookup, serial_add_interface): Update.
6264 2018-06-09 Tom Tromey <tom@tromey.com>
6266 * dwarf2read.c (process_cu_includes): Update.
6267 (process_full_comp_unit): Update.
6268 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
6271 2018-06-08 Paul Koning <paul_koning@dell.com>
6275 * python/python.c (do_start_initialization):
6276 Avoid call to internal Python API.
6277 (init__gdb_module): New function.
6279 2018-06-08 Gary Benson <gbenson@redhat.com>
6281 * linux-thread-db.c (valprint.h): New include.
6282 (struct check_thread_db_info): New structure.
6283 (check_thread_db_on_load, tdb_testinfo): New static globals.
6284 (check_thread_db, check_thread_db_callback): New functions.
6285 (try_thread_db_load_1): Run integrity checks if requested.
6286 (maintenance_check_libthread_db): New function.
6287 (_initialize_thread_db): Register "maint check libthread-db"
6288 and "maint set/show check-libthread-db".
6289 * NEWS: Mention the above new commands.
6291 2018-06-08 Tom Tromey <tom@tromey.com>
6293 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
6296 2018-06-08 Tom Tromey <tom@tromey.com>
6298 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
6300 2018-06-08 Tom Tromey <tom@tromey.com>
6302 * common/btrace-common.h (struct btrace_data): Add constructor,
6303 destructor, move assignment operator.
6304 <empty, clear, fini>: New methods.
6305 <format>: Initialize.
6306 (btrace_data_init, btrace_data_fini, btrace_data_clear)
6307 (btrace_data_empty): Don't declare.
6308 * common/btrace-common.c (btrace_data_init): Remove.
6309 (btrace_data::fini): Rename from btrace_data_fini.
6310 (btrace_data::empty): Rename from btrace_data_empty.
6311 (btrace_data::clear): Rename from btrace_data_clear. Return
6313 * btrace.h (make_cleanup_btrace_data): Don't declare.
6314 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
6315 (parse_xml_btrace): Update.
6316 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
6317 (maint_btrace_clear_packet_history_cmd): Update.
6319 2018-06-07 Pedro Alves <palves@redhat.com>
6321 * target.h (target_ops) <beneath>: Now a method. All references
6323 (class target_stack): New.
6324 * target.c (g_target_stack): New.
6325 (g_current_top_target): Delete.
6326 (current_top_target): Get the top target out of g_target_stack.
6327 (target_stack::push, target_stack::unpush): New.
6328 (push_target, unpush_target): Reimplement.
6329 (target_is_pushed): Reimplement in terms of g_target_stack.
6330 (target_ops::beneath, target_stack::find_beneath): New.
6332 2018-06-07 Pedro Alves <palves@redhat.com>
6334 * target.h (find_target_beneath): Delete declaration.
6335 * target.c (find_target_beneath): Delete definition.
6336 * aix-thread.c: All callers of find_target_beneath adjusted to
6337 call target_ops::beneath instead.
6338 * bsd-uthread.c: Likewise.
6339 * linux-thread-db.c: Likewise.
6340 * ravenscar-thread.c: Likewise.
6341 * sol-thread.c: Likewise.
6342 * spu-multiarch.c: Likewise.
6344 2018-06-07 Pedro Alves <palves@redhat.com>
6346 * target.h (target_ops) <beneath>: Now a method. All references
6348 (target_ops) <m_beneath>: New.
6349 * target.c (target_ops::beneath): New.
6350 * corelow.c: Adjust all references to target_ops::beneath.
6351 * linux-thread-db.c: Likewise.
6352 * make-target-delegates: Likewise.
6353 * record-btrace.c: Likewise.
6354 * record-full.c: Likewise.
6355 * remote.c: Likewise.
6356 * target.c: Likewise.
6357 * target-delegates.c: Regenerate.
6359 2018-06-07 Pedro Alves <palves@redhat.com>
6361 * target.h (target_stack): Delete.
6362 (current_top_target): Declare function.
6363 * target.c (target_stack): Delete.
6364 (g_current_top_target): New.
6365 (current_top_target): New function.
6366 * auxv.c: Use current_top_target instead of target_stack
6368 * avr-tdep.c: Likewise.
6369 * breakpoint.c: Likewise.
6370 * corefile.c: Likewise.
6371 * elfread.c: Likewise.
6373 * exceptions.c: Likewise.
6374 * frame.c: Likewise.
6375 * gdbarch-selftests.c: Likewise.
6376 * gnu-v3-abi.c: Likewise.
6377 * ia64-tdep.c: Likewise.
6378 * ia64-vms-tdep.c: Likewise.
6379 * infcall.c: Likewise.
6380 * infcmd.c: Likewise.
6381 * infrun.c: Likewise.
6382 * linespec.c: Likewise.
6383 * linux-tdep.c: Likewise.
6384 * minsyms.c: Likewise.
6385 * ppc-linux-nat.c: Likewise.
6386 * ppc-linux-tdep.c: Likewise.
6387 * procfs.c: Likewise.
6388 * regcache.c: Likewise.
6389 * remote.c: Likewise.
6390 * rs6000-tdep.c: Likewise.
6391 * s390-linux-nat.c: Likewise.
6392 * s390-tdep.c: Likewise.
6393 * solib-aix.c: Likewise.
6394 * solib-darwin.c: Likewise.
6395 * solib-dsbt.c: Likewise.
6396 * solib-spu.c: Likewise.
6397 * solib-svr4.c: Likewise.
6398 * solib-target.c: Likewise.
6399 * sparc-tdep.c: Likewise.
6400 * sparc64-tdep.c: Likewise.
6401 * spu-tdep.c: Likewise.
6402 * symfile.c: Likewise.
6403 * symtab.c: Likewise.
6404 * target-descriptions.c: Likewise.
6405 * target-memory.c: Likewise.
6406 * target.c: Likewise.
6407 * target.h: Likewise.
6408 * tracefile-tfile.c: Likewise.
6409 * tracepoint.c: Likewise.
6410 * valops.c: Likewise.
6411 * valprint.c: Likewise.
6412 * value.c: Likewise.
6413 * windows-tdep.c: Likewise.
6414 * mi/mi-main.c: Likewise.
6416 2018-06-07 Tom Tromey <tom@tromey.com>
6418 * valprint.h (build_address_symbolic): Declare.
6419 * printcmd.c (print_address_symbolic): Update.
6420 (build_address_symbolic): Change "name" and "filename" to
6422 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
6424 * defs.h (build_address_symbolic): Remove declaration.
6426 2018-06-07 Alan Hayward <alan.hayward@arm.com>
6428 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
6429 (aarch64_vnv_type): Add function.
6430 (aarch64_pseudo_register_name): Add V regs for SVE.
6431 (aarch64_pseudo_register_type): Likewise.
6432 (aarch64_pseudo_register_reggroup_p): Likewise.
6433 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
6434 (aarch64_pseudo_read_value): Add V regs for SVE.
6435 (aarch64_pseudo_write_2): Use V0 offset for SVE
6436 (aarch64_pseudo_write): Add V regs for SVE.
6437 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
6439 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
6441 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
6442 (sve_vl_from_vq): Likewise.
6444 2018-06-05 Tom Tromey <tom@tromey.com>
6446 * cli/cli-cmds.c (show_version): Update.
6447 * top.c (print_gdb_version): Add "interactive" parameter.
6449 * main.c (captured_main_1): Update.
6450 * top.h (print_gdb_version): Add "interactive" parameter and a
6453 2018-06-05 David Malcolm <dmalcolm@redhat.com>
6455 * common/enum-flags.h: Add trailing semicolon to example in
6458 2018-06-05 Tom Tromey <tom@tromey.com>
6461 * NEWS: Add entry about pager.
6462 * utils.c (pagination_disabled_for_command): New global.
6463 (prompt_for_continue): Allow "c" response to prompt.
6464 (reinitialize_more_filter): Clear
6465 pagination_disabled_for_command.
6466 (fputs_maybe_filtered): Check pagination_disabled_for_command.
6468 2018-06-04 Tom Tromey <tom@tromey.com>
6470 * ada-lang.h (ada_lookup_symbol_list): Update.
6471 * ada-lang.c (resolve_subexp): Update.
6472 (symbols_are_identical_enums): Change type of syms. Remove nsyms
6474 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
6475 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
6476 results parameter to std::vector.
6477 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
6479 * ada-exp.y (block_lookup): Update.
6480 (select_possible_type_sym): Change type of syms. Remove nsyms
6482 (write_var_or_type, write_name_assoc): Update.
6484 2018-06-04 Joel Brobecker <brobecker@adacore.com>
6486 * windows-nat.c (windows_nat_target::xfer_partial): Return
6487 TARGET_XFER_E_IO if we need to delegate to the target beneath
6488 but BENEATH is NULL.
6490 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
6492 * Makefile.in (config.status): Add configure.nat as a
6495 2018-06-04 Tom Tromey <tom@tromey.com>
6497 * cp-name-parser.y (cpname_state): Add method declarations.
6498 (HANDLE_QUAL): Update.
6499 (cpname_state::d_grab, cpname_state::fill_comp)
6500 (cpname_state::make_operator, cpname_state::make_dtor)
6501 (cpname_state::make_builtin_type, cpname_state::make_name)
6502 (cpname_state::d_qualify, cpname_state::d_int_type)
6503 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
6504 (%union): Move earlier.
6506 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6508 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
6510 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6512 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
6513 (aarch64_pseudo_write_1): Likewise.
6514 (aarch64_pseudo_read_value): Use helper.
6515 (aarch64_pseudo_write): Likewise.
6517 2018-06-04 Pedro Alves <palves@redhat.com>
6519 * darwin-nat.c (darwin_ops): Delete.
6520 (darwin_attach_pid): Use get_native_target.
6522 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6524 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
6525 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
6527 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6529 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
6530 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
6531 (aarch64_gdbarch_init): Check for SVE.
6532 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
6534 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6536 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
6537 * aarch64-tdep.h (aarch64_read_description): Likewise.
6538 * arch/aarch64.c (aarch64_create_target_description): Likewise.
6539 * arch/aarch64.h (aarch64_create_target_description): Likewise.
6540 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
6541 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
6542 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
6544 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
6546 * value.c (value_fetch_lazy_bitfield): New.
6547 (value_fetch_lazy_memory): New.
6548 (value_fetch_lazy_register): New.
6549 (value_fetch_lazy): Factor out to smaller functions.
6551 2018-06-01 Tom Tromey <tom@tromey.com>
6553 * cp-name-parser.y (backslashable, represented): Now const.
6555 2018-06-01 Tom Tromey <tom@tromey.com>
6557 * cp-name-parser.y: Include parser-defs.h.
6558 (parser_fprintf): Remove declaration.
6560 2018-06-01 Tom Tromey <tom@tromey.com>
6562 * cp-name-parser.y: Use %pure-parser, %lex-param, and
6564 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
6565 (global_result): Remove globals.
6566 (struct cpname_state): New.
6567 (yyparse): Don't declare.
6568 (yylex, yyerror): Move declarations after %union.
6569 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
6570 (make_name): Add state parameter.
6572 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
6574 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
6576 (yylex): Add lvalp, state parameters.
6577 (yyerror): Add state parameter.
6578 (cp_demangled_name_to_comp): Update.
6580 2018-06-01 Tom Tromey <tom@tromey.com>
6582 * cp-name-parser.y (parser_fprintf): Declare.
6583 (GDB_YY_REMAP_PREFIX): Define.
6584 Include yy-remap.h. Don't redefine yy* identifiers.
6586 2018-06-01 Tom Tromey <tom@tromey.com>
6588 * python/py-type.c (typy_legacy_template_argument): Update.
6589 * cp-support.h (cp_demangled_name_to_comp): Update.
6590 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
6591 parameter to be a "std::string *".
6594 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
6596 * ada-lex.l: Include "diagnostics.h" instead of
6597 "common/diagnostics.h".
6598 * unittests/environ-selftests.c: Likewise.
6599 * common/diagnostics.h: Moved to ../include.
6601 2018-06-01 Joel Brobecker <brobecker@adacore.com>
6603 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
6604 to language_mode_manual while calling breakpoint_re_set_one.
6606 2018-06-01 Tom Tromey <tom@tromey.com>
6608 * valops.c (value_cast_structs, destructor_name_p): Update.
6609 * symtab.c (gdb_mangle_name): Update.
6610 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
6612 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
6613 (pascal_object_print_value_fields, pascal_object_print_value):
6615 * p-typeprint.c (pascal_type_print_derivation_info): Update.
6616 * linespec.c (find_methods): Update.
6617 * gdbtypes.h (type_name_no_tag): Remove.
6618 (type_name_or_error): Rename from type_name_no_tag_or_error.
6619 * gdbtypes.c (type_name_no_tag): Remove.
6620 (type_name_or_error): Rename from type_name_no_tag_or_error.
6621 (lookup_struct_elt_type, check_typedef): Update.
6622 * expprint.c (print_subexp_standard): Update.
6623 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
6624 * d-namespace.c (d_lookup_nested_symbol): Update.
6625 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
6626 (cp_print_class_member): Update.
6627 * cp-namespace.c (cp_lookup_nested_symbol): Update.
6628 * completer.c (add_struct_fields): Update.
6629 * c-typeprint.c (cp_type_print_derivation_info)
6630 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
6632 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
6633 (ada_prefer_type, ada_is_exception_sym): Update.
6635 2018-06-01 Tom Tromey <tom@tromey.com>
6637 * valops.c (enum_constant_from_type, value_namespace_elt)
6638 (value_maybe_namespace_elt): Update.
6639 * valarith.c (find_size_for_pointer_math): Update.
6640 * target-descriptions.c (make_gdb_type): Update.
6641 * symmisc.c (print_symbol): Update.
6642 * stabsread.c (define_symbol, read_type)
6643 (complain_about_struct_wipeout, add_undefined_type)
6644 (cleanup_undefined_types_1): Update.
6645 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
6646 (rust_range_type_p, val_print_struct, rust_print_struct_def)
6647 (rust_internal_print_type, rust_composite_type)
6648 (rust_evaluate_funcall, rust_evaluate_subexp)
6649 (rust_inclusive_range_type_p): Update.
6650 * python/py-type.c (typy_get_tag): Update.
6651 * p-typeprint.c (pascal_type_print_base): Update.
6652 * mdebugread.c (parse_symbol, parse_type): Update.
6653 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
6655 * guile/scm-type.c (gdbscm_type_tag): Update.
6656 * go-lang.c (sixg_string_p): Update.
6657 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
6659 * gdbtypes.h (struct main_type) <tag_name>: Remove.
6660 (TYPE_TAG_NAME): Remove.
6661 * gdbtypes.c (type_name_no_tag): Simplify.
6662 (check_typedef, check_types_equal, recursive_dump_type)
6663 (copy_type_recursive, arch_composite_type): Update.
6664 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
6665 in summary mode when needed.
6666 * eval.c (evaluate_funcall): Update.
6667 * dwarf2read.c (fixup_go_packaging, read_structure_type)
6668 (process_structure_scope, read_enumeration_type)
6669 (read_namespace_type, read_module_type, determine_prefix): Update.
6670 * cp-support.c (inspect_type): Update.
6671 * coffread.c (process_coff_symbol, decode_base_type): Update.
6672 * c-varobj.c (c_is_path_expr_parent): Update.
6673 * c-typeprint.c (c_type_print_base_struct_union): Update.
6674 (c_type_print_base_1): Update. Print struct/class/union/enum in
6675 summary when using C language.
6676 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
6677 (gen_maybe_namespace_elt): Update.
6678 * ada-lang.c (ada_type_name): Simplify.
6679 (empty_record, ada_template_to_fixed_record_type_1)
6680 (template_to_static_fixed_type)
6681 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
6683 2018-06-01 Tom Tromey <tom@tromey.com>
6685 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
6687 * c-typeprint.c (c_print_type_1): Add "language" parameter.
6688 (c_print_type): Update.
6689 (c_print_type): New overload.
6690 (c_type_print_varspec_prefix, c_type_print_args)
6691 (c_type_print_varspec_suffix, c_print_type_no_offsets)
6692 (c_type_print_base_struct_union, c_type_print_base_1)
6693 (cp_type_print_method_args): Add "language" parameter.
6694 (c_type_print_base): Update.
6695 * c-lang.h (c_print_type): Add new overload.
6697 2018-06-01 Tom Tromey <tom@tromey.com>
6699 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
6700 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
6702 2018-06-01 Alan Hayward <alan.hayward@arm.com>
6704 * aarch64-tdep.c (aarch64_sve_register_names): New const
6706 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
6707 (AARCH64_SVE_Z_REGS_NUM): New define.
6708 (AARCH64_SVE_P_REGS_NUM): Likewise.
6709 (AARCH64_SVE_NUM_REGS): Likewise.
6711 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
6713 * nat/linux-ptrace.h [__alpha__]
6714 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
6717 2018-05-31 Maciej W. Rozycki <macro@mips.com>
6719 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
6720 the endianness selected.
6721 * NEWS: Document `set endian auto' mode operation update.
6723 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6725 * Makefile.in: Add new header.
6726 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
6727 (sve_vl_from_vg): Likewise.
6728 (sve_vq_from_vl): Likewise.
6729 (sve_vl_from_vq): Likewise.
6730 (sve_vq_from_vg): Likewise.
6731 (sve_vg_from_vq): Likewise.
6732 * configure.nat: Add new c file.
6733 * nat/aarch64-sve-linux-ptrace.c: New file.
6734 * nat/aarch64-sve-linux-ptrace.h: New file.
6736 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6738 * aarch64-linux-nat.c (aarch64_linux_read_description):
6740 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
6742 * aarch64-tdep.c (tdesc_aarch64_list): Add.
6743 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
6744 (aarch64_gdbarch_init): Add parmeter zero.
6745 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
6746 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
6747 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
6749 * doc/gdb.texinfo: Describe SVE feature
6750 * features/aarch64-sve.c: New file.
6752 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
6755 * gdbarch.sh (significant_addr_bit): Default to zero when
6756 not set by target architecture.
6757 * gdbarch.c: Re-generated.
6758 * utils.c (address_significant): Update.
6760 2018-05-30 Joel Brobecker <brobecker@adacore.com>
6762 * stack.c (func_command): Remove trailing newline in call to error.
6764 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6766 * regcache.h (regcache_raw_collect): Remove, update callers to
6767 use regcache::raw_collect.
6768 * regcache.c (regcache_raw_collect): Remove.
6770 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6772 * regcache.h (regcache_raw_supply): Remove, update callers to
6773 use detached_regcache::raw_supply.
6774 * regcache.c (regcache_raw_supply): Remove.
6776 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6778 * regcache.h (regcache_cooked_write_part): Remove, update
6779 callers to use regcache::cooked_write_part.
6780 * regcache.c (regcache_cooked_write_part): Remove.
6782 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6784 * regcache.h (regcache_cooked_read_part): Remove, update callers
6785 to use readable_regcache::cooked_read_part.
6786 * regcache.c (regcache_cooked_read_part): Remove.
6788 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6790 * regcache.h (regcache_cooked_read_value): Remove, update
6791 callers to use readable_regcache::cooked_read_value.
6792 * regcache.c (regcache_cooked_read_value): Remove.
6794 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6796 * regcache.h (regcache_cooked_write): Remove, update callers to
6797 use regcache::cooked_write.
6798 * regcache.c (regcache_cooked_write): Remove.
6800 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6802 * regcache.h (regcache_invalidate): Remove, update callers to
6803 use detached_regcache::invalidate instead.
6804 * regcache.c (regcache_invalidate): Remove.
6806 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6808 * regcache.h (regcache_raw_write_part): Remove, update callers
6809 to use regcache::raw_write_part instead.
6810 * regcache.c (regcache_raw_write_part): Remove.
6812 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6814 * regcache.h (regcache_raw_read_part): Remove, update callers to
6815 use readable_regcache::raw_read_part instead.
6816 * regcache.c (regcache_raw_read_part): Remove.
6818 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6820 * regcache.h (regcache_cooked_read): Remove, update callers to
6821 use readable_regcache::cooked_read instead.
6822 * regcache.c (regcache_cooked_read): Remove.
6824 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6826 * regcache.h (regcache_raw_write): Remove, update callers to use
6827 regcache::raw_write instead.
6828 * regcache.c (regcache_raw_write): Remove.
6830 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6832 * regcache.h (regcache_raw_read): Remove, update callers to use
6833 readable_regcache::raw_read instead.
6834 * regcache.c (regcache_raw_read): Remove.
6836 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6838 * regcache.h (regcache_raw_update): Remove, update callers to
6839 use readable_regcache::raw_update instead.
6840 * regcache.c (regcache_raw_update): Remove.
6842 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6844 * regcache.h (regcache_register_status): Remove, update callers
6845 to use reg_buffer::get_register_status directly instead.
6846 * regcache.c (regcache_register_status): Remove.
6848 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6850 * regcache.h (regcache_get_ptid): Remove, update all callers to
6851 call regcache::ptid instead.
6852 * regcache.c (regcache_get_ptid): Remove.
6854 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6856 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
6858 2018-05-30 Pedro Alves <palves@redhat.com>
6860 * common/common-exceptions.h (exception_rethrow): Use
6863 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
6865 * breakpoint.c (print_solib_event, check_status_catch_solib):
6866 Remove struct keyword in range-based for loops.
6867 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
6868 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
6870 * linespec.c (find_superclass_methods, search_minsyms_for_name):
6872 * symfile.c (addr_info_make_relative): Likewise.
6873 * thread.c (value_in_thread_stack_temporaries): Likewise.
6875 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
6878 * valops.c (value_struct_elt_for_reference): Call check_typedef on
6879 aggregate type to get its real type before accessing it.
6881 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
6883 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
6884 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
6885 * coff-pe-read.c (add_pe_forwarded_sym): Replace
6886 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
6887 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
6888 * jit.c (jit_breakpoint_re_set_internal): Likewise.
6889 * printcmd.c (info_address_command): Likewise.
6891 2018-05-29 Tom Tromey <tom@tromey.com>
6893 * windows-nat.c (handle_exception): Update fall-through comment.
6895 2018-05-29 Tom Tromey <tom@tromey.com>
6897 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
6898 (struct program_space) <added_solibs>: Now a std::vector.
6899 * breakpoint.c (print_solib_event): Update.
6900 (check_status_catch_solib): Update.
6901 * progspace.c (clear_program_space_solib_cache): Update.
6902 * solib.c (update_solib_list): Update.
6904 2018-05-29 Tom Tromey <tom@tromey.com>
6906 * python/py-type.c (typy_richcompare): Update.
6907 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
6908 * gdbtypes.h (types_deeply_equal): Return bool.
6909 (types_equal): Likewise.
6910 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6912 (check_types_equal): Change worklist to std::vector. Return
6914 (struct type_equality_entry): Add constructor.
6915 (compare_maybe_null_strings): Return bool.
6916 (check_types_worklist): Return bool. Change worklist to
6918 (types_deeply_equal): Use std::vector.
6919 (types_equal): Return bool.
6920 (compare_maybe_null_strings): Simplify.
6922 2018-05-29 Tom Tromey <tom@tromey.com>
6924 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6926 2018-05-29 Tom Tromey <tom@tromey.com>
6928 * objc-lang.h: Don't include cp-support.h.
6929 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6932 2018-05-27 Tom Tromey <tom@tromey.com>
6934 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6936 2018-05-25 Tom Tromey <tom@tromey.com>
6938 * value.c (value::location): Initialize.
6940 2018-05-25 Tom Tromey <tom@tromey.com>
6942 * dbxread.c (init_bincl_list): Remove.
6943 (bincl_list): Now a std::vector.
6944 (bincls_allocated, next_bincl): Remove.
6945 (free_bincl_list, do_free_bincl_list_cleanup)
6946 (make_cleanup_free_bincl_list): Remove.
6947 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
6949 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
6950 (struct header_file_location): Add constructor.
6951 (add_bincl_to_list): Remove.
6953 2018-05-25 Tom Tromey <tom@tromey.com>
6955 * tui/tui.c (tui_enable): Update.
6956 * mi/mi-interp.c (mi_interp::init): Update.
6957 * interps.h (class interp) <name>: New method.
6958 <m_name>: Rename from name.
6959 (~scoped_restore_interp): Update.
6960 * interps.c (interp::interp): Update.
6961 (interp_add, interp_set, interp_lookup_existing)
6962 (current_interp_named_p): Update.
6964 2018-05-25 Tom Tromey <tom@tromey.com>
6966 * interps.c (interp_name): Remove.
6967 * mi/mi-interp.c (mi_interp::init): Update.
6968 * interps.h (interp_name): Remove.
6969 (~scoped_restore_interp): Update.
6970 * tui/tui.c (tui_enable): Update.
6972 2018-05-25 Tom Tromey <tom@tromey.com>
6974 * utils.c (fputs_maybe_filtered): Update.
6975 * linespec.c (decode_line_full): Update.
6976 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
6977 (mi_print_breakpoint_for_event, mi_solib_loaded)
6978 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6979 (mi_user_selected_context_changed): Update.
6980 * mi/mi-main.c (mi_execute_command): Update.
6981 * cli/cli-script.c (execute_control_command): Update.
6982 * python/python.c (execute_gdb_command): Update.
6983 * solib.c (info_sharedlibrary_command): Update.
6984 * interps.c (interp_ui_out): Remove.
6985 * interps.h (interp_ui_out): Remove.
6987 2018-05-25 Tom Tromey <tom@tromey.com>
6989 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
6990 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
6991 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
6993 2018-05-25 Tom Tromey <tom@tromey.com>
6995 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
6996 * interps.c (interp_exec): Use scoped_restore.
6998 2018-05-25 Tom Tromey <tom@tromey.com>
7000 * remote.c (remote_target::remote_file_get): Use
7002 (remote_target::remote_file_put): Likewise.
7004 2018-05-25 Tom Tromey <tom@tromey.com>
7006 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
7008 (get_pe_section_index, add_pe_exported_sym): Update.
7009 (read_pe_exported_syms): Use gdb::def_vector.
7011 2018-05-25 Tom Tromey <tom@tromey.com>
7013 * frame.c (remove_prev_frame): Remove.
7014 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
7016 2018-05-25 Maciej W. Rozycki <macro@mips.com>
7018 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
7020 * mips-linux-nat.c (supply_fpregset): Always call
7021 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
7022 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
7023 `mips_fill_fpregset'.
7024 * mips-linux-tdep.c (mips_supply_fpregset)
7025 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
7026 (mips_fill_fpregset_wrapper): Remove functions.
7027 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
7028 (mips_linux_fpregset): Remove variable.
7029 (mips_linux_iterate_over_regset_sections): Use
7030 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
7031 (mips_linux_o32_sigframe_init): Remove comment.
7033 2018-05-25 Pedro Alves <palves@redhat.com>
7035 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
7036 (struct readahead_cache, struct packet_reg, struct
7037 remote_arch_state, class remote_state): Move higher up in the
7039 (remote_target::m_remote_state): Now an object instead of a pointer.
7040 (remote_target::get_remote_state): Adjust.
7042 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7044 * stack.c (select_and_print_frame): Delete.
7045 (struct function_bounds): Move struct within function.
7046 (func_command): Most content moved into new function
7047 find_frame_for_function, use new function, print result, add
7049 (find_frame_for_function): New function, now returns a result.
7051 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7053 * stack.c (iterate_over_block_arg_vars): Fix comment.
7054 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
7056 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7060 (scoped_restore_selected_frame::scoped_restore_selected_frame):
7062 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
7064 * frame.h (class scoped_restore_selected_frame): New class.
7065 * stack.c (print_frame_local_vars): Remove catching and rethrowing
7066 of any exception, use scoped_restore_selected_frame to restore the
7069 2018-05-24 Pedro Alves <palves@redhat.com>
7071 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
7074 2018-05-23 Tom Tromey <tom@tromey.com>
7076 * complaints.c (struct complaints): Remove.
7077 (symfile_complaint_book): Remove.
7078 (series): New global.
7079 (complaint_internal): Update.
7080 (clear_complaints): Update.
7082 2018-05-23 Tom Tromey <tom@tromey.com>
7084 * complaints.c (counters): New global.
7085 (struct complain): Remove.
7086 (struct complaints) <root>: Remove.
7087 (complaint_sentinel): Remove.
7088 (symfile_complaint_book): Update.
7089 (find_complaint) Remove.
7090 (complaint_internal, clear_complaints): Update.
7092 2018-05-23 Tom Tromey <tom@tromey.com>
7094 * complaints.c (struct complain) <file, line>: Remove.
7095 (find_complaint): Remove file, line parameters.
7096 (complaint_internal): Update.
7098 2018-05-23 Tom Tromey <tom@tromey.com>
7100 * complaints.c (vcomplaint): Remove.
7101 (complaint_internal) Merge in contents of vcomplaint.
7103 2018-05-23 Tom Tromey <tom@tromey.com>
7105 * complaints.c (struct complaints) <explanation>: Remove.
7106 (symfile_explanations): Remove.
7107 (symfile_complaint_book): Update.
7108 (vcomplaint): Update.
7109 (struct explanation): Remove.
7111 2018-05-23 Tom Tromey <tom@tromey.com>
7113 * complaints.c (symfile_complaints): Remove.
7114 (complaint_internal): Remove "complaints" parameter.
7115 (clear_complaints, vcomplaint): Remove "c" parameter.
7116 (get_complaints): Remove.
7117 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
7118 (dwarf2_debug_line_missing_file_complaint)
7119 (dwarf2_debug_line_missing_end_sequence_complaint)
7120 (dwarf2_complex_location_expr_complaint)
7121 (dwarf2_const_value_length_mismatch_complaint)
7122 (dwarf2_section_buffer_overflow_complaint)
7123 (dwarf2_macro_malformed_definition_complaint)
7124 (dwarf2_invalid_attrib_class_complaint)
7125 (create_addrmap_from_index, dw2_symtab_iter_next)
7126 (dw2_expand_marked_cus)
7127 (dw2_debug_names_iterator::find_vec_in_debug_names)
7128 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
7129 (create_debug_type_hash_table, init_cutu_and_read_dies)
7130 (partial_die_parent_scope, add_partial_enumeration)
7131 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
7132 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
7133 (read_import_statement, read_file_scope, create_dwo_cu_reader)
7134 (create_cus_hash_table, create_dwp_hash_table)
7135 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
7136 (dwarf2_rnglists_process, dwarf2_ranges_process)
7137 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
7138 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
7139 (handle_struct_member_die, process_structure_scope)
7140 (read_array_type, read_common_block, read_module_type)
7141 (read_tag_pointer_type, read_typedef, read_base_type)
7142 (read_subrange_type, load_partial_dies, partial_die_info::read)
7143 (partial_die_info::read, partial_die_info::read)
7144 (partial_die_info::read, read_checked_initial_length_and_offset)
7145 (dwarf2_string_attr, read_formatted_entries)
7146 (dwarf_decode_line_header)
7147 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
7148 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
7149 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
7150 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
7151 (get_signatured_type, get_DW_AT_signature_type)
7152 (decode_locdesc, file_file_name, consume_improper_spaces)
7153 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
7154 (dwarf_decode_macro_bytes, dwarf_decode_macros)
7155 (dwarf2_symbol_mark_computed, set_die_type)
7156 (read_attribute_value): Update.
7157 * stap-probe.c (handle_stap_probe, get_stap_base_address):
7159 * dbxread.c (unknown_symtype_complaint)
7160 (lbrac_mismatch_complaint, repeated_header_complaint)
7161 (set_namestring, function_outside_compilation_unit_complaint)
7162 (read_dbx_symtab, process_one_symbol): Update.
7163 * gdbtypes.c (stub_noname_complaint): Update.
7164 * windows-nat.c (handle_unload_dll): Update.
7165 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
7166 (decode_base_type): Update.
7167 * xcoffread.c (bf_notfound_complaint, ef_complaint)
7168 (eb_complaint, record_include_begin, record_include_end)
7169 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
7170 (process_xcoff_symbol, read_symbol)
7171 (function_outside_compilation_unit_complaint)
7172 (scan_xcoff_symtab): Update.
7173 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
7174 * buildsym.c (finish_block_internal, make_blockvector)
7175 (end_symtab_get_static_block, augment_type_symtab): Update.
7176 * dtrace-probe.c (dtrace_process_dof)
7177 (dtrace_static_probe_ops::get_probes): Update.
7178 * complaints.h (struct complaint): Don't declare.
7179 (symfile_complaints): Remove.
7180 (complaint_internal): Remove "complaints" parameter.
7181 (complaint): Likewise.
7182 (clear_complaints): Likewise.
7183 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7184 (reread_symbols): Update.
7185 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
7186 (dwarf2_frame_cache, decode_frame_entry): Update.
7187 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
7188 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7189 (info_selectors_command): Update.
7190 * macrotab.c (macro_include, check_for_redefinition)
7191 (macro_undef): Update.
7192 * objfiles.c (filter_overlapping_sections): Update.
7193 * stabsread.c (invalid_cpp_abbrev_complaint)
7194 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
7195 (define_symbol, error_type, read_type, rs6000_builtin_type)
7196 (stabs_method_name_from_physname, read_member_functions)
7197 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
7198 (attach_fields_to_type, complain_about_struct_wipeout)
7199 (read_range_type, read_args, common_block_start)
7200 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
7202 * mdebugread.c (index_complaint, unknown_ext_complaint)
7203 (basic_type_complaint, bad_tag_guess_complaint)
7204 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
7205 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
7206 (parse_procedure, parse_lines)
7207 (function_outside_compilation_unit_complaint)
7208 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
7209 (bad_tag_guess_complaint, reg_value_complaint): Update.
7210 * cp-support.c (demangled_name_complaint): Update.
7211 * macroscope.c (sal_macro_scope): Update.
7212 * dwarf-index-write.c (class debug_names): Update.
7214 2018-05-23 Tom Tromey <tom@tromey.com>
7216 * complaints.c (clear_complaints): Remove "noisy" parameter.
7217 * complaints.h (clear_complaints): Update.
7218 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7219 (reread_symbols): Update.
7221 2018-05-23 Tom Tromey <tom@tromey.com>
7223 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
7225 (vcomplaint, clear_complaints): Update.
7226 (symfile_explanations): Remove some messages.
7228 2018-05-23 Tom Tromey <tom@tromey.com>
7230 * complaints.c (internal_complaint): Remove.
7231 * complaints.h (internal_complaint): Remove.
7233 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7235 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
7237 2018-05-22 Pedro Alves <palves@redhat.com>
7239 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
7240 (remote_fileio_badfd, remote_fileio_return_errno)
7241 (remote_fileio_return_success, remote_fileio_func_open)
7242 (remote_fileio_func_open, remote_fileio_func_close)
7243 (remote_fileio_func_read, remote_fileio_func_write)
7244 (remote_fileio_func_lseek, remote_fileio_func_rename)
7245 (remote_fileio_func_unlink, remote_fileio_func_stat)
7246 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
7247 (remote_fileio_func_isatty, remote_fileio_func_system): Add
7248 remote_target parameter.
7249 (remote_fio_func_map) <func>: Add remote_target parameter.
7250 (do_remote_fileio_request, remote_fileio_request):
7251 * remote-fileio.h (remote_fileio_request):
7252 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
7253 remote_target parameter.
7254 (remote_notif_process, handle_notification): Adjust to pass down
7256 (remote_notif_state_allocate): Add remote_target parameter. Save
7258 * remote-notif.h (struct remote_target): Forward declare.
7259 (struct notif_client) <parse, ack, can_get_pending_events>: Add
7260 remote_target parameter.
7261 (struct remote_notif_state) <remote>: New field.
7262 (remote_notif_ack, remote_notif_parse): Add remote_target
7264 (remote_notif_state_allocate, remote_notif_state_allocate): Add
7265 remote_target parameter.
7266 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
7267 (threads_listing_context, rmt_thread_action, protocol_feature)
7268 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
7269 (packet_result, struct threads_listing_context, remote_state):
7270 Move definitions and declarations higher up.
7271 (remote_target) <~remote_target>: Declare.
7272 (remote_download_command_source, remote_file_put, remote_file_get)
7273 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
7274 (remote_hostio_pread_vFile, remote_hostio_send_command)
7275 (remote_hostio_set_filesystem, remote_hostio_open)
7276 (remote_hostio_close, remote_hostio_unlink, remote_state)
7277 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
7278 (get_memory_write_packet_size, get_memory_read_packet_size)
7279 (append_pending_thread_resumptions, remote_detach_1)
7280 (append_resumption, remote_resume_with_vcont)
7281 (add_current_inferior_and_thread, wait_ns, wait_as)
7282 (process_stop_reply, remote_notice_new_inferior)
7283 (process_initial_stop_replies, remote_add_thread)
7284 (btrace_sync_conf, remote_btrace_maybe_reopen)
7285 (remove_new_fork_children, kill_new_fork_children)
7286 (discard_pending_stop_replies, stop_reply_queue_length)
7287 (check_pending_events_prevent_wildcard_vcont)
7288 (discard_pending_stop_replies_in_queue, stop_reply)
7289 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
7290 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
7291 (remote_interrupt_as, remote_interrupt_ns)
7292 (remote_get_noisy_reply, remote_query_attached)
7293 (remote_add_inferior, remote_current_thread, get_current_thread)
7294 (set_thread, set_general_thread, set_continue_thread)
7295 (set_general_process, write_ptid)
7296 (remote_unpack_thread_info_response, remote_get_threadinfo)
7297 (parse_threadlist_response, remote_get_threadlist)
7298 (remote_threadlist_iterator, remote_get_threads_with_ql)
7299 (remote_get_threads_with_qxfer)
7300 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
7301 (get_offsets, remote_check_symbols, remote_supported_packet)
7302 (remote_query_supported, remote_packet_size)
7303 (remote_serial_quit_handler, remote_detach_pid)
7304 (remote_vcont_probe, remote_resume_with_hc)
7305 (send_interrupt_sequence, interrupt_query)
7306 (remote_notif_get_pending_events, fetch_register_using_p)
7307 (send_g_packet, process_g_packet, fetch_registers_using_g)
7308 (store_register_using_P, store_registers_using_G)
7309 (set_remote_traceframe, check_binary_download)
7310 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
7311 (remote_xfer_live_readonly_partial, remote_read_bytes)
7312 (remote_send_printf, remote_flash_write, readchar)
7313 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
7314 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
7315 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
7316 (extended_remote_disable_randomization, extended_remote_run)
7317 (send_environment_packet, extended_remote_environment_support)
7318 (extended_remote_set_inferior_cwd, remote_write_qxfer)
7319 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
7320 (packet_command): Now methods of ...
7321 (remote_target): ... this class.
7322 (m_remote_state) <remote_target>: New field.
7323 (struct remote_state) <stop_reply_queue,
7324 remote_async_inferior_event_token, wait_forever_enabled_p>: New
7326 (remote_state::remote_state): Allocate stop_reply_queue.
7327 (remote_state): Delete global.
7328 (get_remote_state_raw): Delete.
7329 (remote_target::get_remote_state): Allocate m_remote_state on
7331 (get_current_remote_target): New.
7332 (remote_ops, extended_remote_ops): Delete.
7333 (wait_forever_enabled_p, remote_async_inferior_event_token):
7334 Delete, moved to struct remote_state.
7335 (remote_target::close): Delete self. Destruction bits split to
7337 (remote_target::~remote_target): ... this.
7338 (show_memory_packet_size): Adjust to use
7339 get_current_remote_target.
7340 (struct protocol_feature) <func>: Add remote_target parameter.
7341 All callers adjusted.
7342 (curr_quit_handler_target): New.
7343 (remote_serial_quit_handler): Reimplement.
7344 (remote_target::open_1): Adjust to use get_current_remote_target.
7345 Heap-allocate remote_target/extended_remote_target instances.
7346 (vcont_builder::vcont_builder): Add remote_target parameter, and
7347 save it in m_remote. All callers adjusted.
7348 (vcont_builder::m_remote): New field.
7349 (vcont_builder::restart, vcont_builder::flush)
7350 (vcont_builder::push_action): Use it.
7351 (remote_target::commit_resume): Use it.
7352 (struct queue_iter_param) <remote>: New field.
7353 (remote_target::remove_new_fork_children): Fill in 'remote' field.
7354 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
7355 (check_pending_event_prevents_wildcard_vcont_callback)
7356 (remote_target::check_pending_events_prevent_wildcard_vcont)
7357 (remote_target::discard_pending_stop_replies)
7358 (remote_target::discard_pending_stop_replies_in_queue)
7359 (remote_target::remote_notif_remove_queued_reply): Fill in
7361 (remote_notif_get_pending_events): New.
7362 (remote_target::readchar, remote_target::remote_serial_write):
7363 Save/restore curr_quit_handler_target.
7365 (kill_new_fork_children): Fill in 'remote' field.
7366 (packet_command): Use get_current_remote_target, defer to
7367 remote_target method of same name.
7368 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
7369 parameter, and save it in m_remote. All callers adjusted.
7370 (scoped_remote_fd::release): Use m_remote.
7371 (scoped_remote_fd::m_remote): New field.
7372 (remote_file_put, remote_file_get, remote_file_delete): Use
7373 get_current_remote_target, defer to remote_target method of same
7375 (remote_btrace_reset): Add remote_state paremeter. Update all
7377 (remote_async_inferior_event_handler). Pass down 'data'.
7378 (remote_new_objfile): Use get_current_remote_target.
7379 (remote_target::vcont_r_supported): New.
7380 (set_range_stepping): Use get_current_remote_target and
7381 remote_target::vcont_r_supported.
7382 (_initialize_remote): Don't allocate 'remote_state' and
7383 'stop_reply_queue' globals.
7384 * remote.h (struct remote_target): Forward declare.
7385 (getpkt, putpkt, remote_notif_get_pending_events): Add
7386 'remote_target' parameter.
7388 2018-05-22 Pedro Alves <palves@redhat.com>
7390 * remote.c (vcont_builder): Now a class. Make all data members
7392 (vcont_builder) <vcont_builder, restart, flush, push_action>:
7394 (vcont_builder_restart): Rename to ...
7395 (vcont_builder::restart): ... this.
7396 (vcont_builder_flush): Rename to ...
7397 (vcont_builder::flush): ... this.
7398 (vcont_builder_push_action): Rename to ...
7399 (vcont_builder::push_action): ... this.
7400 (remote_target::commit_resume): Adjust.
7402 2018-05-22 Pedro Alves <palves@redhat.com>
7404 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
7405 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
7406 (get_fixed_memory_packet_size): New.
7407 (get_memory_packet_size): Use it.
7408 (set_memory_packet_size): Don't override the config size with
7409 DEFAULT_MAX_MEMORY_PACKET_SIZE.
7410 (show_memory_packet_size): Use get_fixed_memory_packet_size.
7411 Don't refer to get_memory_packet_size if not connected to a remote
7412 target. Show "(default)" if configured size is 0.
7414 2018-05-22 Pedro Alves <palves@redhat.com>
7416 * remote.c (remote_target::mourn_inferior): Move
7417 discard_pending_stop_replies call here from ...
7418 (_initialize_remote): ... here.
7420 2018-05-22 Pedro Alves <palves@redhat.com>
7422 * remote.c (compare_section_command): Remove set_general_process
7425 2018-05-22 Pedro Alves <palves@redhat.com>
7427 * remote.c (struct packet_reg, struct remote_arch_state):
7428 Move higher up in the file.
7429 (remote_state) <m_arch_states>: Store remote_arch_state values
7430 instead of remote_arch_state pointers.
7431 (remote_state::get_remote_arch_state): Adjust.
7433 2018-05-22 Pedro Alves <palves@redhat.com>
7435 * remote.c: Include <unordered_map>.
7436 (remote_state): Now a class.
7437 (remote_state) <get_remote_arch_state>: Declare method.
7438 <get_remote_arch_state>: New field.
7439 (remote_arch_state) <remote_arch_state>: Declare ctor.
7440 <regs>: Now a unique_ptr.
7441 (remote_gdbarch_data_handle): Delete.
7442 (get_remote_arch_state): Delete.
7443 (remote_state::get_remote_arch_state): New.
7444 (get_remote_state): Adjust to call remote_state's
7445 get_remote_arch_state method.
7446 (init_remote_state): Delete, bits factored out to ...
7447 (remote_arch_state::remote_arch_state): ... this new method.
7448 (get_remote_packet_size, get_memory_packet_size)
7449 (process_g_packet, remote_target::fetch_registers)
7450 (remote_target::prepare_to_store, store_registers_using_G)
7451 (remote_target::store_registers, remote_target::get_trace_status):
7452 Adjust to call remote_state's method.
7453 (_initialize_remote): Remove reference to
7454 remote_gdbarch_data_handle.
7456 2018-05-22 Pedro Alves <palves@redhat.com>
7458 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
7459 pread>: New method declarations.
7460 (remote_target::open_1): Adjust.
7461 (readahead_cache_invalidate): Rename to ...
7462 (readahead_cache::invalidate): ... this, and adjust to be a class
7464 (readahead_cache_invalidate_fd): Rename to ...
7465 (readahead_cache::invalidate_fd): ... this, and adjust to be a
7467 (remote_hostio_pwrite): Adjust.
7468 (remote_hostio_pread_from_cache): Rename to ...
7469 (readahead_cache::pread): ... this, and adjust to be a class
7471 (remote_hostio_close): Adjust.
7473 2018-05-22 Pedro Alves <palves@redhat.com>
7475 * remote.c (remote_hostio_close_cleanup): Delete.
7476 (class scoped_remote_fd): New.
7477 (remote_file_put, remote_file_get): Use it.
7479 2018-05-22 Pedro Alves <palves@redhat.com>
7481 (struct vCont_action_support): Use bool and initialize all fields.
7482 (struct readahead_cache): Initialize all fields.
7483 (remote_state): Use bool and initialize all fields.
7484 (remote_state::remote_state, remote_state::~remote_state): New.
7485 (new_remote_state): Delete.
7486 (_initialize_remote): Use new to allocate remote_state.
7488 2018-05-22 Pedro Alves <palves@redhat.com>
7492 * c-exp.y: Include "c-support.h".
7493 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
7494 of tolower. Use c_ident_is_alpha to scan names.
7495 * c-lang.c: Include "c-support.h".
7496 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
7497 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
7498 * c-support.h: New file, with bits factored out from ...
7499 * cp-name-parser.y: ... this file.
7500 Include "c-support.h".
7501 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
7502 c-support.h and renamed.
7503 (symbol_end, yylex): Adjust.
7505 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7507 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
7508 parameter type to CORE_ADDR.
7509 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
7510 parameter type in declaration to CORE_ADDR.
7511 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
7512 target_auxv_search to get AT_HWCAP and use the result to get the
7514 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
7515 to CORE_ADDR. Remove the cast of the return value to unsigned
7516 long. Fix error predicate of target_auxv_search.
7517 (ppc_linux_nat_target::read_description): Change the type of the
7518 hwcap variable to CORE_ADDR.
7520 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7522 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
7523 if the size of fpscr is larger than 32 bits.
7525 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7527 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
7528 (ppc32_linux_vsxregmap): New global.
7529 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
7530 regcache_supply_regset, and regcache_collect_regset.
7531 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
7532 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
7533 (fetch_vsx_register, store_vsx_register): Remove.
7534 (fetch_vsx_registers): Add regno parameter. Get regset using
7535 ppc_linux_vsxregset. Use regset to supply registers.
7536 (store_vsx_registers): Add regno parameter. Get regset using
7537 ppc_linux_vsxregset. Use regset to collect registers.
7538 (fetch_register): Call fetch_vsx_registers instead of
7540 (store_register): Call store_vsx_registers instead of
7542 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
7543 new regno parameter.
7544 (store_ppc_registers): Call store_vsx_registers with -1 for the
7545 new regno parameter.
7546 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
7547 (ppc_collect_vsxregset): Remove.
7549 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7551 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
7553 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
7554 for vector register offset fields.
7555 (ppc64_fbsd_reg_offsets): Likewise.
7556 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7557 to vector register offset fields.
7558 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7559 to vector register offset fields.
7560 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
7561 vector register offset fields.
7562 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
7563 initializers for vector register offset fields.
7564 (rs6000_aix64_reg_offsets): Likewise.
7565 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
7566 (ppc_supply_vrregset): Remove.
7567 (ppc_collect_vrregset): Remove.
7568 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
7569 (ppc_linux_vrregset) : New function.
7570 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
7571 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
7572 (ppc32_linux_vrregset): Remove.
7573 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
7574 and use result instead of ppc32_linux_vrregset.
7575 (ppc32_linux_reg_offsets): Remove initializers for vector register
7577 (ppc64_linux_reg_offsets): Likewise.
7578 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
7579 * ppc-linux-nat.c: Include regset.h.
7580 (gdb_vrregset_t): Adjust comment to account for little-endian
7582 (supply_vrregset, fill_vrregset): Remove.
7583 (fetch_altivec_register, store_altivec_register): Remove.
7584 (fetch_altivec_registers): Add regno parameter. Get regset using
7585 ppc_linux_vrregset. Use regset to supply registers.
7586 (store_altivec_registers): Add regno parameter. Get regset using
7587 ppc_linux_vrregset. Use regset to collect registers.
7588 (fetch_register): Call fetch_altivec_registers instead of
7589 fetch_altivec_register.
7590 (store_register): Call store_altivec_registers instead of
7591 store_altivec_register.
7592 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
7593 the new regno parameter.
7594 (store_ppc_registers): Call store_altivec_registers with -1 for
7595 the new regno parameter.
7597 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7599 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
7600 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
7601 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
7602 (gdb_vrregset_t): Change array type size to
7603 PPC_LINUX_SIZEOF_VRREGSET.
7604 (gdb_vsxregset_t): Change array type size to
7605 PPC_LINUX_SIZEOF_VSXREGSET.
7606 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
7607 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
7608 PPC_LINUX_SIZEOF_VSXREGSET.
7610 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7612 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
7613 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
7615 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
7616 ppc_linux_target_wordsize with tid.
7617 (ppc_linux_nat_target::read_description): Call ppc_linux_target
7619 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
7620 (ppc64_64bit_inferior_p): Add static and inline specifiers.
7621 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
7622 tid parameter. Remove static specifier.
7623 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
7624 (ppc_linux_target_wordsize): New declaration.
7626 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7628 * arch/ppc-linux-common.c: New file.
7629 * arch/ppc-linux-common.h: New file.
7630 * arch/ppc-linux-tdesc.h: New file.
7631 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
7632 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
7633 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
7634 arch/ppc-linux-tdesc.h.
7635 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
7636 arch/ppc-linux-tdesc.h.
7637 (ppc_linux_nat_target::read_description): Remove target
7638 description matching code. Fill a ppc_linux_features struct and
7639 call ppc_linux_match_description with it. Move comment about ISA
7640 2.05 to ppc-linux-common.c.
7641 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
7642 arch/ppc-linux-tdesc.h.
7643 (ppc_linux_core_read_description): Remove target description
7644 matching code. Fill a ppc_linux_features struct and call
7645 ppc_linux_match_description with it.
7646 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
7647 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
7648 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
7649 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
7650 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
7651 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
7652 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
7653 (tdesc_powerpc_e500l): Remove.
7655 2018-05-22 Joel Brobecker <brobecker@adacore.com>
7657 * ada-lang.c (catch_assert_command): Pass empty string instead
7658 of NULL for excep_string argument.
7660 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7662 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
7663 the width of the requested register exceeds the width of the
7666 2018-05-21 Tom Tromey <tom@tromey.com>
7668 * printcmd.c (output_command): Remove.
7669 (output_command_const): Rename to output_command.
7670 * valprint.h (output_command): Rename from output_command_const.
7671 * tracepoint.c (trace_dump_actions): Call output_command.
7673 2018-05-21 Tom Tromey <tom@tromey.com>
7675 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7676 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
7677 * ada-lang.h (create_ada_exception_catchpoint): Update.
7678 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
7680 (create_excep_cond_exprs, ~ada_catchpoint)
7681 (should_stop_exception, print_one_exception)
7682 (print_mention_exception, print_recreate_exception): Update.
7683 (ada_get_next_arg): Remove.
7684 (catch_ada_exception_command_split): Use std::string. Change type
7685 of "excep_string", "cond_string".
7686 (catch_ada_exception_command): Update.
7687 (create_ada_exception_catchpoint): Change type of excep_string.
7688 (ada_exception_sal): Remove excep_string parameter.
7689 (~ada_catchpoint): Remove.
7691 2018-05-21 Tom Tromey <tom@tromey.com>
7693 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
7696 2018-05-21 Tom Tromey <tom@tromey.com>
7698 * ada-lang.c (ada_exception_message_1, ada_exception_message):
7699 Return unique_xmalloc_ptr.
7700 (print_it_exception): Update.
7702 2018-05-21 Tom Tromey <tom@tromey.com>
7704 * tracepoint.c (trace_dump_actions): Use std::string.
7706 2018-05-21 Tom Tromey <tom@tromey.com>
7708 * symfile.c (reread_symbols): Use std::string for original_name.
7710 2018-05-21 Tom Tromey <tom@tromey.com>
7712 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
7713 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
7716 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
7718 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
7720 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
7721 * objfiles.c (get_objfile_bfd_data): Allocate
7722 objfile_per_bfd_storage with obstack_new when allocating on
7725 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7727 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
7729 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
7730 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
7731 * mdebugread.c (mdebug_build_psymtabs): Likewise.
7732 (add_pending): Likewise.
7733 (parse_symbol): Likewise.
7734 (parse_partial_symbols): Likewise.
7735 (psymtab_to_symtab_1): Likewise.
7736 (new_psymtab): Likewise.
7737 (elfmdebug_build_psymtabs): Likewise.
7738 * minsyms.c (terminate_minimal_symbol_table): Likewise.
7739 * objfiles.c (get_objfile_bfd_data): Likewise.
7740 (objfile_register_static_link): Likewise.
7741 * psymtab.c (allocate_psymtab): Likewise.
7742 * stabsread.c (read_member_functions): Likewise.
7743 * xcoffread.c (xcoff_end_psymtab): Likewise.
7745 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7747 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
7748 compiler supports std::is_trivially_constructible.
7749 * common/poison.h: Include obstack.h.
7750 (IsMallocable): Define to is_trivially_constructible if the
7751 compiler supports it, define to true_type otherwise.
7755 (XOBNEWVEC): Redefine.
7756 * gdb_obstack.h (obstack_zalloc): New.
7757 (OBSTACK_ZALLOC): Redefine.
7758 (obstack_calloc): New.
7759 (OBSTACK_CALLOC): Redefine.
7761 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
7762 (gdbarch_obstack): New declaration in gdbarch.h, definition in
7764 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
7765 obstack_calloc/obstack_zalloc.
7766 (gdbarch_obstack_zalloc): Remove.
7767 * target-descriptions.c (tdesc_data_init): Use obstack_new.
7769 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7771 * stack.c (backtrace_command_1): Remove useless variable int i.
7773 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7775 * stack.c (print_frame_info): Fix comment.
7777 2018-05-18 Tom Tromey <tom@tromey.com>
7779 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
7780 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
7781 (~dwarf2_per_objfile): Update
7782 (dwarf2_get_dwz_file): Use new.
7783 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
7786 2018-05-18 Tom Tromey <tom@tromey.com>
7788 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
7790 * dwarf2read.c (struct dwp_file): Add constructor and
7792 (open_and_init_dwp_file): Return a unique_ptr.
7793 (dwarf2_per_objfile, create_dwp_hash_table)
7794 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
7795 (lookup_dwo_unit_in_dwp): Update.
7796 (open_and_init_dwp_file, get_dwp_file): Update.
7798 2018-05-18 Tom Tromey <tom@tromey.com>
7800 * dwarf2read.c (dwarf2_per_objfile): Update.
7801 (struct mapped_index): Add initializers.
7802 (dwarf2_read_index): Use new.
7803 (dw2_symtab_iter_init): Update.
7804 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
7807 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7809 * dwarf2read.c (mapped_index) <total_size>: Remove.
7811 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7813 * unittests/format_pieces-selftests.c (test_format_specifier):
7816 2018-05-18 Tom Tromey <tom@tromey.com>
7818 * c-typeprint.c (maybe_print_hole): New function.
7819 (c_print_type_struct_field_offset): Update.
7820 (c_type_print_base_struct_union): Call maybe_print_hole.
7822 2018-05-17 Keith Seitz <keiths@redhat.com>
7824 * breakpoint.c (build_bpstat_chain): New function, moved from
7826 (bpstat_stop_status): Add optional parameter, `stop_chain'.
7827 If no stop chain is passed, call build_bpstat_chain to build it.
7828 * breakpoint.h (build_bpstat_chain): Declare.
7829 (bpstat_stop_status): Move documentation here from breakpoint.c.
7830 * infrun.c (handle_signal_stop): Before eliding inlined frames,
7831 build the stop chain and pass it to skip_inline_frames.
7832 Pass this stop chain to bpstat_stop_status.
7833 * inline-frame.c: Include breakpoint.h.
7834 (stopped_by_user_bp_inline_frame): New function.
7835 (skip_inline_frames): Add parameter `stop_chain'.
7836 Move documention to inline-frame.h.
7837 If non-NULL, use stopped_by_user_bp_inline_frame to determine
7838 whether the frame should be elided.
7839 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
7840 Add moved documentation and update for new parameter.
7842 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7845 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7846 unittests/format_pieces-selftests.c.
7847 * common/format.h (format_piece) <operator==>: New.
7848 (format_pieces) <operator[]>: Remove.
7849 * common/format.c (format_pieces::format_pieces): Handle \e.
7850 * unittests/format_pieces-selftests.c: New.
7852 2018-05-17 Tom Tromey <tom@tromey.com>
7855 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
7856 (dw2_instantiate_symtab): Add skip_partial parameter.
7857 (dw2_find_last_source_symtab, dw2_map_expand_apply)
7858 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
7859 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
7860 (dw2_expand_symtabs_matching_one)
7861 (dw2_find_pc_sect_compunit_symtab)
7862 (dw2_debug_names_lookup_symbol)
7863 (dw2_debug_names_expand_symtabs_for_function): Update.
7864 (init_cutu_and_read_dies): Add skip_partial parameter.
7865 (process_psymtab_comp_unit, build_type_psymtabs_1)
7866 (process_skeletonless_type_unit, load_partial_comp_unit)
7867 (psymtab_to_symtab_1): Update.
7868 (load_full_comp_unit): Add skip_partial parameter.
7869 (process_imported_unit_die, dwarf2_read_addr_index)
7870 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
7871 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
7872 (read_signatured_type): Update.
7874 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7876 * value.c (release_value): Remove unused variable.
7877 (record_latest_value): Likewise.
7878 (access_value_history): Likewise.
7879 (preserve_values): Likewise.
7881 2018-05-17 Tom Tromey <tom@tromey.com>
7883 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
7886 2018-05-16 Maciej W. Rozycki <macro@mips.com>
7889 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
7890 Also handle registers whose width is not a multiple of
7892 (linux_nat_trad_target::store_register): Likewise.
7894 2018-05-16 Tom Tromey <tom@tromey.com>
7896 * gdbcore.h (core_bfd): Redefine.
7897 * corelow.c (core_target::close): Update.
7898 (core_target_open): Update.
7899 * progspace.h (struct program_space) <cbfd>: Now a
7902 2018-05-16 Tom Tromey <tom@tromey.com>
7905 * symfile-add-flags.h (enum symfile_add_flags)
7906 <SYMFILE_NOT_FILENAME>: New constant.
7907 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
7908 objfile name from BFD.
7909 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7910 * minidebug.c (find_separate_debug_file_in_section): Put
7911 ".gnu_debugdata" into BFD's file name.
7913 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7915 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7918 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7921 * aarch64-tdep.c (aarch64_analyze_prologue,
7922 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7923 Indicate not interested in errors.
7925 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7927 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7928 Supply the MIPS_ZERO_REGNUM register.
7930 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7932 * mips-tdep.c (mask_address_var): Make variable static.
7934 2018-05-14 Tom Tromey <tom@tromey.com>
7936 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7938 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7940 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7941 FXSAVE_ADDR for the mxcsr register.
7943 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7945 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
7947 2018-05-11 Pedro Alves <palves@redhat.com>
7949 * corelow.c (core_target) <core_target>: No longer inline.
7950 Initialize m_core_gdbarch, m_core_vec and build the section table
7952 <~core_target>: New.
7953 <core_gdbarch, get_core_register_section>: New methods.
7954 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
7955 factored out from ...
7956 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
7958 (sniff_core_bfd): Add gdbarch parameter.
7959 (core_close): Delete, merged into ...
7960 (core_target::close): ... here. Delete self.
7961 (core_close_cleanup): Delete.
7962 (core_target_open): Allocate a core_target on the heap. Use a
7963 unique_ptr instead of a cleanup. Bits moved into the core_target
7964 ctor. Adjust to use core_target methods instead of globals.
7965 (get_core_register_section): Rename to ...
7966 (core_target::get_core_register_section): ... this and adjust.
7967 (struct get_core_registers_cb_data): New.
7968 (get_core_registers_cb): Use it. Use bool.
7969 (core_target::fetch_registers, core_target::files_info)
7970 (core_target::xfer_partial, core_target::read_description)
7971 (core_target::pid_to, core_target::thread_name): Adjust to
7972 reference class fields instead of globals.
7973 * target.h (struct target_ops_deleter, target_ops_up): New.
7975 2018-05-11 Pedro Alves <palves@redhat.com>
7977 * corefile.c (core_file_command): Move to corelow.c.
7978 * corelow.c (the_core_target): Delete.
7979 (core_file_command): Moved from corefile.c. Check exec_bfd
7980 instead of the_core_target. Use target_detach instead of calling
7981 into the_core_target directly.
7982 (maybe_say_no_core_file_now): New.
7983 (core_target::detach): Use it.
7984 (_initialize_corelow): Remove references to the_core_target.
7985 * gdbcore.h (the_core_target): Delete.
7987 2018-05-11 Tom Tromey <tromey@redhat.com>
7988 Pedro Alves <palves@redhat.com>
7990 * corefile.c (core_bfd): Remove.
7991 * gdbcore.h (core_bfd): Now a macro.
7992 * progspace.h (struct program_space) <cbfd>: New field.
7994 2018-05-11 Tom Tromey <tom@tromey.com>
7996 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
7999 2018-05-10 Tom Tromey <tom@tromey.com>
8001 * configure: Rebuild.
8002 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
8004 2018-05-10 Joel Brobecker <brobecker@adacore.com>
8007 * regformats/regdat.sh: Adjust script, following the addition
8008 of the new expedite_regs parameter to init_target_desc.
8010 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
8013 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
8014 set_gdbarch_significant_addr_bit.
8015 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
8016 set_gdbarch_significant_addr_bit.
8017 * utils.c (address_significant): Update to sign extend addr.
8019 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
8021 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
8022 (xtensa_linux_init_abi): Limit tdep->num_regs by
8023 tdep->num_nopriv_regs.
8024 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
8025 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
8028 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
8030 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
8032 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
8034 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
8035 (I387_MXCSR_INIT_VAL): New constant.
8036 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
8037 buffer if it was supplied by the inferior.
8038 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
8039 (i387_xsave_get_clear_bv): New function.
8040 (i387_supply_xsave): Only read x87 control registers from the
8041 xsave buffer if the feature is enabled, and the state will have
8042 been written, otherwise, provide a suitable default.
8043 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
8044 including x87 control registers. Update control registers if they
8045 have changed from the default value, and mark features as enabled
8047 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
8049 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
8051 * spu-tdep.c (info_spu_event_command): Fix output formatting.
8053 2018-05-07 Tom Tromey <tom@tromey.com>
8055 * configure: Rebuild.
8056 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
8058 2018-05-07 Tom Tromey <tom@tromey.com>
8061 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
8062 bit. Use correct value for VDIV.
8064 2018-05-04 Tom Tromey <tom@tromey.com>
8066 * configure: Rebuild.
8067 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
8069 2018-05-04 Tom Tromey <tom@tromey.com>
8071 * linux-record.c (record_linux_system_call) <case
8072 RECORD_SYS_RECVFROM>: Add "break".
8074 2018-05-04 Tom Tromey <tom@tromey.com>
8076 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
8077 Add missing "break".
8078 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
8079 Add missing "break".
8081 2018-05-04 Tom Tromey <tom@tromey.com>
8083 * rs6000-tdep.c (ppc_process_record_op4)
8084 (ppc_process_record_op63): Add fall-through comment.
8086 2018-05-04 Tom Tromey <tom@tromey.com>
8088 * i386-tdep.c (i386_process_record): Add fall-through comment.
8090 2018-05-04 Tom Tromey <tom@tromey.com>
8092 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
8095 2018-05-04 Tom Tromey <tom@tromey.com>
8097 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
8098 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
8099 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
8101 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
8103 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
8106 2018-05-04 Tom Tromey <tom@tromey.com>
8108 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
8110 2018-05-04 Tom Tromey <tom@tromey.com>
8112 * s390-tdep.c (s390_process_record): Fix fall-through comments.
8113 * xcoffread.c (scan_xcoff_symtab): Move comment later.
8114 * symfile.c (section_is_mapped): Fix fall-through comment.
8115 * stabsread.c (define_symbol, read_member_functions): Fix
8116 fall-through comment.
8117 * s390-linux-tdep.c (s390_process_record): Fix fall-through
8119 * remote.c (remote_wait_as): Fix fall-through comment.
8120 * p-exp.y (yylex): Fix fall-through comment.
8121 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
8123 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
8124 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
8125 * jv-exp.y (yylex): Fix fall-through comment.
8126 * go-exp.y (lex_one_token): Fix fall-through comment.
8127 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
8128 fall-through comment.
8129 * f-exp.y (yylex): Fix fall-through comment.
8130 * dwarf2read.c (process_die): Fix fall-through comments.
8131 * dbxread.c (process_one_symbol): Fix fall-through comment.
8132 * d-exp.y (lex_one_token): Fix fall-through comment.
8133 * cp-name-parser.y (yylex): Fix fall-through comment.
8134 * coffread.c (coff_symtab_read): Fix fall-through comment.
8135 * c-exp.y (lex_one_token): Fix fall-through comment.
8136 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
8138 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
8141 2018-05-04 Tom Tromey <tom@tromey.com>
8144 * NEWS: Mention gdb.execute change.
8145 * gdbcmd.h (execute_control_command): Don't declare.
8146 * python/python.c (execute_gdb_command): Use read_command_lines_1,
8147 execute_control_commands, execute_control_commands_to_string.
8148 * cli/cli-script.h (execute_control_commands)
8149 (execute_control_commands_to_string): Declare.
8150 (execute_control_command): Add from_tty parameter.
8151 * cli/cli-script.c (execute_control_commands)
8152 (execute_control_commands_to_string): New functions.
8153 (execute_user_command): Use execute_control_commands.
8154 (execute_control_command_1): Add "from_tty" parameter. Update.
8155 (execute_control_command): Likewise.
8157 2018-05-04 Tom Tromey <tom@tromey.com>
8160 * NEWS: Mention that breakpoint commands are writable.
8161 * python/py-breakpoint.c (bppy_set_commands): New function.
8162 (breakpoint_object_getset) <"commands">: Use it.
8164 2018-05-04 Tom Tromey <tom@tromey.com>
8166 * tracepoint.c (actions_command): Update.
8167 * mi/mi-cmd-break.c (mi_command_line_array)
8168 (mi_command_line_array_cnt, mi_command_line_array_ptr)
8169 (mi_read_next_line): Remove.
8170 (mi_cmd_break_commands): Update.
8171 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
8173 * cli/cli-script.c (get_command_line): Update.
8174 (process_next_line): Use function_view. Constify.
8175 (recurse_read_control_structure, read_command_lines)
8176 (read_command_lines_1): Change argument types to function_view.
8177 (do_define_command, document_command): Update.
8178 * breakpoint.h (check_tracepoint_command): Don't declare.
8179 * breakpoint.c (check_tracepoint_command): Remove.
8180 (commands_command_1, create_tracepoint_from_upload): Update.
8182 2018-05-04 Tom Tromey <tom@tromey.com>
8185 * cli/cli-script.h (enum command_control_type) <define_control>:
8187 * cli/cli-script.c (multi_line_command_p): Handle define_control.
8188 (build_command_line, execute_control_command_1)
8189 (process_next_line): Likewise.
8190 (do_define_command): New function, extracted from define_command.
8191 (define_command): Use it.
8193 2018-05-04 Tom Tromey <tom@tromey.com>
8195 * tracepoint.c (actions_command): Update.
8196 * cli/cli-script.h (read_command_lines): Update.
8197 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
8198 (MAX_TMPBUF): Remove define.
8199 (define_command): Use string_printf.
8200 (document_command): Likewise.
8201 * breakpoint.c (commands_command_1): Update.
8203 2018-05-04 Tom Tromey <tom@tromey.com>
8205 * top.c (execute_command): Update.
8206 * cli/cli-script.h (print_command_lines): Now varargs.
8207 * cli/cli-script.c (print_command_lines): Now varargs.
8208 (execute_control_command_1) <case while_control, case if_control>:
8211 2018-05-04 Tom Tromey <tom@tromey.com>
8213 * tracepoint.c (all_tracepoint_actions): Rename from
8214 all_tracepoint_actions_and_cleanup. Change return type.
8215 (actions_command, encode_actions_1, encode_actions)
8216 (trace_dump_actions, tdump_command): Update.
8217 * remote.c (remote_download_command_source): Update.
8218 * python/python.c (gdbpy_eval_from_control_command)
8219 (python_command, python_interactive_command): Update.
8220 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8221 * guile/guile.c (guile_command)
8222 (gdbscm_eval_from_control_command, guile_command): Update.
8223 * compile/compile.c (compile_code_command)
8224 (compile_print_command, compile_to_object): Update.
8225 * cli/cli-script.h (struct command_lines_deleter): New.
8226 (counted_command_line): New typedef.
8227 (struct command_line): Add constructor, destructor.
8228 <body_list>: Remove.
8229 <body_list_0, body_list_1>: New members.
8230 (command_line_up): Remove typedef.
8231 (read_command_lines, read_command_lines_1, get_command_line):
8233 (copy_command_lines): Don't declare.
8234 * cli/cli-script.c (build_command_line): Use "new".
8235 (get_command_line): Return counted_command_line.
8236 (print_command_lines, execute_user_command)
8237 (execute_control_command_1, while_command, if_command): Update.
8238 (realloc_body_list): Remove.
8239 (process_next_line, recurse_read_control_structure): Update.
8240 (read_command_lines, read_command_lines_1): Return counted_command_line.
8241 (free_command_lines): Use "delete".
8242 (copy_command_lines): Remove.
8243 (define_command, document_command, show_user_1): Update.
8244 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
8245 a counted_command_line.
8246 * breakpoint.h (counted_command_line): Remove typedef.
8247 (breakpoint_set_commands): Update.
8248 * breakpoint.c (check_no_tracepoint_commands)
8249 (validate_commands_for_breakpoint): Update.
8250 (breakpoint_set_commands): Change commands to be a
8251 counted_command_line.
8252 (commands_command_1, update_dprintf_command_list)
8253 (create_tracepoint_from_upload): Update.
8255 2018-05-04 Tom Tromey <tom@tromey.com>
8257 * cli/cli-decode.h (cmd_list_element): New constructor.
8258 (~cmd_list_element): New destructor.
8259 (struct cmd_list_element): Add initializers.
8260 * cli/cli-decode.c (do_add_cmd): Use "new".
8261 (delete_cmd): Use "delete".
8263 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
8264 Pedro Alves <palves@redhat.com>
8266 PR breakpoints/19806 and support for PR external/20207.
8267 * NEWS: Mention Aarch64 watchpoint improvements.
8268 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
8269 watchpoints and PR external/20207 watchpoints.
8270 * nat/aarch64-linux-hw-point.c
8271 (kernel_supports_any_contiguous_range): New.
8272 (aarch64_watchpoint_offset): New.
8273 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
8274 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
8275 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
8276 (aarch64_align_watchpoint): New parameters aligned_offset_p and
8277 next_addr_orig_p. Support PR external/20207 watchpoints.
8278 (aarch64_downgrade_regs): New.
8279 (aarch64_dr_state_insert_one_point): New parameters offset and
8281 (aarch64_dr_state_remove_one_point): Likewise.
8282 (aarch64_handle_breakpoint): Update caller.
8283 (aarch64_handle_aligned_watchpoint): Likewise.
8284 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
8286 (aarch64_linux_set_debug_regs): Remove const from state. Call
8287 aarch64_downgrade_regs.
8288 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
8289 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
8290 (DR_CONTROL_MASK): ... this.
8291 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
8292 (unsigned int aarch64_watchpoint_offset): New prototype.
8293 (aarch64_linux_set_debug_regs): Remove const from state.
8294 * utils.c (align_up, align_down): Move to ...
8295 * common/common-utils.c (align_up, align_down): ... here.
8296 * utils.h (align_up, align_down): Move to ...
8297 * common/common-utils.h (align_up, align_down): ... here.
8299 2018-05-04 Joel Brobecker <brobecker@adacore.com>
8301 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
8302 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
8303 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
8304 Re-implement to match the ABI as summarized in GCC's
8305 gcc/config/sparc/sparc.c. All callers updated.
8306 (sparc32_store_arguments): Remove assertion.
8308 2018-05-04 Tom Tromey <tom@tromey.com>
8310 * printcmd.c: Don't include tui.h.
8311 (decode_format): Use skip_spaces.
8313 2018-05-04 Tom Tromey <tom@tromey.com>
8316 * printcmd.c (last_count): New global.
8317 (x_command): Use saved count when repeating.
8319 2018-05-04 Tom Tromey <tom@tromey.com>
8321 * nto-procfs.c (do_closedir_cleanup): Remove.
8322 (procfs_pidlist): Use gdb_dir_up.
8323 * procfs.c (do_closedir_cleanup): Remove.
8324 (proc_update_threads): Use gdb_dir_up.
8325 * common/filestuff.h (struct gdb_dir_deleter): New.
8326 (gdb_dir_up): New typedef.
8328 2018-05-04 Tom Tromey <tom@tromey.com>
8330 * ada-lang.c (print_mention_exception): Use std::string.
8332 2018-05-04 Tom Tromey <tom@tromey.com>
8334 * ada-lang.c (create_excep_cond_exprs): Update.
8335 (ada_exception_catchpoint_cond_string): Use std::string.
8337 2018-05-04 Tom Tromey <tom@tromey.com>
8339 * ada-lang.c (xget_renaming_scope): Return std::string.
8340 (old_renaming_is_invisible): Update.
8342 2018-05-04 Tom Tromey <tom@tromey.com>
8344 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
8345 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
8347 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
8349 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
8351 2018-05-04 Tom Tromey <tom@tromey.com>
8353 * remote.c (remote_query_supported_append): Change type.
8354 (remote_check_symbols): Update.
8356 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
8359 * configure.ac: Prepend libpython.
8360 * python/python-config.py: Likewise.
8361 * configure: Regenerate.
8363 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
8365 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
8367 2018-05-03 Pedro Alves <palves@redhat.com>
8370 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
8371 override. Write 'true' instead of '1'.
8372 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
8375 2018-05-02 Pedro Alves <palves@redhat.com>
8377 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
8378 add_inf_child_target.
8379 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
8380 add_inf_child_target.
8381 * aix-thread.c (aix_thread_target_info): New.
8382 (aix_thread_target) <shortname, longname, doc>: Delete.
8384 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
8385 add_inf_child_target.
8386 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
8387 add_inf_child_target.
8388 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
8389 add_inf_child_target.
8390 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
8391 add_inf_child_target.
8392 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
8393 add_inf_child_target.
8394 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
8395 add_inf_child_target.
8396 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
8397 add_inf_child_target.
8398 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
8399 add_inf_child_target.
8400 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
8401 add_inf_child_target.
8402 * bfd-target.c (target_bfd_target_info): New.
8403 (target_bfd) <shortname, longname, doc>: Delete.
8405 * bsd-kvm.c (bsd_kvm_target_info): New.
8406 (bsd_kvm_target) <shortname, longname, doc>: Delete.
8408 (bsd_kvm_target::open): Rename to ...
8409 (bsd_kvm_target_open): ... this. Adjust.
8410 * bsd-uthread.c (bsd_uthread_target_info): New.
8411 (bsd_uthread_target) <shortname, longname, doc>: Delete.
8413 * corefile.c (core_file_command): Adjust.
8414 * corelow.c (core_target_info): New.
8415 (core_target) <shortname, longname, doc>: Delete.
8417 (core_target::open): Rename to ...
8418 (core_target_open): ... this. Adjust.
8419 * ctf.c (ctf_target_info): New.
8420 (ctf_target) <shortname, longname, doc>: Delete.
8422 (ctf_target::open): Rename to ...
8423 (ctf_target_open): ... this.
8424 (_initialize_ctf): Adjust.
8425 * exec.c (exec_target_info): New.
8426 (exec_target) <shortname, longname, doc>: Delete.
8428 (exec_target::open): Rename to ...
8429 (exec_target_open): ... this.
8430 * gdbcore.h (core_target_open): Declare.
8431 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
8432 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
8433 add_inf_child_target.
8434 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
8435 add_inf_child_target.
8436 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
8437 add_inf_child_target.
8438 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
8439 add_inf_child_target.
8440 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
8441 add_inf_child_target.
8442 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
8443 add_inf_child_target.
8444 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
8445 add_inf_child_target.
8446 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
8447 add_inf_child_target.
8448 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
8449 add_inf_child_target.
8450 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
8451 add_inf_child_target.
8452 * inf-child.c (inf_child_target_info): New.
8453 (inf_child_target::info): New.
8454 (inf_child_open_target): Remove 'target' parameter. Use
8455 get_native_target instead.
8456 (inf_child_target::open): Delete.
8457 (add_inf_child_target): New.
8458 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
8461 (add_inf_child_target): Declare.
8462 (inf_child_open_target): Declare.
8463 * linux-thread-db.c (thread_db_target_info): New.
8464 (thread_db_target) <shortname, longname, doc>: Delete.
8466 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
8467 add_inf_child_target.
8468 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
8469 add_inf_child_target.
8470 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
8471 add_inf_child_target.
8472 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
8473 add_inf_child_target.
8474 * make-target-delegates (print_class): Adjust.
8475 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
8476 add_inf_child_target.
8477 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
8478 add_inf_child_target.
8479 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
8480 add_inf_child_target.
8481 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
8482 add_inf_child_target.
8483 * nto-procfs.c (nto_native_target_info): New.
8484 (nto_procfs_target_native) <shortname, longname, doc>:
8487 (nto_procfs_target_info): New.
8488 (nto_procfs_target_procfs) <shortname, longname, doc>:
8491 (init_procfs_targets): Adjust.
8492 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
8493 add_inf_child_target.
8494 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
8495 add_inf_child_target.
8496 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
8497 add_inf_child_target.
8498 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
8499 add_inf_child_target.
8500 * ravenscar-thread.c (ravenscar_target_info): New.
8501 (ravenscar_thread_target) <shortname, longname, doc>:
8504 * record-btrace.c (record_btrace_target_info):
8505 (record_btrace_target) <shortname, longname, doc>: Delete.
8507 (record_btrace_target::open): Rename to ...
8508 (record_btrace_target_open): ... this. Adjust.
8509 * record-full.c (record_longname, record_doc): New.
8510 (record_full_base_target) <shortname, longname, doc>: Delete.
8512 (record_full_target_info): New.
8513 (record_full_target): <shortname>: Delete.
8515 (record_full_core_open_1, record_full_open_1): Update comments.
8516 (record_full_base_target::open): Rename to ...
8517 (record_full_open): ... this.
8518 (cmd_record_full_restore): Update.
8519 (_initialize_record_full): Update.
8520 * remote-sim.c (remote_sim_target_info): New.
8521 (gdbsim_target) <shortname, longname, doc>: Delete.
8523 (gdbsim_target::open): Rename to ...
8524 (gdbsim_target_open): ... this.
8525 (_initialize_remote_sim): Adjust.
8526 * remote.c (remote_doc): New.
8527 (remote_target_info): New.
8528 (remote_target) <shortname, longname, doc>: Delete.
8530 (extended_remote_target_info): New.
8531 (extended_remote_target) <shortname, longname, doc>: Delete.
8533 (remote_target::open_1): Make static. Adjust.
8534 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
8535 * s390-linux-nat.c (_initialize_s390_nat): Use
8536 add_inf_child_target.
8537 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
8538 add_inf_child_target.
8539 * sol-thread.c (thread_db_target_info): New.
8540 (sol_thread_target) <shortname, longname, doc>: Delete.
8542 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
8543 add_inf_child_target.
8544 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
8545 add_inf_child_target.
8546 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
8547 add_inf_child_target.
8548 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
8549 add_inf_child_target.
8550 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
8551 add_inf_child_target.
8552 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
8553 add_inf_child_target.
8554 * spu-linux-nat.c (_initialize_spu_nat): Use
8555 add_inf_child_target.
8556 * spu-multiarch.c (spu_multiarch_target_info): New.
8557 (spu_multiarch_target) <shortname, longname, doc>: Delete.
8559 * target-delegates.c: Regenerate.
8560 * target.c: Include <unordered_map>.
8561 (target_ops_p): Delete.
8562 (DEF_VEC_P(target_ops_p)): Delete.
8563 (target_factories): New.
8564 (test_target_info): New.
8565 (test_target_ops::info): New.
8566 (open_target): Adjust to use target_factories.
8567 (add_target_with_completer): Rename to ...
8568 (add_target): ... this. Change prototype. Register target_info
8569 and open callback in target_factories. Register target_info in
8570 command context instead of target_ops.
8571 (add_target): Delete old implementation.
8572 (add_deprecated_target_alias): Change prototype. Adjust.
8573 (the_native_target): New.
8574 (set_native_target, get_native_target): New.
8575 (find_default_run_target): Use the_native_target.
8576 (find_attach_target, find_run_target): Simplify.
8577 (target_ops::open): Delete.
8578 (dummy_target_info): New.
8579 (dummy_target::shortname, dummy_target::longname)
8580 (dummy_target::doc): Delete.
8581 (dummy_target::info): New.
8582 (debug_target::shortname, debug_target::longname)
8583 (debug_target::doc): Delete.
8584 (debug_target::info): New.
8585 * target.h (struct target_info): New.
8586 (target_ops::~target_ops): Add comment.
8587 (target_ops::info): New.
8588 (target_ops::shortname, target_ops::longname, target_ops::doc): No
8589 longer virtual. Implement in terms of target_info.
8590 (set_native_target, get_native_target): Declare.
8591 (target_open_ftype): New.
8592 (add_target, add_target_with_completer)
8593 (add_deprecated_target_alias): Change prototype.
8594 (test_target) <shortname, longname, doc>: Delete.
8596 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
8597 add_inf_child_target.
8598 * tracefile-tfile.c (tfile_target_info): New.
8599 (tfile_target) <shortname, longname, doc>: Delete.
8601 (tfile_target::open): Rename to ...
8602 (tfile_target_open): ... this.
8603 (_initialize_tracefile_tfile): Adjust.
8604 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
8605 add_inf_child_target.
8606 * windows-nat.c (_initialize_windows_nat): Use
8607 add_inf_child_target.
8608 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
8609 add_inf_child_target.
8611 2018-05-02 Pedro Alves <palves@redhat.com>
8613 * linux-nat.h (linux_nat_target) <low_new_thread,
8614 low_delete_thread, low_new_fork, low_forget_process,
8615 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
8616 New virtual methods.
8617 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
8618 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
8619 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
8620 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
8621 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
8623 * linux-fork.c (delete_fork): Adjust to call low method.
8624 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
8625 (linux_nat_new_fork, linux_nat_forget_process_hook)
8626 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
8627 (linux_nat_status_is_event):
8628 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
8629 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
8631 (sigtrap_is_event): Rename to ...
8632 (linux_nat_target::low_status_is_event): ... this.
8633 (linux_nat_set_status_is_event): Delete.
8634 (save_stop_reason, linux_nat_wait_1)
8635 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
8637 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
8638 (linux_nat_set_new_fork, linux_nat_set_forget_process)
8639 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
8640 (linux_nat_set_prepare_to_resume): Delete.
8641 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
8642 low virtual methods.
8643 * amd64-linux-nat.c: Likewise.
8644 * arm-linux-nat.c: Likewise.
8645 * i386-linux-nat.c: Likewise.
8646 * ia64-linux-nat.c: Likewise.
8647 * mips-linux-nat.c: Likewise.
8648 * ppc-linux-nat.c: Likewise.
8649 * s390-linux-nat.c: Likewise.
8650 * sparc64-linux-nat.c: Likewise.
8651 * x86-linux-nat.c: Likewise.
8652 * x86-linux-nat.h: Include "nat/x86-linux.h".
8653 (x86_linux_nat_target) <low_new_fork, low_forget_process,
8654 low_prepare_to_resume, low_new_thread, low_delete_thread>:
8657 2018-05-02 Pedro Alves <palves@redhat.com>
8659 * target.h (target_ops)
8660 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8661 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
8662 stopped_by_watchpoint, have_continuable_watchpoint,
8663 stopped_data_address, watchpoint_addr_within_range,
8664 can_accel_watchpoint_condition, can_run, thread_alive,
8665 has_all_memory, has_memory, has_stack, has_registers,
8666 has_execution, can_async_p, is_async_p, supports_non_stop,
8667 always_non_stop_p, can_execute_reverse, supports_multi_process,
8668 supports_enable_disable_tracepoint,
8669 supports_disable_randomization, supports_string_tracing,
8670 supports_evaluation_of_breakpoint_conditions,
8671 can_run_breakpoint_commands, filesystem_is_local,
8672 can_download_tracepoint, get_trace_state_variable_value,
8673 set_trace_notes, get_tib_address, use_agent, can_use_agent,
8674 record_is_replaying, record_will_replay,
8675 augmented_libraries_svr4_read>: Adjust to return bool.
8676 * aarch64-linux-nat.c: All implementations adjusted.
8677 * aix-thread.c: All implementations adjusted.
8678 * arm-linux-nat.c: All implementations adjusted.
8679 * breakpoint.c: All implementations adjusted.
8680 * bsd-kvm.c: All implementations adjusted.
8681 * bsd-uthread.c: All implementations adjusted.
8682 * corelow.c: All implementations adjusted.
8683 * ctf.c: All implementations adjusted.
8684 * darwin-nat.c: All implementations adjusted.
8685 * darwin-nat.h: All implementations adjusted.
8686 * exec.c: All implementations adjusted.
8687 * fbsd-nat.c: All implementations adjusted.
8688 * fbsd-nat.h: All implementations adjusted.
8689 * gnu-nat.c: All implementations adjusted.
8690 * gnu-nat.h: All implementations adjusted.
8691 * go32-nat.c: All implementations adjusted.
8692 * ia64-linux-nat.c: All implementations adjusted.
8693 * inf-child.c: All implementations adjusted.
8694 * inf-child.h: All implementations adjusted.
8695 * inf-ptrace.c: All implementations adjusted.
8696 * inf-ptrace.h: All implementations adjusted.
8697 * linux-nat.c: All implementations adjusted.
8698 * linux-nat.h: All implementations adjusted.
8699 * mips-linux-nat.c: All implementations adjusted.
8700 * nto-procfs.c: All implementations adjusted.
8701 * ppc-linux-nat.c: All implementations adjusted.
8702 * procfs.c: All implementations adjusted.
8703 * ravenscar-thread.c: All implementations adjusted.
8704 * record-btrace.c: All implementations adjusted.
8705 * record-full.c: All implementations adjusted.
8706 * remote-sim.c: All implementations adjusted.
8707 * remote.c: All implementations adjusted.
8708 * s390-linux-nat.c: All implementations adjusted.
8709 * sol-thread.c: All implementations adjusted.
8710 * spu-multiarch.c: All implementations adjusted.
8711 * target-delegates.c: All implementations adjusted.
8712 * target.c: All implementations adjusted.
8713 * target.h: All implementations adjusted.
8714 * tracefile-tfile.c: All implementations adjusted.
8715 * tracefile.c: All implementations adjusted.
8716 * tracefile.h: All implementations adjusted.
8717 * windows-nat.c: All implementations adjusted.
8718 * x86-linux-nat.h: All implementations adjusted.
8719 * x86-nat.h: All implementations adjusted.
8721 2018-05-02 Pedro Alves <palves@redhat.com>
8723 * make-target-delegates (scan_target_h): Don't trim lines here.
8724 Replace sequences of tabs and/or whitespace with a single
8726 (top level, parsing methods): Trim each line before processing it
8729 2018-05-02 Pedro Alves <palves@redhat.com>
8730 John Baldwin <jhb@freebsd.org>
8732 * target.h (enum strata) <debug_stratum>: New.
8733 (struct target_ops) <all delegation methods>: Replace by C++
8734 virtual methods, and drop "to_" prefix. All references updated
8736 <to_shortname, to_longname, to_doc, to_data,
8737 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
8738 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
8739 virtual methods. All references updated throughout.
8740 <can_attach, supports_terminal_ours, can_create_inferior,
8741 get_thread_control_capabilities, attach_no_wait>: New
8743 <insert_breakpoint, remove_breakpoint>: Now
8744 TARGET_DEFAULT_NORETURN methods.
8745 <info_proc>: Now returns bool.
8747 (OPS_MAGIC): Delete.
8748 (current_target): Delete. All references replaced by references
8750 (target_stack): ... this. New.
8751 (target_shortname, target_longname): Adjust.
8752 (target_can_run): Now a function declaration.
8753 (default_child_has_all_memory, default_child_has_memory)
8754 (default_child_has_stack, default_child_has_registers)
8755 (default_child_has_execution): Remove target_ops parameter.
8756 (complete_target_initialization): Delete.
8757 (memory_breakpoint_target): New template class.
8758 (test_target_ops): Refactor as a C++ class with virtual methods.
8759 * make-target-delegates (NAME_PART): Tighten.
8760 (POINTER_PART, CP_SYMBOL): New.
8761 (SIMPLE_RETURN_PART): Reimplement.
8762 (VEC_RETURN_PART): Expect less.
8763 (RETURN_PART, VIRTUAL_PART): New.
8764 (METHOD): Adjust to C++ virtual methods.
8765 (scan_target_h): Remove reference to C99.
8766 (dname): Output "target_ops::" prefix.
8767 (write_function_header): Adjust to output a C++ class method.
8768 (write_declaration): New.
8769 (write_delegator): Adjust to output a C++ class method.
8770 (tdname): Output "dummy_target::" prefix.
8771 (write_tdefault, write_debugmethod): Adjust to output a C++ class
8773 (tdefault_names, debug_names): Delete.
8774 (return_types, tdefaults, styles, argtypes_array): New.
8775 (top level): All methods are delegators.
8777 (top level): Print dummy_target and debug_target classes.
8778 * target-delegates.c: Regenerate.
8779 * target-debug.h (target_debug_print_enum_info_proc_what)
8780 (target_debug_print_thread_control_capabilities)
8781 (target_debug_print_thread_info_p): New.
8782 * target.c (dummy_target): Delete.
8783 (the_dummy_target, the_debug_target): New.
8784 (target_stack): Now extern.
8785 (set_targetdebug): Push/unpush debug target.
8786 (default_child_has_all_memory, default_child_has_memory)
8787 (default_child_has_stack, default_child_has_registers)
8788 (default_child_has_execution): Remove target_ops parameter.
8789 (complete_target_initialization): Delete.
8790 (add_target_with_completer): No longer call
8791 complete_target_initialization.
8792 (target_supports_terminal_ours): Use regular delegation.
8793 (update_current_target): Delete.
8794 (push_target): No longer check magic number. Don't call
8795 update_current_target.
8796 (unpush_target): Don't call update_current_target.
8797 (target_is_pushed): No longer check magic number.
8798 (target_require_runnable): Skip for all stratums over
8800 (target_ops::info_proc): New.
8801 (target_info_proc): Use find_target_at and
8802 find_default_run_target.
8803 (target_supports_disable_randomization): Use regular delegation.
8804 (target_get_osdata): Use find_target_at.
8805 (target_ops::open, target_ops::close, target_ops::can_attach)
8806 (target_ops::attach, target_ops::can_create_inferior)
8807 (target_ops::create_inferior, target_ops::can_run)
8808 (target_can_run): New.
8809 (default_fileio_target): Use regular delegation.
8810 (target_ops::fileio_open, target_ops::fileio_pwrite)
8811 (target_ops::fileio_pread, target_ops::fileio_fstat)
8812 (target_ops::fileio_close, target_ops::fileio_unlink)
8813 (target_ops::fileio_readlink): New.
8814 (target_fileio_open_1, target_fileio_unlink)
8815 (target_fileio_readlink): Always call the target method. Handle
8817 (return_zero, return_zero_has_execution): Delete.
8818 (init_dummy_target): Delete.
8819 (dummy_target::dummy_target, dummy_target::shortname)
8820 (dummy_target::longname, dummy_target::doc)
8821 (debug_target::debug_target, debug_target::shortname)
8822 (debug_target::longname, debug_target::doc): New.
8823 (target_supports_delete_record): Use regular delegation.
8824 (setup_target_debug): Delete.
8825 (maintenance_print_target_stack): Skip debug_stratum.
8826 (initialize_targets): Instantiate the_dummy_target and
8828 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
8830 (target_auxv_search, fprint_target_auxv): Adjust.
8831 (info_auxv_command): Adjust to use target_stack.
8832 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
8833 * exceptions.c (print_flush): Handle a NULL target_stack.
8834 * regcache.c (target_ops_no_register): Refactor as class with
8837 * exec.c (exec_target): New class.
8838 (exec_ops): Now an exec_target.
8839 (exec_open, exec_close_1, exec_get_section_table)
8840 (exec_xfer_partial, exec_files_info, exec_has_memory)
8841 (exec_make_note_section): Refactor as exec_target methods.
8842 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
8844 (exec_target::find_memory_regions): New.
8845 (_initialize_exec): Don't call init_exec_ops.
8846 * gdbcore.h (exec_file_clear): Delete.
8848 * corefile.c (core_target): Delete.
8849 (core_file_command): Adjust.
8850 * corelow.c (core_target): New class.
8851 (the_core_target): New.
8852 (core_close): Remove target_ops parameter.
8853 (core_close_cleanup): Adjust.
8854 (core_target::close): New.
8855 (core_open, core_detach, get_core_registers, core_files_info)
8856 (core_xfer_partial, core_thread_alive, core_read_description)
8857 (core_pid_to_str, core_thread_name, core_has_memory)
8858 (core_has_stack, core_has_registers, core_info_proc): Rework as
8859 core_target methods.
8860 (ignore, core_remove_breakpoint, init_core_ops): Delete.
8861 (_initialize_corelow): Initialize the_core_target.
8862 * gdbcore.h (core_target): Delete.
8863 (the_core_target): New.
8865 * ctf.c: (ctf_target): New class.
8866 (ctf_ops): Now a ctf_target.
8867 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
8868 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
8869 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
8871 (init_ctf_ops): Delete.
8872 (_initialize_ctf): Don't call it.
8873 * tracefile-tfile.c (tfile_target): New class.
8874 (tfile_ops): Now a tfile_target.
8875 (tfile_open, tfile_close, tfile_files_info)
8876 (tfile_get_tracepoint_status, tfile_trace_find)
8877 (tfile_fetch_registers, tfile_xfer_partial)
8878 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
8879 Refactor as tfile_target methods.
8880 (tfile_xfer_partial_features): Remove target_ops parameter.
8881 (init_tfile_ops): Delete.
8882 (_initialize_tracefile_tfile): Don't call it.
8883 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
8884 (tracefile_has_stack, tracefile_has_registers)
8885 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
8886 tracefile_target methods.
8887 (init_tracefile_ops): Delete.
8888 (tracefile_target::tracefile_target): New.
8889 * tracefile.h: Include "target.h".
8890 (tracefile_target): New class.
8891 (init_tracefile_ops): Delete.
8893 * spu-multiarch.c (spu_multiarch_target): New class.
8894 (spu_ops): Now a spu_multiarch_target.
8895 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
8896 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
8897 (spu_search_memory, spu_mourn_inferior): Refactor as
8898 spu_multiarch_target methods.
8899 (init_spu_ops): Delete.
8900 (_initialize_spu_multiarch): Remove references to init_spu_ops,
8901 complete_target_initialization.
8903 * ravenscar-thread.c (ravenscar_thread_target): New class.
8904 (ravenscar_ops): Now a ravenscar_thread_target.
8905 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
8906 (ravenscar_thread_alive, ravenscar_pid_to_str)
8907 (ravenscar_fetch_registers, ravenscar_store_registers)
8908 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
8909 (ravenscar_stopped_by_hw_breakpoint)
8910 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8911 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8912 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8914 (init_ravenscar_thread_ops): Delete.
8915 (_initialize_ravenscar): Remove references to
8916 init_ravenscar_thread_ops and complete_target_initialization.
8918 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8919 (bsd_uthread_target): New class.
8920 (bsd_uthread_ops): Now a bsd_uthread_target.
8921 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8922 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8923 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8924 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8925 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8926 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8927 (bsd_uthread_target): Delete function.
8928 (_initialize_bsd_uthread): Remove reference to
8929 complete_target_initialization.
8931 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8932 (target_bfd): ... this new class.
8933 (target_bfd_xfer_partial, target_bfd_get_section_table)
8934 (target_bfd_close): Refactor as target_bfd methods.
8935 (target_bfd::~target_bfd): New.
8936 (target_bfd_reopen): Adjust.
8937 (target_bfd::close): New.
8939 * record-btrace.c (record_btrace_target): New class.
8940 (record_btrace_ops): Now a record_btrace_target.
8941 (record_btrace_open, record_btrace_stop_recording)
8942 (record_btrace_disconnect, record_btrace_close)
8943 (record_btrace_async, record_btrace_info)
8944 (record_btrace_insn_history, record_btrace_insn_history_range)
8945 (record_btrace_insn_history_from, record_btrace_call_history)
8946 (record_btrace_call_history_range)
8947 (record_btrace_call_history_from, record_btrace_record_method)
8948 (record_btrace_is_replaying, record_btrace_will_replay)
8949 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
8950 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
8951 (record_btrace_store_registers, record_btrace_prepare_to_store)
8952 (record_btrace_to_get_unwinder)
8953 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
8954 (record_btrace_commit_resume, record_btrace_wait)
8955 (record_btrace_stop, record_btrace_can_execute_reverse)
8956 (record_btrace_stopped_by_sw_breakpoint)
8957 (record_btrace_supports_stopped_by_sw_breakpoint)
8958 (record_btrace_stopped_by_hw_breakpoint)
8959 (record_btrace_supports_stopped_by_hw_breakpoint)
8960 (record_btrace_update_thread_list, record_btrace_thread_alive)
8961 (record_btrace_goto_begin, record_btrace_goto_end)
8962 (record_btrace_goto, record_btrace_stop_replaying_all)
8963 (record_btrace_execution_direction)
8964 (record_btrace_prepare_to_generate_core)
8965 (record_btrace_done_generating_core): Refactor as
8966 record_btrace_target methods.
8967 (init_record_btrace_ops): Delete.
8968 (_initialize_record_btrace): Remove reference to
8969 init_record_btrace_ops.
8970 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
8971 the execution_direction global.
8972 (record_full_base_target, record_full_target)
8973 (record_full_core_target): New classes.
8974 (record_full_ops): Now a record_full_target.
8975 (record_full_core_ops): Now a record_full_core_target.
8976 (record_full_target::detach, record_full_target::disconnect)
8977 (record_full_core_target::disconnect)
8978 (record_full_target::mourn_inferior, record_full_target::kill):
8980 (record_full_open, record_full_close, record_full_async): Refactor
8981 as methods of the record_full_base_target class.
8982 (record_full_resume, record_full_commit_resume): Refactor
8983 as methods of the record_full_target class.
8984 (record_full_wait, record_full_stopped_by_watchpoint)
8985 (record_full_stopped_data_address)
8986 (record_full_stopped_by_sw_breakpoint)
8987 (record_full_supports_stopped_by_sw_breakpoint)
8988 (record_full_stopped_by_hw_breakpoint)
8989 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
8990 methods of the record_full_base_target class.
8991 (record_full_store_registers, record_full_xfer_partial)
8992 (record_full_insert_breakpoint, record_full_remove_breakpoint):
8993 Refactor as methods of the record_full_target class.
8994 (record_full_can_execute_reverse, record_full_get_bookmark)
8995 (record_full_goto_bookmark, record_full_execution_direction)
8996 (record_full_record_method, record_full_info, record_full_delete)
8997 (record_full_is_replaying, record_full_will_replay)
8998 (record_full_goto_begin, record_full_goto_end, record_full_goto)
8999 (record_full_stop_replaying): Refactor as methods of the
9000 record_full_base_target class.
9001 (record_full_core_resume, record_full_core_kill)
9002 (record_full_core_fetch_registers)
9003 (record_full_core_prepare_to_store)
9004 (record_full_core_store_registers, record_full_core_xfer_partial)
9005 (record_full_core_insert_breakpoint)
9006 (record_full_core_remove_breakpoint)
9007 (record_full_core_has_execution): Refactor
9008 as methods of the record_full_core_target class.
9009 (record_full_base_target::supports_delete_record): New.
9010 (init_record_full_ops): Delete.
9011 (init_record_full_core_ops): Delete.
9012 (record_full_save): Refactor as method of the
9013 record_full_base_target class.
9014 (_initialize_record_full): Remove references to
9015 init_record_full_ops and init_record_full_core_ops.
9017 * remote.c (remote_target, extended_remote_target): New classes.
9018 (remote_ops): Now a remote_target.
9019 (extended_remote_ops): Now an extended_remote_target.
9020 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
9021 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
9022 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
9023 (remote_pass_signals, remote_set_syscall_catchpoint)
9024 (remote_program_signals, )
9025 (remote_thread_always_alive): Remove target_ops parameter.
9026 (remote_thread_alive, remote_thread_name)
9027 (remote_update_thread_list, remote_threads_extra_info)
9028 (remote_static_tracepoint_marker_at)
9029 (remote_static_tracepoint_markers_by_strid)
9030 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
9031 (remote_open): Refactor as methods of remote_target.
9032 (extended_remote_open, extended_remote_detach)
9033 (extended_remote_attach, extended_remote_post_attach):
9034 (extended_remote_supports_disable_randomization)
9035 (extended_remote_create_inferior): : Refactor as method of
9036 extended_remote_target.
9037 (remote_set_permissions, remote_open_1, remote_detach)
9038 (remote_follow_fork, remote_follow_exec, remote_disconnect)
9039 (remote_resume, remote_commit_resume, remote_stop)
9040 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
9041 (remote_terminal_ours, remote_wait, remote_fetch_registers)
9042 (remote_prepare_to_store, remote_store_registers)
9043 (remote_flash_erase, remote_flash_done, remote_files_info)
9044 (remote_kill, remote_mourn, remote_insert_breakpoint)
9045 (remote_remove_breakpoint, remote_insert_watchpoint)
9046 (remote_watchpoint_addr_within_range)
9047 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
9048 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
9049 (remote_supports_stopped_by_sw_breakpoint)
9050 (remote_stopped_by_hw_breakpoint)
9051 (remote_supports_stopped_by_hw_breakpoint)
9052 (remote_stopped_by_watchpoint, remote_stopped_data_address)
9053 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
9054 (remote_verify_memory): Refactor as methods of remote_target.
9055 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
9057 (remote_xfer_partial, remote_get_memory_xfer_limit)
9058 (remote_search_memory, remote_rcmd, remote_memory_map)
9059 (remote_pid_to_str, remote_get_thread_local_address)
9060 (remote_get_tib_address, remote_read_description): Refactor as
9061 methods of remote_target.
9062 (remote_target::fileio_open, remote_target::fileio_pwrite)
9063 (remote_target::fileio_pread, remote_target::fileio_close): New.
9064 (remote_hostio_readlink, remote_hostio_fstat)
9065 (remote_filesystem_is_local, remote_can_execute_reverse)
9066 (remote_supports_non_stop, remote_supports_disable_randomization)
9067 (remote_supports_multi_process, remote_supports_cond_breakpoints)
9068 (remote_supports_enable_disable_tracepoint)
9069 (remote_supports_string_tracing)
9070 (remote_can_run_breakpoint_commands, remote_trace_init)
9071 (remote_download_tracepoint, remote_can_download_tracepoint)
9072 (remote_download_trace_state_variable, remote_enable_tracepoint)
9073 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
9074 (remote_trace_start, remote_get_trace_status)
9075 (remote_get_tracepoint_status, remote_trace_stop)
9076 (remote_trace_find, remote_get_trace_state_variable_value)
9077 (remote_save_trace_data, remote_get_raw_trace_data)
9078 (remote_set_disconnected_tracing, remote_core_of_thread)
9079 (remote_set_circular_trace_buffer, remote_traceframe_info)
9080 (remote_get_min_fast_tracepoint_insn_len)
9081 (remote_set_trace_buffer_size, remote_set_trace_notes)
9082 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
9083 (remote_disable_btrace, remote_teardown_btrace)
9084 (remote_read_btrace, remote_btrace_conf)
9085 (remote_augmented_libraries_svr4_read, remote_load)
9086 (remote_pid_to_exec_file, remote_can_do_single_step)
9087 (remote_execution_direction, remote_thread_handle_to_thread_info):
9088 Refactor as methods of remote_target.
9089 (init_remote_ops, init_extended_remote_ops): Delete.
9090 (remote_can_async_p, remote_is_async_p, remote_async)
9091 (remote_thread_events, remote_upload_tracepoints)
9092 (remote_upload_trace_state_variables): Refactor as methods of
9094 (_initialize_remote): Remove references to init_remote_ops and
9095 init_extended_remote_ops.
9097 * remote-sim.c (gdbsim_target): New class.
9098 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
9099 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
9100 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
9101 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
9102 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
9103 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
9104 Refactor as methods of gdbsim_target.
9105 (gdbsim_ops): Now a gdbsim_target.
9106 (init_gdbsim_ops): Delete.
9107 (gdbsim_cntrl_c): Adjust.
9108 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
9110 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
9111 (the_amd64_linux_nat_target): New.
9112 (amd64_linux_fetch_inferior_registers)
9113 (amd64_linux_store_inferior_registers): Refactor as methods of
9114 amd64_linux_nat_target.
9115 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
9116 * i386-linux-nat.c: Don't include "linux-nat.h".
9117 (i386_linux_nat_target): New class.
9118 (the_i386_linux_nat_target): New.
9119 (i386_linux_fetch_inferior_registers)
9120 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
9121 as methods of i386_linux_nat_target.
9122 (_initialize_i386_linux_nat): Adjust. Set linux_target.
9123 * inf-child.c (inf_child_ops): Delete.
9124 (inf_child_fetch_inferior_registers)
9125 (inf_child_store_inferior_registers): Delete.
9126 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
9127 methods of inf_child_target.
9128 (inf_child_target::supports_terminal_ours)
9129 (inf_child_target::terminal_init)
9130 (inf_child_target::terminal_inferior)
9131 (inf_child_target::terminal_ours_for_output)
9132 (inf_child_target::terminal_ours, inf_child_target::interrupt)
9133 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
9135 (inf_child_open, inf_child_disconnect, inf_child_close)
9136 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
9137 (inf_child_post_startup_inferior, inf_child_can_run)
9138 (inf_child_pid_to_exec_file): Refactor as methods of
9140 (inf_child_follow_fork): Delete.
9141 (inf_child_target::can_create_inferior)
9142 (inf_child_target::can_attach): New.
9143 (inf_child_target::has_all_memory, inf_child_target::has_memory)
9144 (inf_child_target::has_stack, inf_child_target::has_registers)
9145 (inf_child_target::has_execution): New.
9146 (inf_child_fileio_open, inf_child_fileio_pwrite)
9147 (inf_child_fileio_pread, inf_child_fileio_fstat)
9148 (inf_child_fileio_close, inf_child_fileio_unlink)
9149 (inf_child_fileio_readlink, inf_child_use_agent)
9150 (inf_child_can_use_agent): Refactor as methods of
9152 (return_zero, inf_child_target): Delete.
9153 (inf_child_target::inf_child_target): New.
9154 * inf-child.h: Include "target.h".
9155 (inf_child_target): Delete function prototype.
9156 (inf_child_target): New class.
9157 (inf_child_open_target, inf_child_mourn_inferior)
9158 (inf_child_maybe_unpush_target): Delete.
9159 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
9160 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
9161 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
9162 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
9163 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
9164 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
9165 (inf_ptrace_wait, inf_ptrace_xfer_partial)
9166 (inf_ptrace_thread_alive, inf_ptrace_files_info)
9167 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
9168 methods of inf_ptrace_target.
9169 (inf_ptrace_target): Delete function.
9170 * inf-ptrace.h: Include "inf-child.h".
9171 (inf_ptrace_target): Delete function declaration.
9172 (inf_ptrace_target): New class.
9173 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
9174 * linux-nat.c (linux_target): New.
9175 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
9176 (linux_nat_target::~linux_nat_target): New.
9177 (linux_child_post_attach, linux_child_post_startup_inferior)
9178 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
9179 (linux_child_remove_fork_catchpoint)
9180 (linux_child_insert_vfork_catchpoint)
9181 (linux_child_remove_vfork_catchpoint)
9182 (linux_child_insert_exec_catchpoint)
9183 (linux_child_remove_exec_catchpoint)
9184 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
9185 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
9186 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
9187 (linux_nat_stopped_data_address)
9188 (linux_nat_stopped_by_sw_breakpoint)
9189 (linux_nat_supports_stopped_by_sw_breakpoint)
9190 (linux_nat_stopped_by_hw_breakpoint)
9191 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
9192 (linux_nat_kill, linux_nat_mourn_inferior)
9193 (linux_nat_xfer_partial, linux_nat_thread_alive)
9194 (linux_nat_update_thread_list, linux_nat_pid_to_str)
9195 (linux_nat_thread_name, linux_child_pid_to_exec_file)
9196 (linux_child_static_tracepoint_markers_by_strid)
9197 (linux_nat_is_async_p, linux_nat_can_async_p)
9198 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
9199 (linux_nat_supports_multi_process)
9200 (linux_nat_supports_disable_randomization, linux_nat_async)
9201 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
9202 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
9203 (linux_nat_fileio_open, linux_nat_fileio_readlink)
9204 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
9205 methods of linux_nat_target.
9206 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
9207 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
9209 (check_stopped_by_watchpoint): Adjust.
9210 (linux_xfer_partial): Delete.
9211 (linux_target_install_ops, linux_target, linux_nat_add_target):
9213 (linux_nat_target::linux_nat_target): New.
9214 * linux-nat.h: Include "inf-ptrace.h".
9215 (linux_nat_target): New.
9216 (linux_target, linux_target_install_ops, linux_nat_add_target):
9217 Delete function declarations.
9218 (linux_target): Declare global.
9219 * linux-thread-db.c (thread_db_target): New.
9220 (thread_db_target::thread_db_target): New.
9221 (thread_db_ops): Delete.
9222 (the_thread_db_target): New.
9223 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
9224 (thread_db_update_thread_list, thread_db_pid_to_str)
9225 (thread_db_extra_thread_info)
9226 (thread_db_thread_handle_to_thread_info)
9227 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
9228 (thread_db_resume): Refactor as methods of thread_db_target.
9229 (init_thread_db_ops): Delete.
9230 (_initialize_thread_db): Remove reference to init_thread_db_ops.
9231 * x86-linux-nat.c: Don't include "linux-nat.h".
9232 (super_post_startup_inferior): Delete.
9233 (x86_linux_nat_target::~x86_linux_nat_target): New.
9234 (x86_linux_child_post_startup_inferior)
9235 (x86_linux_read_description, x86_linux_enable_btrace)
9236 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
9237 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
9238 methods of x86_linux_nat_target.
9239 (x86_linux_create_target): Delete. Bits folded ...
9240 (x86_linux_add_target): ... here. Now takes a linux_nat_target
9242 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
9243 (x86_linux_nat_target): New class.
9244 (x86_linux_create_target): Delete.
9245 (x86_linux_add_target): Now takes a linux_nat_target pointer.
9246 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
9247 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
9248 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
9249 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
9250 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
9252 (x86_use_watchpoints): Delete.
9253 * x86-nat.h: Include "breakpoint.h" and "target.h".
9254 (x86_use_watchpoints): Delete.
9255 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
9256 (x86_stopped_by_watchpoint, x86_stopped_data_address)
9257 (x86_insert_watchpoint, x86_remove_watchpoint)
9258 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
9259 (x86_stopped_by_hw_breakpoint): New declarations.
9260 (x86_nat_target): New template class.
9262 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
9263 (the_ppc_linux_nat_target): New.
9264 (ppc_linux_fetch_inferior_registers)
9265 (ppc_linux_can_use_hw_breakpoint)
9266 (ppc_linux_region_ok_for_hw_watchpoint)
9267 (ppc_linux_ranged_break_num_registers)
9268 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
9269 (ppc_linux_insert_mask_watchpoint)
9270 (ppc_linux_remove_mask_watchpoint)
9271 (ppc_linux_can_accel_watchpoint_condition)
9272 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
9273 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
9274 (ppc_linux_watchpoint_addr_within_range)
9275 (ppc_linux_masked_watch_num_registers)
9276 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
9277 (ppc_linux_read_description): Refactor as methods of
9278 ppc_linux_nat_target.
9279 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
9281 * procfs.c (procfs_xfer_partial): Delete forward declaration.
9282 (procfs_target): New class.
9283 (the_procfs_target): New.
9284 (procfs_target): Delete function.
9285 (procfs_auxv_parse, procfs_attach, procfs_detach)
9286 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
9287 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
9288 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
9289 (procfs_create_inferior, procfs_update_thread_list)
9290 (procfs_thread_alive, procfs_pid_to_str)
9291 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
9292 (procfs_stopped_data_address, procfs_insert_watchpoint)
9293 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
9294 (proc_find_memory_regions, procfs_info_proc)
9295 (procfs_make_note_section): Refactor as methods of procfs_target.
9296 (_initialize_procfs): Adjust.
9297 * sol-thread.c (sol_thread_target): New class.
9298 (sol_thread_ops): Now a sol_thread_target.
9299 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
9300 (sol_thread_fetch_registers, sol_thread_store_registers)
9301 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
9302 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
9303 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
9304 (init_sol_thread_ops): Delete.
9305 (_initialize_sol_thread): Adjust. Remove references to
9306 init_sol_thread_ops and complete_target_initialization.
9308 * windows-nat.c (windows_nat_target): New class.
9309 (windows_fetch_inferior_registers)
9310 (windows_store_inferior_registers, windows_resume, windows_wait)
9311 (windows_attach, windows_detach, windows_pid_to_exec_file)
9312 (windows_files_info, windows_create_inferior)
9313 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
9314 (windows_close, windows_pid_to_str, windows_xfer_partial)
9315 (windows_get_tib_address, windows_get_ada_task_ptid)
9316 (windows_thread_name, windows_thread_alive): Refactor as
9317 windows_nat_target methods.
9318 (do_initial_windows_stuff): Adjust.
9319 (windows_target): Delete function.
9320 (_initialize_windows_nat): Adjust.
9322 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
9323 (darwin_mourn_inferior, darwin_kill_inferior)
9324 (darwin_create_inferior, darwin_attach, darwin_detach)
9325 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
9326 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
9327 (darwin_supports_multi_process): Refactor as darwin_nat_target
9329 (darwin_resume_to, darwin_files_info): Delete.
9330 (_initialize_darwin_inferior): Rename to ...
9331 (_initialize_darwin_nat): ... this. Adjust to C++ification.
9332 * darwin-nat.h: Include "inf-child.h".
9333 (darwin_nat_target): New class.
9334 (darwin_complete_target): Delete.
9335 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
9336 (darwin_target): New.
9337 (i386_darwin_fetch_inferior_registers)
9338 (i386_darwin_store_inferior_registers): Refactor as methods of
9340 (darwin_complete_target): Delete, with ...
9341 (_initialize_i386_darwin_nat): ... bits factored out here.
9343 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
9344 (the_alpha_linux_nat_target): New.
9345 (alpha_linux_register_u_offset): Refactor as
9346 alpha_linux_nat_target method.
9347 (_initialize_alpha_linux_nat): Adjust.
9348 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
9349 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9350 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
9351 methods of linux_nat_trad_target.
9352 (linux_trad_target): Delete.
9353 * linux-nat-trad.h (linux_trad_target): Delete function.
9354 (linux_nat_trad_target): New class.
9355 * mips-linux-nat.c (mips_linux_nat_target): New class.
9356 (super_fetch_registers, super_store_registers, super_close):
9358 (the_mips_linux_nat_target): New.
9359 (mips64_linux_regsets_fetch_registers)
9360 (mips64_linux_regsets_store_registers)
9361 (mips64_linux_fetch_registers, mips64_linux_store_registers)
9362 (mips_linux_register_u_offset, mips_linux_read_description)
9363 (mips_linux_can_use_hw_breakpoint)
9364 (mips_linux_stopped_by_watchpoint)
9365 (mips_linux_stopped_data_address)
9366 (mips_linux_region_ok_for_hw_watchpoint)
9367 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
9368 (mips_linux_close): Refactor as methods of mips_linux_nat.
9369 (_initialize_mips_linux_nat): Adjust to C++ification.
9371 * aix-thread.c (aix_thread_target): New class.
9372 (aix_thread_ops): Now an aix_thread_target.
9373 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
9374 (aix_thread_fetch_registers, aix_thread_store_registers)
9375 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
9376 (aix_thread_thread_alive, aix_thread_pid_to_str)
9377 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
9378 Refactor as methods of aix_thread_target.
9379 (init_aix_thread_ops): Delete.
9380 (_initialize_aix_thread): Remove references to init_aix_thread_ops
9381 and complete_target_initialization.
9382 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
9383 (rs6000_nat_target): New class.
9384 (the_rs6000_nat_target): New.
9385 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
9386 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
9387 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
9388 (super_create_inferior): Delete.
9389 (_initialize_rs6000_nat): Adjust to C++ification.
9391 * arm-linux-nat.c (arm_linux_nat_target): New class.
9392 (the_arm_linux_nat_target): New.
9393 (arm_linux_fetch_inferior_registers)
9394 (arm_linux_store_inferior_registers, arm_linux_read_description)
9395 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
9396 (arm_linux_remove_hw_breakpoint)
9397 (arm_linux_region_ok_for_hw_watchpoint)
9398 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
9399 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
9400 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
9401 arm_linux_nat_target.
9402 (_initialize_arm_linux_nat): Adjust to C++ification.
9404 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
9405 (the_aarch64_linux_nat_target): New.
9406 (aarch64_linux_fetch_inferior_registers)
9407 (aarch64_linux_store_inferior_registers)
9408 (aarch64_linux_child_post_startup_inferior)
9409 (aarch64_linux_read_description)
9410 (aarch64_linux_can_use_hw_breakpoint)
9411 (aarch64_linux_insert_hw_breakpoint)
9412 (aarch64_linux_remove_hw_breakpoint)
9413 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
9414 (aarch64_linux_region_ok_for_hw_watchpoint)
9415 (aarch64_linux_stopped_data_address)
9416 (aarch64_linux_stopped_by_watchpoint)
9417 (aarch64_linux_watchpoint_addr_within_range)
9418 (aarch64_linux_can_do_single_step): Refactor as methods of
9419 aarch64_linux_nat_target.
9420 (super_post_startup_inferior): Delete.
9421 (_initialize_aarch64_linux_nat): Adjust to C++ification.
9423 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
9424 (the_hppa_linux_nat_target): New.
9425 (hppa_linux_fetch_inferior_registers)
9426 (hppa_linux_store_inferior_registers): Refactor as methods of
9427 hppa_linux_nat_target.
9428 (_initialize_hppa_linux_nat): Adjust to C++ification.
9430 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
9431 (the_ia64_linux_nat_target): New.
9432 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
9433 (ia64_linux_stopped_data_address)
9434 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
9435 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
9436 ia64_linux_nat_target methods.
9437 (super_xfer_partial): Delete.
9438 (_initialize_ia64_linux_nat): Adjust to C++ification.
9440 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
9441 (the_m32r_linux_nat_target): New.
9442 (m32r_linux_fetch_inferior_registers)
9443 (m32r_linux_store_inferior_registers): Refactor as
9444 m32r_linux_nat_target methods.
9445 (_initialize_m32r_linux_nat): Adjust to C++ification.
9447 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
9448 (the_m68k_linux_nat_target): New.
9449 (m68k_linux_fetch_inferior_registers)
9450 (m68k_linux_store_inferior_registers): Refactor as
9451 m68k_linux_nat_target methods.
9452 (_initialize_m68k_linux_nat): Adjust to C++ification.
9454 * s390-linux-nat.c (s390_linux_nat_target): New class.
9455 (the_s390_linux_nat_target): New.
9456 (s390_linux_fetch_inferior_registers)
9457 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
9458 (s390_insert_watchpoint, s390_remove_watchpoint)
9459 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
9460 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
9461 (s390_auxv_parse, s390_read_description): Refactor as methods of
9462 s390_linux_nat_target.
9463 (_initialize_s390_nat): Adjust to C++ification.
9465 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
9466 (the_sparc_linux_nat_target): New.
9467 (_initialize_sparc_linux_nat): Adjust to C++ification.
9468 * sparc-nat.c (sparc_fetch_inferior_registers)
9469 (sparc_store_inferior_registers): Remove target_ops parameter.
9470 * sparc-nat.h (sparc_fetch_inferior_registers)
9471 (sparc_store_inferior_registers): Remove target_ops parameter.
9472 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
9473 (the_sparc64_linux_nat_target): New.
9474 (_initialize_sparc64_linux_nat): Adjust to C++ification.
9476 * spu-linux-nat.c (spu_linux_nat_target): New class.
9477 (the_spu_linux_nat_target): New.
9478 (spu_child_post_startup_inferior, spu_child_post_attach)
9479 (spu_child_wait, spu_fetch_inferior_registers)
9480 (spu_store_inferior_registers, spu_xfer_partial)
9481 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
9483 (_initialize_spu_nat): Adjust to C++ification.
9485 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
9486 (the_tilegx_linux_nat_target): New.
9487 (fetch_inferior_registers, store_inferior_registers):
9488 Refactor as methods.
9489 (_initialize_tile_linux_nat): Adjust to C++ification.
9491 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
9492 (the_xtensa_linux_nat_target): New.
9493 (xtensa_linux_fetch_inferior_registers)
9494 (xtensa_linux_store_inferior_registers): Refactor as
9495 xtensa_linux_nat_target methods.
9496 (_initialize_xtensa_linux_nat): Adjust to C++ification.
9498 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
9499 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
9500 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
9501 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
9502 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
9503 (fbsd_stopped_by_sw_breakpoint)
9504 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
9505 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
9506 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
9507 (fbsd_post_startup_inferior, fbsd_post_attach)
9508 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
9509 (fbsd_set_syscall_catchpoint)
9510 (super_xfer_partial, super_resume, super_wait)
9511 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
9512 (fbsd_handle_debug_trap): Remove target_ops parameter.
9513 (fbsd_nat_add_target): Delete.
9514 * fbsd-nat.h: Include "inf-ptrace.h".
9515 (fbsd_nat_add_target): Delete.
9516 (USE_SIGTRAP_SIGINFO): Define.
9517 (fbsd_nat_target): New class.
9519 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
9520 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
9521 (amd64bsd_target): Delete.
9522 * amd64-bsd-nat.h: New file.
9523 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
9525 (amd64_fbsd_nat_target): New class.
9526 (the_amd64_fbsd_nat_target): New.
9527 (amd64fbsd_read_description): Refactor as method of
9528 amd64_fbsd_nat_target.
9529 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9530 (_initialize_amd64fbsd_nat): Adjust to C++ification.
9531 * amd64-nat.h (amd64bsd_target): Delete function declaration.
9532 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
9533 (i386bsd_store_inferior_registers): Remove target_ops parameter.
9534 (i386bsd_target): Delete.
9535 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
9536 (i386bsd_fetch_inferior_registers)
9537 (i386bsd_store_inferior_registers): Declare.
9538 (i386_bsd_nat_target): New class.
9539 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
9540 (the_i386_fbsd_nat_target): New.
9541 (i386fbsd_resume, i386fbsd_read_description): Refactor as
9542 i386_fbsd_nat_target methods.
9543 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9544 (_initialize_i386fbsd_nat): Adjust to C++ification.
9545 * x86-bsd-nat.c (super_mourn_inferior): Delete.
9546 (x86bsd_mourn_inferior, x86bsd_target): Delete.
9547 (_initialize_x86_bsd_nat): Adjust to C++ification.
9548 * x86-bsd-nat.h: Include "x86-nat.h".
9549 (x86bsd_target): Delete declaration.
9550 (x86bsd_nat_target): New class.
9552 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
9553 (the_aarch64_fbsd_nat_target): New.
9554 (aarch64_fbsd_fetch_inferior_registers)
9555 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
9556 aarch64_fbsd_nat_target.
9557 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
9558 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
9559 (the_alpha_bsd_nat_target): New.
9560 (alphabsd_fetch_inferior_registers)
9561 (alphabsd_store_inferior_registers): Refactor as
9562 alpha_bsd_nat_target methods.
9563 (_initialize_alphabsd_nat): Refactor as methods of
9564 alpha_bsd_nat_target.
9565 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
9566 (the_amd64_nbsd_nat_target): New.
9567 (_initialize_amd64nbsd_nat): Adjust to C++ification.
9568 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
9569 (the_amd64_obsd_nat_target): New.
9570 (_initialize_amd64obsd_nat): Adjust to C++ification.
9571 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
9572 (the_arm_fbsd_nat_target): New.
9573 (arm_fbsd_fetch_inferior_registers)
9574 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
9575 (_initialize_arm_fbsd_nat): Refactor as methods of
9576 arm_fbsd_nat_target.
9577 (_initialize_arm_fbsd_nat): Adjust to C++ification.
9578 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
9579 (the_arm_netbsd_nat_target): New.
9580 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
9581 arm_netbsd_nat_target.
9582 (_initialize_arm_netbsd_nat): Adjust to C++ification.
9583 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
9584 (the_hppa_nbsd_nat_target): New.
9585 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
9586 hppa_nbsd_nat_target methods.
9587 (_initialize_hppanbsd_nat): Adjust to C++ification.
9588 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
9589 (the_hppa_obsd_nat_target): New.
9590 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
9591 methods of hppa_obsd_nat_target.
9592 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
9594 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
9595 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
9597 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
9598 (_initialize_i386obsd_nat): Use add_target.
9599 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
9600 (the_m68k_bsd_nat_target): New.
9601 (m68kbsd_fetch_inferior_registers)
9602 (m68kbsd_store_inferior_registers): Refactor as methods of
9603 m68k_bsd_nat_target.
9604 (_initialize_m68kbsd_nat): Adjust to C++ification.
9605 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
9606 (the_mips_fbsd_nat_target): New.
9607 (mips_fbsd_fetch_inferior_registers)
9608 (mips_fbsd_store_inferior_registers): Refactor as methods of
9609 mips_fbsd_nat_target.
9610 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
9612 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
9613 (the_mips_nbsd_nat_target): New.
9614 (mipsnbsd_fetch_inferior_registers)
9615 (mipsnbsd_store_inferior_registers): Refactor as methods of
9616 mips_nbsd_nat_target.
9617 (_initialize_mipsnbsd_nat): Adjust to C++ification.
9618 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
9619 (the_mips64_obsd_nat_target): New.
9620 (mips64obsd_fetch_inferior_registers)
9621 (mips64obsd_store_inferior_registers): Refactor as methods of
9622 mips64_obsd_nat_target.
9623 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
9625 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
9627 * nbsd-nat.h: Include "inf-ptrace.h".
9628 (nbsd_nat_target): New class.
9629 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
9630 (obsd_wait): Refactor as methods of obsd_nat_target.
9631 (obsd_add_target): Delete.
9632 * obsd-nat.h: Include "inf-ptrace.h".
9633 (obsd_nat_target): New class.
9634 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
9635 (the_ppc_fbsd_nat_target): New.
9636 (ppcfbsd_fetch_inferior_registers)
9637 (ppcfbsd_store_inferior_registers): Refactor as methods of
9638 ppc_fbsd_nat_target.
9639 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
9641 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
9642 (the_ppc_nbsd_nat_target): New.
9643 (ppcnbsd_fetch_inferior_registers)
9644 (ppcnbsd_store_inferior_registers): Refactor as methods of
9645 ppc_nbsd_nat_target.
9646 (_initialize_ppcnbsd_nat): Adjust to C++ification.
9647 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
9648 (the_ppc_obsd_nat_target): New.
9649 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
9650 methods of ppc_obsd_nat_target.
9651 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
9653 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
9654 (the_sh_nbsd_nat_target): New.
9655 (shnbsd_fetch_inferior_registers)
9656 (shnbsd_store_inferior_registers): Refactor as methods of
9658 (_initialize_shnbsd_nat): Adjust to C++ification.
9659 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
9660 (inf_ptrace_xfer_partial): Delete.
9661 (sparc_xfer_partial, sparc_target): Delete.
9662 * sparc-nat.h (sparc_fetch_inferior_registers)
9663 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
9664 (sparc_target): Delete function declaration.
9665 (sparc_target): New template class.
9666 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
9667 (_initialize_sparcnbsd_nat): Adjust to C++ification.
9668 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
9669 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
9671 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
9672 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
9673 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
9674 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
9676 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
9677 (the_vax_bsd_nat_target): New.
9678 (vaxbsd_fetch_inferior_registers)
9679 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
9681 (_initialize_vaxbsd_nat): Adjust to C++ification.
9683 * bsd-kvm.c (bsd_kvm_target): New class.
9684 (bsd_kvm_ops): Now a bsd_kvm_target.
9685 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
9686 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
9687 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
9689 (bsd_kvm_return_one): Delete.
9690 (bsd_kvm_add_target): Adjust to C++ification.
9692 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
9693 (nto_procfs_target_procfs): New classes.
9694 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
9695 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
9696 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
9697 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
9698 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
9699 (procfs_remove_hw_breakpoint, procfs_resume)
9700 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
9701 (procfs_kill_inferior, procfs_store_registers)
9702 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
9703 as methods of nto_procfs_target.
9704 (nto_procfs_ops): Now an nto_procfs_target_procfs.
9705 (nto_native_ops): Delete.
9706 (procfs_open, procfs_native_open): Delete.
9707 (nto_native_ops): Now an nto_procfs_target_native.
9708 (init_procfs_targets): Adjust to C++ification.
9709 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
9710 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
9711 Refactor as methods of nto_procfs_target.
9713 * go32-nat.c (go32_nat_target): New class.
9714 (the_go32_nat_target): New.
9715 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
9716 (go32_store_registers, go32_xfer_partial, go32_files_info)
9717 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
9718 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
9719 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
9720 (go32_pid_to_str): Refactor as methods of go32_nat_target.
9721 (go32_target): Delete.
9722 (_initialize_go32_nat): Adjust to C++ification.
9724 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
9725 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
9726 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
9727 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
9729 (gnu_target): Delete.
9730 * gnu-nat.h (gnu_target): Delete.
9731 (gnu_nat_target): New class.
9732 * i386-gnu-nat.c (gnu_base_target): New.
9733 (i386_gnu_nat_target): New class.
9734 (the_i386_gnu_nat_target): New.
9735 (_initialize_i386gnu_nat): Adjust to C++ification.
9737 2018-05-02 Pedro Alves <palves@redhat.com>
9739 * bfd-target.c (target_bfd_xclose): Rename to ...
9740 (target_bfd_close): ... this.
9741 (target_bfd_reopen): Adjust.
9742 * target.c (target_close): Remove references to to_xclose.
9743 * target.h (target_ops::to_xclose): Delete.
9744 (target_ops::to_close): Update comments.
9746 2018-05-02 Pedro Alves <palves@redhat.com>
9748 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
9750 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
9751 * inf-ptrace.c (inf_ptrace_register_u_offset)
9752 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9753 (inf_ptrace_store_register, inf_ptrace_store_registers)
9754 (inf_ptrace_trad_target): Move to ...
9755 * linux-nat-trad.c: ... this new file.
9756 * linux-nat-trad.h: New file.
9757 * linux-nat.c (linux_target_install_ops): Make extern.
9758 (linux_trad_target): Delete.
9759 * linux-nat.h (linux_trad_target): Delete declaration.
9760 (linux_target_install_ops): Declare.
9761 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
9764 2018-05-02 Pedro Alves <palves@redhat.com>
9766 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9767 procfs_target/add_target here.
9768 * procfs.c (procfs_target): Make static.
9769 (_initialize_procfs): Call add_target here.
9770 * procfs.h (struct target_ops): Remove forward declaration.
9771 (procfs_target): Remove declaration.
9772 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
9774 2018-05-02 Pedro Alves <palves@redhat.com>
9776 * procfs.c (procfs_stopped_by_watchpoint)
9777 (procfs_insert_watchpoint, procfs_remove_watchpoint)
9778 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
9780 (procfs_use_watchpoints): Delete, move contents...
9781 (procfs_target): ... here.
9782 * procfs.h (procfs_use_watchpoints): Delete declaration.
9783 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9784 procfs_use_watchpoints.
9785 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
9786 procfs_use_watchpoints.
9788 2018-05-02 Tom Tromey <tom@tromey.com>
9791 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
9792 and var_zuinteger_unlimited.
9793 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
9794 and PARAM_ZUINTEGER_UNLIMITED.
9795 (set_parameter_value): Handle var_zuinteger and
9796 var_zuinteger_unlimited.
9797 (add_setshow_generic): Likewise.
9798 (parmpy_init): Likewise.
9800 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
9803 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
9804 pointer is not null before dereferencing it.
9806 2018-04-30 Tom Tromey <tom@tromey.com>
9808 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
9811 2018-04-30 Tom Tromey <tom@tromey.com>
9813 * breakpoint.c (mention): Remove use of is_mi_like_p.
9814 (print_mention_ranged_breakpoint): Likewise.
9815 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
9818 2018-04-30 Tom Tromey <tom@tromey.com>
9820 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
9822 2018-04-30 Tom Tromey <tom@tromey.com>
9824 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
9825 (info_spu_event_command): Remove some uses of is_mi_like_p.
9827 2018-04-30 Tom Tromey <tom@tromey.com>
9829 * python/py-framefilter.c (py_print_single_arg)
9830 (enumerate_locals, py_print_args, py_print_frame): Remove some
9831 uses of is_mi_like_p.
9833 2018-04-30 Tom Tromey <tom@tromey.com>
9836 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
9837 * ui-out.h (ui_out::is_mi_like_p): Now const.
9838 (ui_out::do_is_mi_like_p): Now const.
9839 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
9841 2018-04-30 Tom Tromey <tom@tromey.com>
9843 * varobj.c (varobj_set_visualizer): Use new_reference.
9844 * python/python.c (gdbpy_decode_line): Use new_reference.
9845 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
9848 2018-04-30 Tom Tromey <tom@tromey.com>
9850 * varobj.c (install_new_value): Use new_reference.
9851 * value.h (value_incref): Return void. Swap intro comment with
9853 * value.c (set_value_parent): Use new_reference.
9854 (value_incref): Return void. Update intro comment.
9855 (release_value): Use new_reference.
9856 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
9858 2018-04-30 Tom Tromey <tom@tromey.com>
9860 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
9861 * gdb_bfd.h (new_bfd_ref): Remove.
9862 (gdb_bfd_open): Update comment.
9863 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
9864 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
9865 (gdb_bfd_fdopenr): Use new_reference.
9866 * exec.c (exec_file_attach): Use new_reference.
9868 2018-04-30 Tom Tromey <tom@tromey.com>
9870 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
9873 2018-04-30 Tom Tromey <tom@tromey.com>
9875 * jit.c (jit_read_code_entry): Use type_align.
9876 * i386-tdep.c (i386_gdbarch_init): Don't call
9877 set_gdbarch_long_long_align_bit.
9878 * gdbarch.sh: Remove long_long_align_bit.
9879 * gdbarch.c, gdbarch.h: Rebuild.
9880 * arc-tdep.c (arc_type_align): New function.
9881 (arc_gdbarch_init): Use arc_type_align. Don't call
9882 set_gdbarch_long_long_align_bit.
9884 2018-04-30 Tom Tromey <tom@tromey.com>
9886 * rust-lang.c (rust_type_alignment): Remove.
9887 (rust_composite_type): Use type_align.
9889 2018-04-30 Tom Tromey <tom@tromey.com>
9891 * NEWS: Mention Type.align.
9892 * python/py-type.c (typy_get_alignof): New function.
9893 (type_object_getset): Add "alignof".
9895 2018-04-30 Tom Tromey <tom@tromey.com>
9899 * std-operator.def (UNOP_ALIGNOF): New operator.
9900 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
9902 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
9903 * c-lang.c (c_op_print_tab): Add alignof.
9904 * c-exp.y (ALIGNOF): New token.
9905 (exp): Add "ALIGNOF" production.
9906 (ident_tokens): Add _Alignof and alignof.
9908 2018-04-30 Tom Tromey <tom@tromey.com>
9910 * i386-tdep.c (i386_type_align): New function.
9911 (i386_gdbarch_init): Update.
9912 * gdbarch.sh (type_align): New method.
9913 * gdbarch.c, gdbarch.h: Rebuild.
9914 * arch-utils.h (default_type_align): Declare.
9915 * arch-utils.c (default_type_align): New function.
9916 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9917 (struct type) <align_log2>: New field.
9918 <instance_flags>: Now a bitfield.
9919 (TYPE_RAW_ALIGN): New macro.
9920 (type_align, type_raw_align, set_type_align): Declare.
9921 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9923 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9924 (get_alignment, maybe_set_alignment): New functions.
9925 (read_structure_type, read_enumeration_type, read_array_type)
9926 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9927 (read_subrange_type, read_base_type): Set type alignment.
9929 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9931 * dwarf2read.c (read_index_from_section): Use bool.
9933 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9936 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9939 2018-04-29 John Reiser <jreiser@BitWagon.com>
9942 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9943 last step, and do it atomically.
9945 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
9947 * compile/compile-c-types.c (convert_int, convert_float):
9950 2018-04-27 Tom Tromey <tom@tromey.com>
9953 * rust-lang.c (rust_inclusive_range_type_p): New function.
9954 (rust_range): Handle inclusive ranges.
9955 (rust_compute_range): Likewise.
9956 * rust-exp.y (struct rust_op) <inclusive>: New field.
9957 (DOTDOTEQ): New constant.
9958 (range_expr): Add "..=" productions.
9959 (operator_tokens): Add "..=" token.
9960 (ast_range): Add "inclusive" parameter.
9961 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
9963 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
9965 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
9966 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
9968 * expprint.c (print_subexp_standard): Handle new bounds values.
9969 (dump_subexp_body_standard): Likewise.
9971 2018-04-27 Tom Tromey <tom@tromey.com>
9973 * configure: Rebuild.
9974 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
9975 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
9977 (class symbol_needs_eval_context): Likewise.
9978 * dwarf2read.c (mock_mapped_index::symbol_name_count)
9979 (mock_mapped_index::symbol_name_at): Use "override". Remove
9981 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
9983 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
9984 * aarch64-tdep.c (instruction_reader::read): Use "override".
9985 (instruction_reader_test::read): Likewise.
9986 * arm-tdep.c (instruction_reader::read): Use "override".
9987 (instruction_reader_thumb::read): Likewise.
9989 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
9992 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
9993 instead of remote_send.
9994 (remote_send): Remove.
9996 2018-04-26 Pedro Alves <palves@redhat.com>
9998 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
9999 find_function_start_sal instead of find_pc_line.
10001 2018-04-26 Pedro Alves <palves@redhat.com>
10003 * breakpoint.c (set_breakpoint_location_function): Handle
10004 mst_data_gnu_ifunc.
10005 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
10006 * elfread.c (elf_symtab_read): Give data symbols with
10007 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
10008 (elf_rel_plt_read): Update comment.
10009 * linespec.c (convert_linespec_to_sals): Handle
10010 mst_data_gnu_ifunc.
10011 (minsym_found): Handle mst_data_gnu_ifunc.
10012 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
10013 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
10014 * parse.c (find_minsym_type_and_address): Handle
10015 mst_data_gnu_ifunc.
10016 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
10017 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
10018 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
10020 <mst_data_gnu_ifunc>: New enumerator.
10022 2018-04-26 Pedro Alves <palves@redhat.com>
10024 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
10025 (lookup_minimal_symbol_by_pc_section): ... this. Replace
10026 'want_trampoline' parameter by a lookup_msym_prefer parameter.
10028 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
10029 (lookup_minimal_symbol_by_pc): Adjust.
10030 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
10031 (lookup_solib_trampoline_symbol_by_pc): Adjust.
10032 * minsyms.h (lookup_msym_prefer): New enum.
10033 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10034 parameter by a lookup_msym_prefer parameter.
10036 2018-04-26 Pedro Alves <palves@redhat.com>
10038 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
10039 ends in "@plt" instead of looking at the symbol's section.
10041 2018-04-26 Pedro Alves <palves@redhat.com>
10043 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
10045 (find_pc_partial_function_gnu_ifunc): Rename to ...
10046 (find_pc_partial_function): ... this, and remove references to
10048 (find_pc_partial_function): Delete old implementation.
10049 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
10051 2018-04-26 Pedro Alves <palves@redhat.com>
10053 * linespec.c (struct bound_minimal_symbol_search_key): New.
10054 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
10055 skip first line if we found a GNU ifunc minimal symbol by name.
10056 (compare_msymbols): Change parameters to work with a destructured
10058 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
10061 2018-04-26 Pedro Alves <palves@redhat.com>
10063 * breakpoint.c (set_breakpoint_location_function): Don't resolve
10064 ifunc targets here. Instead, if we have an ifunc minsym, use its
10066 (add_location_to_breakpoint): Store the minsym and the objfile in
10067 the breakpoint location.
10068 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
10069 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
10070 Record the minsym in the sal.
10071 * symtab.h (symtab_and_line) <msymbol>: New field.
10073 2018-04-26 Pedro Alves <palves@redhat.com>
10075 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
10076 unless we actually resolved the ifunc.
10078 2018-04-26 Pedro Alves <palves@redhat.com>
10080 * c-exp.y (variable production): Prefer ifunc minsyms over
10081 regular function symbols.
10082 * symtab.c (find_gnu_ifunc): New function.
10083 * minsyms.h (lookup_msym_prefer): New enum.
10084 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10085 parameter by a lookup_msym_prefer parameter.
10086 * symtab.h (find_gnu_ifunc): New declaration.
10088 2018-04-26 Pedro Alves <palves@redhat.com>
10090 * blockframe.c (find_gnu_ifunc_target_type): New function.
10091 (find_function_type): New.
10092 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
10093 return a value with a memory address.
10094 (eval_call): For calls to GNU ifunc functions, try to find the
10095 type of the target function from the type that the resolver
10097 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
10099 * infcall.c (find_function_return_type): Delete.
10100 (find_function_addr): Add 'function_type' parameter. For calls to
10101 GNU ifunc functions, try to find the type of the target function
10102 from the type that the resolver returns, and return it via
10104 (call_function_by_hand_dummy): Adjust to use the function type
10105 returned by find_function_addr.
10106 (find_function_addr): Add 'function_type' parameter and move
10108 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
10111 2018-04-26 Pedro Alves <palves@redhat.com>
10113 * c-exp.y (variable production): Skip finding an alias for ifunc
10116 2018-04-26 Pedro Alves <palves@redhat.com>
10118 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
10120 2018-04-25 Pedro Alves <palves@redhat.com>
10122 * infcmd.c (kill_command): Print the pid as string, not the whole
10123 thread's ptid. Add comment. s/has been killed/killed/ in output
10125 * remote.c (remote_detach_1): Print the pid as string, not the
10126 whole thread's ptid.
10128 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
10129 Sergio Durigan Junior <sergiodj@redhat.com>
10130 Pedro Alves <palves@redhat.com>
10132 * infcmd.c (kill_command): Print message when inferior has
10134 * inferior.c (print_inferior_events): Remove 'static'. Set as
10136 (add_inferior): Improve message printed when
10137 'print_inferior_events' is on.
10138 (exit_inferior): Remove message printed when
10139 'print_inferior_events' is on.
10140 (detach_inferior): Improve message printed when
10141 'print_inferior_events' is on.
10142 (initialize_inferiors): Use 'add_inferior_silent' to set
10143 'current_inferior_'.
10144 * inferior.h (print_inferior_events): Declare here as
10146 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
10147 '[Detaching...]' messages when 'print_inferior_events' is on.
10148 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
10149 as prefix/suffix for messages. Remove periods. Fix erroneous
10150 'Detaching after fork from child...', replace it by '... from
10152 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
10153 prefix/suffix when printing 'Detaching...' messages. Print
10154 them when 'print_inferior_events' is on.
10155 * remote.c (remote_detach_1): Print message when detaching
10156 from inferior and '!is_fork_parent'.
10158 2018-04-24 Tom Tromey <tom@tromey.com>
10160 * cli-out.h: Reindent.
10162 2018-04-24 Tom Tromey <tom@tromey.com>
10164 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
10165 (cli_ui_out::do_field_string): Use fputs_filtered.
10166 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
10168 2018-04-23 Tom Tromey <tom@tromey.com>
10170 * guile/scm-frame.c (gdbscm_frame_read_var): Use
10171 gdb::unique_xmalloc_ptr.
10173 2018-04-23 Tom Tromey <tom@tromey.com>
10175 * configure: Rebuild.
10177 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
10180 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
10181 prepare_for_testing. Set normal_bp to r_debug_state if target
10184 2018-04-21 Pedro Alves <palves@redhat.com>
10185 Rajendra SY <rajendra.sy@gmail.com>
10187 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
10188 * remote.c (extended_remote_attach): In all-stop mode, mark the
10189 thread as executing.
10191 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10193 * thread.c (thread_apply_all_command): Fix comment.
10194 (thread_command): Fix comment.
10196 2018-04-10 Alan Hayward <alan.hayward@arm.com>
10198 * common/tdesc.h (tdesc_create_feature): Remove xml filename
10200 * features/aarch64-core.c (create_feature_aarch64_core):
10202 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
10204 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
10206 * features/i386/32bit-avx512.c
10207 (create_feature_i386_32bit_avx512): Likewise.
10208 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
10210 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
10212 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
10214 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
10216 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
10218 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
10220 * features/i386/64bit-avx512.c
10221 (create_feature_i386_64bit_avx512): Likewise.
10222 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
10224 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
10226 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
10228 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
10230 * features/i386/64bit-segments.c
10231 (create_feature_i386_64bit_segments): Likewise.
10232 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
10234 * features/i386/x32-core.c
10235 (create_feature_i386_x32_core): Likewise.
10236 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
10237 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
10238 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
10239 * target-descriptions.c: In generated code, don't pass xml
10242 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10244 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
10245 (print_xml_feature::visit_post): Likewise.
10246 (print_xml_feature::visit): Likewise.
10247 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
10248 (print_xml_feature): Add new class.
10249 * regformats/regdat.sh: Null xmltarget on feature targets.
10250 * target-descriptions.c (struct target_desc): Add xmltarget.
10251 (maintenance_check_tdesc_xml_convert): Add unittest function.
10252 (tdesc_get_features_xml): Add function to get xml.
10253 (maintenance_check_xml_descriptions): Test xml generation.
10254 * xml-tdesc.c (string_read_description_xml): Add function.
10255 * xml-tdesc.h (string_read_description_xml): Add declaration.
10257 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10259 * features/Makefile: Add feature marker to targets with new style
10260 target descriptions.
10261 * regformats/aarch64.dat: Regenerate.
10262 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
10263 * regformats/i386/amd64-avx-linux.dat: Likewise.
10264 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
10265 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
10266 * regformats/i386/amd64-linux.dat: Likewise.
10267 * regformats/i386/amd64-mpx-linux.dat: Likewise.
10268 * regformats/i386/amd64.dat: Likewise.
10269 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
10270 * regformats/i386/i386-avx-linux.dat: Likewise.
10271 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
10272 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
10273 * regformats/i386/i386-linux.dat: Likewise.
10274 * regformats/i386/i386-mmx-linux.dat: Likewise.
10275 * regformats/i386/i386-mpx-linux.dat: Likewise.
10276 * regformats/i386/i386.dat: Likewise.
10277 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
10278 * regformats/i386/x32-avx-linux.dat: Likewise.
10279 * regformats/i386/x32-linux.dat: Likewise.
10280 * regformats/tic6x-c62x-linux.dat: Likewise.
10281 * regformats/tic6x-c64x-linux.dat: Likewise.
10282 * regformats/tic6x-c64xp-linux.dat: Likewise.
10283 * regformats/regdat.sh: Parse feature marker.
10285 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10287 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
10288 (tdesc_osabi_name): Likewise.
10289 * target-descriptions.c (tdesc_architecture_name): Add new
10291 (tdesc_osabi_name): Likewise.
10293 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10295 * common/tdesc.c (tdesc_predefined_type): Move to here.
10296 (tdesc_named_type): Likewise.
10297 (tdesc_create_vector): Likewise.
10298 (tdesc_create_struct): Likewise.
10299 (tdesc_set_struct_size): Likewise.
10300 (tdesc_create_union): Likewise.
10301 (tdesc_create_flags): Likewise.
10302 (tdesc_create_enum): Likewise.
10303 (tdesc_add_field): Likewise.
10304 (tdesc_add_typed_bitfield): Likewise.
10305 (tdesc_add_bitfield): Likewise.
10306 (tdesc_add_flag): Likewise.
10307 (tdesc_add_enum_value): Likewise.
10308 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
10309 (struct tdesc_type_vector): Likewise.
10310 (struct tdesc_type_field): Likewise.
10311 (struct tdesc_type_with_fields): Likewise.
10312 (tdesc_create_enum): Add declaration.
10313 (tdesc_add_typed_bitfield): Likewise.
10314 (tdesc_add_enum_value): Likewise.
10315 * target-descriptions.c (tdesc_type_field): Move from here.
10316 (tdesc_type_builtin): Likewise.
10317 (tdesc_type_vector): Likewise.
10318 (tdesc_type_with_fields): Likewise.
10319 (tdesc_predefined_types): Likewise.
10320 (tdesc_named_type): Likewise.
10321 (tdesc_create_vector): Likewise.
10322 (tdesc_create_struct): Likewise.
10323 (tdesc_set_struct_size): Likewise.
10324 (tdesc_create_union): Likewise.
10325 (tdesc_create_flags): Likewise.
10326 (tdesc_create_enum): Likewise.
10327 (tdesc_add_field): Likewise.
10328 (tdesc_add_typed_bitfield): Likewise.
10329 (tdesc_add_bitfield): Likewise.
10330 (tdesc_add_flag): Likewise.
10331 (tdesc_add_enum_value): Likewise.
10332 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
10333 (tdesc_add_typed_bitfield): Likewise.
10334 (tdesc_add_enum_value): Likewise.
10336 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10338 * common/tdesc.c (tdesc_feature::accept): Move to here.
10339 (tdesc_feature::operator==): Likewise.
10340 (tdesc_create_reg): Likewise.
10341 * common/tdesc.h (tdesc_type_kind): Likewise.
10342 (struct tdesc_type): Likewise.
10343 (struct tdesc_feature): Likewise.
10344 * regformats/regdat.sh: Create a feature.
10345 * target-descriptions.c (tdesc_type_kind): Move from here.
10346 (tdesc_type): Likewise.
10347 (tdesc_type_up): Likewise.
10348 (tdesc_feature): Likewise.
10349 (tdesc_create_reg): Likewise.
10351 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10353 * Makefile.in: Add arch/tdesc.c
10354 * common/tdesc.c: New file.
10355 * common/tdesc.h (tdesc_element_visitor): Move to here.
10356 (tdesc_element): Likewise.
10357 (tdesc_reg): Likewise.
10358 (tdesc_reg_up): Likewise.
10359 * regformats/regdef.h (reg): Add offset to constructors.
10360 * target-descriptions.c (tdesc_element_visitor): Move from here.
10361 (tdesc_element): Likewise.
10362 (tdesc_reg): Likewise.
10363 (tdesc_reg_up): Likewise.
10365 2018-04-17 Tom Tromey <tom@tromey.com>
10367 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
10368 discriminant field.
10370 2018-04-17 Tom Tromey <tom@tromey.com>
10372 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
10374 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
10376 * symtab.c (print_symbol_info): Skip printing filename and line
10377 number when `last' is NULL.
10378 (symtab_symbol_info): Use empty string instead of NULL for first
10379 invocation of print_symbol_info.
10380 (rbreak_command): Pass NULL to `last' parameter of
10383 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
10385 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
10386 instead of nullptr.
10388 2018-04-16 Pedro Alves <palves@redhat.com>
10390 * MAINTAINERS (sh): Remove.
10391 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
10392 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
10393 (ALLDEPFILES): Remove sh64-tdep.c.
10394 * NEWS: Mentions that support for SH-5/SH64 is removed.
10395 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
10396 (sh*-*-openbsd*): Ditto.
10397 (sh64-*-elf*): Remove.
10399 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
10400 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
10401 * sh-tdep.c: No longer include "sh64-tdep.h".
10402 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
10403 * sh64-tdep.c, sh64-tdep.h: Remove files.
10405 2018-04-16 Pedro Alves <palves@redhat.com>
10407 * MAINTAINERS: Remove m88k.
10408 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
10409 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
10410 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
10411 * NEWS: Mention that support for m88k was removed.
10412 * configure.host (m88*-*-*): Remove support.
10413 * configure.nat (m88k-*-*): Remove support.
10414 * configure.tgt (m88*-*-openbsd*): Remove.
10415 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
10417 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
10419 * configure.tgt (x86_tobjs): New variable.
10420 (amd64_tobjs, i386_tobjs): Use it.
10422 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10424 * symtab.c (print_symbol_info): Precede the symbol definition by
10425 the line number when available.
10426 * NEWS: Advertise this enhancement.
10428 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10430 * NEWS (New options): announce set/show record btrace cpu.
10431 * btrace.c: Include record-btrace.h.
10432 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
10433 the vendor is unknown.
10434 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
10435 Maybe overwrite the btrace configuration's cpu.
10436 (btrace_compute_ftrace): Add cpu parameter. Update callers.
10437 (btrace_fetch): Add cpu parameter. Update callers.
10438 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
10439 Maybe overwrite the btrace configuration's cpu. Skip enabling
10440 errata workarounds if the vendor is unknown.
10441 * python/py-record-btrace.c: Include record-btrace.h.
10442 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
10443 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
10444 * record-btrace.c (record_btrace_cpu_state_kind): New.
10445 (record_btrace_cpu): New.
10446 (set_record_btrace_cpu_cmdlist): New.
10447 (record_btrace_get_cpu): New.
10448 (require_btrace_thread, record_btrace_info)
10449 (record_btrace_resume_thread): Call record_btrace_get_cpu.
10450 (cmd_set_record_btrace_cpu_none): New.
10451 (cmd_set_record_btrace_cpu_auto): New.
10452 (cmd_set_record_btrace_cpu): New.
10453 (cmd_show_record_btrace_cpu): New.
10454 (_initialize_record_btrace): Initialize set/show record btrace cpu
10456 * record-btrace.h (record_btrace_get_cpu): New.
10458 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10460 * record.c (set_record_command): Fix typo in message.
10462 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10464 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
10466 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10468 * infrun.c (process_event_stop_test): Call
10469 gdbarch_in_indirect_branch_thunk.
10470 * gdbarch.sh (in_indirect_branch_thunk): New.
10471 * gdbarch.c: Regenerated.
10472 * gdbarch.h: Regenerated.
10475 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
10476 (HFILES_NO_SRCDIR): Add x86-tdep.h.
10477 (ALLDEPFILES): Add x86-tdep.c.
10478 * arch-utils.h (default_in_indirect_branch_thunk): New.
10479 * arch-utils.c (default_in_indirect_branch_thunk): New.
10480 * i386-tdep: Include x86-tdep.h.
10481 (i386_in_indirect_branch_thunk): New.
10482 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
10484 * amd64-tdep: Include x86-tdep.h.
10485 (amd64_in_indirect_branch_thunk): New.
10486 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
10488 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10491 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
10492 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
10493 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
10496 2018-04-12 Tom Tromey <tom@tromey.com>
10498 * rust-lang.c (rust_print_struct_def): Remove univariant code.
10499 (rust_evaluate_subexp): Likewise.
10501 2018-04-12 Pedro Alves <palves@redhat.com>
10503 * procfs.c (procfs_detach): Make forward declaration's prototype
10504 match definition's protototype.
10505 (proc_get_LDT_entry): Remove stale do_cleanups call.
10507 2018-04-12 Pedro Alves <palves@redhat.com>
10509 * target.h (target_ops::to_has_exited): Delete.
10510 (target_has_exited): Delete.
10511 * target-delegates.c: Regenerate.
10513 2018-04-11 Pedro Alves <palves@redhat.com>
10515 * target.c (fileio_fh_t::t): Add comment.
10516 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10517 (target_fileio_close): Handle a NULL target.
10518 (invalidate_fileio_fh): New.
10519 (target_close): Call it.
10520 * remote.c (remote_hostio_send_command): No longer check whether
10521 remote_desc is open.
10523 2018-04-11 Pedro Alves <palves@redhat.com>
10525 * target.c (fileio_fh_t): Make it a named struct instead of a
10527 (fileio_fh_t::is_closed): New method.
10528 (DEF_VEC_O (fileio_fh_t)): Remove.
10529 (fileio_fhandles): Now a std::vector.
10530 (is_closed_fileio_fh): Delete.
10531 (acquire_fileio_fd): Adjust. Rename parameters.
10532 (release_fileio_fd): Adjust.
10533 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
10534 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10535 (target_fileio_close): Adjust.
10537 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
10539 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
10542 2018-04-10 Pedro Alves <palves@redhat.com>
10544 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
10545 (scoped_finish_thread_state): New class.
10546 * infcmd.c (run_command_1): Use it instead of finish_thread_state
10548 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
10549 (fetch_inferior_event, normal_stop): Likewise.
10550 * thread.c (finish_thread_state_cleanup): Delete.
10552 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10553 Pedro Alves <palves@redhat.com>
10555 * value.c: Include "selftest.h" and "common/array-view.h".
10556 (struct range) <operator ==>: New.
10557 (test_ranges_contain): New.
10558 (check_ranges_vector): New.
10559 (test_insert_into_bit_range_vector): New.
10560 (_initialize_values): Register selftests.
10561 * common/array-view.h (operator==, operator!=): New.
10563 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10565 * common/gdb_vecs.h (unordered_remove): Add overload that takes
10567 * inline-frame.c: Include <algorithm>.
10568 (struct inline_state): Add constructor.
10569 (inline_state_s): Remove.
10570 (DEF_VEC_O(inline_state_s)): Remove.
10571 (inline_states): Change type to std::vector.
10572 (find_inline_frame_state): Adjust to std::vector.
10573 (allocate_inline_frame_state): Remove.
10574 (clear_inline_frame_state): Adjust to std::vector.
10575 (skip_inline_frames): Adjust to std::vector.
10577 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10579 * tracepoint.h (struct trace_state_variable): Add constructor.
10580 <name>: Change type to std::string.
10581 * tracepoint.c (tsv_s): Remove.
10582 (DEF_VEC_O(tsv_s)): Remove.
10583 (tvariables): Change to std::vector.
10584 (create_trace_state_variable): Adjust to std::vector.
10585 (find_trace_state_variable): Likewise.
10586 (find_trace_state_variable_by_number): Likewise.
10587 (delete_trace_state_variable): Likewise.
10588 (trace_variable_command): Adjust to std::string.
10589 (delete_trace_variable_command): Likewise.
10590 (tvariables_info_1): Adjust to std::vector.
10591 (save_trace_state_variables): Likewise.
10592 (start_tracing): Likewise.
10593 (merge_uploaded_trace_state_variables): Adjust to std::vector
10595 * target.h (struct target_ops)
10596 <to_download_trace_state_variable>: Pass reference to
10597 trace_state_variable.
10598 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
10599 * target-delegates.c: Re-generate.
10600 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
10601 (mi_tsv_deleted): Likewise.
10602 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
10603 * remote.c (remote_download_trace_state_variable): Change
10604 pointer to reference and adjust.
10605 * make-target-delegates (parse_argtypes): Handle references.
10606 (write_function_header): Likewise.
10607 (munge_type): Likewise.
10609 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10611 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10612 string_view-selftests.c.
10613 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
10615 * unittests/basic_string_view/cons/char/1.cc: Likewise.
10616 * unittests/basic_string_view/cons/char/2.cc: Likewise.
10617 * unittests/basic_string_view/cons/char/3.cc: Likewise.
10618 * unittests/basic_string_view/element_access/char/1.cc:
10620 * unittests/basic_string_view/element_access/char/empty.cc:
10622 * unittests/basic_string_view/element_access/char/front_back.cc:
10624 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
10625 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
10627 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
10629 * unittests/basic_string_view/modifiers/swap/char/1.cc:
10631 * unittests/basic_string_view/operations/compare/char/1.cc:
10633 * unittests/basic_string_view/operations/compare/char/13650.cc:
10635 * unittests/basic_string_view/operations/copy/char/1.cc:
10637 * unittests/basic_string_view/operations/data/char/1.cc:
10639 * unittests/basic_string_view/operations/find/char/1.cc:
10641 * unittests/basic_string_view/operations/find/char/2.cc:
10643 * unittests/basic_string_view/operations/find/char/3.cc:
10645 * unittests/basic_string_view/operations/find/char/4.cc:
10647 * unittests/basic_string_view/operations/rfind/char/1.cc:
10649 * unittests/basic_string_view/operations/rfind/char/2.cc:
10651 * unittests/basic_string_view/operations/rfind/char/3.cc:
10653 * unittests/basic_string_view/operations/substr/char/1.cc:
10655 * unittests/basic_string_view/operators/char/2.cc: Likewise.
10656 * unittests/string_view-selftests.c: New file.
10658 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10660 * unittests/basic_string_view/capacity/1.cc: New file.
10661 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
10662 * unittests/basic_string_view/cons/char/1.cc: New file.
10663 * unittests/basic_string_view/cons/char/2.cc: New file.
10664 * unittests/basic_string_view/cons/char/3.cc: New file.
10665 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
10666 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
10667 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
10668 * unittests/basic_string_view/element_access/char/1.cc: New file.
10669 * unittests/basic_string_view/element_access/char/2.cc: New file.
10670 * unittests/basic_string_view/element_access/char/empty.cc: New file.
10671 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
10672 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
10673 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
10674 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
10675 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
10676 * unittests/basic_string_view/include.cc: New file.
10677 * unittests/basic_string_view/inserters/char/1.cc: New file.
10678 * unittests/basic_string_view/inserters/char/2.cc: New file.
10679 * unittests/basic_string_view/inserters/char/3.cc: New file.
10680 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
10681 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
10682 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
10683 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
10684 * unittests/basic_string_view/literals/types.cc: New file.
10685 * unittests/basic_string_view/literals/values.cc: New file.
10686 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
10687 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
10688 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
10689 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
10690 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
10691 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
10692 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
10693 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
10694 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
10695 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
10696 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
10697 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
10698 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
10699 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
10700 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
10701 * unittests/basic_string_view/operations/data/char/1.cc: New file.
10702 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
10703 * unittests/basic_string_view/operations/find/char/1.cc: New file.
10704 * unittests/basic_string_view/operations/find/char/2.cc: New file.
10705 * unittests/basic_string_view/operations/find/char/3.cc: New file.
10706 * unittests/basic_string_view/operations/find/char/4.cc: New file.
10707 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
10708 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
10709 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
10710 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
10711 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
10712 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
10713 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
10714 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
10715 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
10716 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
10717 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
10718 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
10719 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
10720 * unittests/basic_string_view/operators/char/2.cc: New file.
10721 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
10722 * unittests/basic_string_view/range_access/char/1.cc: New file.
10723 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
10724 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
10725 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
10726 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
10727 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
10728 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
10729 * unittests/basic_string_view/requirements/typedefs.cc: New file.
10730 * unittests/basic_string_view/typedefs.cc: New file.
10731 * unittests/basic_string_view/types/1.cc: New file.
10733 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10735 * common/gdb_string_view.h: Remove libstdc++ implementation
10736 details, adjust to gdb reality.
10737 * common/gdb_string_view.tcc: Likewise.
10738 * cli/cli-script.c (struct string_view): Remove.
10739 (user_args) <m_args>: Change element type to gdb::string_view.
10740 (user_args::insert_args): Adjust.
10742 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10744 * common/gdb_string_view.h: New file.
10745 * common/gdb_string_view.tcc: New file.
10747 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10749 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
10750 * configure: Re-generate.
10752 2018-04-09 Pedro Alves <palves@redhat.com>
10754 * gdbarch.sh: Include "observable.h" instead of "observer.h".
10755 (set_target_gdbarch): Call
10756 gdb::observers::architecture_changed.notify instead of
10757 observer_notify_architecture_changed.
10759 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10761 * tracepoint.c (struct current_traceframe_cleanup): Remove.
10762 (do_restore_current_traceframe_cleanup): Remove.
10763 (restore_current_traceframe_cleanup_dtor): Remove.
10764 (make_cleanup_restore_current_traceframe): Remove.
10765 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
10767 * tracepoint.h (struct scoped_restore_current_traceframe): New.
10768 * infrun.c (fetch_inferior_event): Use
10769 scoped_restore_current_traceframe.
10771 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10773 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
10775 <n_allocated_type_units>: Remove.
10776 <all_type_units>: Change to std::vector.
10777 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10778 to std::vector change.
10779 (dwarf2_per_objfile::get_cutu): Likewise.
10780 (dwarf2_per_objfile::get_tu): Likewise.
10781 (create_signatured_type_table_from_index): Likewise.
10782 (create_signatured_type_table_from_debug_names): Likewise.
10783 (dw2_symtab_iter_next): Likewise.
10784 (dw2_print_stats): Likewise.
10785 (dw2_expand_all_symtabs): Likewise.
10786 (dw2_expand_marked_cus): Likewise.
10787 (dw2_debug_names_iterator::next): Likewise.
10788 (dwarf2_initialize_objfile): Likewise.
10789 (add_signatured_type_cu_to_table): Likewise.
10790 (create_all_type_units): Likewise.
10791 (add_type_unit): Likewise.
10792 (struct tu_abbrev_offset): Add constructor.
10793 (build_type_psymtabs_1): Adjust to std::vector change.
10794 (print_tu_stats): Likewise.
10795 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10796 (write_debug_names): Likewise.
10798 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10800 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
10801 Make an std::vector.
10802 <n_comp_units>: Remove.
10803 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10804 to std::vector change.
10805 (dwarf2_per_objfile::get_cutu): Likewise.
10806 (dwarf2_per_objfile::get_cu): Likewise.
10807 (create_cus_from_index): Likewise.
10808 (create_addrmap_from_index): Likewise.
10809 (create_addrmap_from_aranges): Likewise.
10810 (dwarf2_read_index): Likewise.
10811 (dw2_find_last_source_symtab): Likewise.
10812 (dw2_map_symtabs_matching_filename): Likewise.
10813 (dw2_symtab_iter_next): Likewise.
10814 (dw2_print_stats): Likewise.
10815 (dw2_expand_all_symtabs): Likewise.
10816 (dw2_expand_symtabs_with_fullname): Likewise.
10817 (dw2_expand_marked_cus): Likewise.
10818 (dw2_map_symbol_filenames): Likewise.
10819 (create_cus_from_debug_names): Likewise.
10820 (dwarf2_read_debug_names): Likewise.
10821 (dw2_debug_names_iterator::next): Likewise.
10822 (dwarf2_initialize_objfile): Likewise.
10823 (set_partial_user): Likewise.
10824 (dwarf2_build_psymtabs_hard): Likewise.
10825 (read_comp_units_from_section): Remove arguments, adjust to
10826 std::vector change.
10827 (create_all_comp_units): Adjust to std::vector and
10828 read_comp_units_from_section changes.
10829 (dwarf2_find_containing_comp_unit): Adjust to std::vector
10831 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10832 (psyms_seen_size): Likewise.
10833 (write_gdbindex): Likewise.
10834 (write_debug_names): Likewise.
10836 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10838 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
10839 with dwarf2_per_objfile.
10840 (create_cus_from_index): Likewise.
10841 (create_signatured_type_table_from_index): Likewise.
10842 (dwarf2_read_index): Likewise.
10843 (dwarf2_initialize_objfile): Likewise.
10844 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
10845 per_cu rather than get_dwarf2_per_objfile.
10847 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10849 * dwarf2read.h (struct signatured_type): Forward declare.
10850 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
10852 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
10853 (dw2_get_cutu): ...this.
10854 (dwarf2_per_objfile::get_cu): Rename from...
10855 (dw2_get_cu): ...this.
10856 (dwarf2_per_objfile::get_tu): New.
10857 (create_addrmap_from_index): Adjust.
10858 (create_addrmap_from_aranges): Adjust.
10859 (dw2_find_last_source_symtab): Adjust.
10860 (dw2_map_symtabs_matching_filename): Adjust.
10861 (dw2_symtab_iter_next): Adjust.
10862 (dw2_print_stats): Adjust.
10863 (dw2_expand_all_symtabs): Adjust.
10864 (dw2_expand_symtabs_with_fullname): Adjust.
10865 (dw2_expand_marked_cus): Adjust.
10866 (dw_expand_symtabs_matching_file_matcher): Adjust.
10867 (dw2_map_symbol_filenames): Adjust.
10868 (dw2_debug_names_iterator::next): Adjust.
10869 (dwarf2_initialize_objfile): Adjust.
10870 (set_partial_user): Adjust.
10871 (dwarf2_build_psymtabs_hard): Adjust.
10873 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10875 * dwarf2read.c (create_signatured_type_table_from_debug_names):
10876 Remove unused variables.
10877 (dw2_map_symtabs_matching_filename): Likewise.
10878 (dwarf2_record_block_ranges): Likewise.
10879 (dwarf2_read_addr_index): Likewise.
10880 (follow_die_offset): Likewise.
10882 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10884 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
10885 to symbol_file_add_main.
10887 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10890 * mi/mi-console.c (do_fputc_async_safe): New.
10891 (mi_console_file::write_async_safe): New.
10892 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
10893 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
10895 * ui-file.c (ui_file::putstrn): Adjust call to
10896 fputstrn_unfiltered.
10897 * utils.c (printchar): Replace do_fputs and do_fprintf
10898 parameters by do_fputc.
10899 (fputstr_filtered): Adjust call to printchar.
10900 (fputstr_unfiltered): Likewise.
10901 (fputstrn_filtered): Likewise.
10902 (fputstrn_unfiltered): Add do_fputc parameter, pass to
10904 * utils.h (do_fputc_ftype): New typedef.
10905 (fputstrn_unfiltered): Add do_fputc parameter.
10907 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10909 * regformats/i386/i386-avx.dat: Remove.
10911 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10914 * amd64-tdep.c (amd64_none_init_abi): New function.
10915 (amd64_x32_none_init_abi): New function.
10916 (_initialize_amd64_tdep): Register handlers for x86-64 and
10917 x64_32 with GDB_OSABI_NONE.
10918 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10919 GDB_OSABI_NONE osabi.
10921 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10924 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10926 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10927 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10929 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10931 * common/byte-vector.h (char_vector): New type.
10932 * target.h (target_read_alloc): Return
10933 gdb::optional<byte_vector>.
10934 (target_read_stralloc): Return gdb::optional<char_vector>.
10935 (target_get_osdata): Return gdb::optional<char_vector>.
10936 * target.c (target_read_alloc_1): Templatize. Replacement
10937 manual memory management with vector.
10938 (target_read_alloc): Change return type, adjust.
10939 (target_read_stralloc): Change return type, adjust.
10940 (target_get_osdata): Change return type, adjust.
10941 * auxv.c (struct auxv_info) <length>: Remove.
10942 <data>: Change type to gdb::optional<byte_vector>.
10943 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10944 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
10945 (target_auxv_search): Adjust.
10946 (fprint_target_auxv): Adjust.
10947 * avr-tdep.c (avr_io_reg_read_command): Adjust.
10948 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
10949 (linux_make_corefile_notes): Adjust.
10950 * osdata.c (get_osdata): Adjust.
10951 * remote.c (remote_get_threads_with_qxfer): Adjust.
10952 (remote_memory_map): Adjust.
10953 (remote_traceframe_info): Adjust.
10954 (btrace_read_config): Adjust.
10955 (remote_read_btrace): Adjust.
10956 (remote_pid_to_exec_file): Adjust.
10957 * solib-aix.c (solib_aix_get_library_list): Adjust.
10958 * solib-dsbt.c (decode_loadmap): Don't free buf.
10959 (dsbt_get_initial_loadmaps): Adjust.
10960 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
10961 * solib-target.c (solib_target_current_sos): Adjust.
10962 * tracepoint.c (sdata_make_value): Adjust.
10963 * xml-support.c (xinclude_start_include): Adjust.
10964 (xml_fetch_content_from_file): Adjust.
10965 * xml-support.h (xml_fetch_another): Change return type.
10966 (xml_fetch_content_from_file): Change return type.
10967 * xml-syscall.c (xml_init_syscalls_info): Adjust.
10968 * xml-tdesc.c (file_read_description_xml): Adjust.
10969 (fetch_available_features_from_target): Change return type.
10970 (target_fetch_description_xml): Adjust.
10971 (target_read_description_xml): Adjust.
10973 2018-04-06 Tom Tromey <tom@tromey.com>
10975 * value.c (~value): Update.
10976 (struct value) <contents>: Now unique_xmalloc_ptr.
10977 (value_contents_bits_eq, allocate_value_contents)
10978 (value_contents_raw, value_contents_all_raw)
10979 (value_contents_for_printing, value_contents_for_printing_const)
10980 (set_value_enclosing_type): Update.
10982 2018-04-06 Tom Tromey <tom@tromey.com>
10984 * value.c (range_s): Remove typedef, VEC.
10985 (struct range): Add operator<.
10986 (range_lessthan): Remove.
10987 (ranges_contain): Change type.
10989 (struct value) <unavailable, optimized_out>: Now std::vector.
10990 (value_entirely_available)
10991 (value_entirely_covered_by_range_vector)
10992 (value_entirely_unavailable, value_entirely_optimized_out):
10994 (insert_into_bit_range_vector): Change argument type.
10995 (find_first_range_overlap): Likewise.
10996 (struct ranges_and_idx, value_contents_bits_eq)
10997 (require_not_optimized_out, require_available): Update.
10998 (ranges_copy_adjusted): Change argument types.
10999 (value_optimized_out, value_copy, value_fetch_lazy): Update.
11001 2018-04-06 Tom Tromey <tom@tromey.com>
11003 * value.c (~value): Update.
11004 (struct value) <parent>: Now a value_ref_ptr.
11005 (value_parent, set_value_parent, value_address, value_copy):
11008 2018-04-06 Tom Tromey <tom@tromey.com>
11010 * value.c (struct value): Add constructor, destructor, and member
11012 (allocate_value_lazy, value_decref): Update.
11014 2018-04-06 Tom Tromey <tom@tromey.com>
11016 * value.c (struct value) <released, next>: Remove.
11017 (all_values): Now a std::vector.
11018 (allocate_value_lazy): Update.
11019 (value_next): Remove.
11020 (value_mark, value_free_to_mark, release_value)
11021 (value_release_to_mark): Update.
11023 2018-04-06 Tom Tromey <tom@tromey.com>
11025 * value.h (fetch_subexp_value, value_release_to_mark): Update.
11026 (free_value_chain): Remove.
11027 * value.c (free_value_chain): Remove.
11028 (value_release_to_mark): Return a std::vector.
11029 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
11031 (check_condition): Update.
11032 * eval.c (fetch_subexp_value): Change "val_chain" to a
11034 * breakpoint.c (update_watchpoint): Update.
11035 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
11037 2018-04-06 Tom Tromey <tom@tromey.com>
11039 * value.h (free_all_values): Remove.
11040 * value.c (free_all_values): Remove.
11042 2018-04-06 Tom Tromey <tom@tromey.com>
11044 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
11045 (value_history_chain, value_history_count): Remove.
11046 (value_history): New global.
11047 (record_latest_value, access_value_history, show_values)
11048 (preserve_values): Update.
11050 2018-04-06 Tom Tromey <tom@tromey.com>
11052 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
11053 * varobj.c (varobj_set_display_format, varobj_set_value)
11054 (install_default_visualizer, construct_visualizer)
11055 (install_new_value, ~varobj, varobj_get_value_type)
11056 (my_value_of_variable, varobj_editable_p): Update.
11057 * c-varobj.c (c_describe_child, c_value_of_variable)
11058 (cplus_number_of_children, cplus_describe_child): Update.
11059 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
11060 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
11061 (ada_value_of_variable, ada_value_is_changeable_p): Update.
11063 2018-04-06 Tom Tromey <tom@tromey.com>
11065 * printcmd.c (last_examine_address): Change type to
11067 (do_examine, x_command): Update.
11069 2018-04-06 Tom Tromey <tom@tromey.com>
11071 * value.c (release_value): Update.
11072 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
11073 (struct bpstats) <val>: Now a value_ref_ptr.
11074 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11075 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11076 (~watchpoint, print_it_watchpoint, watch_command_1)
11077 (invalidate_bp_value_on_memory_change): Update.
11079 2018-04-06 Tom Tromey <tom@tromey.com>
11081 * varobj.c (varobj_clear_saved_item)
11082 (update_dynamic_varobj_children, install_new_value, ~varobj):
11084 * value.h (value_incref): Move declaration earlier.
11085 (value_decref): Rename from value_free.
11086 (struct value_ref_policy): New.
11087 (value_ref_ptr): New typedef.
11088 (struct value_deleter): Remove.
11089 (gdb_value_up): Remove typedef.
11090 (release_value): Change return type.
11091 (release_value_or_incref): Remove.
11092 * value.c (set_value_parent): Update.
11093 (value_incref): Change return type.
11094 (value_decref): Rename from value_free.
11095 (value_free_to_mark, free_all_values, free_value_chain): Update.
11096 (release_value): Return value_ref_ptr.
11097 (release_value_or_incref): Remove.
11098 (record_latest_value, set_internalvar, clear_internalvar):
11100 * stack.c (info_frame_command): Don't call value_free.
11101 * python/py-value.c (valpy_dealloc, valpy_new)
11102 (value_to_value_object): Update.
11103 * printcmd.c (do_examine): Update.
11104 * opencl-lang.c (lval_func_free_closure): Update.
11105 * mi/mi-main.c (register_changed_p): Don't call value_free.
11106 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
11107 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
11108 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
11110 * guile/scm-value.c (vlscm_free_value_smob)
11111 (vlscm_scm_from_value): Update.
11112 * frame.c (frame_register_unwind, frame_unwind_register_signed)
11113 (frame_unwind_register_unsigned, get_frame_register_bytes)
11114 (put_frame_register_bytes): Don't call value_free.
11115 * findvar.c (address_from_register): Don't call value_free.
11116 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
11117 * dwarf2loc.c (entry_data_value_free_closure)
11118 (value_of_dwarf_reg_entry, free_pieced_value_closure)
11119 (dwarf2_evaluate_loc_desc_full): Update.
11120 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11121 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11122 (~watchpoint, watch_command_1)
11123 (invalidate_bp_value_on_memory_change): Update.
11124 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
11126 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
11129 * warning.m4: Add -Wno-error=deprecated-register.
11130 * configure: Re-generate.
11132 2018-04-05 Tom Tromey <tom@tromey.com>
11134 * linespec.h: Remove include of "vec.h".
11136 2018-04-05 Tom Tromey <tom@tromey.com>
11138 * linespec.c (typep): Remove typedef.
11139 (find_methods, find_superclass_methods): Take a std::vector.
11140 (find_method): Use std::vector.
11142 2018-04-05 Tom Tromey <tom@tromey.com>
11144 * utils.c (compare_strings): Remove.
11145 * utils.h (compare_strings): Remove.
11146 * objc-lang.h (find_imps): Update.
11147 * objc-lang.c (find_methods): Take a std::vector.
11148 (uniquify_strings, find_imps): Likewise.
11149 * linespec.c (find_methods): Take a std::vector.
11150 (decode_objc): Use std::vector.
11151 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
11153 (find_method, find_function_symbols): Use std::vector.
11155 2018-04-05 Tom Tromey <tom@tromey.com>
11157 * completer.c (completion_tracker::completion_tracker): Remove
11159 (completion_tracker::discard_completions): Likewise.
11160 * breakpoint.c (ambiguous_names_p): Remove cast.
11161 * ada-lang.c (_initialize_ada_language): Remove cast.
11162 * utils.h (streq): Update.
11163 (streq_hash): Add new declaration.
11164 * utils.c (streq): Return bool.
11165 (streq_hash): New function.
11167 2018-04-05 Tom Tromey <tom@tromey.com>
11169 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
11170 Remove a string copy.
11172 2018-04-05 Tom Tromey <tom@tromey.com>
11174 * linespec.c (filter_results): Use std::vector.
11175 (decode_line_2, decode_line_full): Update.
11177 2018-04-05 Tom Tromey <tom@tromey.com>
11179 * linespec.c (canonical_to_fullform): Return std::string.
11180 (filter_results): Update.
11181 (struct decode_line_2_item): Add constructor.
11182 <fullform, displayform>: Now std::string.
11183 (decode_line_2_compare_items): Now a std::sort comparator.
11184 (decode_line_2): Update.
11186 2018-04-05 Tom Tromey <tom@tromey.com>
11188 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
11189 (unexpected_linespec_error): Update.
11190 (linespec_parse_basic, parse_linespec): Update.
11192 2018-04-05 Tom Tromey <tom@tromey.com>
11194 * linespec.c (linespec_parse_basic): Reindent.
11196 2018-04-05 Tom Tromey <tom@tromey.com>
11198 * minsyms.h (iterate_over_minimal_symbols): Update.
11199 * minsyms.c (iterate_over_minimal_symbols): Take a
11200 gdb::function_view.
11201 * linespec.c (struct collect_minsyms): Remove.
11202 (compare_msyms): Now a std::sort comparator.
11203 (add_minsym): Add parameters.
11204 (search_minsyms_for_name): Update. Use std::vector.
11206 2018-04-03 Tom Tromey <tom@tromey.com>
11208 * mipsread.c (read_alphacoff_dynamic_symtab): Use
11211 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11213 * MAINTAINERS (Write After Approval): Add Weimin Pan.
11215 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11218 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
11219 printing static type.
11221 2018-04-01 Tom Tromey <tom@tromey.com>
11223 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
11224 (rs6000_xfer_shared_libraries): Update.
11226 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
11228 * common/gdb_vecs.h (char_ptr): Remove.
11229 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
11231 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11233 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
11235 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
11237 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11239 * tracepoint.h (struct uploaded_tp): Initialize fields.
11240 <actions, step_actions, cmd_strings>: Change type to
11241 std::vector<char *>.
11242 * tracepoint.c (get_uploaded_tp): Allocate with new.
11243 (free_uploaded_tps): Free with delete.
11244 (parse_tracepoint_definition): Adjust to std::vector change.
11245 * breakpoint.c (read_uploaded_action): Likewise.
11246 (create_tracepoint_from_upload): Likewise.
11247 * ctf.c (ctf_write_uploaded_tp): Likewise.
11248 (SET_ARRAY_FIELD): Likewise.
11249 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
11251 2018-03-30 Tom Tromey <tom@tromey.com>
11253 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
11255 (svr4_keep_data_in_core): Update.
11256 (svr4_read_so_list): Update.
11258 2018-03-30 Tom Tromey <tom@tromey.com>
11260 * windows-nat.c (handle_output_debug_string, handle_exception):
11262 * target.h (target_read_string): Update.
11263 * target.c (target_read_string): Change "string" to
11264 unique_xmalloc_ptr.
11265 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
11267 * solib-frv.c (frv_current_sos): Update.
11268 * solib-dsbt.c (dsbt_current_sos): Update.
11269 * solib-darwin.c (darwin_current_sos): Update.
11270 * linux-thread-db.c (inferior_has_bug): Update.
11271 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
11272 Update. Remove alloca.
11273 * ada-lang.c (ada_main_name): Update.
11275 2018-03-30 Tom Tromey <tom@tromey.com>
11277 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
11278 (struct dwo_file_deleter): New.
11279 (dwo_file_up): New typedef.
11280 (open_and_init_dwo_file): Use dwo_file_up.
11281 (free_dwo_file_cleanup): Remove.
11283 2018-03-30 Tom Tromey <tom@tromey.com>
11285 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
11286 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
11288 2018-03-30 Tom Tromey <tom@tromey.com>
11290 * dwarf2read.c (class free_cached_comp_units): New class.
11291 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
11292 (free_cached_comp_units): Remove function.
11294 2018-03-30 Tom Tromey <tom@tromey.com>
11296 * utils.h (make_cleanup_unpush_target): Remove.
11297 * inf-ptrace.c (struct target_unpusher): New.
11298 (target_unpush_up) New typedef.
11299 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
11301 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
11303 2018-03-27 Tom Tromey <tom@tromey.com>
11305 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
11307 2018-03-27 Pedro Alves <palves@redhat.com>
11308 Tom Tromey <tom@tromey.com>
11310 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
11311 destructor. Now a class.
11312 (gdb_readline_wrapper_cleanup): Remove function.
11313 (gdb_readline_wrapper): Remove cleanups.
11315 2018-03-27 Tom Tromey <tom@tromey.com>
11317 * typeprint.h (struct type_print_options) <local_typedefs,
11318 global_typedefs>: Remove "struct" keyword.
11319 (class typedef_hash_table): New class.
11320 (recursively_update_typedef_hash, add_template_parameters)
11321 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
11322 (find_typedef_in_hash): Don't declare.
11323 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
11324 (typedef_hash_table::recursively_update): Rename from
11325 recursively_update_typedef_hash. Now a member.
11326 (typedef_hash_table::add_template_parameters): Rename from
11327 add_template_parameters. Now a member.
11328 (typedef_hash_table::typedef_hash_table): Now a constructor;
11329 rename from create_typedef_hash.
11330 (typedef_hash_table::~typedef_hash_table): Now a destructor;
11331 rename from free_typedef_hash.
11332 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
11333 (do_free_global_table): Remove.
11334 (typedef_hash_table::typedef_hash_table): New constructor; renamed
11335 from copy_type_recursive.
11336 (create_global_typedef_table): Remove.
11337 (typedef_hash_table::find_global_typedef): Now a member of
11338 typedef_hash_table.
11339 (typedef_hash_table::find_typedef): Rename from
11340 find_typedef_in_hash; now a member.
11341 (whatis_exp): Update.
11342 * extension.h (struct ext_lang_type_printers): Add constructor and
11344 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
11346 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
11347 Now a constructor; rename from start_ext_lang_type_printers.
11348 (ext_lang_type_printers): Now a destructor; rename from
11349 free_ext_lang_type_printers.
11350 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
11352 (c_type_print_base_struct_union): Update. Remove cleanups.
11354 2018-03-27 Tom Tromey <tom@tromey.com>
11356 * dwarf-index-write.c: Include <cmath>.
11358 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11360 * NEWS: Add entry describing new "set|show varsize-limit" command.
11361 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
11363 * printcmd.c (_initialize_printcmd): Add "set var" alias of
11366 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
11368 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
11369 dwarf-index-write.c
11370 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
11371 * dwarf-index-common.c: New file.
11372 * dwarf-index-common.h: New file.
11373 * dwarf-index-write.c: New file.
11374 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
11375 (struct dwarf2_section_info): Move from here.
11376 (dwarf2_section_info_def): Likewise.
11377 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
11378 (offset_type): Likewise.
11379 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
11380 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
11381 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
11382 (byte_swap): Likewise.
11383 (MAYBE_SWAP): Likewise.
11384 (dwarf2_per_cu_ptr): Likewise.
11385 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
11386 (struct tu_stats): Likewise.
11387 (struct dwarf2_per_objfile): Likewise.
11388 (struct dwarf2_per_cu_data): Likewise.
11389 (struct signatured_type): Likewise.
11390 (sig_type_ptr): Likewise.
11391 (DEF_VEC_P (sig_type_ptr)): Likewise.
11392 (INDEX4_SUFFIX): Likewise.
11393 (INDEX5_SUFFIX): Likewise.
11394 (DEBUG_STR_SUFFIX): Likewise.
11395 (dwarf2_read_section): Make non-static.
11396 (mapped_index_string_hash): Move from here.
11397 (dwarf5_djb_hash): Likewise.
11398 (file_write): Likewise.
11399 (class data_buf): Likewise.
11400 (struct symtab_index_entry): Likewise.
11401 (struct mapped_symtab): Likewise.
11402 (find_slot): Likewise.
11403 (hash_expand): Likewise.
11404 (add_index_entry): Likewise.
11405 (uniquify_cu_indices): Likewise.
11406 (class c_str_view): Likewise.
11407 (class c_str_view_hasher): Likewise.
11408 (class vector_hasher): Likewise.
11409 (write_hash_table): Likewise.
11410 (psym_index_map): Likewise.
11411 (struct addrmap_index_data): Likewise.
11412 (add_address_entry): Likewise.
11413 (add_address_entry_worker): Likewise.
11414 (write_address_map): Likewise.
11415 (symbol_kind): Likewise.
11416 (write_psymbols): Likewise.
11417 (struct signatured_type_index_data): Likewise.
11418 (write_one_signatured_type): Likewise.
11419 (recursively_count_psymbols): Likewise.
11420 (recursively_write_psymbols): Likewise.
11421 (class debug_names): Likewise.
11422 (check_dwarf64_offsets): Likewise.
11423 (psyms_seen_size): Likewise.
11424 (write_gdbindex): Likewise.
11425 (write_debug_names): Likewise.
11426 (assert_file_size): Likewise.
11427 (write_psymtabs_to_index): Likewise.
11428 (save_gdb_index_command): Likewise.
11429 (_initialize_dwarf2_read): Don't register the "save gdb-index"
11431 * dwarf2read.h: New file.
11433 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11436 * dwarf2read.c (dwarf2_physname): Do not return the demangled
11437 symbol name if the CU's language stores symbol names in linkage
11439 * language.h (struct language_defn)
11440 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
11441 all instances of this struct.
11443 2018-03-26 Tom Tromey <tom@tromey.com>
11445 * stack.c (backtrace_command_1): Remove verbose code.
11447 2018-03-26 Tom Tromey <tom@tromey.com>
11449 * python/py-framefilter.c (py_print_type): Don't catch
11450 exceptions. Return void.
11451 (py_print_value): Likewise.
11452 (py_print_single_arg): Likewise.
11453 (enumerate_args): Don't catch exceptions.
11454 (py_print_args): Likewise.
11455 (py_print_frame): Likewise.
11456 (gdbpy_apply_frame_filter): Catch exceptions here.
11458 2018-03-26 Tom Tromey <tom@tromey.com>
11460 * stack.c (_initialize_stack): Remove trailing newlines from help
11461 text. Add "Usage" line to "backtrace" help.
11463 2018-03-26 Tom Tromey <tom@tromey.com>
11466 * python/py-framefilter.c (py_print_args): Call wrap_hint.
11468 2018-03-26 Tom Tromey <tom@tromey.com>
11470 * python/py-framefilter.c (py_print_single_arg): Return
11471 EXT_LANG_BT_ERROR from catch.
11473 2018-03-26 Tom Tromey <tom@tromey.com>
11475 PR backtrace/15584:
11476 * stack.c (backtrace_command_1): Move some code into no-filters
11479 2018-03-26 Tom Tromey <tom@tromey.com>
11481 * python/py-framefilter.c (throw_quit_or_print_exception): New
11483 (gdbpy_apply_frame_filter): Use it.
11485 2018-03-26 Tom Tromey <tom@tromey.com>
11488 * python/py-framefilter.c (py_print_type, py_print_value)
11489 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
11492 2018-03-26 Tom Tromey <tom@tromey.com>
11494 * python/py-framefilter.c (enumerate_args): Use
11495 gdb::unique_xmalloc_ptr.
11497 2018-03-26 Tom Tromey <tom@tromey.com>
11499 * python/py-framefilter.c (py_print_frame): Return
11501 (gdbpy_apply_frame_filter): Update comment.
11502 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
11504 <EXT_LANG_BT_NO_FILTERS>: Change value.
11506 2018-03-26 Tom Tromey <tom@tromey.com>
11508 PR backtrace/15582:
11509 * stack.c (backtrace_command): Parse "hide" argument.
11510 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
11511 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
11514 2018-03-26 Tom Tromey <tom@tromey.com>
11516 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
11518 (backtrace_command): Remove "fulltrace", add "flags".
11520 2018-03-26 Tom Tromey <tom@tromey.com>
11522 * stack.c (backtrace_command): Rewrite command line parsing.
11524 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11526 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
11528 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11530 * filename-seen-cache.h: Add include guard.
11532 2018-03-26 Keith Seitz <keiths@redhat.com>
11534 * symfile.c (place_section): Remove "struct" from section_addr_info
11536 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
11537 "struct" keyword from section_addr_info.
11539 2018-03-26 Alan Hayward <alan.hayward@arm.com>
11541 * regformats/regdef.h (reg): Add constructors.
11543 2018-03-25 Pedro Alves <palves@redhat.com>
11545 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
11546 if then/else bodies in var_func_name extraction.
11548 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
11550 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
11551 lookup_minimal_symbol() to find symbol entry.
11552 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
11554 2018-03-23 Keith Seitz <keiths@redhat.com>
11557 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
11558 nested type definitions for C++, too.
11560 2018-03-23 Tom Tromey <tom@tromey.com>
11562 * machoread.c (struct oso_el): Add a constructor. Don't define as
11564 (macho_register_oso): Remove.
11565 (macho_symtab_read): Take a std::vector.
11566 (oso_el_compare_name): Now a std::sort comparator.
11567 (macho_symfile_read_all_oso): Take a std::vector.
11568 (macho_symfile_read): Use std::vector. Remove cleanups.
11570 2018-03-22 Tom Tromey <tom@tromey.com>
11572 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
11573 (record_full_goto_bookmark): Use std::string.
11575 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11578 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
11581 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11583 * rs6000-tdep.c (store_insn_p): New function.
11584 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
11585 and cr_reg to their unshifted values. Use store_insn_p to
11586 match LR saves using either R1 or fdata->alloca_reg. Use
11587 store_insn_p to match CR saves. Set alloca_reg_offset
11588 when alloca_reg and framep are set. Remove lr_reg shift
11589 when assigning to fdata->lr_register.
11591 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
11593 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
11594 command line args instead of emitting a warning.
11596 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11598 * tracepoint.h (struct static_tracepoint_marker): Initialize
11599 fields, define default constructor, move constructor and move
11600 assignment, disable the rest.
11601 <str_id, extra>: Make std::string.
11602 (release_static_tracepoint_marker): Remove.
11603 (free_current_marker): Remove.
11604 * tracepoint.c (free_current_marker): Remove.
11605 (parse_static_tracepoint_marker_definition): Adjust to
11606 std::string, use new hex2str overload.
11607 (release_static_tracepoint_marker): Remove.
11608 (print_one_static_tracepoint_marker): Get marker by reference
11609 and adjust to std::string.
11610 (info_static_tracepoint_markers_command): Adjust to std::vector
11612 * target.h (static_tracepoint_marker_p): Remove typedef.
11613 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
11614 (struct target_ops) <to_static_tracepoint_marker_at>: Return
11616 <to_static_tracepoint_markers_by_strid>: Return std::vector.
11618 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
11619 (target_debug_print_std_vector_static_tracepoint_marker): New.
11620 (target_debug_print_struct_static_tracepoint_marker_p): Rename
11622 (target_debug_print_static_tracepoint_marker_p): ... this.
11623 * target-delegates.c: Re-generate.
11624 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
11626 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
11627 (decode_static_tracepoint_spec): Adjust to std::vector.
11628 (tracepoint_print_one_detail): Adjust to std::string.
11629 (strace_marker_decode_location): Adjust to std::string.
11630 (update_static_tracepoint): Adjust to std::string, remove call
11631 to release_static_tracepoint_marker.
11632 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
11633 Adjust to std::vector.
11634 * remote.c (remote_static_tracepoint_marker_at): Return bool.
11635 (remote_static_tracepoint_markers_by_strid): Adjust to
11637 * common/rsp-low.h (hex2str): New overload with explicit count
11639 * common/rsp-low.c (hex2str): New overload with explicit count
11641 * unittests/rsp-low-selftests.c (test_hex2str): New function.
11642 (_initialize_rsp_low_selftests): Add test_hex2str test.
11643 * unittests/tracepoint-selftests.c
11644 (test_parse_static_tracepoint_marker_definition): Adjust to
11647 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11649 * tracepoint.c (parse_static_tracepoint_marker_definition):
11650 Consider case where the definition is followed by more
11652 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11653 tracepoint-selftests.c.
11654 * unittests/tracepoint-selftests.c: New.
11656 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11658 * MAINTAINERS (Write After Approval): Add Pedro Franco de
11661 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
11663 * symtab.c (find_pc_sect_line): fixed indentation.
11665 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
11667 * symtab.c (find_pc_sect_line): now uses binary search.
11669 2018-03-19 Tom Tromey <tom@tromey.com>
11671 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
11672 "IDENT" production.
11674 2018-03-19 Pedro Alves <palves@redhat.com>
11675 Tom Tromey <tom@tromey.com>
11677 * unittests/observable-selftests.c: New file.
11678 * common/observable.h: New file.
11679 * observable.h: New file.
11680 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
11681 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
11682 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
11683 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
11684 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
11685 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
11686 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
11687 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
11688 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
11689 python/py-breakpoint.c, python/py-finishbreakpoint.c,
11690 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
11691 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
11692 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
11693 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
11694 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
11695 tui/tui-interp.c, valops.c: Update all users.
11696 * tui/tui-hooks.c (tui_bp_created_observer)
11697 (tui_bp_deleted_observer, tui_bp_modified_observer)
11698 (tui_inferior_exit_observer, tui_before_prompt_observer)
11699 (tui_normal_stop_observer, tui_register_changed_observer):
11701 (tui_observers_token): New global.
11702 (attach_or_detach, tui_attach_detach_observers): New functions.
11703 (tui_install_hooks, tui_remove_hooks): Use
11704 tui_attach_detach_observers.
11705 * record-btrace.c (record_btrace_thread_observer): Remove.
11706 (record_btrace_thread_observer_token): New global.
11707 * observer.sh: Remove.
11708 * observer.c: Rename to observable.c.
11709 * observable.c (namespace gdb_observers): Define new objects.
11710 (observer_debug): Move into gdb_observers namespace.
11711 (struct observer, struct observer_list, xalloc_observer_list_node)
11712 (xfree_observer_list_node, generic_observer_attach)
11713 (generic_observer_detach, generic_observer_notify): Remove.
11714 (_initialize_observer): Update.
11715 Don't include observer.inc.
11716 * Makefile.in (generated_files): Remove observer.h, observer.inc.
11717 (clean mostlyclean): Likewise.
11718 (observer.h, observer.inc): Remove targets.
11719 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
11720 (COMMON_SFILES): Use observable.c, not observer.c.
11721 * .gitignore: Remove observer.h.
11723 2018-03-18 Tom Tromey <tom@tromey.com>
11725 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
11727 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
11729 2018-03-17 Tom Tromey <tom@tromey.com>
11731 * auto-load.c (auto_load_objfile_script_1): Use std::string.
11733 2018-03-17 Tom Tromey <tom@tromey.com>
11735 * target.c (class scoped_target_fd): New.
11736 (target_fileio_close_cleanup): Remove.
11737 (target_fileio_read_alloc_1): Use scoped_target_fd.
11739 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
11741 * silent-rules.mk: New.
11742 * Makefile.in: Include silent-rules.mk
11743 (srcdir, VPATH, top_srcdir): Move up.
11744 (COMPILE): Add ECHO_CXX.
11745 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
11746 (init.c): Add ECHO_INIT_C.
11747 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
11748 (version.c): Add ECHO_GEN.
11749 (printcmd.o): Add ECHO_CXX.
11750 (target-float.o): Add ECHO_CXX.
11751 (ada-exp.o): Add ECHO_CXX.
11752 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
11753 (insight$(EXEEXT)): Add ECHO_CXXLD.
11754 * gnulib/configure.ac: Add AM_SILENT_RULES.
11755 * gnulib/aclocal.m4: Re-generate.
11756 * gnulib/configure: Re-generate.
11757 * gnulib/import/Makefile.in: Re-generate.
11759 2018-03-16 Tom Tromey <tom@tromey.com>
11761 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
11762 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
11763 * utils.c (do_free_section_addr_info)
11764 (make_cleanup_free_section_addr_info): Remove.
11765 * symfile.h (struct other_sections): Add constructor.
11766 (struct section_addr_info): Remove.
11767 (section_addr_info): New typedef.
11768 (struct sym_fns) <sym_offsets>: Change type of parameter.
11769 (build_section_addr_info_from_objfile)
11770 (relative_addr_info_to_section_offsets, addr_info_make_relative)
11771 (default_symfile_offsets, symbol_file_add)
11772 (symbol_file_add_from_bfd)
11773 (build_section_addr_info_from_section_table): Update.
11774 (alloc_section_addr_info, free_section_addr_info): Don't declare.
11775 * symfile.c (alloc_section_addr_info): Remove.
11776 (build_section_addr_info_from_section_table): Change return type.
11778 (build_section_addr_info_from_bfd)
11779 (build_section_addr_info_from_objfile): Likewise.
11780 (free_section_addr_info): Remove.
11781 (relative_addr_info_to_section_offsets): Change type of "addrs".
11782 (addrs_section_compar): Now a std::sort comparator.
11783 (addrs_section_sort): Change return type.
11784 (addr_info_make_relative): Change type of "addrs". Update.
11785 (default_symfile_offsets, syms_from_objfile_1)
11786 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
11787 (symbol_file_add_separate): Update.
11788 (symbol_file_add): Change type of "addrs". Update.
11789 (add_symbol_file_command): Update. Remove cleanups.
11790 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
11792 * symfile-debug.c (debug_sym_offsets): Change type of "info".
11793 * solib.c (solib_read_symbols): Update.
11794 * objfiles.c (objfile_relocate): Update. Remove cleanups.
11795 * machoread.c (macho_symfile_offsets): Update.
11796 * jit.c (jit_bfd_try_read_symtab): Update.
11798 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
11800 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11801 unittests/utils-selftests.c.
11802 * unittests/utils-selftests.c: New file.
11804 2018-03-14 Tom Tromey <tom@tromey.com>
11807 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
11810 2018-03-14 Tom Tromey <tom@tromey.com>
11813 * printcmd.c (printf_pointer): Allow "-" in format.
11815 2018-03-14 Tom Tromey <tom@tromey.com>
11817 * printcmd.c (_initialize_printcmd): Add usage to printf.
11819 2018-03-14 Yao Qi <qiyao@sourceware.org>
11821 * MAINTAINERS: Update my email address.
11823 2018-03-13 Tom Tromey <tom@tromey.com>
11825 * machoread.c (macho_check_dsym): Change filenamep to a
11827 (macho_symfile_read): Update.
11828 * symfile.c (load_command): Use std::string.
11830 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
11832 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
11833 to error message string.
11834 (riscv_register_name): Use xsnprintf instead of sprintf.
11835 (riscv_insn::fetch_instruction): Use gdb_assert instead of
11837 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
11839 (riscv_push_dummy_call): Likewise.
11841 2018-03-12 Tom Tromey <tom@tromey.com>
11843 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
11844 Use gdb::byte_vector.
11845 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
11847 2018-03-12 Yao Qi <yao.qi@linaro.org>
11849 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
11850 parameter type to readable_regcache.
11851 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
11854 2018-03-11 Tom Tromey <tom@tromey.com>
11856 * dwarf2read.c (struct nextfield): Add initializers.
11857 (struct nextfnfield): Remove.
11858 (struct fnfieldlist): Add initializers. Remove "length" and
11859 "head", use std::vector.
11860 (struct decl_field_list): Remove.
11861 (struct field_info): Add initializers.
11862 <fields, baseclasses>: Now std::vector.
11863 <nbaseclasses, nfnfields, typedef_field_list_count,
11864 nested_types_list_count>: Remove.
11865 (dwarf2_add_field, dwarf2_add_type_defn)
11866 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
11867 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
11868 (process_structure_scope): Update.
11870 2018-03-11 Tom Tromey <tom@tromey.com>
11872 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
11873 for use by std::sort.
11874 (build_type_psymtabs_1): Use std::vector.
11876 2018-03-09 Eli Zaretskii <eliz@gnu.org>
11878 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
11879 and LIBMPFR in the printed configuration.
11881 2018-03-08 Tom Tromey <tom@tromey.com>
11883 * source.c (get_filename_and_charpos): Use scoped_fd.
11884 * nto-procfs.c (procfs_open_1): Use scoped_fd.
11885 (procfs_pidlist): Likewise.
11886 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
11887 (iterate_over_mappings): Likewise.
11889 2018-03-08 Tom Tromey <tom@tromey.com>
11891 * infcall.c (struct call_return_meta_info)
11892 <stack_temporaries_enabled>: Remove.
11893 (get_call_return_value, call_function_by_hand_dummy): Update.
11894 * thread.c (disable_thread_stack_temporaries): Remove.
11895 (enable_thread_stack_temporaries): Remove.
11896 (thread_stack_temporaries_enabled_p): Return bool.
11897 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
11898 (get_last_thread_stack_temporary): Update.
11899 * eval.c (evaluate_subexp): Update.
11900 * gdbthread.h (class enable_thread_stack_temporaries): Now a
11901 class, not a function.
11902 (value_ptr, value_vec): Remove typedefs.
11903 (class thread_info) <stack_temporaries_enabled>: Now bool.
11904 <stack_temporaries>: Now a std::vector.
11905 (thread_stack_temporaries_enabled_p)
11906 (value_in_thread_stack_temporaries): Return bool.
11908 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
11910 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11911 (getpkt_or_notif_sane_1): Likewise.
11913 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11915 * build-id.c (build_id_to_debug_bfd): Use std::string.
11917 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11919 * build-id.c (find_separate_debug_file_by_buildid): Return
11921 * build-id.h (find_separate_debug_file_by_buildid): Return
11923 * coffread.c (coff_symfile_read): Adjust to std::string.
11924 * elfread.c (elf_symfile_read): Adjust to std::string.
11925 * symfile.c (separate_debug_file_exists): Change parameter to
11927 (find_separate_debug_file): Return std::string.
11928 (find_separate_debug_file_by_debuglink): Return std::string.
11929 * symfile.h (find_separate_debug_file_by_debuglink): Return
11932 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11934 * common/xml-utils.c (xml_escape_text): Move code to...
11935 (xml_escape_text_append): ... this new function.
11936 * common/xml-utils.h (xml_escape_text_append): New declaration.
11937 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11939 (_initialize_xml_utils): register test_xml_escape_text_append as
11942 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11944 * defs.h: Remove MAX_REGISTER_SIZE.
11945 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
11947 * python/py-unwind.c (pyuw_sniffer): Likewise.
11949 2018-03-07 Tom Tromey <tom@tromey.com>
11951 * linux-tdep.c (linux_info_proc): Update.
11952 * target.h (struct target_ops) <to_fileio_readlink>: Return
11954 (target_fileio_readlink): Return optional<string>.
11955 * remote.c (remote_hostio_readlink): Return optional<string>.
11956 * inf-child.c (inf_child_fileio_readlink): Return
11958 * target.c (target_fileio_readlink): Return optional<string>.
11960 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
11962 * regcache.c (cooked_read_test): Add riscv to the list of
11963 architectures that have a save_reggroup.
11965 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
11967 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
11968 value is not a dynamic class object.
11970 2018-03-06 Tom Tromey <tom@tromey.com>
11972 * rust-exp.y: Formatting fixes.
11974 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11976 * riscv-tdep.c (riscv_register_name): Remove target description
11978 (riscv_gdbarch_init): Remove target description check.
11980 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11982 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
11984 * riscv-tdep.h: Likewise.
11986 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11988 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
11989 (riscv_pseudo_register_write): Delete.
11990 (riscv_gdbarch_init): Remove all use of pseudo registers.
11992 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11994 * record-btrace.c (btrace_print_lines): Replace cleanup
11995 parameter with RAII equivalents.
11996 (btrace_insn_history): Replace cleanup with RAII equivalents.
11997 * ui-out.h (make_cleanup_ui_out_list_begin_end,
11998 make_cleanup_ui_out_tuple_begin_end): Remove.
11999 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
12000 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
12001 make_cleanup_ui_out_list_begin_end): Remove.
12003 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12005 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
12006 parameter types to std::vector. Use bool.
12007 (record_btrace_wait): Replace VEC(tp_t) with
12008 std::vector<thread_info *>.
12009 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
12011 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12013 * record-btrace.c (record_btrace_disable_callback): Remove.
12014 (struct scoped_btrace_disable): New.
12015 (record_btrace_open): Use scoped_btrace_disable.
12017 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12019 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
12020 reading values from registers.
12022 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12024 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
12027 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12029 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
12030 change parameter type. Use GDB's print functions, and use
12031 core_addr_to_string where appropriate.
12032 (riscv_push_dummy_call): Use core_addr_to_string where
12033 appropriate, update call to riscv_print_arg_location, and reindent
12035 (riscv_return_value): Update call to riscv_print_arg_location.
12037 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12038 Tim Newsome <tim@sifive.com>
12039 Albert Ou <a0u@eecs.berkeley.edu>
12040 Darius Rad <darius@bluespec.com>
12042 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
12043 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
12044 (ALLDEPFILES): Add riscv-tdep.c
12045 * configure.tgt: Add riscv support.
12046 * riscv-tdep.c: New file.
12047 * riscv-tdep.h: New file.
12048 * NEWS: Mention new target.
12049 * MAINTAINERS: Add entry for riscv.
12051 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12053 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
12054 fields within aggregates.
12056 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
12058 * record-btrace.c (btrace_print_lines): Change type of flags to
12059 gdb_disassembly_flags.
12061 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12063 * fbsd-nat.c: Include "inf-ptrace.h".
12064 (USE_SIGTRAP_SIGINFO): Conditionally define.
12065 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
12066 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
12067 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
12069 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
12071 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
12073 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
12074 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
12075 "supports_stopped_by_hw_breakpoint" target methods.
12077 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12079 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
12080 * fbsd-nat.c (debug_fbsd_nat): New variable.
12081 (show_fbsd_nat_debug): New function.
12082 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
12083 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
12085 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12087 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
12088 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
12090 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
12091 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
12094 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12096 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
12097 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
12099 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12101 * charset.c (struct charset_vector): New.
12102 (charsets): Change type to charset_vector.
12103 (find_charset_names): Adjust.
12105 (_initialize_charset): Adjust.
12107 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12109 * progspace.h (struct program_space) <deleted_solibs>: Change
12110 type to std::vector<std::string>.
12111 * progspace.c (clear_program_space_solib_cache): Adjust.
12112 * breakpoint.c (print_solib_event): Adjust.
12113 (check_status_catch_solib): Adjust.
12114 * solib.c (update_solib_list): Adjust.
12115 * ui-out.h (class ui_out) <field_string>: New overload.
12116 * ui-out.c (ui_out::field_string): New overload.
12118 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12120 * progspace.h (struct program_space): Add constructor and
12121 destructor, initialize fields.
12122 (add_program_space): Remove.
12123 * progspace.c (add_program_space): Rename to...
12124 (program_space::program_space): ... this.
12125 (release_program_space): Rename to...
12126 (program_space::~program_space): ... this.
12127 (delete_program_space): Use delete to delete program_space.
12128 (initialize_progspace): Use new to allocate program_space.
12129 * inferior.c (add_inferior_with_spaces): Likewise.
12130 (clone_inferior_command): Likewise.
12131 * infrun.c (follow_fork_inferior): Likewise.
12132 (handle_vfork_child_exec_or_exit): Likewise.
12134 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12136 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
12137 (delim_string_to_char_ptr_vec): Return std::vector of
12138 gdb::unique_xmalloc_ptr.
12139 (dirnames_to_char_ptr_vec_append): Take std::vector of
12140 gdb::unique_xmalloc_ptr.
12141 (dirnames_to_char_ptr_vec): Return std::vector of
12142 gdb::unique_xmalloc_ptr.
12143 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
12144 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
12145 (delim_string_to_char_ptr_vec): Return an std::vector of
12146 gdb::unique_xmalloc_ptr, adjust the code.
12147 (dirnames_to_char_ptr_vec_append): Take an std::vector of
12148 gdb::unique_xmalloc_ptr, adjust the code.
12149 (dirnames_to_char_ptr_vec): Return an std::vector of
12150 gdb::unique_xmalloc_ptr, adjust the code.
12151 * auto-load.c (auto_load_safe_path_vec): Change type to
12152 std::vector of gdb::unique_xmalloc_ptr.
12153 (auto_load_expand_dir_vars): Return an std::vector of
12154 gdb::unique_xmalloc_ptr, adjust the code.
12155 (auto_load_safe_path_vec_update): Adjust.
12156 (filename_is_in_auto_load_safe_path_vec): Adjust.
12157 (auto_load_objfile_script_1): Adjust.
12158 * build-id.c (build_id_to_debug_bfd): Adjust.
12159 * linux-thread-db.c (thread_db_load_search): Adjust.
12160 * source.c (add_path): Adjust.
12162 * symfile.c (find_separate_debug_file): Adjust.
12163 * utils.c (do_free_char_ptr_vec): Remove.
12164 (make_cleanup_free_char_ptr_vec): Remove.
12166 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
12169 * common/pathstuff.c: Conditionally include "<windows.h>".
12171 2018-03-01 Georg Sauthoff <mail@georg.so>
12174 * gcore.in: Quote variables and switch interpreter to bash.
12176 2018-03-01 Tom Tromey <tom@tromey.com>
12178 * dwarf2read.c (alloc_discriminant_info): Fix default_index
12179 assertion. Add assertion for discriminant_index.
12180 (quirk_rust_enum): Use correct base type name in univariant case.
12182 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
12184 * record.c (get_call_history_modifiers): Return a
12185 record_print_flags.
12186 (cmd_record_call_history): Adjust.
12187 * record-btrace.c (record_btrace_call_history): Adjust.
12188 (record_btrace_call_history_range): Adjust.
12189 (record_btrace_call_history_from): Adjust.
12190 * target-debug.h (target_debug_print_record_print_flags): New.
12191 * target-delegates.c: Re-generate.
12192 * target.c (target_call_history): Change flags type.
12193 (target_call_history_from): Likewise.
12194 (target_call_history_range): Likewise.
12195 * target.h (struct target_ops) <target_call_history>: Likewise.
12196 (target_call_history_from): Likewise.
12197 (target_call_history_range): Likewise.
12199 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12200 Simon Marchi <simon.marchi@polymtl.ca>
12202 * common/common-utils.c: Include "sys/stat.h".
12203 (is_regular_file): Move here from "source.c"; change return
12205 * common/common-utils.h (is_regular_file): New prototype.
12206 * common/pathstuff.c (contains_dir_separator): New function.
12207 * common/pathstuff.h (contains_dir_separator): New prototype.
12208 * source.c: Don't include "sys/stat.h".
12209 (is_regular_file): Move to "common/common-utils.c".
12211 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12213 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
12214 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
12215 * auto-load.c: Include "common/pathstuff.h".
12216 * common/common-def.h (current_directory): Move here.
12217 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
12219 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
12221 * common/pathstuff.c: New file.
12222 * common/pathstuff.h: New file.
12223 * compile/compile.c: Include "common/pathstuff.h".
12224 * defs.h (current_directory): Move to "common/common-defs.h".
12225 * dwarf2read.c: Include "common/pathstuff.h".
12226 * exec.c: Likewise.
12227 * guile/scm-safe-call.c: Likewise.
12228 * linux-thread-db.c: Likewise.
12229 * main.c: Likewise.
12230 * nto-tdep.c: Likewise.
12231 * objfiles.c: Likewise.
12232 * source.c: Likewise.
12233 * symtab.c: Likewise.
12234 * utils.c: Include "common/pathstuff.h".
12235 (gdb_realpath): Move to "common/pathstuff.c".
12236 (gdb_realpath_keepfile): Likewise.
12237 (gdb_abspath): Likewise.
12238 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
12239 (gdb_realpath_keepfile): Likewise.
12240 (gdb_abspath): Likewise.
12242 2018-02-28 John Baldwin <jhb@FreeBSD.org>
12244 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
12245 wildcard process pid for super_resume for kernels with a
12248 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
12250 * compile/compile.c (get_args): Add additional comments
12251 explaining function.
12253 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
12254 Tom Tromey <tom@tromey.com>
12256 * target.h (memory_write_request_s): Remove typedef. Don't define
12258 (target_write_memory_blocks): Change argument to std::vector.
12259 (struct memory_write_request): Add constructor.
12260 * target-memory.c (compare_block_starting_address): Return bool.
12261 Change argument types.
12262 (claim_memory): Change arguments to use std::vector.
12263 (split_regular_and_flash_blocks, blocks_to_erase)
12264 (compute_garbled_blocks): Likewise.
12265 (cleanup_request_data, cleanup_write_requests_vector): Remove.
12266 (target_write_memory_blocks): Change argument to std::vector.
12267 * symfile.c (struct load_section_data): Add constructor and
12268 destructor. Use std::vector for "requests".
12269 (struct load_progress_data): Add initializers.
12270 (load_section_callback): Update. Use "new".
12271 (clear_memory_write_data): Remove.
12272 (generic_load): Update.
12274 2018-02-27 Alan Hayward <alan.hayward@arm.com>
12276 * arch/aarch64.h: Use common/tdesc.h.
12278 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12280 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
12281 architecture with a 64-bit ABI.
12283 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12285 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
12286 ahead of target description loading.
12288 2018-02-26 Tom Tromey <tom@tromey.com>
12290 * stack.c (backtrace_command_1): Update.
12291 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
12293 * python/py-framefilter.c (py_print_frame)
12294 (gdbpy_apply_frame_filter): Change type of "flags".
12295 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
12297 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
12298 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
12299 * extension.h (enum frame_filter_flag): Rename from
12300 frame_filter_flags.
12301 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
12302 (apply_ext_lang_frame_filter): Change type of "flags".
12303 * extension.c (apply_ext_lang_frame_filter): Change type of
12305 * extension-priv.h (struct extension_language_ops)
12306 <apply_frame_filter>: Change type of "flags".
12308 2018-02-26 Tom Tromey <tom@tromey.com>
12311 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
12312 off-by-one in py_end computation.
12313 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
12315 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
12318 2018-02-26 Tom Tromey <tom@tromey.com>
12320 * dwarf2read.c (struct variant_field): New.
12321 (struct nextfield) <variant>: New field.
12322 (dwarf2_add_field): Handle DW_TAG_variant_part.
12323 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
12324 discriminated union.
12325 (read_structure_type): Handle DW_TAG_variant_part.
12326 (handle_struct_member_die): New function, extracted from
12327 process_structure_scope. Handle DW_TAG_variant.
12328 (process_structure_scope): Handle discriminated unions. Call
12329 handle_struct_member_die.
12331 2018-02-26 Tom Tromey <tom@tromey.com>
12333 * rust-lang.h (rust_last_path_segment): Declare.
12334 * rust-lang.c (rust_last_path_segment): Now public. Change
12336 (struct disr_info): Remove.
12337 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
12338 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
12339 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
12340 (rust_enum_p, rust_enum_variant): New function.
12341 (rust_underscore_fields): Remove "offset" parameter.
12342 (rust_print_enum): New function.
12343 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
12344 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
12345 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
12347 (rust_internal_print_type): New function, from rust_print_type.
12349 (rust_print_type): Call rust_internal_print_type.
12350 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
12351 Update enum handling.
12352 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
12353 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
12354 (rust_union_quirks): New functions.
12355 (process_full_comp_unit, process_full_type_unit): Call
12357 (process_structure_scope): Update rust_unions if necessary.
12359 2018-02-26 Tom Tromey <tom@tromey.com>
12361 * value.h (value_union_variant): Declare.
12362 * valops.c (value_union_variant): New function.
12363 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
12364 (struct discriminant_info): New.
12365 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
12367 (struct main_type) <flag_discriminated_union>: New field.
12369 2018-02-26 Tom Tromey <tom@tromey.com>
12371 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12372 unittests/unpack-selftests.c.
12373 * unittests/unpack-selftests.c: New file.
12374 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
12376 2018-02-26 Yao Qi <yao.qi@linaro.org>
12378 * dwarf2read.c (struct partial_die_info) <read>: New method.
12379 (read_partial_die): Remove the declaration.
12380 (load_partial_dies): Update.
12381 (partial_die_info::partial_die_info):
12382 (read_partial_die): Change it to partial_die_info::read.
12384 2018-02-26 Yao Qi <yao.qi@linaro.org>
12386 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
12387 (fixup_partial_die): Remove declaration.
12388 (scan_partial_symbols): Update.
12389 (partial_die_parent_scope): Likewise.
12390 (partial_die_full_name): Likewise.
12391 (fixup_partial_die): Change it to partial_die_info::fixup.
12393 2018-02-26 Yao Qi <yao.qi@linaro.org>
12395 * dwarf2read.c (read_partial_die): Update the declaration.
12396 (load_partial_dies): Caller update.
12397 (read_partial_die): Remove one argument abbrev_len.
12399 2018-02-26 Yao Qi <yao.qi@linaro.org>
12401 * dwarf2read.c (struct partial_die_info): Add ctor, delete
12402 assignment operator.
12403 (load_partial_dies): Use ctor and copy ctor.
12404 (read_partial_die): Update.
12405 (dwarf2_cu::find_partial_die): Use ctor.
12407 2018-02-26 Yao Qi <yao.qi@linaro.org>
12409 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
12410 (find_partial_die_in_comp_unit): Change it to
12411 dwarf2_cu::find_partial_die.
12412 (find_partial_die): Update.
12414 2018-02-26 Yao Qi <yao.qi@linaro.org>
12416 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
12419 2018-02-26 Yao Qi <yao.qi@linaro.org>
12421 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
12423 2018-02-26 Alan Hayward <alan.hayward@arm.com>
12425 * arch/amd64.h: Use common/tdesc.h.
12426 * arch/i386.c: Likewise.
12427 * arch/i386.h: Likewise.
12428 * arch/tic6x.c: Likewise.
12429 * arch/tdesc.h: Move file from here...
12430 * common/tdesc.h: ...to here.
12431 * features/aarch64-core.c: Regenerate.
12432 * features/aarch64-fpu.c: Regenerate.
12433 * features/i386/32bit-avx.c: Regenerate.
12434 * features/i386/32bit-avx512.c: Regenerate.
12435 * features/i386/32bit-core.c: Regenerate.
12436 * features/i386/32bit-linux.c: Regenerate.
12437 * features/i386/32bit-mpx.c: Regenerate.
12438 * features/i386/32bit-pkeys.c: Regenerate.
12439 * features/i386/32bit-sse.c: Regenerate.
12440 * features/i386/64bit-avx.c: Regenerate.
12441 * features/i386/64bit-avx512.c: Regenerate.
12442 * features/i386/64bit-core.c: Regenerate.
12443 * features/i386/64bit-linux.c: Regenerate.
12444 * features/i386/64bit-mpx.c: Regenerate.
12445 * features/i386/64bit-pkeys.c: Regenerate.
12446 * features/i386/64bit-segments.c: Regenerate.
12447 * features/i386/64bit-sse.c: Regenerate.
12448 * features/i386/x32-core.c: Regenerate.
12449 * features/tic6x-c6xp.c: Regenerate.
12450 * features/tic6x-core.c: Regenerate.
12451 * features/tic6x-gp.c: Regenerate.
12452 * target-descriptions.c: Use common/tdesc.h.
12453 * target-descriptions.h: Likewise.
12455 2018-02-24 Tom Tromey <tom@tromey.com>
12457 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
12458 (try_thread_db_load_from_dir, thread_db_load_search): Use
12460 (info_auto_load_libthread_db_compare): Return bool. Change
12462 (info_auto_load_libthread_db): Use std::vector, std::string.
12465 2018-02-24 Tom Tromey <tom@tromey.com>
12467 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
12469 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
12471 * gdbarch.c: Rebuild.
12472 * gdbarch.h: Rebuild.
12473 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
12474 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
12475 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
12478 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
12480 * gdbtypes.h (sect_offset): Change type to uint64_t.
12481 (sect_offset_str): New function.
12482 * dwarf2read.c (create_addrmap_from_aranges): Use
12484 (error_check_comp_unit_head): Likewise.
12485 (create_debug_type_hash_table): Likewise.
12486 (read_cutu_die_from_dwo): Likewise.
12487 (init_cutu_and_read_dies): Likewise.
12488 (init_cutu_and_read_dies_no_follow): Likewise.
12489 (process_psymtab_comp_unit_reader): Likewise.
12490 (partial_die_parent_scope): Likewise.
12491 (peek_die_abbrev): Likewise.
12492 (process_queue): Likewise.
12493 (dwarf2_physname): Likewise.
12494 (read_namespace_alias): Likewise.
12495 (read_import_statement): Likewise.
12496 (create_dwo_cu_reader): Likewise.
12497 (create_cus_hash_table): Likewise.
12498 (lookup_dwo_cutu): Likewise.
12499 (inherit_abstract_dies): Likewise.
12500 (read_func_scope): Likewise.
12501 (read_call_site_scope): Likewise.
12502 (dwarf2_add_member_fn): Likewise.
12503 (read_common_block): Likewise.
12504 (read_module_type): Likewise.
12505 (read_typedef): Likewise.
12506 (read_subrange_type): Likewise.
12507 (load_partial_dies): Likewise.
12508 (read_partial_die): Likewise.
12509 (find_partial_die): Likewise.
12510 (read_str_index): Likewise.
12511 (dwarf2_string_attr): Likewise.
12512 (build_error_marker_type): Likewise.
12513 (lookup_die_type): Likewise.
12514 (dump_die_shallow): Likewise.
12515 (follow_die_ref): Likewise.
12516 (dwarf2_fetch_die_loc_sect_off): Likewise.
12517 (dwarf2_fetch_constant_bytes): Likewise.
12518 (follow_die_sig): Likewise.
12519 (get_signatured_type): Likewise.
12520 (get_DW_AT_signature_type): Likewise.
12521 (dwarf2_find_containing_comp_unit): Likewise.
12522 (set_die_type): Likewise.
12524 2018-02-21 John Baldwin <jhb@FreeBSD.org>
12526 * arch/aarch64.c: Include "common-defs.h".
12527 * arch/amd64.c: Likewise.
12528 * arch/i386.c: Likewise.
12530 2018-02-21 Tom Tromey <tom@tromey.com>
12532 * value.h: (extract_field_op): Update.
12533 * eval.c (extract_field_op): Return a const char *.
12534 * expression.h (parse_expression_for_completion): Update.
12535 * completer.c (complete_expression): Update.
12536 (add_struct_fields): Make fieldname const.
12537 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
12538 (mark_completion_tag, parse_exp_in_context_1): Update.
12539 (parse_expression_for_completion): Change "name" to
12540 unique_xmalloc_ptr*.
12542 2018-02-21 Tom Tromey <tom@tromey.com>
12544 * infcall.c (call_function_by_hand_dummy): Use std::vector.
12546 2018-02-21 Yao Qi <yao.qi@linaro.org>
12548 * avr-tdep.c (avr_read_pc): Change parameter type to
12550 * gdbarch.sh (read_pc): Likewise.
12551 * gdbarch.c: Re-generated.
12552 * gdbarch.h: Re-generated.
12553 * hppa-tdep.c (hppa_read_pc): Change parameter type to
12555 * ia64-tdep.c (ia64_read_pc): Likewise.
12556 * mips-tdep.c (mips_read_pc): Likewise.
12557 * spu-tdep.c (spu_read_pc): Likewise.
12559 2018-02-21 Yao Qi <yao.qi@linaro.org>
12561 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
12562 * regcache-dump.c: New file.
12563 * regcache.c: Move register_dump to regcache-dump.c.
12564 (maintenance_print_registers): Likewise.
12565 (maintenance_print_raw_registers): Likewise.
12566 (maintenance_print_cooked_registers): Likewise.
12567 (maintenance_print_register_groups): Likewise.
12568 (maintenance_print_remote_registers): Likewise.
12569 (_initialize_regcache): Likewise.
12570 * regcache.h (register_dump): Moved from regcache.c.
12572 2018-02-21 Yao Qi <yao.qi@linaro.org>
12574 * regcache.c (regcache::regcache): Update.
12575 (regcache::invalidate): Move it to detached_regcache::invalidate.
12576 (get_thread_arch_aspace_regcache): Update.
12577 (regcache::raw_update): Update.
12578 (regcache::cooked_read): Remove some code.
12579 (regcache::cooked_read_value): Likewise.
12580 (regcache::raw_write): Remove assert on m_readonly_p.
12581 (regcache::raw_supply_integer): Move it to
12582 detached_regcache::raw_supply_integer.
12583 (regcache::raw_supply_zeroed): Likewise.
12584 * regcache.h (detached_regcache) <raw_supply_integer>: New
12586 <raw_supply_zeroed, invalidate>: Likewise.
12587 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
12588 <invalidate>: Likewise.
12589 <m_readonly_p>: Removed.
12591 2018-02-21 Yao Qi <yao.qi@linaro.org>
12593 * infcmd.c (get_return_value): Let stop_regs point to
12594 get_current_regcache.
12595 * regcache.c (regcache::regcache): Remove.
12596 (register_dump_reg_buffer): New class.
12597 (regcache_print): Adjust.
12598 * regcache.h (regcache): Remove constructors.
12600 2018-02-21 Yao Qi <yao.qi@linaro.org>
12602 * regcache.c (class register_dump): New class.
12603 (register_dump_regcache, register_dump_none): New class.
12604 (register_dump_remote, register_dump_groups): New class.
12605 (regcache_print): Update.
12606 * regcache.h (regcache_dump_what): Move it to regcache.c.
12607 (regcache) <dump>: Remove.
12609 2018-02-21 Yao Qi <yao.qi@linaro.org>
12611 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
12613 (jit_unwind_reg_set_impl): Call raw_supply.
12614 (jit_frame_sniffer): Use reg_buffer_rw.
12615 * record-full.c (record_full_core_regbuf): Change its type.
12616 (record_full_core_open_1): Use reg_buffer_rw.
12617 (record_full_close): Likewise.
12618 (record_full_core_fetch_registers): Use regcache->raw_supply.
12619 (record_full_core_store_registers): Likewise.
12620 * regcache.c (regcache::get_register_status): Move it to
12622 (regcache_raw_set_cached_value): Remove.
12623 (regcache::raw_set_cached_value): Remove.
12624 (regcache::raw_write): Call raw_supply.
12625 (regcache::raw_supply): Move it to reg_buffer_rw.
12626 * regcache.h (regcache_raw_set_cached_value): Remove.
12627 (reg_buffer_rw): New class.
12629 2018-02-21 Yao Qi <yao.qi@linaro.org>
12631 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
12632 readonly_detached_regcache.
12633 (dummy_frame_prev_register): Use regcache->cooked_read.
12634 * frame.c (frame_save_as_regcache): Change return type.
12635 (frame_pop): Update.
12636 * frame.h (frame_save_as_regcache): Update declaration.
12637 * inferior.h (get_infcall_suspend_state_regcache): Update
12639 * infrun.c (infcall_suspend_state) <registers>: use
12640 readonly_detached_regcache.
12641 (save_infcall_suspend_state): Don't use regcache_dup.
12642 (get_infcall_suspend_state_regcache): Change return type.
12643 * linux-fork.c (struct fork_info) <savedregs>: Change to
12644 readonly_detached_regcache.
12646 (fork_save_infrun_state): Don't use regcache_dup.
12647 (info_checkpoints_command): Adjust.
12648 * mi/mi-main.c (register_changed_p): Update declaration.
12649 (mi_cmd_data_list_changed_registers): Use
12650 readonly_detached_regcache.
12651 (register_changed_p): Change parameter type to
12652 readonly_detached_regcache.
12653 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
12654 readonly_detached_regcache.
12655 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
12656 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
12658 (regcache::save): Move it to reg_buffer.
12659 (regcache::restore): Change parameter type.
12660 (regcache_dup): Remove.
12661 * regcache.h (reg_buffer) <save>: New method.
12662 (readonly_detached_regcache): New class.
12663 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
12664 readonly_detached_regcache.
12665 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
12667 2018-02-21 Yao Qi <yao.qi@linaro.org>
12669 * frame.c (frame_save_as_regcache): Use regcache method save.
12670 (frame_pop): Use regcache method restore.
12671 * infrun.c (restore_infcall_suspend_state): Likewise.
12672 * linux-fork.c (fork_load_infrun_state): Likewise.
12673 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
12675 * regcache.c (regcache_save): Remove.
12676 (regcache::restore): More asserts.
12677 (regcache_cpy): Remove.
12678 * regcache.h (regcache_save): Remove the declaration.
12679 (regcache::restore): Move from private to public.
12680 Remove the friend declaration of regcache_cpy.
12681 (regcache_cpy): Remove declaration.
12683 2018-02-21 Yao Qi <yao.qi@linaro.org>
12685 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
12686 parameter type to 'readable_regcache *'.
12687 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12688 * arm-tdep.c (arm_neon_quad_read): Likewise.
12689 (arm_pseudo_read): Likewise.
12690 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12691 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12692 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12693 * gdbarch.c: Re-generated.
12694 * gdbarch.h: Re-generated.
12695 * gdbarch.sh (pseudo_register_read): Change parameter type to
12696 'readable_regcache *'.
12697 (pseudo_register_read_value): Likewise.
12698 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
12699 (h8300_pseudo_register_read): Likewise.
12700 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
12701 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12702 (i386_pseudo_register_read_into_value): Likewise.
12703 (i386_pseudo_register_read_value): Likewise.
12704 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
12706 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
12707 * m32c-tdep.c (m32c_raw_read): Likewise.
12708 (m32c_read_flg): Likewise.
12709 (m32c_banked_register): Likewise.
12710 (m32c_banked_read): Likewise.
12711 (m32c_sb_read): Likewise.
12712 (m32c_part_read): Likewise.
12713 (m32c_cat_read): Likewise.
12714 (m32c_r3r2r1r0_read): Likewise.
12715 (m32c_pseudo_register_read): Likewise.
12716 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12717 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12718 (mep_pseudo_cr64_read): Likewise.
12719 (mep_pseudo_register_read): Likewise.
12720 * mips-tdep.c (mips_pseudo_register_read): Likewise.
12721 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12722 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12723 * regcache.c (regcache::raw_read): Move it to readable_regcache.
12724 (regcache::cooked_read): Likewise.
12725 (regcache::cooked_read_value): Likewise.
12726 (regcache_cooked_read_signed):
12727 (regcache::cooked_read): Likewise.
12728 * regcache.h (readable_regcache): New class.
12729 (regcache): Inherit readable_regcache. Move some methods to
12731 * rl78-tdep.c (rl78_pseudo_register_read): Change
12732 parameter type to 'readable_regcache *'.
12733 * rs6000-tdep.c (do_regcache_raw_read): Remove.
12734 (e500_pseudo_register_read): Change parameter type to
12735 'readable_regcache *'.
12736 (dfp_pseudo_register_read): Likewise.
12737 (vsx_pseudo_register_read): Likewise.
12738 (efpr_pseudo_register_read): Likewise.
12739 * s390-tdep.c (s390_pseudo_register_read): Likewise.
12740 * sh-tdep.c (sh_pseudo_register_read): Likewise.
12741 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
12742 (sh64_pseudo_register_read): Likewise.
12743 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12744 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12745 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12746 (spu_pseudo_register_read): Likewise.
12747 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12748 (xtensa_pseudo_register_read): Likewise.
12750 2018-02-21 Yao Qi <yao.qi@linaro.org>
12752 * regcache.c (regcache::regcache): Call reg_buffer ctor.
12753 (regcache::arch): Move it to reg_buffer::arch.
12754 (regcache::register_buffer): Likewise.
12755 (regcache::assert_regnum): Likewise.
12756 (regcache::num_raw_registers): Likewise.
12757 * regcache.h (reg_buffer): New class.
12758 (regcache): Inherit reg_buffer.
12760 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
12762 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
12763 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
12765 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
12767 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
12769 2018-02-19 Alan Hayward <alan.hayward@arm.com>
12771 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
12772 (SFILES): Remove common/*.c files.
12773 (COMMON_OBS): Remove some *.o files built from common/*.c files.
12774 * common/common.host: Add common reference.
12775 * configure.ac: Likewise.
12776 * configure: Regenerate.
12778 2018-02-16 Yao Qi <yao.qi@linaro.org>
12780 * block.c (block_namespace_info): Inherit allocate_on_obstack.
12781 (block_initialize_namespace): Use new.
12782 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
12783 (dwarf2_free_objfile): Use delete.
12784 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
12785 (copy_type_recursive): Use new.
12786 * gdb_obstack.h (allocate_on_obstack): New.
12788 2018-02-15 Yao Qi <yao.qi@linaro.org>
12791 * inferior.c (exit_inferior_1): Reset inf->control.
12793 2018-02-15 Joel Brobecker <brobecker@adacore.com>
12795 * ada-lang.c (ada_to_fixed_value_create): Delete advance
12798 2018-02-14 Pedro Alves <palves@redhat.com>
12800 * frame-unwind.c (frame_unwind_try_unwinder): Always call
12801 frame_cleanup_after_sniffer on exception.
12803 2018-02-14 Tom Tromey <tom@tromey.com>
12805 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
12807 (solib_bfd_open): Make pathname const.
12808 * solib.c (solib_bfd_open): Make pathname const.
12809 * solib-spu.c (spu_bfd_fopen): Make name const.
12810 (spu_bfd_open): Make pathname const.
12811 * solib-darwin.c (darwin_bfd_open): Make pathname const.
12812 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
12814 2018-02-14 Tom Tromey <tom@tromey.com>
12816 * symfile.c (symfile_bfd_open): Update.
12817 * source.h (openp, source_full_path_of, find_and_open_source):
12818 Change argument type to unique_xmalloc_ptr.
12819 * source.c (openp): Take a unique_xmalloc_ptr.
12820 (source_full_path_of, find_and_open_source): Likewise.
12821 (open_source_file, symtab_to_fullname): Update.
12822 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
12823 unique_xmalloc_ptr.
12824 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
12825 (exec_file_find): Update.
12826 * psymtab.c (psymtab_to_fullname): Update.
12827 * nto-tdep.h (nto_find_and_open_solib): Update.
12828 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
12829 unique_xmalloc_ptr.
12830 * exec.c (exec_file_attach): Update.
12831 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
12832 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
12834 2018-02-14 Tom Tromey <tom@tromey.com>
12836 * solib.c: Include source.h.
12837 * nto-tdep.c: Include source.h.
12838 * mi/mi-cmd-env.c: Include source.h.
12839 * infcmd.c: Include source.h.
12840 * exec.c: Include source.h.
12841 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
12842 (add_path, directory_switch, source_path, init_source_path): Move
12844 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
12845 (add_path, directory_switch, source_path, init_source_path):
12848 2018-02-14 Tom Tromey <tom@tromey.com>
12850 * solist.h (exec_file_find, solib_find): Return
12851 unique_xmalloc_ptr.
12852 (solib_bfd_fopen): Take a const char *.
12853 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
12854 (exec_file_find, solib_find): Likewise.
12855 (solib_bfd_fopen): Do not take ownership of "pathname".
12856 (solib_bfd_open): Use unique_xmalloc_ptr.
12857 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
12858 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
12859 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
12860 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
12862 2018-02-14 Joel Brobecker <brobecker@adacore.com>
12864 * ada-lang.c (name_match_type_from_name): Remove reference to
12865 ada_name_for_lookup in function's documentation.
12866 * ada-lang.h (ada_name_for_lookup): Delete declaration.
12868 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12870 * defs.h (enum openp_flags): New enum.
12871 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
12872 Move to enum openp_flags.
12873 (openp_flags): New enum flags.
12874 (openp): Change parameter type to openp_flags.
12875 * source.c (openp): Change parameter type to openp_flags.
12876 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
12877 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
12879 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12881 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
12884 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
12886 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
12888 (class dwarf2_queue_guard): ...the destructor of this new class.
12889 (dw2_do_instantiate_symtab): Create instance of the new class
12890 dwarf2_queue_guard, remove cleanup.
12892 2018-02-09 Tom Tromey <tom@tromey.com>
12894 * source.c (find_source_lines): Don't reference past the end of
12897 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12899 * remote.c (remote_btrace_maybe_reopen): Change error message.
12900 * btrace.c (btrace_enable): Likewise.
12901 (parse_xml_btrace): Likewise.
12902 (parse_xml_btrace_conf): Likewise.
12904 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12906 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
12907 (linux_enable_pt, linux_enable_bts): Call
12908 diagnose_perf_event_open_fail.
12910 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12912 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12913 Remove parameter and change return type. Update callers. Move it.
12914 (linux_enable_bts, linux_enable_pt): Improve error message.
12915 (linux_enable_pt): Remove zero buffer size check.
12916 (linux_enable_btrace): Improve error messages. Remove NULL return
12919 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12921 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12922 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12923 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12924 (linux_supports_pt, linux_supports_btrace): Remove.
12925 (linux_enable_bts): Call cpu_supports_bts.
12926 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12927 * remote.c (remote_supports_btrace): Remove.
12928 (init_remote_ops): Remove remote_supports_btrace.
12929 * target-delegates.c: Regenerated.
12930 * target.c (target_supports_btrace): Remove.
12931 * target.h (target_ops) <to_supports_btrace>: Remove
12932 (target_supports_btrace): Remove.
12933 * x86-linux-nat.c (x86_linux_create_target): Remove
12934 linux_supports_btrace.
12936 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12938 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12940 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12941 exception and use message in own exception.
12943 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12945 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
12946 (perf_event_pt_event_type): Use gdb_file_up.
12947 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
12948 scoped_fd, and scoped_mmap.
12950 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12952 * common/scoped_mmap.h: New.
12953 * unittests/scoped_mmap-selftest.c: New.
12954 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12955 unittests/scoped_mmap-selftest.c.
12957 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12959 * common/scoped_fd.h: New.
12960 * unittests/scoped_fd-selftest.c: New.
12961 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12962 unittests/scoped_fd-selftest.c.
12964 2018-02-09 Tom Tromey <tom@tromey.com>
12966 * auto-load.c (auto_load_section_scripts): Use
12967 gdb::unique_xmalloc_ptr.
12969 2018-02-09 Tom Tromey <tom@tromey.com>
12971 * auto-load.c (execute_script_contents): Use std::string.
12973 2018-02-09 Joel Brobecker <brobecker@adacore.com>
12975 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
12976 Python function, rather than a new command.
12978 2018-02-08 Tom Tromey <tom@tromey.com>
12980 * solib.c (solib_find_1): Use std::string.
12981 (solib_bfd_fopen): Use unique_xmalloc_ptr.
12983 2018-02-08 Tom Tromey <tom@tromey.com>
12985 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
12987 2018-02-08 Tom Tromey <tom@tromey.com>
12989 * source.c (find_source_lines): Use gdb::def_vector.
12991 2018-02-08 Tom Tromey <tom@tromey.com>
12993 * macrocmd.c (struct temporary_macro_definition): New.
12994 (macro_define_command): Use temporary_macro_definition. Remove
12996 (free_macro_definition_ptr): Remove.
12998 2018-02-08 Tom Tromey <tom@tromey.com>
13000 * macroexp.c (maybe_expand): Use std::string.
13002 2018-02-08 Tom Tromey <tom@tromey.com>
13004 * macroexp.c (struct macro_buffer): Add initializers for some
13006 (init_buffer, init_shared_buffer, free_buffer)
13007 (free_buffer_return_text): Remove.
13008 (macro_buffer): New constructors.
13009 (~macro_buffer): New destructor.
13010 (macro_buffer::set_shared): New method.
13011 (macro_buffer::resize_buffer, macro_buffer::appendc)
13012 (macro_buffer::appendmem): Now methods, not free functions.
13013 (set_token, append_tokens_without_splicing, stringify)
13014 (macro_stringify): Update.
13015 (gather_arguments): Change return type. Remove argc_p argument,
13016 add args_ptr argument. Use std::vector.
13017 (substitute_args): Remove argc argument. Accept std::vector.
13018 (expand): Update. Use std::vector.
13019 (scan, macro_expand, macro_expand_next): Update.
13021 2018-02-08 Tom Tromey <tom@tromey.com>
13023 * symtab.c (default_collect_symbol_completion_matches_break_on):
13024 Use unique_xmalloc_ptr.
13025 * macroscope.h: (sal_macro_scope, user_macro_scope)
13026 (default_macro_scope): Return unique_xmalloc_ptr.
13027 * macroscope.c (sal_macro_scope, user_macro_scope)
13028 (default_macro_scope): Return unique_xmalloc_ptr.
13029 * macroexp.h (macro_expand, macro_expand_once): Return
13030 unique_xmalloc_ptr.
13031 * macroexp.c (macro_expand, macro_expand_once): Return
13032 unique_xmalloc_ptr.
13033 * macrocmd.c (macro_expand_command, macro_expand_once_command)
13034 (info_macro_command, info_macros_command): Use
13035 unique_xmalloc_ptr.
13036 * compile/compile-c-support.c (write_macro_definitions): Use
13037 unique_xmalloc_ptr.
13038 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
13040 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
13042 * value.c (value_static_field): Assign field type instead of
13043 containing type when returning an optimized out value.
13045 2018-02-06 Yao Qi <yao.qi@linaro.org>
13047 * ft32-tdep.c (ft32_read_pc): Remove.
13048 (ft32_write_pc): Remove.
13049 (ft32_gdbarch_init): Update.
13050 * m32r-tdep.c (m32r_read_pc): Remove.
13051 (m32r_gdbarch_init): Update.
13052 * mep-tdep.c (mep_read_pc): Remove.
13053 (mep_gdbarch_init): Update.
13054 * microblaze-tdep.c (microblaze_write_pc): Remove.
13055 (microblaze_gdbarch_init): Update.
13056 * mn10300-tdep.c (mn10300_read_pc): Remove.
13057 (mn10300_write_pc): Remove.
13058 (mn10300_gdbarch_init): Update.
13059 * moxie-tdep.c (moxie_read_pc): Remove.
13060 (moxie_write_pc): Remove.
13061 (moxie_gdbarch_init): Update.
13063 2018-02-06 Yao Qi <yao.qi@linaro.org>
13065 * expprint.c (print_subexp_standard): Handle
13066 OP_F77_UNDETERMINED_ARGLIST.
13067 (dump_subexp_body_standard): Likewise.
13069 2018-02-05 Alan Hayward <alan.hayward@arm.com>
13071 * target-descriptions.c (tdesc_element_visitor) Add empty
13073 (tdesc_type): Move make_gdb_type from here.
13074 (tdesc_type_builtin): Likewise.
13075 (tdesc_type_vector): Likewise.
13076 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
13077 (make_gdb_type_struct): Move from tdesc_type_with_fields.
13078 (make_gdb_type_union): Likewise.
13079 (make_gdb_type_flags): Likewise.
13080 (make_gdb_type_enum): Likewise.
13081 (make_gdb_type): New function.
13082 (tdesc_register_type): Use static make_gdb_type.
13084 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
13086 * infcmd.c (default_print_one_register_info): Align natural-format
13087 column values consistently one under another.
13088 (pad_to_column): New function.
13090 2018-02-05 Joel Brobecker <brobecker@adacore.com>
13092 * dwarf2read.c (dwarf2_physname): Move commment.
13094 2018-02-01 Leszek Swirski <leszeks@google.com>
13096 * varobj.c (varobj_formatted_print_options): Allow recursive
13097 pretty printing if pretty printing is enabled.
13099 2018-02-01 Leszek Swirski <leszeks@google.com>
13101 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
13102 names after a structop as a filename.
13104 2018-02-01 Yao Qi <yao.qi@linaro.org>
13106 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
13107 (arm_record_coproc_data_proc): Likewise.
13109 2018-02-01 Yao Qi <yao.qi@linaro.org>
13111 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
13113 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
13115 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
13116 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
13118 2018-01-31 Pedro Alves <palves@redhat.com>
13120 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
13121 * inflow.c (child_terminal_save_inferior): Wrap reference to
13122 tcgetpgrp in HAVE_TERMIOS_H.
13123 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
13125 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
13126 always iterate over all inferiors.
13127 (gdbsim_cntrl_c): Adjust.
13128 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
13130 2018-01-31 Joel Brobecker <brobecker@adacore.com>
13132 * gdbtypes.c (lookup_array_range_type): Make sure the array's
13133 index type is objfile-owned if the element type is as well.
13135 2018-01-31 Joel Brobecker <brobecker@adacore.com>
13139 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
13141 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
13142 "features/s390x-linux64.c".
13143 (_initialize_s390_linux_tdep): Remove initialization of tdescs
13144 s390_linux32 and s390x_linux64.
13145 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
13147 * s390-tdep.c: Include "features/s390-linux32.c" and
13148 "features/s390x-linux64.c".
13149 (s390_tdesc_valid): Add check for tdesc_has_registers.
13150 (s390_gdbarch_init): Make sure there is always a valid tdesc.
13151 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
13152 tdesc_s390x_linux64.
13153 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
13154 tdesc_s390x_linux64 to...
13155 * s390-tdep.h: ...here.
13157 2018-01-30 Pedro Alves <palves@redhat.com>
13160 * config.in, configure: Regenerate.
13161 * configure.ac: Check for getpgid.
13162 * go32-nat.c (go32_pass_ctrlc): New.
13163 (go32_target): Install it.
13164 * inf-child.c (inf_child_target): Install
13165 child_terminal_save_inferior, child_pass_ctrlc and
13167 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
13168 (inf_ptrace_target): No longer install it.
13169 * infcmd.c (interrupt_target_1): Adjust.
13170 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
13171 (child_interrupt): Declare.
13172 (inferior::terminal_state): New.
13173 * inflow.c (struct terminal_info): Update comments.
13174 (inferior_process_group): Delete.
13175 (terminal_is_ours): Delete.
13176 (gdb_tty_state): New.
13177 (child_terminal_init): Adjust.
13178 (is_gdb_terminal, sharing_input_terminal_1)
13179 (sharing_input_terminal): New functions.
13180 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
13181 Set the process's actual process group in the foreground if
13182 possible. Handle is_ours_for_output/is_ours distinction. Don't
13183 mark terminal as the inferior's if not sharing GDB's terminal.
13184 Don't check attach_flag.
13185 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
13186 pass down a target_terminal_state.
13187 (child_terminal_save_inferior): New, factored out from ...
13188 (child_terminal_ours_1): ... this. Handle
13189 target_terminal_state::is_ours_for_output.
13190 (child_interrupt, child_pass_ctrlc): New.
13191 (inflow_inferior_exit): Clear the inferior's terminal_state.
13192 (copy_terminal_info): Copy the inferior's terminal state.
13193 (_initialize_inflow): Remove reference to terminal_is_ours.
13194 * inflow.h (inferior_process_group): Delete.
13195 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
13196 * procfs.c (procfs_target): Don't install procfs_interrupt.
13197 (procfs_interrupt): Delete.
13198 * remote.c (remote_serial_quit_handler): Adjust.
13199 (remote_interrupt): Remove ptid parameter. Adjust.
13200 * target-delegates.c: Regenerate.
13201 * target.c: Include "terminal.h".
13202 (target_terminal::terminal_state): Rename to ...
13203 (target_terminal::m_terminal_state): ... this.
13204 (target_terminal::init): Adjust.
13205 (target_terminal::inferior): Adjust to per-inferior
13207 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
13208 (target_terminal::ours, target_terminal::ours_for_output): Use
13209 target_terminal_is_ours_kind.
13210 (target_interrupt): Remove ptid parameter. Adjust.
13211 (default_target_pass_ctrlc): Adjust.
13212 * target.h (target_ops::to_terminal_save_inferior): New field.
13213 (target_ops::to_interrupt): Remove ptid_t parameter.
13214 (target_interrupt): Remove ptid_t parameter. Update comment.
13215 (target_pass_ctrlc): Update comment.
13216 * target/target.h (target_terminal_state): New scoped enum,
13217 factored out of ...
13218 (target_terminal::terminal_state): ... here.
13219 (target_terminal::inferior): Update comments.
13220 (target_terminal::restore_inferior): New.
13221 (target_terminal::is_inferior, target_terminal::is_ours)
13222 (target_terminal::is_ours_for_output): Adjust.
13223 (target_terminal::scoped_restore_terminal_state): Adjust to
13224 rename, and call restore_inferior() instead of inferior().
13225 (target_terminal::scoped_restore_terminal_state::m_state): Change
13227 (target_terminal::terminal_state): Rename to ...
13228 (target_terminal::m_terminal_state): ... this and change type.
13230 2018-01-30 Pedro Alves <palves@redhat.com>
13232 * linux-nat.c (wait_for_signal): New function.
13233 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
13235 (async_terminal_is_ours)
13236 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
13237 (linux_nat_add_target): Don't override
13238 to_terminal_inferior/to_terminal_ours.
13240 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
13242 * remote.c (remote_follow_fork): Don't call "detach_inferior".
13244 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
13246 * dwarf2read.c (free_dwo_files): Add forward-declaration.
13247 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
13248 dwarf2_per_objfile_free here.
13249 (dwarf2_per_objfile_free): Remove.
13250 (_initialize_dwarf2_read): Don't register
13251 dwarf2_per_objfile_free as a registry cleanup.
13253 2018-01-27 Eli Zaretskii <eliz@gnu.org>
13255 Avoid compilation errors in MinGW native builds
13257 The error is triggered by including python-internal.h, and the
13260 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
13261 from build-gnulib/import/math.h:27,
13262 from d:/usr/Python26/include/pyport.h:235,
13263 from d:/usr/Python26/include/Python.h:58,
13264 from python/python-internal.h:94,
13265 from python/py-arch.c:24:
13266 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
13270 This happens because Python headers define 'hypot' to expand t
13271 '_hypot' in the Windows builds.
13272 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
13273 'hypoth'. This avoids a compilation error.
13275 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13277 * MAINTAINERS (Write After Approval): Fix ordering.
13279 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13281 * MAINTAINERS (Write After Approval): Add Alan Hayward.
13283 2018-01-26 Alan Modra <amodra@gmail.com>
13285 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
13286 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
13287 Remove nop. Make const. Comment.
13288 (powerpc32_plt_stub_so_2): New.
13289 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
13290 Correct count. Update uses.
13291 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
13292 Move common code reading PLT entry word. Correct
13293 powerpc32_plt_stub PLT address calculation.
13294 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
13295 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
13296 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
13297 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
13298 (ppc64_standard_linkage8): Likewise.
13299 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
13300 Correct insns description.
13301 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
13303 2018-01-24 Pedro Alves <palves@redhat.com>
13305 GCC PR libstdc++/83906
13306 * gdbtypes.c (operator==(const dynamic_prop &,
13307 const dynamic_prop &)): New.
13308 (operator==(const range_bounds &, const range_bounds &)): New.
13309 (check_types_equal): Use them instead of memcmp.
13310 * gdbtypes.h (operator==(const dynamic_prop &,
13311 const dynamic_prop &)): Declare.
13312 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
13313 (operator==(const range_bounds &, const range_bounds &)): Declare.
13314 (operator!=(const range_bounds &, const range_bounds &)): Declare.
13316 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13318 * s390-linux-tdep.c (s390_record_address_mask)
13319 (s390_record_calc_disp_common, s390_record_calc_disp)
13320 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13321 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13322 (s390_process_record): Move to s390-tdep.c.
13323 (s390_linux_init_abi_any): Adjust.
13324 * s390-tdep.c (s390_record_address_mask)
13325 (s390_record_calc_disp_common, s390_record_calc_disp)
13326 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13327 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13328 (s390_process_record): Moved from s390-linux-tdep.c
13329 (s390_gdbarch_init): Adjust.
13331 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13333 * s390-linux-nat.c (s390-tdep.h): New include.
13334 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
13335 (HFILES_NO_SRCDIR): Add s390-tdep.h.
13336 (ALLDEPFILES): Add s390-tdep.c.
13337 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
13338 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
13339 * s390-tdep.h: ...this. New file.
13340 * s390-linux-tdep.c (s390-tdep.h): New include.
13341 (_initialize_s390_tdep): Rename to...
13342 (_initialize_s390_linux_tdep): ...this and adjust.
13343 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
13344 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
13346 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
13347 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
13348 (s390_is_partial_instruction, s390_software_single_step)
13349 (is_non_branch_ril, s390_displaced_step_copy_insn)
13350 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
13351 (s390_prologue_data, s390_addr, s390_store, s390_load)
13352 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
13353 (s390_register_call_saved, s390_guess_tracepoint_registers)
13354 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
13355 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
13356 (s390_pseudo_register_name, s390_pseudo_register_type)
13357 (s390_pseudo_register_read, s390_pseudo_register_write)
13358 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
13359 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
13360 (s390_addr_bits_remove, s390_address_class_type_flags)
13361 (s390_address_class_type_flags_to_name)
13362 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
13363 (s390_function_arg_float, s390_function_arg_vector)
13364 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
13365 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
13366 (s390_frame_align, s390_register_return_value, s390_return_value)
13367 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
13368 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
13369 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
13370 (s390_trad_frame_prev_register, s390_unwind_cache)
13371 (s390_prologue_frame_unwind_cache)
13372 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
13373 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
13374 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
13375 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
13376 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
13377 (s390_frame_base_address, s390_local_base_address)
13378 (s390_frame_base, s390_gcc_target_options)
13379 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
13380 (s390_validate_reg_range, s390_tdesc_valid)
13381 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
13382 * s390-tdep.c: ...this. New file.
13384 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13386 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
13387 (s390_process_record, s390_gdbarch_tdep_alloc)
13388 (s390_linux_init_abi_any): Use/set new hook.
13390 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13392 * s390-linux-tdep.c (osabi.h): New include.
13393 (s390_linux_init_abi_31, s390_linux_init_abi_64)
13394 (s390_linux_init_abi_any): New functions.
13395 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
13397 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13399 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
13400 tdesc_has_registers check
13402 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13404 * s390-linux-tdep.c (s390_tdesc_valid): New function.
13405 (s390_validate_reg_range): New macro.
13406 (s390_gdbarch_init): Adjust.
13408 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13410 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
13411 (s390_gdbarch_tdep_alloc): Adjust.
13412 (s390_gdbarch_init): Adjust.
13414 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13416 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
13417 <have_tdb>: Change type to bool.
13418 (s390_gdbarch_tdep_alloc): Adjust.
13419 (s390_gdbarch_init): Adjust.
13421 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13423 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
13424 (gdbarch_tdep) <have_upper, have_vx>: New fields.
13425 (s390_gdbarch_tdep_alloc): New function.
13426 (s390_gdbarch_init): Allocate tdep at start and use its fields
13427 instead of separate variables.
13429 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13431 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
13432 when looking for cached gdbarch and add comment for remaining.
13434 2018-01-22 Pedro Alves <palves@redhat.com>
13435 Sergio Durigan Junior <sergiodj@redhat.com>
13437 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
13440 2018-01-22 Maciej W. Rozycki <macro@mips.com>
13442 * MAINTAINERS: Update my company e-mail address.
13444 2018-01-22 Yao Qi <yao.qi@linaro.org>
13446 * regcache.c (cooked_write_test): New function.
13447 (_initialize_regcache): Register the test.
13449 2018-01-22 Yao Qi <yao.qi@linaro.org>
13451 * ia64-tdep.c (ia64_pseudo_register_read): Call
13452 regcache->cooked_read instead of regcache_cooked_read_unsigned.
13453 * m32c-tdep.c (m32c_cat_read): Likewise.
13454 (m32c_r3r2r1r0_read): Likewise.
13455 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
13456 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
13458 2018-01-22 Yao Qi <yao.qi@linaro.org>
13460 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
13461 method raw_read instead of regcache_raw_read.
13462 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
13463 * arm-tdep.c (arm_neon_quad_read): Likewise.
13464 * avr-tdep.c (avr_pseudo_register_read): Likewise.
13465 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
13466 * frv-tdep.c (frv_pseudo_register_read): Likewise.
13467 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
13468 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
13469 (i386_pseudo_register_read_into_value): Likewise.
13470 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
13471 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
13472 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
13473 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
13474 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
13475 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
13476 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
13477 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
13478 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
13480 2018-01-22 Yao Qi <yao.qi@linaro.org>
13482 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
13483 * configure.tgt: Remove target mt.
13484 * mt-tdep.c: Remove.
13485 * regcache.c (cooked_read_test): Remove the check for mt.
13487 2018-01-22 Yao Qi <yao.qi@linaro.org>
13489 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
13490 instead of gdbarch_pseudo_register_read_value.
13492 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13494 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
13497 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13499 * linespec.c (create_sals_line_offset): Remove code that preserved
13500 the symtab_and_line's line number.
13502 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13504 * varobj.c (varobj_create): Don't set valid_block when creating a
13507 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13509 * varobj.c (varobj_create): Remove out of date comment.
13511 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13514 * ada-exp.y (write_var_from_sym): Pass extra parameter when
13515 updating innermost block.
13516 * parse.c (innermost_block_tracker::update): Take extra type
13517 parameter, and check types match before updating innermost block.
13518 (write_dollar_variable): Update innermost block for registers.
13519 * parser-defs.h (enum innermost_block_tracker_type): New enum.
13520 (innermost_block_tracker::innermost_block_tracker): Initialise
13522 (innermost_block_tracker::reset): Take type parameter.
13523 (innermost_block_tracker::update): Take type parameter, and pass
13524 type through as needed.
13525 (innermost_block_tracker::m_types): New member.
13526 * varobj.c (varobj_create): Pass type when reseting innermost
13529 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13531 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
13532 * ada-lang.c (resolve_subexp): Likewise.
13533 * breakpoint.c (set_breakpoint_condition) Likewise.
13534 (watch_command_1) Likewise.
13535 * c-exp.y (variable): Likewise.
13536 * d-exp.y (PrimaryExpression): Likewise.
13537 * f-exp.y (variable): Likewise.
13538 * go-exp.y (variable): Likewise.
13539 * m2-exp.y (variable): Likewise.
13540 * objfiles.c (objfile::~objfile): Likewise.
13541 * p-exp.y (variable): Likewise.
13542 * parse.c (innermost_block): Change type.
13543 * parser-defs.h (class innermost_block_tracker): New.
13544 (innermost_block): Change to innermost_block_tracker.
13545 * printcmd.c (display_command): Switch to innermost_block API.
13546 (do_one_display): Likewise.
13547 * rust-exp.y (do_one_display): Likewise.
13548 * symfile.c (clear_symtab_users): Likewise.
13549 * varobj.c (varobj_create): Switch to innermost_block API, replace
13550 use of innermost_block with block stored on varobj object.
13552 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13554 * expression.h (innermost_block): Remove declaration.
13555 * varobj.c: Add 'parser-defs.h' include.
13557 2018-01-19 Tom Tromey <tom@tromey.com>
13559 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
13560 symbols in the static and global blocks.
13562 2018-01-19 James Clarke <jrtc27@jrtc27.com>
13564 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
13565 gdb_ptrace.h, and move including gdb_wait.h ...
13566 * nat/linux-ptrace.h: ... to here.
13568 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13570 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
13571 inf_ptrace_detach_success.
13572 (inf_ptrace_detach_success): Add inferior parameter, use it
13573 instead of inferior_ptid, pass it to detach_inferior.
13574 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
13576 * inferior.c (detach_inferior): Add overload that takes an
13578 * inferior.h (detach_inferior): Likewise.
13579 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
13580 use inferior_ptid, adjust call to inf_ptrace_detach_success.
13581 * linux-thread-db.c (thread_db_detach): Use inf parameter.
13583 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13585 * target.h (struct target_ops) <to_detach>: Add inferior
13587 (target_detach): Likewise.
13588 * target.c (dispose_inferior): Pass inferior down.
13589 (target_detach): Pass inferior down. Assert that it is equal to
13590 the current inferior.
13591 * aix-thread.c (aix_thread_detach): Pass inferior down.
13592 * corefile.c (core_file_command): Pass current_inferior() down.
13593 * corelow.c (core_detach): Add inferior parameter.
13594 * darwin-nat.c (darwin_detach): Likewise.
13595 * gnu-nat.c (gnu_detach): Likewise.
13596 * inf-ptrace.c (inf_ptrace_detach): Likewise.
13597 * infcmd.c (detach_command): Pass current_inferior() down to
13599 * infrun.c (follow_fork_inferior): Pass parent_inf to
13601 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
13603 * linux-nat.c (linux_nat_detach): Add inferior parameter.
13604 * linux-thread-db.c (thread_db_detach): Likewise.
13605 * nto-procfs.c (procfs_detach): Likewise.
13606 * procfs.c (procfs_detach): Likewise.
13607 * record.c (record_detach): Likewise.
13608 * record.h (struct inferior): Forward-declare.
13609 (record_detach): Add inferior parameter.
13610 * remote-sim.c (gdbsim_detach): Likewise.
13611 * remote.c (remote_detach_1): Likewise.
13612 (remote_detach): Likewise.
13613 (extended_remote_detach): Likewise.
13614 * sol-thread.c (sol_thread_detach): Likewise.
13615 * target-debug.h (target_debug_print_inferior_p): New macro.
13616 * target-delegates.c: Re-generate.
13617 * top.c (kill_or_detach): Pass inferior down to target_detach.
13618 * windows-nat.c (windows_detach): Add inferior parameter.
13620 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13622 * target.h (struct target_ops) <to_detach>: Remove args
13624 (target_detach): Likewise.
13625 * target.c (dispose_inferior): Adjust.
13626 (target_detach): Remove args parameter, adjust.
13627 * aix-thread.c (aix_thread_detach): Adjust.
13628 * corefile.c (core_file_command): Adjust.
13629 * corelow.c (core_detach): Adjust.
13630 * darwin-nat.c (darwin_detach): Adjust.
13631 * gnu-nat.c (gnu_detach): Adjust.
13632 * inf-ptrace.c (inf_ptrace_detach): Adjust.
13633 * infcmd.c (detach_command): Adjust
13634 * infrun.c (follow_fork_inferior): Adjust.
13635 (handle_vfork_child_exec_or_exit): Adjust.
13636 * linux-fork.c (linux_fork_detach): Remove args parameter.
13637 * linux-fork.h (linux_fork_detach): Likewise.
13638 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
13639 * linux-thread-db.c (thread_db_detach): Likewise.
13640 * nto-procfs.c (procfs_detach): Likewise.
13641 * procfs.c (procfs_detach): Likewise.
13642 (do_detach): Remove signo parameter.
13643 * record.c (record_detach): Remove args parameter.
13644 * record.h (record_detach): Likewise.
13645 * remote-sim.c (gdbsim_detach): Likewise.
13646 * remote.c (remote_detach_1): Likewise.
13647 (remote_detach): Likewise.
13648 (extended_remote_detach): Likewise.
13649 * sol-thread.c (sol_thread_detach): Likewise.
13650 * target-delegates.c: Re-generate.
13651 * top.c (struct qt_args) <args>: Remove field.
13652 (kill_or_detach): Don't pass args.
13653 (quit_force): Don't set args.
13654 * windows-nat.c (windows_detach): Remove args parameter.
13656 2018-01-19 Yao Qi <yao.qi@linaro.org>
13658 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
13659 (arm_linux_init_abi): Install it.
13661 2018-01-19 Yao Qi <yao.qi@linaro.org>
13663 * osabi.c (gdb_osabi_names): Extend the regexp for
13664 arm-linux-gnueabihf.
13666 2018-01-18 Yao Qi <yao.qi@linaro.org>
13668 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
13670 (abbrev_table::add_abbrev): Update.
13671 (abbrev_table::lookup_abbrev): Update.
13673 2018-01-18 Yao Qi <yao.qi@linaro.org>
13675 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
13677 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
13679 * compile/compile.c (compile_to_object): Convert "triplet_rx"
13682 2018-01-17 Tom Tromey <tom@tromey.com>
13684 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
13686 2018-01-17 Tom Tromey <tom@tromey.com>
13688 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
13689 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
13690 (create_array_type_with_stride): Update.
13691 * dwarf2read.c (set_die_type): Update.
13693 2018-01-17 Tom Tromey <tom@tromey.com>
13695 * dwarf2read.c (delayed_method_info): Remove typedef.
13696 (dwarf2_cu::method_info): Now a std::vector.
13697 (add_to_method_list): Update.
13698 (free_delayed_list): Remove.
13699 (compute_delayed_physnames): Update.
13700 (process_full_comp_unit, process_full_type_unit): Clear the method
13701 list. Remove cleanups.
13702 (psymtab_include_file_name): Add name_holder parameter. Use
13703 unique_xmalloc_ptr.
13704 (dwarf_decode_lines): Update.
13706 2018-01-17 Tom Tromey <tom@tromey.com>
13707 Simon Marchi <simon.marchi@ericsson.com>
13709 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
13710 (dwarf2_per_objfile::free_cached_comp_units)
13711 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13712 (init_cutu_and_read_dies_no_follow): Update.
13713 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
13714 (dwarf2_cu::~dwarf2_cu): New.
13715 (free_heap_comp_unit, free_stack_comp_unit): Remove.
13716 (age_cached_comp_units, free_one_cached_comp_unit): Update.
13718 2018-01-17 Tom Tromey <tom@tromey.com>
13719 Simon Marchi <simon.marchi@ericsson.com>
13721 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
13722 (struct die_reader_specs) <abbrev_table>: New member.
13723 (struct abbrev_table): Add constructor.
13724 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
13725 <abbrev_obstack>: Now an auto_obstack.
13726 (abbrev_table_up): New typedef.
13727 (init_cu_die_reader): Add abbrev_table parameter.
13728 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
13729 Add result_dwo_abbrev_table.
13730 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13731 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
13733 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
13735 (skip_children): Update.
13736 (abbrev_table::alloc_abbrev): Rename from
13737 abbrev_table_alloc_abbrev.
13738 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
13739 (abbrev_table::lookup_abbrev): Rename from
13740 abbrev_table_lookup_abbrev.
13741 (abbrev_table_read_table): Return abbrev_table_up.
13742 (abbrev_table_free, abbrev_table_free_cleanup)
13743 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
13744 (load_partial_dies): Update.
13746 2018-01-17 Tom Tromey <tom@tromey.com>
13748 * dwarf2read.c (dwarf2_compute_name): Update comment.
13749 (read_func_scope, read_variable): Update.
13750 (new_symbol): Remove.
13751 (new_symbol_full): Rename to new_symbol.
13753 2018-01-17 Mike Gulick <mgulick@mathworks.com>
13756 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
13757 a warning instead of throwing an error, set section size to 0 and return
13759 * gdb_bfd.h (gdb_bfd_map_section): Update description.
13761 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13763 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
13765 (linux_ptrace_attach_fail_reason_string): Likewise.
13766 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
13768 (linux_ptrace_attach_fail_reason_string): Likewise.
13769 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
13771 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13773 * linux-nat.c (linux_nat_attach): Remove xstrdup.
13775 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
13778 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
13779 checking for fs_base/gs_base fields in struct user_regs_struct.
13780 * configure: Regenerate.
13782 2018-01-17 Yao Qi <yao.qi@linaro.org>
13784 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
13786 (aarch64_linux_init_abi): Install it to gdbarch hook
13787 gcc_target_options.
13789 2018-01-15 Pedro Alves <palves@redhat.com>
13791 * common/signals-state-save-restore.c
13792 (save_original_signals_state): Fix typos.
13794 2017-01-12 Tom Tromey <tom@tromey.com>
13795 Sergio Durigan Junior <sergiodj@redhat.com>
13797 * Makefile.in (install-only): Install gdb-add-index.
13799 2018-01-12 John Baldwin <jhb@FreeBSD.org>
13801 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
13803 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
13805 * infrun.c (keep_going_pass_signal): Clear step-over info when
13806 insert_breakpoints fails.
13808 2018-01-11 Pedro Alves <palves@redhat.com>
13811 * infrun.c (resume): Rename to ...
13812 (resume_1): ... this.
13813 (resume): Reimplement as wrapper around resume_1.
13815 2018-01-11 Pedro Alves <palves@redhat.com>
13818 * remote.c (remote_parse_stop_reply): Default to the last-set
13819 general thread instead of to 'magic_null_ptid'.
13821 2018-01-10 Pedro Alves <palves@redhat.com>
13823 * language.h (language_get_symbol_name_matcher): Rename ...
13824 (get_symbol_name_matcher): ... this.
13825 * language.c (language_get_symbol_name_matcher): Ditto.
13826 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
13829 2018-01-10 Pedro Alves <palves@redhat.com>
13833 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
13834 Adjust to use language_get_symbol_name_matcher instead of
13835 language_defn::la_get_symbol_name_matcher.
13836 * language.c (language_get_symbol_name_matcher): If in Ada mode
13837 and the lookup name is a verbatim match, return Ada's matcher.
13838 * language.h (language_get_symbol_name_matcher): Adjust comment.
13839 (ada_lookup_name_info::verbatim_p):: New method.
13841 2018-01-10 Pedro Alves <palves@redhat.com>
13844 * ada-lang.c (ada_collect_symbol_completion_matches): If the
13845 minsym's language is language_auto or language_cplus, pass down
13846 language_ada instead.
13847 * symtab.c (compare_symbol_name): Don't frob symbol language here.
13849 2018-01-10 Pedro Alves <palves@redhat.com>
13852 * minsyms.c (linkage_name_str): New function.
13853 (iterate_over_minimal_symbols): Use it.
13855 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13857 * NEWS: Document that 'info proc' now works on FreeBSD.
13859 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13861 * configure.ac: Check for kinfo_getfile in libutil.
13862 * configure: Regenerate.
13863 * config.in: Regenerate.
13864 * fbsd-nat.c: Include "fbsd-tdep.h".
13865 (fbsd_fetch_cmdline): New.
13866 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
13867 rather than calling error.
13868 (fbsd_info_proc): New.
13869 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
13870 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
13871 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
13873 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13875 * fbsd-nat.c (struct free_deleter): Remove.
13876 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
13878 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13880 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
13881 NULL for an empty pathname.
13883 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13885 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
13886 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
13887 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
13888 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
13889 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
13890 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
13891 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
13892 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
13893 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
13894 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
13895 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
13896 (fbsd_core_fetch_timeval, fbsd_print_sigset)
13897 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
13898 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
13899 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
13901 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
13903 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
13904 (gnu_xfer_auxv): New function.
13905 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
13906 TARGET_OBJECT_AUXV.
13908 2018-01-08 Yao Qi <yao.qi@linaro.org>
13909 Simon Marchi <simon.marchi@ericsson.com>
13911 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13913 (COMMON_OBS): Remove selftest.o.
13914 * configure.ac: Append selftest-arch.c and common/selftest.c to
13915 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13916 * configure: Re-generated.
13917 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13919 (maintenance_info_selftests): Likewise.
13921 2018-01-08 Xavier Roirand <roirand@adacore.com>
13923 * ada-valprint.c (val_print_packed_array_elements): Use
13924 proper number of elements when printing an array indexed
13925 by an enumeration type.
13927 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13929 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13930 (dw2_get_file_names_reader): Adjust.
13931 (lookup_dwo_signatured_type): Adjust.
13932 (lookup_dwp_signatured_type): Adjust.
13933 (lookup_signatured_type): Adjust.
13934 (create_type_unit_group): Adjust.
13935 (get_type_unit_group): Adjust.
13936 (process_psymtab_comp_unit_reader): Adjust.
13937 (build_type_psymtabs_reader): Adjust.
13938 (scan_partial_symbols): Adjust.
13939 (add_partial_symbol): Adjust.
13940 (add_partial_subprogram): Adjust.
13941 (peek_die_abbrev): Adjust.
13942 (fixup_go_packaging): Adjust.
13943 (process_imported_unit_die): Adjust.
13944 (dwarf2_compute_name): Adjust.
13945 (dwarf2_physname): Adjust.
13946 (read_import_statement): Adjust.
13947 (handle_DW_AT_stmt_list): Adjust.
13948 (read_file_scope): Adjust.
13949 (read_func_scope): Adjust.
13950 (read_lexical_block_scope): Adjust.
13951 (read_call_site_scope): Adjust.
13952 (read_variable): Adjust.
13953 (dwarf2_rnglists_process): Adjust.
13954 (dwarf2_ranges_process): Adjust.
13955 (dwarf2_ranges_read): Adjust.
13956 (dwarf2_get_pc_bounds): Adjust.
13957 (dwarf2_record_block_ranges): Adjust.
13958 (dwarf2_add_field): Adjust.
13959 (dwarf2_add_member_fn): Adjust.
13960 (read_structure_type): Adjust.
13961 (process_structure_scope): Adjust.
13962 (read_enumeration_type): Adjust.
13963 (read_array_type): Adjust.
13964 (mark_common_block_symbol_computed): Adjust.
13965 (read_common_block): Adjust.
13966 (read_namespace_type): Adjust.
13967 (read_namespace): Adjust.
13968 (read_module_type): Adjust.
13969 (read_tag_pointer_type): Adjust.
13970 (read_tag_ptr_to_member_type): Adjust.
13971 (read_tag_string_type): Adjust.
13972 (read_subroutine_type): Adjust.
13973 (read_typedef): Adjust.
13974 (read_base_type): Adjust.
13975 (attr_to_dynamic_prop): Adjust.
13976 (read_subrange_type): Adjust.
13977 (read_unspecified_type): Adjust.
13978 (dwarf2_read_abbrevs): Adjust.
13979 (load_partial_dies): Adjust.
13980 (read_partial_die): Adjust.
13981 (find_partial_die): Adjust.
13982 (guess_partial_die_structure_name): Adjust.
13983 (fixup_partial_die): Adjust.
13984 (read_attribute_value): Adjust.
13985 (read_addr_index): Adjust.
13986 (read_addr_index_from_leb128): Adjust.
13987 (read_str_index): Adjust.
13988 (dwarf2_string_attr): Adjust.
13989 (get_debug_line_section): Adjust.
13990 (dwarf_decode_line_header): Adjust.
13991 (lnp_state_machine::check_line_address): Adjust.
13992 (dwarf_decode_lines_1): Adjust.
13993 (dwarf_decode_lines): Adjust.
13994 (dwarf2_start_symtab): Adjust.
13995 (var_decode_location): Adjust.
13996 (new_symbol_full): Adjust.
13997 (dwarf2_const_value_data): Adjust.
13998 (dwarf2_const_value_attr): Adjust.
13999 (dwarf2_const_value): Adjust.
14000 (die_type): Adjust.
14001 (die_containing_type): Adjust.
14002 (build_error_marker_type): Adjust.
14003 (lookup_die_type): Adjust.
14004 (guess_full_die_structure_name): Adjust.
14005 (anonymous_struct_prefix): Adjust.
14006 (determine_prefix): Adjust.
14007 (dwarf2_name): Adjust.
14008 (follow_die_ref_or_sig): Adjust.
14009 (follow_die_offset): Adjust.
14010 (follow_die_ref): Adjust.
14011 (follow_die_sig_1): Adjust.
14012 (follow_die_sig): Adjust.
14013 (get_signatured_type): Adjust.
14014 (get_DW_AT_signature_type): Adjust.
14015 (decode_locdesc): Adjust.
14016 (dwarf_decode_macros): Adjust.
14017 (cu_debug_loc_section): Adjust.
14018 (fill_in_loclist_baton): Adjust.
14019 (dwarf2_symbol_mark_computed): Adjust.
14020 (init_one_comp_unit): Don't assign
14021 dwarf2_cu::dwarf2_per_objfile.
14022 (set_die_type): Adjust.
14024 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14026 * dwarf2read.c (struct mapped_debug_names): Add constructor.
14027 <dwarf2_per_objfile>: New field.
14028 (dwarf2_per_objfile): Remove global.
14029 (get_dwarf2_per_objfile): New function.
14030 (set_dwarf2_per_objfile): New function.
14031 (dwarf2_build_psymtabs_hard): Change objfile parameter to
14032 dwarf2_per_objfile.
14033 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14034 (read_abbrev_offset): Likewise.
14035 (read_indirect_string): Likewise.
14036 (read_indirect_line_string): Likewise.
14037 (read_indirect_string_at_offset): Likewise.
14038 (read_indirect_string_from_dwz): Likewise.
14039 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14040 dwarf2_per_objfile.
14041 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14042 (create_all_comp_units): Change objfile parameter to
14043 dwarf2_per_objfile.
14044 (create_all_type_units): Likewise.
14045 (process_queue): Add dwarf2_per_objfile parameter.
14046 (read_and_check_comp_unit_head): Likewise.
14047 (lookup_dwo_unit_in_dwp): Likewise.
14048 (get_dwp_file): Likewise.
14049 (process_cu_includes): Likewise.
14050 (struct free_dwo_file_cleanup_data): New struct.
14051 (dwarf2_has_info): Use get_dwarf2_per_objfile and
14052 set_dwarf2_per_objfile.
14053 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
14054 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
14055 context, adjust calls.
14056 (dw2_instantiate_symtab): Likewise.
14057 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
14058 (dw2_get_cu): Likewise.
14059 (create_cu_from_index_list): Change objfile parameter to
14060 dwarf2_per_objfile.
14061 (create_cus_from_index_list): Get dwarf2_per_objfile from
14062 context, adjust calls.
14063 (create_cus_from_index): Likewise.
14064 (create_signatured_type_table_from_index): Change objfile
14065 parameter to dwarf2_per_objfile.
14066 (create_signatured_type_table_from_debug_names): Change objfile
14067 parameter to dwarf2_per_objfile.
14068 (create_addrmap_from_index): Likewise.
14069 (create_addrmap_from_aranges): Likewise.
14070 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
14071 (dw2_setup): Remove.
14072 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
14074 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
14075 get_dwarf2_per_objfile.
14076 (dw2_forget_cached_source_info): Likewise.
14077 (dw2_map_symtabs_matching_filename): Likewise.
14078 (struct dw2_symtab_iterator) <index>: Remove.
14079 <dwarf2_per_objfile>: New field.
14080 (dw2_symtab_iter_init): Replace index parameter with
14081 dwarf2_per_objfile.
14082 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
14083 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
14084 (dw2_print_stats): Likewise.
14085 (dw2_dump): Likewise.
14086 (dw2_expand_symtabs_for_function): Likewise.
14087 (dw2_expand_all_symtabs): Likewise.
14088 (dw2_expand_symtabs_with_fullname): Likewise.
14089 (dw2_expand_marked_cus): Replace index and objfile parameters
14090 with dwarf2_per_objfile.
14091 (dw_expand_symtabs_matching_file_matcher): Add
14092 dwarf2_per_objfile parameter and adjust calls.
14093 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
14095 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
14096 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
14098 (create_cus_from_debug_names_list): Replace objfile parameter
14099 with dwarf2_per_objfile and adjust calls.
14100 (create_cus_from_debug_names): Likewise.
14101 (dwarf2_read_debug_names): Likewise.
14102 (mapped_debug_names::namei_to_name): Adjust call.
14103 (dw2_debug_names_iterator::next): Likewise.
14104 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
14105 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
14106 (dw2_debug_names_dump): Likewise.
14107 (dw2_debug_names_expand_symtabs_for_function): Likewise.
14108 (dw2_debug_names_expand_symtabs_matching): Likewise.
14109 (dwarf2_initialize_objfile): Likewise.
14110 (dwarf2_build_psymtabs): Likewise.
14111 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
14113 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
14114 (read_and_check_comp_unit_head): Likewise.
14115 (read_abbrev_offset): Likewise.
14116 (create_debug_type_hash_table): Likewise.
14117 (create_debug_types_hash_table): Likewise.
14118 (create_all_type_units): Replace objfile parameter with
14119 dwarf2_per_objfile.
14120 (add_type_unit): Add dwarf2_per_objfile parameter.
14121 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
14122 with dwarf2_per_objfile.
14123 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
14124 (lookup_dwp_signatured_type): Likewise.
14125 (lookup_signatured_type): Likewise.
14126 (read_cutu_die_from_dwo): Likewise.
14127 (init_tu_and_read_dwo_dies): Likewise.
14128 (init_cutu_and_read_dies): Likewise.
14129 (init_cutu_and_read_dies_no_follow): Likewise.
14130 (allocate_type_unit_groups_table): Add objfile parameter.
14131 (create_type_unit_group): Use dwarf2_per_objfile from cu.
14132 (get_type_unit_group): Likewise.
14133 (process_psymtab_comp_unit): Update call.
14134 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
14135 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
14136 (print_tu_stats): Likewise.
14137 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
14138 in void* parameter.
14139 (build_type_psymtabs): Change objfile parameter to
14140 dwarf2_per_objfile.
14141 (process_skeletonless_type_unit): Use dwarf2_per_objfile
14142 passed in void* parameter.
14143 (process_skeletonless_type_units): Change objfile parameter to
14144 dwarf2_per_objfile.
14145 (set_partial_user): Likewise.
14146 (dwarf2_build_psymtabs_hard): Likewise.
14147 (read_comp_units_from_section): Likewise.
14148 (create_all_comp_units): Likewise.
14149 (scan_partial_symbols): Update calls.
14150 (add_partial_symbol): Likewise.
14151 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
14152 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
14153 (process_queue): Add dwarf2_per_objfile parameter.
14154 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
14155 (compute_compunit_symtab_includes): Likewise.
14156 (process_cu_includes): Add dwarf2_per_objfile parameter.
14157 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
14158 (process_full_type_unit): Likewise.
14159 (process_imported_unit_die): Update call.
14160 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
14161 (read_file_scope): Likewise.
14162 (allocate_dwo_file_hash_table): Add objfile parameter.
14163 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
14164 (create_cus_hash_table): Likewise.
14165 (create_dwp_hash_table): Likewise.
14166 (create_dwo_unit_in_dwp_v1): Likewise.
14167 (create_dwp_v2_section): Likewise.
14168 (create_dwo_unit_in_dwp_v2): Likewise.
14169 (lookup_dwo_unit_in_dwp): Likewise.
14170 (try_open_dwop_file): Likewise.
14171 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
14172 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
14173 cleanup to include a reference to dwarf2_per_objfile.
14174 (open_dwp_file): Add dwarf2_per_objfile parameter.
14175 (open_and_init_dwp_file): Likewise.
14176 (get_dwp_file): Likewise.
14177 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
14178 (queue_and_load_all_dwo_tus): Update call.
14179 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
14181 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
14182 (dwarf2_ranges_process): Likewise.
14183 (dwarf2_get_pc_bounds): Likewise.
14184 (mark_common_block_symbol_computed): Likewise.
14185 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14186 (dwarf2_read_abbrevs): Update call.
14187 (read_partial_die): Use dwarf2_per_objfile from cu.
14188 (find_partial_die): Likewise.
14189 (fixup_partial_die): Likewise.
14190 (read_attribute_value): Likewise.
14191 (read_indirect_string_at_offset_from): Add objfile parameter.
14192 (read_indirect_string_at_offset): Add dwarf2_per_objfile
14194 (read_indirect_string_from_dwz): Add objfile parameter.
14195 (read_indirect_string): Add objfile parameter.
14196 (read_addr_index_1): Add dwarf2_per_objfile parameter.
14197 (read_addr_index): Use dwarf2_per_objfile from cu.
14198 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
14200 (read_str_index): Use dwarf2_per_objfile from cu.
14201 (get_debug_line_section): Likewise.
14202 (read_formatted_entries): Add dwarf2_per_objfile parameter.
14203 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
14204 (new_symbol_full): Use dwarf2_per_objfile from cu.
14205 (build_error_marker_type): Likewise.
14206 (lookup_die_type): Likewise.
14207 (determine_prefix): Likewise.
14208 (follow_die_offset): Likewise.
14209 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
14210 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
14211 (dwarf2_fetch_die_type_sect_off): Likewise.
14212 (dwarf2_get_die_type): Likewise.
14213 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
14214 (get_signatured_type): Likewise.
14215 (get_DW_AT_signature_type): Likewise.
14216 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
14217 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
14218 (cu_debug_loc_section): Likewise.
14219 (fill_in_loclist_baton): Likewise.
14220 (dwarf2_symbol_mark_computed): Likewise.
14221 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14222 dwarf2_per_objfile.
14223 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
14225 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14226 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
14227 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
14228 (set_die_type): Use dwarf2_free_objfile from cu.
14229 (get_die_type_at_offset): Likewise.
14230 (dwarf2_per_objfile_free): Don't assign global variable.
14231 (debug_names) <constructor>: Add dwarf2_per_objfile
14232 parameter, update m_debugstrlookup construction.
14233 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
14235 <m_dwarf2_per_objfile>: New field.
14236 <lookup>: Use m_dwarf2_per_objfile.
14237 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
14238 (psyms_seen_size): Likewise.
14239 (write_gdbindex): Replace objfile parameter with
14240 dwarf2_per_objfile.
14241 (write_debug_names): Likewise.
14242 (write_psymtabs_to_index): Likewise.
14243 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
14246 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14248 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
14249 <dwarf2_per_objfile>: New field.
14250 (struct dwarf2_per_cu_data) <objfile>: Remove.
14251 <dwarf2_per_objfile>: New field.
14252 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
14254 (create_signatured_type_table_from_index): Likewise.
14255 (create_debug_type_hash_table): Likewise.
14256 (fill_in_sig_entry_from_dwo_entry): Likewise.
14257 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
14258 (create_type_unit_group): Assign dwarf2_per_objfile instead of
14260 (create_partial_symtab): Access objfile through
14261 dwarf2_per_objfile.
14262 (process_psymtab_comp_unit_reader): Likewise.
14263 (read_comp_units_from_section): Likewise.
14264 (scan_partial_symbols): Likewise.
14265 (add_partial_symbol): Likewise.
14266 (add_partial_subprogram): Likewise.
14267 (peek_die_abbrev): Likewise.
14268 (fixup_go_packaging): Likewise.
14269 (process_full_comp_unit): Likewise.
14270 (process_full_type_unit): Likewise.
14271 (process_imported_unit_die): Likewise.
14272 (dwarf2_compute_name): Likewise.
14273 (dwarf2_physname): Likewise.
14274 (read_import_statement): Likewise.
14275 (create_cus_hash_table): Assign dwarf2_physname instead of
14277 (read_func_scope): Access objfile through dwarf2_per_objfile.
14278 (read_lexical_block_scope): Likewise.
14279 (read_call_site_scope): Likewise.
14280 (read_variable): Likewise.
14281 (dwarf2_rnglists_process): Likewise.
14282 (dwarf2_ranges_process): Likewise.
14283 (dwarf2_ranges_read): Likewise.
14284 (dwarf2_record_block_ranges): Likewise.
14285 (dwarf2_add_field): Likewise.
14286 (dwarf2_add_member_fn): Likewise.
14287 (read_structure_type): Likewise.
14288 (process_structure_scope): Likewise.
14289 (read_enumeration_type): Likewise.
14290 (read_array_type): Likewise.
14291 (read_common_block): Likewise.
14292 (read_namespace_type): Likewise.
14293 (read_namespace): Likewise.
14294 (read_module_type): Likewise.
14295 (read_tag_pointer_type): Likewise.
14296 (read_tag_ptr_to_member_type): Likewise.
14297 (read_tag_string_type): Likewise.
14298 (read_subroutine_type): Likewise.
14299 (read_typedef): Likewise.
14300 (read_base_type): Likewise.
14301 (attr_to_dynamic_prop): Likewise.
14302 (read_subrange_type): Likewise.
14303 (read_unspecified_type): Likewise.
14304 (load_partial_dies): Likewise.
14305 (read_partial_die): Likewise.
14306 (find_partial_die): Likewise.
14307 (guess_partial_die_structure_name): Likewise.
14308 (fixup_partial_die): Likewise.
14309 (read_attribute_value): Likewise.
14310 (read_addr_index_from_leb128): Likewise.
14311 (dwarf2_read_addr_index): Likewise.
14312 (dwarf2_string_attr): Likewise.
14313 (lnp_state_machine::check_line_address): Likewise.
14314 (dwarf_decode_lines_1): Likewise.
14315 (dwarf_decode_lines): Likewise.
14316 (dwarf2_start_symtab): Likewise.
14317 (var_decode_location): Likewise.
14318 (new_symbol_full): Likewise.
14319 (dwarf2_const_value_data): Likewise.
14320 (dwarf2_const_value_attr): Likewise.
14321 (dwarf2_const_value): Likewise.
14322 (die_type): Likewise.
14323 (die_containing_type): Likewise.
14324 (lookup_die_type): Likewise.
14325 (guess_full_die_structure_name): Likewise.
14326 (anonymous_struct_prefix): Likewise.
14327 (dwarf2_name): Likewise.
14328 (follow_die_ref_or_sig): Likewise.
14329 (follow_die_offset): Likewise.
14330 (follow_die_ref): Likewise.
14331 (dwarf2_fetch_die_loc_sect_off): Likewise.
14332 (dwarf2_fetch_constant_bytes): Likewise.
14333 (dwarf2_fetch_die_type_sect_off): Likewise.
14334 (dwarf2_get_die_type): Likewise.
14335 (follow_die_sig): Likewise.
14336 (decode_locdesc): Likewise.
14337 (dwarf2_per_cu_objfile): Likewise.
14338 (dwarf2_per_cu_text_offset): Likewise.
14339 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
14341 (set_die_type): Access objfile through
14342 dwarf2_per_objfile.
14344 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14346 * valprint.c (converted_character_d): Remove typedef.
14347 (DEF_VEC_O (converted_character_d)): Remove.
14348 (count_next_character): Use std::vector.
14349 (print_converted_chars_to_obstack): Likewise.
14350 (generic_printstr): Likewise.
14352 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14354 * xml-support.h (struct gdb_xml_value): Add constructor.
14355 <value>: Change type to unique_xmalloc_ptr.
14356 (gdb_xml_value_s): Remove typedef.
14357 (DEF_VEC_O (gdb_xml_value_s)): Remove.
14358 (gdb_xml_element_start_handler): Change parameter type to
14360 (xml_find_attribute): Likewise.
14361 * xml-support.c (xml_find_attribute): Change parameter type to
14362 std::vector and adjust.
14363 (gdb_xml_values_cleanup): Remove.
14364 (gdb_xml_parser::start_element): Adjust to std::vector.
14365 (xinclude_start_include): Change paraeter type to std::vector
14367 * btrace.c (check_xml_btrace_version): Likewise.
14368 (parse_xml_btrace_block): Likewise.
14369 (parse_xml_btrace_pt_config_cpu): Likewise.
14370 (parse_xml_btrace_pt): Likewise.
14371 (parse_xml_btrace_conf_bts): Likewise.
14372 (parse_xml_btrace_conf_pt): Likewise.
14373 * memory-map.c (memory_map_start_memory): Likewise.
14374 (memory_map_start_property): Likewise.
14375 * osdata.c (osdata_start_osdata): Likewise.
14376 (osdata_start_item): Likewise.
14377 (osdata_start_column): Likewise.
14378 * remote.c (start_thread): Likewise.
14379 * solib-aix.c (library_list_start_library): Likewise.
14380 (library_list_start_list): Likewise.
14381 * solib-svr4.c (library_list_start_library): Likewise.
14382 (svr4_library_list_start_list): Likewise.
14383 * solib-target.c (library_list_start_segment): Likewise.
14384 (library_list_start_section): Likewise.
14385 (library_list_start_library): Likewise.
14386 (library_list_start_list): Likewise.
14387 * tracepoint.c (traceframe_info_start_memory): Likewise.
14388 (traceframe_info_start_tvar): Likewise.
14389 * xml-syscall.c (syscall_start_syscall): Likewise.
14390 * xml-tdesc.c (tdesc_start_target): Likewise.
14391 (tdesc_start_feature): Likewise.
14392 (tdesc_start_reg): Likewise.
14393 (tdesc_start_union): Likewise.
14394 (tdesc_start_struct): Likewise.
14395 (tdesc_start_flags): Likewise.
14396 (tdesc_start_enum): Likewise.
14397 (tdesc_start_field): Likewise.
14398 (tdesc_start_enum_value): Likewise.
14399 (tdesc_start_vector): Likewise.
14401 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14403 * extension.h (struct xmethod_worker) <clone>: Remove.
14404 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
14406 (python_xmethod_worker::clone): Remove.
14407 * valops.c (find_overload_match): Use std::move instead of
14410 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14412 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
14413 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
14414 <free_xmethod_worker_data>: Remove.
14415 <get_matching_xmethod_workers>: Chance VEC to std::vector.
14416 <get_xmethod_arg_types>: Remove.
14417 <get_xmethod_result_type>: Remove.
14418 <invoke_xmethod>: Remove.
14419 * extension.c (new_xmethod_worker): Remove.
14420 (clone_xmethod_worker): Remove.
14421 (get_matching_xmethod_workers): Return void, pass std::vector by
14423 (get_xmethod_arg_types): Rename to...
14424 (xmethod_worker::get_arg_types): ... this, and adjust.
14425 (get_xmethod_result_type): Rename to...
14426 (xmethod_worker::get_result_type): ... this, and adjust.
14427 (invoke_xmethod): Remove.
14428 (free_xmethod_worker): Remove.
14429 (free_xmethod_worker_vec): Remove.
14430 * extension.h (enum ext_lang_rc): Move here from
14432 (struct xmethod_worker): Add constructor and destructor.
14435 <invoke, clone, do_get_result_type, do_get_arg_types>: New
14436 virtual pure methods.
14437 <get_arg_types, get_result_type>: New methods.
14438 (xmethod_worker_ptr): Remove typedef.
14439 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
14440 (xmethod_worker_vec): Remove typedef.
14441 (xmethod_worker_up): New typedef.
14442 (invoke_xmethod): Remove.
14443 (clone_xmethod_worker): Remove.
14444 (free_xmethod_worker): Remove.
14445 (free_xmethod_worker_vec): Remove.
14446 (get_xmethod_arg_types): Remove.
14447 (get_xmethod_result_type): Remove.
14448 * valops.c (find_method_list): Use std::vector, don't use
14449 intermediate vector.
14450 (value_find_oload_method_list): Use std::vector.
14451 (find_overload_match): Use std::vector.
14452 (find_oload_champ): Use std::vector.
14453 * value.c (value_free): Use operator delete.
14454 (value_of_xmethod): Rename to...
14455 (value_from_xmethod): ... this. Don't assign
14456 xmethod_worker::value, take rvalue-reference.
14457 (result_type_of_xmethod): Adjust.
14458 (call_xmethod): Adjust.
14459 * value.h: Include extension.h.
14460 (struct xmethod_worker): Don't forward-declare.
14461 (value_of_xmethod): Rename to...
14462 (value_from_xmethod): ... this, take rvalue-reference.
14463 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
14464 (struct python_xmethod_worker): ... this, add constructor and
14466 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
14467 (gdbpy_free_xmethod_worker_data): Rename to...
14468 (python_xmethod_worker::~python_xmethod_worker): ... this and
14470 (gdbpy_clone_xmethod_worker_data): Rename to...
14471 (python_xmethod_worker::clone): ... this and adjust.
14472 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
14474 (gdbpy_get_xmethod_arg_types): Rename to...
14475 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
14476 (gdbpy_get_xmethod_result_type): Rename to...
14477 (python_xmethod_worker::do_get_result_type): ... this and
14479 (gdbpy_invoke_xmethod): Rename to...
14480 (python_xmethod_worker::invoke): ... this and adjust.
14481 (new_python_xmethod_worker): Rename to...
14482 (python_xmethod_worker::python_xmethod_worker): ... this and
14484 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
14486 (gdbpy_free_xmethod_worker_data): Remove.
14487 (gdbpy_get_matching_xmethod_workers): Use std::vector.
14488 (gdbpy_get_xmethod_arg_types): Remove.
14489 (gdbpy_get_xmethod_result_type): Remove.
14490 (gdbpy_invoke_xmethod): Remove.
14491 * python/python.c (python_extension_ops): Remove obsolete
14494 2018-01-05 Pedro Alves <palves@redhat.com>
14497 * common/signals-state-save-restore.c
14498 (save_original_signals_state): New parameter 'quiet'. Warn if we
14499 find a custom handler preinstalled, instead of internal erroring.
14500 But only warn if !quiet.
14501 * common/signals-state-save-restore.h
14502 (save_original_signals_state): New parameter 'quiet'.
14503 * main.c (captured_main_1): Move save_original_signals_state call
14504 after option handling, and pass QUIET.
14506 2018-01-05 Pedro Alves <palves@redhat.com>
14508 * spu-tdep.c (spu_catch_start): Pass
14509 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
14511 2018-01-05 Pedro Alves <palves@redhat.com>
14514 * ada-lang.c (literal_symbol_name_matcher): New function.
14515 (ada_get_symbol_name_matcher): Use it for
14516 symbol_name_match_type::SEARCH_NAME.
14517 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
14518 it down instead of assuming symbol_name_match_type::FULL.
14519 * block.h (block_lookup_symbol): New parameter 'match_type'.
14520 * c-valprint.c (print_unpacked_pointer): Use
14521 lookup_symbol_search_name instead of lookup_symbol.
14522 * compile/compile-object-load.c (get_out_value_type): Pass down
14523 symbol_name_match_type::SEARCH_NAME.
14524 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
14525 symbol_name_match_type::FULL.
14526 * cp-support.c (cp_get_symbol_name_matcher): Handle
14527 symbol_name_match_type::SEARCH_NAME.
14528 * infrun.c (insert_exception_resume_breakpoint): Use
14529 lookup_symbol_search_name.
14530 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
14531 * psymtab.c (maintenance_check_psymtabs): Use
14532 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
14533 * stack.c (print_frame_args): Use lookup_symbol_search_name and
14534 SYMBOL_SEARCH_NAME.
14535 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
14536 if symbol_name_match_type::SEARCH_NAME.
14537 (lookup_symbol_in_language): Pass down
14538 symbol_name_match_type::FULL.
14539 (lookup_symbol_search_name): New.
14540 (lookup_language_this): Pass down
14541 symbol_name_match_type::SEARCH_NAME.
14542 (lookup_symbol_aux, lookup_local_symbol): New parameter
14543 'match_type'. Pass it down.
14544 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
14545 (lookup_symbol_search_name): New declaration.
14546 (lookup_symbol_in_block): New 'match_type' parameter.
14548 2018-01-05 Pedro Alves <palves@redhat.com>
14551 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
14553 (ada_lookup_symbol): Reimplement in terms of
14554 ada_lookup_symbol_list, bits factored out from
14555 ada_lookup_encoded_symbol.
14557 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14559 * ada-exp.y (write_object_renaming): When subscripting an array
14560 using a symbol as the index, pass the block in call to
14561 ada_lookup_encoded_symbol when looking that symbol up.
14563 2018-01-05 Jerome Guitton <guitton@adacore.com>
14565 * ada-lang.c (ada_array_length): Use ada_index_type instead of
14568 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14570 * ada-lang.c (ada_to_fixed_value_create): Add handling of
14571 the case where VALUE_LVAL (val0) is not lval_memory.
14573 2018-01-05 Xavier Roirand <roirand@adacore.com>
14575 * ada-valprint.c (print_optional_low_bound): Handle
14576 character-indexed array printing like boolean-indexed array
14579 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14581 * NEWS: Create a new section for the next release branch.
14582 Rename the section of the current branch, now that it has
14585 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14587 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
14588 * version.in: Bump version to 8.1.50.DATE-git.
14590 2018-01-03 Xavier Roirand <roirand@adacore.com>
14592 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
14594 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
14596 (default_exception_support_info) <catch_handlers_sym>: Add field.
14597 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
14598 (ada_exception_name_addr_1): Add "catch handlers" handling.
14599 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
14600 Update all callers.
14601 (create_excep_cond_exprs) <ex>: Add parameter.
14602 (re_set_exception): Update create_excep_cond_exprs call.
14603 (print_it_exception, print_one_exception, print_mention_exception)
14604 (print_recreate_exception): Add "catch handler" handling.
14605 (allocate_location_catch_handlers, re_set_catch_handlers)
14606 (check_status_catch_handlers, print_it_catch_handlers)
14607 (print_one_catch_handlers, print_mention_catch_handlers)
14608 (print_recreate_catch_handlers): New function.
14609 (catch_handlers_breakpoint_ops): New variable.
14610 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
14611 Add parameter. Add "catch handler" handling.
14612 (ada_exception_sym_name, ada_exception_breakpoint_ops):
14613 Add "catch handler" handling.
14614 (ada_exception_catchpoint_cond_string): Add "catch handler"
14616 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
14618 (catch_ada_handlers_command): New function.
14619 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
14620 operations structure.
14621 (_initialize_ada_language): Add "catch handlers" command entry.
14622 * NEWS: Document "catch handlers" feature.
14624 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14626 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
14627 account when creating the array type of the slice.
14628 (ada_value_slice): Likewise.
14630 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14632 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
14634 (create_array_type_with_stride): Add byte_stride_prop parameter.
14635 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
14636 New parameter. Update all callers in this file.
14637 (array_type_has_dynamic_stride): New function.
14638 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
14639 of arrays with dynamic byte strides.
14640 * dwarf2read.c (read_array_type): Add support for dynamic
14641 DW_AT_byte_stride attributes.
14643 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14645 * dwarf2read.c (read_unspecified_type): Treat
14646 DW_TAG_enumeration_type DIEs from Ada units as stubs.
14648 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14650 Update copyright year range in all GDB files.
14652 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
14654 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
14655 and gdb/testsuite/gdb.base/step-line.c.
14657 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14659 * copyright.py (main): Dump the contents of
14660 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
14661 even if BY_HAND is empty.
14663 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14665 * top.c (print_gdb_version): Update Copyright year in version
14668 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14670 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
14672 For older changes see ChangeLog-2017.
14678 version-control: never