Make gdbserver reg_defs a vector of objects
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
5cd3e386
AH
12018-03-26 Alan Hayward <alan.hayward@arm.com>
2
3 * regformats/regdef.h (reg): Add constructors.
4
3e5ef9a4
PA
52018-03-25 Pedro Alves <palves@redhat.com>
6
7 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8 if then/else bodies in var_func_name extraction.
9
c88d2fcc 102018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
11
12 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
13 lookup_minimal_symbol() to find symbol entry.
14 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
15
b7fee5a3
KS
162018-03-23 Keith Seitz <keiths@redhat.com>
17
18 PR c++/22968
19 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
20 nested type definitions for C++, too.
21
2cc9b304
TT
222018-03-23 Tom Tromey <tom@tromey.com>
23
24 * machoread.c (struct oso_el): Add a constructor. Don't define as
25 a typedef.
26 (macho_register_oso): Remove.
27 (macho_symtab_read): Take a std::vector.
28 (oso_el_compare_name): Now a std::sort comparator.
29 (macho_symfile_read_all_oso): Take a std::vector.
30 (macho_symfile_read): Use std::vector. Remove cleanups.
31
a2b2bc12
TT
322018-03-22 Tom Tromey <tom@tromey.com>
33
34 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
35 (record_full_goto_bookmark): Use std::string.
36
7a8f494c
PFC
372018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
38
39 PR tdep/18295
40 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
41 a single mask.
42
dd6d677f
PFC
432018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
44
45 * rs6000-tdep.c (store_insn_p): New function.
46 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
47 and cr_reg to their unshifted values. Use store_insn_p to
48 match LR saves using either R1 or fdata->alloca_reg. Use
49 store_insn_p to match CR saves. Set alloca_reg_offset
50 when alloca_reg and framep are set. Remove lr_reg shift
51 when assigning to fdata->lr_register.
52
26d6cec4
AA
532018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
54
55 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
56 command line args instead of emitting a warning.
57
5d9310c4
SM
582018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
59
60 * tracepoint.h (struct static_tracepoint_marker): Initialize
61 fields, define default constructor, move constructor and move
62 assignment, disable the rest.
63 <str_id, extra>: Make std::string.
64 (release_static_tracepoint_marker): Remove.
65 (free_current_marker): Remove.
66 * tracepoint.c (free_current_marker): Remove.
67 (parse_static_tracepoint_marker_definition): Adjust to
68 std::string, use new hex2str overload.
69 (release_static_tracepoint_marker): Remove.
70 (print_one_static_tracepoint_marker): Get marker by reference
71 and adjust to std::string.
72 (info_static_tracepoint_markers_command): Adjust to std::vector
73 changes
74 * target.h (static_tracepoint_marker_p): Remove typedef.
75 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
76 (struct target_ops) <to_static_tracepoint_marker_at>: Return
77 bool.
78 <to_static_tracepoint_markers_by_strid>: Return std::vector.
79 * target-debug.h
80 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
81 (target_debug_print_std_vector_static_tracepoint_marker): New.
82 (target_debug_print_struct_static_tracepoint_marker_p): Rename
83 to...
84 (target_debug_print_static_tracepoint_marker_p): ... this.
85 * target-delegates.c: Re-generate.
86 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
87 Make std::string.
88 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
89 (decode_static_tracepoint_spec): Adjust to std::vector.
90 (tracepoint_print_one_detail): Adjust to std::string.
91 (strace_marker_decode_location): Adjust to std::string.
92 (update_static_tracepoint): Adjust to std::string, remove call
93 to release_static_tracepoint_marker.
94 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
95 Adjust to std::vector.
96 * remote.c (remote_static_tracepoint_marker_at): Return bool.
97 (remote_static_tracepoint_markers_by_strid): Adjust to
98 std::vector.
99 * common/rsp-low.h (hex2str): New overload with explicit count
100 of bytes.
101 * common/rsp-low.c (hex2str): New overload with explicit count
102 of bytes.
103 * unittests/rsp-low-selftests.c (test_hex2str): New function.
104 (_initialize_rsp_low_selftests): Add test_hex2str test.
105 * unittests/tracepoint-selftests.c
106 (test_parse_static_tracepoint_marker_definition): Adjust to
107 std::string.
108
62c222b6
SM
1092018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
110
111 * tracepoint.c (parse_static_tracepoint_marker_definition):
112 Consider case where the definition is followed by more
113 definitions.
114 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
115 tracepoint-selftests.c.
116 * unittests/tracepoint-selftests.c: New.
117
7eb2418f
PFC
1182018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
119
120 * MAINTAINERS (Write After Approval): Add Pedro Franco de
121 Carvalho.
122
7cbe16e9
SR
1232018-03-20 Stephen Roberts <stephen.roberts@arm.com>
124
125 * gdb/symtab.c (find_pc_sect_line): fixed indentation.
126
4ee89e90
SR
1272018-03-20 Stephen Roberts <stephen.roberts@arm.com>
128
129 * gdb/symtab.c (find_pc_sect_line): now uses binary search.
130
92630041
TT
1312018-03-19 Tom Tromey <tom@tromey.com>
132
133 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
134 "IDENT" production.
135
76727919
TT
1362018-03-19 Pedro Alves <palves@redhat.com>
137 Tom Tromey <tom@tromey.com>
138
139 * unittests/observable-selftests.c: New file.
140 * common/observable.h: New file.
141 * observable.h: New file.
142 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
143 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
144 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
145 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
146 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
147 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
148 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
149 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
150 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
151 python/py-breakpoint.c, python/py-finishbreakpoint.c,
152 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
153 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
154 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
155 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
156 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
157 tui/tui-interp.c, valops.c: Update all users.
158 * tui/tui-hooks.c (tui_bp_created_observer)
159 (tui_bp_deleted_observer, tui_bp_modified_observer)
160 (tui_inferior_exit_observer, tui_before_prompt_observer)
161 (tui_normal_stop_observer, tui_register_changed_observer):
162 Remove.
163 (tui_observers_token): New global.
164 (attach_or_detach, tui_attach_detach_observers): New functions.
165 (tui_install_hooks, tui_remove_hooks): Use
166 tui_attach_detach_observers.
167 * record-btrace.c (record_btrace_thread_observer): Remove.
168 (record_btrace_thread_observer_token): New global.
169 * observer.sh: Remove.
170 * observer.c: Rename to observable.c.
171 * observable.c (namespace gdb_observers): Define new objects.
172 (observer_debug): Move into gdb_observers namespace.
173 (struct observer, struct observer_list, xalloc_observer_list_node)
174 (xfree_observer_list_node, generic_observer_attach)
175 (generic_observer_detach, generic_observer_notify): Remove.
176 (_initialize_observer): Update.
177 Don't include observer.inc.
178 * Makefile.in (generated_files): Remove observer.h, observer.inc.
179 (clean mostlyclean): Likewise.
180 (observer.h, observer.inc): Remove targets.
181 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
182 (COMMON_SFILES): Use observable.c, not observer.c.
183 * .gitignore: Remove observer.h.
184
1cb1f3da
TT
1852018-03-18 Tom Tromey <tom@tromey.com>
186
187 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
188 gdb::def_vector.
189 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
190
a06ab151
TT
1912018-03-17 Tom Tromey <tom@tromey.com>
192
193 * auto-load.c (auto_load_objfile_script_1): Use std::string.
194
770623f7
TT
1952018-03-17 Tom Tromey <tom@tromey.com>
196
197 * target.c (class scoped_target_fd): New.
198 (target_fileio_close_cleanup): Remove.
199 (target_fileio_read_alloc_1): Use scoped_target_fd.
200
39be3c7e
SM
2012018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
202
203 * silent-rules.mk: New.
204 * Makefile.in: Include silent-rules.mk
205 (srcdir, VPATH, top_srcdir): Move up.
206 (COMPILE): Add ECHO_CXX.
207 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
208 (init.c): Add ECHO_INIT_C.
209 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
210 (version.c): Add ECHO_GEN.
211 (printcmd.o): Add ECHO_CXX.
212 (target-float.o): Add ECHO_CXX.
213 (ada-exp.o): Add ECHO_CXX.
214 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
215 (insight$(EXEEXT)): Add ECHO_CXXLD.
216 * gnulib/configure.ac: Add AM_SILENT_RULES.
217 * gnulib/aclocal.m4: Re-generate.
218 * gnulib/configure: Re-generate.
219 * gnulib/import/Makefile.in: Re-generate.
220
37e136b1
TT
2212018-03-16 Tom Tromey <tom@tromey.com>
222
223 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
224 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
225 * utils.c (do_free_section_addr_info)
226 (make_cleanup_free_section_addr_info): Remove.
227 * symfile.h (struct other_sections): Add constructor.
228 (struct section_addr_info): Remove.
229 (section_addr_info): New typedef.
230 (struct sym_fns) <sym_offsets>: Change type of parameter.
231 (build_section_addr_info_from_objfile)
232 (relative_addr_info_to_section_offsets, addr_info_make_relative)
233 (default_symfile_offsets, symbol_file_add)
234 (symbol_file_add_from_bfd)
235 (build_section_addr_info_from_section_table): Update.
236 (alloc_section_addr_info, free_section_addr_info): Don't declare.
237 * symfile.c (alloc_section_addr_info): Remove.
238 (build_section_addr_info_from_section_table): Change return type.
239 Update.
240 (build_section_addr_info_from_bfd)
241 (build_section_addr_info_from_objfile): Likewise.
242 (free_section_addr_info): Remove.
243 (relative_addr_info_to_section_offsets): Change type of "addrs".
244 (addrs_section_compar): Now a std::sort comparator.
245 (addrs_section_sort): Change return type.
246 (addr_info_make_relative): Change type of "addrs". Update.
247 (default_symfile_offsets, syms_from_objfile_1)
248 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
249 (symbol_file_add_separate): Update.
250 (symbol_file_add): Change type of "addrs". Update.
251 (add_symbol_file_command): Update. Remove cleanups.
252 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
253 cleanups.
254 * symfile-debug.c (debug_sym_offsets): Change type of "info".
255 * solib.c (solib_read_symbols): Update.
256 * objfiles.c (objfile_relocate): Update. Remove cleanups.
257 * machoread.c (macho_symfile_offsets): Update.
258 * jit.c (jit_bfd_try_read_symtab): Update.
259
03afa6ef
SM
2602018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
261
262 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
263 unittests/utils-selftests.c.
264 * unittests/utils-selftests.c: New file.
265
3ae9ce5d
TT
2662018-03-14 Tom Tromey <tom@tromey.com>
267
268 PR cli/14977:
269 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
270 for NULL.
271
b8c2339b
TT
2722018-03-14 Tom Tromey <tom@tromey.com>
273
274 PR cli/19918:
275 * printcmd.c (printf_pointer): Allow "-" in format.
276
80ae639d
TT
2772018-03-14 Tom Tromey <tom@tromey.com>
278
279 * printcmd.c (_initialize_printcmd): Add usage to printf.
280
0d671d99
YQ
2812018-03-14 Yao Qi <qiyao@sourceware.org>
282
283 * MAINTAINERS: Update my email address.
284
b577b6af
TT
2852018-03-13 Tom Tromey <tom@tromey.com>
286
287 * machoread.c (macho_check_dsym): Change filenamep to a
288 std::string*.
289 (macho_symfile_read): Update.
290 * symfile.c (load_command): Use std::string.
291
89a3b63e
AB
2922018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
293
294 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
295 to error message string.
296 (riscv_register_name): Use xsnprintf instead of sprintf.
297 (riscv_insn::fetch_instruction): Use gdb_assert instead of
298 internal_error.
299 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
300 error.
301 (riscv_push_dummy_call): Likewise.
302
984c7238
TT
3032018-03-12 Tom Tromey <tom@tromey.com>
304
305 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
306 Use gdb::byte_vector.
307 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
308
933522d1
YQ
3092018-03-12 Yao Qi <yao.qi@linaro.org>
310
311 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
312 parameter type to readable_regcache.
313 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
314 the declaration.
315
be2daae6
TT
3162018-03-11 Tom Tromey <tom@tromey.com>
317
318 * dwarf2read.c (struct nextfield): Add initializers.
319 (struct nextfnfield): Remove.
320 (struct fnfieldlist): Add initializers. Remove "length" and
321 "head", use std::vector.
322 (struct decl_field_list): Remove.
323 (struct field_info): Add initializers.
324 <fields, baseclasses>: Now std::vector.
325 <nbaseclasses, nfnfields, typedef_field_list_count,
326 nested_types_list_count>: Remove.
327 (dwarf2_add_field, dwarf2_add_type_defn)
328 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
329 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
330 (process_structure_scope): Update.
331
484cf504
TT
3322018-03-11 Tom Tromey <tom@tromey.com>
333
334 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
335 for use by std::sort.
336 (build_type_psymtabs_1): Use std::vector.
337
9bd8e0b0
EZ
3382018-03-09 Eli Zaretskii <eliz@gnu.org>
339
340 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
341 and LIBMPFR in the printed configuration.
342
5dc1a704
TT
3432018-03-08 Tom Tromey <tom@tromey.com>
344
345 * source.c (get_filename_and_charpos): Use scoped_fd.
346 * nto-procfs.c (procfs_open_1): Use scoped_fd.
347 (procfs_pidlist): Likewise.
348 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
349 (iterate_over_mappings): Likewise.
350
fdf07f3a
TT
3512018-03-08 Tom Tromey <tom@tromey.com>
352
353 * infcall.c (struct call_return_meta_info)
354 <stack_temporaries_enabled>: Remove.
355 (get_call_return_value, call_function_by_hand_dummy): Update.
356 * thread.c (disable_thread_stack_temporaries): Remove.
357 (enable_thread_stack_temporaries): Remove.
358 (thread_stack_temporaries_enabled_p): Return bool.
359 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
360 (get_last_thread_stack_temporary): Update.
361 * eval.c (evaluate_subexp): Update.
362 * gdbthread.h (class enable_thread_stack_temporaries): Now a
363 class, not a function.
364 (value_ptr, value_vec): Remove typedefs.
365 (class thread_info) <stack_temporaries_enabled>: Now bool.
366 <stack_temporaries>: Now a std::vector.
367 (thread_stack_temporaries_enabled_p)
368 (value_in_thread_stack_temporaries): Return bool.
369
567a3e54
SM
3702018-03-08 Simon Marchi <simon.marchi@ericsson.com>
371
372 * remote.c (putpkt_binary): Fix omitted bytes reporting.
373 (getpkt_or_notif_sane_1): Likewise.
374
00b40057
SM
3752018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
376
377 * build-id.c (build_id_to_debug_bfd): Use std::string.
378
a8dbfd58
SM
3792018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
380
381 * build-id.c (find_separate_debug_file_by_buildid): Return
382 std::string.
383 * build-id.h (find_separate_debug_file_by_buildid): Return
384 std::string.
385 * coffread.c (coff_symfile_read): Adjust to std::string.
386 * elfread.c (elf_symfile_read): Adjust to std::string.
387 * symfile.c (separate_debug_file_exists): Change parameter to
388 std::string.
389 (find_separate_debug_file): Return std::string.
390 (find_separate_debug_file_by_debuglink): Return std::string.
391 * symfile.h (find_separate_debug_file_by_debuglink): Return
392 std::string.
393
e6a58aa8
SM
3942018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
395
396 * common/xml-utils.c (xml_escape_text): Move code to...
397 (xml_escape_text_append): ... this new function.
398 * common/xml-utils.h (xml_escape_text_append): New declaration.
399 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
400 New function.
401 (_initialize_xml_utils): register test_xml_escape_text_append as
402 a selftest.
403
4ef0bef6
AH
4042018-03-07 Alan Hayward <alan.hayward@arm.com>
405
406 * defs.h: Remove MAX_REGISTER_SIZE.
407 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
408 asserts.
409 * python/py-unwind.c (pyuw_sniffer): Likewise.
410
e0d3522b
TT
4112018-03-07 Tom Tromey <tom@tromey.com>
412
413 * linux-tdep.c (linux_info_proc): Update.
414 * target.h (struct target_ops) <to_fileio_readlink>: Return
415 optional<string>.
416 (target_fileio_readlink): Return optional<string>.
417 * remote.c (remote_hostio_readlink): Return optional<string>.
418 * inf-child.c (inf_child_fileio_readlink): Return
419 optional<string>.
420 * target.c (target_fileio_readlink): Return optional<string>.
421
ea005f31
AB
4222018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
423
424 * regcache.c (cooked_read_test): Add riscv to the list of
425 architectures that have a save_reggroup.
426
e95a97d4
AA
4272018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
428
429 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
430 value is not a dynamic class object.
431
d8344f3d
TT
4322018-03-06 Tom Tromey <tom@tromey.com>
433
434 * rust-exp.y: Formatting fixes.
435
9add17f2
AB
4362018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
437
438 * riscv-tdep.c (riscv_register_name): Remove target description
439 support.
440 (riscv_gdbarch_init): Remove target description check.
441
c9486dfe
AB
4422018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
443
444 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
445 comment.
446 * riscv-tdep.h: Likewise.
447
d74aff3d
AB
4482018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
449
450 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
451 (riscv_pseudo_register_write): Delete.
452 (riscv_gdbarch_init): Remove all use of pseudo registers.
453
7ea78b59
SM
4542018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
455
456 * record-btrace.c (btrace_print_lines): Replace cleanup
457 parameter with RAII equivalents.
458 (btrace_insn_history): Replace cleanup with RAII equivalents.
459 * ui-out.h (make_cleanup_ui_out_list_begin_end,
460 make_cleanup_ui_out_tuple_begin_end): Remove.
461 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
462 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
463 make_cleanup_ui_out_list_begin_end): Remove.
464
53127008
SM
4652018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
466
467 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
468 parameter types to std::vector. Use bool.
469 (record_btrace_wait): Replace VEC(tp_t) with
470 std::vector<thread_info *>.
471 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
472
228f1508
SM
4732018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
474
475 * record-btrace.c (record_btrace_disable_callback): Remove.
476 (struct scoped_btrace_disable): New.
477 (record_btrace_open): Use scoped_btrace_disable.
478
b2970c23
AB
4792018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
480
481 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
482 reading values from registers.
483
fb294655
AB
4842018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
485
486 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
487 where appropriate.
488
cab5bb9d
AB
4892018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
490
491 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
492 change parameter type. Use GDB's print functions, and use
493 core_addr_to_string where appropriate.
494 (riscv_push_dummy_call): Use core_addr_to_string where
495 appropriate, update call to riscv_print_arg_location, and reindent
496 a few lines.
497 (riscv_return_value): Update call to riscv_print_arg_location.
498
dbbb1059
AB
4992018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
500 Tim Newsome <tim@sifive.com>
501 Albert Ou <a0u@eecs.berkeley.edu>
502 Darius Rad <darius@bluespec.com>
503
504 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
505 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
506 (ALLDEPFILES): Add riscv-tdep.c
507 * configure.tgt: Add riscv support.
508 * riscv-tdep.c: New file.
509 * riscv-tdep.h: New file.
510 * NEWS: Mention new target.
511 * MAINTAINERS: Add entry for riscv.
512
5dc43913
AB
5132018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
514
515 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
516 fields within aggregates.
517
3dea1ef7
SM
5182018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
519
520 * record-btrace.c (btrace_print_lines): Change type of flags to
521 gdb_disassembly_flags.
522
7efba073
JB
5232018-03-04 John Baldwin <jhb@FreeBSD.org>
524
525 * fbsd-nat.c: Include "inf-ptrace.h".
526 (USE_SIGTRAP_SIGINFO): Conditionally define.
527 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
528 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
529 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
530 function.
531 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
532 Likewise.
533 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
534 Likewise.
535 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
536 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
537 "supports_stopped_by_hw_breakpoint" target methods.
538
386a8676
JB
5392018-03-04 John Baldwin <jhb@FreeBSD.org>
540
541 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
542 * fbsd-nat.c (debug_fbsd_nat): New variable.
543 (show_fbsd_nat_debug): New function.
544 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
545 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
546
12279366
JB
5472018-03-04 John Baldwin <jhb@FreeBSD.org>
548
549 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
550 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
551 prototype.
552 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
553 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
554 method.
555
54693cf5
SM
5562018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
557
558 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
559 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
560
ccb2231c
SM
5612018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
562
563 * charset.c (struct charset_vector): New.
564 (charsets): Change type to charset_vector.
565 (find_charset_names): Adjust.
566 (add_one): Adjust.
567 (_initialize_charset): Adjust.
568
6fb16ce6
SM
5692018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
570
571 * progspace.h (struct program_space) <deleted_solibs>: Change
572 type to std::vector<std::string>.
573 * progspace.c (clear_program_space_solib_cache): Adjust.
574 * breakpoint.c (print_solib_event): Adjust.
575 (check_status_catch_solib): Adjust.
576 * solib.c (update_solib_list): Adjust.
577 * ui-out.h (class ui_out) <field_string>: New overload.
578 * ui-out.c (ui_out::field_string): New overload.
579
564b1e3f
SM
5802018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
581
582 * progspace.h (struct program_space): Add constructor and
583 destructor, initialize fields.
584 (add_program_space): Remove.
585 * progspace.c (add_program_space): Rename to...
586 (program_space::program_space): ... this.
587 (release_program_space): Rename to...
588 (program_space::~program_space): ... this.
589 (delete_program_space): Use delete to delete program_space.
590 (initialize_progspace): Use new to allocate program_space.
591 * inferior.c (add_inferior_with_spaces): Likewise.
592 (clone_inferior_command): Likewise.
593 * infrun.c (follow_fork_inferior): Likewise.
594 (handle_vfork_child_exec_or_exit): Likewise.
595
e80aaf61
SM
5962018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
597
598 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
599 (delim_string_to_char_ptr_vec): Return std::vector of
600 gdb::unique_xmalloc_ptr.
601 (dirnames_to_char_ptr_vec_append): Take std::vector of
602 gdb::unique_xmalloc_ptr.
603 (dirnames_to_char_ptr_vec): Return std::vector of
604 gdb::unique_xmalloc_ptr.
605 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
606 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
607 (delim_string_to_char_ptr_vec): Return an std::vector of
608 gdb::unique_xmalloc_ptr, adjust the code.
609 (dirnames_to_char_ptr_vec_append): Take an std::vector of
610 gdb::unique_xmalloc_ptr, adjust the code.
611 (dirnames_to_char_ptr_vec): Return an std::vector of
612 gdb::unique_xmalloc_ptr, adjust the code.
613 * auto-load.c (auto_load_safe_path_vec): Change type to
614 std::vector of gdb::unique_xmalloc_ptr.
615 (auto_load_expand_dir_vars): Return an std::vector of
616 gdb::unique_xmalloc_ptr, adjust the code.
617 (auto_load_safe_path_vec_update): Adjust.
618 (filename_is_in_auto_load_safe_path_vec): Adjust.
619 (auto_load_objfile_script_1): Adjust.
620 * build-id.c (build_id_to_debug_bfd): Adjust.
621 * linux-thread-db.c (thread_db_load_search): Adjust.
622 * source.c (add_path): Adjust.
623 (openp): Adjust.
624 * symfile.c (find_separate_debug_file): Adjust.
625 * utils.c (do_free_char_ptr_vec): Remove.
626 (make_cleanup_free_char_ptr_vec): Remove.
627
ab818ade
SDJ
6282018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
629
630 PR gdb/22907
631 * common/pathstuff.c: Conditionally include "<windows.h>".
632
e1e6f073
GS
6332018-03-01 Georg Sauthoff <mail@georg.so>
634
635 PR gdb/22888
636 * gcore.in: Quote variables and switch interpreter to bash.
637
c7b15a66
TT
6382018-03-01 Tom Tromey <tom@tromey.com>
639
640 * dwarf2read.c (alloc_discriminant_info): Fix default_index
641 assertion. Add assertion for discriminant_index.
642 (quirk_rust_enum): Use correct base type name in univariant case.
643
0cb7c7b0
SM
6442018-03-01 Simon Marchi <simon.marchi@ericsson.com>
645
646 * record.c (get_call_history_modifiers): Return a
647 record_print_flags.
648 (cmd_record_call_history): Adjust.
649 * record-btrace.c (record_btrace_call_history): Adjust.
650 (record_btrace_call_history_range): Adjust.
651 (record_btrace_call_history_from): Adjust.
652 * target-debug.h (target_debug_print_record_print_flags): New.
653 * target-delegates.c: Re-generate.
654 * target.c (target_call_history): Change flags type.
655 (target_call_history_from): Likewise.
656 (target_call_history_range): Likewise.
657 * target.h (struct target_ops) <target_call_history>: Likewise.
658 (target_call_history_from): Likewise.
659 (target_call_history_range): Likewise.
660
25e3c82c
SDJ
6612018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
662 Simon Marchi <simon.marchi@polymtl.ca>
663
664 * common/common-utils.c: Include "sys/stat.h".
665 (is_regular_file): Move here from "source.c"; change return
666 type to "bool".
667 * common/common-utils.h (is_regular_file): New prototype.
668 * common/pathstuff.c (contains_dir_separator): New function.
669 * common/pathstuff.h (contains_dir_separator): New prototype.
670 * source.c: Don't include "sys/stat.h".
671 (is_regular_file): Move to "common/common-utils.c".
672
b4987c95
SDJ
6732018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
674
675 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
676 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
677 * auto-load.c: Include "common/pathstuff.h".
678 * common/common-def.h (current_directory): Move here.
679 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
680 function.
681 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
682 prototype.
683 * common/pathstuff.c: New file.
684 * common/pathstuff.h: New file.
685 * compile/compile.c: Include "common/pathstuff.h".
686 * defs.h (current_directory): Move to "common/common-defs.h".
687 * dwarf2read.c: Include "common/pathstuff.h".
688 * exec.c: Likewise.
689 * guile/scm-safe-call.c: Likewise.
690 * linux-thread-db.c: Likewise.
691 * main.c: Likewise.
692 * nto-tdep.c: Likewise.
693 * objfiles.c: Likewise.
694 * source.c: Likewise.
695 * symtab.c: Likewise.
696 * utils.c: Include "common/pathstuff.h".
697 (gdb_realpath): Move to "common/pathstuff.c".
698 (gdb_realpath_keepfile): Likewise.
699 (gdb_abspath): Likewise.
700 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
701 (gdb_realpath_keepfile): Likewise.
702 (gdb_abspath): Likewise.
703
f169cfdc
JB
7042018-02-28 John Baldwin <jhb@FreeBSD.org>
705
706 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
707 wildcard process pid for super_resume for kernels with a
708 specific bug.
709
e05cac70
PM
7102018-02-27 Phil Muldoon <pmuldoon@redhat.com>
711
712 * compile/compile.c (get_args): Add additional comments
713 explaining function.
714
55089490
TT
7152018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
716 Tom Tromey <tom@tromey.com>
717
718 * target.h (memory_write_request_s): Remove typedef. Don't define
719 VEC.
720 (target_write_memory_blocks): Change argument to std::vector.
721 (struct memory_write_request): Add constructor.
722 * target-memory.c (compare_block_starting_address): Return bool.
723 Change argument types.
724 (claim_memory): Change arguments to use std::vector.
725 (split_regular_and_flash_blocks, blocks_to_erase)
726 (compute_garbled_blocks): Likewise.
727 (cleanup_request_data, cleanup_write_requests_vector): Remove.
728 (target_write_memory_blocks): Change argument to std::vector.
729 * symfile.c (struct load_section_data): Add constructor and
730 destructor. Use std::vector for "requests".
731 (struct load_progress_data): Add initializers.
732 (load_section_callback): Update. Use "new".
733 (clear_memory_write_data): Remove.
734 (generic_load): Update.
735
0c305b61
AH
7362018-02-27 Alan Hayward <alan.hayward@arm.com>
737
738 * arch/aarch64.h: Use common/tdesc.h.
739
c5196c92
MR
7402018-02-26 Maciej W. Rozycki <macro@mips.com>
741
742 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
743 architecture with a 64-bit ABI.
744
37c33887
MR
7452018-02-26 Maciej W. Rozycki <macro@mips.com>
746
747 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
748 ahead of target description loading.
749
d4dd3282
TT
7502018-02-26 Tom Tromey <tom@tromey.com>
751
752 * stack.c (backtrace_command_1): Update.
753 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
754 of "flags".
755 * python/py-framefilter.c (py_print_frame)
756 (gdbpy_apply_frame_filter): Change type of "flags".
757 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
758 of "flags".
759 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
760 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
761 * extension.h (enum frame_filter_flag): Rename from
762 frame_filter_flags.
763 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
764 (apply_ext_lang_frame_filter): Change type of "flags".
765 * extension.c (apply_ext_lang_frame_filter): Change type of
766 "flags".
767 * extension-priv.h (struct extension_language_ops)
768 <apply_frame_filter>: Change type of "flags".
769
6893c19a
TT
7702018-02-26 Tom Tromey <tom@tromey.com>
771
772 PR python/16497:
773 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
774 off-by-one in py_end computation.
775 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
776 PRINT_MORE_FRAMES.
777 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
778 constant.
779
2ddeaf8a
TT
7802018-02-26 Tom Tromey <tom@tromey.com>
781
782 * dwarf2read.c (struct variant_field): New.
783 (struct nextfield) <variant>: New field.
784 (dwarf2_add_field): Handle DW_TAG_variant_part.
785 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
786 discriminated union.
787 (read_structure_type): Handle DW_TAG_variant_part.
788 (handle_struct_member_die): New function, extracted from
789 process_structure_scope. Handle DW_TAG_variant.
790 (process_structure_scope): Handle discriminated unions. Call
791 handle_struct_member_die.
792
c9317f21
TT
7932018-02-26 Tom Tromey <tom@tromey.com>
794
795 * rust-lang.h (rust_last_path_segment): Declare.
796 * rust-lang.c (rust_last_path_segment): Now public. Change
797 contract.
798 (struct disr_info): Remove.
799 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
800 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
801 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
802 (rust_enum_p, rust_enum_variant): New function.
803 (rust_underscore_fields): Remove "offset" parameter.
804 (rust_print_enum): New function.
805 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
806 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
807 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
808 enums.
809 (rust_internal_print_type): New function, from rust_print_type.
810 Remove enum code.
811 (rust_print_type): Call rust_internal_print_type.
812 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
813 Update enum handling.
814 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
815 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
816 (rust_union_quirks): New functions.
817 (process_full_comp_unit, process_full_type_unit): Call
818 rust_union_quirks.
819 (process_structure_scope): Update rust_unions if necessary.
820
7c22600a
TT
8212018-02-26 Tom Tromey <tom@tromey.com>
822
823 * value.h (value_union_variant): Declare.
824 * valops.c (value_union_variant): New function.
825 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
826 (struct discriminant_info): New.
827 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
828 enumerator.
829 (struct main_type) <flag_discriminated_union>: New field.
830
15ce8941
TT
8312018-02-26 Tom Tromey <tom@tromey.com>
832
833 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
834 unittests/unpack-selftests.c.
835 * unittests/unpack-selftests.c: New file.
836 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
837
48fbe735
YQ
8382018-02-26 Yao Qi <yao.qi@linaro.org>
839
840 * dwarf2read.c (struct partial_die_info) <read>: New method.
841 (read_partial_die): Remove the declaration.
842 (load_partial_dies): Update.
843 (partial_die_info::partial_die_info):
844 (read_partial_die): Change it to partial_die_info::read.
845
52356b79
YQ
8462018-02-26 Yao Qi <yao.qi@linaro.org>
847
848 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
849 (fixup_partial_die): Remove declaration.
850 (scan_partial_symbols): Update.
851 (partial_die_parent_scope): Likewise.
852 (partial_die_full_name): Likewise.
853 (fixup_partial_die): Change it to partial_die_info::fixup.
854
35cc7ed7
YQ
8552018-02-26 Yao Qi <yao.qi@linaro.org>
856
857 * dwarf2read.c (read_partial_die): Update the declaration.
858 (load_partial_dies): Caller update.
859 (read_partial_die): Remove one argument abbrev_len.
860
6f06d47b
YQ
8612018-02-26 Yao Qi <yao.qi@linaro.org>
862
863 * dwarf2read.c (struct partial_die_info): Add ctor, delete
864 assignment operator.
865 (load_partial_dies): Use ctor and copy ctor.
866 (read_partial_die): Update.
867 (dwarf2_cu::find_partial_die): Use ctor.
868
d590ff25
YQ
8692018-02-26 Yao Qi <yao.qi@linaro.org>
870
871 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
872 (find_partial_die_in_comp_unit): Change it to
873 dwarf2_cu::find_partial_die.
874 (find_partial_die): Update.
875
fd0a254f
YQ
8762018-02-26 Yao Qi <yao.qi@linaro.org>
877
878 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
879 is NULL.
880
cd9983dd
YQ
8812018-02-26 Yao Qi <yao.qi@linaro.org>
882
883 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
884
f46cd62a
AH
8852018-02-26 Alan Hayward <alan.hayward@arm.com>
886
887 * arch/amd64.h: Use common/tdesc.h.
888 * arch/i386.c: Likewise.
889 * arch/i386.h: Likewise.
890 * arch/tic6x.c: Likewise.
891 * arch/tdesc.h: Move file from here...
892 * common/tdesc.h: ...to here.
893 * features/aarch64-core.c: Regenerate.
894 * features/aarch64-fpu.c: Regenerate.
895 * features/i386/32bit-avx.c: Regenerate.
896 * features/i386/32bit-avx512.c: Regenerate.
897 * features/i386/32bit-core.c: Regenerate.
898 * features/i386/32bit-linux.c: Regenerate.
899 * features/i386/32bit-mpx.c: Regenerate.
900 * features/i386/32bit-pkeys.c: Regenerate.
901 * features/i386/32bit-sse.c: Regenerate.
902 * features/i386/64bit-avx.c: Regenerate.
903 * features/i386/64bit-avx512.c: Regenerate.
904 * features/i386/64bit-core.c: Regenerate.
905 * features/i386/64bit-linux.c: Regenerate.
906 * features/i386/64bit-mpx.c: Regenerate.
907 * features/i386/64bit-pkeys.c: Regenerate.
908 * features/i386/64bit-segments.c: Regenerate.
909 * features/i386/64bit-sse.c: Regenerate.
910 * features/i386/x32-core.c: Regenerate.
911 * features/tic6x-c6xp.c: Regenerate.
912 * features/tic6x-core.c: Regenerate.
913 * features/tic6x-gp.c: Regenerate.
914 * target-descriptions.c: Use common/tdesc.h.
915 * target-descriptions.h: Likewise.
916
9b292f68
TT
9172018-02-24 Tom Tromey <tom@tromey.com>
918
919 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
920 (try_thread_db_load_from_dir, thread_db_load_search): Use
921 std::string.
922 (info_auto_load_libthread_db_compare): Return bool. Change
923 argument types.
924 (info_auto_load_libthread_db): Use std::vector, std::string.
925 Remove cleanups.
926
281d762b
TT
9272018-02-24 Tom Tromey <tom@tromey.com>
928
929 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
930 std::string.
931 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
932 std::string*.
933 * gdbarch.c: Rebuild.
934 * gdbarch.h: Rebuild.
935 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
936 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
937 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
938 std::string*.
939
9d8780f0
SM
9402018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
941
942 * gdbtypes.h (sect_offset): Change type to uint64_t.
943 (sect_offset_str): New function.
944 * dwarf2read.c (create_addrmap_from_aranges): Use
945 sect_offset_str.
946 (error_check_comp_unit_head): Likewise.
947 (create_debug_type_hash_table): Likewise.
948 (read_cutu_die_from_dwo): Likewise.
949 (init_cutu_and_read_dies): Likewise.
950 (init_cutu_and_read_dies_no_follow): Likewise.
951 (process_psymtab_comp_unit_reader): Likewise.
952 (partial_die_parent_scope): Likewise.
953 (peek_die_abbrev): Likewise.
954 (process_queue): Likewise.
955 (dwarf2_physname): Likewise.
956 (read_namespace_alias): Likewise.
957 (read_import_statement): Likewise.
958 (create_dwo_cu_reader): Likewise.
959 (create_cus_hash_table): Likewise.
960 (lookup_dwo_cutu): Likewise.
961 (inherit_abstract_dies): Likewise.
962 (read_func_scope): Likewise.
963 (read_call_site_scope): Likewise.
964 (dwarf2_add_member_fn): Likewise.
965 (read_common_block): Likewise.
966 (read_module_type): Likewise.
967 (read_typedef): Likewise.
968 (read_subrange_type): Likewise.
969 (load_partial_dies): Likewise.
970 (read_partial_die): Likewise.
971 (find_partial_die): Likewise.
972 (read_str_index): Likewise.
973 (dwarf2_string_attr): Likewise.
974 (build_error_marker_type): Likewise.
975 (lookup_die_type): Likewise.
976 (dump_die_shallow): Likewise.
977 (follow_die_ref): Likewise.
978 (dwarf2_fetch_die_loc_sect_off): Likewise.
979 (dwarf2_fetch_constant_bytes): Likewise.
980 (follow_die_sig): Likewise.
981 (get_signatured_type): Likewise.
982 (get_DW_AT_signature_type): Likewise.
983 (dwarf2_find_containing_comp_unit): Likewise.
984 (set_die_type): Likewise.
985
8ec57239
JB
9862018-02-21 John Baldwin <jhb@FreeBSD.org>
987
988 * arch/aarch64.c: Include "common-defs.h".
989 * arch/amd64.c: Likewise.
990 * arch/i386.c: Likewise.
991
3eac2b65
TT
9922018-02-21 Tom Tromey <tom@tromey.com>
993
994 * value.h: (extract_field_op): Update.
995 * eval.c (extract_field_op): Return a const char *.
996 * expression.h (parse_expression_for_completion): Update.
997 * completer.c (complete_expression): Update.
998 (add_struct_fields): Make fieldname const.
999 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
1000 (mark_completion_tag, parse_exp_in_context_1): Update.
1001 (parse_expression_for_completion): Change "name" to
1002 unique_xmalloc_ptr*.
1003
6ccb583f
TT
10042018-02-21 Tom Tromey <tom@tromey.com>
1005
1006 * infcall.c (call_function_by_hand_dummy): Use std::vector.
1007
c113ed0c
YQ
10082018-02-21 Yao Qi <yao.qi@linaro.org>
1009
1010 * avr-tdep.c (avr_read_pc): Change parameter type to
1011 readable_regcache.
1012 * gdbarch.sh (read_pc): Likewise.
1013 * gdbarch.c: Re-generated.
1014 * gdbarch.h: Re-generated.
1015 * hppa-tdep.c (hppa_read_pc): Change parameter type to
1016 readable_regcache.
1017 * ia64-tdep.c (ia64_read_pc): Likewise.
1018 * mips-tdep.c (mips_read_pc): Likewise.
1019 * spu-tdep.c (spu_read_pc): Likewise.
1020
4c74fe6b
YQ
10212018-02-21 Yao Qi <yao.qi@linaro.org>
1022
1023 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
1024 * regcache-dump.c: New file.
1025 * regcache.c: Move register_dump to regcache-dump.c.
1026 (maintenance_print_registers): Likewise.
1027 (maintenance_print_raw_registers): Likewise.
1028 (maintenance_print_cooked_registers): Likewise.
1029 (maintenance_print_register_groups): Likewise.
1030 (maintenance_print_remote_registers): Likewise.
1031 (_initialize_regcache): Likewise.
1032 * regcache.h (register_dump): Moved from regcache.c.
1033
796bb026
YQ
10342018-02-21 Yao Qi <yao.qi@linaro.org>
1035
1036 * regcache.c (regcache::regcache): Update.
1037 (regcache::invalidate): Move it to detached_regcache::invalidate.
1038 (get_thread_arch_aspace_regcache): Update.
1039 (regcache::raw_update): Update.
1040 (regcache::cooked_read): Remove some code.
1041 (regcache::cooked_read_value): Likewise.
1042 (regcache::raw_write): Remove assert on m_readonly_p.
1043 (regcache::raw_supply_integer): Move it to
1044 detached_regcache::raw_supply_integer.
1045 (regcache::raw_supply_zeroed): Likewise.
1046 * regcache.h (detached_regcache) <raw_supply_integer>: New
1047 declaration.
1048 <raw_supply_zeroed, invalidate>: Likewise.
1049 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
1050 <invalidate>: Likewise.
1051 <m_readonly_p>: Removed.
1052
215c69dc
YQ
10532018-02-21 Yao Qi <yao.qi@linaro.org>
1054
1055 * infcmd.c (get_return_value): Let stop_regs point to
1056 get_current_regcache.
1057 * regcache.c (regcache::regcache): Remove.
1058 (register_dump_reg_buffer): New class.
1059 (regcache_print): Adjust.
1060 * regcache.h (regcache): Remove constructors.
1061
f3384e66
YQ
10622018-02-21 Yao Qi <yao.qi@linaro.org>
1063
1064 * regcache.c (class register_dump): New class.
1065 (register_dump_regcache, register_dump_none): New class.
1066 (register_dump_remote, register_dump_groups): New class.
1067 (regcache_print): Update.
1068 * regcache.h (regcache_dump_what): Move it to regcache.c.
1069 (regcache) <dump>: Remove.
1070
c8ec2f33
YQ
10712018-02-21 Yao Qi <yao.qi@linaro.org>
1072
1073 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
1074 reg_buffer_rw *.
1075 (jit_unwind_reg_set_impl): Call raw_supply.
1076 (jit_frame_sniffer): Use reg_buffer_rw.
1077 * record-full.c (record_full_core_regbuf): Change its type.
1078 (record_full_core_open_1): Use reg_buffer_rw.
1079 (record_full_close): Likewise.
1080 (record_full_core_fetch_registers): Use regcache->raw_supply.
1081 (record_full_core_store_registers): Likewise.
1082 * regcache.c (regcache::get_register_status): Move it to
1083 reg_buffer.
1084 (regcache_raw_set_cached_value): Remove.
1085 (regcache::raw_set_cached_value): Remove.
1086 (regcache::raw_write): Call raw_supply.
1087 (regcache::raw_supply): Move it to reg_buffer_rw.
1088 * regcache.h (regcache_raw_set_cached_value): Remove.
1089 (reg_buffer_rw): New class.
1090
daf6667d
YQ
10912018-02-21 Yao Qi <yao.qi@linaro.org>
1092
1093 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
1094 readonly_detached_regcache.
1095 (dummy_frame_prev_register): Use regcache->cooked_read.
1096 * frame.c (frame_save_as_regcache): Change return type.
1097 (frame_pop): Update.
1098 * frame.h (frame_save_as_regcache): Update declaration.
1099 * inferior.h (get_infcall_suspend_state_regcache): Update
1100 declaration.
1101 * infrun.c (infcall_suspend_state) <registers>: use
1102 readonly_detached_regcache.
1103 (save_infcall_suspend_state): Don't use regcache_dup.
1104 (get_infcall_suspend_state_regcache): Change return type.
1105 * linux-fork.c (struct fork_info) <savedregs>: Change to
1106 readonly_detached_regcache.
1107 <pc>: New field.
1108 (fork_save_infrun_state): Don't use regcache_dup.
1109 (info_checkpoints_command): Adjust.
1110 * mi/mi-main.c (register_changed_p): Update declaration.
1111 (mi_cmd_data_list_changed_registers): Use
1112 readonly_detached_regcache.
1113 (register_changed_p): Change parameter type to
1114 readonly_detached_regcache.
1115 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
1116 readonly_detached_regcache.
1117 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
1118 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
1119 New.
1120 (regcache::save): Move it to reg_buffer.
1121 (regcache::restore): Change parameter type.
1122 (regcache_dup): Remove.
1123 * regcache.h (reg_buffer) <save>: New method.
1124 (readonly_detached_regcache): New class.
1125 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
1126 readonly_detached_regcache.
1127 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
1128
fc5b8736
YQ
11292018-02-21 Yao Qi <yao.qi@linaro.org>
1130
1131 * frame.c (frame_save_as_regcache): Use regcache method save.
1132 (frame_pop): Use regcache method restore.
1133 * infrun.c (restore_infcall_suspend_state): Likewise.
1134 * linux-fork.c (fork_load_infrun_state): Likewise.
1135 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
1136 save.
1137 * regcache.c (regcache_save): Remove.
1138 (regcache::restore): More asserts.
1139 (regcache_cpy): Remove.
1140 * regcache.h (regcache_save): Remove the declaration.
1141 (regcache::restore): Move from private to public.
1142 Remove the friend declaration of regcache_cpy.
1143 (regcache_cpy): Remove declaration.
1144
849d0ba8
YQ
11452018-02-21 Yao Qi <yao.qi@linaro.org>
1146
1147 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
1148 parameter type to 'readable_regcache *'.
1149 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
1150 * arm-tdep.c (arm_neon_quad_read): Likewise.
1151 (arm_pseudo_read): Likewise.
1152 * avr-tdep.c (avr_pseudo_register_read): Likewise.
1153 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
1154 * frv-tdep.c (frv_pseudo_register_read): Likewise.
1155 * gdbarch.c: Re-generated.
1156 * gdbarch.h: Re-generated.
1157 * gdbarch.sh (pseudo_register_read): Change parameter type to
1158 'readable_regcache *'.
1159 (pseudo_register_read_value): Likewise.
1160 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
1161 (h8300_pseudo_register_read): Likewise.
1162 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
1163 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1164 (i386_pseudo_register_read_into_value): Likewise.
1165 (i386_pseudo_register_read_value): Likewise.
1166 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
1167 declaration.
1168 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
1169 * m32c-tdep.c (m32c_raw_read): Likewise.
1170 (m32c_read_flg): Likewise.
1171 (m32c_banked_register): Likewise.
1172 (m32c_banked_read): Likewise.
1173 (m32c_sb_read): Likewise.
1174 (m32c_part_read): Likewise.
1175 (m32c_cat_read): Likewise.
1176 (m32c_r3r2r1r0_read): Likewise.
1177 (m32c_pseudo_register_read): Likewise.
1178 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
1179 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
1180 (mep_pseudo_cr64_read): Likewise.
1181 (mep_pseudo_register_read): Likewise.
1182 * mips-tdep.c (mips_pseudo_register_read): Likewise.
1183 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
1184 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
1185 * regcache.c (regcache::raw_read): Move it to readable_regcache.
1186 (regcache::cooked_read): Likewise.
1187 (regcache::cooked_read_value): Likewise.
1188 (regcache_cooked_read_signed):
1189 (regcache::cooked_read): Likewise.
1190 * regcache.h (readable_regcache): New class.
1191 (regcache): Inherit readable_regcache. Move some methods to
1192 readable_regcache.
1193 * rl78-tdep.c (rl78_pseudo_register_read): Change
1194 parameter type to 'readable_regcache *'.
1195 * rs6000-tdep.c (do_regcache_raw_read): Remove.
1196 (e500_pseudo_register_read): Change parameter type to
1197 'readable_regcache *'.
1198 (dfp_pseudo_register_read): Likewise.
1199 (vsx_pseudo_register_read): Likewise.
1200 (efpr_pseudo_register_read): Likewise.
1201 * s390-tdep.c (s390_pseudo_register_read): Likewise.
1202 * sh-tdep.c (sh_pseudo_register_read): Likewise.
1203 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
1204 (sh64_pseudo_register_read): Likewise.
1205 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
1206 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
1207 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
1208 (spu_pseudo_register_read): Likewise.
1209 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
1210 (xtensa_pseudo_register_read): Likewise.
1211
31716595
YQ
12122018-02-21 Yao Qi <yao.qi@linaro.org>
1213
1214 * regcache.c (regcache::regcache): Call reg_buffer ctor.
1215 (regcache::arch): Move it to reg_buffer::arch.
1216 (regcache::register_buffer): Likewise.
1217 (regcache::assert_regnum): Likewise.
1218 (regcache::num_raw_registers): Likewise.
1219 * regcache.h (reg_buffer): New class.
1220 (regcache): Inherit reg_buffer.
1221
7104e59b
SM
12222018-02-20 Simon Marchi <simon.marchi@ericsson.com>
1223
1224 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
1225 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
1226
2d8adcbd
MM
12272018-02-20 Markus Metzger <markus.t.metzger@intel.com>
1228
1229 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
1230
b5884fa7
AH
12312018-02-19 Alan Hayward <alan.hayward@arm.com>
1232
1233 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
1234 (SFILES): Remove common/*.c files.
1235 (COMMON_OBS): Remove some *.o files built from common/*.c files.
1236 * common/common.host: Add common reference.
1237 * configure.ac: Likewise.
1238 * configure: Regenerate.
1239
fd90ace4
YQ
12402018-02-16 Yao Qi <yao.qi@linaro.org>
1241
1242 * block.c (block_namespace_info): Inherit allocate_on_obstack.
1243 (block_initialize_namespace): Use new.
1244 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
1245 (dwarf2_free_objfile): Use delete.
1246 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
1247 (copy_type_recursive): Use new.
1248 * gdb_obstack.h (allocate_on_obstack): New.
1249
85046ae2
YQ
12502018-02-15 Yao Qi <yao.qi@linaro.org>
1251
1252 PR gdb/22849
1253 * inferior.c (exit_inferior_1): Reset inf->control.
1254
355c559b
JB
12552018-02-15 Joel Brobecker <brobecker@adacore.com>
1256
1257 * ada-lang.c (ada_to_fixed_value_create): Delete advance
1258 declaration.
1259
980548fd
PA
12602018-02-14 Pedro Alves <palves@redhat.com>
1261
1262 * frame-unwind.c (frame_unwind_try_unwinder): Always call
1263 frame_cleanup_after_sniffer on exception.
1264
692d6f97
TT
12652018-02-14 Tom Tromey <tom@tromey.com>
1266
1267 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
1268 const.
1269 (solib_bfd_open): Make pathname const.
1270 * solib.c (solib_bfd_open): Make pathname const.
1271 * solib-spu.c (spu_bfd_fopen): Make name const.
1272 (spu_bfd_open): Make pathname const.
1273 * solib-darwin.c (darwin_bfd_open): Make pathname const.
1274 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
1275
e0cc99a6
TT
12762018-02-14 Tom Tromey <tom@tromey.com>
1277
1278 * symfile.c (symfile_bfd_open): Update.
1279 * source.h (openp, source_full_path_of, find_and_open_source):
1280 Change argument type to unique_xmalloc_ptr.
1281 * source.c (openp): Take a unique_xmalloc_ptr.
1282 (source_full_path_of, find_and_open_source): Likewise.
1283 (open_source_file, symtab_to_fullname): Update.
1284 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
1285 unique_xmalloc_ptr.
1286 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
1287 (exec_file_find): Update.
1288 * psymtab.c (psymtab_to_fullname): Update.
1289 * nto-tdep.h (nto_find_and_open_solib): Update.
1290 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
1291 unique_xmalloc_ptr.
1292 * exec.c (exec_file_attach): Update.
1293 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
1294 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
1295
b46a8d7c
TT
12962018-02-14 Tom Tromey <tom@tromey.com>
1297
1298 * solib.c: Include source.h.
1299 * nto-tdep.c: Include source.h.
1300 * mi/mi-cmd-env.c: Include source.h.
1301 * infcmd.c: Include source.h.
1302 * exec.c: Include source.h.
1303 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
1304 (add_path, directory_switch, source_path, init_source_path): Move
1305 declarations...
1306 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
1307 (add_path, directory_switch, source_path, init_source_path):
1308 ...here.
1309
797bc1cb
TT
13102018-02-14 Tom Tromey <tom@tromey.com>
1311
1312 * solist.h (exec_file_find, solib_find): Return
1313 unique_xmalloc_ptr.
1314 (solib_bfd_fopen): Take a const char *.
1315 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
1316 (exec_file_find, solib_find): Likewise.
1317 (solib_bfd_fopen): Do not take ownership of "pathname".
1318 (solib_bfd_open): Use unique_xmalloc_ptr.
1319 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
1320 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
1321 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
1322 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
1323
f98b2e33
JB
13242018-02-14 Joel Brobecker <brobecker@adacore.com>
1325
1326 * ada-lang.c (name_match_type_from_name): Remove reference to
1327 ada_name_for_lookup in function's documentation.
1328 * ada-lang.h (ada_name_for_lookup): Delete declaration.
1329
24b9144d
SM
13302018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
1331
1332 * defs.h (enum openp_flags): New enum.
1333 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
1334 Move to enum openp_flags.
1335 (openp_flags): New enum flags.
1336 (openp): Change parameter type to openp_flags.
1337 * source.c (openp): Change parameter type to openp_flags.
1338 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
1339 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
1340
387cd15b
SM
13412018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
1342
1343 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
1344 per-command.
1345
b303c6f6
AB
13462018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
1347
1348 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
1349 into...
1350 (class dwarf2_queue_guard): ...the destructor of this new class.
1351 (dw2_do_instantiate_symtab): Create instance of the new class
1352 dwarf2_queue_guard, remove cleanup.
1353
9c3630e9
TT
13542018-02-09 Tom Tromey <tom@tromey.com>
1355
1356 * source.c (find_source_lines): Don't reference past the end of
1357 the vector.
1358
c4e12631
MM
13592018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1360
1361 * remote.c (remote_btrace_maybe_reopen): Change error message.
1362 * btrace.c (btrace_enable): Likewise.
1363 (parse_xml_btrace): Likewise.
1364 (parse_xml_btrace_conf): Likewise.
1365
88711fbf
MM
13662018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1367
1368 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
1369 (linux_enable_pt, linux_enable_bts): Call
1370 diagnose_perf_event_open_fail.
1371
17ad2a4f
MM
13722018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1373
1374 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
1375 Remove parameter and change return type. Update callers. Move it.
1376 (linux_enable_bts, linux_enable_pt): Improve error message.
1377 (linux_enable_pt): Remove zero buffer size check.
1378 (linux_enable_btrace): Improve error messages. Remove NULL return
1379 check.
1380
de6242d3
MM
13812018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1382
1383 * btrace.c (btrace_enable): Remove target_supports_btrace call.
1384 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
1385 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
1386 (linux_supports_pt, linux_supports_btrace): Remove.
1387 (linux_enable_bts): Call cpu_supports_bts.
1388 * nat/linux-btrace.h (linux_supports_btrace): Remove.
1389 * remote.c (remote_supports_btrace): Remove.
1390 (init_remote_ops): Remove remote_supports_btrace.
1391 * target-delegates.c: Regenerated.
1392 * target.c (target_supports_btrace): Remove.
1393 * target.h (target_ops) <to_supports_btrace>: Remove
1394 (target_supports_btrace): Remove.
1395 * x86-linux-nat.c (x86_linux_create_target): Remove
1396 linux_supports_btrace.
1397
9ee23a85
MM
13982018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1399
1400 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
1401 btrace failed.
1402 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
1403 exception and use message in own exception.
1404
5c3284c1
MM
14052018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1406
1407 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
1408 (perf_event_pt_event_type): Use gdb_file_up.
1409 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
1410 scoped_fd, and scoped_mmap.
1411
84696f37
MM
14122018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1413
1414 * common/scoped_mmap.h: New.
1415 * unittests/scoped_mmap-selftest.c: New.
1416 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1417 unittests/scoped_mmap-selftest.c.
1418
ea4a0888
MM
14192018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1420
1421 * common/scoped_fd.h: New.
1422 * unittests/scoped_fd-selftest.c: New.
1423 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1424 unittests/scoped_fd-selftest.c.
1425
869e8290
TT
14262018-02-09 Tom Tromey <tom@tromey.com>
1427
1428 * auto-load.c (auto_load_section_scripts): Use
1429 gdb::unique_xmalloc_ptr.
1430
a37a2ae7
TT
14312018-02-09 Tom Tromey <tom@tromey.com>
1432
1433 * auto-load.c (execute_script_contents): Use std::string.
1434
4e725347
JB
14352018-02-09 Joel Brobecker <brobecker@adacore.com>
1436
1437 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
1438 Python function, rather than a new command.
1439
9a897d43
TT
14402018-02-08 Tom Tromey <tom@tromey.com>
1441
1442 * solib.c (solib_find_1): Use std::string.
1443 (solib_bfd_fopen): Use unique_xmalloc_ptr.
1444
58ef3771
TT
14452018-02-08 Tom Tromey <tom@tromey.com>
1446
1447 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
1448
a9abc434
TT
14492018-02-08 Tom Tromey <tom@tromey.com>
1450
1451 * source.c (find_source_lines): Use gdb::def_vector.
1452
84f27c6f
TT
14532018-02-08 Tom Tromey <tom@tromey.com>
1454
1455 * macrocmd.c (struct temporary_macro_definition): New.
1456 (macro_define_command): Use temporary_macro_definition. Remove
1457 cleanups.
1458 (free_macro_definition_ptr): Remove.
1459
0354904b
TT
14602018-02-08 Tom Tromey <tom@tromey.com>
1461
1462 * macroexp.c (maybe_expand): Use std::string.
1463
1739cf24
TT
14642018-02-08 Tom Tromey <tom@tromey.com>
1465
1466 * macroexp.c (struct macro_buffer): Add initializers for some
1467 members.
1468 (init_buffer, init_shared_buffer, free_buffer)
1469 (free_buffer_return_text): Remove.
1470 (macro_buffer): New constructors.
1471 (~macro_buffer): New destructor.
1472 (macro_buffer::set_shared): New method.
1473 (macro_buffer::resize_buffer, macro_buffer::appendc)
1474 (macro_buffer::appendmem): Now methods, not free functions.
1475 (set_token, append_tokens_without_splicing, stringify)
1476 (macro_stringify): Update.
1477 (gather_arguments): Change return type. Remove argc_p argument,
1478 add args_ptr argument. Use std::vector.
1479 (substitute_args): Remove argc argument. Accept std::vector.
1480 (expand): Update. Use std::vector.
1481 (scan, macro_expand, macro_expand_next): Update.
1482
f6c2623e
TT
14832018-02-08 Tom Tromey <tom@tromey.com>
1484
1485 * symtab.c (default_collect_symbol_completion_matches_break_on):
1486 Use unique_xmalloc_ptr.
1487 * macroscope.h: (sal_macro_scope, user_macro_scope)
1488 (default_macro_scope): Return unique_xmalloc_ptr.
1489 * macroscope.c (sal_macro_scope, user_macro_scope)
1490 (default_macro_scope): Return unique_xmalloc_ptr.
1491 * macroexp.h (macro_expand, macro_expand_once): Return
1492 unique_xmalloc_ptr.
1493 * macroexp.c (macro_expand, macro_expand_once): Return
1494 unique_xmalloc_ptr.
1495 * macrocmd.c (macro_expand_command, macro_expand_once_command)
1496 (info_macro_command, info_macros_command): Use
1497 unique_xmalloc_ptr.
1498 * compile/compile-c-support.c (write_macro_definitions): Use
1499 unique_xmalloc_ptr.
1500 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
1501
c2e0e465
SM
15022018-02-07 Simon Marchi <simon.marchi@ericsson.com>
1503
1504 * value.c (value_static_field): Assign field type instead of
1505 containing type when returning an optimized out value.
1506
3f8c94b4
YQ
15072018-02-06 Yao Qi <yao.qi@linaro.org>
1508
1509 * ft32-tdep.c (ft32_read_pc): Remove.
1510 (ft32_write_pc): Remove.
1511 (ft32_gdbarch_init): Update.
1512 * m32r-tdep.c (m32r_read_pc): Remove.
1513 (m32r_gdbarch_init): Update.
1514 * mep-tdep.c (mep_read_pc): Remove.
1515 (mep_gdbarch_init): Update.
1516 * microblaze-tdep.c (microblaze_write_pc): Remove.
1517 (microblaze_gdbarch_init): Update.
1518 * mn10300-tdep.c (mn10300_read_pc): Remove.
1519 (mn10300_write_pc): Remove.
1520 (mn10300_gdbarch_init): Update.
1521 * moxie-tdep.c (moxie_read_pc): Remove.
1522 (moxie_write_pc): Remove.
1523 (moxie_gdbarch_init): Update.
1524
bca65a23
YQ
15252018-02-06 Yao Qi <yao.qi@linaro.org>
1526
1527 * expprint.c (print_subexp_standard): Handle
1528 OP_F77_UNDETERMINED_ARGLIST.
1529 (dump_subexp_body_standard): Likewise.
1530
583e3f90 15312018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 1532
583e3f90
YQ
1533 * target-descriptions.c (tdesc_element_visitor) Add empty
1534 implementations.
b8df6ca7
AH
1535 (tdesc_type): Move make_gdb_type from here.
1536 (tdesc_type_builtin): Likewise.
1537 (tdesc_type_vector): Likewise.
1538 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
1539 (make_gdb_type_struct): Move from tdesc_type_with_fields.
1540 (make_gdb_type_union): Likewise.
1541 (make_gdb_type_flags): Likewise.
1542 (make_gdb_type_enum): Likewise.
1543 (make_gdb_type): New function.
1544 (tdesc_register_type): Use static make_gdb_type.
1545
e813d34a
RK
15462018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
1547
1548 * infcmd.c (default_print_one_register_info): Align natural-format
1549 column values consistently one under another.
1550 (pad_to_column): New function.
1551
0eb876f5
JB
15522018-02-05 Joel Brobecker <brobecker@adacore.com>
1553
1554 * dwarf2read.c (dwarf2_physname): Move commment.
1555
0625771b
LS
15562018-02-01 Leszek Swirski <leszeks@google.com>
1557
1558 * varobj.c (varobj_formatted_print_options): Allow recursive
1559 pretty printing if pretty printing is enabled.
1560
59498c30
LS
15612018-02-01 Leszek Swirski <leszeks@google.com>
1562
1563 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
1564 names after a structop as a filename.
1565
2d9e6acb
YQ
15662018-02-01 Yao Qi <yao.qi@linaro.org>
1567
1568 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
1569 (arm_record_coproc_data_proc): Likewise.
1570
df95a9cf
YQ
15712018-02-01 Yao Qi <yao.qi@linaro.org>
1572
1573 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
1574
07e5f5cf
NP
15752018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
1576
1577 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
1578 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
1579
3045b475
PA
15802018-01-31 Pedro Alves <palves@redhat.com>
1581
1582 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
1583 * inflow.c (child_terminal_save_inferior): Wrap reference to
1584 tcgetpgrp in HAVE_TERMIOS_H.
1585 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
1586 _WIN32.
1587 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
1588 always iterate over all inferiors.
1589 (gdbsim_cntrl_c): Adjust.
1590 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
1591
929b5ad4
JB
15922018-01-31 Joel Brobecker <brobecker@adacore.com>
1593
1594 * gdbtypes.c (lookup_array_range_type): Make sure the array's
1595 index type is objfile-owned if the element type is as well.
1596
29236ca2
JB
15972018-01-31 Joel Brobecker <brobecker@adacore.com>
1598
1599 GDB 8.1 released.
1600
c81e8879
PR
16012018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
1602
1603 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
1604 "features/s390x-linux64.c".
1605 (_initialize_s390_linux_tdep): Remove initialization of tdescs
1606 s390_linux32 and s390x_linux64.
1607 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
1608 default tdesc.
1609 * s390-tdep.c: Include "features/s390-linux32.c" and
1610 "features/s390x-linux64.c".
1611 (s390_tdesc_valid): Add check for tdesc_has_registers.
1612 (s390_gdbarch_init): Make sure there is always a valid tdesc.
1613 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
1614 tdesc_s390x_linux64.
1615 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
1616 tdesc_s390x_linux64 to...
1617 * s390-tdep.h: ...here.
1618
e671cd59
PA
16192018-01-30 Pedro Alves <palves@redhat.com>
1620
1621 PR gdb/13211
1622 * config.in, configure: Regenerate.
1623 * configure.ac: Check for getpgid.
1624 * go32-nat.c (go32_pass_ctrlc): New.
1625 (go32_target): Install it.
1626 * inf-child.c (inf_child_target): Install
1627 child_terminal_save_inferior, child_pass_ctrlc and
1628 child_interrupt.
1629 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
1630 (inf_ptrace_target): No longer install it.
1631 * infcmd.c (interrupt_target_1): Adjust.
1632 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
1633 (child_interrupt): Declare.
1634 (inferior::terminal_state): New.
1635 * inflow.c (struct terminal_info): Update comments.
1636 (inferior_process_group): Delete.
1637 (terminal_is_ours): Delete.
1638 (gdb_tty_state): New.
1639 (child_terminal_init): Adjust.
1640 (is_gdb_terminal, sharing_input_terminal_1)
1641 (sharing_input_terminal): New functions.
1642 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
1643 Set the process's actual process group in the foreground if
1644 possible. Handle is_ours_for_output/is_ours distinction. Don't
1645 mark terminal as the inferior's if not sharing GDB's terminal.
1646 Don't check attach_flag.
1647 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
1648 pass down a target_terminal_state.
1649 (child_terminal_save_inferior): New, factored out from ...
1650 (child_terminal_ours_1): ... this. Handle
1651 target_terminal_state::is_ours_for_output.
1652 (child_interrupt, child_pass_ctrlc): New.
1653 (inflow_inferior_exit): Clear the inferior's terminal_state.
1654 (copy_terminal_info): Copy the inferior's terminal state.
1655 (_initialize_inflow): Remove reference to terminal_is_ours.
1656 * inflow.h (inferior_process_group): Delete.
1657 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
1658 * procfs.c (procfs_target): Don't install procfs_interrupt.
1659 (procfs_interrupt): Delete.
1660 * remote.c (remote_serial_quit_handler): Adjust.
1661 (remote_interrupt): Remove ptid parameter. Adjust.
1662 * target-delegates.c: Regenerate.
1663 * target.c: Include "terminal.h".
1664 (target_terminal::terminal_state): Rename to ...
1665 (target_terminal::m_terminal_state): ... this.
1666 (target_terminal::init): Adjust.
1667 (target_terminal::inferior): Adjust to per-inferior
1668 terminal_state.
1669 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
1670 (target_terminal::ours, target_terminal::ours_for_output): Use
1671 target_terminal_is_ours_kind.
1672 (target_interrupt): Remove ptid parameter. Adjust.
1673 (default_target_pass_ctrlc): Adjust.
1674 * target.h (target_ops::to_terminal_save_inferior): New field.
1675 (target_ops::to_interrupt): Remove ptid_t parameter.
1676 (target_interrupt): Remove ptid_t parameter. Update comment.
1677 (target_pass_ctrlc): Update comment.
1678 * target/target.h (target_terminal_state): New scoped enum,
1679 factored out of ...
1680 (target_terminal::terminal_state): ... here.
1681 (target_terminal::inferior): Update comments.
1682 (target_terminal::restore_inferior): New.
1683 (target_terminal::is_inferior, target_terminal::is_ours)
1684 (target_terminal::is_ours_for_output): Adjust.
1685 (target_terminal::scoped_restore_terminal_state): Adjust to
1686 rename, and call restore_inferior() instead of inferior().
1687 (target_terminal::scoped_restore_terminal_state::m_state): Change
1688 type.
1689 (target_terminal::terminal_state): Rename to ...
1690 (target_terminal::m_terminal_state): ... this and change type.
1691
9c3a5d93
PA
16922018-01-30 Pedro Alves <palves@redhat.com>
1693
1694 * linux-nat.c (wait_for_signal): New function.
1695 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
1696 directly.
1697 (async_terminal_is_ours)
1698 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
1699 (linux_nat_add_target): Don't override
1700 to_terminal_inferior/to_terminal_ours.
1701
69ab5edb
SDJ
17022018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
1703
1704 * remote.c (remote_follow_fork): Don't call "detach_inferior".
1705
fc8e7e75
SM
17062018-01-28 Simon Marchi <simon.marchi@ericsson.com>
1707
1708 * dwarf2read.c (free_dwo_files): Add forward-declaration.
1709 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
1710 dwarf2_per_objfile_free here.
1711 (dwarf2_per_objfile_free): Remove.
1712 (_initialize_dwarf2_read): Don't register
1713 dwarf2_per_objfile_free as a registry cleanup.
1714
b2a426e2
EZ
17152018-01-27 Eli Zaretskii <eliz@gnu.org>
1716
1717 Avoid compilation errors in MinGW native builds
1718
1719 The error is triggered by including python-internal.h, and the
1720 error message is:
1721
1722 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
1723 from build-gnulib/import/math.h:27,
1724 from d:/usr/Python26/include/pyport.h:235,
1725 from d:/usr/Python26/include/Python.h:58,
1726 from python/python-internal.h:94,
1727 from python/py-arch.c:24:
1728 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
1729 using ::hypot;
1730 ^~~~~
1731
1732 This happens because Python headers define 'hypot' to expand t
1733 '_hypot' in the Windows builds.
1734 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
1735 'hypoth'. This avoids a compilation error.
1736
0bdd8eac
AH
17372018-01-26 Alan Hayward <alan.hayward@arm.com>
1738
1739 * MAINTAINERS (Write After Approval): Fix ordering.
1740
56ae9dc3
AH
17412018-01-26 Alan Hayward <alan.hayward@arm.com>
1742
1743 * MAINTAINERS (Write After Approval): Add Alan Hayward.
1744
7433498b
AM
17452018-01-26 Alan Modra <amodra@gmail.com>
1746
1747 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
1748 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
1749 Remove nop. Make const. Comment.
1750 (powerpc32_plt_stub_so_2): New.
1751 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
1752 Correct count. Update uses.
1753 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
1754 Move common code reading PLT entry word. Correct
1755 powerpc32_plt_stub PLT address calculation.
1756 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
1757 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
1758 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
1759 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
1760 (ppc64_standard_linkage8): Likewise.
1761 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
1762 Correct insns description.
1763 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
1764
0f59d5fc
PA
17652018-01-24 Pedro Alves <palves@redhat.com>
1766
1767 GCC PR libstdc++/83906
1768 * gdbtypes.c (operator==(const dynamic_prop &,
1769 const dynamic_prop &)): New.
1770 (operator==(const range_bounds &, const range_bounds &)): New.
1771 (check_types_equal): Use them instead of memcmp.
1772 * gdbtypes.h (operator==(const dynamic_prop &,
1773 const dynamic_prop &)): Declare.
1774 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
1775 (operator==(const range_bounds &, const range_bounds &)): Declare.
1776 (operator!=(const range_bounds &, const range_bounds &)): Declare.
1777
ef8914a4
PR
17782018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1779
1780 * s390-linux-tdep.c (s390_record_address_mask)
1781 (s390_record_calc_disp_common, s390_record_calc_disp)
1782 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
1783 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
1784 (s390_process_record): Move to s390-tdep.c.
1785 (s390_linux_init_abi_any): Adjust.
1786 * s390-tdep.c (s390_record_address_mask)
1787 (s390_record_calc_disp_common, s390_record_calc_disp)
1788 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
1789 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
1790 (s390_process_record): Moved from s390-linux-tdep.c
1791 (s390_gdbarch_init): Adjust.
1792
d6e58945
PR
17932018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1794
1795 * s390-linux-nat.c (s390-tdep.h): New include.
1796 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
1797 (HFILES_NO_SRCDIR): Add s390-tdep.h.
1798 (ALLDEPFILES): Add s390-tdep.c.
1799 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
1800 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
1801 * s390-tdep.h: ...this. New file.
1802 * s390-linux-tdep.c (s390-tdep.h): New include.
1803 (_initialize_s390_tdep): Rename to...
1804 (_initialize_s390_linux_tdep): ...this and adjust.
1805 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
1806 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
1807 s390-tdep.h.
1808 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
1809 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
1810 (s390_is_partial_instruction, s390_software_single_step)
1811 (is_non_branch_ril, s390_displaced_step_copy_insn)
1812 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
1813 (s390_prologue_data, s390_addr, s390_store, s390_load)
1814 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
1815 (s390_register_call_saved, s390_guess_tracepoint_registers)
1816 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
1817 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
1818 (s390_pseudo_register_name, s390_pseudo_register_type)
1819 (s390_pseudo_register_read, s390_pseudo_register_write)
1820 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
1821 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
1822 (s390_addr_bits_remove, s390_address_class_type_flags)
1823 (s390_address_class_type_flags_to_name)
1824 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
1825 (s390_function_arg_float, s390_function_arg_vector)
1826 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
1827 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
1828 (s390_frame_align, s390_register_return_value, s390_return_value)
1829 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
1830 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
1831 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
1832 (s390_trad_frame_prev_register, s390_unwind_cache)
1833 (s390_prologue_frame_unwind_cache)
1834 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
1835 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
1836 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
1837 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
1838 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
1839 (s390_frame_base_address, s390_local_base_address)
1840 (s390_frame_base, s390_gcc_target_options)
1841 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
1842 (s390_validate_reg_range, s390_tdesc_valid)
1843 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
1844 * s390-tdep.c: ...this. New file.
1845
9c0b896e
PR
18462018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1847
1848 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
1849 (s390_process_record, s390_gdbarch_tdep_alloc)
1850 (s390_linux_init_abi_any): Use/set new hook.
1851
7042632b
PR
18522018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1853
1854 * s390-linux-tdep.c (osabi.h): New include.
1855 (s390_linux_init_abi_31, s390_linux_init_abi_64)
1856 (s390_linux_init_abi_any): New functions.
1857 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
1858
650f5e13
PR
18592018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1860
1861 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
1862 tdesc_has_registers check
1863
47c9317e
PR
18642018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1865
1866 * s390-linux-tdep.c (s390_tdesc_valid): New function.
1867 (s390_validate_reg_range): New macro.
1868 (s390_gdbarch_init): Adjust.
1869
095085d8
PR
18702018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1871
1872 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
1873 (s390_gdbarch_tdep_alloc): Adjust.
1874 (s390_gdbarch_init): Adjust.
1875
ab9bcc67
PR
18762018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1877
1878 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
1879 <have_tdb>: Change type to bool.
1880 (s390_gdbarch_tdep_alloc): Adjust.
1881 (s390_gdbarch_init): Adjust.
1882
21f6f5ff
PR
18832018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1884
1885 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
1886 (gdbarch_tdep) <have_upper, have_vx>: New fields.
1887 (s390_gdbarch_tdep_alloc): New function.
1888 (s390_gdbarch_init): Allocate tdep at start and use its fields
1889 instead of separate variables.
1890
0eb97953
PR
18912018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1892
1893 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
1894 when looking for cached gdbarch and add comment for remaining.
1895
5c319bb2
PA
18962018-01-22 Pedro Alves <palves@redhat.com>
1897 Sergio Durigan Junior <sergiodj@redhat.com>
1898
1899 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
1900 case.
1901
d65ce302
MR
19022018-01-22 Maciej W. Rozycki <macro@mips.com>
1903
1904 * MAINTAINERS: Update my company e-mail address.
1905
ec7a5fcb
YQ
19062018-01-22 Yao Qi <yao.qi@linaro.org>
1907
1908 * regcache.c (cooked_write_test): New function.
1909 (_initialize_regcache): Register the test.
1910
11f57cb6
YQ
19112018-01-22 Yao Qi <yao.qi@linaro.org>
1912
1913 * ia64-tdep.c (ia64_pseudo_register_read): Call
1914 regcache->cooked_read instead of regcache_cooked_read_unsigned.
1915 * m32c-tdep.c (m32c_cat_read): Likewise.
1916 (m32c_r3r2r1r0_read): Likewise.
1917 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
1918 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
1919
03f50fc8
YQ
19202018-01-22 Yao Qi <yao.qi@linaro.org>
1921
1922 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
1923 method raw_read instead of regcache_raw_read.
1924 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
1925 * arm-tdep.c (arm_neon_quad_read): Likewise.
1926 * avr-tdep.c (avr_pseudo_register_read): Likewise.
1927 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
1928 * frv-tdep.c (frv_pseudo_register_read): Likewise.
1929 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
1930 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1931 (i386_pseudo_register_read_into_value): Likewise.
1932 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
1933 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
1934 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
1935 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
1936 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
1937 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
1938 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
1939 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
1940 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
1941
dc711524
YQ
19422018-01-22 Yao Qi <yao.qi@linaro.org>
1943
1944 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
1945 * configure.tgt: Remove target mt.
1946 * mt-tdep.c: Remove.
1947 * regcache.c (cooked_read_test): Remove the check for mt.
1948
3f5a868b
YQ
19492018-01-22 Yao Qi <yao.qi@linaro.org>
1950
1951 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
1952 instead of gdbarch_pseudo_register_read_value.
1953
de4cb04a
JB
19542018-01-22 Joel Brobecker <brobecker@adacore.com>
1955
1956 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
1957 language is Ada.
1958
a9e40818
JB
19592018-01-22 Joel Brobecker <brobecker@adacore.com>
1960
1961 * linespec.c (create_sals_line_offset): Remove code that preserved
1962 the symtab_and_line's line number.
1963
e707fc44
AB
19642018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1965
1966 * varobj.c (varobj_create): Don't set valid_block when creating a
1967 floating varobj.
1968
03d0bf7b
AB
19692018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1970
1971 * varobj.c (varobj_create): Remove out of date comment.
1972
ae451627
AB
19732018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1974
1975 PR mi/20395
1976 * ada-exp.y (write_var_from_sym): Pass extra parameter when
1977 updating innermost block.
1978 * parse.c (innermost_block_tracker::update): Take extra type
1979 parameter, and check types match before updating innermost block.
1980 (write_dollar_variable): Update innermost block for registers.
1981 * parser-defs.h (enum innermost_block_tracker_type): New enum.
1982 (innermost_block_tracker::innermost_block_tracker): Initialise
1983 m_types member.
1984 (innermost_block_tracker::reset): Take type parameter.
1985 (innermost_block_tracker::update): Take type parameter, and pass
1986 type through as needed.
1987 (innermost_block_tracker::m_types): New member.
1988 * varobj.c (varobj_create): Pass type when reseting innermost
1989 block.
1990
aee1fcdf
AB
19912018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1992
1993 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
1994 * ada-lang.c (resolve_subexp): Likewise.
1995 * breakpoint.c (set_breakpoint_condition) Likewise.
1996 (watch_command_1) Likewise.
1997 * c-exp.y (variable): Likewise.
1998 * d-exp.y (PrimaryExpression): Likewise.
1999 * f-exp.y (variable): Likewise.
2000 * go-exp.y (variable): Likewise.
2001 * m2-exp.y (variable): Likewise.
2002 * objfiles.c (objfile::~objfile): Likewise.
2003 * p-exp.y (variable): Likewise.
2004 * parse.c (innermost_block): Change type.
2005 * parser-defs.h (class innermost_block_tracker): New.
2006 (innermost_block): Change to innermost_block_tracker.
2007 * printcmd.c (display_command): Switch to innermost_block API.
2008 (do_one_display): Likewise.
2009 * rust-exp.y (do_one_display): Likewise.
2010 * symfile.c (clear_symtab_users): Likewise.
2011 * varobj.c (varobj_create): Switch to innermost_block API, replace
2012 use of innermost_block with block stored on varobj object.
2013
396af9a1
AB
20142018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
2015
2016 * expression.h (innermost_block): Remove declaration.
2017 * varobj.c: Add 'parser-defs.h' include.
2018
fcfcc376
TT
20192018-01-19 Tom Tromey <tom@tromey.com>
2020
2021 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
2022 symbols in the static and global blocks.
2023
5a6c3296
JC
20242018-01-19 James Clarke <jrtc27@jrtc27.com>
2025
2026 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
2027 gdb_ptrace.h, and move including gdb_wait.h ...
2028 * nat/linux-ptrace.h: ... to here.
2029
bc09b0c1
SM
20302018-01-19 Simon Marchi <simon.marchi@ericsson.com>
2031
2032 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
2033 inf_ptrace_detach_success.
2034 (inf_ptrace_detach_success): Add inferior parameter, use it
2035 instead of inferior_ptid, pass it to detach_inferior.
2036 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
2037 parameter.
2038 * inferior.c (detach_inferior): Add overload that takes an
2039 inferior object.
2040 * inferior.h (detach_inferior): Likewise.
2041 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
2042 use inferior_ptid, adjust call to inf_ptrace_detach_success.
2043 * linux-thread-db.c (thread_db_detach): Use inf parameter.
2044
6e1e1966
SM
20452018-01-19 Simon Marchi <simon.marchi@ericsson.com>
2046
2047 * target.h (struct target_ops) <to_detach>: Add inferior
2048 parameter.
2049 (target_detach): Likewise.
2050 * target.c (dispose_inferior): Pass inferior down.
2051 (target_detach): Pass inferior down. Assert that it is equal to
2052 the current inferior.
2053 * aix-thread.c (aix_thread_detach): Pass inferior down.
2054 * corefile.c (core_file_command): Pass current_inferior() down.
2055 * corelow.c (core_detach): Add inferior parameter.
2056 * darwin-nat.c (darwin_detach): Likewise.
2057 * gnu-nat.c (gnu_detach): Likewise.
2058 * inf-ptrace.c (inf_ptrace_detach): Likewise.
2059 * infcmd.c (detach_command): Pass current_inferior() down to
2060 target_detach.
2061 * infrun.c (follow_fork_inferior): Pass parent_inf to
2062 target_detach.
2063 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
2064 target_detach.
2065 * linux-nat.c (linux_nat_detach): Add inferior parameter.
2066 * linux-thread-db.c (thread_db_detach): Likewise.
2067 * nto-procfs.c (procfs_detach): Likewise.
2068 * procfs.c (procfs_detach): Likewise.
2069 * record.c (record_detach): Likewise.
2070 * record.h (struct inferior): Forward-declare.
2071 (record_detach): Add inferior parameter.
2072 * remote-sim.c (gdbsim_detach): Likewise.
2073 * remote.c (remote_detach_1): Likewise.
2074 (remote_detach): Likewise.
2075 (extended_remote_detach): Likewise.
2076 * sol-thread.c (sol_thread_detach): Likewise.
2077 * target-debug.h (target_debug_print_inferior_p): New macro.
2078 * target-delegates.c: Re-generate.
2079 * top.c (kill_or_detach): Pass inferior down to target_detach.
2080 * windows-nat.c (windows_detach): Add inferior parameter.
2081
6bd6f3b6
SM
20822018-01-19 Simon Marchi <simon.marchi@ericsson.com>
2083
2084 * target.h (struct target_ops) <to_detach>: Remove args
2085 parameter.
2086 (target_detach): Likewise.
2087 * target.c (dispose_inferior): Adjust.
2088 (target_detach): Remove args parameter, adjust.
2089 * aix-thread.c (aix_thread_detach): Adjust.
2090 * corefile.c (core_file_command): Adjust.
2091 * corelow.c (core_detach): Adjust.
2092 * darwin-nat.c (darwin_detach): Adjust.
2093 * gnu-nat.c (gnu_detach): Adjust.
2094 * inf-ptrace.c (inf_ptrace_detach): Adjust.
2095 * infcmd.c (detach_command): Adjust
2096 * infrun.c (follow_fork_inferior): Adjust.
2097 (handle_vfork_child_exec_or_exit): Adjust.
2098 * linux-fork.c (linux_fork_detach): Remove args parameter.
2099 * linux-fork.h (linux_fork_detach): Likewise.
2100 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
2101 * linux-thread-db.c (thread_db_detach): Likewise.
2102 * nto-procfs.c (procfs_detach): Likewise.
2103 * procfs.c (procfs_detach): Likewise.
2104 (do_detach): Remove signo parameter.
2105 * record.c (record_detach): Remove args parameter.
2106 * record.h (record_detach): Likewise.
2107 * remote-sim.c (gdbsim_detach): Likewise.
2108 * remote.c (remote_detach_1): Likewise.
2109 (remote_detach): Likewise.
2110 (extended_remote_detach): Likewise.
2111 * sol-thread.c (sol_thread_detach): Likewise.
2112 * target-delegates.c: Re-generate.
2113 * top.c (struct qt_args) <args>: Remove field.
2114 (kill_or_detach): Don't pass args.
2115 (quit_force): Don't set args.
2116 * windows-nat.c (windows_detach): Remove args parameter.
2117
88af8ea8
YQ
21182018-01-19 Yao Qi <yao.qi@linaro.org>
2119
2120 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
2121 (arm_linux_init_abi): Install it.
2122
dea445b9
YQ
21232018-01-19 Yao Qi <yao.qi@linaro.org>
2124
2125 * osabi.c (gdb_osabi_names): Extend the regexp for
2126 arm-linux-gnueabihf.
2127
4a17f768
YQ
21282018-01-18 Yao Qi <yao.qi@linaro.org>
2129
2130 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
2131 m_abbrevs.
2132 (abbrev_table::add_abbrev): Update.
2133 (abbrev_table::lookup_abbrev): Update.
2134
d679c21a
YQ
21352018-01-18 Yao Qi <yao.qi@linaro.org>
2136
2137 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
2138
7d937cad
SDJ
21392018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
2140
2141 * compile/compile.c (compile_to_object): Convert "triplet_rx"
2142 to "std::string".
2143
9e14690d
TT
21442018-01-17 Tom Tromey <tom@tromey.com>
2145
2146 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
2147
50a82047
TT
21482018-01-17 Tom Tromey <tom@tromey.com>
2149
2150 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
2151 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
2152 (create_array_type_with_stride): Update.
2153 * dwarf2read.c (set_die_type): Update.
2154
c89b44cd
TT
21552018-01-17 Tom Tromey <tom@tromey.com>
2156
2157 * dwarf2read.c (delayed_method_info): Remove typedef.
2158 (dwarf2_cu::method_info): Now a std::vector.
2159 (add_to_method_list): Update.
2160 (free_delayed_list): Remove.
2161 (compute_delayed_physnames): Update.
2162 (process_full_comp_unit, process_full_type_unit): Clear the method
2163 list. Remove cleanups.
2164 (psymtab_include_file_name): Add name_holder parameter. Use
2165 unique_xmalloc_ptr.
2166 (dwarf_decode_lines): Update.
2167
fcd3b13d
SM
21682018-01-17 Tom Tromey <tom@tromey.com>
2169 Simon Marchi <simon.marchi@ericsson.com>
2170
2171 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
2172 (dwarf2_per_objfile::free_cached_comp_units)
2173 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
2174 (init_cutu_and_read_dies_no_follow): Update.
2175 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
2176 (dwarf2_cu::~dwarf2_cu): New.
2177 (free_heap_comp_unit, free_stack_comp_unit): Remove.
2178 (age_cached_comp_units, free_one_cached_comp_unit): Update.
2179
685af9cd
TT
21802018-01-17 Tom Tromey <tom@tromey.com>
2181 Simon Marchi <simon.marchi@ericsson.com>
2182
2183 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
2184 (struct die_reader_specs) <abbrev_table>: New member.
2185 (struct abbrev_table): Add constructor.
2186 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
2187 <abbrev_obstack>: Now an auto_obstack.
2188 (abbrev_table_up): New typedef.
2189 (init_cu_die_reader): Add abbrev_table parameter.
2190 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
2191 Add result_dwo_abbrev_table.
2192 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
2193 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
2194 Update.
2195 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
2196 parameter.
2197 (skip_children): Update.
2198 (abbrev_table::alloc_abbrev): Rename from
2199 abbrev_table_alloc_abbrev.
2200 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
2201 (abbrev_table::lookup_abbrev): Rename from
2202 abbrev_table_lookup_abbrev.
2203 (abbrev_table_read_table): Return abbrev_table_up.
2204 (abbrev_table_free, abbrev_table_free_cleanup)
2205 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
2206 (load_partial_dies): Update.
2207
5e2db402
TT
22082018-01-17 Tom Tromey <tom@tromey.com>
2209
2210 * dwarf2read.c (dwarf2_compute_name): Update comment.
2211 (read_func_scope, read_variable): Update.
2212 (new_symbol): Remove.
2213 (new_symbol_full): Rename to new_symbol.
2214
ee7f689e 22152018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
2216
2217 PR gdb/16577
2218 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
2219 a warning instead of throwing an error, set section size to 0 and return
2220 NULL.
2221 * gdb_bfd.h (gdb_bfd_map_section): Update description.
2222
4d9b86e1
SM
22232018-01-17 Simon Marchi <simon.marchi@ericsson.com>
2224
2225 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
2226 std::string.
2227 (linux_ptrace_attach_fail_reason_string): Likewise.
2228 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
2229 Likewise.
2230 (linux_ptrace_attach_fail_reason_string): Likewise.
2231 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
2232
a7b2d0fb
SM
22332018-01-17 Simon Marchi <simon.marchi@ericsson.com>
2234
2235 * linux-nat.c (linux_nat_attach): Remove xstrdup.
2236
f517c180
EA
22372018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
2238
2239 PR gdb/21559
2240 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
2241 checking for fs_base/gs_base fields in struct user_regs_struct.
2242 * configure: Regenerate.
2243
7045b1ca
YQ
22442018-01-17 Yao Qi <yao.qi@linaro.org>
2245
2246 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
2247 function.
2248 (aarch64_linux_init_abi): Install it to gdbarch hook
2249 gcc_target_options.
2250
db422fb2
PA
22512018-01-15 Pedro Alves <palves@redhat.com>
2252
2253 * common/signals-state-save-restore.c
2254 (save_original_signals_state): Fix typos.
2255
ba643918
SDJ
22562017-01-12 Tom Tromey <tom@tromey.com>
2257 Sergio Durigan Junior <sergiodj@redhat.com>
2258
2259 * Makefile.in (install-only): Install gdb-add-index.
2260
906b4aac
JB
22612018-01-12 John Baldwin <jhb@FreeBSD.org>
2262
2263 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
2264
bdf2a94a
AA
22652018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
2266
2267 * infrun.c (keep_going_pass_signal): Clear step-over info when
2268 insert_breakpoints fails.
2269
71d378ae
PA
22702018-01-11 Pedro Alves <palves@redhat.com>
2271
2272 PR gdb/22583
2273 * infrun.c (resume): Rename to ...
2274 (resume_1): ... this.
2275 (resume): Reimplement as wrapper around resume_1.
2276
3cada740
PA
22772018-01-11 Pedro Alves <palves@redhat.com>
2278
2279 PR remote/22597
2280 * remote.c (remote_parse_stop_reply): Default to the last-set
2281 general thread instead of to 'magic_null_ptid'.
2282
618daa93
PA
22832018-01-10 Pedro Alves <palves@redhat.com>
2284
2285 * language.h (language_get_symbol_name_matcher): Rename ...
2286 (get_symbol_name_matcher): ... this.
2287 * language.c (language_get_symbol_name_matcher): Ditto.
2288 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
2289 callers adjusted.
2290
c63d3e8d
PA
22912018-01-10 Pedro Alves <palves@redhat.com>
2292
2293 PR gdb/22670
2294 * dwarf2read.c
2295 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
2296 Adjust to use language_get_symbol_name_matcher instead of
2297 language_defn::la_get_symbol_name_matcher.
2298 * language.c (language_get_symbol_name_matcher): If in Ada mode
2299 and the lookup name is a verbatim match, return Ada's matcher.
2300 * language.h (language_get_symbol_name_matcher): Adjust comment.
2301 (ada_lookup_name_info::verbatim_p):: New method.
2302
d4c2a405
PA
23032018-01-10 Pedro Alves <palves@redhat.com>
2304
2305 PR gdb/22670
2306 * ada-lang.c (ada_collect_symbol_completion_matches): If the
2307 minsym's language is language_auto or language_cplus, pass down
2308 language_ada instead.
2309 * symtab.c (compare_symbol_name): Don't frob symbol language here.
2310
8825213e
PA
23112018-01-10 Pedro Alves <palves@redhat.com>
2312
2313 PR gdb/22670
2314 * minsyms.c (linkage_name_str): New function.
2315 (iterate_over_minimal_symbols): Use it.
2316
2d97a5d9
JB
23172018-01-09 John Baldwin <jhb@FreeBSD.org>
2318
2319 * NEWS: Document that 'info proc' now works on FreeBSD.
2320
92fce24d
JB
23212018-01-09 John Baldwin <jhb@FreeBSD.org>
2322
2323 * configure.ac: Check for kinfo_getfile in libutil.
2324 * configure: Regenerate.
2325 * config.in: Regenerate.
2326 * fbsd-nat.c: Include "fbsd-tdep.h".
2327 (fbsd_fetch_cmdline): New.
2328 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
2329 rather than calling error.
2330 (fbsd_info_proc): New.
2331 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
2332 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
2333 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
2334
262f62f5
JB
23352018-01-09 John Baldwin <jhb@FreeBSD.org>
2336
2337 * fbsd-nat.c (struct free_deleter): Remove.
2338 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
2339
b999e203
JB
23402018-01-09 John Baldwin <jhb@FreeBSD.org>
2341
2342 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
2343 NULL for an empty pathname.
2344
d2176225
JB
23452018-01-09 John Baldwin <jhb@FreeBSD.org>
2346
2347 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
2348 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
2349 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
2350 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
2351 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
2352 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
2353 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
2354 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
2355 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
2356 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
2357 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
2358 (fbsd_core_fetch_timeval, fbsd_print_sigset)
2359 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
2360 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
2361 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
2362
9c4ac400
ST
23632018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
2364
2365 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
2366 (gnu_xfer_auxv): New function.
2367 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
2368 TARGET_OBJECT_AUXV.
2369
1e5ded6c
YQ
23702018-01-08 Yao Qi <yao.qi@linaro.org>
2371 Simon Marchi <simon.marchi@ericsson.com>
2372
2373 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
2374 common/selftest.c.
2375 (COMMON_OBS): Remove selftest.o.
2376 * configure.ac: Append selftest-arch.c and common/selftest.c to
2377 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
2378 * configure: Re-generated.
2379 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
2380 GDB_SELF_TEST.
2381 (maintenance_info_selftests): Likewise.
2382
04bafb1e
XR
23832018-01-08 Xavier Roirand <roirand@adacore.com>
2384
2385 * ada-valprint.c (val_print_packed_array_elements): Use
2386 proper number of elements when printing an array indexed
2387 by an enumeration type.
2388
518817b3
SM
23892018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2390
2391 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
2392 (dw2_get_file_names_reader): Adjust.
2393 (lookup_dwo_signatured_type): Adjust.
2394 (lookup_dwp_signatured_type): Adjust.
2395 (lookup_signatured_type): Adjust.
2396 (create_type_unit_group): Adjust.
2397 (get_type_unit_group): Adjust.
2398 (process_psymtab_comp_unit_reader): Adjust.
2399 (build_type_psymtabs_reader): Adjust.
2400 (scan_partial_symbols): Adjust.
2401 (add_partial_symbol): Adjust.
2402 (add_partial_subprogram): Adjust.
2403 (peek_die_abbrev): Adjust.
2404 (fixup_go_packaging): Adjust.
2405 (process_imported_unit_die): Adjust.
2406 (dwarf2_compute_name): Adjust.
2407 (dwarf2_physname): Adjust.
2408 (read_import_statement): Adjust.
2409 (handle_DW_AT_stmt_list): Adjust.
2410 (read_file_scope): Adjust.
2411 (read_func_scope): Adjust.
2412 (read_lexical_block_scope): Adjust.
2413 (read_call_site_scope): Adjust.
2414 (read_variable): Adjust.
2415 (dwarf2_rnglists_process): Adjust.
2416 (dwarf2_ranges_process): Adjust.
2417 (dwarf2_ranges_read): Adjust.
2418 (dwarf2_get_pc_bounds): Adjust.
2419 (dwarf2_record_block_ranges): Adjust.
2420 (dwarf2_add_field): Adjust.
2421 (dwarf2_add_member_fn): Adjust.
2422 (read_structure_type): Adjust.
2423 (process_structure_scope): Adjust.
2424 (read_enumeration_type): Adjust.
2425 (read_array_type): Adjust.
2426 (mark_common_block_symbol_computed): Adjust.
2427 (read_common_block): Adjust.
2428 (read_namespace_type): Adjust.
2429 (read_namespace): Adjust.
2430 (read_module_type): Adjust.
2431 (read_tag_pointer_type): Adjust.
2432 (read_tag_ptr_to_member_type): Adjust.
2433 (read_tag_string_type): Adjust.
2434 (read_subroutine_type): Adjust.
2435 (read_typedef): Adjust.
2436 (read_base_type): Adjust.
2437 (attr_to_dynamic_prop): Adjust.
2438 (read_subrange_type): Adjust.
2439 (read_unspecified_type): Adjust.
2440 (dwarf2_read_abbrevs): Adjust.
2441 (load_partial_dies): Adjust.
2442 (read_partial_die): Adjust.
2443 (find_partial_die): Adjust.
2444 (guess_partial_die_structure_name): Adjust.
2445 (fixup_partial_die): Adjust.
2446 (read_attribute_value): Adjust.
2447 (read_addr_index): Adjust.
2448 (read_addr_index_from_leb128): Adjust.
2449 (read_str_index): Adjust.
2450 (dwarf2_string_attr): Adjust.
2451 (get_debug_line_section): Adjust.
2452 (dwarf_decode_line_header): Adjust.
2453 (lnp_state_machine::check_line_address): Adjust.
2454 (dwarf_decode_lines_1): Adjust.
2455 (dwarf_decode_lines): Adjust.
2456 (dwarf2_start_symtab): Adjust.
2457 (var_decode_location): Adjust.
2458 (new_symbol_full): Adjust.
2459 (dwarf2_const_value_data): Adjust.
2460 (dwarf2_const_value_attr): Adjust.
2461 (dwarf2_const_value): Adjust.
2462 (die_type): Adjust.
2463 (die_containing_type): Adjust.
2464 (build_error_marker_type): Adjust.
2465 (lookup_die_type): Adjust.
2466 (guess_full_die_structure_name): Adjust.
2467 (anonymous_struct_prefix): Adjust.
2468 (determine_prefix): Adjust.
2469 (dwarf2_name): Adjust.
2470 (follow_die_ref_or_sig): Adjust.
2471 (follow_die_offset): Adjust.
2472 (follow_die_ref): Adjust.
2473 (follow_die_sig_1): Adjust.
2474 (follow_die_sig): Adjust.
2475 (get_signatured_type): Adjust.
2476 (get_DW_AT_signature_type): Adjust.
2477 (decode_locdesc): Adjust.
2478 (dwarf_decode_macros): Adjust.
2479 (cu_debug_loc_section): Adjust.
2480 (fill_in_loclist_baton): Adjust.
2481 (dwarf2_symbol_mark_computed): Adjust.
2482 (init_one_comp_unit): Don't assign
2483 dwarf2_cu::dwarf2_per_objfile.
2484 (set_die_type): Adjust.
2485
ed2dc618
SM
24862018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2487
2488 * dwarf2read.c (struct mapped_debug_names): Add constructor.
2489 <dwarf2_per_objfile>: New field.
2490 (dwarf2_per_objfile): Remove global.
2491 (get_dwarf2_per_objfile): New function.
2492 (set_dwarf2_per_objfile): New function.
2493 (dwarf2_build_psymtabs_hard): Change objfile parameter to
2494 dwarf2_per_objfile.
2495 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
2496 (read_abbrev_offset): Likewise.
2497 (read_indirect_string): Likewise.
2498 (read_indirect_line_string): Likewise.
2499 (read_indirect_string_at_offset): Likewise.
2500 (read_indirect_string_from_dwz): Likewise.
2501 (dwarf2_find_containing_comp_unit): Change objfile parameter to
2502 dwarf2_per_objfile.
2503 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
2504 (create_all_comp_units): Change objfile parameter to
2505 dwarf2_per_objfile.
2506 (create_all_type_units): Likewise.
2507 (process_queue): Add dwarf2_per_objfile parameter.
2508 (read_and_check_comp_unit_head): Likewise.
2509 (lookup_dwo_unit_in_dwp): Likewise.
2510 (get_dwp_file): Likewise.
2511 (process_cu_includes): Likewise.
2512 (struct free_dwo_file_cleanup_data): New struct.
2513 (dwarf2_has_info): Use get_dwarf2_per_objfile and
2514 set_dwarf2_per_objfile.
2515 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
2516 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
2517 context, adjust calls.
2518 (dw2_instantiate_symtab): Likewise.
2519 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
2520 (dw2_get_cu): Likewise.
2521 (create_cu_from_index_list): Change objfile parameter to
2522 dwarf2_per_objfile.
2523 (create_cus_from_index_list): Get dwarf2_per_objfile from
2524 context, adjust calls.
2525 (create_cus_from_index): Likewise.
2526 (create_signatured_type_table_from_index): Change objfile
2527 parameter to dwarf2_per_objfile.
2528 (create_signatured_type_table_from_debug_names): Change objfile
2529 parameter to dwarf2_per_objfile.
2530 (create_addrmap_from_index): Likewise.
2531 (create_addrmap_from_aranges): Likewise.
2532 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
2533 (dw2_setup): Remove.
2534 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
2535 context.
2536 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
2537 get_dwarf2_per_objfile.
2538 (dw2_forget_cached_source_info): Likewise.
2539 (dw2_map_symtabs_matching_filename): Likewise.
2540 (struct dw2_symtab_iterator) <index>: Remove.
2541 <dwarf2_per_objfile>: New field.
2542 (dw2_symtab_iter_init): Replace index parameter with
2543 dwarf2_per_objfile.
2544 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
2545 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
2546 (dw2_print_stats): Likewise.
2547 (dw2_dump): Likewise.
2548 (dw2_expand_symtabs_for_function): Likewise.
2549 (dw2_expand_all_symtabs): Likewise.
2550 (dw2_expand_symtabs_with_fullname): Likewise.
2551 (dw2_expand_marked_cus): Replace index and objfile parameters
2552 with dwarf2_per_objfile.
2553 (dw_expand_symtabs_matching_file_matcher): Add
2554 dwarf2_per_objfile parameter and adjust calls.
2555 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
2556 adjust calls.
2557 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
2558 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
2559 adjust calls.
2560 (create_cus_from_debug_names_list): Replace objfile parameter
2561 with dwarf2_per_objfile and adjust calls.
2562 (create_cus_from_debug_names): Likewise.
2563 (dwarf2_read_debug_names): Likewise.
2564 (mapped_debug_names::namei_to_name): Adjust call.
2565 (dw2_debug_names_iterator::next): Likewise.
2566 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
2567 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
2568 (dw2_debug_names_dump): Likewise.
2569 (dw2_debug_names_expand_symtabs_for_function): Likewise.
2570 (dw2_debug_names_expand_symtabs_matching): Likewise.
2571 (dwarf2_initialize_objfile): Likewise.
2572 (dwarf2_build_psymtabs): Likewise.
2573 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
2574 this_cu.
2575 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
2576 (read_and_check_comp_unit_head): Likewise.
2577 (read_abbrev_offset): Likewise.
2578 (create_debug_type_hash_table): Likewise.
2579 (create_debug_types_hash_table): Likewise.
2580 (create_all_type_units): Replace objfile parameter with
2581 dwarf2_per_objfile.
2582 (add_type_unit): Add dwarf2_per_objfile parameter.
2583 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
2584 with dwarf2_per_objfile.
2585 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
2586 (lookup_dwp_signatured_type): Likewise.
2587 (lookup_signatured_type): Likewise.
2588 (read_cutu_die_from_dwo): Likewise.
2589 (init_tu_and_read_dwo_dies): Likewise.
2590 (init_cutu_and_read_dies): Likewise.
2591 (init_cutu_and_read_dies_no_follow): Likewise.
2592 (allocate_type_unit_groups_table): Add objfile parameter.
2593 (create_type_unit_group): Use dwarf2_per_objfile from cu.
2594 (get_type_unit_group): Likewise.
2595 (process_psymtab_comp_unit): Update call.
2596 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
2597 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
2598 (print_tu_stats): Likewise.
2599 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
2600 in void* parameter.
2601 (build_type_psymtabs): Change objfile parameter to
2602 dwarf2_per_objfile.
2603 (process_skeletonless_type_unit): Use dwarf2_per_objfile
2604 passed in void* parameter.
2605 (process_skeletonless_type_units): Change objfile parameter to
2606 dwarf2_per_objfile.
2607 (set_partial_user): Likewise.
2608 (dwarf2_build_psymtabs_hard): Likewise.
2609 (read_comp_units_from_section): Likewise.
2610 (create_all_comp_units): Likewise.
2611 (scan_partial_symbols): Update calls.
2612 (add_partial_symbol): Likewise.
2613 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
2614 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
2615 (process_queue): Add dwarf2_per_objfile parameter.
2616 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
2617 (compute_compunit_symtab_includes): Likewise.
2618 (process_cu_includes): Add dwarf2_per_objfile parameter.
2619 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
2620 (process_full_type_unit): Likewise.
2621 (process_imported_unit_die): Update call.
2622 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
2623 (read_file_scope): Likewise.
2624 (allocate_dwo_file_hash_table): Add objfile parameter.
2625 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
2626 (create_cus_hash_table): Likewise.
2627 (create_dwp_hash_table): Likewise.
2628 (create_dwo_unit_in_dwp_v1): Likewise.
2629 (create_dwp_v2_section): Likewise.
2630 (create_dwo_unit_in_dwp_v2): Likewise.
2631 (lookup_dwo_unit_in_dwp): Likewise.
2632 (try_open_dwop_file): Likewise.
2633 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
2634 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
2635 cleanup to include a reference to dwarf2_per_objfile.
2636 (open_dwp_file): Add dwarf2_per_objfile parameter.
2637 (open_and_init_dwp_file): Likewise.
2638 (get_dwp_file): Likewise.
2639 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
2640 (queue_and_load_all_dwo_tus): Update call.
2641 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
2642 data.
2643 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
2644 (dwarf2_ranges_process): Likewise.
2645 (dwarf2_get_pc_bounds): Likewise.
2646 (mark_common_block_symbol_computed): Likewise.
2647 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
2648 (dwarf2_read_abbrevs): Update call.
2649 (read_partial_die): Use dwarf2_per_objfile from cu.
2650 (find_partial_die): Likewise.
2651 (fixup_partial_die): Likewise.
2652 (read_attribute_value): Likewise.
2653 (read_indirect_string_at_offset_from): Add objfile parameter.
2654 (read_indirect_string_at_offset): Add dwarf2_per_objfile
2655 parameter.
2656 (read_indirect_string_from_dwz): Add objfile parameter.
2657 (read_indirect_string): Add objfile parameter.
2658 (read_addr_index_1): Add dwarf2_per_objfile parameter.
2659 (read_addr_index): Use dwarf2_per_objfile from cu.
2660 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
2661 call dw2_setup.
2662 (read_str_index): Use dwarf2_per_objfile from cu.
2663 (get_debug_line_section): Likewise.
2664 (read_formatted_entries): Add dwarf2_per_objfile parameter.
2665 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
2666 (new_symbol_full): Use dwarf2_per_objfile from cu.
2667 (build_error_marker_type): Likewise.
2668 (lookup_die_type): Likewise.
2669 (determine_prefix): Likewise.
2670 (follow_die_offset): Likewise.
2671 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
2672 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
2673 (dwarf2_fetch_die_type_sect_off): Likewise.
2674 (dwarf2_get_die_type): Likewise.
2675 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
2676 (get_signatured_type): Likewise.
2677 (get_DW_AT_signature_type): Likewise.
2678 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
2679 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
2680 (cu_debug_loc_section): Likewise.
2681 (fill_in_loclist_baton): Likewise.
2682 (dwarf2_symbol_mark_computed): Likewise.
2683 (dwarf2_find_containing_comp_unit): Change objfile parameter to
2684 dwarf2_per_objfile.
2685 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
2686 parameter.
2687 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
2688 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
2689 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
2690 (set_die_type): Use dwarf2_free_objfile from cu.
2691 (get_die_type_at_offset): Likewise.
2692 (dwarf2_per_objfile_free): Don't assign global variable.
2693 (debug_names) <constructor>: Add dwarf2_per_objfile
2694 parameter, update m_debugstrlookup construction.
2695 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
2696 parameter.
2697 <m_dwarf2_per_objfile>: New field.
2698 <lookup>: Use m_dwarf2_per_objfile.
2699 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
2700 (psyms_seen_size): Likewise.
2701 (write_gdbindex): Replace objfile parameter with
2702 dwarf2_per_objfile.
2703 (write_debug_names): Likewise.
2704 (write_psymtabs_to_index): Likewise.
2705 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
2706 calls.
2707
e3b94546
SM
27082018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2709
2710 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
2711 <dwarf2_per_objfile>: New field.
2712 (struct dwarf2_per_cu_data) <objfile>: Remove.
2713 <dwarf2_per_objfile>: New field.
2714 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
2715 of objfile.
2716 (create_signatured_type_table_from_index): Likewise.
2717 (create_debug_type_hash_table): Likewise.
2718 (fill_in_sig_entry_from_dwo_entry): Likewise.
2719 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
2720 (create_type_unit_group): Assign dwarf2_per_objfile instead of
2721 objfile.
2722 (create_partial_symtab): Access objfile through
2723 dwarf2_per_objfile.
2724 (process_psymtab_comp_unit_reader): Likewise.
2725 (read_comp_units_from_section): Likewise.
2726 (scan_partial_symbols): Likewise.
2727 (add_partial_symbol): Likewise.
2728 (add_partial_subprogram): Likewise.
2729 (peek_die_abbrev): Likewise.
2730 (fixup_go_packaging): Likewise.
2731 (process_full_comp_unit): Likewise.
2732 (process_full_type_unit): Likewise.
2733 (process_imported_unit_die): Likewise.
2734 (dwarf2_compute_name): Likewise.
2735 (dwarf2_physname): Likewise.
2736 (read_import_statement): Likewise.
2737 (create_cus_hash_table): Assign dwarf2_physname instead of
2738 objfile.
2739 (read_func_scope): Access objfile through dwarf2_per_objfile.
2740 (read_lexical_block_scope): Likewise.
2741 (read_call_site_scope): Likewise.
2742 (read_variable): Likewise.
2743 (dwarf2_rnglists_process): Likewise.
2744 (dwarf2_ranges_process): Likewise.
2745 (dwarf2_ranges_read): Likewise.
2746 (dwarf2_record_block_ranges): Likewise.
2747 (dwarf2_add_field): Likewise.
2748 (dwarf2_add_member_fn): Likewise.
2749 (read_structure_type): Likewise.
2750 (process_structure_scope): Likewise.
2751 (read_enumeration_type): Likewise.
2752 (read_array_type): Likewise.
2753 (read_common_block): Likewise.
2754 (read_namespace_type): Likewise.
2755 (read_namespace): Likewise.
2756 (read_module_type): Likewise.
2757 (read_tag_pointer_type): Likewise.
2758 (read_tag_ptr_to_member_type): Likewise.
2759 (read_tag_string_type): Likewise.
2760 (read_subroutine_type): Likewise.
2761 (read_typedef): Likewise.
2762 (read_base_type): Likewise.
2763 (attr_to_dynamic_prop): Likewise.
2764 (read_subrange_type): Likewise.
2765 (read_unspecified_type): Likewise.
2766 (load_partial_dies): Likewise.
2767 (read_partial_die): Likewise.
2768 (find_partial_die): Likewise.
2769 (guess_partial_die_structure_name): Likewise.
2770 (fixup_partial_die): Likewise.
2771 (read_attribute_value): Likewise.
2772 (read_addr_index_from_leb128): Likewise.
2773 (dwarf2_read_addr_index): Likewise.
2774 (dwarf2_string_attr): Likewise.
2775 (lnp_state_machine::check_line_address): Likewise.
2776 (dwarf_decode_lines_1): Likewise.
2777 (dwarf_decode_lines): Likewise.
2778 (dwarf2_start_symtab): Likewise.
2779 (var_decode_location): Likewise.
2780 (new_symbol_full): Likewise.
2781 (dwarf2_const_value_data): Likewise.
2782 (dwarf2_const_value_attr): Likewise.
2783 (dwarf2_const_value): Likewise.
2784 (die_type): Likewise.
2785 (die_containing_type): Likewise.
2786 (lookup_die_type): Likewise.
2787 (guess_full_die_structure_name): Likewise.
2788 (anonymous_struct_prefix): Likewise.
2789 (dwarf2_name): Likewise.
2790 (follow_die_ref_or_sig): Likewise.
2791 (follow_die_offset): Likewise.
2792 (follow_die_ref): Likewise.
2793 (dwarf2_fetch_die_loc_sect_off): Likewise.
2794 (dwarf2_fetch_constant_bytes): Likewise.
2795 (dwarf2_fetch_die_type_sect_off): Likewise.
2796 (dwarf2_get_die_type): Likewise.
2797 (follow_die_sig): Likewise.
2798 (decode_locdesc): Likewise.
2799 (dwarf2_per_cu_objfile): Likewise.
2800 (dwarf2_per_cu_text_offset): Likewise.
2801 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
2802 objfile.
2803 (set_die_type): Access objfile through
2804 dwarf2_per_objfile.
2805
b01ba14d
SM
28062018-01-07 Simon Marchi <simon.marchi@ericsson.com>
2807
2808 * valprint.c (converted_character_d): Remove typedef.
2809 (DEF_VEC_O (converted_character_d)): Remove.
2810 (count_next_character): Use std::vector.
2811 (print_converted_chars_to_obstack): Likewise.
2812 (generic_printstr): Likewise.
2813
4d0fdd9b
SM
28142018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2815
2816 * xml-support.h (struct gdb_xml_value): Add constructor.
2817 <value>: Change type to unique_xmalloc_ptr.
2818 (gdb_xml_value_s): Remove typedef.
2819 (DEF_VEC_O (gdb_xml_value_s)): Remove.
2820 (gdb_xml_element_start_handler): Change parameter type to
2821 std::vector.
2822 (xml_find_attribute): Likewise.
2823 * xml-support.c (xml_find_attribute): Change parameter type to
2824 std::vector and adjust.
2825 (gdb_xml_values_cleanup): Remove.
2826 (gdb_xml_parser::start_element): Adjust to std::vector.
2827 (xinclude_start_include): Change paraeter type to std::vector
2828 and adjust.
2829 * btrace.c (check_xml_btrace_version): Likewise.
2830 (parse_xml_btrace_block): Likewise.
2831 (parse_xml_btrace_pt_config_cpu): Likewise.
2832 (parse_xml_btrace_pt): Likewise.
2833 (parse_xml_btrace_conf_bts): Likewise.
2834 (parse_xml_btrace_conf_pt): Likewise.
2835 * memory-map.c (memory_map_start_memory): Likewise.
2836 (memory_map_start_property): Likewise.
2837 * osdata.c (osdata_start_osdata): Likewise.
2838 (osdata_start_item): Likewise.
2839 (osdata_start_column): Likewise.
2840 * remote.c (start_thread): Likewise.
2841 * solib-aix.c (library_list_start_library): Likewise.
2842 (library_list_start_list): Likewise.
2843 * solib-svr4.c (library_list_start_library): Likewise.
2844 (svr4_library_list_start_list): Likewise.
2845 * solib-target.c (library_list_start_segment): Likewise.
2846 (library_list_start_section): Likewise.
2847 (library_list_start_library): Likewise.
2848 (library_list_start_list): Likewise.
2849 * tracepoint.c (traceframe_info_start_memory): Likewise.
2850 (traceframe_info_start_tvar): Likewise.
2851 * xml-syscall.c (syscall_start_syscall): Likewise.
2852 * xml-tdesc.c (tdesc_start_target): Likewise.
2853 (tdesc_start_feature): Likewise.
2854 (tdesc_start_reg): Likewise.
2855 (tdesc_start_union): Likewise.
2856 (tdesc_start_struct): Likewise.
2857 (tdesc_start_flags): Likewise.
2858 (tdesc_start_enum): Likewise.
2859 (tdesc_start_field): Likewise.
2860 (tdesc_start_enum_value): Likewise.
2861 (tdesc_start_vector): Likewise.
2862
f979c73f
SM
28632018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2864
2865 * extension.h (struct xmethod_worker) <clone>: Remove.
2866 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
2867 Remove.
2868 (python_xmethod_worker::clone): Remove.
2869 * valops.c (find_overload_match): Use std::move instead of
2870 clone.
2871
ba18742c
SM
28722018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2873
2874 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
2875 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
2876 <free_xmethod_worker_data>: Remove.
2877 <get_matching_xmethod_workers>: Chance VEC to std::vector.
2878 <get_xmethod_arg_types>: Remove.
2879 <get_xmethod_result_type>: Remove.
2880 <invoke_xmethod>: Remove.
2881 * extension.c (new_xmethod_worker): Remove.
2882 (clone_xmethod_worker): Remove.
2883 (get_matching_xmethod_workers): Return void, pass std::vector by
2884 pointer.
2885 (get_xmethod_arg_types): Rename to...
2886 (xmethod_worker::get_arg_types): ... this, and adjust.
2887 (get_xmethod_result_type): Rename to...
2888 (xmethod_worker::get_result_type): ... this, and adjust.
2889 (invoke_xmethod): Remove.
2890 (free_xmethod_worker): Remove.
2891 (free_xmethod_worker_vec): Remove.
2892 * extension.h (enum ext_lang_rc): Move here from
2893 extension-priv.h.
2894 (struct xmethod_worker): Add constructor and destructor.
2895 <data>: Remove.
2896 <value>: Remove.
2897 <invoke, clone, do_get_result_type, do_get_arg_types>: New
2898 virtual pure methods.
2899 <get_arg_types, get_result_type>: New methods.
2900 (xmethod_worker_ptr): Remove typedef.
2901 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
2902 (xmethod_worker_vec): Remove typedef.
2903 (xmethod_worker_up): New typedef.
2904 (invoke_xmethod): Remove.
2905 (clone_xmethod_worker): Remove.
2906 (free_xmethod_worker): Remove.
2907 (free_xmethod_worker_vec): Remove.
2908 (get_xmethod_arg_types): Remove.
2909 (get_xmethod_result_type): Remove.
2910 * valops.c (find_method_list): Use std::vector, don't use
2911 intermediate vector.
2912 (value_find_oload_method_list): Use std::vector.
2913 (find_overload_match): Use std::vector.
2914 (find_oload_champ): Use std::vector.
2915 * value.c (value_free): Use operator delete.
2916 (value_of_xmethod): Rename to...
2917 (value_from_xmethod): ... this. Don't assign
2918 xmethod_worker::value, take rvalue-reference.
2919 (result_type_of_xmethod): Adjust.
2920 (call_xmethod): Adjust.
2921 * value.h: Include extension.h.
2922 (struct xmethod_worker): Don't forward-declare.
2923 (value_of_xmethod): Rename to...
2924 (value_from_xmethod): ... this, take rvalue-reference.
2925 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
2926 (struct python_xmethod_worker): ... this, add constructor and
2927 destructor.
2928 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
2929 (gdbpy_free_xmethod_worker_data): Rename to...
2930 (python_xmethod_worker::~python_xmethod_worker): ... this and
2931 adjust.
2932 (gdbpy_clone_xmethod_worker_data): Rename to...
2933 (python_xmethod_worker::clone): ... this and adjust.
2934 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
2935 temporary vector.
2936 (gdbpy_get_xmethod_arg_types): Rename to...
2937 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
2938 (gdbpy_get_xmethod_result_type): Rename to...
2939 (python_xmethod_worker::do_get_result_type): ... this and
2940 adjust.
2941 (gdbpy_invoke_xmethod): Rename to...
2942 (python_xmethod_worker::invoke): ... this and adjust.
2943 (new_python_xmethod_worker): Rename to...
2944 (python_xmethod_worker::python_xmethod_worker): ... this and
2945 adjust.
2946 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
2947 Remove.
2948 (gdbpy_free_xmethod_worker_data): Remove.
2949 (gdbpy_get_matching_xmethod_workers): Use std::vector.
2950 (gdbpy_get_xmethod_arg_types): Remove.
2951 (gdbpy_get_xmethod_result_type): Remove.
2952 (gdbpy_invoke_xmethod): Remove.
2953 * python/python.c (python_extension_ops): Remove obsolete
2954 callbacks.
2955
e379cee6
PA
29562018-01-05 Pedro Alves <palves@redhat.com>
2957
2958 PR gdb/18653
2959 * common/signals-state-save-restore.c
2960 (save_original_signals_state): New parameter 'quiet'. Warn if we
2961 find a custom handler preinstalled, instead of internal erroring.
2962 But only warn if !quiet.
2963 * common/signals-state-save-restore.h
2964 (save_original_signals_state): New parameter 'quiet'.
2965 * main.c (captured_main_1): Move save_original_signals_state call
2966 after option handling, and pass QUIET.
2967
a655456c
PA
29682018-01-05 Pedro Alves <palves@redhat.com>
2969
2970 * spu-tdep.c (spu_catch_start): Pass
2971 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
2972
de63c46b
PA
29732018-01-05 Pedro Alves <palves@redhat.com>
2974
2975 PR gdb/22670
2976 * ada-lang.c (literal_symbol_name_matcher): New function.
2977 (ada_get_symbol_name_matcher): Use it for
2978 symbol_name_match_type::SEARCH_NAME.
2979 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
2980 it down instead of assuming symbol_name_match_type::FULL.
2981 * block.h (block_lookup_symbol): New parameter 'match_type'.
2982 * c-valprint.c (print_unpacked_pointer): Use
2983 lookup_symbol_search_name instead of lookup_symbol.
2984 * compile/compile-object-load.c (get_out_value_type): Pass down
2985 symbol_name_match_type::SEARCH_NAME.
2986 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
2987 symbol_name_match_type::FULL.
2988 * cp-support.c (cp_get_symbol_name_matcher): Handle
2989 symbol_name_match_type::SEARCH_NAME.
2990 * infrun.c (insert_exception_resume_breakpoint): Use
2991 lookup_symbol_search_name.
2992 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
2993 * psymtab.c (maintenance_check_psymtabs): Use
2994 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
2995 * stack.c (print_frame_args): Use lookup_symbol_search_name and
2996 SYMBOL_SEARCH_NAME.
2997 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
2998 if symbol_name_match_type::SEARCH_NAME.
2999 (lookup_symbol_in_language): Pass down
3000 symbol_name_match_type::FULL.
3001 (lookup_symbol_search_name): New.
3002 (lookup_language_this): Pass down
3003 symbol_name_match_type::SEARCH_NAME.
3004 (lookup_symbol_aux, lookup_local_symbol): New parameter
3005 'match_type'. Pass it down.
3006 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
3007 (lookup_symbol_search_name): New declaration.
3008 (lookup_symbol_in_block): New 'match_type' parameter.
3009
f98fc17b
PA
30102018-01-05 Pedro Alves <palves@redhat.com>
3011
3012 PR gdb/22670
3013 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
3014 ada_lookup_symbol.
3015 (ada_lookup_symbol): Reimplement in terms of
3016 ada_lookup_symbol_list, bits factored out from
3017 ada_lookup_encoded_symbol.
3018
342f8240
JB
30192018-01-05 Joel Brobecker <brobecker@adacore.com>
3020
3021 * ada-exp.y (write_object_renaming): When subscripting an array
3022 using a symbol as the index, pass the block in call to
3023 ada_lookup_encoded_symbol when looking that symbol up.
3024
7150d33c
JG
30252018-01-05 Jerome Guitton <guitton@adacore.com>
3026
3027 * ada-lang.c (ada_array_length): Use ada_index_type instead of
3028 TYPE_INDEX_TYPE.
3029
cc0e770c
JB
30302018-01-05 Joel Brobecker <brobecker@adacore.com>
3031
3032 * ada-lang.c (ada_to_fixed_value_create): Add handling of
3033 the case where VALUE_LVAL (val0) is not lval_memory.
3034
f79da888 30352018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
3036
3037 * ada-valprint.c (print_optional_low_bound): Handle
3038 character-indexed array printing like boolean-indexed array
3039 printing.
3040
cd385f94
JB
30412018-01-05 Joel Brobecker <brobecker@adacore.com>
3042
3043 * NEWS: Create a new section for the next release branch.
3044 Rename the section of the current branch, now that it has
3045 been cut.
3046
09aca949
JB
30472018-01-05 Joel Brobecker <brobecker@adacore.com>
3048
3049 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
3050 * version.in: Bump version to 8.1.50.DATE-git.
3051
9f757bf7
XR
30522018-01-03 Xavier Roirand <roirand@adacore.com>
3053
3054 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
3055 Add field.
3056 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
3057 Add field.
3058 (default_exception_support_info) <catch_handlers_sym>: Add field.
3059 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
3060 (ada_exception_name_addr_1): Add "catch handlers" handling.
3061 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
3062 Update all callers.
3063 (create_excep_cond_exprs) <ex>: Add parameter.
3064 (re_set_exception): Update create_excep_cond_exprs call.
3065 (print_it_exception, print_one_exception, print_mention_exception)
3066 (print_recreate_exception): Add "catch handler" handling.
3067 (allocate_location_catch_handlers, re_set_catch_handlers)
3068 (check_status_catch_handlers, print_it_catch_handlers)
3069 (print_one_catch_handlers, print_mention_catch_handlers)
3070 (print_recreate_catch_handlers): New function.
3071 (catch_handlers_breakpoint_ops): New variable.
3072 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
3073 Add parameter. Add "catch handler" handling.
3074 (ada_exception_sym_name, ada_exception_breakpoint_ops):
3075 Add "catch handler" handling.
3076 (ada_exception_catchpoint_cond_string): Add "catch handler"
3077 handling.
3078 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
3079 call.
3080 (catch_ada_handlers_command): New function.
3081 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
3082 operations structure.
3083 (_initialize_ada_language): Add "catch handlers" command entry.
3084 * NEWS: Document "catch handlers" feature.
3085
9fe561ab
JB
30862018-01-02 Joel Brobecker <brobecker@adacore.com>
3087
3088 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
3089 account when creating the array type of the slice.
3090 (ada_value_slice): Likewise.
3091
a405673c
JB
30922018-01-02 Joel Brobecker <brobecker@adacore.com>
3093
3094 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
3095 New enum value.
3096 (create_array_type_with_stride): Add byte_stride_prop parameter.
3097 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
3098 New parameter. Update all callers in this file.
3099 (array_type_has_dynamic_stride): New function.
3100 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
3101 of arrays with dynamic byte strides.
3102 * dwarf2read.c (read_array_type): Add support for dynamic
3103 DW_AT_byte_stride attributes.
3104
74a2f8ff
JB
31052018-01-02 Joel Brobecker <brobecker@adacore.com>
3106
3107 * dwarf2read.c (read_unspecified_type): Treat
3108 DW_TAG_enumeration_type DIEs from Ada units as stubs.
3109
e2882c85
JB
31102018-01-01 Joel Brobecker <brobecker@adacore.com>
3111
3112 Update copyright year range in all GDB files.
3113
1690bb24
JB
31142018-01-01 Joel Brobecker <brobecker@adacore.com>
3115
3116 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
3117 and gdb/testsuite/gdb.base/step-line.c.
3118
0f0c98a8
JB
31192018-01-01 Joel Brobecker <brobecker@adacore.com>
3120
3121 * copyright.py (main): Dump the contents of
3122 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
3123 even if BY_HAND is empty.
3124
82e1e79a
JB
31252018-01-01 Joel Brobecker <brobecker@adacore.com>
3126
3127 * top.c (print_gdb_version): Update Copyright year in version
3128 message.
3129
053f54e5 31302018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 3131
053f54e5 3132 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 3133
053f54e5 3134For older changes see ChangeLog-2017.
c906108c
SS
3135\f
3136Local Variables:
3137mode: change-log
3138left-margin: 8
3139fill-column: 74
3140version-control: never
57da7796 3141coding: utf-8
c906108c 3142End:
This page took 2.25712 seconds and 4 git commands to generate.