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