1 2018-03-08 Tom Tromey <tom@tromey.com>
3 * source.c (get_filename_and_charpos): Use scoped_fd.
4 * nto-procfs.c (procfs_open_1): Use scoped_fd.
5 (procfs_pidlist): Likewise.
6 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
7 (iterate_over_mappings): Likewise.
9 2018-03-08 Tom Tromey <tom@tromey.com>
11 * infcall.c (struct call_return_meta_info)
12 <stack_temporaries_enabled>: Remove.
13 (get_call_return_value, call_function_by_hand_dummy): Update.
14 * thread.c (disable_thread_stack_temporaries): Remove.
15 (enable_thread_stack_temporaries): Remove.
16 (thread_stack_temporaries_enabled_p): Return bool.
17 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
18 (get_last_thread_stack_temporary): Update.
19 * eval.c (evaluate_subexp): Update.
20 * gdbthread.h (class enable_thread_stack_temporaries): Now a
21 class, not a function.
22 (value_ptr, value_vec): Remove typedefs.
23 (class thread_info) <stack_temporaries_enabled>: Now bool.
24 <stack_temporaries>: Now a std::vector.
25 (thread_stack_temporaries_enabled_p)
26 (value_in_thread_stack_temporaries): Return bool.
28 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
30 * remote.c (putpkt_binary): Fix omitted bytes reporting.
31 (getpkt_or_notif_sane_1): Likewise.
33 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
35 * build-id.c (build_id_to_debug_bfd): Use std::string.
37 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
39 * build-id.c (find_separate_debug_file_by_buildid): Return
41 * build-id.h (find_separate_debug_file_by_buildid): Return
43 * coffread.c (coff_symfile_read): Adjust to std::string.
44 * elfread.c (elf_symfile_read): Adjust to std::string.
45 * symfile.c (separate_debug_file_exists): Change parameter to
47 (find_separate_debug_file): Return std::string.
48 (find_separate_debug_file_by_debuglink): Return std::string.
49 * symfile.h (find_separate_debug_file_by_debuglink): Return
52 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
54 * common/xml-utils.c (xml_escape_text): Move code to...
55 (xml_escape_text_append): ... this new function.
56 * common/xml-utils.h (xml_escape_text_append): New declaration.
57 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
59 (_initialize_xml_utils): register test_xml_escape_text_append as
62 2018-03-07 Alan Hayward <alan.hayward@arm.com>
64 * defs.h: Remove MAX_REGISTER_SIZE.
65 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
67 * python/py-unwind.c (pyuw_sniffer): Likewise.
69 2018-03-07 Tom Tromey <tom@tromey.com>
71 * linux-tdep.c (linux_info_proc): Update.
72 * target.h (struct target_ops) <to_fileio_readlink>: Return
74 (target_fileio_readlink): Return optional<string>.
75 * remote.c (remote_hostio_readlink): Return optional<string>.
76 * inf-child.c (inf_child_fileio_readlink): Return
78 * target.c (target_fileio_readlink): Return optional<string>.
80 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
82 * regcache.c (cooked_read_test): Add riscv to the list of
83 architectures that have a save_reggroup.
85 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
87 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
88 value is not a dynamic class object.
90 2018-03-06 Tom Tromey <tom@tromey.com>
92 * rust-exp.y: Formatting fixes.
94 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
96 * riscv-tdep.c (riscv_register_name): Remove target description
98 (riscv_gdbarch_init): Remove target description check.
100 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
102 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
104 * riscv-tdep.h: Likewise.
106 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
108 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
109 (riscv_pseudo_register_write): Delete.
110 (riscv_gdbarch_init): Remove all use of pseudo registers.
112 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
114 * record-btrace.c (btrace_print_lines): Replace cleanup
115 parameter with RAII equivalents.
116 (btrace_insn_history): Replace cleanup with RAII equivalents.
117 * ui-out.h (make_cleanup_ui_out_list_begin_end,
118 make_cleanup_ui_out_tuple_begin_end): Remove.
119 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
120 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
121 make_cleanup_ui_out_list_begin_end): Remove.
123 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
125 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
126 parameter types to std::vector. Use bool.
127 (record_btrace_wait): Replace VEC(tp_t) with
128 std::vector<thread_info *>.
129 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
131 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
133 * record-btrace.c (record_btrace_disable_callback): Remove.
134 (struct scoped_btrace_disable): New.
135 (record_btrace_open): Use scoped_btrace_disable.
137 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
139 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
140 reading values from registers.
142 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
144 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
147 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
149 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
150 change parameter type. Use GDB's print functions, and use
151 core_addr_to_string where appropriate.
152 (riscv_push_dummy_call): Use core_addr_to_string where
153 appropriate, update call to riscv_print_arg_location, and reindent
155 (riscv_return_value): Update call to riscv_print_arg_location.
157 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
158 Tim Newsome <tim@sifive.com>
159 Albert Ou <a0u@eecs.berkeley.edu>
160 Darius Rad <darius@bluespec.com>
162 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
163 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
164 (ALLDEPFILES): Add riscv-tdep.c
165 * configure.tgt: Add riscv support.
166 * riscv-tdep.c: New file.
167 * riscv-tdep.h: New file.
168 * NEWS: Mention new target.
169 * MAINTAINERS: Add entry for riscv.
171 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
173 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
174 fields within aggregates.
176 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
178 * record-btrace.c (btrace_print_lines): Change type of flags to
179 gdb_disassembly_flags.
181 2018-03-04 John Baldwin <jhb@FreeBSD.org>
183 * fbsd-nat.c: Include "inf-ptrace.h".
184 (USE_SIGTRAP_SIGINFO): Conditionally define.
185 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
186 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
187 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
189 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
191 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
193 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
194 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
195 "supports_stopped_by_hw_breakpoint" target methods.
197 2018-03-04 John Baldwin <jhb@FreeBSD.org>
199 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
200 * fbsd-nat.c (debug_fbsd_nat): New variable.
201 (show_fbsd_nat_debug): New function.
202 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
203 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
205 2018-03-04 John Baldwin <jhb@FreeBSD.org>
207 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
208 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
210 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
211 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
214 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
216 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
217 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
219 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
221 * charset.c (struct charset_vector): New.
222 (charsets): Change type to charset_vector.
223 (find_charset_names): Adjust.
225 (_initialize_charset): Adjust.
227 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
229 * progspace.h (struct program_space) <deleted_solibs>: Change
230 type to std::vector<std::string>.
231 * progspace.c (clear_program_space_solib_cache): Adjust.
232 * breakpoint.c (print_solib_event): Adjust.
233 (check_status_catch_solib): Adjust.
234 * solib.c (update_solib_list): Adjust.
235 * ui-out.h (class ui_out) <field_string>: New overload.
236 * ui-out.c (ui_out::field_string): New overload.
238 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
240 * progspace.h (struct program_space): Add constructor and
241 destructor, initialize fields.
242 (add_program_space): Remove.
243 * progspace.c (add_program_space): Rename to...
244 (program_space::program_space): ... this.
245 (release_program_space): Rename to...
246 (program_space::~program_space): ... this.
247 (delete_program_space): Use delete to delete program_space.
248 (initialize_progspace): Use new to allocate program_space.
249 * inferior.c (add_inferior_with_spaces): Likewise.
250 (clone_inferior_command): Likewise.
251 * infrun.c (follow_fork_inferior): Likewise.
252 (handle_vfork_child_exec_or_exit): Likewise.
254 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
256 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
257 (delim_string_to_char_ptr_vec): Return std::vector of
258 gdb::unique_xmalloc_ptr.
259 (dirnames_to_char_ptr_vec_append): Take std::vector of
260 gdb::unique_xmalloc_ptr.
261 (dirnames_to_char_ptr_vec): Return std::vector of
262 gdb::unique_xmalloc_ptr.
263 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
264 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
265 (delim_string_to_char_ptr_vec): Return an std::vector of
266 gdb::unique_xmalloc_ptr, adjust the code.
267 (dirnames_to_char_ptr_vec_append): Take an std::vector of
268 gdb::unique_xmalloc_ptr, adjust the code.
269 (dirnames_to_char_ptr_vec): Return an std::vector of
270 gdb::unique_xmalloc_ptr, adjust the code.
271 * auto-load.c (auto_load_safe_path_vec): Change type to
272 std::vector of gdb::unique_xmalloc_ptr.
273 (auto_load_expand_dir_vars): Return an std::vector of
274 gdb::unique_xmalloc_ptr, adjust the code.
275 (auto_load_safe_path_vec_update): Adjust.
276 (filename_is_in_auto_load_safe_path_vec): Adjust.
277 (auto_load_objfile_script_1): Adjust.
278 * build-id.c (build_id_to_debug_bfd): Adjust.
279 * linux-thread-db.c (thread_db_load_search): Adjust.
280 * source.c (add_path): Adjust.
282 * symfile.c (find_separate_debug_file): Adjust.
283 * utils.c (do_free_char_ptr_vec): Remove.
284 (make_cleanup_free_char_ptr_vec): Remove.
286 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
289 * common/pathstuff.c: Conditionally include "<windows.h>".
291 2018-03-01 Georg Sauthoff <mail@georg.so>
294 * gcore.in: Quote variables and switch interpreter to bash.
296 2018-03-01 Tom Tromey <tom@tromey.com>
298 * dwarf2read.c (alloc_discriminant_info): Fix default_index
299 assertion. Add assertion for discriminant_index.
300 (quirk_rust_enum): Use correct base type name in univariant case.
302 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
304 * record.c (get_call_history_modifiers): Return a
306 (cmd_record_call_history): Adjust.
307 * record-btrace.c (record_btrace_call_history): Adjust.
308 (record_btrace_call_history_range): Adjust.
309 (record_btrace_call_history_from): Adjust.
310 * target-debug.h (target_debug_print_record_print_flags): New.
311 * target-delegates.c: Re-generate.
312 * target.c (target_call_history): Change flags type.
313 (target_call_history_from): Likewise.
314 (target_call_history_range): Likewise.
315 * target.h (struct target_ops) <target_call_history>: Likewise.
316 (target_call_history_from): Likewise.
317 (target_call_history_range): Likewise.
319 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
320 Simon Marchi <simon.marchi@polymtl.ca>
322 * common/common-utils.c: Include "sys/stat.h".
323 (is_regular_file): Move here from "source.c"; change return
325 * common/common-utils.h (is_regular_file): New prototype.
326 * common/pathstuff.c (contains_dir_separator): New function.
327 * common/pathstuff.h (contains_dir_separator): New prototype.
328 * source.c: Don't include "sys/stat.h".
329 (is_regular_file): Move to "common/common-utils.c".
331 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
333 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
334 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
335 * auto-load.c: Include "common/pathstuff.h".
336 * common/common-def.h (current_directory): Move here.
337 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
339 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
341 * common/pathstuff.c: New file.
342 * common/pathstuff.h: New file.
343 * compile/compile.c: Include "common/pathstuff.h".
344 * defs.h (current_directory): Move to "common/common-defs.h".
345 * dwarf2read.c: Include "common/pathstuff.h".
347 * guile/scm-safe-call.c: Likewise.
348 * linux-thread-db.c: Likewise.
350 * nto-tdep.c: Likewise.
351 * objfiles.c: Likewise.
352 * source.c: Likewise.
353 * symtab.c: Likewise.
354 * utils.c: Include "common/pathstuff.h".
355 (gdb_realpath): Move to "common/pathstuff.c".
356 (gdb_realpath_keepfile): Likewise.
357 (gdb_abspath): Likewise.
358 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
359 (gdb_realpath_keepfile): Likewise.
360 (gdb_abspath): Likewise.
362 2018-02-28 John Baldwin <jhb@FreeBSD.org>
364 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
365 wildcard process pid for super_resume for kernels with a
368 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
370 * compile/compile.c (get_args): Add additional comments
373 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
374 Tom Tromey <tom@tromey.com>
376 * target.h (memory_write_request_s): Remove typedef. Don't define
378 (target_write_memory_blocks): Change argument to std::vector.
379 (struct memory_write_request): Add constructor.
380 * target-memory.c (compare_block_starting_address): Return bool.
381 Change argument types.
382 (claim_memory): Change arguments to use std::vector.
383 (split_regular_and_flash_blocks, blocks_to_erase)
384 (compute_garbled_blocks): Likewise.
385 (cleanup_request_data, cleanup_write_requests_vector): Remove.
386 (target_write_memory_blocks): Change argument to std::vector.
387 * symfile.c (struct load_section_data): Add constructor and
388 destructor. Use std::vector for "requests".
389 (struct load_progress_data): Add initializers.
390 (load_section_callback): Update. Use "new".
391 (clear_memory_write_data): Remove.
392 (generic_load): Update.
394 2018-02-27 Alan Hayward <alan.hayward@arm.com>
396 * arch/aarch64.h: Use common/tdesc.h.
398 2018-02-26 Maciej W. Rozycki <macro@mips.com>
400 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
401 architecture with a 64-bit ABI.
403 2018-02-26 Maciej W. Rozycki <macro@mips.com>
405 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
406 ahead of target description loading.
408 2018-02-26 Tom Tromey <tom@tromey.com>
410 * stack.c (backtrace_command_1): Update.
411 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
413 * python/py-framefilter.c (py_print_frame)
414 (gdbpy_apply_frame_filter): Change type of "flags".
415 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
417 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
418 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
419 * extension.h (enum frame_filter_flag): Rename from
421 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
422 (apply_ext_lang_frame_filter): Change type of "flags".
423 * extension.c (apply_ext_lang_frame_filter): Change type of
425 * extension-priv.h (struct extension_language_ops)
426 <apply_frame_filter>: Change type of "flags".
428 2018-02-26 Tom Tromey <tom@tromey.com>
431 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
432 off-by-one in py_end computation.
433 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
435 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
438 2018-02-26 Tom Tromey <tom@tromey.com>
440 * dwarf2read.c (struct variant_field): New.
441 (struct nextfield) <variant>: New field.
442 (dwarf2_add_field): Handle DW_TAG_variant_part.
443 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
445 (read_structure_type): Handle DW_TAG_variant_part.
446 (handle_struct_member_die): New function, extracted from
447 process_structure_scope. Handle DW_TAG_variant.
448 (process_structure_scope): Handle discriminated unions. Call
449 handle_struct_member_die.
451 2018-02-26 Tom Tromey <tom@tromey.com>
453 * rust-lang.h (rust_last_path_segment): Declare.
454 * rust-lang.c (rust_last_path_segment): Now public. Change
456 (struct disr_info): Remove.
457 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
458 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
459 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
460 (rust_enum_p, rust_enum_variant): New function.
461 (rust_underscore_fields): Remove "offset" parameter.
462 (rust_print_enum): New function.
463 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
464 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
465 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
467 (rust_internal_print_type): New function, from rust_print_type.
469 (rust_print_type): Call rust_internal_print_type.
470 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
471 Update enum handling.
472 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
473 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
474 (rust_union_quirks): New functions.
475 (process_full_comp_unit, process_full_type_unit): Call
477 (process_structure_scope): Update rust_unions if necessary.
479 2018-02-26 Tom Tromey <tom@tromey.com>
481 * value.h (value_union_variant): Declare.
482 * valops.c (value_union_variant): New function.
483 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
484 (struct discriminant_info): New.
485 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
487 (struct main_type) <flag_discriminated_union>: New field.
489 2018-02-26 Tom Tromey <tom@tromey.com>
491 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
492 unittests/unpack-selftests.c.
493 * unittests/unpack-selftests.c: New file.
494 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
496 2018-02-26 Yao Qi <yao.qi@linaro.org>
498 * dwarf2read.c (struct partial_die_info) <read>: New method.
499 (read_partial_die): Remove the declaration.
500 (load_partial_dies): Update.
501 (partial_die_info::partial_die_info):
502 (read_partial_die): Change it to partial_die_info::read.
504 2018-02-26 Yao Qi <yao.qi@linaro.org>
506 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
507 (fixup_partial_die): Remove declaration.
508 (scan_partial_symbols): Update.
509 (partial_die_parent_scope): Likewise.
510 (partial_die_full_name): Likewise.
511 (fixup_partial_die): Change it to partial_die_info::fixup.
513 2018-02-26 Yao Qi <yao.qi@linaro.org>
515 * dwarf2read.c (read_partial_die): Update the declaration.
516 (load_partial_dies): Caller update.
517 (read_partial_die): Remove one argument abbrev_len.
519 2018-02-26 Yao Qi <yao.qi@linaro.org>
521 * dwarf2read.c (struct partial_die_info): Add ctor, delete
523 (load_partial_dies): Use ctor and copy ctor.
524 (read_partial_die): Update.
525 (dwarf2_cu::find_partial_die): Use ctor.
527 2018-02-26 Yao Qi <yao.qi@linaro.org>
529 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
530 (find_partial_die_in_comp_unit): Change it to
531 dwarf2_cu::find_partial_die.
532 (find_partial_die): Update.
534 2018-02-26 Yao Qi <yao.qi@linaro.org>
536 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
539 2018-02-26 Yao Qi <yao.qi@linaro.org>
541 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
543 2018-02-26 Alan Hayward <alan.hayward@arm.com>
545 * arch/amd64.h: Use common/tdesc.h.
546 * arch/i386.c: Likewise.
547 * arch/i386.h: Likewise.
548 * arch/tic6x.c: Likewise.
549 * arch/tdesc.h: Move file from here...
550 * common/tdesc.h: ...to here.
551 * features/aarch64-core.c: Regenerate.
552 * features/aarch64-fpu.c: Regenerate.
553 * features/i386/32bit-avx.c: Regenerate.
554 * features/i386/32bit-avx512.c: Regenerate.
555 * features/i386/32bit-core.c: Regenerate.
556 * features/i386/32bit-linux.c: Regenerate.
557 * features/i386/32bit-mpx.c: Regenerate.
558 * features/i386/32bit-pkeys.c: Regenerate.
559 * features/i386/32bit-sse.c: Regenerate.
560 * features/i386/64bit-avx.c: Regenerate.
561 * features/i386/64bit-avx512.c: Regenerate.
562 * features/i386/64bit-core.c: Regenerate.
563 * features/i386/64bit-linux.c: Regenerate.
564 * features/i386/64bit-mpx.c: Regenerate.
565 * features/i386/64bit-pkeys.c: Regenerate.
566 * features/i386/64bit-segments.c: Regenerate.
567 * features/i386/64bit-sse.c: Regenerate.
568 * features/i386/x32-core.c: Regenerate.
569 * features/tic6x-c6xp.c: Regenerate.
570 * features/tic6x-core.c: Regenerate.
571 * features/tic6x-gp.c: Regenerate.
572 * target-descriptions.c: Use common/tdesc.h.
573 * target-descriptions.h: Likewise.
575 2018-02-24 Tom Tromey <tom@tromey.com>
577 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
578 (try_thread_db_load_from_dir, thread_db_load_search): Use
580 (info_auto_load_libthread_db_compare): Return bool. Change
582 (info_auto_load_libthread_db): Use std::vector, std::string.
585 2018-02-24 Tom Tromey <tom@tromey.com>
587 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
589 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
591 * gdbarch.c: Rebuild.
592 * gdbarch.h: Rebuild.
593 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
594 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
595 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
598 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
600 * gdbtypes.h (sect_offset): Change type to uint64_t.
601 (sect_offset_str): New function.
602 * dwarf2read.c (create_addrmap_from_aranges): Use
604 (error_check_comp_unit_head): Likewise.
605 (create_debug_type_hash_table): Likewise.
606 (read_cutu_die_from_dwo): Likewise.
607 (init_cutu_and_read_dies): Likewise.
608 (init_cutu_and_read_dies_no_follow): Likewise.
609 (process_psymtab_comp_unit_reader): Likewise.
610 (partial_die_parent_scope): Likewise.
611 (peek_die_abbrev): Likewise.
612 (process_queue): Likewise.
613 (dwarf2_physname): Likewise.
614 (read_namespace_alias): Likewise.
615 (read_import_statement): Likewise.
616 (create_dwo_cu_reader): Likewise.
617 (create_cus_hash_table): Likewise.
618 (lookup_dwo_cutu): Likewise.
619 (inherit_abstract_dies): Likewise.
620 (read_func_scope): Likewise.
621 (read_call_site_scope): Likewise.
622 (dwarf2_add_member_fn): Likewise.
623 (read_common_block): Likewise.
624 (read_module_type): Likewise.
625 (read_typedef): Likewise.
626 (read_subrange_type): Likewise.
627 (load_partial_dies): Likewise.
628 (read_partial_die): Likewise.
629 (find_partial_die): Likewise.
630 (read_str_index): Likewise.
631 (dwarf2_string_attr): Likewise.
632 (build_error_marker_type): Likewise.
633 (lookup_die_type): Likewise.
634 (dump_die_shallow): Likewise.
635 (follow_die_ref): Likewise.
636 (dwarf2_fetch_die_loc_sect_off): Likewise.
637 (dwarf2_fetch_constant_bytes): Likewise.
638 (follow_die_sig): Likewise.
639 (get_signatured_type): Likewise.
640 (get_DW_AT_signature_type): Likewise.
641 (dwarf2_find_containing_comp_unit): Likewise.
642 (set_die_type): Likewise.
644 2018-02-21 John Baldwin <jhb@FreeBSD.org>
646 * arch/aarch64.c: Include "common-defs.h".
647 * arch/amd64.c: Likewise.
648 * arch/i386.c: Likewise.
650 2018-02-21 Tom Tromey <tom@tromey.com>
652 * value.h: (extract_field_op): Update.
653 * eval.c (extract_field_op): Return a const char *.
654 * expression.h (parse_expression_for_completion): Update.
655 * completer.c (complete_expression): Update.
656 (add_struct_fields): Make fieldname const.
657 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
658 (mark_completion_tag, parse_exp_in_context_1): Update.
659 (parse_expression_for_completion): Change "name" to
662 2018-02-21 Tom Tromey <tom@tromey.com>
664 * infcall.c (call_function_by_hand_dummy): Use std::vector.
666 2018-02-21 Yao Qi <yao.qi@linaro.org>
668 * avr-tdep.c (avr_read_pc): Change parameter type to
670 * gdbarch.sh (read_pc): Likewise.
671 * gdbarch.c: Re-generated.
672 * gdbarch.h: Re-generated.
673 * hppa-tdep.c (hppa_read_pc): Change parameter type to
675 * ia64-tdep.c (ia64_read_pc): Likewise.
676 * mips-tdep.c (mips_read_pc): Likewise.
677 * spu-tdep.c (spu_read_pc): Likewise.
679 2018-02-21 Yao Qi <yao.qi@linaro.org>
681 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
682 * regcache-dump.c: New file.
683 * regcache.c: Move register_dump to regcache-dump.c.
684 (maintenance_print_registers): Likewise.
685 (maintenance_print_raw_registers): Likewise.
686 (maintenance_print_cooked_registers): Likewise.
687 (maintenance_print_register_groups): Likewise.
688 (maintenance_print_remote_registers): Likewise.
689 (_initialize_regcache): Likewise.
690 * regcache.h (register_dump): Moved from regcache.c.
692 2018-02-21 Yao Qi <yao.qi@linaro.org>
694 * regcache.c (regcache::regcache): Update.
695 (regcache::invalidate): Move it to detached_regcache::invalidate.
696 (get_thread_arch_aspace_regcache): Update.
697 (regcache::raw_update): Update.
698 (regcache::cooked_read): Remove some code.
699 (regcache::cooked_read_value): Likewise.
700 (regcache::raw_write): Remove assert on m_readonly_p.
701 (regcache::raw_supply_integer): Move it to
702 detached_regcache::raw_supply_integer.
703 (regcache::raw_supply_zeroed): Likewise.
704 * regcache.h (detached_regcache) <raw_supply_integer>: New
706 <raw_supply_zeroed, invalidate>: Likewise.
707 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
708 <invalidate>: Likewise.
709 <m_readonly_p>: Removed.
711 2018-02-21 Yao Qi <yao.qi@linaro.org>
713 * infcmd.c (get_return_value): Let stop_regs point to
714 get_current_regcache.
715 * regcache.c (regcache::regcache): Remove.
716 (register_dump_reg_buffer): New class.
717 (regcache_print): Adjust.
718 * regcache.h (regcache): Remove constructors.
720 2018-02-21 Yao Qi <yao.qi@linaro.org>
722 * regcache.c (class register_dump): New class.
723 (register_dump_regcache, register_dump_none): New class.
724 (register_dump_remote, register_dump_groups): New class.
725 (regcache_print): Update.
726 * regcache.h (regcache_dump_what): Move it to regcache.c.
727 (regcache) <dump>: Remove.
729 2018-02-21 Yao Qi <yao.qi@linaro.org>
731 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
733 (jit_unwind_reg_set_impl): Call raw_supply.
734 (jit_frame_sniffer): Use reg_buffer_rw.
735 * record-full.c (record_full_core_regbuf): Change its type.
736 (record_full_core_open_1): Use reg_buffer_rw.
737 (record_full_close): Likewise.
738 (record_full_core_fetch_registers): Use regcache->raw_supply.
739 (record_full_core_store_registers): Likewise.
740 * regcache.c (regcache::get_register_status): Move it to
742 (regcache_raw_set_cached_value): Remove.
743 (regcache::raw_set_cached_value): Remove.
744 (regcache::raw_write): Call raw_supply.
745 (regcache::raw_supply): Move it to reg_buffer_rw.
746 * regcache.h (regcache_raw_set_cached_value): Remove.
747 (reg_buffer_rw): New class.
749 2018-02-21 Yao Qi <yao.qi@linaro.org>
751 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
752 readonly_detached_regcache.
753 (dummy_frame_prev_register): Use regcache->cooked_read.
754 * frame.c (frame_save_as_regcache): Change return type.
756 * frame.h (frame_save_as_regcache): Update declaration.
757 * inferior.h (get_infcall_suspend_state_regcache): Update
759 * infrun.c (infcall_suspend_state) <registers>: use
760 readonly_detached_regcache.
761 (save_infcall_suspend_state): Don't use regcache_dup.
762 (get_infcall_suspend_state_regcache): Change return type.
763 * linux-fork.c (struct fork_info) <savedregs>: Change to
764 readonly_detached_regcache.
766 (fork_save_infrun_state): Don't use regcache_dup.
767 (info_checkpoints_command): Adjust.
768 * mi/mi-main.c (register_changed_p): Update declaration.
769 (mi_cmd_data_list_changed_registers): Use
770 readonly_detached_regcache.
771 (register_changed_p): Change parameter type to
772 readonly_detached_regcache.
773 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
774 readonly_detached_regcache.
775 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
776 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
778 (regcache::save): Move it to reg_buffer.
779 (regcache::restore): Change parameter type.
780 (regcache_dup): Remove.
781 * regcache.h (reg_buffer) <save>: New method.
782 (readonly_detached_regcache): New class.
783 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
784 readonly_detached_regcache.
785 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
787 2018-02-21 Yao Qi <yao.qi@linaro.org>
789 * frame.c (frame_save_as_regcache): Use regcache method save.
790 (frame_pop): Use regcache method restore.
791 * infrun.c (restore_infcall_suspend_state): Likewise.
792 * linux-fork.c (fork_load_infrun_state): Likewise.
793 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
795 * regcache.c (regcache_save): Remove.
796 (regcache::restore): More asserts.
797 (regcache_cpy): Remove.
798 * regcache.h (regcache_save): Remove the declaration.
799 (regcache::restore): Move from private to public.
800 Remove the friend declaration of regcache_cpy.
801 (regcache_cpy): Remove declaration.
803 2018-02-21 Yao Qi <yao.qi@linaro.org>
805 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
806 parameter type to 'readable_regcache *'.
807 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
808 * arm-tdep.c (arm_neon_quad_read): Likewise.
809 (arm_pseudo_read): Likewise.
810 * avr-tdep.c (avr_pseudo_register_read): Likewise.
811 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
812 * frv-tdep.c (frv_pseudo_register_read): Likewise.
813 * gdbarch.c: Re-generated.
814 * gdbarch.h: Re-generated.
815 * gdbarch.sh (pseudo_register_read): Change parameter type to
816 'readable_regcache *'.
817 (pseudo_register_read_value): Likewise.
818 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
819 (h8300_pseudo_register_read): Likewise.
820 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
821 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
822 (i386_pseudo_register_read_into_value): Likewise.
823 (i386_pseudo_register_read_value): Likewise.
824 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
826 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
827 * m32c-tdep.c (m32c_raw_read): Likewise.
828 (m32c_read_flg): Likewise.
829 (m32c_banked_register): Likewise.
830 (m32c_banked_read): Likewise.
831 (m32c_sb_read): Likewise.
832 (m32c_part_read): Likewise.
833 (m32c_cat_read): Likewise.
834 (m32c_r3r2r1r0_read): Likewise.
835 (m32c_pseudo_register_read): Likewise.
836 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
837 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
838 (mep_pseudo_cr64_read): Likewise.
839 (mep_pseudo_register_read): Likewise.
840 * mips-tdep.c (mips_pseudo_register_read): Likewise.
841 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
842 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
843 * regcache.c (regcache::raw_read): Move it to readable_regcache.
844 (regcache::cooked_read): Likewise.
845 (regcache::cooked_read_value): Likewise.
846 (regcache_cooked_read_signed):
847 (regcache::cooked_read): Likewise.
848 * regcache.h (readable_regcache): New class.
849 (regcache): Inherit readable_regcache. Move some methods to
851 * rl78-tdep.c (rl78_pseudo_register_read): Change
852 parameter type to 'readable_regcache *'.
853 * rs6000-tdep.c (do_regcache_raw_read): Remove.
854 (e500_pseudo_register_read): Change parameter type to
855 'readable_regcache *'.
856 (dfp_pseudo_register_read): Likewise.
857 (vsx_pseudo_register_read): Likewise.
858 (efpr_pseudo_register_read): Likewise.
859 * s390-tdep.c (s390_pseudo_register_read): Likewise.
860 * sh-tdep.c (sh_pseudo_register_read): Likewise.
861 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
862 (sh64_pseudo_register_read): Likewise.
863 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
864 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
865 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
866 (spu_pseudo_register_read): Likewise.
867 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
868 (xtensa_pseudo_register_read): Likewise.
870 2018-02-21 Yao Qi <yao.qi@linaro.org>
872 * regcache.c (regcache::regcache): Call reg_buffer ctor.
873 (regcache::arch): Move it to reg_buffer::arch.
874 (regcache::register_buffer): Likewise.
875 (regcache::assert_regnum): Likewise.
876 (regcache::num_raw_registers): Likewise.
877 * regcache.h (reg_buffer): New class.
878 (regcache): Inherit reg_buffer.
880 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
882 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
883 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
885 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
887 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
889 2018-02-19 Alan Hayward <alan.hayward@arm.com>
891 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
892 (SFILES): Remove common/*.c files.
893 (COMMON_OBS): Remove some *.o files built from common/*.c files.
894 * common/common.host: Add common reference.
895 * configure.ac: Likewise.
896 * configure: Regenerate.
898 2018-02-16 Yao Qi <yao.qi@linaro.org>
900 * block.c (block_namespace_info): Inherit allocate_on_obstack.
901 (block_initialize_namespace): Use new.
902 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
903 (dwarf2_free_objfile): Use delete.
904 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
905 (copy_type_recursive): Use new.
906 * gdb_obstack.h (allocate_on_obstack): New.
908 2018-02-15 Yao Qi <yao.qi@linaro.org>
911 * inferior.c (exit_inferior_1): Reset inf->control.
913 2018-02-15 Joel Brobecker <brobecker@adacore.com>
915 * ada-lang.c (ada_to_fixed_value_create): Delete advance
918 2018-02-14 Pedro Alves <palves@redhat.com>
920 * frame-unwind.c (frame_unwind_try_unwinder): Always call
921 frame_cleanup_after_sniffer on exception.
923 2018-02-14 Tom Tromey <tom@tromey.com>
925 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
927 (solib_bfd_open): Make pathname const.
928 * solib.c (solib_bfd_open): Make pathname const.
929 * solib-spu.c (spu_bfd_fopen): Make name const.
930 (spu_bfd_open): Make pathname const.
931 * solib-darwin.c (darwin_bfd_open): Make pathname const.
932 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
934 2018-02-14 Tom Tromey <tom@tromey.com>
936 * symfile.c (symfile_bfd_open): Update.
937 * source.h (openp, source_full_path_of, find_and_open_source):
938 Change argument type to unique_xmalloc_ptr.
939 * source.c (openp): Take a unique_xmalloc_ptr.
940 (source_full_path_of, find_and_open_source): Likewise.
941 (open_source_file, symtab_to_fullname): Update.
942 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
944 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
945 (exec_file_find): Update.
946 * psymtab.c (psymtab_to_fullname): Update.
947 * nto-tdep.h (nto_find_and_open_solib): Update.
948 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
950 * exec.c (exec_file_attach): Update.
951 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
952 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
954 2018-02-14 Tom Tromey <tom@tromey.com>
956 * solib.c: Include source.h.
957 * nto-tdep.c: Include source.h.
958 * mi/mi-cmd-env.c: Include source.h.
959 * infcmd.c: Include source.h.
960 * exec.c: Include source.h.
961 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
962 (add_path, directory_switch, source_path, init_source_path): Move
964 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
965 (add_path, directory_switch, source_path, init_source_path):
968 2018-02-14 Tom Tromey <tom@tromey.com>
970 * solist.h (exec_file_find, solib_find): Return
972 (solib_bfd_fopen): Take a const char *.
973 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
974 (exec_file_find, solib_find): Likewise.
975 (solib_bfd_fopen): Do not take ownership of "pathname".
976 (solib_bfd_open): Use unique_xmalloc_ptr.
977 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
978 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
979 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
980 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
982 2018-02-14 Joel Brobecker <brobecker@adacore.com>
984 * ada-lang.c (name_match_type_from_name): Remove reference to
985 ada_name_for_lookup in function's documentation.
986 * ada-lang.h (ada_name_for_lookup): Delete declaration.
988 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
990 * defs.h (enum openp_flags): New enum.
991 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
992 Move to enum openp_flags.
993 (openp_flags): New enum flags.
994 (openp): Change parameter type to openp_flags.
995 * source.c (openp): Change parameter type to openp_flags.
996 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
997 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
999 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
1001 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
1004 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
1006 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
1008 (class dwarf2_queue_guard): ...the destructor of this new class.
1009 (dw2_do_instantiate_symtab): Create instance of the new class
1010 dwarf2_queue_guard, remove cleanup.
1012 2018-02-09 Tom Tromey <tom@tromey.com>
1014 * source.c (find_source_lines): Don't reference past the end of
1017 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1019 * remote.c (remote_btrace_maybe_reopen): Change error message.
1020 * btrace.c (btrace_enable): Likewise.
1021 (parse_xml_btrace): Likewise.
1022 (parse_xml_btrace_conf): Likewise.
1024 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1026 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
1027 (linux_enable_pt, linux_enable_bts): Call
1028 diagnose_perf_event_open_fail.
1030 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1032 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
1033 Remove parameter and change return type. Update callers. Move it.
1034 (linux_enable_bts, linux_enable_pt): Improve error message.
1035 (linux_enable_pt): Remove zero buffer size check.
1036 (linux_enable_btrace): Improve error messages. Remove NULL return
1039 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1041 * btrace.c (btrace_enable): Remove target_supports_btrace call.
1042 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
1043 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
1044 (linux_supports_pt, linux_supports_btrace): Remove.
1045 (linux_enable_bts): Call cpu_supports_bts.
1046 * nat/linux-btrace.h (linux_supports_btrace): Remove.
1047 * remote.c (remote_supports_btrace): Remove.
1048 (init_remote_ops): Remove remote_supports_btrace.
1049 * target-delegates.c: Regenerated.
1050 * target.c (target_supports_btrace): Remove.
1051 * target.h (target_ops) <to_supports_btrace>: Remove
1052 (target_supports_btrace): Remove.
1053 * x86-linux-nat.c (x86_linux_create_target): Remove
1054 linux_supports_btrace.
1056 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1058 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
1060 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
1061 exception and use message in own exception.
1063 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1065 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
1066 (perf_event_pt_event_type): Use gdb_file_up.
1067 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
1068 scoped_fd, and scoped_mmap.
1070 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1072 * common/scoped_mmap.h: New.
1073 * unittests/scoped_mmap-selftest.c: New.
1074 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1075 unittests/scoped_mmap-selftest.c.
1077 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1079 * common/scoped_fd.h: New.
1080 * unittests/scoped_fd-selftest.c: New.
1081 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1082 unittests/scoped_fd-selftest.c.
1084 2018-02-09 Tom Tromey <tom@tromey.com>
1086 * auto-load.c (auto_load_section_scripts): Use
1087 gdb::unique_xmalloc_ptr.
1089 2018-02-09 Tom Tromey <tom@tromey.com>
1091 * auto-load.c (execute_script_contents): Use std::string.
1093 2018-02-09 Joel Brobecker <brobecker@adacore.com>
1095 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
1096 Python function, rather than a new command.
1098 2018-02-08 Tom Tromey <tom@tromey.com>
1100 * solib.c (solib_find_1): Use std::string.
1101 (solib_bfd_fopen): Use unique_xmalloc_ptr.
1103 2018-02-08 Tom Tromey <tom@tromey.com>
1105 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
1107 2018-02-08 Tom Tromey <tom@tromey.com>
1109 * source.c (find_source_lines): Use gdb::def_vector.
1111 2018-02-08 Tom Tromey <tom@tromey.com>
1113 * macrocmd.c (struct temporary_macro_definition): New.
1114 (macro_define_command): Use temporary_macro_definition. Remove
1116 (free_macro_definition_ptr): Remove.
1118 2018-02-08 Tom Tromey <tom@tromey.com>
1120 * macroexp.c (maybe_expand): Use std::string.
1122 2018-02-08 Tom Tromey <tom@tromey.com>
1124 * macroexp.c (struct macro_buffer): Add initializers for some
1126 (init_buffer, init_shared_buffer, free_buffer)
1127 (free_buffer_return_text): Remove.
1128 (macro_buffer): New constructors.
1129 (~macro_buffer): New destructor.
1130 (macro_buffer::set_shared): New method.
1131 (macro_buffer::resize_buffer, macro_buffer::appendc)
1132 (macro_buffer::appendmem): Now methods, not free functions.
1133 (set_token, append_tokens_without_splicing, stringify)
1134 (macro_stringify): Update.
1135 (gather_arguments): Change return type. Remove argc_p argument,
1136 add args_ptr argument. Use std::vector.
1137 (substitute_args): Remove argc argument. Accept std::vector.
1138 (expand): Update. Use std::vector.
1139 (scan, macro_expand, macro_expand_next): Update.
1141 2018-02-08 Tom Tromey <tom@tromey.com>
1143 * symtab.c (default_collect_symbol_completion_matches_break_on):
1144 Use unique_xmalloc_ptr.
1145 * macroscope.h: (sal_macro_scope, user_macro_scope)
1146 (default_macro_scope): Return unique_xmalloc_ptr.
1147 * macroscope.c (sal_macro_scope, user_macro_scope)
1148 (default_macro_scope): Return unique_xmalloc_ptr.
1149 * macroexp.h (macro_expand, macro_expand_once): Return
1151 * macroexp.c (macro_expand, macro_expand_once): Return
1153 * macrocmd.c (macro_expand_command, macro_expand_once_command)
1154 (info_macro_command, info_macros_command): Use
1156 * compile/compile-c-support.c (write_macro_definitions): Use
1158 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
1160 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
1162 * value.c (value_static_field): Assign field type instead of
1163 containing type when returning an optimized out value.
1165 2018-02-06 Yao Qi <yao.qi@linaro.org>
1167 * ft32-tdep.c (ft32_read_pc): Remove.
1168 (ft32_write_pc): Remove.
1169 (ft32_gdbarch_init): Update.
1170 * m32r-tdep.c (m32r_read_pc): Remove.
1171 (m32r_gdbarch_init): Update.
1172 * mep-tdep.c (mep_read_pc): Remove.
1173 (mep_gdbarch_init): Update.
1174 * microblaze-tdep.c (microblaze_write_pc): Remove.
1175 (microblaze_gdbarch_init): Update.
1176 * mn10300-tdep.c (mn10300_read_pc): Remove.
1177 (mn10300_write_pc): Remove.
1178 (mn10300_gdbarch_init): Update.
1179 * moxie-tdep.c (moxie_read_pc): Remove.
1180 (moxie_write_pc): Remove.
1181 (moxie_gdbarch_init): Update.
1183 2018-02-06 Yao Qi <yao.qi@linaro.org>
1185 * expprint.c (print_subexp_standard): Handle
1186 OP_F77_UNDETERMINED_ARGLIST.
1187 (dump_subexp_body_standard): Likewise.
1189 2018-02-05 Alan Hayward <alan.hayward@arm.com>
1191 * target-descriptions.c (tdesc_element_visitor) Add empty
1193 (tdesc_type): Move make_gdb_type from here.
1194 (tdesc_type_builtin): Likewise.
1195 (tdesc_type_vector): Likewise.
1196 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
1197 (make_gdb_type_struct): Move from tdesc_type_with_fields.
1198 (make_gdb_type_union): Likewise.
1199 (make_gdb_type_flags): Likewise.
1200 (make_gdb_type_enum): Likewise.
1201 (make_gdb_type): New function.
1202 (tdesc_register_type): Use static make_gdb_type.
1204 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
1206 * infcmd.c (default_print_one_register_info): Align natural-format
1207 column values consistently one under another.
1208 (pad_to_column): New function.
1210 2018-02-05 Joel Brobecker <brobecker@adacore.com>
1212 * dwarf2read.c (dwarf2_physname): Move commment.
1214 2018-02-01 Leszek Swirski <leszeks@google.com>
1216 * varobj.c (varobj_formatted_print_options): Allow recursive
1217 pretty printing if pretty printing is enabled.
1219 2018-02-01 Leszek Swirski <leszeks@google.com>
1221 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
1222 names after a structop as a filename.
1224 2018-02-01 Yao Qi <yao.qi@linaro.org>
1226 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
1227 (arm_record_coproc_data_proc): Likewise.
1229 2018-02-01 Yao Qi <yao.qi@linaro.org>
1231 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
1233 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
1235 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
1236 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
1238 2018-01-31 Pedro Alves <palves@redhat.com>
1240 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
1241 * inflow.c (child_terminal_save_inferior): Wrap reference to
1242 tcgetpgrp in HAVE_TERMIOS_H.
1243 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
1245 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
1246 always iterate over all inferiors.
1247 (gdbsim_cntrl_c): Adjust.
1248 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
1250 2018-01-31 Joel Brobecker <brobecker@adacore.com>
1252 * gdbtypes.c (lookup_array_range_type): Make sure the array's
1253 index type is objfile-owned if the element type is as well.
1255 2018-01-31 Joel Brobecker <brobecker@adacore.com>
1259 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
1261 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
1262 "features/s390x-linux64.c".
1263 (_initialize_s390_linux_tdep): Remove initialization of tdescs
1264 s390_linux32 and s390x_linux64.
1265 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
1267 * s390-tdep.c: Include "features/s390-linux32.c" and
1268 "features/s390x-linux64.c".
1269 (s390_tdesc_valid): Add check for tdesc_has_registers.
1270 (s390_gdbarch_init): Make sure there is always a valid tdesc.
1271 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
1272 tdesc_s390x_linux64.
1273 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
1274 tdesc_s390x_linux64 to...
1275 * s390-tdep.h: ...here.
1277 2018-01-30 Pedro Alves <palves@redhat.com>
1280 * config.in, configure: Regenerate.
1281 * configure.ac: Check for getpgid.
1282 * go32-nat.c (go32_pass_ctrlc): New.
1283 (go32_target): Install it.
1284 * inf-child.c (inf_child_target): Install
1285 child_terminal_save_inferior, child_pass_ctrlc and
1287 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
1288 (inf_ptrace_target): No longer install it.
1289 * infcmd.c (interrupt_target_1): Adjust.
1290 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
1291 (child_interrupt): Declare.
1292 (inferior::terminal_state): New.
1293 * inflow.c (struct terminal_info): Update comments.
1294 (inferior_process_group): Delete.
1295 (terminal_is_ours): Delete.
1296 (gdb_tty_state): New.
1297 (child_terminal_init): Adjust.
1298 (is_gdb_terminal, sharing_input_terminal_1)
1299 (sharing_input_terminal): New functions.
1300 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
1301 Set the process's actual process group in the foreground if
1302 possible. Handle is_ours_for_output/is_ours distinction. Don't
1303 mark terminal as the inferior's if not sharing GDB's terminal.
1304 Don't check attach_flag.
1305 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
1306 pass down a target_terminal_state.
1307 (child_terminal_save_inferior): New, factored out from ...
1308 (child_terminal_ours_1): ... this. Handle
1309 target_terminal_state::is_ours_for_output.
1310 (child_interrupt, child_pass_ctrlc): New.
1311 (inflow_inferior_exit): Clear the inferior's terminal_state.
1312 (copy_terminal_info): Copy the inferior's terminal state.
1313 (_initialize_inflow): Remove reference to terminal_is_ours.
1314 * inflow.h (inferior_process_group): Delete.
1315 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
1316 * procfs.c (procfs_target): Don't install procfs_interrupt.
1317 (procfs_interrupt): Delete.
1318 * remote.c (remote_serial_quit_handler): Adjust.
1319 (remote_interrupt): Remove ptid parameter. Adjust.
1320 * target-delegates.c: Regenerate.
1321 * target.c: Include "terminal.h".
1322 (target_terminal::terminal_state): Rename to ...
1323 (target_terminal::m_terminal_state): ... this.
1324 (target_terminal::init): Adjust.
1325 (target_terminal::inferior): Adjust to per-inferior
1327 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
1328 (target_terminal::ours, target_terminal::ours_for_output): Use
1329 target_terminal_is_ours_kind.
1330 (target_interrupt): Remove ptid parameter. Adjust.
1331 (default_target_pass_ctrlc): Adjust.
1332 * target.h (target_ops::to_terminal_save_inferior): New field.
1333 (target_ops::to_interrupt): Remove ptid_t parameter.
1334 (target_interrupt): Remove ptid_t parameter. Update comment.
1335 (target_pass_ctrlc): Update comment.
1336 * target/target.h (target_terminal_state): New scoped enum,
1338 (target_terminal::terminal_state): ... here.
1339 (target_terminal::inferior): Update comments.
1340 (target_terminal::restore_inferior): New.
1341 (target_terminal::is_inferior, target_terminal::is_ours)
1342 (target_terminal::is_ours_for_output): Adjust.
1343 (target_terminal::scoped_restore_terminal_state): Adjust to
1344 rename, and call restore_inferior() instead of inferior().
1345 (target_terminal::scoped_restore_terminal_state::m_state): Change
1347 (target_terminal::terminal_state): Rename to ...
1348 (target_terminal::m_terminal_state): ... this and change type.
1350 2018-01-30 Pedro Alves <palves@redhat.com>
1352 * linux-nat.c (wait_for_signal): New function.
1353 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
1355 (async_terminal_is_ours)
1356 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
1357 (linux_nat_add_target): Don't override
1358 to_terminal_inferior/to_terminal_ours.
1360 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
1362 * remote.c (remote_follow_fork): Don't call "detach_inferior".
1364 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
1366 * dwarf2read.c (free_dwo_files): Add forward-declaration.
1367 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
1368 dwarf2_per_objfile_free here.
1369 (dwarf2_per_objfile_free): Remove.
1370 (_initialize_dwarf2_read): Don't register
1371 dwarf2_per_objfile_free as a registry cleanup.
1373 2018-01-27 Eli Zaretskii <eliz@gnu.org>
1375 Avoid compilation errors in MinGW native builds
1377 The error is triggered by including python-internal.h, and the
1380 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
1381 from build-gnulib/import/math.h:27,
1382 from d:/usr/Python26/include/pyport.h:235,
1383 from d:/usr/Python26/include/Python.h:58,
1384 from python/python-internal.h:94,
1385 from python/py-arch.c:24:
1386 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
1390 This happens because Python headers define 'hypot' to expand t
1391 '_hypot' in the Windows builds.
1392 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
1393 'hypoth'. This avoids a compilation error.
1395 2018-01-26 Alan Hayward <alan.hayward@arm.com>
1397 * MAINTAINERS (Write After Approval): Fix ordering.
1399 2018-01-26 Alan Hayward <alan.hayward@arm.com>
1401 * MAINTAINERS (Write After Approval): Add Alan Hayward.
1403 2018-01-26 Alan Modra <amodra@gmail.com>
1405 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
1406 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
1407 Remove nop. Make const. Comment.
1408 (powerpc32_plt_stub_so_2): New.
1409 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
1410 Correct count. Update uses.
1411 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
1412 Move common code reading PLT entry word. Correct
1413 powerpc32_plt_stub PLT address calculation.
1414 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
1415 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
1416 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
1417 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
1418 (ppc64_standard_linkage8): Likewise.
1419 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
1420 Correct insns description.
1421 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
1423 2018-01-24 Pedro Alves <palves@redhat.com>
1425 GCC PR libstdc++/83906
1426 * gdbtypes.c (operator==(const dynamic_prop &,
1427 const dynamic_prop &)): New.
1428 (operator==(const range_bounds &, const range_bounds &)): New.
1429 (check_types_equal): Use them instead of memcmp.
1430 * gdbtypes.h (operator==(const dynamic_prop &,
1431 const dynamic_prop &)): Declare.
1432 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
1433 (operator==(const range_bounds &, const range_bounds &)): Declare.
1434 (operator!=(const range_bounds &, const range_bounds &)): Declare.
1436 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1438 * s390-linux-tdep.c (s390_record_address_mask)
1439 (s390_record_calc_disp_common, s390_record_calc_disp)
1440 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
1441 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
1442 (s390_process_record): Move to s390-tdep.c.
1443 (s390_linux_init_abi_any): Adjust.
1444 * s390-tdep.c (s390_record_address_mask)
1445 (s390_record_calc_disp_common, s390_record_calc_disp)
1446 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
1447 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
1448 (s390_process_record): Moved from s390-linux-tdep.c
1449 (s390_gdbarch_init): Adjust.
1451 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1453 * s390-linux-nat.c (s390-tdep.h): New include.
1454 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
1455 (HFILES_NO_SRCDIR): Add s390-tdep.h.
1456 (ALLDEPFILES): Add s390-tdep.c.
1457 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
1458 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
1459 * s390-tdep.h: ...this. New file.
1460 * s390-linux-tdep.c (s390-tdep.h): New include.
1461 (_initialize_s390_tdep): Rename to...
1462 (_initialize_s390_linux_tdep): ...this and adjust.
1463 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
1464 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
1466 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
1467 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
1468 (s390_is_partial_instruction, s390_software_single_step)
1469 (is_non_branch_ril, s390_displaced_step_copy_insn)
1470 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
1471 (s390_prologue_data, s390_addr, s390_store, s390_load)
1472 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
1473 (s390_register_call_saved, s390_guess_tracepoint_registers)
1474 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
1475 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
1476 (s390_pseudo_register_name, s390_pseudo_register_type)
1477 (s390_pseudo_register_read, s390_pseudo_register_write)
1478 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
1479 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
1480 (s390_addr_bits_remove, s390_address_class_type_flags)
1481 (s390_address_class_type_flags_to_name)
1482 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
1483 (s390_function_arg_float, s390_function_arg_vector)
1484 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
1485 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
1486 (s390_frame_align, s390_register_return_value, s390_return_value)
1487 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
1488 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
1489 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
1490 (s390_trad_frame_prev_register, s390_unwind_cache)
1491 (s390_prologue_frame_unwind_cache)
1492 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
1493 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
1494 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
1495 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
1496 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
1497 (s390_frame_base_address, s390_local_base_address)
1498 (s390_frame_base, s390_gcc_target_options)
1499 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
1500 (s390_validate_reg_range, s390_tdesc_valid)
1501 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
1502 * s390-tdep.c: ...this. New file.
1504 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1506 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
1507 (s390_process_record, s390_gdbarch_tdep_alloc)
1508 (s390_linux_init_abi_any): Use/set new hook.
1510 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1512 * s390-linux-tdep.c (osabi.h): New include.
1513 (s390_linux_init_abi_31, s390_linux_init_abi_64)
1514 (s390_linux_init_abi_any): New functions.
1515 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
1517 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1519 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
1520 tdesc_has_registers check
1522 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1524 * s390-linux-tdep.c (s390_tdesc_valid): New function.
1525 (s390_validate_reg_range): New macro.
1526 (s390_gdbarch_init): Adjust.
1528 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1530 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
1531 (s390_gdbarch_tdep_alloc): Adjust.
1532 (s390_gdbarch_init): Adjust.
1534 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1536 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
1537 <have_tdb>: Change type to bool.
1538 (s390_gdbarch_tdep_alloc): Adjust.
1539 (s390_gdbarch_init): Adjust.
1541 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1543 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
1544 (gdbarch_tdep) <have_upper, have_vx>: New fields.
1545 (s390_gdbarch_tdep_alloc): New function.
1546 (s390_gdbarch_init): Allocate tdep at start and use its fields
1547 instead of separate variables.
1549 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1551 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
1552 when looking for cached gdbarch and add comment for remaining.
1554 2018-01-22 Pedro Alves <palves@redhat.com>
1555 Sergio Durigan Junior <sergiodj@redhat.com>
1557 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
1560 2018-01-22 Maciej W. Rozycki <macro@mips.com>
1562 * MAINTAINERS: Update my company e-mail address.
1564 2018-01-22 Yao Qi <yao.qi@linaro.org>
1566 * regcache.c (cooked_write_test): New function.
1567 (_initialize_regcache): Register the test.
1569 2018-01-22 Yao Qi <yao.qi@linaro.org>
1571 * ia64-tdep.c (ia64_pseudo_register_read): Call
1572 regcache->cooked_read instead of regcache_cooked_read_unsigned.
1573 * m32c-tdep.c (m32c_cat_read): Likewise.
1574 (m32c_r3r2r1r0_read): Likewise.
1575 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
1576 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
1578 2018-01-22 Yao Qi <yao.qi@linaro.org>
1580 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
1581 method raw_read instead of regcache_raw_read.
1582 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
1583 * arm-tdep.c (arm_neon_quad_read): Likewise.
1584 * avr-tdep.c (avr_pseudo_register_read): Likewise.
1585 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
1586 * frv-tdep.c (frv_pseudo_register_read): Likewise.
1587 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
1588 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1589 (i386_pseudo_register_read_into_value): Likewise.
1590 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
1591 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
1592 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
1593 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
1594 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
1595 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
1596 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
1597 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
1598 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
1600 2018-01-22 Yao Qi <yao.qi@linaro.org>
1602 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
1603 * configure.tgt: Remove target mt.
1604 * mt-tdep.c: Remove.
1605 * regcache.c (cooked_read_test): Remove the check for mt.
1607 2018-01-22 Yao Qi <yao.qi@linaro.org>
1609 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
1610 instead of gdbarch_pseudo_register_read_value.
1612 2018-01-22 Joel Brobecker <brobecker@adacore.com>
1614 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
1617 2018-01-22 Joel Brobecker <brobecker@adacore.com>
1619 * linespec.c (create_sals_line_offset): Remove code that preserved
1620 the symtab_and_line's line number.
1622 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1624 * varobj.c (varobj_create): Don't set valid_block when creating a
1627 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1629 * varobj.c (varobj_create): Remove out of date comment.
1631 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1634 * ada-exp.y (write_var_from_sym): Pass extra parameter when
1635 updating innermost block.
1636 * parse.c (innermost_block_tracker::update): Take extra type
1637 parameter, and check types match before updating innermost block.
1638 (write_dollar_variable): Update innermost block for registers.
1639 * parser-defs.h (enum innermost_block_tracker_type): New enum.
1640 (innermost_block_tracker::innermost_block_tracker): Initialise
1642 (innermost_block_tracker::reset): Take type parameter.
1643 (innermost_block_tracker::update): Take type parameter, and pass
1644 type through as needed.
1645 (innermost_block_tracker::m_types): New member.
1646 * varobj.c (varobj_create): Pass type when reseting innermost
1649 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1651 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
1652 * ada-lang.c (resolve_subexp): Likewise.
1653 * breakpoint.c (set_breakpoint_condition) Likewise.
1654 (watch_command_1) Likewise.
1655 * c-exp.y (variable): Likewise.
1656 * d-exp.y (PrimaryExpression): Likewise.
1657 * f-exp.y (variable): Likewise.
1658 * go-exp.y (variable): Likewise.
1659 * m2-exp.y (variable): Likewise.
1660 * objfiles.c (objfile::~objfile): Likewise.
1661 * p-exp.y (variable): Likewise.
1662 * parse.c (innermost_block): Change type.
1663 * parser-defs.h (class innermost_block_tracker): New.
1664 (innermost_block): Change to innermost_block_tracker.
1665 * printcmd.c (display_command): Switch to innermost_block API.
1666 (do_one_display): Likewise.
1667 * rust-exp.y (do_one_display): Likewise.
1668 * symfile.c (clear_symtab_users): Likewise.
1669 * varobj.c (varobj_create): Switch to innermost_block API, replace
1670 use of innermost_block with block stored on varobj object.
1672 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1674 * expression.h (innermost_block): Remove declaration.
1675 * varobj.c: Add 'parser-defs.h' include.
1677 2018-01-19 Tom Tromey <tom@tromey.com>
1679 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
1680 symbols in the static and global blocks.
1682 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1684 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
1685 gdb_ptrace.h, and move including gdb_wait.h ...
1686 * nat/linux-ptrace.h: ... to here.
1688 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1690 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
1691 inf_ptrace_detach_success.
1692 (inf_ptrace_detach_success): Add inferior parameter, use it
1693 instead of inferior_ptid, pass it to detach_inferior.
1694 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
1696 * inferior.c (detach_inferior): Add overload that takes an
1698 * inferior.h (detach_inferior): Likewise.
1699 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
1700 use inferior_ptid, adjust call to inf_ptrace_detach_success.
1701 * linux-thread-db.c (thread_db_detach): Use inf parameter.
1703 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1705 * target.h (struct target_ops) <to_detach>: Add inferior
1707 (target_detach): Likewise.
1708 * target.c (dispose_inferior): Pass inferior down.
1709 (target_detach): Pass inferior down. Assert that it is equal to
1710 the current inferior.
1711 * aix-thread.c (aix_thread_detach): Pass inferior down.
1712 * corefile.c (core_file_command): Pass current_inferior() down.
1713 * corelow.c (core_detach): Add inferior parameter.
1714 * darwin-nat.c (darwin_detach): Likewise.
1715 * gnu-nat.c (gnu_detach): Likewise.
1716 * inf-ptrace.c (inf_ptrace_detach): Likewise.
1717 * infcmd.c (detach_command): Pass current_inferior() down to
1719 * infrun.c (follow_fork_inferior): Pass parent_inf to
1721 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
1723 * linux-nat.c (linux_nat_detach): Add inferior parameter.
1724 * linux-thread-db.c (thread_db_detach): Likewise.
1725 * nto-procfs.c (procfs_detach): Likewise.
1726 * procfs.c (procfs_detach): Likewise.
1727 * record.c (record_detach): Likewise.
1728 * record.h (struct inferior): Forward-declare.
1729 (record_detach): Add inferior parameter.
1730 * remote-sim.c (gdbsim_detach): Likewise.
1731 * remote.c (remote_detach_1): Likewise.
1732 (remote_detach): Likewise.
1733 (extended_remote_detach): Likewise.
1734 * sol-thread.c (sol_thread_detach): Likewise.
1735 * target-debug.h (target_debug_print_inferior_p): New macro.
1736 * target-delegates.c: Re-generate.
1737 * top.c (kill_or_detach): Pass inferior down to target_detach.
1738 * windows-nat.c (windows_detach): Add inferior parameter.
1740 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1742 * target.h (struct target_ops) <to_detach>: Remove args
1744 (target_detach): Likewise.
1745 * target.c (dispose_inferior): Adjust.
1746 (target_detach): Remove args parameter, adjust.
1747 * aix-thread.c (aix_thread_detach): Adjust.
1748 * corefile.c (core_file_command): Adjust.
1749 * corelow.c (core_detach): Adjust.
1750 * darwin-nat.c (darwin_detach): Adjust.
1751 * gnu-nat.c (gnu_detach): Adjust.
1752 * inf-ptrace.c (inf_ptrace_detach): Adjust.
1753 * infcmd.c (detach_command): Adjust
1754 * infrun.c (follow_fork_inferior): Adjust.
1755 (handle_vfork_child_exec_or_exit): Adjust.
1756 * linux-fork.c (linux_fork_detach): Remove args parameter.
1757 * linux-fork.h (linux_fork_detach): Likewise.
1758 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
1759 * linux-thread-db.c (thread_db_detach): Likewise.
1760 * nto-procfs.c (procfs_detach): Likewise.
1761 * procfs.c (procfs_detach): Likewise.
1762 (do_detach): Remove signo parameter.
1763 * record.c (record_detach): Remove args parameter.
1764 * record.h (record_detach): Likewise.
1765 * remote-sim.c (gdbsim_detach): Likewise.
1766 * remote.c (remote_detach_1): Likewise.
1767 (remote_detach): Likewise.
1768 (extended_remote_detach): Likewise.
1769 * sol-thread.c (sol_thread_detach): Likewise.
1770 * target-delegates.c: Re-generate.
1771 * top.c (struct qt_args) <args>: Remove field.
1772 (kill_or_detach): Don't pass args.
1773 (quit_force): Don't set args.
1774 * windows-nat.c (windows_detach): Remove args parameter.
1776 2018-01-19 Yao Qi <yao.qi@linaro.org>
1778 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
1779 (arm_linux_init_abi): Install it.
1781 2018-01-19 Yao Qi <yao.qi@linaro.org>
1783 * osabi.c (gdb_osabi_names): Extend the regexp for
1784 arm-linux-gnueabihf.
1786 2018-01-18 Yao Qi <yao.qi@linaro.org>
1788 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
1790 (abbrev_table::add_abbrev): Update.
1791 (abbrev_table::lookup_abbrev): Update.
1793 2018-01-18 Yao Qi <yao.qi@linaro.org>
1795 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
1797 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
1799 * compile/compile.c (compile_to_object): Convert "triplet_rx"
1802 2018-01-17 Tom Tromey <tom@tromey.com>
1804 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
1806 2018-01-17 Tom Tromey <tom@tromey.com>
1808 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
1809 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
1810 (create_array_type_with_stride): Update.
1811 * dwarf2read.c (set_die_type): Update.
1813 2018-01-17 Tom Tromey <tom@tromey.com>
1815 * dwarf2read.c (delayed_method_info): Remove typedef.
1816 (dwarf2_cu::method_info): Now a std::vector.
1817 (add_to_method_list): Update.
1818 (free_delayed_list): Remove.
1819 (compute_delayed_physnames): Update.
1820 (process_full_comp_unit, process_full_type_unit): Clear the method
1821 list. Remove cleanups.
1822 (psymtab_include_file_name): Add name_holder parameter. Use
1824 (dwarf_decode_lines): Update.
1826 2018-01-17 Tom Tromey <tom@tromey.com>
1827 Simon Marchi <simon.marchi@ericsson.com>
1829 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
1830 (dwarf2_per_objfile::free_cached_comp_units)
1831 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
1832 (init_cutu_and_read_dies_no_follow): Update.
1833 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
1834 (dwarf2_cu::~dwarf2_cu): New.
1835 (free_heap_comp_unit, free_stack_comp_unit): Remove.
1836 (age_cached_comp_units, free_one_cached_comp_unit): Update.
1838 2018-01-17 Tom Tromey <tom@tromey.com>
1839 Simon Marchi <simon.marchi@ericsson.com>
1841 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
1842 (struct die_reader_specs) <abbrev_table>: New member.
1843 (struct abbrev_table): Add constructor.
1844 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
1845 <abbrev_obstack>: Now an auto_obstack.
1846 (abbrev_table_up): New typedef.
1847 (init_cu_die_reader): Add abbrev_table parameter.
1848 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
1849 Add result_dwo_abbrev_table.
1850 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
1851 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
1853 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
1855 (skip_children): Update.
1856 (abbrev_table::alloc_abbrev): Rename from
1857 abbrev_table_alloc_abbrev.
1858 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
1859 (abbrev_table::lookup_abbrev): Rename from
1860 abbrev_table_lookup_abbrev.
1861 (abbrev_table_read_table): Return abbrev_table_up.
1862 (abbrev_table_free, abbrev_table_free_cleanup)
1863 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
1864 (load_partial_dies): Update.
1866 2018-01-17 Tom Tromey <tom@tromey.com>
1868 * dwarf2read.c (dwarf2_compute_name): Update comment.
1869 (read_func_scope, read_variable): Update.
1870 (new_symbol): Remove.
1871 (new_symbol_full): Rename to new_symbol.
1873 2018-01-17 Mike Gulick <mgulick@mathworks.com>
1876 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
1877 a warning instead of throwing an error, set section size to 0 and return
1879 * gdb_bfd.h (gdb_bfd_map_section): Update description.
1881 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1883 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
1885 (linux_ptrace_attach_fail_reason_string): Likewise.
1886 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
1888 (linux_ptrace_attach_fail_reason_string): Likewise.
1889 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
1891 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1893 * linux-nat.c (linux_nat_attach): Remove xstrdup.
1895 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1898 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1899 checking for fs_base/gs_base fields in struct user_regs_struct.
1900 * configure: Regenerate.
1902 2018-01-17 Yao Qi <yao.qi@linaro.org>
1904 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
1906 (aarch64_linux_init_abi): Install it to gdbarch hook
1909 2018-01-15 Pedro Alves <palves@redhat.com>
1911 * common/signals-state-save-restore.c
1912 (save_original_signals_state): Fix typos.
1914 2017-01-12 Tom Tromey <tom@tromey.com>
1915 Sergio Durigan Junior <sergiodj@redhat.com>
1917 * Makefile.in (install-only): Install gdb-add-index.
1919 2018-01-12 John Baldwin <jhb@FreeBSD.org>
1921 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
1923 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
1925 * infrun.c (keep_going_pass_signal): Clear step-over info when
1926 insert_breakpoints fails.
1928 2018-01-11 Pedro Alves <palves@redhat.com>
1931 * infrun.c (resume): Rename to ...
1932 (resume_1): ... this.
1933 (resume): Reimplement as wrapper around resume_1.
1935 2018-01-11 Pedro Alves <palves@redhat.com>
1938 * remote.c (remote_parse_stop_reply): Default to the last-set
1939 general thread instead of to 'magic_null_ptid'.
1941 2018-01-10 Pedro Alves <palves@redhat.com>
1943 * language.h (language_get_symbol_name_matcher): Rename ...
1944 (get_symbol_name_matcher): ... this.
1945 * language.c (language_get_symbol_name_matcher): Ditto.
1946 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
1949 2018-01-10 Pedro Alves <palves@redhat.com>
1953 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
1954 Adjust to use language_get_symbol_name_matcher instead of
1955 language_defn::la_get_symbol_name_matcher.
1956 * language.c (language_get_symbol_name_matcher): If in Ada mode
1957 and the lookup name is a verbatim match, return Ada's matcher.
1958 * language.h (language_get_symbol_name_matcher): Adjust comment.
1959 (ada_lookup_name_info::verbatim_p):: New method.
1961 2018-01-10 Pedro Alves <palves@redhat.com>
1964 * ada-lang.c (ada_collect_symbol_completion_matches): If the
1965 minsym's language is language_auto or language_cplus, pass down
1966 language_ada instead.
1967 * symtab.c (compare_symbol_name): Don't frob symbol language here.
1969 2018-01-10 Pedro Alves <palves@redhat.com>
1972 * minsyms.c (linkage_name_str): New function.
1973 (iterate_over_minimal_symbols): Use it.
1975 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1977 * NEWS: Document that 'info proc' now works on FreeBSD.
1979 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1981 * configure.ac: Check for kinfo_getfile in libutil.
1982 * configure: Regenerate.
1983 * config.in: Regenerate.
1984 * fbsd-nat.c: Include "fbsd-tdep.h".
1985 (fbsd_fetch_cmdline): New.
1986 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
1987 rather than calling error.
1988 (fbsd_info_proc): New.
1989 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
1990 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
1991 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
1993 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1995 * fbsd-nat.c (struct free_deleter): Remove.
1996 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
1998 2018-01-09 John Baldwin <jhb@FreeBSD.org>
2000 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
2001 NULL for an empty pathname.
2003 2018-01-09 John Baldwin <jhb@FreeBSD.org>
2005 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
2006 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
2007 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
2008 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
2009 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
2010 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
2011 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
2012 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
2013 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
2014 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
2015 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
2016 (fbsd_core_fetch_timeval, fbsd_print_sigset)
2017 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
2018 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
2019 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
2021 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
2023 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
2024 (gnu_xfer_auxv): New function.
2025 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
2028 2018-01-08 Yao Qi <yao.qi@linaro.org>
2029 Simon Marchi <simon.marchi@ericsson.com>
2031 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
2033 (COMMON_OBS): Remove selftest.o.
2034 * configure.ac: Append selftest-arch.c and common/selftest.c to
2035 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
2036 * configure: Re-generated.
2037 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
2039 (maintenance_info_selftests): Likewise.
2041 2018-01-08 Xavier Roirand <roirand@adacore.com>
2043 * ada-valprint.c (val_print_packed_array_elements): Use
2044 proper number of elements when printing an array indexed
2045 by an enumeration type.
2047 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2049 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
2050 (dw2_get_file_names_reader): Adjust.
2051 (lookup_dwo_signatured_type): Adjust.
2052 (lookup_dwp_signatured_type): Adjust.
2053 (lookup_signatured_type): Adjust.
2054 (create_type_unit_group): Adjust.
2055 (get_type_unit_group): Adjust.
2056 (process_psymtab_comp_unit_reader): Adjust.
2057 (build_type_psymtabs_reader): Adjust.
2058 (scan_partial_symbols): Adjust.
2059 (add_partial_symbol): Adjust.
2060 (add_partial_subprogram): Adjust.
2061 (peek_die_abbrev): Adjust.
2062 (fixup_go_packaging): Adjust.
2063 (process_imported_unit_die): Adjust.
2064 (dwarf2_compute_name): Adjust.
2065 (dwarf2_physname): Adjust.
2066 (read_import_statement): Adjust.
2067 (handle_DW_AT_stmt_list): Adjust.
2068 (read_file_scope): Adjust.
2069 (read_func_scope): Adjust.
2070 (read_lexical_block_scope): Adjust.
2071 (read_call_site_scope): Adjust.
2072 (read_variable): Adjust.
2073 (dwarf2_rnglists_process): Adjust.
2074 (dwarf2_ranges_process): Adjust.
2075 (dwarf2_ranges_read): Adjust.
2076 (dwarf2_get_pc_bounds): Adjust.
2077 (dwarf2_record_block_ranges): Adjust.
2078 (dwarf2_add_field): Adjust.
2079 (dwarf2_add_member_fn): Adjust.
2080 (read_structure_type): Adjust.
2081 (process_structure_scope): Adjust.
2082 (read_enumeration_type): Adjust.
2083 (read_array_type): Adjust.
2084 (mark_common_block_symbol_computed): Adjust.
2085 (read_common_block): Adjust.
2086 (read_namespace_type): Adjust.
2087 (read_namespace): Adjust.
2088 (read_module_type): Adjust.
2089 (read_tag_pointer_type): Adjust.
2090 (read_tag_ptr_to_member_type): Adjust.
2091 (read_tag_string_type): Adjust.
2092 (read_subroutine_type): Adjust.
2093 (read_typedef): Adjust.
2094 (read_base_type): Adjust.
2095 (attr_to_dynamic_prop): Adjust.
2096 (read_subrange_type): Adjust.
2097 (read_unspecified_type): Adjust.
2098 (dwarf2_read_abbrevs): Adjust.
2099 (load_partial_dies): Adjust.
2100 (read_partial_die): Adjust.
2101 (find_partial_die): Adjust.
2102 (guess_partial_die_structure_name): Adjust.
2103 (fixup_partial_die): Adjust.
2104 (read_attribute_value): Adjust.
2105 (read_addr_index): Adjust.
2106 (read_addr_index_from_leb128): Adjust.
2107 (read_str_index): Adjust.
2108 (dwarf2_string_attr): Adjust.
2109 (get_debug_line_section): Adjust.
2110 (dwarf_decode_line_header): Adjust.
2111 (lnp_state_machine::check_line_address): Adjust.
2112 (dwarf_decode_lines_1): Adjust.
2113 (dwarf_decode_lines): Adjust.
2114 (dwarf2_start_symtab): Adjust.
2115 (var_decode_location): Adjust.
2116 (new_symbol_full): Adjust.
2117 (dwarf2_const_value_data): Adjust.
2118 (dwarf2_const_value_attr): Adjust.
2119 (dwarf2_const_value): Adjust.
2121 (die_containing_type): Adjust.
2122 (build_error_marker_type): Adjust.
2123 (lookup_die_type): Adjust.
2124 (guess_full_die_structure_name): Adjust.
2125 (anonymous_struct_prefix): Adjust.
2126 (determine_prefix): Adjust.
2127 (dwarf2_name): Adjust.
2128 (follow_die_ref_or_sig): Adjust.
2129 (follow_die_offset): Adjust.
2130 (follow_die_ref): Adjust.
2131 (follow_die_sig_1): Adjust.
2132 (follow_die_sig): Adjust.
2133 (get_signatured_type): Adjust.
2134 (get_DW_AT_signature_type): Adjust.
2135 (decode_locdesc): Adjust.
2136 (dwarf_decode_macros): Adjust.
2137 (cu_debug_loc_section): Adjust.
2138 (fill_in_loclist_baton): Adjust.
2139 (dwarf2_symbol_mark_computed): Adjust.
2140 (init_one_comp_unit): Don't assign
2141 dwarf2_cu::dwarf2_per_objfile.
2142 (set_die_type): Adjust.
2144 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2146 * dwarf2read.c (struct mapped_debug_names): Add constructor.
2147 <dwarf2_per_objfile>: New field.
2148 (dwarf2_per_objfile): Remove global.
2149 (get_dwarf2_per_objfile): New function.
2150 (set_dwarf2_per_objfile): New function.
2151 (dwarf2_build_psymtabs_hard): Change objfile parameter to
2153 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
2154 (read_abbrev_offset): Likewise.
2155 (read_indirect_string): Likewise.
2156 (read_indirect_line_string): Likewise.
2157 (read_indirect_string_at_offset): Likewise.
2158 (read_indirect_string_from_dwz): Likewise.
2159 (dwarf2_find_containing_comp_unit): Change objfile parameter to
2161 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
2162 (create_all_comp_units): Change objfile parameter to
2164 (create_all_type_units): Likewise.
2165 (process_queue): Add dwarf2_per_objfile parameter.
2166 (read_and_check_comp_unit_head): Likewise.
2167 (lookup_dwo_unit_in_dwp): Likewise.
2168 (get_dwp_file): Likewise.
2169 (process_cu_includes): Likewise.
2170 (struct free_dwo_file_cleanup_data): New struct.
2171 (dwarf2_has_info): Use get_dwarf2_per_objfile and
2172 set_dwarf2_per_objfile.
2173 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
2174 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
2175 context, adjust calls.
2176 (dw2_instantiate_symtab): Likewise.
2177 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
2178 (dw2_get_cu): Likewise.
2179 (create_cu_from_index_list): Change objfile parameter to
2181 (create_cus_from_index_list): Get dwarf2_per_objfile from
2182 context, adjust calls.
2183 (create_cus_from_index): Likewise.
2184 (create_signatured_type_table_from_index): Change objfile
2185 parameter to dwarf2_per_objfile.
2186 (create_signatured_type_table_from_debug_names): Change objfile
2187 parameter to dwarf2_per_objfile.
2188 (create_addrmap_from_index): Likewise.
2189 (create_addrmap_from_aranges): Likewise.
2190 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
2191 (dw2_setup): Remove.
2192 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
2194 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
2195 get_dwarf2_per_objfile.
2196 (dw2_forget_cached_source_info): Likewise.
2197 (dw2_map_symtabs_matching_filename): Likewise.
2198 (struct dw2_symtab_iterator) <index>: Remove.
2199 <dwarf2_per_objfile>: New field.
2200 (dw2_symtab_iter_init): Replace index parameter with
2202 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
2203 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
2204 (dw2_print_stats): Likewise.
2205 (dw2_dump): Likewise.
2206 (dw2_expand_symtabs_for_function): Likewise.
2207 (dw2_expand_all_symtabs): Likewise.
2208 (dw2_expand_symtabs_with_fullname): Likewise.
2209 (dw2_expand_marked_cus): Replace index and objfile parameters
2210 with dwarf2_per_objfile.
2211 (dw_expand_symtabs_matching_file_matcher): Add
2212 dwarf2_per_objfile parameter and adjust calls.
2213 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
2215 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
2216 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
2218 (create_cus_from_debug_names_list): Replace objfile parameter
2219 with dwarf2_per_objfile and adjust calls.
2220 (create_cus_from_debug_names): Likewise.
2221 (dwarf2_read_debug_names): Likewise.
2222 (mapped_debug_names::namei_to_name): Adjust call.
2223 (dw2_debug_names_iterator::next): Likewise.
2224 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
2225 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
2226 (dw2_debug_names_dump): Likewise.
2227 (dw2_debug_names_expand_symtabs_for_function): Likewise.
2228 (dw2_debug_names_expand_symtabs_matching): Likewise.
2229 (dwarf2_initialize_objfile): Likewise.
2230 (dwarf2_build_psymtabs): Likewise.
2231 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
2233 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
2234 (read_and_check_comp_unit_head): Likewise.
2235 (read_abbrev_offset): Likewise.
2236 (create_debug_type_hash_table): Likewise.
2237 (create_debug_types_hash_table): Likewise.
2238 (create_all_type_units): Replace objfile parameter with
2240 (add_type_unit): Add dwarf2_per_objfile parameter.
2241 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
2242 with dwarf2_per_objfile.
2243 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
2244 (lookup_dwp_signatured_type): Likewise.
2245 (lookup_signatured_type): Likewise.
2246 (read_cutu_die_from_dwo): Likewise.
2247 (init_tu_and_read_dwo_dies): Likewise.
2248 (init_cutu_and_read_dies): Likewise.
2249 (init_cutu_and_read_dies_no_follow): Likewise.
2250 (allocate_type_unit_groups_table): Add objfile parameter.
2251 (create_type_unit_group): Use dwarf2_per_objfile from cu.
2252 (get_type_unit_group): Likewise.
2253 (process_psymtab_comp_unit): Update call.
2254 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
2255 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
2256 (print_tu_stats): Likewise.
2257 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
2259 (build_type_psymtabs): Change objfile parameter to
2261 (process_skeletonless_type_unit): Use dwarf2_per_objfile
2262 passed in void* parameter.
2263 (process_skeletonless_type_units): Change objfile parameter to
2265 (set_partial_user): Likewise.
2266 (dwarf2_build_psymtabs_hard): Likewise.
2267 (read_comp_units_from_section): Likewise.
2268 (create_all_comp_units): Likewise.
2269 (scan_partial_symbols): Update calls.
2270 (add_partial_symbol): Likewise.
2271 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
2272 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
2273 (process_queue): Add dwarf2_per_objfile parameter.
2274 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
2275 (compute_compunit_symtab_includes): Likewise.
2276 (process_cu_includes): Add dwarf2_per_objfile parameter.
2277 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
2278 (process_full_type_unit): Likewise.
2279 (process_imported_unit_die): Update call.
2280 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
2281 (read_file_scope): Likewise.
2282 (allocate_dwo_file_hash_table): Add objfile parameter.
2283 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
2284 (create_cus_hash_table): Likewise.
2285 (create_dwp_hash_table): Likewise.
2286 (create_dwo_unit_in_dwp_v1): Likewise.
2287 (create_dwp_v2_section): Likewise.
2288 (create_dwo_unit_in_dwp_v2): Likewise.
2289 (lookup_dwo_unit_in_dwp): Likewise.
2290 (try_open_dwop_file): Likewise.
2291 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
2292 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
2293 cleanup to include a reference to dwarf2_per_objfile.
2294 (open_dwp_file): Add dwarf2_per_objfile parameter.
2295 (open_and_init_dwp_file): Likewise.
2296 (get_dwp_file): Likewise.
2297 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
2298 (queue_and_load_all_dwo_tus): Update call.
2299 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
2301 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
2302 (dwarf2_ranges_process): Likewise.
2303 (dwarf2_get_pc_bounds): Likewise.
2304 (mark_common_block_symbol_computed): Likewise.
2305 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
2306 (dwarf2_read_abbrevs): Update call.
2307 (read_partial_die): Use dwarf2_per_objfile from cu.
2308 (find_partial_die): Likewise.
2309 (fixup_partial_die): Likewise.
2310 (read_attribute_value): Likewise.
2311 (read_indirect_string_at_offset_from): Add objfile parameter.
2312 (read_indirect_string_at_offset): Add dwarf2_per_objfile
2314 (read_indirect_string_from_dwz): Add objfile parameter.
2315 (read_indirect_string): Add objfile parameter.
2316 (read_addr_index_1): Add dwarf2_per_objfile parameter.
2317 (read_addr_index): Use dwarf2_per_objfile from cu.
2318 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
2320 (read_str_index): Use dwarf2_per_objfile from cu.
2321 (get_debug_line_section): Likewise.
2322 (read_formatted_entries): Add dwarf2_per_objfile parameter.
2323 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
2324 (new_symbol_full): Use dwarf2_per_objfile from cu.
2325 (build_error_marker_type): Likewise.
2326 (lookup_die_type): Likewise.
2327 (determine_prefix): Likewise.
2328 (follow_die_offset): Likewise.
2329 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
2330 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
2331 (dwarf2_fetch_die_type_sect_off): Likewise.
2332 (dwarf2_get_die_type): Likewise.
2333 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
2334 (get_signatured_type): Likewise.
2335 (get_DW_AT_signature_type): Likewise.
2336 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
2337 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
2338 (cu_debug_loc_section): Likewise.
2339 (fill_in_loclist_baton): Likewise.
2340 (dwarf2_symbol_mark_computed): Likewise.
2341 (dwarf2_find_containing_comp_unit): Change objfile parameter to
2343 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
2345 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
2346 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
2347 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
2348 (set_die_type): Use dwarf2_free_objfile from cu.
2349 (get_die_type_at_offset): Likewise.
2350 (dwarf2_per_objfile_free): Don't assign global variable.
2351 (debug_names) <constructor>: Add dwarf2_per_objfile
2352 parameter, update m_debugstrlookup construction.
2353 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
2355 <m_dwarf2_per_objfile>: New field.
2356 <lookup>: Use m_dwarf2_per_objfile.
2357 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
2358 (psyms_seen_size): Likewise.
2359 (write_gdbindex): Replace objfile parameter with
2361 (write_debug_names): Likewise.
2362 (write_psymtabs_to_index): Likewise.
2363 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
2366 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2368 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
2369 <dwarf2_per_objfile>: New field.
2370 (struct dwarf2_per_cu_data) <objfile>: Remove.
2371 <dwarf2_per_objfile>: New field.
2372 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
2374 (create_signatured_type_table_from_index): Likewise.
2375 (create_debug_type_hash_table): Likewise.
2376 (fill_in_sig_entry_from_dwo_entry): Likewise.
2377 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
2378 (create_type_unit_group): Assign dwarf2_per_objfile instead of
2380 (create_partial_symtab): Access objfile through
2382 (process_psymtab_comp_unit_reader): Likewise.
2383 (read_comp_units_from_section): Likewise.
2384 (scan_partial_symbols): Likewise.
2385 (add_partial_symbol): Likewise.
2386 (add_partial_subprogram): Likewise.
2387 (peek_die_abbrev): Likewise.
2388 (fixup_go_packaging): Likewise.
2389 (process_full_comp_unit): Likewise.
2390 (process_full_type_unit): Likewise.
2391 (process_imported_unit_die): Likewise.
2392 (dwarf2_compute_name): Likewise.
2393 (dwarf2_physname): Likewise.
2394 (read_import_statement): Likewise.
2395 (create_cus_hash_table): Assign dwarf2_physname instead of
2397 (read_func_scope): Access objfile through dwarf2_per_objfile.
2398 (read_lexical_block_scope): Likewise.
2399 (read_call_site_scope): Likewise.
2400 (read_variable): Likewise.
2401 (dwarf2_rnglists_process): Likewise.
2402 (dwarf2_ranges_process): Likewise.
2403 (dwarf2_ranges_read): Likewise.
2404 (dwarf2_record_block_ranges): Likewise.
2405 (dwarf2_add_field): Likewise.
2406 (dwarf2_add_member_fn): Likewise.
2407 (read_structure_type): Likewise.
2408 (process_structure_scope): Likewise.
2409 (read_enumeration_type): Likewise.
2410 (read_array_type): Likewise.
2411 (read_common_block): Likewise.
2412 (read_namespace_type): Likewise.
2413 (read_namespace): Likewise.
2414 (read_module_type): Likewise.
2415 (read_tag_pointer_type): Likewise.
2416 (read_tag_ptr_to_member_type): Likewise.
2417 (read_tag_string_type): Likewise.
2418 (read_subroutine_type): Likewise.
2419 (read_typedef): Likewise.
2420 (read_base_type): Likewise.
2421 (attr_to_dynamic_prop): Likewise.
2422 (read_subrange_type): Likewise.
2423 (read_unspecified_type): Likewise.
2424 (load_partial_dies): Likewise.
2425 (read_partial_die): Likewise.
2426 (find_partial_die): Likewise.
2427 (guess_partial_die_structure_name): Likewise.
2428 (fixup_partial_die): Likewise.
2429 (read_attribute_value): Likewise.
2430 (read_addr_index_from_leb128): Likewise.
2431 (dwarf2_read_addr_index): Likewise.
2432 (dwarf2_string_attr): Likewise.
2433 (lnp_state_machine::check_line_address): Likewise.
2434 (dwarf_decode_lines_1): Likewise.
2435 (dwarf_decode_lines): Likewise.
2436 (dwarf2_start_symtab): Likewise.
2437 (var_decode_location): Likewise.
2438 (new_symbol_full): Likewise.
2439 (dwarf2_const_value_data): Likewise.
2440 (dwarf2_const_value_attr): Likewise.
2441 (dwarf2_const_value): Likewise.
2442 (die_type): Likewise.
2443 (die_containing_type): Likewise.
2444 (lookup_die_type): Likewise.
2445 (guess_full_die_structure_name): Likewise.
2446 (anonymous_struct_prefix): Likewise.
2447 (dwarf2_name): Likewise.
2448 (follow_die_ref_or_sig): Likewise.
2449 (follow_die_offset): Likewise.
2450 (follow_die_ref): Likewise.
2451 (dwarf2_fetch_die_loc_sect_off): Likewise.
2452 (dwarf2_fetch_constant_bytes): Likewise.
2453 (dwarf2_fetch_die_type_sect_off): Likewise.
2454 (dwarf2_get_die_type): Likewise.
2455 (follow_die_sig): Likewise.
2456 (decode_locdesc): Likewise.
2457 (dwarf2_per_cu_objfile): Likewise.
2458 (dwarf2_per_cu_text_offset): Likewise.
2459 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
2461 (set_die_type): Access objfile through
2464 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2466 * valprint.c (converted_character_d): Remove typedef.
2467 (DEF_VEC_O (converted_character_d)): Remove.
2468 (count_next_character): Use std::vector.
2469 (print_converted_chars_to_obstack): Likewise.
2470 (generic_printstr): Likewise.
2472 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2474 * xml-support.h (struct gdb_xml_value): Add constructor.
2475 <value>: Change type to unique_xmalloc_ptr.
2476 (gdb_xml_value_s): Remove typedef.
2477 (DEF_VEC_O (gdb_xml_value_s)): Remove.
2478 (gdb_xml_element_start_handler): Change parameter type to
2480 (xml_find_attribute): Likewise.
2481 * xml-support.c (xml_find_attribute): Change parameter type to
2482 std::vector and adjust.
2483 (gdb_xml_values_cleanup): Remove.
2484 (gdb_xml_parser::start_element): Adjust to std::vector.
2485 (xinclude_start_include): Change paraeter type to std::vector
2487 * btrace.c (check_xml_btrace_version): Likewise.
2488 (parse_xml_btrace_block): Likewise.
2489 (parse_xml_btrace_pt_config_cpu): Likewise.
2490 (parse_xml_btrace_pt): Likewise.
2491 (parse_xml_btrace_conf_bts): Likewise.
2492 (parse_xml_btrace_conf_pt): Likewise.
2493 * memory-map.c (memory_map_start_memory): Likewise.
2494 (memory_map_start_property): Likewise.
2495 * osdata.c (osdata_start_osdata): Likewise.
2496 (osdata_start_item): Likewise.
2497 (osdata_start_column): Likewise.
2498 * remote.c (start_thread): Likewise.
2499 * solib-aix.c (library_list_start_library): Likewise.
2500 (library_list_start_list): Likewise.
2501 * solib-svr4.c (library_list_start_library): Likewise.
2502 (svr4_library_list_start_list): Likewise.
2503 * solib-target.c (library_list_start_segment): Likewise.
2504 (library_list_start_section): Likewise.
2505 (library_list_start_library): Likewise.
2506 (library_list_start_list): Likewise.
2507 * tracepoint.c (traceframe_info_start_memory): Likewise.
2508 (traceframe_info_start_tvar): Likewise.
2509 * xml-syscall.c (syscall_start_syscall): Likewise.
2510 * xml-tdesc.c (tdesc_start_target): Likewise.
2511 (tdesc_start_feature): Likewise.
2512 (tdesc_start_reg): Likewise.
2513 (tdesc_start_union): Likewise.
2514 (tdesc_start_struct): Likewise.
2515 (tdesc_start_flags): Likewise.
2516 (tdesc_start_enum): Likewise.
2517 (tdesc_start_field): Likewise.
2518 (tdesc_start_enum_value): Likewise.
2519 (tdesc_start_vector): Likewise.
2521 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2523 * extension.h (struct xmethod_worker) <clone>: Remove.
2524 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
2526 (python_xmethod_worker::clone): Remove.
2527 * valops.c (find_overload_match): Use std::move instead of
2530 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2532 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
2533 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
2534 <free_xmethod_worker_data>: Remove.
2535 <get_matching_xmethod_workers>: Chance VEC to std::vector.
2536 <get_xmethod_arg_types>: Remove.
2537 <get_xmethod_result_type>: Remove.
2538 <invoke_xmethod>: Remove.
2539 * extension.c (new_xmethod_worker): Remove.
2540 (clone_xmethod_worker): Remove.
2541 (get_matching_xmethod_workers): Return void, pass std::vector by
2543 (get_xmethod_arg_types): Rename to...
2544 (xmethod_worker::get_arg_types): ... this, and adjust.
2545 (get_xmethod_result_type): Rename to...
2546 (xmethod_worker::get_result_type): ... this, and adjust.
2547 (invoke_xmethod): Remove.
2548 (free_xmethod_worker): Remove.
2549 (free_xmethod_worker_vec): Remove.
2550 * extension.h (enum ext_lang_rc): Move here from
2552 (struct xmethod_worker): Add constructor and destructor.
2555 <invoke, clone, do_get_result_type, do_get_arg_types>: New
2556 virtual pure methods.
2557 <get_arg_types, get_result_type>: New methods.
2558 (xmethod_worker_ptr): Remove typedef.
2559 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
2560 (xmethod_worker_vec): Remove typedef.
2561 (xmethod_worker_up): New typedef.
2562 (invoke_xmethod): Remove.
2563 (clone_xmethod_worker): Remove.
2564 (free_xmethod_worker): Remove.
2565 (free_xmethod_worker_vec): Remove.
2566 (get_xmethod_arg_types): Remove.
2567 (get_xmethod_result_type): Remove.
2568 * valops.c (find_method_list): Use std::vector, don't use
2569 intermediate vector.
2570 (value_find_oload_method_list): Use std::vector.
2571 (find_overload_match): Use std::vector.
2572 (find_oload_champ): Use std::vector.
2573 * value.c (value_free): Use operator delete.
2574 (value_of_xmethod): Rename to...
2575 (value_from_xmethod): ... this. Don't assign
2576 xmethod_worker::value, take rvalue-reference.
2577 (result_type_of_xmethod): Adjust.
2578 (call_xmethod): Adjust.
2579 * value.h: Include extension.h.
2580 (struct xmethod_worker): Don't forward-declare.
2581 (value_of_xmethod): Rename to...
2582 (value_from_xmethod): ... this, take rvalue-reference.
2583 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
2584 (struct python_xmethod_worker): ... this, add constructor and
2586 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
2587 (gdbpy_free_xmethod_worker_data): Rename to...
2588 (python_xmethod_worker::~python_xmethod_worker): ... this and
2590 (gdbpy_clone_xmethod_worker_data): Rename to...
2591 (python_xmethod_worker::clone): ... this and adjust.
2592 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
2594 (gdbpy_get_xmethod_arg_types): Rename to...
2595 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
2596 (gdbpy_get_xmethod_result_type): Rename to...
2597 (python_xmethod_worker::do_get_result_type): ... this and
2599 (gdbpy_invoke_xmethod): Rename to...
2600 (python_xmethod_worker::invoke): ... this and adjust.
2601 (new_python_xmethod_worker): Rename to...
2602 (python_xmethod_worker::python_xmethod_worker): ... this and
2604 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
2606 (gdbpy_free_xmethod_worker_data): Remove.
2607 (gdbpy_get_matching_xmethod_workers): Use std::vector.
2608 (gdbpy_get_xmethod_arg_types): Remove.
2609 (gdbpy_get_xmethod_result_type): Remove.
2610 (gdbpy_invoke_xmethod): Remove.
2611 * python/python.c (python_extension_ops): Remove obsolete
2614 2018-01-05 Pedro Alves <palves@redhat.com>
2617 * common/signals-state-save-restore.c
2618 (save_original_signals_state): New parameter 'quiet'. Warn if we
2619 find a custom handler preinstalled, instead of internal erroring.
2620 But only warn if !quiet.
2621 * common/signals-state-save-restore.h
2622 (save_original_signals_state): New parameter 'quiet'.
2623 * main.c (captured_main_1): Move save_original_signals_state call
2624 after option handling, and pass QUIET.
2626 2018-01-05 Pedro Alves <palves@redhat.com>
2628 * spu-tdep.c (spu_catch_start): Pass
2629 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
2631 2018-01-05 Pedro Alves <palves@redhat.com>
2634 * ada-lang.c (literal_symbol_name_matcher): New function.
2635 (ada_get_symbol_name_matcher): Use it for
2636 symbol_name_match_type::SEARCH_NAME.
2637 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
2638 it down instead of assuming symbol_name_match_type::FULL.
2639 * block.h (block_lookup_symbol): New parameter 'match_type'.
2640 * c-valprint.c (print_unpacked_pointer): Use
2641 lookup_symbol_search_name instead of lookup_symbol.
2642 * compile/compile-object-load.c (get_out_value_type): Pass down
2643 symbol_name_match_type::SEARCH_NAME.
2644 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
2645 symbol_name_match_type::FULL.
2646 * cp-support.c (cp_get_symbol_name_matcher): Handle
2647 symbol_name_match_type::SEARCH_NAME.
2648 * infrun.c (insert_exception_resume_breakpoint): Use
2649 lookup_symbol_search_name.
2650 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
2651 * psymtab.c (maintenance_check_psymtabs): Use
2652 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
2653 * stack.c (print_frame_args): Use lookup_symbol_search_name and
2655 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
2656 if symbol_name_match_type::SEARCH_NAME.
2657 (lookup_symbol_in_language): Pass down
2658 symbol_name_match_type::FULL.
2659 (lookup_symbol_search_name): New.
2660 (lookup_language_this): Pass down
2661 symbol_name_match_type::SEARCH_NAME.
2662 (lookup_symbol_aux, lookup_local_symbol): New parameter
2663 'match_type'. Pass it down.
2664 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
2665 (lookup_symbol_search_name): New declaration.
2666 (lookup_symbol_in_block): New 'match_type' parameter.
2668 2018-01-05 Pedro Alves <palves@redhat.com>
2671 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
2673 (ada_lookup_symbol): Reimplement in terms of
2674 ada_lookup_symbol_list, bits factored out from
2675 ada_lookup_encoded_symbol.
2677 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2679 * ada-exp.y (write_object_renaming): When subscripting an array
2680 using a symbol as the index, pass the block in call to
2681 ada_lookup_encoded_symbol when looking that symbol up.
2683 2018-01-05 Jerome Guitton <guitton@adacore.com>
2685 * ada-lang.c (ada_array_length): Use ada_index_type instead of
2688 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2690 * ada-lang.c (ada_to_fixed_value_create): Add handling of
2691 the case where VALUE_LVAL (val0) is not lval_memory.
2693 2018-01-05 Xavier Roirand <roirand@adacore.com>
2695 * ada-valprint.c (print_optional_low_bound): Handle
2696 character-indexed array printing like boolean-indexed array
2699 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2701 * NEWS: Create a new section for the next release branch.
2702 Rename the section of the current branch, now that it has
2705 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2707 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
2708 * version.in: Bump version to 8.1.50.DATE-git.
2710 2018-01-03 Xavier Roirand <roirand@adacore.com>
2712 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
2714 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
2716 (default_exception_support_info) <catch_handlers_sym>: Add field.
2717 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
2718 (ada_exception_name_addr_1): Add "catch handlers" handling.
2719 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
2721 (create_excep_cond_exprs) <ex>: Add parameter.
2722 (re_set_exception): Update create_excep_cond_exprs call.
2723 (print_it_exception, print_one_exception, print_mention_exception)
2724 (print_recreate_exception): Add "catch handler" handling.
2725 (allocate_location_catch_handlers, re_set_catch_handlers)
2726 (check_status_catch_handlers, print_it_catch_handlers)
2727 (print_one_catch_handlers, print_mention_catch_handlers)
2728 (print_recreate_catch_handlers): New function.
2729 (catch_handlers_breakpoint_ops): New variable.
2730 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
2731 Add parameter. Add "catch handler" handling.
2732 (ada_exception_sym_name, ada_exception_breakpoint_ops):
2733 Add "catch handler" handling.
2734 (ada_exception_catchpoint_cond_string): Add "catch handler"
2736 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
2738 (catch_ada_handlers_command): New function.
2739 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
2740 operations structure.
2741 (_initialize_ada_language): Add "catch handlers" command entry.
2742 * NEWS: Document "catch handlers" feature.
2744 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2746 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
2747 account when creating the array type of the slice.
2748 (ada_value_slice): Likewise.
2750 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2752 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
2754 (create_array_type_with_stride): Add byte_stride_prop parameter.
2755 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
2756 New parameter. Update all callers in this file.
2757 (array_type_has_dynamic_stride): New function.
2758 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
2759 of arrays with dynamic byte strides.
2760 * dwarf2read.c (read_array_type): Add support for dynamic
2761 DW_AT_byte_stride attributes.
2763 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2765 * dwarf2read.c (read_unspecified_type): Treat
2766 DW_TAG_enumeration_type DIEs from Ada units as stubs.
2768 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2770 Update copyright year range in all GDB files.
2772 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2774 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
2775 and gdb/testsuite/gdb.base/step-line.c.
2777 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2779 * copyright.py (main): Dump the contents of
2780 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
2781 even if BY_HAND is empty.
2783 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2785 * top.c (print_gdb_version): Update Copyright year in version
2788 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2790 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
2792 For older changes see ChangeLog-2017.
2798 version-control: never