gdb/ChangeLog:
[binutils-gdb.git] / gdb / ChangeLog
1 2018-10-17 Paul Koning <paul_koning@dell.com>
2
3 * charset.c (convert_between_encodings): Fix unsigned overflow.
4
5 2018-10-17 John Baldwin <jhb@FreeBSD.org>
6
7 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
8 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
9 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
10 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
11 New functions.
12 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
13 and fbsd_info_proc_mappings_header.
14 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
15 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
16 New.
17
18 2018-10-17 Joel Brobecker <brobecker@adacore.com>
19
20 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
21 Solaris Maintainer.
22
23 2018-10-15 Tom Tromey <tom@tromey.com>
24
25 * tui/tui.c (strcat_to_buf): Remove casts.
26 * tui/tui-winsource.c (tui_show_source_line)
27 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
28 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
29 * tui/tui-windata.c (tui_first_data_item_displayed)
30 (tui_delete_data_content_windows, tui_erase_data_content)
31 (tui_display_all_data, tui_display_data_from)
32 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
33 * tui/tui-win.c (tui_set_win_height)
34 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
35 casts.
36 * tui/tui-win.c (tui_resize_all): Remove casts.
37 (tui_scroll_backward_command, tui_set_focus)
38 (tui_set_tab_width_command): Likewise.
39 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
40 * tui/tui-regs.c (tui_show_register_group): Remove cast.
41 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
42 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
43 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
44 Remove casts.
45
46 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
47
48 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
49 AArch64/ARM maintainer.
50
51 2018-10-11 Gary Benson <gbenson@redhat.com>
52
53 * interps.h (interp::m_name): Make private and mutable.
54 * interps.c (interp::~interp): Free m_name.
55
56 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
57 Simon Marchi <simark@simark.ca>
58
59 * README (`configure' options): Add documentation for new
60 "--enable-unit-tests" option.
61 * acinclude.m4: Include "selftest.m4".
62 * configure: Regenerate.
63 * configure.ac: Use "GDB_AC_SELFTEST".
64 * maint.c (maintenance_selftest): Update message informing
65 that selftests have been disabled.
66 (maintenance_info_selftests): Likewise.
67 * selftest.m4: New file.
68
69 2018-10-10 Gary Benson <gbenson@redhat.com>
70
71 * remote.c (remote_target::remote_send_printf): Add
72 missing va_end found by Coverity.
73
74 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
75
76 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
77
78 2018-10-09 Tom Tromey <tom@tromey.com>
79
80 * configure: Rebuild.
81 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
82 * NEWS: Update --enable-ubsan documentation.
83
84 2018-10-09 Gary Benson <gbenson@redhat.com>
85
86 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
87 found by Coverity.
88
89 2018-10-08 Tom Tromey <tom@tromey.com>
90
91 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
92 variable.
93 (riscv_fbsd_init_abi): Likewise.
94
95 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
96 * valops.c (value_struct_elt_for_reference): Rename local variable
97 to work around the shadowing a previous local warning.
98
99 2018-10-08 John Baldwin <jhb@FreeBSD.org>
100
101 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
102 * NEWS: Mention new FreeBSD/riscv native configuration.
103 * configure.host: Add riscv*-*-freebsd*.
104 * configure.nat: Likewise.
105 * riscv-fbsd-nat.c: New file.
106
107 2018-10-08 John Baldwin <jhb@FreeBSD.org>
108
109 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
110 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
111 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
112 * NEWS: Mention new FreeBSD/riscv target.
113 * configure.tgt: Add riscv*-*-freebsd*.
114 * riscv-fbsd-tdep.c: New file.
115 * riscv-fbsd-tdep.h: New file.
116
117 2018-10-08 John Baldwin <jhb@FreeBSD.org>
118
119 * regcache.h (struct regcache_map_entry): Note that this type can
120 be used with traditional frame caches.
121 * trad-frame.c (trad_frame_set_reg_regmap): New.
122 * trad-frame.h (trad_frame_set_reg_regmap): New.
123
124 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
125
126 PR c++/16841
127 * valops.c (get_virtual_base_offset): New function.
128 (value_struct_elt_for_reference): Use it to get virtual base offset
129 and add it in calculating class member address.
130
131 2018-10-08 John Darrington <john@darrington.wattle.id.au>
132
133 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
134 (check_producer): Check if the producer is codewarrior.
135 (producer_is_codewarrior): New function.
136 (lnp_state_machine::record_line): Ignore is_stmt flag for records
137 produced by codewarrior.
138 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
139
140 2018-10-06 Tom Tromey <tom@tromey.com>
141
142 PR python/19399:
143 * python/py-inferior.c: Add "architecture" entry.
144 (infpy_architecture): New function.
145
146 2018-10-06 Tom Tromey <tom@tromey.com>
147
148 PR python/21765:
149 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
150 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
151 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
152 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
153
154 2018-10-06 Tom Tromey <tom@tromey.com>
155
156 PR build/17077:
157 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
158 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
159 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
160 #include.
161
162 2018-10-06 Tom Tromey <tom@tromey.com>
163
164 * python/py-breakpoint.c (bppy_get_location): Handle a
165 bp_breakpoint without a location.
166
167 2018-10-06 Tom Tromey <tom@tromey.com>
168
169 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
170 (_RegEx): Reformat help text.
171 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
172 (AnyCallerIs, AnyCallerMatches): Reformat help text.
173 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
174 text.
175 * python/lib/gdb/command/xmethods.py (InfoXMethod)
176 (EnableXMethod, DisableXMethod): Remove help indentation.
177 Capitalize meta-syntactic variables.
178 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
179 (EnableUnwinder, DisableUnwinder): Remove help indentation.
180 Capitalize meta-syntactic variables.
181 * python/lib/gdb/command/explore.py (ExploreCommand)
182 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
183 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
184 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
185 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
186 Remove help indentation.
187 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
188 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
189 (DisableFrameFilter, SetFrameFilterPriority)
190 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
191
192 2018-10-06 Tom Tromey <tom@tromey.com>
193
194 PR tui/28819:
195 * tui/tui-io.c (gdb_wgetch): New function.
196 (tui_mld_getc, tui_getc): Use it.
197
198 2018-10-05 Tom Tromey <tom@tromey.com>
199
200 * sol-thread.c (sol_thread_target::wait): Rename inner
201 "save_ptid".
202
203 2018-10-04 Tom Tromey <tom@tromey.com>
204
205 * configure: Rebuild.
206 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
207
208 2018-10-04 Tom Tromey <tom@tromey.com>
209
210 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
211 declaration of "block".
212
213 2018-10-04 Tom Tromey <tom@tromey.com>
214
215 * common/filestuff.c (fdwalk): Remove inner declaration of
216 "result".
217
218 2018-10-04 Tom Tromey <tom@tromey.com>
219
220 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
221 "structs_addr" and hoist declaration.
222
223 2018-10-04 Tom Tromey <tom@tromey.com>
224
225 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
226 variable "size".
227
228 2018-10-04 Tom Tromey <tom@tromey.com>
229
230 * mdebugread.c (parse_partial_symbols): Use std::string.
231
232 2018-10-04 Tom Tromey <tom@tromey.com>
233
234 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
235 * p-valprint.c (pascal_val_print): Split inner "i" variable.
236 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
237 header.
238 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
239 more inner scope.
240 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
241 * varobj.c (varobj_update): Rename inner "newobj",
242 "type_changed".
243 * valprint.c (generic_emit_char): Rename inner "buf".
244 * valops.c (find_overload_match): Rename inner "temp".
245 (value_struct_elt_for_reference): Declare "v" in more inner
246 scope.
247 * v850-tdep.c (v850_push_dummy_call): Rename "len".
248 * unittests/array-view-selftests.c (run_tests): Rename inner
249 "vec".
250 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
251 header.
252 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
253 "tsv" in more inner scope.
254 (print_one_static_tracepoint_marker): Rename inner
255 "tuple_emitter".
256 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
257 (tic6x_push_dummy_call): Don't redeclare "addr".
258 * target-float.c: Declare "dto" lower.
259 * symtab.c (lookup_local_symbol): Rename inner "sym".
260 (find_pc_sect_line): Rename inner "pc".
261 * stack.c (print_frame): Don't redeclare "gdbarch".
262 (return_command): Rename inner "gdbarch".
263 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
264 "sp".
265 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
266 header.
267 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
268 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
269 scope.
270 * remote.c (remote_target::update_thread_list): Don't redeclare
271 "tp".
272 (remote_target::process_initial_stop_replies): Rename inner
273 "thread".
274 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
275 (remote_target::wait_as): Don't redeclare "stop_reply".
276 (remote_target::get_thread_local_address): Rename inner
277 "result".
278 (remote_target::get_tib_address): Likewise.
279
280 * regcache.c (cooked_read_test): Rename "regnum".
281 * record-btrace.c (cmd_record_btrace_start): Rename inner
282 "exception".
283 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
284 loop header.
285 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
286 header.
287 (ppu2spu_sniffer): Rename inner "buf".
288 * parse.c (operator_check_standard): Rename inner "type",
289 "objfile".
290 * p-valprint.c (pascal_val_print): Introduce new scope for
291 "low_bound", "high_bound".
292 * p-exp.y (yylex): Declare "i" in loop header.
293 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
294 Lower declaration of "s".
295 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
296 header.
297 (nios2_push_dummy_call): Rename "len".
298 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
299 "buf".
300 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
301 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
302 (linux_xfer_osdata_modules): Likewise.
303 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
304 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
305 (mips_o64_push_dummy_call): Likewise.
306 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
307 "op".
308 * mi/mi-main.c (list_available_thread_groups): Rename inner
309 "tuple_emitter".
310 (mi_cmd_data_read_memory): Rename inner "opts".
311 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
312 "tuple_emitter".
313 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
314 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
315 more inner scope.
316 (parse_partial_symbols): Rename inner "pst", "p", "name"
317 * main.c (captured_main_1): Rename inner "i"s.
318 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
319 "oso2".
320 * linux-tdep.c (linux_info_proc): Rename inner "filename".
321 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
322 * infrun.c (handle_no_resumed): Don't redeclare "thread".
323 (handle_signal_stop): Rename inner "gdbarch".
324 (handle_command): Declare "signum" in loop header.
325 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
326 "status".
327 (examine_prologue): Rename inner "sol" and "sof".
328 (ia64_extract_return_value): Rename inner "val". Declare another
329 "val" in a more inner scope.
330 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
331 inner scope.
332 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
333 "except".
334 * findvar.c (default_read_var_value): Don't redeclare "addr".
335 * f-exp.y (yylex): Declare "i" in loop header.
336 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
337 Rename inner "type", "expect_type".
338 (evaluate_subexp_for_sizeof): Rename inner "pc".
339 * elfread.c (elf_symfile_read): Rename inner "abfd".
340 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
341 "bytes_read".
342 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
343 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
344 (dwarf_decode_line_header): Rename inner "lh".
345 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
346 "offset". Declare "i" in loop header.
347 (disassemble_dwarf_expression): Rename inner "addr_size".
348 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
349 inner "result".
350 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
351 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
352 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
353 "inner_list_emitter".
354 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
355 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
356 declaration in a block.
357 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
358 * cp-valprint.c (cp_print_value_fields): Don't redeclare
359 "obstack_final_size".
360 * cp-support.c (inspect_type): Declare "i" in loop header.
361 * compile/compile.c (compile_instance::insert_symbol_error):
362 Rename inner "e".
363 * common/agent.c (agent_run_command): Remove inner "ret"
364 declaration.
365 * coffread.c (coff_symfile_read): Rename inner "name".
366 (coff_symfile_read): Rename inner "abfd".
367 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
368 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
369 "high".
370 * c-exp.y (lex_one_token): Move "len" declaration lower.
371 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
372 "gdbarch".
373 (create_exception_master_breakpoint): Likewise. Don't redeclare
374 "b".
375 (watch_command_1): Declare "mark" later.
376 (clear_command): Don't shadow "a" or "b".
377 (delete_command): Rename inner "b".
378 (delete_trace_command): Likewise.
379 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
380 "op".
381 (arm_gdbarch_init): Remove inner "e_flags".
382 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
383 "offset" in inner blocks.
384
385 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
386
387 * dwarf-index-write.c (file_write): Don't write if the vector is
388 empty.
389
390 2018-10-05 Tom de Vries <tdevries@suse.de>
391
392 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
393 PyArg_ParseTuple call.
394
395 2018-10-05 Tom de Vries <tdevries@suse.de>
396
397 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
398 PyArg_ParseTuple call.
399
400 2018-10-04 Joel Brobecker <brobecker@adacore.com>
401
402 * psymtab.c (recursively_search_psymtabs): Reformat parameters
403 to avoid exceeding 80 characters per line limit.
404
405 2018-10-04 Tom Tromey <tom@tromey.com>
406
407 * symfile.c (syms_from_objfile_1, finish_new_objfile)
408 (reread_symbols): Update.
409 * complaints.h (clear_complaints): Remove argument.
410 * complaints.c (enum complaint_series): Remove.
411 (series): Remove global.
412 (complaint_internal): Update.
413 (clear_complaints): Remove argument.
414
415 2018-10-04 Tom Tromey <tom@tromey.com>
416
417 * symfile.c (symbol_file_add_with_addrs): Do not print "no
418 debugging symbols" message if there is a separate debug objfile.
419
420 2018-10-04 Tom Tromey <tom@tromey.com>
421
422 PR cli/19551:
423 * symfile.c (symbol_file_add_with_addrs): Update output.
424 * psymtab.c (require_partial_symbols): Update output.
425
426 2018-10-04 Tom Tromey <tom@tromey.com>
427
428 PR cli/22234:
429 * complaints.c: Emit \n.
430
431 2018-10-04 Tom Tromey <tom@tromey.com>
432
433 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
434 (separate_debug_file_exists, find_separate_debug_file)
435 (add_symbol_file_command, reread_symbols, allocate_symtab)
436 (allocate_compunit_symtab): Use filtered printing, not
437 unfiltered.
438 * psymtab.c (require_partial_symbols, dump_psymtab)
439 (allocate_psymtab): Use filtered printing, not unfiltered.
440
441 2018-10-04 Tom Tromey <tom@tromey.com>
442
443 * complaints.c (complaint_internal): Correctly check complaint
444 count.
445
446 2018-10-04 Tom Tromey <tom@tromey.com>
447
448 * complaints.h (struct complaints): Remove declaration.
449 * complaints.c (clear_complaints): Remove an unused variable.
450
451 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
452
453 * MAINTAINERS (Write After Approval): Add self.
454
455 2018-10-03 Tom Tromey <tom@tromey.com>
456
457 * guile/scm-value.c (gdbscm_value_to_string): Initialize
458 "buffer_contents".
459 * coffread.c (coff_symtab_read): Initialize "newobj".
460
461 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
462
463 * dwarf2read.c (read_func_scope): Remove struct keyword in
464 range-based for.
465
466 2018-10-03 Tom Tromey <tom@tromey.com>
467
468 * README: Mention --enable-ubsan.
469 * NEWS: Mention --enable-ubsan.
470 * acinclude.m4: Include sanitize.m4.
471 * configure: Rebuild.
472 * configure.ac: Call AM_GDB_UBSAN.
473 * sanitize.m4: New file.
474
475 2018-10-03 Tom Tromey <tom@tromey.com>
476
477 * expression.h (enum exp_opcode): Use uint8_t as base type.
478 * expprint.c (op_name): Handle invalid opcodes.
479
480 2018-10-03 Tom Tromey <tom@tromey.com>
481
482 * parse.c (prefixify_expression): Add assert.
483 (parse_exp_in_context_1): Throw exception if the expression is
484 empty.
485
486 2018-10-03 Tom Tromey <tom@tromey.com>
487
488 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
489
490 2018-10-03 Tom Tromey <tom@tromey.com>
491
492 * c-exp.y (parse_number): Work in unsigned. Remove casts.
493
494 2018-10-03 Tom Tromey <tom@tromey.com>
495
496 * dwarf2read.c (read_subrange_type): Make "negative_mask"
497 unsigned.
498
499 2018-10-03 Tom Tromey <tom@tromey.com>
500
501 * findvar.c (extract_integer): Do work in an unsigned type.
502
503 2018-10-03 Tom Tromey <tom@tromey.com>
504
505 * common/enum-flags.h (enum_flags::operator~): Add static assert.
506 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
507 base type.
508 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
509 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
510 type.
511 * c-lang.h (enum c_string_type_values): Use unsigned as base
512 type.
513 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
514
515 2018-10-03 Tom Tromey <tom@tromey.com>
516
517 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
518 <~dwarf2_frame_state_reg_info>: Update.
519 <dwarf2_frame_state_reg_info>: Update.
520 <alloc_regs>: Add assertion. Update.
521 <reg>: Now a std::vector.
522 <num_regs>: Remove.
523 <swap>: Update.
524 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
525 (execute_cfa_program_test, dwarf2_frame_cache): Update.
526
527 2018-10-03 Tom Tromey <tom@tromey.com>
528
529 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
530
531 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
532
533 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
534
535 2018-10-02 Tom Tromey <tom@tromey.com>
536
537 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
538
539 2018-10-02 John Darrington <john@darrington.wattle.id.au>
540
541 * NEWS: Mention changed commands.
542 * ser-uds.c: New file.
543 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
544 * configure: Regenerate.
545 * Makefile.in: Add new file.
546 * serial.c (serial_open): Check if filename is a socket
547 and lookup the appropriate interface accordingly.
548
549 2018-10-01 Alan Hayward <alan.hayward@arm.com>
550
551 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
552 define.
553 (AARCH64_EXTRA_MAGIC): Likewise.
554 (AARCH64_FPSIMD_MAGIC): Likewise.
555 (AARCH64_SVE_MAGIC): Likewise.
556 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
557 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
558 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
559 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
560 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
561 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
562 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
563 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
564 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
565 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
566 (read_aarch64_ctx): Add function.
567 (aarch64_linux_sigframe_init): Detect FP registers.
568
569 2018-10-01 Alan Hayward <alan.hayward@arm.com>
570
571 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
572 (AARCH64_D0_REGNUM): Likewise.
573 (AARCH64_S0_REGNUM): Likewise.
574 (AARCH64_H0_REGNUM): Likewise.
575 (AARCH64_B0_REGNUM): Likewise.
576 (AARCH64_SVE_V0_REGNUM): Likewise.
577 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
578 (AARCH64_D0_REGNUM): Likewise.
579 (AARCH64_S0_REGNUM): Likewise.
580 (AARCH64_H0_REGNUM): Likewise.
581 (AARCH64_B0_REGNUM): Likewise.
582 (AARCH64_SVE_V0_REGNUM): Likewise.
583
584 2018-10-01 Gary Benson <gbenson@redhat.com>
585
586 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
587 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
588 prfpregset_t instead of gdb_prfpregset_t.
589 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
590 * configure, config.in: Rebuild.
591
592 2018-10-01 Gary Benson <gbenson@redhat.com>
593
594 * common/gdb_proc_service.h: New file, factored out from...
595 * gdb_proc_service.h: Moved common code to the above file.
596 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
597
598 2018-10-01 Gary Benson <gbenson@redhat.com>
599
600 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
601 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
602
603 2018-10-01 Gary Benson <gbenson@redhat.com>
604
605 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
606 (AC_CHECK_HEADERS): Check for linux/elf.h.
607 * configure, config.in: Rebuild.
608 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
609 doesn't define elf_fpregset_t.
610
611 2018-10-01 Gary Benson <gbenson@redhat.com>
612
613 * gdb_proc_service.h: Whitespace change.
614
615 2018-10-01 Tom Tromey <tom@tromey.com>
616
617 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
618 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
619 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
620
621 2018-10-01 Tom Tromey <tom@tromey.com>
622
623 * README: Minor change.
624
625 2018-09-30 Pedro Alves <palves@redhat.com>
626
627 * darwin-nat-info.c (darwin_debug_regions_recurse)
628 (info_mach_exceptions_command): Remove unused local variables.
629 * darwin-nat.c (darwin_decode_notify_message)
630 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
631 (darwin_stop_inferior, darwin_setup_exceptions)
632 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
633 (darwin_nat_target::attach, darwin_nat_target::detach)
634 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
635 local variables.
636 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
637 variables.
638
639 2018-09-29 Tom Tromey <tom@tromey.com>
640
641 * README: Remove some leftover text.
642
643 2018-09-29 Tom Tromey <tom@tromey.com>
644
645 * PROBLEMS: Rewrite.
646 * README: Update.
647
648 2018-09-28 John Baldwin <jhb@FreeBSD.org>
649
650 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
651 case with explicit breakpoint kind.
652 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
653 'additional_info' and related logic.
654 (riscv_debug_breakpoints): New variable.
655 (riscv_breakpoint_kind_from_pc): Use the length of the existing
656 instruction to determine the breakpoint kind.
657 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
658 flag. Update description of 'set/show riscv
659 use-compressed-breakpoints' flag.
660
661 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
662
663 (NEWS): Mention changes to frame related commands.
664 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
665 (add_prefix_cmd_suppress_notification): New function.
666 (add_com_suppress_notification): Call
667 add_cmd_suppress_notification.
668 * command.h (add_cmd_suppress_notification): Declare.
669 (add_prefix_cmd_suppress_notification): Declare.
670 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
671 (parse_frame_specification): Moved from stack.c, with
672 simplification to handle a single argument.
673 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
674 switch to the selected frame. Add a header comment.
675 * stack.c: Remove 'safe-ctype.h' include.
676 (find_frame_for_function): Add declaration.
677 (find_frame_for_address): New function.
678 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
679 (frame_selection_by_function_completer): New function.
680 (info_frame_command): Rename to...
681 (info_frame_command_core): ...this, and update parameter types.
682 (select_frame_command): Rename to...
683 (select_frame_command_core): ...this, and update parameter types.
684 (frame_command): Rename to...
685 (frame_command_core): ...this, and update parameter types.
686 (class frame_command_helper): New class to wrap implementations of
687 frame related sub-commands.
688 (frame_apply_cmd_list): New static global.
689 (frame_cmd_list): Make static.
690 (select_frame_cmd_list): New global for sub-commands.
691 (info_frame_cmd_list): New global for sub-commands.
692 (_initialize_stack): Register sub-commands for 'frame',
693 'select-frame', and 'info frame'. Update 'frame apply' commands
694 to use frame_apply_cmd_list. Move function local static
695 frame_apply_list to file static frame_apply_cmd_list for
696 consistency.
697 * stack.h (select_frame_command): Delete declarationn.
698 (select_frame_for_mi): Declare new function.
699
700 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
701
702 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
703 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
704 and NOP.
705
706 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
707
708 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
709
710 2018-09-26 Tom Tromey <tom@tromey.com>
711
712 * valops.c (auto_abandon): Remove dead code.
713
714 2018-09-26 Tom Tromey <tom@tromey.com>
715
716 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
717
718 2018-09-24 Tom Tromey <tom@tromey.com>
719
720 * common/pathstuff.c (get_standard_cache_dir): Make
721 "xdg_cache_home" and "home" const.
722 * top.c (init_history): Make "tmpenv" const.
723 * main.c (get_init_files): Make "homedir" const.
724
725 2018-09-23 Tom Tromey <tom@tromey.com>
726
727 PR python/18852:
728 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
729
730 2018-09-23 Tom Tromey <tom@tromey.com>
731
732 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
733 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
734 * python/python-internal.h (gdbpy_handle_exception): Declare.
735 * python/py-utils.c (gdbpy_handle_exception): New function.
736
737 2018-09-23 Tom Tromey <tom@tromey.com>
738
739 PR python/17284:
740 * python/py-type.c (typy_template_argument): Check for negative
741 argument number.
742
743 2018-09-23 Tom Tromey <tom@tromey.com>
744
745 PR python/14062:
746 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
747
748 2018-09-23 Tom Tromey <tom@tromey.com>
749
750 PR python/18170:
751 * python/py-value.c (valpy_int): Allow conversion from pointer
752 type.
753
754 2018-09-23 Tom Tromey <tom@tromey.com>
755
756 PR python/20126:
757 * python/py-value.c (valpy_int): Respect type sign.
758
759 2018-09-23 Tom Tromey <tom@tromey.com>
760
761 PR python/18352;
762 * python/py-value.c (valpy_float): Allow conversions from int or
763 char.
764 (valpy_int, valpy_long): Allow conversions from float.
765
766 2018-09-23 Tom Tromey <tom@tromey.com>
767
768 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
769 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
770
771 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
772
773 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
774 __sighndlr.
775 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
776
777 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
778
779 * windows-nat.c (windows_nat_target::wait): Remove a spurious
780 target_terminal::ours().
781
782 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
783
784 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
785 of vl to ULONGEST.
786
787 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
788
789 * breakpoint.c (update_inserted_breakpoint_locations): Remove
790 redundant condition.
791
792 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
793
794 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
795
796 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
797 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
798 * sol-thread.c (ps_pdmodel): Don't guard definition.
799
800 * procfs.c: Fix formatting.
801
802 * procfs.c (sysset_t_alloc): Remove.
803 (create_procinfo): Use XNEW instead of sysset_t_alloc.
804 (procfs_debug_inferior): Likewise.
805 (procfs_set_exec_trap): Likewise.
806 (proc_set_traced_sysentry): Don't allocate argp dynamically.
807 (proc_set_traced_sysexit): Likewise.
808
809 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
810 (dead_procinfo): Likewise.
811 (proc_warn): Likewise.
812 (proc_error): Likewise.
813 (proc_get_LDT_entry): Likewise.
814 (do_attach): Likewise.
815 (procfs_target::pid_to_str): Likewise.
816 (iterate_over_mappings): Likewise.
817
818 * procfs.c (create_procinfo): Fix ARI warning.
819 (proc_get_status): Likewise.
820 (proc_stop_process): Likewise.
821 (proc_run_process): Likewise.
822 (proc_kill): Likewise.
823 (proc_get_LDT_entry): Likewise.
824 (procfs_find_LDT_entry): Likewise.
825 (proc_update_threads): Likewise.
826 (proc_iterate_over_threads): Likewise.
827 (do_attach): Likewise.
828 (procfs_xfer_memory): Likewise.
829 (invalidate_cache): Likewise.
830 (procfs_target::resume): Likewise.
831 (procfs_init_inferior): Likewise.
832 (procfs_set_exec_trap): Likewise.
833 (procfs_target::thread_alive): Likewise.
834 (procfs_target::pid_to_exec_file): Likewise.
835 (iterate_over_mappings): Likewise.
836 (procfs_target::make_corefile_notes): Likewise.
837 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
838
839 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
840 (procfs_find_LDT_entry): Likewise.
841 * sol-thread.c (ps_lgetLDT): Likewise.
842
843 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
844
845 PR tdep/17903
846 * procfs.c (procfs_target): Declare pid_to_exec_file.
847 (procfs_target::pid_to_exec_file): New.
848
849 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
850
851 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
852 renaming.
853 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
854 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
855
856 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
857
858 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
859 (supply_fpregset, fill_fpregset): Move ...
860 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
861 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
862 Remove references to ioctl-based procfs.
863 Include <sys/reg.h>.
864 Remove PR_MODEL_NATIVE guards.
865 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
866 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
867
868 2018-09-19 Xavier Roirand <roirand@adacore.com>
869
870 PR gdb/20981:
871 * solib-darwin.c (darwin_get_dyld_bfd): New function.
872 (darwin_solib_get_all_image_info_addr_at_init): Update call.
873 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
874
875 2018-09-19 John Baldwin <jhb@FreeBSD.org>
876
877 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
878 (fbsd_print_sockaddr_in6): Likewise.
879
880 2018-09-19 Richard Bunt <richard.bunt@arm.com>
881 Chris January <chris.january@arm.com>
882
883 * eval.c (skip_undetermined_arglist): Skip argument list helper.
884 (evaluate_subexp_standard): Return a dummy type when
885 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
886 OP_F77_UNDETERMINED_ARGLIST case.
887 * expression.h (enum noside): Update comment.
888
889 2018-09-19 George Vasick <george.vasick@oracle.com>
890
891 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
892
893 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
894 April Chin <april.chin@oracle.com>
895 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
896
897 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
898 uint_t lwpid_t.
899 (create_procinfo): Print pids in /proc without leading zeros.
900
901 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
902
903 * nios2-tdep.c (nios2_gcc_target_options): New.
904 (nios2_gdb_arch_init): Install new hook.
905
906 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
907
908 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
909 New file.
910 * update-gnulib.sh: Apply patch.
911 * configure: Re-generate.
912
913 2018-09-18 John Baldwin <jhb@FreeBSD.org>
914
915 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
916 description. Make "info proc" command descriptions more
917 consistent.
918
919 2018-09-18 John Baldwin <jhb@FreeBSD.org>
920
921 * NEWS: Mention 'info proc files' command.
922
923 2018-09-18 John Baldwin <jhb@FreeBSD.org>
924
925 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
926 descriptors for IP_FILES and IP_ALL.
927
928 2018-09-18 John Baldwin <jhb@FreeBSD.org>
929
930 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
931 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
932 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
933 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
934 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
935 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
936 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
937 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
938 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
939 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
940 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
941 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
942 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
943 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
944 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
945 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
946 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
947 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
948 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
949 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
950 (struct fbsd_sockaddr_un): New types.
951 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
952 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
953 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
954 (fbsd_core_info_proc_files): New functions.
955 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
956 IP_ALL.
957 * fbsd-tdep.h (fbsd_info_proc_files_header)
958 (fbsd_info_proc_files_entry): New.
959
960 2018-09-18 John Baldwin <jhb@FreeBSD.org>
961
962 * defs.h (enum info_proc_what) [IP_FILES]: New value.
963 * infcmd.c (info_proc_cmd_files): New function.
964 (_initialize_infcmd): Register 'info proc files' command.
965
966 2018-09-18 John Baldwin <jhb@FreeBSD.org>
967
968 * gnulib/aclocal-m4-deps.mk: Re-generate.
969 * gnulib/aclocal.m4: Re-generate.
970 * gnulib/config.in: Re-generate.
971 * gnulib/configure: Re-generate.
972 * gnulib/import/Makefile.am: Re-generate.
973 * gnulib/import/Makefile.in: Re-generate.
974 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
975 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
976 * gnulib/import/arpa_inet.in.h: New file.
977 * gnulib/import/inet_ntop.c: New file.
978 * gnulib/import/m4/arpa_inet_h.m4: New file.
979 * gnulib/import/m4/inet_ntop.m4: New file.
980 * gnulib/import/m4/netinet_in_h.m4: New file.
981 * gnulib/import/m4/socklen.m4: New file.
982 * gnulib/import/m4/sockpfaf.m4: New file.
983 * gnulib/import/m4/stdalign.m4: New file.
984 * gnulib/import/m4/sys_uio_h.m4: New file.
985 * gnulib/import/netinet_in.in.h: New file.
986 * gnulib/import/stdalign.in.h: New file.
987 * gnulib/import/sys_socket.c: New file.
988 * gnulib/import/sys_socket.in.h: New file.
989 * gnulib/import/sys_uio.in.h: New file.
990 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
991 module.
992
993 2018-09-18 John Baldwin <jhb@FreeBSD.org>
994
995 * gnulib/aclocal-m4-deps.mk: New file.
996 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
997 deterministically.
998
999 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1000
1001 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
1002 KVE_PATH.
1003
1004 2018-09-18 Tom Tromey <tom@tromey.com>
1005
1006 * compile/compile-object-load.c (struct
1007 link_hash_table_cleanup_data): Add constructor and destructor.
1008 Use DISABLE_COPY_AND_ASSIGN.
1009 (~link_hash_table_cleanup_data): Rename from
1010 link_hash_table_free. Now a destructor.
1011 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
1012
1013 2018-09-18 Tom Tromey <tom@tromey.com>
1014
1015 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1016 * compile/compile-object-load.c (struct munmap_list): Move to
1017 header file.
1018 (munmap_list::add): Rename from munmap_list_add; rewrite.
1019 (munmap_list::~munmap_list): Rename from munmap_list_free.
1020 (munmap_listp_free_cleanup): Remove.
1021 (compile_object_load): Update.
1022 * compile/compile-object-load.h (struct munmap_list): Move from
1023 compile-object-load.c. Rewrite.
1024
1025 2018-09-18 Alan Hayward <alan.hayward@arm.com>
1026
1027 * aarch64-tdep.c (pass_in_v): Use register size.
1028 (aarch64_extract_return_value): Likewise.
1029 (aarch64_store_return_value): Likewise.
1030
1031 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1032
1033 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
1034 rlim_t.
1035
1036 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1037
1038 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
1039 Fix short help line.
1040
1041 2018-09-17 Tom Tromey <tom@tromey.com>
1042
1043 PR python/20445:
1044 * configure: Rebuild.
1045 * configure.ac: Conditionally use -DNDEBUG for Python.
1046
1047 2018-09-17 Tom Tromey <tom@tromey.com>
1048
1049 * configure: Rebuild.
1050 * configure.ac: Use gmp as a library dependency when checking for
1051 mpfr.
1052
1053 2018-09-17 Pedro Alves <palves@redhat.com>
1054
1055 * python/py-inferior.c (find_inferior_object): Delete.
1056
1057 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
1058
1059 * compile/compile-cplus-types.c
1060 (compile_cplus_instance::enter_scope): Don't use new_scope after
1061 std::move.
1062
1063 2018-09-17 Tom Tromey <tom@tromey.com>
1064
1065 * common/pathstuff.c (get_standard_cache_dir): Use
1066 ~/Library/Caches on macOS.
1067 * common/pathstuff.h (get_standard_cache_dir): Update comment.
1068
1069 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
1070
1071 PR python/23669
1072 * breakpoint.c (commands_cmd_element): New.
1073 (_initialize_breakpoint): Assign commands_cmd_element.
1074 * breakpoint.h (commands_cmd_element): New.
1075 * cli/cli-script.c (while_cmd_element, if_command,
1076 define_cmd_element): New.
1077 (command_name_equals): Remove.
1078 (process_next_line): Compare commands by pointer, not by name.
1079 (_initialize_cli_script): Assign the various cmd_list_element
1080 variables.
1081 * compile/compile.c (compile_cmd_element): New.
1082 (_initialize_compile): Assign compile_cmd_element.
1083 * compile/compile.h (compile_cmd_element): New.
1084 * guile/guile.c (guile_cmd_element): New.
1085 (install_gdb_commands): Assign guile_cmd_element.
1086 * guile/guile.h (guile_cmd_element): New.
1087 * python/python.c (python_cmd_element): New.
1088 (_initialize_python): Assign python_cmd_element.
1089 * python/python.h (python_cmd_element): New.
1090 * tracepoint.c (while_stepping_cmd_element): New.
1091 (_initialize_tracepoint): Assign while_stepping_cmd_element.
1092 * tracepoint.h (while_stepping_cmd_element): New.
1093
1094 2018-09-17 Tom Tromey <tom@tromey.com>
1095
1096 * infrun.c (save_infcall_suspend_state): Return
1097 infcall_suspend_state_up.
1098 (save_infcall_control_state): Return infcall_control_state_up.
1099 * inferior.h (save_infcall_suspend_state)
1100 (save_infcall_control_state): Declare later. Return unique
1101 pointers.
1102
1103 2018-09-17 Tom Tromey <tom@tromey.com>
1104
1105 * infrun.c (struct stop_context): Declare constructor,
1106 destructor, "changed" method.
1107 (stop_context::stop_context): Rename from save_stop_context.
1108 (stop_context::~stop_context): Rename from
1109 release_stop_context_cleanup.
1110 (normal_stop): Update.
1111 (stop_context::changed): Rename from stop_context_changed. Return
1112 bool.
1113
1114 2018-09-17 Tom Tromey <tom@tromey.com>
1115
1116 * inferior.h (struct infcall_suspend_state_deleter): New.
1117 (infcall_suspend_state_up): New typedef.
1118 (struct infcall_control_state_deleter): New.
1119 (infcall_control_state_up): New typedef.
1120 (make_cleanup_restore_infcall_suspend_state)
1121 (make_cleanup_restore_infcall_control_state): Don't declare.
1122 * infcall.c (call_function_by_hand_dummy): Update.
1123 * infrun.c (do_restore_infcall_suspend_state_cleanup)
1124 (make_cleanup_restore_infcall_suspend_state): Remove.
1125 (do_restore_infcall_control_state_cleanup)
1126 (make_cleanup_restore_infcall_control_state): Remove.
1127
1128 2018-09-17 Tom Tromey <tom@tromey.com>
1129
1130 * gdbthread.h (struct thread_control_state): Add initializer.
1131 (class thread_info) <control>: Remove initializer.
1132 * inferior.h (struct inferior_control_state): Add initializer.
1133 (class inferior) <control>: Remove initializer.
1134 (exit_inferior_1): Update.
1135 * infrun.c (struct infcall_control_state): Add constructors.
1136 (save_infcall_control_state): Use new.
1137 (restore_infcall_control_state, discard_infcall_control_state):
1138 Use delete.
1139
1140 2018-09-17 Tom Tromey <tom@tromey.com>
1141
1142 * infrun.c (struct infcall_suspend_state) <registers>: Now a
1143 unique_ptr.
1144 <siginfo_data>: Now a unique_xmalloc_ptr.
1145 (save_infcall_suspend_state, restore_infcall_suspend_state)
1146 (discard_infcall_suspend_state)
1147 (get_infcall_suspend_state_regcache): Update.
1148
1149 2018-09-17 Tom Tromey <tom@tromey.com>
1150
1151 * gdbthread.h (struct thread_suspend_state): Add initializers.
1152 (class thread_info) <suspend>: Remove initializer.
1153 * infrun.c (struct infcall_suspend_state): Add initializers.
1154 (save_infcall_suspend_state): Use new.
1155 (discard_infcall_suspend_state): Use delete.
1156
1157 2018-09-16 Tom Tromey <tom@tromey.com>
1158
1159 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
1160 Remove.
1161 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
1162 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
1163 (py_varobj_iter_new): Likewise.
1164 (py_varobj_get_iterator): Use gdbpy_ref.
1165
1166 2018-09-16 Tom Tromey <tom@tromey.com>
1167
1168 * python/py-threadevent.c (py_get_event_thread): Simplify.
1169 * python/py-inferior.c (infpy_thread_from_thread_handle):
1170 Return immediately after calling thread_to_thread_object. Use
1171 Py_RETURN_NONE.
1172 (thread_to_thread_object): Set the exception on a NULL return.
1173
1174 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1175
1176 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
1177
1178 2018-09-16 Tom Tromey <tom@tromey.com>
1179
1180 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
1181 Remove.
1182
1183 2018-09-16 Tom Tromey <tom@tromey.com>
1184
1185 * python/python-internal.h (thread_to_thread_object): Change
1186 return type.
1187 * python/py-inferior.c (thread_to_thread_object): Return a new
1188 reference.
1189 (infpy_thread_from_thread_handle): Update.
1190 * python/py-infthread.c (gdbpy_selected_thread): Update.
1191 * python/py-stopevent.c (create_stop_event_object): Update.
1192 * python/py-threadevent.c (py_get_event_thread): Return a new
1193 reference.
1194 (py_get_event_thread): Update.
1195 * python/py-event.h (py_get_event_thread): Change return type.
1196 * python/py-continueevent.c (create_continue_event_object):
1197 Update.
1198
1199 2018-09-16 Tom Tromey <tom@tromey.com>
1200
1201 * python/py-progspace.c (pspy_get_objfiles): Update.
1202 * python/python-internal.h (objfile_to_objfile_object): Change
1203 return type.
1204 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1205 Update.
1206 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1207 Update.
1208 * python/python.c (gdbpy_get_current_objfile): Update.
1209 (gdbpy_objfiles): Update.
1210 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
1211 Update.
1212 (objfile_to_objfile_object): Return a new reference.
1213 * python/py-symtab.c (stpy_get_objfile): Update.
1214 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
1215 Update.
1216
1217 2018-09-16 Tom Tromey <tom@tromey.com>
1218
1219 * python/py-inferior.c (infpy_get_progspace): Update.
1220 * python/python-internal.h (pspace_to_pspace_object): Change
1221 return type.
1222 * python/py-newobjfileevent.c
1223 (create_clear_objfiles_event_object): Update.
1224 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1225 Update.
1226 * python/python.c (gdbpy_get_current_progspace): Update.
1227 (gdbpy_progspaces): Update.
1228 * python/py-progspace.c (pspace_to_pspace_object): Return a new
1229 reference.
1230 * python/py-objfile.c (objfpy_get_progspace): Update.
1231 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
1232 Update.
1233
1234 2018-09-16 Tom Tromey <tom@tromey.com>
1235
1236 * python/lib/gdb/__init__.py (current_progspace, objfiles)
1237 (solib_name, block_for_pc, find_pc_line): New functions.
1238 (execute_unwinders): Update.
1239 * python/py-block.c (gdbpy_block_for_pc): Remove.
1240 * python/py-inferior.c (infpy_get_progspace): New function.
1241 (inferior_object_getset) <progspace>: Add.
1242 * python/py-progspace.c (pspy_objfiles): Rewrite.
1243 (pspy_solib_name, pspy_block_for_pc)
1244 (pspy_find_pc_line, pspy_is_valid): New functions.
1245 (progspace_object_methods): Add entries for solib_name,
1246 block_for_pc, find_pc_line, is_valid.
1247 * python/python-internal.h (gdbpy_block_for_pc)
1248 (build_objfiles_list): Don't declare.
1249 * python/python.c: Don't include solib.h.
1250 (gdbpy_solib_name, gdbpy_find_pc_line)
1251 (gdbpy_get_current_progspace, build_objfiles_list)
1252 (gdbpy_objfiles): Remove.
1253 (GdbMethods) <current_progspace, objfiles, block_for_pc,
1254 solib_name, find_pc_line>: Remove entries.
1255
1256 2018-09-16 Tom Tromey <tom@tromey.com>
1257
1258 * top.c (new_ui_command): Use GNU style for metasyntactic
1259 variables.
1260 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
1261 variables.
1262 * maint.c (maintenance_translate_address): Remove "<>" around
1263 text.
1264 * interps.c (interpreter_exec_cmd): Use GNU style for
1265 metasyntactic variables.
1266 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
1267 metasyntactic variables.
1268 * tracepoint.c (tfind_range_command): Use GNU style for
1269 metasyntactic variables.
1270 (tfind_outside_command): Likewise.
1271 (_initialize_tracepoint): Likewise.
1272 * remote.c (extended_remote_target::create_inferior): Use GNU
1273 style for metasyntactic variables.
1274 * sparc64-tdep.c (adi_examine_command): Use GNU style for
1275 metasyntactic variables.
1276 (adi_assign_command): Likewise.
1277
1278 2018-09-16 Tom Tromey <tom@tromey.com>
1279
1280 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
1281 metasyntactic variables. Print message if no disassembler options
1282 are available.
1283
1284 2018-09-15 Tom Tromey <tom@tromey.com>
1285
1286 * infcmd.c (get_inferior_args): Return const char *.
1287 * inferior.h (get_inferior_args): Return type now const.
1288 * linux-tdep.c (linux_fill_prpsinfo): Update.
1289 * procfs.c (procfs_target::make_corefile_notes): Update.
1290
1291 2018-09-07 Tom Tromey <tom@tromey.com>
1292
1293 * python/python.c (execute_gdb_command): Call bpstat_do_actions
1294 inside the TRY.
1295
1296 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
1297
1298 * nios2-tdep.c (nios2_type_align): New.
1299 (nios2_gdb_arch_init): Install type_align hook.
1300
1301 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1302
1303 * eval.c (fake_method::fake_method): Call xzalloc directly for a
1304 type that is neither object file owned, nor gdbarch owned.
1305 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
1306 gdbarch is non-NULL.
1307 (alloc_type_instance): Allocate non-objfile owned types on the
1308 gdbarch obstack.
1309 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
1310 using TYPE_ALLOC to ensure memory is allocated on the correct
1311 obstack.
1312 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
1313 obstack, or the gdbarch obstack.
1314 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
1315
1316 2018-09-14 Tom Tromey <tom@tromey.com>
1317
1318 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
1319 block.
1320
1321 2018-09-14 Tom Tromey <tom@tromey.com>
1322
1323 * nat/fork-inferior.c (get_startup_shell): Remove "static".
1324
1325 2018-09-13 Tom Tromey <tom@tromey.com>
1326
1327 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
1328 static.
1329
1330 2018-09-13 Tom Tromey <tom@tromey.com>
1331
1332 * exec.c (try_open_exec_file): Use std::string.
1333
1334 2018-09-13 Tom Tromey <tom@tromey.com>
1335
1336 * utils.h (gdb_bfd_errmsg): Return std::string.
1337 * exec.c (exec_file_attach): Update.
1338 * compile/compile-object-load.c (compile_object_load): Update.
1339 * utils.c (gdb_bfd_errmsg): Return std::string.
1340
1341 2018-09-13 Tom Tromey <tom@tromey.com>
1342
1343 * procfs.c (struct procinfo_deleter): New.
1344 (procinfo_up): New typedef.
1345 (do_destroy_procinfo_cleanup): Remove.
1346 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
1347
1348 2018-09-13 Tom Tromey <tom@tromey.com>
1349
1350 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
1351
1352 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1353 2018-09-13 Tom Tromey <tom@tromey.com>
1354
1355 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
1356 (pspy_get_objfiles): New function.
1357 (progspace_object_methods): New.
1358 (pspace_object_type): Add tp_methods callback.
1359 * python/python-internal.h (build_objfiles_list): New
1360 declaration.
1361 * python/python.c (build_objfiles_list): New function.
1362 (gdbpy_objfiles): Implement using build_objfiles_list.
1363 * NEWS: Mention the Progspace.objfiles method.
1364
1365 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1366
1367 * python/py-inferior.c (infpy_get_progspace): New function.
1368 (inferior_object_getset): Add progspace property.
1369 * NEWS: Mention the new property.
1370
1371 2018-09-13 Tom Tromey <tom@tromey.com>
1372
1373 PR rust/23650:
1374 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
1375
1376 2018-09-13 Tom Tromey <tom@tromey.com>
1377
1378 PR rust/23626:
1379 * rust-lang.c (rust_enum_variant): Now static.
1380 (rust_empty_enum_p): New function.
1381 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
1382 Handle empty enum.
1383
1384 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1385
1386 * python/py-inferior.c (infpy_repr): New.
1387 (inferior_object_type): Register infpy_repr.
1388 * python/py-objfile.c (objfpy_repr): New.
1389 (objfile_object_type): Register objfpy_repr.
1390
1391 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1392
1393 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
1394
1395 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1396
1397 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
1398 typo.
1399
1400 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
1401
1402 * common/common-utils.c: Don't include '<sys/stat.h>'.
1403 (is_regular_file): Move to...
1404 * common/filestuff.c (is_regular_file): ... here.
1405 * common/common-utils.h (is_regular_file): Move to...
1406 * common/filestuff.h (is_regular_file): ... here.
1407
1408 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
1409
1410 * skip.c (debug_skip): New variable.
1411 (skiplist_entry::do_skip_file_p): Add debug output.
1412 (skiplist_entry::do_skip_gfile_p): Likewise.
1413 (skiplist_entry::skip_function_p): Likewise.
1414 (_initialize_step_skip): Create debug command.
1415 * NEWS: Mention set/show debug skip.
1416
1417 2018-09-11 Xavier Roirand <roirand@adacore.com>
1418
1419 * darwin-nat.c (should_disable_startup_with_shell):
1420 New function.
1421 (darwin_nat_target::create_inferior): Add call.
1422
1423 2018-09-11 Xavier Roirand <roirand@adacore.com>
1424
1425 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
1426 inf_port, msg_state>: Initialize.
1427 (struct darwin_thread_info) <signaled, single_step>: Change
1428 type and initialize.
1429 (struct darwin_thread_info) <event>: Initialize.
1430
1431 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1432
1433 PR gdb/23555
1434 PR gdb/23558
1435 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
1436 guesses.
1437
1438 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1439
1440 Revert:
1441 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1442
1443 PR gdb/23555
1444 PR gdb/23558
1445 * gnulib/aclocal.m4: Regenerate.
1446 * gnulib/config.in: Regenerate.
1447 * gnulib/configure: Regenerate.
1448 * gnulib/import/Makefile.am: Update.
1449 * gnulib/import/Makefile.in: Update.
1450 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1451 * gnulib/import/_Noreturn.h: ... this.
1452 * gnulib/import/alloca.in.h: Update.
1453 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1454 * gnulib/import/arg-nonnull.h: ... this.
1455 * gnulib/import/assure.h: Update.
1456 * gnulib/import/at-func.c: Update.
1457 * gnulib/import/basename-lgpl.c: Update.
1458 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1459 * gnulib/import/c++defs.h: ... this.
1460 * gnulib/import/canonicalize-lgpl.c: Update.
1461 * gnulib/import/cdefs.h: Update.
1462 * gnulib/import/chdir-long.c: Update.
1463 * gnulib/import/chdir-long.h: Update.
1464 * gnulib/import/cloexec.c: Update.
1465 * gnulib/import/cloexec.h: Update.
1466 * gnulib/import/close.c: Update.
1467 * gnulib/import/closedir.c: Update.
1468 * gnulib/import/config.charset: Update.
1469 * gnulib/import/dirent-private.h: Update.
1470 * gnulib/import/dirent.in.h: Update.
1471 * gnulib/import/dirfd.c: Update.
1472 * gnulib/import/dirname-lgpl.c: Update.
1473 * gnulib/import/dirname.h: Update.
1474 * gnulib/import/dosname.h: Update.
1475 * gnulib/import/dup-safer-flag.c: Update.
1476 * gnulib/import/dup-safer.c: Update.
1477 * gnulib/import/dup.c: Update.
1478 * gnulib/import/dup2.c: Update.
1479 * gnulib/import/errno.in.h: Update.
1480 * gnulib/import/error.c: Update.
1481 * gnulib/import/error.h: Update.
1482 * gnulib/import/exitfail.c: Update.
1483 * gnulib/import/exitfail.h: Update.
1484 * gnulib/import/extra/update-copyright: Update.
1485 * gnulib/import/fchdir.c: Update.
1486 * gnulib/import/fcntl.c: Update.
1487 * gnulib/import/fcntl.in.h: Update.
1488 * gnulib/import/fd-hook.c: Update.
1489 * gnulib/import/fd-hook.h: Update.
1490 * gnulib/import/fd-safer-flag.c: Update.
1491 * gnulib/import/fd-safer.c: Update.
1492 * gnulib/import/fdopendir.c: Update.
1493 * gnulib/import/filename.h: Update.
1494 * gnulib/import/filenamecat-lgpl.c: Update.
1495 * gnulib/import/filenamecat.h: Update.
1496 * gnulib/import/flexmember.h: Update.
1497 * gnulib/import/float+.h: Update.
1498 * gnulib/import/float.c: Update.
1499 * gnulib/import/float.in.h: Update.
1500 * gnulib/import/fnmatch.c: Update.
1501 * gnulib/import/fnmatch.in.h: Update.
1502 * gnulib/import/fnmatch_loop.c: Update.
1503 * gnulib/import/fpucw.h: Update.
1504 * gnulib/import/frexp.c: Update.
1505 * gnulib/import/frexpl.c: Update.
1506 * gnulib/import/fstat.c: Update.
1507 * gnulib/import/fstatat.c: Update.
1508 * gnulib/import/getcwd-lgpl.c: Update.
1509 * gnulib/import/getcwd.c: Update.
1510 * gnulib/import/getdtablesize.c: Update.
1511 * gnulib/import/getlogin_r.c: Update.
1512 * gnulib/import/getprogname.c: Update.
1513 * gnulib/import/getprogname.h: Update.
1514 * gnulib/import/gettext.h: Update.
1515 * gnulib/import/gettimeofday.c: Update.
1516 * gnulib/import/glob-libc.h: Update.
1517 * gnulib/import/glob.c: Update.
1518 * gnulib/import/glob.in.h: Update.
1519 * gnulib/import/glob_internal.h: Update.
1520 * gnulib/import/glob_pattern_p.c: Update.
1521 * gnulib/import/globfree.c: Update.
1522 * gnulib/import/hard-locale.c: Update.
1523 * gnulib/import/hard-locale.h: Update.
1524 * gnulib/import/intprops.h: Update.
1525 * gnulib/import/inttypes.in.h: Update.
1526 * gnulib/import/isnan.c: Update.
1527 * gnulib/import/isnand-nolibm.h: Update.
1528 * gnulib/import/isnand.c: Update.
1529 * gnulib/import/isnanl-nolibm.h: Update.
1530 * gnulib/import/isnanl.c: Update.
1531 * gnulib/import/itold.c: Update.
1532 * gnulib/import/libc-config.h: Update.
1533 * gnulib/import/limits.in.h: Update.
1534 * gnulib/import/localcharset.c: Update.
1535 * gnulib/import/localcharset.h: Update.
1536 * gnulib/import/localtime-buffer.c: Update.
1537 * gnulib/import/localtime-buffer.h: Update.
1538 * gnulib/import/lstat.c: Update.
1539 * gnulib/import/m4/00gnulib.m4: Update.
1540 * gnulib/import/m4/__inline.m4: Update.
1541 * gnulib/import/m4/absolute-header.m4: Update.
1542 * gnulib/import/m4/alloca.m4: Update.
1543 * gnulib/import/m4/builtin-expect.m4: Update.
1544 * gnulib/import/m4/canonicalize.m4: Update.
1545 * gnulib/import/m4/chdir-long.m4: Update.
1546 * gnulib/import/m4/close.m4: Update.
1547 * gnulib/import/m4/closedir.m4: Update.
1548 * gnulib/import/m4/configmake.m4: Update.
1549 * gnulib/import/m4/d-ino.m4: Update.
1550 * gnulib/import/m4/d-type.m4: Update.
1551 * gnulib/import/m4/dirent_h.m4: Update.
1552 * gnulib/import/m4/dirfd.m4: Update.
1553 * gnulib/import/m4/dirname.m4: Update.
1554 * gnulib/import/m4/double-slash-root.m4: Update.
1555 * gnulib/import/m4/dup.m4: Update.
1556 * gnulib/import/m4/dup2.m4: Update.
1557 * gnulib/import/m4/eealloc.m4: Update.
1558 * gnulib/import/m4/environ.m4: Update.
1559 * gnulib/import/m4/errno_h.m4: Update.
1560 * gnulib/import/m4/error.m4: Update.
1561 * gnulib/import/m4/exponentd.m4: Update.
1562 * gnulib/import/m4/exponentl.m4: Update.
1563 * gnulib/import/m4/extensions.m4: Update.
1564 * gnulib/import/m4/extern-inline.m4: Update.
1565 * gnulib/import/m4/fchdir.m4: Update.
1566 * gnulib/import/m4/fcntl-o.m4: Update.
1567 * gnulib/import/m4/fcntl.m4: Update.
1568 * gnulib/import/m4/fcntl_h.m4: Update.
1569 * gnulib/import/m4/fdopendir.m4: Update.
1570 * gnulib/import/m4/filenamecat.m4: Update.
1571 * gnulib/import/m4/flexmember.m4: Update.
1572 * gnulib/import/m4/float_h.m4: Update.
1573 * gnulib/import/m4/fnmatch.m4: Update.
1574 * gnulib/import/m4/fnmatch_h.m4: Update.
1575 * gnulib/import/m4/fpieee.m4: Update.
1576 * gnulib/import/m4/frexp.m4: Update.
1577 * gnulib/import/m4/frexpl.m4: Update.
1578 * gnulib/import/m4/fstat.m4: Update.
1579 * gnulib/import/m4/fstatat.m4: Update.
1580 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1581 * gnulib/import/m4/getcwd-path-max.m4: Update.
1582 * gnulib/import/m4/getcwd.m4: Update.
1583 * gnulib/import/m4/getdtablesize.m4: Update.
1584 * gnulib/import/m4/getlogin.m4: Update.
1585 * gnulib/import/m4/getlogin_r.m4: Update.
1586 * gnulib/import/m4/getpagesize.m4: Update.
1587 * gnulib/import/m4/getprogname.m4: Update.
1588 * gnulib/import/m4/gettimeofday.m4: Update.
1589 * gnulib/import/m4/glibc21.m4: Update.
1590 * gnulib/import/m4/glob.m4: Update.
1591 * gnulib/import/m4/glob_h.m4: Update.
1592 * gnulib/import/m4/gnulib-cache.m4: Update.
1593 * gnulib/import/m4/gnulib-common.m4: Update.
1594 * gnulib/import/m4/gnulib-comp.m4: Update.
1595 * gnulib/import/m4/gnulib-tool.m4: Update.
1596 * gnulib/import/m4/hard-locale.m4: Update.
1597 * gnulib/import/m4/include_next.m4: Update.
1598 * gnulib/import/m4/inttypes-pri.m4: Update.
1599 * gnulib/import/m4/inttypes.m4: Update.
1600 * gnulib/import/m4/isnand.m4: Update.
1601 * gnulib/import/m4/isnanl.m4: Update.
1602 * gnulib/import/m4/largefile.m4: Update.
1603 * gnulib/import/m4/limits-h.m4: Update.
1604 * gnulib/import/m4/localcharset.m4: Update.
1605 * gnulib/import/m4/locale-fr.m4: Update.
1606 * gnulib/import/m4/locale-ja.m4: Update.
1607 * gnulib/import/m4/locale-zh.m4: Update.
1608 * gnulib/import/m4/localtime-buffer.m4: Update.
1609 * gnulib/import/m4/longlong.m4: Update.
1610 * gnulib/import/m4/lstat.m4: Update.
1611 * gnulib/import/m4/malloc.m4: Update.
1612 * gnulib/import/m4/malloca.m4: Update.
1613 * gnulib/import/m4/math_h.m4: Update.
1614 * gnulib/import/m4/mbrtowc.m4: Update.
1615 * gnulib/import/m4/mbsinit.m4: Update.
1616 * gnulib/import/m4/mbsrtowcs.m4: Update.
1617 * gnulib/import/m4/mbstate_t.m4: Update.
1618 * gnulib/import/m4/memchr.m4: Update.
1619 * gnulib/import/m4/memmem.m4: Update.
1620 * gnulib/import/m4/mempcpy.m4: Update.
1621 * gnulib/import/m4/memrchr.m4: Update.
1622 * gnulib/import/m4/mkdir.m4: Update.
1623 * gnulib/import/m4/mkstemp.m4: Update.
1624 * gnulib/import/m4/mmap-anon.m4: Update.
1625 * gnulib/import/m4/mode_t.m4: Update.
1626 * gnulib/import/m4/msvc-inval.m4: Update.
1627 * gnulib/import/m4/msvc-nothrow.m4: Update.
1628 * gnulib/import/m4/multiarch.m4: Update.
1629 * gnulib/import/m4/nocrash.m4: Update.
1630 * gnulib/import/m4/off_t.m4: Update.
1631 * gnulib/import/m4/onceonly.m4: Update.
1632 * gnulib/import/m4/open-cloexec.m4: Update.
1633 * gnulib/import/m4/open.m4: Update.
1634 * gnulib/import/m4/openat.m4: Update.
1635 * gnulib/import/m4/opendir.m4: Update.
1636 * gnulib/import/m4/pathmax.m4: Update.
1637 * gnulib/import/m4/rawmemchr.m4: Update.
1638 * gnulib/import/m4/readdir.m4: Update.
1639 * gnulib/import/m4/readlink.m4: Update.
1640 * gnulib/import/m4/realloc.m4: Update.
1641 * gnulib/import/m4/rename.m4: Update.
1642 * gnulib/import/m4/rewinddir.m4: Update.
1643 * gnulib/import/m4/rmdir.m4: Update.
1644 * gnulib/import/m4/save-cwd.m4: Update.
1645 * gnulib/import/m4/secure_getenv.m4: Update.
1646 * gnulib/import/m4/setenv.m4: Update.
1647 * gnulib/import/m4/signal_h.m4: Update.
1648 * gnulib/import/m4/ssize_t.m4: Update.
1649 * gnulib/import/m4/stat-time.m4: Update.
1650 * gnulib/import/m4/stat.m4: Update.
1651 * gnulib/import/m4/std-gnu11.m4: Update.
1652 * gnulib/import/m4/stdbool.m4: Update.
1653 * gnulib/import/m4/stddef_h.m4: Update.
1654 * gnulib/import/m4/stdint.m4: Update.
1655 * gnulib/import/m4/stdio_h.m4: Update.
1656 * gnulib/import/m4/stdlib_h.m4: Update.
1657 * gnulib/import/m4/strchrnul.m4: Update.
1658 * gnulib/import/m4/strdup.m4: Update.
1659 * gnulib/import/m4/strerror.m4: Update.
1660 * gnulib/import/m4/string_h.m4: Update.
1661 * gnulib/import/m4/strstr.m4: Update.
1662 * gnulib/import/m4/strtok_r.m4: Update.
1663 * gnulib/import/m4/sys_socket_h.m4: Update.
1664 * gnulib/import/m4/sys_stat_h.m4: Update.
1665 * gnulib/import/m4/sys_time_h.m4: Update.
1666 * gnulib/import/m4/sys_types_h.m4: Update.
1667 * gnulib/import/m4/tempname.m4: Update.
1668 * gnulib/import/m4/time_h.m4: Update.
1669 * gnulib/import/m4/unistd-safer.m4: Update.
1670 * gnulib/import/m4/unistd_h.m4: Update.
1671 * gnulib/import/m4/warn-on-use.m4: Update.
1672 * gnulib/import/m4/wchar_h.m4: Update.
1673 * gnulib/import/m4/wchar_t.m4: Update.
1674 * gnulib/import/m4/wctype_h.m4: Update.
1675 * gnulib/import/m4/wint_t.m4: Update.
1676 * gnulib/import/malloc.c: Update.
1677 * gnulib/import/malloc/scratch_buffer.h: Update.
1678 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1679 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1680 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1681 * gnulib/import/malloca.c: Update.
1682 * gnulib/import/malloca.h: Update.
1683 * gnulib/import/malloca.valgrind: Update.
1684 * gnulib/import/math.in.h: Update.
1685 * gnulib/import/mbrtowc.c: Update.
1686 * gnulib/import/mbsinit.c: Update.
1687 * gnulib/import/mbsrtowcs-impl.h: Update.
1688 * gnulib/import/mbsrtowcs-state.c: Update.
1689 * gnulib/import/mbsrtowcs.c: Update.
1690 * gnulib/import/memchr.c: Update.
1691 * gnulib/import/memmem.c: Update.
1692 * gnulib/import/mempcpy.c: Update.
1693 * gnulib/import/memrchr.c: Update.
1694 * gnulib/import/mkdir.c: Update.
1695 * gnulib/import/mkstemp.c: Update.
1696 * gnulib/import/msvc-inval.c: Update.
1697 * gnulib/import/msvc-inval.h: Update.
1698 * gnulib/import/msvc-nothrow.c: Update.
1699 * gnulib/import/msvc-nothrow.h: Update.
1700 * gnulib/import/open.c: Update.
1701 * gnulib/import/openat-die.c: Update.
1702 * gnulib/import/openat-priv.h: Update.
1703 * gnulib/import/openat-proc.c: Update.
1704 * gnulib/import/openat.c: Update.
1705 * gnulib/import/openat.h: Update.
1706 * gnulib/import/opendir.c: Update.
1707 * gnulib/import/pathmax.h: Update.
1708 * gnulib/import/pipe-safer.c: Update.
1709 * gnulib/import/rawmemchr.c: Update.
1710 * gnulib/import/readdir.c: Update.
1711 * gnulib/import/readlink.c: Update.
1712 * gnulib/import/realloc.c: Update.
1713 * gnulib/import/ref-add.sin: Update.
1714 * gnulib/import/ref-del.sin: Update.
1715 * gnulib/import/rename.c: Update.
1716 * gnulib/import/rewinddir.c: Update.
1717 * gnulib/import/rmdir.c: Update.
1718 * gnulib/import/same-inode.h: Update.
1719 * gnulib/import/save-cwd.c: Update.
1720 * gnulib/import/save-cwd.h: Update.
1721 * gnulib/import/scratch_buffer.h: Update.
1722 * gnulib/import/secure_getenv.c: Update.
1723 * gnulib/import/setenv.c: Update.
1724 * gnulib/import/signal.in.h: Update.
1725 * gnulib/import/stat-time.c: Update.
1726 * gnulib/import/stat-time.h: Update.
1727 * gnulib/import/stat-w32.c: Update.
1728 * gnulib/import/stat-w32.h: Update.
1729 * gnulib/import/stat.c: Update.
1730 * gnulib/import/stdbool.in.h: Update.
1731 * gnulib/import/stddef.in.h: Update.
1732 * gnulib/import/stdint.in.h: Update.
1733 * gnulib/import/stdio.in.h: Update.
1734 * gnulib/import/stdlib.in.h: Update.
1735 * gnulib/import/str-two-way.h: Update.
1736 * gnulib/import/strchrnul.c: Update.
1737 * gnulib/import/strdup.c: Update.
1738 * gnulib/import/streq.h: Update.
1739 * gnulib/import/strerror-override.c: Update.
1740 * gnulib/import/strerror-override.h: Update.
1741 * gnulib/import/strerror.c: Update.
1742 * gnulib/import/string.in.h: Update.
1743 * gnulib/import/stripslash.c: Update.
1744 * gnulib/import/strnlen1.c: Update.
1745 * gnulib/import/strnlen1.h: Update.
1746 * gnulib/import/strstr.c: Update.
1747 * gnulib/import/strtok_r.c: Update.
1748 * gnulib/import/sys_stat.in.h: Update.
1749 * gnulib/import/sys_time.in.h: Update.
1750 * gnulib/import/sys_types.in.h: Update.
1751 * gnulib/import/tempname.c: Update.
1752 * gnulib/import/tempname.h: Update.
1753 * gnulib/import/time.in.h: Update.
1754 * gnulib/import/unistd--.h: Update.
1755 * gnulib/import/unistd-safer.h: Update.
1756 * gnulib/import/unistd.in.h: Update.
1757 * gnulib/import/unsetenv.c: Update.
1758 * gnulib/import/verify.h: Update.
1759 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1760 * gnulib/import/wchar.in.h: Update.
1761 * gnulib/import/wctype.in.h: Update.
1762 * gnulib/import/xalloc-oversized.h: Update.
1763 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1764 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1765
1766 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
1767
1768 * record-btrace.c (get_thread_current_frame): Remove
1769 old_inferior_ptid.
1770
1771 2018-09-10 Jerome Guitton <guitton@adacore.com>
1772
1773 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
1774 with check_tag to 1 if and only if the type is tagged and the
1775 component being searched cannot been found in the current
1776 view. Otherwise, always call ada_to_fixed_type with
1777 check_tag to 0.
1778
1779 2018-09-10 Xavier Roirand <roirand@adacore.com>
1780
1781 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
1782 declaration.
1783 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
1784 * ada-varobj.c (ada_varobj_get_number_of_children,
1785 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
1786
1787 2018-09-10 Xavier Roirand <roirand@adacore.com>
1788
1789 * ada-valprint.c (ada_value_print): Use type instead of
1790 enclosing type.
1791
1792 2018-09-10 Xavier Roirand <roirand@adacore.com>
1793
1794 * ada-lang.c (ada_value_subscript): Handle case when parameter is
1795 an array of access to unconstrained array.
1796
1797 2018-09-10 Xavier Roirand <roirand@adacore.com>
1798
1799 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
1800 (ada_check_typedef): Use it.
1801
1802 2018-09-10 Xavier Roirand <roirand@adacore.com>
1803
1804 * ada-varobj.c (ada_varobj_describe_struct_child)
1805 (ada_varobj_describe_child): Handle union case like struct one.
1806
1807 2018-09-10 Tom Tromey <tom@tromey.com>
1808
1809 PR python/18380:
1810 * python/python.c (_initialize_python): Make example in "python"
1811 help work in Python 3.
1812
1813 2018-09-10 Eli Zaretskii <eliz@gnu.org>
1814
1815 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
1816 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
1817 $(EXEEXT) to the script, as it is not a program.
1818
1819 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
1820
1821 * python/py-prettyprint.c (pretty_print_one_value): Return
1822 gdbpy_ref<>.
1823 (print_string_repr): Adjust.
1824 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
1825 * python/python-internal.h (apply_varobj_pretty_printer): Return
1826 gdbpy_ref<>.
1827 * varobj.c (varobj_value_get_print_value): Adjust.
1828
1829 2018-09-08 Tom Tromey <tom@tromey.com>
1830
1831 PR python/16047:
1832 * python/py-prettyprint.c (pretty_print_one_value): Check for
1833 to_string method.
1834
1835 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1836
1837 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
1838 replace_operator_with_call.
1839
1840 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1841
1842 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
1843
1844 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1845
1846 * ada-typeprint.c (print_range): Print the bounds using TYPE
1847 rather than its TYPE_TARGET_TYPE.
1848
1849 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1850
1851 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
1852 call to ada_to_fixed_value_create.
1853
1854 2018-09-08 Jerome Guitton <guitton@adacore.com>
1855
1856 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
1857
1858 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1859
1860 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
1861 by calls to error.
1862
1863 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1864
1865 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
1866 Move update of loop variable "fi".
1867
1868 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1869
1870 * ada-lang.c (value_assign_to_component): In the case of
1871 big-endian targets, extract the bits of the given VAL
1872 using an src_offset of zero if container is not a scalar.
1873
1874 2018-09-06 Simon Ser <contact@emersion.fr>
1875
1876 PR gdb/23105
1877 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
1878 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1879 * fbsd-tdep.c (fbsd_make_note_desc): New.
1880 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
1881 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
1882 * target.h (enum target_object) Add FreeBSD-specific
1883 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1884
1885 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1886
1887 * compile/compile-c.h (generate_c_for_variable_locations):
1888 Change reference to pointer.
1889 * compile/compile-c-support.c (compile_program) <compute>:
1890 Likewise.
1891 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
1892 (generate_c_for_for_one_variable): Likewise
1893 (generate_c_for_variable_locations): Likewise
1894 * compile/compile-c-types.c (compile_c_instance::convert_type):
1895 Likewise
1896 * compile/compile-cplus-symbols.c (convert_one_symbol):
1897 std::move the scope passed to enter_scope.
1898 * compile/compile-cplus-types.c
1899 (compile_cplus_instance::enter_scope): Make parameter
1900 rvalue-reference.
1901 (compile_cplus_instance::new_scope): Change reference to
1902 pointer.
1903 (compile_cplus_instance::convert_type): Likewise
1904 (compile_cplus_convert_typedef): std::move the scope passed to
1905 enter_scope.
1906 (compile_cplus_convert_struct_or_union): Likewise.
1907 (compile_cplus_convert_enum): Likewise.
1908 (compile_cplus_convert_namespace): Likewise.
1909 * compile/compile-cplus.h (compile_cplus_instance)
1910 <enter_scope>: Make parameter rvalue-reference.
1911 * compile/compile-internal.h (compile_instance)
1912 <get_cached_type>: Likewise
1913 * compile/compile-loc2c.c (push): Likewise
1914 (pushf): Likewise
1915 (unary): Likewise
1916 (binary): Likewise
1917 (print_label): Likewise
1918 (pushf_register_address): Likewise
1919 (pushf_register): Likewise
1920 (do_compile_dwarf_expr_to_c): Likewise
1921 (compile_dwarf_expr_to_c): Likewise
1922 (compile_dwarf_bounds_to_c): Likewise
1923 * compile/compile.c (compile_instance::get_cached_type):
1924 Likewise
1925 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
1926 (compile_dwarf_bounds_to_c): Likewise
1927 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
1928 (dwarf2_compile_property_to_c): Likewise
1929 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
1930 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1931 Likewise
1932
1933 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1934
1935 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
1936 * tui/tui-data.c (init_content_element): Don't initialize it.
1937
1938 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1939
1940 * tui/tui-data.h (struct tui_win_info)
1941 <detail::opaque>: Remove.
1942 * tui/tui-data.c (init_win_info): Remove assignment.
1943
1944 2018-09-05 Tom Tromey <tom@tromey.com>
1945
1946 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
1947 -Wformat-nonliteral.
1948 * target-float.c (host_float_ops<T>::to_string)
1949 (host_float_ops<T>::from_string): Use
1950 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1951 * configure: Rebuild.
1952
1953 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
1954
1955 * printcmd.c (printf_c_string): Use
1956 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1957 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
1958
1959 2018-09-05 Tom Tromey <tom@tromey.com>
1960
1961 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
1962
1963 2018-09-05 Tom de Vries <tdevries@suse.de>
1964
1965 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1966 with resolve_abstract_p == true.
1967 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1968 defaulting to false. Propagate resolve_abstract_p to
1969 dwarf2_fetch_die_loc_sect_off.
1970 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1971 parameter, defaulting to false.
1972 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1973 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1974 parameter.
1975 * dwarf2read.h (struct die_info): Forward-declare.
1976 (die_info_ptr): New typedef.
1977 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1978
1979 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1980
1981 GDB 8.2 released.
1982
1983 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1984 Pedro Alves <palves@redhat.com>
1985
1986 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1987 "aclocal-m4-deps.mk". Include file here.
1988 $(srcdir)/aclocal.m4: Add "configure.ac".
1989 * gnulib/aclocal-m4-deps.mk: New file.
1990 * gnulib/update-gnulib.sh: Automatically update
1991 "aclocal-m4-deps.mk".
1992
1993 2018-09-04 Tom Tromey <tom@tromey.com>
1994
1995 * configure: Rebuild.
1996 * configure.ac: Remove multi-ice code.
1997
1998 2018-09-04 Tom Tromey <tom@tromey.com>
1999
2000 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
2001 (ada-exp.o): Update.
2002
2003 2018-09-04 Tom Tromey <tom@tromey.com>
2004
2005 * Makefile.in (printcmd.o, target-float.o): Remove.
2006 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
2007
2008 2018-09-04 Tom Tromey <tom@tromey.com>
2009
2010 * gnulib/Makefile.in: Remove obsolete comment.
2011 * Makefile.in: Remove obsolete comment.
2012
2013 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
2014
2015 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
2016 line with '+'.
2017
2018 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
2019
2020 * riscv-tdep.c: Add 'prologue-value.h' include.
2021 (struct riscv_unwind_cache): New struct.
2022 (riscv_debug_unwinder): New global.
2023 (riscv_scan_prologue): Update arguments, capture register details
2024 from prologue scan.
2025 (riscv_skip_prologue): Reformat arguments line, move end of
2026 prologue calculation into riscv_scan_prologue.
2027 (riscv_frame_cache): Update return type, create
2028 riscv_unwind_cache, scan the prologue, and fill in remaining cache
2029 details.
2030 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
2031 (riscv_frame_prev_register): Use the trad_frame within the
2032 riscv_unwind_cache.
2033 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
2034 flag.
2035
2036 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
2037
2038 * trad-frame.h (trad_frame_set_realreg): Declare.
2039 (trad_frame_set_addr): Declare.
2040 * trad-frame.c (trad_frame_set_realreg): Define new function.
2041 (trad_frame_set_addr): Define new function.
2042 (trad_frame_set_reg_realreg): Use new function.
2043 (trad_frame_set_reg_addr): Use new function.
2044
2045 2018-09-01 Keith Seitz <keiths@redhat.com>
2046
2047 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
2048 pulongest instead of "%lld".
2049 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
2050 ATTRIBUTE_UNUSED.
2051
2052 2018-08-31 Tom Tromey <tom@tromey.com>
2053
2054 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
2055 variant part type.
2056
2057 2018-08-31 Pedro Alves <palves@redhat.com>
2058
2059 * gdbarch.h: Regenerate.
2060
2061 2018-08-31 Pedro Alves <palves@redhat.com>
2062
2063 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
2064 * target.h (Hardware watchpoint interfaces): Describe
2065 continuable/steppable/non-steppable watchpoints.
2066 * gdbarch.h, gdbarch.c: Regenerate.
2067
2068 2018-08-31 Pedro Alves <palves@redhat.com>
2069
2070 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
2071 Delete.
2072 * s390-linux-nat.c
2073 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
2074 * target.h (target_ops::have_continuable_watchpoint): Delete.
2075 (target_have_continuable_watchpoint): Delete.
2076 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
2077 * target-delegates.c: Regenerate.
2078
2079 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2080
2081 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
2082 the files present in "gnulib/import/m4/".
2083
2084 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2085
2086 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
2087 c.sw, c.swsp, and c.sdsp.
2088
2089 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2090
2091 * riscv-tdep.c (struct riscv_inferior_data): Delete.
2092 (riscv_read_misa_reg): Don't cache value read into inferior data.
2093 (riscv_new_inferior_data): Delete.
2094 (riscv_inferior_data_cleanup): Delete.
2095 (riscv_inferior_data): Delete.
2096 (riscv_invalidate_inferior_data): Delete.
2097 (_initialize_riscv_tdep): Remove initialisation of inferior data.
2098
2099 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
2100
2101 * compile/compile-cplus-types.c
2102 (compile_cplus_instance::leave_scope): Take the address of scope
2103 object.
2104 (compile_cplus_instance::convert_qualified_base): Compare quals
2105 to 0.
2106
2107 2018-08-30 Keith Seitz <keiths@redhat.com>
2108
2109 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
2110 Use "%s" and host_address_to_string instead of "%p" in printf.
2111
2112 2018-08-29 Keith Seitz <keiths@redhat.com>
2113
2114 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
2115 and compile-cplus-types.c.
2116 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
2117 * c-lang.c (cplus_language_defn): Set C++ compile functions.
2118 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
2119 Declare.
2120 * compile/compile-c-support.c: Include compile-cplus.h.
2121 (load_libcompile): Templatize.
2122 (get_compile_context): "New" function.
2123 (c_get_compile_context): Use get_compile_context.
2124 (cplus_get_compile_context): New function.
2125 (cplus_push_user_expression, cplus_pop_user_expression)
2126 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
2127 (cplus_compute_program): Define new structs/functions.
2128 * compile/compile-cplus-symmbols.c: New file.
2129 * compile/compile-cplus-types.c: New file.
2130 * compile/compile-cplus.h: New file.
2131 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
2132 Declare.
2133 * compile/compile-object-load.c (get_out_value_type): Use
2134 strncmp_iw when comparing symbol names.
2135 (compile_object_load): Add mst_bss and mst_data.
2136 * compile/compile.c (_initialize_compile): Remove
2137 -Wno-implicit-function-declaration from `compile_args'.
2138 * compile/gcc-cp-plugin.h: New file.
2139 * NEWS: Mention C++ compile support and new debug options.
2140
2141 2018-08-29 Keith Seitz <keiths@redhat.com>
2142
2143 * linespec.c (collect_info::add_symbol): Make virtual.
2144 (struct symbol_searcher_collect_info): New struct.
2145 (symbol_searcher::find_all_symbols): New method.
2146 * symtab.h (class symbol_searcher): New class.
2147
2148 2018-08-29 Keith Seitz <keiths@redhat.com>
2149
2150 * linespec.c (struct linespec) <function_symbols, label_symbols>:
2151 Change to vector of block_symbol. Update all users.
2152 (struct collect_info) <symbols>: Likewise.
2153 (collect_info::add_symbol): Take block_symbol as argument.
2154 Update all callers.
2155 (decode_compound_collector) <m_symbols>: Change type to vector
2156 of block_symbol. Update all users.
2157 (decode_compound_collector::operator ()): Change parameter type
2158 to block_symbol.
2159 (find_method, find_function_symbols, find_linespec_symbols)
2160 (find_label_symbols_in_block, find_label_symbols): Change symbol
2161 vectors to block_symbol vectors.
2162 * symtab.h (symbol_found_callback_ftype): Change parameter type to
2163 block_symbol.
2164
2165 2018-08-29 Keith Seitz <keiths@redhat.com>
2166
2167 * linespec.c (symbolp): Remove typedef and VEC definitions.
2168 (bound_minimal_symbol_d): Likewise.
2169
2170 2018-08-29 Keith Seitz <keiths@redhat.com>
2171
2172 * linespec.c (decode_compound_collector::decode_compound_collector):
2173 Remove initialization for `m_symtabs'.
2174 (decode_compound_collector::release_symbols): Change return type
2175 to std::vector. Update all callers.
2176 (class decode_compound_collector) <m_symbols>: Change type to
2177 std::vector.
2178 (lookup_prefix_sym): Change return type to std::vector. Update all
2179 callers.
2180 (compare_symbols): Remove.
2181 (std_compare_symbols): Rename to `compare_symbols'.
2182 (find_method): Change `sym_classes' parameter to std::vector.
2183 Update all callers. Use std::sort to sort sym_classes.
2184 (find_linespec_symbols): Remove cleanup.
2185
2186 2018-08-29 Keith Seitz <keiths@redhat.com>
2187
2188 * linespec.c (struct linespec) <minimal_symbols>: Change type to
2189 std::vector. Update all users.
2190 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
2191 (struct collect_info) <minimal_symbols>: Likewise.
2192 (compare_msymbols): Return bool. Change parameters to const
2193 bound_minimal_symbol references.
2194 (find_method, find_function_symbols, find_linespec_symbols): Change
2195 `minsyms' parameter to std::vector. Update all callers.
2196
2197 2018-08-29 Keith Seitz <keiths@redhat.com>
2198
2199 * linespec.c (struct linespec) <label_symbols>: Change type to
2200 std::vector. Update all users.
2201 (find_label_symbols_in_block): Change `result' parameter to
2202 std::vector. Update all callers.
2203 (find_label_symbols): Return std::vector. Update all callers.
2204
2205 2018-08-29 Keith Seitz <keiths@redhat.com>
2206
2207 * linespec.c (struct linespec) <function_symbols>: Change type to
2208 std::vector. Update all users.
2209 (struct collect_info) <function_symbols>: Likewise.
2210 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
2211 (std_compare_symbols): New function.
2212 (find_method, find_function_symbols, find_linespec_symbols)
2213 (find_label_symbols_in_block): Change `symbols' parameter to
2214 std::vector. Update all callers.
2215 (find_label_symbols): Likewise for `function_symbols' and
2216 `label_funcs_ret'.
2217
2218 2018-08-29 Keith Seitz <keiths@redhat.com>
2219
2220 * linespec.c (symtab_vector_up): Define.
2221 (struct linespec) <file_symtabs>: Change type to std::vector *.
2222 Update all uses.
2223 (struct collect_info) <file_symtabs>: Likewise.
2224 (collect_symtabs_from_filename): Return symtab_vector_up.
2225 Update all callers.
2226 (decode_objc): Remove cleanup.
2227 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
2228 (symtab_collector::release_symtabs): Return symtab_vector_up.
2229 Update all callers.
2230 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
2231 Update all users.
2232 (collect_symtabs_from_filename, symtabs_from_filename): Return
2233 symtab_vector_up. Update all callers.
2234
2235 2018-08-29 Tom Tromey <tom@tromey.com>
2236
2237 * csky-tdep.c (csky_analyze_prologue): Use
2238 core_addr_to_string_nz.
2239
2240 2018-08-29 Tom Tromey <tom@tromey.com>
2241
2242 * windows-nat.c (struct xlate_exception) <them>: Change type to
2243 DWORD.
2244 (xlate): Fix formatting. Remove last entry.
2245 (struct xlate_exception, xlate): Comment out.
2246 (windows_nat_target::resume): Use ranged for.
2247
2248 2018-08-29 Jim Wilson <jimw@sifive.com>
2249
2250 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
2251 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
2252 of NT_PRFPREG.
2253 (riscv_linux_nat_target::store_registers): Likewise.
2254
2255 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
2256
2257 PR gdb/23555
2258 PR gdb/23558
2259 * gnulib/aclocal.m4: Regenerate.
2260 * gnulib/config.in: Regenerate.
2261 * gnulib/configure: Regenerate.
2262 * gnulib/import/Makefile.am: Update.
2263 * gnulib/import/Makefile.in: Update.
2264 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
2265 * gnulib/import/_Noreturn.h: ... this.
2266 * gnulib/import/alloca.in.h: Update.
2267 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
2268 * gnulib/import/arg-nonnull.h: ... this.
2269 * gnulib/import/assure.h: Update.
2270 * gnulib/import/at-func.c: Update.
2271 * gnulib/import/basename-lgpl.c: Update.
2272 * gnulib/import/extra/snippet/c++defs.h: Rename to...
2273 * gnulib/import/c++defs.h: ... this.
2274 * gnulib/import/canonicalize-lgpl.c: Update.
2275 * gnulib/import/cdefs.h: Update.
2276 * gnulib/import/chdir-long.c: Update.
2277 * gnulib/import/chdir-long.h: Update.
2278 * gnulib/import/cloexec.c: Update.
2279 * gnulib/import/cloexec.h: Update.
2280 * gnulib/import/close.c: Update.
2281 * gnulib/import/closedir.c: Update.
2282 * gnulib/import/config.charset: Update.
2283 * gnulib/import/dirent-private.h: Update.
2284 * gnulib/import/dirent.in.h: Update.
2285 * gnulib/import/dirfd.c: Update.
2286 * gnulib/import/dirname-lgpl.c: Update.
2287 * gnulib/import/dirname.h: Update.
2288 * gnulib/import/dosname.h: Update.
2289 * gnulib/import/dup-safer-flag.c: Update.
2290 * gnulib/import/dup-safer.c: Update.
2291 * gnulib/import/dup.c: Update.
2292 * gnulib/import/dup2.c: Update.
2293 * gnulib/import/errno.in.h: Update.
2294 * gnulib/import/error.c: Update.
2295 * gnulib/import/error.h: Update.
2296 * gnulib/import/exitfail.c: Update.
2297 * gnulib/import/exitfail.h: Update.
2298 * gnulib/import/extra/update-copyright: Update.
2299 * gnulib/import/fchdir.c: Update.
2300 * gnulib/import/fcntl.c: Update.
2301 * gnulib/import/fcntl.in.h: Update.
2302 * gnulib/import/fd-hook.c: Update.
2303 * gnulib/import/fd-hook.h: Update.
2304 * gnulib/import/fd-safer-flag.c: Update.
2305 * gnulib/import/fd-safer.c: Update.
2306 * gnulib/import/fdopendir.c: Update.
2307 * gnulib/import/filename.h: Update.
2308 * gnulib/import/filenamecat-lgpl.c: Update.
2309 * gnulib/import/filenamecat.h: Update.
2310 * gnulib/import/flexmember.h: Update.
2311 * gnulib/import/float+.h: Update.
2312 * gnulib/import/float.c: Update.
2313 * gnulib/import/float.in.h: Update.
2314 * gnulib/import/fnmatch.c: Update.
2315 * gnulib/import/fnmatch.in.h: Update.
2316 * gnulib/import/fnmatch_loop.c: Update.
2317 * gnulib/import/fpucw.h: Update.
2318 * gnulib/import/frexp.c: Update.
2319 * gnulib/import/frexpl.c: Update.
2320 * gnulib/import/fstat.c: Update.
2321 * gnulib/import/fstatat.c: Update.
2322 * gnulib/import/getcwd-lgpl.c: Update.
2323 * gnulib/import/getcwd.c: Update.
2324 * gnulib/import/getdtablesize.c: Update.
2325 * gnulib/import/getlogin_r.c: Update.
2326 * gnulib/import/getprogname.c: Update.
2327 * gnulib/import/getprogname.h: Update.
2328 * gnulib/import/gettext.h: Update.
2329 * gnulib/import/gettimeofday.c: Update.
2330 * gnulib/import/glob-libc.h: Update.
2331 * gnulib/import/glob.c: Update.
2332 * gnulib/import/glob.in.h: Update.
2333 * gnulib/import/glob_internal.h: Update.
2334 * gnulib/import/glob_pattern_p.c: Update.
2335 * gnulib/import/globfree.c: Update.
2336 * gnulib/import/hard-locale.c: Update.
2337 * gnulib/import/hard-locale.h: Update.
2338 * gnulib/import/intprops.h: Update.
2339 * gnulib/import/inttypes.in.h: Update.
2340 * gnulib/import/isnan.c: Update.
2341 * gnulib/import/isnand-nolibm.h: Update.
2342 * gnulib/import/isnand.c: Update.
2343 * gnulib/import/isnanl-nolibm.h: Update.
2344 * gnulib/import/isnanl.c: Update.
2345 * gnulib/import/itold.c: Update.
2346 * gnulib/import/libc-config.h: Update.
2347 * gnulib/import/limits.in.h: Update.
2348 * gnulib/import/localcharset.c: Update.
2349 * gnulib/import/localcharset.h: Update.
2350 * gnulib/import/localtime-buffer.c: Update.
2351 * gnulib/import/localtime-buffer.h: Update.
2352 * gnulib/import/lstat.c: Update.
2353 * gnulib/import/m4/00gnulib.m4: Update.
2354 * gnulib/import/m4/__inline.m4: Update.
2355 * gnulib/import/m4/absolute-header.m4: Update.
2356 * gnulib/import/m4/alloca.m4: Update.
2357 * gnulib/import/m4/builtin-expect.m4: Update.
2358 * gnulib/import/m4/canonicalize.m4: Update.
2359 * gnulib/import/m4/chdir-long.m4: Update.
2360 * gnulib/import/m4/close.m4: Update.
2361 * gnulib/import/m4/closedir.m4: Update.
2362 * gnulib/import/m4/configmake.m4: Update.
2363 * gnulib/import/m4/d-ino.m4: Update.
2364 * gnulib/import/m4/d-type.m4: Update.
2365 * gnulib/import/m4/dirent_h.m4: Update.
2366 * gnulib/import/m4/dirfd.m4: Update.
2367 * gnulib/import/m4/dirname.m4: Update.
2368 * gnulib/import/m4/double-slash-root.m4: Update.
2369 * gnulib/import/m4/dup.m4: Update.
2370 * gnulib/import/m4/dup2.m4: Update.
2371 * gnulib/import/m4/eealloc.m4: Update.
2372 * gnulib/import/m4/environ.m4: Update.
2373 * gnulib/import/m4/errno_h.m4: Update.
2374 * gnulib/import/m4/error.m4: Update.
2375 * gnulib/import/m4/exponentd.m4: Update.
2376 * gnulib/import/m4/exponentl.m4: Update.
2377 * gnulib/import/m4/extensions.m4: Update.
2378 * gnulib/import/m4/extern-inline.m4: Update.
2379 * gnulib/import/m4/fchdir.m4: Update.
2380 * gnulib/import/m4/fcntl-o.m4: Update.
2381 * gnulib/import/m4/fcntl.m4: Update.
2382 * gnulib/import/m4/fcntl_h.m4: Update.
2383 * gnulib/import/m4/fdopendir.m4: Update.
2384 * gnulib/import/m4/filenamecat.m4: Update.
2385 * gnulib/import/m4/flexmember.m4: Update.
2386 * gnulib/import/m4/float_h.m4: Update.
2387 * gnulib/import/m4/fnmatch.m4: Update.
2388 * gnulib/import/m4/fnmatch_h.m4: Update.
2389 * gnulib/import/m4/fpieee.m4: Update.
2390 * gnulib/import/m4/frexp.m4: Update.
2391 * gnulib/import/m4/frexpl.m4: Update.
2392 * gnulib/import/m4/fstat.m4: Update.
2393 * gnulib/import/m4/fstatat.m4: Update.
2394 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
2395 * gnulib/import/m4/getcwd-path-max.m4: Update.
2396 * gnulib/import/m4/getcwd.m4: Update.
2397 * gnulib/import/m4/getdtablesize.m4: Update.
2398 * gnulib/import/m4/getlogin.m4: Update.
2399 * gnulib/import/m4/getlogin_r.m4: Update.
2400 * gnulib/import/m4/getpagesize.m4: Update.
2401 * gnulib/import/m4/getprogname.m4: Update.
2402 * gnulib/import/m4/gettimeofday.m4: Update.
2403 * gnulib/import/m4/glibc21.m4: Update.
2404 * gnulib/import/m4/glob.m4: Update.
2405 * gnulib/import/m4/glob_h.m4: Update.
2406 * gnulib/import/m4/gnulib-cache.m4: Update.
2407 * gnulib/import/m4/gnulib-common.m4: Update.
2408 * gnulib/import/m4/gnulib-comp.m4: Update.
2409 * gnulib/import/m4/gnulib-tool.m4: Update.
2410 * gnulib/import/m4/hard-locale.m4: Update.
2411 * gnulib/import/m4/include_next.m4: Update.
2412 * gnulib/import/m4/inttypes-pri.m4: Update.
2413 * gnulib/import/m4/inttypes.m4: Update.
2414 * gnulib/import/m4/isnand.m4: Update.
2415 * gnulib/import/m4/isnanl.m4: Update.
2416 * gnulib/import/m4/largefile.m4: Update.
2417 * gnulib/import/m4/limits-h.m4: Update.
2418 * gnulib/import/m4/localcharset.m4: Update.
2419 * gnulib/import/m4/locale-fr.m4: Update.
2420 * gnulib/import/m4/locale-ja.m4: Update.
2421 * gnulib/import/m4/locale-zh.m4: Update.
2422 * gnulib/import/m4/localtime-buffer.m4: Update.
2423 * gnulib/import/m4/longlong.m4: Update.
2424 * gnulib/import/m4/lstat.m4: Update.
2425 * gnulib/import/m4/malloc.m4: Update.
2426 * gnulib/import/m4/malloca.m4: Update.
2427 * gnulib/import/m4/math_h.m4: Update.
2428 * gnulib/import/m4/mbrtowc.m4: Update.
2429 * gnulib/import/m4/mbsinit.m4: Update.
2430 * gnulib/import/m4/mbsrtowcs.m4: Update.
2431 * gnulib/import/m4/mbstate_t.m4: Update.
2432 * gnulib/import/m4/memchr.m4: Update.
2433 * gnulib/import/m4/memmem.m4: Update.
2434 * gnulib/import/m4/mempcpy.m4: Update.
2435 * gnulib/import/m4/memrchr.m4: Update.
2436 * gnulib/import/m4/mkdir.m4: Update.
2437 * gnulib/import/m4/mkstemp.m4: Update.
2438 * gnulib/import/m4/mmap-anon.m4: Update.
2439 * gnulib/import/m4/mode_t.m4: Update.
2440 * gnulib/import/m4/msvc-inval.m4: Update.
2441 * gnulib/import/m4/msvc-nothrow.m4: Update.
2442 * gnulib/import/m4/multiarch.m4: Update.
2443 * gnulib/import/m4/nocrash.m4: Update.
2444 * gnulib/import/m4/off_t.m4: Update.
2445 * gnulib/import/m4/onceonly.m4: Update.
2446 * gnulib/import/m4/open-cloexec.m4: Update.
2447 * gnulib/import/m4/open.m4: Update.
2448 * gnulib/import/m4/openat.m4: Update.
2449 * gnulib/import/m4/opendir.m4: Update.
2450 * gnulib/import/m4/pathmax.m4: Update.
2451 * gnulib/import/m4/rawmemchr.m4: Update.
2452 * gnulib/import/m4/readdir.m4: Update.
2453 * gnulib/import/m4/readlink.m4: Update.
2454 * gnulib/import/m4/realloc.m4: Update.
2455 * gnulib/import/m4/rename.m4: Update.
2456 * gnulib/import/m4/rewinddir.m4: Update.
2457 * gnulib/import/m4/rmdir.m4: Update.
2458 * gnulib/import/m4/save-cwd.m4: Update.
2459 * gnulib/import/m4/secure_getenv.m4: Update.
2460 * gnulib/import/m4/setenv.m4: Update.
2461 * gnulib/import/m4/signal_h.m4: Update.
2462 * gnulib/import/m4/ssize_t.m4: Update.
2463 * gnulib/import/m4/stat-time.m4: Update.
2464 * gnulib/import/m4/stat.m4: Update.
2465 * gnulib/import/m4/std-gnu11.m4: Update.
2466 * gnulib/import/m4/stdbool.m4: Update.
2467 * gnulib/import/m4/stddef_h.m4: Update.
2468 * gnulib/import/m4/stdint.m4: Update.
2469 * gnulib/import/m4/stdio_h.m4: Update.
2470 * gnulib/import/m4/stdlib_h.m4: Update.
2471 * gnulib/import/m4/strchrnul.m4: Update.
2472 * gnulib/import/m4/strdup.m4: Update.
2473 * gnulib/import/m4/strerror.m4: Update.
2474 * gnulib/import/m4/string_h.m4: Update.
2475 * gnulib/import/m4/strstr.m4: Update.
2476 * gnulib/import/m4/strtok_r.m4: Update.
2477 * gnulib/import/m4/sys_socket_h.m4: Update.
2478 * gnulib/import/m4/sys_stat_h.m4: Update.
2479 * gnulib/import/m4/sys_time_h.m4: Update.
2480 * gnulib/import/m4/sys_types_h.m4: Update.
2481 * gnulib/import/m4/tempname.m4: Update.
2482 * gnulib/import/m4/time_h.m4: Update.
2483 * gnulib/import/m4/unistd-safer.m4: Update.
2484 * gnulib/import/m4/unistd_h.m4: Update.
2485 * gnulib/import/m4/warn-on-use.m4: Update.
2486 * gnulib/import/m4/wchar_h.m4: Update.
2487 * gnulib/import/m4/wchar_t.m4: Update.
2488 * gnulib/import/m4/wctype_h.m4: Update.
2489 * gnulib/import/m4/wint_t.m4: Update.
2490 * gnulib/import/malloc.c: Update.
2491 * gnulib/import/malloc/scratch_buffer.h: Update.
2492 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
2493 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
2494 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
2495 * gnulib/import/malloca.c: Update.
2496 * gnulib/import/malloca.h: Update.
2497 * gnulib/import/malloca.valgrind: Update.
2498 * gnulib/import/math.in.h: Update.
2499 * gnulib/import/mbrtowc.c: Update.
2500 * gnulib/import/mbsinit.c: Update.
2501 * gnulib/import/mbsrtowcs-impl.h: Update.
2502 * gnulib/import/mbsrtowcs-state.c: Update.
2503 * gnulib/import/mbsrtowcs.c: Update.
2504 * gnulib/import/memchr.c: Update.
2505 * gnulib/import/memmem.c: Update.
2506 * gnulib/import/mempcpy.c: Update.
2507 * gnulib/import/memrchr.c: Update.
2508 * gnulib/import/mkdir.c: Update.
2509 * gnulib/import/mkstemp.c: Update.
2510 * gnulib/import/msvc-inval.c: Update.
2511 * gnulib/import/msvc-inval.h: Update.
2512 * gnulib/import/msvc-nothrow.c: Update.
2513 * gnulib/import/msvc-nothrow.h: Update.
2514 * gnulib/import/open.c: Update.
2515 * gnulib/import/openat-die.c: Update.
2516 * gnulib/import/openat-priv.h: Update.
2517 * gnulib/import/openat-proc.c: Update.
2518 * gnulib/import/openat.c: Update.
2519 * gnulib/import/openat.h: Update.
2520 * gnulib/import/opendir.c: Update.
2521 * gnulib/import/pathmax.h: Update.
2522 * gnulib/import/pipe-safer.c: Update.
2523 * gnulib/import/rawmemchr.c: Update.
2524 * gnulib/import/readdir.c: Update.
2525 * gnulib/import/readlink.c: Update.
2526 * gnulib/import/realloc.c: Update.
2527 * gnulib/import/ref-add.sin: Update.
2528 * gnulib/import/ref-del.sin: Update.
2529 * gnulib/import/rename.c: Update.
2530 * gnulib/import/rewinddir.c: Update.
2531 * gnulib/import/rmdir.c: Update.
2532 * gnulib/import/same-inode.h: Update.
2533 * gnulib/import/save-cwd.c: Update.
2534 * gnulib/import/save-cwd.h: Update.
2535 * gnulib/import/scratch_buffer.h: Update.
2536 * gnulib/import/secure_getenv.c: Update.
2537 * gnulib/import/setenv.c: Update.
2538 * gnulib/import/signal.in.h: Update.
2539 * gnulib/import/stat-time.c: Update.
2540 * gnulib/import/stat-time.h: Update.
2541 * gnulib/import/stat-w32.c: Update.
2542 * gnulib/import/stat-w32.h: Update.
2543 * gnulib/import/stat.c: Update.
2544 * gnulib/import/stdbool.in.h: Update.
2545 * gnulib/import/stddef.in.h: Update.
2546 * gnulib/import/stdint.in.h: Update.
2547 * gnulib/import/stdio.in.h: Update.
2548 * gnulib/import/stdlib.in.h: Update.
2549 * gnulib/import/str-two-way.h: Update.
2550 * gnulib/import/strchrnul.c: Update.
2551 * gnulib/import/strdup.c: Update.
2552 * gnulib/import/streq.h: Update.
2553 * gnulib/import/strerror-override.c: Update.
2554 * gnulib/import/strerror-override.h: Update.
2555 * gnulib/import/strerror.c: Update.
2556 * gnulib/import/string.in.h: Update.
2557 * gnulib/import/stripslash.c: Update.
2558 * gnulib/import/strnlen1.c: Update.
2559 * gnulib/import/strnlen1.h: Update.
2560 * gnulib/import/strstr.c: Update.
2561 * gnulib/import/strtok_r.c: Update.
2562 * gnulib/import/sys_stat.in.h: Update.
2563 * gnulib/import/sys_time.in.h: Update.
2564 * gnulib/import/sys_types.in.h: Update.
2565 * gnulib/import/tempname.c: Update.
2566 * gnulib/import/tempname.h: Update.
2567 * gnulib/import/time.in.h: Update.
2568 * gnulib/import/unistd--.h: Update.
2569 * gnulib/import/unistd-safer.h: Update.
2570 * gnulib/import/unistd.in.h: Update.
2571 * gnulib/import/unsetenv.c: Update.
2572 * gnulib/import/verify.h: Update.
2573 * gnulib/import/extra/snippet/warn-on-use.h: Update.
2574 * gnulib/import/wchar.in.h: Update.
2575 * gnulib/import/wctype.in.h: Update.
2576 * gnulib/import/xalloc-oversized.h: Update.
2577 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
2578 "53e2c179f26a890fa6685af4b6c1397ee370433b".
2579
2580 2018-08-16 Gary Benson <gbenson@redhat.com>
2581
2582 PR gdb/13000:
2583 * gdb/main.c (captured_main_1): Exit with nonzero status
2584 in batch mode if the last command to be executed failed.
2585 * NEWS: Mention the above.
2586
2587 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
2588
2589 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
2590 end of warning message.
2591
2592 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2593
2594 PR gdb/22943:
2595 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
2596 (aarch64_extract_return_value): Use
2597 aapcs_is_vfp_call_or_return_candidate.
2598 (aarch64_return_in_memory): Likewise.
2599 (aarch64_store_return_value): Likewise.
2600
2601 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2602
2603 * aarch64-tdep.c
2604 (aapcs_is_vfp_call_or_return_candidate): Make static
2605 (pass_in_v_or_stack): Remove function.
2606 (pass_in_v_vfp_candidate): New function.
2607 (aarch64_push_dummy_call): Check for float register candidates.
2608
2609 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2610
2611 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
2612 (aapcs_is_vfp_call_or_return_candidate_1): New function.
2613 (aapcs_is_vfp_call_or_return_candidate): Likewise.
2614
2615 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
2616
2617 PR build/23399
2618 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
2619 (struct ipa_sym_addresses): Rename to...
2620 (struct ipa_sym_addresses_common): ... this.
2621 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
2622
2623 2018-08-28 Tom Tromey <tom@tromey.com>
2624
2625 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2626 (token_fifo): Now a std::vector.
2627 (yylex, c_parse): Update.
2628 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2629 (token_fifo): Now a std::vector.
2630 (yylex, d_parse): Update.
2631 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
2632 (token_fifo): Now a std::vector.
2633 (yylex, go_parse): Update.
2634
2635 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
2636
2637 * parser-defs.h (struct type_stack) <elements>: Change type to
2638 std::vector<union type_stack_elt>.
2639 <depth, size>: Remove.
2640 * parse.c (parse_exp_in_context_1): Adjust.
2641 (type_stack_reserve): Remove.
2642 (check_type_stack_depth): Remove.
2643 (insert_into_type_stack): Adjust to std::vector.
2644 (insert_type): Likewise.
2645 (push_type): Likewise.
2646 (push_type_int): Likewise.
2647 (insert_type_address_space): Likewise.
2648 (pop_type): Likewise.
2649 (pop_type_int): Likewise.
2650 (pop_typelist): Likewise.
2651 (pop_type_stack): Likewise.
2652 (append_type_stack): Likewise.
2653 (push_type_stack): Likewise.
2654 (get_type_stack): Likewise.
2655 (type_stack_cleanup): Likewise.
2656 (push_typelist): Likewise.
2657 (follow_types): Likewise.
2658 (_initialize_parse): Likewise.
2659
2660 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
2661
2662 * NEWS: Mention csky target.
2663
2664 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
2665 Hafiz Abid Qadeer <abidh@codesourcery.com>
2666 Don Breazeal <donb@codesourcery.com>
2667
2668 * csky-linux-tdep.c: New file.
2669 * csky-tdep.c: Likewise.
2670 * csky-tdep.h: Likewise.
2671 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
2672 csky-tdep.o.
2673 (HFILES_NO_SRCDIR): Add csky-tdep.h.
2674 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
2675 * configure.tgt: Add csky support.
2676
2677 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
2678
2679 * python/py-framefilter.c (py_print_frame): Print frame architecture
2680 when printing on an MI output.
2681
2682 2018-08-27 Tom Tromey <tom@tromey.com>
2683
2684 PR build/23087:
2685 * configure: Rebuild.
2686 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
2687
2688 2018-08-27 Tom Tromey <tom@tromey.com>
2689
2690 * aarch64-linux-tdep.c
2691 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
2692 casts to int.
2693
2694 2018-08-27 Tom Tromey <tom@tromey.com>
2695
2696 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
2697 unsigned.
2698 (ppc64_standard_linkage1, ppc64_standard_linkage2)
2699 (ppc64_standard_linkage3, ppc64_standard_linkage4)
2700 (ppc64_standard_linkage5, ppc64_standard_linkage6)
2701 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
2702 unsigned.
2703
2704 2018-08-27 Tom Tromey <tom@tromey.com>
2705
2706 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
2707 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
2708
2709 2018-08-27 Tom Tromey <tom@tromey.com>
2710
2711 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
2712 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
2713 ULONGEST_MAX.
2714 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
2715 ULONGEST_MAX.
2716 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
2717 ULONGEST_MAX.
2718 * sparc-linux-tdep.c (sparc32_linux_sigframe)
2719 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
2720 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
2721 ULONGEST_MAX.
2722 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
2723 (ppc64_linux_sigaction_tramp_frame)
2724 (ppc32_linux_sighandler_tramp_frame)
2725 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
2726 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
2727 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
2728 * mn10300-linux-tdep.c (am33_linux_sigframe)
2729 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
2730 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
2731 * mips-linux-tdep.c (mips_linux_o32_sigframe)
2732 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
2733 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
2734 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
2735 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
2736 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
2737 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
2738 * microblaze-linux-tdep.c
2739 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
2740 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
2741 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
2742 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
2743 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
2744 * common/common-types.h (ULONGEST_MAX): New define.
2745 (CORE_ADDR_MAX): Fix formatting.
2746 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
2747 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
2748 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
2749 (arm_linux_rt_sigreturn_tramp_frame)
2750 (arm_eabi_linux_sigreturn_tramp_frame)
2751 (arm_eabi_linux_rt_sigreturn_tramp_frame)
2752 (thumb2_eabi_linux_sigreturn_tramp_frame)
2753 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
2754 (arm_linux_restart_syscall_tramp_frame)
2755 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
2756 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
2757 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
2758 ULONGEST_MAX.
2759 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
2760
2761 2018-08-27 Tom Tromey <tom@tromey.com>
2762
2763 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
2764 CORE_ADDR_MAX.
2765 * mips-tdep.c (mips_deal_with_atomic_sequence)
2766 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
2767 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
2768 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
2769 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
2770 CORE_ADDR_MAX.
2771 * aarch64-tdep.c (aarch64_software_single_step): Use
2772 CORE_ADDR_MAX.
2773
2774 2018-08-27 Tom Tromey <tom@tromey.com>
2775
2776 * linespec.c (complete_linespec_component): Add cast to "char".
2777 * completer.c (completion_tracker::build_completion_result): Add
2778 cast to "char".
2779
2780 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2781
2782 * solist.h (struct solist, struct target_so_ops): Fix
2783 indentation.
2784
2785 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2786
2787 * ada-tasks.c (ada_task_info_s): Remove typedef.
2788 (DEF_VEC_O(ada_task_info_s)): Remove.
2789 (struct ada_tasks_inferior_data): Initialize fields.
2790 <task_list>: Make an std::vector.
2791 (get_ada_tasks_inferior_data): Allocate with new.
2792 (ada_get_task_number): Adjust.
2793 (get_task_number_from_id): Likewise.
2794 (valid_task_id): Likewise.
2795 (ada_get_task_info_from_ptid): Likewise.
2796 (iterate_over_live_ada_tasks): Likewise.
2797 (add_ada_task): Likewise.
2798 (read_known_tasks): Likewise.
2799 (ada_build_task_list): Likewise.
2800 (print_ada_task_info): Likewise.
2801 (info_task): Likewise.
2802 (task_command_1): Likewise.
2803
2804 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2805
2806 * ada-lang.c (add_angle_brackets): Return std::string.
2807
2808 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
2809
2810 * python/py-threadevent.c (py_get_event_thread): Initialize
2811 pythread.
2812
2813 2018-08-24 Pedro Alves <palves@redhat.com>
2814
2815 * python/py-bpevent.c (create_breakpoint_event_object): Use
2816 copy-initialization.
2817 * python/py-continueevent.c (emit_continue_event): Use
2818 copy-initialization.
2819 * python/py-exitedevent.c (create_exited_event_object): Return a
2820 gdbpy_ref<>.
2821 (emit_exited_event): Use copy-initialization.
2822 * python/py-inferior.c (python_new_inferior)
2823 (python_inferior_deleted, add_thread_object): Use
2824 copy-initialization.
2825 * python/py-infevents.c (create_inferior_call_event_object)
2826 (create_register_changed_event_object)
2827 (create_memory_changed_event_object): Return a gdbpy_ref<>.
2828 (emit_inferior_call_event, emit_memory_changed_event)
2829 (emit_register_changed_event): Use copy-initialization.
2830 * python/py-newobjfileevent.c (create_new_objfile_event_object):
2831 Return a gdbpy_ref<>.
2832 (emit_new_objfile_event): Use copy-initialization.
2833 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
2834 (emit_clear_objfiles_event): Use copy-initialization.
2835 * python/py-signalevent.c (create_signal_event_object): Use
2836 copy-initialization.
2837 * python/py-threadevent.c (create_thread_event_object): Use
2838 copy-initialization.
2839
2840 2018-08-24 Pedro Alves <palves@redhat.com>
2841 Simon Marchi <simon.marchi@ericsson.com>
2842
2843 PR gdb/23379
2844 * python/py-continueevent.c: Include "gdbthread.h".
2845 (create_continue_event_object): Add intro comment. Add 'ptid'
2846 parameter. Use it to find thread to pass to
2847 create_thread_event_object.
2848 (emit_continue_event): Pass PTID down to
2849 create_continue_event_object.
2850 * python/py-event.h (py_get_event_thread): Declare.
2851 (create_thread_event_object): Remove default from 'thread'
2852 parameter.
2853 * python/py-stopevent.c (create_stop_event_object): Use
2854 py_get_event_thread.
2855 * python/py-threadevent.c (get_event_thread): Rename to ...
2856 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
2857 and use it to find the thread.
2858 (create_thread_event_object): Assert that THREAD isn't null.
2859 Don't find the event thread here.
2860
2861 2018-08-23 Kevin Buettner <kevinb@redhat.com>
2862
2863 * block.h (blockrange, blockranges): New struct declarations.
2864 (struct block): Add new field named `ranges'.
2865 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
2866 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
2867 macros for accessing ranges in struct block.
2868 (make_blockranges): New declaration.
2869 block.c (make_blockranges): New function.
2870 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
2871 for block.
2872 * symtab.h (find_pc_partial_function): Add new parameter `block'.
2873 * blockframe.c (cache_pc_function_block): New static global.
2874 (clear_pc_function_cache): Clear cache_pc_function_block.
2875 (find_pc_partial_function): Move comment to symtab.h. Add
2876 support for non-contiguous blocks.
2877 * cli/cli-cmds.c (block.h): Include.
2878 (print_disassembly): Handle printing of non-contiguous blocks.
2879 (disassemble_current_function): Likewise.
2880 (disassemble_command): Likewise.
2881
2882 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
2883 BLOCK_START.
2884 * blockframe.c (get_pc_function_start): Likewise.
2885 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
2886 (gcc_symbol_address): Likewise.
2887 * compile/compile-object-run.c (compile_object_run): Likewise.
2888 * compile/compile.c (get_expr_block_and_pc): Likewise.
2889 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
2890 (func_addr_to_tail_call_list): Likewise.
2891 * findvar.c (default_read_var_value): Likewise.
2892 * inline-frame.c (inline_frame_this_id): Likewise.
2893 (skip-inline_frames): Likewise.
2894 * infcmd.c (until_next_command): Likewise.
2895 * linespec.c (convert_linespec_to_sals): Likewise.
2896 * parse.c (parse_exp_in_context_1): Likewise.
2897 * printcmd.c (build_address_symbolic): likewise.
2898 (info_address_command): Likewise.
2899 symtab.c (find_function_start_sal): Likewise.
2900 (skip_prologue_sal): Likewise.
2901 (find_function_alias_target): Likewise.
2902 (find_gnu_ifunc): Likewise.
2903 * stack.c (find_frame_funname): Likewise.
2904 * symtab.c (fixup_symbol_section): Likewise.
2905 (find_function_start_sal): Likewise.
2906 (skip_prologue_sal): Likewsie.
2907 (find_function_alias_target): Likewise.
2908 (find_gnu_ifunc): Likewise.
2909 * tracepoint.c (info_scope_command): Likewise.
2910 * value.c (value_fn_field): Likewise.
2911
2912 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
2913 in place of find_pc_partial_function.
2914 * blockframe.c (find_function_entry_range_from_pc): New function.
2915 * symtab.h (find_function_entry_range_from_pc): Declare and document.
2916 * objfiles.c (objfile_relocate1): Relocate start and end addresses
2917 for each range in a block.
2918
2919
2920 2018-08-23 Xavier Roirand <roirand@adacore.com>
2921
2922 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
2923 incrementation.
2924
2925 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2926
2927 * solib-svr4.c (read_program_headers_from_bfd): Return
2928 gdb::optional<gdb::byte_vector>.
2929 (svr4_exec_displacement): Adjust.
2930
2931 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2932
2933 * solib-svr4.c (read_program_header): Return
2934 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
2935 (find_program_interpreter): Return
2936 gdb::optional<gdb::byte_vector>.
2937 (scan_dyntag_auxv): Adjust.
2938 (enable_break): Adjust.
2939 (svr4_exec_displacement): Adjust.
2940
2941 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2942
2943 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
2944 * inf-child.c (inf_child_target::terminal_save_inferior): New.
2945
2946 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2947
2948 * guile/scm-string.c (gdbscm_scm_from_printf): Use
2949 string_vprintf.
2950 * guile/scm-utils.c (gdbscm_printf): Likewise.
2951 * serial.c (serial_printf): Likewise.
2952 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
2953
2954 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
2955
2956 * stack.c (print_frame): Print frame architecture when printing on
2957 an MI output.
2958 * NEWS: Mention new "arch" attribute in frame output.
2959
2960 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2961
2962 * arch/aarch64.h (aarch64_regnum): Update comment.
2963
2964 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2965
2966 * NEWS: Add SVE to 8.2 section.
2967
2968 2018-08-21 Pedro Alves <palves@redhat.com>
2969
2970 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2971 out from gdbscm_parse_function_args.
2972 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2973 gdbscm_parse_function_args_1.
2974
2975 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2976
2977 PR gdb/17816
2978 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2979 operator.
2980
2981 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2982
2983 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2984
2985 2018-08-19 Michael Spang <spang@google.com>
2986
2987 PR gdb/11786
2988 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2989 for PT_TLS segments.
2990
2991 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2992
2993 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2994 dwarf_variable_value.
2995 * dwarf2-frame.c (class dwarf_expr_executor):
2996 Add override for dwarf_variable_value.
2997 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2998 (class symbol_needs_eval_context): Likewise.
2999 (indirect_synthetic_pointer): Add forward declaration.
3000 (sect_variable_value): New function.
3001 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
3002 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
3003 for DW_OP_GNU_variable_value.
3004
3005 2018-08-16 Tom Tromey <tom@tromey.com>
3006
3007 * top.c (read_command_file): Update.
3008 (command_line_input): Remove "repeat" argument.
3009 * ada-lang.c (get_selections): Update.
3010 * linespec.c (decode_line_2): Update.
3011 * defs.h (command_line_input): Remove argument.
3012 * cli/cli-script.c (read_next_line): Update.
3013 * python/py-gdb-readline.c: Update.
3014
3015 2018-08-17 Tom Tromey <tom@tromey.com>
3016
3017 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
3018 command_line_input.
3019
3020 2018-08-15 Tom Tromey <tom@tromey.com>
3021
3022 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
3023
3024 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
3025
3026 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
3027 If used, use find_pc_partial_function to find address range
3028 to disassemble.
3029 * mi/mi-main.c (mi_cmd_list_features): Report
3030 "data-disassemble-a-option" feature.
3031 * NEWS: Mention new -data-disassemble option -a.
3032
3033 2018-08-13 Tom Tromey <tom@tromey.com>
3034
3035 * common/common-defs.h (_FORTIFY_SOURCE): Define.
3036
3037 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3038
3039 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
3040 (aarch64_linux_collect_sve_regset): Likewise.
3041 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
3042 * regcache.h (regcache_map_entry_size): New function.
3043
3044 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3045
3046 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
3047 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
3048 (SVE_HEADER_VL_LENGTH): Likewise.
3049 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
3050 (SVE_HEADER_FLAGS_LENGTH): Likewise.
3051 (SVE_HEADER_RESERVED_LENGTH): Likewise.
3052 (SVE_HEADER_SIZE_OFFSET): Likewise.
3053 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
3054 (SVE_HEADER_VL_OFFSET): Likewise.
3055 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
3056 (SVE_HEADER_FLAGS_OFFSET): Likewise.
3057 (SVE_HEADER_RESERVED_OFFSET): Likewise.
3058 (SVE_HEADER_SIZE): Likewise.
3059 (aarch64_linux_core_read_vq): Add function.
3060 (aarch64_linux_core_read_description): Check for SVE section.
3061
3062 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3063
3064 * aarch64-fbsd-tdep.c
3065 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
3066 collect_size.
3067 * aarch64-linux-tdep.c
3068 (aarch64_linux_iterate_over_regset_sections): Likewise.
3069 * alpha-linux-tdep.c
3070 (alpha_linux_iterate_over_regset_sections):
3071 * alpha-nbsd-tdep.c
3072 (alphanbsd_iterate_over_regset_sections): Likewise.
3073 * amd64-fbsd-tdep.c
3074 (amd64fbsd_iterate_over_regset_sections): Likewise.
3075 * amd64-linux-tdep.c
3076 (amd64_linux_iterate_over_regset_sections): Likewise.
3077 * arm-bsd-tdep.c
3078 (armbsd_iterate_over_regset_sections): Likewise.
3079 * arm-fbsd-tdep.c
3080 (arm_fbsd_iterate_over_regset_sections): Likewise.
3081 * arm-linux-tdep.c
3082 (arm_linux_iterate_over_regset_sections): Likewise.
3083 * corelow.c (get_core_registers_cb): Likewise.
3084 (core_target::fetch_registers): Likewise.
3085 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
3086 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
3087 * gdbarch.h (void): Regenerate.
3088 * gdbarch.sh: Add supply_size and collect_size.
3089 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
3090 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
3091 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
3092 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
3093 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
3094 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
3095 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
3096 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
3097 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
3098 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
3099 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
3100 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
3101 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
3102 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
3103 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
3104 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
3105 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
3106 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
3107 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
3108 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
3109 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
3110 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
3111 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
3112 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
3113 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
3114 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
3115 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
3116 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
3117 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
3118 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
3119
3120 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
3121
3122 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
3123 with string_printf.
3124
3125 2018-08-10 Keith Seitz <keiths@redhat.com>
3126
3127 * compile/compile-c-support.c (add_code_header, add_code_footer):
3128 Move into policy class.
3129 (c_push_user_expression, pop_user_expression_nop)
3130 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
3131 (compile_program): New host class.
3132 (c_compile_program): New typedef.
3133 (c_compute_porgram): Use c_compile_program.
3134
3135 2018-08-10 Keith Seitz <keiths@redhat.com>
3136
3137 * compile/compile-internal.h (compile_instance::~compile_instance):
3138 Remove calls to htab_delete.
3139 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
3140 * compile.c (compile_instance::compile_instance): Initialize
3141 htab unique pointers.
3142 (compile_instance::get_cached_type, compile_instance::insert_type)
3143 (compile_instance::error_symbol_once): Update for unique_ptr.
3144
3145 2018-08-10 Keith Seitz <keiths@redhat.com>
3146
3147 * compile/compile-c-symbols.c (struct symbol_error)
3148 (hash_symbol_error, eq_symbol_error, del_symbol_error)
3149 (compile_instance::insert_symbol_error)
3150 (compile_instance::error_symbol_once): Move to ...
3151 * compile/compile.c: ... here.
3152
3153 2018-08-10 Keith Seitz <keiths@redhat.com>
3154
3155 * compile/compile-c-support.c (c_get_compile_context): Use `new'
3156 instead of `new_compile_instance'.
3157 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
3158 Update description.
3159 If the symbol error map is not initialized, create it.
3160 (generate_c_for_for_one_symbol): Do not check/initialize
3161 the symbol error map.
3162 * compile/compile-c-types.c (compile_c_instance): Make a class.
3163 Update all callers.
3164 (compile_instance::compile_instance): Initialize the type cache.
3165 (get_cached_type): New function.
3166 (insert_type): Update description.
3167 (compile_c_instance::m_default_cflags): Define.
3168 (convert_type): Update description. Use get_cached_type.
3169 (delete_instance): Moved to destructor.
3170 (new_compile_instance): Moved to constructor.
3171 * compile/compile-c.h (compile_c_instance): Make class inheriting
3172 from compile_instance.
3173 <base>: Remove field.
3174 <type_map, symbol_err_map>: Move to base class.
3175 <c_plugin>: Rename to `m_plugin' and remove pointer type.
3176 * compile/compile-internal.h (compile_instance): Make class.
3177 <type_map_t, symbol_err_map_t>: Define.
3178 <fe>: Rename to `m_gcc_fe'.
3179 <scope, block, gcc_target_options>: Add `m_' prefix.
3180 <m_type_map, m_symbol_err_map>: New fields, moved from
3181 compile_c_instance.
3182 <destroy>: Remove.
3183 (convert_type, new_compile_instance): Remove.
3184 * compile/compile.c (cleanup_compile_instance): Remove.
3185 (compile_to_object): Use unique_ptr to eliminate cleanups.
3186 (compile_instance::set_print_callback, compile_instance::version)
3187 (compile_instance::set_verbose)
3188 (compile_instance::set_driver_filename)
3189 (compile_instance::set_triplet_regexp)
3190 (compile_instance::set_arguments)
3191 (compile_instance::set_source_file)
3192 (compile_instance::compile): Define.
3193
3194 2018-08-10 Keith Seitz <keiths@redhat.com>
3195
3196 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
3197 * compile/compile-c-types.c: Define GCC_METHODN macros and include
3198 gcc-c-fe.def to define C plugin.
3199 (delete_instance): Delete `c_plugin'.
3200 (new_compile_instance): Initialize `c_plugin'.
3201 * compile/compile-c.h: Include gcc_c_plugin.h.
3202 (struct compile_c_instance) <c_plugin>: New member.
3203 * gcc-c-plugin.h: New file.
3204 Update all callers with API change.
3205
3206 2018-08-10 Keith Seitz <keiths@redhat.com>
3207
3208 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
3209 (HFILES_NO_SRCDIR): ... to here.
3210 Add compile-internal.h and compile-c.h.
3211 * compile/compile-c-support.c: Include compile-c.h.
3212 * compile/compile-c-symbols.c: Include compile-c.h.
3213 (generate_c_for_variable_locations): Update comment.
3214 * compile/compile-c-types.c: Include compile-c.h.
3215 * compile/compile-c.h: New file -- moved C language declarations
3216 from other files here.
3217 * compile/compile-internal.h: Do not include hashtab.h or
3218 common/enum-flags.h.
3219 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
3220 (gcc_convert_symbol, gcc_symbol_address)
3221 (generate_c_for_variable_locations, c_get_mode_for_size)
3222 (c_get_range_decl_name): Definitions moved to compile-c.h.
3223 * compile/compile-loc2c.c: Include compile-c.h.
3224
3225 2018-08-10 Keith Seitz <keiths@redhat.com>
3226
3227 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
3228 (c_symbol_substitution_name): ... this.
3229 Update all callers.
3230
3231 2018-08-10 Keith Seitz <keiths@redhat.com>
3232
3233 * compile/compile-c-support.c (c_compute_program): Use
3234 unique_xmalloc_ptr to eliminate cleanup.
3235 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
3236 Return a unique_xmalloc_ptr and eliminate cleanup.
3237 * compile/compile-internal.h (generate_c_for_variable_locations):
3238 Return unique_xmalloc_ptr and update description.
3239
3240 2018-08-10 Alan Hayward <alan.hayward@arm.com>
3241
3242 * corelow.c (core_target::get_core_register_section): Rename
3243 min_size to section_min_size.
3244
3245 2018-08-09 Jim Wilson <jimw@sifive.com>
3246
3247 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
3248 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
3249 * NEWS: Mention new GNU/Linux RISC-V target.
3250 * configure.host: Add riscv*-*-linux*.
3251 * configure.nat: Add riscv*.
3252 * configure.tgt: Add riscv*-*-linux*.
3253 * riscv-linux-nat.c: New file.
3254 * riscv-linux-tdep.c: New file.
3255
3256 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3257
3258 * infrun.c (resume): Make static, add forward declaration.
3259 (proceed): Update header comment.
3260 * infrun.h (resume): Delete declaration.
3261
3262 2018-08-09 Tom Tromey <tom@tromey.com>
3263
3264 * riscv-tdep.h: Minor formatting fixes.
3265
3266 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
3267
3268 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
3269 * dwarf-index-cache.c (create_dir_and_check): Likewise.
3270 (test_mkdir_recursive): Likewise.
3271 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
3272
3273 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3274
3275 * valarith.c (value_subscripted_rvalue): If an array is not in
3276 memory, and we don't know the upper bound, then we can't know that
3277 the requested element exists or not.
3278
3279 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
3280
3281 * target.c (str_comma_list_concat_elem): Fix typo in comment.
3282 (target_options_to_string): Add comment.
3283
3284 2018-08-08 Tom Tromey <tom@tromey.com>
3285
3286 * unittests/scoped_mmap-selftests.c: Check result of "write".
3287
3288 2018-08-08 Jim Wilson <jimw@sifive.com>
3289
3290 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
3291 (decode_register_index_short): New.
3292 (decode_j_type_insn, decode_cj_type_insn): New.
3293 (decode_b_type_insn, decode_cb_type_insn): New.
3294 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
3295 local xlen. Check xlen when decoding ambiguous compressed insns. In
3296 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
3297 is_c_sw_insn instead of is_sw_insn.
3298 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
3299 (riscv_software_single_step): New.
3300 * riscv-tdep.h (riscv_software_single_step): Declare.
3301
3302 * riscv-tdep.c (riscv_isa_xlen): Drop static.
3303 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
3304
3305 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
3306
3307 PR gdb/18050:
3308 * target.c (dispose_inferior): Don't dispose of inferiors that are
3309 already killed.
3310
3311 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
3312
3313 * remote.c (remote_target::download_tracepoint): Change char* to
3314 const char*.
3315
3316 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
3317
3318 * target.h (target_options_to_string): Return an std::string.
3319 * target.c (str_comma_list_concat_elem): Return void, use
3320 std::string.
3321 (do_option): Likewise.
3322 (target_options_to_string): Return an std::string.
3323 * linux-nat.c (linux_nat_target::wait): Adjust.
3324 * target-debug.h (target_debug_print_options): Adjust.
3325
3326 2018-08-07 Tom Tromey <tom@tromey.com>
3327
3328 * Makefile.in (CPPFLAGS): New variable.
3329 (INTERNAL_CPPFLAGS): Use it.
3330
3331 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3332
3333 * NEWS: Mention the index cache.
3334
3335 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3336
3337 * common/pathstuff.h (get_standard_cache_dir): New.
3338 * common/pathstuff.c (get_standard_cache_dir): New.
3339 * build-id.h (build_id_to_string): New.
3340 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
3341 DEBUG_STR_SUFFIX): Move to here.
3342 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
3343 DEBUG_STR_SUFFIX): Move from there.
3344 (write_psymtabs_to_index): Make non-static, add basename
3345 parameter. Write to temporary files, rename when done.
3346 (save_gdb_index_command): Adjust call to
3347 write_psymtabs_to_index.
3348 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
3349 field.
3350 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
3351 (get_gdb_index_contents_from_cache): New.
3352 (get_gdb_index_contents_from_cache_dwz): New.
3353 (dwarf2_initialize_objfile): Read index from cache.
3354 (dwarf2_build_psymtabs): Save to index.
3355 * dwarf-index-cache.h: New file.
3356 * dwarf-index-cache.c: New file.
3357 * dwarf-index-write.h: New file.
3358
3359 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3360
3361 * gnulib/aclocal.m4: Re-generate.
3362 * gnulib/config.in: Re-generate.
3363 * gnulib/configure: Re-generate.
3364 * gnulib/import/Makefile.am: Re-generate.
3365 * gnulib/import/Makefile.in: Re-generate.
3366 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3367 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3368 * gnulib/import/m4/mkdir.m4: New file.
3369 * gnulib/import/mkdir.c: New file.
3370 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
3371 module.
3372
3373 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3374
3375 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
3376 * common/scoped_mmap.c: New file.
3377 * common/scoped_mmap.h (destroy): New method.
3378 (~scoped_mmap, reset): Use destroy.
3379 (scoped_mmap): New move constructor.
3380 (mmap_file): New declaration.
3381 * unittests/scoped_mmap-selftests.c (test_normal,
3382 test_invalid_filename, run_tests): New functions.
3383 (_initialize_scoped_mmap_selftests): Register selftest.
3384
3385 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3386
3387 * dwarf2read.c (read_gdb_index_from_section): Rename to...
3388 (read_gdb_index_from_buffer): ... this. Remove section
3389 parameter, add buffer parameter.
3390 (get_gdb_index_contents_ftype,
3391 get_gdb_index_contents_dwz_ftype): New typedefs.
3392 (dwarf2_read_gdb_index): Add callback parameters to get the
3393 index contents.
3394 (get_gdb_index_contents_from_section): New.
3395 (dwarf2_initialize_objfile): Update call to
3396 dwarf2_read_gdb_index.
3397
3398 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3399
3400 * common/filestuff.h (gdb_fopen_cloexec): New overload.
3401 (gdb_open_cloexec): Likewise.
3402 * nat/linux-osdata.c (command_from_pid): Use string_printf.
3403 (commandline_from_pid): Likewise.
3404 (linux_xfer_osdata_threads): Likewise.
3405 (linux_xfer_osdata_fds): Likewise.
3406 * ada-lang.c (is_package_name): Likewise.
3407 * auxv.c (procfs_xfer_auxv): Likewise.
3408 * breakpoint.c (print_one_breakpoint_location): Use
3409 uiout::field_fmt.
3410 (print_one_catch_solib): Use string_printf.
3411 * coff-pe-read.c (add_pe_exported_sym): Likewise.
3412 (add_pe_forwarded_sym): Likewise.
3413 * dwarf2read.c (create_type_unit_group): Likewise.
3414 (build_error_marker_type): Likewise.
3415 * infcall.c (get_function_name): Likewise.
3416 * valprint.c (print_converted_chars_to_obstack): Likewise.
3417 * xtensa-tdep.c (xtensa_register_type): Likewise.
3418
3419 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
3420
3421 * remote.c (remote_target::download_tracepoint): Fix format
3422 string errors.
3423
3424 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3425
3426 * tracefile.c: Include common/byte-vector.h.
3427 (trace_save): Change type of buf to gdb::byte_vector. Initialize
3428 with trace_regblock_size if needed. Update uses of buf.
3429
3430 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3431
3432 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
3433 std::vector<unsigned char>.
3434 * tracepoint.c (collection_list::collection_list): Remove
3435 m_regs_mask initializer from initializer list. Resize
3436 m_regs_mask using the largest remote register number.
3437 (collection_list::add_remote_register): Remove size check on
3438 m_regs_mask. Use at to access element.
3439 (collection_list::stringify): Change type of temp_buf to
3440 gdb::char_vector. Update uses of temp_buf. Resize if needed to
3441 stringify the register mask. Use pack_hex_byte for the register
3442 mask.
3443
3444 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3445
3446 * tracepoint.h (class collection_list) <add_register>: Remove.
3447 <add_remote_register, add_ax_registers, add_local_register>:
3448 Declare.
3449 <add_memrange>: Add scope parameter.
3450 * tracepoint.c (encode_actions_1): Likewise.
3451 (collection_list::add_register): Rename to ...
3452 (collection_list::add_remote_register): ... this. Update
3453 comment.
3454 (collection_list::add_ax_registers, add_local_register): New
3455 methods.
3456 (collection_list::add_memrange): Add scope parameter. Call
3457 add_local_register instead of add_register.
3458 (finalize_tracepoint_aexpr): New function.
3459 (collection_list::collect_symbol): Update calls to add_memrange.
3460 Call add_local_register instead of add_register. Call
3461 add_ax_registers. Call finalize_tracepoint_aexpr.
3462 (encode_actions_1): Get remote regnos for $reg action. Call
3463 add_remote_register, add_ax_registers, and add_local_register.
3464 Update call to add_memrange. Call finalize_tracepoint_aexpr.
3465 (validate_actionline): Call finalize_tracepoint_aexpr.
3466
3467 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3468
3469 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
3470 Replace array buf with gdb::char_vector buf, of size
3471 get_remote_packet_size (). Replace references to buf and
3472 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
3473 and xsnprintf with snprintf. Raise errors if the buffer is too
3474 small.
3475
3476 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3477
3478 * remote.c (remote_target::download_tracepoint): Fix the has_more
3479 predicate in the QTDP action list iteration.
3480
3481 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3482
3483 * remote.c (remote_target::download_tracepoint): Fix indentation
3484 in for block.
3485
3486 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3487
3488 * proc-api.c (_initialize_proc_api): Remove c, unused.
3489 * procfs.c (procfs_init_inferior): Remove signals, unused.
3490 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
3491 unused.
3492
3493 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
3494 Andrew Burgess <andrew.burgess@embecosm.com>
3495
3496 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
3497 'W_STOPCODE (0)' as this could be ambiguous.
3498
3499 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
3500
3501 * ser-tcp.c (net_open): Fix thinko when deciding whether to
3502 disable TCP's Nagle algorithm (use "ai_protocol" instead of
3503 "ai_socktype").
3504
3505 2018-08-02 Tom Tromey <tom@tromey.com>
3506
3507 PR symtab/16842.
3508 * dwarf2read.c (read_func_scope): Set symtab on template parameter
3509 symbols.
3510 (process_structure_scope): Likewise.
3511
3512 2018-08-02 Xavier Roirand <roirand@adacore.com>
3513
3514 PR gdb/22629:
3515 * darwin-nat.c (darwin_kill_inferior): Fix handling of
3516 kill inferior.
3517
3518 2018-08-02 Tom Tromey <tom@tromey.com>
3519
3520 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
3521 (darwin_suspend_inferior, darwin_resume_inferior)
3522 (darwin_decode_notify_message, darwin_resume_inferior_threads)
3523 (darwin_check_new_threads): Check result of get_darwin_inferior.
3524
3525 2018-07-31 Joel Brobecker <brobecker@adacore.com>
3526
3527 GDB 8.1.1 released.
3528
3529 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
3530
3531 * varobj.c (varobj_get_path_expr_parent): Report an error if
3532 parent is a dynamic varobj.
3533
3534 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3535
3536 * gnulib/aclocal.m4: Re-generate.
3537 * gnulib/config.in: Re-generate.
3538 * gnulib/configure: Re-generate.
3539 * gnulib/import/Makefile.in: Re-generate.
3540 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3541 * gnulib/import/m4/onceonly.m4: Re-generate.
3542
3543 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3544
3545 * target-descriptions.c (struct xml_test_tdesc): New.
3546 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
3547 (record_xml_tdesc): Update.
3548 (maintenance_check_xml_descriptions): Update.
3549 * target-descriptions.h (record_xml_tdesc): Update comment.
3550
3551 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
3552
3553 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
3554 checking array bounds are defined.
3555
3556 2018-07-30 Tom Tromey <tom@tromey.com>
3557
3558 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
3559 irreflexivity violation.
3560
3561 2018-07-30 Tom Tromey <tom@tromey.com>
3562
3563 * cli/cli-decode.c (lookup_cmd): Remove lint code.
3564 * value.c (unpack_long): Remove lint code.
3565 * valops.c (value_ind): Remove lint code.
3566 * valarith.c (value_x_binop, value_x_unop, value_equal)
3567 (value_pos): Remove lint code.
3568
3569 2018-07-28 Tom de Vries <tdevries@suse.de>
3570
3571 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
3572 with undefined upper bound as <optimized out>.
3573
3574 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
3575
3576 * gcore.in: Rename variable "name" to "prefix". Expand
3577 "usage" text.
3578
3579 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
3580
3581 * windows-nat.c (windows_nat_target::create_inferior): Update to
3582 call close() in global namespace.
3583
3584 2018-07-26 Tom Tromey <tom@tromey.com>
3585
3586 * dwarf-index-write.c (add_address_entry): Don't add objfile
3587 offsets.
3588 * dbxread.c (find_stab_function): Rename from
3589 find_stab_function_addr. Return a bound_minimal_symbol.
3590 (read_dbx_symtab): Use raw_text_low, raw_text_high.
3591 Don't add objfile offsets.
3592 (end_psymtab): Use raw_text_low, raw_text_high,
3593 MSYMBOL_VALUE_RAW_ADDRESS.
3594 (read_ofile_symtab): Update.
3595 (process_one_symbol): Update.
3596 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
3597 offsets.
3598 (dw2_relocate): Remove.
3599 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
3600 searching addrmap.
3601 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
3602 Update.
3603 (process_psymtab_comp_unit_reader, add_partial_symbol)
3604 (add_partial_subprogram, dwarf2_ranges_read): Update.
3605 (load_partial_dies): Update.
3606 (add_address_entry): Don't add objfile offsets.
3607 (dwarf2_build_include_psymtabs): Update.
3608 (create_addrmap_from_aranges): Don't add objfile offsets.
3609 (dw2_find_pc_sect_compunit_symtab): Update.
3610 * mdebugread.c (parse_symbol): Don't add objfile offsets.
3611 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
3612 Update.
3613 (parse_partial_symbols): Don't add objfile offsets. Use
3614 raw_text_low, raw_text_high. Update.
3615 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
3616 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
3617 or call 'relocate' quick function. Clear psymbol_map.
3618 * psympriv.h (struct partial_symbol) <address>: Add section
3619 offset.
3620 <set_unrelocated_address>: Rename from set_address.
3621 <raw_text_low, raw_text_high>: New methods.
3622 <text_low, text_high>: Add objfile parameter.
3623 (add_psymbol_to_bcache): Add 'section' parameter. Call
3624 set_unrelocated_address.
3625 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3626 (find_pc_psymbol): Update.
3627 (fixup_psymbol_section, relocate_psymtabs): Remove.
3628 (dump_psymtab, psym_functions): Update.
3629 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
3630 parameter.
3631 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
3632 (start_psymtab_common): Update.
3633 * symfile-debug.c (debug_qf_relocate): Remove.
3634 (debug_sym_quick_functions): Update.
3635 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
3636 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
3637 Update.
3638
3639 2018-07-26 Tom Tromey <tromey@redhat.com>
3640
3641 * dbxread.c (end_psymtab): Use text_high_valid and
3642 text_low_valid.
3643 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
3644 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
3645 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
3646 Update comment.
3647 <text_low_valid, text_high_valid>: New fields.
3648 <set_text_low, set_text_high>: Update.
3649 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
3650
3651 2018-07-26 Tom Tromey <tom@tromey.com>
3652
3653 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
3654 Update.
3655 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
3656 textlow and texthigh fields.
3657 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
3658 Update.
3659 * mdebugread.c (parse_lines, parse_partial_symbols)
3660 (psymtab_to_symtab_1): Update.
3661 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
3662 Rename fields. Update comment. Now private.
3663 <text_low, text_high, set_text_low, set_text_high>: New methods.
3664 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3665 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
3666 (start_psymtab_common, maintenance_info_psymtabs)
3667 (maintenance_check_psymtabs): Update.
3668 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
3669 texthigh fields.
3670 (scan_xcoff_symtab): Update.
3671
3672 2018-07-26 Tom Tromey <tromey@redhat.com>
3673
3674 * psympriv.h (struct partial_symbol) <unrelocated_address,
3675 address, set_address>: New methods.
3676 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
3677 (fixup_psymbol_section, relocate_psymtabs): Update.
3678 (print_partial_symbols): Add 'objfile' parameter. Update.
3679 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
3680 Update.
3681
3682 2018-07-26 Tom Tromey <tom@tromey.com>
3683
3684 * dwarf-index-write.c (write_psymbols, debug_names::insert)
3685 (debug_names::write_psymbols): Update.
3686 * psympriv.h (struct partial_symbol): Derive from
3687 general_symbol_info.
3688 <obj_section>: New method.
3689 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
3690 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
3691 (find_pc_sect_psymbol, fixup_psymbol_section)
3692 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
3693 (print_partial_symbols, recursively_search_psymtabs)
3694 (compare_psymbols, psymbol_hash, psymbol_compare)
3695 (add_psymbol_to_bcache, maintenance_check_psymtabs)
3696 (psymbol_name_matches, psym_fill_psymbol_map): Update.
3697
3698 2018-07-26 Tom Tromey <tromey@redhat.com>
3699
3700 * dbxread.c (end_psymtab): Remove dead code.
3701
3702 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
3703
3704 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
3705 DWARF unwinders are disabled.
3706 * dwarf2-frame.c: Add dwarf2read.h include.
3707 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
3708 disabled.
3709 (dwarf2_frame_unwinders_enabled_p): Define.
3710 (show_dwarf_unwinders_enabled_p): New function.
3711 (_initialize_dwarf2_frame): Register switch to control DWARF
3712 unwinder use.
3713 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
3714 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
3715 (show_dwarf_cmdlist): Remove static keyword.
3716 * dwarf2read.h (set_dwarf_cmdlist): Declare.
3717 (show_dwarf_cmdlist): Declare.
3718 * NEWS: Document new feature.
3719
3720 2018-07-26 Tom de Vries <tdevries@suse.de>
3721
3722 PR breakpoints/23366
3723 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
3724
3725 2018-07-26 Tom de Vries <tdevries@suse.de>
3726
3727 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
3728 DW_AT_count can't be translated to a dynamic prop.
3729
3730 2018-07-25 Tom de Vries <tdevries@suse.de>
3731
3732 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
3733 try/catch.
3734
3735 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
3736
3737 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
3738
3739 2018-07-25 Joel Brobecker <brobecker@adacore.com>
3740
3741 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
3742
3743 2018-07-24 Keith Seitz <keiths@redhat.comt
3744
3745 PR symtab/23010
3746 * dwarf2read.c (dw2_add_symbol_to_list): New function.
3747 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
3748 instead of add_symbol_to_list.
3749 (read_file_scope): Call prepare_one_comp_unit before reading
3750 any other DIEs.
3751
3752 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
3753
3754 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
3755
3756 2018-07-24 Tom Tromey <tom@tromey.com>
3757
3758 * utils.c (malloc, realloc, free): Don't declare.
3759 * configure, config.in: Rebuild.
3760 * configure.ac: Don't check for declarations of free, malloc, or
3761 realloc.
3762
3763 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3764
3765 * aarch64-linux-nat.c
3766 (aarch64_linux_nat_target::stopped_data_address): Remove unused
3767 variable.
3768 * arm-linux-nat.c (fetch_regs): Likewise.
3769 (store_regs): Likewise.
3770 (fetch_vfp_regs): Likewise.
3771 (store_vfp_regs): Likewise.
3772 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
3773 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
3774 (arm_linux_nat_target::insert_watchpoint): Likewise.
3775 (arm_linux_nat_target::remove_watchpoint): Likewise.
3776 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
3777 Likewise.
3778 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
3779 Likewise.
3780 * ppc-linux-nat.c (fetch_register): Likewise.
3781 (fetch_all_gp_regs): Likewise.
3782 (fetch_ppc_registers): Likewise.
3783 (store_all_gp_regs): Likewise.
3784 (store_ppc_registers): Likewise.
3785 (hwdebug_insert_point): Likewise.
3786 (can_use_watchpoint_cond_accel): Likewise.
3787 * remote-sim.c (gdb_os_write_stdout): Likewise.
3788
3789 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3790 Tom Tromey <tom@tromey.com>
3791
3792 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
3793 test for it.
3794 * configure: Rebuild.
3795
3796 2018-07-22 Tom Tromey <tom@tromey.com>
3797
3798 * regformats/regdat.sh: Define xmltarget_${name} inside
3799 #ifndef IN_PROCESS_AGENT.
3800
3801 2018-07-22 Tom Tromey <tom@tromey.com>
3802
3803 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
3804
3805 2018-07-22 Tom Tromey <tom@tromey.com>
3806
3807 * symfile.c (reread_symbols): Notify iter, not objfile.
3808
3809 2018-07-22 Tom Tromey <tom@tromey.com>
3810
3811 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
3812 Use arch_ops.
3813 (ravenscar_thread_target::prepare_to_store): Likewise.
3814
3815 2018-07-22 Tom Tromey <tom@tromey.com>
3816
3817 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
3818 unused variable. Call value_fetch_lazy when needed.
3819 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
3820 Remove unused variable. Call value_fetch_lazy when needed.
3821
3822 2018-07-22 Tom Tromey <tom@tromey.com>
3823
3824 * m32c-tdep.c (mark_dma): Return void.
3825 (make_regs): Remove unused declarations.
3826
3827 2018-07-22 Tom Tromey <tom@tromey.com>
3828
3829 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
3830 cmdscm_get_valid_command_smob_arg_unsafe for effect.
3831 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
3832 bkscm_get_valid_block_smob_arg_unsafe for effect.
3833
3834 2018-07-22 Tom Tromey <tom@tromey.com>
3835
3836 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
3837 value_type.
3838
3839 2018-07-22 Tom Tromey <tom@tromey.com>
3840
3841 * windows-nat.c (saved_context): Conditionally define.
3842 * remote.c (remote_target::remote_btrace_maybe_reopen):
3843 Conditionally declare "warned".
3844 * inflow.c (sigquit_ours): Conditionally define.
3845 (new_tty): Move "tty" declaration inside #if.
3846 * guile/guile.c (guile_datadir): Conditionally define.
3847 * charset.c (set_be_le_names): Move some declarations inside #if.
3848 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
3849 #if.
3850 (parse_xml_btrace_conf): Likewise.
3851
3852 2018-07-22 Tom Tromey <tom@tromey.com>
3853
3854 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
3855
3856 2018-07-22 Tom Tromey <tom@tromey.com>
3857
3858 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
3859 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
3860 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
3861 * buildsym-legacy.c (get_macro_table): Remove unused variable.
3862 * stack.c (frame_apply_level_command): Remove unused variable.
3863 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
3864 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
3865 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
3866 unused variable.
3867 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
3868 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
3869 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
3870 variable.
3871 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
3872 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
3873 variable.
3874 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
3875 Remove unused variable.
3876 * cli/cli-script.c (recurse_read_control_structure): Remove unused
3877 variable.
3878 * common/tdesc.c (print_xml_feature::visit): Remove unused
3879 variable.
3880 * compile/compile-object-load.c (store_regs): Remove unused
3881 variables.
3882 * complaints.c (clear_complaints): Remove unused variable.
3883 * corelow.c (core_target_open): Remove unused variable.
3884 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
3885 variable.
3886 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
3887 variable.
3888 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
3889 variable.
3890 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
3891 variable.
3892 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
3893 variable.
3894 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
3895 variable.
3896 * ia64-tdep.c (examine_prologue): Remove unused variable.
3897 * infcall.c (run_inferior_call): Remove unused variable.
3898 * inferior.c (exit_inferior): Remove unused variable.
3899 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
3900 * linespec.c (decode_line_2): Remove unused variable.
3901 * linux-nat.c (super_close): Remove.
3902 * linux-tdep.c (linux_info_proc): Remove unused variable.
3903 * mi/mi-main.c (mi_execute_command): Remove unused variable.
3904 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
3905 Remove unused variable.
3906 * parse.c (find_minsym_type_and_address): Remove unused variable.
3907 * printcmd.c (info_symbol_command, printf_floating): Remove unused
3908 variable.
3909 * python/py-breakpoint.c (bppy_set_commands): Remove unused
3910 variable.
3911 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
3912 variables.
3913 * record-btrace.c (record_btrace_target::store_registers): Remove
3914 unused variable.
3915 (cmd_show_record_btrace_cpu): Remove unused variable.
3916 * riscv-tdep.c (riscv_register_reggroup_p)
3917 (riscv_push_dummy_call, riscv_return_value): Remove unused
3918 variable.
3919 * rust-exp.y (literal): Remove unused variable.
3920 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
3921 unused variable.
3922 <STRUCTOP_ANONYMOUS>: Likewise.
3923 * s390-linux-tdep.c (s390_linux_init_abi_31)
3924 (s390_linux_init_abi_64): Remove unused variable.
3925 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
3926 (file_select_thread, net_windows_open, _initialize_ser_windows):
3927 Remove unused variables.
3928 * symtab.c (find_pc_sect_line): Remove unused variable.
3929 * target-memory.c (compute_garbled_blocks): Remove unused
3930 variable.
3931 (target_write_memory_blocks): Remove unused variable.
3932 * target.c (target_stack::unpush): Remove unused variables.
3933 * tracepoint.c (start_tracing, all_tracepoint_actions)
3934 (merge_uploaded_trace_state_variables)
3935 (print_one_static_tracepoint_marker): Remove unused variable.
3936 * unittests/basic_string_view/element_access/char/1.cc (test01):
3937 Remove unused variable.
3938 * windows-nat.c (windows_continue, windows_add_all_dlls)
3939 (do_initial_windows_stuff, windows_nat_target::create_inferior):
3940 Remove unused variables.
3941
3942 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
3943
3944 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
3945 attr_profile in HAVE_ELF.
3946 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
3947 HAVE_ELF.
3948
3949 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
3950
3951 * frame.c (frame_register_unwind): Change parameter name.
3952 (frame_unwind_register): Likewise.
3953 (frame_unwind_register_value): Likewise.
3954 (frame_unwind_register_signed): Likewise.
3955 (frame_unwind_register_unsigned): Likewise.
3956 * frame.h (frame_register_unwind): Likewise.
3957 (frame_unwind_register): Likewise.
3958 (frame_unwind_register_value): Likewise.
3959 (frame_unwind_register_signed): Likewise.
3960 (frame_unwind_register_unsigned): Likewise.
3961 (frame_unwind_arch): Likewise.
3962
3963 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3964
3965 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3966 ISA maintenance.
3967
3968 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3969
3970 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3971 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3972 hand.
3973
3974 2018-07-20 Keith Seitz <keiths@redhat.com>
3975
3976 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3977 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3978 m_compunit_symtab, m_language>: Add "m_" prefix.
3979 Update all uses.
3980 * buildsym.c: Update all uses.
3981
3982 2018-07-20 Tom Tromey <tom@tromey.com>
3983
3984 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3985 * buildsym.h (record_line_ftype): Remove typedef.
3986
3987 2018-07-20 Tom Tromey <tom@tromey.com>
3988
3989 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3990 (end_expandable_symtab): Likewise.
3991 (end_symtab_get_static_block): Likewise.
3992 (end_symtab_from_static_block): Likewise.
3993 * buildsym-legacy.c (augment_type_symtab): Remove.
3994 (end_expandable_symtab): Remove.
3995 (end_symtab_get_static_block): Remove.
3996 (end_symtab_from_static_block): Remove.
3997
3998 2018-07-20 Tom Tromey <tom@tromey.com>
3999
4000 * dwarf2read.c: Include buildsym.h.
4001 (struct dwarf2_cu) <builder>: New method.
4002 (fixup_go_packaging): Update.
4003 (process_full_comp_unit, process_full_type_unit): Update. Don't
4004 use scoped_free_pendings.
4005 (using_directives): Add "cu" parameter, remove "language".
4006 (read_import_statement, setup_type_unit_groups, )
4007 (read_func_scope, read_lexical_block_scope)
4008 (dwarf2_record_block_ranges, read_namespace): Update.
4009 (lnp_state_machine::lnp_state_machine): Add cu parameter.
4010 (lnp_state_machine::handle_end_sequence): Update.
4011 (class lnp_state_machine) <m_cu>: New member.
4012 <m_record_line_callback>: Remove.
4013 <m_currently_recording_lines>: New member.
4014 (lnp_state_machine::handle_set_file): Update.
4015 (noop_record_line): Remove.
4016 (dwarf_record_line_p): Add cu parameter.
4017 (dwarf_record_line_1, dwarf_finish_line): Likewise.
4018 (lnp_state_machine::record_line)
4019 (lnp_state_machine::lnp_state_machine)
4020 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4021 (dwarf_decode_lines): Update.
4022 (dwarf2_start_subfile): Add cu parameter.
4023 (dwarf2_start_symtab, new_symbol): Update.
4024 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
4025 Remove dwarf2_per_objfile parameter.
4026 (dwarf_decode_macros): Update.
4027
4028 2018-07-20 Tom Tromey <tom@tromey.com>
4029
4030 * stabsread.c (define_symbol): Update.
4031 * buildsym-legacy.h (get_buildsym_compunit): Declare.
4032 * dwarf2read.c (new_symbol): Update.
4033 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
4034 * cp-namespace.c: Include buildsym.h.
4035 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
4036 * buildsym-legacy.c (get_buildsym_compunit): New function.
4037
4038 2018-07-20 Tom Tromey <tom@tromey.com>
4039
4040 * xcoffread.c: Include buildsym-legacy.h.
4041 * windows-nat.c: Include buildsym-legacy.h.
4042 * stabsread.c: Include buildsym-legacy.h.
4043 * mdebugread.c: Include buildsym-legacy.h.
4044 * buildsym-legacy.h: New file.
4045 * buildsym-legacy.c: New file, from buildsym.c.
4046 * go32-nat.c: Include buildsym-legacy.h.
4047 * dwarf2read.c: Include buildsym-legacy.h.
4048 * dbxread.c: Include buildsym-legacy.h.
4049 * cp-namespace.c: Include buildsym-legacy.h.
4050 * coffread.c: Include buildsym-legacy.h.
4051 * buildsym.h: Move some contents to buildsym-legacy.h.
4052 * buildsym.c: Include buildsym-legacy.h. Move many functions to
4053 buildsym-legacy.c.
4054 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
4055
4056 2018-07-20 Tom Tromey <tom@tromey.com>
4057
4058 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
4059 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
4060 (buildsym_compunit::buildsym_compunit)
4061 (buildsym_compunit::~buildsym_compunit)
4062 (buildsym_compunit::get_macro_table): Define.
4063
4064 2018-07-20 Tom Tromey <tom@tromey.com>
4065
4066 * buildsym.c (reset_symtab_globals): Remove.
4067 (buildsym_compunit::end_symtab_from_static_block): Update.
4068 (buildsym_compunit::augment_type_symtab): Update.
4069 (end_symtab_from_static_block): Call free_buildsym_compunit.
4070 (augment_type_symtab, end_symtab, end_expandable_symtab):
4071 Likewise.
4072
4073 2018-07-20 Tom Tromey <tom@tromey.com>
4074
4075 * arch-utils.c: Do not include buildsym.h.
4076 * mipsread.c: Do not include buildsym.h.
4077 * machoread.c: Do not include buildsym.h.
4078 * elfread.c: Do not include buildsym.h.
4079
4080 2018-07-20 Tom Tromey <tom@tromey.com>
4081
4082 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
4083 initialization.
4084 (buildsym_compunit): Add new constructor.
4085 (struct buildsym_compunit) <get_last_source_file, finish_block,
4086 record_block_range, start_subfile, patch_subfile_names,
4087 push_subfile, pop_subfile, record_line, get_compunit_symtab,
4088 set_last_source_start_addr, get_last_source_start_addr,
4089 get_local_using_directives, set_local_using_directives,
4090 get_global_using_directives, outermost_context_p,
4091 get_current_context_stack, get_context_stack_depth,
4092 get_current_subfile, get_local_symbols, get_file_symbols,
4093 get_global_symbols, record_debugformat, record_producer,
4094 push_context, pop_context, end_symtab_get_static_block,
4095 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
4096 New public methods.
4097 <record_pending_block, finish_block_internal, make_blockvector,
4098 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
4099 private methods.
4100 Update all users.
4101
4102 2018-05-22 Tom Tromey <tom@tromey.com>
4103
4104 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4105 parameter.
4106 (finish_block_internal): Update.
4107
4108 2018-07-20 Tom Tromey <tom@tromey.com>
4109
4110 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4111 parameter.
4112 (finish_block_internal): Update.
4113
4114 2018-07-20 Tom Tromey <tom@tromey.com>
4115
4116 * buildsym.h (EXTERN): Don't define or undef.
4117 * buildsym.c (EXTERN): Don't define.
4118
4119 2018-07-20 Tom Tromey <tom@tromey.com>
4120
4121 * buildsym.c: Remove TODO comment.
4122
4123 2018-07-20 Tom Tromey <tom@tromey.com>
4124
4125 * coffread.c (coff_symtab_read): Update.
4126 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
4127 (xcoff_new_init): Update.
4128 * mipsread.c (mipscoff_new_init): Update.
4129 * mdebugread.c (mdebug_build_psymtabs): Update.
4130 * elfread.c (elf_new_init): Update.
4131 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
4132 Update.
4133 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
4134 (coffstab_build_psymtabs, elfstab_build_psymtabs)
4135 (stabsect_build_psymtabs): Update.
4136 * buildsym.h (buildsym_init): Don't declare.
4137 * buildsym.c: Update comment.
4138 (prepare_for_building): Remove.
4139 (start_symtab, restart_symtab): Update.
4140 (reset_symtab_globals): Update comment.
4141 (buildsym_init): Remove.
4142
4143 2018-07-20 Tom Tromey <tom@tromey.com>
4144
4145 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
4146 * stabsread.c (patch_block_stabs, define_symbol, read_type)
4147 (read_enum_type, common_block_start, common_block_end)
4148 (cleanup_undefined_types_1, finish_global_stabs): Update.
4149 * mdebugread.c (psymtab_to_symtab_1): Update.
4150 * dwarf2read.c (fixup_go_packaging, read_func_scope)
4151 (read_lexical_block_scope, new_symbol): Update.
4152 * dbxread.c (process_one_symbol): Update.
4153 * coffread.c (coff_symtab_read, process_coff_symbol)
4154 (coff_read_enum_type): Update.
4155 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
4156 declare.
4157 (get_local_symbols, get_file_symbols, get_global_symbols): New
4158 functions.
4159 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
4160 m_global_symbols.
4161 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
4162 (~scoped_free_pendings): Update.
4163 (finish_block, prepare_for_building, reset_symtab_globals)
4164 (end_symtab_get_static_block, end_symtab_with_blockvector)
4165 (augment_type_symtab, push_context): Update.
4166 (get_local_symbols, get_file_symbols, get_global_symbols): New
4167 functions.
4168 (buildsym_init): Update.
4169
4170 2018-07-20 Tom Tromey <tom@tromey.com>
4171
4172 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
4173 (process_full_type_unit): Likewise.
4174 (dwarf2_start_symtab): Set list_in_scope.
4175
4176 2018-07-20 Tom Tromey <tom@tromey.com>
4177
4178 * dwarf2read.c (process_psymtab_comp_unit_reader)
4179 (build_type_psymtabs_reader): Do not set list_in_scope.
4180
4181 2018-07-20 Tom Tromey <tom@tromey.com>
4182
4183 * buildsym.c (free_pendings): Remove.
4184 (add_symbol_to_list, scoped_free_pendings)
4185 (finish_block_internal, buildsym_init): Update.
4186
4187 2018-07-20 Tom Tromey <tom@tromey.com>
4188
4189 * xcoffread.c (read_xcoff_symtab): Update.
4190 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
4191 Update.
4192 * dbxread.c (process_one_symbol): Update.
4193 * coffread.c (coff_symtab_read): Update.
4194 * buildsym.h (finish_block): Update.
4195 * buildsym.c (finish_block): Remove "listhead" argument.
4196 (end_symtab_get_static_block): Update.
4197
4198 2018-07-20 Tom Tromey <tom@tromey.com>
4199
4200 * buildsym.h (class scoped_free_pendings): Remove constructor.
4201 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
4202 method.
4203 <m_pending_block_obstack, m_pending_blocks>: New members.
4204 (pending_block_obstack, pending_blocks): Remove.
4205 (scoped_free_pendings::scoped_free_pendings): Default.
4206 (~scoped_free_pendings): Update.
4207 (free_pending_blocks): Remove.
4208 (finish_block_internal, record_pending_block, make_blockvector)
4209 (end_symtab_get_static_block, augment_type_symtab, push_context)
4210 (buildsym_init): Update.
4211
4212 2018-07-20 Tom Tromey <tom@tromey.com>
4213
4214 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
4215 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
4216 members.
4217 (pending_addrmap, pending_addrmap_obstack)
4218 (pending_addrmap_interesting): Remove.
4219 (scoped_free_pendings, record_block_range, make_blockvector)
4220 (prepare_for_building, reset_symtab_globals, buildsym_init):
4221 Update.
4222
4223 2018-07-20 Tom Tromey <tom@tromey.com>
4224
4225 * xcoffread.c (process_linenos): Update.
4226 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
4227 * mdebugread.c (psymtab_to_symtab_1): Update.
4228 * dwarf2read.c (setup_type_unit_groups)
4229 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
4230 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
4231 * dbxread.c (process_one_symbol): Update.
4232 * coffread.c (coff_symtab_read, enter_linenos)
4233 (process_coff_symbol): Update.
4234 * buildsym.h (current_subfile): Don't declare.
4235 (get_current_subfile): Declare.
4236 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
4237 member.
4238 (start_subfile, free_buildsym_compunit, push_subfile)
4239 (prepare_for_building, start_symtab): Update.
4240 (get_current_subfile): New function.
4241
4242 2018-07-20 Tom Tromey <tom@tromey.com>
4243
4244 * coffread.c (coff_symtab_read): Update.
4245 * xcoffread.c (read_xcoff_symtab): Update.
4246 * dwarf2read.c (new_symbol): Update.
4247 (read_func_scope, read_lexical_block_scope): Update.
4248 * dbxread.c (process_one_symbol): Update.
4249 * buildsym.h (context_stack, context_stack_depth): Don't declare.
4250 (outermost_context_p): Remove macro.
4251 (outermost_context_p, get_current_context_stack)
4252 (get_context_stack_depth): Declare.
4253 (pop_context): Return struct context_stack.
4254 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
4255 member.
4256 (context_stack_size): Remove.
4257 (INITIAL_CONTEXT_STACK_SIZE): Remove.
4258 (prepare_for_building, end_symtab_get_static_block)
4259 (augment_type_symtab, push_context): Update.
4260 (pop_context): Return struct context_stack.
4261 (outermost_context_p, get_current_context_stack)
4262 (get_context_stack_depth): New functions.
4263 (buildsym_init): Update.
4264
4265 2018-07-20 Tom Tromey <tom@tromey.com>
4266
4267 * rust-exp.y: Now a pure parser. Update all rules.
4268 (%union): Move earlier.
4269 (current_parser, work_obstack): Remove globals.
4270 (rust_parser, ~rust_parser): Update.
4271 (class rust_parser) <copy_name, concat3, crate_name, super_name,
4272 lex_character, lex_number, lex_string, lex_identifier,
4273 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
4274 convert_name, convert_params_to_expression,
4275 convert_ast_to_expression, ast_basic_type, ast_operation,
4276 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
4277 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
4278 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
4279 ast_array_type, ast_slice_type, ast_reference_type,
4280 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
4281 (rust_parse): Update.
4282 (rustyyerror, rustyylex): Add parser parameter.
4283 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
4284 (rust_lex_stringish_test, rust_lex_test_sequence)
4285 (rust_lex_test_trailing_dot, rust_lex_test_completion)
4286 (rust_lex_test_push_back, rust_lex_tests): Update.
4287
4288 2018-07-19 Pedro Alves <palves@redhat.com>
4289
4290 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
4291 gdb::unique_xmalloc_ptr.
4292 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
4293 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
4294 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
4295 copy-initialization.
4296 * guile/scm-pretty-print.c (ppscm_print_children): Use
4297 gdb::unique_xmalloc_ptr instead of cleanups.
4298 (gdbscm_apply_val_pretty_printer): Remove cleanups.
4299 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
4300 gdb::unique_xmalloc_ptr.
4301 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4302 Adjust to use gdb::unique_xmalloc_ptr.
4303 * guile/scm-utils.c (extract_arg): Adjust.
4304 * guile/scm-value.c (gdbscm_value_field): Adjust to use
4305 gdb::unique_xmalloc_ptr instead of a cleanup.
4306
4307 2018-07-19 Tom Tromey <tom@tromey.com>
4308
4309 * utils.c (do_value_free_to_mark)
4310 (make_cleanup_value_free_to_mark): Remove.
4311 * utils.h (make_cleanup_value_free_to_mark): Remove.
4312
4313 2018-07-19 Pedro Alves <palves@redhat.com>
4314
4315 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
4316 forwarding reference.
4317
4318 2018-07-18 Pedro Alves <palves@redhat.com>
4319
4320 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
4321 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
4322 cleanup.
4323
4324 2018-07-18 Pedro Alves <palves@redhat.com>
4325
4326 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
4327 exceptions.
4328 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
4329 (gdbscm_wrap): New.
4330 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
4331 directly instead of a cleanup.
4332 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
4333 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
4334 (vlscm_binop_gdbthrow): New, factored out from ...
4335 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
4336 (vlscm_rich_compare): Use gdbscm_wrap.
4337 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
4338 instead of a cleanup.
4339 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
4340 cleanup.
4341 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4342 Use xfree directly instead of a cleanup.
4343 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
4344 Adjust to use gdbscm_wrap and scoped_value_mark.
4345 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
4346 (gdbscm_value_address, gdbscm_value_dereference)
4347 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
4348 scoped_value_mark.
4349 (gdbscm_value_dynamic_type): Use scoped_value_mark.
4350 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
4351 scoped_value_mark.
4352 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
4353 gdbscm_wrap and scoped_value_mark.
4354 (gdbscm_value_to_string): Use xfree directly instead of a
4355 cleanup. Move 'buffer' unique_ptr to TRY scope.
4356 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
4357 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
4358 scoped_value_mark.
4359 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
4360 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
4361 scoped_value_mark.
4362 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
4363 gdbscm_wrap.
4364
4365 2018-07-18 Tom de Vries <tdevries@suse.de>
4366
4367 * findvar.c (default_read_var_value): Also resolve dynamic type for
4368 LOC_OPTIMIZED_OUT vars.
4369
4370 2018-07-18 Maciej W. Rozycki <macro@mips.com>
4371
4372 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
4373 decoding.
4374
4375 2018-07-17 Tom Tromey <tom@tromey.com>
4376
4377 * guile/scm-param.c (pascm_set_func, pascm_show_func)
4378 (compute_enum_list, pascm_set_param_value_x)
4379 (gdbscm_parameter_value): Update.
4380 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
4381 (gdbscm_scm_to_host_string): Update.
4382 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
4383 Update.
4384 * guile/scm-cmd.c (cmdscm_add_completion): Update.
4385 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
4386 * guile/scm-string.c (gdbscm_scm_to_string): Return
4387 unique_xmalloc_ptr.
4388 (gdbscm_scm_to_host_string): Likewise.
4389
4390 2018-07-17 Tom Tromey <tom@tromey.com>
4391
4392 * guile/guile.c (gdbscm_eval_from_control_command): Update.
4393 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
4394 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
4395 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
4396 unique_xmalloc_ptr.
4397
4398 2018-07-17 Tom Tromey <tom@tromey.com>
4399
4400 * guile/scm-param.c (pascm_signal_setshow_error): Update.
4401 * guile/guile-internal.h (gdbscm_exception_message_to_string):
4402 Update.
4403 * guile/scm-cmd.c (cmdscm_function): Update.
4404 * guile/scm-pretty-print.c
4405 (ppscm_print_exception_unless_memory_error): Update.
4406 * guile/scm-exception.c (gdbscm_exception_message_to_string):
4407 Return unique_xmalloc_ptr.
4408
4409 2018-07-17 Tom Tromey <tom@tromey.com>
4410
4411 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
4412 Use string_printf.
4413
4414 2018-07-17 Jim Wilson <jimw@sifive.com>
4415
4416 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
4417 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
4418 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
4419 unecessary braces after EF_RISCV_RVC test. Delete call to
4420 set_gdbarch_decr_pc_after_break.
4421
4422 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
4423 RISCV_LAST_FP_REGNUM + 1.
4424 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
4425
4426 2018-07-17 Tom Tromey <tom@tromey.com>
4427
4428 * configure.ac: Remove --disable-gdbcli.
4429 * configure: Rebuild.
4430 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
4431 (SUBDIR_CLI_CFLAGS): Remove.
4432 (SFILES): Use SUBDIR_CLI_SRCS.
4433 (COMMON_OBS): Use SUBDIR_CLI_OBS.
4434
4435 2018-07-17 Tom Tromey <tom@tromey.com>
4436
4437 PR gdb/18624:
4438 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
4439
4440 2018-07-16 Jim Wilson <jimw@sifive.com>
4441
4442 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
4443
4444 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4445
4446 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
4447 variable.
4448 (libunwind_frame_sniffer): Likewise.
4449 (libunwind_frame_prev_register): Likewise.
4450 (libunwind_sigtramp_frame_sniffer): Likewise.
4451 * ia64-tdep.c (ia64_access_reg): Likewise.
4452 (ia64_access_rse_reg): Likewise.
4453 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
4454 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
4455
4456 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4457
4458 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
4459
4460 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4461
4462 * remote-sim.c (gdbsim_target::close,
4463 gdbsim_target::mourn_inferior): Remove unused variables.
4464
4465 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
4466
4467 * ia64-tdep.c (ktab_buf): New global.
4468 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
4469 (get_kernel_table): Adjust.
4470
4471 2018-07-16 Tom Tromey <tom@tromey.com>
4472
4473 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
4474 * dwarf2read.c (using_directives, new_symbol): Use
4475 outermost_context_p.
4476 * dbxread.c (process_one_symbol): Use outermost_context_p.
4477 * coffread.c (coff_symtab_read): Use outermost_context_p.
4478
4479 2018-07-16 Tom Tromey <tom@tromey.com>
4480
4481 * dwarf2read.c (using_directives, read_func_scope)
4482 (read_lexical_block_scope): Update.
4483 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
4484 * buildsym.h (local_using_directives, global_using_directives):
4485 Don't declare.
4486 (get_local_using_directives, set_local_using_directives)
4487 (get_global_using_directives): Declare.
4488 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
4489 m_global_using_directives>: New members.
4490 (finish_block_internal, prepare_for_building)
4491 (reset_symtab_globals, end_symtab_get_static_block)
4492 (push_context): Update.
4493 (get_local_using_directives, set_local_using_directives)
4494 (get_global_using_directives): New functions.
4495 (buildsym_init): Update.
4496
4497 2018-07-16 Tom Tromey <tom@tromey.com>
4498
4499 * xcoffread.c (xcoff_initial_scan): Don't call
4500 free_pending_blocks.
4501 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
4502 * buildsym.h (class scoped_free_pendings): Add constructor.
4503 (free_pending_blocks): Don't declare.
4504 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
4505 (free_pending_blocks): Now static.
4506
4507 2018-07-16 Tom Tromey <tom@tromey.com>
4508
4509 * buildsym.h (push_subfile, pop_subfile): Update declarations.
4510 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
4511 member.
4512 (struct subfile_stack): Remove.
4513 (subfile_stack): Remove.
4514 (push_subfile, pop_subfile, buildsym_init): Update.
4515
4516 2018-07-16 Tom Tromey <tom@tromey.com>
4517
4518 * buildsym.c (push_subfile): Use gdb_assert.
4519 (pop_subfile): Use gdb_assert.
4520
4521 2018-07-16 Tom Tromey <tom@tromey.com>
4522
4523 * buildsym.h (merge_symbol_lists): Remove.
4524 * buildsym.c (merge_symbol_lists): Remove.
4525
4526 2018-07-16 Tom Tromey <tom@tromey.com>
4527
4528 * stabsread.c (scan_file_globals): Update comment.
4529 * stabsread.h (scan_file_globals): Move from buildsym.h.
4530 * buildsym.h (scan_file_globals): Move to stabsread.h.
4531
4532 2018-07-16 Tom Tromey <tom@tromey.com>
4533
4534 * xcoffread.c (xcoff_new_init): Update.
4535 * mipsread.c (mipscoff_new_init): Update.
4536 * mdebugread.c (mdebug_build_psymtabs): Update.
4537 * elfread.c (elf_new_init): Update.
4538 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
4539 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
4540 * buildsym.h (buildsym_new_init): Don't declare.
4541 * buildsym.c (buildsym_new_init): Remove.
4542
4543 2018-07-16 Tom Tromey <tom@tromey.com>
4544
4545 * stabsread.h (within_function): Move from buildsym.h.
4546 * stabsread.c (start_stabs): Clear within_function.
4547 * coffread.c (coff_start_symtab): Clear within_function.
4548 * buildsym.h (within_function): Move to stabsread.h.
4549 * buildsym.c (prepare_for_building): Update.
4550
4551 2018-07-16 Tom Tromey <tom@tromey.com>
4552
4553 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
4554 * dwarf2read.c (dwarf2_start_symtab): Don't set
4555 processing_gcc_compilation.
4556 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
4557
4558 2018-07-16 Tom Tromey <tom@tromey.com>
4559
4560 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
4561 (next_symbol_text_func): Move from buildsym.h.
4562 * stabsread.c (hashname): Move from buildsym.c.
4563 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
4564 (next_symbol_text_func, hashname): Move to stabsread.h.
4565 * buildsym.c: Don't include bcache.h
4566 (hashname): Move to stasbread.c.
4567
4568 2018-07-16 Tom Tromey <tom@tromey.com>
4569
4570 * buildsym.h (context_stack_size): Don't declare.
4571 * buildsym.c (context_stack_size): New global.
4572
4573 2018-07-16 Tom Tromey <tom@tromey.com>
4574
4575 * dbxread.c (processing_acc_compilation): New global.
4576 * buildsym.h (processing_acc_compilation): Don't declare.
4577
4578 2018-07-16 Tom Tromey <tom@tromey.com>
4579
4580 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
4581 * dbxread.c (read_ofile_symtab): Update.
4582 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
4583 * buildsym.h (last_source_start_addr): Remove.
4584 (set_last_source_start_addr, get_last_source_start_addr):
4585 Declare.
4586 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
4587 parameter.
4588 (struct buildsym_compunit) <m_last_source_start_addr>: New
4589 member.
4590 (prepare_for_building): Remove start_addr parameter.
4591 (start_symtab, restart_symtab, end_symtab_get_static_block)
4592 (end_symtab_with_blockvector): Update.
4593 (set_last_source_start_addr, get_last_source_start_addr): New
4594 functions.
4595
4596 2018-07-16 Tom Tromey <tom@tromey.com>
4597
4598 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
4599 member.
4600 (have_line_numbers): Remove.
4601 (record_line, prepare_for_building, end_symtab_get_static_block)
4602 (augment_type_symtab): Update.
4603
4604 2018-07-16 Tom Tromey <tom@tromey.com>
4605
4606 * buildsym.c (~buildsym_compunit): Free the macro table.
4607 (struct buildsym_compunit) <get_macro_table, release_macros>: New
4608 methods.
4609 <m_pending_macros>: New member.
4610 (pending_macros): Remove.
4611 (~scoped_free_pendings, get_macro_table, prepare_for_building)
4612 (reset_symtab_globals, end_symtab_get_static_block)
4613 (end_symtab_with_blockvector, augment_type_symtab)
4614 (buildsym_init): Update.
4615
4616 2018-07-16 Tom Tromey <tom@tromey.com>
4617
4618 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
4619 parameter.
4620 (buildsym_compunit::set_last_source_file): New method.
4621 <m_last_source_file>: New member.
4622 (prepare_for_building): Remove "name" parameter.
4623 (start_symtab, restart_symtab, reset_symtab_globals): Update.
4624 (last_source_file): Remove.
4625 (set_last_source_file, get_last_source_file): Update.
4626
4627 2018-07-16 Tom Tromey <tom@tromey.com>
4628
4629 * buildsym.c (prepare_for_building): Add assert.
4630
4631 2018-07-16 Tom Tromey <tom@tromey.com>
4632
4633 * buildsym.c (~buildsym_compunit): Update.
4634 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
4635 (start_subfile, patch_subfile_names)
4636 (end_symtab_with_blockvector): Update.
4637
4638 2018-07-16 Tom Tromey <tom@tromey.com>
4639
4640 * buildsym.c (struct buildsym_compunit): Add constructor,
4641 destructor, initializers.
4642 (start_buildsym_compunit): Remove.
4643 (free_buildsym_compunit): Use "delete".
4644 (start_symtab, restart_symtab): Use "new".
4645
4646 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
4647
4648 * symfile.c (set_objfile_default_section_offset): Remove struct
4649 keyword.
4650
4651 2018-07-14 Stafford Horne <shorne@gmail.com>
4652
4653 * (Responsible Maintainers): Add myself as or1k maintainer.
4654
4655 2018-07-13 Tom Tromey <tom@tromey.com>
4656
4657 * symfile.c (set_objfile_default_section_offset): Use extra braces
4658 around initializer.
4659
4660 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4661
4662 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
4663 non-branching basr.
4664
4665 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4666
4667 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4668 unittests/cli-utils-selftests.c
4669 * unittests/cli-utils-selftests.c: New file.
4670
4671 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4672
4673 * NEWS: Mention new commands. Mention change to 'thread apply'.
4674
4675 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4676
4677 * thread.c (thr_try_catch_cmd): New function.
4678 (thread_apply_all_command): Handle qcs flags.
4679 (thread_apply_command): Handle qcs flags.
4680 (taas_command): New function.
4681 (tfaas_command): New function.
4682 (_initialize_thread): Update to setup the new commands 'taas
4683 and 'tfaas'. Change doc string for 'thread apply'.
4684
4685 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4686
4687 * stack.c: (trailing_outermost_frame): New function, mostly
4688 extracted from backtrace_command_1.
4689 (leading_innermost_frame): New function.
4690 (backtrace_command_1): Update to call trailing_outermost_frame.
4691 (frame_apply_command_count): New function.
4692 (frame_apply_level_command): New function.
4693 (frame_apply_all_command): New function.
4694 (frame_apply_command): New function.
4695 (faas_command): New function.
4696 (frame_cmd_list): New variable.
4697 (_initialize_stack): Update to setup the new commands 'frame apply'
4698 and 'faas'.
4699
4700 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4701
4702 * cli-utils.c (number_or_range_parser::get_number): Only handle
4703 numbers or convenience var as numbers.
4704 (parse_flags): New function.
4705 (parse_flags_qcs): New function.
4706 (number_or_range_parser::finished): Ensure parsing end is detected
4707 before end of string.
4708 * cli-utils.h (parse_flags): New function.
4709 (parse_flags_qcs): New function.
4710 (number_or_range_parser): Remove m_finished bool.
4711 (number_or_range_parser::skip_range): Set m_in_range to false.
4712
4713 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
4714
4715 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
4716 on Windows.
4717
4718 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4719 Jan Kratochvil <jan.kratochvil@redhat.com>
4720 Paul Fertser <fercerpav@gmail.com>
4721 Tsutomu Seki <sekiriki@gmail.com>
4722 Pedro Alves <palves@redhat.com>
4723
4724 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4725 'unittests/parse-connection-spec-selftests.c'.
4726 (COMMON_SFILES): Add 'common/netstuff.c'.
4727 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
4728 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
4729 * common/netstuff.c: New file.
4730 * common/netstuff.h: New file.
4731 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
4732 (wait_for_connect): Update comment. New parameter
4733 'gdb::optional<int> sock' instead of 'struct serial *scb'.
4734 Use 'sock' directly instead of 'scb->fd'.
4735 (try_connect): New function, with code from 'net_open'.
4736 (net_open): Rewrite main loop to deal with multiple
4737 sockets/addresses. Handle IPv6-style hostnames; implement
4738 support for IPv6 connections.
4739 * unittests/parse-connection-spec-selftests.c: New file.
4740
4741 2018-07-11 Pedro Alves <palves@redhat.com>
4742
4743 PR gdb/23377
4744 * remote.c (remote_target::remote_detach_pid): Call
4745 set_current_process.
4746
4747 2018-07-11 Pedro Alves <palves@redhat.com>
4748
4749 * h8300-tdep.c (h8300_gdbarch_init): Remove
4750 set_gdbarch_ecoff_reg_to_regnum calls.
4751
4752 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4753
4754 PR c++/23373
4755 * c-typeprint.c (c_type_print_base_struct_union): Don't print
4756 offsets/sizes for static members of a class/struct.
4757
4758 2018-07-11 Alan Hayward <alan.hayward@arm.com>
4759
4760 * target-descriptions.c (tdesc_register_bitsize): Rename.
4761 * target-descriptions.h (tdesc_register_bitsize): Likewise.
4762 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
4763 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
4764
4765 2018-07-10 Tom Tromey <tom@tromey.com>
4766
4767 * breakpoint.c (moribund_locations): Now static and a
4768 std::vector.
4769 (breakpoint_init_inferior, moribund_breakpoint_here_p)
4770 (build_bpstat_chain, update_global_location_list)
4771 (breakpoint_retire_moribund): Update.
4772 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
4773 VEC.
4774
4775 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4776
4777 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
4778 (riscv_register_reggroup_p): Use new function, remove unneeded
4779 parenthesis.
4780 (riscv_push_dummy_call): Extend assert to compare against xlen or
4781 flen based on register type.
4782
4783 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4784
4785 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
4786
4787 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
4788
4789 * remote.c (show_hardware_watchpoint_limit): New function.
4790 (show_hardware_watchpoint_length_limit): New function.
4791 (show_hardware_breakpoint_limit): New function.
4792 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
4793 where appropriate, update help text.
4794
4795 2018-07-09 Tom Tromey <tom@tromey.com>
4796
4797 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
4798 (CLIBS): Don't mention NAT_CLIBS.
4799
4800 2018-07-09 Tom Tromey <tom@tromey.com>
4801
4802 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
4803 (LIBGDB_OBS, clean mostlyclean): Update.
4804 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
4805
4806 2018-07-09 Tom Tromey <tom@tromey.com>
4807
4808 * Makefile.in (%.c: %.y): Use ECHO_YACC.
4809 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
4810 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
4811
4812 2018-07-09 Tom Tromey <tom@tromey.com>
4813
4814 * Makefile.in (ALLDEPFILES): Remove exec.c.
4815 (COMMON_OBS): Remove exec.o.
4816 (COMMON_SFILES): Add exec.c.
4817
4818 2018-07-09 Tom Tromey <tom@tromey.com>
4819
4820 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
4821
4822 2018-07-09 Tom Tromey <tom@tromey.com>
4823
4824 * Makefile.in (clean mostlyclean): Remove stamp-version.
4825 (version.c): Depend on stamp-version.
4826 (stamp-version): New rule, from version.c rule.
4827
4828 2018-07-09 Tom Tromey <tom@tromey.com>
4829
4830 * Makefile.in (init.c): Depend on stamp-init.
4831 (stamp-init): New rule, from init.c rule.
4832 (clean mostlyclean): Remove stamp-init.
4833
4834 2018-07-09 Tom Tromey <tom@tromey.com>
4835
4836 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
4837 SUBDIR_GCC_COMPILE_SRCS.
4838
4839 2018-07-09 Tom Tromey <tom@tromey.com>
4840
4841 * Makefile.in (init.c): Remove some unused sed rules.
4842
4843 2018-07-09 Tom Tromey <tom@tromey.com>
4844
4845 * Makefile.in (TSOBS): Remove.
4846 (INIT_FILES): Update.
4847 (LIBGDB_OBS): Update.
4848 (COMMON_SFILES): Add inflow.c.
4849 (SFILES): Remove inflow.c.
4850
4851 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
4852
4853 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
4854
4855 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
4856
4857 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
4858 get_saveloc_name, is_signal_frame_name, step_name,
4859 init_remote_name, create_addr_space_name,
4860 destroy_addr_space_name, search_unwind_table_name,
4861 find_dyn_list_name): Constify.
4862
4863 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
4864
4865 * darwin-nat.c (darwin_pthread_kill): New function.
4866 (darwin_resume_thread): Use darwin_pthread_kill.
4867
4868 2018-07-05 Tom de Vries <tdevries@suse.de>
4869
4870 * macroexp.c (macro_buffer) <operator=>: New member function.
4871
4872 2018-07-04 Tom Tromey <tom@tromey.com>
4873
4874 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
4875
4876 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
4877
4878 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
4879 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
4880 * maint.c: Likewise.
4881 * top.c: Likewise.
4882
4883 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4884
4885 * NEWS: Create a new section for the next release branch.
4886 Rename the section of the current branch, now that it has
4887 been cut.
4888
4889 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4890
4891 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
4892 * version.in: Bump version to 8.2.50.DATE-git.
4893
4894 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4895 Pedro Alves <palves@redhat.com>
4896
4897 * linux-nat.c (linux_init_ptrace): Rename to ...
4898 (linux_init_ptrace_procfs): ... this. Call
4899 linux_proc_init_warnings.
4900 (linux_nat_target::post_attach)
4901 (linux_nat_target::post_startup_inferior): Adjust.
4902 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
4903 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
4904
4905 2018-07-04 Tom de Vries <tdevries@suse.de>
4906
4907 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
4908 check ...
4909 (read_comp_unit_head): ... here.
4910
4911 2018-07-03 Tom Tromey <tom@tromey.com>
4912
4913 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
4914 (stop_tracing, tstatus_command)
4915 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
4916 (print_one_static_tracepoint_marker): Update.
4917 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
4918 std::vector.
4919 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
4920 VEC.
4921 (all_tracepoints, static_tracepoints_here): Return std::vector.
4922
4923 2018-07-03 Tom Tromey <tom@tromey.com>
4924
4925 * common/ptid.c (ptid_equal): Remove.
4926 * common/ptid.h (ptid_equal): Don't declare.
4927 * ada-tasks.c: Update.
4928 * breakpoint.c: Update.
4929 * common/agent.c: Update.
4930 * corelow.c: Update.
4931 * darwin-nat-info.c: Update.
4932 * darwin-nat.c: Update.
4933 * dcache.c: Update.
4934 * dtrace-probe.c: Update.
4935 * dummy-frame.c: Update.
4936 * fbsd-nat.c: Update.
4937 * frame.c: Update.
4938 * gdbthread.h: Update.
4939 * gnu-nat.c: Update.
4940 * go32-nat.c: Update.
4941 * inf-loop.c: Update.
4942 * inf-ptrace.c: Update.
4943 * infcall.c: Update.
4944 * infcmd.c: Update.
4945 * inflow.c: Update.
4946 * infrun.c: Update.
4947 * linux-fork.c: Update.
4948 * linux-nat.c: Update.
4949 * linux-thread-db.c: Update.
4950 * mi/mi-cmd-var.c: Update.
4951 * mi/mi-interp.c: Update.
4952 * mi/mi-main.c: Update.
4953 * nto-procfs.c: Update.
4954 * ppc-linux-tdep.c: Update.
4955 * procfs.c: Update.
4956 * python/py-inferior.c: Update.
4957 * python/py-record-btrace.c: Update.
4958 * python/py-record.c: Update.
4959 * ravenscar-thread.c: Update.
4960 * regcache.c: Update.
4961 * remote-sim.c: Update.
4962 * remote.c: Update.
4963 * sol-thread.c: Update.
4964 * solib.c: Update.
4965 * target.c: Update.
4966 * tui/tui-stack.c: Update.
4967 * varobj.c: Update.
4968 * windows-nat.c: Update.
4969 * windows-tdep.c: Update.
4970
4971 2018-07-03 Tom Tromey <tom@tromey.com>
4972
4973 * common/ptid.c (ptid_match): Remove.
4974 * common/ptid.h (ptid_match): Don't declare.
4975 * fbsd-nat.c: Update.
4976 * infcmd.c: Update.
4977 * infrun.c: Update.
4978 * linux-nat.c: Update.
4979 * record-btrace.c: Update.
4980 * regcache.c: Update.
4981 * remote.c: Update.
4982
4983 2018-07-03 Tom Tromey <tom@tromey.com>
4984
4985 * common/ptid.c (ptid_tid_p): Remove.
4986 * common/ptid.h (ptid_tid_p): Don't declare.
4987 * sol-thread.c: Update.
4988
4989 2018-07-03 Tom Tromey <tom@tromey.com>
4990
4991 * common/ptid.c (ptid_lwp_p): Remove.
4992 * common/ptid.h (ptid_lwp_p): Don't declare.
4993 * fbsd-nat.c: Update.
4994 * linux-nat.c: Update.
4995 * nat/linux-procfs.c: Update.
4996 * nat/x86-linux-dregs.c: Update.
4997 * sol-thread.c: Update.
4998
4999 2018-07-03 Tom Tromey <tom@tromey.com>
5000
5001 * common/ptid.c (ptid_is_pid): Remove.
5002 * common/ptid.h (ptid_is_pid): Don't declare.
5003 * infrun.c: Update.
5004 * linux-nat.c: Update.
5005 * mi/mi-interp.c: Update.
5006 * remote.c: Update.
5007 * thread.c: Update.
5008
5009 2018-07-03 Tom Tromey <tom@tromey.com>
5010
5011 * common/ptid.c (ptid_get_tid): Remove.
5012 * common/ptid.h (ptid_get_tid): Don't declare.
5013 * ada-tasks.c: Update.
5014 * aix-thread.c: Update.
5015 * bsd-uthread.c: Update.
5016 * darwin-nat.c: Update.
5017 * fbsd-nat.c: Update.
5018 * i386-darwin-nat.c: Update.
5019 * infrun.c: Update.
5020 * linux-tdep.c: Update.
5021 * nto-procfs.c: Update.
5022 * ppc-ravenscar-thread.c: Update.
5023 * python/py-infthread.c: Update.
5024 * ravenscar-thread.c: Update.
5025 * sol-thread.c: Update.
5026 * sparc-ravenscar-thread.c: Update.
5027 * windows-nat.c: Update.
5028
5029 2018-07-03 Tom Tromey <tom@tromey.com>
5030
5031 * common/ptid.c (ptid_get_lwp): Remove.
5032 * common/ptid.h (ptid_get_lwp): Don't declare.
5033 * aarch64-linux-nat.c: Update.
5034 * ada-tasks.c: Update.
5035 * aix-thread.c: Update.
5036 * amd64-linux-nat.c: Update.
5037 * arm-linux-nat.c: Update.
5038 * corelow.c: Update.
5039 * fbsd-nat.c: Update.
5040 * fbsd-tdep.c: Update.
5041 * gnu-nat.c: Update.
5042 * i386-cygwin-tdep.c: Update.
5043 * i386-gnu-nat.c: Update.
5044 * i386-linux-nat.c: Update.
5045 * ia64-linux-nat.c: Update.
5046 * inf-ptrace.c: Update.
5047 * infrun.c: Update.
5048 * linux-fork.c: Update.
5049 * linux-nat.c: Update.
5050 * linux-tdep.c: Update.
5051 * linux-thread-db.c: Update.
5052 * mips-linux-nat.c: Update.
5053 * nat/aarch64-linux-hw-point.c: Update.
5054 * nat/aarch64-linux.c: Update.
5055 * nat/linux-btrace.c: Update.
5056 * nat/linux-osdata.c: Update.
5057 * nat/linux-procfs.c: Update.
5058 * nat/x86-linux-dregs.c: Update.
5059 * obsd-nat.c: Update.
5060 * ppc-fbsd-nat.c: Update.
5061 * ppc-linux-nat.c: Update.
5062 * procfs.c: Update.
5063 * python/py-infthread.c: Update.
5064 * ravenscar-thread.c: Update.
5065 * remote.c: Update.
5066 * s390-linux-nat.c: Update.
5067 * sol-thread.c: Update.
5068 * sol2-tdep.c: Update.
5069 * spu-linux-nat.c: Update.
5070 * x86-linux-nat.c: Update.
5071 * xtensa-linux-nat.c: Update.
5072
5073 2018-07-03 Tom Tromey <tom@tromey.com>
5074
5075 * common/ptid.c (ptid_get_pid): Remove.
5076 * common/ptid.h (ptid_get_pid): Don't declare.
5077 * aarch64-linux-nat.c: Update.
5078 * ada-lang.c: Update.
5079 * aix-thread.c: Update.
5080 * alpha-bsd-nat.c: Update.
5081 * amd64-fbsd-nat.c: Update.
5082 * amd64-linux-nat.c: Update.
5083 * arm-linux-nat.c: Update.
5084 * arm-nbsd-nat.c: Update.
5085 * auxv.c: Update.
5086 * break-catch-syscall.c: Update.
5087 * breakpoint.c: Update.
5088 * bsd-uthread.c: Update.
5089 * corelow.c: Update.
5090 * ctf.c: Update.
5091 * darwin-nat.c: Update.
5092 * fbsd-nat.c: Update.
5093 * fbsd-tdep.c: Update.
5094 * gcore.c: Update.
5095 * gnu-nat.c: Update.
5096 * hppa-nbsd-nat.c: Update.
5097 * hppa-obsd-nat.c: Update.
5098 * i386-fbsd-nat.c: Update.
5099 * ia64-linux-nat.c: Update.
5100 * inf-ptrace.c: Update.
5101 * infcmd.c: Update.
5102 * inferior.c: Update.
5103 * inferior.h: Update.
5104 * inflow.c: Update.
5105 * infrun.c: Update.
5106 * linux-fork.c: Update.
5107 * linux-nat.c: Update.
5108 * linux-tdep.c: Update.
5109 * linux-thread-db.c: Update.
5110 * m68k-bsd-nat.c: Update.
5111 * mi/mi-interp.c: Update.
5112 * mi/mi-main.c: Update.
5113 * mips-linux-nat.c: Update.
5114 * mips-nbsd-nat.c: Update.
5115 * mips64-obsd-nat.c: Update.
5116 * nat/aarch64-linux-hw-point.c: Update.
5117 * nat/aarch64-linux.c: Update.
5118 * nat/linux-btrace.c: Update.
5119 * nat/linux-osdata.c: Update.
5120 * nat/linux-procfs.c: Update.
5121 * nat/x86-linux-dregs.c: Update.
5122 * nto-procfs.c: Update.
5123 * obsd-nat.c: Update.
5124 * ppc-linux-nat.c: Update.
5125 * ppc-nbsd-nat.c: Update.
5126 * ppc-obsd-nat.c: Update.
5127 * proc-service.c: Update.
5128 * procfs.c: Update.
5129 * python/py-inferior.c: Update.
5130 * python/py-infthread.c: Update.
5131 * ravenscar-thread.c: Update.
5132 * record.c: Update.
5133 * remote-sim.c: Update.
5134 * remote.c: Update.
5135 * rs6000-nat.c: Update.
5136 * s390-linux-nat.c: Update.
5137 * sh-nbsd-nat.c: Update.
5138 * sol-thread.c: Update.
5139 * sparc-nat.c: Update.
5140 * sparc64-tdep.c: Update.
5141 * spu-linux-nat.c: Update.
5142 * spu-tdep.c: Update.
5143 * target-debug.h: Update.
5144 * target.c: Update.
5145 * thread.c: Update.
5146 * tid-parse.c: Update.
5147 * tracefile-tfile.c: Update.
5148 * vax-bsd-nat.c: Update.
5149 * windows-nat.c: Update.
5150 * x86-linux-nat.c: Update.
5151 * x86-nat.c: Update.
5152
5153 2018-07-03 Tom Tromey <tom@tromey.com>
5154
5155 * common/ptid.c (pid_to_ptid): Remove.
5156 * common/ptid.h (pid_to_ptid): Don't declare.
5157 * aix-thread.c: Update.
5158 * arm-linux-nat.c: Update.
5159 * common/ptid.c: Update.
5160 * common/ptid.h: Update.
5161 * corelow.c: Update.
5162 * ctf.c: Update.
5163 * darwin-nat.c: Update.
5164 * fbsd-nat.c: Update.
5165 * fork-child.c: Update.
5166 * gnu-nat.c: Update.
5167 * go32-nat.c: Update.
5168 * inf-ptrace.c: Update.
5169 * infcmd.c: Update.
5170 * inferior.c: Update.
5171 * infrun.c: Update.
5172 * linux-fork.c: Update.
5173 * linux-nat.c: Update.
5174 * nat/aarch64-linux-hw-point.c: Update.
5175 * nat/fork-inferior.c: Update.
5176 * nat/x86-linux-dregs.c: Update.
5177 * nto-procfs.c: Update.
5178 * obsd-nat.c: Update.
5179 * procfs.c: Update.
5180 * progspace.c: Update.
5181 * remote.c: Update.
5182 * rs6000-nat.c: Update.
5183 * s390-linux-nat.c: Update.
5184 * sol-thread.c: Update.
5185 * spu-linux-nat.c: Update.
5186 * target.c: Update.
5187 * top.c: Update.
5188 * tracefile-tfile.c: Update.
5189 * windows-nat.c: Update.
5190
5191 2018-07-03 Tom Tromey <tom@tromey.com>
5192
5193 * common/ptid.h (ptid_build): Don't declare.
5194 * common/ptid.c (ptid_build): Remove.
5195 * aix-thread.c: Update.
5196 * bsd-kvm.c: Update.
5197 * bsd-uthread.c: Update.
5198 * common/agent.c: Update.
5199 * common/ptid.c: Update.
5200 * common/ptid.h: Update.
5201 * corelow.c: Update.
5202 * darwin-nat.c: Update.
5203 * fbsd-nat.c: Update.
5204 * gnu-nat.c: Update.
5205 * linux-fork.c: Update.
5206 * linux-nat.c: Update.
5207 * linux-thread-db.c: Update.
5208 * nat/linux-osdata.c: Update.
5209 * nat/linux-procfs.c: Update.
5210 * nto-procfs.c: Update.
5211 * obsd-nat.c: Update.
5212 * proc-service.c: Update.
5213 * procfs.c: Update.
5214 * ravenscar-thread.c: Update.
5215 * remote-sim.c: Update.
5216 * remote.c: Update.
5217 * sol-thread.c: Update.
5218 * target.c: Update.
5219 * windows-nat.c: Update.
5220
5221 2018-07-03 Tom Tromey <tom@tromey.com>
5222
5223 * infrun.c (follow_exec): Use exit_inferior_silent.
5224 * inferior.c (exit_inferior_num_silent): Remove.
5225 * inferior.h (exit_inferior_num_silent): Don't declare.
5226
5227 2018-07-03 Tom Tromey <tom@tromey.com>
5228
5229 PR cli/23340:
5230 * darwin-nat.c (darwin_attach_pid): Reset inferior and
5231 inferior_ptid on error.
5232
5233 2018-07-02 Maciej W. Rozycki <macro@mips.com>
5234 Simon Marchi <simon.marchi@polymtl.ca>
5235
5236 PR tdep/8282
5237 * disasm.h (gdb_disassembler): Add
5238 `m_disassembler_options_holder'. member
5239 * disasm.c (get_all_disassembler_options): New function.
5240 (gdb_disassembler::gdb_disassembler): Use it.
5241 (gdb_buffered_insn_length_init_dis): Likewise.
5242 (gdb_buffered_insn_length): Adjust accordingly.
5243 (set_disassembler_options): Handle options with arguments.
5244 (show_disassembler_options_sfunc): Likewise. Add a leading new
5245 line if showing options with descriptions.
5246 (disassembler_options_completer): Adapt to using the
5247 `disasm_options_and_args_t' structure.
5248 * mips-tdep.c (mips_disassembler_options): New variable.
5249 (mips_disassembler_options_o32): Likewise.
5250 (mips_disassembler_options_n32): Likewise.
5251 (mips_disassembler_options_n64): Likewise.
5252 (gdb_print_insn_mips): Don't set `disassembler_options'.
5253 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
5254 functions.
5255 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
5256 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
5257 `gdbarch_disassembler_options_implicit' and
5258 `gdbarch_valid_disassembler_options'.
5259 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
5260 `disasm_options_and_args_t' structure.
5261 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
5262 method.
5263 (valid_disassembler_options): Switch from `disasm_options_t' to
5264 the `disasm_options_and_args_t' structure.
5265 * NEWS: Document `set disassembler-options' support for the MIPS
5266 target.
5267 * gdbarch.h: Regenerate.
5268 * gdbarch.c: Regenerate.
5269
5270 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
5271
5272 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
5273
5274 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5275
5276 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
5277 parameter in call to amd64_target_description.
5278 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
5279 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
5280 (amd64fbsd_init_abi): Likewise.
5281 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5282 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
5283 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
5284 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
5285
5286 2018-06-29 Pedro Alves <palves@redhat.com>
5287
5288 * gdb/amd64-tdep.h (amd64_create_target_description): Add
5289 "segments" parameter.
5290 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
5291 (_initialize_amd64_tdep): Update call to
5292 amd64_create_target_description.
5293 (amd64_target_description): Add "segments" parameter. Adjust
5294 the implementation to use it.
5295 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
5296 call to amd64_create_target_description.
5297 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
5298 * gdb/arch/amd64.h (amd64_create_target_description): Add
5299 "segments" register.
5300 * gdb/arch/amd64.c (amd64_create_target_description): Add
5301 "segments" parameter. Call create_feature_i386_64bit_segments
5302 only if SEGMENTS is true.
5303 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
5304 call to amd64_create_target_description.
5305
5306 2018-06-29 Pedro Alves <palves@redhat.com>
5307
5308 * thread.c (thread_target_id_str): New, factored out from ...
5309 (print_thread_info_1): ... here. Use it to compute the max
5310 "Target Id" column width.
5311
5312 2018-06-29 Pedro Alves <palves@redhat.com>
5313
5314 * remote.c (remote_target::extra_thread_info): Delete
5315 'display_buf' and 'n' locals. from the cache, regardless of
5316 packet mechanims is in use. Use cache for qThreadExtra and qP
5317 methods too.
5318
5319 2018-06-29 Pedro Alves <palves@redhat.com>
5320
5321 * blockframe.c (find_pc_sect_containing_function): New function.
5322 * breakpoint.c (print_breakpoint_location): Don't call
5323 find_pc_sect_function.
5324 * linespec.c (create_sals_line_offset): Record the location's
5325 symbol in the sal.
5326 * linespec.c (convert_address_location_to_sals): Fill in sal's
5327 symbol with find_pc_sect_containing_function.
5328 * symtab.c (find_function_start_sal): Rename to ...
5329 (find_function_start_sal_1): ... this.
5330 (find_function_start_sal): Reimplement as wrapper around
5331 find_function_start_sal_1, and use
5332 find_pc_sect_containing_function to fill in the sal's symbol.
5333 (find_function_start_sal(symbol*, bool)): Adjust.
5334 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
5335 comments.
5336 (find_pc_sect_containing_function): Declare.
5337
5338 2018-06-29 Pedro Alves <palves@redhat.com>
5339
5340 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
5341 true if the the location has no symbol.
5342
5343 2018-06-28 Tom Tromey <tom@tromey.com>
5344
5345 * NEWS: Mention --enable-codesign.
5346 * silent-rules.mk (ECHO_SIGN): New variable.
5347 * configure.ac: Add --enable-codesign.
5348 * configure: Rebuild.
5349 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
5350 (gdb$(EXEEXT)): Optionally invoke codesign.
5351
5352 2018-06-28 Pedro Alves <palves@redhat.com>
5353
5354 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
5355 comments.
5356 (switch_to_thread_no_regs): Adjust comment.
5357 * infcmd.c (stop_pc): Delete.
5358 (post_create_inferior, info_program_command): Replace references
5359 to stop_pc with references to thread_info->suspend.stop_pc.
5360 * inferior.h (stop_pc): Delete declaration.
5361 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
5362 (handle_inferior_event_1, handle_signal_stop)
5363 (process_event_stop_test, keep_going_stepped_thread)
5364 (handle_step_into_function, handle_step_into_function_backward)
5365 (print_stop_location): Replace references to stop_pc with
5366 references to thread_info->suspend.stop_pc.
5367 (struct infcall_suspend_state) <stop_pc>: Delete field.
5368 (save_infcall_suspend_state, restore_infcall_suspend_state):
5369 Remove references to inf_stat->stop_pc.
5370 * linux-fork.c (fork_load_infrun_state): Likewise.
5371 * record-btrace.c (record_btrace_set_replay): Likewise.
5372 * record-full.c (record_full_goto_entry): Likewise.
5373 * remote.c (print_one_stopped_thread): Likewise.
5374 * target.c (target_resume): Extend comment.
5375 * thread.c (set_executing_thread): New.
5376 (set_executing): Use it.
5377 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
5378 Remove references to stop_pc.
5379
5380 2018-06-28 Pedro Alves <palves@redhat.com>
5381
5382 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
5383 Moving fetching stop_pc until after ecs->event_thread is refreshed.
5384
5385 2018-06-28 Tom Tromey <tom@tromey.com>
5386
5387 * coffread.c (coff_symfile_finish): Update.
5388 * xcoffread.c (xcoff_symfile_finish): Update.
5389 * elfread.c (elf_symfile_finish): Update.
5390 * symfile.h (dwarf2_free_objfile): Don't declare.
5391 * dwarf2read.c (_initialize_dwarf2_read): Use
5392 register_objfile_data_with_cleanup.
5393 (dwarf2_free_objfile): Now static. Change signature.
5394
5395 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5396
5397 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
5398 option "-o" to add-symbol-file-load to add an offset to each
5399 section's load address.
5400 * symfile.c (set_objfile_default_section_offset): New function.
5401
5402 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5403
5404 * symfile.c (add_symbol_file_command): Make sure that sections
5405 with the same name are sorted in the same order.
5406
5407 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5408
5409 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
5410 require the second argument. If omitted, load sections at the
5411 addresses specified in the file.
5412
5413 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5414
5415 * symfile.c (symbol_file_command, symbol_file_add_main_1)
5416 (_initialize_symfile): Add option "-o" to symbol-file to add an
5417 offset to each section of the symbol file.
5418
5419 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5420
5421 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
5422
5423 2018-06-27 Tom Tromey <tom@tromey.com>
5424
5425 * stack.c (_initialize_stack): Update "func" help text.
5426
5427 2018-06-27 Tom Tromey <tom@tromey.com>
5428
5429 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
5430 std::vector.
5431 (unwind_infopy_str, pyuw_create_unwind_info)
5432 (unwind_infopy_add_saved_register, pyuw_sniffer)
5433 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
5434 Update.
5435 (struct saved_reg): Add constructor.
5436 <value>: Now a gdbpy_ref<>.
5437
5438 2018-06-27 Tom Tromey <tom@tromey.com>
5439
5440 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
5441
5442 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5443
5444 * gdb-gdb.py.in: Format using autopep8.
5445
5446 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5447
5448 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
5449 (type_lookup_function): Recognize CORE_ADDR values.
5450
5451 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5452
5453 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
5454 print tag_name.
5455
5456 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5457
5458 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
5459 <__lt__>: Add.
5460
5461 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5462
5463 * gdb-gdb.py: Move to...
5464 * gdb-gdb.py.in: ... here.
5465 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
5466 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
5467 dependencies.
5468 (distclean): Remove gdb-gdb.py when cleaning.
5469 (gdb-gdb.py, gdb-gdb.gdb): New rules.
5470 * configure: Re-generate.
5471
5472 2018-06-27 Pedro Alves <palves@redhat.com>
5473
5474 * proc-service.c (get_ps_regcache): New.
5475 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
5476 (ps_lsetfpregs): Use it.
5477
5478 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
5479
5480 PR gdb/21695
5481 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
5482 (dwarf_decode_lines_1): Adjust.
5483
5484 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5485
5486 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
5487 override.
5488 <info_proc>: Likewise.
5489
5490 2018-06-26 Joel Brobecker <brobecker@adacore.com>
5491
5492 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
5493 to windows_fetch_one_register, and only handle the case of
5494 fetching one register. Move the code that reloads the context
5495 and iterates over all registers if R is negative to...
5496 (windows_nat_target::fetch_registers): ... here.
5497 (do_windows_store_inferior_registers): Rename to
5498 windows_store_one_register, and only handle the case of storing
5499 one register. Move the code that handles the case where r is
5500 negative to...
5501 (windows_nat_target::store_registers) ... here.
5502
5503 2018-06-26 Tom Tromey <tom@tromey.com>
5504
5505 PR rust/22574:
5506 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
5507 * rust-lang.c (rust_print_struct_def): Add podata parameter.
5508 Update.
5509 (rust_internal_print_type): Add podata parameter.
5510 (rust_print_type): Update.
5511
5512 2018-06-26 Tom Tromey <tom@tromey.com>
5513
5514 * typeprint.h (struct print_offset_data) <update, finish,
5515 maybe_print_hole>: New methods.
5516 <indentation>: New constant.
5517 * typeprint.c (print_offset_data::indentation): Define.
5518 (print_offset_data::maybe_print_hole, print_offset_data::update)
5519 (print_offset_data::finish): Move from c-typeprint.c and rename.
5520 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
5521 (print_spaces_filtered_with_print_options): Update.
5522 (c_print_type_union_field_offset, maybe_print_hole)
5523 (c_print_type_struct_field_offset): Move to typeprint.c and
5524 rename.
5525 (c_type_print_base_struct_union): Update.
5526
5527 2018-06-25 Pedro Alves <palves@redhat.com>
5528
5529 * gdbthread.h (thread_info_ref, delete_thread)
5530 (delete_thread_silent, first_thread_of_inferior)
5531 (any_thread_of_inferior, switch_to_thread)
5532 (enable_thread_stack_temporaries)
5533 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5534 (get_last_thread_stack_temporary)
5535 (value_in_thread_stack_temporaries, can_access_registers_thread):
5536 Spell out "struct thread_info" instead of just "thread_info".
5537 * inferior.h (notice_new_inferior): Likewise.
5538
5539 2018-06-25 Pedro Alves <palves@redhat.com>
5540
5541 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5542 pass thread_info pointer to delete_thread.
5543 (windows_nat_target::detach): Pass inferior pointer to
5544 detach_inferior.
5545 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
5546 delete_thread.
5547 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
5548 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
5549 and pass a thread_info pointer to delete_thread.
5550 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
5551 pass thread_info pointer to delete_thread.
5552 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
5553 delete_thread_silent call.
5554 * procfs.c (procfs_target::detach): Pass inferior pointer to
5555 detach_inferior.
5556 (procfs_target::wait): Pass thread_info pointer to delete_thread.
5557 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
5558 delete_thread_silent call.
5559 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5560 pass thread_info pointer to delete_thread.
5561 (windows_nat_target::detach): Pass inferior pointer to
5562 delete_inferior.
5563
5564 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5565
5566 * regcache.c (readable_regcache::read_part): Fix asserts.
5567 (reg_buffer::raw_collect_part): New function.
5568 (regcache::write_part): Fix asserts.
5569 (reg_buffer::raw_supply_part): New function.
5570 (regcache::transfer_regset_register): New helper function.
5571 (regcache::transfer_regset): Call new functions.
5572 (regcache_supply_regset): Use gdb_byte*.
5573 (regcache::supply_regset): Likewise.
5574 (regcache_collect_regset): Likewise.
5575 (regcache::collect_regset): Likewise.
5576 * regcache.h (reg_buffer::raw_collect_part): New declaration.
5577 (reg_buffer::raw_supply_part): Likewise.
5578 (regcache::transfer_regset_register): Likewise.
5579 (regcache::transfer_regset): Use gdb_byte*.
5580
5581 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5582
5583 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
5584
5585 2018-06-21 Pedro Alves <palves@redhat.com>
5586
5587 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
5588 instead of a ptid_t. All callers adjusted.
5589 * ada-tasks.c (ada_get_task_number): Likewise. All callers
5590 adjusted.
5591 (print_ada_task_info, display_current_task_id, task_command_1):
5592 Adjust.
5593 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
5594 inferior_thread.
5595 (breakpoint_kind): Adjust.
5596 (remove_breakpoints_pid): Rename to ...
5597 (remove_breakpoints_inf): ... this. Adjust to take an inferior
5598 pointer. All callers adjusted.
5599 (bpstat_clear_actions): Use inferior_thread.
5600 (get_bpstat_thread): New.
5601 (bpstat_do_actions): Use it.
5602 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
5603 to take a thread_info pointer. All callers adjusted.
5604 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
5605 (breakpoint_re_set_thread): Use inferior_thread.
5606 * breakpoint.h (struct inferior): Forward declare.
5607 (bpstat_stop_status): Update.
5608 (remove_breakpoints_pid): Delete.
5609 (remove_breakpoints_inf): New.
5610 * bsd-uthread.c (bsd_uthread_target::wait)
5611 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
5612 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
5613 (maint_btrace_packet_history_cmd)
5614 (maint_btrace_clear_packet_history_cmd): Adjust.
5615 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
5616 inferior_thread.
5617 * cli/cli-interp.c: Include "inferior.h".
5618 * common/refcounted-object.h (struct
5619 refcounted_object_ref_policy): New.
5620 * compile/compile-object-load.c: Include gdbthread.h.
5621 (store_regs): Use inferior_thread.
5622 * corelow.c (core_target::close): Use current_inferior.
5623 (core_target_open): Adjust to use first_thread_of_inferior and use
5624 the current inferior.
5625 * ctf.c (ctf_target::close): Adjust to use current_inferior.
5626 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
5627 <thread>: ... this new field. All references adjusted.
5628 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
5629 Take a thread_info pointer instead of a ptid_t.
5630 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
5631 (dummy_frame_discard, register_dummy_frame_dtor): Take a
5632 thread_info pointer instead of a ptid_t.
5633 * elfread.c: Include "inferior.h".
5634 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
5635 Use inferior_thread.
5636 * eval.c (evaluate_subexp): Likewise.
5637 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
5638 inferior_thread.
5639 * gdb_proc_service.h (struct thread_info): Forward declare.
5640 (struct ps_prochandle) <ptid>: Delete, replaced by ...
5641 <thread>: ... this new field. All references adjusted.
5642 * gdbarch.h, gdbarch.c: Regenerate.
5643 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
5644 'thread' parameter. All implementations and callers adjusted.
5645 * gdbthread.h (thread_info) <set_running>: New method.
5646 (delete_thread, delete_thread_silent): Take a thread_info pointer
5647 instead of a ptid.
5648 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
5649 (first_thread_of_process): Delete, replaced by ...
5650 (first_thread_of_inferior): ... this new function. All callers
5651 adjusted.
5652 (any_live_thread_of_process): Delete, replaced by ...
5653 (any_live_thread_of_inferior): ... this new function. All callers
5654 adjusted.
5655 (switch_to_thread, switch_to_no_thread): Declare.
5656 (is_executing): Delete.
5657 (enable_thread_stack_temporaries): Update comment.
5658 <enable_thread_stack_temporaries>: Take a thread_info pointer
5659 instead of a ptid_t. Incref the thread.
5660 <~enable_thread_stack_temporaries>: Decref the thread.
5661 <m_ptid>: Delete
5662 <m_thr>: New.
5663 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5664 (get_last_thread_stack_temporary)
5665 (value_in_thread_stack_temporaries, can_access_registers_thread):
5666 Take a thread_info pointer instead of a ptid_t. All callers
5667 adjusted.
5668 * infcall.c (get_call_return_value): Use inferior_thread.
5669 (run_inferior_call): Work with thread pointers instead of ptid_t.
5670 (call_function_by_hand_dummy): Work with thread pointers instead
5671 of ptid_t. Use thread_info_ref.
5672 * infcmd.c (proceed_thread_callback): Access thread's state
5673 directly.
5674 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
5675 access thread's state directly.
5676 (continue_command): Use inferior_thread.
5677 (info_program_command): Use find_thread_ptid and access thread
5678 state directly.
5679 (proceed_after_attach_callback): Use thread state directly.
5680 (notice_new_inferior): Take a thread_info pointer instead of a
5681 ptid_t. All callers adjusted.
5682 (exit_inferior): Take an inferior pointer instead of a pid. All
5683 callers adjusted.
5684 (exit_inferior_silent): New.
5685 (detach_inferior): Delete.
5686 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
5687 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
5688 (detach_inferior_command, kill_inferior_command): Use
5689 find_inferior_id instead of valid_gdb_inferior_id and
5690 gdb_inferior_id_to_pid.
5691 (inferior_command): Use inferior and thread pointers.
5692 * inferior.h (struct thread_info): Forward declare.
5693 (notice_new_inferior): Take a thread_info pointer instead of a
5694 ptid_t. All callers adjusted.
5695 (detach_inferior): Delete declaration.
5696 (exit_inferior, exit_inferior_silent): Take an inferior pointer
5697 instead of a pid. All callers adjusted.
5698 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
5699 (valid_gdb_inferior_id): Delete.
5700 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
5701 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
5702 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
5703 ...
5704 <inf>: ... this new field.
5705 <step_ptid>: Delete, replaced by ...
5706 <step_thread>: ... this new field.
5707 (get_displaced_stepping_state): Take an inferior pointer instead
5708 of a pid. All callers adjusted.
5709 (displaced_step_in_progress_any_inferior): Adjust.
5710 (displaced_step_in_progress_thread): Take a thread pointer instead
5711 of a ptid_t. All callers adjusted.
5712 (displaced_step_in_progress, add_displaced_stepping_state): Take
5713 an inferior pointer instead of a pid. All callers adjusted.
5714 (get_displaced_step_closure_by_addr): Adjust.
5715 (remove_displaced_stepping_state): Take an inferior pointer
5716 instead of a pid. All callers adjusted.
5717 (displaced_step_prepare_throw, displaced_step_prepare)
5718 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
5719 All callers adjusted.
5720 (start_step_over): Adjust.
5721 (infrun_thread_ptid_changed): Remove bit updating ptids in the
5722 displaced step queue.
5723 (do_target_resume): Adjust.
5724 (fetch_inferior_event): Use inferior_thread.
5725 (context_switch, get_inferior_stop_soon): Take an
5726 execution_control_state pointer instead of a ptid_t. All callers
5727 adjusted.
5728 (switch_to_thread_cleanup): Delete.
5729 (stop_all_threads): Use scoped_restore_current_thread.
5730 * inline-frame.c: Include "gdbthread.h".
5731 (inline_state) <inline_state>: Take a thread pointer instead of a
5732 ptid_t. All callers adjusted.
5733 <ptid>: Delete, replaced by ...
5734 <thread>: ... this new field.
5735 (find_inline_frame_state): Take a thread pointer instead of a
5736 ptid_t. All callers adjusted.
5737 (skip_inline_frames, step_into_inline_frame)
5738 (inline_skipped_frames, inline_skipped_symbol): Take a thread
5739 pointer instead of a ptid_t. All callers adjusted.
5740 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
5741 (inline_skipped_frames, inline_skipped_symbol): Likewise.
5742 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
5743 pointers directly.
5744 * linux-nat.c (get_detach_signal): Likewise.
5745 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
5746 (thread_db_notice_clone): Adjust.
5747 (thread_db_find_new_threads_silently)
5748 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
5749 a thread pointer instead of a ptid_t. All callers adjusted.
5750 * mi/mi-cmd-var.c: Include "inferior.h".
5751 (mi_cmd_var_update_iter): Update to use thread pointers.
5752 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
5753 inferior directly.
5754 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
5755 out to ...
5756 (mi_output_running): ... this new function.
5757 (mi_on_resume_1): Adjust to use it.
5758 (mi_user_selected_context_changed): Adjust to use inferior_thread.
5759 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
5760 directly.
5761 (interrupt_thread_callback): : Adjust to use thread and inferior
5762 pointers.
5763 * proc-service.c: Include "gdbthread.h".
5764 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
5765 * progspace-and-thread.c: Include "inferior.h".
5766 * progspace.c: Include "inferior.h".
5767 * python/py-exitedevent.c (create_exited_event_object): Adjust to
5768 hold a reference to an inferior_object.
5769 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
5770 inferior_thread.
5771 * python/py-inferior.c (struct inferior_object): Give the type a
5772 tag name instead of a typedef.
5773 (python_on_normal_stop): No need to check if the current thread is
5774 listed.
5775 (inferior_to_inferior_object): Change return type to
5776 inferior_object. All callers adjusted.
5777 (find_thread_object): Delete, bits factored out to ...
5778 (thread_to_thread_object): ... this new function.
5779 * python/py-infthread.c (create_thread_object): Use
5780 inferior_to_inferior_object.
5781 (thpy_is_stopped): Use thread pointer directly.
5782 (gdbpy_selected_thread): Use inferior_thread.
5783 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
5784 field, replaced with ...
5785 <thread>: ... this new field. All users adjusted.
5786 (btpy_insn_or_gap_new): Drop const.
5787 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
5788 callers adjusted.
5789 * python/py-record.c: Include "gdbthread.h".
5790 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5791 a ptid_t. All callers adjusted.
5792 (gdbpy_current_recording): Use inferior_thread.
5793 * python/py-record.h (recpy_record_object) <ptid>: Delete
5794 field, replaced with ...
5795 <thread>: ... this new field. All users adjusted.
5796 (recpy_element_object) <ptid>: Delete
5797 field, replaced with ...
5798 <thread>: ... this new field. All users adjusted.
5799 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5800 a ptid_t. All callers adjusted.
5801 * python/py-threadevent.c: Include "gdbthread.h".
5802 (get_event_thread): Use thread_to_thread_object.
5803 * python/python-internal.h (struct inferior_object): Forward
5804 declare.
5805 (find_thread_object, find_inferior_object): Delete declarations.
5806 (thread_to_thread_object, inferior_to_inferior_object): New
5807 declarations.
5808 * record-btrace.c: Include "inferior.h".
5809 (require_btrace_thread): Use inferior_thread.
5810 (record_btrace_frame_sniffer)
5811 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
5812 (get_thread_current_frame): Use scoped_restore_current_thread and
5813 switch_to_thread.
5814 (get_thread_current_frame): Use thread pointer directly.
5815 (record_btrace_replay_at_breakpoint): Use thread's inferior
5816 pointer directly.
5817 * record-full.c: Include "inferior.h".
5818 * regcache.c: Include "gdbthread.h".
5819 (get_thread_arch_regcache): Use the inferior's address space
5820 directly.
5821 (get_thread_regcache, registers_changed_thread): New.
5822 * regcache.h (get_thread_regcache(thread_info *thread)): New
5823 overload.
5824 (registers_changed_thread): New.
5825 (remote_target) <remote_detach_1>: Swap order of parameters.
5826 (remote_add_thread): <remote_add_thread>: Return the new thread.
5827 (get_remote_thread_info(ptid_t)): New overload.
5828 (remote_target::remote_notice_new_inferior): Use thread pointers
5829 directly.
5830 (remote_target::process_initial_stop_replies): Use
5831 thread_info::set_running.
5832 (remote_target::remote_detach_1, remote_target::detach)
5833 (extended_remote_target::detach): Adjust.
5834 * stack.c (frame_show_address): Use inferior_thread.
5835 * target-debug.h (target_debug_print_thread_info_pp): New.
5836 * target-delegates.c: Regenerate.
5837 * target.c (default_thread_address_space): Delete.
5838 (memory_xfer_partial_1): Use current_inferior.
5839 (target_detach): Use current_inferior.
5840 (target_thread_address_space): Delete.
5841 (generic_mourn_inferior): Use current_inferior.
5842 * target.h (struct target_ops) <thread_address_space>: Delete.
5843 (target_thread_address_space): Delete.
5844 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
5845 pointers directly.
5846 (delete_thread_1, delete_thread, delete_thread_silent): Take a
5847 thread pointer instead of a ptid_t. Adjust all callers.
5848 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
5849 (first_thread_of_process): Delete, replaced by ...
5850 (first_thread_of_inferior): ... this new function. All callers
5851 adjusted.
5852 (any_thread_of_process): Rename to ...
5853 (any_thread_of_inferior): ... this, and take an inferior pointer.
5854 (any_live_thread_of_process): Rename to ...
5855 (any_live_thread_of_inferior): ... this, and take an inferior
5856 pointer.
5857 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5858 (value_in_thread_stack_temporaries)
5859 (get_last_thread_stack_temporary): Take a thread pointer instead
5860 of a ptid_t. Adjust all callers.
5861 (thread_info::set_running): New.
5862 (validate_registers_access): Use inferior_thread.
5863 (can_access_registers_ptid): Rename to ...
5864 (can_access_registers_thread): ... this, and take a thread
5865 pointer.
5866 (print_thread_info_1): Adjust to compare thread pointers instead
5867 of ptids.
5868 (switch_to_no_thread, switch_to_thread): Make extern.
5869 (scoped_restore_current_thread::~scoped_restore_current_thread):
5870 Use m_thread pointer directly.
5871 (scoped_restore_current_thread::scoped_restore_current_thread):
5872 Use inferior_thread.
5873 (thread_command): Use thread pointer directly.
5874 (thread_num_make_value_helper): Use inferior_thread.
5875 * top.c (execute_command): Use inferior_thread.
5876 * tui/tui-interp.c: Include "inferior.h".
5877 * varobj.c (varobj_create): Use inferior_thread.
5878 (value_of_root_1): Use find_thread_global_id instead of
5879 global_thread_id_to_ptid.
5880
5881 2018-06-21 Alan Hayward <alan.hayward@arm.com>
5882
5883 * regcache.c (readable_regcache::read_part): Avoid memcpy when
5884 possible.
5885 (regcache::write_part): Likewise.
5886 (readable_regcache::cooked_read_part): Update comment.
5887 (readable_regcache::cooked_write_part): Likewise.
5888 * regcache.h: (readable_regcache::read_part): Likewise.
5889 (regcache::write_part): Likewise.
5890
5891 2018-06-21 Richard Bunt <richard.bunt@arm.com>
5892 Dirk Schubert <dirk.schubert@arm.com>
5893
5894 * aarch64-linux-nat.c (post_attach): New.
5895 (aarch64_linux_nat_target::post_attach): Override post_attach to
5896 record the number of hardware debug registers.
5897
5898 2018-06-20 Tom Tromey <tom@tromey.com>
5899
5900 * python/py-param.c (add_setshow_generic): Make parameters const.
5901 (parmpy_init): Update.
5902
5903 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5904
5905 * regcache.h (regcache_cooked_read_ftype): Rename to...
5906 (register_read_ftype): ...this, change type to function_view.
5907 (class reg_buffer) <save>: Remove src parameter.
5908 (readonly_detached_regcache) <readonly_detached_regcache>: Make
5909 parameter non-const in first overload. Remove src parameter in
5910 second overload.
5911 * regcache.c (do_cooked_read): Remove.
5912 (readonly_detached_regcache::readonly_detached_regcache): Make
5913 parameter non-const, adjust call to other constructor.
5914 (reg_buffer::save): Remove src parameter.
5915 * frame.c (do_frame_register_read): Remove.
5916 (frame_save_as_regcache): Use lambda function.
5917 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
5918 parameter to ppu2spu_data *.
5919 (ppu2spu_sniffer): Use lambda function.
5920
5921 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5922
5923 * record-full.c (record_full_target::insert_breakpoint): Remove
5924 "struct" keyword, add const.
5925
5926 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5927
5928 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
5929 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
5930 * configure.ac: Remove AC_PREREQ, add missing quoting.
5931 * gnulib/configure.ac: Modernize usage of
5932 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
5933 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
5934 (AUTOMAKE_VERSION): Bump to 1.15.1.
5935 * configure: Re-generate.
5936 * config.in: Re-generate.
5937 * aclocal.m4: Re-generate.
5938 * gnulib/aclocal.m4: Re-generate.
5939 * gnulib/config.in: Re-generate.
5940 * gnulib/configure: Re-generate.
5941 * gnulib/import/Makefile.in: Re-generate.
5942
5943 2018-06-19 Pedro Alves <palves@redhat.com>
5944
5945 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
5946 (lookup_minimal_symbol_by_pc_section): ... here with
5947 gdb_assert_not_reached added.
5948
5949 2018-06-19 Pedro Alves <palves@redhat.com>
5950
5951 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
5952 parameter with a block parameter. Compare location's block symbol
5953 with the frame's block instead of addresses.
5954 (skip_inline_frames): Pass the current block instead of the
5955 frame's address. Break out as soon as we determine the frame
5956 should not be skipped.
5957
5958 2018-06-18 Tom Tromey <tom@tromey.com>
5959
5960 * solib-aix.c (solib_aix_get_section_offsets): Return
5961 unique_xmalloc_ptr.
5962 (solib_aix_solib_create_inferior_hook): Update.
5963
5964 2018-06-18 Tom Tromey <tom@tromey.com>
5965
5966 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5967
5968 2018-06-18 Tom Tromey <tom@tromey.com>
5969
5970 * solib-frv.c (frv_relocate_main_executable): Use
5971 unique_xmalloc_ptr.
5972 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5973 unique_xmalloc_ptr.
5974
5975 2018-06-18 Tom Tromey <tom@tromey.com>
5976
5977 * objfiles.h (inhibit_section_map_updates): Update.
5978 (resume_section_map_updates, resume_section_map_updates_cleanup):
5979 Remove.
5980 * solib-svr4.c (svr4_handle_solib_event): Update.
5981 * objfiles.c (inhibit_section_map_updates): Return
5982 scoped_restore_tmpl<int>.
5983 (resume_section_map_updates, resume_section_map_updates_cleanup):
5984 Remove.
5985
5986 2018-06-18 Tom Tromey <tom@tromey.com>
5987
5988 * valprint.h (read_string): Update.
5989 * valprint.c (read_string): Change type of "buffer".
5990 (val_print_string): Update.
5991 * python/py-value.c (valpy_string): Update.
5992 * language.h (struct language_defn) <la_get_string>: Change
5993 type of "buffer".
5994 (default_get_string, c_get_string): Update.
5995 * language.c (default_get_string): Change type of "buffer".
5996 * guile/scm-value.c (gdbscm_value_to_string): Update.
5997 * c-lang.c (c_get_string): Change type of "buffer".
5998
5999 2018-06-18 Tom Tromey <tom@tromey.com>
6000
6001 * ser-mingw.c (struct pipe_state_destroyer): New.
6002 (pipe_state_up): New typedef.
6003 (cleanup_pipe_state): Remove.
6004 (pipe_windows_open): Use pipe_state_up. Don't release argv.
6005
6006 2018-06-18 Tom Tromey <tom@tromey.com>
6007
6008 * rust-lang.h (rust_yyerror): Don't declare.
6009 * rust-lang.c (rust_language_defn): Update.
6010 * rust-exp.y (yyerror): Now static.
6011 * parse.c (parse_exp_in_context_1): Update.
6012 * p-lang.h (p_yyerror): Don't declare.
6013 * p-lang.c (p_language_defn): Update.
6014 * p-exp.y (yyerror): Now static.
6015 * opencl-lang.c (opencl_language_defn): Update.
6016 * objc-lang.c (objc_language_defn): Update.
6017 * m2-lang.h (m2_yyerror): Don't declare.
6018 * m2-lang.c (m2_language_defn): Update.
6019 * m2-exp.y (yyerror): Now static.
6020 * language.h (struct language_defn) <la_error>: Remove.
6021 * language.c (unk_lang_error): Remove.
6022 (unknown_language_defn, auto_language_defn): Remove.
6023 * go-lang.h (go_yyerror): Don't declare.
6024 * go-lang.c (go_language_defn): Update.
6025 * go-exp.y (yyerror): Now static.
6026 * f-lang.h (f_yyerror): Don't declare.
6027 * f-lang.c (f_language_defn): Update.
6028 * f-exp.y (yyerror): Now static.
6029 * d-lang.h (d_yyerror): Don't declare.
6030 * d-lang.c (d_language_defn): Update.
6031 * d-exp.y (yyerror): Now static.
6032 * c-lang.h (c_yyerror): Don't declare.
6033 * c-lang.c (c_language_defn, cplus_language_defn)
6034 (asm_language_defn, minimal_language_defn): Update.
6035 * c-exp.y (yyerror): Now static.
6036 * ada-lang.h (ada_yyerror): Don't declare.
6037 * ada-lang.c (ada_language_defn): Update.
6038 * ada-exp.y (yyerror): Now static.
6039
6040 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6041
6042 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
6043 (store_sveregs_to_thread): Likewise.
6044 (aarch64_linux_fetch_inferior_registers): Check for SVE.
6045 (aarch64_linux_store_inferior_registers): Likewise.
6046 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
6047 function.
6048 (aarch64_sve_regs_copy_to_regcache): Likewise.
6049 (aarch64_sve_regs_copy_from_regcache): Likewise.
6050 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
6051 declaration.
6052 (aarch64_sve_regs_copy_to_regcache): Likewise.
6053 (aarch64_sve_regs_copy_from_regcache): Likewise.
6054 (sve_context): Structure from Linux headers.
6055 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
6056 (SVE_SIG_ZREG_SIZE): Likewise.
6057 (SVE_SIG_PREG_SIZE): Likewise.
6058 (SVE_SIG_FFR_SIZE): Likewise.
6059 (SVE_SIG_REGS_OFFSET): Likewise.
6060 (SVE_SIG_ZREGS_OFFSET): Likewise.
6061 (SVE_SIG_ZREG_OFFSET): Likewise.
6062 (SVE_SIG_ZREGS_SIZE): Likewise.
6063 (SVE_SIG_PREGS_OFFSET): Likewise.
6064 (SVE_SIG_PREG_OFFSET): Likewise.
6065 (SVE_SIG_PREGS_SIZE): Likewise.
6066 (SVE_SIG_FFR_OFFSET): Likewise.
6067 (SVE_SIG_REGS_SIZE): Likewise.
6068 (SVE_SIG_CONTEXT_SIZE): Likewise.
6069 (SVE_PT_REGS_MASK): Likewise.
6070 (SVE_PT_REGS_FPSIMD): Likewise.
6071 (SVE_PT_REGS_SVE): Likewise.
6072 (SVE_PT_VL_INHERIT): Likewise.
6073 (SVE_PT_VL_ONEXEC): Likewise.
6074 (SVE_PT_REGS_OFFSET): Likewise.
6075 (SVE_PT_FPSIMD_OFFSET): Likewise.
6076 (SVE_PT_FPSIMD_SIZE): Likewise.
6077 (SVE_PT_SVE_ZREG_SIZE): Likewise.
6078 (SVE_PT_SVE_PREG_SIZE): Likewise.
6079 (SVE_PT_SVE_FFR_SIZE): Likewise.
6080 (SVE_PT_SVE_FPSR_SIZE): Likewise.
6081 (SVE_PT_SVE_FPCR_SIZE): Likewise.
6082 (__SVE_SIG_TO_PT): Likewise.
6083 (SVE_PT_SVE_OFFSET): Likewise.
6084 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
6085 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
6086 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
6087 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
6088 (SVE_PT_SVE_PREG_OFFSET): Likewise.
6089 (SVE_PT_SVE_PREGS_SIZE): Likewise.
6090 (SVE_PT_SVE_FFR_OFFSET): Likewise.
6091 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
6092 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
6093 (SVE_PT_SVE_SIZE): Likewise.
6094 (SVE_PT_SIZE): Likewise.
6095 (HAS_SVE_STATE): New define.
6096
6097 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6098
6099 * nat/aarch64-sve-linux-sigcontext.h: New file.
6100 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
6101 new files.
6102 (SVE_VQ_MIN): Likewise.
6103 (SVE_VQ_MAX): Likewise.
6104 (SVE_VL_MIN): Likewise.
6105 (SVE_VL_MAX): Likewise.
6106 (SVE_NUM_ZREGS): Likewise.
6107 (SVE_NUM_PREGS): Likewise.
6108 (sve_vl_valid): Likewise.
6109 (struct user_sve_header): Likewise.
6110
6111 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
6112 Richard Bunt <Richard.Bunt@arm.com>
6113
6114 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
6115 was requested by GDB.
6116
6117 2018-06-15 Tom de Vries <tdevries@suse.de>
6118
6119 * MAINTAINERS (Write After Approval): Add Tom de Vries.
6120
6121 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
6122
6123 * gnulib/update-gnulib.sh: Print expected versions of
6124 autoconf/aclocal.
6125
6126 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
6127
6128 * arch-utils.c (default_type_align): Use type_length_units.
6129 * gdbtypes.c (type_align): Use type_length_units.
6130
6131 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6132
6133 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
6134 of 'define' command.
6135
6136 2018-06-14 Tom de Vries <tdevries@suse.de>
6137
6138 PR cli/22573
6139 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
6140 get_no_prettyformat_print_options.
6141
6142 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
6143
6144 * sparc-nat.h: Include target.h.
6145 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
6146 <fetch_registers>: Remove this argument in function call.
6147 <store_registers>: Remove this argument in function call, remove
6148 extra semicolon.
6149 <low_forget_process>: Call sparc64_forget_process instead of
6150 sparc_forget_process.
6151
6152 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6153
6154 * procfs.c (_initialize_procfs): Use add_inf_child_target.
6155 (procfs_target::make_corefile_notes): Adjust to new
6156 target_read_alloc return type.
6157
6158 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6159 Stephen Roberts <stephen.roberts@arm.com>
6160
6161 PR gdb/22882
6162 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
6163 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
6164 Move should_notify_stop local into more inner scope.
6165
6166 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6167 Stephen Roberts <stephen.roberts@arm.com>
6168
6169 PR gdb/22882
6170 * infrun.c (resume_1): Add call to mark_async_event_handler.
6171
6172 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6173
6174 * infrun.c (do_target_wait): Change old version of $pc printed.
6175
6176 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
6177
6178 * dwarf2read.c (read_index_from_section): Rename to...
6179 (read_gdb_index_from_section): ... this, update all callers.
6180 (dwarf2_read_index): Rename to...
6181 (dwarf2_read_gdb_index): ... this, update all callers.
6182
6183 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
6184
6185 * gdb/hppa-linux-nat.c
6186 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
6187 hppa_linux_nat_target::fetch_registers.
6188
6189 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6190
6191 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
6192 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
6193 (AARCH64_DWARF_SVE_FFR): Likewise.
6194 (AARCH64_DWARF_SVE_P0): Likewise.
6195 (AARCH64_DWARF_SVE_Z0): Likewise.
6196
6197 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6198
6199 * common/common-regcache.h (raw_compare): New function.
6200 * regcache.c (regcache::raw_compare): Likewise.
6201 * regcache.h (regcache::raw_compare): New declaration.
6202
6203 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6204
6205 * common/common-regcache.h (reg_buffer_common): New structure.
6206 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
6207 (reg_buffer::raw_supply): Likewise.
6208 (reg_buffer::raw_supply_integer): Likewise.
6209 (reg_buffer::raw_supply_zeroed): Likewise.
6210 (reg_buffer::raw_collect): Likewise.
6211 (reg_buffer::raw_collect_integer): Likewise.
6212 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
6213 (reg_buffer::raw_supply): Likewise.
6214 (reg_buffer::raw_supply_integer): Likewise.
6215 (reg_buffer::raw_supply_zeroed): Likewise.
6216 (reg_buffer::raw_collect): Likewise.
6217 (reg_buffer::raw_collect_integer): Likewise.
6218
6219 2018-06-10 Tom Tromey <tom@tromey.com>
6220
6221 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
6222 (class remote_state) <stop_reply_queue>: Now std::vector.
6223 (remote_state::~remote_state)
6224 (remote_target::stop_reply_queue_length): Update.
6225 (struct queue_iter_param, remove_child_of_pending_fork)
6226 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
6227 (check_pending_event_prevents_wildcard_vcont_callback)
6228 (remove_stop_reply_for_inferior)
6229 (remove_stop_reply_of_remote_state)
6230 (remote_notif_remove_once_on_match)
6231 (stop_reply_match_ptid_and_ws)
6232 (remote_kill_child_of_pending_fork): Remove.
6233 (remote_target::remove_new_fork_children)
6234 (remote_target::check_pending_events_prevent_wildcard_vcont)
6235 (remote_target::discard_pending_stop_replies)
6236 (remote_target::discard_pending_stop_replies_in_queue)
6237 (remote_target::remote_notif_remove_queued_reply)
6238 (remote_target::queued_stop_reply)
6239 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
6240 (remote_target::wait, remote_target::kill_new_fork_children)
6241 (remote_target::async): Update.
6242
6243 2018-06-10 Tom Tromey <tom@tromey.com>
6244
6245 * record-full.c (record_full_arch_list_cleanups): Remove.
6246 (record_full_message): Use try/catch.
6247 (record_full_wait_cleanups): Remove.
6248 (record_full_wait_1): Use try/catch.
6249 (record_full_restore): Likewise.
6250
6251 2018-06-10 Tom Tromey <tom@tromey.com>
6252
6253 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
6254 declare VEC. Add constructor.
6255 <in_target_beneath>: Now bool.
6256 (record_full_breakpoints): Now a std::vector, static.
6257 (record_full_sync_record_breakpoints)
6258 (record_full_init_record_breakpoints)
6259 (record_full_target::insert_breakpoint)
6260 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
6261
6262 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
6263
6264 * dwarf2read.c (process_cu_includes): Remove struct keyword.
6265 * serial.c (serial_interface_lookup): Remove struct keyword.
6266
6267 2018-06-10 Tom Tromey <tom@tromey.com>
6268
6269 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
6270 method.
6271 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
6272 a method.
6273 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
6274 method.
6275 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
6276 "beneath" as a method.
6277 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
6278 Use "beneath" as a method.
6279
6280 2018-06-10 Tom Tromey <tom@tromey.com>
6281
6282 * tracefile.c (struct trace_file_writer_deleter): New.
6283 <operator()>: Rename from trace_file_writer_xfree.
6284 (trace_file_writer_up): New typedef.
6285 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
6286
6287 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6288
6289 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
6290 <m_registers, m_register_status>: Change type to
6291 std::unique_ptr.
6292 * regcache.c (reg_buffer::reg_buffer): Use new instead of
6293 XCNEWVEC.
6294
6295 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6296
6297 * common/common-regcache.h (enum register_status): Add
6298 underlying type "signed char".
6299 * regcache.h (reg_buffer) <m_register_status>: Change type to
6300 register_status *.
6301 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
6302 register_status instead of signed char.
6303 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
6304 (reg_buffer::get_register_status): Remove cast.
6305 (readable_regcache::raw_read): Remove cast.
6306 (readable_regcache::cooked_read): Remove cast.
6307
6308 2018-06-09 Tom Tromey <tom@tromey.com>
6309
6310 * source.c (reverse_search_command, forward_search_command): Use
6311 scoped_fd.
6312
6313 2018-06-09 Tom Tromey <tom@tromey.com>
6314
6315 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
6316 (serial_ops_list): Now static, std::vector.
6317 (serial_interface_lookup, serial_add_interface): Update.
6318
6319 2018-06-09 Tom Tromey <tom@tromey.com>
6320
6321 * dwarf2read.c (process_cu_includes): Update.
6322 (process_full_comp_unit): Update.
6323 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
6324 std::vector.
6325
6326 2018-06-08 Paul Koning <paul_koning@dell.com>
6327
6328 PR gdb/23252
6329
6330 * python/python.c (do_start_initialization):
6331 Avoid call to internal Python API.
6332 (init__gdb_module): New function.
6333
6334 2018-06-08 Gary Benson <gbenson@redhat.com>
6335
6336 * linux-thread-db.c (valprint.h): New include.
6337 (struct check_thread_db_info): New structure.
6338 (check_thread_db_on_load, tdb_testinfo): New static globals.
6339 (check_thread_db, check_thread_db_callback): New functions.
6340 (try_thread_db_load_1): Run integrity checks if requested.
6341 (maintenance_check_libthread_db): New function.
6342 (_initialize_thread_db): Register "maint check libthread-db"
6343 and "maint set/show check-libthread-db".
6344 * NEWS: Mention the above new commands.
6345
6346 2018-06-08 Tom Tromey <tom@tromey.com>
6347
6348 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
6349 now a method.
6350
6351 2018-06-08 Tom Tromey <tom@tromey.com>
6352
6353 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
6354
6355 2018-06-08 Tom Tromey <tom@tromey.com>
6356
6357 * common/btrace-common.h (struct btrace_data): Add constructor,
6358 destructor, move assignment operator.
6359 <empty, clear, fini>: New methods.
6360 <format>: Initialize.
6361 (btrace_data_init, btrace_data_fini, btrace_data_clear)
6362 (btrace_data_empty): Don't declare.
6363 * common/btrace-common.c (btrace_data_init): Remove.
6364 (btrace_data::fini): Rename from btrace_data_fini.
6365 (btrace_data::empty): Rename from btrace_data_empty.
6366 (btrace_data::clear): Rename from btrace_data_clear. Return
6367 bool.
6368 * btrace.h (make_cleanup_btrace_data): Don't declare.
6369 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
6370 (parse_xml_btrace): Update.
6371 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
6372 (maint_btrace_clear_packet_history_cmd): Update.
6373
6374 2018-06-07 Pedro Alves <palves@redhat.com>
6375
6376 * target.h (target_ops) <beneath>: Now a method. All references
6377 updated.
6378 (class target_stack): New.
6379 * target.c (g_target_stack): New.
6380 (g_current_top_target): Delete.
6381 (current_top_target): Get the top target out of g_target_stack.
6382 (target_stack::push, target_stack::unpush): New.
6383 (push_target, unpush_target): Reimplement.
6384 (target_is_pushed): Reimplement in terms of g_target_stack.
6385 (target_ops::beneath, target_stack::find_beneath): New.
6386
6387 2018-06-07 Pedro Alves <palves@redhat.com>
6388
6389 * target.h (find_target_beneath): Delete declaration.
6390 * target.c (find_target_beneath): Delete definition.
6391 * aix-thread.c: All callers of find_target_beneath adjusted to
6392 call target_ops::beneath instead.
6393 * bsd-uthread.c: Likewise.
6394 * linux-thread-db.c: Likewise.
6395 * ravenscar-thread.c: Likewise.
6396 * sol-thread.c: Likewise.
6397 * spu-multiarch.c: Likewise.
6398
6399 2018-06-07 Pedro Alves <palves@redhat.com>
6400
6401 * target.h (target_ops) <beneath>: Now a method. All references
6402 updated.
6403 (target_ops) <m_beneath>: New.
6404 * target.c (target_ops::beneath): New.
6405 * corelow.c: Adjust all references to target_ops::beneath.
6406 * linux-thread-db.c: Likewise.
6407 * make-target-delegates: Likewise.
6408 * record-btrace.c: Likewise.
6409 * record-full.c: Likewise.
6410 * remote.c: Likewise.
6411 * target.c: Likewise.
6412 * target-delegates.c: Regenerate.
6413
6414 2018-06-07 Pedro Alves <palves@redhat.com>
6415
6416 * target.h (target_stack): Delete.
6417 (current_top_target): Declare function.
6418 * target.c (target_stack): Delete.
6419 (g_current_top_target): New.
6420 (current_top_target): New function.
6421 * auxv.c: Use current_top_target instead of target_stack
6422 throughout.
6423 * avr-tdep.c: Likewise.
6424 * breakpoint.c: Likewise.
6425 * corefile.c: Likewise.
6426 * elfread.c: Likewise.
6427 * eval.c: Likewise.
6428 * exceptions.c: Likewise.
6429 * frame.c: Likewise.
6430 * gdbarch-selftests.c: Likewise.
6431 * gnu-v3-abi.c: Likewise.
6432 * ia64-tdep.c: Likewise.
6433 * ia64-vms-tdep.c: Likewise.
6434 * infcall.c: Likewise.
6435 * infcmd.c: Likewise.
6436 * infrun.c: Likewise.
6437 * linespec.c: Likewise.
6438 * linux-tdep.c: Likewise.
6439 * minsyms.c: Likewise.
6440 * ppc-linux-nat.c: Likewise.
6441 * ppc-linux-tdep.c: Likewise.
6442 * procfs.c: Likewise.
6443 * regcache.c: Likewise.
6444 * remote.c: Likewise.
6445 * rs6000-tdep.c: Likewise.
6446 * s390-linux-nat.c: Likewise.
6447 * s390-tdep.c: Likewise.
6448 * solib-aix.c: Likewise.
6449 * solib-darwin.c: Likewise.
6450 * solib-dsbt.c: Likewise.
6451 * solib-spu.c: Likewise.
6452 * solib-svr4.c: Likewise.
6453 * solib-target.c: Likewise.
6454 * sparc-tdep.c: Likewise.
6455 * sparc64-tdep.c: Likewise.
6456 * spu-tdep.c: Likewise.
6457 * symfile.c: Likewise.
6458 * symtab.c: Likewise.
6459 * target-descriptions.c: Likewise.
6460 * target-memory.c: Likewise.
6461 * target.c: Likewise.
6462 * target.h: Likewise.
6463 * tracefile-tfile.c: Likewise.
6464 * tracepoint.c: Likewise.
6465 * valops.c: Likewise.
6466 * valprint.c: Likewise.
6467 * value.c: Likewise.
6468 * windows-tdep.c: Likewise.
6469 * mi/mi-main.c: Likewise.
6470
6471 2018-06-07 Tom Tromey <tom@tromey.com>
6472
6473 * valprint.h (build_address_symbolic): Declare.
6474 * printcmd.c (print_address_symbolic): Update.
6475 (build_address_symbolic): Change "name" and "filename" to
6476 std::string.
6477 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
6478 Update.
6479 * defs.h (build_address_symbolic): Remove declaration.
6480
6481 2018-06-07 Alan Hayward <alan.hayward@arm.com>
6482
6483 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
6484 (aarch64_vnv_type): Add function.
6485 (aarch64_pseudo_register_name): Add V regs for SVE.
6486 (aarch64_pseudo_register_type): Likewise.
6487 (aarch64_pseudo_register_reggroup_p): Likewise.
6488 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
6489 (aarch64_pseudo_read_value): Add V regs for SVE.
6490 (aarch64_pseudo_write_2): Use V0 offset for SVE
6491 (aarch64_pseudo_write): Add V regs for SVE.
6492 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
6493
6494 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
6495
6496 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
6497 (sve_vl_from_vq): Likewise.
6498
6499 2018-06-05 Tom Tromey <tom@tromey.com>
6500
6501 * cli/cli-cmds.c (show_version): Update.
6502 * top.c (print_gdb_version): Add "interactive" parameter.
6503 Update.
6504 * main.c (captured_main_1): Update.
6505 * top.h (print_gdb_version): Add "interactive" parameter and a
6506 comment.
6507
6508 2018-06-05 David Malcolm <dmalcolm@redhat.com>
6509
6510 * common/enum-flags.h: Add trailing semicolon to example in
6511 comment.
6512
6513 2018-06-05 Tom Tromey <tom@tromey.com>
6514
6515 PR cli/12326:
6516 * NEWS: Add entry about pager.
6517 * utils.c (pagination_disabled_for_command): New global.
6518 (prompt_for_continue): Allow "c" response to prompt.
6519 (reinitialize_more_filter): Clear
6520 pagination_disabled_for_command.
6521 (fputs_maybe_filtered): Check pagination_disabled_for_command.
6522
6523 2018-06-04 Tom Tromey <tom@tromey.com>
6524
6525 * ada-lang.h (ada_lookup_symbol_list): Update.
6526 * ada-lang.c (resolve_subexp): Update.
6527 (symbols_are_identical_enums): Change type of syms. Remove nsyms
6528 parameter.
6529 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
6530 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
6531 results parameter to std::vector.
6532 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
6533 Update.
6534 * ada-exp.y (block_lookup): Update.
6535 (select_possible_type_sym): Change type of syms. Remove nsyms
6536 parameter.
6537 (write_var_or_type, write_name_assoc): Update.
6538
6539 2018-06-04 Joel Brobecker <brobecker@adacore.com>
6540
6541 * windows-nat.c (windows_nat_target::xfer_partial): Return
6542 TARGET_XFER_E_IO if we need to delegate to the target beneath
6543 but BENEATH is NULL.
6544
6545 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
6546
6547 * Makefile.in (config.status): Add configure.nat as a
6548 dependency.
6549
6550 2018-06-04 Tom Tromey <tom@tromey.com>
6551
6552 * cp-name-parser.y (cpname_state): Add method declarations.
6553 (HANDLE_QUAL): Update.
6554 (cpname_state::d_grab, cpname_state::fill_comp)
6555 (cpname_state::make_operator, cpname_state::make_dtor)
6556 (cpname_state::make_builtin_type, cpname_state::make_name)
6557 (cpname_state::d_qualify, cpname_state::d_int_type)
6558 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
6559 (%union): Move earlier.
6560
6561 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6562
6563 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
6564
6565 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6566
6567 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
6568 (aarch64_pseudo_write_1): Likewise.
6569 (aarch64_pseudo_read_value): Use helper.
6570 (aarch64_pseudo_write): Likewise.
6571
6572 2018-06-04 Pedro Alves <palves@redhat.com>
6573
6574 * darwin-nat.c (darwin_ops): Delete.
6575 (darwin_attach_pid): Use get_native_target.
6576
6577 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6578
6579 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
6580 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
6581
6582 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6583
6584 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
6585 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
6586 (aarch64_gdbarch_init): Check for SVE.
6587 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
6588
6589 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6590
6591 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
6592 * aarch64-tdep.h (aarch64_read_description): Likewise.
6593 * arch/aarch64.c (aarch64_create_target_description): Likewise.
6594 * arch/aarch64.h (aarch64_create_target_description): Likewise.
6595 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
6596 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
6597 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
6598
6599 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
6600
6601 * value.c (value_fetch_lazy_bitfield): New.
6602 (value_fetch_lazy_memory): New.
6603 (value_fetch_lazy_register): New.
6604 (value_fetch_lazy): Factor out to smaller functions.
6605
6606 2018-06-01 Tom Tromey <tom@tromey.com>
6607
6608 * cp-name-parser.y (backslashable, represented): Now const.
6609
6610 2018-06-01 Tom Tromey <tom@tromey.com>
6611
6612 * cp-name-parser.y: Include parser-defs.h.
6613 (parser_fprintf): Remove declaration.
6614
6615 2018-06-01 Tom Tromey <tom@tromey.com>
6616
6617 * cp-name-parser.y: Use %pure-parser, %lex-param, and
6618 %parse-param.
6619 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
6620 (global_result): Remove globals.
6621 (struct cpname_state): New.
6622 (yyparse): Don't declare.
6623 (yylex, yyerror): Move declarations after %union.
6624 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
6625 (make_name): Add state parameter.
6626 Update all callers.
6627 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
6628 parameter.
6629 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
6630 Update.
6631 (yylex): Add lvalp, state parameters.
6632 (yyerror): Add state parameter.
6633 (cp_demangled_name_to_comp): Update.
6634
6635 2018-06-01 Tom Tromey <tom@tromey.com>
6636
6637 * cp-name-parser.y (parser_fprintf): Declare.
6638 (GDB_YY_REMAP_PREFIX): Define.
6639 Include yy-remap.h. Don't redefine yy* identifiers.
6640
6641 2018-06-01 Tom Tromey <tom@tromey.com>
6642
6643 * python/py-type.c (typy_legacy_template_argument): Update.
6644 * cp-support.h (cp_demangled_name_to_comp): Update.
6645 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
6646 parameter to be a "std::string *".
6647 (main): Update.
6648
6649 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
6650
6651 * ada-lex.l: Include "diagnostics.h" instead of
6652 "common/diagnostics.h".
6653 * unittests/environ-selftests.c: Likewise.
6654 * common/diagnostics.h: Moved to ../include.
6655
6656 2018-06-01 Joel Brobecker <brobecker@adacore.com>
6657
6658 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
6659 to language_mode_manual while calling breakpoint_re_set_one.
6660
6661 2018-06-01 Tom Tromey <tom@tromey.com>
6662
6663 * valops.c (value_cast_structs, destructor_name_p): Update.
6664 * symtab.c (gdb_mangle_name): Update.
6665 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
6666 Update.
6667 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
6668 (pascal_object_print_value_fields, pascal_object_print_value):
6669 Update.
6670 * p-typeprint.c (pascal_type_print_derivation_info): Update.
6671 * linespec.c (find_methods): Update.
6672 * gdbtypes.h (type_name_no_tag): Remove.
6673 (type_name_or_error): Rename from type_name_no_tag_or_error.
6674 * gdbtypes.c (type_name_no_tag): Remove.
6675 (type_name_or_error): Rename from type_name_no_tag_or_error.
6676 (lookup_struct_elt_type, check_typedef): Update.
6677 * expprint.c (print_subexp_standard): Update.
6678 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
6679 * d-namespace.c (d_lookup_nested_symbol): Update.
6680 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
6681 (cp_print_class_member): Update.
6682 * cp-namespace.c (cp_lookup_nested_symbol): Update.
6683 * completer.c (add_struct_fields): Update.
6684 * c-typeprint.c (cp_type_print_derivation_info)
6685 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
6686 Update.
6687 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
6688 (ada_prefer_type, ada_is_exception_sym): Update.
6689
6690 2018-06-01 Tom Tromey <tom@tromey.com>
6691
6692 * valops.c (enum_constant_from_type, value_namespace_elt)
6693 (value_maybe_namespace_elt): Update.
6694 * valarith.c (find_size_for_pointer_math): Update.
6695 * target-descriptions.c (make_gdb_type): Update.
6696 * symmisc.c (print_symbol): Update.
6697 * stabsread.c (define_symbol, read_type)
6698 (complain_about_struct_wipeout, add_undefined_type)
6699 (cleanup_undefined_types_1): Update.
6700 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
6701 (rust_range_type_p, val_print_struct, rust_print_struct_def)
6702 (rust_internal_print_type, rust_composite_type)
6703 (rust_evaluate_funcall, rust_evaluate_subexp)
6704 (rust_inclusive_range_type_p): Update.
6705 * python/py-type.c (typy_get_tag): Update.
6706 * p-typeprint.c (pascal_type_print_base): Update.
6707 * mdebugread.c (parse_symbol, parse_type): Update.
6708 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
6709 Update.
6710 * guile/scm-type.c (gdbscm_type_tag): Update.
6711 * go-lang.c (sixg_string_p): Update.
6712 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
6713 Update.
6714 * gdbtypes.h (struct main_type) <tag_name>: Remove.
6715 (TYPE_TAG_NAME): Remove.
6716 * gdbtypes.c (type_name_no_tag): Simplify.
6717 (check_typedef, check_types_equal, recursive_dump_type)
6718 (copy_type_recursive, arch_composite_type): Update.
6719 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
6720 in summary mode when needed.
6721 * eval.c (evaluate_funcall): Update.
6722 * dwarf2read.c (fixup_go_packaging, read_structure_type)
6723 (process_structure_scope, read_enumeration_type)
6724 (read_namespace_type, read_module_type, determine_prefix): Update.
6725 * cp-support.c (inspect_type): Update.
6726 * coffread.c (process_coff_symbol, decode_base_type): Update.
6727 * c-varobj.c (c_is_path_expr_parent): Update.
6728 * c-typeprint.c (c_type_print_base_struct_union): Update.
6729 (c_type_print_base_1): Update. Print struct/class/union/enum in
6730 summary when using C language.
6731 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
6732 (gen_maybe_namespace_elt): Update.
6733 * ada-lang.c (ada_type_name): Simplify.
6734 (empty_record, ada_template_to_fixed_record_type_1)
6735 (template_to_static_fixed_type)
6736 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
6737
6738 2018-06-01 Tom Tromey <tom@tromey.com>
6739
6740 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
6741 c_print_type.
6742 * c-typeprint.c (c_print_type_1): Add "language" parameter.
6743 (c_print_type): Update.
6744 (c_print_type): New overload.
6745 (c_type_print_varspec_prefix, c_type_print_args)
6746 (c_type_print_varspec_suffix, c_print_type_no_offsets)
6747 (c_type_print_base_struct_union, c_type_print_base_1)
6748 (cp_type_print_method_args): Add "language" parameter.
6749 (c_type_print_base): Update.
6750 * c-lang.h (c_print_type): Add new overload.
6751
6752 2018-06-01 Tom Tromey <tom@tromey.com>
6753
6754 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
6755 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
6756
6757 2018-06-01 Alan Hayward <alan.hayward@arm.com>
6758
6759 * aarch64-tdep.c (aarch64_sve_register_names): New const
6760 var.
6761 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
6762 (AARCH64_SVE_Z_REGS_NUM): New define.
6763 (AARCH64_SVE_P_REGS_NUM): Likewise.
6764 (AARCH64_SVE_NUM_REGS): Likewise.
6765
6766 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
6767
6768 * nat/linux-ptrace.h [__alpha__]
6769 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
6770 definitions.
6771
6772 2018-05-31 Maciej W. Rozycki <macro@mips.com>
6773
6774 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
6775 the endianness selected.
6776 * NEWS: Document `set endian auto' mode operation update.
6777
6778 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6779
6780 * Makefile.in: Add new header.
6781 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
6782 (sve_vl_from_vg): Likewise.
6783 (sve_vq_from_vl): Likewise.
6784 (sve_vl_from_vq): Likewise.
6785 (sve_vq_from_vg): Likewise.
6786 (sve_vg_from_vq): Likewise.
6787 * configure.nat: Add new c file.
6788 * nat/aarch64-sve-linux-ptrace.c: New file.
6789 * nat/aarch64-sve-linux-ptrace.h: New file.
6790
6791 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6792
6793 * aarch64-linux-nat.c (aarch64_linux_read_description):
6794 Add parmeter zero.
6795 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
6796 Likewise.
6797 * aarch64-tdep.c (tdesc_aarch64_list): Add.
6798 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
6799 (aarch64_gdbarch_init): Add parmeter zero.
6800 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
6801 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
6802 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
6803 parmeter.
6804 * doc/gdb.texinfo: Describe SVE feature
6805 * features/aarch64-sve.c: New file.
6806
6807 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
6808
6809 PR gdb/23210
6810 * gdbarch.sh (significant_addr_bit): Default to zero when
6811 not set by target architecture.
6812 * gdbarch.c: Re-generated.
6813 * utils.c (address_significant): Update.
6814
6815 2018-05-30 Joel Brobecker <brobecker@adacore.com>
6816
6817 * stack.c (func_command): Remove trailing newline in call to error.
6818
6819 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6820
6821 * regcache.h (regcache_raw_collect): Remove, update callers to
6822 use regcache::raw_collect.
6823 * regcache.c (regcache_raw_collect): Remove.
6824
6825 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6826
6827 * regcache.h (regcache_raw_supply): Remove, update callers to
6828 use detached_regcache::raw_supply.
6829 * regcache.c (regcache_raw_supply): Remove.
6830
6831 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6832
6833 * regcache.h (regcache_cooked_write_part): Remove, update
6834 callers to use regcache::cooked_write_part.
6835 * regcache.c (regcache_cooked_write_part): Remove.
6836
6837 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6838
6839 * regcache.h (regcache_cooked_read_part): Remove, update callers
6840 to use readable_regcache::cooked_read_part.
6841 * regcache.c (regcache_cooked_read_part): Remove.
6842
6843 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6844
6845 * regcache.h (regcache_cooked_read_value): Remove, update
6846 callers to use readable_regcache::cooked_read_value.
6847 * regcache.c (regcache_cooked_read_value): Remove.
6848
6849 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6850
6851 * regcache.h (regcache_cooked_write): Remove, update callers to
6852 use regcache::cooked_write.
6853 * regcache.c (regcache_cooked_write): Remove.
6854
6855 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6856
6857 * regcache.h (regcache_invalidate): Remove, update callers to
6858 use detached_regcache::invalidate instead.
6859 * regcache.c (regcache_invalidate): Remove.
6860
6861 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6862
6863 * regcache.h (regcache_raw_write_part): Remove, update callers
6864 to use regcache::raw_write_part instead.
6865 * regcache.c (regcache_raw_write_part): Remove.
6866
6867 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6868
6869 * regcache.h (regcache_raw_read_part): Remove, update callers to
6870 use readable_regcache::raw_read_part instead.
6871 * regcache.c (regcache_raw_read_part): Remove.
6872
6873 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6874
6875 * regcache.h (regcache_cooked_read): Remove, update callers to
6876 use readable_regcache::cooked_read instead.
6877 * regcache.c (regcache_cooked_read): Remove.
6878
6879 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6880
6881 * regcache.h (regcache_raw_write): Remove, update callers to use
6882 regcache::raw_write instead.
6883 * regcache.c (regcache_raw_write): Remove.
6884
6885 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6886
6887 * regcache.h (regcache_raw_read): Remove, update callers to use
6888 readable_regcache::raw_read instead.
6889 * regcache.c (regcache_raw_read): Remove.
6890
6891 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6892
6893 * regcache.h (regcache_raw_update): Remove, update callers to
6894 use readable_regcache::raw_update instead.
6895 * regcache.c (regcache_raw_update): Remove.
6896
6897 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6898
6899 * regcache.h (regcache_register_status): Remove, update callers
6900 to use reg_buffer::get_register_status directly instead.
6901 * regcache.c (regcache_register_status): Remove.
6902
6903 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6904
6905 * regcache.h (regcache_get_ptid): Remove, update all callers to
6906 call regcache::ptid instead.
6907 * regcache.c (regcache_get_ptid): Remove.
6908
6909 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6910
6911 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
6912
6913 2018-05-30 Pedro Alves <palves@redhat.com>
6914
6915 * common/common-exceptions.h (exception_rethrow): Use
6916 ATTRIBUTE_NORETURN.
6917
6918 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
6919
6920 * breakpoint.c (print_solib_event, check_status_catch_solib):
6921 Remove struct keyword in range-based for loops.
6922 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
6923 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
6924 Likewise.
6925 * linespec.c (find_superclass_methods, search_minsyms_for_name):
6926 Likewise.
6927 * symfile.c (addr_info_make_relative): Likewise.
6928 * thread.c (value_in_thread_stack_temporaries): Likewise.
6929
6930 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
6931
6932 PR gdb/16841
6933 * valops.c (value_struct_elt_for_reference): Call check_typedef on
6934 aggregate type to get its real type before accessing it.
6935
6936 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
6937
6938 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
6939 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
6940 * coff-pe-read.c (add_pe_forwarded_sym): Replace
6941 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
6942 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
6943 * jit.c (jit_breakpoint_re_set_internal): Likewise.
6944 * printcmd.c (info_address_command): Likewise.
6945
6946 2018-05-29 Tom Tromey <tom@tromey.com>
6947
6948 * windows-nat.c (handle_exception): Update fall-through comment.
6949
6950 2018-05-29 Tom Tromey <tom@tromey.com>
6951
6952 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
6953 (struct program_space) <added_solibs>: Now a std::vector.
6954 * breakpoint.c (print_solib_event): Update.
6955 (check_status_catch_solib): Update.
6956 * progspace.c (clear_program_space_solib_cache): Update.
6957 * solib.c (update_solib_list): Update.
6958
6959 2018-05-29 Tom Tromey <tom@tromey.com>
6960
6961 * python/py-type.c (typy_richcompare): Update.
6962 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
6963 * gdbtypes.h (types_deeply_equal): Return bool.
6964 (types_equal): Likewise.
6965 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6966 declare VEC.
6967 (check_types_equal): Change worklist to std::vector. Return
6968 bool.
6969 (struct type_equality_entry): Add constructor.
6970 (compare_maybe_null_strings): Return bool.
6971 (check_types_worklist): Return bool. Change worklist to
6972 std::vector.
6973 (types_deeply_equal): Use std::vector.
6974 (types_equal): Return bool.
6975 (compare_maybe_null_strings): Simplify.
6976
6977 2018-05-29 Tom Tromey <tom@tromey.com>
6978
6979 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6980
6981 2018-05-29 Tom Tromey <tom@tromey.com>
6982
6983 * objc-lang.h: Don't include cp-support.h.
6984 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6985 declare VEC.
6986
6987 2018-05-27 Tom Tromey <tom@tromey.com>
6988
6989 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6990
6991 2018-05-25 Tom Tromey <tom@tromey.com>
6992
6993 * value.c (value::location): Initialize.
6994
6995 2018-05-25 Tom Tromey <tom@tromey.com>
6996
6997 * dbxread.c (init_bincl_list): Remove.
6998 (bincl_list): Now a std::vector.
6999 (bincls_allocated, next_bincl): Remove.
7000 (free_bincl_list, do_free_bincl_list_cleanup)
7001 (make_cleanup_free_bincl_list): Remove.
7002 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
7003 unique_xmalloc_ptr.
7004 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
7005 (struct header_file_location): Add constructor.
7006 (add_bincl_to_list): Remove.
7007
7008 2018-05-25 Tom Tromey <tom@tromey.com>
7009
7010 * tui/tui.c (tui_enable): Update.
7011 * mi/mi-interp.c (mi_interp::init): Update.
7012 * interps.h (class interp) <name>: New method.
7013 <m_name>: Rename from name.
7014 (~scoped_restore_interp): Update.
7015 * interps.c (interp::interp): Update.
7016 (interp_add, interp_set, interp_lookup_existing)
7017 (current_interp_named_p): Update.
7018
7019 2018-05-25 Tom Tromey <tom@tromey.com>
7020
7021 * interps.c (interp_name): Remove.
7022 * mi/mi-interp.c (mi_interp::init): Update.
7023 * interps.h (interp_name): Remove.
7024 (~scoped_restore_interp): Update.
7025 * tui/tui.c (tui_enable): Update.
7026
7027 2018-05-25 Tom Tromey <tom@tromey.com>
7028
7029 * utils.c (fputs_maybe_filtered): Update.
7030 * linespec.c (decode_line_full): Update.
7031 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
7032 (mi_print_breakpoint_for_event, mi_solib_loaded)
7033 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7034 (mi_user_selected_context_changed): Update.
7035 * mi/mi-main.c (mi_execute_command): Update.
7036 * cli/cli-script.c (execute_control_command): Update.
7037 * python/python.c (execute_gdb_command): Update.
7038 * solib.c (info_sharedlibrary_command): Update.
7039 * interps.c (interp_ui_out): Remove.
7040 * interps.h (interp_ui_out): Remove.
7041
7042 2018-05-25 Tom Tromey <tom@tromey.com>
7043
7044 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
7045 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
7046 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
7047
7048 2018-05-25 Tom Tromey <tom@tromey.com>
7049
7050 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
7051 * interps.c (interp_exec): Use scoped_restore.
7052
7053 2018-05-25 Tom Tromey <tom@tromey.com>
7054
7055 * remote.c (remote_target::remote_file_get): Use
7056 gdb::byte_vector.
7057 (remote_target::remote_file_put): Likewise.
7058
7059 2018-05-25 Tom Tromey <tom@tromey.com>
7060
7061 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
7062 a std::string.
7063 (get_pe_section_index, add_pe_exported_sym): Update.
7064 (read_pe_exported_syms): Use gdb::def_vector.
7065
7066 2018-05-25 Tom Tromey <tom@tromey.com>
7067
7068 * frame.c (remove_prev_frame): Remove.
7069 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
7070
7071 2018-05-25 Maciej W. Rozycki <macro@mips.com>
7072
7073 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
7074 Remove prototypes.
7075 * mips-linux-nat.c (supply_fpregset): Always call
7076 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
7077 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
7078 `mips_fill_fpregset'.
7079 * mips-linux-tdep.c (mips_supply_fpregset)
7080 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
7081 (mips_fill_fpregset_wrapper): Remove functions.
7082 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
7083 (mips_linux_fpregset): Remove variable.
7084 (mips_linux_iterate_over_regset_sections): Use
7085 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
7086 (mips_linux_o32_sigframe_init): Remove comment.
7087
7088 2018-05-25 Pedro Alves <palves@redhat.com>
7089
7090 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
7091 (struct readahead_cache, struct packet_reg, struct
7092 remote_arch_state, class remote_state): Move higher up in the
7093 file.
7094 (remote_target::m_remote_state): Now an object instead of a pointer.
7095 (remote_target::get_remote_state): Adjust.
7096
7097 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7098
7099 * stack.c (select_and_print_frame): Delete.
7100 (struct function_bounds): Move struct within function.
7101 (func_command): Most content moved into new function
7102 find_frame_for_function, use new function, print result, add
7103 function comment.
7104 (find_frame_for_function): New function, now returns a result.
7105
7106 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7107
7108 * stack.c (iterate_over_block_arg_vars): Fix comment.
7109 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
7110
7111 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7112
7113 PR gdb/23203
7114 * frame.c
7115 (scoped_restore_selected_frame::scoped_restore_selected_frame):
7116 Define.
7117 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
7118 Define.
7119 * frame.h (class scoped_restore_selected_frame): New class.
7120 * stack.c (print_frame_local_vars): Remove catching and rethrowing
7121 of any exception, use scoped_restore_selected_frame to restore the
7122 frame instead.
7123
7124 2018-05-24 Pedro Alves <palves@redhat.com>
7125
7126 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
7127 override.
7128
7129 2018-05-23 Tom Tromey <tom@tromey.com>
7130
7131 * complaints.c (struct complaints): Remove.
7132 (symfile_complaint_book): Remove.
7133 (series): New global.
7134 (complaint_internal): Update.
7135 (clear_complaints): Update.
7136
7137 2018-05-23 Tom Tromey <tom@tromey.com>
7138
7139 * complaints.c (counters): New global.
7140 (struct complain): Remove.
7141 (struct complaints) <root>: Remove.
7142 (complaint_sentinel): Remove.
7143 (symfile_complaint_book): Update.
7144 (find_complaint) Remove.
7145 (complaint_internal, clear_complaints): Update.
7146
7147 2018-05-23 Tom Tromey <tom@tromey.com>
7148
7149 * complaints.c (struct complain) <file, line>: Remove.
7150 (find_complaint): Remove file, line parameters.
7151 (complaint_internal): Update.
7152
7153 2018-05-23 Tom Tromey <tom@tromey.com>
7154
7155 * complaints.c (vcomplaint): Remove.
7156 (complaint_internal) Merge in contents of vcomplaint.
7157
7158 2018-05-23 Tom Tromey <tom@tromey.com>
7159
7160 * complaints.c (struct complaints) <explanation>: Remove.
7161 (symfile_explanations): Remove.
7162 (symfile_complaint_book): Update.
7163 (vcomplaint): Update.
7164 (struct explanation): Remove.
7165
7166 2018-05-23 Tom Tromey <tom@tromey.com>
7167
7168 * complaints.c (symfile_complaints): Remove.
7169 (complaint_internal): Remove "complaints" parameter.
7170 (clear_complaints, vcomplaint): Remove "c" parameter.
7171 (get_complaints): Remove.
7172 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
7173 (dwarf2_debug_line_missing_file_complaint)
7174 (dwarf2_debug_line_missing_end_sequence_complaint)
7175 (dwarf2_complex_location_expr_complaint)
7176 (dwarf2_const_value_length_mismatch_complaint)
7177 (dwarf2_section_buffer_overflow_complaint)
7178 (dwarf2_macro_malformed_definition_complaint)
7179 (dwarf2_invalid_attrib_class_complaint)
7180 (create_addrmap_from_index, dw2_symtab_iter_next)
7181 (dw2_expand_marked_cus)
7182 (dw2_debug_names_iterator::find_vec_in_debug_names)
7183 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
7184 (create_debug_type_hash_table, init_cutu_and_read_dies)
7185 (partial_die_parent_scope, add_partial_enumeration)
7186 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
7187 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
7188 (read_import_statement, read_file_scope, create_dwo_cu_reader)
7189 (create_cus_hash_table, create_dwp_hash_table)
7190 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
7191 (dwarf2_rnglists_process, dwarf2_ranges_process)
7192 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
7193 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
7194 (handle_struct_member_die, process_structure_scope)
7195 (read_array_type, read_common_block, read_module_type)
7196 (read_tag_pointer_type, read_typedef, read_base_type)
7197 (read_subrange_type, load_partial_dies, partial_die_info::read)
7198 (partial_die_info::read, partial_die_info::read)
7199 (partial_die_info::read, read_checked_initial_length_and_offset)
7200 (dwarf2_string_attr, read_formatted_entries)
7201 (dwarf_decode_line_header)
7202 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
7203 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
7204 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
7205 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
7206 (get_signatured_type, get_DW_AT_signature_type)
7207 (decode_locdesc, file_file_name, consume_improper_spaces)
7208 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
7209 (dwarf_decode_macro_bytes, dwarf_decode_macros)
7210 (dwarf2_symbol_mark_computed, set_die_type)
7211 (read_attribute_value): Update.
7212 * stap-probe.c (handle_stap_probe, get_stap_base_address):
7213 Update.
7214 * dbxread.c (unknown_symtype_complaint)
7215 (lbrac_mismatch_complaint, repeated_header_complaint)
7216 (set_namestring, function_outside_compilation_unit_complaint)
7217 (read_dbx_symtab, process_one_symbol): Update.
7218 * gdbtypes.c (stub_noname_complaint): Update.
7219 * windows-nat.c (handle_unload_dll): Update.
7220 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
7221 (decode_base_type): Update.
7222 * xcoffread.c (bf_notfound_complaint, ef_complaint)
7223 (eb_complaint, record_include_begin, record_include_end)
7224 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
7225 (process_xcoff_symbol, read_symbol)
7226 (function_outside_compilation_unit_complaint)
7227 (scan_xcoff_symtab): Update.
7228 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
7229 * buildsym.c (finish_block_internal, make_blockvector)
7230 (end_symtab_get_static_block, augment_type_symtab): Update.
7231 * dtrace-probe.c (dtrace_process_dof)
7232 (dtrace_static_probe_ops::get_probes): Update.
7233 * complaints.h (struct complaint): Don't declare.
7234 (symfile_complaints): Remove.
7235 (complaint_internal): Remove "complaints" parameter.
7236 (complaint): Likewise.
7237 (clear_complaints): Likewise.
7238 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7239 (reread_symbols): Update.
7240 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
7241 (dwarf2_frame_cache, decode_frame_entry): Update.
7242 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
7243 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7244 (info_selectors_command): Update.
7245 * macrotab.c (macro_include, check_for_redefinition)
7246 (macro_undef): Update.
7247 * objfiles.c (filter_overlapping_sections): Update.
7248 * stabsread.c (invalid_cpp_abbrev_complaint)
7249 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
7250 (define_symbol, error_type, read_type, rs6000_builtin_type)
7251 (stabs_method_name_from_physname, read_member_functions)
7252 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
7253 (attach_fields_to_type, complain_about_struct_wipeout)
7254 (read_range_type, read_args, common_block_start)
7255 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
7256 Update.
7257 * mdebugread.c (index_complaint, unknown_ext_complaint)
7258 (basic_type_complaint, bad_tag_guess_complaint)
7259 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
7260 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
7261 (parse_procedure, parse_lines)
7262 (function_outside_compilation_unit_complaint)
7263 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
7264 (bad_tag_guess_complaint, reg_value_complaint): Update.
7265 * cp-support.c (demangled_name_complaint): Update.
7266 * macroscope.c (sal_macro_scope): Update.
7267 * dwarf-index-write.c (class debug_names): Update.
7268
7269 2018-05-23 Tom Tromey <tom@tromey.com>
7270
7271 * complaints.c (clear_complaints): Remove "noisy" parameter.
7272 * complaints.h (clear_complaints): Update.
7273 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7274 (reread_symbols): Update.
7275
7276 2018-05-23 Tom Tromey <tom@tromey.com>
7277
7278 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
7279 SUBSEQUENT_MESSAGE.
7280 (vcomplaint, clear_complaints): Update.
7281 (symfile_explanations): Remove some messages.
7282
7283 2018-05-23 Tom Tromey <tom@tromey.com>
7284
7285 * complaints.c (internal_complaint): Remove.
7286 * complaints.h (internal_complaint): Remove.
7287
7288 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7289
7290 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
7291
7292 2018-05-22 Pedro Alves <palves@redhat.com>
7293
7294 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
7295 (remote_fileio_badfd, remote_fileio_return_errno)
7296 (remote_fileio_return_success, remote_fileio_func_open)
7297 (remote_fileio_func_open, remote_fileio_func_close)
7298 (remote_fileio_func_read, remote_fileio_func_write)
7299 (remote_fileio_func_lseek, remote_fileio_func_rename)
7300 (remote_fileio_func_unlink, remote_fileio_func_stat)
7301 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
7302 (remote_fileio_func_isatty, remote_fileio_func_system): Add
7303 remote_target parameter.
7304 (remote_fio_func_map) <func>: Add remote_target parameter.
7305 (do_remote_fileio_request, remote_fileio_request):
7306 * remote-fileio.h (remote_fileio_request):
7307 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
7308 remote_target parameter.
7309 (remote_notif_process, handle_notification): Adjust to pass down
7310 the remote.
7311 (remote_notif_state_allocate): Add remote_target parameter. Save
7312 it.
7313 * remote-notif.h (struct remote_target): Forward declare.
7314 (struct notif_client) <parse, ack, can_get_pending_events>: Add
7315 remote_target parameter.
7316 (struct remote_notif_state) <remote>: New field.
7317 (remote_notif_ack, remote_notif_parse): Add remote_target
7318 parameter.
7319 (remote_notif_state_allocate, remote_notif_state_allocate): Add
7320 remote_target parameter.
7321 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
7322 (threads_listing_context, rmt_thread_action, protocol_feature)
7323 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
7324 (packet_result, struct threads_listing_context, remote_state):
7325 Move definitions and declarations higher up.
7326 (remote_target) <~remote_target>: Declare.
7327 (remote_download_command_source, remote_file_put, remote_file_get)
7328 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
7329 (remote_hostio_pread_vFile, remote_hostio_send_command)
7330 (remote_hostio_set_filesystem, remote_hostio_open)
7331 (remote_hostio_close, remote_hostio_unlink, remote_state)
7332 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
7333 (get_memory_write_packet_size, get_memory_read_packet_size)
7334 (append_pending_thread_resumptions, remote_detach_1)
7335 (append_resumption, remote_resume_with_vcont)
7336 (add_current_inferior_and_thread, wait_ns, wait_as)
7337 (process_stop_reply, remote_notice_new_inferior)
7338 (process_initial_stop_replies, remote_add_thread)
7339 (btrace_sync_conf, remote_btrace_maybe_reopen)
7340 (remove_new_fork_children, kill_new_fork_children)
7341 (discard_pending_stop_replies, stop_reply_queue_length)
7342 (check_pending_events_prevent_wildcard_vcont)
7343 (discard_pending_stop_replies_in_queue, stop_reply)
7344 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
7345 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
7346 (remote_interrupt_as, remote_interrupt_ns)
7347 (remote_get_noisy_reply, remote_query_attached)
7348 (remote_add_inferior, remote_current_thread, get_current_thread)
7349 (set_thread, set_general_thread, set_continue_thread)
7350 (set_general_process, write_ptid)
7351 (remote_unpack_thread_info_response, remote_get_threadinfo)
7352 (parse_threadlist_response, remote_get_threadlist)
7353 (remote_threadlist_iterator, remote_get_threads_with_ql)
7354 (remote_get_threads_with_qxfer)
7355 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
7356 (get_offsets, remote_check_symbols, remote_supported_packet)
7357 (remote_query_supported, remote_packet_size)
7358 (remote_serial_quit_handler, remote_detach_pid)
7359 (remote_vcont_probe, remote_resume_with_hc)
7360 (send_interrupt_sequence, interrupt_query)
7361 (remote_notif_get_pending_events, fetch_register_using_p)
7362 (send_g_packet, process_g_packet, fetch_registers_using_g)
7363 (store_register_using_P, store_registers_using_G)
7364 (set_remote_traceframe, check_binary_download)
7365 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
7366 (remote_xfer_live_readonly_partial, remote_read_bytes)
7367 (remote_send_printf, remote_flash_write, readchar)
7368 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
7369 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
7370 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
7371 (extended_remote_disable_randomization, extended_remote_run)
7372 (send_environment_packet, extended_remote_environment_support)
7373 (extended_remote_set_inferior_cwd, remote_write_qxfer)
7374 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
7375 (packet_command): Now methods of ...
7376 (remote_target): ... this class.
7377 (m_remote_state) <remote_target>: New field.
7378 (struct remote_state) <stop_reply_queue,
7379 remote_async_inferior_event_token, wait_forever_enabled_p>: New
7380 fields.
7381 (remote_state::remote_state): Allocate stop_reply_queue.
7382 (remote_state): Delete global.
7383 (get_remote_state_raw): Delete.
7384 (remote_target::get_remote_state): Allocate m_remote_state on
7385 demand.
7386 (get_current_remote_target): New.
7387 (remote_ops, extended_remote_ops): Delete.
7388 (wait_forever_enabled_p, remote_async_inferior_event_token):
7389 Delete, moved to struct remote_state.
7390 (remote_target::close): Delete self. Destruction bits split to
7391 ...
7392 (remote_target::~remote_target): ... this.
7393 (show_memory_packet_size): Adjust to use
7394 get_current_remote_target.
7395 (struct protocol_feature) <func>: Add remote_target parameter.
7396 All callers adjusted.
7397 (curr_quit_handler_target): New.
7398 (remote_serial_quit_handler): Reimplement.
7399 (remote_target::open_1): Adjust to use get_current_remote_target.
7400 Heap-allocate remote_target/extended_remote_target instances.
7401 (vcont_builder::vcont_builder): Add remote_target parameter, and
7402 save it in m_remote. All callers adjusted.
7403 (vcont_builder::m_remote): New field.
7404 (vcont_builder::restart, vcont_builder::flush)
7405 (vcont_builder::push_action): Use it.
7406 (remote_target::commit_resume): Use it.
7407 (struct queue_iter_param) <remote>: New field.
7408 (remote_target::remove_new_fork_children): Fill in 'remote' field.
7409 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
7410 (check_pending_event_prevents_wildcard_vcont_callback)
7411 (remote_target::check_pending_events_prevent_wildcard_vcont)
7412 (remote_target::discard_pending_stop_replies)
7413 (remote_target::discard_pending_stop_replies_in_queue)
7414 (remote_target::remote_notif_remove_queued_reply): Fill in
7415 'remote' field.
7416 (remote_notif_get_pending_events): New.
7417 (remote_target::readchar, remote_target::remote_serial_write):
7418 Save/restore curr_quit_handler_target.
7419 (putpkt): New.
7420 (kill_new_fork_children): Fill in 'remote' field.
7421 (packet_command): Use get_current_remote_target, defer to
7422 remote_target method of same name.
7423 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
7424 parameter, and save it in m_remote. All callers adjusted.
7425 (scoped_remote_fd::release): Use m_remote.
7426 (scoped_remote_fd::m_remote): New field.
7427 (remote_file_put, remote_file_get, remote_file_delete): Use
7428 get_current_remote_target, defer to remote_target method of same
7429 name.
7430 (remote_btrace_reset): Add remote_state paremeter. Update all
7431 callers.
7432 (remote_async_inferior_event_handler). Pass down 'data'.
7433 (remote_new_objfile): Use get_current_remote_target.
7434 (remote_target::vcont_r_supported): New.
7435 (set_range_stepping): Use get_current_remote_target and
7436 remote_target::vcont_r_supported.
7437 (_initialize_remote): Don't allocate 'remote_state' and
7438 'stop_reply_queue' globals.
7439 * remote.h (struct remote_target): Forward declare.
7440 (getpkt, putpkt, remote_notif_get_pending_events): Add
7441 'remote_target' parameter.
7442
7443 2018-05-22 Pedro Alves <palves@redhat.com>
7444
7445 * remote.c (vcont_builder): Now a class. Make all data members
7446 private.
7447 (vcont_builder) <vcont_builder, restart, flush, push_action>:
7448 Declare methods.
7449 (vcont_builder_restart): Rename to ...
7450 (vcont_builder::restart): ... this.
7451 (vcont_builder_flush): Rename to ...
7452 (vcont_builder::flush): ... this.
7453 (vcont_builder_push_action): Rename to ...
7454 (vcont_builder::push_action): ... this.
7455 (remote_target::commit_resume): Adjust.
7456
7457 2018-05-22 Pedro Alves <palves@redhat.com>
7458
7459 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
7460 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
7461 (get_fixed_memory_packet_size): New.
7462 (get_memory_packet_size): Use it.
7463 (set_memory_packet_size): Don't override the config size with
7464 DEFAULT_MAX_MEMORY_PACKET_SIZE.
7465 (show_memory_packet_size): Use get_fixed_memory_packet_size.
7466 Don't refer to get_memory_packet_size if not connected to a remote
7467 target. Show "(default)" if configured size is 0.
7468
7469 2018-05-22 Pedro Alves <palves@redhat.com>
7470
7471 * remote.c (remote_target::mourn_inferior): Move
7472 discard_pending_stop_replies call here from ...
7473 (_initialize_remote): ... here.
7474
7475 2018-05-22 Pedro Alves <palves@redhat.com>
7476
7477 * remote.c (compare_section_command): Remove set_general_process
7478 call.
7479
7480 2018-05-22 Pedro Alves <palves@redhat.com>
7481
7482 * remote.c (struct packet_reg, struct remote_arch_state):
7483 Move higher up in the file.
7484 (remote_state) <m_arch_states>: Store remote_arch_state values
7485 instead of remote_arch_state pointers.
7486 (remote_state::get_remote_arch_state): Adjust.
7487
7488 2018-05-22 Pedro Alves <palves@redhat.com>
7489
7490 * remote.c: Include <unordered_map>.
7491 (remote_state): Now a class.
7492 (remote_state) <get_remote_arch_state>: Declare method.
7493 <get_remote_arch_state>: New field.
7494 (remote_arch_state) <remote_arch_state>: Declare ctor.
7495 <regs>: Now a unique_ptr.
7496 (remote_gdbarch_data_handle): Delete.
7497 (get_remote_arch_state): Delete.
7498 (remote_state::get_remote_arch_state): New.
7499 (get_remote_state): Adjust to call remote_state's
7500 get_remote_arch_state method.
7501 (init_remote_state): Delete, bits factored out to ...
7502 (remote_arch_state::remote_arch_state): ... this new method.
7503 (get_remote_packet_size, get_memory_packet_size)
7504 (process_g_packet, remote_target::fetch_registers)
7505 (remote_target::prepare_to_store, store_registers_using_G)
7506 (remote_target::store_registers, remote_target::get_trace_status):
7507 Adjust to call remote_state's method.
7508 (_initialize_remote): Remove reference to
7509 remote_gdbarch_data_handle.
7510
7511 2018-05-22 Pedro Alves <palves@redhat.com>
7512
7513 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
7514 pread>: New method declarations.
7515 (remote_target::open_1): Adjust.
7516 (readahead_cache_invalidate): Rename to ...
7517 (readahead_cache::invalidate): ... this, and adjust to be a class
7518 method.
7519 (readahead_cache_invalidate_fd): Rename to ...
7520 (readahead_cache::invalidate_fd): ... this, and adjust to be a
7521 class method.
7522 (remote_hostio_pwrite): Adjust.
7523 (remote_hostio_pread_from_cache): Rename to ...
7524 (readahead_cache::pread): ... this, and adjust to be a class
7525 method.
7526 (remote_hostio_close): Adjust.
7527
7528 2018-05-22 Pedro Alves <palves@redhat.com>
7529
7530 * remote.c (remote_hostio_close_cleanup): Delete.
7531 (class scoped_remote_fd): New.
7532 (remote_file_put, remote_file_get): Use it.
7533
7534 2018-05-22 Pedro Alves <palves@redhat.com>
7535
7536 (struct vCont_action_support): Use bool and initialize all fields.
7537 (struct readahead_cache): Initialize all fields.
7538 (remote_state): Use bool and initialize all fields.
7539 (remote_state::remote_state, remote_state::~remote_state): New.
7540 (new_remote_state): Delete.
7541 (_initialize_remote): Use new to allocate remote_state.
7542
7543 2018-05-22 Pedro Alves <palves@redhat.com>
7544 張俊芝 <zjz@zjz.name>
7545
7546 PR gdb/22973
7547 * c-exp.y: Include "c-support.h".
7548 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
7549 of tolower. Use c_ident_is_alpha to scan names.
7550 * c-lang.c: Include "c-support.h".
7551 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
7552 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
7553 * c-support.h: New file, with bits factored out from ...
7554 * cp-name-parser.y: ... this file.
7555 Include "c-support.h".
7556 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
7557 c-support.h and renamed.
7558 (symbol_end, yylex): Adjust.
7559
7560 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7561
7562 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
7563 parameter type to CORE_ADDR.
7564 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
7565 parameter type in declaration to CORE_ADDR.
7566 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
7567 target_auxv_search to get AT_HWCAP and use the result to get the
7568 target description.
7569 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
7570 to CORE_ADDR. Remove the cast of the return value to unsigned
7571 long. Fix error predicate of target_auxv_search.
7572 (ppc_linux_nat_target::read_description): Change the type of the
7573 hwcap variable to CORE_ADDR.
7574
7575 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7576
7577 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
7578 if the size of fpscr is larger than 32 bits.
7579
7580 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7581
7582 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
7583 (ppc32_linux_vsxregmap): New global.
7584 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
7585 regcache_supply_regset, and regcache_collect_regset.
7586 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
7587 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
7588 (fetch_vsx_register, store_vsx_register): Remove.
7589 (fetch_vsx_registers): Add regno parameter. Get regset using
7590 ppc_linux_vsxregset. Use regset to supply registers.
7591 (store_vsx_registers): Add regno parameter. Get regset using
7592 ppc_linux_vsxregset. Use regset to collect registers.
7593 (fetch_register): Call fetch_vsx_registers instead of
7594 fetch_vsx_register.
7595 (store_register): Call store_vsx_registers instead of
7596 store_vsx_register.
7597 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
7598 new regno parameter.
7599 (store_ppc_registers): Call store_vsx_registers with -1 for the
7600 new regno parameter.
7601 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
7602 (ppc_collect_vsxregset): Remove.
7603
7604 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7605
7606 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
7607 offset fields.
7608 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
7609 for vector register offset fields.
7610 (ppc64_fbsd_reg_offsets): Likewise.
7611 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7612 to vector register offset fields.
7613 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7614 to vector register offset fields.
7615 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
7616 vector register offset fields.
7617 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
7618 initializers for vector register offset fields.
7619 (rs6000_aix64_reg_offsets): Likewise.
7620 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
7621 (ppc_supply_vrregset): Remove.
7622 (ppc_collect_vrregset): Remove.
7623 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
7624 (ppc_linux_vrregset) : New function.
7625 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
7626 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
7627 (ppc32_linux_vrregset): Remove.
7628 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
7629 and use result instead of ppc32_linux_vrregset.
7630 (ppc32_linux_reg_offsets): Remove initializers for vector register
7631 offset fields.
7632 (ppc64_linux_reg_offsets): Likewise.
7633 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
7634 * ppc-linux-nat.c: Include regset.h.
7635 (gdb_vrregset_t): Adjust comment to account for little-endian
7636 mode.
7637 (supply_vrregset, fill_vrregset): Remove.
7638 (fetch_altivec_register, store_altivec_register): Remove.
7639 (fetch_altivec_registers): Add regno parameter. Get regset using
7640 ppc_linux_vrregset. Use regset to supply registers.
7641 (store_altivec_registers): Add regno parameter. Get regset using
7642 ppc_linux_vrregset. Use regset to collect registers.
7643 (fetch_register): Call fetch_altivec_registers instead of
7644 fetch_altivec_register.
7645 (store_register): Call store_altivec_registers instead of
7646 store_altivec_register.
7647 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
7648 the new regno parameter.
7649 (store_ppc_registers): Call store_altivec_registers with -1 for
7650 the new regno parameter.
7651
7652 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7653
7654 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
7655 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
7656 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
7657 (gdb_vrregset_t): Change array type size to
7658 PPC_LINUX_SIZEOF_VRREGSET.
7659 (gdb_vsxregset_t): Change array type size to
7660 PPC_LINUX_SIZEOF_VSXREGSET.
7661 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
7662 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
7663 PPC_LINUX_SIZEOF_VSXREGSET.
7664
7665 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7666
7667 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
7668 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
7669 nat/ppc-linux.c.
7670 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
7671 ppc_linux_target_wordsize with tid.
7672 (ppc_linux_nat_target::read_description): Call ppc_linux_target
7673 wordsize with tid.
7674 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
7675 (ppc64_64bit_inferior_p): Add static and inline specifiers.
7676 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
7677 tid parameter. Remove static specifier.
7678 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
7679 (ppc_linux_target_wordsize): New declaration.
7680
7681 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7682
7683 * arch/ppc-linux-common.c: New file.
7684 * arch/ppc-linux-common.h: New file.
7685 * arch/ppc-linux-tdesc.h: New file.
7686 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
7687 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
7688 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
7689 arch/ppc-linux-tdesc.h.
7690 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
7691 arch/ppc-linux-tdesc.h.
7692 (ppc_linux_nat_target::read_description): Remove target
7693 description matching code. Fill a ppc_linux_features struct and
7694 call ppc_linux_match_description with it. Move comment about ISA
7695 2.05 to ppc-linux-common.c.
7696 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
7697 arch/ppc-linux-tdesc.h.
7698 (ppc_linux_core_read_description): Remove target description
7699 matching code. Fill a ppc_linux_features struct and call
7700 ppc_linux_match_description with it.
7701 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
7702 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
7703 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
7704 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
7705 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
7706 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
7707 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
7708 (tdesc_powerpc_e500l): Remove.
7709
7710 2018-05-22 Joel Brobecker <brobecker@adacore.com>
7711
7712 * ada-lang.c (catch_assert_command): Pass empty string instead
7713 of NULL for excep_string argument.
7714
7715 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7716
7717 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
7718 the width of the requested register exceeds the width of the
7719 `ptrace' data type.
7720
7721 2018-05-21 Tom Tromey <tom@tromey.com>
7722
7723 * printcmd.c (output_command): Remove.
7724 (output_command_const): Rename to output_command.
7725 * valprint.h (output_command): Rename from output_command_const.
7726 * tracepoint.c (trace_dump_actions): Call output_command.
7727
7728 2018-05-21 Tom Tromey <tom@tromey.com>
7729
7730 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7731 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
7732 * ada-lang.h (create_ada_exception_catchpoint): Update.
7733 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
7734 std::string.
7735 (create_excep_cond_exprs, ~ada_catchpoint)
7736 (should_stop_exception, print_one_exception)
7737 (print_mention_exception, print_recreate_exception): Update.
7738 (ada_get_next_arg): Remove.
7739 (catch_ada_exception_command_split): Use std::string. Change type
7740 of "excep_string", "cond_string".
7741 (catch_ada_exception_command): Update.
7742 (create_ada_exception_catchpoint): Change type of excep_string.
7743 (ada_exception_sal): Remove excep_string parameter.
7744 (~ada_catchpoint): Remove.
7745
7746 2018-05-21 Tom Tromey <tom@tromey.com>
7747
7748 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
7749 cleanup.
7750
7751 2018-05-21 Tom Tromey <tom@tromey.com>
7752
7753 * ada-lang.c (ada_exception_message_1, ada_exception_message):
7754 Return unique_xmalloc_ptr.
7755 (print_it_exception): Update.
7756
7757 2018-05-21 Tom Tromey <tom@tromey.com>
7758
7759 * tracepoint.c (trace_dump_actions): Use std::string.
7760
7761 2018-05-21 Tom Tromey <tom@tromey.com>
7762
7763 * symfile.c (reread_symbols): Use std::string for original_name.
7764
7765 2018-05-21 Tom Tromey <tom@tromey.com>
7766
7767 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
7768 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
7769 constructor.
7770
7771 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
7772
7773 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
7774 instance to...
7775 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
7776 * objfiles.c (get_objfile_bfd_data): Allocate
7777 objfile_per_bfd_storage with obstack_new when allocating on
7778 obstack.
7779
7780 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7781
7782 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
7783 OBSTACK_ZALLOC.
7784 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
7785 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
7786 * mdebugread.c (mdebug_build_psymtabs): Likewise.
7787 (add_pending): Likewise.
7788 (parse_symbol): Likewise.
7789 (parse_partial_symbols): Likewise.
7790 (psymtab_to_symtab_1): Likewise.
7791 (new_psymtab): Likewise.
7792 (elfmdebug_build_psymtabs): Likewise.
7793 * minsyms.c (terminate_minimal_symbol_table): Likewise.
7794 * objfiles.c (get_objfile_bfd_data): Likewise.
7795 (objfile_register_static_link): Likewise.
7796 * psymtab.c (allocate_psymtab): Likewise.
7797 * stabsread.c (read_member_functions): Likewise.
7798 * xcoffread.c (xcoff_end_psymtab): Likewise.
7799
7800 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7801
7802 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
7803 compiler supports std::is_trivially_constructible.
7804 * common/poison.h: Include obstack.h.
7805 (IsMallocable): Define to is_trivially_constructible if the
7806 compiler supports it, define to true_type otherwise.
7807 (xobnew): New.
7808 (XOBNEW): Redefine.
7809 (xobnewvec): New.
7810 (XOBNEWVEC): Redefine.
7811 * gdb_obstack.h (obstack_zalloc): New.
7812 (OBSTACK_ZALLOC): Redefine.
7813 (obstack_calloc): New.
7814 (OBSTACK_CALLOC): Redefine.
7815 (obstack_new): New.
7816 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
7817 (gdbarch_obstack): New declaration in gdbarch.h, definition in
7818 gdbarch.c.
7819 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
7820 obstack_calloc/obstack_zalloc.
7821 (gdbarch_obstack_zalloc): Remove.
7822 * target-descriptions.c (tdesc_data_init): Use obstack_new.
7823
7824 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7825
7826 * stack.c (backtrace_command_1): Remove useless variable int i.
7827
7828 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7829
7830 * stack.c (print_frame_info): Fix comment.
7831
7832 2018-05-18 Tom Tromey <tom@tromey.com>
7833
7834 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
7835 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
7836 (~dwarf2_per_objfile): Update
7837 (dwarf2_get_dwz_file): Use new.
7838 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
7839 unique_ptr.
7840
7841 2018-05-18 Tom Tromey <tom@tromey.com>
7842
7843 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
7844 unique_ptr.
7845 * dwarf2read.c (struct dwp_file): Add constructor and
7846 initializers.
7847 (open_and_init_dwp_file): Return a unique_ptr.
7848 (dwarf2_per_objfile, create_dwp_hash_table)
7849 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
7850 (lookup_dwo_unit_in_dwp): Update.
7851 (open_and_init_dwp_file, get_dwp_file): Update.
7852
7853 2018-05-18 Tom Tromey <tom@tromey.com>
7854
7855 * dwarf2read.c (dwarf2_per_objfile): Update.
7856 (struct mapped_index): Add initializers.
7857 (dwarf2_read_index): Use new.
7858 (dw2_symtab_iter_init): Update.
7859 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
7860 unique_ptr.
7861
7862 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7863
7864 * dwarf2read.c (mapped_index) <total_size>: Remove.
7865
7866 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7867
7868 * unittests/format_pieces-selftests.c (test_format_specifier):
7869 Add ARI comments.
7870
7871 2018-05-18 Tom Tromey <tom@tromey.com>
7872
7873 * c-typeprint.c (maybe_print_hole): New function.
7874 (c_print_type_struct_field_offset): Update.
7875 (c_type_print_base_struct_union): Call maybe_print_hole.
7876
7877 2018-05-17 Keith Seitz <keiths@redhat.com>
7878
7879 * breakpoint.c (build_bpstat_chain): New function, moved from
7880 bpstat_stop_status.
7881 (bpstat_stop_status): Add optional parameter, `stop_chain'.
7882 If no stop chain is passed, call build_bpstat_chain to build it.
7883 * breakpoint.h (build_bpstat_chain): Declare.
7884 (bpstat_stop_status): Move documentation here from breakpoint.c.
7885 * infrun.c (handle_signal_stop): Before eliding inlined frames,
7886 build the stop chain and pass it to skip_inline_frames.
7887 Pass this stop chain to bpstat_stop_status.
7888 * inline-frame.c: Include breakpoint.h.
7889 (stopped_by_user_bp_inline_frame): New function.
7890 (skip_inline_frames): Add parameter `stop_chain'.
7891 Move documention to inline-frame.h.
7892 If non-NULL, use stopped_by_user_bp_inline_frame to determine
7893 whether the frame should be elided.
7894 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
7895 Add moved documentation and update for new parameter.
7896
7897 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7898
7899 PR cli/14975
7900 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7901 unittests/format_pieces-selftests.c.
7902 * common/format.h (format_piece) <operator==>: New.
7903 (format_pieces) <operator[]>: Remove.
7904 * common/format.c (format_pieces::format_pieces): Handle \e.
7905 * unittests/format_pieces-selftests.c: New.
7906
7907 2018-05-17 Tom Tromey <tom@tromey.com>
7908
7909 PR symtab/23010:
7910 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
7911 (dw2_instantiate_symtab): Add skip_partial parameter.
7912 (dw2_find_last_source_symtab, dw2_map_expand_apply)
7913 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
7914 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
7915 (dw2_expand_symtabs_matching_one)
7916 (dw2_find_pc_sect_compunit_symtab)
7917 (dw2_debug_names_lookup_symbol)
7918 (dw2_debug_names_expand_symtabs_for_function): Update.
7919 (init_cutu_and_read_dies): Add skip_partial parameter.
7920 (process_psymtab_comp_unit, build_type_psymtabs_1)
7921 (process_skeletonless_type_unit, load_partial_comp_unit)
7922 (psymtab_to_symtab_1): Update.
7923 (load_full_comp_unit): Add skip_partial parameter.
7924 (process_imported_unit_die, dwarf2_read_addr_index)
7925 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
7926 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
7927 (read_signatured_type): Update.
7928
7929 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7930
7931 * value.c (release_value): Remove unused variable.
7932 (record_latest_value): Likewise.
7933 (access_value_history): Likewise.
7934 (preserve_values): Likewise.
7935
7936 2018-05-17 Tom Tromey <tom@tromey.com>
7937
7938 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
7939 Initialize.
7940
7941 2018-05-16 Maciej W. Rozycki <macro@mips.com>
7942
7943 PR gdb/22286
7944 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
7945 Also handle registers whose width is not a multiple of
7946 PTRACE_TYPE_RET.
7947 (linux_nat_trad_target::store_register): Likewise.
7948
7949 2018-05-16 Tom Tromey <tom@tromey.com>
7950
7951 * gdbcore.h (core_bfd): Redefine.
7952 * corelow.c (core_target::close): Update.
7953 (core_target_open): Update.
7954 * progspace.h (struct program_space) <cbfd>: Now a
7955 gdb_bfd_ref_ptr.
7956
7957 2018-05-16 Tom Tromey <tom@tromey.com>
7958
7959 PR cli/19551:
7960 * symfile-add-flags.h (enum symfile_add_flags)
7961 <SYMFILE_NOT_FILENAME>: New constant.
7962 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
7963 objfile name from BFD.
7964 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7965 * minidebug.c (find_separate_debug_file_in_section): Put
7966 ".gnu_debugdata" into BFD's file name.
7967
7968 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7969
7970 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7971 Remove.
7972
7973 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7974
7975 PR binutils/21446
7976 * aarch64-tdep.c (aarch64_analyze_prologue,
7977 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7978 Indicate not interested in errors.
7979
7980 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7981
7982 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7983 Supply the MIPS_ZERO_REGNUM register.
7984
7985 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7986
7987 * mips-tdep.c (mask_address_var): Make variable static.
7988
7989 2018-05-14 Tom Tromey <tom@tromey.com>
7990
7991 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7992
7993 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7994
7995 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7996 FXSAVE_ADDR for the mxcsr register.
7997
7998 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7999
8000 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
8001
8002 2018-05-11 Pedro Alves <palves@redhat.com>
8003
8004 * corelow.c (core_target) <core_target>: No longer inline.
8005 Initialize m_core_gdbarch, m_core_vec and build the section table
8006 here.
8007 <~core_target>: New.
8008 <core_gdbarch, get_core_register_section>: New methods.
8009 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
8010 factored out from ...
8011 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
8012 (core_ops): Delete.
8013 (sniff_core_bfd): Add gdbarch parameter.
8014 (core_close): Delete, merged into ...
8015 (core_target::close): ... here. Delete self.
8016 (core_close_cleanup): Delete.
8017 (core_target_open): Allocate a core_target on the heap. Use a
8018 unique_ptr instead of a cleanup. Bits moved into the core_target
8019 ctor. Adjust to use core_target methods instead of globals.
8020 (get_core_register_section): Rename to ...
8021 (core_target::get_core_register_section): ... this and adjust.
8022 (struct get_core_registers_cb_data): New.
8023 (get_core_registers_cb): Use it. Use bool.
8024 (core_target::fetch_registers, core_target::files_info)
8025 (core_target::xfer_partial, core_target::read_description)
8026 (core_target::pid_to, core_target::thread_name): Adjust to
8027 reference class fields instead of globals.
8028 * target.h (struct target_ops_deleter, target_ops_up): New.
8029
8030 2018-05-11 Pedro Alves <palves@redhat.com>
8031
8032 * corefile.c (core_file_command): Move to corelow.c.
8033 * corelow.c (the_core_target): Delete.
8034 (core_file_command): Moved from corefile.c. Check exec_bfd
8035 instead of the_core_target. Use target_detach instead of calling
8036 into the_core_target directly.
8037 (maybe_say_no_core_file_now): New.
8038 (core_target::detach): Use it.
8039 (_initialize_corelow): Remove references to the_core_target.
8040 * gdbcore.h (the_core_target): Delete.
8041
8042 2018-05-11 Tom Tromey <tromey@redhat.com>
8043 Pedro Alves <palves@redhat.com>
8044
8045 * corefile.c (core_bfd): Remove.
8046 * gdbcore.h (core_bfd): Now a macro.
8047 * progspace.h (struct program_space) <cbfd>: New field.
8048
8049 2018-05-11 Tom Tromey <tom@tromey.com>
8050
8051 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
8052 gdb::def_vector.
8053
8054 2018-05-10 Tom Tromey <tom@tromey.com>
8055
8056 * configure: Rebuild.
8057 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
8058
8059 2018-05-10 Joel Brobecker <brobecker@adacore.com>
8060
8061 PR server/23158:
8062 * regformats/regdat.sh: Adjust script, following the addition
8063 of the new expedite_regs parameter to init_target_desc.
8064
8065 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
8066
8067 PR gdb/23127
8068 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
8069 set_gdbarch_significant_addr_bit.
8070 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
8071 set_gdbarch_significant_addr_bit.
8072 * utils.c (address_significant): Update to sign extend addr.
8073
8074 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
8075
8076 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
8077 (xtensa_linux_init_abi): Limit tdep->num_regs by
8078 tdep->num_nopriv_regs.
8079 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
8080 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
8081 not initialized.
8082
8083 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
8084
8085 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
8086
8087 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
8088
8089 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
8090 (I387_MXCSR_INIT_VAL): New constant.
8091 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
8092 buffer if it was supplied by the inferior.
8093 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
8094 (i387_xsave_get_clear_bv): New function.
8095 (i387_supply_xsave): Only read x87 control registers from the
8096 xsave buffer if the feature is enabled, and the state will have
8097 been written, otherwise, provide a suitable default.
8098 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
8099 including x87 control registers. Update control registers if they
8100 have changed from the default value, and mark features as enabled
8101 as required.
8102 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
8103
8104 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
8105
8106 * spu-tdep.c (info_spu_event_command): Fix output formatting.
8107
8108 2018-05-07 Tom Tromey <tom@tromey.com>
8109
8110 * configure: Rebuild.
8111 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
8112
8113 2018-05-07 Tom Tromey <tom@tromey.com>
8114
8115 PR tdep/20362:
8116 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
8117 bit. Use correct value for VDIV.
8118
8119 2018-05-04 Tom Tromey <tom@tromey.com>
8120
8121 * configure: Rebuild.
8122 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
8123
8124 2018-05-04 Tom Tromey <tom@tromey.com>
8125
8126 * linux-record.c (record_linux_system_call) <case
8127 RECORD_SYS_RECVFROM>: Add "break".
8128
8129 2018-05-04 Tom Tromey <tom@tromey.com>
8130
8131 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
8132 Add missing "break".
8133 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
8134 Add missing "break".
8135
8136 2018-05-04 Tom Tromey <tom@tromey.com>
8137
8138 * rs6000-tdep.c (ppc_process_record_op4)
8139 (ppc_process_record_op63): Add fall-through comment.
8140
8141 2018-05-04 Tom Tromey <tom@tromey.com>
8142
8143 * i386-tdep.c (i386_process_record): Add fall-through comment.
8144
8145 2018-05-04 Tom Tromey <tom@tromey.com>
8146
8147 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
8148 comment.
8149
8150 2018-05-04 Tom Tromey <tom@tromey.com>
8151
8152 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
8153 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
8154 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
8155 comment.
8156 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
8157 comment.
8158 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
8159 comment.
8160
8161 2018-05-04 Tom Tromey <tom@tromey.com>
8162
8163 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
8164
8165 2018-05-04 Tom Tromey <tom@tromey.com>
8166
8167 * s390-tdep.c (s390_process_record): Fix fall-through comments.
8168 * xcoffread.c (scan_xcoff_symtab): Move comment later.
8169 * symfile.c (section_is_mapped): Fix fall-through comment.
8170 * stabsread.c (define_symbol, read_member_functions): Fix
8171 fall-through comment.
8172 * s390-linux-tdep.c (s390_process_record): Fix fall-through
8173 comment.
8174 * remote.c (remote_wait_as): Fix fall-through comment.
8175 * p-exp.y (yylex): Fix fall-through comment.
8176 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
8177 comment.
8178 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
8179 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
8180 * jv-exp.y (yylex): Fix fall-through comment.
8181 * go-exp.y (lex_one_token): Fix fall-through comment.
8182 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
8183 fall-through comment.
8184 * f-exp.y (yylex): Fix fall-through comment.
8185 * dwarf2read.c (process_die): Fix fall-through comments.
8186 * dbxread.c (process_one_symbol): Fix fall-through comment.
8187 * d-exp.y (lex_one_token): Fix fall-through comment.
8188 * cp-name-parser.y (yylex): Fix fall-through comment.
8189 * coffread.c (coff_symtab_read): Fix fall-through comment.
8190 * c-exp.y (lex_one_token): Fix fall-through comment.
8191 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
8192 comment.
8193 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
8194 comment.
8195
8196 2018-05-04 Tom Tromey <tom@tromey.com>
8197
8198 PR python/22730:
8199 * NEWS: Mention gdb.execute change.
8200 * gdbcmd.h (execute_control_command): Don't declare.
8201 * python/python.c (execute_gdb_command): Use read_command_lines_1,
8202 execute_control_commands, execute_control_commands_to_string.
8203 * cli/cli-script.h (execute_control_commands)
8204 (execute_control_commands_to_string): Declare.
8205 (execute_control_command): Add from_tty parameter.
8206 * cli/cli-script.c (execute_control_commands)
8207 (execute_control_commands_to_string): New functions.
8208 (execute_user_command): Use execute_control_commands.
8209 (execute_control_command_1): Add "from_tty" parameter. Update.
8210 (execute_control_command): Likewise.
8211
8212 2018-05-04 Tom Tromey <tom@tromey.com>
8213
8214 PR python/22731:
8215 * NEWS: Mention that breakpoint commands are writable.
8216 * python/py-breakpoint.c (bppy_set_commands): New function.
8217 (breakpoint_object_getset) <"commands">: Use it.
8218
8219 2018-05-04 Tom Tromey <tom@tromey.com>
8220
8221 * tracepoint.c (actions_command): Update.
8222 * mi/mi-cmd-break.c (mi_command_line_array)
8223 (mi_command_line_array_cnt, mi_command_line_array_ptr)
8224 (mi_read_next_line): Remove.
8225 (mi_cmd_break_commands): Update.
8226 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
8227 function_view.
8228 * cli/cli-script.c (get_command_line): Update.
8229 (process_next_line): Use function_view. Constify.
8230 (recurse_read_control_structure, read_command_lines)
8231 (read_command_lines_1): Change argument types to function_view.
8232 (do_define_command, document_command): Update.
8233 * breakpoint.h (check_tracepoint_command): Don't declare.
8234 * breakpoint.c (check_tracepoint_command): Remove.
8235 (commands_command_1, create_tracepoint_from_upload): Update.
8236
8237 2018-05-04 Tom Tromey <tom@tromey.com>
8238
8239 PR gdb/11750:
8240 * cli/cli-script.h (enum command_control_type) <define_control>:
8241 New constant.
8242 * cli/cli-script.c (multi_line_command_p): Handle define_control.
8243 (build_command_line, execute_control_command_1)
8244 (process_next_line): Likewise.
8245 (do_define_command): New function, extracted from define_command.
8246 (define_command): Use it.
8247
8248 2018-05-04 Tom Tromey <tom@tromey.com>
8249
8250 * tracepoint.c (actions_command): Update.
8251 * cli/cli-script.h (read_command_lines): Update.
8252 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
8253 (MAX_TMPBUF): Remove define.
8254 (define_command): Use string_printf.
8255 (document_command): Likewise.
8256 * breakpoint.c (commands_command_1): Update.
8257
8258 2018-05-04 Tom Tromey <tom@tromey.com>
8259
8260 * top.c (execute_command): Update.
8261 * cli/cli-script.h (print_command_lines): Now varargs.
8262 * cli/cli-script.c (print_command_lines): Now varargs.
8263 (execute_control_command_1) <case while_control, case if_control>:
8264 Update.
8265
8266 2018-05-04 Tom Tromey <tom@tromey.com>
8267
8268 * tracepoint.c (all_tracepoint_actions): Rename from
8269 all_tracepoint_actions_and_cleanup. Change return type.
8270 (actions_command, encode_actions_1, encode_actions)
8271 (trace_dump_actions, tdump_command): Update.
8272 * remote.c (remote_download_command_source): Update.
8273 * python/python.c (gdbpy_eval_from_control_command)
8274 (python_command, python_interactive_command): Update.
8275 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8276 * guile/guile.c (guile_command)
8277 (gdbscm_eval_from_control_command, guile_command): Update.
8278 * compile/compile.c (compile_code_command)
8279 (compile_print_command, compile_to_object): Update.
8280 * cli/cli-script.h (struct command_lines_deleter): New.
8281 (counted_command_line): New typedef.
8282 (struct command_line): Add constructor, destructor.
8283 <body_list>: Remove.
8284 <body_list_0, body_list_1>: New members.
8285 (command_line_up): Remove typedef.
8286 (read_command_lines, read_command_lines_1, get_command_line):
8287 Update.
8288 (copy_command_lines): Don't declare.
8289 * cli/cli-script.c (build_command_line): Use "new".
8290 (get_command_line): Return counted_command_line.
8291 (print_command_lines, execute_user_command)
8292 (execute_control_command_1, while_command, if_command): Update.
8293 (realloc_body_list): Remove.
8294 (process_next_line, recurse_read_control_structure): Update.
8295 (read_command_lines, read_command_lines_1): Return counted_command_line.
8296 (free_command_lines): Use "delete".
8297 (copy_command_lines): Remove.
8298 (define_command, document_command, show_user_1): Update.
8299 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
8300 a counted_command_line.
8301 * breakpoint.h (counted_command_line): Remove typedef.
8302 (breakpoint_set_commands): Update.
8303 * breakpoint.c (check_no_tracepoint_commands)
8304 (validate_commands_for_breakpoint): Update.
8305 (breakpoint_set_commands): Change commands to be a
8306 counted_command_line.
8307 (commands_command_1, update_dprintf_command_list)
8308 (create_tracepoint_from_upload): Update.
8309
8310 2018-05-04 Tom Tromey <tom@tromey.com>
8311
8312 * cli/cli-decode.h (cmd_list_element): New constructor.
8313 (~cmd_list_element): New destructor.
8314 (struct cmd_list_element): Add initializers.
8315 * cli/cli-decode.c (do_add_cmd): Use "new".
8316 (delete_cmd): Use "delete".
8317
8318 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
8319 Pedro Alves <palves@redhat.com>
8320
8321 PR breakpoints/19806 and support for PR external/20207.
8322 * NEWS: Mention Aarch64 watchpoint improvements.
8323 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
8324 watchpoints and PR external/20207 watchpoints.
8325 * nat/aarch64-linux-hw-point.c
8326 (kernel_supports_any_contiguous_range): New.
8327 (aarch64_watchpoint_offset): New.
8328 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
8329 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
8330 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
8331 (aarch64_align_watchpoint): New parameters aligned_offset_p and
8332 next_addr_orig_p. Support PR external/20207 watchpoints.
8333 (aarch64_downgrade_regs): New.
8334 (aarch64_dr_state_insert_one_point): New parameters offset and
8335 addr_orig.
8336 (aarch64_dr_state_remove_one_point): Likewise.
8337 (aarch64_handle_breakpoint): Update caller.
8338 (aarch64_handle_aligned_watchpoint): Likewise.
8339 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
8340 aligned_offset.
8341 (aarch64_linux_set_debug_regs): Remove const from state. Call
8342 aarch64_downgrade_regs.
8343 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
8344 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
8345 (DR_CONTROL_MASK): ... this.
8346 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
8347 (unsigned int aarch64_watchpoint_offset): New prototype.
8348 (aarch64_linux_set_debug_regs): Remove const from state.
8349 * utils.c (align_up, align_down): Move to ...
8350 * common/common-utils.c (align_up, align_down): ... here.
8351 * utils.h (align_up, align_down): Move to ...
8352 * common/common-utils.h (align_up, align_down): ... here.
8353
8354 2018-05-04 Joel Brobecker <brobecker@adacore.com>
8355
8356 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
8357 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
8358 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
8359 Re-implement to match the ABI as summarized in GCC's
8360 gcc/config/sparc/sparc.c. All callers updated.
8361 (sparc32_store_arguments): Remove assertion.
8362
8363 2018-05-04 Tom Tromey <tom@tromey.com>
8364
8365 * printcmd.c: Don't include tui.h.
8366 (decode_format): Use skip_spaces.
8367
8368 2018-05-04 Tom Tromey <tom@tromey.com>
8369
8370 PR gdb/22619:
8371 * printcmd.c (last_count): New global.
8372 (x_command): Use saved count when repeating.
8373
8374 2018-05-04 Tom Tromey <tom@tromey.com>
8375
8376 * nto-procfs.c (do_closedir_cleanup): Remove.
8377 (procfs_pidlist): Use gdb_dir_up.
8378 * procfs.c (do_closedir_cleanup): Remove.
8379 (proc_update_threads): Use gdb_dir_up.
8380 * common/filestuff.h (struct gdb_dir_deleter): New.
8381 (gdb_dir_up): New typedef.
8382
8383 2018-05-04 Tom Tromey <tom@tromey.com>
8384
8385 * ada-lang.c (print_mention_exception): Use std::string.
8386
8387 2018-05-04 Tom Tromey <tom@tromey.com>
8388
8389 * ada-lang.c (create_excep_cond_exprs): Update.
8390 (ada_exception_catchpoint_cond_string): Use std::string.
8391
8392 2018-05-04 Tom Tromey <tom@tromey.com>
8393
8394 * ada-lang.c (xget_renaming_scope): Return std::string.
8395 (old_renaming_is_invisible): Update.
8396
8397 2018-05-04 Tom Tromey <tom@tromey.com>
8398
8399 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
8400 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
8401
8402 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
8403
8404 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
8405
8406 2018-05-04 Tom Tromey <tom@tromey.com>
8407
8408 * remote.c (remote_query_supported_append): Change type.
8409 (remote_check_symbols): Update.
8410
8411 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
8412
8413 PR gdb/11420
8414 * configure.ac: Prepend libpython.
8415 * python/python-config.py: Likewise.
8416 * configure: Regenerate.
8417
8418 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
8419
8420 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
8421
8422 2018-05-03 Pedro Alves <palves@redhat.com>
8423
8424 * s390-linux-nat.c
8425 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
8426 override. Write 'true' instead of '1'.
8427 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
8428 declaration.
8429
8430 2018-05-02 Pedro Alves <palves@redhat.com>
8431
8432 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
8433 add_inf_child_target.
8434 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
8435 add_inf_child_target.
8436 * aix-thread.c (aix_thread_target_info): New.
8437 (aix_thread_target) <shortname, longname, doc>: Delete.
8438 <info>: New.
8439 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
8440 add_inf_child_target.
8441 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
8442 add_inf_child_target.
8443 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
8444 add_inf_child_target.
8445 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
8446 add_inf_child_target.
8447 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
8448 add_inf_child_target.
8449 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
8450 add_inf_child_target.
8451 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
8452 add_inf_child_target.
8453 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
8454 add_inf_child_target.
8455 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
8456 add_inf_child_target.
8457 * bfd-target.c (target_bfd_target_info): New.
8458 (target_bfd) <shortname, longname, doc>: Delete.
8459 <info>: New.
8460 * bsd-kvm.c (bsd_kvm_target_info): New.
8461 (bsd_kvm_target) <shortname, longname, doc>: Delete.
8462 <info>: New.
8463 (bsd_kvm_target::open): Rename to ...
8464 (bsd_kvm_target_open): ... this. Adjust.
8465 * bsd-uthread.c (bsd_uthread_target_info): New.
8466 (bsd_uthread_target) <shortname, longname, doc>: Delete.
8467 <info>: New.
8468 * corefile.c (core_file_command): Adjust.
8469 * corelow.c (core_target_info): New.
8470 (core_target) <shortname, longname, doc>: Delete.
8471 <info>: New.
8472 (core_target::open): Rename to ...
8473 (core_target_open): ... this. Adjust.
8474 * ctf.c (ctf_target_info): New.
8475 (ctf_target) <shortname, longname, doc>: Delete.
8476 <info>: New.
8477 (ctf_target::open): Rename to ...
8478 (ctf_target_open): ... this.
8479 (_initialize_ctf): Adjust.
8480 * exec.c (exec_target_info): New.
8481 (exec_target) <shortname, longname, doc>: Delete.
8482 <info>: New.
8483 (exec_target::open): Rename to ...
8484 (exec_target_open): ... this.
8485 * gdbcore.h (core_target_open): Declare.
8486 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
8487 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
8488 add_inf_child_target.
8489 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
8490 add_inf_child_target.
8491 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
8492 add_inf_child_target.
8493 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
8494 add_inf_child_target.
8495 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
8496 add_inf_child_target.
8497 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
8498 add_inf_child_target.
8499 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
8500 add_inf_child_target.
8501 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
8502 add_inf_child_target.
8503 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
8504 add_inf_child_target.
8505 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
8506 add_inf_child_target.
8507 * inf-child.c (inf_child_target_info): New.
8508 (inf_child_target::info): New.
8509 (inf_child_open_target): Remove 'target' parameter. Use
8510 get_native_target instead.
8511 (inf_child_target::open): Delete.
8512 (add_inf_child_target): New.
8513 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
8514 Delete.
8515 <info>: New.
8516 (add_inf_child_target): Declare.
8517 (inf_child_open_target): Declare.
8518 * linux-thread-db.c (thread_db_target_info): New.
8519 (thread_db_target) <shortname, longname, doc>: Delete.
8520 <info>: New.
8521 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
8522 add_inf_child_target.
8523 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
8524 add_inf_child_target.
8525 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
8526 add_inf_child_target.
8527 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
8528 add_inf_child_target.
8529 * make-target-delegates (print_class): Adjust.
8530 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
8531 add_inf_child_target.
8532 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
8533 add_inf_child_target.
8534 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
8535 add_inf_child_target.
8536 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
8537 add_inf_child_target.
8538 * nto-procfs.c (nto_native_target_info): New.
8539 (nto_procfs_target_native) <shortname, longname, doc>:
8540 Delete.
8541 <info>: New.
8542 (nto_procfs_target_info): New.
8543 (nto_procfs_target_procfs) <shortname, longname, doc>:
8544 Delete.
8545 <info>: New.
8546 (init_procfs_targets): Adjust.
8547 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
8548 add_inf_child_target.
8549 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
8550 add_inf_child_target.
8551 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
8552 add_inf_child_target.
8553 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
8554 add_inf_child_target.
8555 * ravenscar-thread.c (ravenscar_target_info): New.
8556 (ravenscar_thread_target) <shortname, longname, doc>:
8557 Delete.
8558 <info>: New.
8559 * record-btrace.c (record_btrace_target_info):
8560 (record_btrace_target) <shortname, longname, doc>: Delete.
8561 <info>: New.
8562 (record_btrace_target::open): Rename to ...
8563 (record_btrace_target_open): ... this. Adjust.
8564 * record-full.c (record_longname, record_doc): New.
8565 (record_full_base_target) <shortname, longname, doc>: Delete.
8566 <info>: New.
8567 (record_full_target_info): New.
8568 (record_full_target): <shortname>: Delete.
8569 <info>: New.
8570 (record_full_core_open_1, record_full_open_1): Update comments.
8571 (record_full_base_target::open): Rename to ...
8572 (record_full_open): ... this.
8573 (cmd_record_full_restore): Update.
8574 (_initialize_record_full): Update.
8575 * remote-sim.c (remote_sim_target_info): New.
8576 (gdbsim_target) <shortname, longname, doc>: Delete.
8577 <info>: New.
8578 (gdbsim_target::open): Rename to ...
8579 (gdbsim_target_open): ... this.
8580 (_initialize_remote_sim): Adjust.
8581 * remote.c (remote_doc): New.
8582 (remote_target_info): New.
8583 (remote_target) <shortname, longname, doc>: Delete.
8584 <info>: New.
8585 (extended_remote_target_info): New.
8586 (extended_remote_target) <shortname, longname, doc>: Delete.
8587 <info>: New.
8588 (remote_target::open_1): Make static. Adjust.
8589 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
8590 * s390-linux-nat.c (_initialize_s390_nat): Use
8591 add_inf_child_target.
8592 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
8593 add_inf_child_target.
8594 * sol-thread.c (thread_db_target_info): New.
8595 (sol_thread_target) <shortname, longname, doc>: Delete.
8596 <info>: New.
8597 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
8598 add_inf_child_target.
8599 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
8600 add_inf_child_target.
8601 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
8602 add_inf_child_target.
8603 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
8604 add_inf_child_target.
8605 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
8606 add_inf_child_target.
8607 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
8608 add_inf_child_target.
8609 * spu-linux-nat.c (_initialize_spu_nat): Use
8610 add_inf_child_target.
8611 * spu-multiarch.c (spu_multiarch_target_info): New.
8612 (spu_multiarch_target) <shortname, longname, doc>: Delete.
8613 <info>: New.
8614 * target-delegates.c: Regenerate.
8615 * target.c: Include <unordered_map>.
8616 (target_ops_p): Delete.
8617 (DEF_VEC_P(target_ops_p)): Delete.
8618 (target_factories): New.
8619 (test_target_info): New.
8620 (test_target_ops::info): New.
8621 (open_target): Adjust to use target_factories.
8622 (add_target_with_completer): Rename to ...
8623 (add_target): ... this. Change prototype. Register target_info
8624 and open callback in target_factories. Register target_info in
8625 command context instead of target_ops.
8626 (add_target): Delete old implementation.
8627 (add_deprecated_target_alias): Change prototype. Adjust.
8628 (the_native_target): New.
8629 (set_native_target, get_native_target): New.
8630 (find_default_run_target): Use the_native_target.
8631 (find_attach_target, find_run_target): Simplify.
8632 (target_ops::open): Delete.
8633 (dummy_target_info): New.
8634 (dummy_target::shortname, dummy_target::longname)
8635 (dummy_target::doc): Delete.
8636 (dummy_target::info): New.
8637 (debug_target::shortname, debug_target::longname)
8638 (debug_target::doc): Delete.
8639 (debug_target::info): New.
8640 * target.h (struct target_info): New.
8641 (target_ops::~target_ops): Add comment.
8642 (target_ops::info): New.
8643 (target_ops::shortname, target_ops::longname, target_ops::doc): No
8644 longer virtual. Implement in terms of target_info.
8645 (set_native_target, get_native_target): Declare.
8646 (target_open_ftype): New.
8647 (add_target, add_target_with_completer)
8648 (add_deprecated_target_alias): Change prototype.
8649 (test_target) <shortname, longname, doc>: Delete.
8650 <info>: New.
8651 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
8652 add_inf_child_target.
8653 * tracefile-tfile.c (tfile_target_info): New.
8654 (tfile_target) <shortname, longname, doc>: Delete.
8655 <info>: New.
8656 (tfile_target::open): Rename to ...
8657 (tfile_target_open): ... this.
8658 (_initialize_tracefile_tfile): Adjust.
8659 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
8660 add_inf_child_target.
8661 * windows-nat.c (_initialize_windows_nat): Use
8662 add_inf_child_target.
8663 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
8664 add_inf_child_target.
8665
8666 2018-05-02 Pedro Alves <palves@redhat.com>
8667
8668 * linux-nat.h (linux_nat_target) <low_new_thread,
8669 low_delete_thread, low_new_fork, low_forget_process,
8670 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
8671 New virtual methods.
8672 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
8673 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
8674 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
8675 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
8676 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
8677 Delete.
8678 * linux-fork.c (delete_fork): Adjust to call low method.
8679 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
8680 (linux_nat_new_fork, linux_nat_forget_process_hook)
8681 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
8682 (linux_nat_status_is_event):
8683 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
8684 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
8685 to call low method.
8686 (sigtrap_is_event): Rename to ...
8687 (linux_nat_target::low_status_is_event): ... this.
8688 (linux_nat_set_status_is_event): Delete.
8689 (save_stop_reason, linux_nat_wait_1)
8690 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
8691 low methods.
8692 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
8693 (linux_nat_set_new_fork, linux_nat_set_forget_process)
8694 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
8695 (linux_nat_set_prepare_to_resume): Delete.
8696 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
8697 low virtual methods.
8698 * amd64-linux-nat.c: Likewise.
8699 * arm-linux-nat.c: Likewise.
8700 * i386-linux-nat.c: Likewise.
8701 * ia64-linux-nat.c: Likewise.
8702 * mips-linux-nat.c: Likewise.
8703 * ppc-linux-nat.c: Likewise.
8704 * s390-linux-nat.c: Likewise.
8705 * sparc64-linux-nat.c: Likewise.
8706 * x86-linux-nat.c: Likewise.
8707 * x86-linux-nat.h: Include "nat/x86-linux.h".
8708 (x86_linux_nat_target) <low_new_fork, low_forget_process,
8709 low_prepare_to_resume, low_new_thread, low_delete_thread>:
8710 Override methods.
8711
8712 2018-05-02 Pedro Alves <palves@redhat.com>
8713
8714 * target.h (target_ops)
8715 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
8716 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
8717 stopped_by_watchpoint, have_continuable_watchpoint,
8718 stopped_data_address, watchpoint_addr_within_range,
8719 can_accel_watchpoint_condition, can_run, thread_alive,
8720 has_all_memory, has_memory, has_stack, has_registers,
8721 has_execution, can_async_p, is_async_p, supports_non_stop,
8722 always_non_stop_p, can_execute_reverse, supports_multi_process,
8723 supports_enable_disable_tracepoint,
8724 supports_disable_randomization, supports_string_tracing,
8725 supports_evaluation_of_breakpoint_conditions,
8726 can_run_breakpoint_commands, filesystem_is_local,
8727 can_download_tracepoint, get_trace_state_variable_value,
8728 set_trace_notes, get_tib_address, use_agent, can_use_agent,
8729 record_is_replaying, record_will_replay,
8730 augmented_libraries_svr4_read>: Adjust to return bool.
8731 * aarch64-linux-nat.c: All implementations adjusted.
8732 * aix-thread.c: All implementations adjusted.
8733 * arm-linux-nat.c: All implementations adjusted.
8734 * breakpoint.c: All implementations adjusted.
8735 * bsd-kvm.c: All implementations adjusted.
8736 * bsd-uthread.c: All implementations adjusted.
8737 * corelow.c: All implementations adjusted.
8738 * ctf.c: All implementations adjusted.
8739 * darwin-nat.c: All implementations adjusted.
8740 * darwin-nat.h: All implementations adjusted.
8741 * exec.c: All implementations adjusted.
8742 * fbsd-nat.c: All implementations adjusted.
8743 * fbsd-nat.h: All implementations adjusted.
8744 * gnu-nat.c: All implementations adjusted.
8745 * gnu-nat.h: All implementations adjusted.
8746 * go32-nat.c: All implementations adjusted.
8747 * ia64-linux-nat.c: All implementations adjusted.
8748 * inf-child.c: All implementations adjusted.
8749 * inf-child.h: All implementations adjusted.
8750 * inf-ptrace.c: All implementations adjusted.
8751 * inf-ptrace.h: All implementations adjusted.
8752 * linux-nat.c: All implementations adjusted.
8753 * linux-nat.h: All implementations adjusted.
8754 * mips-linux-nat.c: All implementations adjusted.
8755 * nto-procfs.c: All implementations adjusted.
8756 * ppc-linux-nat.c: All implementations adjusted.
8757 * procfs.c: All implementations adjusted.
8758 * ravenscar-thread.c: All implementations adjusted.
8759 * record-btrace.c: All implementations adjusted.
8760 * record-full.c: All implementations adjusted.
8761 * remote-sim.c: All implementations adjusted.
8762 * remote.c: All implementations adjusted.
8763 * s390-linux-nat.c: All implementations adjusted.
8764 * sol-thread.c: All implementations adjusted.
8765 * spu-multiarch.c: All implementations adjusted.
8766 * target-delegates.c: All implementations adjusted.
8767 * target.c: All implementations adjusted.
8768 * target.h: All implementations adjusted.
8769 * tracefile-tfile.c: All implementations adjusted.
8770 * tracefile.c: All implementations adjusted.
8771 * tracefile.h: All implementations adjusted.
8772 * windows-nat.c: All implementations adjusted.
8773 * x86-linux-nat.h: All implementations adjusted.
8774 * x86-nat.h: All implementations adjusted.
8775
8776 2018-05-02 Pedro Alves <palves@redhat.com>
8777
8778 * make-target-delegates (scan_target_h): Don't trim lines here.
8779 Replace sequences of tabs and/or whitespace with a single
8780 whitespace.
8781 (top level, parsing methods): Trim each line before processing it
8782 here.
8783
8784 2018-05-02 Pedro Alves <palves@redhat.com>
8785 John Baldwin <jhb@freebsd.org>
8786
8787 * target.h (enum strata) <debug_stratum>: New.
8788 (struct target_ops) <all delegation methods>: Replace by C++
8789 virtual methods, and drop "to_" prefix. All references updated
8790 throughout.
8791 <to_shortname, to_longname, to_doc, to_data,
8792 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
8793 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
8794 virtual methods. All references updated throughout.
8795 <can_attach, supports_terminal_ours, can_create_inferior,
8796 get_thread_control_capabilities, attach_no_wait>: New
8797 virtual methods.
8798 <insert_breakpoint, remove_breakpoint>: Now
8799 TARGET_DEFAULT_NORETURN methods.
8800 <info_proc>: Now returns bool.
8801 <to_magic>: Delete.
8802 (OPS_MAGIC): Delete.
8803 (current_target): Delete. All references replaced by references
8804 to ...
8805 (target_stack): ... this. New.
8806 (target_shortname, target_longname): Adjust.
8807 (target_can_run): Now a function declaration.
8808 (default_child_has_all_memory, default_child_has_memory)
8809 (default_child_has_stack, default_child_has_registers)
8810 (default_child_has_execution): Remove target_ops parameter.
8811 (complete_target_initialization): Delete.
8812 (memory_breakpoint_target): New template class.
8813 (test_target_ops): Refactor as a C++ class with virtual methods.
8814 * make-target-delegates (NAME_PART): Tighten.
8815 (POINTER_PART, CP_SYMBOL): New.
8816 (SIMPLE_RETURN_PART): Reimplement.
8817 (VEC_RETURN_PART): Expect less.
8818 (RETURN_PART, VIRTUAL_PART): New.
8819 (METHOD): Adjust to C++ virtual methods.
8820 (scan_target_h): Remove reference to C99.
8821 (dname): Output "target_ops::" prefix.
8822 (write_function_header): Adjust to output a C++ class method.
8823 (write_declaration): New.
8824 (write_delegator): Adjust to output a C++ class method.
8825 (tdname): Output "dummy_target::" prefix.
8826 (write_tdefault, write_debugmethod): Adjust to output a C++ class
8827 method.
8828 (tdefault_names, debug_names): Delete.
8829 (return_types, tdefaults, styles, argtypes_array): New.
8830 (top level): All methods are delegators.
8831 (print_class): New.
8832 (top level): Print dummy_target and debug_target classes.
8833 * target-delegates.c: Regenerate.
8834 * target-debug.h (target_debug_print_enum_info_proc_what)
8835 (target_debug_print_thread_control_capabilities)
8836 (target_debug_print_thread_info_p): New.
8837 * target.c (dummy_target): Delete.
8838 (the_dummy_target, the_debug_target): New.
8839 (target_stack): Now extern.
8840 (set_targetdebug): Push/unpush debug target.
8841 (default_child_has_all_memory, default_child_has_memory)
8842 (default_child_has_stack, default_child_has_registers)
8843 (default_child_has_execution): Remove target_ops parameter.
8844 (complete_target_initialization): Delete.
8845 (add_target_with_completer): No longer call
8846 complete_target_initialization.
8847 (target_supports_terminal_ours): Use regular delegation.
8848 (update_current_target): Delete.
8849 (push_target): No longer check magic number. Don't call
8850 update_current_target.
8851 (unpush_target): Don't call update_current_target.
8852 (target_is_pushed): No longer check magic number.
8853 (target_require_runnable): Skip for all stratums over
8854 process_stratum.
8855 (target_ops::info_proc): New.
8856 (target_info_proc): Use find_target_at and
8857 find_default_run_target.
8858 (target_supports_disable_randomization): Use regular delegation.
8859 (target_get_osdata): Use find_target_at.
8860 (target_ops::open, target_ops::close, target_ops::can_attach)
8861 (target_ops::attach, target_ops::can_create_inferior)
8862 (target_ops::create_inferior, target_ops::can_run)
8863 (target_can_run): New.
8864 (default_fileio_target): Use regular delegation.
8865 (target_ops::fileio_open, target_ops::fileio_pwrite)
8866 (target_ops::fileio_pread, target_ops::fileio_fstat)
8867 (target_ops::fileio_close, target_ops::fileio_unlink)
8868 (target_ops::fileio_readlink): New.
8869 (target_fileio_open_1, target_fileio_unlink)
8870 (target_fileio_readlink): Always call the target method. Handle
8871 FILEIO_ENOSYS.
8872 (return_zero, return_zero_has_execution): Delete.
8873 (init_dummy_target): Delete.
8874 (dummy_target::dummy_target, dummy_target::shortname)
8875 (dummy_target::longname, dummy_target::doc)
8876 (debug_target::debug_target, debug_target::shortname)
8877 (debug_target::longname, debug_target::doc): New.
8878 (target_supports_delete_record): Use regular delegation.
8879 (setup_target_debug): Delete.
8880 (maintenance_print_target_stack): Skip debug_stratum.
8881 (initialize_targets): Instantiate the_dummy_target and
8882 the_debug_target.
8883 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
8884 use target_stack.
8885 (target_auxv_search, fprint_target_auxv): Adjust.
8886 (info_auxv_command): Adjust to use target_stack.
8887 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
8888 * exceptions.c (print_flush): Handle a NULL target_stack.
8889 * regcache.c (target_ops_no_register): Refactor as class with
8890 virtual methods.
8891
8892 * exec.c (exec_target): New class.
8893 (exec_ops): Now an exec_target.
8894 (exec_open, exec_close_1, exec_get_section_table)
8895 (exec_xfer_partial, exec_files_info, exec_has_memory)
8896 (exec_make_note_section): Refactor as exec_target methods.
8897 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
8898 Delete.
8899 (exec_target::find_memory_regions): New.
8900 (_initialize_exec): Don't call init_exec_ops.
8901 * gdbcore.h (exec_file_clear): Delete.
8902
8903 * corefile.c (core_target): Delete.
8904 (core_file_command): Adjust.
8905 * corelow.c (core_target): New class.
8906 (the_core_target): New.
8907 (core_close): Remove target_ops parameter.
8908 (core_close_cleanup): Adjust.
8909 (core_target::close): New.
8910 (core_open, core_detach, get_core_registers, core_files_info)
8911 (core_xfer_partial, core_thread_alive, core_read_description)
8912 (core_pid_to_str, core_thread_name, core_has_memory)
8913 (core_has_stack, core_has_registers, core_info_proc): Rework as
8914 core_target methods.
8915 (ignore, core_remove_breakpoint, init_core_ops): Delete.
8916 (_initialize_corelow): Initialize the_core_target.
8917 * gdbcore.h (core_target): Delete.
8918 (the_core_target): New.
8919
8920 * ctf.c: (ctf_target): New class.
8921 (ctf_ops): Now a ctf_target.
8922 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
8923 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
8924 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
8925 methods.
8926 (init_ctf_ops): Delete.
8927 (_initialize_ctf): Don't call it.
8928 * tracefile-tfile.c (tfile_target): New class.
8929 (tfile_ops): Now a tfile_target.
8930 (tfile_open, tfile_close, tfile_files_info)
8931 (tfile_get_tracepoint_status, tfile_trace_find)
8932 (tfile_fetch_registers, tfile_xfer_partial)
8933 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
8934 Refactor as tfile_target methods.
8935 (tfile_xfer_partial_features): Remove target_ops parameter.
8936 (init_tfile_ops): Delete.
8937 (_initialize_tracefile_tfile): Don't call it.
8938 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
8939 (tracefile_has_stack, tracefile_has_registers)
8940 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
8941 tracefile_target methods.
8942 (init_tracefile_ops): Delete.
8943 (tracefile_target::tracefile_target): New.
8944 * tracefile.h: Include "target.h".
8945 (tracefile_target): New class.
8946 (init_tracefile_ops): Delete.
8947
8948 * spu-multiarch.c (spu_multiarch_target): New class.
8949 (spu_ops): Now a spu_multiarch_target.
8950 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
8951 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
8952 (spu_search_memory, spu_mourn_inferior): Refactor as
8953 spu_multiarch_target methods.
8954 (init_spu_ops): Delete.
8955 (_initialize_spu_multiarch): Remove references to init_spu_ops,
8956 complete_target_initialization.
8957
8958 * ravenscar-thread.c (ravenscar_thread_target): New class.
8959 (ravenscar_ops): Now a ravenscar_thread_target.
8960 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
8961 (ravenscar_thread_alive, ravenscar_pid_to_str)
8962 (ravenscar_fetch_registers, ravenscar_store_registers)
8963 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
8964 (ravenscar_stopped_by_hw_breakpoint)
8965 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8966 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8967 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8968 methods.
8969 (init_ravenscar_thread_ops): Delete.
8970 (_initialize_ravenscar): Remove references to
8971 init_ravenscar_thread_ops and complete_target_initialization.
8972
8973 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8974 (bsd_uthread_target): New class.
8975 (bsd_uthread_ops): Now a bsd_uthread_target.
8976 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8977 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8978 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8979 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8980 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8981 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8982 (bsd_uthread_target): Delete function.
8983 (_initialize_bsd_uthread): Remove reference to
8984 complete_target_initialization.
8985
8986 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8987 (target_bfd): ... this new class.
8988 (target_bfd_xfer_partial, target_bfd_get_section_table)
8989 (target_bfd_close): Refactor as target_bfd methods.
8990 (target_bfd::~target_bfd): New.
8991 (target_bfd_reopen): Adjust.
8992 (target_bfd::close): New.
8993
8994 * record-btrace.c (record_btrace_target): New class.
8995 (record_btrace_ops): Now a record_btrace_target.
8996 (record_btrace_open, record_btrace_stop_recording)
8997 (record_btrace_disconnect, record_btrace_close)
8998 (record_btrace_async, record_btrace_info)
8999 (record_btrace_insn_history, record_btrace_insn_history_range)
9000 (record_btrace_insn_history_from, record_btrace_call_history)
9001 (record_btrace_call_history_range)
9002 (record_btrace_call_history_from, record_btrace_record_method)
9003 (record_btrace_is_replaying, record_btrace_will_replay)
9004 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
9005 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
9006 (record_btrace_store_registers, record_btrace_prepare_to_store)
9007 (record_btrace_to_get_unwinder)
9008 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
9009 (record_btrace_commit_resume, record_btrace_wait)
9010 (record_btrace_stop, record_btrace_can_execute_reverse)
9011 (record_btrace_stopped_by_sw_breakpoint)
9012 (record_btrace_supports_stopped_by_sw_breakpoint)
9013 (record_btrace_stopped_by_hw_breakpoint)
9014 (record_btrace_supports_stopped_by_hw_breakpoint)
9015 (record_btrace_update_thread_list, record_btrace_thread_alive)
9016 (record_btrace_goto_begin, record_btrace_goto_end)
9017 (record_btrace_goto, record_btrace_stop_replaying_all)
9018 (record_btrace_execution_direction)
9019 (record_btrace_prepare_to_generate_core)
9020 (record_btrace_done_generating_core): Refactor as
9021 record_btrace_target methods.
9022 (init_record_btrace_ops): Delete.
9023 (_initialize_record_btrace): Remove reference to
9024 init_record_btrace_ops.
9025 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
9026 the execution_direction global.
9027 (record_full_base_target, record_full_target)
9028 (record_full_core_target): New classes.
9029 (record_full_ops): Now a record_full_target.
9030 (record_full_core_ops): Now a record_full_core_target.
9031 (record_full_target::detach, record_full_target::disconnect)
9032 (record_full_core_target::disconnect)
9033 (record_full_target::mourn_inferior, record_full_target::kill):
9034 New.
9035 (record_full_open, record_full_close, record_full_async): Refactor
9036 as methods of the record_full_base_target class.
9037 (record_full_resume, record_full_commit_resume): Refactor
9038 as methods of the record_full_target class.
9039 (record_full_wait, record_full_stopped_by_watchpoint)
9040 (record_full_stopped_data_address)
9041 (record_full_stopped_by_sw_breakpoint)
9042 (record_full_supports_stopped_by_sw_breakpoint)
9043 (record_full_stopped_by_hw_breakpoint)
9044 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
9045 methods of the record_full_base_target class.
9046 (record_full_store_registers, record_full_xfer_partial)
9047 (record_full_insert_breakpoint, record_full_remove_breakpoint):
9048 Refactor as methods of the record_full_target class.
9049 (record_full_can_execute_reverse, record_full_get_bookmark)
9050 (record_full_goto_bookmark, record_full_execution_direction)
9051 (record_full_record_method, record_full_info, record_full_delete)
9052 (record_full_is_replaying, record_full_will_replay)
9053 (record_full_goto_begin, record_full_goto_end, record_full_goto)
9054 (record_full_stop_replaying): Refactor as methods of the
9055 record_full_base_target class.
9056 (record_full_core_resume, record_full_core_kill)
9057 (record_full_core_fetch_registers)
9058 (record_full_core_prepare_to_store)
9059 (record_full_core_store_registers, record_full_core_xfer_partial)
9060 (record_full_core_insert_breakpoint)
9061 (record_full_core_remove_breakpoint)
9062 (record_full_core_has_execution): Refactor
9063 as methods of the record_full_core_target class.
9064 (record_full_base_target::supports_delete_record): New.
9065 (init_record_full_ops): Delete.
9066 (init_record_full_core_ops): Delete.
9067 (record_full_save): Refactor as method of the
9068 record_full_base_target class.
9069 (_initialize_record_full): Remove references to
9070 init_record_full_ops and init_record_full_core_ops.
9071
9072 * remote.c (remote_target, extended_remote_target): New classes.
9073 (remote_ops): Now a remote_target.
9074 (extended_remote_ops): Now an extended_remote_target.
9075 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
9076 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
9077 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
9078 (remote_pass_signals, remote_set_syscall_catchpoint)
9079 (remote_program_signals, )
9080 (remote_thread_always_alive): Remove target_ops parameter.
9081 (remote_thread_alive, remote_thread_name)
9082 (remote_update_thread_list, remote_threads_extra_info)
9083 (remote_static_tracepoint_marker_at)
9084 (remote_static_tracepoint_markers_by_strid)
9085 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
9086 (remote_open): Refactor as methods of remote_target.
9087 (extended_remote_open, extended_remote_detach)
9088 (extended_remote_attach, extended_remote_post_attach):
9089 (extended_remote_supports_disable_randomization)
9090 (extended_remote_create_inferior): : Refactor as method of
9091 extended_remote_target.
9092 (remote_set_permissions, remote_open_1, remote_detach)
9093 (remote_follow_fork, remote_follow_exec, remote_disconnect)
9094 (remote_resume, remote_commit_resume, remote_stop)
9095 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
9096 (remote_terminal_ours, remote_wait, remote_fetch_registers)
9097 (remote_prepare_to_store, remote_store_registers)
9098 (remote_flash_erase, remote_flash_done, remote_files_info)
9099 (remote_kill, remote_mourn, remote_insert_breakpoint)
9100 (remote_remove_breakpoint, remote_insert_watchpoint)
9101 (remote_watchpoint_addr_within_range)
9102 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
9103 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
9104 (remote_supports_stopped_by_sw_breakpoint)
9105 (remote_stopped_by_hw_breakpoint)
9106 (remote_supports_stopped_by_hw_breakpoint)
9107 (remote_stopped_by_watchpoint, remote_stopped_data_address)
9108 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
9109 (remote_verify_memory): Refactor as methods of remote_target.
9110 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
9111 parameter.
9112 (remote_xfer_partial, remote_get_memory_xfer_limit)
9113 (remote_search_memory, remote_rcmd, remote_memory_map)
9114 (remote_pid_to_str, remote_get_thread_local_address)
9115 (remote_get_tib_address, remote_read_description): Refactor as
9116 methods of remote_target.
9117 (remote_target::fileio_open, remote_target::fileio_pwrite)
9118 (remote_target::fileio_pread, remote_target::fileio_close): New.
9119 (remote_hostio_readlink, remote_hostio_fstat)
9120 (remote_filesystem_is_local, remote_can_execute_reverse)
9121 (remote_supports_non_stop, remote_supports_disable_randomization)
9122 (remote_supports_multi_process, remote_supports_cond_breakpoints)
9123 (remote_supports_enable_disable_tracepoint)
9124 (remote_supports_string_tracing)
9125 (remote_can_run_breakpoint_commands, remote_trace_init)
9126 (remote_download_tracepoint, remote_can_download_tracepoint)
9127 (remote_download_trace_state_variable, remote_enable_tracepoint)
9128 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
9129 (remote_trace_start, remote_get_trace_status)
9130 (remote_get_tracepoint_status, remote_trace_stop)
9131 (remote_trace_find, remote_get_trace_state_variable_value)
9132 (remote_save_trace_data, remote_get_raw_trace_data)
9133 (remote_set_disconnected_tracing, remote_core_of_thread)
9134 (remote_set_circular_trace_buffer, remote_traceframe_info)
9135 (remote_get_min_fast_tracepoint_insn_len)
9136 (remote_set_trace_buffer_size, remote_set_trace_notes)
9137 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
9138 (remote_disable_btrace, remote_teardown_btrace)
9139 (remote_read_btrace, remote_btrace_conf)
9140 (remote_augmented_libraries_svr4_read, remote_load)
9141 (remote_pid_to_exec_file, remote_can_do_single_step)
9142 (remote_execution_direction, remote_thread_handle_to_thread_info):
9143 Refactor as methods of remote_target.
9144 (init_remote_ops, init_extended_remote_ops): Delete.
9145 (remote_can_async_p, remote_is_async_p, remote_async)
9146 (remote_thread_events, remote_upload_tracepoints)
9147 (remote_upload_trace_state_variables): Refactor as methods of
9148 remote_target.
9149 (_initialize_remote): Remove references to init_remote_ops and
9150 init_extended_remote_ops.
9151
9152 * remote-sim.c (gdbsim_target): New class.
9153 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
9154 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
9155 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
9156 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
9157 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
9158 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
9159 Refactor as methods of gdbsim_target.
9160 (gdbsim_ops): Now a gdbsim_target.
9161 (init_gdbsim_ops): Delete.
9162 (gdbsim_cntrl_c): Adjust.
9163 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
9164
9165 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
9166 (the_amd64_linux_nat_target): New.
9167 (amd64_linux_fetch_inferior_registers)
9168 (amd64_linux_store_inferior_registers): Refactor as methods of
9169 amd64_linux_nat_target.
9170 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
9171 * i386-linux-nat.c: Don't include "linux-nat.h".
9172 (i386_linux_nat_target): New class.
9173 (the_i386_linux_nat_target): New.
9174 (i386_linux_fetch_inferior_registers)
9175 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
9176 as methods of i386_linux_nat_target.
9177 (_initialize_i386_linux_nat): Adjust. Set linux_target.
9178 * inf-child.c (inf_child_ops): Delete.
9179 (inf_child_fetch_inferior_registers)
9180 (inf_child_store_inferior_registers): Delete.
9181 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
9182 methods of inf_child_target.
9183 (inf_child_target::supports_terminal_ours)
9184 (inf_child_target::terminal_init)
9185 (inf_child_target::terminal_inferior)
9186 (inf_child_target::terminal_ours_for_output)
9187 (inf_child_target::terminal_ours, inf_child_target::interrupt)
9188 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
9189 New.
9190 (inf_child_open, inf_child_disconnect, inf_child_close)
9191 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
9192 (inf_child_post_startup_inferior, inf_child_can_run)
9193 (inf_child_pid_to_exec_file): Refactor as methods of
9194 inf_child_target.
9195 (inf_child_follow_fork): Delete.
9196 (inf_child_target::can_create_inferior)
9197 (inf_child_target::can_attach): New.
9198 (inf_child_target::has_all_memory, inf_child_target::has_memory)
9199 (inf_child_target::has_stack, inf_child_target::has_registers)
9200 (inf_child_target::has_execution): New.
9201 (inf_child_fileio_open, inf_child_fileio_pwrite)
9202 (inf_child_fileio_pread, inf_child_fileio_fstat)
9203 (inf_child_fileio_close, inf_child_fileio_unlink)
9204 (inf_child_fileio_readlink, inf_child_use_agent)
9205 (inf_child_can_use_agent): Refactor as methods of
9206 inf_child_target.
9207 (return_zero, inf_child_target): Delete.
9208 (inf_child_target::inf_child_target): New.
9209 * inf-child.h: Include "target.h".
9210 (inf_child_target): Delete function prototype.
9211 (inf_child_target): New class.
9212 (inf_child_open_target, inf_child_mourn_inferior)
9213 (inf_child_maybe_unpush_target): Delete.
9214 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
9215 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
9216 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
9217 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
9218 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
9219 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
9220 (inf_ptrace_wait, inf_ptrace_xfer_partial)
9221 (inf_ptrace_thread_alive, inf_ptrace_files_info)
9222 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
9223 methods of inf_ptrace_target.
9224 (inf_ptrace_target): Delete function.
9225 * inf-ptrace.h: Include "inf-child.h".
9226 (inf_ptrace_target): Delete function declaration.
9227 (inf_ptrace_target): New class.
9228 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
9229 * linux-nat.c (linux_target): New.
9230 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
9231 (linux_nat_target::~linux_nat_target): New.
9232 (linux_child_post_attach, linux_child_post_startup_inferior)
9233 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
9234 (linux_child_remove_fork_catchpoint)
9235 (linux_child_insert_vfork_catchpoint)
9236 (linux_child_remove_vfork_catchpoint)
9237 (linux_child_insert_exec_catchpoint)
9238 (linux_child_remove_exec_catchpoint)
9239 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
9240 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
9241 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
9242 (linux_nat_stopped_data_address)
9243 (linux_nat_stopped_by_sw_breakpoint)
9244 (linux_nat_supports_stopped_by_sw_breakpoint)
9245 (linux_nat_stopped_by_hw_breakpoint)
9246 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
9247 (linux_nat_kill, linux_nat_mourn_inferior)
9248 (linux_nat_xfer_partial, linux_nat_thread_alive)
9249 (linux_nat_update_thread_list, linux_nat_pid_to_str)
9250 (linux_nat_thread_name, linux_child_pid_to_exec_file)
9251 (linux_child_static_tracepoint_markers_by_strid)
9252 (linux_nat_is_async_p, linux_nat_can_async_p)
9253 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
9254 (linux_nat_supports_multi_process)
9255 (linux_nat_supports_disable_randomization, linux_nat_async)
9256 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
9257 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
9258 (linux_nat_fileio_open, linux_nat_fileio_readlink)
9259 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
9260 methods of linux_nat_target.
9261 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
9262 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
9263 parameter.
9264 (check_stopped_by_watchpoint): Adjust.
9265 (linux_xfer_partial): Delete.
9266 (linux_target_install_ops, linux_target, linux_nat_add_target):
9267 Delete.
9268 (linux_nat_target::linux_nat_target): New.
9269 * linux-nat.h: Include "inf-ptrace.h".
9270 (linux_nat_target): New.
9271 (linux_target, linux_target_install_ops, linux_nat_add_target):
9272 Delete function declarations.
9273 (linux_target): Declare global.
9274 * linux-thread-db.c (thread_db_target): New.
9275 (thread_db_target::thread_db_target): New.
9276 (thread_db_ops): Delete.
9277 (the_thread_db_target): New.
9278 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
9279 (thread_db_update_thread_list, thread_db_pid_to_str)
9280 (thread_db_extra_thread_info)
9281 (thread_db_thread_handle_to_thread_info)
9282 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
9283 (thread_db_resume): Refactor as methods of thread_db_target.
9284 (init_thread_db_ops): Delete.
9285 (_initialize_thread_db): Remove reference to init_thread_db_ops.
9286 * x86-linux-nat.c: Don't include "linux-nat.h".
9287 (super_post_startup_inferior): Delete.
9288 (x86_linux_nat_target::~x86_linux_nat_target): New.
9289 (x86_linux_child_post_startup_inferior)
9290 (x86_linux_read_description, x86_linux_enable_btrace)
9291 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
9292 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
9293 methods of x86_linux_nat_target.
9294 (x86_linux_create_target): Delete. Bits folded ...
9295 (x86_linux_add_target): ... here. Now takes a linux_nat_target
9296 pointer.
9297 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
9298 (x86_linux_nat_target): New class.
9299 (x86_linux_create_target): Delete.
9300 (x86_linux_add_target): Now takes a linux_nat_target pointer.
9301 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
9302 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
9303 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
9304 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
9305 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
9306 make extern.
9307 (x86_use_watchpoints): Delete.
9308 * x86-nat.h: Include "breakpoint.h" and "target.h".
9309 (x86_use_watchpoints): Delete.
9310 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
9311 (x86_stopped_by_watchpoint, x86_stopped_data_address)
9312 (x86_insert_watchpoint, x86_remove_watchpoint)
9313 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
9314 (x86_stopped_by_hw_breakpoint): New declarations.
9315 (x86_nat_target): New template class.
9316
9317 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
9318 (the_ppc_linux_nat_target): New.
9319 (ppc_linux_fetch_inferior_registers)
9320 (ppc_linux_can_use_hw_breakpoint)
9321 (ppc_linux_region_ok_for_hw_watchpoint)
9322 (ppc_linux_ranged_break_num_registers)
9323 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
9324 (ppc_linux_insert_mask_watchpoint)
9325 (ppc_linux_remove_mask_watchpoint)
9326 (ppc_linux_can_accel_watchpoint_condition)
9327 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
9328 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
9329 (ppc_linux_watchpoint_addr_within_range)
9330 (ppc_linux_masked_watch_num_registers)
9331 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
9332 (ppc_linux_read_description): Refactor as methods of
9333 ppc_linux_nat_target.
9334 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
9335
9336 * procfs.c (procfs_xfer_partial): Delete forward declaration.
9337 (procfs_target): New class.
9338 (the_procfs_target): New.
9339 (procfs_target): Delete function.
9340 (procfs_auxv_parse, procfs_attach, procfs_detach)
9341 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
9342 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
9343 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
9344 (procfs_create_inferior, procfs_update_thread_list)
9345 (procfs_thread_alive, procfs_pid_to_str)
9346 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
9347 (procfs_stopped_data_address, procfs_insert_watchpoint)
9348 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
9349 (proc_find_memory_regions, procfs_info_proc)
9350 (procfs_make_note_section): Refactor as methods of procfs_target.
9351 (_initialize_procfs): Adjust.
9352 * sol-thread.c (sol_thread_target): New class.
9353 (sol_thread_ops): Now a sol_thread_target.
9354 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
9355 (sol_thread_fetch_registers, sol_thread_store_registers)
9356 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
9357 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
9358 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
9359 (init_sol_thread_ops): Delete.
9360 (_initialize_sol_thread): Adjust. Remove references to
9361 init_sol_thread_ops and complete_target_initialization.
9362
9363 * windows-nat.c (windows_nat_target): New class.
9364 (windows_fetch_inferior_registers)
9365 (windows_store_inferior_registers, windows_resume, windows_wait)
9366 (windows_attach, windows_detach, windows_pid_to_exec_file)
9367 (windows_files_info, windows_create_inferior)
9368 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
9369 (windows_close, windows_pid_to_str, windows_xfer_partial)
9370 (windows_get_tib_address, windows_get_ada_task_ptid)
9371 (windows_thread_name, windows_thread_alive): Refactor as
9372 windows_nat_target methods.
9373 (do_initial_windows_stuff): Adjust.
9374 (windows_target): Delete function.
9375 (_initialize_windows_nat): Adjust.
9376
9377 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
9378 (darwin_mourn_inferior, darwin_kill_inferior)
9379 (darwin_create_inferior, darwin_attach, darwin_detach)
9380 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
9381 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
9382 (darwin_supports_multi_process): Refactor as darwin_nat_target
9383 methods.
9384 (darwin_resume_to, darwin_files_info): Delete.
9385 (_initialize_darwin_inferior): Rename to ...
9386 (_initialize_darwin_nat): ... this. Adjust to C++ification.
9387 * darwin-nat.h: Include "inf-child.h".
9388 (darwin_nat_target): New class.
9389 (darwin_complete_target): Delete.
9390 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
9391 (darwin_target): New.
9392 (i386_darwin_fetch_inferior_registers)
9393 (i386_darwin_store_inferior_registers): Refactor as methods of
9394 darwin_nat_target.
9395 (darwin_complete_target): Delete, with ...
9396 (_initialize_i386_darwin_nat): ... bits factored out here.
9397
9398 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
9399 (the_alpha_linux_nat_target): New.
9400 (alpha_linux_register_u_offset): Refactor as
9401 alpha_linux_nat_target method.
9402 (_initialize_alpha_linux_nat): Adjust.
9403 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
9404 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9405 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
9406 methods of linux_nat_trad_target.
9407 (linux_trad_target): Delete.
9408 * linux-nat-trad.h (linux_trad_target): Delete function.
9409 (linux_nat_trad_target): New class.
9410 * mips-linux-nat.c (mips_linux_nat_target): New class.
9411 (super_fetch_registers, super_store_registers, super_close):
9412 Delete.
9413 (the_mips_linux_nat_target): New.
9414 (mips64_linux_regsets_fetch_registers)
9415 (mips64_linux_regsets_store_registers)
9416 (mips64_linux_fetch_registers, mips64_linux_store_registers)
9417 (mips_linux_register_u_offset, mips_linux_read_description)
9418 (mips_linux_can_use_hw_breakpoint)
9419 (mips_linux_stopped_by_watchpoint)
9420 (mips_linux_stopped_data_address)
9421 (mips_linux_region_ok_for_hw_watchpoint)
9422 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
9423 (mips_linux_close): Refactor as methods of mips_linux_nat.
9424 (_initialize_mips_linux_nat): Adjust to C++ification.
9425
9426 * aix-thread.c (aix_thread_target): New class.
9427 (aix_thread_ops): Now an aix_thread_target.
9428 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
9429 (aix_thread_fetch_registers, aix_thread_store_registers)
9430 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
9431 (aix_thread_thread_alive, aix_thread_pid_to_str)
9432 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
9433 Refactor as methods of aix_thread_target.
9434 (init_aix_thread_ops): Delete.
9435 (_initialize_aix_thread): Remove references to init_aix_thread_ops
9436 and complete_target_initialization.
9437 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
9438 (rs6000_nat_target): New class.
9439 (the_rs6000_nat_target): New.
9440 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
9441 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
9442 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
9443 (super_create_inferior): Delete.
9444 (_initialize_rs6000_nat): Adjust to C++ification.
9445
9446 * arm-linux-nat.c (arm_linux_nat_target): New class.
9447 (the_arm_linux_nat_target): New.
9448 (arm_linux_fetch_inferior_registers)
9449 (arm_linux_store_inferior_registers, arm_linux_read_description)
9450 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
9451 (arm_linux_remove_hw_breakpoint)
9452 (arm_linux_region_ok_for_hw_watchpoint)
9453 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
9454 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
9455 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
9456 arm_linux_nat_target.
9457 (_initialize_arm_linux_nat): Adjust to C++ification.
9458
9459 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
9460 (the_aarch64_linux_nat_target): New.
9461 (aarch64_linux_fetch_inferior_registers)
9462 (aarch64_linux_store_inferior_registers)
9463 (aarch64_linux_child_post_startup_inferior)
9464 (aarch64_linux_read_description)
9465 (aarch64_linux_can_use_hw_breakpoint)
9466 (aarch64_linux_insert_hw_breakpoint)
9467 (aarch64_linux_remove_hw_breakpoint)
9468 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
9469 (aarch64_linux_region_ok_for_hw_watchpoint)
9470 (aarch64_linux_stopped_data_address)
9471 (aarch64_linux_stopped_by_watchpoint)
9472 (aarch64_linux_watchpoint_addr_within_range)
9473 (aarch64_linux_can_do_single_step): Refactor as methods of
9474 aarch64_linux_nat_target.
9475 (super_post_startup_inferior): Delete.
9476 (_initialize_aarch64_linux_nat): Adjust to C++ification.
9477
9478 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
9479 (the_hppa_linux_nat_target): New.
9480 (hppa_linux_fetch_inferior_registers)
9481 (hppa_linux_store_inferior_registers): Refactor as methods of
9482 hppa_linux_nat_target.
9483 (_initialize_hppa_linux_nat): Adjust to C++ification.
9484
9485 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
9486 (the_ia64_linux_nat_target): New.
9487 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
9488 (ia64_linux_stopped_data_address)
9489 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
9490 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
9491 ia64_linux_nat_target methods.
9492 (super_xfer_partial): Delete.
9493 (_initialize_ia64_linux_nat): Adjust to C++ification.
9494
9495 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
9496 (the_m32r_linux_nat_target): New.
9497 (m32r_linux_fetch_inferior_registers)
9498 (m32r_linux_store_inferior_registers): Refactor as
9499 m32r_linux_nat_target methods.
9500 (_initialize_m32r_linux_nat): Adjust to C++ification.
9501
9502 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
9503 (the_m68k_linux_nat_target): New.
9504 (m68k_linux_fetch_inferior_registers)
9505 (m68k_linux_store_inferior_registers): Refactor as
9506 m68k_linux_nat_target methods.
9507 (_initialize_m68k_linux_nat): Adjust to C++ification.
9508
9509 * s390-linux-nat.c (s390_linux_nat_target): New class.
9510 (the_s390_linux_nat_target): New.
9511 (s390_linux_fetch_inferior_registers)
9512 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
9513 (s390_insert_watchpoint, s390_remove_watchpoint)
9514 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
9515 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
9516 (s390_auxv_parse, s390_read_description): Refactor as methods of
9517 s390_linux_nat_target.
9518 (_initialize_s390_nat): Adjust to C++ification.
9519
9520 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
9521 (the_sparc_linux_nat_target): New.
9522 (_initialize_sparc_linux_nat): Adjust to C++ification.
9523 * sparc-nat.c (sparc_fetch_inferior_registers)
9524 (sparc_store_inferior_registers): Remove target_ops parameter.
9525 * sparc-nat.h (sparc_fetch_inferior_registers)
9526 (sparc_store_inferior_registers): Remove target_ops parameter.
9527 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
9528 (the_sparc64_linux_nat_target): New.
9529 (_initialize_sparc64_linux_nat): Adjust to C++ification.
9530
9531 * spu-linux-nat.c (spu_linux_nat_target): New class.
9532 (the_spu_linux_nat_target): New.
9533 (spu_child_post_startup_inferior, spu_child_post_attach)
9534 (spu_child_wait, spu_fetch_inferior_registers)
9535 (spu_store_inferior_registers, spu_xfer_partial)
9536 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
9537 methods.
9538 (_initialize_spu_nat): Adjust to C++ification.
9539
9540 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
9541 (the_tilegx_linux_nat_target): New.
9542 (fetch_inferior_registers, store_inferior_registers):
9543 Refactor as methods.
9544 (_initialize_tile_linux_nat): Adjust to C++ification.
9545
9546 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
9547 (the_xtensa_linux_nat_target): New.
9548 (xtensa_linux_fetch_inferior_registers)
9549 (xtensa_linux_store_inferior_registers): Refactor as
9550 xtensa_linux_nat_target methods.
9551 (_initialize_xtensa_linux_nat): Adjust to C++ification.
9552
9553 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
9554 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
9555 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
9556 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
9557 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
9558 (fbsd_stopped_by_sw_breakpoint)
9559 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
9560 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
9561 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
9562 (fbsd_post_startup_inferior, fbsd_post_attach)
9563 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
9564 (fbsd_set_syscall_catchpoint)
9565 (super_xfer_partial, super_resume, super_wait)
9566 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
9567 (fbsd_handle_debug_trap): Remove target_ops parameter.
9568 (fbsd_nat_add_target): Delete.
9569 * fbsd-nat.h: Include "inf-ptrace.h".
9570 (fbsd_nat_add_target): Delete.
9571 (USE_SIGTRAP_SIGINFO): Define.
9572 (fbsd_nat_target): New class.
9573
9574 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
9575 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
9576 (amd64bsd_target): Delete.
9577 * amd64-bsd-nat.h: New file.
9578 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
9579 "x86-bsd-nat.h".
9580 (amd64_fbsd_nat_target): New class.
9581 (the_amd64_fbsd_nat_target): New.
9582 (amd64fbsd_read_description): Refactor as method of
9583 amd64_fbsd_nat_target.
9584 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9585 (_initialize_amd64fbsd_nat): Adjust to C++ification.
9586 * amd64-nat.h (amd64bsd_target): Delete function declaration.
9587 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
9588 (i386bsd_store_inferior_registers): Remove target_ops parameter.
9589 (i386bsd_target): Delete.
9590 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
9591 (i386bsd_fetch_inferior_registers)
9592 (i386bsd_store_inferior_registers): Declare.
9593 (i386_bsd_nat_target): New class.
9594 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
9595 (the_i386_fbsd_nat_target): New.
9596 (i386fbsd_resume, i386fbsd_read_description): Refactor as
9597 i386_fbsd_nat_target methods.
9598 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9599 (_initialize_i386fbsd_nat): Adjust to C++ification.
9600 * x86-bsd-nat.c (super_mourn_inferior): Delete.
9601 (x86bsd_mourn_inferior, x86bsd_target): Delete.
9602 (_initialize_x86_bsd_nat): Adjust to C++ification.
9603 * x86-bsd-nat.h: Include "x86-nat.h".
9604 (x86bsd_target): Delete declaration.
9605 (x86bsd_nat_target): New class.
9606
9607 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
9608 (the_aarch64_fbsd_nat_target): New.
9609 (aarch64_fbsd_fetch_inferior_registers)
9610 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
9611 aarch64_fbsd_nat_target.
9612 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
9613 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
9614 (the_alpha_bsd_nat_target): New.
9615 (alphabsd_fetch_inferior_registers)
9616 (alphabsd_store_inferior_registers): Refactor as
9617 alpha_bsd_nat_target methods.
9618 (_initialize_alphabsd_nat): Refactor as methods of
9619 alpha_bsd_nat_target.
9620 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
9621 (the_amd64_nbsd_nat_target): New.
9622 (_initialize_amd64nbsd_nat): Adjust to C++ification.
9623 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
9624 (the_amd64_obsd_nat_target): New.
9625 (_initialize_amd64obsd_nat): Adjust to C++ification.
9626 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
9627 (the_arm_fbsd_nat_target): New.
9628 (arm_fbsd_fetch_inferior_registers)
9629 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
9630 (_initialize_arm_fbsd_nat): Refactor as methods of
9631 arm_fbsd_nat_target.
9632 (_initialize_arm_fbsd_nat): Adjust to C++ification.
9633 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
9634 (the_arm_netbsd_nat_target): New.
9635 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
9636 arm_netbsd_nat_target.
9637 (_initialize_arm_netbsd_nat): Adjust to C++ification.
9638 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
9639 (the_hppa_nbsd_nat_target): New.
9640 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
9641 hppa_nbsd_nat_target methods.
9642 (_initialize_hppanbsd_nat): Adjust to C++ification.
9643 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
9644 (the_hppa_obsd_nat_target): New.
9645 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
9646 methods of hppa_obsd_nat_target.
9647 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
9648 add_target.
9649 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
9650 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
9651 add_target.
9652 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
9653 (_initialize_i386obsd_nat): Use add_target.
9654 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
9655 (the_m68k_bsd_nat_target): New.
9656 (m68kbsd_fetch_inferior_registers)
9657 (m68kbsd_store_inferior_registers): Refactor as methods of
9658 m68k_bsd_nat_target.
9659 (_initialize_m68kbsd_nat): Adjust to C++ification.
9660 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
9661 (the_mips_fbsd_nat_target): New.
9662 (mips_fbsd_fetch_inferior_registers)
9663 (mips_fbsd_store_inferior_registers): Refactor as methods of
9664 mips_fbsd_nat_target.
9665 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
9666 add_target.
9667 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
9668 (the_mips_nbsd_nat_target): New.
9669 (mipsnbsd_fetch_inferior_registers)
9670 (mipsnbsd_store_inferior_registers): Refactor as methods of
9671 mips_nbsd_nat_target.
9672 (_initialize_mipsnbsd_nat): Adjust to C++ification.
9673 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
9674 (the_mips64_obsd_nat_target): New.
9675 (mips64obsd_fetch_inferior_registers)
9676 (mips64obsd_store_inferior_registers): Refactor as methods of
9677 mips64_obsd_nat_target.
9678 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
9679 add_target.
9680 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
9681 nbsd_nat_target.
9682 * nbsd-nat.h: Include "inf-ptrace.h".
9683 (nbsd_nat_target): New class.
9684 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
9685 (obsd_wait): Refactor as methods of obsd_nat_target.
9686 (obsd_add_target): Delete.
9687 * obsd-nat.h: Include "inf-ptrace.h".
9688 (obsd_nat_target): New class.
9689 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
9690 (the_ppc_fbsd_nat_target): New.
9691 (ppcfbsd_fetch_inferior_registers)
9692 (ppcfbsd_store_inferior_registers): Refactor as methods of
9693 ppc_fbsd_nat_target.
9694 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
9695 add_target.
9696 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
9697 (the_ppc_nbsd_nat_target): New.
9698 (ppcnbsd_fetch_inferior_registers)
9699 (ppcnbsd_store_inferior_registers): Refactor as methods of
9700 ppc_nbsd_nat_target.
9701 (_initialize_ppcnbsd_nat): Adjust to C++ification.
9702 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
9703 (the_ppc_obsd_nat_target): New.
9704 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
9705 methods of ppc_obsd_nat_target.
9706 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
9707 add_target.
9708 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
9709 (the_sh_nbsd_nat_target): New.
9710 (shnbsd_fetch_inferior_registers)
9711 (shnbsd_store_inferior_registers): Refactor as methods of
9712 sh_nbsd_nat_target.
9713 (_initialize_shnbsd_nat): Adjust to C++ification.
9714 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
9715 (inf_ptrace_xfer_partial): Delete.
9716 (sparc_xfer_partial, sparc_target): Delete.
9717 * sparc-nat.h (sparc_fetch_inferior_registers)
9718 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
9719 (sparc_target): Delete function declaration.
9720 (sparc_target): New template class.
9721 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
9722 (_initialize_sparcnbsd_nat): Adjust to C++ification.
9723 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
9724 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
9725 add_target.
9726 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
9727 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
9728 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
9729 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
9730 add_target.
9731 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
9732 (the_vax_bsd_nat_target): New.
9733 (vaxbsd_fetch_inferior_registers)
9734 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
9735 methods.
9736 (_initialize_vaxbsd_nat): Adjust to C++ification.
9737
9738 * bsd-kvm.c (bsd_kvm_target): New class.
9739 (bsd_kvm_ops): Now a bsd_kvm_target.
9740 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
9741 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
9742 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
9743 bsd_kvm_target.
9744 (bsd_kvm_return_one): Delete.
9745 (bsd_kvm_add_target): Adjust to C++ification.
9746
9747 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
9748 (nto_procfs_target_procfs): New classes.
9749 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
9750 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
9751 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
9752 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
9753 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
9754 (procfs_remove_hw_breakpoint, procfs_resume)
9755 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
9756 (procfs_kill_inferior, procfs_store_registers)
9757 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
9758 as methods of nto_procfs_target.
9759 (nto_procfs_ops): Now an nto_procfs_target_procfs.
9760 (nto_native_ops): Delete.
9761 (procfs_open, procfs_native_open): Delete.
9762 (nto_native_ops): Now an nto_procfs_target_native.
9763 (init_procfs_targets): Adjust to C++ification.
9764 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
9765 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
9766 Refactor as methods of nto_procfs_target.
9767
9768 * go32-nat.c (go32_nat_target): New class.
9769 (the_go32_nat_target): New.
9770 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
9771 (go32_store_registers, go32_xfer_partial, go32_files_info)
9772 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
9773 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
9774 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
9775 (go32_pid_to_str): Refactor as methods of go32_nat_target.
9776 (go32_target): Delete.
9777 (_initialize_go32_nat): Adjust to C++ification.
9778
9779 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
9780 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
9781 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
9782 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
9783 gnu_nat_target.
9784 (gnu_target): Delete.
9785 * gnu-nat.h (gnu_target): Delete.
9786 (gnu_nat_target): New class.
9787 * i386-gnu-nat.c (gnu_base_target): New.
9788 (i386_gnu_nat_target): New class.
9789 (the_i386_gnu_nat_target): New.
9790 (_initialize_i386gnu_nat): Adjust to C++ification.
9791
9792 2018-05-02 Pedro Alves <palves@redhat.com>
9793
9794 * bfd-target.c (target_bfd_xclose): Rename to ...
9795 (target_bfd_close): ... this.
9796 (target_bfd_reopen): Adjust.
9797 * target.c (target_close): Remove references to to_xclose.
9798 * target.h (target_ops::to_xclose): Delete.
9799 (target_ops::to_close): Update comments.
9800
9801 2018-05-02 Pedro Alves <palves@redhat.com>
9802
9803 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
9804 "linux-nat.h".
9805 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
9806 * inf-ptrace.c (inf_ptrace_register_u_offset)
9807 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9808 (inf_ptrace_store_register, inf_ptrace_store_registers)
9809 (inf_ptrace_trad_target): Move to ...
9810 * linux-nat-trad.c: ... this new file.
9811 * linux-nat-trad.h: New file.
9812 * linux-nat.c (linux_target_install_ops): Make extern.
9813 (linux_trad_target): Delete.
9814 * linux-nat.h (linux_trad_target): Delete declaration.
9815 (linux_target_install_ops): Declare.
9816 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
9817 "linux-nat.h".
9818
9819 2018-05-02 Pedro Alves <palves@redhat.com>
9820
9821 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9822 procfs_target/add_target here.
9823 * procfs.c (procfs_target): Make static.
9824 (_initialize_procfs): Call add_target here.
9825 * procfs.h (struct target_ops): Remove forward declaration.
9826 (procfs_target): Remove declaration.
9827 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
9828
9829 2018-05-02 Pedro Alves <palves@redhat.com>
9830
9831 * procfs.c (procfs_stopped_by_watchpoint)
9832 (procfs_insert_watchpoint, procfs_remove_watchpoint)
9833 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
9834 Forward declare.
9835 (procfs_use_watchpoints): Delete, move contents...
9836 (procfs_target): ... here.
9837 * procfs.h (procfs_use_watchpoints): Delete declaration.
9838 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9839 procfs_use_watchpoints.
9840 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
9841 procfs_use_watchpoints.
9842
9843 2018-05-02 Tom Tromey <tom@tromey.com>
9844
9845 PR python/20084:
9846 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
9847 and var_zuinteger_unlimited.
9848 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
9849 and PARAM_ZUINTEGER_UNLIMITED.
9850 (set_parameter_value): Handle var_zuinteger and
9851 var_zuinteger_unlimited.
9852 (add_setshow_generic): Likewise.
9853 (parmpy_init): Likewise.
9854
9855 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
9856
9857 PR rust/23124
9858 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
9859 pointer is not null before dereferencing it.
9860
9861 2018-04-30 Tom Tromey <tom@tromey.com>
9862
9863 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
9864 is_mi_like_p.
9865
9866 2018-04-30 Tom Tromey <tom@tromey.com>
9867
9868 * breakpoint.c (mention): Remove use of is_mi_like_p.
9869 (print_mention_ranged_breakpoint): Likewise.
9870 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
9871 of is_mi_like_p.
9872
9873 2018-04-30 Tom Tromey <tom@tromey.com>
9874
9875 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
9876
9877 2018-04-30 Tom Tromey <tom@tromey.com>
9878
9879 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
9880 (info_spu_event_command): Remove some uses of is_mi_like_p.
9881
9882 2018-04-30 Tom Tromey <tom@tromey.com>
9883
9884 * python/py-framefilter.c (py_print_single_arg)
9885 (enumerate_locals, py_print_args, py_print_frame): Remove some
9886 uses of is_mi_like_p.
9887
9888 2018-04-30 Tom Tromey <tom@tromey.com>
9889
9890 * ui-out.c: Update.
9891 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
9892 * ui-out.h (ui_out::is_mi_like_p): Now const.
9893 (ui_out::do_is_mi_like_p): Now const.
9894 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
9895
9896 2018-04-30 Tom Tromey <tom@tromey.com>
9897
9898 * varobj.c (varobj_set_visualizer): Use new_reference.
9899 * python/python.c (gdbpy_decode_line): Use new_reference.
9900 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
9901 new_reference.
9902
9903 2018-04-30 Tom Tromey <tom@tromey.com>
9904
9905 * varobj.c (install_new_value): Use new_reference.
9906 * value.h (value_incref): Return void. Swap intro comment with
9907 value_decref.
9908 * value.c (set_value_parent): Use new_reference.
9909 (value_incref): Return void. Update intro comment.
9910 (release_value): Use new_reference.
9911 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
9912
9913 2018-04-30 Tom Tromey <tom@tromey.com>
9914
9915 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
9916 * gdb_bfd.h (new_bfd_ref): Remove.
9917 (gdb_bfd_open): Update comment.
9918 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
9919 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
9920 (gdb_bfd_fdopenr): Use new_reference.
9921 * exec.c (exec_file_attach): Use new_reference.
9922
9923 2018-04-30 Tom Tromey <tom@tromey.com>
9924
9925 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
9926 method.
9927
9928 2018-04-30 Tom Tromey <tom@tromey.com>
9929
9930 * jit.c (jit_read_code_entry): Use type_align.
9931 * i386-tdep.c (i386_gdbarch_init): Don't call
9932 set_gdbarch_long_long_align_bit.
9933 * gdbarch.sh: Remove long_long_align_bit.
9934 * gdbarch.c, gdbarch.h: Rebuild.
9935 * arc-tdep.c (arc_type_align): New function.
9936 (arc_gdbarch_init): Use arc_type_align. Don't call
9937 set_gdbarch_long_long_align_bit.
9938
9939 2018-04-30 Tom Tromey <tom@tromey.com>
9940
9941 * rust-lang.c (rust_type_alignment): Remove.
9942 (rust_composite_type): Use type_align.
9943
9944 2018-04-30 Tom Tromey <tom@tromey.com>
9945
9946 * NEWS: Mention Type.align.
9947 * python/py-type.c (typy_get_alignof): New function.
9948 (type_object_getset): Add "alignof".
9949
9950 2018-04-30 Tom Tromey <tom@tromey.com>
9951
9952 PR exp/17095:
9953 * NEWS: Update.
9954 * std-operator.def (UNOP_ALIGNOF): New operator.
9955 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
9956 New.
9957 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
9958 * c-lang.c (c_op_print_tab): Add alignof.
9959 * c-exp.y (ALIGNOF): New token.
9960 (exp): Add "ALIGNOF" production.
9961 (ident_tokens): Add _Alignof and alignof.
9962
9963 2018-04-30 Tom Tromey <tom@tromey.com>
9964
9965 * i386-tdep.c (i386_type_align): New function.
9966 (i386_gdbarch_init): Update.
9967 * gdbarch.sh (type_align): New method.
9968 * gdbarch.c, gdbarch.h: Rebuild.
9969 * arch-utils.h (default_type_align): Declare.
9970 * arch-utils.c (default_type_align): New function.
9971 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9972 (struct type) <align_log2>: New field.
9973 <instance_flags>: Now a bitfield.
9974 (TYPE_RAW_ALIGN): New macro.
9975 (type_align, type_raw_align, set_type_align): Declare.
9976 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9977 functions.
9978 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9979 (get_alignment, maybe_set_alignment): New functions.
9980 (read_structure_type, read_enumeration_type, read_array_type)
9981 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9982 (read_subrange_type, read_base_type): Set type alignment.
9983
9984 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9985
9986 * dwarf2read.c (read_index_from_section): Use bool.
9987
9988 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9989
9990 PR gdb/22950
9991 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9992 with #ifdef.
9993
9994 2018-04-29 John Reiser <jreiser@BitWagon.com>
9995
9996 PR build/22873
9997 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9998 last step, and do it atomically.
9999
10000 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
10001
10002 * compile/compile-c-types.c (convert_int, convert_float):
10003 Update for C FE v1.
10004
10005 2018-04-27 Tom Tromey <tom@tromey.com>
10006
10007 PR rust/22545:
10008 * rust-lang.c (rust_inclusive_range_type_p): New function.
10009 (rust_range): Handle inclusive ranges.
10010 (rust_compute_range): Likewise.
10011 * rust-exp.y (struct rust_op) <inclusive>: New field.
10012 (DOTDOTEQ): New constant.
10013 (range_expr): Add "..=" productions.
10014 (operator_tokens): Add "..=" token.
10015 (ast_range): Add "inclusive" parameter.
10016 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
10017 ranges.
10018 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
10019 bounds values.
10020 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
10021 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
10022 Update comments.
10023 * expprint.c (print_subexp_standard): Handle new bounds values.
10024 (dump_subexp_body_standard): Likewise.
10025
10026 2018-04-27 Tom Tromey <tom@tromey.com>
10027
10028 * configure: Rebuild.
10029 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
10030 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
10031 "OVERRIDE".
10032 (class symbol_needs_eval_context): Likewise.
10033 * dwarf2read.c (mock_mapped_index::symbol_name_count)
10034 (mock_mapped_index::symbol_name_at): Use "override". Remove
10035 "virtual".
10036 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
10037 "override".
10038 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
10039 * aarch64-tdep.c (instruction_reader::read): Use "override".
10040 (instruction_reader_test::read): Likewise.
10041 * arm-tdep.c (instruction_reader::read): Use "override".
10042 (instruction_reader_thumb::read): Likewise.
10043
10044 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
10045
10046 PR remote/9665
10047 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
10048 instead of remote_send.
10049 (remote_send): Remove.
10050
10051 2018-04-26 Pedro Alves <palves@redhat.com>
10052
10053 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
10054 find_function_start_sal instead of find_pc_line.
10055
10056 2018-04-26 Pedro Alves <palves@redhat.com>
10057
10058 * breakpoint.c (set_breakpoint_location_function): Handle
10059 mst_data_gnu_ifunc.
10060 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
10061 * elfread.c (elf_symtab_read): Give data symbols with
10062 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
10063 (elf_rel_plt_read): Update comment.
10064 * linespec.c (convert_linespec_to_sals): Handle
10065 mst_data_gnu_ifunc.
10066 (minsym_found): Handle mst_data_gnu_ifunc.
10067 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
10068 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
10069 * parse.c (find_minsym_type_and_address): Handle
10070 mst_data_gnu_ifunc.
10071 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
10072 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
10073 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
10074 comment.
10075 <mst_data_gnu_ifunc>: New enumerator.
10076
10077 2018-04-26 Pedro Alves <palves@redhat.com>
10078
10079 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
10080 (lookup_minimal_symbol_by_pc_section): ... this. Replace
10081 'want_trampoline' parameter by a lookup_msym_prefer parameter.
10082 Handle it.
10083 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
10084 (lookup_minimal_symbol_by_pc): Adjust.
10085 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
10086 (lookup_solib_trampoline_symbol_by_pc): Adjust.
10087 * minsyms.h (lookup_msym_prefer): New enum.
10088 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10089 parameter by a lookup_msym_prefer parameter.
10090
10091 2018-04-26 Pedro Alves <palves@redhat.com>
10092
10093 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
10094 ends in "@plt" instead of looking at the symbol's section.
10095
10096 2018-04-26 Pedro Alves <palves@redhat.com>
10097
10098 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
10099 all references.
10100 (find_pc_partial_function_gnu_ifunc): Rename to ...
10101 (find_pc_partial_function): ... this, and remove references to
10102 'is_gnu_ifunc_p'.
10103 (find_pc_partial_function): Delete old implementation.
10104 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
10105
10106 2018-04-26 Pedro Alves <palves@redhat.com>
10107
10108 * linespec.c (struct bound_minimal_symbol_search_key): New.
10109 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
10110 skip first line if we found a GNU ifunc minimal symbol by name.
10111 (compare_msymbols): Change parameters to work with a destructured
10112 lhs minsym.
10113 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
10114 functions.
10115
10116 2018-04-26 Pedro Alves <palves@redhat.com>
10117
10118 * breakpoint.c (set_breakpoint_location_function): Don't resolve
10119 ifunc targets here. Instead, if we have an ifunc minsym, use its
10120 address/name.
10121 (add_location_to_breakpoint): Store the minsym and the objfile in
10122 the breakpoint location.
10123 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
10124 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
10125 Record the minsym in the sal.
10126 * symtab.h (symtab_and_line) <msymbol>: New field.
10127
10128 2018-04-26 Pedro Alves <palves@redhat.com>
10129
10130 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
10131 unless we actually resolved the ifunc.
10132
10133 2018-04-26 Pedro Alves <palves@redhat.com>
10134
10135 * c-exp.y (variable production): Prefer ifunc minsyms over
10136 regular function symbols.
10137 * symtab.c (find_gnu_ifunc): New function.
10138 * minsyms.h (lookup_msym_prefer): New enum.
10139 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10140 parameter by a lookup_msym_prefer parameter.
10141 * symtab.h (find_gnu_ifunc): New declaration.
10142
10143 2018-04-26 Pedro Alves <palves@redhat.com>
10144
10145 * blockframe.c (find_gnu_ifunc_target_type): New function.
10146 (find_function_type): New.
10147 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
10148 return a value with a memory address.
10149 (eval_call): For calls to GNU ifunc functions, try to find the
10150 type of the target function from the type that the resolver
10151 returns.
10152 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
10153 symbols.
10154 * infcall.c (find_function_return_type): Delete.
10155 (find_function_addr): Add 'function_type' parameter. For calls to
10156 GNU ifunc functions, try to find the type of the target function
10157 from the type that the resolver returns, and return it via
10158 FUNCTION_TYPE.
10159 (call_function_by_hand_dummy): Adjust to use the function type
10160 returned by find_function_addr.
10161 (find_function_addr): Add 'function_type' parameter and move
10162 description here.
10163 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
10164 declarations.
10165
10166 2018-04-26 Pedro Alves <palves@redhat.com>
10167
10168 * c-exp.y (variable production): Skip finding an alias for ifunc
10169 symbols.
10170
10171 2018-04-26 Pedro Alves <palves@redhat.com>
10172
10173 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
10174
10175 2018-04-25 Pedro Alves <palves@redhat.com>
10176
10177 * infcmd.c (kill_command): Print the pid as string, not the whole
10178 thread's ptid. Add comment. s/has been killed/killed/ in output
10179 message.
10180 * remote.c (remote_detach_1): Print the pid as string, not the
10181 whole thread's ptid.
10182
10183 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
10184 Sergio Durigan Junior <sergiodj@redhat.com>
10185 Pedro Alves <palves@redhat.com>
10186
10187 * infcmd.c (kill_command): Print message when inferior has
10188 been killed.
10189 * inferior.c (print_inferior_events): Remove 'static'. Set as
10190 '1'.
10191 (add_inferior): Improve message printed when
10192 'print_inferior_events' is on.
10193 (exit_inferior): Remove message printed when
10194 'print_inferior_events' is on.
10195 (detach_inferior): Improve message printed when
10196 'print_inferior_events' is on.
10197 (initialize_inferiors): Use 'add_inferior_silent' to set
10198 'current_inferior_'.
10199 * inferior.h (print_inferior_events): Declare here as
10200 'extern'.
10201 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
10202 '[Detaching...]' messages when 'print_inferior_events' is on.
10203 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
10204 as prefix/suffix for messages. Remove periods. Fix erroneous
10205 'Detaching after fork from child...', replace it by '... from
10206 parent...'.
10207 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
10208 prefix/suffix when printing 'Detaching...' messages. Print
10209 them when 'print_inferior_events' is on.
10210 * remote.c (remote_detach_1): Print message when detaching
10211 from inferior and '!is_fork_parent'.
10212
10213 2018-04-24 Tom Tromey <tom@tromey.com>
10214
10215 * cli-out.h: Reindent.
10216
10217 2018-04-24 Tom Tromey <tom@tromey.com>
10218
10219 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
10220 (cli_ui_out::do_field_string): Use fputs_filtered.
10221 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
10222
10223 2018-04-23 Tom Tromey <tom@tromey.com>
10224
10225 * guile/scm-frame.c (gdbscm_frame_read_var): Use
10226 gdb::unique_xmalloc_ptr.
10227
10228 2018-04-23 Tom Tromey <tom@tromey.com>
10229
10230 * configure: Rebuild.
10231
10232 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
10233
10234 PR gdb/23095
10235 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
10236 prepare_for_testing. Set normal_bp to r_debug_state if target
10237 is bsd.
10238
10239 2018-04-21 Pedro Alves <palves@redhat.com>
10240 Rajendra SY <rajendra.sy@gmail.com>
10241
10242 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
10243 * remote.c (extended_remote_attach): In all-stop mode, mark the
10244 thread as executing.
10245
10246 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10247
10248 * thread.c (thread_apply_all_command): Fix comment.
10249 (thread_command): Fix comment.
10250
10251 2018-04-10 Alan Hayward <alan.hayward@arm.com>
10252
10253 * common/tdesc.h (tdesc_create_feature): Remove xml filename
10254 parameter.
10255 * features/aarch64-core.c (create_feature_aarch64_core):
10256 Regenerate.
10257 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
10258 Likewise.
10259 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
10260 Likewise.
10261 * features/i386/32bit-avx512.c
10262 (create_feature_i386_32bit_avx512): Likewise.
10263 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
10264 Likewise.
10265 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
10266 Likewise.
10267 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
10268 Likewise.
10269 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
10270 Likewise.
10271 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
10272 Likewise.
10273 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
10274 Likewise.
10275 * features/i386/64bit-avx512.c
10276 (create_feature_i386_64bit_avx512): Likewise.
10277 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
10278 Likewise.
10279 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
10280 Likewise.
10281 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
10282 Likewise.
10283 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
10284 Likewise.
10285 * features/i386/64bit-segments.c
10286 (create_feature_i386_64bit_segments): Likewise.
10287 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
10288 Likewise.
10289 * features/i386/x32-core.c
10290 (create_feature_i386_x32_core): Likewise.
10291 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
10292 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
10293 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
10294 * target-descriptions.c: In generated code, don't pass xml
10295 filename.
10296
10297 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10298
10299 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
10300 (print_xml_feature::visit_post): Likewise.
10301 (print_xml_feature::visit): Likewise.
10302 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
10303 (print_xml_feature): Add new class.
10304 * regformats/regdat.sh: Null xmltarget on feature targets.
10305 * target-descriptions.c (struct target_desc): Add xmltarget.
10306 (maintenance_check_tdesc_xml_convert): Add unittest function.
10307 (tdesc_get_features_xml): Add function to get xml.
10308 (maintenance_check_xml_descriptions): Test xml generation.
10309 * xml-tdesc.c (string_read_description_xml): Add function.
10310 * xml-tdesc.h (string_read_description_xml): Add declaration.
10311
10312 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10313
10314 * features/Makefile: Add feature marker to targets with new style
10315 target descriptions.
10316 * regformats/aarch64.dat: Regenerate.
10317 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
10318 * regformats/i386/amd64-avx-linux.dat: Likewise.
10319 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
10320 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
10321 * regformats/i386/amd64-linux.dat: Likewise.
10322 * regformats/i386/amd64-mpx-linux.dat: Likewise.
10323 * regformats/i386/amd64.dat: Likewise.
10324 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
10325 * regformats/i386/i386-avx-linux.dat: Likewise.
10326 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
10327 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
10328 * regformats/i386/i386-linux.dat: Likewise.
10329 * regformats/i386/i386-mmx-linux.dat: Likewise.
10330 * regformats/i386/i386-mpx-linux.dat: Likewise.
10331 * regformats/i386/i386.dat: Likewise.
10332 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
10333 * regformats/i386/x32-avx-linux.dat: Likewise.
10334 * regformats/i386/x32-linux.dat: Likewise.
10335 * regformats/tic6x-c62x-linux.dat: Likewise.
10336 * regformats/tic6x-c64x-linux.dat: Likewise.
10337 * regformats/tic6x-c64xp-linux.dat: Likewise.
10338 * regformats/regdat.sh: Parse feature marker.
10339
10340 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10341
10342 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
10343 (tdesc_osabi_name): Likewise.
10344 * target-descriptions.c (tdesc_architecture_name): Add new
10345 function.
10346 (tdesc_osabi_name): Likewise.
10347
10348 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10349
10350 * common/tdesc.c (tdesc_predefined_type): Move to here.
10351 (tdesc_named_type): Likewise.
10352 (tdesc_create_vector): Likewise.
10353 (tdesc_create_struct): Likewise.
10354 (tdesc_set_struct_size): Likewise.
10355 (tdesc_create_union): Likewise.
10356 (tdesc_create_flags): Likewise.
10357 (tdesc_create_enum): Likewise.
10358 (tdesc_add_field): Likewise.
10359 (tdesc_add_typed_bitfield): Likewise.
10360 (tdesc_add_bitfield): Likewise.
10361 (tdesc_add_flag): Likewise.
10362 (tdesc_add_enum_value): Likewise.
10363 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
10364 (struct tdesc_type_vector): Likewise.
10365 (struct tdesc_type_field): Likewise.
10366 (struct tdesc_type_with_fields): Likewise.
10367 (tdesc_create_enum): Add declaration.
10368 (tdesc_add_typed_bitfield): Likewise.
10369 (tdesc_add_enum_value): Likewise.
10370 * target-descriptions.c (tdesc_type_field): Move from here.
10371 (tdesc_type_builtin): Likewise.
10372 (tdesc_type_vector): Likewise.
10373 (tdesc_type_with_fields): Likewise.
10374 (tdesc_predefined_types): Likewise.
10375 (tdesc_named_type): Likewise.
10376 (tdesc_create_vector): Likewise.
10377 (tdesc_create_struct): Likewise.
10378 (tdesc_set_struct_size): Likewise.
10379 (tdesc_create_union): Likewise.
10380 (tdesc_create_flags): Likewise.
10381 (tdesc_create_enum): Likewise.
10382 (tdesc_add_field): Likewise.
10383 (tdesc_add_typed_bitfield): Likewise.
10384 (tdesc_add_bitfield): Likewise.
10385 (tdesc_add_flag): Likewise.
10386 (tdesc_add_enum_value): Likewise.
10387 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
10388 (tdesc_add_typed_bitfield): Likewise.
10389 (tdesc_add_enum_value): Likewise.
10390
10391 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10392
10393 * common/tdesc.c (tdesc_feature::accept): Move to here.
10394 (tdesc_feature::operator==): Likewise.
10395 (tdesc_create_reg): Likewise.
10396 * common/tdesc.h (tdesc_type_kind): Likewise.
10397 (struct tdesc_type): Likewise.
10398 (struct tdesc_feature): Likewise.
10399 * regformats/regdat.sh: Create a feature.
10400 * target-descriptions.c (tdesc_type_kind): Move from here.
10401 (tdesc_type): Likewise.
10402 (tdesc_type_up): Likewise.
10403 (tdesc_feature): Likewise.
10404 (tdesc_create_reg): Likewise.
10405
10406 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10407
10408 * Makefile.in: Add arch/tdesc.c
10409 * common/tdesc.c: New file.
10410 * common/tdesc.h (tdesc_element_visitor): Move to here.
10411 (tdesc_element): Likewise.
10412 (tdesc_reg): Likewise.
10413 (tdesc_reg_up): Likewise.
10414 * regformats/regdef.h (reg): Add offset to constructors.
10415 * target-descriptions.c (tdesc_element_visitor): Move from here.
10416 (tdesc_element): Likewise.
10417 (tdesc_reg): Likewise.
10418 (tdesc_reg_up): Likewise.
10419
10420 2018-04-17 Tom Tromey <tom@tromey.com>
10421
10422 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
10423 discriminant field.
10424
10425 2018-04-17 Tom Tromey <tom@tromey.com>
10426
10427 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
10428
10429 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
10430
10431 * symtab.c (print_symbol_info): Skip printing filename and line
10432 number when `last' is NULL.
10433 (symtab_symbol_info): Use empty string instead of NULL for first
10434 invocation of print_symbol_info.
10435 (rbreak_command): Pass NULL to `last' parameter of
10436 print_symbol_info.
10437
10438 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
10439
10440 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
10441 instead of nullptr.
10442
10443 2018-04-16 Pedro Alves <palves@redhat.com>
10444
10445 * MAINTAINERS (sh): Remove.
10446 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
10447 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
10448 (ALLDEPFILES): Remove sh64-tdep.c.
10449 * NEWS: Mentions that support for SH-5/SH64 is removed.
10450 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
10451 (sh*-*-openbsd*): Ditto.
10452 (sh64-*-elf*): Remove.
10453 (sh*): Remove.
10454 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
10455 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
10456 * sh-tdep.c: No longer include "sh64-tdep.h".
10457 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
10458 * sh64-tdep.c, sh64-tdep.h: Remove files.
10459
10460 2018-04-16 Pedro Alves <palves@redhat.com>
10461
10462 * MAINTAINERS: Remove m88k.
10463 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
10464 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
10465 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
10466 * NEWS: Mention that support for m88k was removed.
10467 * configure.host (m88*-*-*): Remove support.
10468 * configure.nat (m88k-*-*): Remove support.
10469 * configure.tgt (m88*-*-openbsd*): Remove.
10470 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
10471
10472 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
10473
10474 * configure.tgt (x86_tobjs): New variable.
10475 (amd64_tobjs, i386_tobjs): Use it.
10476
10477 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10478
10479 * symtab.c (print_symbol_info): Precede the symbol definition by
10480 the line number when available.
10481 * NEWS: Advertise this enhancement.
10482
10483 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10484
10485 * NEWS (New options): announce set/show record btrace cpu.
10486 * btrace.c: Include record-btrace.h.
10487 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
10488 the vendor is unknown.
10489 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
10490 Maybe overwrite the btrace configuration's cpu.
10491 (btrace_compute_ftrace): Add cpu parameter. Update callers.
10492 (btrace_fetch): Add cpu parameter. Update callers.
10493 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
10494 Maybe overwrite the btrace configuration's cpu. Skip enabling
10495 errata workarounds if the vendor is unknown.
10496 * python/py-record-btrace.c: Include record-btrace.h.
10497 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
10498 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
10499 * record-btrace.c (record_btrace_cpu_state_kind): New.
10500 (record_btrace_cpu): New.
10501 (set_record_btrace_cpu_cmdlist): New.
10502 (record_btrace_get_cpu): New.
10503 (require_btrace_thread, record_btrace_info)
10504 (record_btrace_resume_thread): Call record_btrace_get_cpu.
10505 (cmd_set_record_btrace_cpu_none): New.
10506 (cmd_set_record_btrace_cpu_auto): New.
10507 (cmd_set_record_btrace_cpu): New.
10508 (cmd_show_record_btrace_cpu): New.
10509 (_initialize_record_btrace): Initialize set/show record btrace cpu
10510 commands.
10511 * record-btrace.h (record_btrace_get_cpu): New.
10512
10513 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10514
10515 * record.c (set_record_command): Fix typo in message.
10516
10517 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10518
10519 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
10520
10521 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10522
10523 * infrun.c (process_event_stop_test): Call
10524 gdbarch_in_indirect_branch_thunk.
10525 * gdbarch.sh (in_indirect_branch_thunk): New.
10526 * gdbarch.c: Regenerated.
10527 * gdbarch.h: Regenerated.
10528 * x86-tdep.h: New.
10529 * x86-tdep.c: New.
10530 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
10531 (HFILES_NO_SRCDIR): Add x86-tdep.h.
10532 (ALLDEPFILES): Add x86-tdep.c.
10533 * arch-utils.h (default_in_indirect_branch_thunk): New.
10534 * arch-utils.c (default_in_indirect_branch_thunk): New.
10535 * i386-tdep: Include x86-tdep.h.
10536 (i386_in_indirect_branch_thunk): New.
10537 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
10538 function.
10539 * amd64-tdep: Include x86-tdep.h.
10540 (amd64_in_indirect_branch_thunk): New.
10541 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
10542
10543 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10544
10545 PR gdb/23053
10546 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
10547 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
10548 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
10549 regression.
10550
10551 2018-04-12 Tom Tromey <tom@tromey.com>
10552
10553 * rust-lang.c (rust_print_struct_def): Remove univariant code.
10554 (rust_evaluate_subexp): Likewise.
10555
10556 2018-04-12 Pedro Alves <palves@redhat.com>
10557
10558 * procfs.c (procfs_detach): Make forward declaration's prototype
10559 match definition's protototype.
10560 (proc_get_LDT_entry): Remove stale do_cleanups call.
10561
10562 2018-04-12 Pedro Alves <palves@redhat.com>
10563
10564 * target.h (target_ops::to_has_exited): Delete.
10565 (target_has_exited): Delete.
10566 * target-delegates.c: Regenerate.
10567
10568 2018-04-11 Pedro Alves <palves@redhat.com>
10569
10570 * target.c (fileio_fh_t::t): Add comment.
10571 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10572 (target_fileio_close): Handle a NULL target.
10573 (invalidate_fileio_fh): New.
10574 (target_close): Call it.
10575 * remote.c (remote_hostio_send_command): No longer check whether
10576 remote_desc is open.
10577
10578 2018-04-11 Pedro Alves <palves@redhat.com>
10579
10580 * target.c (fileio_fh_t): Make it a named struct instead of a
10581 typedef.
10582 (fileio_fh_t::is_closed): New method.
10583 (DEF_VEC_O (fileio_fh_t)): Remove.
10584 (fileio_fhandles): Now a std::vector.
10585 (is_closed_fileio_fh): Delete.
10586 (acquire_fileio_fd): Adjust. Rename parameters.
10587 (release_fileio_fd): Adjust.
10588 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
10589 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10590 (target_fileio_close): Adjust.
10591
10592 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
10593
10594 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
10595 index.
10596
10597 2018-04-10 Pedro Alves <palves@redhat.com>
10598
10599 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
10600 (scoped_finish_thread_state): New class.
10601 * infcmd.c (run_command_1): Use it instead of finish_thread_state
10602 cleanup.
10603 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
10604 (fetch_inferior_event, normal_stop): Likewise.
10605 * thread.c (finish_thread_state_cleanup): Delete.
10606
10607 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10608 Pedro Alves <palves@redhat.com>
10609
10610 * value.c: Include "selftest.h" and "common/array-view.h".
10611 (struct range) <operator ==>: New.
10612 (test_ranges_contain): New.
10613 (check_ranges_vector): New.
10614 (test_insert_into_bit_range_vector): New.
10615 (_initialize_values): Register selftests.
10616 * common/array-view.h (operator==, operator!=): New.
10617
10618 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10619
10620 * common/gdb_vecs.h (unordered_remove): Add overload that takes
10621 an iterator.
10622 * inline-frame.c: Include <algorithm>.
10623 (struct inline_state): Add constructor.
10624 (inline_state_s): Remove.
10625 (DEF_VEC_O(inline_state_s)): Remove.
10626 (inline_states): Change type to std::vector.
10627 (find_inline_frame_state): Adjust to std::vector.
10628 (allocate_inline_frame_state): Remove.
10629 (clear_inline_frame_state): Adjust to std::vector.
10630 (skip_inline_frames): Adjust to std::vector.
10631
10632 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10633
10634 * tracepoint.h (struct trace_state_variable): Add constructor.
10635 <name>: Change type to std::string.
10636 * tracepoint.c (tsv_s): Remove.
10637 (DEF_VEC_O(tsv_s)): Remove.
10638 (tvariables): Change to std::vector.
10639 (create_trace_state_variable): Adjust to std::vector.
10640 (find_trace_state_variable): Likewise.
10641 (find_trace_state_variable_by_number): Likewise.
10642 (delete_trace_state_variable): Likewise.
10643 (trace_variable_command): Adjust to std::string.
10644 (delete_trace_variable_command): Likewise.
10645 (tvariables_info_1): Adjust to std::vector.
10646 (save_trace_state_variables): Likewise.
10647 (start_tracing): Likewise.
10648 (merge_uploaded_trace_state_variables): Adjust to std::vector
10649 and std::string.
10650 * target.h (struct target_ops)
10651 <to_download_trace_state_variable>: Pass reference to
10652 trace_state_variable.
10653 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
10654 * target-delegates.c: Re-generate.
10655 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
10656 (mi_tsv_deleted): Likewise.
10657 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
10658 * remote.c (remote_download_trace_state_variable): Change
10659 pointer to reference and adjust.
10660 * make-target-delegates (parse_argtypes): Handle references.
10661 (write_function_header): Likewise.
10662 (munge_type): Likewise.
10663
10664 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10665
10666 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10667 string_view-selftests.c.
10668 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
10669 testsuite.
10670 * unittests/basic_string_view/cons/char/1.cc: Likewise.
10671 * unittests/basic_string_view/cons/char/2.cc: Likewise.
10672 * unittests/basic_string_view/cons/char/3.cc: Likewise.
10673 * unittests/basic_string_view/element_access/char/1.cc:
10674 Likewise.
10675 * unittests/basic_string_view/element_access/char/empty.cc:
10676 Likewise.
10677 * unittests/basic_string_view/element_access/char/front_back.cc:
10678 Likewise.
10679 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
10680 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
10681 Likewise.
10682 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
10683 Likewise.
10684 * unittests/basic_string_view/modifiers/swap/char/1.cc:
10685 Likewise.
10686 * unittests/basic_string_view/operations/compare/char/1.cc:
10687 Likewise.
10688 * unittests/basic_string_view/operations/compare/char/13650.cc:
10689 Likewise.
10690 * unittests/basic_string_view/operations/copy/char/1.cc:
10691 Likewise.
10692 * unittests/basic_string_view/operations/data/char/1.cc:
10693 Likewise.
10694 * unittests/basic_string_view/operations/find/char/1.cc:
10695 Likewise.
10696 * unittests/basic_string_view/operations/find/char/2.cc:
10697 Likewise.
10698 * unittests/basic_string_view/operations/find/char/3.cc:
10699 Likewise.
10700 * unittests/basic_string_view/operations/find/char/4.cc:
10701 Likewise.
10702 * unittests/basic_string_view/operations/rfind/char/1.cc:
10703 Likewise.
10704 * unittests/basic_string_view/operations/rfind/char/2.cc:
10705 Likewise.
10706 * unittests/basic_string_view/operations/rfind/char/3.cc:
10707 Likewise.
10708 * unittests/basic_string_view/operations/substr/char/1.cc:
10709 Likewise.
10710 * unittests/basic_string_view/operators/char/2.cc: Likewise.
10711 * unittests/string_view-selftests.c: New file.
10712
10713 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10714
10715 * unittests/basic_string_view/capacity/1.cc: New file.
10716 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
10717 * unittests/basic_string_view/cons/char/1.cc: New file.
10718 * unittests/basic_string_view/cons/char/2.cc: New file.
10719 * unittests/basic_string_view/cons/char/3.cc: New file.
10720 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
10721 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
10722 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
10723 * unittests/basic_string_view/element_access/char/1.cc: New file.
10724 * unittests/basic_string_view/element_access/char/2.cc: New file.
10725 * unittests/basic_string_view/element_access/char/empty.cc: New file.
10726 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
10727 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
10728 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
10729 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
10730 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
10731 * unittests/basic_string_view/include.cc: New file.
10732 * unittests/basic_string_view/inserters/char/1.cc: New file.
10733 * unittests/basic_string_view/inserters/char/2.cc: New file.
10734 * unittests/basic_string_view/inserters/char/3.cc: New file.
10735 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
10736 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
10737 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
10738 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
10739 * unittests/basic_string_view/literals/types.cc: New file.
10740 * unittests/basic_string_view/literals/values.cc: New file.
10741 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
10742 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
10743 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
10744 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
10745 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
10746 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
10747 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
10748 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
10749 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
10750 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
10751 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
10752 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
10753 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
10754 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
10755 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
10756 * unittests/basic_string_view/operations/data/char/1.cc: New file.
10757 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
10758 * unittests/basic_string_view/operations/find/char/1.cc: New file.
10759 * unittests/basic_string_view/operations/find/char/2.cc: New file.
10760 * unittests/basic_string_view/operations/find/char/3.cc: New file.
10761 * unittests/basic_string_view/operations/find/char/4.cc: New file.
10762 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
10763 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
10764 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
10765 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
10766 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
10767 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
10768 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
10769 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
10770 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
10771 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
10772 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
10773 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
10774 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
10775 * unittests/basic_string_view/operators/char/2.cc: New file.
10776 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
10777 * unittests/basic_string_view/range_access/char/1.cc: New file.
10778 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
10779 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
10780 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
10781 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
10782 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
10783 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
10784 * unittests/basic_string_view/requirements/typedefs.cc: New file.
10785 * unittests/basic_string_view/typedefs.cc: New file.
10786 * unittests/basic_string_view/types/1.cc: New file.
10787
10788 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10789
10790 * common/gdb_string_view.h: Remove libstdc++ implementation
10791 details, adjust to gdb reality.
10792 * common/gdb_string_view.tcc: Likewise.
10793 * cli/cli-script.c (struct string_view): Remove.
10794 (user_args) <m_args>: Change element type to gdb::string_view.
10795 (user_args::insert_args): Adjust.
10796
10797 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10798
10799 * common/gdb_string_view.h: New file.
10800 * common/gdb_string_view.tcc: New file.
10801
10802 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10803
10804 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
10805 * configure: Re-generate.
10806
10807 2018-04-09 Pedro Alves <palves@redhat.com>
10808
10809 * gdbarch.sh: Include "observable.h" instead of "observer.h".
10810 (set_target_gdbarch): Call
10811 gdb::observers::architecture_changed.notify instead of
10812 observer_notify_architecture_changed.
10813
10814 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10815
10816 * tracepoint.c (struct current_traceframe_cleanup): Remove.
10817 (do_restore_current_traceframe_cleanup): Remove.
10818 (restore_current_traceframe_cleanup_dtor): Remove.
10819 (make_cleanup_restore_current_traceframe): Remove.
10820 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
10821 New.
10822 * tracepoint.h (struct scoped_restore_current_traceframe): New.
10823 * infrun.c (fetch_inferior_event): Use
10824 scoped_restore_current_traceframe.
10825
10826 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10827
10828 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
10829 Remove.
10830 <n_allocated_type_units>: Remove.
10831 <all_type_units>: Change to std::vector.
10832 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10833 to std::vector change.
10834 (dwarf2_per_objfile::get_cutu): Likewise.
10835 (dwarf2_per_objfile::get_tu): Likewise.
10836 (create_signatured_type_table_from_index): Likewise.
10837 (create_signatured_type_table_from_debug_names): Likewise.
10838 (dw2_symtab_iter_next): Likewise.
10839 (dw2_print_stats): Likewise.
10840 (dw2_expand_all_symtabs): Likewise.
10841 (dw2_expand_marked_cus): Likewise.
10842 (dw2_debug_names_iterator::next): Likewise.
10843 (dwarf2_initialize_objfile): Likewise.
10844 (add_signatured_type_cu_to_table): Likewise.
10845 (create_all_type_units): Likewise.
10846 (add_type_unit): Likewise.
10847 (struct tu_abbrev_offset): Add constructor.
10848 (build_type_psymtabs_1): Adjust to std::vector change.
10849 (print_tu_stats): Likewise.
10850 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10851 (write_debug_names): Likewise.
10852
10853 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10854
10855 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
10856 Make an std::vector.
10857 <n_comp_units>: Remove.
10858 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10859 to std::vector change.
10860 (dwarf2_per_objfile::get_cutu): Likewise.
10861 (dwarf2_per_objfile::get_cu): Likewise.
10862 (create_cus_from_index): Likewise.
10863 (create_addrmap_from_index): Likewise.
10864 (create_addrmap_from_aranges): Likewise.
10865 (dwarf2_read_index): Likewise.
10866 (dw2_find_last_source_symtab): Likewise.
10867 (dw2_map_symtabs_matching_filename): Likewise.
10868 (dw2_symtab_iter_next): Likewise.
10869 (dw2_print_stats): Likewise.
10870 (dw2_expand_all_symtabs): Likewise.
10871 (dw2_expand_symtabs_with_fullname): Likewise.
10872 (dw2_expand_marked_cus): Likewise.
10873 (dw2_map_symbol_filenames): Likewise.
10874 (create_cus_from_debug_names): Likewise.
10875 (dwarf2_read_debug_names): Likewise.
10876 (dw2_debug_names_iterator::next): Likewise.
10877 (dwarf2_initialize_objfile): Likewise.
10878 (set_partial_user): Likewise.
10879 (dwarf2_build_psymtabs_hard): Likewise.
10880 (read_comp_units_from_section): Remove arguments, adjust to
10881 std::vector change.
10882 (create_all_comp_units): Adjust to std::vector and
10883 read_comp_units_from_section changes.
10884 (dwarf2_find_containing_comp_unit): Adjust to std::vector
10885 change.
10886 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10887 (psyms_seen_size): Likewise.
10888 (write_gdbindex): Likewise.
10889 (write_debug_names): Likewise.
10890
10891 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10892
10893 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
10894 with dwarf2_per_objfile.
10895 (create_cus_from_index): Likewise.
10896 (create_signatured_type_table_from_index): Likewise.
10897 (dwarf2_read_index): Likewise.
10898 (dwarf2_initialize_objfile): Likewise.
10899 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
10900 per_cu rather than get_dwarf2_per_objfile.
10901
10902 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10903
10904 * dwarf2read.h (struct signatured_type): Forward declare.
10905 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
10906 New methods.
10907 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
10908 (dw2_get_cutu): ...this.
10909 (dwarf2_per_objfile::get_cu): Rename from...
10910 (dw2_get_cu): ...this.
10911 (dwarf2_per_objfile::get_tu): New.
10912 (create_addrmap_from_index): Adjust.
10913 (create_addrmap_from_aranges): Adjust.
10914 (dw2_find_last_source_symtab): Adjust.
10915 (dw2_map_symtabs_matching_filename): Adjust.
10916 (dw2_symtab_iter_next): Adjust.
10917 (dw2_print_stats): Adjust.
10918 (dw2_expand_all_symtabs): Adjust.
10919 (dw2_expand_symtabs_with_fullname): Adjust.
10920 (dw2_expand_marked_cus): Adjust.
10921 (dw_expand_symtabs_matching_file_matcher): Adjust.
10922 (dw2_map_symbol_filenames): Adjust.
10923 (dw2_debug_names_iterator::next): Adjust.
10924 (dwarf2_initialize_objfile): Adjust.
10925 (set_partial_user): Adjust.
10926 (dwarf2_build_psymtabs_hard): Adjust.
10927
10928 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10929
10930 * dwarf2read.c (create_signatured_type_table_from_debug_names):
10931 Remove unused variables.
10932 (dw2_map_symtabs_matching_filename): Likewise.
10933 (dwarf2_record_block_ranges): Likewise.
10934 (dwarf2_read_addr_index): Likewise.
10935 (follow_die_offset): Likewise.
10936
10937 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10938
10939 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
10940 to symbol_file_add_main.
10941
10942 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10943
10944 PR mi/22299
10945 * mi/mi-console.c (do_fputc_async_safe): New.
10946 (mi_console_file::write_async_safe): New.
10947 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
10948 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
10949 New.
10950 * ui-file.c (ui_file::putstrn): Adjust call to
10951 fputstrn_unfiltered.
10952 * utils.c (printchar): Replace do_fputs and do_fprintf
10953 parameters by do_fputc.
10954 (fputstr_filtered): Adjust call to printchar.
10955 (fputstr_unfiltered): Likewise.
10956 (fputstrn_filtered): Likewise.
10957 (fputstrn_unfiltered): Add do_fputc parameter, pass to
10958 printchar.
10959 * utils.h (do_fputc_ftype): New typedef.
10960 (fputstrn_unfiltered): Add do_fputc parameter.
10961
10962 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10963
10964 * regformats/i386/i386-avx.dat: Remove.
10965
10966 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10967
10968 PR gdb/22979
10969 * amd64-tdep.c (amd64_none_init_abi): New function.
10970 (amd64_x32_none_init_abi): New function.
10971 (_initialize_amd64_tdep): Register handlers for x86-64 and
10972 x64_32 with GDB_OSABI_NONE.
10973 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10974 GDB_OSABI_NONE osabi.
10975
10976 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10977
10978 PR gdb/22980
10979 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10980 GDB_OSABI_NONE.
10981 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10982 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10983
10984 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10985
10986 * common/byte-vector.h (char_vector): New type.
10987 * target.h (target_read_alloc): Return
10988 gdb::optional<byte_vector>.
10989 (target_read_stralloc): Return gdb::optional<char_vector>.
10990 (target_get_osdata): Return gdb::optional<char_vector>.
10991 * target.c (target_read_alloc_1): Templatize. Replacement
10992 manual memory management with vector.
10993 (target_read_alloc): Change return type, adjust.
10994 (target_read_stralloc): Change return type, adjust.
10995 (target_get_osdata): Change return type, adjust.
10996 * auxv.c (struct auxv_info) <length>: Remove.
10997 <data>: Change type to gdb::optional<byte_vector>.
10998 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10999 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
11000 (target_auxv_search): Adjust.
11001 (fprint_target_auxv): Adjust.
11002 * avr-tdep.c (avr_io_reg_read_command): Adjust.
11003 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
11004 (linux_make_corefile_notes): Adjust.
11005 * osdata.c (get_osdata): Adjust.
11006 * remote.c (remote_get_threads_with_qxfer): Adjust.
11007 (remote_memory_map): Adjust.
11008 (remote_traceframe_info): Adjust.
11009 (btrace_read_config): Adjust.
11010 (remote_read_btrace): Adjust.
11011 (remote_pid_to_exec_file): Adjust.
11012 * solib-aix.c (solib_aix_get_library_list): Adjust.
11013 * solib-dsbt.c (decode_loadmap): Don't free buf.
11014 (dsbt_get_initial_loadmaps): Adjust.
11015 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
11016 * solib-target.c (solib_target_current_sos): Adjust.
11017 * tracepoint.c (sdata_make_value): Adjust.
11018 * xml-support.c (xinclude_start_include): Adjust.
11019 (xml_fetch_content_from_file): Adjust.
11020 * xml-support.h (xml_fetch_another): Change return type.
11021 (xml_fetch_content_from_file): Change return type.
11022 * xml-syscall.c (xml_init_syscalls_info): Adjust.
11023 * xml-tdesc.c (file_read_description_xml): Adjust.
11024 (fetch_available_features_from_target): Change return type.
11025 (target_fetch_description_xml): Adjust.
11026 (target_read_description_xml): Adjust.
11027
11028 2018-04-06 Tom Tromey <tom@tromey.com>
11029
11030 * value.c (~value): Update.
11031 (struct value) <contents>: Now unique_xmalloc_ptr.
11032 (value_contents_bits_eq, allocate_value_contents)
11033 (value_contents_raw, value_contents_all_raw)
11034 (value_contents_for_printing, value_contents_for_printing_const)
11035 (set_value_enclosing_type): Update.
11036
11037 2018-04-06 Tom Tromey <tom@tromey.com>
11038
11039 * value.c (range_s): Remove typedef, VEC.
11040 (struct range): Add operator<.
11041 (range_lessthan): Remove.
11042 (ranges_contain): Change type.
11043 (~value): Update.
11044 (struct value) <unavailable, optimized_out>: Now std::vector.
11045 (value_entirely_available)
11046 (value_entirely_covered_by_range_vector)
11047 (value_entirely_unavailable, value_entirely_optimized_out):
11048 Update.
11049 (insert_into_bit_range_vector): Change argument type.
11050 (find_first_range_overlap): Likewise.
11051 (struct ranges_and_idx, value_contents_bits_eq)
11052 (require_not_optimized_out, require_available): Update.
11053 (ranges_copy_adjusted): Change argument types.
11054 (value_optimized_out, value_copy, value_fetch_lazy): Update.
11055
11056 2018-04-06 Tom Tromey <tom@tromey.com>
11057
11058 * value.c (~value): Update.
11059 (struct value) <parent>: Now a value_ref_ptr.
11060 (value_parent, set_value_parent, value_address, value_copy):
11061 Update.
11062
11063 2018-04-06 Tom Tromey <tom@tromey.com>
11064
11065 * value.c (struct value): Add constructor, destructor, and member
11066 initializers.
11067 (allocate_value_lazy, value_decref): Update.
11068
11069 2018-04-06 Tom Tromey <tom@tromey.com>
11070
11071 * value.c (struct value) <released, next>: Remove.
11072 (all_values): Now a std::vector.
11073 (allocate_value_lazy): Update.
11074 (value_next): Remove.
11075 (value_mark, value_free_to_mark, release_value)
11076 (value_release_to_mark): Update.
11077
11078 2018-04-06 Tom Tromey <tom@tromey.com>
11079
11080 * value.h (fetch_subexp_value, value_release_to_mark): Update.
11081 (free_value_chain): Remove.
11082 * value.c (free_value_chain): Remove.
11083 (value_release_to_mark): Return a std::vector.
11084 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
11085 std::vector.
11086 (check_condition): Update.
11087 * eval.c (fetch_subexp_value): Change "val_chain" to a
11088 std::vector.
11089 * breakpoint.c (update_watchpoint): Update.
11090 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
11091
11092 2018-04-06 Tom Tromey <tom@tromey.com>
11093
11094 * value.h (free_all_values): Remove.
11095 * value.c (free_all_values): Remove.
11096
11097 2018-04-06 Tom Tromey <tom@tromey.com>
11098
11099 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
11100 (value_history_chain, value_history_count): Remove.
11101 (value_history): New global.
11102 (record_latest_value, access_value_history, show_values)
11103 (preserve_values): Update.
11104
11105 2018-04-06 Tom Tromey <tom@tromey.com>
11106
11107 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
11108 * varobj.c (varobj_set_display_format, varobj_set_value)
11109 (install_default_visualizer, construct_visualizer)
11110 (install_new_value, ~varobj, varobj_get_value_type)
11111 (my_value_of_variable, varobj_editable_p): Update.
11112 * c-varobj.c (c_describe_child, c_value_of_variable)
11113 (cplus_number_of_children, cplus_describe_child): Update.
11114 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
11115 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
11116 (ada_value_of_variable, ada_value_is_changeable_p): Update.
11117
11118 2018-04-06 Tom Tromey <tom@tromey.com>
11119
11120 * printcmd.c (last_examine_address): Change type to
11121 value_ref_ptr.
11122 (do_examine, x_command): Update.
11123
11124 2018-04-06 Tom Tromey <tom@tromey.com>
11125
11126 * value.c (release_value): Update.
11127 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
11128 (struct bpstats) <val>: Now a value_ref_ptr.
11129 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11130 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11131 (~watchpoint, print_it_watchpoint, watch_command_1)
11132 (invalidate_bp_value_on_memory_change): Update.
11133
11134 2018-04-06 Tom Tromey <tom@tromey.com>
11135
11136 * varobj.c (varobj_clear_saved_item)
11137 (update_dynamic_varobj_children, install_new_value, ~varobj):
11138 Update.
11139 * value.h (value_incref): Move declaration earlier.
11140 (value_decref): Rename from value_free.
11141 (struct value_ref_policy): New.
11142 (value_ref_ptr): New typedef.
11143 (struct value_deleter): Remove.
11144 (gdb_value_up): Remove typedef.
11145 (release_value): Change return type.
11146 (release_value_or_incref): Remove.
11147 * value.c (set_value_parent): Update.
11148 (value_incref): Change return type.
11149 (value_decref): Rename from value_free.
11150 (value_free_to_mark, free_all_values, free_value_chain): Update.
11151 (release_value): Return value_ref_ptr.
11152 (release_value_or_incref): Remove.
11153 (record_latest_value, set_internalvar, clear_internalvar):
11154 Update.
11155 * stack.c (info_frame_command): Don't call value_free.
11156 * python/py-value.c (valpy_dealloc, valpy_new)
11157 (value_to_value_object): Update.
11158 * printcmd.c (do_examine): Update.
11159 * opencl-lang.c (lval_func_free_closure): Update.
11160 * mi/mi-main.c (register_changed_p): Don't call value_free.
11161 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
11162 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
11163 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
11164 value_free.
11165 * guile/scm-value.c (vlscm_free_value_smob)
11166 (vlscm_scm_from_value): Update.
11167 * frame.c (frame_register_unwind, frame_unwind_register_signed)
11168 (frame_unwind_register_unsigned, get_frame_register_bytes)
11169 (put_frame_register_bytes): Don't call value_free.
11170 * findvar.c (address_from_register): Don't call value_free.
11171 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
11172 * dwarf2loc.c (entry_data_value_free_closure)
11173 (value_of_dwarf_reg_entry, free_pieced_value_closure)
11174 (dwarf2_evaluate_loc_desc_full): Update.
11175 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11176 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11177 (~watchpoint, watch_command_1)
11178 (invalidate_bp_value_on_memory_change): Update.
11179 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
11180
11181 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
11182
11183 PR gdb/23022
11184 * warning.m4: Add -Wno-error=deprecated-register.
11185 * configure: Re-generate.
11186
11187 2018-04-05 Tom Tromey <tom@tromey.com>
11188
11189 * linespec.h: Remove include of "vec.h".
11190
11191 2018-04-05 Tom Tromey <tom@tromey.com>
11192
11193 * linespec.c (typep): Remove typedef.
11194 (find_methods, find_superclass_methods): Take a std::vector.
11195 (find_method): Use std::vector.
11196
11197 2018-04-05 Tom Tromey <tom@tromey.com>
11198
11199 * utils.c (compare_strings): Remove.
11200 * utils.h (compare_strings): Remove.
11201 * objc-lang.h (find_imps): Update.
11202 * objc-lang.c (find_methods): Take a std::vector.
11203 (uniquify_strings, find_imps): Likewise.
11204 * linespec.c (find_methods): Take a std::vector.
11205 (decode_objc): Use std::vector.
11206 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
11207 a std::vector.
11208 (find_method, find_function_symbols): Use std::vector.
11209
11210 2018-04-05 Tom Tromey <tom@tromey.com>
11211
11212 * completer.c (completion_tracker::completion_tracker): Remove
11213 cast.
11214 (completion_tracker::discard_completions): Likewise.
11215 * breakpoint.c (ambiguous_names_p): Remove cast.
11216 * ada-lang.c (_initialize_ada_language): Remove cast.
11217 * utils.h (streq): Update.
11218 (streq_hash): Add new declaration.
11219 * utils.c (streq): Return bool.
11220 (streq_hash): New function.
11221
11222 2018-04-05 Tom Tromey <tom@tromey.com>
11223
11224 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
11225 Remove a string copy.
11226
11227 2018-04-05 Tom Tromey <tom@tromey.com>
11228
11229 * linespec.c (filter_results): Use std::vector.
11230 (decode_line_2, decode_line_full): Update.
11231
11232 2018-04-05 Tom Tromey <tom@tromey.com>
11233
11234 * linespec.c (canonical_to_fullform): Return std::string.
11235 (filter_results): Update.
11236 (struct decode_line_2_item): Add constructor.
11237 <fullform, displayform>: Now std::string.
11238 (decode_line_2_compare_items): Now a std::sort comparator.
11239 (decode_line_2): Update.
11240
11241 2018-04-05 Tom Tromey <tom@tromey.com>
11242
11243 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
11244 (unexpected_linespec_error): Update.
11245 (linespec_parse_basic, parse_linespec): Update.
11246
11247 2018-04-05 Tom Tromey <tom@tromey.com>
11248
11249 * linespec.c (linespec_parse_basic): Reindent.
11250
11251 2018-04-05 Tom Tromey <tom@tromey.com>
11252
11253 * minsyms.h (iterate_over_minimal_symbols): Update.
11254 * minsyms.c (iterate_over_minimal_symbols): Take a
11255 gdb::function_view.
11256 * linespec.c (struct collect_minsyms): Remove.
11257 (compare_msyms): Now a std::sort comparator.
11258 (add_minsym): Add parameters.
11259 (search_minsyms_for_name): Update. Use std::vector.
11260
11261 2018-04-03 Tom Tromey <tom@tromey.com>
11262
11263 * mipsread.c (read_alphacoff_dynamic_symtab): Use
11264 gdb::byte_vector.
11265
11266 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11267
11268 * MAINTAINERS (Write After Approval): Add Weimin Pan.
11269
11270 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11271
11272 PR gdb/16959
11273 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
11274 printing static type.
11275
11276 2018-04-01 Tom Tromey <tom@tromey.com>
11277
11278 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
11279 (rs6000_xfer_shared_libraries): Update.
11280
11281 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
11282
11283 * common/gdb_vecs.h (char_ptr): Remove.
11284 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
11285
11286 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11287
11288 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
11289 with std::vector.
11290 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
11291
11292 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11293
11294 * tracepoint.h (struct uploaded_tp): Initialize fields.
11295 <actions, step_actions, cmd_strings>: Change type to
11296 std::vector<char *>.
11297 * tracepoint.c (get_uploaded_tp): Allocate with new.
11298 (free_uploaded_tps): Free with delete.
11299 (parse_tracepoint_definition): Adjust to std::vector change.
11300 * breakpoint.c (read_uploaded_action): Likewise.
11301 (create_tracepoint_from_upload): Likewise.
11302 * ctf.c (ctf_write_uploaded_tp): Likewise.
11303 (SET_ARRAY_FIELD): Likewise.
11304 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
11305
11306 2018-03-30 Tom Tromey <tom@tromey.com>
11307
11308 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
11309 std::unique_ptr.
11310 (svr4_keep_data_in_core): Update.
11311 (svr4_read_so_list): Update.
11312
11313 2018-03-30 Tom Tromey <tom@tromey.com>
11314
11315 * windows-nat.c (handle_output_debug_string, handle_exception):
11316 Update.
11317 * target.h (target_read_string): Update.
11318 * target.c (target_read_string): Change "string" to
11319 unique_xmalloc_ptr.
11320 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
11321 Update.
11322 * solib-frv.c (frv_current_sos): Update.
11323 * solib-dsbt.c (dsbt_current_sos): Update.
11324 * solib-darwin.c (darwin_current_sos): Update.
11325 * linux-thread-db.c (inferior_has_bug): Update.
11326 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
11327 Update. Remove alloca.
11328 * ada-lang.c (ada_main_name): Update.
11329
11330 2018-03-30 Tom Tromey <tom@tromey.com>
11331
11332 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
11333 (struct dwo_file_deleter): New.
11334 (dwo_file_up): New typedef.
11335 (open_and_init_dwo_file): Use dwo_file_up.
11336 (free_dwo_file_cleanup): Remove.
11337
11338 2018-03-30 Tom Tromey <tom@tromey.com>
11339
11340 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
11341 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
11342
11343 2018-03-30 Tom Tromey <tom@tromey.com>
11344
11345 * dwarf2read.c (class free_cached_comp_units): New class.
11346 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
11347 (free_cached_comp_units): Remove function.
11348
11349 2018-03-30 Tom Tromey <tom@tromey.com>
11350
11351 * utils.h (make_cleanup_unpush_target): Remove.
11352 * inf-ptrace.c (struct target_unpusher): New.
11353 (target_unpush_up) New typedef.
11354 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
11355 target_unpush_up.
11356 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
11357
11358 2018-03-27 Tom Tromey <tom@tromey.com>
11359
11360 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
11361
11362 2018-03-27 Pedro Alves <palves@redhat.com>
11363 Tom Tromey <tom@tromey.com>
11364
11365 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
11366 destructor. Now a class.
11367 (gdb_readline_wrapper_cleanup): Remove function.
11368 (gdb_readline_wrapper): Remove cleanups.
11369
11370 2018-03-27 Tom Tromey <tom@tromey.com>
11371
11372 * typeprint.h (struct type_print_options) <local_typedefs,
11373 global_typedefs>: Remove "struct" keyword.
11374 (class typedef_hash_table): New class.
11375 (recursively_update_typedef_hash, add_template_parameters)
11376 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
11377 (find_typedef_in_hash): Don't declare.
11378 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
11379 (typedef_hash_table::recursively_update): Rename from
11380 recursively_update_typedef_hash. Now a member.
11381 (typedef_hash_table::add_template_parameters): Rename from
11382 add_template_parameters. Now a member.
11383 (typedef_hash_table::typedef_hash_table): Now a constructor;
11384 rename from create_typedef_hash.
11385 (typedef_hash_table::~typedef_hash_table): Now a destructor;
11386 rename from free_typedef_hash.
11387 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
11388 (do_free_global_table): Remove.
11389 (typedef_hash_table::typedef_hash_table): New constructor; renamed
11390 from copy_type_recursive.
11391 (create_global_typedef_table): Remove.
11392 (typedef_hash_table::find_global_typedef): Now a member of
11393 typedef_hash_table.
11394 (typedef_hash_table::find_typedef): Rename from
11395 find_typedef_in_hash; now a member.
11396 (whatis_exp): Update.
11397 * extension.h (struct ext_lang_type_printers): Add constructor and
11398 destructor.
11399 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
11400 declare.
11401 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
11402 Now a constructor; rename from start_ext_lang_type_printers.
11403 (ext_lang_type_printers): Now a destructor; rename from
11404 free_ext_lang_type_printers.
11405 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
11406 Update.
11407 (c_type_print_base_struct_union): Update. Remove cleanups.
11408
11409 2018-03-27 Tom Tromey <tom@tromey.com>
11410
11411 * dwarf-index-write.c: Include <cmath>.
11412
11413 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11414
11415 * NEWS: Add entry describing new "set|show varsize-limit" command.
11416 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
11417 command.
11418 * printcmd.c (_initialize_printcmd): Add "set var" alias of
11419 "set variable".
11420
11421 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
11422
11423 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
11424 dwarf-index-write.c
11425 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
11426 * dwarf-index-common.c: New file.
11427 * dwarf-index-common.h: New file.
11428 * dwarf-index-write.c: New file.
11429 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
11430 (struct dwarf2_section_info): Move from here.
11431 (dwarf2_section_info_def): Likewise.
11432 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
11433 (offset_type): Likewise.
11434 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
11435 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
11436 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
11437 (byte_swap): Likewise.
11438 (MAYBE_SWAP): Likewise.
11439 (dwarf2_per_cu_ptr): Likewise.
11440 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
11441 (struct tu_stats): Likewise.
11442 (struct dwarf2_per_objfile): Likewise.
11443 (struct dwarf2_per_cu_data): Likewise.
11444 (struct signatured_type): Likewise.
11445 (sig_type_ptr): Likewise.
11446 (DEF_VEC_P (sig_type_ptr)): Likewise.
11447 (INDEX4_SUFFIX): Likewise.
11448 (INDEX5_SUFFIX): Likewise.
11449 (DEBUG_STR_SUFFIX): Likewise.
11450 (dwarf2_read_section): Make non-static.
11451 (mapped_index_string_hash): Move from here.
11452 (dwarf5_djb_hash): Likewise.
11453 (file_write): Likewise.
11454 (class data_buf): Likewise.
11455 (struct symtab_index_entry): Likewise.
11456 (struct mapped_symtab): Likewise.
11457 (find_slot): Likewise.
11458 (hash_expand): Likewise.
11459 (add_index_entry): Likewise.
11460 (uniquify_cu_indices): Likewise.
11461 (class c_str_view): Likewise.
11462 (class c_str_view_hasher): Likewise.
11463 (class vector_hasher): Likewise.
11464 (write_hash_table): Likewise.
11465 (psym_index_map): Likewise.
11466 (struct addrmap_index_data): Likewise.
11467 (add_address_entry): Likewise.
11468 (add_address_entry_worker): Likewise.
11469 (write_address_map): Likewise.
11470 (symbol_kind): Likewise.
11471 (write_psymbols): Likewise.
11472 (struct signatured_type_index_data): Likewise.
11473 (write_one_signatured_type): Likewise.
11474 (recursively_count_psymbols): Likewise.
11475 (recursively_write_psymbols): Likewise.
11476 (class debug_names): Likewise.
11477 (check_dwarf64_offsets): Likewise.
11478 (psyms_seen_size): Likewise.
11479 (write_gdbindex): Likewise.
11480 (write_debug_names): Likewise.
11481 (assert_file_size): Likewise.
11482 (write_psymtabs_to_index): Likewise.
11483 (save_gdb_index_command): Likewise.
11484 (_initialize_dwarf2_read): Don't register the "save gdb-index"
11485 command.
11486 * dwarf2read.h: New file.
11487
11488 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11489
11490 PR gdb/22670
11491 * dwarf2read.c (dwarf2_physname): Do not return the demangled
11492 symbol name if the CU's language stores symbol names in linkage
11493 format.
11494 * language.h (struct language_defn)
11495 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
11496 all instances of this struct.
11497
11498 2018-03-26 Tom Tromey <tom@tromey.com>
11499
11500 * stack.c (backtrace_command_1): Remove verbose code.
11501
11502 2018-03-26 Tom Tromey <tom@tromey.com>
11503
11504 * python/py-framefilter.c (py_print_type): Don't catch
11505 exceptions. Return void.
11506 (py_print_value): Likewise.
11507 (py_print_single_arg): Likewise.
11508 (enumerate_args): Don't catch exceptions.
11509 (py_print_args): Likewise.
11510 (py_print_frame): Likewise.
11511 (gdbpy_apply_frame_filter): Catch exceptions here.
11512
11513 2018-03-26 Tom Tromey <tom@tromey.com>
11514
11515 * stack.c (_initialize_stack): Remove trailing newlines from help
11516 text. Add "Usage" line to "backtrace" help.
11517
11518 2018-03-26 Tom Tromey <tom@tromey.com>
11519
11520 PR python/16486:
11521 * python/py-framefilter.c (py_print_args): Call wrap_hint.
11522
11523 2018-03-26 Tom Tromey <tom@tromey.com>
11524
11525 * python/py-framefilter.c (py_print_single_arg): Return
11526 EXT_LANG_BT_ERROR from catch.
11527
11528 2018-03-26 Tom Tromey <tom@tromey.com>
11529
11530 PR backtrace/15584:
11531 * stack.c (backtrace_command_1): Move some code into no-filters
11532 "if".
11533
11534 2018-03-26 Tom Tromey <tom@tromey.com>
11535
11536 * python/py-framefilter.c (throw_quit_or_print_exception): New
11537 function.
11538 (gdbpy_apply_frame_filter): Use it.
11539
11540 2018-03-26 Tom Tromey <tom@tromey.com>
11541
11542 PR cli/17716:
11543 * python/py-framefilter.c (py_print_type, py_print_value)
11544 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
11545 RETURN_MASK_ERROR.
11546
11547 2018-03-26 Tom Tromey <tom@tromey.com>
11548
11549 * python/py-framefilter.c (enumerate_args): Use
11550 gdb::unique_xmalloc_ptr.
11551
11552 2018-03-26 Tom Tromey <tom@tromey.com>
11553
11554 * python/py-framefilter.c (py_print_frame): Return
11555 EXT_LANG_BT_OK.
11556 (gdbpy_apply_frame_filter): Update comment.
11557 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
11558 Remove.
11559 <EXT_LANG_BT_NO_FILTERS>: Change value.
11560
11561 2018-03-26 Tom Tromey <tom@tromey.com>
11562
11563 PR backtrace/15582:
11564 * stack.c (backtrace_command): Parse "hide" argument.
11565 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
11566 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
11567 constant.
11568
11569 2018-03-26 Tom Tromey <tom@tromey.com>
11570
11571 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
11572 add "flags".
11573 (backtrace_command): Remove "fulltrace", add "flags".
11574
11575 2018-03-26 Tom Tromey <tom@tromey.com>
11576
11577 * stack.c (backtrace_command): Rewrite command line parsing.
11578
11579 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11580
11581 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
11582
11583 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11584
11585 * filename-seen-cache.h: Add include guard.
11586
11587 2018-03-26 Keith Seitz <keiths@redhat.com>
11588
11589 * symfile.c (place_section): Remove "struct" from section_addr_info
11590 in comment.
11591 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
11592 "struct" keyword from section_addr_info.
11593
11594 2018-03-26 Alan Hayward <alan.hayward@arm.com>
11595
11596 * regformats/regdef.h (reg): Add constructors.
11597
11598 2018-03-25 Pedro Alves <palves@redhat.com>
11599
11600 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
11601 if then/else bodies in var_func_name extraction.
11602
11603 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
11604
11605 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
11606 lookup_minimal_symbol() to find symbol entry.
11607 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
11608
11609 2018-03-23 Keith Seitz <keiths@redhat.com>
11610
11611 PR c++/22968
11612 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
11613 nested type definitions for C++, too.
11614
11615 2018-03-23 Tom Tromey <tom@tromey.com>
11616
11617 * machoread.c (struct oso_el): Add a constructor. Don't define as
11618 a typedef.
11619 (macho_register_oso): Remove.
11620 (macho_symtab_read): Take a std::vector.
11621 (oso_el_compare_name): Now a std::sort comparator.
11622 (macho_symfile_read_all_oso): Take a std::vector.
11623 (macho_symfile_read): Use std::vector. Remove cleanups.
11624
11625 2018-03-22 Tom Tromey <tom@tromey.com>
11626
11627 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
11628 (record_full_goto_bookmark): Use std::string.
11629
11630 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11631
11632 PR tdep/18295
11633 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
11634 a single mask.
11635
11636 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11637
11638 * rs6000-tdep.c (store_insn_p): New function.
11639 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
11640 and cr_reg to their unshifted values. Use store_insn_p to
11641 match LR saves using either R1 or fdata->alloca_reg. Use
11642 store_insn_p to match CR saves. Set alloca_reg_offset
11643 when alloca_reg and framep are set. Remove lr_reg shift
11644 when assigning to fdata->lr_register.
11645
11646 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
11647
11648 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
11649 command line args instead of emitting a warning.
11650
11651 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11652
11653 * tracepoint.h (struct static_tracepoint_marker): Initialize
11654 fields, define default constructor, move constructor and move
11655 assignment, disable the rest.
11656 <str_id, extra>: Make std::string.
11657 (release_static_tracepoint_marker): Remove.
11658 (free_current_marker): Remove.
11659 * tracepoint.c (free_current_marker): Remove.
11660 (parse_static_tracepoint_marker_definition): Adjust to
11661 std::string, use new hex2str overload.
11662 (release_static_tracepoint_marker): Remove.
11663 (print_one_static_tracepoint_marker): Get marker by reference
11664 and adjust to std::string.
11665 (info_static_tracepoint_markers_command): Adjust to std::vector
11666 changes
11667 * target.h (static_tracepoint_marker_p): Remove typedef.
11668 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
11669 (struct target_ops) <to_static_tracepoint_marker_at>: Return
11670 bool.
11671 <to_static_tracepoint_markers_by_strid>: Return std::vector.
11672 * target-debug.h
11673 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
11674 (target_debug_print_std_vector_static_tracepoint_marker): New.
11675 (target_debug_print_struct_static_tracepoint_marker_p): Rename
11676 to...
11677 (target_debug_print_static_tracepoint_marker_p): ... this.
11678 * target-delegates.c: Re-generate.
11679 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
11680 Make std::string.
11681 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
11682 (decode_static_tracepoint_spec): Adjust to std::vector.
11683 (tracepoint_print_one_detail): Adjust to std::string.
11684 (strace_marker_decode_location): Adjust to std::string.
11685 (update_static_tracepoint): Adjust to std::string, remove call
11686 to release_static_tracepoint_marker.
11687 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
11688 Adjust to std::vector.
11689 * remote.c (remote_static_tracepoint_marker_at): Return bool.
11690 (remote_static_tracepoint_markers_by_strid): Adjust to
11691 std::vector.
11692 * common/rsp-low.h (hex2str): New overload with explicit count
11693 of bytes.
11694 * common/rsp-low.c (hex2str): New overload with explicit count
11695 of bytes.
11696 * unittests/rsp-low-selftests.c (test_hex2str): New function.
11697 (_initialize_rsp_low_selftests): Add test_hex2str test.
11698 * unittests/tracepoint-selftests.c
11699 (test_parse_static_tracepoint_marker_definition): Adjust to
11700 std::string.
11701
11702 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11703
11704 * tracepoint.c (parse_static_tracepoint_marker_definition):
11705 Consider case where the definition is followed by more
11706 definitions.
11707 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11708 tracepoint-selftests.c.
11709 * unittests/tracepoint-selftests.c: New.
11710
11711 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
11712
11713 * MAINTAINERS (Write After Approval): Add Pedro Franco de
11714 Carvalho.
11715
11716 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
11717
11718 * symtab.c (find_pc_sect_line): fixed indentation.
11719
11720 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
11721
11722 * symtab.c (find_pc_sect_line): now uses binary search.
11723
11724 2018-03-19 Tom Tromey <tom@tromey.com>
11725
11726 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
11727 "IDENT" production.
11728
11729 2018-03-19 Pedro Alves <palves@redhat.com>
11730 Tom Tromey <tom@tromey.com>
11731
11732 * unittests/observable-selftests.c: New file.
11733 * common/observable.h: New file.
11734 * observable.h: New file.
11735 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
11736 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
11737 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
11738 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
11739 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
11740 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
11741 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
11742 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
11743 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
11744 python/py-breakpoint.c, python/py-finishbreakpoint.c,
11745 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
11746 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
11747 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
11748 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
11749 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
11750 tui/tui-interp.c, valops.c: Update all users.
11751 * tui/tui-hooks.c (tui_bp_created_observer)
11752 (tui_bp_deleted_observer, tui_bp_modified_observer)
11753 (tui_inferior_exit_observer, tui_before_prompt_observer)
11754 (tui_normal_stop_observer, tui_register_changed_observer):
11755 Remove.
11756 (tui_observers_token): New global.
11757 (attach_or_detach, tui_attach_detach_observers): New functions.
11758 (tui_install_hooks, tui_remove_hooks): Use
11759 tui_attach_detach_observers.
11760 * record-btrace.c (record_btrace_thread_observer): Remove.
11761 (record_btrace_thread_observer_token): New global.
11762 * observer.sh: Remove.
11763 * observer.c: Rename to observable.c.
11764 * observable.c (namespace gdb_observers): Define new objects.
11765 (observer_debug): Move into gdb_observers namespace.
11766 (struct observer, struct observer_list, xalloc_observer_list_node)
11767 (xfree_observer_list_node, generic_observer_attach)
11768 (generic_observer_detach, generic_observer_notify): Remove.
11769 (_initialize_observer): Update.
11770 Don't include observer.inc.
11771 * Makefile.in (generated_files): Remove observer.h, observer.inc.
11772 (clean mostlyclean): Likewise.
11773 (observer.h, observer.inc): Remove targets.
11774 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
11775 (COMMON_SFILES): Use observable.c, not observer.c.
11776 * .gitignore: Remove observer.h.
11777
11778 2018-03-18 Tom Tromey <tom@tromey.com>
11779
11780 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
11781 gdb::def_vector.
11782 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
11783
11784 2018-03-17 Tom Tromey <tom@tromey.com>
11785
11786 * auto-load.c (auto_load_objfile_script_1): Use std::string.
11787
11788 2018-03-17 Tom Tromey <tom@tromey.com>
11789
11790 * target.c (class scoped_target_fd): New.
11791 (target_fileio_close_cleanup): Remove.
11792 (target_fileio_read_alloc_1): Use scoped_target_fd.
11793
11794 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
11795
11796 * silent-rules.mk: New.
11797 * Makefile.in: Include silent-rules.mk
11798 (srcdir, VPATH, top_srcdir): Move up.
11799 (COMPILE): Add ECHO_CXX.
11800 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
11801 (init.c): Add ECHO_INIT_C.
11802 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
11803 (version.c): Add ECHO_GEN.
11804 (printcmd.o): Add ECHO_CXX.
11805 (target-float.o): Add ECHO_CXX.
11806 (ada-exp.o): Add ECHO_CXX.
11807 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
11808 (insight$(EXEEXT)): Add ECHO_CXXLD.
11809 * gnulib/configure.ac: Add AM_SILENT_RULES.
11810 * gnulib/aclocal.m4: Re-generate.
11811 * gnulib/configure: Re-generate.
11812 * gnulib/import/Makefile.in: Re-generate.
11813
11814 2018-03-16 Tom Tromey <tom@tromey.com>
11815
11816 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
11817 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
11818 * utils.c (do_free_section_addr_info)
11819 (make_cleanup_free_section_addr_info): Remove.
11820 * symfile.h (struct other_sections): Add constructor.
11821 (struct section_addr_info): Remove.
11822 (section_addr_info): New typedef.
11823 (struct sym_fns) <sym_offsets>: Change type of parameter.
11824 (build_section_addr_info_from_objfile)
11825 (relative_addr_info_to_section_offsets, addr_info_make_relative)
11826 (default_symfile_offsets, symbol_file_add)
11827 (symbol_file_add_from_bfd)
11828 (build_section_addr_info_from_section_table): Update.
11829 (alloc_section_addr_info, free_section_addr_info): Don't declare.
11830 * symfile.c (alloc_section_addr_info): Remove.
11831 (build_section_addr_info_from_section_table): Change return type.
11832 Update.
11833 (build_section_addr_info_from_bfd)
11834 (build_section_addr_info_from_objfile): Likewise.
11835 (free_section_addr_info): Remove.
11836 (relative_addr_info_to_section_offsets): Change type of "addrs".
11837 (addrs_section_compar): Now a std::sort comparator.
11838 (addrs_section_sort): Change return type.
11839 (addr_info_make_relative): Change type of "addrs". Update.
11840 (default_symfile_offsets, syms_from_objfile_1)
11841 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
11842 (symbol_file_add_separate): Update.
11843 (symbol_file_add): Change type of "addrs". Update.
11844 (add_symbol_file_command): Update. Remove cleanups.
11845 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
11846 cleanups.
11847 * symfile-debug.c (debug_sym_offsets): Change type of "info".
11848 * solib.c (solib_read_symbols): Update.
11849 * objfiles.c (objfile_relocate): Update. Remove cleanups.
11850 * machoread.c (macho_symfile_offsets): Update.
11851 * jit.c (jit_bfd_try_read_symtab): Update.
11852
11853 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
11854
11855 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11856 unittests/utils-selftests.c.
11857 * unittests/utils-selftests.c: New file.
11858
11859 2018-03-14 Tom Tromey <tom@tromey.com>
11860
11861 PR cli/14977:
11862 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
11863 for NULL.
11864
11865 2018-03-14 Tom Tromey <tom@tromey.com>
11866
11867 PR cli/19918:
11868 * printcmd.c (printf_pointer): Allow "-" in format.
11869
11870 2018-03-14 Tom Tromey <tom@tromey.com>
11871
11872 * printcmd.c (_initialize_printcmd): Add usage to printf.
11873
11874 2018-03-14 Yao Qi <qiyao@sourceware.org>
11875
11876 * MAINTAINERS: Update my email address.
11877
11878 2018-03-13 Tom Tromey <tom@tromey.com>
11879
11880 * machoread.c (macho_check_dsym): Change filenamep to a
11881 std::string*.
11882 (macho_symfile_read): Update.
11883 * symfile.c (load_command): Use std::string.
11884
11885 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
11886
11887 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
11888 to error message string.
11889 (riscv_register_name): Use xsnprintf instead of sprintf.
11890 (riscv_insn::fetch_instruction): Use gdb_assert instead of
11891 internal_error.
11892 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
11893 error.
11894 (riscv_push_dummy_call): Likewise.
11895
11896 2018-03-12 Tom Tromey <tom@tromey.com>
11897
11898 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
11899 Use gdb::byte_vector.
11900 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
11901
11902 2018-03-12 Yao Qi <yao.qi@linaro.org>
11903
11904 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
11905 parameter type to readable_regcache.
11906 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
11907 the declaration.
11908
11909 2018-03-11 Tom Tromey <tom@tromey.com>
11910
11911 * dwarf2read.c (struct nextfield): Add initializers.
11912 (struct nextfnfield): Remove.
11913 (struct fnfieldlist): Add initializers. Remove "length" and
11914 "head", use std::vector.
11915 (struct decl_field_list): Remove.
11916 (struct field_info): Add initializers.
11917 <fields, baseclasses>: Now std::vector.
11918 <nbaseclasses, nfnfields, typedef_field_list_count,
11919 nested_types_list_count>: Remove.
11920 (dwarf2_add_field, dwarf2_add_type_defn)
11921 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
11922 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
11923 (process_structure_scope): Update.
11924
11925 2018-03-11 Tom Tromey <tom@tromey.com>
11926
11927 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
11928 for use by std::sort.
11929 (build_type_psymtabs_1): Use std::vector.
11930
11931 2018-03-09 Eli Zaretskii <eliz@gnu.org>
11932
11933 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
11934 and LIBMPFR in the printed configuration.
11935
11936 2018-03-08 Tom Tromey <tom@tromey.com>
11937
11938 * source.c (get_filename_and_charpos): Use scoped_fd.
11939 * nto-procfs.c (procfs_open_1): Use scoped_fd.
11940 (procfs_pidlist): Likewise.
11941 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
11942 (iterate_over_mappings): Likewise.
11943
11944 2018-03-08 Tom Tromey <tom@tromey.com>
11945
11946 * infcall.c (struct call_return_meta_info)
11947 <stack_temporaries_enabled>: Remove.
11948 (get_call_return_value, call_function_by_hand_dummy): Update.
11949 * thread.c (disable_thread_stack_temporaries): Remove.
11950 (enable_thread_stack_temporaries): Remove.
11951 (thread_stack_temporaries_enabled_p): Return bool.
11952 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
11953 (get_last_thread_stack_temporary): Update.
11954 * eval.c (evaluate_subexp): Update.
11955 * gdbthread.h (class enable_thread_stack_temporaries): Now a
11956 class, not a function.
11957 (value_ptr, value_vec): Remove typedefs.
11958 (class thread_info) <stack_temporaries_enabled>: Now bool.
11959 <stack_temporaries>: Now a std::vector.
11960 (thread_stack_temporaries_enabled_p)
11961 (value_in_thread_stack_temporaries): Return bool.
11962
11963 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
11964
11965 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11966 (getpkt_or_notif_sane_1): Likewise.
11967
11968 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11969
11970 * build-id.c (build_id_to_debug_bfd): Use std::string.
11971
11972 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11973
11974 * build-id.c (find_separate_debug_file_by_buildid): Return
11975 std::string.
11976 * build-id.h (find_separate_debug_file_by_buildid): Return
11977 std::string.
11978 * coffread.c (coff_symfile_read): Adjust to std::string.
11979 * elfread.c (elf_symfile_read): Adjust to std::string.
11980 * symfile.c (separate_debug_file_exists): Change parameter to
11981 std::string.
11982 (find_separate_debug_file): Return std::string.
11983 (find_separate_debug_file_by_debuglink): Return std::string.
11984 * symfile.h (find_separate_debug_file_by_debuglink): Return
11985 std::string.
11986
11987 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11988
11989 * common/xml-utils.c (xml_escape_text): Move code to...
11990 (xml_escape_text_append): ... this new function.
11991 * common/xml-utils.h (xml_escape_text_append): New declaration.
11992 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11993 New function.
11994 (_initialize_xml_utils): register test_xml_escape_text_append as
11995 a selftest.
11996
11997 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11998
11999 * defs.h: Remove MAX_REGISTER_SIZE.
12000 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
12001 asserts.
12002 * python/py-unwind.c (pyuw_sniffer): Likewise.
12003
12004 2018-03-07 Tom Tromey <tom@tromey.com>
12005
12006 * linux-tdep.c (linux_info_proc): Update.
12007 * target.h (struct target_ops) <to_fileio_readlink>: Return
12008 optional<string>.
12009 (target_fileio_readlink): Return optional<string>.
12010 * remote.c (remote_hostio_readlink): Return optional<string>.
12011 * inf-child.c (inf_child_fileio_readlink): Return
12012 optional<string>.
12013 * target.c (target_fileio_readlink): Return optional<string>.
12014
12015 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
12016
12017 * regcache.c (cooked_read_test): Add riscv to the list of
12018 architectures that have a save_reggroup.
12019
12020 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
12021
12022 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
12023 value is not a dynamic class object.
12024
12025 2018-03-06 Tom Tromey <tom@tromey.com>
12026
12027 * rust-exp.y: Formatting fixes.
12028
12029 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12030
12031 * riscv-tdep.c (riscv_register_name): Remove target description
12032 support.
12033 (riscv_gdbarch_init): Remove target description check.
12034
12035 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12036
12037 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
12038 comment.
12039 * riscv-tdep.h: Likewise.
12040
12041 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12042
12043 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
12044 (riscv_pseudo_register_write): Delete.
12045 (riscv_gdbarch_init): Remove all use of pseudo registers.
12046
12047 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12048
12049 * record-btrace.c (btrace_print_lines): Replace cleanup
12050 parameter with RAII equivalents.
12051 (btrace_insn_history): Replace cleanup with RAII equivalents.
12052 * ui-out.h (make_cleanup_ui_out_list_begin_end,
12053 make_cleanup_ui_out_tuple_begin_end): Remove.
12054 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
12055 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
12056 make_cleanup_ui_out_list_begin_end): Remove.
12057
12058 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12059
12060 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
12061 parameter types to std::vector. Use bool.
12062 (record_btrace_wait): Replace VEC(tp_t) with
12063 std::vector<thread_info *>.
12064 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
12065
12066 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12067
12068 * record-btrace.c (record_btrace_disable_callback): Remove.
12069 (struct scoped_btrace_disable): New.
12070 (record_btrace_open): Use scoped_btrace_disable.
12071
12072 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12073
12074 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
12075 reading values from registers.
12076
12077 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12078
12079 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
12080 where appropriate.
12081
12082 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12083
12084 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
12085 change parameter type. Use GDB's print functions, and use
12086 core_addr_to_string where appropriate.
12087 (riscv_push_dummy_call): Use core_addr_to_string where
12088 appropriate, update call to riscv_print_arg_location, and reindent
12089 a few lines.
12090 (riscv_return_value): Update call to riscv_print_arg_location.
12091
12092 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12093 Tim Newsome <tim@sifive.com>
12094 Albert Ou <a0u@eecs.berkeley.edu>
12095 Darius Rad <darius@bluespec.com>
12096
12097 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
12098 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
12099 (ALLDEPFILES): Add riscv-tdep.c
12100 * configure.tgt: Add riscv support.
12101 * riscv-tdep.c: New file.
12102 * riscv-tdep.h: New file.
12103 * NEWS: Mention new target.
12104 * MAINTAINERS: Add entry for riscv.
12105
12106 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12107
12108 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
12109 fields within aggregates.
12110
12111 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
12112
12113 * record-btrace.c (btrace_print_lines): Change type of flags to
12114 gdb_disassembly_flags.
12115
12116 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12117
12118 * fbsd-nat.c: Include "inf-ptrace.h".
12119 (USE_SIGTRAP_SIGINFO): Conditionally define.
12120 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
12121 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
12122 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
12123 function.
12124 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
12125 Likewise.
12126 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
12127 Likewise.
12128 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
12129 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
12130 "supports_stopped_by_hw_breakpoint" target methods.
12131
12132 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12133
12134 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
12135 * fbsd-nat.c (debug_fbsd_nat): New variable.
12136 (show_fbsd_nat_debug): New function.
12137 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
12138 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
12139
12140 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12141
12142 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
12143 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
12144 prototype.
12145 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
12146 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
12147 method.
12148
12149 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12150
12151 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
12152 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
12153
12154 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12155
12156 * charset.c (struct charset_vector): New.
12157 (charsets): Change type to charset_vector.
12158 (find_charset_names): Adjust.
12159 (add_one): Adjust.
12160 (_initialize_charset): Adjust.
12161
12162 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12163
12164 * progspace.h (struct program_space) <deleted_solibs>: Change
12165 type to std::vector<std::string>.
12166 * progspace.c (clear_program_space_solib_cache): Adjust.
12167 * breakpoint.c (print_solib_event): Adjust.
12168 (check_status_catch_solib): Adjust.
12169 * solib.c (update_solib_list): Adjust.
12170 * ui-out.h (class ui_out) <field_string>: New overload.
12171 * ui-out.c (ui_out::field_string): New overload.
12172
12173 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12174
12175 * progspace.h (struct program_space): Add constructor and
12176 destructor, initialize fields.
12177 (add_program_space): Remove.
12178 * progspace.c (add_program_space): Rename to...
12179 (program_space::program_space): ... this.
12180 (release_program_space): Rename to...
12181 (program_space::~program_space): ... this.
12182 (delete_program_space): Use delete to delete program_space.
12183 (initialize_progspace): Use new to allocate program_space.
12184 * inferior.c (add_inferior_with_spaces): Likewise.
12185 (clone_inferior_command): Likewise.
12186 * infrun.c (follow_fork_inferior): Likewise.
12187 (handle_vfork_child_exec_or_exit): Likewise.
12188
12189 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12190
12191 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
12192 (delim_string_to_char_ptr_vec): Return std::vector of
12193 gdb::unique_xmalloc_ptr.
12194 (dirnames_to_char_ptr_vec_append): Take std::vector of
12195 gdb::unique_xmalloc_ptr.
12196 (dirnames_to_char_ptr_vec): Return std::vector of
12197 gdb::unique_xmalloc_ptr.
12198 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
12199 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
12200 (delim_string_to_char_ptr_vec): Return an std::vector of
12201 gdb::unique_xmalloc_ptr, adjust the code.
12202 (dirnames_to_char_ptr_vec_append): Take an std::vector of
12203 gdb::unique_xmalloc_ptr, adjust the code.
12204 (dirnames_to_char_ptr_vec): Return an std::vector of
12205 gdb::unique_xmalloc_ptr, adjust the code.
12206 * auto-load.c (auto_load_safe_path_vec): Change type to
12207 std::vector of gdb::unique_xmalloc_ptr.
12208 (auto_load_expand_dir_vars): Return an std::vector of
12209 gdb::unique_xmalloc_ptr, adjust the code.
12210 (auto_load_safe_path_vec_update): Adjust.
12211 (filename_is_in_auto_load_safe_path_vec): Adjust.
12212 (auto_load_objfile_script_1): Adjust.
12213 * build-id.c (build_id_to_debug_bfd): Adjust.
12214 * linux-thread-db.c (thread_db_load_search): Adjust.
12215 * source.c (add_path): Adjust.
12216 (openp): Adjust.
12217 * symfile.c (find_separate_debug_file): Adjust.
12218 * utils.c (do_free_char_ptr_vec): Remove.
12219 (make_cleanup_free_char_ptr_vec): Remove.
12220
12221 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
12222
12223 PR gdb/22907
12224 * common/pathstuff.c: Conditionally include "<windows.h>".
12225
12226 2018-03-01 Georg Sauthoff <mail@georg.so>
12227
12228 PR gdb/22888
12229 * gcore.in: Quote variables and switch interpreter to bash.
12230
12231 2018-03-01 Tom Tromey <tom@tromey.com>
12232
12233 * dwarf2read.c (alloc_discriminant_info): Fix default_index
12234 assertion. Add assertion for discriminant_index.
12235 (quirk_rust_enum): Use correct base type name in univariant case.
12236
12237 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
12238
12239 * record.c (get_call_history_modifiers): Return a
12240 record_print_flags.
12241 (cmd_record_call_history): Adjust.
12242 * record-btrace.c (record_btrace_call_history): Adjust.
12243 (record_btrace_call_history_range): Adjust.
12244 (record_btrace_call_history_from): Adjust.
12245 * target-debug.h (target_debug_print_record_print_flags): New.
12246 * target-delegates.c: Re-generate.
12247 * target.c (target_call_history): Change flags type.
12248 (target_call_history_from): Likewise.
12249 (target_call_history_range): Likewise.
12250 * target.h (struct target_ops) <target_call_history>: Likewise.
12251 (target_call_history_from): Likewise.
12252 (target_call_history_range): Likewise.
12253
12254 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12255 Simon Marchi <simon.marchi@polymtl.ca>
12256
12257 * common/common-utils.c: Include "sys/stat.h".
12258 (is_regular_file): Move here from "source.c"; change return
12259 type to "bool".
12260 * common/common-utils.h (is_regular_file): New prototype.
12261 * common/pathstuff.c (contains_dir_separator): New function.
12262 * common/pathstuff.h (contains_dir_separator): New prototype.
12263 * source.c: Don't include "sys/stat.h".
12264 (is_regular_file): Move to "common/common-utils.c".
12265
12266 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12267
12268 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
12269 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
12270 * auto-load.c: Include "common/pathstuff.h".
12271 * common/common-def.h (current_directory): Move here.
12272 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
12273 function.
12274 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
12275 prototype.
12276 * common/pathstuff.c: New file.
12277 * common/pathstuff.h: New file.
12278 * compile/compile.c: Include "common/pathstuff.h".
12279 * defs.h (current_directory): Move to "common/common-defs.h".
12280 * dwarf2read.c: Include "common/pathstuff.h".
12281 * exec.c: Likewise.
12282 * guile/scm-safe-call.c: Likewise.
12283 * linux-thread-db.c: Likewise.
12284 * main.c: Likewise.
12285 * nto-tdep.c: Likewise.
12286 * objfiles.c: Likewise.
12287 * source.c: Likewise.
12288 * symtab.c: Likewise.
12289 * utils.c: Include "common/pathstuff.h".
12290 (gdb_realpath): Move to "common/pathstuff.c".
12291 (gdb_realpath_keepfile): Likewise.
12292 (gdb_abspath): Likewise.
12293 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
12294 (gdb_realpath_keepfile): Likewise.
12295 (gdb_abspath): Likewise.
12296
12297 2018-02-28 John Baldwin <jhb@FreeBSD.org>
12298
12299 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
12300 wildcard process pid for super_resume for kernels with a
12301 specific bug.
12302
12303 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
12304
12305 * compile/compile.c (get_args): Add additional comments
12306 explaining function.
12307
12308 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
12309 Tom Tromey <tom@tromey.com>
12310
12311 * target.h (memory_write_request_s): Remove typedef. Don't define
12312 VEC.
12313 (target_write_memory_blocks): Change argument to std::vector.
12314 (struct memory_write_request): Add constructor.
12315 * target-memory.c (compare_block_starting_address): Return bool.
12316 Change argument types.
12317 (claim_memory): Change arguments to use std::vector.
12318 (split_regular_and_flash_blocks, blocks_to_erase)
12319 (compute_garbled_blocks): Likewise.
12320 (cleanup_request_data, cleanup_write_requests_vector): Remove.
12321 (target_write_memory_blocks): Change argument to std::vector.
12322 * symfile.c (struct load_section_data): Add constructor and
12323 destructor. Use std::vector for "requests".
12324 (struct load_progress_data): Add initializers.
12325 (load_section_callback): Update. Use "new".
12326 (clear_memory_write_data): Remove.
12327 (generic_load): Update.
12328
12329 2018-02-27 Alan Hayward <alan.hayward@arm.com>
12330
12331 * arch/aarch64.h: Use common/tdesc.h.
12332
12333 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12334
12335 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
12336 architecture with a 64-bit ABI.
12337
12338 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12339
12340 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
12341 ahead of target description loading.
12342
12343 2018-02-26 Tom Tromey <tom@tromey.com>
12344
12345 * stack.c (backtrace_command_1): Update.
12346 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
12347 of "flags".
12348 * python/py-framefilter.c (py_print_frame)
12349 (gdbpy_apply_frame_filter): Change type of "flags".
12350 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
12351 of "flags".
12352 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
12353 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
12354 * extension.h (enum frame_filter_flag): Rename from
12355 frame_filter_flags.
12356 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
12357 (apply_ext_lang_frame_filter): Change type of "flags".
12358 * extension.c (apply_ext_lang_frame_filter): Change type of
12359 "flags".
12360 * extension-priv.h (struct extension_language_ops)
12361 <apply_frame_filter>: Change type of "flags".
12362
12363 2018-02-26 Tom Tromey <tom@tromey.com>
12364
12365 PR python/16497:
12366 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
12367 off-by-one in py_end computation.
12368 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
12369 PRINT_MORE_FRAMES.
12370 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
12371 constant.
12372
12373 2018-02-26 Tom Tromey <tom@tromey.com>
12374
12375 * dwarf2read.c (struct variant_field): New.
12376 (struct nextfield) <variant>: New field.
12377 (dwarf2_add_field): Handle DW_TAG_variant_part.
12378 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
12379 discriminated union.
12380 (read_structure_type): Handle DW_TAG_variant_part.
12381 (handle_struct_member_die): New function, extracted from
12382 process_structure_scope. Handle DW_TAG_variant.
12383 (process_structure_scope): Handle discriminated unions. Call
12384 handle_struct_member_die.
12385
12386 2018-02-26 Tom Tromey <tom@tromey.com>
12387
12388 * rust-lang.h (rust_last_path_segment): Declare.
12389 * rust-lang.c (rust_last_path_segment): Now public. Change
12390 contract.
12391 (struct disr_info): Remove.
12392 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
12393 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
12394 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
12395 (rust_enum_p, rust_enum_variant): New function.
12396 (rust_underscore_fields): Remove "offset" parameter.
12397 (rust_print_enum): New function.
12398 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
12399 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
12400 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
12401 enums.
12402 (rust_internal_print_type): New function, from rust_print_type.
12403 Remove enum code.
12404 (rust_print_type): Call rust_internal_print_type.
12405 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
12406 Update enum handling.
12407 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
12408 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
12409 (rust_union_quirks): New functions.
12410 (process_full_comp_unit, process_full_type_unit): Call
12411 rust_union_quirks.
12412 (process_structure_scope): Update rust_unions if necessary.
12413
12414 2018-02-26 Tom Tromey <tom@tromey.com>
12415
12416 * value.h (value_union_variant): Declare.
12417 * valops.c (value_union_variant): New function.
12418 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
12419 (struct discriminant_info): New.
12420 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
12421 enumerator.
12422 (struct main_type) <flag_discriminated_union>: New field.
12423
12424 2018-02-26 Tom Tromey <tom@tromey.com>
12425
12426 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12427 unittests/unpack-selftests.c.
12428 * unittests/unpack-selftests.c: New file.
12429 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
12430
12431 2018-02-26 Yao Qi <yao.qi@linaro.org>
12432
12433 * dwarf2read.c (struct partial_die_info) <read>: New method.
12434 (read_partial_die): Remove the declaration.
12435 (load_partial_dies): Update.
12436 (partial_die_info::partial_die_info):
12437 (read_partial_die): Change it to partial_die_info::read.
12438
12439 2018-02-26 Yao Qi <yao.qi@linaro.org>
12440
12441 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
12442 (fixup_partial_die): Remove declaration.
12443 (scan_partial_symbols): Update.
12444 (partial_die_parent_scope): Likewise.
12445 (partial_die_full_name): Likewise.
12446 (fixup_partial_die): Change it to partial_die_info::fixup.
12447
12448 2018-02-26 Yao Qi <yao.qi@linaro.org>
12449
12450 * dwarf2read.c (read_partial_die): Update the declaration.
12451 (load_partial_dies): Caller update.
12452 (read_partial_die): Remove one argument abbrev_len.
12453
12454 2018-02-26 Yao Qi <yao.qi@linaro.org>
12455
12456 * dwarf2read.c (struct partial_die_info): Add ctor, delete
12457 assignment operator.
12458 (load_partial_dies): Use ctor and copy ctor.
12459 (read_partial_die): Update.
12460 (dwarf2_cu::find_partial_die): Use ctor.
12461
12462 2018-02-26 Yao Qi <yao.qi@linaro.org>
12463
12464 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
12465 (find_partial_die_in_comp_unit): Change it to
12466 dwarf2_cu::find_partial_die.
12467 (find_partial_die): Update.
12468
12469 2018-02-26 Yao Qi <yao.qi@linaro.org>
12470
12471 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
12472 is NULL.
12473
12474 2018-02-26 Yao Qi <yao.qi@linaro.org>
12475
12476 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
12477
12478 2018-02-26 Alan Hayward <alan.hayward@arm.com>
12479
12480 * arch/amd64.h: Use common/tdesc.h.
12481 * arch/i386.c: Likewise.
12482 * arch/i386.h: Likewise.
12483 * arch/tic6x.c: Likewise.
12484 * arch/tdesc.h: Move file from here...
12485 * common/tdesc.h: ...to here.
12486 * features/aarch64-core.c: Regenerate.
12487 * features/aarch64-fpu.c: Regenerate.
12488 * features/i386/32bit-avx.c: Regenerate.
12489 * features/i386/32bit-avx512.c: Regenerate.
12490 * features/i386/32bit-core.c: Regenerate.
12491 * features/i386/32bit-linux.c: Regenerate.
12492 * features/i386/32bit-mpx.c: Regenerate.
12493 * features/i386/32bit-pkeys.c: Regenerate.
12494 * features/i386/32bit-sse.c: Regenerate.
12495 * features/i386/64bit-avx.c: Regenerate.
12496 * features/i386/64bit-avx512.c: Regenerate.
12497 * features/i386/64bit-core.c: Regenerate.
12498 * features/i386/64bit-linux.c: Regenerate.
12499 * features/i386/64bit-mpx.c: Regenerate.
12500 * features/i386/64bit-pkeys.c: Regenerate.
12501 * features/i386/64bit-segments.c: Regenerate.
12502 * features/i386/64bit-sse.c: Regenerate.
12503 * features/i386/x32-core.c: Regenerate.
12504 * features/tic6x-c6xp.c: Regenerate.
12505 * features/tic6x-core.c: Regenerate.
12506 * features/tic6x-gp.c: Regenerate.
12507 * target-descriptions.c: Use common/tdesc.h.
12508 * target-descriptions.h: Likewise.
12509
12510 2018-02-24 Tom Tromey <tom@tromey.com>
12511
12512 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
12513 (try_thread_db_load_from_dir, thread_db_load_search): Use
12514 std::string.
12515 (info_auto_load_libthread_db_compare): Return bool. Change
12516 argument types.
12517 (info_auto_load_libthread_db): Use std::vector, std::string.
12518 Remove cleanups.
12519
12520 2018-02-24 Tom Tromey <tom@tromey.com>
12521
12522 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
12523 std::string.
12524 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
12525 std::string*.
12526 * gdbarch.c: Rebuild.
12527 * gdbarch.h: Rebuild.
12528 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
12529 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
12530 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
12531 std::string*.
12532
12533 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
12534
12535 * gdbtypes.h (sect_offset): Change type to uint64_t.
12536 (sect_offset_str): New function.
12537 * dwarf2read.c (create_addrmap_from_aranges): Use
12538 sect_offset_str.
12539 (error_check_comp_unit_head): Likewise.
12540 (create_debug_type_hash_table): Likewise.
12541 (read_cutu_die_from_dwo): Likewise.
12542 (init_cutu_and_read_dies): Likewise.
12543 (init_cutu_and_read_dies_no_follow): Likewise.
12544 (process_psymtab_comp_unit_reader): Likewise.
12545 (partial_die_parent_scope): Likewise.
12546 (peek_die_abbrev): Likewise.
12547 (process_queue): Likewise.
12548 (dwarf2_physname): Likewise.
12549 (read_namespace_alias): Likewise.
12550 (read_import_statement): Likewise.
12551 (create_dwo_cu_reader): Likewise.
12552 (create_cus_hash_table): Likewise.
12553 (lookup_dwo_cutu): Likewise.
12554 (inherit_abstract_dies): Likewise.
12555 (read_func_scope): Likewise.
12556 (read_call_site_scope): Likewise.
12557 (dwarf2_add_member_fn): Likewise.
12558 (read_common_block): Likewise.
12559 (read_module_type): Likewise.
12560 (read_typedef): Likewise.
12561 (read_subrange_type): Likewise.
12562 (load_partial_dies): Likewise.
12563 (read_partial_die): Likewise.
12564 (find_partial_die): Likewise.
12565 (read_str_index): Likewise.
12566 (dwarf2_string_attr): Likewise.
12567 (build_error_marker_type): Likewise.
12568 (lookup_die_type): Likewise.
12569 (dump_die_shallow): Likewise.
12570 (follow_die_ref): Likewise.
12571 (dwarf2_fetch_die_loc_sect_off): Likewise.
12572 (dwarf2_fetch_constant_bytes): Likewise.
12573 (follow_die_sig): Likewise.
12574 (get_signatured_type): Likewise.
12575 (get_DW_AT_signature_type): Likewise.
12576 (dwarf2_find_containing_comp_unit): Likewise.
12577 (set_die_type): Likewise.
12578
12579 2018-02-21 John Baldwin <jhb@FreeBSD.org>
12580
12581 * arch/aarch64.c: Include "common-defs.h".
12582 * arch/amd64.c: Likewise.
12583 * arch/i386.c: Likewise.
12584
12585 2018-02-21 Tom Tromey <tom@tromey.com>
12586
12587 * value.h: (extract_field_op): Update.
12588 * eval.c (extract_field_op): Return a const char *.
12589 * expression.h (parse_expression_for_completion): Update.
12590 * completer.c (complete_expression): Update.
12591 (add_struct_fields): Make fieldname const.
12592 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
12593 (mark_completion_tag, parse_exp_in_context_1): Update.
12594 (parse_expression_for_completion): Change "name" to
12595 unique_xmalloc_ptr*.
12596
12597 2018-02-21 Tom Tromey <tom@tromey.com>
12598
12599 * infcall.c (call_function_by_hand_dummy): Use std::vector.
12600
12601 2018-02-21 Yao Qi <yao.qi@linaro.org>
12602
12603 * avr-tdep.c (avr_read_pc): Change parameter type to
12604 readable_regcache.
12605 * gdbarch.sh (read_pc): Likewise.
12606 * gdbarch.c: Re-generated.
12607 * gdbarch.h: Re-generated.
12608 * hppa-tdep.c (hppa_read_pc): Change parameter type to
12609 readable_regcache.
12610 * ia64-tdep.c (ia64_read_pc): Likewise.
12611 * mips-tdep.c (mips_read_pc): Likewise.
12612 * spu-tdep.c (spu_read_pc): Likewise.
12613
12614 2018-02-21 Yao Qi <yao.qi@linaro.org>
12615
12616 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
12617 * regcache-dump.c: New file.
12618 * regcache.c: Move register_dump to regcache-dump.c.
12619 (maintenance_print_registers): Likewise.
12620 (maintenance_print_raw_registers): Likewise.
12621 (maintenance_print_cooked_registers): Likewise.
12622 (maintenance_print_register_groups): Likewise.
12623 (maintenance_print_remote_registers): Likewise.
12624 (_initialize_regcache): Likewise.
12625 * regcache.h (register_dump): Moved from regcache.c.
12626
12627 2018-02-21 Yao Qi <yao.qi@linaro.org>
12628
12629 * regcache.c (regcache::regcache): Update.
12630 (regcache::invalidate): Move it to detached_regcache::invalidate.
12631 (get_thread_arch_aspace_regcache): Update.
12632 (regcache::raw_update): Update.
12633 (regcache::cooked_read): Remove some code.
12634 (regcache::cooked_read_value): Likewise.
12635 (regcache::raw_write): Remove assert on m_readonly_p.
12636 (regcache::raw_supply_integer): Move it to
12637 detached_regcache::raw_supply_integer.
12638 (regcache::raw_supply_zeroed): Likewise.
12639 * regcache.h (detached_regcache) <raw_supply_integer>: New
12640 declaration.
12641 <raw_supply_zeroed, invalidate>: Likewise.
12642 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
12643 <invalidate>: Likewise.
12644 <m_readonly_p>: Removed.
12645
12646 2018-02-21 Yao Qi <yao.qi@linaro.org>
12647
12648 * infcmd.c (get_return_value): Let stop_regs point to
12649 get_current_regcache.
12650 * regcache.c (regcache::regcache): Remove.
12651 (register_dump_reg_buffer): New class.
12652 (regcache_print): Adjust.
12653 * regcache.h (regcache): Remove constructors.
12654
12655 2018-02-21 Yao Qi <yao.qi@linaro.org>
12656
12657 * regcache.c (class register_dump): New class.
12658 (register_dump_regcache, register_dump_none): New class.
12659 (register_dump_remote, register_dump_groups): New class.
12660 (regcache_print): Update.
12661 * regcache.h (regcache_dump_what): Move it to regcache.c.
12662 (regcache) <dump>: Remove.
12663
12664 2018-02-21 Yao Qi <yao.qi@linaro.org>
12665
12666 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
12667 reg_buffer_rw *.
12668 (jit_unwind_reg_set_impl): Call raw_supply.
12669 (jit_frame_sniffer): Use reg_buffer_rw.
12670 * record-full.c (record_full_core_regbuf): Change its type.
12671 (record_full_core_open_1): Use reg_buffer_rw.
12672 (record_full_close): Likewise.
12673 (record_full_core_fetch_registers): Use regcache->raw_supply.
12674 (record_full_core_store_registers): Likewise.
12675 * regcache.c (regcache::get_register_status): Move it to
12676 reg_buffer.
12677 (regcache_raw_set_cached_value): Remove.
12678 (regcache::raw_set_cached_value): Remove.
12679 (regcache::raw_write): Call raw_supply.
12680 (regcache::raw_supply): Move it to reg_buffer_rw.
12681 * regcache.h (regcache_raw_set_cached_value): Remove.
12682 (reg_buffer_rw): New class.
12683
12684 2018-02-21 Yao Qi <yao.qi@linaro.org>
12685
12686 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
12687 readonly_detached_regcache.
12688 (dummy_frame_prev_register): Use regcache->cooked_read.
12689 * frame.c (frame_save_as_regcache): Change return type.
12690 (frame_pop): Update.
12691 * frame.h (frame_save_as_regcache): Update declaration.
12692 * inferior.h (get_infcall_suspend_state_regcache): Update
12693 declaration.
12694 * infrun.c (infcall_suspend_state) <registers>: use
12695 readonly_detached_regcache.
12696 (save_infcall_suspend_state): Don't use regcache_dup.
12697 (get_infcall_suspend_state_regcache): Change return type.
12698 * linux-fork.c (struct fork_info) <savedregs>: Change to
12699 readonly_detached_regcache.
12700 <pc>: New field.
12701 (fork_save_infrun_state): Don't use regcache_dup.
12702 (info_checkpoints_command): Adjust.
12703 * mi/mi-main.c (register_changed_p): Update declaration.
12704 (mi_cmd_data_list_changed_registers): Use
12705 readonly_detached_regcache.
12706 (register_changed_p): Change parameter type to
12707 readonly_detached_regcache.
12708 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
12709 readonly_detached_regcache.
12710 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
12711 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
12712 New.
12713 (regcache::save): Move it to reg_buffer.
12714 (regcache::restore): Change parameter type.
12715 (regcache_dup): Remove.
12716 * regcache.h (reg_buffer) <save>: New method.
12717 (readonly_detached_regcache): New class.
12718 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
12719 readonly_detached_regcache.
12720 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
12721
12722 2018-02-21 Yao Qi <yao.qi@linaro.org>
12723
12724 * frame.c (frame_save_as_regcache): Use regcache method save.
12725 (frame_pop): Use regcache method restore.
12726 * infrun.c (restore_infcall_suspend_state): Likewise.
12727 * linux-fork.c (fork_load_infrun_state): Likewise.
12728 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
12729 save.
12730 * regcache.c (regcache_save): Remove.
12731 (regcache::restore): More asserts.
12732 (regcache_cpy): Remove.
12733 * regcache.h (regcache_save): Remove the declaration.
12734 (regcache::restore): Move from private to public.
12735 Remove the friend declaration of regcache_cpy.
12736 (regcache_cpy): Remove declaration.
12737
12738 2018-02-21 Yao Qi <yao.qi@linaro.org>
12739
12740 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
12741 parameter type to 'readable_regcache *'.
12742 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12743 * arm-tdep.c (arm_neon_quad_read): Likewise.
12744 (arm_pseudo_read): Likewise.
12745 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12746 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12747 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12748 * gdbarch.c: Re-generated.
12749 * gdbarch.h: Re-generated.
12750 * gdbarch.sh (pseudo_register_read): Change parameter type to
12751 'readable_regcache *'.
12752 (pseudo_register_read_value): Likewise.
12753 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
12754 (h8300_pseudo_register_read): Likewise.
12755 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
12756 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12757 (i386_pseudo_register_read_into_value): Likewise.
12758 (i386_pseudo_register_read_value): Likewise.
12759 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
12760 declaration.
12761 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
12762 * m32c-tdep.c (m32c_raw_read): Likewise.
12763 (m32c_read_flg): Likewise.
12764 (m32c_banked_register): Likewise.
12765 (m32c_banked_read): Likewise.
12766 (m32c_sb_read): Likewise.
12767 (m32c_part_read): Likewise.
12768 (m32c_cat_read): Likewise.
12769 (m32c_r3r2r1r0_read): Likewise.
12770 (m32c_pseudo_register_read): Likewise.
12771 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12772 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12773 (mep_pseudo_cr64_read): Likewise.
12774 (mep_pseudo_register_read): Likewise.
12775 * mips-tdep.c (mips_pseudo_register_read): Likewise.
12776 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12777 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12778 * regcache.c (regcache::raw_read): Move it to readable_regcache.
12779 (regcache::cooked_read): Likewise.
12780 (regcache::cooked_read_value): Likewise.
12781 (regcache_cooked_read_signed):
12782 (regcache::cooked_read): Likewise.
12783 * regcache.h (readable_regcache): New class.
12784 (regcache): Inherit readable_regcache. Move some methods to
12785 readable_regcache.
12786 * rl78-tdep.c (rl78_pseudo_register_read): Change
12787 parameter type to 'readable_regcache *'.
12788 * rs6000-tdep.c (do_regcache_raw_read): Remove.
12789 (e500_pseudo_register_read): Change parameter type to
12790 'readable_regcache *'.
12791 (dfp_pseudo_register_read): Likewise.
12792 (vsx_pseudo_register_read): Likewise.
12793 (efpr_pseudo_register_read): Likewise.
12794 * s390-tdep.c (s390_pseudo_register_read): Likewise.
12795 * sh-tdep.c (sh_pseudo_register_read): Likewise.
12796 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
12797 (sh64_pseudo_register_read): Likewise.
12798 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12799 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12800 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12801 (spu_pseudo_register_read): Likewise.
12802 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12803 (xtensa_pseudo_register_read): Likewise.
12804
12805 2018-02-21 Yao Qi <yao.qi@linaro.org>
12806
12807 * regcache.c (regcache::regcache): Call reg_buffer ctor.
12808 (regcache::arch): Move it to reg_buffer::arch.
12809 (regcache::register_buffer): Likewise.
12810 (regcache::assert_regnum): Likewise.
12811 (regcache::num_raw_registers): Likewise.
12812 * regcache.h (reg_buffer): New class.
12813 (regcache): Inherit reg_buffer.
12814
12815 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
12816
12817 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
12818 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
12819
12820 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
12821
12822 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
12823
12824 2018-02-19 Alan Hayward <alan.hayward@arm.com>
12825
12826 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
12827 (SFILES): Remove common/*.c files.
12828 (COMMON_OBS): Remove some *.o files built from common/*.c files.
12829 * common/common.host: Add common reference.
12830 * configure.ac: Likewise.
12831 * configure: Regenerate.
12832
12833 2018-02-16 Yao Qi <yao.qi@linaro.org>
12834
12835 * block.c (block_namespace_info): Inherit allocate_on_obstack.
12836 (block_initialize_namespace): Use new.
12837 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
12838 (dwarf2_free_objfile): Use delete.
12839 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
12840 (copy_type_recursive): Use new.
12841 * gdb_obstack.h (allocate_on_obstack): New.
12842
12843 2018-02-15 Yao Qi <yao.qi@linaro.org>
12844
12845 PR gdb/22849
12846 * inferior.c (exit_inferior_1): Reset inf->control.
12847
12848 2018-02-15 Joel Brobecker <brobecker@adacore.com>
12849
12850 * ada-lang.c (ada_to_fixed_value_create): Delete advance
12851 declaration.
12852
12853 2018-02-14 Pedro Alves <palves@redhat.com>
12854
12855 * frame-unwind.c (frame_unwind_try_unwinder): Always call
12856 frame_cleanup_after_sniffer on exception.
12857
12858 2018-02-14 Tom Tromey <tom@tromey.com>
12859
12860 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
12861 const.
12862 (solib_bfd_open): Make pathname const.
12863 * solib.c (solib_bfd_open): Make pathname const.
12864 * solib-spu.c (spu_bfd_fopen): Make name const.
12865 (spu_bfd_open): Make pathname const.
12866 * solib-darwin.c (darwin_bfd_open): Make pathname const.
12867 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
12868
12869 2018-02-14 Tom Tromey <tom@tromey.com>
12870
12871 * symfile.c (symfile_bfd_open): Update.
12872 * source.h (openp, source_full_path_of, find_and_open_source):
12873 Change argument type to unique_xmalloc_ptr.
12874 * source.c (openp): Take a unique_xmalloc_ptr.
12875 (source_full_path_of, find_and_open_source): Likewise.
12876 (open_source_file, symtab_to_fullname): Update.
12877 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
12878 unique_xmalloc_ptr.
12879 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
12880 (exec_file_find): Update.
12881 * psymtab.c (psymtab_to_fullname): Update.
12882 * nto-tdep.h (nto_find_and_open_solib): Update.
12883 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
12884 unique_xmalloc_ptr.
12885 * exec.c (exec_file_attach): Update.
12886 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
12887 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
12888
12889 2018-02-14 Tom Tromey <tom@tromey.com>
12890
12891 * solib.c: Include source.h.
12892 * nto-tdep.c: Include source.h.
12893 * mi/mi-cmd-env.c: Include source.h.
12894 * infcmd.c: Include source.h.
12895 * exec.c: Include source.h.
12896 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
12897 (add_path, directory_switch, source_path, init_source_path): Move
12898 declarations...
12899 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
12900 (add_path, directory_switch, source_path, init_source_path):
12901 ...here.
12902
12903 2018-02-14 Tom Tromey <tom@tromey.com>
12904
12905 * solist.h (exec_file_find, solib_find): Return
12906 unique_xmalloc_ptr.
12907 (solib_bfd_fopen): Take a const char *.
12908 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
12909 (exec_file_find, solib_find): Likewise.
12910 (solib_bfd_fopen): Do not take ownership of "pathname".
12911 (solib_bfd_open): Use unique_xmalloc_ptr.
12912 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
12913 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
12914 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
12915 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
12916
12917 2018-02-14 Joel Brobecker <brobecker@adacore.com>
12918
12919 * ada-lang.c (name_match_type_from_name): Remove reference to
12920 ada_name_for_lookup in function's documentation.
12921 * ada-lang.h (ada_name_for_lookup): Delete declaration.
12922
12923 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12924
12925 * defs.h (enum openp_flags): New enum.
12926 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
12927 Move to enum openp_flags.
12928 (openp_flags): New enum flags.
12929 (openp): Change parameter type to openp_flags.
12930 * source.c (openp): Change parameter type to openp_flags.
12931 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
12932 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
12933
12934 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12935
12936 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
12937 per-command.
12938
12939 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
12940
12941 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
12942 into...
12943 (class dwarf2_queue_guard): ...the destructor of this new class.
12944 (dw2_do_instantiate_symtab): Create instance of the new class
12945 dwarf2_queue_guard, remove cleanup.
12946
12947 2018-02-09 Tom Tromey <tom@tromey.com>
12948
12949 * source.c (find_source_lines): Don't reference past the end of
12950 the vector.
12951
12952 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12953
12954 * remote.c (remote_btrace_maybe_reopen): Change error message.
12955 * btrace.c (btrace_enable): Likewise.
12956 (parse_xml_btrace): Likewise.
12957 (parse_xml_btrace_conf): Likewise.
12958
12959 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12960
12961 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
12962 (linux_enable_pt, linux_enable_bts): Call
12963 diagnose_perf_event_open_fail.
12964
12965 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12966
12967 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12968 Remove parameter and change return type. Update callers. Move it.
12969 (linux_enable_bts, linux_enable_pt): Improve error message.
12970 (linux_enable_pt): Remove zero buffer size check.
12971 (linux_enable_btrace): Improve error messages. Remove NULL return
12972 check.
12973
12974 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12975
12976 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12977 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12978 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12979 (linux_supports_pt, linux_supports_btrace): Remove.
12980 (linux_enable_bts): Call cpu_supports_bts.
12981 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12982 * remote.c (remote_supports_btrace): Remove.
12983 (init_remote_ops): Remove remote_supports_btrace.
12984 * target-delegates.c: Regenerated.
12985 * target.c (target_supports_btrace): Remove.
12986 * target.h (target_ops) <to_supports_btrace>: Remove
12987 (target_supports_btrace): Remove.
12988 * x86-linux-nat.c (x86_linux_create_target): Remove
12989 linux_supports_btrace.
12990
12991 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12992
12993 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12994 btrace failed.
12995 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12996 exception and use message in own exception.
12997
12998 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12999
13000 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
13001 (perf_event_pt_event_type): Use gdb_file_up.
13002 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
13003 scoped_fd, and scoped_mmap.
13004
13005 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13006
13007 * common/scoped_mmap.h: New.
13008 * unittests/scoped_mmap-selftest.c: New.
13009 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13010 unittests/scoped_mmap-selftest.c.
13011
13012 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13013
13014 * common/scoped_fd.h: New.
13015 * unittests/scoped_fd-selftest.c: New.
13016 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13017 unittests/scoped_fd-selftest.c.
13018
13019 2018-02-09 Tom Tromey <tom@tromey.com>
13020
13021 * auto-load.c (auto_load_section_scripts): Use
13022 gdb::unique_xmalloc_ptr.
13023
13024 2018-02-09 Tom Tromey <tom@tromey.com>
13025
13026 * auto-load.c (execute_script_contents): Use std::string.
13027
13028 2018-02-09 Joel Brobecker <brobecker@adacore.com>
13029
13030 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
13031 Python function, rather than a new command.
13032
13033 2018-02-08 Tom Tromey <tom@tromey.com>
13034
13035 * solib.c (solib_find_1): Use std::string.
13036 (solib_bfd_fopen): Use unique_xmalloc_ptr.
13037
13038 2018-02-08 Tom Tromey <tom@tromey.com>
13039
13040 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
13041
13042 2018-02-08 Tom Tromey <tom@tromey.com>
13043
13044 * source.c (find_source_lines): Use gdb::def_vector.
13045
13046 2018-02-08 Tom Tromey <tom@tromey.com>
13047
13048 * macrocmd.c (struct temporary_macro_definition): New.
13049 (macro_define_command): Use temporary_macro_definition. Remove
13050 cleanups.
13051 (free_macro_definition_ptr): Remove.
13052
13053 2018-02-08 Tom Tromey <tom@tromey.com>
13054
13055 * macroexp.c (maybe_expand): Use std::string.
13056
13057 2018-02-08 Tom Tromey <tom@tromey.com>
13058
13059 * macroexp.c (struct macro_buffer): Add initializers for some
13060 members.
13061 (init_buffer, init_shared_buffer, free_buffer)
13062 (free_buffer_return_text): Remove.
13063 (macro_buffer): New constructors.
13064 (~macro_buffer): New destructor.
13065 (macro_buffer::set_shared): New method.
13066 (macro_buffer::resize_buffer, macro_buffer::appendc)
13067 (macro_buffer::appendmem): Now methods, not free functions.
13068 (set_token, append_tokens_without_splicing, stringify)
13069 (macro_stringify): Update.
13070 (gather_arguments): Change return type. Remove argc_p argument,
13071 add args_ptr argument. Use std::vector.
13072 (substitute_args): Remove argc argument. Accept std::vector.
13073 (expand): Update. Use std::vector.
13074 (scan, macro_expand, macro_expand_next): Update.
13075
13076 2018-02-08 Tom Tromey <tom@tromey.com>
13077
13078 * symtab.c (default_collect_symbol_completion_matches_break_on):
13079 Use unique_xmalloc_ptr.
13080 * macroscope.h: (sal_macro_scope, user_macro_scope)
13081 (default_macro_scope): Return unique_xmalloc_ptr.
13082 * macroscope.c (sal_macro_scope, user_macro_scope)
13083 (default_macro_scope): Return unique_xmalloc_ptr.
13084 * macroexp.h (macro_expand, macro_expand_once): Return
13085 unique_xmalloc_ptr.
13086 * macroexp.c (macro_expand, macro_expand_once): Return
13087 unique_xmalloc_ptr.
13088 * macrocmd.c (macro_expand_command, macro_expand_once_command)
13089 (info_macro_command, info_macros_command): Use
13090 unique_xmalloc_ptr.
13091 * compile/compile-c-support.c (write_macro_definitions): Use
13092 unique_xmalloc_ptr.
13093 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
13094
13095 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
13096
13097 * value.c (value_static_field): Assign field type instead of
13098 containing type when returning an optimized out value.
13099
13100 2018-02-06 Yao Qi <yao.qi@linaro.org>
13101
13102 * ft32-tdep.c (ft32_read_pc): Remove.
13103 (ft32_write_pc): Remove.
13104 (ft32_gdbarch_init): Update.
13105 * m32r-tdep.c (m32r_read_pc): Remove.
13106 (m32r_gdbarch_init): Update.
13107 * mep-tdep.c (mep_read_pc): Remove.
13108 (mep_gdbarch_init): Update.
13109 * microblaze-tdep.c (microblaze_write_pc): Remove.
13110 (microblaze_gdbarch_init): Update.
13111 * mn10300-tdep.c (mn10300_read_pc): Remove.
13112 (mn10300_write_pc): Remove.
13113 (mn10300_gdbarch_init): Update.
13114 * moxie-tdep.c (moxie_read_pc): Remove.
13115 (moxie_write_pc): Remove.
13116 (moxie_gdbarch_init): Update.
13117
13118 2018-02-06 Yao Qi <yao.qi@linaro.org>
13119
13120 * expprint.c (print_subexp_standard): Handle
13121 OP_F77_UNDETERMINED_ARGLIST.
13122 (dump_subexp_body_standard): Likewise.
13123
13124 2018-02-05 Alan Hayward <alan.hayward@arm.com>
13125
13126 * target-descriptions.c (tdesc_element_visitor) Add empty
13127 implementations.
13128 (tdesc_type): Move make_gdb_type from here.
13129 (tdesc_type_builtin): Likewise.
13130 (tdesc_type_vector): Likewise.
13131 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
13132 (make_gdb_type_struct): Move from tdesc_type_with_fields.
13133 (make_gdb_type_union): Likewise.
13134 (make_gdb_type_flags): Likewise.
13135 (make_gdb_type_enum): Likewise.
13136 (make_gdb_type): New function.
13137 (tdesc_register_type): Use static make_gdb_type.
13138
13139 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
13140
13141 * infcmd.c (default_print_one_register_info): Align natural-format
13142 column values consistently one under another.
13143 (pad_to_column): New function.
13144
13145 2018-02-05 Joel Brobecker <brobecker@adacore.com>
13146
13147 * dwarf2read.c (dwarf2_physname): Move commment.
13148
13149 2018-02-01 Leszek Swirski <leszeks@google.com>
13150
13151 * varobj.c (varobj_formatted_print_options): Allow recursive
13152 pretty printing if pretty printing is enabled.
13153
13154 2018-02-01 Leszek Swirski <leszeks@google.com>
13155
13156 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
13157 names after a structop as a filename.
13158
13159 2018-02-01 Yao Qi <yao.qi@linaro.org>
13160
13161 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
13162 (arm_record_coproc_data_proc): Likewise.
13163
13164 2018-02-01 Yao Qi <yao.qi@linaro.org>
13165
13166 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
13167
13168 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
13169
13170 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
13171 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
13172
13173 2018-01-31 Pedro Alves <palves@redhat.com>
13174
13175 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
13176 * inflow.c (child_terminal_save_inferior): Wrap reference to
13177 tcgetpgrp in HAVE_TERMIOS_H.
13178 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
13179 _WIN32.
13180 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
13181 always iterate over all inferiors.
13182 (gdbsim_cntrl_c): Adjust.
13183 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
13184
13185 2018-01-31 Joel Brobecker <brobecker@adacore.com>
13186
13187 * gdbtypes.c (lookup_array_range_type): Make sure the array's
13188 index type is objfile-owned if the element type is as well.
13189
13190 2018-01-31 Joel Brobecker <brobecker@adacore.com>
13191
13192 GDB 8.1 released.
13193
13194 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
13195
13196 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
13197 "features/s390x-linux64.c".
13198 (_initialize_s390_linux_tdep): Remove initialization of tdescs
13199 s390_linux32 and s390x_linux64.
13200 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
13201 default tdesc.
13202 * s390-tdep.c: Include "features/s390-linux32.c" and
13203 "features/s390x-linux64.c".
13204 (s390_tdesc_valid): Add check for tdesc_has_registers.
13205 (s390_gdbarch_init): Make sure there is always a valid tdesc.
13206 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
13207 tdesc_s390x_linux64.
13208 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
13209 tdesc_s390x_linux64 to...
13210 * s390-tdep.h: ...here.
13211
13212 2018-01-30 Pedro Alves <palves@redhat.com>
13213
13214 PR gdb/13211
13215 * config.in, configure: Regenerate.
13216 * configure.ac: Check for getpgid.
13217 * go32-nat.c (go32_pass_ctrlc): New.
13218 (go32_target): Install it.
13219 * inf-child.c (inf_child_target): Install
13220 child_terminal_save_inferior, child_pass_ctrlc and
13221 child_interrupt.
13222 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
13223 (inf_ptrace_target): No longer install it.
13224 * infcmd.c (interrupt_target_1): Adjust.
13225 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
13226 (child_interrupt): Declare.
13227 (inferior::terminal_state): New.
13228 * inflow.c (struct terminal_info): Update comments.
13229 (inferior_process_group): Delete.
13230 (terminal_is_ours): Delete.
13231 (gdb_tty_state): New.
13232 (child_terminal_init): Adjust.
13233 (is_gdb_terminal, sharing_input_terminal_1)
13234 (sharing_input_terminal): New functions.
13235 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
13236 Set the process's actual process group in the foreground if
13237 possible. Handle is_ours_for_output/is_ours distinction. Don't
13238 mark terminal as the inferior's if not sharing GDB's terminal.
13239 Don't check attach_flag.
13240 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
13241 pass down a target_terminal_state.
13242 (child_terminal_save_inferior): New, factored out from ...
13243 (child_terminal_ours_1): ... this. Handle
13244 target_terminal_state::is_ours_for_output.
13245 (child_interrupt, child_pass_ctrlc): New.
13246 (inflow_inferior_exit): Clear the inferior's terminal_state.
13247 (copy_terminal_info): Copy the inferior's terminal state.
13248 (_initialize_inflow): Remove reference to terminal_is_ours.
13249 * inflow.h (inferior_process_group): Delete.
13250 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
13251 * procfs.c (procfs_target): Don't install procfs_interrupt.
13252 (procfs_interrupt): Delete.
13253 * remote.c (remote_serial_quit_handler): Adjust.
13254 (remote_interrupt): Remove ptid parameter. Adjust.
13255 * target-delegates.c: Regenerate.
13256 * target.c: Include "terminal.h".
13257 (target_terminal::terminal_state): Rename to ...
13258 (target_terminal::m_terminal_state): ... this.
13259 (target_terminal::init): Adjust.
13260 (target_terminal::inferior): Adjust to per-inferior
13261 terminal_state.
13262 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
13263 (target_terminal::ours, target_terminal::ours_for_output): Use
13264 target_terminal_is_ours_kind.
13265 (target_interrupt): Remove ptid parameter. Adjust.
13266 (default_target_pass_ctrlc): Adjust.
13267 * target.h (target_ops::to_terminal_save_inferior): New field.
13268 (target_ops::to_interrupt): Remove ptid_t parameter.
13269 (target_interrupt): Remove ptid_t parameter. Update comment.
13270 (target_pass_ctrlc): Update comment.
13271 * target/target.h (target_terminal_state): New scoped enum,
13272 factored out of ...
13273 (target_terminal::terminal_state): ... here.
13274 (target_terminal::inferior): Update comments.
13275 (target_terminal::restore_inferior): New.
13276 (target_terminal::is_inferior, target_terminal::is_ours)
13277 (target_terminal::is_ours_for_output): Adjust.
13278 (target_terminal::scoped_restore_terminal_state): Adjust to
13279 rename, and call restore_inferior() instead of inferior().
13280 (target_terminal::scoped_restore_terminal_state::m_state): Change
13281 type.
13282 (target_terminal::terminal_state): Rename to ...
13283 (target_terminal::m_terminal_state): ... this and change type.
13284
13285 2018-01-30 Pedro Alves <palves@redhat.com>
13286
13287 * linux-nat.c (wait_for_signal): New function.
13288 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
13289 directly.
13290 (async_terminal_is_ours)
13291 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
13292 (linux_nat_add_target): Don't override
13293 to_terminal_inferior/to_terminal_ours.
13294
13295 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
13296
13297 * remote.c (remote_follow_fork): Don't call "detach_inferior".
13298
13299 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
13300
13301 * dwarf2read.c (free_dwo_files): Add forward-declaration.
13302 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
13303 dwarf2_per_objfile_free here.
13304 (dwarf2_per_objfile_free): Remove.
13305 (_initialize_dwarf2_read): Don't register
13306 dwarf2_per_objfile_free as a registry cleanup.
13307
13308 2018-01-27 Eli Zaretskii <eliz@gnu.org>
13309
13310 Avoid compilation errors in MinGW native builds
13311
13312 The error is triggered by including python-internal.h, and the
13313 error message is:
13314
13315 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
13316 from build-gnulib/import/math.h:27,
13317 from d:/usr/Python26/include/pyport.h:235,
13318 from d:/usr/Python26/include/Python.h:58,
13319 from python/python-internal.h:94,
13320 from python/py-arch.c:24:
13321 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
13322 using ::hypot;
13323 ^~~~~
13324
13325 This happens because Python headers define 'hypot' to expand t
13326 '_hypot' in the Windows builds.
13327 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
13328 'hypoth'. This avoids a compilation error.
13329
13330 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13331
13332 * MAINTAINERS (Write After Approval): Fix ordering.
13333
13334 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13335
13336 * MAINTAINERS (Write After Approval): Add Alan Hayward.
13337
13338 2018-01-26 Alan Modra <amodra@gmail.com>
13339
13340 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
13341 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
13342 Remove nop. Make const. Comment.
13343 (powerpc32_plt_stub_so_2): New.
13344 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
13345 Correct count. Update uses.
13346 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
13347 Move common code reading PLT entry word. Correct
13348 powerpc32_plt_stub PLT address calculation.
13349 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
13350 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
13351 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
13352 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
13353 (ppc64_standard_linkage8): Likewise.
13354 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
13355 Correct insns description.
13356 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
13357
13358 2018-01-24 Pedro Alves <palves@redhat.com>
13359
13360 GCC PR libstdc++/83906
13361 * gdbtypes.c (operator==(const dynamic_prop &,
13362 const dynamic_prop &)): New.
13363 (operator==(const range_bounds &, const range_bounds &)): New.
13364 (check_types_equal): Use them instead of memcmp.
13365 * gdbtypes.h (operator==(const dynamic_prop &,
13366 const dynamic_prop &)): Declare.
13367 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
13368 (operator==(const range_bounds &, const range_bounds &)): Declare.
13369 (operator!=(const range_bounds &, const range_bounds &)): Declare.
13370
13371 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13372
13373 * s390-linux-tdep.c (s390_record_address_mask)
13374 (s390_record_calc_disp_common, s390_record_calc_disp)
13375 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13376 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13377 (s390_process_record): Move to s390-tdep.c.
13378 (s390_linux_init_abi_any): Adjust.
13379 * s390-tdep.c (s390_record_address_mask)
13380 (s390_record_calc_disp_common, s390_record_calc_disp)
13381 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13382 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13383 (s390_process_record): Moved from s390-linux-tdep.c
13384 (s390_gdbarch_init): Adjust.
13385
13386 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13387
13388 * s390-linux-nat.c (s390-tdep.h): New include.
13389 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
13390 (HFILES_NO_SRCDIR): Add s390-tdep.h.
13391 (ALLDEPFILES): Add s390-tdep.c.
13392 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
13393 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
13394 * s390-tdep.h: ...this. New file.
13395 * s390-linux-tdep.c (s390-tdep.h): New include.
13396 (_initialize_s390_tdep): Rename to...
13397 (_initialize_s390_linux_tdep): ...this and adjust.
13398 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
13399 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
13400 s390-tdep.h.
13401 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
13402 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
13403 (s390_is_partial_instruction, s390_software_single_step)
13404 (is_non_branch_ril, s390_displaced_step_copy_insn)
13405 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
13406 (s390_prologue_data, s390_addr, s390_store, s390_load)
13407 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
13408 (s390_register_call_saved, s390_guess_tracepoint_registers)
13409 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
13410 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
13411 (s390_pseudo_register_name, s390_pseudo_register_type)
13412 (s390_pseudo_register_read, s390_pseudo_register_write)
13413 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
13414 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
13415 (s390_addr_bits_remove, s390_address_class_type_flags)
13416 (s390_address_class_type_flags_to_name)
13417 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
13418 (s390_function_arg_float, s390_function_arg_vector)
13419 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
13420 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
13421 (s390_frame_align, s390_register_return_value, s390_return_value)
13422 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
13423 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
13424 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
13425 (s390_trad_frame_prev_register, s390_unwind_cache)
13426 (s390_prologue_frame_unwind_cache)
13427 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
13428 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
13429 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
13430 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
13431 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
13432 (s390_frame_base_address, s390_local_base_address)
13433 (s390_frame_base, s390_gcc_target_options)
13434 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
13435 (s390_validate_reg_range, s390_tdesc_valid)
13436 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
13437 * s390-tdep.c: ...this. New file.
13438
13439 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13440
13441 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
13442 (s390_process_record, s390_gdbarch_tdep_alloc)
13443 (s390_linux_init_abi_any): Use/set new hook.
13444
13445 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13446
13447 * s390-linux-tdep.c (osabi.h): New include.
13448 (s390_linux_init_abi_31, s390_linux_init_abi_64)
13449 (s390_linux_init_abi_any): New functions.
13450 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
13451
13452 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13453
13454 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
13455 tdesc_has_registers check
13456
13457 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13458
13459 * s390-linux-tdep.c (s390_tdesc_valid): New function.
13460 (s390_validate_reg_range): New macro.
13461 (s390_gdbarch_init): Adjust.
13462
13463 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13464
13465 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
13466 (s390_gdbarch_tdep_alloc): Adjust.
13467 (s390_gdbarch_init): Adjust.
13468
13469 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13470
13471 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
13472 <have_tdb>: Change type to bool.
13473 (s390_gdbarch_tdep_alloc): Adjust.
13474 (s390_gdbarch_init): Adjust.
13475
13476 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13477
13478 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
13479 (gdbarch_tdep) <have_upper, have_vx>: New fields.
13480 (s390_gdbarch_tdep_alloc): New function.
13481 (s390_gdbarch_init): Allocate tdep at start and use its fields
13482 instead of separate variables.
13483
13484 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13485
13486 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
13487 when looking for cached gdbarch and add comment for remaining.
13488
13489 2018-01-22 Pedro Alves <palves@redhat.com>
13490 Sergio Durigan Junior <sergiodj@redhat.com>
13491
13492 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
13493 case.
13494
13495 2018-01-22 Maciej W. Rozycki <macro@mips.com>
13496
13497 * MAINTAINERS: Update my company e-mail address.
13498
13499 2018-01-22 Yao Qi <yao.qi@linaro.org>
13500
13501 * regcache.c (cooked_write_test): New function.
13502 (_initialize_regcache): Register the test.
13503
13504 2018-01-22 Yao Qi <yao.qi@linaro.org>
13505
13506 * ia64-tdep.c (ia64_pseudo_register_read): Call
13507 regcache->cooked_read instead of regcache_cooked_read_unsigned.
13508 * m32c-tdep.c (m32c_cat_read): Likewise.
13509 (m32c_r3r2r1r0_read): Likewise.
13510 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
13511 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
13512
13513 2018-01-22 Yao Qi <yao.qi@linaro.org>
13514
13515 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
13516 method raw_read instead of regcache_raw_read.
13517 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
13518 * arm-tdep.c (arm_neon_quad_read): Likewise.
13519 * avr-tdep.c (avr_pseudo_register_read): Likewise.
13520 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
13521 * frv-tdep.c (frv_pseudo_register_read): Likewise.
13522 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
13523 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
13524 (i386_pseudo_register_read_into_value): Likewise.
13525 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
13526 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
13527 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
13528 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
13529 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
13530 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
13531 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
13532 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
13533 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
13534
13535 2018-01-22 Yao Qi <yao.qi@linaro.org>
13536
13537 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
13538 * configure.tgt: Remove target mt.
13539 * mt-tdep.c: Remove.
13540 * regcache.c (cooked_read_test): Remove the check for mt.
13541
13542 2018-01-22 Yao Qi <yao.qi@linaro.org>
13543
13544 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
13545 instead of gdbarch_pseudo_register_read_value.
13546
13547 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13548
13549 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
13550 language is Ada.
13551
13552 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13553
13554 * linespec.c (create_sals_line_offset): Remove code that preserved
13555 the symtab_and_line's line number.
13556
13557 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13558
13559 * varobj.c (varobj_create): Don't set valid_block when creating a
13560 floating varobj.
13561
13562 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13563
13564 * varobj.c (varobj_create): Remove out of date comment.
13565
13566 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13567
13568 PR mi/20395
13569 * ada-exp.y (write_var_from_sym): Pass extra parameter when
13570 updating innermost block.
13571 * parse.c (innermost_block_tracker::update): Take extra type
13572 parameter, and check types match before updating innermost block.
13573 (write_dollar_variable): Update innermost block for registers.
13574 * parser-defs.h (enum innermost_block_tracker_type): New enum.
13575 (innermost_block_tracker::innermost_block_tracker): Initialise
13576 m_types member.
13577 (innermost_block_tracker::reset): Take type parameter.
13578 (innermost_block_tracker::update): Take type parameter, and pass
13579 type through as needed.
13580 (innermost_block_tracker::m_types): New member.
13581 * varobj.c (varobj_create): Pass type when reseting innermost
13582 block.
13583
13584 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13585
13586 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
13587 * ada-lang.c (resolve_subexp): Likewise.
13588 * breakpoint.c (set_breakpoint_condition) Likewise.
13589 (watch_command_1) Likewise.
13590 * c-exp.y (variable): Likewise.
13591 * d-exp.y (PrimaryExpression): Likewise.
13592 * f-exp.y (variable): Likewise.
13593 * go-exp.y (variable): Likewise.
13594 * m2-exp.y (variable): Likewise.
13595 * objfiles.c (objfile::~objfile): Likewise.
13596 * p-exp.y (variable): Likewise.
13597 * parse.c (innermost_block): Change type.
13598 * parser-defs.h (class innermost_block_tracker): New.
13599 (innermost_block): Change to innermost_block_tracker.
13600 * printcmd.c (display_command): Switch to innermost_block API.
13601 (do_one_display): Likewise.
13602 * rust-exp.y (do_one_display): Likewise.
13603 * symfile.c (clear_symtab_users): Likewise.
13604 * varobj.c (varobj_create): Switch to innermost_block API, replace
13605 use of innermost_block with block stored on varobj object.
13606
13607 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13608
13609 * expression.h (innermost_block): Remove declaration.
13610 * varobj.c: Add 'parser-defs.h' include.
13611
13612 2018-01-19 Tom Tromey <tom@tromey.com>
13613
13614 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
13615 symbols in the static and global blocks.
13616
13617 2018-01-19 James Clarke <jrtc27@jrtc27.com>
13618
13619 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
13620 gdb_ptrace.h, and move including gdb_wait.h ...
13621 * nat/linux-ptrace.h: ... to here.
13622
13623 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13624
13625 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
13626 inf_ptrace_detach_success.
13627 (inf_ptrace_detach_success): Add inferior parameter, use it
13628 instead of inferior_ptid, pass it to detach_inferior.
13629 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
13630 parameter.
13631 * inferior.c (detach_inferior): Add overload that takes an
13632 inferior object.
13633 * inferior.h (detach_inferior): Likewise.
13634 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
13635 use inferior_ptid, adjust call to inf_ptrace_detach_success.
13636 * linux-thread-db.c (thread_db_detach): Use inf parameter.
13637
13638 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13639
13640 * target.h (struct target_ops) <to_detach>: Add inferior
13641 parameter.
13642 (target_detach): Likewise.
13643 * target.c (dispose_inferior): Pass inferior down.
13644 (target_detach): Pass inferior down. Assert that it is equal to
13645 the current inferior.
13646 * aix-thread.c (aix_thread_detach): Pass inferior down.
13647 * corefile.c (core_file_command): Pass current_inferior() down.
13648 * corelow.c (core_detach): Add inferior parameter.
13649 * darwin-nat.c (darwin_detach): Likewise.
13650 * gnu-nat.c (gnu_detach): Likewise.
13651 * inf-ptrace.c (inf_ptrace_detach): Likewise.
13652 * infcmd.c (detach_command): Pass current_inferior() down to
13653 target_detach.
13654 * infrun.c (follow_fork_inferior): Pass parent_inf to
13655 target_detach.
13656 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
13657 target_detach.
13658 * linux-nat.c (linux_nat_detach): Add inferior parameter.
13659 * linux-thread-db.c (thread_db_detach): Likewise.
13660 * nto-procfs.c (procfs_detach): Likewise.
13661 * procfs.c (procfs_detach): Likewise.
13662 * record.c (record_detach): Likewise.
13663 * record.h (struct inferior): Forward-declare.
13664 (record_detach): Add inferior parameter.
13665 * remote-sim.c (gdbsim_detach): Likewise.
13666 * remote.c (remote_detach_1): Likewise.
13667 (remote_detach): Likewise.
13668 (extended_remote_detach): Likewise.
13669 * sol-thread.c (sol_thread_detach): Likewise.
13670 * target-debug.h (target_debug_print_inferior_p): New macro.
13671 * target-delegates.c: Re-generate.
13672 * top.c (kill_or_detach): Pass inferior down to target_detach.
13673 * windows-nat.c (windows_detach): Add inferior parameter.
13674
13675 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
13676
13677 * target.h (struct target_ops) <to_detach>: Remove args
13678 parameter.
13679 (target_detach): Likewise.
13680 * target.c (dispose_inferior): Adjust.
13681 (target_detach): Remove args parameter, adjust.
13682 * aix-thread.c (aix_thread_detach): Adjust.
13683 * corefile.c (core_file_command): Adjust.
13684 * corelow.c (core_detach): Adjust.
13685 * darwin-nat.c (darwin_detach): Adjust.
13686 * gnu-nat.c (gnu_detach): Adjust.
13687 * inf-ptrace.c (inf_ptrace_detach): Adjust.
13688 * infcmd.c (detach_command): Adjust
13689 * infrun.c (follow_fork_inferior): Adjust.
13690 (handle_vfork_child_exec_or_exit): Adjust.
13691 * linux-fork.c (linux_fork_detach): Remove args parameter.
13692 * linux-fork.h (linux_fork_detach): Likewise.
13693 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
13694 * linux-thread-db.c (thread_db_detach): Likewise.
13695 * nto-procfs.c (procfs_detach): Likewise.
13696 * procfs.c (procfs_detach): Likewise.
13697 (do_detach): Remove signo parameter.
13698 * record.c (record_detach): Remove args parameter.
13699 * record.h (record_detach): Likewise.
13700 * remote-sim.c (gdbsim_detach): Likewise.
13701 * remote.c (remote_detach_1): Likewise.
13702 (remote_detach): Likewise.
13703 (extended_remote_detach): Likewise.
13704 * sol-thread.c (sol_thread_detach): Likewise.
13705 * target-delegates.c: Re-generate.
13706 * top.c (struct qt_args) <args>: Remove field.
13707 (kill_or_detach): Don't pass args.
13708 (quit_force): Don't set args.
13709 * windows-nat.c (windows_detach): Remove args parameter.
13710
13711 2018-01-19 Yao Qi <yao.qi@linaro.org>
13712
13713 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
13714 (arm_linux_init_abi): Install it.
13715
13716 2018-01-19 Yao Qi <yao.qi@linaro.org>
13717
13718 * osabi.c (gdb_osabi_names): Extend the regexp for
13719 arm-linux-gnueabihf.
13720
13721 2018-01-18 Yao Qi <yao.qi@linaro.org>
13722
13723 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
13724 m_abbrevs.
13725 (abbrev_table::add_abbrev): Update.
13726 (abbrev_table::lookup_abbrev): Update.
13727
13728 2018-01-18 Yao Qi <yao.qi@linaro.org>
13729
13730 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
13731
13732 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
13733
13734 * compile/compile.c (compile_to_object): Convert "triplet_rx"
13735 to "std::string".
13736
13737 2018-01-17 Tom Tromey <tom@tromey.com>
13738
13739 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
13740
13741 2018-01-17 Tom Tromey <tom@tromey.com>
13742
13743 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
13744 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
13745 (create_array_type_with_stride): Update.
13746 * dwarf2read.c (set_die_type): Update.
13747
13748 2018-01-17 Tom Tromey <tom@tromey.com>
13749
13750 * dwarf2read.c (delayed_method_info): Remove typedef.
13751 (dwarf2_cu::method_info): Now a std::vector.
13752 (add_to_method_list): Update.
13753 (free_delayed_list): Remove.
13754 (compute_delayed_physnames): Update.
13755 (process_full_comp_unit, process_full_type_unit): Clear the method
13756 list. Remove cleanups.
13757 (psymtab_include_file_name): Add name_holder parameter. Use
13758 unique_xmalloc_ptr.
13759 (dwarf_decode_lines): Update.
13760
13761 2018-01-17 Tom Tromey <tom@tromey.com>
13762 Simon Marchi <simon.marchi@ericsson.com>
13763
13764 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
13765 (dwarf2_per_objfile::free_cached_comp_units)
13766 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13767 (init_cutu_and_read_dies_no_follow): Update.
13768 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
13769 (dwarf2_cu::~dwarf2_cu): New.
13770 (free_heap_comp_unit, free_stack_comp_unit): Remove.
13771 (age_cached_comp_units, free_one_cached_comp_unit): Update.
13772
13773 2018-01-17 Tom Tromey <tom@tromey.com>
13774 Simon Marchi <simon.marchi@ericsson.com>
13775
13776 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
13777 (struct die_reader_specs) <abbrev_table>: New member.
13778 (struct abbrev_table): Add constructor.
13779 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
13780 <abbrev_obstack>: Now an auto_obstack.
13781 (abbrev_table_up): New typedef.
13782 (init_cu_die_reader): Add abbrev_table parameter.
13783 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
13784 Add result_dwo_abbrev_table.
13785 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13786 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
13787 Update.
13788 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
13789 parameter.
13790 (skip_children): Update.
13791 (abbrev_table::alloc_abbrev): Rename from
13792 abbrev_table_alloc_abbrev.
13793 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
13794 (abbrev_table::lookup_abbrev): Rename from
13795 abbrev_table_lookup_abbrev.
13796 (abbrev_table_read_table): Return abbrev_table_up.
13797 (abbrev_table_free, abbrev_table_free_cleanup)
13798 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
13799 (load_partial_dies): Update.
13800
13801 2018-01-17 Tom Tromey <tom@tromey.com>
13802
13803 * dwarf2read.c (dwarf2_compute_name): Update comment.
13804 (read_func_scope, read_variable): Update.
13805 (new_symbol): Remove.
13806 (new_symbol_full): Rename to new_symbol.
13807
13808 2018-01-17 Mike Gulick <mgulick@mathworks.com>
13809
13810 PR gdb/16577
13811 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
13812 a warning instead of throwing an error, set section size to 0 and return
13813 NULL.
13814 * gdb_bfd.h (gdb_bfd_map_section): Update description.
13815
13816 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13817
13818 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
13819 std::string.
13820 (linux_ptrace_attach_fail_reason_string): Likewise.
13821 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
13822 Likewise.
13823 (linux_ptrace_attach_fail_reason_string): Likewise.
13824 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
13825
13826 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13827
13828 * linux-nat.c (linux_nat_attach): Remove xstrdup.
13829
13830 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
13831
13832 PR gdb/21559
13833 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
13834 checking for fs_base/gs_base fields in struct user_regs_struct.
13835 * configure: Regenerate.
13836
13837 2018-01-17 Yao Qi <yao.qi@linaro.org>
13838
13839 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
13840 function.
13841 (aarch64_linux_init_abi): Install it to gdbarch hook
13842 gcc_target_options.
13843
13844 2018-01-15 Pedro Alves <palves@redhat.com>
13845
13846 * common/signals-state-save-restore.c
13847 (save_original_signals_state): Fix typos.
13848
13849 2017-01-12 Tom Tromey <tom@tromey.com>
13850 Sergio Durigan Junior <sergiodj@redhat.com>
13851
13852 * Makefile.in (install-only): Install gdb-add-index.
13853
13854 2018-01-12 John Baldwin <jhb@FreeBSD.org>
13855
13856 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
13857
13858 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
13859
13860 * infrun.c (keep_going_pass_signal): Clear step-over info when
13861 insert_breakpoints fails.
13862
13863 2018-01-11 Pedro Alves <palves@redhat.com>
13864
13865 PR gdb/22583
13866 * infrun.c (resume): Rename to ...
13867 (resume_1): ... this.
13868 (resume): Reimplement as wrapper around resume_1.
13869
13870 2018-01-11 Pedro Alves <palves@redhat.com>
13871
13872 PR remote/22597
13873 * remote.c (remote_parse_stop_reply): Default to the last-set
13874 general thread instead of to 'magic_null_ptid'.
13875
13876 2018-01-10 Pedro Alves <palves@redhat.com>
13877
13878 * language.h (language_get_symbol_name_matcher): Rename ...
13879 (get_symbol_name_matcher): ... this.
13880 * language.c (language_get_symbol_name_matcher): Ditto.
13881 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
13882 callers adjusted.
13883
13884 2018-01-10 Pedro Alves <palves@redhat.com>
13885
13886 PR gdb/22670
13887 * dwarf2read.c
13888 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
13889 Adjust to use language_get_symbol_name_matcher instead of
13890 language_defn::la_get_symbol_name_matcher.
13891 * language.c (language_get_symbol_name_matcher): If in Ada mode
13892 and the lookup name is a verbatim match, return Ada's matcher.
13893 * language.h (language_get_symbol_name_matcher): Adjust comment.
13894 (ada_lookup_name_info::verbatim_p):: New method.
13895
13896 2018-01-10 Pedro Alves <palves@redhat.com>
13897
13898 PR gdb/22670
13899 * ada-lang.c (ada_collect_symbol_completion_matches): If the
13900 minsym's language is language_auto or language_cplus, pass down
13901 language_ada instead.
13902 * symtab.c (compare_symbol_name): Don't frob symbol language here.
13903
13904 2018-01-10 Pedro Alves <palves@redhat.com>
13905
13906 PR gdb/22670
13907 * minsyms.c (linkage_name_str): New function.
13908 (iterate_over_minimal_symbols): Use it.
13909
13910 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13911
13912 * NEWS: Document that 'info proc' now works on FreeBSD.
13913
13914 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13915
13916 * configure.ac: Check for kinfo_getfile in libutil.
13917 * configure: Regenerate.
13918 * config.in: Regenerate.
13919 * fbsd-nat.c: Include "fbsd-tdep.h".
13920 (fbsd_fetch_cmdline): New.
13921 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
13922 rather than calling error.
13923 (fbsd_info_proc): New.
13924 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
13925 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
13926 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
13927
13928 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13929
13930 * fbsd-nat.c (struct free_deleter): Remove.
13931 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
13932
13933 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13934
13935 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
13936 NULL for an empty pathname.
13937
13938 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13939
13940 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
13941 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
13942 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
13943 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
13944 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
13945 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
13946 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
13947 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
13948 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
13949 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
13950 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
13951 (fbsd_core_fetch_timeval, fbsd_print_sigset)
13952 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
13953 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
13954 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
13955
13956 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
13957
13958 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
13959 (gnu_xfer_auxv): New function.
13960 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
13961 TARGET_OBJECT_AUXV.
13962
13963 2018-01-08 Yao Qi <yao.qi@linaro.org>
13964 Simon Marchi <simon.marchi@ericsson.com>
13965
13966 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13967 common/selftest.c.
13968 (COMMON_OBS): Remove selftest.o.
13969 * configure.ac: Append selftest-arch.c and common/selftest.c to
13970 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13971 * configure: Re-generated.
13972 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13973 GDB_SELF_TEST.
13974 (maintenance_info_selftests): Likewise.
13975
13976 2018-01-08 Xavier Roirand <roirand@adacore.com>
13977
13978 * ada-valprint.c (val_print_packed_array_elements): Use
13979 proper number of elements when printing an array indexed
13980 by an enumeration type.
13981
13982 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13983
13984 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13985 (dw2_get_file_names_reader): Adjust.
13986 (lookup_dwo_signatured_type): Adjust.
13987 (lookup_dwp_signatured_type): Adjust.
13988 (lookup_signatured_type): Adjust.
13989 (create_type_unit_group): Adjust.
13990 (get_type_unit_group): Adjust.
13991 (process_psymtab_comp_unit_reader): Adjust.
13992 (build_type_psymtabs_reader): Adjust.
13993 (scan_partial_symbols): Adjust.
13994 (add_partial_symbol): Adjust.
13995 (add_partial_subprogram): Adjust.
13996 (peek_die_abbrev): Adjust.
13997 (fixup_go_packaging): Adjust.
13998 (process_imported_unit_die): Adjust.
13999 (dwarf2_compute_name): Adjust.
14000 (dwarf2_physname): Adjust.
14001 (read_import_statement): Adjust.
14002 (handle_DW_AT_stmt_list): Adjust.
14003 (read_file_scope): Adjust.
14004 (read_func_scope): Adjust.
14005 (read_lexical_block_scope): Adjust.
14006 (read_call_site_scope): Adjust.
14007 (read_variable): Adjust.
14008 (dwarf2_rnglists_process): Adjust.
14009 (dwarf2_ranges_process): Adjust.
14010 (dwarf2_ranges_read): Adjust.
14011 (dwarf2_get_pc_bounds): Adjust.
14012 (dwarf2_record_block_ranges): Adjust.
14013 (dwarf2_add_field): Adjust.
14014 (dwarf2_add_member_fn): Adjust.
14015 (read_structure_type): Adjust.
14016 (process_structure_scope): Adjust.
14017 (read_enumeration_type): Adjust.
14018 (read_array_type): Adjust.
14019 (mark_common_block_symbol_computed): Adjust.
14020 (read_common_block): Adjust.
14021 (read_namespace_type): Adjust.
14022 (read_namespace): Adjust.
14023 (read_module_type): Adjust.
14024 (read_tag_pointer_type): Adjust.
14025 (read_tag_ptr_to_member_type): Adjust.
14026 (read_tag_string_type): Adjust.
14027 (read_subroutine_type): Adjust.
14028 (read_typedef): Adjust.
14029 (read_base_type): Adjust.
14030 (attr_to_dynamic_prop): Adjust.
14031 (read_subrange_type): Adjust.
14032 (read_unspecified_type): Adjust.
14033 (dwarf2_read_abbrevs): Adjust.
14034 (load_partial_dies): Adjust.
14035 (read_partial_die): Adjust.
14036 (find_partial_die): Adjust.
14037 (guess_partial_die_structure_name): Adjust.
14038 (fixup_partial_die): Adjust.
14039 (read_attribute_value): Adjust.
14040 (read_addr_index): Adjust.
14041 (read_addr_index_from_leb128): Adjust.
14042 (read_str_index): Adjust.
14043 (dwarf2_string_attr): Adjust.
14044 (get_debug_line_section): Adjust.
14045 (dwarf_decode_line_header): Adjust.
14046 (lnp_state_machine::check_line_address): Adjust.
14047 (dwarf_decode_lines_1): Adjust.
14048 (dwarf_decode_lines): Adjust.
14049 (dwarf2_start_symtab): Adjust.
14050 (var_decode_location): Adjust.
14051 (new_symbol_full): Adjust.
14052 (dwarf2_const_value_data): Adjust.
14053 (dwarf2_const_value_attr): Adjust.
14054 (dwarf2_const_value): Adjust.
14055 (die_type): Adjust.
14056 (die_containing_type): Adjust.
14057 (build_error_marker_type): Adjust.
14058 (lookup_die_type): Adjust.
14059 (guess_full_die_structure_name): Adjust.
14060 (anonymous_struct_prefix): Adjust.
14061 (determine_prefix): Adjust.
14062 (dwarf2_name): Adjust.
14063 (follow_die_ref_or_sig): Adjust.
14064 (follow_die_offset): Adjust.
14065 (follow_die_ref): Adjust.
14066 (follow_die_sig_1): Adjust.
14067 (follow_die_sig): Adjust.
14068 (get_signatured_type): Adjust.
14069 (get_DW_AT_signature_type): Adjust.
14070 (decode_locdesc): Adjust.
14071 (dwarf_decode_macros): Adjust.
14072 (cu_debug_loc_section): Adjust.
14073 (fill_in_loclist_baton): Adjust.
14074 (dwarf2_symbol_mark_computed): Adjust.
14075 (init_one_comp_unit): Don't assign
14076 dwarf2_cu::dwarf2_per_objfile.
14077 (set_die_type): Adjust.
14078
14079 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14080
14081 * dwarf2read.c (struct mapped_debug_names): Add constructor.
14082 <dwarf2_per_objfile>: New field.
14083 (dwarf2_per_objfile): Remove global.
14084 (get_dwarf2_per_objfile): New function.
14085 (set_dwarf2_per_objfile): New function.
14086 (dwarf2_build_psymtabs_hard): Change objfile parameter to
14087 dwarf2_per_objfile.
14088 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14089 (read_abbrev_offset): Likewise.
14090 (read_indirect_string): Likewise.
14091 (read_indirect_line_string): Likewise.
14092 (read_indirect_string_at_offset): Likewise.
14093 (read_indirect_string_from_dwz): Likewise.
14094 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14095 dwarf2_per_objfile.
14096 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14097 (create_all_comp_units): Change objfile parameter to
14098 dwarf2_per_objfile.
14099 (create_all_type_units): Likewise.
14100 (process_queue): Add dwarf2_per_objfile parameter.
14101 (read_and_check_comp_unit_head): Likewise.
14102 (lookup_dwo_unit_in_dwp): Likewise.
14103 (get_dwp_file): Likewise.
14104 (process_cu_includes): Likewise.
14105 (struct free_dwo_file_cleanup_data): New struct.
14106 (dwarf2_has_info): Use get_dwarf2_per_objfile and
14107 set_dwarf2_per_objfile.
14108 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
14109 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
14110 context, adjust calls.
14111 (dw2_instantiate_symtab): Likewise.
14112 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
14113 (dw2_get_cu): Likewise.
14114 (create_cu_from_index_list): Change objfile parameter to
14115 dwarf2_per_objfile.
14116 (create_cus_from_index_list): Get dwarf2_per_objfile from
14117 context, adjust calls.
14118 (create_cus_from_index): Likewise.
14119 (create_signatured_type_table_from_index): Change objfile
14120 parameter to dwarf2_per_objfile.
14121 (create_signatured_type_table_from_debug_names): Change objfile
14122 parameter to dwarf2_per_objfile.
14123 (create_addrmap_from_index): Likewise.
14124 (create_addrmap_from_aranges): Likewise.
14125 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
14126 (dw2_setup): Remove.
14127 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
14128 context.
14129 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
14130 get_dwarf2_per_objfile.
14131 (dw2_forget_cached_source_info): Likewise.
14132 (dw2_map_symtabs_matching_filename): Likewise.
14133 (struct dw2_symtab_iterator) <index>: Remove.
14134 <dwarf2_per_objfile>: New field.
14135 (dw2_symtab_iter_init): Replace index parameter with
14136 dwarf2_per_objfile.
14137 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
14138 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
14139 (dw2_print_stats): Likewise.
14140 (dw2_dump): Likewise.
14141 (dw2_expand_symtabs_for_function): Likewise.
14142 (dw2_expand_all_symtabs): Likewise.
14143 (dw2_expand_symtabs_with_fullname): Likewise.
14144 (dw2_expand_marked_cus): Replace index and objfile parameters
14145 with dwarf2_per_objfile.
14146 (dw_expand_symtabs_matching_file_matcher): Add
14147 dwarf2_per_objfile parameter and adjust calls.
14148 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
14149 adjust calls.
14150 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
14151 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
14152 adjust calls.
14153 (create_cus_from_debug_names_list): Replace objfile parameter
14154 with dwarf2_per_objfile and adjust calls.
14155 (create_cus_from_debug_names): Likewise.
14156 (dwarf2_read_debug_names): Likewise.
14157 (mapped_debug_names::namei_to_name): Adjust call.
14158 (dw2_debug_names_iterator::next): Likewise.
14159 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
14160 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
14161 (dw2_debug_names_dump): Likewise.
14162 (dw2_debug_names_expand_symtabs_for_function): Likewise.
14163 (dw2_debug_names_expand_symtabs_matching): Likewise.
14164 (dwarf2_initialize_objfile): Likewise.
14165 (dwarf2_build_psymtabs): Likewise.
14166 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
14167 this_cu.
14168 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
14169 (read_and_check_comp_unit_head): Likewise.
14170 (read_abbrev_offset): Likewise.
14171 (create_debug_type_hash_table): Likewise.
14172 (create_debug_types_hash_table): Likewise.
14173 (create_all_type_units): Replace objfile parameter with
14174 dwarf2_per_objfile.
14175 (add_type_unit): Add dwarf2_per_objfile parameter.
14176 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
14177 with dwarf2_per_objfile.
14178 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
14179 (lookup_dwp_signatured_type): Likewise.
14180 (lookup_signatured_type): Likewise.
14181 (read_cutu_die_from_dwo): Likewise.
14182 (init_tu_and_read_dwo_dies): Likewise.
14183 (init_cutu_and_read_dies): Likewise.
14184 (init_cutu_and_read_dies_no_follow): Likewise.
14185 (allocate_type_unit_groups_table): Add objfile parameter.
14186 (create_type_unit_group): Use dwarf2_per_objfile from cu.
14187 (get_type_unit_group): Likewise.
14188 (process_psymtab_comp_unit): Update call.
14189 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
14190 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
14191 (print_tu_stats): Likewise.
14192 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
14193 in void* parameter.
14194 (build_type_psymtabs): Change objfile parameter to
14195 dwarf2_per_objfile.
14196 (process_skeletonless_type_unit): Use dwarf2_per_objfile
14197 passed in void* parameter.
14198 (process_skeletonless_type_units): Change objfile parameter to
14199 dwarf2_per_objfile.
14200 (set_partial_user): Likewise.
14201 (dwarf2_build_psymtabs_hard): Likewise.
14202 (read_comp_units_from_section): Likewise.
14203 (create_all_comp_units): Likewise.
14204 (scan_partial_symbols): Update calls.
14205 (add_partial_symbol): Likewise.
14206 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
14207 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
14208 (process_queue): Add dwarf2_per_objfile parameter.
14209 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
14210 (compute_compunit_symtab_includes): Likewise.
14211 (process_cu_includes): Add dwarf2_per_objfile parameter.
14212 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
14213 (process_full_type_unit): Likewise.
14214 (process_imported_unit_die): Update call.
14215 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
14216 (read_file_scope): Likewise.
14217 (allocate_dwo_file_hash_table): Add objfile parameter.
14218 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
14219 (create_cus_hash_table): Likewise.
14220 (create_dwp_hash_table): Likewise.
14221 (create_dwo_unit_in_dwp_v1): Likewise.
14222 (create_dwp_v2_section): Likewise.
14223 (create_dwo_unit_in_dwp_v2): Likewise.
14224 (lookup_dwo_unit_in_dwp): Likewise.
14225 (try_open_dwop_file): Likewise.
14226 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
14227 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
14228 cleanup to include a reference to dwarf2_per_objfile.
14229 (open_dwp_file): Add dwarf2_per_objfile parameter.
14230 (open_and_init_dwp_file): Likewise.
14231 (get_dwp_file): Likewise.
14232 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
14233 (queue_and_load_all_dwo_tus): Update call.
14234 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
14235 data.
14236 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
14237 (dwarf2_ranges_process): Likewise.
14238 (dwarf2_get_pc_bounds): Likewise.
14239 (mark_common_block_symbol_computed): Likewise.
14240 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14241 (dwarf2_read_abbrevs): Update call.
14242 (read_partial_die): Use dwarf2_per_objfile from cu.
14243 (find_partial_die): Likewise.
14244 (fixup_partial_die): Likewise.
14245 (read_attribute_value): Likewise.
14246 (read_indirect_string_at_offset_from): Add objfile parameter.
14247 (read_indirect_string_at_offset): Add dwarf2_per_objfile
14248 parameter.
14249 (read_indirect_string_from_dwz): Add objfile parameter.
14250 (read_indirect_string): Add objfile parameter.
14251 (read_addr_index_1): Add dwarf2_per_objfile parameter.
14252 (read_addr_index): Use dwarf2_per_objfile from cu.
14253 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
14254 call dw2_setup.
14255 (read_str_index): Use dwarf2_per_objfile from cu.
14256 (get_debug_line_section): Likewise.
14257 (read_formatted_entries): Add dwarf2_per_objfile parameter.
14258 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
14259 (new_symbol_full): Use dwarf2_per_objfile from cu.
14260 (build_error_marker_type): Likewise.
14261 (lookup_die_type): Likewise.
14262 (determine_prefix): Likewise.
14263 (follow_die_offset): Likewise.
14264 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
14265 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
14266 (dwarf2_fetch_die_type_sect_off): Likewise.
14267 (dwarf2_get_die_type): Likewise.
14268 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
14269 (get_signatured_type): Likewise.
14270 (get_DW_AT_signature_type): Likewise.
14271 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
14272 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
14273 (cu_debug_loc_section): Likewise.
14274 (fill_in_loclist_baton): Likewise.
14275 (dwarf2_symbol_mark_computed): Likewise.
14276 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14277 dwarf2_per_objfile.
14278 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
14279 parameter.
14280 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14281 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
14282 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
14283 (set_die_type): Use dwarf2_free_objfile from cu.
14284 (get_die_type_at_offset): Likewise.
14285 (dwarf2_per_objfile_free): Don't assign global variable.
14286 (debug_names) <constructor>: Add dwarf2_per_objfile
14287 parameter, update m_debugstrlookup construction.
14288 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
14289 parameter.
14290 <m_dwarf2_per_objfile>: New field.
14291 <lookup>: Use m_dwarf2_per_objfile.
14292 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
14293 (psyms_seen_size): Likewise.
14294 (write_gdbindex): Replace objfile parameter with
14295 dwarf2_per_objfile.
14296 (write_debug_names): Likewise.
14297 (write_psymtabs_to_index): Likewise.
14298 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
14299 calls.
14300
14301 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14302
14303 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
14304 <dwarf2_per_objfile>: New field.
14305 (struct dwarf2_per_cu_data) <objfile>: Remove.
14306 <dwarf2_per_objfile>: New field.
14307 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
14308 of objfile.
14309 (create_signatured_type_table_from_index): Likewise.
14310 (create_debug_type_hash_table): Likewise.
14311 (fill_in_sig_entry_from_dwo_entry): Likewise.
14312 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
14313 (create_type_unit_group): Assign dwarf2_per_objfile instead of
14314 objfile.
14315 (create_partial_symtab): Access objfile through
14316 dwarf2_per_objfile.
14317 (process_psymtab_comp_unit_reader): Likewise.
14318 (read_comp_units_from_section): Likewise.
14319 (scan_partial_symbols): Likewise.
14320 (add_partial_symbol): Likewise.
14321 (add_partial_subprogram): Likewise.
14322 (peek_die_abbrev): Likewise.
14323 (fixup_go_packaging): Likewise.
14324 (process_full_comp_unit): Likewise.
14325 (process_full_type_unit): Likewise.
14326 (process_imported_unit_die): Likewise.
14327 (dwarf2_compute_name): Likewise.
14328 (dwarf2_physname): Likewise.
14329 (read_import_statement): Likewise.
14330 (create_cus_hash_table): Assign dwarf2_physname instead of
14331 objfile.
14332 (read_func_scope): Access objfile through dwarf2_per_objfile.
14333 (read_lexical_block_scope): Likewise.
14334 (read_call_site_scope): Likewise.
14335 (read_variable): Likewise.
14336 (dwarf2_rnglists_process): Likewise.
14337 (dwarf2_ranges_process): Likewise.
14338 (dwarf2_ranges_read): Likewise.
14339 (dwarf2_record_block_ranges): Likewise.
14340 (dwarf2_add_field): Likewise.
14341 (dwarf2_add_member_fn): Likewise.
14342 (read_structure_type): Likewise.
14343 (process_structure_scope): Likewise.
14344 (read_enumeration_type): Likewise.
14345 (read_array_type): Likewise.
14346 (read_common_block): Likewise.
14347 (read_namespace_type): Likewise.
14348 (read_namespace): Likewise.
14349 (read_module_type): Likewise.
14350 (read_tag_pointer_type): Likewise.
14351 (read_tag_ptr_to_member_type): Likewise.
14352 (read_tag_string_type): Likewise.
14353 (read_subroutine_type): Likewise.
14354 (read_typedef): Likewise.
14355 (read_base_type): Likewise.
14356 (attr_to_dynamic_prop): Likewise.
14357 (read_subrange_type): Likewise.
14358 (read_unspecified_type): Likewise.
14359 (load_partial_dies): Likewise.
14360 (read_partial_die): Likewise.
14361 (find_partial_die): Likewise.
14362 (guess_partial_die_structure_name): Likewise.
14363 (fixup_partial_die): Likewise.
14364 (read_attribute_value): Likewise.
14365 (read_addr_index_from_leb128): Likewise.
14366 (dwarf2_read_addr_index): Likewise.
14367 (dwarf2_string_attr): Likewise.
14368 (lnp_state_machine::check_line_address): Likewise.
14369 (dwarf_decode_lines_1): Likewise.
14370 (dwarf_decode_lines): Likewise.
14371 (dwarf2_start_symtab): Likewise.
14372 (var_decode_location): Likewise.
14373 (new_symbol_full): Likewise.
14374 (dwarf2_const_value_data): Likewise.
14375 (dwarf2_const_value_attr): Likewise.
14376 (dwarf2_const_value): Likewise.
14377 (die_type): Likewise.
14378 (die_containing_type): Likewise.
14379 (lookup_die_type): Likewise.
14380 (guess_full_die_structure_name): Likewise.
14381 (anonymous_struct_prefix): Likewise.
14382 (dwarf2_name): Likewise.
14383 (follow_die_ref_or_sig): Likewise.
14384 (follow_die_offset): Likewise.
14385 (follow_die_ref): Likewise.
14386 (dwarf2_fetch_die_loc_sect_off): Likewise.
14387 (dwarf2_fetch_constant_bytes): Likewise.
14388 (dwarf2_fetch_die_type_sect_off): Likewise.
14389 (dwarf2_get_die_type): Likewise.
14390 (follow_die_sig): Likewise.
14391 (decode_locdesc): Likewise.
14392 (dwarf2_per_cu_objfile): Likewise.
14393 (dwarf2_per_cu_text_offset): Likewise.
14394 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
14395 objfile.
14396 (set_die_type): Access objfile through
14397 dwarf2_per_objfile.
14398
14399 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14400
14401 * valprint.c (converted_character_d): Remove typedef.
14402 (DEF_VEC_O (converted_character_d)): Remove.
14403 (count_next_character): Use std::vector.
14404 (print_converted_chars_to_obstack): Likewise.
14405 (generic_printstr): Likewise.
14406
14407 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14408
14409 * xml-support.h (struct gdb_xml_value): Add constructor.
14410 <value>: Change type to unique_xmalloc_ptr.
14411 (gdb_xml_value_s): Remove typedef.
14412 (DEF_VEC_O (gdb_xml_value_s)): Remove.
14413 (gdb_xml_element_start_handler): Change parameter type to
14414 std::vector.
14415 (xml_find_attribute): Likewise.
14416 * xml-support.c (xml_find_attribute): Change parameter type to
14417 std::vector and adjust.
14418 (gdb_xml_values_cleanup): Remove.
14419 (gdb_xml_parser::start_element): Adjust to std::vector.
14420 (xinclude_start_include): Change paraeter type to std::vector
14421 and adjust.
14422 * btrace.c (check_xml_btrace_version): Likewise.
14423 (parse_xml_btrace_block): Likewise.
14424 (parse_xml_btrace_pt_config_cpu): Likewise.
14425 (parse_xml_btrace_pt): Likewise.
14426 (parse_xml_btrace_conf_bts): Likewise.
14427 (parse_xml_btrace_conf_pt): Likewise.
14428 * memory-map.c (memory_map_start_memory): Likewise.
14429 (memory_map_start_property): Likewise.
14430 * osdata.c (osdata_start_osdata): Likewise.
14431 (osdata_start_item): Likewise.
14432 (osdata_start_column): Likewise.
14433 * remote.c (start_thread): Likewise.
14434 * solib-aix.c (library_list_start_library): Likewise.
14435 (library_list_start_list): Likewise.
14436 * solib-svr4.c (library_list_start_library): Likewise.
14437 (svr4_library_list_start_list): Likewise.
14438 * solib-target.c (library_list_start_segment): Likewise.
14439 (library_list_start_section): Likewise.
14440 (library_list_start_library): Likewise.
14441 (library_list_start_list): Likewise.
14442 * tracepoint.c (traceframe_info_start_memory): Likewise.
14443 (traceframe_info_start_tvar): Likewise.
14444 * xml-syscall.c (syscall_start_syscall): Likewise.
14445 * xml-tdesc.c (tdesc_start_target): Likewise.
14446 (tdesc_start_feature): Likewise.
14447 (tdesc_start_reg): Likewise.
14448 (tdesc_start_union): Likewise.
14449 (tdesc_start_struct): Likewise.
14450 (tdesc_start_flags): Likewise.
14451 (tdesc_start_enum): Likewise.
14452 (tdesc_start_field): Likewise.
14453 (tdesc_start_enum_value): Likewise.
14454 (tdesc_start_vector): Likewise.
14455
14456 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14457
14458 * extension.h (struct xmethod_worker) <clone>: Remove.
14459 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
14460 Remove.
14461 (python_xmethod_worker::clone): Remove.
14462 * valops.c (find_overload_match): Use std::move instead of
14463 clone.
14464
14465 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14466
14467 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
14468 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
14469 <free_xmethod_worker_data>: Remove.
14470 <get_matching_xmethod_workers>: Chance VEC to std::vector.
14471 <get_xmethod_arg_types>: Remove.
14472 <get_xmethod_result_type>: Remove.
14473 <invoke_xmethod>: Remove.
14474 * extension.c (new_xmethod_worker): Remove.
14475 (clone_xmethod_worker): Remove.
14476 (get_matching_xmethod_workers): Return void, pass std::vector by
14477 pointer.
14478 (get_xmethod_arg_types): Rename to...
14479 (xmethod_worker::get_arg_types): ... this, and adjust.
14480 (get_xmethod_result_type): Rename to...
14481 (xmethod_worker::get_result_type): ... this, and adjust.
14482 (invoke_xmethod): Remove.
14483 (free_xmethod_worker): Remove.
14484 (free_xmethod_worker_vec): Remove.
14485 * extension.h (enum ext_lang_rc): Move here from
14486 extension-priv.h.
14487 (struct xmethod_worker): Add constructor and destructor.
14488 <data>: Remove.
14489 <value>: Remove.
14490 <invoke, clone, do_get_result_type, do_get_arg_types>: New
14491 virtual pure methods.
14492 <get_arg_types, get_result_type>: New methods.
14493 (xmethod_worker_ptr): Remove typedef.
14494 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
14495 (xmethod_worker_vec): Remove typedef.
14496 (xmethod_worker_up): New typedef.
14497 (invoke_xmethod): Remove.
14498 (clone_xmethod_worker): Remove.
14499 (free_xmethod_worker): Remove.
14500 (free_xmethod_worker_vec): Remove.
14501 (get_xmethod_arg_types): Remove.
14502 (get_xmethod_result_type): Remove.
14503 * valops.c (find_method_list): Use std::vector, don't use
14504 intermediate vector.
14505 (value_find_oload_method_list): Use std::vector.
14506 (find_overload_match): Use std::vector.
14507 (find_oload_champ): Use std::vector.
14508 * value.c (value_free): Use operator delete.
14509 (value_of_xmethod): Rename to...
14510 (value_from_xmethod): ... this. Don't assign
14511 xmethod_worker::value, take rvalue-reference.
14512 (result_type_of_xmethod): Adjust.
14513 (call_xmethod): Adjust.
14514 * value.h: Include extension.h.
14515 (struct xmethod_worker): Don't forward-declare.
14516 (value_of_xmethod): Rename to...
14517 (value_from_xmethod): ... this, take rvalue-reference.
14518 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
14519 (struct python_xmethod_worker): ... this, add constructor and
14520 destructor.
14521 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
14522 (gdbpy_free_xmethod_worker_data): Rename to...
14523 (python_xmethod_worker::~python_xmethod_worker): ... this and
14524 adjust.
14525 (gdbpy_clone_xmethod_worker_data): Rename to...
14526 (python_xmethod_worker::clone): ... this and adjust.
14527 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
14528 temporary vector.
14529 (gdbpy_get_xmethod_arg_types): Rename to...
14530 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
14531 (gdbpy_get_xmethod_result_type): Rename to...
14532 (python_xmethod_worker::do_get_result_type): ... this and
14533 adjust.
14534 (gdbpy_invoke_xmethod): Rename to...
14535 (python_xmethod_worker::invoke): ... this and adjust.
14536 (new_python_xmethod_worker): Rename to...
14537 (python_xmethod_worker::python_xmethod_worker): ... this and
14538 adjust.
14539 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
14540 Remove.
14541 (gdbpy_free_xmethod_worker_data): Remove.
14542 (gdbpy_get_matching_xmethod_workers): Use std::vector.
14543 (gdbpy_get_xmethod_arg_types): Remove.
14544 (gdbpy_get_xmethod_result_type): Remove.
14545 (gdbpy_invoke_xmethod): Remove.
14546 * python/python.c (python_extension_ops): Remove obsolete
14547 callbacks.
14548
14549 2018-01-05 Pedro Alves <palves@redhat.com>
14550
14551 PR gdb/18653
14552 * common/signals-state-save-restore.c
14553 (save_original_signals_state): New parameter 'quiet'. Warn if we
14554 find a custom handler preinstalled, instead of internal erroring.
14555 But only warn if !quiet.
14556 * common/signals-state-save-restore.h
14557 (save_original_signals_state): New parameter 'quiet'.
14558 * main.c (captured_main_1): Move save_original_signals_state call
14559 after option handling, and pass QUIET.
14560
14561 2018-01-05 Pedro Alves <palves@redhat.com>
14562
14563 * spu-tdep.c (spu_catch_start): Pass
14564 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
14565
14566 2018-01-05 Pedro Alves <palves@redhat.com>
14567
14568 PR gdb/22670
14569 * ada-lang.c (literal_symbol_name_matcher): New function.
14570 (ada_get_symbol_name_matcher): Use it for
14571 symbol_name_match_type::SEARCH_NAME.
14572 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
14573 it down instead of assuming symbol_name_match_type::FULL.
14574 * block.h (block_lookup_symbol): New parameter 'match_type'.
14575 * c-valprint.c (print_unpacked_pointer): Use
14576 lookup_symbol_search_name instead of lookup_symbol.
14577 * compile/compile-object-load.c (get_out_value_type): Pass down
14578 symbol_name_match_type::SEARCH_NAME.
14579 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
14580 symbol_name_match_type::FULL.
14581 * cp-support.c (cp_get_symbol_name_matcher): Handle
14582 symbol_name_match_type::SEARCH_NAME.
14583 * infrun.c (insert_exception_resume_breakpoint): Use
14584 lookup_symbol_search_name.
14585 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
14586 * psymtab.c (maintenance_check_psymtabs): Use
14587 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
14588 * stack.c (print_frame_args): Use lookup_symbol_search_name and
14589 SYMBOL_SEARCH_NAME.
14590 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
14591 if symbol_name_match_type::SEARCH_NAME.
14592 (lookup_symbol_in_language): Pass down
14593 symbol_name_match_type::FULL.
14594 (lookup_symbol_search_name): New.
14595 (lookup_language_this): Pass down
14596 symbol_name_match_type::SEARCH_NAME.
14597 (lookup_symbol_aux, lookup_local_symbol): New parameter
14598 'match_type'. Pass it down.
14599 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
14600 (lookup_symbol_search_name): New declaration.
14601 (lookup_symbol_in_block): New 'match_type' parameter.
14602
14603 2018-01-05 Pedro Alves <palves@redhat.com>
14604
14605 PR gdb/22670
14606 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
14607 ada_lookup_symbol.
14608 (ada_lookup_symbol): Reimplement in terms of
14609 ada_lookup_symbol_list, bits factored out from
14610 ada_lookup_encoded_symbol.
14611
14612 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14613
14614 * ada-exp.y (write_object_renaming): When subscripting an array
14615 using a symbol as the index, pass the block in call to
14616 ada_lookup_encoded_symbol when looking that symbol up.
14617
14618 2018-01-05 Jerome Guitton <guitton@adacore.com>
14619
14620 * ada-lang.c (ada_array_length): Use ada_index_type instead of
14621 TYPE_INDEX_TYPE.
14622
14623 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14624
14625 * ada-lang.c (ada_to_fixed_value_create): Add handling of
14626 the case where VALUE_LVAL (val0) is not lval_memory.
14627
14628 2018-01-05 Xavier Roirand <roirand@adacore.com>
14629
14630 * ada-valprint.c (print_optional_low_bound): Handle
14631 character-indexed array printing like boolean-indexed array
14632 printing.
14633
14634 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14635
14636 * NEWS: Create a new section for the next release branch.
14637 Rename the section of the current branch, now that it has
14638 been cut.
14639
14640 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14641
14642 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
14643 * version.in: Bump version to 8.1.50.DATE-git.
14644
14645 2018-01-03 Xavier Roirand <roirand@adacore.com>
14646
14647 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
14648 Add field.
14649 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
14650 Add field.
14651 (default_exception_support_info) <catch_handlers_sym>: Add field.
14652 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
14653 (ada_exception_name_addr_1): Add "catch handlers" handling.
14654 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
14655 Update all callers.
14656 (create_excep_cond_exprs) <ex>: Add parameter.
14657 (re_set_exception): Update create_excep_cond_exprs call.
14658 (print_it_exception, print_one_exception, print_mention_exception)
14659 (print_recreate_exception): Add "catch handler" handling.
14660 (allocate_location_catch_handlers, re_set_catch_handlers)
14661 (check_status_catch_handlers, print_it_catch_handlers)
14662 (print_one_catch_handlers, print_mention_catch_handlers)
14663 (print_recreate_catch_handlers): New function.
14664 (catch_handlers_breakpoint_ops): New variable.
14665 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
14666 Add parameter. Add "catch handler" handling.
14667 (ada_exception_sym_name, ada_exception_breakpoint_ops):
14668 Add "catch handler" handling.
14669 (ada_exception_catchpoint_cond_string): Add "catch handler"
14670 handling.
14671 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
14672 call.
14673 (catch_ada_handlers_command): New function.
14674 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
14675 operations structure.
14676 (_initialize_ada_language): Add "catch handlers" command entry.
14677 * NEWS: Document "catch handlers" feature.
14678
14679 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14680
14681 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
14682 account when creating the array type of the slice.
14683 (ada_value_slice): Likewise.
14684
14685 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14686
14687 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
14688 New enum value.
14689 (create_array_type_with_stride): Add byte_stride_prop parameter.
14690 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
14691 New parameter. Update all callers in this file.
14692 (array_type_has_dynamic_stride): New function.
14693 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
14694 of arrays with dynamic byte strides.
14695 * dwarf2read.c (read_array_type): Add support for dynamic
14696 DW_AT_byte_stride attributes.
14697
14698 2018-01-02 Joel Brobecker <brobecker@adacore.com>
14699
14700 * dwarf2read.c (read_unspecified_type): Treat
14701 DW_TAG_enumeration_type DIEs from Ada units as stubs.
14702
14703 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14704
14705 Update copyright year range in all GDB files.
14706
14707 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
14708
14709 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
14710 and gdb/testsuite/gdb.base/step-line.c.
14711
14712 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14713
14714 * copyright.py (main): Dump the contents of
14715 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
14716 even if BY_HAND is empty.
14717
14718 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14719
14720 * top.c (print_gdb_version): Update Copyright year in version
14721 message.
14722
14723 2018-01-01 Joel Brobecker <brobecker@adacore.com>
14724
14725 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
14726
14727 For older changes see ChangeLog-2017.
14728 \f
14729 Local Variables:
14730 mode: change-log
14731 left-margin: 8
14732 fill-column: 74
14733 version-control: never
14734 coding: utf-8
14735 End: