c98d292087b31a3a8d55a758a3f1a1f6ac4587fc
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-12-28 Tom Tromey <tom@tromey.com>
2
3 * ui-out.h (enum class ui_out_style_kind) <ADDRESS>: New
4 constant.
5 * ui-out.c (ui_out::field_core_addr): Add styling.
6 * stack.c (print_frame): Add styling.
7 * printcmd.c (print_address): Add styling.
8 (print_address_demangle, info_address_command): Likewise.
9 * cli/cli-style.h (address_style): Declare.
10 * cli/cli-style.c (address_style): New global.
11 (_initialize_cli_style): Register new commands.
12 * cli-out.c (cli_ui_out::do_field_string): Update.
13
14 2018-12-28 Tom Tromey <tom@tromey.com>
15
16 * symfile.c (symbol_file_add_with_addrs): Style file name.
17
18 2018-12-28 Tom Tromey <tom@tromey.com>
19
20 * top.c (print_gdb_version): Style gdb version number.
21
22 2018-12-28 Tom Tromey <tom@tromey.com>
23
24 * printcmd.c (print_address_symbolic): Style function name.
25
26 2018-12-28 Tom Tromey <tom@tromey.com>
27
28 * breakpoint.c (say_where): Style file name.
29
30 2018-12-28 Tom Tromey <tom@tromey.com>
31
32 * ui-out.h (enum class ui_out_style_kind) <VARIABLE>: New global.
33 * stack.c (print_frame_arg): Style name.
34 * printcmd.c (print_variable_and_value): Style variable name.
35 * cli/cli-style.h (variable_name_style): Declare.
36 * cli/cli-style.c (variable_name_style): New global.
37 (_initialize_cli_style): Update.
38 * cli-out.c (cli_ui_out::do_field_string): Update.
39
40 2018-12-28 Tom Tromey <tom@tromey.com>
41
42 * utils.h (reset_terminal_style): Declare.
43 * utils.c (can_emit_style_escape): New function.
44 (set_output_style): Use it.
45 (reset_terminal_style): New function.
46 * printcmd.c (printf_command): Call reset_terminal_style.
47 * cli/cli-cmds.c (echo_command): Call reset_terminal_style.
48
49 2018-12-28 Tom Tromey <tom@tromey.com>
50
51 * utils.h (set_output_style, fprintf_styled)
52 (fputs_styled): Declare.
53 * utils.c (applied_style, desired_style): New globals.
54 (emit_style_escape, set_output_style): New function.
55 (prompt_for_continue): Emit style escapes.
56 (fputs_maybe_filtered): Likewise.
57 (fputs_styled, fprintf_styled): New functions.
58 * ui-out.h (enum class ui_out_style_kind): New.
59 (class ui_out) <field_string, field_stream, do_field_string>: Add
60 style parameter.
61 * ui-out.c (ui_out::field_stream, ui_out::field_string): Add style
62 parameter.
63 * tui/tui-out.h (class tui_ui_out) <do_field_string>: Add style
64 parameter.
65 * tui/tui-out.c (tui_ui_out::do_field_string): Add style
66 parameter.
67 (tui_ui_out::do_field_string): Update.
68 * tracepoint.c (print_one_static_tracepoint_marker): Style
69 output.
70 * stack.c (print_frame_info, print_frame): Style output.
71 * source.c (print_source_lines_base): Style output.
72 * skip.c (info_skip_command): Style output.
73 * record-btrace.c (btrace_call_history_src_line): Style output.
74 (btrace_call_history): Likewise.
75 * python/py-framefilter.c (py_print_frame): Style output.
76 * mi/mi-out.h (class mi_ui_out) <do_field_string>: Add style
77 parameter.
78 * mi/mi-out.c (mi_ui_out::do_table_header)
79 (mi_ui_out::do_field_int): Update.
80 (mi_ui_out::do_field_string): Update.
81 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
82 Style output.
83 * cli/cli-style.h: New file.
84 * cli/cli-style.c: New file.
85 * cli-out.h (class cli_ui_out) <do_field_string>: Add style
86 parameter.
87 * cli-out.c (cli_ui_out::do_table_header)
88 (cli_ui_out::do_field_int, cli_ui_out::do_field_skip): Update.
89 (cli_ui_out::do_field_string): Add style parameter. Style the
90 output.
91 * breakpoint.c (print_breakpoint_location): Style output.
92 (update_static_tracepoint): Likewise.
93 * Makefile.in (SUBDIR_CLI_SRCS): Add cli-style.c.
94 (HFILES_NO_SRCDIR): Add cli-style.h.
95
96 2018-12-28 Tom Tromey <tom@tromey.com>
97
98 * unittests/style-selftests.c: New file.
99 * ui-style.c: New file.
100 * ui-style.h: New file.
101 * ui-file.h: Include ui-style.h.
102 * Makefile.in (COMMON_SFILES): Add ui-style.c.
103 (HFILES_NO_SRCDIR): Add ui-style.h.
104 (SUBDIR_UNITTESTS_SRCS): Add style-selftests.c.
105
106 2018-12-28 Tom Tromey <tom@tromey.com>
107
108 * command.h (add_setshow_enum_cmd): Add "context" argument.
109 * cli/cli-decode.c (add_setshow_enum_cmd): Add "context"
110 argument. Call set_cmd_context.
111
112 2018-12-28 Tom Tromey <tom@tromey.com>
113
114 * utils.c (filter_initialized): New global.
115 (wrap_buffer): Now a std::string.
116 (wrap_pointer): Remove.
117 (flush_wrap_buffer): New function.
118 (filtered_printing_initialized, set_width, wrap_here)
119 (fputs_maybe_filtered): Update.
120
121 2018-12-28 Eli Zaretskii <eliz@gnu.org>
122
123 * coffread.c (coff_symtab_read): Don't record in minsyms symbols
124 that are unresolved. This avoids triggering an internal error
125 when stepping outside of 'main' in MinGW programs.
126
127 2018-12-27 Tom Tromey <tom@tromey.com>
128
129 * python/py-utils.c (gdbpy_handle_exception): Translate
130 PyExc_KeyboardInterrupt to quit.
131
132 2018-12-27 Tom Tromey <tom@tromey.com>
133
134 * python/python-internal.h (gdbpy_print_stack_or_quit): Declare.
135 * python/py-unwind.c (pyuw_sniffer): Use
136 gdbpy_print_stack_or_quit.
137 * python/py-framefilter.c (throw_quit_or_print_exception):
138 Remove.
139 (gdbpy_apply_frame_filter): Use gdbpy_print_stack_or_quit.
140 * python/python.c (gdbpy_print_stack_or_quit): New function.
141
142 2018-12-27 Tom Tromey <tom@tromey.com>
143
144 * python/py-value.c (convert_value_from_python): Use
145 gdbpy_convert_exception.
146 * python/py-param.c (parmpy_init): Use gdbpy_convert_exception.
147 * python/py-cmd.c (cmdpy_init): Use gdbpy_convert_exception.
148 * python/py-breakpoint.c (bppy_init): Use
149 gdbpy_convert_exception.
150
151 2018-12-27 Tom Tromey <tom@tromey.com>
152
153 * configure.nat (NATDEPFILES): Use nat/ prefix.
154 * Makefile.in (CONFIG_SRC_SUBDIR): Add nat.
155 (%.o: ${srcdir}/nat/%.c): Remove rule.
156 (INIT_FILES): Do not filter out NATDEPFILES.
157
158 2018-12-27 Tom Tromey <tom@tromey.com>
159
160 * Makefile.in (INIT_FILES): Redefine.
161 (stamp-init): Remove sed, tr invocations. Use for loop. Don't
162 set LANG or LC_ALL.
163
164 2018-12-27 Tom Tromey <tom@tromey.com>
165
166 * Makefile.in (stamp-init): Remove gdbtypes special case.
167
168 2018-12-27 John Baldwin <jhb@FreeBSD.org>
169
170 * config/i386/nm-fbsd.h: Remove file.
171 * Makefile.in (HFILES_NO_SRCDIR): Remove config/i386/nm-fbsd.h.
172 * configure.nat: Remove NAT_FILE for FreeBSD/i386.
173
174 2018-12-27 Tom Tromey <tom@tromey.com>
175
176 * minsyms.h (class minimal_symbol_reader): Use
177 DISABLE_COPY_AND_ASSIGN.
178
179 2018-12-27 Tom Tromey <tom@tromey.com>
180
181 * python/python.c (python_interactive_command): Use std::string.
182 (gdbpy_parameter): Likewise.
183 * python/py-utils.c (unicode_to_encoded_string): Update comment.
184 * python/py-symtab.c (salpy_str): Use PyString_FromFormat.
185 * python/py-record-btrace.c (recpy_bt_insn_data): Use
186 byte_vector.
187 * python/py-objfile.c (objfpy_get_build_id): Use
188 unique_xmalloc_ptr.
189 * python/py-inferior.c (infpy_read_memory): Use
190 unique_xmalloc_ptr.
191 * python/py-cmd.c (gdbpy_parse_command_name): Use std::string.
192
193 2018-12-26 Simon Marchi <simon.marchi@polymtl.ca>
194
195 * target.c (target_terminal::restore_inferior): Remove struct keyword.
196
197 2018-12-26 Simon Marchi <simon.marchi@ericsson.com>
198
199 * build-id.c (build_id_to_debug_bfd): Enhance debug output.
200 * symfile.c (separate_debug_file_exists): Likewise.
201
202 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
203
204 * c-exp.y (field_name): Allow DOUBLE_KEYWORD, INT_KEYWORD, LONG,
205 SHORT, SIGNED_KEYWORD, and UNSIGNED tokens to act as a field
206 names.
207 (typename_stoken): New function.
208
209 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
210
211 * c-exp.y (field_name): New %token, and new rule.
212 (exp): Replace uses of 'name' with 'field_name' where appropriate.
213
214 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
215
216 PR gdb/13368
217 * c-exp.y (typebase): Extend the comment.
218 (ident_tokens): Likewise.
219
220 2018-12-18 Tom Tromey <tom@tromey.com>
221
222 * dwarf2read.c (dwarf2_find_containing_comp_unit): Don't take
223 address of sect_off.
224
225 2018-12-23 Joel Brobecker <brobecker@adacore.com>
226
227 GDB 8.2.1 released.
228
229 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
230
231 * riscv-tdep.c (riscv_call_arg_struct): Don't adjust size before
232 assigning locations.
233 (riscv_return_value): Take more care not to read/write outside of
234 argument buffer. Cast return value between the declared type and
235 the abi type.
236
237 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
238
239 * riscv-tdep.c (riscv_register_reggroup_p): Save and restore fcsr,
240 fflags, and frm registers.
241
242 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
243
244 * riscv-tdep.c (riscv_dwarf_reg_to_regnum): New function.
245 (riscv_gdbarch_init): Register new function with gdbarch.
246 * riscv-tdep.h: New enum to define RISC-V DWARF register numbers.
247
248 2018-12-21 Simon Marchi <simon.marchi@ericsson.com>
249
250 * minsyms.c (mst_str): New.
251 (minimal_symbol_reader::record_full): Add debug output.
252
253 2018-12-21 John Baldwin <jhb@FreeBSD.org>
254
255 * fbsd-nat.c (fbsd_handle_debug_trap): Require pl.pl_flags to
256 equal PL_FLAG_SI.
257 (fbsd_nat_target::stopped_by_sw_breakpoint): Likewise.
258
259 2018-12-21 Paul Marechal <paul.marechal@ericsson.com>
260
261 PR gdb/23974
262 * target.c (target_read_stralloc): Check for empty vector.
263
264 2018-12-21 Дилян Палаузов <dilyan.palauzov@aegee.org>
265
266 * top.c (print_gdb_configuration): Print "--without-python"
267 if GDB was configured without Python.
268
269 2018-12-21 Andrew Burgess <andrew.burgess@embecosm.com>
270
271 * riscv-tdep.c (riscv_scan_prologue): Use plongest to format
272 a signed offset as a string.
273
274 2018-12-21 Dave Murphy <davem@devkitpro.org>
275
276 * dtrace-probe.c (dtrace_static_probe_ops): Explicit zero
277 initialise.
278 * probe.c (any_static_probe_ops): Ditto.
279 * record-btrace.c (record_btrace_thread_observer_token): Ditto.
280 * stap-probe.c (stap_static_probe_ops): Ditto.
281 * tui/tui-hooks.c (tui_observers_token): Ditto.
282 * unittests/observable-selftests.c (token1, token2, token3): Ditto.
283
284 2018-12-19 Andrew Burgess <andrew.burgess@embecosm.com>
285
286 * gdb/dummy-frame.c (default_dummy_id): Defined new function.
287 * gdb/dummy-frame.h (default_dummy_id): Declare new function.
288 * gdb/frame-unwind.c (default_unwind_pc): Define new function.
289 (default_unwind_sp): Define new function.
290 * gdb/frame-unwind.h (default_unwind_pc): Declare new function.
291 (default_unwind_sp): Declare new function.
292 * gdb/frame.c (frame_unwind_pc): Assume gdbarch_unwind_pc is
293 available.
294 (get_frame_sp): Assume that gdbarch_unwind_sp is available.
295 * gdb/gdbarch.c: Regenerate.
296 * gdb/gdbarch.h: Regenerate.
297 * gdb/gdbarch.sh: Update definition of dummy_id, unwind_pc, and
298 unwind_sp. Add additional header files to be included in
299 generated file.
300
301 2018-12-19 Dimitar Dimitrov <dimitar@dinux.eu>
302
303 * nat/linux-ptrace.c (linux_ptrace_test_ret_to_nx): Remove
304 sp clobbers.
305
306 2018-12-17 Andrew Burgess <andrew.burgess@embecosm.com>
307
308 * dwarf2read.c (struct dwarf2_cu): Convert the fields 'mark',
309 'has_loclist', 'checked_producer', 'producer_is_gxx_lt_4_6',
310 'producer_is_gcc_lt_4_3', 'producer_is_icc_lt_14',
311 'processing_has_namespace_info' from unsigned int to bool. Update
312 comments.
313 (producer_is_icc_lt_14): Update return type.
314 (producer_is_gcc_lt_4_3): Likewise.
315 (producer_is_gxx_lt_4_6): Likewise.
316 (process_die): Write true instead of 1 into predicate fields.
317 (dwarf2_start_symtab): Likewise.
318 (var_decode_location): Likewise.
319 (dwarf2_mark_helper): Likewise.
320 (dwarf2_mark): Likewise.
321 (dwarf2_clear_marks): Write false instead of 0 into predicate
322 field.
323 (dwarf2_cu::dwarf2_cu): Initialise predicate fields to false, not
324 0.
325
326 2018-12-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
327
328 * nat/aarch64-sve-linux-ptrace.h: Include signal.h instead of
329 asm/sigcontext.h.
330
331 2018-12-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
332
333 * nat/linux-ptrace.c (kill_child): Fix ARI warning by removing
334 warning trailing new line.
335
336 2018-12-16 Philippe Waroquiers <philippe.waroquiers@skynet.be>
337
338 * nat/linux-ptrace.c (kill_child): New function.
339 (linux_ptrace_test_ret_to_nx): Use kill_child instead of local code.
340 Add a call to kill_child in case of early return after fork.
341 (linux_check_ptrace_features): Use kill_child instead of local code.
342 (linux_test_for_tracefork): Likewise.
343
344 2018-12-14 Tom Tromey <tom@tromey.com>
345
346 * Makefile.in: Remove "alloca" comment.
347 (INFOFILES): Remove.
348 (local-maintainer-clean): Don't use INFOFILES.
349
350 2018-12-13 John Baldwin <jhb@FreeBSD.org>
351
352 * syscalls/update-freebsd.sh: New file.
353 * syscalls/freebsd.xml: Regenerate.
354
355 2018-12-13 John Baldwin <jhb@FreeBSD.org>
356
357 * NEWS: Add entry documenting system call aliases.
358 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
359 to get_syscalls_by_name.
360 * gdbarch.sh (UNKNOWN_SYSCALL): Remove.
361 * gdbarch.h: Regenerate.
362 * syscalls/gdb-syscalls.dtd (syscall): Add alias attribute.
363 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_name): Rename
364 from get_syscall_by_name. Now accepts a pointer to a vector of
365 integers and returns a bool.
366 [HAVE_LIBEXPAT] (struct syscall_desc): Add alias member.
367 (syscall_create_syscall_desc): Add alias parameter and pass it to
368 syscall_desc constructor.
369 (syscall_start_syscall): Handle alias attribute.
370 (syscall_attr): Add alias attribute.
371 (xml_get_syscalls_by_name): Rename from xml_get_syscall_number.
372 Now accepts a pointer to a vector of integers and returns a
373 bool. Add syscalls whose alias or name matches the requested
374 name.
375 (get_syscalls_by_name): Rename from get_syscall_by_name. Now
376 accepts a pointer to a vector of integers and returns a bool.
377 * xml-syscall.h (get_syscalls_by_name): Likewise.
378
379 2018-12-13 John Baldwin <jhb@FreeBSD.org>
380
381 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
382 to get_syscalls_by_group.
383 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_group): Return
384 false.
385 [HAVE_LIBEXPAT] (xml_list_syscalls_by_group): Append syscall
386 numbers to an existing vector of integers and return a bool.
387 (get_syscalls_by_group): Accept pointer to vector of integers
388 and change return type to bool.
389 * xml-syscall.h (get_syscalls_by_group): Likewise.
390
391 2018-12-13 Jim Wilson <jimw@sifive.com>
392
393 * riscv-tdep.c (riscv_print_one_register_info): For MSTATUS, add
394 comment for SD field, and correct xlen calculation. For MISA, add
395 comment for MXL field, add call to register_size, and correct base
396 calculation.
397
398 2018-12-13 Stafford Horne <shorne@gmail.com>
399
400 * NEWS(New targets): Add or1k*-*-linux*.
401
402 2018-12-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
403
404 * nat/linux-osdata.c (linux_xfer_osdata_info_os_types): Forward
405 declare on one line to fix ARI warning.
406
407 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
408
409 * infrun.c (infcall_suspend_state::infcall_suspend_state): New.
410 (infcall_suspend_state::registers): New.
411 (infcall_suspend_state::restore): New.
412 (infcall_suspend_state::thread_suspend): Rename to...
413 (infcall_suspend_state::m_thread_suspend): ...this.
414 (infcall_suspend_state::registers): Rename to...
415 (infcall_suspend_state::m_registers): ...this.
416 (infcall_suspend_state::siginfo_gdbarch): Rename to...
417 (infcall_suspend_state::m_siginfo_gdbarch): ...this.
418 (infcall_suspend_state::siginfo_data): Rename to...
419 (infcall_suspend_state::m_siginfo_data): ...this.
420 (save_infcall_suspend_state): Rewrite to use infcall_suspend_state
421 constructor.
422 (restore_infcall_suspend_state): Rewrite to use
423 infcall_suspend_state::restore method.
424 (get_infcall_suspend_state_regcache): Use
425 infcall_suspend_state::registers method.
426
427 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
428
429 * riscv-tdep.c (riscv_call_arg_scalar_float): Unnamed (variadic)
430 arguments are passed in integer registers.
431 (riscv_call_arg_complex_float): Likewise.
432
433 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
434
435 * nat/linux-osdata.c (common_getter): New function.
436 (struct osdata_type): Change getter to take_snapshot.
437 Add LONGEST len_avail and struct buffer buffer.
438 Change all elements in the initializer.
439 Add an element for the list of types.
440 (linux_xfer_osdata_info_os_types): New function.
441 (linux_common_xfer_osdata): Use common_getter for the list of types.
442 Replace getter call by common_getter.
443 (linux_xfer_osdata_cpus): Remove args READBUF, OFFSET, LEN.
444 Add arg BUFFER. Only keep the code that adds data in BUFFER.
445 (linux_xfer_osdata_fds): Likewise.
446 (linux_xfer_osdata_modules): Likewise.
447 (linux_xfer_osdata_msg): Likewise.
448 (linux_xfer_osdata_processes): Likewise.
449 (linux_xfer_osdata_processgroups): Likewise.
450 (linux_xfer_osdata_sem): Likewise.
451 (linux_xfer_osdata_shm): Likewise.
452 (linux_xfer_osdata_isockets): Likewise.
453 (linux_xfer_osdata_threads): Likewise.
454
455 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
456
457 * nat/linux-osdata.c: Removed various trailing spaces.
458
459 2018-12-10 Andrew Burgess <andrew.burgess@embecosm.com>
460
461 * riscv-tdep.c (riscv_register_name): Fix ARI warning by removing
462 leading whitespace before #include line.
463
464 2018-12-08 Simon Marchi <simon.marchi@ericsson.com>
465 Дилян Палаузов <dilyan.palauzov@aegee.org>
466
467 PR gdb/23950
468 * configure.ac: Search for tgetent in libtinfow.
469 * configure: Re-generate.
470
471 2018-12-08 Philippe Waroquiers <philippe.waroquiers@skynet.be>
472
473 * linux-thread-db.c (struct thread_db_info): Add td_ta_delete_p.
474 (thread_db_err_str): Forward declare.
475 (delete_thread_db_info): Call td_ta_delete_p if available.
476 (try_thread_db_load_1): Acquire td_ta_delete address.
477 * nat/gdb_thread_db.h (td_ta_delete_ftype): Declare.
478
479 2018-12-08 Pedro Alves <palves@redhat.com>
480
481 * source.c (forward_search_command): Rename to ...
482 (search_command_helper): ... this. Add 'forward' parameter.
483 Tweak to use a gdb::def_vector<char> instead of a xrealloc'ed
484 buffer. Handle backward searches too.
485 (forward_search_command, reverse_search_command): Reimplement by
486 calling search_command_helper.
487
488 2018-12-07 Andrew Burgess <andrew.burgess@embecosm.com>
489
490 * .dir-locals.el: Copy most of the settings from c-mode over to
491 c++-mode.
492
493 2018-12-08 Stafford Horne <shorne@gmail.com>
494
495 * Makefile.in (ALL_TARGET_OBS): Add or1k-linux-tdep.o.
496 * configure.tgt: Add or1k*-*-linux*.
497 * or1k-linux-tdep.c: New file.
498 * or1k-tdep.c (or1k_gdbarch_init): Call gdbarch_init_osabi.
499
500 2018-12-07 Pedro Alves <palves@redhat.com>
501
502 * dwarf2read.c (get_gdb_index_contents_from_section): Use
503 gdb::make_array_view.
504
505 2018-12-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
506
507 * language.c (_initialize_language): Fix leak by assigning
508 a static string to language. Same for range and case_sensitive,
509 even if no leak is detected for these variables.
510
511 2018-12-05 John Baldwin <jhb@FreeBSD.org>
512
513 * configure: Re-generate.
514 * configure.ac: Use separate sed expressions to escape variables
515 in auto-load directories.
516
517 2018-12-05 Andrew Burgess <andrew.burgess@embecosm.com>
518
519 * riscv-tdep.c (riscv_features_from_gdbarch_info): New function.
520 (riscv_find_default_target_description): Use new function to
521 extract feature from gdbarch_info.
522 (riscv_gdbarch_init): Add error checks for xlen and flen between
523 target description and bfd headers. Be smarter about when we
524 think the hardware floating point abi should be used.
525
526 2018-12-05 Alan Hayward <alan.hayward@arm.com>
527
528 * nat/aarch64-linux-hw-point.c
529 (aarch64_linux_any_set_debug_regs_state): New function.
530 * nat/aarch64-linux-hw-point.h
531 (aarch64_linux_any_set_debug_regs_state): New declaration.
532 * nat/aarch64-linux.c (aarch64_linux_new_thread): Check if any
533 BPs or WPs are set.
534
535 2018-11-30 John Baldwin <jhb@FreeBSD.org>
536
537 * common/filestuff.c [HAVE_KINFO_GETFILE]: Include headers.
538 (fdwalk) [HAVE_KINFO_GETFILE]: Use kinfo_getfile.
539
540 2018-11-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
541 Simon Marchi <simon.marchi@ericsson.com>
542
543 * linespec.c (symtab_vector_up): Remove.
544 (symtabs_from_filename): Change return type to std::vector.
545 (collect_symtabs_from_filename): Likewise.
546 (create_sals_line_offset): Assign return value of
547 collect_symtabs_from_filename to *ls->file_symtabs.
548 (convert_explicit_location_to_linespec): Remove call to release.
549 (parse_linespec): Likewise.
550 (symtab_collector) <symtab_collector>: Remove initialization of
551 m_symtabs.
552 <release_symtabs>: Change return type to std::vector<symtab *>.
553 <operator ()>: Adjust.
554
555 2018-11-30 John Baldwin <jhb@FreeBSD.org>
556
557 * fbsd-nat.c [__FreeBSD_version >= 700009] (USE_SIGINFO): Macro
558 defined.
559 (union sigval32, struct siginfo32, fbsd_siginfo_size)
560 (fbsd_convert_siginfo): Make conditional on USE_SIGINFO instead
561 of KERN_PROC_AUXV and PT_LWPINFO.
562 (fbsd_nat_target::xfer_partial): Define method unconditionally.
563 Make TARGET_OBJECT_SIGNAL_INFO conditional on USE_SIGINFO.
564 Make TARGET_OBJECT_AUXV conditional on KERN_PROC_AUXV.
565 Make TARGET_OBJECT_FREEBSD_VMMAP and
566 TARGET_OBJECT_FREEBSD_PS_STRINGS conditional on KERN_PROC_VMMAP
567 and KERN_PROC_PS_STRINGS.
568 * fbsd-nat.h: Include <sys/proc.h>.
569 (fbsd_nat_target::xfer_partial): Declare method unconditionally.
570
571 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
572
573 * riscv-linux-nat.c: Add 'inferior.h' and 'target-descriptions.h'
574 header files.
575 (riscv_linux_nat_target::read_description): New method.
576
577 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
578
579 * arch/riscv.h (riscv_gdbarch_features::hash): New method.
580 * arch/riscv.c (struct riscv_gdbarch_features_hasher): New.
581 (riscv_tdesc_cache): New global.
582 (riscv_create_target_description): Look in the cache before
583 creating a new target description.
584
585 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
586
587 * arch/riscv.h (riscv_gdb_features::operator==): New.
588 (riscv_gdb_features::operator!=): New.
589 * riscv-tdep.c (riscv_gdbarch_init): Make use of the inequality
590 operator.
591
592 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
593
594 * arch/riscv.h (riscv_create_target_description): Make return type
595 const.
596 * arch/riscv.c (riscv_create_target_description): Likewise.
597 * riscv-tdep.c (riscv_find_default_target_description): Likewise.
598
599 2018-11-30 Jan Kratochvil <jan.kratochvil@redhat.com>
600 Keith Seitz <keiths@redhat.com>
601 Tom Tromey <tom@tromey.com>
602 Sergio Durigan Junior <sergiodj@redhat.com>
603
604 https://bugzilla.redhat.com/show_bug.cgi?id=1613614
605 * dwarf2read.c (dwarf2_find_containing_comp_unit): Add
606 'mid_cu->length' to '*cu_off' when checking if 'sect_off' is
607 inside the CU.
608
609 2018-11-30 Pedro Alves <palves@redhat.com>
610
611 * aix-thread.c (aix_thread_target) <aix_thread_target>: Delete.
612 <stratum>: New override.
613 * bfd-target.c (aix_thread_target) <aix_thread_target>: Delete.
614 <stratum>: New override.
615 * bsd-uthread.c (bsd_uthread_target) <bsd_uthread_target>: Delete.
616 <stratum>: New override.
617 * exec.c (exec_target) <exec_target>: Delete.
618 <stratum>: New override.
619 * gdbarch-selftests.c (register_to_value_test): Adjust to use the
620 stratum method instead of the to_stratum field.
621 * linux-thread-db.c (thread_db_target) <thread_db_target>: Delete.
622 <stratum>: New override.
623 (thread_db_target::thread_db_target): Delete.
624 * make-target-delegates (print_class): Don't print a ctor
625 declaration. Print a stratum method override declaration.
626 * process-stratum-target.h (process_stratum_target)
627 <process_stratum_target>: Delete.
628 <stratum>: New override.
629 * ravenscar-thread.c (ravenscar_thread_target)
630 <ravenscar_thread_target>: Delete.
631 <stratum>: New override.
632 * record-btrace.c (record_btrace_target)
633 <record_btrace_target>: Delete.
634 <stratum>: New override.
635 * record-full.c (record_full_base_target)
636 <record_full_base_target>: Delete.
637 <stratum>: New override.
638 * record.c (record_disconnect, record_detach)
639 (record_mourn_inferior, record_kill): Adjust to use the stratum
640 method instead of the to_stratum field.
641 * regcache.c (cooked_read_test, cooked_write_test): Likewise.
642 * sol-thread.c (sol_thread_target)
643 <sol_thread_target>: Delete.
644 <stratum>: New override.
645 * spu-multiarch.c (spu_multiarch_target)
646 <spu_multiarch_target>: Delete.
647 <stratum>: New override.
648 * target-delegates.c: Regenerate.
649 * target.c (target_stack::push, target_stack::unpush)
650 (pop_all_targets_above, pop_all_targets_at_and_above)
651 (info_target_command, target_require_runnable)
652 (target_stack::find_beneath): Adjust to use the stratum method
653 instead of the to_stratum field.
654 (dummy_target::dummy_target): Delete.
655 (dummy_target::stratum): New.
656 (debug_target::debug_target): Delete.
657 (debug_target::stratum): New.
658 (maintenance_print_target_stack): Adjust to use the stratum method
659 instead of the to_stratum field.
660 * target.h (struct target_ops) <stratum>: New method.
661 <to_stratum>: Delete.
662 <is_pushed>: Adjust to use the stratum method
663 instead of the to_stratum field.
664
665 2018-11-30 Pedro Alves <palves@redhat.com>
666
667 * corelow.c (core_target) <has_all_memory, has_execution>: New
668 overrides.
669 * inf-child.c (inf_child_target::has_all_memory)
670 (inf_child_target::has_memory, inf_child_target::has_stack)
671 (inf_child_target::has_registers)
672 (inf_child_target::has_execution): Delete.
673 * inf-child.h (inf_child_target) <has_all_memory, has_memory,
674 has_stack, has_registers, has_execution>: Delete.
675 * process-stratum-target.c
676 (process_stratum_target::has_all_memory)
677 (process_stratum_target::has_memory)
678 (process_stratum_target::has_stack)
679 (process_stratum_target::has_registers)
680 (process_stratum_target::has_execution): New.
681 * process-stratum-target.h (process_stratum_target)
682 <has_all_memory, has_memory, has_stack, has_registers,
683 has_execution>: New method overrides.
684 * ravenscar-thread.c (ravenscar_thread_target) <has_all_memory,
685 has_memory, has_stack, has_registers, has_execution>: Delete.
686 * remote-sim.c (gdbsim_target) <has_stack, has_registers,
687 has_execution>: Delete.
688 * remote.c (remote_target) <has_all_memory, has_memory, has_stack,
689 has_registers, has_execution>: Delete.
690 * target.c (default_child_has_all_memory)
691 (default_child_has_memory, default_child_has_stack)
692 (default_child_has_registers, default_child_has_execution):
693 Delete.
694 * target.h (default_child_has_all_memory)
695 (default_child_has_memory, default_child_has_stack)
696 (default_child_has_registers, default_child_has_execution):
697 Delete.
698 * tracefile.h (tracefile_target) <has_execution>: New override.
699
700 2018-11-30 Pedro Alves <palves@redhat.com>
701
702 * Makefile.in (COMMON_SFILES): Add process-stratum-target.c.
703 * bsd-kvm.c: Include "process-stratum-target.h".
704 (bsd_kvm_target): Now inherits from process_stratum_target.
705 (bsd_kvm_target::bsd_kvm_target): Default it.
706 * corelow.c: Include "process-stratum-target.h".
707 (core_target): Now inherits from process_stratum_target.
708 (core_target::core_target): Don't set to_stratum here.
709 * inf-child.c (inf_child_target::inf_child_target): Delete.
710 * inf-child.h: Include "process-stratum-target.h".
711 (inf_child_target): Inherit from process_stratum_target.
712 (inf_child_target) <inf_child_target>: Default it.
713 <can_async_p, supports_non_stop, supports_disable_randomization>:
714 Delete overrides.
715 * process-stratum-target.c: New file.
716 * process-stratum-target.h: New file.
717 * remote-sim.c: Include "process-stratum-target.h".
718 (gdbsim_target): Inherit from process_stratum_target.
719 <gdbsim_target>: Default it.
720 * remote.c: Include "process-stratum-target.h".
721 (remote_target): Inherit from process_stratum_target.
722 <remote_target>: Default it.
723 * target.c (default_thread_address_space)
724 (default_thread_architecture): Delete.
725 * target.h (target_ops) <thread_architecture>: Now returns NULL by
726 default.
727 <thread_address_space>: Ditto.
728 * test-target.h: Include "process-stratum-target.h" instead of
729 "target.h".
730 (test_target_ops): Inherit from process_stratum_target.
731 <test_target_ops>: Default it.
732 * tracefile.c (tracefile_target::tracefile_target): Delete.
733 * tracefile.h: Include "process-stratum-target.h".
734 (tracefile_target): Inherit from process_stratum_target.
735 <tracefile_target>: Default it.
736 * target-delegates.c: Regenerate.
737
738 2018-11-30 Pedro Alves <palves@redhat.com>
739
740 * Makefile.in (COMMON_SFILES): Add test-target.c.
741 * gdbarch-selftests.c: Include "test-target.h".
742 * regcache.c: Include "test-target.h".
743 * target.c (test_target_info, test_target_ops::info): Move to ...
744 * test-target.c: ... this new file.
745 * target.h (test_target_ops): Move to ...
746 * test-target.h: ... this new file.
747
748 2018-11-29 Philippe Waroquiers <philippe.waroquiers@skynet.be>
749
750 * source.c (forward_search_command): Fix leak by using
751 xrealloc even for the first allocation in the loop, as buf
752 is static.
753
754 2018-11-29 Rajendra SY <rajendra.sy@gmail.com>
755
756 PR gdb/23093
757 * gdb/fbsd-tdep.c (fbsd_gdb_signal_from_target)
758 (fbsd_gdb_signal_to_target): New.
759 (fbsd_init_abi): Install gdbarch "signal_from_target" and
760 "signal_to_target" methods.
761
762 2018-11-29 Tom Tromey <tom@tromey.com>
763
764 * valarith.c (value_x_unop): Don't set argvec[3].
765
766 2018-11-26 Simon Marchi <simon.marchi@ericsson.com>
767
768 PR gdb/23917
769 * sparc-linux-nat.c (sparc_linux_nat_target): Remove extraneous
770 semicolon.
771
772 2018-11-26 Pedro Alves <palves@redhat.com>
773
774 * procfs.c (procfs_notice_thread): Replace uses of
775 in_thread_list/is_exited with find_thread_ptid/THREAD_EXITED.
776 * sol-thread.c (sol_thread_target::wait)
777 (sol_update_thread_list_callback): Likewise.
778
779 2018-11-25 Tom Tromey <tom@tromey.com>
780
781 * ui-out.c (ui_out::field_fmt): Remove comment.
782 * tui/tui-out.c (tui_ui_out::do_field_fmt): Remove comment.
783 * mi/mi-out.c (mi_ui_out::do_field_fmt): Remove comment.
784
785 2018-11-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
786
787 * source.c (open_source_file): Leak fixed in '8e6a5953e1d Fix 4K
788 leak in open_source_file' has been partially undone by '2179fbc36d23
789 Return scoped_fd from open_source_file'. Re-add the transfer of
790 current s->fullname to the unique_xmalloc_ptr fullname given
791 to find_and_open_source.
792
793 2018-11-23 Pedro Alves <palves@redhat.com>
794
795 * gdbthread.h (enum thread_state): Move comments here.
796 (is_running, is_stopped, is_exited): Remove declarations.
797
798 2018-11-22 Pedro Alves <palves@redhat.com>
799
800 * Makefile.in (COMMON_SFILES): Add thread-iter.c.
801 * breakpoint.c (breakpoints_should_be_inserted_now): Replace
802 ALL_NON_EXITED_THREADS with all_non_exited_threads.
803 (print_one_breakpoint_location): Replace ALL_INFERIORS with
804 all_inferiors.
805 * bsd-kvm.c: Include inferior.h.
806 * btrace.c (btrace_free_objfile): Replace ALL_NON_EXITED_THREADS
807 with all_non_exited_threads.
808 * common/filtered-iterator.h: New.
809 * common/safe-iterator.h: New.
810 * corelow.c (core_target_open): Don't call init_thread_list here.
811 * darwin-nat.c (thread_info_from_private_thread_info): Replace
812 ALL_THREADS with all_threads.
813 * fbsd-nat.c (fbsd_nat_target::resume): Replace
814 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
815 * fbsd-tdep.c (fbsd_make_corefile_notes): Replace
816 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
817 * fork-child.c (postfork_hook): Don't call init_thread_list here.
818 * gdbarch-selftests.c (register_to_value_test): Adjust.
819 * gdbthread.h: Don't include "inferior.h" here.
820 (struct inferior): Forward declare.
821 (enum step_over_calls_kind): Moved here from inferior.h.
822 (thread_info::deletable): Definition moved to thread.c.
823 (find_thread_ptid (inferior *, ptid_t)): Declare.
824 (ALL_THREADS, ALL_THREADS_BY_INFERIOR, ALL_THREADS_SAFE): Delete.
825 Include "thread-iter.h".
826 (all_threads, all_non_exited_threads, all_threads_safe): New.
827 (any_thread_p): Declare.
828 (thread_list): Delete.
829 * infcmd.c (signal_command): Replace ALL_NON_EXITED_THREADS with
830 all_non_exited_threads.
831 (proceed_after_attach_callback): Delete.
832 (proceed_after_attach): Take an inferior pointer instead of an
833 integer PID. Adjust to use range-for.
834 (attach_post_wait): Pass down inferior pointer instead of pid.
835 Use range-for instead of ALL_NON_EXITED_THREADS.
836 (detach_command): Remove init_thread_list call.
837 * inferior-iter.h: New.
838 * inferior.c (struct delete_thread_of_inferior_arg): Delete.
839 (delete_thread_of_inferior): Delete.
840 (delete_inferior, exit_inferior_1): Use range-for with
841 inf->threads_safe() instead of iterate_over_threads.
842 (inferior_appeared): Call init_thread_list here.
843 (discard_all_inferiors): Use all_non_exited_inferiors.
844 (find_inferior_id, find_inferior_pid): Use all_inferiors.
845 (iterate_over_inferiors): Use all_inferiors_safe.
846 (have_inferiors, number_of_live_inferiors): Use
847 all_non_exited_inferiors.
848 (number_of_inferiors): Use all_inferiors and std::distance.
849 (print_inferior): Use all_inferiors.
850 * inferior.h: Include gdbthread.h.
851 (enum step_over_calls_kind): Moved to gdbthread.h.
852 (struct inferior) <thread_list>: New field.
853 <threads, non_exited_threads, threads_safe>: New methods.
854 (ALL_INFERIORS): Delete.
855 Include "inferior-iter.h".
856 (ALL_NON_EXITED_INFERIORS): Delete.
857 (all_inferiors_safe, all_inferiors, all_non_exited_inferiors): New
858 functions.
859 * inflow.c (child_interrupt, child_pass_ctrlc): Replace
860 ALL_NON_EXITED_THREADS with all_non_exited_threads.
861 * infrun.c (follow_exec): Use all_threads_safe.
862 (clear_proceed_status, proceed): Use all_non_exited_threads.
863 (init_wait_for_inferior): Don't clear inline frame state here.
864 (infrun_thread_stop_requested, for_each_just_stopped_thread): Use
865 all_threads instead of ALL_NON_EXITED_THREADS.
866 (random_pending_event_thread): Use all_non_exited_threads instead
867 of ALL_NON_EXITED_THREADS. Use a lambda for repeated code.
868 (clean_up_just_stopped_threads_fsms): Use all_non_exited_threads
869 instead of ALL_NON_EXITED_THREADS.
870 (handle_no_resumed): Use all_non_exited_threads instead of
871 ALL_NON_EXITED_THREADS. Use all_inferiors instead of
872 ALL_INFERIORS.
873 (restart_threads, switch_back_to_stepped_thread): Use
874 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
875 * linux-nat.c (check_zombie_leaders): Replace ALL_INFERIORS with
876 all_inferiors.
877 (kill_unfollowed_fork_children): Use inf->non_exited_threads
878 instead of ALL_NON_EXITED_THREADS.
879 * linux-tdep.c (linux_make_corefile_notes): Use
880 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
881 * linux-thread-db.c (thread_db_target::update_thread_list):
882 Replace ALL_INFERIORS with all_inferiors.
883 (thread_db_target::thread_handle_to_thread_info): Use
884 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
885 * mi/mi-interp.c (multiple_inferiors_p): New.
886 (mi_on_resume_1): Simplify using all_non_exited_threads and
887 multiple_inferiors_p.
888 * mi/mi-main.c (mi_cmd_thread_list_ids): Use all_non_exited_threads
889 instead of ALL_NON_EXITED_THREADS.
890 * nto-procfs.c (nto_procfs_target::open): Don't call
891 init_thread_list here.
892 * record-btrace.c (record_btrace_target_open)
893 (record_btrace_target::stop_recording)
894 (record_btrace_target::close)
895 (record_btrace_target::record_is_replaying)
896 (record_btrace_target::resume, record_btrace_target::wait)
897 (record_btrace_target::record_stop_replaying): Use
898 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
899 * record-full.c (record_full_wait_1): Use all_non_exited_threads
900 instead of ALL_NON_EXITED_THREADS.
901 * regcache.c (cooked_read_test): Remove reference to global
902 thread_list.
903 * remote-sim.c (gdbsim_target::create_inferior): Don't call
904 init_thread_list here.
905 * remote.c (remote_target::update_thread_list): Use
906 all_threads_safe instead of ALL_NON_EXITED_THREADS.
907 (remote_target::process_initial_stop_replies): Replace
908 ALL_INFERIORS with all_non_exited_inferiors and use
909 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
910 (remote_target::open_1): Don't call init_thread_list here.
911 (remote_target::append_pending_thread_resumptions)
912 (remote_target::remote_resume_with_hc): Use all_non_exited_threads
913 instead of ALL_NON_EXITED_THREADS.
914 (remote_target::commit_resume)
915 (remote_target::remove_new_fork_children): Replace ALL_INFERIORS
916 with all_non_exited_inferiors and use all_non_exited_threads
917 instead of ALL_NON_EXITED_THREADS.
918 (remote_target::kill_new_fork_children): Use
919 all_non_exited_threads instead of ALL_NON_EXITED_THREADS. Remove
920 init_thread_list and init_wait_for_inferior calls.
921 (remote_target::remote_btrace_maybe_reopen)
922 (remote_target::thread_handle_to_thread_info): Use
923 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
924 * target.c (target_terminal::restore_inferior)
925 (target_terminal_is_ours_kind): Replace ALL_INFERIORS with
926 all_non_exited_inferiors.
927 * thread-iter.c: New file.
928 * thread-iter.h: New file.
929 * thread.c: Include "inline-frame.h".
930 (thread_list): Delete.
931 (clear_thread_inferior_resources): Call clear_inline_frame_state.
932 (init_thread_list): Use all_threads_safe instead of
933 ALL_THREADS_SAFE. Adjust to per-inferior thread lists.
934 (new_thread): Adjust to per-inferior thread lists.
935 (add_thread_silent): Pass inferior to find_thread_ptid.
936 (thread_info::deletable): New, moved from the header.
937 (delete_thread_1): Adjust to per-inferior thread lists.
938 (find_thread_global_id): Use inf->threads().
939 (find_thread_ptid): Use find_inferior_ptid and pass inferior to
940 find_thread_ptid.
941 (find_thread_ptid(inferior*, ptid_t)): New overload.
942 (iterate_over_threads): Use all_threads_safe.
943 (any_thread_p): New.
944 (thread_count): Use all_threads and std::distance.
945 (live_threads_count): Use all_non_exited_threads and
946 std::distance.
947 (valid_global_thread_id): Use all_threads.
948 (in_thread_list): Use find_thread_ptid.
949 (first_thread_of_inferior): Adjust to per-inferior thread lists.
950 (any_thread_of_inferior, any_live_thread_of_inferior): Use
951 inf->non_exited_threads().
952 (prune_threads, delete_exited_threads): Use all_threads_safe.
953 (thread_change_ptid): Pass inferior pointer to find_thread_ptid.
954 (set_resumed, set_running): Use all_non_exited_threads.
955 (is_thread_state, is_stopped, is_exited, is_running)
956 (is_executing): Delete.
957 (set_executing, set_stop_requested, finish_thread_state): Use
958 all_non_exited_threads.
959 (print_thread_info_1): Use all_inferiors and all_threads.
960 (thread_apply_all_command): Use all_non_exited_threads.
961 (thread_find_command): Use all_threads.
962 (update_threads_executing): Use all_non_exited_threads.
963 * tid-parse.c (parse_thread_id): Use inf->threads.
964 * x86-bsd-nat.c (x86bsd_dr_set): Use inf->non_exited_threads ().
965
966 2018-11-22 Pedro Alves <palves@redhat.com>
967
968 * infrun.c (follow_exec) <set follow-exec new>: Add thread and
969 switch to it before calling into try_open_exec_file.
970
971 2018-11-22 Pedro Alves <palves@redhat.com>
972
973 * cli/cli-interp.c (cli_on_user_selected_context_changed): Use
974 inferior_thread instead of find_thread_ptid, and only when
975 inferior_ptid is not null_ptid.
976 * inferior.c (add_inferior): Don't include target_pid_to_str
977 output when the inferior is not started.
978 * python/py-inferior.c (python_on_normal_stop): Don't use
979 find_thread_ptid.
980 (tui_on_user_selected_context_changed): Use inferior_thread
981 instead of find_thread_ptid, and only when inferior_ptid is not
982 null_ptid.
983
984 2018-11-21 Benno Fünfstück <benno.fuenfstueck@gmail.com>
985
986 PR python/23714
987 * gdb/python/python.c (execute_gdb_command): Call
988 prevent_dont_repeat earlier to avoid affecting dont_repeat.
989
990 2018-11-21 Andrew Burgess <andrew.burgess@embecosm.com>
991
992 * Makefile.in (ALL_TARGET_OBS): Add arch/riscv.o.
993 (HFILES_NO_SRCDIR): Add arch/riscv.h.
994 * arch/riscv.c: New file.
995 * arch/riscv.h: New file.
996 * configure.tgt: Add cpu_obs list of riscv, move riscv-tdep.o into
997 this list, and add arch/riscv.o.
998 * features/Makefile: Add riscv features.
999 * features/riscv/32bit-cpu.c: New file.
1000 * features/riscv/32bit-cpu.xml: New file.
1001 * features/riscv/32bit-csr.c: New file.
1002 * features/riscv/32bit-csr.xml: New file.
1003 * features/riscv/32bit-fpu.c: New file.
1004 * features/riscv/32bit-fpu.xml: New file.
1005 * features/riscv/64bit-cpu.c: New file.
1006 * features/riscv/64bit-cpu.xml: New file.
1007 * features/riscv/64bit-csr.c: New file.
1008 * features/riscv/64bit-csr.xml: New file.
1009 * features/riscv/64bit-fpu.c: New file.
1010 * features/riscv/64bit-fpu.xml: New file.
1011 * features/riscv/rebuild-csr-xml.sh: New file.
1012 * riscv-tdep.c: Add 'arch/riscv.h' include.
1013 (riscv_gdb_reg_names): Delete.
1014 (csr_reggroup): New global.
1015 (struct riscv_register_alias): Delete.
1016 (struct riscv_register_feature): New structure.
1017 (riscv_register_aliases): Delete.
1018 (riscv_xreg_feature): New global.
1019 (riscv_freg_feature): New global.
1020 (riscv_virtual_feature): New global.
1021 (riscv_csr_feature): New global.
1022 (riscv_create_csr_aliases): New function.
1023 (riscv_read_misa_reg): Delete.
1024 (riscv_has_feature): Delete.
1025 (riscv_isa_xlen): Simplify, just return cached xlen.
1026 (riscv_isa_flen): Simplify, just return cached flen.
1027 (riscv_has_fp_abi): Update for changes in struct gdbarch_tdep.
1028 (riscv_register_name): Update to make use of tdesc_register_name.
1029 Look up xreg and freg names in the new globals riscv_xreg_feature
1030 and riscv_freg_feature. Don't supply csr aliases here.
1031 (riscv_fpreg_q_type): Delete.
1032 (riscv_register_type): Use tdesc_register_type in almost all
1033 cases, override the returned type in a few specific cases only.
1034 (riscv_print_one_register_info): Handle errors reading registers.
1035 (riscv_register_reggroup_p): Use tdesc_register_in_reggroup_p for
1036 registers that are otherwise unknown to GDB. Also check the
1037 csr_reggroup.
1038 (riscv_print_registers_info): Remove assert about upper register
1039 number, and use gdbarch_register_reggroup_p instead of
1040 short-cutting.
1041 (riscv_find_default_target_description): New function.
1042 (riscv_check_tdesc_feature): New function.
1043 (riscv_add_reggroups): New function.
1044 (riscv_setup_register_aliases): New function.
1045 (riscv_init_reggroups): New function.
1046 (_initialize_riscv_tdep): Add calls to setup CSR aliases, and
1047 setup register groups. Register new riscv debug variable.
1048 * riscv-tdep.h: Add 'arch/riscv.h' include.
1049 (struct gdbarch_tdep): Remove abi union, and add
1050 riscv_gdbarch_features field. Remove cached quad floating point
1051 type, and provide initialisation for double type field.
1052 * target-descriptions.c (maint_print_c_tdesc_cmd): Add riscv to
1053 the list of targets using the feature based target descriptions.
1054 * NEWS: Mention target description support.
1055
1056 2018-11-21 Pedro Alves <palves@redhat.com>
1057
1058 * valops.c (find_method_list, value_find_oload_method_list)
1059 (find_overload_match, find_oload_champ): Rename parameters and
1060 locals.
1061
1062 2018-11-21 Pedro Alves <palves@redhat.com>
1063
1064 * valops.c (find_method_list): Replace pointer and length
1065 parameters with an gdb::array_view. Adjust.
1066 (value_find_oload_method_list): Likewise.
1067 (find_overload_match): Use gdb::array_view for methods list.
1068 Adjust to find_oload_champ interface change.
1069 (find_oload_champ): 'xm_worker_vec' parameter now a pointer/array.
1070 'num_fns' parameter now a size_t. Eliminate 'fn_count' local.
1071
1072 2018-11-21 Pedro Alves <palves@redhat.com>
1073
1074 * gdbtypes.c (compare_badness): Change type of parameters to const
1075 reference. Adjust to badness_vector being a std::vector now.
1076 (rank_function): Adjust to badness_vector being a std::vector now.
1077 * gdbtypes.h (badness_vector): Now a typedef to std::vector.
1078 (LENGTH_MATCH): Delete.
1079 (compare_badness): Change type of parameters to const reference.
1080 (rank_function): Return a badness_vector by value now.
1081 (find_overload_match): Adjust to badness_vector being a
1082 std::vector now. Remove cleanups.
1083 (find_oload_champ_namespace): 'oload_champ_bv' parameter now a
1084 badness_vector pointer.
1085 (find_oload_champ_namespace_loop): 'oload_champ_bv' parameter now
1086 a badness_vector pointer. Adjust to badness_vector being a
1087 std::vector now. Remove cleanups.
1088 (find_oload_champ): 'oload_champ_bv' parameter now
1089 a badness_vector pointer. Adjust to badness_vector being a
1090 std::vector now. Remove cleanups.
1091
1092 2018-11-21 Pedro Alves <palves@redhat.com>
1093
1094 * cp-support.c (sym_return_val_size, sym_return_val_index)
1095 (sym_return_val): Delete.
1096 (overload_list_add_symbol): Add std::vector parameter. Adjust to
1097 add to the vector.
1098 (make_symbol_overload_list): Adjust to return a std::vector
1099 instead of maintaining a global open coded vector.
1100 (make_symbol_overload_list_block): Add std::vector parameter.
1101 (make_symbol_overload_list_block): Rename to ...
1102 (add_symbol_overload_list_block): ... this and add std::vector
1103 parameter.
1104 (make_symbol_overload_list_namespace): Rename to ...
1105 (add_symbol_overload_list_namespace): ... this and add std::vector
1106 parameter.
1107 (make_symbol_overload_list_adl_namespace): Rename to ...
1108 (add_symbol_overload_list_adl_namespace): ... this and add
1109 std::vector parameter.
1110 (make_symbol_overload_list_adl): Delete.
1111 (add_symbol_overload_list_adl): New.
1112 (make_symbol_overload_list_using): Rename to ...
1113 (add_symbol_overload_list_using): ... this and add std::vector
1114 parameter.
1115 (make_symbol_overload_list_qualified): Rename to ...
1116 (add_symbol_overload_list_qualified): ... this and add std::vector
1117 parameter.
1118 * cp-support.h: Include "common/array-view.h" and <vector>.
1119 (make_symbol_overload_list): Change return type to std::vector.
1120 (make_symbol_overload_list_adl): Delete declaration.
1121 (add_symbol_overload_list_adl): New declaration.
1122 * valops.c (find_overload_match): Local 'oload_syms' now a
1123 std::vector.
1124 (find_oload_champ_namespace): 'oload_syms' parameter now a
1125 std::vector pointer.
1126 (find_oload_champ_namespace_loop): 'oload_syms' parameter now a
1127 std::vector pointer. Adjust to new make_symbol_overload_list
1128 interface.
1129
1130 2018-11-21 Pedro Alves <palves@redhat.com>
1131
1132 * common/array-view.h (array_view::splice(size_type, size_t)): New.
1133 (array_view::splice(size_type)): New.
1134 * eval.c (eval_call, evaluate_funcall): Adjust to use array_view.
1135 * extension.c (xmethod_worker::get_arg_types): Adjust to return an
1136 std::vector.
1137 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
1138 * extension.h: Include "common/array-view.h".
1139 (xmethod_worker::invoke): Adjust to use gdb::array_view.
1140 (xmethod_worker::get_arg_types): Adjust to return an std::vector.
1141 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
1142 (xmethod_worker::do_get_arg_types): Adjust to use std::vector.
1143 (xmethod_worker::do_get_result_type): Adjust to use
1144 gdb::array_view.
1145 * gdbtypes.c (rank_function): Adjust to use gdb::array_view.
1146 * gdbtypes.h: Include "common/array-view.h".
1147 (rank_function): Adjust to use gdb::array_view.
1148 * python/py-xmethods.c (python_xmethod_worker::invoke)
1149 (python_xmethod_worker::do_get_arg_types)
1150 (python_xmethod_worker::do_get_result_type)
1151 (python_xmethod_worker::invoke): Adjust to new interfaces.
1152 * valarith.c (value_user_defined_cpp_op, value_user_defined_op)
1153 (value_x_binop, value_x_unop): Adjust to use gdb::array_view.
1154 * valops.c (find_overload_match, find_oload_champ_namespace)
1155 (find_oload_champ_namespace_loop, find_oload_champ): Adjust to use
1156 gdb:array_view and the new xmethod_worker interfaces.
1157 * value.c (result_type_of_xmethod, call_xmethod): Adjust to use
1158 gdb::array_view.
1159 * value.h (find_overload_match, result_type_of_xmethod)
1160 (call_xmethod): Adjust to use gdb::array_view.
1161 * unittests/array-view-selftests.c: Add slicing tests.
1162
1163 2018-11-21 Pedro Alves <palves@redhat.com>
1164
1165 * ada-lang.c (ada_evaluate_subexp): Adjust to pass an array_view.
1166 * common/array-view.h (make_array_view): New.
1167 * compile/compile-object-run.c (compile_object_run): Adjust to
1168 pass an array_view.
1169 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust.
1170 * eval.c (eval_call): Adjust to pass an array_view.
1171 (evaluate_subexp_standard): Adjust to pass an array_view.
1172 * gcore.c (call_target_sbrk): Adjust to pass an array_view.
1173 * guile/scm-value.c (gdbscm_value_call): Likewise.
1174 * infcall.c (push_dummy_code): Replace pointer + size parameters
1175 with an array_view parameter.
1176 (call_function_by_hand, call_function_by_hand_dummy): Likewise and
1177 adjust.
1178 * infcall.h: Include "common/array-view.h".
1179 (call_function_by_hand, call_function_by_hand_dummy): Replace
1180 pointer + size parameters with an array_view parameter.
1181 * linux-fork.c (inferior_call_waitpid): Adjust to use array_view.
1182 * linux-tdep.c (linux_infcall_mmap): Likewise.
1183 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1184 (value_nsstring, print_object_command): Likewise.
1185 * python/py-value.c (valpy_call): Likewise.
1186 * rust-lang.c (rust_evaluate_funcall): Likewise.
1187 * spu-tdep.c (flush_ea_cache): Likewise.
1188 * valarith.c (value_x_binop, value_x_unop): Likewise.
1189 * valops.c (value_allocate_space_in_inferior): Likewise.
1190 * unittests/array-view-selftests.c (run_tests): Add
1191 gdb::make_array_view test.
1192
1193 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
1194
1195 * cli-out.c (cli_ui_out::do_field_int): Use string_printf rather
1196 than a fixed size buffer.
1197
1198 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
1199
1200 * breakpoint.c (print_one_breakpoint_location): Reduce whitespace,
1201 and remove insertion of extra spaces in GDB's output.
1202 * cli-out.c (cli_ui_out::do_field_fmt): Update header comment.
1203 Layout field into a temporary buffer, and then output it as a
1204 string field.
1205
1206 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1207
1208 * NEWS: Document the language choice done by
1209 'info [types|functions|variables]|rbreak'.
1210
1211 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1212
1213 * symtab.c (treg_matches_sym_type_name): Use
1214 scoped_switch_to_sym_language_if_auto instead of local logic.
1215 (print_symbol_info): Use scoped_switch_to_sym_language_if_auto
1216 to switch to SYM language when language mode is auto.
1217
1218 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1219
1220 * language.h (scoped_switch_to_sym_language_if_auto): New class.
1221
1222 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1223
1224 * symtab.c (search_symbols): Properly check absence of type regexp
1225 before entering the loop scanning the minimal symbols.
1226
1227 2018-11-20 John Darrington <john@darrington.wattle.id.au>
1228
1229 * s12z-tdep.c (s12z_extract_return_value): New function.
1230 (inv_reg_perm) New array.
1231 (s12z_return_value): Populate readbuf if non-null.
1232
1233 2018-11-20 Eli Zaretskii <eliz@gnu.org>
1234
1235 * common/filestuff.c (gdb_fopen_cloexec): Disable use of "e" mode
1236 with 'fopen' also if O_CLOEXEC is equal to O_NOINHERIT, to cater
1237 to MinGW fixed by Gnulib.
1238 (O_NOINHERIT): Define if not defined.
1239
1240 2018-11-19 John Darrington <john@darrington.wattle.id.au>
1241
1242 * s12z-tdep.c (s12z_frame_cache): Add an assertion.
1243
1244 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
1245
1246 * infrun.c (displaced_step_inferior_state) <next>: Remove.
1247
1248 2018-11-19 Tom Tromey <tom@tromey.com>
1249
1250 * source.c (get_filename_and_charpos): Return void.
1251
1252 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
1253
1254 * skip.c (_initialize_step_skip): Fix "info skip" help.
1255
1256 2018-11-16 Tom Tromey <tom@tromey.com>
1257
1258 PR rust/23625:
1259 * rust-lang.c (rust_internal_print_type): Handle TYPE_CODE_PTR.
1260
1261 2018-11-19 Simon Marchi <simon.marchi@ericsson.com>
1262
1263 * infrun.c (displaced_step_inferior_states): Change type to
1264 std::forward_list.
1265 (get_displaced_stepping_state): Adjust.
1266 (displaced_step_in_progress_any_inferior): Adjust.
1267 (add_displaced_stepping_state): Adjust.
1268 (remove_displaced_stepping_state): Adjust.
1269
1270 2018-11-18 Tom Tromey <tom@tromey.com>
1271
1272 PR build/23814:
1273 * target-delegates.c: Rebuild.
1274 * ia64-linux-nat.c (class ia64_linux_nat_target)
1275 <have_steppable_watchpoint>: Use override. Return true, not 1.
1276 (ia64_linux_nat_target::can_use_hw_breakpoint): Rename. Remove
1277 "self" argument.
1278 (ia64_linux_nat_target::low_new_thread): Rename.
1279 (class ia64_linux_nat_target) <read_description>: Don't declare.
1280 * target.h (struct target_ops) <have_steppable_watchpoint>: Return
1281 bool.
1282
1283 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1284
1285 PR gdb/22736:
1286 * aarch64-tdep.c (aarch64_push_dummy_call): Remove
1287 lang_struct_return code.
1288
1289 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1290
1291 * aarch64-tdep.c (aarch64_push_dummy_call): Replace arg with
1292 return_method.
1293 * alpha-tdep.c (alpha_push_dummy_call): Likewise.
1294 * amd64-tdep.c (amd64_push_arguments): Likewise.
1295 (amd64_push_dummy_call): Likewise.
1296 * amd64-windows-tdep.c (amd64_windows_push_arguments): Likewise.
1297 * arc-tdep.c (arc_push_dummy_call): Likewise.
1298 * arm-tdep.c (arm_push_dummy_call): Likewise.
1299 * avr-tdep.c (avr_push_dummy_call): Likewise.
1300 * bfin-tdep.c (bfin_push_dummy_call): Likewise.
1301 * cris-tdep.c (cris_push_dummy_call): Likewise.
1302 * csky-tdep.c (csky_push_dummy_call): Likewise.
1303 * frv-tdep.c (frv_push_dummy_call): Likewise.
1304 * gdbarch.c: Regenerate.
1305 * gdbarch.h: Regenerate.
1306 * gdbarch.sh (gdbarch_push_dummy_call): Replace arg with
1307 return_method.
1308 * h8300-tdep.c (h8300_push_dummy_call): Likewise.
1309 * hppa-tdep.c (hppa32_push_dummy_call): Likewise.
1310 (hppa64_push_dummy_call): Likewise.
1311 * i386-darwin-tdep.c (i386_darwin_push_dummy_call): Likewise.
1312 * i386-tdep.c (i386_push_dummy_call): Likewise.
1313 * ia64-tdep.c (ia64_push_dummy_call): Likewise.
1314 * infcall.c (call_function_by_hand_dummy): Likewise.
1315 * iq2000-tdep.c (iq2000_push_dummy_call): Likewise.
1316 * lm32-tdep.c (lm32_push_dummy_call): Likewise.
1317 * m32c-tdep.c (m32c_push_dummy_call): Likewise.
1318 * m32r-tdep.c (m32r_push_dummy_call): Likewise.
1319 * m68hc11-tdep.c (m68hc11_push_dummy_call): Likewise.
1320 * m68k-tdep.c (m68k_push_dummy_call): Likewise.
1321 * mep-tdep.c (mep_push_dummy_call): Likewise.
1322 * mips-tdep.c (mips_eabi_push_dummy_call): Likewise.
1323 (mips_n32n64_push_dummy_call): Likewise.
1324 (mips_o32_push_dummy_call): Likewise.
1325 (mips_o64_push_dummy_call): Likewise.
1326 * mn10300-tdep.c (mn10300_push_dummy_call): Likewise.
1327 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
1328 * nds32-tdep.c (nds32_push_dummy_call): Likewise.
1329 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
1330 * or1k-tdep.c (or1k_push_dummy_call): Likewise.
1331 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
1332 (ppc64_sysv_abi_push_dummy_call): Likewise.
1333 * ppc-tdep.h (ppc_sysv_abi_push_dummy_call): Likewise.
1334 (ppc64_sysv_abi_push_dummy_call): Likewise.
1335 * riscv-tdep.c (riscv_push_dummy_call): Likewise.
1336 * rl78-tdep.c (rl78_push_dummy_call): Likewise.
1337 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
1338 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
1339 * rx-tdep.c (rx_push_dummy_call): Likewise.
1340 * s390-tdep.c (s390_push_dummy_call): Likewise.
1341 * score-tdep.c (score_push_dummy_call): Likewise.
1342 * sh-tdep.c (sh_push_dummy_call_fpu): Likewise.
1343 (sh_push_dummy_call_nofpu): Likewise.
1344 * sparc-tdep.c (sparc32_store_arguments): Likewise.
1345 (sparc32_push_dummy_call): Likewise.
1346 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
1347 (sparc64_push_dummy_call): Likewise.
1348 * spu-tdep.c (spu_push_dummy_call): Likewise.
1349 * tic6x-tdep.c (tic6x_push_dummy_call): Likewise.
1350 * tilegx-tdep.c (tilegx_push_dummy_call): Likewise.
1351 * v850-tdep.c (v850_push_dummy_call): Likewise.
1352 * vax-tdep.c (vax_push_dummy_call): Likewise.
1353 * xstormy16-tdep.c (xstormy16_push_dummy_call): Likewise.
1354 * xtensa-tdep.c (xtensa_push_dummy_call): Likewise.
1355
1356 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1357
1358 * gdbarch.sh (enum function_call_return_method): Add enum.
1359 * gdbarch.h: Regenerate.
1360 * infcall.c (call_function_by_hand_dummy): Replace vars with enum.
1361
1362 2018-11-15 Joel Brobecker <brobecker@adacore.com>
1363
1364 * unittests/copy_bitwise-selftests.c: New file.
1365 * utils.c (selftests::bits_to_str, selftests::check_copy_bitwise)
1366 (selftests::copy_bitwise_tests): Delete, moving this code to
1367 unittests/copy_bitwise-selftests.c instead.
1368 (_initialize_utils): Do not register copy_bitwise tests.
1369 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1370 unittests/copy_bitwise-selftests.c.
1371
1372 2018-11-14 Joel Brobecker <brobecker@adacore.com>
1373
1374 * ada-lang.c (move_bits): Delete. Update all callers to use
1375 copy_bitwise instead.
1376 * dwarf2loc.c (copy_bitwise, bits_to_str::bits_to_str)
1377 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1378 Move from here to utils.c.
1379 (_initialize_dwarf2loc): Remove call to register copy_bitwise
1380 selftests.
1381 * utils.h (copy_bitwise): Add declaration.
1382 * utils.c (copy_bitwise, bits_to_str::bits_to_str)
1383 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1384 Moved here from dwarf2loc.c.
1385 (_initialize_utils): Register copy_bitwise selftests.
1386
1387 2018-11-14 Jim Wilson <jimw@sifive.com>
1388
1389 * riscv-tdep.c (struct riscv_arg_info): New field is_unnamed.
1390 (riscv_call_arg_scalar_int): If unnamed arg with twice xlen alignment,
1391 then increment next_regnum if odd.
1392 (riscv_arg_location): New arg is_unnamed. Set ainfo->is_unnamed.
1393 (riscv_push_dummy_call): New local ftype. Call check_typedef to set
1394 function type. Pass new arg to riscv_arg_location based on function
1395 type.
1396 (riscv_return_value): Pass new arg to riscv_arg_location.
1397
1398 * riscv-tdep.c (BIGGEST_ALIGNMENT): New.
1399 (riscv_type_alignment) <TYPE_CODE_ARRAY>: If TYPE_VECTOR, return min
1400 of TYPE_LENGTH and BIGGEST_ALIGNMENT.
1401
1402 * riscv-tdep.c (riscv_call_arg_scalar_int): Use std::min when
1403 setting len. New local align, set to max of arg align and xlen,
1404 and pass to first riscv_assign_stack_location call.
1405
1406 2018-11-12 Simon Marchi <simon.marchi@polymtl.ca>
1407
1408 * skip.c (complete_skip_number): New function.
1409 (_initialize_step_skip): Add completers to some skip commands.
1410
1411 2018-11-09 Tom Tromey <tom@tromey.com>
1412
1413 * remote.c (remote_g_packet_guess_s): Remove typedef and DEF_VEC.
1414 (struct remote_g_packet_data): Derive from allocate_on_obstack.
1415 <guesses>: Now a std::vector.
1416 (remote_g_packet_data_init, register_remote_g_packet_guess):
1417 Update.
1418 (remote_read_description_p): Update. Return bool.
1419 (remote_target::read_description): Update.
1420 (struct remote_g_packet_guess): Add constructor.
1421
1422 2018-11-09 Tom Tromey <tom@tromey.com>
1423
1424 * common/scoped_fd.h (class scoped_fd): Add move constructor and
1425 move assignment operator.
1426 * psymtab.c (psymtab_to_fullname): Update.
1427 * source.h (open_source_file): Return scoped_fd.
1428 (find_and_open_source): Likewise.
1429 * source.c (open_source_file): Return scoped_fd.
1430 (get_filename_and_charpos): Update.
1431 (print_source_lines_base): Update. Use scoped_fd::to_file.
1432 (forward_search_command): Likewise.
1433 (reverse_search_command): Likewise.
1434 (find_and_open_source): Return scoped_fd.
1435 * tui/tui-source.c (tui_set_source_content): Update. Use
1436 gdb_file_up.
1437
1438 2018-11-09 John Baldwin <jhb@FreeBSD.org>
1439
1440 * minsyms.c (minimal_symbol_reader::install): Fix unsigned
1441 overflow.
1442
1443 2018-11-09 Hafiz Abid Qadeer <abidh@codesourcery.com>
1444
1445 * configure: Regenerate.
1446
1447 2018-11-09 Tom de Vries <tdevries@suse.de>
1448
1449 * symtab.c (symbol_set_names): Call symbol_find_demangled_name
1450 unconditionally, to set the language of the symbol. Manage freeing
1451 returned pointer using gdb::unique_xmalloc_ptr.
1452
1453 2018-11-08 Tom Tromey <tom@tromey.com>
1454
1455 * record.c (require_record_target): Upper-case "<TAB>".
1456
1457 2018-11-08 Tom Tromey <tom@tromey.com>
1458
1459 * python/lib/gdb/command/pretty_printers.py
1460 (InfoPrettyPrinter.invoke): Don't indent "objfile" heading.
1461
1462 2018-11-08 Tom Tromey <tom@tromey.com>
1463
1464 PR gdb/23555:
1465 PR gdb/23838:
1466 * target.h (target_supports_terminal_ours): Return bool.
1467 * target.c (target_supports_terminal_ours): Handle case where
1468 current_top_target returns nullptr. Return bool.
1469
1470 2018-11-08 Joel Brobecker <brobecker@adacore.com>
1471
1472 * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1):
1473 return the correct count for potential HFAs.
1474
1475 2018-11-08 Jan Beulich <jbeulich@suse.com>
1476
1477 * i387-tdep.c (i387_supply_xsave): Split handling of
1478 X86_XSTATE_ZMM_H and X86_XSTATE_ZMM.
1479 (i387_collect_xsave): Likewise.
1480
1481 2018-11-08 Andrew Burgess <andrew.burgess@embecosm.com>
1482
1483 * riscv-tdep.c (riscv_insn::decode): Update header comment.
1484 (riscv_frame_this_id): Catch errors thrown while building the
1485 frame cache, leave the frame id as the default, which is the outer
1486 frame id.
1487
1488 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1489
1490 * ada-lang.c (read_atcb): Only set task_info->called_task if
1491 task_info->state == Entry_Caller_Sleep.
1492 (print_ada_task_info): Do not check task_info->state before
1493 checking task_info->called_task.
1494 (info_task): Likewise.
1495
1496 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1497
1498 * ada-tasks.c (read_atcb): Clear task_info before computing
1499 the value of each of its fields.
1500
1501 2018-11-07 Andrew Burgess <andrew.burgess@embecosm.com>
1502
1503 * dwarf2read.c (dwarf2_init_integer_type): Check for name being
1504 NULL before dereferencing it.
1505
1506 2018-11-06 Tom de Vries <tdevries@suse.de>
1507
1508 * linux-tdep.c (linux_vsyscall_range_raw): Use xmalloc to allocate
1509 program headers.
1510
1511 2018-11-06 Max Filippov <jcmvbkbc@gmail.com>
1512
1513 * configure.tgt (xtensa*-*-linux*): Change to xtensa*-*-*linux*
1514 so that it applies to uclinux as well.
1515
1516 2018-11-06 Marius Muench <marius.muench@eurecom.fr>
1517
1518 * arm-tdep.c (arm_scan_prologue): Don't dereference FP reg
1519 when on AAPCS.
1520
1521 2018-11-06 John Baldwin <jhb@FreeBSD.org>
1522
1523 * riscv-fbsd-nat.c (getregs_supplies): Return true for
1524 RISCV_CSR_SSTATUS_REGNUM.
1525
1526 2018-11-04 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1527
1528 * source.c (open_source_file): Fix leak by transferring the
1529 current s->fullname to the unique_xmalloc_ptr fullname given
1530 to find_and_open_source.
1531
1532 2018-11-04 Tom Tromey <tom@tromey.com>
1533
1534 * varobj.c (install_default_visualizer): Update.
1535 * python/python-internal.h (gdbpy_get_varobj_pretty_printer):
1536 Return gdbpy_ref.
1537 * python/py-prettyprint.c (search_pp_list): Return gdbpy_ref.
1538 (find_pretty_printer_from_progspace)
1539 (find_pretty_printer_from_gdb, find_pretty_printer)
1540 (gdbpy_get_varobj_pretty_printer): Return gdbpy_ref.
1541 (gdbpy_get_varobj_pretty_printer, gdbpy_default_visualizer):
1542 Update.
1543
1544 2018-11-04 Tom Tromey <tom@tromey.com>
1545
1546 * python/python.c (gdbpy_parameter_value): Update.
1547 * python/python-internal.h (python_string_to_unicode)
1548 (python_string_to_target_python_string)
1549 (host_string_to_python_string): Return gdbpy_ref.
1550 * python/py-utils.c (python_string_to_unicode)
1551 (unicode_to_encoded_python_string)
1552 (unicode_to_target_python_string)
1553 (python_string_to_target_string)
1554 (python_string_to_target_python_string): Return gdbpy_ref.
1555 (python_string_to_host_string): Update.
1556 (host_string_to_python_string): Return gdbpy_ref.
1557 * python/py-symtab.c (stpy_get_filename, stpy_get_producer)
1558 (stpy_fullname): Update.
1559 * python/py-progspace.c (pspy_get_filename, pspy_solib_name):
1560 Update.
1561 * python/py-prettyprint.c (print_string_repr): Update.
1562 * python/py-objfile.c (objfpy_get_filename, objfpy_get_username)
1563 (objfpy_get_build_id): Update.
1564 * python/py-breakpoint.c (bppy_get_location)
1565 (bppy_get_expression, bppy_get_condition, bppy_get_commands):
1566 Update.
1567
1568 2018-11-04 Tom Tromey <tom@tromey.com>
1569
1570 * python/python-internal.h (gdb_py_object_from_longest)
1571 (gdb_py_object_from_ulongest): Return gdbpy_ref.
1572 * python/py-value.c (valpy_int): Update.
1573 * python/py-utils.c (gdb_py_object_from_longest): Return
1574 gdbpy_ref.
1575 (gdb_py_object_from_ulongest): Likewise.
1576 * python/py-type.c (typy_get_alignof): Update.
1577 * python/py-linetable.c (ltpy_get_all_source_lines)
1578 (ltpy_entry_get_line, ltpy_entry_get_pc): Update.
1579 * python/py-block.c (blpy_get_start, blpy_get_end): Update.
1580
1581 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1582
1583 * ada-lang.c (_initialize_ada_language): Fix typo.
1584
1585 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1586
1587 * language.c (type): Remove.
1588 (_initialize_language): Remove assignment to type.
1589
1590 2018-11-02 Joel Brobecker <brobecker@adacore.com>
1591
1592 * aarch64-ravenscar-thread.h, aarch64-ravenscar-thread.c: New files.
1593 * aarch64-tdep.c: #include "aarch64-ravenscar-thread.h".
1594 (aarch64_gdbarch_init): Add call to register_aarch64_ravenscar_ops.
1595 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-ravenscar-thread.o.
1596 (HFILES_NO_SRCDIR): Add aarch64-ravenscar-thread.h.
1597 (ALLDEPFILES): Add aarch64-ravenscar-thread.c.
1598 * configure.tgt (cpu_obs) [aarch64*-*-*]: Add ravenscar-thread.o
1599 and aarch64-ravenscar-thread.o.
1600 * NEWS: Add entry documenting Ravenscar tasking support
1601 on AArch64 ELF.
1602
1603 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
1604
1605 * symtab.c (info_functions_command): Initialize quiet flag.
1606 * stack.c (info_args_command): Likewise.
1607
1608 2018-11-01 Jim Wilson <jimw@sifive.com>
1609
1610 * riscv-tdep.c (riscv_breakpoint_kind_from_pc): New local unaligned_p.
1611 Set if pcptr if unaligned. Return 2 if unaligned_p true. Update
1612 debugging messages.
1613
1614 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1615
1616 * ada-lang.c (ada_watch_location_expression): New function.
1617 (ada_language_defn): Set la_watch_location_expression to
1618 ada_watch_location_expression.
1619
1620 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1621
1622 * print-utils.c (int_string): Remove unnecessary trailing spaces.
1623
1624 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1625
1626 * rs6000-tdep.c (skip_prologue): Fix potential negative left
1627 shifting.
1628
1629 2018-11-01 Jerome Guitton <guitton@adacore.com>
1630 Joel Brobecker <brobecker@adacore.com>
1631
1632 * defs.h (enum gdb_osabi): Add GDB_OSABI_PIKEOS.
1633 * osabi.c (gdb_osabi_names): Add name for GDB_OSABI_PIKEOS.
1634 * arm-pikeos-tdep.c: New file.
1635 * configure.tgt: Add arm-pikeos-tdep.o to the case of ARM
1636 embedded system.
1637 * Makefile.in (ALL_TARGET_OBS): Add arm-pikeos-tdep.o.
1638
1639 2018-11-01 Simon Marchi <simon.marchi@ericsson.com>
1640
1641 * common/pathstuff.c (get_standard_temp_dir): New.
1642 * common/pathstuff.h (get_standard_temp_dir): New.
1643 * config.in: Re-generate.
1644 * configure: Re-generate.
1645 * configure.ac: Don't check for mkdtemp.
1646 * gnulib/aclocal-m4-deps.mk: Re-generate.
1647 * gnulib/aclocal.m4: Re-generate.
1648 * gnulib/config.in: Re-generate.
1649 * gnulib/configure: Re-generate.
1650 * gnulib/import/Makefile.am: Re-generate.
1651 * gnulib/import/Makefile.in: Re-generate.
1652 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1653 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1654 * gnulib/import/m4/mkdtemp.m4: New file.
1655 * gnulib/import/mkdtemp.c: New file.
1656 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES):
1657 Add mkdtemp module.
1658 * unittests/mkdir-recursive-selftests.c (test): Use
1659 get_standard_temp_dir.
1660 (_initialize_mkdir_recursive_selftests): Remove HAVE_MKDTEMP
1661 ifdef.
1662 * compile/compile.c (get_compile_file_tempdir): Likewise.
1663
1664 2018-11-01 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1665
1666 * rs6000-aix-tdep.c: Include "trad-frame.h" and "frame-unwind.h".
1667 (SIG_FRAME_LR_OFFSET64): New define.
1668 (SIG_FRAME_FP_OFFSET64): New define.
1669 (aix_sighandle_frame_cache): New Function.
1670 (aix_sighandle_frame_this_id): New Function.
1671 (aix_sighandle_frame_prev_register): New Function.
1672 (aix_sighandle_frame_sniffer): New Function.
1673 (aix_sighandle_frame_unwind): New global variable.
1674 (rs6000_aix_init_osabi): Install new frame unwinder.
1675
1676 2018-10-31 Sergio Durigan Junior <sergiodj@redhat.com>
1677
1678 PR gdb/23835
1679 * common/common-defs.h: Don't redefine _FORTIFY_SOURCE if it's
1680 already defined.
1681
1682 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1683
1684 * ppc-linux-nat.c: Include nat/linux-ptrace.h.
1685
1686 2018-10-31 Andrew Burgess <andrew.burgess@embecosm.com>
1687
1688 * dwarf2read.c (struct dwarf2_cu): Add producer_is_icc field.
1689 (producer_is_icc): New function.
1690 (check_producer): Set producer_is_icc field on dwarf2_cu.
1691 (dwarf2_init_integer_type): New function.
1692 (read_base_type): Call dwarf2_init_integer_type instead of
1693 init_integer_type in all cases.
1694 (dwarf2_cu::dwarf2_cu): Initialise producer_is_icc field.
1695 * valprint.c (maybe_negate_by_bytes): Add an assertion that the
1696 LEN is greater than 0.
1697
1698 2018-10-30 Tom Tromey <tom@tromey.com>
1699
1700 * main.c (captured_main_1): Check return value of bfd_init.
1701
1702 2018-10-29 Sergio Durigan Junior <sergiodj@redhat.com>
1703
1704 * common/offset-type.h (DEFINE_OFFSET_REL_OP): Delete.
1705 Adjust comments.
1706
1707 2018-10-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1708
1709 * procfs.c: Include common/pathstuff.h.
1710
1711 2018-10-28 Andrew Burgess <andrew.burgess@embecosm.com>
1712
1713 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1714 Add missing braces. No functional change.
1715
1716 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1717
1718 * macrocmd.c (info_macro_command): Use report_unrecognized_option_error
1719 to report a bad option and fix indentation.
1720 * demangle.c (demangle_command): Use report_unrecognized_option_error
1721 to report a bad option and correctly report the bad option.
1722
1723 2018-10-27 Tom Tromey <tom@tromey.com>
1724
1725 PR cli/23364:
1726 * darwin-nat.c (copied_shell): New global.
1727 (may_have_sip): Rename from should_disable_startup_with_shell.
1728 (copy_shell_to_cache, maybe_cache_shell): New functions.
1729 (darwin_nat_target::create_inferior): Update. Use
1730 copied_shell.
1731
1732 2018-10-27 Tom Tromey <tom@tromey.com>
1733
1734 * unittests/scoped_fd-selftests.c (test_to_file): New function.
1735 (run_tests): Call test_to_file.
1736 * dwarf-index-write.c (write_psymtabs_to_index): Do not reopen
1737 temporary files.
1738 * common/scoped_fd.h (scoped_fd::to_file): New method.
1739
1740 2018-10-27 Tom Tromey <tom@tromey.com>
1741
1742 * unittests/scoped_mmap-selftests.c (test_normal): Use
1743 gdb_mkostemp_cloexec.
1744 * unittests/scoped_fd-selftests.c (test_destroy, test_release):
1745 Use gdb_mkostemp_cloexec.
1746 * gnulib/aclocal-m4-deps.mk, gnulib/aclocal.m4,
1747 gnulib/config.in, gnulib/configure,
1748 gnulib/import/Makefile.am, gnulib/import/Makefile.in,
1749 gnulib/import/m4/gnulib-cache.m4,
1750 gnulib/import/m4/gnulib-comp.m4: Update.
1751 * gnulib/import/m4/mkostemp.m4: New file.
1752 * gnulib/import/m4/mkstemp.m4: Remove.
1753 * gnulib/import/mkostemp.c: New file.
1754 * gnulib/import/mkstemp.m4: Remove.
1755 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Remove
1756 mkstemp, add mkostemp. Apply new patch.
1757 * gnulib/import/stdlib.in.h: Apply patch.
1758 * gnulib/patches/0002-mkostemp-mkostemps-Fix-compilation-error-in-C-mode-o.patch:
1759 New file.
1760 * dwarf-index-write.c (write_psymtabs_to_index): Use
1761 gdb_mkostemp_cloexec.
1762 * common/filestuff.h (gdb_mkostemp_cloexec): New function.
1763
1764 2018-10-27 Tom Tromey <tom@tromey.com>
1765
1766 * unittests/mkdir-recursive-selftests.c: New file.
1767 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1768 unittests/mkdir-recursive-selftests.c.
1769 * dwarf-index-cache.c (mkdir_recursive): Move to
1770 common/filestuff.c.
1771 (index_cache::store): Check return value of mkdir_recursive.
1772 (create_dir_and_check, test_mkdir_recursive): Move to new file.
1773 (_initialize_index_cache): Don't register test.
1774 * common/filestuff.h (mkdir_recursive): Declare.
1775 * common/filestuff.c (mkdir_recursive): Move from
1776 dwarf-index-cache.c. Return bool.
1777
1778 2018-10-27 Tom Tromey <tom@tromey.com>
1779
1780 * dwarf-index-write.c (write_psymtabs_to_index): Move
1781 make_temp_filename to common/pathstuff.c.
1782 * common/pathstuff.h (make_temp_filename): Declare.
1783 * common/pathstuff.c (make_temp_filename): New function, moved
1784 from dwarf-index-write.c.
1785
1786 2018-10-27 Tom Tromey <tom@tromey.com>
1787
1788 * procfs.c (procfs_target::create_inferior): Use get_shell.
1789 * cli/cli-cmds.c (shell_escape): Use get_shell.
1790 * windows-nat.c (windows_nat_target::create_inferior): Use
1791 get_shell.
1792 * common/pathstuff.c (get_shell): New function.
1793 * nat/fork-inferior.c (SHELL_FILE, get_startup_shell): Remove.
1794 (fork_inferior): Use get_shell.
1795 * common/pathstuff.h (get_shell): Declare.
1796
1797 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1798
1799 * NEWS: Mention changes to 'info [args|functions|locals|variables]'
1800
1801 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1802
1803 * stack.c (print_variable_and_value_data): Add preg and treg.
1804 (print_frame_local_vars): Add quiet, regexp and t_regexp arguments,
1805 and update callers.
1806 (print_frame_arg_vars): Likewise.
1807 (prepare_reg): New function.
1808 (info_locals_command): Extract info print args and use them.
1809 (info_args_command): Likewise.
1810 (_initialize_stack): Modify on-line help.
1811 * symtab.c (treg_matches_sym_type_name): New function.
1812 (search_symbols): New arg t_regexp.
1813 (symtab_symbol_info): New args quiet, regexp, t_regexp.
1814 (info_variables_command): Extract info print args and use them.
1815 (info_functions_command): Likewise.
1816 (info_types_command): Update call to symtab_symbol_info.
1817 (_initialize_symtab): Modify on-line help.
1818 * symtab.h (treg_matches_sym_type_name): New function.
1819 (search_symbols): New t_regexp arg.
1820
1821 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1822
1823 * cli-utils.c (extract_arg_maybe_quoted): New function.
1824 (extract_info_print_args): New function.
1825 (info_print_args_help): New function.
1826 (report_unrecognized_option_error): New function.
1827 * cli-utils.h (extract_arg_maybe_quoted): New function.
1828 (extract_info_print_args): New function.
1829 (info_print_args_help): New function.
1830 (report_unrecognized_option_error): New function.
1831
1832 2018-10-26 Tom Tromey <tom@tromey.com>
1833
1834 * dwarf2read.c (recursively_compute_inclusions): Use std::vector.
1835 (compute_compunit_symtab_includes): Update.
1836 * symtab.h: (symtab_ptr): Remove typedef. Don't define a VEC.
1837 (compunit_symtab_ptr): Likewise.
1838
1839 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1840
1841 * fbsd-tdep.c (fbsd_print_auxv_entry): Only use
1842 default_print_auxv_entry for specific tag values.
1843
1844 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1845
1846 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_HWCAP2.
1847
1848 2018-10-26 Jim Wilson <jimw@sifive.com>
1849
1850 * riscv-linux-tdep.c: Include tramp-frame.h and trad-frame.h.
1851 (riscv_linux_sigframe_init): Declare.
1852 (RISCV_INST_LI_A7_SIGRETURN, RISCV_INT_ECALL): New.
1853 (riscv_linux_sigframe): New.
1854 (SIGFRAME_SIGINFO_SIZE, UCONTEXT_MCONTEXT_OFFSET): New.
1855 (riscv_linux_sigframe_init): Define.
1856 (riscv_linux_init_abi): Call tramp_frame_prepend_unwinder.
1857
1858 * riscv-tdep.c (riscv_isa_xlen): Refer to riscv-tdep.h comment.
1859 (riscv_isa_flen): Likewise. Drop static.
1860 * riscv-tdep.h (riscv_isa_xlen): Move riscv-tdep.c comment to here.
1861 (riscv_isa_flen): Likewise. Declare.
1862
1863 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1864 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1865
1866 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_htm_vsx32l)
1867 (tdesc_powerpc_isa207_htm_vsx64l): Declare.
1868 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TM_SPRREGSET)
1869 (PPC32_LINUX_SIZEOF_CGPRREGSET, PPC64_LINUX_SIZEOF_CGPRREGSET)
1870 (PPC_LINUX_SIZEOF_CFPRREGSET, PPC_LINUX_SIZEOF_CVMXREGSET)
1871 (PPC_LINUX_SIZEOF_CVSXREGSET, PPC_LINUX_SIZEOF_CPPRREGSET)
1872 (PPC_LINUX_SIZEOF_CDSCRREGSET, PPC_LINUX_SIZEOF_CTARREGSET):
1873 Define.
1874 (struct ppc_linux_features) <htm>: New field.
1875 (ppc_linux_no_features): Add initializer for htm field.
1876 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1877 new tdescs.
1878 * nat/ppc-linux.h (PPC_FEATURE2_HTM, NT_PPC_TM_CGPR)
1879 (NT_PPC_TM_CFPR, NT_PPC_TM_CVMX, NT_PPC_TM_CVSX)
1880 (NT_PPC_TM_SPR, NT_PPC_TM_CTAR, NT_PPC_TM_CPPR, NT_PPC_TM_CDSCR):
1881 Define if not already defined.
1882 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-htm-vsx32l
1883 and rs6000/powerpc-isa207-htm-vsx64l.
1884 (XMLTOC): Add rs6000/powerpc-isa207-htm-vsx32l.xml and
1885 rs6000/powerpc-isa207-htm-vsx64l.xml.
1886 * features/rs6000/power-htm-spr.xml: New file.
1887 * features/rs6000/power-htm-core.xml: New file.
1888 * features/rs6000/power64-htm-core.xml: New file.
1889 * features/rs6000/power-htm-fpu.xml: New file.
1890 * features/rs6000/power-htm-altivec.xml: New file.
1891 * features/rs6000/power-htm-vsx.xml: New file.
1892 * features/rs6000/power-htm-ppr.xml: New file.
1893 * features/rs6000/power-htm-dscr.xml: New file.
1894 * features/rs6000/power-htm-tar.xml: New file.
1895 * features/rs6000/powerpc-isa207-htm-vsx32l.xml: New file.
1896 * features/rs6000/powerpc-isa207-htm-vsx64l.xml: New file.
1897 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Generate.
1898 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Generate.
1899 * regformats/rs6000/powerpc-isa207-htm-vsx32l.dat: Generate.
1900 * regformats/rs6000/powerpc-isa207-htm-vsx64l.dat: Generate.
1901 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1902 fetch_regset with HTM regsets.
1903 (store_register, store_ppc_registers): Call store_regset with HTM
1904 regsets.
1905 (ppc_linux_nat_target::read_description): Set htm field in the
1906 features struct if needed.
1907 * ppc-linux-tdep.c: Include
1908 features/rs6000/powerpc-isa207-htm-vsx32l.c and
1909 features/rs6000/powerpc-isa207-htm-vsx64l.c.
1910 (ppc32_regmap_tm_spr, ppc32_regmap_cgpr, ppc64_le_regmap_cgpr)
1911 (ppc64_be_regmap_cgpr, ppc32_regmap_cfpr, ppc32_le_regmap_cvmx)
1912 (ppc32_be_regmap_cvmx, ppc32_regmap_cvsx, ppc32_regmap_cppr)
1913 (ppc32_regmap_cdscr, ppc32_regmap_ctar): New globals.
1914 (ppc32_linux_tm_sprregset, ppc32_linux_cgprregset)
1915 (ppc64_be_linux_cgprregset, ppc64_le_linux_cgprregset)
1916 (ppc32_linux_cfprregset, ppc32_le_linux_cvmxregset)
1917 (ppc32_be_linux_cvmxregset, ppc32_linux_cvsxregset)
1918 (ppc32_linux_cpprregset, ppc32_linux_cdscrregset)
1919 (ppc32_linux_ctarregset): New globals.
1920 (ppc_linux_cgprregset, ppc_linux_cvmxregset): New functions.
1921 (ppc_linux_collect_core_cpgrregset): New function.
1922 (ppc_linux_iterate_over_regset_sections): Call back with the htm
1923 regsets.
1924 (ppc_linux_core_read_description): Check if the tm spr section is
1925 present and set htm in the features struct.
1926 (_initialize_ppc_linux_tdep): Call
1927 initialize_tdesc_powerpc_isa207_htm_vsx32l and
1928 initialize_tdesc_powerpc_isa207_htm_vsx64l.
1929 * ppc-linux-tdep.h (ppc_linux_cgprregset, ppc_linux_cvmxregset):
1930 Declare.
1931 (ppc32_linux_tm_sprregset, ppc32_linux_cfprregset)
1932 (ppc32_linux_cvsxregset, ppc32_linux_cpprregset)
1933 (ppc32_linux_cdscrregset, ppc32_linux_ctarregset): Declare.
1934 * ppc-tdep.h (struct gdbarch_tdep) <have_htm_spr, have_htm_core>:
1935 New fields.
1936 <have_htm_fpu, have_htm_altivec, have_htm_vsx>:
1937 Likewise.
1938 <ppc_cppr_regnum, ppc_cdscr_regnum, ppc_ctar_regnum>: Likewise.
1939 <ppc_cdl0_regnum, ppc_cvsr0_regnum, ppc_cefpr0_regnum>: Likewise.
1940 (enum) <PPC_TFHAR_REGNUM, PPC_TEXASR_REGNUM, PPC_TFIAR_REGNUM>:
1941 New enum fields.
1942 <PPC_CR0_REGNUM, PPC_CCR_REGNUM, PPC_CXER_REGNUM>: Likewise.
1943 <PPC_CLR_REGNUM, PPC_CCTR_REGNUM, PPC_CF0_REGNUM>: Likewise.
1944 <PPC_CFPSCR_REGNUM, PPC_CVR0_REGNUM, PPC_CVSCR_REGNUM>: Likewise.
1945 <PPC_CVRSAVE_REGNUM, PPC_CVSR0_UPPER_REGNUM>: Likewise.
1946 <PPC_CPPR_REGNUM, PPC_CDSCR_REGNUM>: Likewise.
1947 <PPC_CTAR_REGNUM>: Likewise.
1948 (PPC_IS_TMSPR_REGNUM, PPC_IS_CKPTGP_REGNUM, PPC_IS_CKPTFP_REGNUM)
1949 (PPC_IS_CKPTVMX_REGNUM, PPC_IS_CKPTVSX_REGNUM): Define.
1950 * rs6000-tdep.c (IS_CDFP_PSEUDOREG, IS_CVSX_PSEUDOREG)
1951 (IS_CEFP_PSEUDOREG): Define.
1952 (rs6000_register_name): Hide the upper halves of checkpointed VSX
1953 registers. Return names for the checkpointed DFP, VSX, and EFP
1954 pseudo registers.
1955 (rs6000_pseudo_register_type): Remove initial assert and raise an
1956 internal error in the else clause instead. Return types for the
1957 checkpointed DFP, VSX, and EFP pseudo registers.
1958 (dfp_pseudo_register_read, dfp_pseudo_register_write): Handle
1959 checkpointed DFP pseudo registers.
1960 (vsx_pseudo_register_read, vsx_pseudo_register_write): Handle
1961 checkpointed VSX pseudo registers.
1962 (efp_pseudo_register_read, efp_pseudo_register_write): Rename
1963 from efpr_pseudo_register_read and
1964 efpr_pseudo_register_write. Handle checkpointed EFP pseudo
1965 registers.
1966 (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
1967 Handle checkpointed DFP, VSX, and EFP registers.
1968 (dfp_ax_pseudo_register_collect, vsx_ax_pseudo_register_collect)
1969 (efp_ax_pseudo_register_collect): New functions.
1970 (rs6000_ax_pseudo_register_collect): Move DFP, VSX and EFP pseudo
1971 register logic to new functions. Handle checkpointed DFP, VSX,
1972 and EFP pseudo registers.
1973 (rs6000_gdbarch_init): Look for and validate the htm features.
1974 Include checkpointed DFP, VSX and EFP pseudo-registers.
1975 * NEWS: Mention access to PPR, DSCR, TAR, EBB/PMU registers and
1976 HTM registers.
1977
1978 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1979
1980 * rs6000-tdep.c (rs6000_gdbarch_init): Reject tdescs with vsx but
1981 without altivec or fpu.
1982
1983 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1984 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1985
1986 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
1987 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
1988 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
1989 Define if not already defined.
1990 * features/rs6000/power-ebb.xml: New file.
1991 * features/rs6000/power-linux-pmu.xml: New file.
1992 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
1993 features.
1994 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
1995 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
1996 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
1997 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
1998 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
1999 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
2000 fetch_regset with ebb and pmu regsets.
2001 (store_register, store_ppc_registers): Call store_regset with ebb
2002 and pmu regsets.
2003 (ppc_linux_nat_target::read_description): Set isa207 field in the
2004 features struct if ebb and pmu are avaiable.
2005 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
2006 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
2007 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
2008 and pmu regsets.
2009 (ppc_linux_core_read_description): Check if the pmu section is
2010 present and set isa207 in the features struct.
2011 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
2012 (ppc32_linux_pmuregset): Declare.
2013 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
2014 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
2015 <ppc_sier_regnum>: New field.
2016 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
2017 New enum values.
2018 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
2019 values.
2020 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
2021 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
2022 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
2023 ebb and pmu features.
2024
2025 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2026 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2027
2028 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
2029 (tdesc_powerpc_isa207_vsx64l): Declare.
2030 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
2031 (struct ppc_linux_features) <isa207>: New field.
2032 (ppc_linux_no_features): Add initializer for isa207 field.
2033 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
2034 new tdescs.
2035 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
2036 (NT_PPC_TAR): Define if not already defined.
2037 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
2038 rs6000/powerpc-isa207-vsx64l.
2039 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
2040 rs6000/powerpc-isa207-vsx64l.xml.
2041 * features/rs6000/power-tar.xml: New file.
2042 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
2043 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
2044 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
2045 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
2046 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
2047 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
2048 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
2049 fetch_regset with the TAR regset.
2050 (store_register, store_ppc_registers): Call store_regset with the
2051 TAR regset.
2052 (ppc_linux_nat_target::read_description): Set isa207 field in the
2053 features struct if needed.
2054 * ppc-linux-tdep.c: Include
2055 features/rs6000/powerpc-isa207-vsx32l.c and
2056 features/rs6000/powerpc-isa207-vsx64l.c.
2057 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
2058 (ppc_linux_iterate_over_regset_sections): Call back with the tar
2059 regset.
2060 (ppc_linux_core_read_description): Check if the tar section is
2061 present and set isa207 in the features struct.
2062 (_initialize_ppc_linux_tdep): Call
2063 initialize_tdesc_powerpc_isa207_vsx32l and
2064 initialize_tdesc_powerpc_isa207_vsx64l.
2065 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
2066 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
2067 (enum) <PPC_TAR_REGNUM>: New enum value.
2068 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
2069 feature.
2070 (ppc_process_record_op31): Record changes to TAR.
2071
2072 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2073 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2074
2075 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
2076 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
2077 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
2078 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
2079 (struct ppc_linux_features) <ppr_dscr>: New field.
2080 (ppc_linux_no_features): Add initializer for ppr_dscr field.
2081 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
2082 new tdescs.
2083 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
2084 Define if not already defined.
2085 * features/Makefile (WHICH): Add
2086 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
2087 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
2088 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
2089 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
2090 * features/rs6000/power-dscr.xml: New file.
2091 * features/rs6000/power-ppr.xml: New file.
2092 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
2093 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
2094 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
2095 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
2096 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
2097 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
2098 * ppc-linux-nat.c: Include <sys/uio.h>.
2099 (fetch_regset, store_regset, check_regset): New functions.
2100 (fetch_register, fetch_ppc_registers): Call fetch_regset with
2101 DSCR and PPR regsets.
2102 (store_register, store_ppc_registers): Call store_regset with
2103 DSCR and PPR regsets.
2104 (ppc_linux_get_hwcap2): New function.
2105 (ppc_linux_nat_target::read_description): Call
2106 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
2107 features struct if needed.
2108 * ppc-linux-tdep.c: Include
2109 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
2110 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
2111 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
2112 (ppc32_linux_dscrregset): New globals.
2113 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
2114 and dscr regsets.
2115 (ppc_linux_core_read_description): Check if the ppr and dscr
2116 sections are present and set ppr_dscr in the features struct.
2117 (_initialize_ppc_linux_tdep): Call
2118 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
2119 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
2120 * ppc-linux-tdep.h (ppc32_linux_pprregset)
2121 (ppc32_linux_dscrregset): Declare.
2122 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
2123 <ppc_dscr_regnum>: New field.
2124 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
2125 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
2126 and dscr features.
2127 (ppc_process_record_op31): Record changes to PPR and DSCR.
2128
2129 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2130
2131 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
2132 second initializer line for the have_* variables. Initialize
2133 have_fpu to 0 instead of 1.
2134
2135 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2136
2137 * arch/ppc-linux-common.c (ppc_linux_match_description):
2138 Parenthesize tdesc assignements and indent them properly.
2139
2140 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2141
2142 * ppc-linux-nat.c (fetch_register): Change if statement to else
2143 if.
2144 (store_register): Likewise.
2145
2146 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2147
2148 * rs6000-tdep.c: Remove reggroups.h include.
2149 (rs6000_pseudo_register_reggroup_p): Remove.
2150 (rs6000_gdbarch_init): Remove call to
2151 set_tdesc_pseudo_register_reggroup_p.
2152
2153 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2154
2155 * reggroups.c (default_register_reggroup_p): Return true for
2156 decfloat registers and float_reggroup.
2157
2158 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2159
2160 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
2161 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
2162 ppc_linux_collect_vrregset by regcache_collect_regset.
2163
2164 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2165
2166 * linux-tdep.c (linux_collect_regset_section_cb): Use
2167 std::vector<gdb_byte> instead of char * and malloc for buf.
2168 Remove xfree.
2169
2170 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
2171
2172 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
2173 symtab_start instead of always using language_unknown.
2174
2175 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
2176
2177 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
2178 READ_P parameter, catch and ignore register access errors from
2179 either the old or new MISA location.
2180 (riscv_has_feature): Update call to riscv_read_misa_reg.
2181
2182 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2183
2184 * python/py-function.c (convert_values_to_python): Return
2185 gdbpy_ref<>. Add header comment.
2186 (fnpy_call): Adjust.
2187
2188 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2189
2190 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
2191 (cmdpy_completer_handle_brkchars): Adjust.
2192 (cmdpy_completer): Adjust.
2193
2194 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2195
2196 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
2197 Pass correct regnum to raw_supply_zeroed.
2198
2199 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
2200
2201 * regcache.c (cooked_read_test): Add CSKY to the list of
2202 architectures with a save_reggroup
2203
2204 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
2205
2206 PR gdb/23368
2207 * infrun.c (follow_exec): In the follow_exec_mode_new case,
2208 transfer terminal state from old new new inferior.
2209 * terminal.h (swap_terminal_info): New function.
2210 * inflow.c (swap_terminal_info): New function.
2211
2212 2018-10-23 Tom Tromey <tom@tromey.com>
2213
2214 * record-btrace.c (get_thread_current_frame_id): Rename from
2215 get_thread_current_frame. Return a frame_id.
2216 (record_btrace_start_replaying): Update.
2217
2218 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
2219
2220 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
2221 for CSRs.
2222
2223 2018-10-23 Joel Brobecker <brobecker@adacore.com>
2224
2225 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
2226 have_nonsteppable_watchpoint attribute to 1.
2227
2228 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
2229
2230 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
2231 register names.
2232 (struct register_alias): Rename to...
2233 (struct riscv_register_alias): ...this, and update comment.
2234 (riscv_register_aliases): Update type, and alias names. Remove
2235 CSR names from this list.
2236 (riscv_register_name): Use riscv_gdb_reg_names for int and float
2237 register names. Add an extra assertion.
2238 (riscv_is_regnum_a_named_csr): New function.
2239 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
2240
2241 2018-10-23 John Darrington <john@darrington.wattle.id.au>
2242
2243 * configure.tgt: Add configuration for s12z.
2244 * s12z-tdep.c: New file.
2245 * NEWS: Mention new target.
2246
2247 2018-10-22 Jim Wilson <jimw@sifive.com>
2248
2249 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
2250 FP reg smaller than FP reg size, and fill with -1 instead of 0.
2251
2252 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
2253 (riscv_register_type): Use them.
2254 (riscv_print_one_register_info): Handle union of floats same as float.
2255 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
2256 riscv_fpreg_q_type fields.
2257
2258 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
2259
2260 * gdbarch.sh (gdbarch_num_cooked_regs): New.
2261 * gdbarch.h: Re-generate.
2262 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
2263 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
2264 * eval.c (evaluate_subexp_standard): Likewise.
2265 * findvar.c (value_of_register): Likewise.
2266 (value_of_register_lazy): Likewise.
2267 (address_from_register): Likewise.
2268 * frame.c (get_frame_register_bytes): Likewise.
2269 * gdbarch-selftests.c (register_to_value_test): Likewise.
2270 * h8300-tdep.c (h8300_register_type): Likewise.
2271 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
2272 (i386_svr4_reg_to_regnum): Likewise.
2273 * infcmd.c (default_print_registers_info): Likewise.
2274 (registers_info): Likewise.
2275 (print_vector_info): Likewise.
2276 (default_print_float_info): Likewise.
2277 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
2278 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
2279 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
2280 (mi_cmd_data_list_changed_registers): Likewise.
2281 (mi_cmd_data_list_register_values): Likewise.
2282 (mi_cmd_data_write_register_values): Likewise.
2283 (mi_cmd_trace_frame_collected): Likewise.
2284 * mips-tdep.c (print_gp_register_row): Likewise.
2285 (mips_print_registers_info): Likewise.
2286 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
2287 * regcache.c (init_regcache_descr): Likewise.
2288 (register_size): Likewise.
2289 (register_dump::dump): Likewise.
2290 (cooked_read_test): Likewise.
2291 (cooked_write_test): Likewise.
2292 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
2293 (rs6000_gdbarch_init): Likewise.
2294 * stabsread.c (stab_reg_to_regnum): Likewise.
2295 * stack.c (info_frame_command): Likewise.
2296 * target-descriptions.c (tdesc_register_name): Likewise.
2297 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
2298 * tui/tui-regs.c (tui_show_register_group): Likewise.
2299 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
2300 (user_reg_map_regnum_to_name): Likewise.
2301 (value_of_user_reg): Likewise.
2302 (maintenance_print_user_registers): Likewise.
2303 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
2304 (xtensa_register_name): Likewise.
2305 (xtensa_register_type): Likewise.
2306 (xtensa_reg_to_regnum): Likewise.
2307 (xtensa_pseudo_register_read): Likewise.
2308 (xtensa_pseudo_register_write): Likewise.
2309
2310 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2311
2312 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
2313 correctly-sized buffer with raw_read.
2314 (amd64_pseudo_register_write): Use correctly-sized buffer for
2315 raw_read/raw_write.
2316
2317 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2318
2319 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
2320 in add_prefix_cmd of set print type.
2321
2322 2018-10-19 Tom Tromey <tom@tromey.com>
2323
2324 PR tui/18388:
2325 * NEWS: Mention tabset deprecation.
2326 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
2327 (update_tab_width): New function.
2328 (tui_set_tab_width, tui_show_tab_width): New functions.
2329 (tui_set_tab_width_command): Use update_tab_width.
2330 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
2331 Add new "set tui tab-width" command.
2332 * tui/tui-source.c (tui_set_source_content): Update.
2333 * tui/tui-disasm.c (tui_set_disassem_content): Update.
2334 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
2335 Don't declare.
2336 (tui_tab_width): Declare.
2337 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
2338 (tui_set_default_tab_len): Remove.
2339
2340 2018-10-19 Tom Tromey <tom@tromey.com>
2341
2342 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
2343 (key_is_backspace, tui_getc): Don't declare.
2344 * tui/tui-io.c (key_is_start_sequence): Now static.
2345 (key_is_end_sequence, key_is_backspace): Remove.
2346 (tui_getc): Now static.
2347
2348 2018-10-19 Tom Tromey <tom@tromey.com>
2349
2350 * symfile.c (reread_symbols): Clear "static_links".
2351
2352 2018-10-19 Alan Hayward <alan.hayward@arm.com>
2353
2354 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
2355 define.
2356 (aarch64_linux_sigframe_init): Extra boundary checks.
2357
2358 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
2359
2360 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
2361 the possibly non-existent tdesc type 'vec128', but the type of raw
2362 register v16 instead.
2363
2364 2018-10-19 Gary Benson <gbenson@redhat.com>
2365
2366 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
2367
2368 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
2369
2370 PR cli/23785
2371 * cli/cli-dump.c (restore_binary_file): Check if "file" is
2372 NULL.
2373
2374 2018-10-17 Paul Koning <paul_koning@dell.com>
2375
2376 * charset.c (convert_between_encodings): Fix unsigned overflow.
2377
2378 2018-10-17 John Baldwin <jhb@FreeBSD.org>
2379
2380 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
2381 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
2382 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
2383 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2384 New functions.
2385 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
2386 and fbsd_info_proc_mappings_header.
2387 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
2388 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2389 New.
2390
2391 2018-10-17 Joel Brobecker <brobecker@adacore.com>
2392
2393 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
2394 Solaris Maintainer.
2395
2396 2018-10-15 Tom Tromey <tom@tromey.com>
2397
2398 * tui/tui.c (strcat_to_buf): Remove casts.
2399 * tui/tui-winsource.c (tui_show_source_line)
2400 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
2401 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
2402 * tui/tui-windata.c (tui_first_data_item_displayed)
2403 (tui_delete_data_content_windows, tui_erase_data_content)
2404 (tui_display_all_data, tui_display_data_from)
2405 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
2406 * tui/tui-win.c (tui_set_win_height)
2407 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
2408 casts.
2409 * tui/tui-win.c (tui_resize_all): Remove casts.
2410 (tui_scroll_backward_command, tui_set_focus)
2411 (tui_set_tab_width_command): Likewise.
2412 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
2413 * tui/tui-regs.c (tui_show_register_group): Remove cast.
2414 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
2415 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
2416 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
2417 Remove casts.
2418
2419 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
2420
2421 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
2422 AArch64/ARM maintainer.
2423
2424 2018-10-11 Gary Benson <gbenson@redhat.com>
2425
2426 * interps.h (interp::m_name): Make private and mutable.
2427 * interps.c (interp::~interp): Free m_name.
2428
2429 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2430 Simon Marchi <simark@simark.ca>
2431
2432 * README (`configure' options): Add documentation for new
2433 "--enable-unit-tests" option.
2434 * acinclude.m4: Include "selftest.m4".
2435 * configure: Regenerate.
2436 * configure.ac: Use "GDB_AC_SELFTEST".
2437 * maint.c (maintenance_selftest): Update message informing
2438 that selftests have been disabled.
2439 (maintenance_info_selftests): Likewise.
2440 * selftest.m4: New file.
2441
2442 2018-10-10 Gary Benson <gbenson@redhat.com>
2443
2444 * remote.c (remote_target::remote_send_printf): Add
2445 missing va_end found by Coverity.
2446
2447 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
2448
2449 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
2450
2451 2018-10-09 Tom Tromey <tom@tromey.com>
2452
2453 * configure: Rebuild.
2454 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
2455 * NEWS: Update --enable-ubsan documentation.
2456
2457 2018-10-09 Gary Benson <gbenson@redhat.com>
2458
2459 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
2460 found by Coverity.
2461
2462 2018-10-08 Tom Tromey <tom@tromey.com>
2463
2464 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
2465 variable.
2466 (riscv_fbsd_init_abi): Likewise.
2467
2468 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2469 * valops.c (value_struct_elt_for_reference): Rename local variable
2470 to work around the shadowing a previous local warning.
2471
2472 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2473
2474 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
2475 * NEWS: Mention new FreeBSD/riscv native configuration.
2476 * configure.host: Add riscv*-*-freebsd*.
2477 * configure.nat: Likewise.
2478 * riscv-fbsd-nat.c: New file.
2479
2480 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2481
2482 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
2483 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
2484 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
2485 * NEWS: Mention new FreeBSD/riscv target.
2486 * configure.tgt: Add riscv*-*-freebsd*.
2487 * riscv-fbsd-tdep.c: New file.
2488 * riscv-fbsd-tdep.h: New file.
2489
2490 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2491
2492 * regcache.h (struct regcache_map_entry): Note that this type can
2493 be used with traditional frame caches.
2494 * trad-frame.c (trad_frame_set_reg_regmap): New.
2495 * trad-frame.h (trad_frame_set_reg_regmap): New.
2496
2497 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2498
2499 PR c++/16841
2500 * valops.c (get_virtual_base_offset): New function.
2501 (value_struct_elt_for_reference): Use it to get virtual base offset
2502 and add it in calculating class member address.
2503
2504 2018-10-08 John Darrington <john@darrington.wattle.id.au>
2505
2506 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
2507 (check_producer): Check if the producer is codewarrior.
2508 (producer_is_codewarrior): New function.
2509 (lnp_state_machine::record_line): Ignore is_stmt flag for records
2510 produced by codewarrior.
2511 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
2512
2513 2018-10-06 Tom Tromey <tom@tromey.com>
2514
2515 PR python/19399:
2516 * python/py-inferior.c: Add "architecture" entry.
2517 (infpy_architecture): New function.
2518
2519 2018-10-06 Tom Tromey <tom@tromey.com>
2520
2521 PR python/21765:
2522 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
2523 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
2524 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
2525 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
2526
2527 2018-10-06 Tom Tromey <tom@tromey.com>
2528
2529 PR build/17077:
2530 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
2531 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
2532 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
2533 #include.
2534
2535 2018-10-06 Tom Tromey <tom@tromey.com>
2536
2537 * python/py-breakpoint.c (bppy_get_location): Handle a
2538 bp_breakpoint without a location.
2539
2540 2018-10-06 Tom Tromey <tom@tromey.com>
2541
2542 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
2543 (_RegEx): Reformat help text.
2544 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
2545 (AnyCallerIs, AnyCallerMatches): Reformat help text.
2546 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
2547 text.
2548 * python/lib/gdb/command/xmethods.py (InfoXMethod)
2549 (EnableXMethod, DisableXMethod): Remove help indentation.
2550 Capitalize meta-syntactic variables.
2551 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
2552 (EnableUnwinder, DisableUnwinder): Remove help indentation.
2553 Capitalize meta-syntactic variables.
2554 * python/lib/gdb/command/explore.py (ExploreCommand)
2555 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
2556 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
2557 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
2558 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
2559 Remove help indentation.
2560 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
2561 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
2562 (DisableFrameFilter, SetFrameFilterPriority)
2563 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
2564
2565 2018-10-06 Tom Tromey <tom@tromey.com>
2566
2567 PR tui/28819:
2568 * tui/tui-io.c (gdb_wgetch): New function.
2569 (tui_mld_getc, tui_getc): Use it.
2570
2571 2018-10-05 Tom Tromey <tom@tromey.com>
2572
2573 * sol-thread.c (sol_thread_target::wait): Rename inner
2574 "save_ptid".
2575
2576 2018-10-04 Tom Tromey <tom@tromey.com>
2577
2578 * configure: Rebuild.
2579 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
2580
2581 2018-10-04 Tom Tromey <tom@tromey.com>
2582
2583 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
2584 declaration of "block".
2585
2586 2018-10-04 Tom Tromey <tom@tromey.com>
2587
2588 * common/filestuff.c (fdwalk): Remove inner declaration of
2589 "result".
2590
2591 2018-10-04 Tom Tromey <tom@tromey.com>
2592
2593 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
2594 "structs_addr" and hoist declaration.
2595
2596 2018-10-04 Tom Tromey <tom@tromey.com>
2597
2598 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
2599 variable "size".
2600
2601 2018-10-04 Tom Tromey <tom@tromey.com>
2602
2603 * mdebugread.c (parse_partial_symbols): Use std::string.
2604
2605 2018-10-04 Tom Tromey <tom@tromey.com>
2606
2607 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
2608 * p-valprint.c (pascal_val_print): Split inner "i" variable.
2609 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
2610 header.
2611 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
2612 more inner scope.
2613 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
2614 * varobj.c (varobj_update): Rename inner "newobj",
2615 "type_changed".
2616 * valprint.c (generic_emit_char): Rename inner "buf".
2617 * valops.c (find_overload_match): Rename inner "temp".
2618 (value_struct_elt_for_reference): Declare "v" in more inner
2619 scope.
2620 * v850-tdep.c (v850_push_dummy_call): Rename "len".
2621 * unittests/array-view-selftests.c (run_tests): Rename inner
2622 "vec".
2623 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
2624 header.
2625 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
2626 "tsv" in more inner scope.
2627 (print_one_static_tracepoint_marker): Rename inner
2628 "tuple_emitter".
2629 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
2630 (tic6x_push_dummy_call): Don't redeclare "addr".
2631 * target-float.c: Declare "dto" lower.
2632 * symtab.c (lookup_local_symbol): Rename inner "sym".
2633 (find_pc_sect_line): Rename inner "pc".
2634 * stack.c (print_frame): Don't redeclare "gdbarch".
2635 (return_command): Rename inner "gdbarch".
2636 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
2637 "sp".
2638 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
2639 header.
2640 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
2641 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
2642 scope.
2643 * remote.c (remote_target::update_thread_list): Don't redeclare
2644 "tp".
2645 (remote_target::process_initial_stop_replies): Rename inner
2646 "thread".
2647 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
2648 (remote_target::wait_as): Don't redeclare "stop_reply".
2649 (remote_target::get_thread_local_address): Rename inner
2650 "result".
2651 (remote_target::get_tib_address): Likewise.
2652
2653 * regcache.c (cooked_read_test): Rename "regnum".
2654 * record-btrace.c (cmd_record_btrace_start): Rename inner
2655 "exception".
2656 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
2657 loop header.
2658 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
2659 header.
2660 (ppu2spu_sniffer): Rename inner "buf".
2661 * parse.c (operator_check_standard): Rename inner "type",
2662 "objfile".
2663 * p-valprint.c (pascal_val_print): Introduce new scope for
2664 "low_bound", "high_bound".
2665 * p-exp.y (yylex): Declare "i" in loop header.
2666 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
2667 Lower declaration of "s".
2668 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
2669 header.
2670 (nios2_push_dummy_call): Rename "len".
2671 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
2672 "buf".
2673 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
2674 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
2675 (linux_xfer_osdata_modules): Likewise.
2676 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
2677 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
2678 (mips_o64_push_dummy_call): Likewise.
2679 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
2680 "op".
2681 * mi/mi-main.c (list_available_thread_groups): Rename inner
2682 "tuple_emitter".
2683 (mi_cmd_data_read_memory): Rename inner "opts".
2684 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
2685 "tuple_emitter".
2686 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
2687 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
2688 more inner scope.
2689 (parse_partial_symbols): Rename inner "pst", "p", "name"
2690 * main.c (captured_main_1): Rename inner "i"s.
2691 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
2692 "oso2".
2693 * linux-tdep.c (linux_info_proc): Rename inner "filename".
2694 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
2695 * infrun.c (handle_no_resumed): Don't redeclare "thread".
2696 (handle_signal_stop): Rename inner "gdbarch".
2697 (handle_command): Declare "signum" in loop header.
2698 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
2699 "status".
2700 (examine_prologue): Rename inner "sol" and "sof".
2701 (ia64_extract_return_value): Rename inner "val". Declare another
2702 "val" in a more inner scope.
2703 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
2704 inner scope.
2705 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
2706 "except".
2707 * findvar.c (default_read_var_value): Don't redeclare "addr".
2708 * f-exp.y (yylex): Declare "i" in loop header.
2709 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
2710 Rename inner "type", "expect_type".
2711 (evaluate_subexp_for_sizeof): Rename inner "pc".
2712 * elfread.c (elf_symfile_read): Rename inner "abfd".
2713 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
2714 "bytes_read".
2715 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
2716 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
2717 (dwarf_decode_line_header): Rename inner "lh".
2718 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
2719 "offset". Declare "i" in loop header.
2720 (disassemble_dwarf_expression): Rename inner "addr_size".
2721 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
2722 inner "result".
2723 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
2724 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
2725 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
2726 "inner_list_emitter".
2727 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
2728 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
2729 declaration in a block.
2730 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
2731 * cp-valprint.c (cp_print_value_fields): Don't redeclare
2732 "obstack_final_size".
2733 * cp-support.c (inspect_type): Declare "i" in loop header.
2734 * compile/compile.c (compile_instance::insert_symbol_error):
2735 Rename inner "e".
2736 * common/agent.c (agent_run_command): Remove inner "ret"
2737 declaration.
2738 * coffread.c (coff_symfile_read): Rename inner "name".
2739 (coff_symfile_read): Rename inner "abfd".
2740 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
2741 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
2742 "high".
2743 * c-exp.y (lex_one_token): Move "len" declaration lower.
2744 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
2745 "gdbarch".
2746 (create_exception_master_breakpoint): Likewise. Don't redeclare
2747 "b".
2748 (watch_command_1): Declare "mark" later.
2749 (clear_command): Don't shadow "a" or "b".
2750 (delete_command): Rename inner "b".
2751 (delete_trace_command): Likewise.
2752 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
2753 "op".
2754 (arm_gdbarch_init): Remove inner "e_flags".
2755 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
2756 "offset" in inner blocks.
2757
2758 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
2759
2760 * dwarf-index-write.c (file_write): Don't write if the vector is
2761 empty.
2762
2763 2018-10-05 Tom de Vries <tdevries@suse.de>
2764
2765 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
2766 PyArg_ParseTuple call.
2767
2768 2018-10-05 Tom de Vries <tdevries@suse.de>
2769
2770 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
2771 PyArg_ParseTuple call.
2772
2773 2018-10-04 Joel Brobecker <brobecker@adacore.com>
2774
2775 * psymtab.c (recursively_search_psymtabs): Reformat parameters
2776 to avoid exceeding 80 characters per line limit.
2777
2778 2018-10-04 Tom Tromey <tom@tromey.com>
2779
2780 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2781 (reread_symbols): Update.
2782 * complaints.h (clear_complaints): Remove argument.
2783 * complaints.c (enum complaint_series): Remove.
2784 (series): Remove global.
2785 (complaint_internal): Update.
2786 (clear_complaints): Remove argument.
2787
2788 2018-10-04 Tom Tromey <tom@tromey.com>
2789
2790 * symfile.c (symbol_file_add_with_addrs): Do not print "no
2791 debugging symbols" message if there is a separate debug objfile.
2792
2793 2018-10-04 Tom Tromey <tom@tromey.com>
2794
2795 PR cli/19551:
2796 * symfile.c (symbol_file_add_with_addrs): Update output.
2797 * psymtab.c (require_partial_symbols): Update output.
2798
2799 2018-10-04 Tom Tromey <tom@tromey.com>
2800
2801 PR cli/22234:
2802 * complaints.c: Emit \n.
2803
2804 2018-10-04 Tom Tromey <tom@tromey.com>
2805
2806 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
2807 (separate_debug_file_exists, find_separate_debug_file)
2808 (add_symbol_file_command, reread_symbols, allocate_symtab)
2809 (allocate_compunit_symtab): Use filtered printing, not
2810 unfiltered.
2811 * psymtab.c (require_partial_symbols, dump_psymtab)
2812 (allocate_psymtab): Use filtered printing, not unfiltered.
2813
2814 2018-10-04 Tom Tromey <tom@tromey.com>
2815
2816 * complaints.c (complaint_internal): Correctly check complaint
2817 count.
2818
2819 2018-10-04 Tom Tromey <tom@tromey.com>
2820
2821 * complaints.h (struct complaints): Remove declaration.
2822 * complaints.c (clear_complaints): Remove an unused variable.
2823
2824 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2825
2826 * MAINTAINERS (Write After Approval): Add self.
2827
2828 2018-10-03 Tom Tromey <tom@tromey.com>
2829
2830 * guile/scm-value.c (gdbscm_value_to_string): Initialize
2831 "buffer_contents".
2832 * coffread.c (coff_symtab_read): Initialize "newobj".
2833
2834 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
2835
2836 * dwarf2read.c (read_func_scope): Remove struct keyword in
2837 range-based for.
2838
2839 2018-10-03 Tom Tromey <tom@tromey.com>
2840
2841 * README: Mention --enable-ubsan.
2842 * NEWS: Mention --enable-ubsan.
2843 * acinclude.m4: Include sanitize.m4.
2844 * configure: Rebuild.
2845 * configure.ac: Call AM_GDB_UBSAN.
2846 * sanitize.m4: New file.
2847
2848 2018-10-03 Tom Tromey <tom@tromey.com>
2849
2850 * expression.h (enum exp_opcode): Use uint8_t as base type.
2851 * expprint.c (op_name): Handle invalid opcodes.
2852
2853 2018-10-03 Tom Tromey <tom@tromey.com>
2854
2855 * parse.c (prefixify_expression): Add assert.
2856 (parse_exp_in_context_1): Throw exception if the expression is
2857 empty.
2858
2859 2018-10-03 Tom Tromey <tom@tromey.com>
2860
2861 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
2862
2863 2018-10-03 Tom Tromey <tom@tromey.com>
2864
2865 * c-exp.y (parse_number): Work in unsigned. Remove casts.
2866
2867 2018-10-03 Tom Tromey <tom@tromey.com>
2868
2869 * dwarf2read.c (read_subrange_type): Make "negative_mask"
2870 unsigned.
2871
2872 2018-10-03 Tom Tromey <tom@tromey.com>
2873
2874 * findvar.c (extract_integer): Do work in an unsigned type.
2875
2876 2018-10-03 Tom Tromey <tom@tromey.com>
2877
2878 * common/enum-flags.h (enum_flags::operator~): Add static assert.
2879 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
2880 base type.
2881 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
2882 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
2883 type.
2884 * c-lang.h (enum c_string_type_values): Use unsigned as base
2885 type.
2886 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
2887
2888 2018-10-03 Tom Tromey <tom@tromey.com>
2889
2890 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
2891 <~dwarf2_frame_state_reg_info>: Update.
2892 <dwarf2_frame_state_reg_info>: Update.
2893 <alloc_regs>: Add assertion. Update.
2894 <reg>: Now a std::vector.
2895 <num_regs>: Remove.
2896 <swap>: Update.
2897 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2898 (execute_cfa_program_test, dwarf2_frame_cache): Update.
2899
2900 2018-10-03 Tom Tromey <tom@tromey.com>
2901
2902 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
2903
2904 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2905
2906 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
2907
2908 2018-10-02 Tom Tromey <tom@tromey.com>
2909
2910 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
2911
2912 2018-10-02 John Darrington <john@darrington.wattle.id.au>
2913
2914 * NEWS: Mention changed commands.
2915 * ser-uds.c: New file.
2916 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
2917 * configure: Regenerate.
2918 * Makefile.in: Add new file.
2919 * serial.c (serial_open): Check if filename is a socket
2920 and lookup the appropriate interface accordingly.
2921
2922 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2923
2924 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
2925 define.
2926 (AARCH64_EXTRA_MAGIC): Likewise.
2927 (AARCH64_FPSIMD_MAGIC): Likewise.
2928 (AARCH64_SVE_MAGIC): Likewise.
2929 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
2930 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
2931 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
2932 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
2933 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
2934 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
2935 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
2936 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
2937 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
2938 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
2939 (read_aarch64_ctx): Add function.
2940 (aarch64_linux_sigframe_init): Detect FP registers.
2941
2942 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2943
2944 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
2945 (AARCH64_D0_REGNUM): Likewise.
2946 (AARCH64_S0_REGNUM): Likewise.
2947 (AARCH64_H0_REGNUM): Likewise.
2948 (AARCH64_B0_REGNUM): Likewise.
2949 (AARCH64_SVE_V0_REGNUM): Likewise.
2950 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
2951 (AARCH64_D0_REGNUM): Likewise.
2952 (AARCH64_S0_REGNUM): Likewise.
2953 (AARCH64_H0_REGNUM): Likewise.
2954 (AARCH64_B0_REGNUM): Likewise.
2955 (AARCH64_SVE_V0_REGNUM): Likewise.
2956
2957 2018-10-01 Gary Benson <gbenson@redhat.com>
2958
2959 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
2960 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
2961 prfpregset_t instead of gdb_prfpregset_t.
2962 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
2963 * configure, config.in: Rebuild.
2964
2965 2018-10-01 Gary Benson <gbenson@redhat.com>
2966
2967 * common/gdb_proc_service.h: New file, factored out from...
2968 * gdb_proc_service.h: Moved common code to the above file.
2969 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
2970
2971 2018-10-01 Gary Benson <gbenson@redhat.com>
2972
2973 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
2974 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
2975
2976 2018-10-01 Gary Benson <gbenson@redhat.com>
2977
2978 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
2979 (AC_CHECK_HEADERS): Check for linux/elf.h.
2980 * configure, config.in: Rebuild.
2981 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
2982 doesn't define elf_fpregset_t.
2983
2984 2018-10-01 Gary Benson <gbenson@redhat.com>
2985
2986 * gdb_proc_service.h: Whitespace change.
2987
2988 2018-10-01 Tom Tromey <tom@tromey.com>
2989
2990 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
2991 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
2992 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
2993
2994 2018-10-01 Tom Tromey <tom@tromey.com>
2995
2996 * README: Minor change.
2997
2998 2018-09-30 Pedro Alves <palves@redhat.com>
2999
3000 * darwin-nat-info.c (darwin_debug_regions_recurse)
3001 (info_mach_exceptions_command): Remove unused local variables.
3002 * darwin-nat.c (darwin_decode_notify_message)
3003 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
3004 (darwin_stop_inferior, darwin_setup_exceptions)
3005 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
3006 (darwin_nat_target::attach, darwin_nat_target::detach)
3007 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
3008 local variables.
3009 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
3010 variables.
3011
3012 2018-09-29 Tom Tromey <tom@tromey.com>
3013
3014 * README: Remove some leftover text.
3015
3016 2018-09-29 Tom Tromey <tom@tromey.com>
3017
3018 * PROBLEMS: Rewrite.
3019 * README: Update.
3020
3021 2018-09-28 John Baldwin <jhb@FreeBSD.org>
3022
3023 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
3024 case with explicit breakpoint kind.
3025 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
3026 'additional_info' and related logic.
3027 (riscv_debug_breakpoints): New variable.
3028 (riscv_breakpoint_kind_from_pc): Use the length of the existing
3029 instruction to determine the breakpoint kind.
3030 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
3031 flag. Update description of 'set/show riscv
3032 use-compressed-breakpoints' flag.
3033
3034 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
3035
3036 (NEWS): Mention changes to frame related commands.
3037 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
3038 (add_prefix_cmd_suppress_notification): New function.
3039 (add_com_suppress_notification): Call
3040 add_cmd_suppress_notification.
3041 * command.h (add_cmd_suppress_notification): Declare.
3042 (add_prefix_cmd_suppress_notification): Declare.
3043 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
3044 (parse_frame_specification): Moved from stack.c, with
3045 simplification to handle a single argument.
3046 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
3047 switch to the selected frame. Add a header comment.
3048 * stack.c: Remove 'safe-ctype.h' include.
3049 (find_frame_for_function): Add declaration.
3050 (find_frame_for_address): New function.
3051 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
3052 (frame_selection_by_function_completer): New function.
3053 (info_frame_command): Rename to...
3054 (info_frame_command_core): ...this, and update parameter types.
3055 (select_frame_command): Rename to...
3056 (select_frame_command_core): ...this, and update parameter types.
3057 (frame_command): Rename to...
3058 (frame_command_core): ...this, and update parameter types.
3059 (class frame_command_helper): New class to wrap implementations of
3060 frame related sub-commands.
3061 (frame_apply_cmd_list): New static global.
3062 (frame_cmd_list): Make static.
3063 (select_frame_cmd_list): New global for sub-commands.
3064 (info_frame_cmd_list): New global for sub-commands.
3065 (_initialize_stack): Register sub-commands for 'frame',
3066 'select-frame', and 'info frame'. Update 'frame apply' commands
3067 to use frame_apply_cmd_list. Move function local static
3068 frame_apply_list to file static frame_apply_cmd_list for
3069 consistency.
3070 * stack.h (select_frame_command): Delete declarationn.
3071 (select_frame_for_mi): Declare new function.
3072
3073 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
3074
3075 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
3076 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
3077 and NOP.
3078
3079 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
3080
3081 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
3082
3083 2018-09-26 Tom Tromey <tom@tromey.com>
3084
3085 * valops.c (auto_abandon): Remove dead code.
3086
3087 2018-09-26 Tom Tromey <tom@tromey.com>
3088
3089 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
3090
3091 2018-09-24 Tom Tromey <tom@tromey.com>
3092
3093 * common/pathstuff.c (get_standard_cache_dir): Make
3094 "xdg_cache_home" and "home" const.
3095 * top.c (init_history): Make "tmpenv" const.
3096 * main.c (get_init_files): Make "homedir" const.
3097
3098 2018-09-23 Tom Tromey <tom@tromey.com>
3099
3100 PR python/18852:
3101 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
3102
3103 2018-09-23 Tom Tromey <tom@tromey.com>
3104
3105 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
3106 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
3107 * python/python-internal.h (gdbpy_handle_exception): Declare.
3108 * python/py-utils.c (gdbpy_handle_exception): New function.
3109
3110 2018-09-23 Tom Tromey <tom@tromey.com>
3111
3112 PR python/17284:
3113 * python/py-type.c (typy_template_argument): Check for negative
3114 argument number.
3115
3116 2018-09-23 Tom Tromey <tom@tromey.com>
3117
3118 PR python/14062:
3119 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
3120
3121 2018-09-23 Tom Tromey <tom@tromey.com>
3122
3123 PR python/18170:
3124 * python/py-value.c (valpy_int): Allow conversion from pointer
3125 type.
3126
3127 2018-09-23 Tom Tromey <tom@tromey.com>
3128
3129 PR python/20126:
3130 * python/py-value.c (valpy_int): Respect type sign.
3131
3132 2018-09-23 Tom Tromey <tom@tromey.com>
3133
3134 PR python/18352;
3135 * python/py-value.c (valpy_float): Allow conversions from int or
3136 char.
3137 (valpy_int, valpy_long): Allow conversions from float.
3138
3139 2018-09-23 Tom Tromey <tom@tromey.com>
3140
3141 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
3142 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
3143
3144 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3145
3146 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
3147 __sighndlr.
3148 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
3149
3150 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
3151
3152 * windows-nat.c (windows_nat_target::wait): Remove a spurious
3153 target_terminal::ours().
3154
3155 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
3156
3157 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
3158 of vl to ULONGEST.
3159
3160 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
3161
3162 * breakpoint.c (update_inserted_breakpoint_locations): Remove
3163 redundant condition.
3164
3165 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3166
3167 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
3168
3169 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
3170 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
3171 * sol-thread.c (ps_pdmodel): Don't guard definition.
3172
3173 * procfs.c: Fix formatting.
3174
3175 * procfs.c (sysset_t_alloc): Remove.
3176 (create_procinfo): Use XNEW instead of sysset_t_alloc.
3177 (procfs_debug_inferior): Likewise.
3178 (procfs_set_exec_trap): Likewise.
3179 (proc_set_traced_sysentry): Don't allocate argp dynamically.
3180 (proc_set_traced_sysexit): Likewise.
3181
3182 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
3183 (dead_procinfo): Likewise.
3184 (proc_warn): Likewise.
3185 (proc_error): Likewise.
3186 (proc_get_LDT_entry): Likewise.
3187 (do_attach): Likewise.
3188 (procfs_target::pid_to_str): Likewise.
3189 (iterate_over_mappings): Likewise.
3190
3191 * procfs.c (create_procinfo): Fix ARI warning.
3192 (proc_get_status): Likewise.
3193 (proc_stop_process): Likewise.
3194 (proc_run_process): Likewise.
3195 (proc_kill): Likewise.
3196 (proc_get_LDT_entry): Likewise.
3197 (procfs_find_LDT_entry): Likewise.
3198 (proc_update_threads): Likewise.
3199 (proc_iterate_over_threads): Likewise.
3200 (do_attach): Likewise.
3201 (procfs_xfer_memory): Likewise.
3202 (invalidate_cache): Likewise.
3203 (procfs_target::resume): Likewise.
3204 (procfs_init_inferior): Likewise.
3205 (procfs_set_exec_trap): Likewise.
3206 (procfs_target::thread_alive): Likewise.
3207 (procfs_target::pid_to_exec_file): Likewise.
3208 (iterate_over_mappings): Likewise.
3209 (procfs_target::make_corefile_notes): Likewise.
3210 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
3211
3212 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
3213 (procfs_find_LDT_entry): Likewise.
3214 * sol-thread.c (ps_lgetLDT): Likewise.
3215
3216 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3217
3218 PR tdep/17903
3219 * procfs.c (procfs_target): Declare pid_to_exec_file.
3220 (procfs_target::pid_to_exec_file): New.
3221
3222 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3223
3224 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
3225 renaming.
3226 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
3227 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
3228
3229 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3230
3231 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
3232 (supply_fpregset, fill_fpregset): Move ...
3233 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
3234 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
3235 Remove references to ioctl-based procfs.
3236 Include <sys/reg.h>.
3237 Remove PR_MODEL_NATIVE guards.
3238 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
3239 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
3240
3241 2018-09-19 Xavier Roirand <roirand@adacore.com>
3242
3243 PR gdb/20981:
3244 * solib-darwin.c (darwin_get_dyld_bfd): New function.
3245 (darwin_solib_get_all_image_info_addr_at_init): Update call.
3246 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
3247
3248 2018-09-19 John Baldwin <jhb@FreeBSD.org>
3249
3250 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
3251 (fbsd_print_sockaddr_in6): Likewise.
3252
3253 2018-09-19 Richard Bunt <richard.bunt@arm.com>
3254 Chris January <chris.january@arm.com>
3255
3256 * eval.c (skip_undetermined_arglist): Skip argument list helper.
3257 (evaluate_subexp_standard): Return a dummy type when
3258 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
3259 OP_F77_UNDETERMINED_ARGLIST case.
3260 * expression.h (enum noside): Update comment.
3261
3262 2018-09-19 George Vasick <george.vasick@oracle.com>
3263
3264 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
3265
3266 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
3267 April Chin <april.chin@oracle.com>
3268 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3269
3270 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
3271 uint_t lwpid_t.
3272 (create_procinfo): Print pids in /proc without leading zeros.
3273
3274 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
3275
3276 * nios2-tdep.c (nios2_gcc_target_options): New.
3277 (nios2_gdb_arch_init): Install new hook.
3278
3279 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
3280
3281 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
3282 New file.
3283 * update-gnulib.sh: Apply patch.
3284 * configure: Re-generate.
3285
3286 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3287
3288 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
3289 description. Make "info proc" command descriptions more
3290 consistent.
3291
3292 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3293
3294 * NEWS: Mention 'info proc files' command.
3295
3296 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3297
3298 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
3299 descriptors for IP_FILES and IP_ALL.
3300
3301 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3302
3303 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
3304 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
3305 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
3306 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
3307 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
3308 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
3309 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
3310 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
3311 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
3312 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
3313 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
3314 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
3315 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
3316 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
3317 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
3318 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
3319 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
3320 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
3321 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
3322 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
3323 (struct fbsd_sockaddr_un): New types.
3324 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
3325 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
3326 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
3327 (fbsd_core_info_proc_files): New functions.
3328 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
3329 IP_ALL.
3330 * fbsd-tdep.h (fbsd_info_proc_files_header)
3331 (fbsd_info_proc_files_entry): New.
3332
3333 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3334
3335 * defs.h (enum info_proc_what) [IP_FILES]: New value.
3336 * infcmd.c (info_proc_cmd_files): New function.
3337 (_initialize_infcmd): Register 'info proc files' command.
3338
3339 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3340
3341 * gnulib/aclocal-m4-deps.mk: Re-generate.
3342 * gnulib/aclocal.m4: Re-generate.
3343 * gnulib/config.in: Re-generate.
3344 * gnulib/configure: Re-generate.
3345 * gnulib/import/Makefile.am: Re-generate.
3346 * gnulib/import/Makefile.in: Re-generate.
3347 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3348 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3349 * gnulib/import/arpa_inet.in.h: New file.
3350 * gnulib/import/inet_ntop.c: New file.
3351 * gnulib/import/m4/arpa_inet_h.m4: New file.
3352 * gnulib/import/m4/inet_ntop.m4: New file.
3353 * gnulib/import/m4/netinet_in_h.m4: New file.
3354 * gnulib/import/m4/socklen.m4: New file.
3355 * gnulib/import/m4/sockpfaf.m4: New file.
3356 * gnulib/import/m4/stdalign.m4: New file.
3357 * gnulib/import/m4/sys_uio_h.m4: New file.
3358 * gnulib/import/netinet_in.in.h: New file.
3359 * gnulib/import/stdalign.in.h: New file.
3360 * gnulib/import/sys_socket.c: New file.
3361 * gnulib/import/sys_socket.in.h: New file.
3362 * gnulib/import/sys_uio.in.h: New file.
3363 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
3364 module.
3365
3366 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3367
3368 * gnulib/aclocal-m4-deps.mk: New file.
3369 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
3370 deterministically.
3371
3372 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3373
3374 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
3375 KVE_PATH.
3376
3377 2018-09-18 Tom Tromey <tom@tromey.com>
3378
3379 * compile/compile-object-load.c (struct
3380 link_hash_table_cleanup_data): Add constructor and destructor.
3381 Use DISABLE_COPY_AND_ASSIGN.
3382 (~link_hash_table_cleanup_data): Rename from
3383 link_hash_table_free. Now a destructor.
3384 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
3385
3386 2018-09-18 Tom Tromey <tom@tromey.com>
3387
3388 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3389 * compile/compile-object-load.c (struct munmap_list): Move to
3390 header file.
3391 (munmap_list::add): Rename from munmap_list_add; rewrite.
3392 (munmap_list::~munmap_list): Rename from munmap_list_free.
3393 (munmap_listp_free_cleanup): Remove.
3394 (compile_object_load): Update.
3395 * compile/compile-object-load.h (struct munmap_list): Move from
3396 compile-object-load.c. Rewrite.
3397
3398 2018-09-18 Alan Hayward <alan.hayward@arm.com>
3399
3400 * aarch64-tdep.c (pass_in_v): Use register size.
3401 (aarch64_extract_return_value): Likewise.
3402 (aarch64_store_return_value): Likewise.
3403
3404 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3405
3406 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
3407 rlim_t.
3408
3409 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3410
3411 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
3412 Fix short help line.
3413
3414 2018-09-17 Tom Tromey <tom@tromey.com>
3415
3416 PR python/20445:
3417 * configure: Rebuild.
3418 * configure.ac: Conditionally use -DNDEBUG for Python.
3419
3420 2018-09-17 Tom Tromey <tom@tromey.com>
3421
3422 * configure: Rebuild.
3423 * configure.ac: Use gmp as a library dependency when checking for
3424 mpfr.
3425
3426 2018-09-17 Pedro Alves <palves@redhat.com>
3427
3428 * python/py-inferior.c (find_inferior_object): Delete.
3429
3430 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
3431
3432 * compile/compile-cplus-types.c
3433 (compile_cplus_instance::enter_scope): Don't use new_scope after
3434 std::move.
3435
3436 2018-09-17 Tom Tromey <tom@tromey.com>
3437
3438 * common/pathstuff.c (get_standard_cache_dir): Use
3439 ~/Library/Caches on macOS.
3440 * common/pathstuff.h (get_standard_cache_dir): Update comment.
3441
3442 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
3443
3444 PR python/23669
3445 * breakpoint.c (commands_cmd_element): New.
3446 (_initialize_breakpoint): Assign commands_cmd_element.
3447 * breakpoint.h (commands_cmd_element): New.
3448 * cli/cli-script.c (while_cmd_element, if_command,
3449 define_cmd_element): New.
3450 (command_name_equals): Remove.
3451 (process_next_line): Compare commands by pointer, not by name.
3452 (_initialize_cli_script): Assign the various cmd_list_element
3453 variables.
3454 * compile/compile.c (compile_cmd_element): New.
3455 (_initialize_compile): Assign compile_cmd_element.
3456 * compile/compile.h (compile_cmd_element): New.
3457 * guile/guile.c (guile_cmd_element): New.
3458 (install_gdb_commands): Assign guile_cmd_element.
3459 * guile/guile.h (guile_cmd_element): New.
3460 * python/python.c (python_cmd_element): New.
3461 (_initialize_python): Assign python_cmd_element.
3462 * python/python.h (python_cmd_element): New.
3463 * tracepoint.c (while_stepping_cmd_element): New.
3464 (_initialize_tracepoint): Assign while_stepping_cmd_element.
3465 * tracepoint.h (while_stepping_cmd_element): New.
3466
3467 2018-09-17 Tom Tromey <tom@tromey.com>
3468
3469 * infrun.c (save_infcall_suspend_state): Return
3470 infcall_suspend_state_up.
3471 (save_infcall_control_state): Return infcall_control_state_up.
3472 * inferior.h (save_infcall_suspend_state)
3473 (save_infcall_control_state): Declare later. Return unique
3474 pointers.
3475
3476 2018-09-17 Tom Tromey <tom@tromey.com>
3477
3478 * infrun.c (struct stop_context): Declare constructor,
3479 destructor, "changed" method.
3480 (stop_context::stop_context): Rename from save_stop_context.
3481 (stop_context::~stop_context): Rename from
3482 release_stop_context_cleanup.
3483 (normal_stop): Update.
3484 (stop_context::changed): Rename from stop_context_changed. Return
3485 bool.
3486
3487 2018-09-17 Tom Tromey <tom@tromey.com>
3488
3489 * inferior.h (struct infcall_suspend_state_deleter): New.
3490 (infcall_suspend_state_up): New typedef.
3491 (struct infcall_control_state_deleter): New.
3492 (infcall_control_state_up): New typedef.
3493 (make_cleanup_restore_infcall_suspend_state)
3494 (make_cleanup_restore_infcall_control_state): Don't declare.
3495 * infcall.c (call_function_by_hand_dummy): Update.
3496 * infrun.c (do_restore_infcall_suspend_state_cleanup)
3497 (make_cleanup_restore_infcall_suspend_state): Remove.
3498 (do_restore_infcall_control_state_cleanup)
3499 (make_cleanup_restore_infcall_control_state): Remove.
3500
3501 2018-09-17 Tom Tromey <tom@tromey.com>
3502
3503 * gdbthread.h (struct thread_control_state): Add initializer.
3504 (class thread_info) <control>: Remove initializer.
3505 * inferior.h (struct inferior_control_state): Add initializer.
3506 (class inferior) <control>: Remove initializer.
3507 (exit_inferior_1): Update.
3508 * infrun.c (struct infcall_control_state): Add constructors.
3509 (save_infcall_control_state): Use new.
3510 (restore_infcall_control_state, discard_infcall_control_state):
3511 Use delete.
3512
3513 2018-09-17 Tom Tromey <tom@tromey.com>
3514
3515 * infrun.c (struct infcall_suspend_state) <registers>: Now a
3516 unique_ptr.
3517 <siginfo_data>: Now a unique_xmalloc_ptr.
3518 (save_infcall_suspend_state, restore_infcall_suspend_state)
3519 (discard_infcall_suspend_state)
3520 (get_infcall_suspend_state_regcache): Update.
3521
3522 2018-09-17 Tom Tromey <tom@tromey.com>
3523
3524 * gdbthread.h (struct thread_suspend_state): Add initializers.
3525 (class thread_info) <suspend>: Remove initializer.
3526 * infrun.c (struct infcall_suspend_state): Add initializers.
3527 (save_infcall_suspend_state): Use new.
3528 (discard_infcall_suspend_state): Use delete.
3529
3530 2018-09-16 Tom Tromey <tom@tromey.com>
3531
3532 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
3533 Remove.
3534 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
3535 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
3536 (py_varobj_iter_new): Likewise.
3537 (py_varobj_get_iterator): Use gdbpy_ref.
3538
3539 2018-09-16 Tom Tromey <tom@tromey.com>
3540
3541 * python/py-threadevent.c (py_get_event_thread): Simplify.
3542 * python/py-inferior.c (infpy_thread_from_thread_handle):
3543 Return immediately after calling thread_to_thread_object. Use
3544 Py_RETURN_NONE.
3545 (thread_to_thread_object): Set the exception on a NULL return.
3546
3547 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3548
3549 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
3550
3551 2018-09-16 Tom Tromey <tom@tromey.com>
3552
3553 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
3554 Remove.
3555
3556 2018-09-16 Tom Tromey <tom@tromey.com>
3557
3558 * python/python-internal.h (thread_to_thread_object): Change
3559 return type.
3560 * python/py-inferior.c (thread_to_thread_object): Return a new
3561 reference.
3562 (infpy_thread_from_thread_handle): Update.
3563 * python/py-infthread.c (gdbpy_selected_thread): Update.
3564 * python/py-stopevent.c (create_stop_event_object): Update.
3565 * python/py-threadevent.c (py_get_event_thread): Return a new
3566 reference.
3567 (py_get_event_thread): Update.
3568 * python/py-event.h (py_get_event_thread): Change return type.
3569 * python/py-continueevent.c (create_continue_event_object):
3570 Update.
3571
3572 2018-09-16 Tom Tromey <tom@tromey.com>
3573
3574 * python/py-progspace.c (pspy_get_objfiles): Update.
3575 * python/python-internal.h (objfile_to_objfile_object): Change
3576 return type.
3577 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3578 Update.
3579 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3580 Update.
3581 * python/python.c (gdbpy_get_current_objfile): Update.
3582 (gdbpy_objfiles): Update.
3583 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
3584 Update.
3585 (objfile_to_objfile_object): Return a new reference.
3586 * python/py-symtab.c (stpy_get_objfile): Update.
3587 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
3588 Update.
3589
3590 2018-09-16 Tom Tromey <tom@tromey.com>
3591
3592 * python/py-inferior.c (infpy_get_progspace): Update.
3593 * python/python-internal.h (pspace_to_pspace_object): Change
3594 return type.
3595 * python/py-newobjfileevent.c
3596 (create_clear_objfiles_event_object): Update.
3597 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3598 Update.
3599 * python/python.c (gdbpy_get_current_progspace): Update.
3600 (gdbpy_progspaces): Update.
3601 * python/py-progspace.c (pspace_to_pspace_object): Return a new
3602 reference.
3603 * python/py-objfile.c (objfpy_get_progspace): Update.
3604 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
3605 Update.
3606
3607 2018-09-16 Tom Tromey <tom@tromey.com>
3608
3609 * python/lib/gdb/__init__.py (current_progspace, objfiles)
3610 (solib_name, block_for_pc, find_pc_line): New functions.
3611 (execute_unwinders): Update.
3612 * python/py-block.c (gdbpy_block_for_pc): Remove.
3613 * python/py-inferior.c (infpy_get_progspace): New function.
3614 (inferior_object_getset) <progspace>: Add.
3615 * python/py-progspace.c (pspy_objfiles): Rewrite.
3616 (pspy_solib_name, pspy_block_for_pc)
3617 (pspy_find_pc_line, pspy_is_valid): New functions.
3618 (progspace_object_methods): Add entries for solib_name,
3619 block_for_pc, find_pc_line, is_valid.
3620 * python/python-internal.h (gdbpy_block_for_pc)
3621 (build_objfiles_list): Don't declare.
3622 * python/python.c: Don't include solib.h.
3623 (gdbpy_solib_name, gdbpy_find_pc_line)
3624 (gdbpy_get_current_progspace, build_objfiles_list)
3625 (gdbpy_objfiles): Remove.
3626 (GdbMethods) <current_progspace, objfiles, block_for_pc,
3627 solib_name, find_pc_line>: Remove entries.
3628
3629 2018-09-16 Tom Tromey <tom@tromey.com>
3630
3631 * top.c (new_ui_command): Use GNU style for metasyntactic
3632 variables.
3633 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
3634 variables.
3635 * maint.c (maintenance_translate_address): Remove "<>" around
3636 text.
3637 * interps.c (interpreter_exec_cmd): Use GNU style for
3638 metasyntactic variables.
3639 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
3640 metasyntactic variables.
3641 * tracepoint.c (tfind_range_command): Use GNU style for
3642 metasyntactic variables.
3643 (tfind_outside_command): Likewise.
3644 (_initialize_tracepoint): Likewise.
3645 * remote.c (extended_remote_target::create_inferior): Use GNU
3646 style for metasyntactic variables.
3647 * sparc64-tdep.c (adi_examine_command): Use GNU style for
3648 metasyntactic variables.
3649 (adi_assign_command): Likewise.
3650
3651 2018-09-16 Tom Tromey <tom@tromey.com>
3652
3653 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
3654 metasyntactic variables. Print message if no disassembler options
3655 are available.
3656
3657 2018-09-15 Tom Tromey <tom@tromey.com>
3658
3659 * infcmd.c (get_inferior_args): Return const char *.
3660 * inferior.h (get_inferior_args): Return type now const.
3661 * linux-tdep.c (linux_fill_prpsinfo): Update.
3662 * procfs.c (procfs_target::make_corefile_notes): Update.
3663
3664 2018-09-07 Tom Tromey <tom@tromey.com>
3665
3666 * python/python.c (execute_gdb_command): Call bpstat_do_actions
3667 inside the TRY.
3668
3669 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
3670
3671 * nios2-tdep.c (nios2_type_align): New.
3672 (nios2_gdb_arch_init): Install type_align hook.
3673
3674 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3675
3676 * eval.c (fake_method::fake_method): Call xzalloc directly for a
3677 type that is neither object file owned, nor gdbarch owned.
3678 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
3679 gdbarch is non-NULL.
3680 (alloc_type_instance): Allocate non-objfile owned types on the
3681 gdbarch obstack.
3682 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
3683 using TYPE_ALLOC to ensure memory is allocated on the correct
3684 obstack.
3685 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
3686 obstack, or the gdbarch obstack.
3687 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
3688
3689 2018-09-14 Tom Tromey <tom@tromey.com>
3690
3691 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
3692 block.
3693
3694 2018-09-14 Tom Tromey <tom@tromey.com>
3695
3696 * nat/fork-inferior.c (get_startup_shell): Remove "static".
3697
3698 2018-09-13 Tom Tromey <tom@tromey.com>
3699
3700 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
3701 static.
3702
3703 2018-09-13 Tom Tromey <tom@tromey.com>
3704
3705 * exec.c (try_open_exec_file): Use std::string.
3706
3707 2018-09-13 Tom Tromey <tom@tromey.com>
3708
3709 * utils.h (gdb_bfd_errmsg): Return std::string.
3710 * exec.c (exec_file_attach): Update.
3711 * compile/compile-object-load.c (compile_object_load): Update.
3712 * utils.c (gdb_bfd_errmsg): Return std::string.
3713
3714 2018-09-13 Tom Tromey <tom@tromey.com>
3715
3716 * procfs.c (struct procinfo_deleter): New.
3717 (procinfo_up): New typedef.
3718 (do_destroy_procinfo_cleanup): Remove.
3719 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
3720
3721 2018-09-13 Tom Tromey <tom@tromey.com>
3722
3723 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
3724
3725 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3726 2018-09-13 Tom Tromey <tom@tromey.com>
3727
3728 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
3729 (pspy_get_objfiles): New function.
3730 (progspace_object_methods): New.
3731 (pspace_object_type): Add tp_methods callback.
3732 * python/python-internal.h (build_objfiles_list): New
3733 declaration.
3734 * python/python.c (build_objfiles_list): New function.
3735 (gdbpy_objfiles): Implement using build_objfiles_list.
3736 * NEWS: Mention the Progspace.objfiles method.
3737
3738 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3739
3740 * python/py-inferior.c (infpy_get_progspace): New function.
3741 (inferior_object_getset): Add progspace property.
3742 * NEWS: Mention the new property.
3743
3744 2018-09-13 Tom Tromey <tom@tromey.com>
3745
3746 PR rust/23650:
3747 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
3748
3749 2018-09-13 Tom Tromey <tom@tromey.com>
3750
3751 PR rust/23626:
3752 * rust-lang.c (rust_enum_variant): Now static.
3753 (rust_empty_enum_p): New function.
3754 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
3755 Handle empty enum.
3756
3757 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3758
3759 * python/py-inferior.c (infpy_repr): New.
3760 (inferior_object_type): Register infpy_repr.
3761 * python/py-objfile.c (objfpy_repr): New.
3762 (objfile_object_type): Register objfpy_repr.
3763
3764 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3765
3766 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
3767
3768 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3769
3770 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
3771 typo.
3772
3773 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
3774
3775 * common/common-utils.c: Don't include '<sys/stat.h>'.
3776 (is_regular_file): Move to...
3777 * common/filestuff.c (is_regular_file): ... here.
3778 * common/common-utils.h (is_regular_file): Move to...
3779 * common/filestuff.h (is_regular_file): ... here.
3780
3781 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
3782
3783 * skip.c (debug_skip): New variable.
3784 (skiplist_entry::do_skip_file_p): Add debug output.
3785 (skiplist_entry::do_skip_gfile_p): Likewise.
3786 (skiplist_entry::skip_function_p): Likewise.
3787 (_initialize_step_skip): Create debug command.
3788 * NEWS: Mention set/show debug skip.
3789
3790 2018-09-11 Xavier Roirand <roirand@adacore.com>
3791
3792 * darwin-nat.c (should_disable_startup_with_shell):
3793 New function.
3794 (darwin_nat_target::create_inferior): Add call.
3795
3796 2018-09-11 Xavier Roirand <roirand@adacore.com>
3797
3798 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
3799 inf_port, msg_state>: Initialize.
3800 (struct darwin_thread_info) <signaled, single_step>: Change
3801 type and initialize.
3802 (struct darwin_thread_info) <event>: Initialize.
3803
3804 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3805
3806 PR gdb/23555
3807 PR gdb/23558
3808 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
3809 guesses.
3810
3811 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3812
3813 Revert:
3814 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
3815
3816 PR gdb/23555
3817 PR gdb/23558
3818 * gnulib/aclocal.m4: Regenerate.
3819 * gnulib/config.in: Regenerate.
3820 * gnulib/configure: Regenerate.
3821 * gnulib/import/Makefile.am: Update.
3822 * gnulib/import/Makefile.in: Update.
3823 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
3824 * gnulib/import/_Noreturn.h: ... this.
3825 * gnulib/import/alloca.in.h: Update.
3826 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
3827 * gnulib/import/arg-nonnull.h: ... this.
3828 * gnulib/import/assure.h: Update.
3829 * gnulib/import/at-func.c: Update.
3830 * gnulib/import/basename-lgpl.c: Update.
3831 * gnulib/import/extra/snippet/c++defs.h: Rename to...
3832 * gnulib/import/c++defs.h: ... this.
3833 * gnulib/import/canonicalize-lgpl.c: Update.
3834 * gnulib/import/cdefs.h: Update.
3835 * gnulib/import/chdir-long.c: Update.
3836 * gnulib/import/chdir-long.h: Update.
3837 * gnulib/import/cloexec.c: Update.
3838 * gnulib/import/cloexec.h: Update.
3839 * gnulib/import/close.c: Update.
3840 * gnulib/import/closedir.c: Update.
3841 * gnulib/import/config.charset: Update.
3842 * gnulib/import/dirent-private.h: Update.
3843 * gnulib/import/dirent.in.h: Update.
3844 * gnulib/import/dirfd.c: Update.
3845 * gnulib/import/dirname-lgpl.c: Update.
3846 * gnulib/import/dirname.h: Update.
3847 * gnulib/import/dosname.h: Update.
3848 * gnulib/import/dup-safer-flag.c: Update.
3849 * gnulib/import/dup-safer.c: Update.
3850 * gnulib/import/dup.c: Update.
3851 * gnulib/import/dup2.c: Update.
3852 * gnulib/import/errno.in.h: Update.
3853 * gnulib/import/error.c: Update.
3854 * gnulib/import/error.h: Update.
3855 * gnulib/import/exitfail.c: Update.
3856 * gnulib/import/exitfail.h: Update.
3857 * gnulib/import/extra/update-copyright: Update.
3858 * gnulib/import/fchdir.c: Update.
3859 * gnulib/import/fcntl.c: Update.
3860 * gnulib/import/fcntl.in.h: Update.
3861 * gnulib/import/fd-hook.c: Update.
3862 * gnulib/import/fd-hook.h: Update.
3863 * gnulib/import/fd-safer-flag.c: Update.
3864 * gnulib/import/fd-safer.c: Update.
3865 * gnulib/import/fdopendir.c: Update.
3866 * gnulib/import/filename.h: Update.
3867 * gnulib/import/filenamecat-lgpl.c: Update.
3868 * gnulib/import/filenamecat.h: Update.
3869 * gnulib/import/flexmember.h: Update.
3870 * gnulib/import/float+.h: Update.
3871 * gnulib/import/float.c: Update.
3872 * gnulib/import/float.in.h: Update.
3873 * gnulib/import/fnmatch.c: Update.
3874 * gnulib/import/fnmatch.in.h: Update.
3875 * gnulib/import/fnmatch_loop.c: Update.
3876 * gnulib/import/fpucw.h: Update.
3877 * gnulib/import/frexp.c: Update.
3878 * gnulib/import/frexpl.c: Update.
3879 * gnulib/import/fstat.c: Update.
3880 * gnulib/import/fstatat.c: Update.
3881 * gnulib/import/getcwd-lgpl.c: Update.
3882 * gnulib/import/getcwd.c: Update.
3883 * gnulib/import/getdtablesize.c: Update.
3884 * gnulib/import/getlogin_r.c: Update.
3885 * gnulib/import/getprogname.c: Update.
3886 * gnulib/import/getprogname.h: Update.
3887 * gnulib/import/gettext.h: Update.
3888 * gnulib/import/gettimeofday.c: Update.
3889 * gnulib/import/glob-libc.h: Update.
3890 * gnulib/import/glob.c: Update.
3891 * gnulib/import/glob.in.h: Update.
3892 * gnulib/import/glob_internal.h: Update.
3893 * gnulib/import/glob_pattern_p.c: Update.
3894 * gnulib/import/globfree.c: Update.
3895 * gnulib/import/hard-locale.c: Update.
3896 * gnulib/import/hard-locale.h: Update.
3897 * gnulib/import/intprops.h: Update.
3898 * gnulib/import/inttypes.in.h: Update.
3899 * gnulib/import/isnan.c: Update.
3900 * gnulib/import/isnand-nolibm.h: Update.
3901 * gnulib/import/isnand.c: Update.
3902 * gnulib/import/isnanl-nolibm.h: Update.
3903 * gnulib/import/isnanl.c: Update.
3904 * gnulib/import/itold.c: Update.
3905 * gnulib/import/libc-config.h: Update.
3906 * gnulib/import/limits.in.h: Update.
3907 * gnulib/import/localcharset.c: Update.
3908 * gnulib/import/localcharset.h: Update.
3909 * gnulib/import/localtime-buffer.c: Update.
3910 * gnulib/import/localtime-buffer.h: Update.
3911 * gnulib/import/lstat.c: Update.
3912 * gnulib/import/m4/00gnulib.m4: Update.
3913 * gnulib/import/m4/__inline.m4: Update.
3914 * gnulib/import/m4/absolute-header.m4: Update.
3915 * gnulib/import/m4/alloca.m4: Update.
3916 * gnulib/import/m4/builtin-expect.m4: Update.
3917 * gnulib/import/m4/canonicalize.m4: Update.
3918 * gnulib/import/m4/chdir-long.m4: Update.
3919 * gnulib/import/m4/close.m4: Update.
3920 * gnulib/import/m4/closedir.m4: Update.
3921 * gnulib/import/m4/configmake.m4: Update.
3922 * gnulib/import/m4/d-ino.m4: Update.
3923 * gnulib/import/m4/d-type.m4: Update.
3924 * gnulib/import/m4/dirent_h.m4: Update.
3925 * gnulib/import/m4/dirfd.m4: Update.
3926 * gnulib/import/m4/dirname.m4: Update.
3927 * gnulib/import/m4/double-slash-root.m4: Update.
3928 * gnulib/import/m4/dup.m4: Update.
3929 * gnulib/import/m4/dup2.m4: Update.
3930 * gnulib/import/m4/eealloc.m4: Update.
3931 * gnulib/import/m4/environ.m4: Update.
3932 * gnulib/import/m4/errno_h.m4: Update.
3933 * gnulib/import/m4/error.m4: Update.
3934 * gnulib/import/m4/exponentd.m4: Update.
3935 * gnulib/import/m4/exponentl.m4: Update.
3936 * gnulib/import/m4/extensions.m4: Update.
3937 * gnulib/import/m4/extern-inline.m4: Update.
3938 * gnulib/import/m4/fchdir.m4: Update.
3939 * gnulib/import/m4/fcntl-o.m4: Update.
3940 * gnulib/import/m4/fcntl.m4: Update.
3941 * gnulib/import/m4/fcntl_h.m4: Update.
3942 * gnulib/import/m4/fdopendir.m4: Update.
3943 * gnulib/import/m4/filenamecat.m4: Update.
3944 * gnulib/import/m4/flexmember.m4: Update.
3945 * gnulib/import/m4/float_h.m4: Update.
3946 * gnulib/import/m4/fnmatch.m4: Update.
3947 * gnulib/import/m4/fnmatch_h.m4: Update.
3948 * gnulib/import/m4/fpieee.m4: Update.
3949 * gnulib/import/m4/frexp.m4: Update.
3950 * gnulib/import/m4/frexpl.m4: Update.
3951 * gnulib/import/m4/fstat.m4: Update.
3952 * gnulib/import/m4/fstatat.m4: Update.
3953 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
3954 * gnulib/import/m4/getcwd-path-max.m4: Update.
3955 * gnulib/import/m4/getcwd.m4: Update.
3956 * gnulib/import/m4/getdtablesize.m4: Update.
3957 * gnulib/import/m4/getlogin.m4: Update.
3958 * gnulib/import/m4/getlogin_r.m4: Update.
3959 * gnulib/import/m4/getpagesize.m4: Update.
3960 * gnulib/import/m4/getprogname.m4: Update.
3961 * gnulib/import/m4/gettimeofday.m4: Update.
3962 * gnulib/import/m4/glibc21.m4: Update.
3963 * gnulib/import/m4/glob.m4: Update.
3964 * gnulib/import/m4/glob_h.m4: Update.
3965 * gnulib/import/m4/gnulib-cache.m4: Update.
3966 * gnulib/import/m4/gnulib-common.m4: Update.
3967 * gnulib/import/m4/gnulib-comp.m4: Update.
3968 * gnulib/import/m4/gnulib-tool.m4: Update.
3969 * gnulib/import/m4/hard-locale.m4: Update.
3970 * gnulib/import/m4/include_next.m4: Update.
3971 * gnulib/import/m4/inttypes-pri.m4: Update.
3972 * gnulib/import/m4/inttypes.m4: Update.
3973 * gnulib/import/m4/isnand.m4: Update.
3974 * gnulib/import/m4/isnanl.m4: Update.
3975 * gnulib/import/m4/largefile.m4: Update.
3976 * gnulib/import/m4/limits-h.m4: Update.
3977 * gnulib/import/m4/localcharset.m4: Update.
3978 * gnulib/import/m4/locale-fr.m4: Update.
3979 * gnulib/import/m4/locale-ja.m4: Update.
3980 * gnulib/import/m4/locale-zh.m4: Update.
3981 * gnulib/import/m4/localtime-buffer.m4: Update.
3982 * gnulib/import/m4/longlong.m4: Update.
3983 * gnulib/import/m4/lstat.m4: Update.
3984 * gnulib/import/m4/malloc.m4: Update.
3985 * gnulib/import/m4/malloca.m4: Update.
3986 * gnulib/import/m4/math_h.m4: Update.
3987 * gnulib/import/m4/mbrtowc.m4: Update.
3988 * gnulib/import/m4/mbsinit.m4: Update.
3989 * gnulib/import/m4/mbsrtowcs.m4: Update.
3990 * gnulib/import/m4/mbstate_t.m4: Update.
3991 * gnulib/import/m4/memchr.m4: Update.
3992 * gnulib/import/m4/memmem.m4: Update.
3993 * gnulib/import/m4/mempcpy.m4: Update.
3994 * gnulib/import/m4/memrchr.m4: Update.
3995 * gnulib/import/m4/mkdir.m4: Update.
3996 * gnulib/import/m4/mkstemp.m4: Update.
3997 * gnulib/import/m4/mmap-anon.m4: Update.
3998 * gnulib/import/m4/mode_t.m4: Update.
3999 * gnulib/import/m4/msvc-inval.m4: Update.
4000 * gnulib/import/m4/msvc-nothrow.m4: Update.
4001 * gnulib/import/m4/multiarch.m4: Update.
4002 * gnulib/import/m4/nocrash.m4: Update.
4003 * gnulib/import/m4/off_t.m4: Update.
4004 * gnulib/import/m4/onceonly.m4: Update.
4005 * gnulib/import/m4/open-cloexec.m4: Update.
4006 * gnulib/import/m4/open.m4: Update.
4007 * gnulib/import/m4/openat.m4: Update.
4008 * gnulib/import/m4/opendir.m4: Update.
4009 * gnulib/import/m4/pathmax.m4: Update.
4010 * gnulib/import/m4/rawmemchr.m4: Update.
4011 * gnulib/import/m4/readdir.m4: Update.
4012 * gnulib/import/m4/readlink.m4: Update.
4013 * gnulib/import/m4/realloc.m4: Update.
4014 * gnulib/import/m4/rename.m4: Update.
4015 * gnulib/import/m4/rewinddir.m4: Update.
4016 * gnulib/import/m4/rmdir.m4: Update.
4017 * gnulib/import/m4/save-cwd.m4: Update.
4018 * gnulib/import/m4/secure_getenv.m4: Update.
4019 * gnulib/import/m4/setenv.m4: Update.
4020 * gnulib/import/m4/signal_h.m4: Update.
4021 * gnulib/import/m4/ssize_t.m4: Update.
4022 * gnulib/import/m4/stat-time.m4: Update.
4023 * gnulib/import/m4/stat.m4: Update.
4024 * gnulib/import/m4/std-gnu11.m4: Update.
4025 * gnulib/import/m4/stdbool.m4: Update.
4026 * gnulib/import/m4/stddef_h.m4: Update.
4027 * gnulib/import/m4/stdint.m4: Update.
4028 * gnulib/import/m4/stdio_h.m4: Update.
4029 * gnulib/import/m4/stdlib_h.m4: Update.
4030 * gnulib/import/m4/strchrnul.m4: Update.
4031 * gnulib/import/m4/strdup.m4: Update.
4032 * gnulib/import/m4/strerror.m4: Update.
4033 * gnulib/import/m4/string_h.m4: Update.
4034 * gnulib/import/m4/strstr.m4: Update.
4035 * gnulib/import/m4/strtok_r.m4: Update.
4036 * gnulib/import/m4/sys_socket_h.m4: Update.
4037 * gnulib/import/m4/sys_stat_h.m4: Update.
4038 * gnulib/import/m4/sys_time_h.m4: Update.
4039 * gnulib/import/m4/sys_types_h.m4: Update.
4040 * gnulib/import/m4/tempname.m4: Update.
4041 * gnulib/import/m4/time_h.m4: Update.
4042 * gnulib/import/m4/unistd-safer.m4: Update.
4043 * gnulib/import/m4/unistd_h.m4: Update.
4044 * gnulib/import/m4/warn-on-use.m4: Update.
4045 * gnulib/import/m4/wchar_h.m4: Update.
4046 * gnulib/import/m4/wchar_t.m4: Update.
4047 * gnulib/import/m4/wctype_h.m4: Update.
4048 * gnulib/import/m4/wint_t.m4: Update.
4049 * gnulib/import/malloc.c: Update.
4050 * gnulib/import/malloc/scratch_buffer.h: Update.
4051 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4052 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4053 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4054 * gnulib/import/malloca.c: Update.
4055 * gnulib/import/malloca.h: Update.
4056 * gnulib/import/malloca.valgrind: Update.
4057 * gnulib/import/math.in.h: Update.
4058 * gnulib/import/mbrtowc.c: Update.
4059 * gnulib/import/mbsinit.c: Update.
4060 * gnulib/import/mbsrtowcs-impl.h: Update.
4061 * gnulib/import/mbsrtowcs-state.c: Update.
4062 * gnulib/import/mbsrtowcs.c: Update.
4063 * gnulib/import/memchr.c: Update.
4064 * gnulib/import/memmem.c: Update.
4065 * gnulib/import/mempcpy.c: Update.
4066 * gnulib/import/memrchr.c: Update.
4067 * gnulib/import/mkdir.c: Update.
4068 * gnulib/import/mkstemp.c: Update.
4069 * gnulib/import/msvc-inval.c: Update.
4070 * gnulib/import/msvc-inval.h: Update.
4071 * gnulib/import/msvc-nothrow.c: Update.
4072 * gnulib/import/msvc-nothrow.h: Update.
4073 * gnulib/import/open.c: Update.
4074 * gnulib/import/openat-die.c: Update.
4075 * gnulib/import/openat-priv.h: Update.
4076 * gnulib/import/openat-proc.c: Update.
4077 * gnulib/import/openat.c: Update.
4078 * gnulib/import/openat.h: Update.
4079 * gnulib/import/opendir.c: Update.
4080 * gnulib/import/pathmax.h: Update.
4081 * gnulib/import/pipe-safer.c: Update.
4082 * gnulib/import/rawmemchr.c: Update.
4083 * gnulib/import/readdir.c: Update.
4084 * gnulib/import/readlink.c: Update.
4085 * gnulib/import/realloc.c: Update.
4086 * gnulib/import/ref-add.sin: Update.
4087 * gnulib/import/ref-del.sin: Update.
4088 * gnulib/import/rename.c: Update.
4089 * gnulib/import/rewinddir.c: Update.
4090 * gnulib/import/rmdir.c: Update.
4091 * gnulib/import/same-inode.h: Update.
4092 * gnulib/import/save-cwd.c: Update.
4093 * gnulib/import/save-cwd.h: Update.
4094 * gnulib/import/scratch_buffer.h: Update.
4095 * gnulib/import/secure_getenv.c: Update.
4096 * gnulib/import/setenv.c: Update.
4097 * gnulib/import/signal.in.h: Update.
4098 * gnulib/import/stat-time.c: Update.
4099 * gnulib/import/stat-time.h: Update.
4100 * gnulib/import/stat-w32.c: Update.
4101 * gnulib/import/stat-w32.h: Update.
4102 * gnulib/import/stat.c: Update.
4103 * gnulib/import/stdbool.in.h: Update.
4104 * gnulib/import/stddef.in.h: Update.
4105 * gnulib/import/stdint.in.h: Update.
4106 * gnulib/import/stdio.in.h: Update.
4107 * gnulib/import/stdlib.in.h: Update.
4108 * gnulib/import/str-two-way.h: Update.
4109 * gnulib/import/strchrnul.c: Update.
4110 * gnulib/import/strdup.c: Update.
4111 * gnulib/import/streq.h: Update.
4112 * gnulib/import/strerror-override.c: Update.
4113 * gnulib/import/strerror-override.h: Update.
4114 * gnulib/import/strerror.c: Update.
4115 * gnulib/import/string.in.h: Update.
4116 * gnulib/import/stripslash.c: Update.
4117 * gnulib/import/strnlen1.c: Update.
4118 * gnulib/import/strnlen1.h: Update.
4119 * gnulib/import/strstr.c: Update.
4120 * gnulib/import/strtok_r.c: Update.
4121 * gnulib/import/sys_stat.in.h: Update.
4122 * gnulib/import/sys_time.in.h: Update.
4123 * gnulib/import/sys_types.in.h: Update.
4124 * gnulib/import/tempname.c: Update.
4125 * gnulib/import/tempname.h: Update.
4126 * gnulib/import/time.in.h: Update.
4127 * gnulib/import/unistd--.h: Update.
4128 * gnulib/import/unistd-safer.h: Update.
4129 * gnulib/import/unistd.in.h: Update.
4130 * gnulib/import/unsetenv.c: Update.
4131 * gnulib/import/verify.h: Update.
4132 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4133 * gnulib/import/wchar.in.h: Update.
4134 * gnulib/import/wctype.in.h: Update.
4135 * gnulib/import/xalloc-oversized.h: Update.
4136 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4137 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4138
4139 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
4140
4141 * record-btrace.c (get_thread_current_frame): Remove
4142 old_inferior_ptid.
4143
4144 2018-09-10 Jerome Guitton <guitton@adacore.com>
4145
4146 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
4147 with check_tag to 1 if and only if the type is tagged and the
4148 component being searched cannot been found in the current
4149 view. Otherwise, always call ada_to_fixed_type with
4150 check_tag to 0.
4151
4152 2018-09-10 Xavier Roirand <roirand@adacore.com>
4153
4154 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
4155 declaration.
4156 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
4157 * ada-varobj.c (ada_varobj_get_number_of_children,
4158 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
4159
4160 2018-09-10 Xavier Roirand <roirand@adacore.com>
4161
4162 * ada-valprint.c (ada_value_print): Use type instead of
4163 enclosing type.
4164
4165 2018-09-10 Xavier Roirand <roirand@adacore.com>
4166
4167 * ada-lang.c (ada_value_subscript): Handle case when parameter is
4168 an array of access to unconstrained array.
4169
4170 2018-09-10 Xavier Roirand <roirand@adacore.com>
4171
4172 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
4173 (ada_check_typedef): Use it.
4174
4175 2018-09-10 Xavier Roirand <roirand@adacore.com>
4176
4177 * ada-varobj.c (ada_varobj_describe_struct_child)
4178 (ada_varobj_describe_child): Handle union case like struct one.
4179
4180 2018-09-10 Tom Tromey <tom@tromey.com>
4181
4182 PR python/18380:
4183 * python/python.c (_initialize_python): Make example in "python"
4184 help work in Python 3.
4185
4186 2018-09-10 Eli Zaretskii <eliz@gnu.org>
4187
4188 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
4189 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
4190 $(EXEEXT) to the script, as it is not a program.
4191
4192 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
4193
4194 * python/py-prettyprint.c (pretty_print_one_value): Return
4195 gdbpy_ref<>.
4196 (print_string_repr): Adjust.
4197 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
4198 * python/python-internal.h (apply_varobj_pretty_printer): Return
4199 gdbpy_ref<>.
4200 * varobj.c (varobj_value_get_print_value): Adjust.
4201
4202 2018-09-08 Tom Tromey <tom@tromey.com>
4203
4204 PR python/16047:
4205 * python/py-prettyprint.c (pretty_print_one_value): Check for
4206 to_string method.
4207
4208 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4209
4210 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
4211 replace_operator_with_call.
4212
4213 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4214
4215 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
4216
4217 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4218
4219 * ada-typeprint.c (print_range): Print the bounds using TYPE
4220 rather than its TYPE_TARGET_TYPE.
4221
4222 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4223
4224 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
4225 call to ada_to_fixed_value_create.
4226
4227 2018-09-08 Jerome Guitton <guitton@adacore.com>
4228
4229 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
4230
4231 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4232
4233 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
4234 by calls to error.
4235
4236 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4237
4238 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
4239 Move update of loop variable "fi".
4240
4241 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4242
4243 * ada-lang.c (value_assign_to_component): In the case of
4244 big-endian targets, extract the bits of the given VAL
4245 using an src_offset of zero if container is not a scalar.
4246
4247 2018-09-06 Simon Ser <contact@emersion.fr>
4248
4249 PR gdb/23105
4250 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
4251 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
4252 * fbsd-tdep.c (fbsd_make_note_desc): New.
4253 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
4254 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
4255 * target.h (enum target_object) Add FreeBSD-specific
4256 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
4257
4258 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4259
4260 * compile/compile-c.h (generate_c_for_variable_locations):
4261 Change reference to pointer.
4262 * compile/compile-c-support.c (compile_program) <compute>:
4263 Likewise.
4264 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
4265 (generate_c_for_for_one_variable): Likewise
4266 (generate_c_for_variable_locations): Likewise
4267 * compile/compile-c-types.c (compile_c_instance::convert_type):
4268 Likewise
4269 * compile/compile-cplus-symbols.c (convert_one_symbol):
4270 std::move the scope passed to enter_scope.
4271 * compile/compile-cplus-types.c
4272 (compile_cplus_instance::enter_scope): Make parameter
4273 rvalue-reference.
4274 (compile_cplus_instance::new_scope): Change reference to
4275 pointer.
4276 (compile_cplus_instance::convert_type): Likewise
4277 (compile_cplus_convert_typedef): std::move the scope passed to
4278 enter_scope.
4279 (compile_cplus_convert_struct_or_union): Likewise.
4280 (compile_cplus_convert_enum): Likewise.
4281 (compile_cplus_convert_namespace): Likewise.
4282 * compile/compile-cplus.h (compile_cplus_instance)
4283 <enter_scope>: Make parameter rvalue-reference.
4284 * compile/compile-internal.h (compile_instance)
4285 <get_cached_type>: Likewise
4286 * compile/compile-loc2c.c (push): Likewise
4287 (pushf): Likewise
4288 (unary): Likewise
4289 (binary): Likewise
4290 (print_label): Likewise
4291 (pushf_register_address): Likewise
4292 (pushf_register): Likewise
4293 (do_compile_dwarf_expr_to_c): Likewise
4294 (compile_dwarf_expr_to_c): Likewise
4295 (compile_dwarf_bounds_to_c): Likewise
4296 * compile/compile.c (compile_instance::get_cached_type):
4297 Likewise
4298 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
4299 (compile_dwarf_bounds_to_c): Likewise
4300 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
4301 (dwarf2_compile_property_to_c): Likewise
4302 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
4303 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
4304 Likewise
4305
4306 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4307
4308 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
4309 * tui/tui-data.c (init_content_element): Don't initialize it.
4310
4311 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4312
4313 * tui/tui-data.h (struct tui_win_info)
4314 <detail::opaque>: Remove.
4315 * tui/tui-data.c (init_win_info): Remove assignment.
4316
4317 2018-09-05 Tom Tromey <tom@tromey.com>
4318
4319 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
4320 -Wformat-nonliteral.
4321 * target-float.c (host_float_ops<T>::to_string)
4322 (host_float_ops<T>::from_string): Use
4323 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4324 * configure: Rebuild.
4325
4326 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
4327
4328 * printcmd.c (printf_c_string): Use
4329 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4330 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
4331
4332 2018-09-05 Tom Tromey <tom@tromey.com>
4333
4334 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
4335
4336 2018-09-05 Tom de Vries <tdevries@suse.de>
4337
4338 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
4339 with resolve_abstract_p == true.
4340 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
4341 defaulting to false. Propagate resolve_abstract_p to
4342 dwarf2_fetch_die_loc_sect_off.
4343 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
4344 parameter, defaulting to false.
4345 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
4346 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
4347 parameter.
4348 * dwarf2read.h (struct die_info): Forward-declare.
4349 (die_info_ptr): New typedef.
4350 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
4351
4352 2018-09-05 Joel Brobecker <brobecker@adacore.com>
4353
4354 GDB 8.2 released.
4355
4356 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
4357 Pedro Alves <palves@redhat.com>
4358
4359 * gnulib/Makefile.in (aclocal_m4_deps): Move to
4360 "aclocal-m4-deps.mk". Include file here.
4361 $(srcdir)/aclocal.m4: Add "configure.ac".
4362 * gnulib/aclocal-m4-deps.mk: New file.
4363 * gnulib/update-gnulib.sh: Automatically update
4364 "aclocal-m4-deps.mk".
4365
4366 2018-09-04 Tom Tromey <tom@tromey.com>
4367
4368 * configure: Rebuild.
4369 * configure.ac: Remove multi-ice code.
4370
4371 2018-09-04 Tom Tromey <tom@tromey.com>
4372
4373 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
4374 (ada-exp.o): Update.
4375
4376 2018-09-04 Tom Tromey <tom@tromey.com>
4377
4378 * Makefile.in (printcmd.o, target-float.o): Remove.
4379 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
4380
4381 2018-09-04 Tom Tromey <tom@tromey.com>
4382
4383 * gnulib/Makefile.in: Remove obsolete comment.
4384 * Makefile.in: Remove obsolete comment.
4385
4386 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
4387
4388 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
4389 line with '+'.
4390
4391 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4392
4393 * riscv-tdep.c: Add 'prologue-value.h' include.
4394 (struct riscv_unwind_cache): New struct.
4395 (riscv_debug_unwinder): New global.
4396 (riscv_scan_prologue): Update arguments, capture register details
4397 from prologue scan.
4398 (riscv_skip_prologue): Reformat arguments line, move end of
4399 prologue calculation into riscv_scan_prologue.
4400 (riscv_frame_cache): Update return type, create
4401 riscv_unwind_cache, scan the prologue, and fill in remaining cache
4402 details.
4403 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
4404 (riscv_frame_prev_register): Use the trad_frame within the
4405 riscv_unwind_cache.
4406 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
4407 flag.
4408
4409 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4410
4411 * trad-frame.h (trad_frame_set_realreg): Declare.
4412 (trad_frame_set_addr): Declare.
4413 * trad-frame.c (trad_frame_set_realreg): Define new function.
4414 (trad_frame_set_addr): Define new function.
4415 (trad_frame_set_reg_realreg): Use new function.
4416 (trad_frame_set_reg_addr): Use new function.
4417
4418 2018-09-01 Keith Seitz <keiths@redhat.com>
4419
4420 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
4421 pulongest instead of "%lld".
4422 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
4423 ATTRIBUTE_UNUSED.
4424
4425 2018-08-31 Tom Tromey <tom@tromey.com>
4426
4427 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
4428 variant part type.
4429
4430 2018-08-31 Pedro Alves <palves@redhat.com>
4431
4432 * gdbarch.h: Regenerate.
4433
4434 2018-08-31 Pedro Alves <palves@redhat.com>
4435
4436 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
4437 * target.h (Hardware watchpoint interfaces): Describe
4438 continuable/steppable/non-steppable watchpoints.
4439 * gdbarch.h, gdbarch.c: Regenerate.
4440
4441 2018-08-31 Pedro Alves <palves@redhat.com>
4442
4443 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
4444 Delete.
4445 * s390-linux-nat.c
4446 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
4447 * target.h (target_ops::have_continuable_watchpoint): Delete.
4448 (target_have_continuable_watchpoint): Delete.
4449 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
4450 * target-delegates.c: Regenerate.
4451
4452 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4453
4454 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
4455 the files present in "gnulib/import/m4/".
4456
4457 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4458
4459 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
4460 c.sw, c.swsp, and c.sdsp.
4461
4462 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4463
4464 * riscv-tdep.c (struct riscv_inferior_data): Delete.
4465 (riscv_read_misa_reg): Don't cache value read into inferior data.
4466 (riscv_new_inferior_data): Delete.
4467 (riscv_inferior_data_cleanup): Delete.
4468 (riscv_inferior_data): Delete.
4469 (riscv_invalidate_inferior_data): Delete.
4470 (_initialize_riscv_tdep): Remove initialisation of inferior data.
4471
4472 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
4473
4474 * compile/compile-cplus-types.c
4475 (compile_cplus_instance::leave_scope): Take the address of scope
4476 object.
4477 (compile_cplus_instance::convert_qualified_base): Compare quals
4478 to 0.
4479
4480 2018-08-30 Keith Seitz <keiths@redhat.com>
4481
4482 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
4483 Use "%s" and host_address_to_string instead of "%p" in printf.
4484
4485 2018-08-29 Keith Seitz <keiths@redhat.com>
4486
4487 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
4488 and compile-cplus-types.c.
4489 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
4490 * c-lang.c (cplus_language_defn): Set C++ compile functions.
4491 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
4492 Declare.
4493 * compile/compile-c-support.c: Include compile-cplus.h.
4494 (load_libcompile): Templatize.
4495 (get_compile_context): "New" function.
4496 (c_get_compile_context): Use get_compile_context.
4497 (cplus_get_compile_context): New function.
4498 (cplus_push_user_expression, cplus_pop_user_expression)
4499 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
4500 (cplus_compute_program): Define new structs/functions.
4501 * compile/compile-cplus-symmbols.c: New file.
4502 * compile/compile-cplus-types.c: New file.
4503 * compile/compile-cplus.h: New file.
4504 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
4505 Declare.
4506 * compile/compile-object-load.c (get_out_value_type): Use
4507 strncmp_iw when comparing symbol names.
4508 (compile_object_load): Add mst_bss and mst_data.
4509 * compile/compile.c (_initialize_compile): Remove
4510 -Wno-implicit-function-declaration from `compile_args'.
4511 * compile/gcc-cp-plugin.h: New file.
4512 * NEWS: Mention C++ compile support and new debug options.
4513
4514 2018-08-29 Keith Seitz <keiths@redhat.com>
4515
4516 * linespec.c (collect_info::add_symbol): Make virtual.
4517 (struct symbol_searcher_collect_info): New struct.
4518 (symbol_searcher::find_all_symbols): New method.
4519 * symtab.h (class symbol_searcher): New class.
4520
4521 2018-08-29 Keith Seitz <keiths@redhat.com>
4522
4523 * linespec.c (struct linespec) <function_symbols, label_symbols>:
4524 Change to vector of block_symbol. Update all users.
4525 (struct collect_info) <symbols>: Likewise.
4526 (collect_info::add_symbol): Take block_symbol as argument.
4527 Update all callers.
4528 (decode_compound_collector) <m_symbols>: Change type to vector
4529 of block_symbol. Update all users.
4530 (decode_compound_collector::operator ()): Change parameter type
4531 to block_symbol.
4532 (find_method, find_function_symbols, find_linespec_symbols)
4533 (find_label_symbols_in_block, find_label_symbols): Change symbol
4534 vectors to block_symbol vectors.
4535 * symtab.h (symbol_found_callback_ftype): Change parameter type to
4536 block_symbol.
4537
4538 2018-08-29 Keith Seitz <keiths@redhat.com>
4539
4540 * linespec.c (symbolp): Remove typedef and VEC definitions.
4541 (bound_minimal_symbol_d): Likewise.
4542
4543 2018-08-29 Keith Seitz <keiths@redhat.com>
4544
4545 * linespec.c (decode_compound_collector::decode_compound_collector):
4546 Remove initialization for `m_symtabs'.
4547 (decode_compound_collector::release_symbols): Change return type
4548 to std::vector. Update all callers.
4549 (class decode_compound_collector) <m_symbols>: Change type to
4550 std::vector.
4551 (lookup_prefix_sym): Change return type to std::vector. Update all
4552 callers.
4553 (compare_symbols): Remove.
4554 (std_compare_symbols): Rename to `compare_symbols'.
4555 (find_method): Change `sym_classes' parameter to std::vector.
4556 Update all callers. Use std::sort to sort sym_classes.
4557 (find_linespec_symbols): Remove cleanup.
4558
4559 2018-08-29 Keith Seitz <keiths@redhat.com>
4560
4561 * linespec.c (struct linespec) <minimal_symbols>: Change type to
4562 std::vector. Update all users.
4563 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
4564 (struct collect_info) <minimal_symbols>: Likewise.
4565 (compare_msymbols): Return bool. Change parameters to const
4566 bound_minimal_symbol references.
4567 (find_method, find_function_symbols, find_linespec_symbols): Change
4568 `minsyms' parameter to std::vector. Update all callers.
4569
4570 2018-08-29 Keith Seitz <keiths@redhat.com>
4571
4572 * linespec.c (struct linespec) <label_symbols>: Change type to
4573 std::vector. Update all users.
4574 (find_label_symbols_in_block): Change `result' parameter to
4575 std::vector. Update all callers.
4576 (find_label_symbols): Return std::vector. Update all callers.
4577
4578 2018-08-29 Keith Seitz <keiths@redhat.com>
4579
4580 * linespec.c (struct linespec) <function_symbols>: Change type to
4581 std::vector. Update all users.
4582 (struct collect_info) <function_symbols>: Likewise.
4583 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
4584 (std_compare_symbols): New function.
4585 (find_method, find_function_symbols, find_linespec_symbols)
4586 (find_label_symbols_in_block): Change `symbols' parameter to
4587 std::vector. Update all callers.
4588 (find_label_symbols): Likewise for `function_symbols' and
4589 `label_funcs_ret'.
4590
4591 2018-08-29 Keith Seitz <keiths@redhat.com>
4592
4593 * linespec.c (symtab_vector_up): Define.
4594 (struct linespec) <file_symtabs>: Change type to std::vector *.
4595 Update all uses.
4596 (struct collect_info) <file_symtabs>: Likewise.
4597 (collect_symtabs_from_filename): Return symtab_vector_up.
4598 Update all callers.
4599 (decode_objc): Remove cleanup.
4600 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
4601 (symtab_collector::release_symtabs): Return symtab_vector_up.
4602 Update all callers.
4603 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
4604 Update all users.
4605 (collect_symtabs_from_filename, symtabs_from_filename): Return
4606 symtab_vector_up. Update all callers.
4607
4608 2018-08-29 Tom Tromey <tom@tromey.com>
4609
4610 * csky-tdep.c (csky_analyze_prologue): Use
4611 core_addr_to_string_nz.
4612
4613 2018-08-29 Tom Tromey <tom@tromey.com>
4614
4615 * windows-nat.c (struct xlate_exception) <them>: Change type to
4616 DWORD.
4617 (xlate): Fix formatting. Remove last entry.
4618 (struct xlate_exception, xlate): Comment out.
4619 (windows_nat_target::resume): Use ranged for.
4620
4621 2018-08-29 Jim Wilson <jimw@sifive.com>
4622
4623 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
4624 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
4625 of NT_PRFPREG.
4626 (riscv_linux_nat_target::store_registers): Likewise.
4627
4628 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
4629
4630 PR gdb/23555
4631 PR gdb/23558
4632 * gnulib/aclocal.m4: Regenerate.
4633 * gnulib/config.in: Regenerate.
4634 * gnulib/configure: Regenerate.
4635 * gnulib/import/Makefile.am: Update.
4636 * gnulib/import/Makefile.in: Update.
4637 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
4638 * gnulib/import/_Noreturn.h: ... this.
4639 * gnulib/import/alloca.in.h: Update.
4640 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
4641 * gnulib/import/arg-nonnull.h: ... this.
4642 * gnulib/import/assure.h: Update.
4643 * gnulib/import/at-func.c: Update.
4644 * gnulib/import/basename-lgpl.c: Update.
4645 * gnulib/import/extra/snippet/c++defs.h: Rename to...
4646 * gnulib/import/c++defs.h: ... this.
4647 * gnulib/import/canonicalize-lgpl.c: Update.
4648 * gnulib/import/cdefs.h: Update.
4649 * gnulib/import/chdir-long.c: Update.
4650 * gnulib/import/chdir-long.h: Update.
4651 * gnulib/import/cloexec.c: Update.
4652 * gnulib/import/cloexec.h: Update.
4653 * gnulib/import/close.c: Update.
4654 * gnulib/import/closedir.c: Update.
4655 * gnulib/import/config.charset: Update.
4656 * gnulib/import/dirent-private.h: Update.
4657 * gnulib/import/dirent.in.h: Update.
4658 * gnulib/import/dirfd.c: Update.
4659 * gnulib/import/dirname-lgpl.c: Update.
4660 * gnulib/import/dirname.h: Update.
4661 * gnulib/import/dosname.h: Update.
4662 * gnulib/import/dup-safer-flag.c: Update.
4663 * gnulib/import/dup-safer.c: Update.
4664 * gnulib/import/dup.c: Update.
4665 * gnulib/import/dup2.c: Update.
4666 * gnulib/import/errno.in.h: Update.
4667 * gnulib/import/error.c: Update.
4668 * gnulib/import/error.h: Update.
4669 * gnulib/import/exitfail.c: Update.
4670 * gnulib/import/exitfail.h: Update.
4671 * gnulib/import/extra/update-copyright: Update.
4672 * gnulib/import/fchdir.c: Update.
4673 * gnulib/import/fcntl.c: Update.
4674 * gnulib/import/fcntl.in.h: Update.
4675 * gnulib/import/fd-hook.c: Update.
4676 * gnulib/import/fd-hook.h: Update.
4677 * gnulib/import/fd-safer-flag.c: Update.
4678 * gnulib/import/fd-safer.c: Update.
4679 * gnulib/import/fdopendir.c: Update.
4680 * gnulib/import/filename.h: Update.
4681 * gnulib/import/filenamecat-lgpl.c: Update.
4682 * gnulib/import/filenamecat.h: Update.
4683 * gnulib/import/flexmember.h: Update.
4684 * gnulib/import/float+.h: Update.
4685 * gnulib/import/float.c: Update.
4686 * gnulib/import/float.in.h: Update.
4687 * gnulib/import/fnmatch.c: Update.
4688 * gnulib/import/fnmatch.in.h: Update.
4689 * gnulib/import/fnmatch_loop.c: Update.
4690 * gnulib/import/fpucw.h: Update.
4691 * gnulib/import/frexp.c: Update.
4692 * gnulib/import/frexpl.c: Update.
4693 * gnulib/import/fstat.c: Update.
4694 * gnulib/import/fstatat.c: Update.
4695 * gnulib/import/getcwd-lgpl.c: Update.
4696 * gnulib/import/getcwd.c: Update.
4697 * gnulib/import/getdtablesize.c: Update.
4698 * gnulib/import/getlogin_r.c: Update.
4699 * gnulib/import/getprogname.c: Update.
4700 * gnulib/import/getprogname.h: Update.
4701 * gnulib/import/gettext.h: Update.
4702 * gnulib/import/gettimeofday.c: Update.
4703 * gnulib/import/glob-libc.h: Update.
4704 * gnulib/import/glob.c: Update.
4705 * gnulib/import/glob.in.h: Update.
4706 * gnulib/import/glob_internal.h: Update.
4707 * gnulib/import/glob_pattern_p.c: Update.
4708 * gnulib/import/globfree.c: Update.
4709 * gnulib/import/hard-locale.c: Update.
4710 * gnulib/import/hard-locale.h: Update.
4711 * gnulib/import/intprops.h: Update.
4712 * gnulib/import/inttypes.in.h: Update.
4713 * gnulib/import/isnan.c: Update.
4714 * gnulib/import/isnand-nolibm.h: Update.
4715 * gnulib/import/isnand.c: Update.
4716 * gnulib/import/isnanl-nolibm.h: Update.
4717 * gnulib/import/isnanl.c: Update.
4718 * gnulib/import/itold.c: Update.
4719 * gnulib/import/libc-config.h: Update.
4720 * gnulib/import/limits.in.h: Update.
4721 * gnulib/import/localcharset.c: Update.
4722 * gnulib/import/localcharset.h: Update.
4723 * gnulib/import/localtime-buffer.c: Update.
4724 * gnulib/import/localtime-buffer.h: Update.
4725 * gnulib/import/lstat.c: Update.
4726 * gnulib/import/m4/00gnulib.m4: Update.
4727 * gnulib/import/m4/__inline.m4: Update.
4728 * gnulib/import/m4/absolute-header.m4: Update.
4729 * gnulib/import/m4/alloca.m4: Update.
4730 * gnulib/import/m4/builtin-expect.m4: Update.
4731 * gnulib/import/m4/canonicalize.m4: Update.
4732 * gnulib/import/m4/chdir-long.m4: Update.
4733 * gnulib/import/m4/close.m4: Update.
4734 * gnulib/import/m4/closedir.m4: Update.
4735 * gnulib/import/m4/configmake.m4: Update.
4736 * gnulib/import/m4/d-ino.m4: Update.
4737 * gnulib/import/m4/d-type.m4: Update.
4738 * gnulib/import/m4/dirent_h.m4: Update.
4739 * gnulib/import/m4/dirfd.m4: Update.
4740 * gnulib/import/m4/dirname.m4: Update.
4741 * gnulib/import/m4/double-slash-root.m4: Update.
4742 * gnulib/import/m4/dup.m4: Update.
4743 * gnulib/import/m4/dup2.m4: Update.
4744 * gnulib/import/m4/eealloc.m4: Update.
4745 * gnulib/import/m4/environ.m4: Update.
4746 * gnulib/import/m4/errno_h.m4: Update.
4747 * gnulib/import/m4/error.m4: Update.
4748 * gnulib/import/m4/exponentd.m4: Update.
4749 * gnulib/import/m4/exponentl.m4: Update.
4750 * gnulib/import/m4/extensions.m4: Update.
4751 * gnulib/import/m4/extern-inline.m4: Update.
4752 * gnulib/import/m4/fchdir.m4: Update.
4753 * gnulib/import/m4/fcntl-o.m4: Update.
4754 * gnulib/import/m4/fcntl.m4: Update.
4755 * gnulib/import/m4/fcntl_h.m4: Update.
4756 * gnulib/import/m4/fdopendir.m4: Update.
4757 * gnulib/import/m4/filenamecat.m4: Update.
4758 * gnulib/import/m4/flexmember.m4: Update.
4759 * gnulib/import/m4/float_h.m4: Update.
4760 * gnulib/import/m4/fnmatch.m4: Update.
4761 * gnulib/import/m4/fnmatch_h.m4: Update.
4762 * gnulib/import/m4/fpieee.m4: Update.
4763 * gnulib/import/m4/frexp.m4: Update.
4764 * gnulib/import/m4/frexpl.m4: Update.
4765 * gnulib/import/m4/fstat.m4: Update.
4766 * gnulib/import/m4/fstatat.m4: Update.
4767 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
4768 * gnulib/import/m4/getcwd-path-max.m4: Update.
4769 * gnulib/import/m4/getcwd.m4: Update.
4770 * gnulib/import/m4/getdtablesize.m4: Update.
4771 * gnulib/import/m4/getlogin.m4: Update.
4772 * gnulib/import/m4/getlogin_r.m4: Update.
4773 * gnulib/import/m4/getpagesize.m4: Update.
4774 * gnulib/import/m4/getprogname.m4: Update.
4775 * gnulib/import/m4/gettimeofday.m4: Update.
4776 * gnulib/import/m4/glibc21.m4: Update.
4777 * gnulib/import/m4/glob.m4: Update.
4778 * gnulib/import/m4/glob_h.m4: Update.
4779 * gnulib/import/m4/gnulib-cache.m4: Update.
4780 * gnulib/import/m4/gnulib-common.m4: Update.
4781 * gnulib/import/m4/gnulib-comp.m4: Update.
4782 * gnulib/import/m4/gnulib-tool.m4: Update.
4783 * gnulib/import/m4/hard-locale.m4: Update.
4784 * gnulib/import/m4/include_next.m4: Update.
4785 * gnulib/import/m4/inttypes-pri.m4: Update.
4786 * gnulib/import/m4/inttypes.m4: Update.
4787 * gnulib/import/m4/isnand.m4: Update.
4788 * gnulib/import/m4/isnanl.m4: Update.
4789 * gnulib/import/m4/largefile.m4: Update.
4790 * gnulib/import/m4/limits-h.m4: Update.
4791 * gnulib/import/m4/localcharset.m4: Update.
4792 * gnulib/import/m4/locale-fr.m4: Update.
4793 * gnulib/import/m4/locale-ja.m4: Update.
4794 * gnulib/import/m4/locale-zh.m4: Update.
4795 * gnulib/import/m4/localtime-buffer.m4: Update.
4796 * gnulib/import/m4/longlong.m4: Update.
4797 * gnulib/import/m4/lstat.m4: Update.
4798 * gnulib/import/m4/malloc.m4: Update.
4799 * gnulib/import/m4/malloca.m4: Update.
4800 * gnulib/import/m4/math_h.m4: Update.
4801 * gnulib/import/m4/mbrtowc.m4: Update.
4802 * gnulib/import/m4/mbsinit.m4: Update.
4803 * gnulib/import/m4/mbsrtowcs.m4: Update.
4804 * gnulib/import/m4/mbstate_t.m4: Update.
4805 * gnulib/import/m4/memchr.m4: Update.
4806 * gnulib/import/m4/memmem.m4: Update.
4807 * gnulib/import/m4/mempcpy.m4: Update.
4808 * gnulib/import/m4/memrchr.m4: Update.
4809 * gnulib/import/m4/mkdir.m4: Update.
4810 * gnulib/import/m4/mkstemp.m4: Update.
4811 * gnulib/import/m4/mmap-anon.m4: Update.
4812 * gnulib/import/m4/mode_t.m4: Update.
4813 * gnulib/import/m4/msvc-inval.m4: Update.
4814 * gnulib/import/m4/msvc-nothrow.m4: Update.
4815 * gnulib/import/m4/multiarch.m4: Update.
4816 * gnulib/import/m4/nocrash.m4: Update.
4817 * gnulib/import/m4/off_t.m4: Update.
4818 * gnulib/import/m4/onceonly.m4: Update.
4819 * gnulib/import/m4/open-cloexec.m4: Update.
4820 * gnulib/import/m4/open.m4: Update.
4821 * gnulib/import/m4/openat.m4: Update.
4822 * gnulib/import/m4/opendir.m4: Update.
4823 * gnulib/import/m4/pathmax.m4: Update.
4824 * gnulib/import/m4/rawmemchr.m4: Update.
4825 * gnulib/import/m4/readdir.m4: Update.
4826 * gnulib/import/m4/readlink.m4: Update.
4827 * gnulib/import/m4/realloc.m4: Update.
4828 * gnulib/import/m4/rename.m4: Update.
4829 * gnulib/import/m4/rewinddir.m4: Update.
4830 * gnulib/import/m4/rmdir.m4: Update.
4831 * gnulib/import/m4/save-cwd.m4: Update.
4832 * gnulib/import/m4/secure_getenv.m4: Update.
4833 * gnulib/import/m4/setenv.m4: Update.
4834 * gnulib/import/m4/signal_h.m4: Update.
4835 * gnulib/import/m4/ssize_t.m4: Update.
4836 * gnulib/import/m4/stat-time.m4: Update.
4837 * gnulib/import/m4/stat.m4: Update.
4838 * gnulib/import/m4/std-gnu11.m4: Update.
4839 * gnulib/import/m4/stdbool.m4: Update.
4840 * gnulib/import/m4/stddef_h.m4: Update.
4841 * gnulib/import/m4/stdint.m4: Update.
4842 * gnulib/import/m4/stdio_h.m4: Update.
4843 * gnulib/import/m4/stdlib_h.m4: Update.
4844 * gnulib/import/m4/strchrnul.m4: Update.
4845 * gnulib/import/m4/strdup.m4: Update.
4846 * gnulib/import/m4/strerror.m4: Update.
4847 * gnulib/import/m4/string_h.m4: Update.
4848 * gnulib/import/m4/strstr.m4: Update.
4849 * gnulib/import/m4/strtok_r.m4: Update.
4850 * gnulib/import/m4/sys_socket_h.m4: Update.
4851 * gnulib/import/m4/sys_stat_h.m4: Update.
4852 * gnulib/import/m4/sys_time_h.m4: Update.
4853 * gnulib/import/m4/sys_types_h.m4: Update.
4854 * gnulib/import/m4/tempname.m4: Update.
4855 * gnulib/import/m4/time_h.m4: Update.
4856 * gnulib/import/m4/unistd-safer.m4: Update.
4857 * gnulib/import/m4/unistd_h.m4: Update.
4858 * gnulib/import/m4/warn-on-use.m4: Update.
4859 * gnulib/import/m4/wchar_h.m4: Update.
4860 * gnulib/import/m4/wchar_t.m4: Update.
4861 * gnulib/import/m4/wctype_h.m4: Update.
4862 * gnulib/import/m4/wint_t.m4: Update.
4863 * gnulib/import/malloc.c: Update.
4864 * gnulib/import/malloc/scratch_buffer.h: Update.
4865 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4866 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4867 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4868 * gnulib/import/malloca.c: Update.
4869 * gnulib/import/malloca.h: Update.
4870 * gnulib/import/malloca.valgrind: Update.
4871 * gnulib/import/math.in.h: Update.
4872 * gnulib/import/mbrtowc.c: Update.
4873 * gnulib/import/mbsinit.c: Update.
4874 * gnulib/import/mbsrtowcs-impl.h: Update.
4875 * gnulib/import/mbsrtowcs-state.c: Update.
4876 * gnulib/import/mbsrtowcs.c: Update.
4877 * gnulib/import/memchr.c: Update.
4878 * gnulib/import/memmem.c: Update.
4879 * gnulib/import/mempcpy.c: Update.
4880 * gnulib/import/memrchr.c: Update.
4881 * gnulib/import/mkdir.c: Update.
4882 * gnulib/import/mkstemp.c: Update.
4883 * gnulib/import/msvc-inval.c: Update.
4884 * gnulib/import/msvc-inval.h: Update.
4885 * gnulib/import/msvc-nothrow.c: Update.
4886 * gnulib/import/msvc-nothrow.h: Update.
4887 * gnulib/import/open.c: Update.
4888 * gnulib/import/openat-die.c: Update.
4889 * gnulib/import/openat-priv.h: Update.
4890 * gnulib/import/openat-proc.c: Update.
4891 * gnulib/import/openat.c: Update.
4892 * gnulib/import/openat.h: Update.
4893 * gnulib/import/opendir.c: Update.
4894 * gnulib/import/pathmax.h: Update.
4895 * gnulib/import/pipe-safer.c: Update.
4896 * gnulib/import/rawmemchr.c: Update.
4897 * gnulib/import/readdir.c: Update.
4898 * gnulib/import/readlink.c: Update.
4899 * gnulib/import/realloc.c: Update.
4900 * gnulib/import/ref-add.sin: Update.
4901 * gnulib/import/ref-del.sin: Update.
4902 * gnulib/import/rename.c: Update.
4903 * gnulib/import/rewinddir.c: Update.
4904 * gnulib/import/rmdir.c: Update.
4905 * gnulib/import/same-inode.h: Update.
4906 * gnulib/import/save-cwd.c: Update.
4907 * gnulib/import/save-cwd.h: Update.
4908 * gnulib/import/scratch_buffer.h: Update.
4909 * gnulib/import/secure_getenv.c: Update.
4910 * gnulib/import/setenv.c: Update.
4911 * gnulib/import/signal.in.h: Update.
4912 * gnulib/import/stat-time.c: Update.
4913 * gnulib/import/stat-time.h: Update.
4914 * gnulib/import/stat-w32.c: Update.
4915 * gnulib/import/stat-w32.h: Update.
4916 * gnulib/import/stat.c: Update.
4917 * gnulib/import/stdbool.in.h: Update.
4918 * gnulib/import/stddef.in.h: Update.
4919 * gnulib/import/stdint.in.h: Update.
4920 * gnulib/import/stdio.in.h: Update.
4921 * gnulib/import/stdlib.in.h: Update.
4922 * gnulib/import/str-two-way.h: Update.
4923 * gnulib/import/strchrnul.c: Update.
4924 * gnulib/import/strdup.c: Update.
4925 * gnulib/import/streq.h: Update.
4926 * gnulib/import/strerror-override.c: Update.
4927 * gnulib/import/strerror-override.h: Update.
4928 * gnulib/import/strerror.c: Update.
4929 * gnulib/import/string.in.h: Update.
4930 * gnulib/import/stripslash.c: Update.
4931 * gnulib/import/strnlen1.c: Update.
4932 * gnulib/import/strnlen1.h: Update.
4933 * gnulib/import/strstr.c: Update.
4934 * gnulib/import/strtok_r.c: Update.
4935 * gnulib/import/sys_stat.in.h: Update.
4936 * gnulib/import/sys_time.in.h: Update.
4937 * gnulib/import/sys_types.in.h: Update.
4938 * gnulib/import/tempname.c: Update.
4939 * gnulib/import/tempname.h: Update.
4940 * gnulib/import/time.in.h: Update.
4941 * gnulib/import/unistd--.h: Update.
4942 * gnulib/import/unistd-safer.h: Update.
4943 * gnulib/import/unistd.in.h: Update.
4944 * gnulib/import/unsetenv.c: Update.
4945 * gnulib/import/verify.h: Update.
4946 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4947 * gnulib/import/wchar.in.h: Update.
4948 * gnulib/import/wctype.in.h: Update.
4949 * gnulib/import/xalloc-oversized.h: Update.
4950 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4951 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4952
4953 2018-08-16 Gary Benson <gbenson@redhat.com>
4954
4955 PR gdb/13000:
4956 * gdb/main.c (captured_main_1): Exit with nonzero status
4957 in batch mode if the last command to be executed failed.
4958 * NEWS: Mention the above.
4959
4960 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
4961
4962 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
4963 end of warning message.
4964
4965 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4966
4967 PR gdb/22943:
4968 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
4969 (aarch64_extract_return_value): Use
4970 aapcs_is_vfp_call_or_return_candidate.
4971 (aarch64_return_in_memory): Likewise.
4972 (aarch64_store_return_value): Likewise.
4973
4974 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4975
4976 * aarch64-tdep.c
4977 (aapcs_is_vfp_call_or_return_candidate): Make static
4978 (pass_in_v_or_stack): Remove function.
4979 (pass_in_v_vfp_candidate): New function.
4980 (aarch64_push_dummy_call): Check for float register candidates.
4981
4982 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4983
4984 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
4985 (aapcs_is_vfp_call_or_return_candidate_1): New function.
4986 (aapcs_is_vfp_call_or_return_candidate): Likewise.
4987
4988 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4989
4990 PR build/23399
4991 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
4992 (struct ipa_sym_addresses): Rename to...
4993 (struct ipa_sym_addresses_common): ... this.
4994 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
4995
4996 2018-08-28 Tom Tromey <tom@tromey.com>
4997
4998 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4999 (token_fifo): Now a std::vector.
5000 (yylex, c_parse): Update.
5001 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
5002 (token_fifo): Now a std::vector.
5003 (yylex, d_parse): Update.
5004 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
5005 (token_fifo): Now a std::vector.
5006 (yylex, go_parse): Update.
5007
5008 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
5009
5010 * parser-defs.h (struct type_stack) <elements>: Change type to
5011 std::vector<union type_stack_elt>.
5012 <depth, size>: Remove.
5013 * parse.c (parse_exp_in_context_1): Adjust.
5014 (type_stack_reserve): Remove.
5015 (check_type_stack_depth): Remove.
5016 (insert_into_type_stack): Adjust to std::vector.
5017 (insert_type): Likewise.
5018 (push_type): Likewise.
5019 (push_type_int): Likewise.
5020 (insert_type_address_space): Likewise.
5021 (pop_type): Likewise.
5022 (pop_type_int): Likewise.
5023 (pop_typelist): Likewise.
5024 (pop_type_stack): Likewise.
5025 (append_type_stack): Likewise.
5026 (push_type_stack): Likewise.
5027 (get_type_stack): Likewise.
5028 (type_stack_cleanup): Likewise.
5029 (push_typelist): Likewise.
5030 (follow_types): Likewise.
5031 (_initialize_parse): Likewise.
5032
5033 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
5034
5035 * NEWS: Mention csky target.
5036
5037 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
5038 Hafiz Abid Qadeer <abidh@codesourcery.com>
5039 Don Breazeal <donb@codesourcery.com>
5040
5041 * csky-linux-tdep.c: New file.
5042 * csky-tdep.c: Likewise.
5043 * csky-tdep.h: Likewise.
5044 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
5045 csky-tdep.o.
5046 (HFILES_NO_SRCDIR): Add csky-tdep.h.
5047 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
5048 * configure.tgt: Add csky support.
5049
5050 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
5051
5052 * python/py-framefilter.c (py_print_frame): Print frame architecture
5053 when printing on an MI output.
5054
5055 2018-08-27 Tom Tromey <tom@tromey.com>
5056
5057 PR build/23087:
5058 * configure: Rebuild.
5059 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
5060
5061 2018-08-27 Tom Tromey <tom@tromey.com>
5062
5063 * aarch64-linux-tdep.c
5064 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
5065 casts to int.
5066
5067 2018-08-27 Tom Tromey <tom@tromey.com>
5068
5069 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
5070 unsigned.
5071 (ppc64_standard_linkage1, ppc64_standard_linkage2)
5072 (ppc64_standard_linkage3, ppc64_standard_linkage4)
5073 (ppc64_standard_linkage5, ppc64_standard_linkage6)
5074 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
5075 unsigned.
5076
5077 2018-08-27 Tom Tromey <tom@tromey.com>
5078
5079 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
5080 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
5081
5082 2018-08-27 Tom Tromey <tom@tromey.com>
5083
5084 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
5085 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
5086 ULONGEST_MAX.
5087 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
5088 ULONGEST_MAX.
5089 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
5090 ULONGEST_MAX.
5091 * sparc-linux-tdep.c (sparc32_linux_sigframe)
5092 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
5093 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
5094 ULONGEST_MAX.
5095 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
5096 (ppc64_linux_sigaction_tramp_frame)
5097 (ppc32_linux_sighandler_tramp_frame)
5098 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
5099 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
5100 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
5101 * mn10300-linux-tdep.c (am33_linux_sigframe)
5102 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
5103 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
5104 * mips-linux-tdep.c (mips_linux_o32_sigframe)
5105 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
5106 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
5107 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
5108 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
5109 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
5110 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
5111 * microblaze-linux-tdep.c
5112 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
5113 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
5114 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
5115 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
5116 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
5117 * common/common-types.h (ULONGEST_MAX): New define.
5118 (CORE_ADDR_MAX): Fix formatting.
5119 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
5120 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
5121 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
5122 (arm_linux_rt_sigreturn_tramp_frame)
5123 (arm_eabi_linux_sigreturn_tramp_frame)
5124 (arm_eabi_linux_rt_sigreturn_tramp_frame)
5125 (thumb2_eabi_linux_sigreturn_tramp_frame)
5126 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
5127 (arm_linux_restart_syscall_tramp_frame)
5128 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
5129 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
5130 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
5131 ULONGEST_MAX.
5132 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
5133
5134 2018-08-27 Tom Tromey <tom@tromey.com>
5135
5136 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
5137 CORE_ADDR_MAX.
5138 * mips-tdep.c (mips_deal_with_atomic_sequence)
5139 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
5140 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
5141 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
5142 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
5143 CORE_ADDR_MAX.
5144 * aarch64-tdep.c (aarch64_software_single_step): Use
5145 CORE_ADDR_MAX.
5146
5147 2018-08-27 Tom Tromey <tom@tromey.com>
5148
5149 * linespec.c (complete_linespec_component): Add cast to "char".
5150 * completer.c (completion_tracker::build_completion_result): Add
5151 cast to "char".
5152
5153 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5154
5155 * solist.h (struct solist, struct target_so_ops): Fix
5156 indentation.
5157
5158 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5159
5160 * ada-tasks.c (ada_task_info_s): Remove typedef.
5161 (DEF_VEC_O(ada_task_info_s)): Remove.
5162 (struct ada_tasks_inferior_data): Initialize fields.
5163 <task_list>: Make an std::vector.
5164 (get_ada_tasks_inferior_data): Allocate with new.
5165 (ada_get_task_number): Adjust.
5166 (get_task_number_from_id): Likewise.
5167 (valid_task_id): Likewise.
5168 (ada_get_task_info_from_ptid): Likewise.
5169 (iterate_over_live_ada_tasks): Likewise.
5170 (add_ada_task): Likewise.
5171 (read_known_tasks): Likewise.
5172 (ada_build_task_list): Likewise.
5173 (print_ada_task_info): Likewise.
5174 (info_task): Likewise.
5175 (task_command_1): Likewise.
5176
5177 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5178
5179 * ada-lang.c (add_angle_brackets): Return std::string.
5180
5181 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
5182
5183 * python/py-threadevent.c (py_get_event_thread): Initialize
5184 pythread.
5185
5186 2018-08-24 Pedro Alves <palves@redhat.com>
5187
5188 * python/py-bpevent.c (create_breakpoint_event_object): Use
5189 copy-initialization.
5190 * python/py-continueevent.c (emit_continue_event): Use
5191 copy-initialization.
5192 * python/py-exitedevent.c (create_exited_event_object): Return a
5193 gdbpy_ref<>.
5194 (emit_exited_event): Use copy-initialization.
5195 * python/py-inferior.c (python_new_inferior)
5196 (python_inferior_deleted, add_thread_object): Use
5197 copy-initialization.
5198 * python/py-infevents.c (create_inferior_call_event_object)
5199 (create_register_changed_event_object)
5200 (create_memory_changed_event_object): Return a gdbpy_ref<>.
5201 (emit_inferior_call_event, emit_memory_changed_event)
5202 (emit_register_changed_event): Use copy-initialization.
5203 * python/py-newobjfileevent.c (create_new_objfile_event_object):
5204 Return a gdbpy_ref<>.
5205 (emit_new_objfile_event): Use copy-initialization.
5206 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
5207 (emit_clear_objfiles_event): Use copy-initialization.
5208 * python/py-signalevent.c (create_signal_event_object): Use
5209 copy-initialization.
5210 * python/py-threadevent.c (create_thread_event_object): Use
5211 copy-initialization.
5212
5213 2018-08-24 Pedro Alves <palves@redhat.com>
5214 Simon Marchi <simon.marchi@ericsson.com>
5215
5216 PR gdb/23379
5217 * python/py-continueevent.c: Include "gdbthread.h".
5218 (create_continue_event_object): Add intro comment. Add 'ptid'
5219 parameter. Use it to find thread to pass to
5220 create_thread_event_object.
5221 (emit_continue_event): Pass PTID down to
5222 create_continue_event_object.
5223 * python/py-event.h (py_get_event_thread): Declare.
5224 (create_thread_event_object): Remove default from 'thread'
5225 parameter.
5226 * python/py-stopevent.c (create_stop_event_object): Use
5227 py_get_event_thread.
5228 * python/py-threadevent.c (get_event_thread): Rename to ...
5229 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
5230 and use it to find the thread.
5231 (create_thread_event_object): Assert that THREAD isn't null.
5232 Don't find the event thread here.
5233
5234 2018-08-23 Kevin Buettner <kevinb@redhat.com>
5235
5236 * block.h (blockrange, blockranges): New struct declarations.
5237 (struct block): Add new field named `ranges'.
5238 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
5239 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
5240 macros for accessing ranges in struct block.
5241 (make_blockranges): New declaration.
5242 block.c (make_blockranges): New function.
5243 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
5244 for block.
5245 * symtab.h (find_pc_partial_function): Add new parameter `block'.
5246 * blockframe.c (cache_pc_function_block): New static global.
5247 (clear_pc_function_cache): Clear cache_pc_function_block.
5248 (find_pc_partial_function): Move comment to symtab.h. Add
5249 support for non-contiguous blocks.
5250 * cli/cli-cmds.c (block.h): Include.
5251 (print_disassembly): Handle printing of non-contiguous blocks.
5252 (disassemble_current_function): Likewise.
5253 (disassemble_command): Likewise.
5254
5255 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
5256 BLOCK_START.
5257 * blockframe.c (get_pc_function_start): Likewise.
5258 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
5259 (gcc_symbol_address): Likewise.
5260 * compile/compile-object-run.c (compile_object_run): Likewise.
5261 * compile/compile.c (get_expr_block_and_pc): Likewise.
5262 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
5263 (func_addr_to_tail_call_list): Likewise.
5264 * findvar.c (default_read_var_value): Likewise.
5265 * inline-frame.c (inline_frame_this_id): Likewise.
5266 (skip-inline_frames): Likewise.
5267 * infcmd.c (until_next_command): Likewise.
5268 * linespec.c (convert_linespec_to_sals): Likewise.
5269 * parse.c (parse_exp_in_context_1): Likewise.
5270 * printcmd.c (build_address_symbolic): likewise.
5271 (info_address_command): Likewise.
5272 symtab.c (find_function_start_sal): Likewise.
5273 (skip_prologue_sal): Likewise.
5274 (find_function_alias_target): Likewise.
5275 (find_gnu_ifunc): Likewise.
5276 * stack.c (find_frame_funname): Likewise.
5277 * symtab.c (fixup_symbol_section): Likewise.
5278 (find_function_start_sal): Likewise.
5279 (skip_prologue_sal): Likewsie.
5280 (find_function_alias_target): Likewise.
5281 (find_gnu_ifunc): Likewise.
5282 * tracepoint.c (info_scope_command): Likewise.
5283 * value.c (value_fn_field): Likewise.
5284
5285 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
5286 in place of find_pc_partial_function.
5287 * blockframe.c (find_function_entry_range_from_pc): New function.
5288 * symtab.h (find_function_entry_range_from_pc): Declare and document.
5289 * objfiles.c (objfile_relocate1): Relocate start and end addresses
5290 for each range in a block.
5291
5292
5293 2018-08-23 Xavier Roirand <roirand@adacore.com>
5294
5295 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
5296 incrementation.
5297
5298 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5299
5300 * solib-svr4.c (read_program_headers_from_bfd): Return
5301 gdb::optional<gdb::byte_vector>.
5302 (svr4_exec_displacement): Adjust.
5303
5304 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5305
5306 * solib-svr4.c (read_program_header): Return
5307 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
5308 (find_program_interpreter): Return
5309 gdb::optional<gdb::byte_vector>.
5310 (scan_dyntag_auxv): Adjust.
5311 (enable_break): Adjust.
5312 (svr4_exec_displacement): Adjust.
5313
5314 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5315
5316 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
5317 * inf-child.c (inf_child_target::terminal_save_inferior): New.
5318
5319 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5320
5321 * guile/scm-string.c (gdbscm_scm_from_printf): Use
5322 string_vprintf.
5323 * guile/scm-utils.c (gdbscm_printf): Likewise.
5324 * serial.c (serial_printf): Likewise.
5325 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
5326
5327 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
5328
5329 * stack.c (print_frame): Print frame architecture when printing on
5330 an MI output.
5331 * NEWS: Mention new "arch" attribute in frame output.
5332
5333 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5334
5335 * arch/aarch64.h (aarch64_regnum): Update comment.
5336
5337 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5338
5339 * NEWS: Add SVE to 8.2 section.
5340
5341 2018-08-21 Pedro Alves <palves@redhat.com>
5342
5343 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
5344 out from gdbscm_parse_function_args.
5345 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
5346 gdbscm_parse_function_args_1.
5347
5348 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
5349
5350 PR gdb/17816
5351 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
5352 operator.
5353
5354 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
5355
5356 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
5357
5358 2018-08-19 Michael Spang <spang@google.com>
5359
5360 PR gdb/11786
5361 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
5362 for PT_TLS segments.
5363
5364 2018-08-18 Kevin Buettner <kevinb@redhat.com>
5365
5366 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
5367 dwarf_variable_value.
5368 * dwarf2-frame.c (class dwarf_expr_executor):
5369 Add override for dwarf_variable_value.
5370 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
5371 (class symbol_needs_eval_context): Likewise.
5372 (indirect_synthetic_pointer): Add forward declaration.
5373 (sect_variable_value): New function.
5374 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
5375 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
5376 for DW_OP_GNU_variable_value.
5377
5378 2018-08-16 Tom Tromey <tom@tromey.com>
5379
5380 * top.c (read_command_file): Update.
5381 (command_line_input): Remove "repeat" argument.
5382 * ada-lang.c (get_selections): Update.
5383 * linespec.c (decode_line_2): Update.
5384 * defs.h (command_line_input): Remove argument.
5385 * cli/cli-script.c (read_next_line): Update.
5386 * python/py-gdb-readline.c: Update.
5387
5388 2018-08-17 Tom Tromey <tom@tromey.com>
5389
5390 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
5391 command_line_input.
5392
5393 2018-08-15 Tom Tromey <tom@tromey.com>
5394
5395 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
5396
5397 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
5398
5399 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
5400 If used, use find_pc_partial_function to find address range
5401 to disassemble.
5402 * mi/mi-main.c (mi_cmd_list_features): Report
5403 "data-disassemble-a-option" feature.
5404 * NEWS: Mention new -data-disassemble option -a.
5405
5406 2018-08-13 Tom Tromey <tom@tromey.com>
5407
5408 * common/common-defs.h (_FORTIFY_SOURCE): Define.
5409
5410 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5411
5412 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
5413 (aarch64_linux_collect_sve_regset): Likewise.
5414 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
5415 * regcache.h (regcache_map_entry_size): New function.
5416
5417 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5418
5419 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
5420 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
5421 (SVE_HEADER_VL_LENGTH): Likewise.
5422 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
5423 (SVE_HEADER_FLAGS_LENGTH): Likewise.
5424 (SVE_HEADER_RESERVED_LENGTH): Likewise.
5425 (SVE_HEADER_SIZE_OFFSET): Likewise.
5426 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
5427 (SVE_HEADER_VL_OFFSET): Likewise.
5428 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
5429 (SVE_HEADER_FLAGS_OFFSET): Likewise.
5430 (SVE_HEADER_RESERVED_OFFSET): Likewise.
5431 (SVE_HEADER_SIZE): Likewise.
5432 (aarch64_linux_core_read_vq): Add function.
5433 (aarch64_linux_core_read_description): Check for SVE section.
5434
5435 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5436
5437 * aarch64-fbsd-tdep.c
5438 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
5439 collect_size.
5440 * aarch64-linux-tdep.c
5441 (aarch64_linux_iterate_over_regset_sections): Likewise.
5442 * alpha-linux-tdep.c
5443 (alpha_linux_iterate_over_regset_sections):
5444 * alpha-nbsd-tdep.c
5445 (alphanbsd_iterate_over_regset_sections): Likewise.
5446 * amd64-fbsd-tdep.c
5447 (amd64fbsd_iterate_over_regset_sections): Likewise.
5448 * amd64-linux-tdep.c
5449 (amd64_linux_iterate_over_regset_sections): Likewise.
5450 * arm-bsd-tdep.c
5451 (armbsd_iterate_over_regset_sections): Likewise.
5452 * arm-fbsd-tdep.c
5453 (arm_fbsd_iterate_over_regset_sections): Likewise.
5454 * arm-linux-tdep.c
5455 (arm_linux_iterate_over_regset_sections): Likewise.
5456 * corelow.c (get_core_registers_cb): Likewise.
5457 (core_target::fetch_registers): Likewise.
5458 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
5459 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
5460 * gdbarch.h (void): Regenerate.
5461 * gdbarch.sh: Add supply_size and collect_size.
5462 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
5463 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
5464 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
5465 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
5466 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
5467 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
5468 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
5469 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
5470 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
5471 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
5472 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
5473 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
5474 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
5475 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
5476 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections):
5477 Likewise.
5478 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
5479 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
5480 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
5481 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
5482 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
5483 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
5484 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections):
5485 Likewise.
5486 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
5487 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
5488 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
5489 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
5490 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
5491 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
5492 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
5493 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
5494
5495 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
5496
5497 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
5498 with string_printf.
5499
5500 2018-08-10 Keith Seitz <keiths@redhat.com>
5501
5502 * compile/compile-c-support.c (add_code_header, add_code_footer):
5503 Move into policy class.
5504 (c_push_user_expression, pop_user_expression_nop)
5505 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
5506 (compile_program): New host class.
5507 (c_compile_program): New typedef.
5508 (c_compute_porgram): Use c_compile_program.
5509
5510 2018-08-10 Keith Seitz <keiths@redhat.com>
5511
5512 * compile/compile-internal.h (compile_instance::~compile_instance):
5513 Remove calls to htab_delete.
5514 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
5515 * compile.c (compile_instance::compile_instance): Initialize
5516 htab unique pointers.
5517 (compile_instance::get_cached_type, compile_instance::insert_type)
5518 (compile_instance::error_symbol_once): Update for unique_ptr.
5519
5520 2018-08-10 Keith Seitz <keiths@redhat.com>
5521
5522 * compile/compile-c-symbols.c (struct symbol_error)
5523 (hash_symbol_error, eq_symbol_error, del_symbol_error)
5524 (compile_instance::insert_symbol_error)
5525 (compile_instance::error_symbol_once): Move to ...
5526 * compile/compile.c: ... here.
5527
5528 2018-08-10 Keith Seitz <keiths@redhat.com>
5529
5530 * compile/compile-c-support.c (c_get_compile_context): Use `new'
5531 instead of `new_compile_instance'.
5532 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
5533 Update description.
5534 If the symbol error map is not initialized, create it.
5535 (generate_c_for_for_one_symbol): Do not check/initialize
5536 the symbol error map.
5537 * compile/compile-c-types.c (compile_c_instance): Make a class.
5538 Update all callers.
5539 (compile_instance::compile_instance): Initialize the type cache.
5540 (get_cached_type): New function.
5541 (insert_type): Update description.
5542 (compile_c_instance::m_default_cflags): Define.
5543 (convert_type): Update description. Use get_cached_type.
5544 (delete_instance): Moved to destructor.
5545 (new_compile_instance): Moved to constructor.
5546 * compile/compile-c.h (compile_c_instance): Make class inheriting
5547 from compile_instance.
5548 <base>: Remove field.
5549 <type_map, symbol_err_map>: Move to base class.
5550 <c_plugin>: Rename to `m_plugin' and remove pointer type.
5551 * compile/compile-internal.h (compile_instance): Make class.
5552 <type_map_t, symbol_err_map_t>: Define.
5553 <fe>: Rename to `m_gcc_fe'.
5554 <scope, block, gcc_target_options>: Add `m_' prefix.
5555 <m_type_map, m_symbol_err_map>: New fields, moved from
5556 compile_c_instance.
5557 <destroy>: Remove.
5558 (convert_type, new_compile_instance): Remove.
5559 * compile/compile.c (cleanup_compile_instance): Remove.
5560 (compile_to_object): Use unique_ptr to eliminate cleanups.
5561 (compile_instance::set_print_callback, compile_instance::version)
5562 (compile_instance::set_verbose)
5563 (compile_instance::set_driver_filename)
5564 (compile_instance::set_triplet_regexp)
5565 (compile_instance::set_arguments)
5566 (compile_instance::set_source_file)
5567 (compile_instance::compile): Define.
5568
5569 2018-08-10 Keith Seitz <keiths@redhat.com>
5570
5571 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
5572 * compile/compile-c-types.c: Define GCC_METHODN macros and include
5573 gcc-c-fe.def to define C plugin.
5574 (delete_instance): Delete `c_plugin'.
5575 (new_compile_instance): Initialize `c_plugin'.
5576 * compile/compile-c.h: Include gcc_c_plugin.h.
5577 (struct compile_c_instance) <c_plugin>: New member.
5578 * gcc-c-plugin.h: New file.
5579 Update all callers with API change.
5580
5581 2018-08-10 Keith Seitz <keiths@redhat.com>
5582
5583 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
5584 (HFILES_NO_SRCDIR): ... to here.
5585 Add compile-internal.h and compile-c.h.
5586 * compile/compile-c-support.c: Include compile-c.h.
5587 * compile/compile-c-symbols.c: Include compile-c.h.
5588 (generate_c_for_variable_locations): Update comment.
5589 * compile/compile-c-types.c: Include compile-c.h.
5590 * compile/compile-c.h: New file -- moved C language declarations
5591 from other files here.
5592 * compile/compile-internal.h: Do not include hashtab.h or
5593 common/enum-flags.h.
5594 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
5595 (gcc_convert_symbol, gcc_symbol_address)
5596 (generate_c_for_variable_locations, c_get_mode_for_size)
5597 (c_get_range_decl_name): Definitions moved to compile-c.h.
5598 * compile/compile-loc2c.c: Include compile-c.h.
5599
5600 2018-08-10 Keith Seitz <keiths@redhat.com>
5601
5602 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
5603 (c_symbol_substitution_name): ... this.
5604 Update all callers.
5605
5606 2018-08-10 Keith Seitz <keiths@redhat.com>
5607
5608 * compile/compile-c-support.c (c_compute_program): Use
5609 unique_xmalloc_ptr to eliminate cleanup.
5610 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
5611 Return a unique_xmalloc_ptr and eliminate cleanup.
5612 * compile/compile-internal.h (generate_c_for_variable_locations):
5613 Return unique_xmalloc_ptr and update description.
5614
5615 2018-08-10 Alan Hayward <alan.hayward@arm.com>
5616
5617 * corelow.c (core_target::get_core_register_section): Rename
5618 min_size to section_min_size.
5619
5620 2018-08-09 Jim Wilson <jimw@sifive.com>
5621
5622 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
5623 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
5624 * NEWS: Mention new GNU/Linux RISC-V target.
5625 * configure.host: Add riscv*-*-linux*.
5626 * configure.nat: Add riscv*.
5627 * configure.tgt: Add riscv*-*-linux*.
5628 * riscv-linux-nat.c: New file.
5629 * riscv-linux-tdep.c: New file.
5630
5631 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5632
5633 * infrun.c (resume): Make static, add forward declaration.
5634 (proceed): Update header comment.
5635 * infrun.h (resume): Delete declaration.
5636
5637 2018-08-09 Tom Tromey <tom@tromey.com>
5638
5639 * riscv-tdep.h: Minor formatting fixes.
5640
5641 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
5642
5643 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
5644 * dwarf-index-cache.c (create_dir_and_check): Likewise.
5645 (test_mkdir_recursive): Likewise.
5646 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
5647
5648 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5649
5650 * valarith.c (value_subscripted_rvalue): If an array is not in
5651 memory, and we don't know the upper bound, then we can't know that
5652 the requested element exists or not.
5653
5654 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
5655
5656 * target.c (str_comma_list_concat_elem): Fix typo in comment.
5657 (target_options_to_string): Add comment.
5658
5659 2018-08-08 Tom Tromey <tom@tromey.com>
5660
5661 * unittests/scoped_mmap-selftests.c: Check result of "write".
5662
5663 2018-08-08 Jim Wilson <jimw@sifive.com>
5664
5665 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
5666 (decode_register_index_short): New.
5667 (decode_j_type_insn, decode_cj_type_insn): New.
5668 (decode_b_type_insn, decode_cb_type_insn): New.
5669 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
5670 local xlen. Check xlen when decoding ambiguous compressed insns. In
5671 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
5672 is_c_sw_insn instead of is_sw_insn.
5673 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
5674 (riscv_software_single_step): New.
5675 * riscv-tdep.h (riscv_software_single_step): Declare.
5676
5677 * riscv-tdep.c (riscv_isa_xlen): Drop static.
5678 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
5679
5680 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
5681
5682 PR gdb/18050:
5683 * target.c (dispose_inferior): Don't dispose of inferiors that are
5684 already killed.
5685
5686 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
5687
5688 * remote.c (remote_target::download_tracepoint): Change char* to
5689 const char*.
5690
5691 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
5692
5693 * target.h (target_options_to_string): Return an std::string.
5694 * target.c (str_comma_list_concat_elem): Return void, use
5695 std::string.
5696 (do_option): Likewise.
5697 (target_options_to_string): Return an std::string.
5698 * linux-nat.c (linux_nat_target::wait): Adjust.
5699 * target-debug.h (target_debug_print_options): Adjust.
5700
5701 2018-08-07 Tom Tromey <tom@tromey.com>
5702
5703 * Makefile.in (CPPFLAGS): New variable.
5704 (INTERNAL_CPPFLAGS): Use it.
5705
5706 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5707
5708 * NEWS: Mention the index cache.
5709
5710 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5711
5712 * common/pathstuff.h (get_standard_cache_dir): New.
5713 * common/pathstuff.c (get_standard_cache_dir): New.
5714 * build-id.h (build_id_to_string): New.
5715 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
5716 DEBUG_STR_SUFFIX): Move to here.
5717 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
5718 DEBUG_STR_SUFFIX): Move from there.
5719 (write_psymtabs_to_index): Make non-static, add basename
5720 parameter. Write to temporary files, rename when done.
5721 (save_gdb_index_command): Adjust call to
5722 write_psymtabs_to_index.
5723 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
5724 field.
5725 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
5726 (get_gdb_index_contents_from_cache): New.
5727 (get_gdb_index_contents_from_cache_dwz): New.
5728 (dwarf2_initialize_objfile): Read index from cache.
5729 (dwarf2_build_psymtabs): Save to index.
5730 * dwarf-index-cache.h: New file.
5731 * dwarf-index-cache.c: New file.
5732 * dwarf-index-write.h: New file.
5733
5734 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5735
5736 * gnulib/aclocal.m4: Re-generate.
5737 * gnulib/config.in: Re-generate.
5738 * gnulib/configure: Re-generate.
5739 * gnulib/import/Makefile.am: Re-generate.
5740 * gnulib/import/Makefile.in: Re-generate.
5741 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
5742 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5743 * gnulib/import/m4/mkdir.m4: New file.
5744 * gnulib/import/mkdir.c: New file.
5745 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
5746 module.
5747
5748 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5749
5750 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
5751 * common/scoped_mmap.c: New file.
5752 * common/scoped_mmap.h (destroy): New method.
5753 (~scoped_mmap, reset): Use destroy.
5754 (scoped_mmap): New move constructor.
5755 (mmap_file): New declaration.
5756 * unittests/scoped_mmap-selftests.c (test_normal,
5757 test_invalid_filename, run_tests): New functions.
5758 (_initialize_scoped_mmap_selftests): Register selftest.
5759
5760 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5761
5762 * dwarf2read.c (read_gdb_index_from_section): Rename to...
5763 (read_gdb_index_from_buffer): ... this. Remove section
5764 parameter, add buffer parameter.
5765 (get_gdb_index_contents_ftype,
5766 get_gdb_index_contents_dwz_ftype): New typedefs.
5767 (dwarf2_read_gdb_index): Add callback parameters to get the
5768 index contents.
5769 (get_gdb_index_contents_from_section): New.
5770 (dwarf2_initialize_objfile): Update call to
5771 dwarf2_read_gdb_index.
5772
5773 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5774
5775 * common/filestuff.h (gdb_fopen_cloexec): New overload.
5776 (gdb_open_cloexec): Likewise.
5777 * nat/linux-osdata.c (command_from_pid): Use string_printf.
5778 (commandline_from_pid): Likewise.
5779 (linux_xfer_osdata_threads): Likewise.
5780 (linux_xfer_osdata_fds): Likewise.
5781 * ada-lang.c (is_package_name): Likewise.
5782 * auxv.c (procfs_xfer_auxv): Likewise.
5783 * breakpoint.c (print_one_breakpoint_location): Use
5784 uiout::field_fmt.
5785 (print_one_catch_solib): Use string_printf.
5786 * coff-pe-read.c (add_pe_exported_sym): Likewise.
5787 (add_pe_forwarded_sym): Likewise.
5788 * dwarf2read.c (create_type_unit_group): Likewise.
5789 (build_error_marker_type): Likewise.
5790 * infcall.c (get_function_name): Likewise.
5791 * valprint.c (print_converted_chars_to_obstack): Likewise.
5792 * xtensa-tdep.c (xtensa_register_type): Likewise.
5793
5794 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
5795
5796 * remote.c (remote_target::download_tracepoint): Fix format
5797 string errors.
5798
5799 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5800
5801 * tracefile.c: Include common/byte-vector.h.
5802 (trace_save): Change type of buf to gdb::byte_vector. Initialize
5803 with trace_regblock_size if needed. Update uses of buf.
5804
5805 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5806
5807 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
5808 std::vector<unsigned char>.
5809 * tracepoint.c (collection_list::collection_list): Remove
5810 m_regs_mask initializer from initializer list. Resize
5811 m_regs_mask using the largest remote register number.
5812 (collection_list::add_remote_register): Remove size check on
5813 m_regs_mask. Use at to access element.
5814 (collection_list::stringify): Change type of temp_buf to
5815 gdb::char_vector. Update uses of temp_buf. Resize if needed to
5816 stringify the register mask. Use pack_hex_byte for the register
5817 mask.
5818
5819 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5820
5821 * tracepoint.h (class collection_list) <add_register>: Remove.
5822 <add_remote_register, add_ax_registers, add_local_register>:
5823 Declare.
5824 <add_memrange>: Add scope parameter.
5825 * tracepoint.c (encode_actions_1): Likewise.
5826 (collection_list::add_register): Rename to ...
5827 (collection_list::add_remote_register): ... this. Update
5828 comment.
5829 (collection_list::add_ax_registers, add_local_register): New
5830 methods.
5831 (collection_list::add_memrange): Add scope parameter. Call
5832 add_local_register instead of add_register.
5833 (finalize_tracepoint_aexpr): New function.
5834 (collection_list::collect_symbol): Update calls to add_memrange.
5835 Call add_local_register instead of add_register. Call
5836 add_ax_registers. Call finalize_tracepoint_aexpr.
5837 (encode_actions_1): Get remote regnos for $reg action. Call
5838 add_remote_register, add_ax_registers, and add_local_register.
5839 Update call to add_memrange. Call finalize_tracepoint_aexpr.
5840 (validate_actionline): Call finalize_tracepoint_aexpr.
5841
5842 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5843
5844 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
5845 Replace array buf with gdb::char_vector buf, of size
5846 get_remote_packet_size (). Replace references to buf and
5847 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
5848 and xsnprintf with snprintf. Raise errors if the buffer is too
5849 small.
5850
5851 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5852
5853 * remote.c (remote_target::download_tracepoint): Fix the has_more
5854 predicate in the QTDP action list iteration.
5855
5856 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5857
5858 * remote.c (remote_target::download_tracepoint): Fix indentation
5859 in for block.
5860
5861 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5862
5863 * proc-api.c (_initialize_proc_api): Remove c, unused.
5864 * procfs.c (procfs_init_inferior): Remove signals, unused.
5865 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
5866 unused.
5867
5868 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
5869 Andrew Burgess <andrew.burgess@embecosm.com>
5870
5871 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
5872 'W_STOPCODE (0)' as this could be ambiguous.
5873
5874 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
5875
5876 * ser-tcp.c (net_open): Fix thinko when deciding whether to
5877 disable TCP's Nagle algorithm (use "ai_protocol" instead of
5878 "ai_socktype").
5879
5880 2018-08-02 Tom Tromey <tom@tromey.com>
5881
5882 PR symtab/16842.
5883 * dwarf2read.c (read_func_scope): Set symtab on template parameter
5884 symbols.
5885 (process_structure_scope): Likewise.
5886
5887 2018-08-02 Xavier Roirand <roirand@adacore.com>
5888
5889 PR gdb/22629:
5890 * darwin-nat.c (darwin_kill_inferior): Fix handling of
5891 kill inferior.
5892
5893 2018-08-02 Tom Tromey <tom@tromey.com>
5894
5895 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
5896 (darwin_suspend_inferior, darwin_resume_inferior)
5897 (darwin_decode_notify_message, darwin_resume_inferior_threads)
5898 (darwin_check_new_threads): Check result of get_darwin_inferior.
5899
5900 2018-07-31 Joel Brobecker <brobecker@adacore.com>
5901
5902 GDB 8.1.1 released.
5903
5904 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
5905
5906 * varobj.c (varobj_get_path_expr_parent): Report an error if
5907 parent is a dynamic varobj.
5908
5909 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5910
5911 * gnulib/aclocal.m4: Re-generate.
5912 * gnulib/config.in: Re-generate.
5913 * gnulib/configure: Re-generate.
5914 * gnulib/import/Makefile.in: Re-generate.
5915 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5916 * gnulib/import/m4/onceonly.m4: Re-generate.
5917
5918 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5919
5920 * target-descriptions.c (struct xml_test_tdesc): New.
5921 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
5922 (record_xml_tdesc): Update.
5923 (maintenance_check_xml_descriptions): Update.
5924 * target-descriptions.h (record_xml_tdesc): Update comment.
5925
5926 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
5927
5928 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
5929 checking array bounds are defined.
5930
5931 2018-07-30 Tom Tromey <tom@tromey.com>
5932
5933 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
5934 irreflexivity violation.
5935
5936 2018-07-30 Tom Tromey <tom@tromey.com>
5937
5938 * cli/cli-decode.c (lookup_cmd): Remove lint code.
5939 * value.c (unpack_long): Remove lint code.
5940 * valops.c (value_ind): Remove lint code.
5941 * valarith.c (value_x_binop, value_x_unop, value_equal)
5942 (value_pos): Remove lint code.
5943
5944 2018-07-28 Tom de Vries <tdevries@suse.de>
5945
5946 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
5947 with undefined upper bound as <optimized out>.
5948
5949 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
5950
5951 * gcore.in: Rename variable "name" to "prefix". Expand
5952 "usage" text.
5953
5954 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
5955
5956 * windows-nat.c (windows_nat_target::create_inferior): Update to
5957 call close() in global namespace.
5958
5959 2018-07-26 Tom Tromey <tom@tromey.com>
5960
5961 * dwarf-index-write.c (add_address_entry): Don't add objfile
5962 offsets.
5963 * dbxread.c (find_stab_function): Rename from
5964 find_stab_function_addr. Return a bound_minimal_symbol.
5965 (read_dbx_symtab): Use raw_text_low, raw_text_high.
5966 Don't add objfile offsets.
5967 (end_psymtab): Use raw_text_low, raw_text_high,
5968 MSYMBOL_VALUE_RAW_ADDRESS.
5969 (read_ofile_symtab): Update.
5970 (process_one_symbol): Update.
5971 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
5972 offsets.
5973 (dw2_relocate): Remove.
5974 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
5975 searching addrmap.
5976 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
5977 Update.
5978 (process_psymtab_comp_unit_reader, add_partial_symbol)
5979 (add_partial_subprogram, dwarf2_ranges_read): Update.
5980 (load_partial_dies): Update.
5981 (add_address_entry): Don't add objfile offsets.
5982 (dwarf2_build_include_psymtabs): Update.
5983 (create_addrmap_from_aranges): Don't add objfile offsets.
5984 (dw2_find_pc_sect_compunit_symtab): Update.
5985 * mdebugread.c (parse_symbol): Don't add objfile offsets.
5986 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
5987 Update.
5988 (parse_partial_symbols): Don't add objfile offsets. Use
5989 raw_text_low, raw_text_high. Update.
5990 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
5991 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
5992 or call 'relocate' quick function. Clear psymbol_map.
5993 * psympriv.h (struct partial_symbol) <address>: Add section
5994 offset.
5995 <set_unrelocated_address>: Rename from set_address.
5996 <raw_text_low, raw_text_high>: New methods.
5997 <text_low, text_high>: Add objfile parameter.
5998 (add_psymbol_to_bcache): Add 'section' parameter. Call
5999 set_unrelocated_address.
6000 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
6001 (find_pc_psymbol): Update.
6002 (fixup_psymbol_section, relocate_psymtabs): Remove.
6003 (dump_psymtab, psym_functions): Update.
6004 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
6005 parameter.
6006 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
6007 (start_psymtab_common): Update.
6008 * symfile-debug.c (debug_qf_relocate): Remove.
6009 (debug_sym_quick_functions): Update.
6010 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
6011 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
6012 Update.
6013
6014 2018-07-26 Tom Tromey <tromey@redhat.com>
6015
6016 * dbxread.c (end_psymtab): Use text_high_valid and
6017 text_low_valid.
6018 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
6019 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
6020 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
6021 Update comment.
6022 <text_low_valid, text_high_valid>: New fields.
6023 <set_text_low, set_text_high>: Update.
6024 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
6025
6026 2018-07-26 Tom Tromey <tom@tromey.com>
6027
6028 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
6029 Update.
6030 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
6031 textlow and texthigh fields.
6032 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
6033 Update.
6034 * mdebugread.c (parse_lines, parse_partial_symbols)
6035 (psymtab_to_symtab_1): Update.
6036 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
6037 Rename fields. Update comment. Now private.
6038 <text_low, text_high, set_text_low, set_text_high>: New methods.
6039 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
6040 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
6041 (start_psymtab_common, maintenance_info_psymtabs)
6042 (maintenance_check_psymtabs): Update.
6043 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
6044 texthigh fields.
6045 (scan_xcoff_symtab): Update.
6046
6047 2018-07-26 Tom Tromey <tromey@redhat.com>
6048
6049 * psympriv.h (struct partial_symbol) <unrelocated_address,
6050 address, set_address>: New methods.
6051 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
6052 (fixup_psymbol_section, relocate_psymtabs): Update.
6053 (print_partial_symbols): Add 'objfile' parameter. Update.
6054 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
6055 Update.
6056
6057 2018-07-26 Tom Tromey <tom@tromey.com>
6058
6059 * dwarf-index-write.c (write_psymbols, debug_names::insert)
6060 (debug_names::write_psymbols): Update.
6061 * psympriv.h (struct partial_symbol): Derive from
6062 general_symbol_info.
6063 <obj_section>: New method.
6064 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
6065 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
6066 (find_pc_sect_psymbol, fixup_psymbol_section)
6067 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
6068 (print_partial_symbols, recursively_search_psymtabs)
6069 (compare_psymbols, psymbol_hash, psymbol_compare)
6070 (add_psymbol_to_bcache, maintenance_check_psymtabs)
6071 (psymbol_name_matches, psym_fill_psymbol_map): Update.
6072
6073 2018-07-26 Tom Tromey <tromey@redhat.com>
6074
6075 * dbxread.c (end_psymtab): Remove dead code.
6076
6077 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
6078
6079 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
6080 DWARF unwinders are disabled.
6081 * dwarf2-frame.c: Add dwarf2read.h include.
6082 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
6083 disabled.
6084 (dwarf2_frame_unwinders_enabled_p): Define.
6085 (show_dwarf_unwinders_enabled_p): New function.
6086 (_initialize_dwarf2_frame): Register switch to control DWARF
6087 unwinder use.
6088 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
6089 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
6090 (show_dwarf_cmdlist): Remove static keyword.
6091 * dwarf2read.h (set_dwarf_cmdlist): Declare.
6092 (show_dwarf_cmdlist): Declare.
6093 * NEWS: Document new feature.
6094
6095 2018-07-26 Tom de Vries <tdevries@suse.de>
6096
6097 PR breakpoints/23366
6098 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
6099
6100 2018-07-26 Tom de Vries <tdevries@suse.de>
6101
6102 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
6103 DW_AT_count can't be translated to a dynamic prop.
6104
6105 2018-07-25 Tom de Vries <tdevries@suse.de>
6106
6107 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
6108 try/catch.
6109
6110 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
6111
6112 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
6113
6114 2018-07-25 Joel Brobecker <brobecker@adacore.com>
6115
6116 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
6117
6118 2018-07-24 Keith Seitz <keiths@redhat.comt
6119
6120 PR symtab/23010
6121 * dwarf2read.c (dw2_add_symbol_to_list): New function.
6122 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
6123 instead of add_symbol_to_list.
6124 (read_file_scope): Call prepare_one_comp_unit before reading
6125 any other DIEs.
6126
6127 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
6128
6129 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
6130
6131 2018-07-24 Tom Tromey <tom@tromey.com>
6132
6133 * utils.c (malloc, realloc, free): Don't declare.
6134 * configure, config.in: Rebuild.
6135 * configure.ac: Don't check for declarations of free, malloc, or
6136 realloc.
6137
6138 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
6139
6140 * aarch64-linux-nat.c
6141 (aarch64_linux_nat_target::stopped_data_address): Remove unused
6142 variable.
6143 * arm-linux-nat.c (fetch_regs): Likewise.
6144 (store_regs): Likewise.
6145 (fetch_vfp_regs): Likewise.
6146 (store_vfp_regs): Likewise.
6147 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
6148 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
6149 (arm_linux_nat_target::insert_watchpoint): Likewise.
6150 (arm_linux_nat_target::remove_watchpoint): Likewise.
6151 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
6152 Likewise.
6153 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
6154 Likewise.
6155 * ppc-linux-nat.c (fetch_register): Likewise.
6156 (fetch_all_gp_regs): Likewise.
6157 (fetch_ppc_registers): Likewise.
6158 (store_all_gp_regs): Likewise.
6159 (store_ppc_registers): Likewise.
6160 (hwdebug_insert_point): Likewise.
6161 (can_use_watchpoint_cond_accel): Likewise.
6162 * remote-sim.c (gdb_os_write_stdout): Likewise.
6163
6164 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
6165 Tom Tromey <tom@tromey.com>
6166
6167 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
6168 test for it.
6169 * configure: Rebuild.
6170
6171 2018-07-22 Tom Tromey <tom@tromey.com>
6172
6173 * regformats/regdat.sh: Define xmltarget_${name} inside
6174 #ifndef IN_PROCESS_AGENT.
6175
6176 2018-07-22 Tom Tromey <tom@tromey.com>
6177
6178 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
6179
6180 2018-07-22 Tom Tromey <tom@tromey.com>
6181
6182 * symfile.c (reread_symbols): Notify iter, not objfile.
6183
6184 2018-07-22 Tom Tromey <tom@tromey.com>
6185
6186 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
6187 Use arch_ops.
6188 (ravenscar_thread_target::prepare_to_store): Likewise.
6189
6190 2018-07-22 Tom Tromey <tom@tromey.com>
6191
6192 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
6193 unused variable. Call value_fetch_lazy when needed.
6194 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
6195 Remove unused variable. Call value_fetch_lazy when needed.
6196
6197 2018-07-22 Tom Tromey <tom@tromey.com>
6198
6199 * m32c-tdep.c (mark_dma): Return void.
6200 (make_regs): Remove unused declarations.
6201
6202 2018-07-22 Tom Tromey <tom@tromey.com>
6203
6204 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
6205 cmdscm_get_valid_command_smob_arg_unsafe for effect.
6206 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
6207 bkscm_get_valid_block_smob_arg_unsafe for effect.
6208
6209 2018-07-22 Tom Tromey <tom@tromey.com>
6210
6211 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
6212 value_type.
6213
6214 2018-07-22 Tom Tromey <tom@tromey.com>
6215
6216 * windows-nat.c (saved_context): Conditionally define.
6217 * remote.c (remote_target::remote_btrace_maybe_reopen):
6218 Conditionally declare "warned".
6219 * inflow.c (sigquit_ours): Conditionally define.
6220 (new_tty): Move "tty" declaration inside #if.
6221 * guile/guile.c (guile_datadir): Conditionally define.
6222 * charset.c (set_be_le_names): Move some declarations inside #if.
6223 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
6224 #if.
6225 (parse_xml_btrace_conf): Likewise.
6226
6227 2018-07-22 Tom Tromey <tom@tromey.com>
6228
6229 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
6230
6231 2018-07-22 Tom Tromey <tom@tromey.com>
6232
6233 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
6234 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
6235 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
6236 * buildsym-legacy.c (get_macro_table): Remove unused variable.
6237 * stack.c (frame_apply_level_command): Remove unused variable.
6238 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
6239 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
6240 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
6241 unused variable.
6242 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
6243 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
6244 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
6245 variable.
6246 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
6247 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
6248 variable.
6249 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
6250 Remove unused variable.
6251 * cli/cli-script.c (recurse_read_control_structure): Remove unused
6252 variable.
6253 * common/tdesc.c (print_xml_feature::visit): Remove unused
6254 variable.
6255 * compile/compile-object-load.c (store_regs): Remove unused
6256 variables.
6257 * complaints.c (clear_complaints): Remove unused variable.
6258 * corelow.c (core_target_open): Remove unused variable.
6259 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
6260 variable.
6261 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
6262 variable.
6263 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
6264 variable.
6265 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
6266 variable.
6267 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
6268 variable.
6269 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
6270 variable.
6271 * ia64-tdep.c (examine_prologue): Remove unused variable.
6272 * infcall.c (run_inferior_call): Remove unused variable.
6273 * inferior.c (exit_inferior): Remove unused variable.
6274 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
6275 * linespec.c (decode_line_2): Remove unused variable.
6276 * linux-nat.c (super_close): Remove.
6277 * linux-tdep.c (linux_info_proc): Remove unused variable.
6278 * mi/mi-main.c (mi_execute_command): Remove unused variable.
6279 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
6280 Remove unused variable.
6281 * parse.c (find_minsym_type_and_address): Remove unused variable.
6282 * printcmd.c (info_symbol_command, printf_floating): Remove unused
6283 variable.
6284 * python/py-breakpoint.c (bppy_set_commands): Remove unused
6285 variable.
6286 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
6287 variables.
6288 * record-btrace.c (record_btrace_target::store_registers): Remove
6289 unused variable.
6290 (cmd_show_record_btrace_cpu): Remove unused variable.
6291 * riscv-tdep.c (riscv_register_reggroup_p)
6292 (riscv_push_dummy_call, riscv_return_value): Remove unused
6293 variable.
6294 * rust-exp.y (literal): Remove unused variable.
6295 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
6296 unused variable.
6297 <STRUCTOP_ANONYMOUS>: Likewise.
6298 * s390-linux-tdep.c (s390_linux_init_abi_31)
6299 (s390_linux_init_abi_64): Remove unused variable.
6300 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
6301 (file_select_thread, net_windows_open, _initialize_ser_windows):
6302 Remove unused variables.
6303 * symtab.c (find_pc_sect_line): Remove unused variable.
6304 * target-memory.c (compute_garbled_blocks): Remove unused
6305 variable.
6306 (target_write_memory_blocks): Remove unused variable.
6307 * target.c (target_stack::unpush): Remove unused variables.
6308 * tracepoint.c (start_tracing, all_tracepoint_actions)
6309 (merge_uploaded_trace_state_variables)
6310 (print_one_static_tracepoint_marker): Remove unused variable.
6311 * unittests/basic_string_view/element_access/char/1.cc (test01):
6312 Remove unused variable.
6313 * windows-nat.c (windows_continue, windows_add_all_dlls)
6314 (do_initial_windows_stuff, windows_nat_target::create_inferior):
6315 Remove unused variables.
6316
6317 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
6318
6319 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
6320 attr_profile in HAVE_ELF.
6321 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
6322 HAVE_ELF.
6323
6324 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
6325
6326 * frame.c (frame_register_unwind): Change parameter name.
6327 (frame_unwind_register): Likewise.
6328 (frame_unwind_register_value): Likewise.
6329 (frame_unwind_register_signed): Likewise.
6330 (frame_unwind_register_unsigned): Likewise.
6331 * frame.h (frame_register_unwind): Likewise.
6332 (frame_unwind_register): Likewise.
6333 (frame_unwind_register_value): Likewise.
6334 (frame_unwind_register_signed): Likewise.
6335 (frame_unwind_register_unsigned): Likewise.
6336 (frame_unwind_arch): Likewise.
6337
6338 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6339
6340 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
6341 ISA maintenance.
6342
6343 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6344
6345 * mips-linux-nat.c (mips_linux_nat_target::read_description):
6346 Call `get_ptrace_pid' rather than extracting the ptrace PID by
6347 hand.
6348
6349 2018-07-20 Keith Seitz <keiths@redhat.com>
6350
6351 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
6352 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
6353 m_compunit_symtab, m_language>: Add "m_" prefix.
6354 Update all uses.
6355 * buildsym.c: Update all uses.
6356
6357 2018-07-20 Tom Tromey <tom@tromey.com>
6358
6359 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
6360 * buildsym.h (record_line_ftype): Remove typedef.
6361
6362 2018-07-20 Tom Tromey <tom@tromey.com>
6363
6364 * buildsym-legacy.h (augment_type_symtab): Don't declare.
6365 (end_expandable_symtab): Likewise.
6366 (end_symtab_get_static_block): Likewise.
6367 (end_symtab_from_static_block): Likewise.
6368 * buildsym-legacy.c (augment_type_symtab): Remove.
6369 (end_expandable_symtab): Remove.
6370 (end_symtab_get_static_block): Remove.
6371 (end_symtab_from_static_block): Remove.
6372
6373 2018-07-20 Tom Tromey <tom@tromey.com>
6374
6375 * dwarf2read.c: Include buildsym.h.
6376 (struct dwarf2_cu) <builder>: New method.
6377 (fixup_go_packaging): Update.
6378 (process_full_comp_unit, process_full_type_unit): Update. Don't
6379 use scoped_free_pendings.
6380 (using_directives): Add "cu" parameter, remove "language".
6381 (read_import_statement, setup_type_unit_groups, )
6382 (read_func_scope, read_lexical_block_scope)
6383 (dwarf2_record_block_ranges, read_namespace): Update.
6384 (lnp_state_machine::lnp_state_machine): Add cu parameter.
6385 (lnp_state_machine::handle_end_sequence): Update.
6386 (class lnp_state_machine) <m_cu>: New member.
6387 <m_record_line_callback>: Remove.
6388 <m_currently_recording_lines>: New member.
6389 (lnp_state_machine::handle_set_file): Update.
6390 (noop_record_line): Remove.
6391 (dwarf_record_line_p): Add cu parameter.
6392 (dwarf_record_line_1, dwarf_finish_line): Likewise.
6393 (lnp_state_machine::record_line)
6394 (lnp_state_machine::lnp_state_machine)
6395 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6396 (dwarf_decode_lines): Update.
6397 (dwarf2_start_subfile): Add cu parameter.
6398 (dwarf2_start_symtab, new_symbol): Update.
6399 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
6400 Remove dwarf2_per_objfile parameter.
6401 (dwarf_decode_macros): Update.
6402
6403 2018-07-20 Tom Tromey <tom@tromey.com>
6404
6405 * stabsread.c (define_symbol): Update.
6406 * buildsym-legacy.h (get_buildsym_compunit): Declare.
6407 * dwarf2read.c (new_symbol): Update.
6408 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
6409 * cp-namespace.c: Include buildsym.h.
6410 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
6411 * buildsym-legacy.c (get_buildsym_compunit): New function.
6412
6413 2018-07-20 Tom Tromey <tom@tromey.com>
6414
6415 * xcoffread.c: Include buildsym-legacy.h.
6416 * windows-nat.c: Include buildsym-legacy.h.
6417 * stabsread.c: Include buildsym-legacy.h.
6418 * mdebugread.c: Include buildsym-legacy.h.
6419 * buildsym-legacy.h: New file.
6420 * buildsym-legacy.c: New file, from buildsym.c.
6421 * go32-nat.c: Include buildsym-legacy.h.
6422 * dwarf2read.c: Include buildsym-legacy.h.
6423 * dbxread.c: Include buildsym-legacy.h.
6424 * cp-namespace.c: Include buildsym-legacy.h.
6425 * coffread.c: Include buildsym-legacy.h.
6426 * buildsym.h: Move some contents to buildsym-legacy.h.
6427 * buildsym.c: Include buildsym-legacy.h. Move many functions to
6428 buildsym-legacy.c.
6429 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
6430
6431 2018-07-20 Tom Tromey <tom@tromey.com>
6432
6433 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
6434 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
6435 (buildsym_compunit::buildsym_compunit)
6436 (buildsym_compunit::~buildsym_compunit)
6437 (buildsym_compunit::get_macro_table): Define.
6438
6439 2018-07-20 Tom Tromey <tom@tromey.com>
6440
6441 * buildsym.c (reset_symtab_globals): Remove.
6442 (buildsym_compunit::end_symtab_from_static_block): Update.
6443 (buildsym_compunit::augment_type_symtab): Update.
6444 (end_symtab_from_static_block): Call free_buildsym_compunit.
6445 (augment_type_symtab, end_symtab, end_expandable_symtab):
6446 Likewise.
6447
6448 2018-07-20 Tom Tromey <tom@tromey.com>
6449
6450 * arch-utils.c: Do not include buildsym.h.
6451 * mipsread.c: Do not include buildsym.h.
6452 * machoread.c: Do not include buildsym.h.
6453 * elfread.c: Do not include buildsym.h.
6454
6455 2018-07-20 Tom Tromey <tom@tromey.com>
6456
6457 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
6458 initialization.
6459 (buildsym_compunit): Add new constructor.
6460 (struct buildsym_compunit) <get_last_source_file, finish_block,
6461 record_block_range, start_subfile, patch_subfile_names,
6462 push_subfile, pop_subfile, record_line, get_compunit_symtab,
6463 set_last_source_start_addr, get_last_source_start_addr,
6464 get_local_using_directives, set_local_using_directives,
6465 get_global_using_directives, outermost_context_p,
6466 get_current_context_stack, get_context_stack_depth,
6467 get_current_subfile, get_local_symbols, get_file_symbols,
6468 get_global_symbols, record_debugformat, record_producer,
6469 push_context, pop_context, end_symtab_get_static_block,
6470 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
6471 New public methods.
6472 <record_pending_block, finish_block_internal, make_blockvector,
6473 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
6474 private methods.
6475 Update all users.
6476
6477 2018-05-22 Tom Tromey <tom@tromey.com>
6478
6479 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6480 parameter.
6481 (finish_block_internal): Update.
6482
6483 2018-07-20 Tom Tromey <tom@tromey.com>
6484
6485 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6486 parameter.
6487 (finish_block_internal): Update.
6488
6489 2018-07-20 Tom Tromey <tom@tromey.com>
6490
6491 * buildsym.h (EXTERN): Don't define or undef.
6492 * buildsym.c (EXTERN): Don't define.
6493
6494 2018-07-20 Tom Tromey <tom@tromey.com>
6495
6496 * buildsym.c: Remove TODO comment.
6497
6498 2018-07-20 Tom Tromey <tom@tromey.com>
6499
6500 * coffread.c (coff_symtab_read): Update.
6501 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6502 (xcoff_new_init): Update.
6503 * mipsread.c (mipscoff_new_init): Update.
6504 * mdebugread.c (mdebug_build_psymtabs): Update.
6505 * elfread.c (elf_new_init): Update.
6506 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
6507 Update.
6508 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
6509 (coffstab_build_psymtabs, elfstab_build_psymtabs)
6510 (stabsect_build_psymtabs): Update.
6511 * buildsym.h (buildsym_init): Don't declare.
6512 * buildsym.c: Update comment.
6513 (prepare_for_building): Remove.
6514 (start_symtab, restart_symtab): Update.
6515 (reset_symtab_globals): Update comment.
6516 (buildsym_init): Remove.
6517
6518 2018-07-20 Tom Tromey <tom@tromey.com>
6519
6520 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
6521 * stabsread.c (patch_block_stabs, define_symbol, read_type)
6522 (read_enum_type, common_block_start, common_block_end)
6523 (cleanup_undefined_types_1, finish_global_stabs): Update.
6524 * mdebugread.c (psymtab_to_symtab_1): Update.
6525 * dwarf2read.c (fixup_go_packaging, read_func_scope)
6526 (read_lexical_block_scope, new_symbol): Update.
6527 * dbxread.c (process_one_symbol): Update.
6528 * coffread.c (coff_symtab_read, process_coff_symbol)
6529 (coff_read_enum_type): Update.
6530 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
6531 declare.
6532 (get_local_symbols, get_file_symbols, get_global_symbols): New
6533 functions.
6534 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
6535 m_global_symbols.
6536 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
6537 (~scoped_free_pendings): Update.
6538 (finish_block, prepare_for_building, reset_symtab_globals)
6539 (end_symtab_get_static_block, end_symtab_with_blockvector)
6540 (augment_type_symtab, push_context): Update.
6541 (get_local_symbols, get_file_symbols, get_global_symbols): New
6542 functions.
6543 (buildsym_init): Update.
6544
6545 2018-07-20 Tom Tromey <tom@tromey.com>
6546
6547 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
6548 (process_full_type_unit): Likewise.
6549 (dwarf2_start_symtab): Set list_in_scope.
6550
6551 2018-07-20 Tom Tromey <tom@tromey.com>
6552
6553 * dwarf2read.c (process_psymtab_comp_unit_reader)
6554 (build_type_psymtabs_reader): Do not set list_in_scope.
6555
6556 2018-07-20 Tom Tromey <tom@tromey.com>
6557
6558 * buildsym.c (free_pendings): Remove.
6559 (add_symbol_to_list, scoped_free_pendings)
6560 (finish_block_internal, buildsym_init): Update.
6561
6562 2018-07-20 Tom Tromey <tom@tromey.com>
6563
6564 * xcoffread.c (read_xcoff_symtab): Update.
6565 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
6566 Update.
6567 * dbxread.c (process_one_symbol): Update.
6568 * coffread.c (coff_symtab_read): Update.
6569 * buildsym.h (finish_block): Update.
6570 * buildsym.c (finish_block): Remove "listhead" argument.
6571 (end_symtab_get_static_block): Update.
6572
6573 2018-07-20 Tom Tromey <tom@tromey.com>
6574
6575 * buildsym.h (class scoped_free_pendings): Remove constructor.
6576 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
6577 method.
6578 <m_pending_block_obstack, m_pending_blocks>: New members.
6579 (pending_block_obstack, pending_blocks): Remove.
6580 (scoped_free_pendings::scoped_free_pendings): Default.
6581 (~scoped_free_pendings): Update.
6582 (free_pending_blocks): Remove.
6583 (finish_block_internal, record_pending_block, make_blockvector)
6584 (end_symtab_get_static_block, augment_type_symtab, push_context)
6585 (buildsym_init): Update.
6586
6587 2018-07-20 Tom Tromey <tom@tromey.com>
6588
6589 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
6590 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
6591 members.
6592 (pending_addrmap, pending_addrmap_obstack)
6593 (pending_addrmap_interesting): Remove.
6594 (scoped_free_pendings, record_block_range, make_blockvector)
6595 (prepare_for_building, reset_symtab_globals, buildsym_init):
6596 Update.
6597
6598 2018-07-20 Tom Tromey <tom@tromey.com>
6599
6600 * xcoffread.c (process_linenos): Update.
6601 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
6602 * mdebugread.c (psymtab_to_symtab_1): Update.
6603 * dwarf2read.c (setup_type_unit_groups)
6604 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
6605 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
6606 * dbxread.c (process_one_symbol): Update.
6607 * coffread.c (coff_symtab_read, enter_linenos)
6608 (process_coff_symbol): Update.
6609 * buildsym.h (current_subfile): Don't declare.
6610 (get_current_subfile): Declare.
6611 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
6612 member.
6613 (start_subfile, free_buildsym_compunit, push_subfile)
6614 (prepare_for_building, start_symtab): Update.
6615 (get_current_subfile): New function.
6616
6617 2018-07-20 Tom Tromey <tom@tromey.com>
6618
6619 * coffread.c (coff_symtab_read): Update.
6620 * xcoffread.c (read_xcoff_symtab): Update.
6621 * dwarf2read.c (new_symbol): Update.
6622 (read_func_scope, read_lexical_block_scope): Update.
6623 * dbxread.c (process_one_symbol): Update.
6624 * buildsym.h (context_stack, context_stack_depth): Don't declare.
6625 (outermost_context_p): Remove macro.
6626 (outermost_context_p, get_current_context_stack)
6627 (get_context_stack_depth): Declare.
6628 (pop_context): Return struct context_stack.
6629 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
6630 member.
6631 (context_stack_size): Remove.
6632 (INITIAL_CONTEXT_STACK_SIZE): Remove.
6633 (prepare_for_building, end_symtab_get_static_block)
6634 (augment_type_symtab, push_context): Update.
6635 (pop_context): Return struct context_stack.
6636 (outermost_context_p, get_current_context_stack)
6637 (get_context_stack_depth): New functions.
6638 (buildsym_init): Update.
6639
6640 2018-07-20 Tom Tromey <tom@tromey.com>
6641
6642 * rust-exp.y: Now a pure parser. Update all rules.
6643 (%union): Move earlier.
6644 (current_parser, work_obstack): Remove globals.
6645 (rust_parser, ~rust_parser): Update.
6646 (class rust_parser) <copy_name, concat3, crate_name, super_name,
6647 lex_character, lex_number, lex_string, lex_identifier,
6648 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
6649 convert_name, convert_params_to_expression,
6650 convert_ast_to_expression, ast_basic_type, ast_operation,
6651 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
6652 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
6653 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
6654 ast_array_type, ast_slice_type, ast_reference_type,
6655 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
6656 (rust_parse): Update.
6657 (rustyyerror, rustyylex): Add parser parameter.
6658 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
6659 (rust_lex_stringish_test, rust_lex_test_sequence)
6660 (rust_lex_test_trailing_dot, rust_lex_test_completion)
6661 (rust_lex_test_push_back, rust_lex_tests): Update.
6662
6663 2018-07-19 Pedro Alves <palves@redhat.com>
6664
6665 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
6666 gdb::unique_xmalloc_ptr.
6667 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
6668 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
6669 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
6670 copy-initialization.
6671 * guile/scm-pretty-print.c (ppscm_print_children): Use
6672 gdb::unique_xmalloc_ptr instead of cleanups.
6673 (gdbscm_apply_val_pretty_printer): Remove cleanups.
6674 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
6675 gdb::unique_xmalloc_ptr.
6676 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6677 Adjust to use gdb::unique_xmalloc_ptr.
6678 * guile/scm-utils.c (extract_arg): Adjust.
6679 * guile/scm-value.c (gdbscm_value_field): Adjust to use
6680 gdb::unique_xmalloc_ptr instead of a cleanup.
6681
6682 2018-07-19 Tom Tromey <tom@tromey.com>
6683
6684 * utils.c (do_value_free_to_mark)
6685 (make_cleanup_value_free_to_mark): Remove.
6686 * utils.h (make_cleanup_value_free_to_mark): Remove.
6687
6688 2018-07-19 Pedro Alves <palves@redhat.com>
6689
6690 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
6691 forwarding reference.
6692
6693 2018-07-18 Pedro Alves <palves@redhat.com>
6694
6695 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
6696 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
6697 cleanup.
6698
6699 2018-07-18 Pedro Alves <palves@redhat.com>
6700
6701 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
6702 exceptions.
6703 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
6704 (gdbscm_wrap): New.
6705 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
6706 directly instead of a cleanup.
6707 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
6708 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
6709 (vlscm_binop_gdbthrow): New, factored out from ...
6710 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
6711 (vlscm_rich_compare): Use gdbscm_wrap.
6712 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
6713 instead of a cleanup.
6714 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
6715 cleanup.
6716 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6717 Use xfree directly instead of a cleanup.
6718 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
6719 Adjust to use gdbscm_wrap and scoped_value_mark.
6720 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
6721 (gdbscm_value_address, gdbscm_value_dereference)
6722 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
6723 scoped_value_mark.
6724 (gdbscm_value_dynamic_type): Use scoped_value_mark.
6725 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
6726 scoped_value_mark.
6727 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
6728 gdbscm_wrap and scoped_value_mark.
6729 (gdbscm_value_to_string): Use xfree directly instead of a
6730 cleanup. Move 'buffer' unique_ptr to TRY scope.
6731 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
6732 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
6733 scoped_value_mark.
6734 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
6735 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
6736 scoped_value_mark.
6737 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
6738 gdbscm_wrap.
6739
6740 2018-07-18 Tom de Vries <tdevries@suse.de>
6741
6742 * findvar.c (default_read_var_value): Also resolve dynamic type for
6743 LOC_OPTIMIZED_OUT vars.
6744
6745 2018-07-18 Maciej W. Rozycki <macro@mips.com>
6746
6747 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
6748 decoding.
6749
6750 2018-07-17 Tom Tromey <tom@tromey.com>
6751
6752 * guile/scm-param.c (pascm_set_func, pascm_show_func)
6753 (compute_enum_list, pascm_set_param_value_x)
6754 (gdbscm_parameter_value): Update.
6755 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
6756 (gdbscm_scm_to_host_string): Update.
6757 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
6758 Update.
6759 * guile/scm-cmd.c (cmdscm_add_completion): Update.
6760 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
6761 * guile/scm-string.c (gdbscm_scm_to_string): Return
6762 unique_xmalloc_ptr.
6763 (gdbscm_scm_to_host_string): Likewise.
6764
6765 2018-07-17 Tom Tromey <tom@tromey.com>
6766
6767 * guile/guile.c (gdbscm_eval_from_control_command): Update.
6768 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
6769 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
6770 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
6771 unique_xmalloc_ptr.
6772
6773 2018-07-17 Tom Tromey <tom@tromey.com>
6774
6775 * guile/scm-param.c (pascm_signal_setshow_error): Update.
6776 * guile/guile-internal.h (gdbscm_exception_message_to_string):
6777 Update.
6778 * guile/scm-cmd.c (cmdscm_function): Update.
6779 * guile/scm-pretty-print.c
6780 (ppscm_print_exception_unless_memory_error): Update.
6781 * guile/scm-exception.c (gdbscm_exception_message_to_string):
6782 Return unique_xmalloc_ptr.
6783
6784 2018-07-17 Tom Tromey <tom@tromey.com>
6785
6786 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
6787 Use string_printf.
6788
6789 2018-07-17 Jim Wilson <jimw@sifive.com>
6790
6791 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
6792 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
6793 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
6794 unecessary braces after EF_RISCV_RVC test. Delete call to
6795 set_gdbarch_decr_pc_after_break.
6796
6797 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
6798 RISCV_LAST_FP_REGNUM + 1.
6799 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
6800
6801 2018-07-17 Tom Tromey <tom@tromey.com>
6802
6803 * configure.ac: Remove --disable-gdbcli.
6804 * configure: Rebuild.
6805 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
6806 (SUBDIR_CLI_CFLAGS): Remove.
6807 (SFILES): Use SUBDIR_CLI_SRCS.
6808 (COMMON_OBS): Use SUBDIR_CLI_OBS.
6809
6810 2018-07-17 Tom Tromey <tom@tromey.com>
6811
6812 PR gdb/18624:
6813 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
6814
6815 2018-07-16 Jim Wilson <jimw@sifive.com>
6816
6817 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
6818
6819 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6820
6821 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
6822 variable.
6823 (libunwind_frame_sniffer): Likewise.
6824 (libunwind_frame_prev_register): Likewise.
6825 (libunwind_sigtramp_frame_sniffer): Likewise.
6826 * ia64-tdep.c (ia64_access_reg): Likewise.
6827 (ia64_access_rse_reg): Likewise.
6828 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
6829 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
6830
6831 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6832
6833 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
6834
6835 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6836
6837 * remote-sim.c (gdbsim_target::close,
6838 gdbsim_target::mourn_inferior): Remove unused variables.
6839
6840 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
6841
6842 * ia64-tdep.c (ktab_buf): New global.
6843 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
6844 (get_kernel_table): Adjust.
6845
6846 2018-07-16 Tom Tromey <tom@tromey.com>
6847
6848 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
6849 * dwarf2read.c (using_directives, new_symbol): Use
6850 outermost_context_p.
6851 * dbxread.c (process_one_symbol): Use outermost_context_p.
6852 * coffread.c (coff_symtab_read): Use outermost_context_p.
6853
6854 2018-07-16 Tom Tromey <tom@tromey.com>
6855
6856 * dwarf2read.c (using_directives, read_func_scope)
6857 (read_lexical_block_scope): Update.
6858 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6859 * buildsym.h (local_using_directives, global_using_directives):
6860 Don't declare.
6861 (get_local_using_directives, set_local_using_directives)
6862 (get_global_using_directives): Declare.
6863 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
6864 m_global_using_directives>: New members.
6865 (finish_block_internal, prepare_for_building)
6866 (reset_symtab_globals, end_symtab_get_static_block)
6867 (push_context): Update.
6868 (get_local_using_directives, set_local_using_directives)
6869 (get_global_using_directives): New functions.
6870 (buildsym_init): Update.
6871
6872 2018-07-16 Tom Tromey <tom@tromey.com>
6873
6874 * xcoffread.c (xcoff_initial_scan): Don't call
6875 free_pending_blocks.
6876 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
6877 * buildsym.h (class scoped_free_pendings): Add constructor.
6878 (free_pending_blocks): Don't declare.
6879 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
6880 (free_pending_blocks): Now static.
6881
6882 2018-07-16 Tom Tromey <tom@tromey.com>
6883
6884 * buildsym.h (push_subfile, pop_subfile): Update declarations.
6885 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
6886 member.
6887 (struct subfile_stack): Remove.
6888 (subfile_stack): Remove.
6889 (push_subfile, pop_subfile, buildsym_init): Update.
6890
6891 2018-07-16 Tom Tromey <tom@tromey.com>
6892
6893 * buildsym.c (push_subfile): Use gdb_assert.
6894 (pop_subfile): Use gdb_assert.
6895
6896 2018-07-16 Tom Tromey <tom@tromey.com>
6897
6898 * buildsym.h (merge_symbol_lists): Remove.
6899 * buildsym.c (merge_symbol_lists): Remove.
6900
6901 2018-07-16 Tom Tromey <tom@tromey.com>
6902
6903 * stabsread.c (scan_file_globals): Update comment.
6904 * stabsread.h (scan_file_globals): Move from buildsym.h.
6905 * buildsym.h (scan_file_globals): Move to stabsread.h.
6906
6907 2018-07-16 Tom Tromey <tom@tromey.com>
6908
6909 * xcoffread.c (xcoff_new_init): Update.
6910 * mipsread.c (mipscoff_new_init): Update.
6911 * mdebugread.c (mdebug_build_psymtabs): Update.
6912 * elfread.c (elf_new_init): Update.
6913 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
6914 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
6915 * buildsym.h (buildsym_new_init): Don't declare.
6916 * buildsym.c (buildsym_new_init): Remove.
6917
6918 2018-07-16 Tom Tromey <tom@tromey.com>
6919
6920 * stabsread.h (within_function): Move from buildsym.h.
6921 * stabsread.c (start_stabs): Clear within_function.
6922 * coffread.c (coff_start_symtab): Clear within_function.
6923 * buildsym.h (within_function): Move to stabsread.h.
6924 * buildsym.c (prepare_for_building): Update.
6925
6926 2018-07-16 Tom Tromey <tom@tromey.com>
6927
6928 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
6929 * dwarf2read.c (dwarf2_start_symtab): Don't set
6930 processing_gcc_compilation.
6931 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
6932
6933 2018-07-16 Tom Tromey <tom@tromey.com>
6934
6935 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
6936 (next_symbol_text_func): Move from buildsym.h.
6937 * stabsread.c (hashname): Move from buildsym.c.
6938 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
6939 (next_symbol_text_func, hashname): Move to stabsread.h.
6940 * buildsym.c: Don't include bcache.h
6941 (hashname): Move to stasbread.c.
6942
6943 2018-07-16 Tom Tromey <tom@tromey.com>
6944
6945 * buildsym.h (context_stack_size): Don't declare.
6946 * buildsym.c (context_stack_size): New global.
6947
6948 2018-07-16 Tom Tromey <tom@tromey.com>
6949
6950 * dbxread.c (processing_acc_compilation): New global.
6951 * buildsym.h (processing_acc_compilation): Don't declare.
6952
6953 2018-07-16 Tom Tromey <tom@tromey.com>
6954
6955 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
6956 * dbxread.c (read_ofile_symtab): Update.
6957 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
6958 * buildsym.h (last_source_start_addr): Remove.
6959 (set_last_source_start_addr, get_last_source_start_addr):
6960 Declare.
6961 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
6962 parameter.
6963 (struct buildsym_compunit) <m_last_source_start_addr>: New
6964 member.
6965 (prepare_for_building): Remove start_addr parameter.
6966 (start_symtab, restart_symtab, end_symtab_get_static_block)
6967 (end_symtab_with_blockvector): Update.
6968 (set_last_source_start_addr, get_last_source_start_addr): New
6969 functions.
6970
6971 2018-07-16 Tom Tromey <tom@tromey.com>
6972
6973 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
6974 member.
6975 (have_line_numbers): Remove.
6976 (record_line, prepare_for_building, end_symtab_get_static_block)
6977 (augment_type_symtab): Update.
6978
6979 2018-07-16 Tom Tromey <tom@tromey.com>
6980
6981 * buildsym.c (~buildsym_compunit): Free the macro table.
6982 (struct buildsym_compunit) <get_macro_table, release_macros>: New
6983 methods.
6984 <m_pending_macros>: New member.
6985 (pending_macros): Remove.
6986 (~scoped_free_pendings, get_macro_table, prepare_for_building)
6987 (reset_symtab_globals, end_symtab_get_static_block)
6988 (end_symtab_with_blockvector, augment_type_symtab)
6989 (buildsym_init): Update.
6990
6991 2018-07-16 Tom Tromey <tom@tromey.com>
6992
6993 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
6994 parameter.
6995 (buildsym_compunit::set_last_source_file): New method.
6996 <m_last_source_file>: New member.
6997 (prepare_for_building): Remove "name" parameter.
6998 (start_symtab, restart_symtab, reset_symtab_globals): Update.
6999 (last_source_file): Remove.
7000 (set_last_source_file, get_last_source_file): Update.
7001
7002 2018-07-16 Tom Tromey <tom@tromey.com>
7003
7004 * buildsym.c (prepare_for_building): Add assert.
7005
7006 2018-07-16 Tom Tromey <tom@tromey.com>
7007
7008 * buildsym.c (~buildsym_compunit): Update.
7009 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
7010 (start_subfile, patch_subfile_names)
7011 (end_symtab_with_blockvector): Update.
7012
7013 2018-07-16 Tom Tromey <tom@tromey.com>
7014
7015 * buildsym.c (struct buildsym_compunit): Add constructor,
7016 destructor, initializers.
7017 (start_buildsym_compunit): Remove.
7018 (free_buildsym_compunit): Use "delete".
7019 (start_symtab, restart_symtab): Use "new".
7020
7021 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
7022
7023 * symfile.c (set_objfile_default_section_offset): Remove struct
7024 keyword.
7025
7026 2018-07-14 Stafford Horne <shorne@gmail.com>
7027
7028 * (Responsible Maintainers): Add myself as or1k maintainer.
7029
7030 2018-07-13 Tom Tromey <tom@tromey.com>
7031
7032 * symfile.c (set_objfile_default_section_offset): Use extra braces
7033 around initializer.
7034
7035 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7036
7037 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
7038 non-branching basr.
7039
7040 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7041
7042 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7043 unittests/cli-utils-selftests.c
7044 * unittests/cli-utils-selftests.c: New file.
7045
7046 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7047
7048 * NEWS: Mention new commands. Mention change to 'thread apply'.
7049
7050 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7051
7052 * thread.c (thr_try_catch_cmd): New function.
7053 (thread_apply_all_command): Handle qcs flags.
7054 (thread_apply_command): Handle qcs flags.
7055 (taas_command): New function.
7056 (tfaas_command): New function.
7057 (_initialize_thread): Update to setup the new commands 'taas
7058 and 'tfaas'. Change doc string for 'thread apply'.
7059
7060 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7061
7062 * stack.c: (trailing_outermost_frame): New function, mostly
7063 extracted from backtrace_command_1.
7064 (leading_innermost_frame): New function.
7065 (backtrace_command_1): Update to call trailing_outermost_frame.
7066 (frame_apply_command_count): New function.
7067 (frame_apply_level_command): New function.
7068 (frame_apply_all_command): New function.
7069 (frame_apply_command): New function.
7070 (faas_command): New function.
7071 (frame_cmd_list): New variable.
7072 (_initialize_stack): Update to setup the new commands 'frame apply'
7073 and 'faas'.
7074
7075 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7076
7077 * cli-utils.c (number_or_range_parser::get_number): Only handle
7078 numbers or convenience var as numbers.
7079 (parse_flags): New function.
7080 (parse_flags_qcs): New function.
7081 (number_or_range_parser::finished): Ensure parsing end is detected
7082 before end of string.
7083 * cli-utils.h (parse_flags): New function.
7084 (parse_flags_qcs): New function.
7085 (number_or_range_parser): Remove m_finished bool.
7086 (number_or_range_parser::skip_range): Set m_in_range to false.
7087
7088 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
7089
7090 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
7091 on Windows.
7092
7093 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
7094 Jan Kratochvil <jan.kratochvil@redhat.com>
7095 Paul Fertser <fercerpav@gmail.com>
7096 Tsutomu Seki <sekiriki@gmail.com>
7097 Pedro Alves <palves@redhat.com>
7098
7099 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7100 'unittests/parse-connection-spec-selftests.c'.
7101 (COMMON_SFILES): Add 'common/netstuff.c'.
7102 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
7103 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
7104 * common/netstuff.c: New file.
7105 * common/netstuff.h: New file.
7106 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
7107 (wait_for_connect): Update comment. New parameter
7108 'gdb::optional<int> sock' instead of 'struct serial *scb'.
7109 Use 'sock' directly instead of 'scb->fd'.
7110 (try_connect): New function, with code from 'net_open'.
7111 (net_open): Rewrite main loop to deal with multiple
7112 sockets/addresses. Handle IPv6-style hostnames; implement
7113 support for IPv6 connections.
7114 * unittests/parse-connection-spec-selftests.c: New file.
7115
7116 2018-07-11 Pedro Alves <palves@redhat.com>
7117
7118 PR gdb/23377
7119 * remote.c (remote_target::remote_detach_pid): Call
7120 set_current_process.
7121
7122 2018-07-11 Pedro Alves <palves@redhat.com>
7123
7124 * h8300-tdep.c (h8300_gdbarch_init): Remove
7125 set_gdbarch_ecoff_reg_to_regnum calls.
7126
7127 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
7128
7129 PR c++/23373
7130 * c-typeprint.c (c_type_print_base_struct_union): Don't print
7131 offsets/sizes for static members of a class/struct.
7132
7133 2018-07-11 Alan Hayward <alan.hayward@arm.com>
7134
7135 * target-descriptions.c (tdesc_register_bitsize): Rename.
7136 * target-descriptions.h (tdesc_register_bitsize): Likewise.
7137 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
7138 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
7139
7140 2018-07-10 Tom Tromey <tom@tromey.com>
7141
7142 * breakpoint.c (moribund_locations): Now static and a
7143 std::vector.
7144 (breakpoint_init_inferior, moribund_breakpoint_here_p)
7145 (build_bpstat_chain, update_global_location_list)
7146 (breakpoint_retire_moribund): Update.
7147 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
7148 VEC.
7149
7150 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
7151
7152 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
7153 (riscv_register_reggroup_p): Use new function, remove unneeded
7154 parenthesis.
7155 (riscv_push_dummy_call): Extend assert to compare against xlen or
7156 flen based on register type.
7157
7158 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
7159
7160 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
7161
7162 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
7163
7164 * remote.c (show_hardware_watchpoint_limit): New function.
7165 (show_hardware_watchpoint_length_limit): New function.
7166 (show_hardware_breakpoint_limit): New function.
7167 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
7168 where appropriate, update help text.
7169
7170 2018-07-09 Tom Tromey <tom@tromey.com>
7171
7172 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
7173 (CLIBS): Don't mention NAT_CLIBS.
7174
7175 2018-07-09 Tom Tromey <tom@tromey.com>
7176
7177 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
7178 (LIBGDB_OBS, clean mostlyclean): Update.
7179 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
7180
7181 2018-07-09 Tom Tromey <tom@tromey.com>
7182
7183 * Makefile.in (%.c: %.y): Use ECHO_YACC.
7184 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
7185 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
7186
7187 2018-07-09 Tom Tromey <tom@tromey.com>
7188
7189 * Makefile.in (ALLDEPFILES): Remove exec.c.
7190 (COMMON_OBS): Remove exec.o.
7191 (COMMON_SFILES): Add exec.c.
7192
7193 2018-07-09 Tom Tromey <tom@tromey.com>
7194
7195 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
7196
7197 2018-07-09 Tom Tromey <tom@tromey.com>
7198
7199 * Makefile.in (clean mostlyclean): Remove stamp-version.
7200 (version.c): Depend on stamp-version.
7201 (stamp-version): New rule, from version.c rule.
7202
7203 2018-07-09 Tom Tromey <tom@tromey.com>
7204
7205 * Makefile.in (init.c): Depend on stamp-init.
7206 (stamp-init): New rule, from init.c rule.
7207 (clean mostlyclean): Remove stamp-init.
7208
7209 2018-07-09 Tom Tromey <tom@tromey.com>
7210
7211 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
7212 SUBDIR_GCC_COMPILE_SRCS.
7213
7214 2018-07-09 Tom Tromey <tom@tromey.com>
7215
7216 * Makefile.in (init.c): Remove some unused sed rules.
7217
7218 2018-07-09 Tom Tromey <tom@tromey.com>
7219
7220 * Makefile.in (TSOBS): Remove.
7221 (INIT_FILES): Update.
7222 (LIBGDB_OBS): Update.
7223 (COMMON_SFILES): Add inflow.c.
7224 (SFILES): Remove inflow.c.
7225
7226 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
7227
7228 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
7229
7230 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
7231
7232 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
7233 get_saveloc_name, is_signal_frame_name, step_name,
7234 init_remote_name, create_addr_space_name,
7235 destroy_addr_space_name, search_unwind_table_name,
7236 find_dyn_list_name): Constify.
7237
7238 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
7239
7240 * darwin-nat.c (darwin_pthread_kill): New function.
7241 (darwin_resume_thread): Use darwin_pthread_kill.
7242
7243 2018-07-05 Tom de Vries <tdevries@suse.de>
7244
7245 * macroexp.c (macro_buffer) <operator=>: New member function.
7246
7247 2018-07-04 Tom Tromey <tom@tromey.com>
7248
7249 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
7250
7251 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
7252
7253 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
7254 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
7255 * maint.c: Likewise.
7256 * top.c: Likewise.
7257
7258 2018-07-04 Joel Brobecker <brobecker@adacore.com>
7259
7260 * NEWS: Create a new section for the next release branch.
7261 Rename the section of the current branch, now that it has
7262 been cut.
7263
7264 2018-07-04 Joel Brobecker <brobecker@adacore.com>
7265
7266 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
7267 * version.in: Bump version to 8.2.50.DATE-git.
7268
7269 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
7270 Pedro Alves <palves@redhat.com>
7271
7272 * linux-nat.c (linux_init_ptrace): Rename to ...
7273 (linux_init_ptrace_procfs): ... this. Call
7274 linux_proc_init_warnings.
7275 (linux_nat_target::post_attach)
7276 (linux_nat_target::post_startup_inferior): Adjust.
7277 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
7278 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
7279
7280 2018-07-04 Tom de Vries <tdevries@suse.de>
7281
7282 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
7283 check ...
7284 (read_comp_unit_head): ... here.
7285
7286 2018-07-03 Tom Tromey <tom@tromey.com>
7287
7288 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
7289 (stop_tracing, tstatus_command)
7290 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
7291 (print_one_static_tracepoint_marker): Update.
7292 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
7293 std::vector.
7294 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
7295 VEC.
7296 (all_tracepoints, static_tracepoints_here): Return std::vector.
7297
7298 2018-07-03 Tom Tromey <tom@tromey.com>
7299
7300 * common/ptid.c (ptid_equal): Remove.
7301 * common/ptid.h (ptid_equal): Don't declare.
7302 * ada-tasks.c: Update.
7303 * breakpoint.c: Update.
7304 * common/agent.c: Update.
7305 * corelow.c: Update.
7306 * darwin-nat-info.c: Update.
7307 * darwin-nat.c: Update.
7308 * dcache.c: Update.
7309 * dtrace-probe.c: Update.
7310 * dummy-frame.c: Update.
7311 * fbsd-nat.c: Update.
7312 * frame.c: Update.
7313 * gdbthread.h: Update.
7314 * gnu-nat.c: Update.
7315 * go32-nat.c: Update.
7316 * inf-loop.c: Update.
7317 * inf-ptrace.c: Update.
7318 * infcall.c: Update.
7319 * infcmd.c: Update.
7320 * inflow.c: Update.
7321 * infrun.c: Update.
7322 * linux-fork.c: Update.
7323 * linux-nat.c: Update.
7324 * linux-thread-db.c: Update.
7325 * mi/mi-cmd-var.c: Update.
7326 * mi/mi-interp.c: Update.
7327 * mi/mi-main.c: Update.
7328 * nto-procfs.c: Update.
7329 * ppc-linux-tdep.c: Update.
7330 * procfs.c: Update.
7331 * python/py-inferior.c: Update.
7332 * python/py-record-btrace.c: Update.
7333 * python/py-record.c: Update.
7334 * ravenscar-thread.c: Update.
7335 * regcache.c: Update.
7336 * remote-sim.c: Update.
7337 * remote.c: Update.
7338 * sol-thread.c: Update.
7339 * solib.c: Update.
7340 * target.c: Update.
7341 * tui/tui-stack.c: Update.
7342 * varobj.c: Update.
7343 * windows-nat.c: Update.
7344 * windows-tdep.c: Update.
7345
7346 2018-07-03 Tom Tromey <tom@tromey.com>
7347
7348 * common/ptid.c (ptid_match): Remove.
7349 * common/ptid.h (ptid_match): Don't declare.
7350 * fbsd-nat.c: Update.
7351 * infcmd.c: Update.
7352 * infrun.c: Update.
7353 * linux-nat.c: Update.
7354 * record-btrace.c: Update.
7355 * regcache.c: Update.
7356 * remote.c: Update.
7357
7358 2018-07-03 Tom Tromey <tom@tromey.com>
7359
7360 * common/ptid.c (ptid_tid_p): Remove.
7361 * common/ptid.h (ptid_tid_p): Don't declare.
7362 * sol-thread.c: Update.
7363
7364 2018-07-03 Tom Tromey <tom@tromey.com>
7365
7366 * common/ptid.c (ptid_lwp_p): Remove.
7367 * common/ptid.h (ptid_lwp_p): Don't declare.
7368 * fbsd-nat.c: Update.
7369 * linux-nat.c: Update.
7370 * nat/linux-procfs.c: Update.
7371 * nat/x86-linux-dregs.c: Update.
7372 * sol-thread.c: Update.
7373
7374 2018-07-03 Tom Tromey <tom@tromey.com>
7375
7376 * common/ptid.c (ptid_is_pid): Remove.
7377 * common/ptid.h (ptid_is_pid): Don't declare.
7378 * infrun.c: Update.
7379 * linux-nat.c: Update.
7380 * mi/mi-interp.c: Update.
7381 * remote.c: Update.
7382 * thread.c: Update.
7383
7384 2018-07-03 Tom Tromey <tom@tromey.com>
7385
7386 * common/ptid.c (ptid_get_tid): Remove.
7387 * common/ptid.h (ptid_get_tid): Don't declare.
7388 * ada-tasks.c: Update.
7389 * aix-thread.c: Update.
7390 * bsd-uthread.c: Update.
7391 * darwin-nat.c: Update.
7392 * fbsd-nat.c: Update.
7393 * i386-darwin-nat.c: Update.
7394 * infrun.c: Update.
7395 * linux-tdep.c: Update.
7396 * nto-procfs.c: Update.
7397 * ppc-ravenscar-thread.c: Update.
7398 * python/py-infthread.c: Update.
7399 * ravenscar-thread.c: Update.
7400 * sol-thread.c: Update.
7401 * sparc-ravenscar-thread.c: Update.
7402 * windows-nat.c: Update.
7403
7404 2018-07-03 Tom Tromey <tom@tromey.com>
7405
7406 * common/ptid.c (ptid_get_lwp): Remove.
7407 * common/ptid.h (ptid_get_lwp): Don't declare.
7408 * aarch64-linux-nat.c: Update.
7409 * ada-tasks.c: Update.
7410 * aix-thread.c: Update.
7411 * amd64-linux-nat.c: Update.
7412 * arm-linux-nat.c: Update.
7413 * corelow.c: Update.
7414 * fbsd-nat.c: Update.
7415 * fbsd-tdep.c: Update.
7416 * gnu-nat.c: Update.
7417 * i386-cygwin-tdep.c: Update.
7418 * i386-gnu-nat.c: Update.
7419 * i386-linux-nat.c: Update.
7420 * ia64-linux-nat.c: Update.
7421 * inf-ptrace.c: Update.
7422 * infrun.c: Update.
7423 * linux-fork.c: Update.
7424 * linux-nat.c: Update.
7425 * linux-tdep.c: Update.
7426 * linux-thread-db.c: Update.
7427 * mips-linux-nat.c: Update.
7428 * nat/aarch64-linux-hw-point.c: Update.
7429 * nat/aarch64-linux.c: Update.
7430 * nat/linux-btrace.c: Update.
7431 * nat/linux-osdata.c: Update.
7432 * nat/linux-procfs.c: Update.
7433 * nat/x86-linux-dregs.c: Update.
7434 * obsd-nat.c: Update.
7435 * ppc-fbsd-nat.c: Update.
7436 * ppc-linux-nat.c: Update.
7437 * procfs.c: Update.
7438 * python/py-infthread.c: Update.
7439 * ravenscar-thread.c: Update.
7440 * remote.c: Update.
7441 * s390-linux-nat.c: Update.
7442 * sol-thread.c: Update.
7443 * sol2-tdep.c: Update.
7444 * spu-linux-nat.c: Update.
7445 * x86-linux-nat.c: Update.
7446 * xtensa-linux-nat.c: Update.
7447
7448 2018-07-03 Tom Tromey <tom@tromey.com>
7449
7450 * common/ptid.c (ptid_get_pid): Remove.
7451 * common/ptid.h (ptid_get_pid): Don't declare.
7452 * aarch64-linux-nat.c: Update.
7453 * ada-lang.c: Update.
7454 * aix-thread.c: Update.
7455 * alpha-bsd-nat.c: Update.
7456 * amd64-fbsd-nat.c: Update.
7457 * amd64-linux-nat.c: Update.
7458 * arm-linux-nat.c: Update.
7459 * arm-nbsd-nat.c: Update.
7460 * auxv.c: Update.
7461 * break-catch-syscall.c: Update.
7462 * breakpoint.c: Update.
7463 * bsd-uthread.c: Update.
7464 * corelow.c: Update.
7465 * ctf.c: Update.
7466 * darwin-nat.c: Update.
7467 * fbsd-nat.c: Update.
7468 * fbsd-tdep.c: Update.
7469 * gcore.c: Update.
7470 * gnu-nat.c: Update.
7471 * hppa-nbsd-nat.c: Update.
7472 * hppa-obsd-nat.c: Update.
7473 * i386-fbsd-nat.c: Update.
7474 * ia64-linux-nat.c: Update.
7475 * inf-ptrace.c: Update.
7476 * infcmd.c: Update.
7477 * inferior.c: Update.
7478 * inferior.h: Update.
7479 * inflow.c: Update.
7480 * infrun.c: Update.
7481 * linux-fork.c: Update.
7482 * linux-nat.c: Update.
7483 * linux-tdep.c: Update.
7484 * linux-thread-db.c: Update.
7485 * m68k-bsd-nat.c: Update.
7486 * mi/mi-interp.c: Update.
7487 * mi/mi-main.c: Update.
7488 * mips-linux-nat.c: Update.
7489 * mips-nbsd-nat.c: Update.
7490 * mips64-obsd-nat.c: Update.
7491 * nat/aarch64-linux-hw-point.c: Update.
7492 * nat/aarch64-linux.c: Update.
7493 * nat/linux-btrace.c: Update.
7494 * nat/linux-osdata.c: Update.
7495 * nat/linux-procfs.c: Update.
7496 * nat/x86-linux-dregs.c: Update.
7497 * nto-procfs.c: Update.
7498 * obsd-nat.c: Update.
7499 * ppc-linux-nat.c: Update.
7500 * ppc-nbsd-nat.c: Update.
7501 * ppc-obsd-nat.c: Update.
7502 * proc-service.c: Update.
7503 * procfs.c: Update.
7504 * python/py-inferior.c: Update.
7505 * python/py-infthread.c: Update.
7506 * ravenscar-thread.c: Update.
7507 * record.c: Update.
7508 * remote-sim.c: Update.
7509 * remote.c: Update.
7510 * rs6000-nat.c: Update.
7511 * s390-linux-nat.c: Update.
7512 * sh-nbsd-nat.c: Update.
7513 * sol-thread.c: Update.
7514 * sparc-nat.c: Update.
7515 * sparc64-tdep.c: Update.
7516 * spu-linux-nat.c: Update.
7517 * spu-tdep.c: Update.
7518 * target-debug.h: Update.
7519 * target.c: Update.
7520 * thread.c: Update.
7521 * tid-parse.c: Update.
7522 * tracefile-tfile.c: Update.
7523 * vax-bsd-nat.c: Update.
7524 * windows-nat.c: Update.
7525 * x86-linux-nat.c: Update.
7526 * x86-nat.c: Update.
7527
7528 2018-07-03 Tom Tromey <tom@tromey.com>
7529
7530 * common/ptid.c (pid_to_ptid): Remove.
7531 * common/ptid.h (pid_to_ptid): Don't declare.
7532 * aix-thread.c: Update.
7533 * arm-linux-nat.c: Update.
7534 * common/ptid.c: Update.
7535 * common/ptid.h: Update.
7536 * corelow.c: Update.
7537 * ctf.c: Update.
7538 * darwin-nat.c: Update.
7539 * fbsd-nat.c: Update.
7540 * fork-child.c: Update.
7541 * gnu-nat.c: Update.
7542 * go32-nat.c: Update.
7543 * inf-ptrace.c: Update.
7544 * infcmd.c: Update.
7545 * inferior.c: Update.
7546 * infrun.c: Update.
7547 * linux-fork.c: Update.
7548 * linux-nat.c: Update.
7549 * nat/aarch64-linux-hw-point.c: Update.
7550 * nat/fork-inferior.c: Update.
7551 * nat/x86-linux-dregs.c: Update.
7552 * nto-procfs.c: Update.
7553 * obsd-nat.c: Update.
7554 * procfs.c: Update.
7555 * progspace.c: Update.
7556 * remote.c: Update.
7557 * rs6000-nat.c: Update.
7558 * s390-linux-nat.c: Update.
7559 * sol-thread.c: Update.
7560 * spu-linux-nat.c: Update.
7561 * target.c: Update.
7562 * top.c: Update.
7563 * tracefile-tfile.c: Update.
7564 * windows-nat.c: Update.
7565
7566 2018-07-03 Tom Tromey <tom@tromey.com>
7567
7568 * common/ptid.h (ptid_build): Don't declare.
7569 * common/ptid.c (ptid_build): Remove.
7570 * aix-thread.c: Update.
7571 * bsd-kvm.c: Update.
7572 * bsd-uthread.c: Update.
7573 * common/agent.c: Update.
7574 * common/ptid.c: Update.
7575 * common/ptid.h: Update.
7576 * corelow.c: Update.
7577 * darwin-nat.c: Update.
7578 * fbsd-nat.c: Update.
7579 * gnu-nat.c: Update.
7580 * linux-fork.c: Update.
7581 * linux-nat.c: Update.
7582 * linux-thread-db.c: Update.
7583 * nat/linux-osdata.c: Update.
7584 * nat/linux-procfs.c: Update.
7585 * nto-procfs.c: Update.
7586 * obsd-nat.c: Update.
7587 * proc-service.c: Update.
7588 * procfs.c: Update.
7589 * ravenscar-thread.c: Update.
7590 * remote-sim.c: Update.
7591 * remote.c: Update.
7592 * sol-thread.c: Update.
7593 * target.c: Update.
7594 * windows-nat.c: Update.
7595
7596 2018-07-03 Tom Tromey <tom@tromey.com>
7597
7598 * infrun.c (follow_exec): Use exit_inferior_silent.
7599 * inferior.c (exit_inferior_num_silent): Remove.
7600 * inferior.h (exit_inferior_num_silent): Don't declare.
7601
7602 2018-07-03 Tom Tromey <tom@tromey.com>
7603
7604 PR cli/23340:
7605 * darwin-nat.c (darwin_attach_pid): Reset inferior and
7606 inferior_ptid on error.
7607
7608 2018-07-02 Maciej W. Rozycki <macro@mips.com>
7609 Simon Marchi <simon.marchi@polymtl.ca>
7610
7611 PR tdep/8282
7612 * disasm.h (gdb_disassembler): Add
7613 `m_disassembler_options_holder'. member
7614 * disasm.c (get_all_disassembler_options): New function.
7615 (gdb_disassembler::gdb_disassembler): Use it.
7616 (gdb_buffered_insn_length_init_dis): Likewise.
7617 (gdb_buffered_insn_length): Adjust accordingly.
7618 (set_disassembler_options): Handle options with arguments.
7619 (show_disassembler_options_sfunc): Likewise. Add a leading new
7620 line if showing options with descriptions.
7621 (disassembler_options_completer): Adapt to using the
7622 `disasm_options_and_args_t' structure.
7623 * mips-tdep.c (mips_disassembler_options): New variable.
7624 (mips_disassembler_options_o32): Likewise.
7625 (mips_disassembler_options_n32): Likewise.
7626 (mips_disassembler_options_n64): Likewise.
7627 (gdb_print_insn_mips): Don't set `disassembler_options'.
7628 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
7629 functions.
7630 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
7631 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
7632 `gdbarch_disassembler_options_implicit' and
7633 `gdbarch_valid_disassembler_options'.
7634 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
7635 `disasm_options_and_args_t' structure.
7636 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
7637 method.
7638 (valid_disassembler_options): Switch from `disasm_options_t' to
7639 the `disasm_options_and_args_t' structure.
7640 * NEWS: Document `set disassembler-options' support for the MIPS
7641 target.
7642 * gdbarch.h: Regenerate.
7643 * gdbarch.c: Regenerate.
7644
7645 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
7646
7647 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
7648
7649 2018-06-29 Joel Brobecker <brobecker@adacore.com>
7650
7651 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
7652 parameter in call to amd64_target_description.
7653 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
7654 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
7655 (amd64fbsd_init_abi): Likewise.
7656 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
7657 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7658 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7659 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
7660
7661 2018-06-29 Pedro Alves <palves@redhat.com>
7662
7663 * gdb/amd64-tdep.h (amd64_create_target_description): Add
7664 "segments" parameter.
7665 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
7666 (_initialize_amd64_tdep): Update call to
7667 amd64_create_target_description.
7668 (amd64_target_description): Add "segments" parameter. Adjust
7669 the implementation to use it.
7670 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
7671 call to amd64_create_target_description.
7672 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
7673 * gdb/arch/amd64.h (amd64_create_target_description): Add
7674 "segments" register.
7675 * gdb/arch/amd64.c (amd64_create_target_description): Add
7676 "segments" parameter. Call create_feature_i386_64bit_segments
7677 only if SEGMENTS is true.
7678 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
7679 call to amd64_create_target_description.
7680
7681 2018-06-29 Pedro Alves <palves@redhat.com>
7682
7683 * thread.c (thread_target_id_str): New, factored out from ...
7684 (print_thread_info_1): ... here. Use it to compute the max
7685 "Target Id" column width.
7686
7687 2018-06-29 Pedro Alves <palves@redhat.com>
7688
7689 * remote.c (remote_target::extra_thread_info): Delete
7690 'display_buf' and 'n' locals. from the cache, regardless of
7691 packet mechanims is in use. Use cache for qThreadExtra and qP
7692 methods too.
7693
7694 2018-06-29 Pedro Alves <palves@redhat.com>
7695
7696 * blockframe.c (find_pc_sect_containing_function): New function.
7697 * breakpoint.c (print_breakpoint_location): Don't call
7698 find_pc_sect_function.
7699 * linespec.c (create_sals_line_offset): Record the location's
7700 symbol in the sal.
7701 * linespec.c (convert_address_location_to_sals): Fill in sal's
7702 symbol with find_pc_sect_containing_function.
7703 * symtab.c (find_function_start_sal): Rename to ...
7704 (find_function_start_sal_1): ... this.
7705 (find_function_start_sal): Reimplement as wrapper around
7706 find_function_start_sal_1, and use
7707 find_pc_sect_containing_function to fill in the sal's symbol.
7708 (find_function_start_sal(symbol*, bool)): Adjust.
7709 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
7710 comments.
7711 (find_pc_sect_containing_function): Declare.
7712
7713 2018-06-29 Pedro Alves <palves@redhat.com>
7714
7715 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
7716 true if the the location has no symbol.
7717
7718 2018-06-28 Tom Tromey <tom@tromey.com>
7719
7720 * NEWS: Mention --enable-codesign.
7721 * silent-rules.mk (ECHO_SIGN): New variable.
7722 * configure.ac: Add --enable-codesign.
7723 * configure: Rebuild.
7724 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
7725 (gdb$(EXEEXT)): Optionally invoke codesign.
7726
7727 2018-06-28 Pedro Alves <palves@redhat.com>
7728
7729 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
7730 comments.
7731 (switch_to_thread_no_regs): Adjust comment.
7732 * infcmd.c (stop_pc): Delete.
7733 (post_create_inferior, info_program_command): Replace references
7734 to stop_pc with references to thread_info->suspend.stop_pc.
7735 * inferior.h (stop_pc): Delete declaration.
7736 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
7737 (handle_inferior_event_1, handle_signal_stop)
7738 (process_event_stop_test, keep_going_stepped_thread)
7739 (handle_step_into_function, handle_step_into_function_backward)
7740 (print_stop_location): Replace references to stop_pc with
7741 references to thread_info->suspend.stop_pc.
7742 (struct infcall_suspend_state) <stop_pc>: Delete field.
7743 (save_infcall_suspend_state, restore_infcall_suspend_state):
7744 Remove references to inf_stat->stop_pc.
7745 * linux-fork.c (fork_load_infrun_state): Likewise.
7746 * record-btrace.c (record_btrace_set_replay): Likewise.
7747 * record-full.c (record_full_goto_entry): Likewise.
7748 * remote.c (print_one_stopped_thread): Likewise.
7749 * target.c (target_resume): Extend comment.
7750 * thread.c (set_executing_thread): New.
7751 (set_executing): Use it.
7752 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
7753 Remove references to stop_pc.
7754
7755 2018-06-28 Pedro Alves <palves@redhat.com>
7756
7757 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
7758 Moving fetching stop_pc until after ecs->event_thread is refreshed.
7759
7760 2018-06-28 Tom Tromey <tom@tromey.com>
7761
7762 * coffread.c (coff_symfile_finish): Update.
7763 * xcoffread.c (xcoff_symfile_finish): Update.
7764 * elfread.c (elf_symfile_finish): Update.
7765 * symfile.h (dwarf2_free_objfile): Don't declare.
7766 * dwarf2read.c (_initialize_dwarf2_read): Use
7767 register_objfile_data_with_cleanup.
7768 (dwarf2_free_objfile): Now static. Change signature.
7769
7770 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7771
7772 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
7773 option "-o" to add-symbol-file-load to add an offset to each
7774 section's load address.
7775 * symfile.c (set_objfile_default_section_offset): New function.
7776
7777 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7778
7779 * symfile.c (add_symbol_file_command): Make sure that sections
7780 with the same name are sorted in the same order.
7781
7782 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7783
7784 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
7785 require the second argument. If omitted, load sections at the
7786 addresses specified in the file.
7787
7788 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7789
7790 * symfile.c (symbol_file_command, symbol_file_add_main_1)
7791 (_initialize_symfile): Add option "-o" to symbol-file to add an
7792 offset to each section of the symbol file.
7793
7794 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7795
7796 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
7797
7798 2018-06-27 Tom Tromey <tom@tromey.com>
7799
7800 * stack.c (_initialize_stack): Update "func" help text.
7801
7802 2018-06-27 Tom Tromey <tom@tromey.com>
7803
7804 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
7805 std::vector.
7806 (unwind_infopy_str, pyuw_create_unwind_info)
7807 (unwind_infopy_add_saved_register, pyuw_sniffer)
7808 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
7809 Update.
7810 (struct saved_reg): Add constructor.
7811 <value>: Now a gdbpy_ref<>.
7812
7813 2018-06-27 Tom Tromey <tom@tromey.com>
7814
7815 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
7816
7817 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7818
7819 * gdb-gdb.py.in: Format using autopep8.
7820
7821 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7822
7823 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
7824 (type_lookup_function): Recognize CORE_ADDR values.
7825
7826 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7827
7828 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
7829 print tag_name.
7830
7831 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7832
7833 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
7834 <__lt__>: Add.
7835
7836 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7837
7838 * gdb-gdb.py: Move to...
7839 * gdb-gdb.py.in: ... here.
7840 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
7841 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
7842 dependencies.
7843 (distclean): Remove gdb-gdb.py when cleaning.
7844 (gdb-gdb.py, gdb-gdb.gdb): New rules.
7845 * configure: Re-generate.
7846
7847 2018-06-27 Pedro Alves <palves@redhat.com>
7848
7849 * proc-service.c (get_ps_regcache): New.
7850 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7851 (ps_lsetfpregs): Use it.
7852
7853 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
7854
7855 PR gdb/21695
7856 * dwarf2read.c (lnp_state_machine::check_line_address): Update
7857 declaration.
7858 (dwarf_decode_lines_1): Adjust.
7859
7860 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7861
7862 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
7863 override.
7864 <info_proc>: Likewise.
7865
7866 2018-06-26 Joel Brobecker <brobecker@adacore.com>
7867
7868 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
7869 to windows_fetch_one_register, and only handle the case of
7870 fetching one register. Move the code that reloads the context
7871 and iterates over all registers if R is negative to...
7872 (windows_nat_target::fetch_registers): ... here.
7873 (do_windows_store_inferior_registers): Rename to
7874 windows_store_one_register, and only handle the case of storing
7875 one register. Move the code that handles the case where r is
7876 negative to...
7877 (windows_nat_target::store_registers) ... here.
7878
7879 2018-06-26 Tom Tromey <tom@tromey.com>
7880
7881 PR rust/22574:
7882 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
7883 * rust-lang.c (rust_print_struct_def): Add podata parameter.
7884 Update.
7885 (rust_internal_print_type): Add podata parameter.
7886 (rust_print_type): Update.
7887
7888 2018-06-26 Tom Tromey <tom@tromey.com>
7889
7890 * typeprint.h (struct print_offset_data) <update, finish,
7891 maybe_print_hole>: New methods.
7892 <indentation>: New constant.
7893 * typeprint.c (print_offset_data::indentation): Define.
7894 (print_offset_data::maybe_print_hole, print_offset_data::update)
7895 (print_offset_data::finish): Move from c-typeprint.c and rename.
7896 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
7897 (print_spaces_filtered_with_print_options): Update.
7898 (c_print_type_union_field_offset, maybe_print_hole)
7899 (c_print_type_struct_field_offset): Move to typeprint.c and
7900 rename.
7901 (c_type_print_base_struct_union): Update.
7902
7903 2018-06-25 Pedro Alves <palves@redhat.com>
7904
7905 * gdbthread.h (thread_info_ref, delete_thread)
7906 (delete_thread_silent, first_thread_of_inferior)
7907 (any_thread_of_inferior, switch_to_thread)
7908 (enable_thread_stack_temporaries)
7909 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7910 (get_last_thread_stack_temporary)
7911 (value_in_thread_stack_temporaries, can_access_registers_thread):
7912 Spell out "struct thread_info" instead of just "thread_info".
7913 * inferior.h (notice_new_inferior): Likewise.
7914
7915 2018-06-25 Pedro Alves <palves@redhat.com>
7916
7917 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7918 pass thread_info pointer to delete_thread.
7919 (windows_nat_target::detach): Pass inferior pointer to
7920 detach_inferior.
7921 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
7922 delete_thread.
7923 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
7924 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
7925 and pass a thread_info pointer to delete_thread.
7926 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
7927 pass thread_info pointer to delete_thread.
7928 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
7929 delete_thread_silent call.
7930 * procfs.c (procfs_target::detach): Pass inferior pointer to
7931 detach_inferior.
7932 (procfs_target::wait): Pass thread_info pointer to delete_thread.
7933 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
7934 delete_thread_silent call.
7935 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7936 pass thread_info pointer to delete_thread.
7937 (windows_nat_target::detach): Pass inferior pointer to
7938 delete_inferior.
7939
7940 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7941
7942 * regcache.c (readable_regcache::read_part): Fix asserts.
7943 (reg_buffer::raw_collect_part): New function.
7944 (regcache::write_part): Fix asserts.
7945 (reg_buffer::raw_supply_part): New function.
7946 (regcache::transfer_regset_register): New helper function.
7947 (regcache::transfer_regset): Call new functions.
7948 (regcache_supply_regset): Use gdb_byte*.
7949 (regcache::supply_regset): Likewise.
7950 (regcache_collect_regset): Likewise.
7951 (regcache::collect_regset): Likewise.
7952 * regcache.h (reg_buffer::raw_collect_part): New declaration.
7953 (reg_buffer::raw_supply_part): Likewise.
7954 (regcache::transfer_regset_register): Likewise.
7955 (regcache::transfer_regset): Use gdb_byte*.
7956
7957 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7958
7959 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
7960
7961 2018-06-21 Pedro Alves <palves@redhat.com>
7962
7963 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
7964 instead of a ptid_t. All callers adjusted.
7965 * ada-tasks.c (ada_get_task_number): Likewise. All callers
7966 adjusted.
7967 (print_ada_task_info, display_current_task_id, task_command_1):
7968 Adjust.
7969 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
7970 inferior_thread.
7971 (breakpoint_kind): Adjust.
7972 (remove_breakpoints_pid): Rename to ...
7973 (remove_breakpoints_inf): ... this. Adjust to take an inferior
7974 pointer. All callers adjusted.
7975 (bpstat_clear_actions): Use inferior_thread.
7976 (get_bpstat_thread): New.
7977 (bpstat_do_actions): Use it.
7978 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
7979 to take a thread_info pointer. All callers adjusted.
7980 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
7981 (breakpoint_re_set_thread): Use inferior_thread.
7982 * breakpoint.h (struct inferior): Forward declare.
7983 (bpstat_stop_status): Update.
7984 (remove_breakpoints_pid): Delete.
7985 (remove_breakpoints_inf): New.
7986 * bsd-uthread.c (bsd_uthread_target::wait)
7987 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
7988 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
7989 (maint_btrace_packet_history_cmd)
7990 (maint_btrace_clear_packet_history_cmd): Adjust.
7991 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
7992 inferior_thread.
7993 * cli/cli-interp.c: Include "inferior.h".
7994 * common/refcounted-object.h (struct
7995 refcounted_object_ref_policy): New.
7996 * compile/compile-object-load.c: Include gdbthread.h.
7997 (store_regs): Use inferior_thread.
7998 * corelow.c (core_target::close): Use current_inferior.
7999 (core_target_open): Adjust to use first_thread_of_inferior and use
8000 the current inferior.
8001 * ctf.c (ctf_target::close): Adjust to use current_inferior.
8002 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
8003 <thread>: ... this new field. All references adjusted.
8004 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
8005 Take a thread_info pointer instead of a ptid_t.
8006 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
8007 (dummy_frame_discard, register_dummy_frame_dtor): Take a
8008 thread_info pointer instead of a ptid_t.
8009 * elfread.c: Include "inferior.h".
8010 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
8011 Use inferior_thread.
8012 * eval.c (evaluate_subexp): Likewise.
8013 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
8014 inferior_thread.
8015 * gdb_proc_service.h (struct thread_info): Forward declare.
8016 (struct ps_prochandle) <ptid>: Delete, replaced by ...
8017 <thread>: ... this new field. All references adjusted.
8018 * gdbarch.h, gdbarch.c: Regenerate.
8019 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
8020 'thread' parameter. All implementations and callers adjusted.
8021 * gdbthread.h (thread_info) <set_running>: New method.
8022 (delete_thread, delete_thread_silent): Take a thread_info pointer
8023 instead of a ptid.
8024 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
8025 (first_thread_of_process): Delete, replaced by ...
8026 (first_thread_of_inferior): ... this new function. All callers
8027 adjusted.
8028 (any_live_thread_of_process): Delete, replaced by ...
8029 (any_live_thread_of_inferior): ... this new function. All callers
8030 adjusted.
8031 (switch_to_thread, switch_to_no_thread): Declare.
8032 (is_executing): Delete.
8033 (enable_thread_stack_temporaries): Update comment.
8034 <enable_thread_stack_temporaries>: Take a thread_info pointer
8035 instead of a ptid_t. Incref the thread.
8036 <~enable_thread_stack_temporaries>: Decref the thread.
8037 <m_ptid>: Delete
8038 <m_thr>: New.
8039 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
8040 (get_last_thread_stack_temporary)
8041 (value_in_thread_stack_temporaries, can_access_registers_thread):
8042 Take a thread_info pointer instead of a ptid_t. All callers
8043 adjusted.
8044 * infcall.c (get_call_return_value): Use inferior_thread.
8045 (run_inferior_call): Work with thread pointers instead of ptid_t.
8046 (call_function_by_hand_dummy): Work with thread pointers instead
8047 of ptid_t. Use thread_info_ref.
8048 * infcmd.c (proceed_thread_callback): Access thread's state
8049 directly.
8050 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
8051 access thread's state directly.
8052 (continue_command): Use inferior_thread.
8053 (info_program_command): Use find_thread_ptid and access thread
8054 state directly.
8055 (proceed_after_attach_callback): Use thread state directly.
8056 (notice_new_inferior): Take a thread_info pointer instead of a
8057 ptid_t. All callers adjusted.
8058 (exit_inferior): Take an inferior pointer instead of a pid. All
8059 callers adjusted.
8060 (exit_inferior_silent): New.
8061 (detach_inferior): Delete.
8062 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
8063 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
8064 (detach_inferior_command, kill_inferior_command): Use
8065 find_inferior_id instead of valid_gdb_inferior_id and
8066 gdb_inferior_id_to_pid.
8067 (inferior_command): Use inferior and thread pointers.
8068 * inferior.h (struct thread_info): Forward declare.
8069 (notice_new_inferior): Take a thread_info pointer instead of a
8070 ptid_t. All callers adjusted.
8071 (detach_inferior): Delete declaration.
8072 (exit_inferior, exit_inferior_silent): Take an inferior pointer
8073 instead of a pid. All callers adjusted.
8074 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
8075 (valid_gdb_inferior_id): Delete.
8076 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
8077 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
8078 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
8079 ...
8080 <inf>: ... this new field.
8081 <step_ptid>: Delete, replaced by ...
8082 <step_thread>: ... this new field.
8083 (get_displaced_stepping_state): Take an inferior pointer instead
8084 of a pid. All callers adjusted.
8085 (displaced_step_in_progress_any_inferior): Adjust.
8086 (displaced_step_in_progress_thread): Take a thread pointer instead
8087 of a ptid_t. All callers adjusted.
8088 (displaced_step_in_progress, add_displaced_stepping_state): Take
8089 an inferior pointer instead of a pid. All callers adjusted.
8090 (get_displaced_step_closure_by_addr): Adjust.
8091 (remove_displaced_stepping_state): Take an inferior pointer
8092 instead of a pid. All callers adjusted.
8093 (displaced_step_prepare_throw, displaced_step_prepare)
8094 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
8095 All callers adjusted.
8096 (start_step_over): Adjust.
8097 (infrun_thread_ptid_changed): Remove bit updating ptids in the
8098 displaced step queue.
8099 (do_target_resume): Adjust.
8100 (fetch_inferior_event): Use inferior_thread.
8101 (context_switch, get_inferior_stop_soon): Take an
8102 execution_control_state pointer instead of a ptid_t. All callers
8103 adjusted.
8104 (switch_to_thread_cleanup): Delete.
8105 (stop_all_threads): Use scoped_restore_current_thread.
8106 * inline-frame.c: Include "gdbthread.h".
8107 (inline_state) <inline_state>: Take a thread pointer instead of a
8108 ptid_t. All callers adjusted.
8109 <ptid>: Delete, replaced by ...
8110 <thread>: ... this new field.
8111 (find_inline_frame_state): Take a thread pointer instead of a
8112 ptid_t. All callers adjusted.
8113 (skip_inline_frames, step_into_inline_frame)
8114 (inline_skipped_frames, inline_skipped_symbol): Take a thread
8115 pointer instead of a ptid_t. All callers adjusted.
8116 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
8117 (inline_skipped_frames, inline_skipped_symbol): Likewise.
8118 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
8119 pointers directly.
8120 * linux-nat.c (get_detach_signal): Likewise.
8121 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
8122 (thread_db_notice_clone): Adjust.
8123 (thread_db_find_new_threads_silently)
8124 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
8125 a thread pointer instead of a ptid_t. All callers adjusted.
8126 * mi/mi-cmd-var.c: Include "inferior.h".
8127 (mi_cmd_var_update_iter): Update to use thread pointers.
8128 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
8129 inferior directly.
8130 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
8131 out to ...
8132 (mi_output_running): ... this new function.
8133 (mi_on_resume_1): Adjust to use it.
8134 (mi_user_selected_context_changed): Adjust to use inferior_thread.
8135 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
8136 directly.
8137 (interrupt_thread_callback): : Adjust to use thread and inferior
8138 pointers.
8139 * proc-service.c: Include "gdbthread.h".
8140 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
8141 * progspace-and-thread.c: Include "inferior.h".
8142 * progspace.c: Include "inferior.h".
8143 * python/py-exitedevent.c (create_exited_event_object): Adjust to
8144 hold a reference to an inferior_object.
8145 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
8146 inferior_thread.
8147 * python/py-inferior.c (struct inferior_object): Give the type a
8148 tag name instead of a typedef.
8149 (python_on_normal_stop): No need to check if the current thread is
8150 listed.
8151 (inferior_to_inferior_object): Change return type to
8152 inferior_object. All callers adjusted.
8153 (find_thread_object): Delete, bits factored out to ...
8154 (thread_to_thread_object): ... this new function.
8155 * python/py-infthread.c (create_thread_object): Use
8156 inferior_to_inferior_object.
8157 (thpy_is_stopped): Use thread pointer directly.
8158 (gdbpy_selected_thread): Use inferior_thread.
8159 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
8160 field, replaced with ...
8161 <thread>: ... this new field. All users adjusted.
8162 (btpy_insn_or_gap_new): Drop const.
8163 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
8164 callers adjusted.
8165 * python/py-record.c: Include "gdbthread.h".
8166 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
8167 a ptid_t. All callers adjusted.
8168 (gdbpy_current_recording): Use inferior_thread.
8169 * python/py-record.h (recpy_record_object) <ptid>: Delete
8170 field, replaced with ...
8171 <thread>: ... this new field. All users adjusted.
8172 (recpy_element_object) <ptid>: Delete
8173 field, replaced with ...
8174 <thread>: ... this new field. All users adjusted.
8175 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
8176 a ptid_t. All callers adjusted.
8177 * python/py-threadevent.c: Include "gdbthread.h".
8178 (get_event_thread): Use thread_to_thread_object.
8179 * python/python-internal.h (struct inferior_object): Forward
8180 declare.
8181 (find_thread_object, find_inferior_object): Delete declarations.
8182 (thread_to_thread_object, inferior_to_inferior_object): New
8183 declarations.
8184 * record-btrace.c: Include "inferior.h".
8185 (require_btrace_thread): Use inferior_thread.
8186 (record_btrace_frame_sniffer)
8187 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
8188 (get_thread_current_frame): Use scoped_restore_current_thread and
8189 switch_to_thread.
8190 (get_thread_current_frame): Use thread pointer directly.
8191 (record_btrace_replay_at_breakpoint): Use thread's inferior
8192 pointer directly.
8193 * record-full.c: Include "inferior.h".
8194 * regcache.c: Include "gdbthread.h".
8195 (get_thread_arch_regcache): Use the inferior's address space
8196 directly.
8197 (get_thread_regcache, registers_changed_thread): New.
8198 * regcache.h (get_thread_regcache(thread_info *thread)): New
8199 overload.
8200 (registers_changed_thread): New.
8201 (remote_target) <remote_detach_1>: Swap order of parameters.
8202 (remote_add_thread): <remote_add_thread>: Return the new thread.
8203 (get_remote_thread_info(ptid_t)): New overload.
8204 (remote_target::remote_notice_new_inferior): Use thread pointers
8205 directly.
8206 (remote_target::process_initial_stop_replies): Use
8207 thread_info::set_running.
8208 (remote_target::remote_detach_1, remote_target::detach)
8209 (extended_remote_target::detach): Adjust.
8210 * stack.c (frame_show_address): Use inferior_thread.
8211 * target-debug.h (target_debug_print_thread_info_pp): New.
8212 * target-delegates.c: Regenerate.
8213 * target.c (default_thread_address_space): Delete.
8214 (memory_xfer_partial_1): Use current_inferior.
8215 (target_detach): Use current_inferior.
8216 (target_thread_address_space): Delete.
8217 (generic_mourn_inferior): Use current_inferior.
8218 * target.h (struct target_ops) <thread_address_space>: Delete.
8219 (target_thread_address_space): Delete.
8220 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
8221 pointers directly.
8222 (delete_thread_1, delete_thread, delete_thread_silent): Take a
8223 thread pointer instead of a ptid_t. Adjust all callers.
8224 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
8225 (first_thread_of_process): Delete, replaced by ...
8226 (first_thread_of_inferior): ... this new function. All callers
8227 adjusted.
8228 (any_thread_of_process): Rename to ...
8229 (any_thread_of_inferior): ... this, and take an inferior pointer.
8230 (any_live_thread_of_process): Rename to ...
8231 (any_live_thread_of_inferior): ... this, and take an inferior
8232 pointer.
8233 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
8234 (value_in_thread_stack_temporaries)
8235 (get_last_thread_stack_temporary): Take a thread pointer instead
8236 of a ptid_t. Adjust all callers.
8237 (thread_info::set_running): New.
8238 (validate_registers_access): Use inferior_thread.
8239 (can_access_registers_ptid): Rename to ...
8240 (can_access_registers_thread): ... this, and take a thread
8241 pointer.
8242 (print_thread_info_1): Adjust to compare thread pointers instead
8243 of ptids.
8244 (switch_to_no_thread, switch_to_thread): Make extern.
8245 (scoped_restore_current_thread::~scoped_restore_current_thread):
8246 Use m_thread pointer directly.
8247 (scoped_restore_current_thread::scoped_restore_current_thread):
8248 Use inferior_thread.
8249 (thread_command): Use thread pointer directly.
8250 (thread_num_make_value_helper): Use inferior_thread.
8251 * top.c (execute_command): Use inferior_thread.
8252 * tui/tui-interp.c: Include "inferior.h".
8253 * varobj.c (varobj_create): Use inferior_thread.
8254 (value_of_root_1): Use find_thread_global_id instead of
8255 global_thread_id_to_ptid.
8256
8257 2018-06-21 Alan Hayward <alan.hayward@arm.com>
8258
8259 * regcache.c (readable_regcache::read_part): Avoid memcpy when
8260 possible.
8261 (regcache::write_part): Likewise.
8262 (readable_regcache::cooked_read_part): Update comment.
8263 (readable_regcache::cooked_write_part): Likewise.
8264 * regcache.h: (readable_regcache::read_part): Likewise.
8265 (regcache::write_part): Likewise.
8266
8267 2018-06-21 Richard Bunt <richard.bunt@arm.com>
8268 Dirk Schubert <dirk.schubert@arm.com>
8269
8270 * aarch64-linux-nat.c (post_attach): New.
8271 (aarch64_linux_nat_target::post_attach): Override post_attach to
8272 record the number of hardware debug registers.
8273
8274 2018-06-20 Tom Tromey <tom@tromey.com>
8275
8276 * python/py-param.c (add_setshow_generic): Make parameters const.
8277 (parmpy_init): Update.
8278
8279 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
8280
8281 * regcache.h (regcache_cooked_read_ftype): Rename to...
8282 (register_read_ftype): ...this, change type to function_view.
8283 (class reg_buffer) <save>: Remove src parameter.
8284 (readonly_detached_regcache) <readonly_detached_regcache>: Make
8285 parameter non-const in first overload. Remove src parameter in
8286 second overload.
8287 * regcache.c (do_cooked_read): Remove.
8288 (readonly_detached_regcache::readonly_detached_regcache): Make
8289 parameter non-const, adjust call to other constructor.
8290 (reg_buffer::save): Remove src parameter.
8291 * frame.c (do_frame_register_read): Remove.
8292 (frame_save_as_regcache): Use lambda function.
8293 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
8294 parameter to ppu2spu_data *.
8295 (ppu2spu_sniffer): Use lambda function.
8296
8297 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
8298
8299 * record-full.c (record_full_target::insert_breakpoint): Remove
8300 "struct" keyword, add const.
8301
8302 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
8303
8304 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
8305 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
8306 * configure.ac: Remove AC_PREREQ, add missing quoting.
8307 * gnulib/configure.ac: Modernize usage of
8308 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
8309 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
8310 (AUTOMAKE_VERSION): Bump to 1.15.1.
8311 * configure: Re-generate.
8312 * config.in: Re-generate.
8313 * aclocal.m4: Re-generate.
8314 * gnulib/aclocal.m4: Re-generate.
8315 * gnulib/config.in: Re-generate.
8316 * gnulib/configure: Re-generate.
8317 * gnulib/import/Makefile.in: Re-generate.
8318
8319 2018-06-19 Pedro Alves <palves@redhat.com>
8320
8321 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
8322 (lookup_minimal_symbol_by_pc_section): ... here with
8323 gdb_assert_not_reached added.
8324
8325 2018-06-19 Pedro Alves <palves@redhat.com>
8326
8327 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
8328 parameter with a block parameter. Compare location's block symbol
8329 with the frame's block instead of addresses.
8330 (skip_inline_frames): Pass the current block instead of the
8331 frame's address. Break out as soon as we determine the frame
8332 should not be skipped.
8333
8334 2018-06-18 Tom Tromey <tom@tromey.com>
8335
8336 * solib-aix.c (solib_aix_get_section_offsets): Return
8337 unique_xmalloc_ptr.
8338 (solib_aix_solib_create_inferior_hook): Update.
8339
8340 2018-06-18 Tom Tromey <tom@tromey.com>
8341
8342 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
8343
8344 2018-06-18 Tom Tromey <tom@tromey.com>
8345
8346 * solib-frv.c (frv_relocate_main_executable): Use
8347 unique_xmalloc_ptr.
8348 * solib-dsbt.c (dsbt_relocate_main_executable): Use
8349 unique_xmalloc_ptr.
8350
8351 2018-06-18 Tom Tromey <tom@tromey.com>
8352
8353 * objfiles.h (inhibit_section_map_updates): Update.
8354 (resume_section_map_updates, resume_section_map_updates_cleanup):
8355 Remove.
8356 * solib-svr4.c (svr4_handle_solib_event): Update.
8357 * objfiles.c (inhibit_section_map_updates): Return
8358 scoped_restore_tmpl<int>.
8359 (resume_section_map_updates, resume_section_map_updates_cleanup):
8360 Remove.
8361
8362 2018-06-18 Tom Tromey <tom@tromey.com>
8363
8364 * valprint.h (read_string): Update.
8365 * valprint.c (read_string): Change type of "buffer".
8366 (val_print_string): Update.
8367 * python/py-value.c (valpy_string): Update.
8368 * language.h (struct language_defn) <la_get_string>: Change
8369 type of "buffer".
8370 (default_get_string, c_get_string): Update.
8371 * language.c (default_get_string): Change type of "buffer".
8372 * guile/scm-value.c (gdbscm_value_to_string): Update.
8373 * c-lang.c (c_get_string): Change type of "buffer".
8374
8375 2018-06-18 Tom Tromey <tom@tromey.com>
8376
8377 * ser-mingw.c (struct pipe_state_destroyer): New.
8378 (pipe_state_up): New typedef.
8379 (cleanup_pipe_state): Remove.
8380 (pipe_windows_open): Use pipe_state_up. Don't release argv.
8381
8382 2018-06-18 Tom Tromey <tom@tromey.com>
8383
8384 * rust-lang.h (rust_yyerror): Don't declare.
8385 * rust-lang.c (rust_language_defn): Update.
8386 * rust-exp.y (yyerror): Now static.
8387 * parse.c (parse_exp_in_context_1): Update.
8388 * p-lang.h (p_yyerror): Don't declare.
8389 * p-lang.c (p_language_defn): Update.
8390 * p-exp.y (yyerror): Now static.
8391 * opencl-lang.c (opencl_language_defn): Update.
8392 * objc-lang.c (objc_language_defn): Update.
8393 * m2-lang.h (m2_yyerror): Don't declare.
8394 * m2-lang.c (m2_language_defn): Update.
8395 * m2-exp.y (yyerror): Now static.
8396 * language.h (struct language_defn) <la_error>: Remove.
8397 * language.c (unk_lang_error): Remove.
8398 (unknown_language_defn, auto_language_defn): Remove.
8399 * go-lang.h (go_yyerror): Don't declare.
8400 * go-lang.c (go_language_defn): Update.
8401 * go-exp.y (yyerror): Now static.
8402 * f-lang.h (f_yyerror): Don't declare.
8403 * f-lang.c (f_language_defn): Update.
8404 * f-exp.y (yyerror): Now static.
8405 * d-lang.h (d_yyerror): Don't declare.
8406 * d-lang.c (d_language_defn): Update.
8407 * d-exp.y (yyerror): Now static.
8408 * c-lang.h (c_yyerror): Don't declare.
8409 * c-lang.c (c_language_defn, cplus_language_defn)
8410 (asm_language_defn, minimal_language_defn): Update.
8411 * c-exp.y (yyerror): Now static.
8412 * ada-lang.h (ada_yyerror): Don't declare.
8413 * ada-lang.c (ada_language_defn): Update.
8414 * ada-exp.y (yyerror): Now static.
8415
8416 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8417
8418 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
8419 (store_sveregs_to_thread): Likewise.
8420 (aarch64_linux_fetch_inferior_registers): Check for SVE.
8421 (aarch64_linux_store_inferior_registers): Likewise.
8422 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
8423 function.
8424 (aarch64_sve_regs_copy_to_regcache): Likewise.
8425 (aarch64_sve_regs_copy_from_regcache): Likewise.
8426 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
8427 declaration.
8428 (aarch64_sve_regs_copy_to_regcache): Likewise.
8429 (aarch64_sve_regs_copy_from_regcache): Likewise.
8430 (sve_context): Structure from Linux headers.
8431 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
8432 (SVE_SIG_ZREG_SIZE): Likewise.
8433 (SVE_SIG_PREG_SIZE): Likewise.
8434 (SVE_SIG_FFR_SIZE): Likewise.
8435 (SVE_SIG_REGS_OFFSET): Likewise.
8436 (SVE_SIG_ZREGS_OFFSET): Likewise.
8437 (SVE_SIG_ZREG_OFFSET): Likewise.
8438 (SVE_SIG_ZREGS_SIZE): Likewise.
8439 (SVE_SIG_PREGS_OFFSET): Likewise.
8440 (SVE_SIG_PREG_OFFSET): Likewise.
8441 (SVE_SIG_PREGS_SIZE): Likewise.
8442 (SVE_SIG_FFR_OFFSET): Likewise.
8443 (SVE_SIG_REGS_SIZE): Likewise.
8444 (SVE_SIG_CONTEXT_SIZE): Likewise.
8445 (SVE_PT_REGS_MASK): Likewise.
8446 (SVE_PT_REGS_FPSIMD): Likewise.
8447 (SVE_PT_REGS_SVE): Likewise.
8448 (SVE_PT_VL_INHERIT): Likewise.
8449 (SVE_PT_VL_ONEXEC): Likewise.
8450 (SVE_PT_REGS_OFFSET): Likewise.
8451 (SVE_PT_FPSIMD_OFFSET): Likewise.
8452 (SVE_PT_FPSIMD_SIZE): Likewise.
8453 (SVE_PT_SVE_ZREG_SIZE): Likewise.
8454 (SVE_PT_SVE_PREG_SIZE): Likewise.
8455 (SVE_PT_SVE_FFR_SIZE): Likewise.
8456 (SVE_PT_SVE_FPSR_SIZE): Likewise.
8457 (SVE_PT_SVE_FPCR_SIZE): Likewise.
8458 (__SVE_SIG_TO_PT): Likewise.
8459 (SVE_PT_SVE_OFFSET): Likewise.
8460 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
8461 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
8462 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
8463 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
8464 (SVE_PT_SVE_PREG_OFFSET): Likewise.
8465 (SVE_PT_SVE_PREGS_SIZE): Likewise.
8466 (SVE_PT_SVE_FFR_OFFSET): Likewise.
8467 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
8468 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
8469 (SVE_PT_SVE_SIZE): Likewise.
8470 (SVE_PT_SIZE): Likewise.
8471 (HAS_SVE_STATE): New define.
8472
8473 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8474
8475 * nat/aarch64-sve-linux-sigcontext.h: New file.
8476 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
8477 new files.
8478 (SVE_VQ_MIN): Likewise.
8479 (SVE_VQ_MAX): Likewise.
8480 (SVE_VL_MIN): Likewise.
8481 (SVE_VL_MAX): Likewise.
8482 (SVE_NUM_ZREGS): Likewise.
8483 (SVE_NUM_PREGS): Likewise.
8484 (sve_vl_valid): Likewise.
8485 (struct user_sve_header): Likewise.
8486
8487 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
8488 Richard Bunt <Richard.Bunt@arm.com>
8489
8490 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
8491 was requested by GDB.
8492
8493 2018-06-15 Tom de Vries <tdevries@suse.de>
8494
8495 * MAINTAINERS (Write After Approval): Add Tom de Vries.
8496
8497 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
8498
8499 * gnulib/update-gnulib.sh: Print expected versions of
8500 autoconf/aclocal.
8501
8502 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
8503
8504 * arch-utils.c (default_type_align): Use type_length_units.
8505 * gdbtypes.c (type_align): Use type_length_units.
8506
8507 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8508
8509 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
8510 of 'define' command.
8511
8512 2018-06-14 Tom de Vries <tdevries@suse.de>
8513
8514 PR cli/22573
8515 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
8516 get_no_prettyformat_print_options.
8517
8518 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
8519
8520 * sparc-nat.h: Include target.h.
8521 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
8522 <fetch_registers>: Remove this argument in function call.
8523 <store_registers>: Remove this argument in function call, remove
8524 extra semicolon.
8525 <low_forget_process>: Call sparc64_forget_process instead of
8526 sparc_forget_process.
8527
8528 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8529
8530 * procfs.c (_initialize_procfs): Use add_inf_child_target.
8531 (procfs_target::make_corefile_notes): Adjust to new
8532 target_read_alloc return type.
8533
8534 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8535 Stephen Roberts <stephen.roberts@arm.com>
8536
8537 PR gdb/22882
8538 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
8539 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
8540 Move should_notify_stop local into more inner scope.
8541
8542 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8543 Stephen Roberts <stephen.roberts@arm.com>
8544
8545 PR gdb/22882
8546 * infrun.c (resume_1): Add call to mark_async_event_handler.
8547
8548 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8549
8550 * infrun.c (do_target_wait): Change old version of $pc printed.
8551
8552 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
8553
8554 * dwarf2read.c (read_index_from_section): Rename to...
8555 (read_gdb_index_from_section): ... this, update all callers.
8556 (dwarf2_read_index): Rename to...
8557 (dwarf2_read_gdb_index): ... this, update all callers.
8558
8559 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
8560
8561 * hppa-linux-nat.c
8562 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
8563 hppa_linux_nat_target::fetch_registers.
8564
8565 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8566
8567 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
8568 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
8569 (AARCH64_DWARF_SVE_FFR): Likewise.
8570 (AARCH64_DWARF_SVE_P0): Likewise.
8571 (AARCH64_DWARF_SVE_Z0): Likewise.
8572
8573 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8574
8575 * common/common-regcache.h (raw_compare): New function.
8576 * regcache.c (regcache::raw_compare): Likewise.
8577 * regcache.h (regcache::raw_compare): New declaration.
8578
8579 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8580
8581 * common/common-regcache.h (reg_buffer_common): New structure.
8582 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
8583 (reg_buffer::raw_supply): Likewise.
8584 (reg_buffer::raw_supply_integer): Likewise.
8585 (reg_buffer::raw_supply_zeroed): Likewise.
8586 (reg_buffer::raw_collect): Likewise.
8587 (reg_buffer::raw_collect_integer): Likewise.
8588 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
8589 (reg_buffer::raw_supply): Likewise.
8590 (reg_buffer::raw_supply_integer): Likewise.
8591 (reg_buffer::raw_supply_zeroed): Likewise.
8592 (reg_buffer::raw_collect): Likewise.
8593 (reg_buffer::raw_collect_integer): Likewise.
8594
8595 2018-06-10 Tom Tromey <tom@tromey.com>
8596
8597 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
8598 (class remote_state) <stop_reply_queue>: Now std::vector.
8599 (remote_state::~remote_state)
8600 (remote_target::stop_reply_queue_length): Update.
8601 (struct queue_iter_param, remove_child_of_pending_fork)
8602 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
8603 (check_pending_event_prevents_wildcard_vcont_callback)
8604 (remove_stop_reply_for_inferior)
8605 (remove_stop_reply_of_remote_state)
8606 (remote_notif_remove_once_on_match)
8607 (stop_reply_match_ptid_and_ws)
8608 (remote_kill_child_of_pending_fork): Remove.
8609 (remote_target::remove_new_fork_children)
8610 (remote_target::check_pending_events_prevent_wildcard_vcont)
8611 (remote_target::discard_pending_stop_replies)
8612 (remote_target::discard_pending_stop_replies_in_queue)
8613 (remote_target::remote_notif_remove_queued_reply)
8614 (remote_target::queued_stop_reply)
8615 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
8616 (remote_target::wait, remote_target::kill_new_fork_children)
8617 (remote_target::async): Update.
8618
8619 2018-06-10 Tom Tromey <tom@tromey.com>
8620
8621 * record-full.c (record_full_arch_list_cleanups): Remove.
8622 (record_full_message): Use try/catch.
8623 (record_full_wait_cleanups): Remove.
8624 (record_full_wait_1): Use try/catch.
8625 (record_full_restore): Likewise.
8626
8627 2018-06-10 Tom Tromey <tom@tromey.com>
8628
8629 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
8630 declare VEC. Add constructor.
8631 <in_target_beneath>: Now bool.
8632 (record_full_breakpoints): Now a std::vector, static.
8633 (record_full_sync_record_breakpoints)
8634 (record_full_init_record_breakpoints)
8635 (record_full_target::insert_breakpoint)
8636 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
8637
8638 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8639
8640 * dwarf2read.c (process_cu_includes): Remove struct keyword.
8641 * serial.c (serial_interface_lookup): Remove struct keyword.
8642
8643 2018-06-10 Tom Tromey <tom@tromey.com>
8644
8645 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
8646 method.
8647 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
8648 a method.
8649 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
8650 method.
8651 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
8652 "beneath" as a method.
8653 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
8654 Use "beneath" as a method.
8655
8656 2018-06-10 Tom Tromey <tom@tromey.com>
8657
8658 * tracefile.c (struct trace_file_writer_deleter): New.
8659 <operator()>: Rename from trace_file_writer_xfree.
8660 (trace_file_writer_up): New typedef.
8661 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
8662
8663 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8664
8665 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
8666 <m_registers, m_register_status>: Change type to
8667 std::unique_ptr.
8668 * regcache.c (reg_buffer::reg_buffer): Use new instead of
8669 XCNEWVEC.
8670
8671 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8672
8673 * common/common-regcache.h (enum register_status): Add
8674 underlying type "signed char".
8675 * regcache.h (reg_buffer) <m_register_status>: Change type to
8676 register_status *.
8677 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
8678 register_status instead of signed char.
8679 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
8680 (reg_buffer::get_register_status): Remove cast.
8681 (readable_regcache::raw_read): Remove cast.
8682 (readable_regcache::cooked_read): Remove cast.
8683
8684 2018-06-09 Tom Tromey <tom@tromey.com>
8685
8686 * source.c (reverse_search_command, forward_search_command): Use
8687 scoped_fd.
8688
8689 2018-06-09 Tom Tromey <tom@tromey.com>
8690
8691 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
8692 (serial_ops_list): Now static, std::vector.
8693 (serial_interface_lookup, serial_add_interface): Update.
8694
8695 2018-06-09 Tom Tromey <tom@tromey.com>
8696
8697 * dwarf2read.c (process_cu_includes): Update.
8698 (process_full_comp_unit): Update.
8699 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
8700 std::vector.
8701
8702 2018-06-08 Paul Koning <paul_koning@dell.com>
8703
8704 PR gdb/23252
8705
8706 * python/python.c (do_start_initialization):
8707 Avoid call to internal Python API.
8708 (init__gdb_module): New function.
8709
8710 2018-06-08 Gary Benson <gbenson@redhat.com>
8711
8712 * linux-thread-db.c (valprint.h): New include.
8713 (struct check_thread_db_info): New structure.
8714 (check_thread_db_on_load, tdb_testinfo): New static globals.
8715 (check_thread_db, check_thread_db_callback): New functions.
8716 (try_thread_db_load_1): Run integrity checks if requested.
8717 (maintenance_check_libthread_db): New function.
8718 (_initialize_thread_db): Register "maint check libthread-db"
8719 and "maint set/show check-libthread-db".
8720 * NEWS: Mention the above new commands.
8721
8722 2018-06-08 Tom Tromey <tom@tromey.com>
8723
8724 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
8725 now a method.
8726
8727 2018-06-08 Tom Tromey <tom@tromey.com>
8728
8729 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
8730
8731 2018-06-08 Tom Tromey <tom@tromey.com>
8732
8733 * common/btrace-common.h (struct btrace_data): Add constructor,
8734 destructor, move assignment operator.
8735 <empty, clear, fini>: New methods.
8736 <format>: Initialize.
8737 (btrace_data_init, btrace_data_fini, btrace_data_clear)
8738 (btrace_data_empty): Don't declare.
8739 * common/btrace-common.c (btrace_data_init): Remove.
8740 (btrace_data::fini): Rename from btrace_data_fini.
8741 (btrace_data::empty): Rename from btrace_data_empty.
8742 (btrace_data::clear): Rename from btrace_data_clear. Return
8743 bool.
8744 * btrace.h (make_cleanup_btrace_data): Don't declare.
8745 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
8746 (parse_xml_btrace): Update.
8747 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
8748 (maint_btrace_clear_packet_history_cmd): Update.
8749
8750 2018-06-07 Pedro Alves <palves@redhat.com>
8751
8752 * target.h (target_ops) <beneath>: Now a method. All references
8753 updated.
8754 (class target_stack): New.
8755 * target.c (g_target_stack): New.
8756 (g_current_top_target): Delete.
8757 (current_top_target): Get the top target out of g_target_stack.
8758 (target_stack::push, target_stack::unpush): New.
8759 (push_target, unpush_target): Reimplement.
8760 (target_is_pushed): Reimplement in terms of g_target_stack.
8761 (target_ops::beneath, target_stack::find_beneath): New.
8762
8763 2018-06-07 Pedro Alves <palves@redhat.com>
8764
8765 * target.h (find_target_beneath): Delete declaration.
8766 * target.c (find_target_beneath): Delete definition.
8767 * aix-thread.c: All callers of find_target_beneath adjusted to
8768 call target_ops::beneath instead.
8769 * bsd-uthread.c: Likewise.
8770 * linux-thread-db.c: Likewise.
8771 * ravenscar-thread.c: Likewise.
8772 * sol-thread.c: Likewise.
8773 * spu-multiarch.c: Likewise.
8774
8775 2018-06-07 Pedro Alves <palves@redhat.com>
8776
8777 * target.h (target_ops) <beneath>: Now a method. All references
8778 updated.
8779 (target_ops) <m_beneath>: New.
8780 * target.c (target_ops::beneath): New.
8781 * corelow.c: Adjust all references to target_ops::beneath.
8782 * linux-thread-db.c: Likewise.
8783 * make-target-delegates: Likewise.
8784 * record-btrace.c: Likewise.
8785 * record-full.c: Likewise.
8786 * remote.c: Likewise.
8787 * target.c: Likewise.
8788 * target-delegates.c: Regenerate.
8789
8790 2018-06-07 Pedro Alves <palves@redhat.com>
8791
8792 * target.h (target_stack): Delete.
8793 (current_top_target): Declare function.
8794 * target.c (target_stack): Delete.
8795 (g_current_top_target): New.
8796 (current_top_target): New function.
8797 * auxv.c: Use current_top_target instead of target_stack
8798 throughout.
8799 * avr-tdep.c: Likewise.
8800 * breakpoint.c: Likewise.
8801 * corefile.c: Likewise.
8802 * elfread.c: Likewise.
8803 * eval.c: Likewise.
8804 * exceptions.c: Likewise.
8805 * frame.c: Likewise.
8806 * gdbarch-selftests.c: Likewise.
8807 * gnu-v3-abi.c: Likewise.
8808 * ia64-tdep.c: Likewise.
8809 * ia64-vms-tdep.c: Likewise.
8810 * infcall.c: Likewise.
8811 * infcmd.c: Likewise.
8812 * infrun.c: Likewise.
8813 * linespec.c: Likewise.
8814 * linux-tdep.c: Likewise.
8815 * minsyms.c: Likewise.
8816 * ppc-linux-nat.c: Likewise.
8817 * ppc-linux-tdep.c: Likewise.
8818 * procfs.c: Likewise.
8819 * regcache.c: Likewise.
8820 * remote.c: Likewise.
8821 * rs6000-tdep.c: Likewise.
8822 * s390-linux-nat.c: Likewise.
8823 * s390-tdep.c: Likewise.
8824 * solib-aix.c: Likewise.
8825 * solib-darwin.c: Likewise.
8826 * solib-dsbt.c: Likewise.
8827 * solib-spu.c: Likewise.
8828 * solib-svr4.c: Likewise.
8829 * solib-target.c: Likewise.
8830 * sparc-tdep.c: Likewise.
8831 * sparc64-tdep.c: Likewise.
8832 * spu-tdep.c: Likewise.
8833 * symfile.c: Likewise.
8834 * symtab.c: Likewise.
8835 * target-descriptions.c: Likewise.
8836 * target-memory.c: Likewise.
8837 * target.c: Likewise.
8838 * target.h: Likewise.
8839 * tracefile-tfile.c: Likewise.
8840 * tracepoint.c: Likewise.
8841 * valops.c: Likewise.
8842 * valprint.c: Likewise.
8843 * value.c: Likewise.
8844 * windows-tdep.c: Likewise.
8845 * mi/mi-main.c: Likewise.
8846
8847 2018-06-07 Tom Tromey <tom@tromey.com>
8848
8849 * valprint.h (build_address_symbolic): Declare.
8850 * printcmd.c (print_address_symbolic): Update.
8851 (build_address_symbolic): Change "name" and "filename" to
8852 std::string.
8853 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
8854 Update.
8855 * defs.h (build_address_symbolic): Remove declaration.
8856
8857 2018-06-07 Alan Hayward <alan.hayward@arm.com>
8858
8859 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
8860 (aarch64_vnv_type): Add function.
8861 (aarch64_pseudo_register_name): Add V regs for SVE.
8862 (aarch64_pseudo_register_type): Likewise.
8863 (aarch64_pseudo_register_reggroup_p): Likewise.
8864 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
8865 (aarch64_pseudo_read_value): Add V regs for SVE.
8866 (aarch64_pseudo_write_2): Use V0 offset for SVE
8867 (aarch64_pseudo_write): Add V regs for SVE.
8868 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
8869
8870 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
8871
8872 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
8873 (sve_vl_from_vq): Likewise.
8874
8875 2018-06-05 Tom Tromey <tom@tromey.com>
8876
8877 * cli/cli-cmds.c (show_version): Update.
8878 * top.c (print_gdb_version): Add "interactive" parameter.
8879 Update.
8880 * main.c (captured_main_1): Update.
8881 * top.h (print_gdb_version): Add "interactive" parameter and a
8882 comment.
8883
8884 2018-06-05 David Malcolm <dmalcolm@redhat.com>
8885
8886 * common/enum-flags.h: Add trailing semicolon to example in
8887 comment.
8888
8889 2018-06-05 Tom Tromey <tom@tromey.com>
8890
8891 PR cli/12326:
8892 * NEWS: Add entry about pager.
8893 * utils.c (pagination_disabled_for_command): New global.
8894 (prompt_for_continue): Allow "c" response to prompt.
8895 (reinitialize_more_filter): Clear
8896 pagination_disabled_for_command.
8897 (fputs_maybe_filtered): Check pagination_disabled_for_command.
8898
8899 2018-06-04 Tom Tromey <tom@tromey.com>
8900
8901 * ada-lang.h (ada_lookup_symbol_list): Update.
8902 * ada-lang.c (resolve_subexp): Update.
8903 (symbols_are_identical_enums): Change type of syms. Remove nsyms
8904 parameter.
8905 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
8906 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
8907 results parameter to std::vector.
8908 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
8909 Update.
8910 * ada-exp.y (block_lookup): Update.
8911 (select_possible_type_sym): Change type of syms. Remove nsyms
8912 parameter.
8913 (write_var_or_type, write_name_assoc): Update.
8914
8915 2018-06-04 Joel Brobecker <brobecker@adacore.com>
8916
8917 * windows-nat.c (windows_nat_target::xfer_partial): Return
8918 TARGET_XFER_E_IO if we need to delegate to the target beneath
8919 but BENEATH is NULL.
8920
8921 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
8922
8923 * Makefile.in (config.status): Add configure.nat as a
8924 dependency.
8925
8926 2018-06-04 Tom Tromey <tom@tromey.com>
8927
8928 * cp-name-parser.y (cpname_state): Add method declarations.
8929 (HANDLE_QUAL): Update.
8930 (cpname_state::d_grab, cpname_state::fill_comp)
8931 (cpname_state::make_operator, cpname_state::make_dtor)
8932 (cpname_state::make_builtin_type, cpname_state::make_name)
8933 (cpname_state::d_qualify, cpname_state::d_int_type)
8934 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
8935 (%union): Move earlier.
8936
8937 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8938
8939 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
8940
8941 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8942
8943 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
8944 (aarch64_pseudo_write_1): Likewise.
8945 (aarch64_pseudo_read_value): Use helper.
8946 (aarch64_pseudo_write): Likewise.
8947
8948 2018-06-04 Pedro Alves <palves@redhat.com>
8949
8950 * darwin-nat.c (darwin_ops): Delete.
8951 (darwin_attach_pid): Use get_native_target.
8952
8953 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8954
8955 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
8956 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
8957
8958 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8959
8960 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
8961 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
8962 (aarch64_gdbarch_init): Check for SVE.
8963 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
8964
8965 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8966
8967 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
8968 * aarch64-tdep.h (aarch64_read_description): Likewise.
8969 * arch/aarch64.c (aarch64_create_target_description): Likewise.
8970 * arch/aarch64.h (aarch64_create_target_description): Likewise.
8971 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
8972 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
8973 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
8974
8975 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
8976
8977 * value.c (value_fetch_lazy_bitfield): New.
8978 (value_fetch_lazy_memory): New.
8979 (value_fetch_lazy_register): New.
8980 (value_fetch_lazy): Factor out to smaller functions.
8981
8982 2018-06-01 Tom Tromey <tom@tromey.com>
8983
8984 * cp-name-parser.y (backslashable, represented): Now const.
8985
8986 2018-06-01 Tom Tromey <tom@tromey.com>
8987
8988 * cp-name-parser.y: Include parser-defs.h.
8989 (parser_fprintf): Remove declaration.
8990
8991 2018-06-01 Tom Tromey <tom@tromey.com>
8992
8993 * cp-name-parser.y: Use %pure-parser, %lex-param, and
8994 %parse-param.
8995 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
8996 (global_result): Remove globals.
8997 (struct cpname_state): New.
8998 (yyparse): Don't declare.
8999 (yylex, yyerror): Move declarations after %union.
9000 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
9001 (make_name): Add state parameter.
9002 Update all callers.
9003 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
9004 parameter.
9005 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
9006 Update.
9007 (yylex): Add lvalp, state parameters.
9008 (yyerror): Add state parameter.
9009 (cp_demangled_name_to_comp): Update.
9010
9011 2018-06-01 Tom Tromey <tom@tromey.com>
9012
9013 * cp-name-parser.y (parser_fprintf): Declare.
9014 (GDB_YY_REMAP_PREFIX): Define.
9015 Include yy-remap.h. Don't redefine yy* identifiers.
9016
9017 2018-06-01 Tom Tromey <tom@tromey.com>
9018
9019 * python/py-type.c (typy_legacy_template_argument): Update.
9020 * cp-support.h (cp_demangled_name_to_comp): Update.
9021 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
9022 parameter to be a "std::string *".
9023 (main): Update.
9024
9025 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
9026
9027 * ada-lex.l: Include "diagnostics.h" instead of
9028 "common/diagnostics.h".
9029 * unittests/environ-selftests.c: Likewise.
9030 * common/diagnostics.h: Moved to ../include.
9031
9032 2018-06-01 Joel Brobecker <brobecker@adacore.com>
9033
9034 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
9035 to language_mode_manual while calling breakpoint_re_set_one.
9036
9037 2018-06-01 Tom Tromey <tom@tromey.com>
9038
9039 * valops.c (value_cast_structs, destructor_name_p): Update.
9040 * symtab.c (gdb_mangle_name): Update.
9041 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
9042 Update.
9043 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
9044 (pascal_object_print_value_fields, pascal_object_print_value):
9045 Update.
9046 * p-typeprint.c (pascal_type_print_derivation_info): Update.
9047 * linespec.c (find_methods): Update.
9048 * gdbtypes.h (type_name_no_tag): Remove.
9049 (type_name_or_error): Rename from type_name_no_tag_or_error.
9050 * gdbtypes.c (type_name_no_tag): Remove.
9051 (type_name_or_error): Rename from type_name_no_tag_or_error.
9052 (lookup_struct_elt_type, check_typedef): Update.
9053 * expprint.c (print_subexp_standard): Update.
9054 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
9055 * d-namespace.c (d_lookup_nested_symbol): Update.
9056 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
9057 (cp_print_class_member): Update.
9058 * cp-namespace.c (cp_lookup_nested_symbol): Update.
9059 * completer.c (add_struct_fields): Update.
9060 * c-typeprint.c (cp_type_print_derivation_info)
9061 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
9062 Update.
9063 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
9064 (ada_prefer_type, ada_is_exception_sym): Update.
9065
9066 2018-06-01 Tom Tromey <tom@tromey.com>
9067
9068 * valops.c (enum_constant_from_type, value_namespace_elt)
9069 (value_maybe_namespace_elt): Update.
9070 * valarith.c (find_size_for_pointer_math): Update.
9071 * target-descriptions.c (make_gdb_type): Update.
9072 * symmisc.c (print_symbol): Update.
9073 * stabsread.c (define_symbol, read_type)
9074 (complain_about_struct_wipeout, add_undefined_type)
9075 (cleanup_undefined_types_1): Update.
9076 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
9077 (rust_range_type_p, val_print_struct, rust_print_struct_def)
9078 (rust_internal_print_type, rust_composite_type)
9079 (rust_evaluate_funcall, rust_evaluate_subexp)
9080 (rust_inclusive_range_type_p): Update.
9081 * python/py-type.c (typy_get_tag): Update.
9082 * p-typeprint.c (pascal_type_print_base): Update.
9083 * mdebugread.c (parse_symbol, parse_type): Update.
9084 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
9085 Update.
9086 * guile/scm-type.c (gdbscm_type_tag): Update.
9087 * go-lang.c (sixg_string_p): Update.
9088 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
9089 Update.
9090 * gdbtypes.h (struct main_type) <tag_name>: Remove.
9091 (TYPE_TAG_NAME): Remove.
9092 * gdbtypes.c (type_name_no_tag): Simplify.
9093 (check_typedef, check_types_equal, recursive_dump_type)
9094 (copy_type_recursive, arch_composite_type): Update.
9095 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
9096 in summary mode when needed.
9097 * eval.c (evaluate_funcall): Update.
9098 * dwarf2read.c (fixup_go_packaging, read_structure_type)
9099 (process_structure_scope, read_enumeration_type)
9100 (read_namespace_type, read_module_type, determine_prefix): Update.
9101 * cp-support.c (inspect_type): Update.
9102 * coffread.c (process_coff_symbol, decode_base_type): Update.
9103 * c-varobj.c (c_is_path_expr_parent): Update.
9104 * c-typeprint.c (c_type_print_base_struct_union): Update.
9105 (c_type_print_base_1): Update. Print struct/class/union/enum in
9106 summary when using C language.
9107 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
9108 (gen_maybe_namespace_elt): Update.
9109 * ada-lang.c (ada_type_name): Simplify.
9110 (empty_record, ada_template_to_fixed_record_type_1)
9111 (template_to_static_fixed_type)
9112 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
9113
9114 2018-06-01 Tom Tromey <tom@tromey.com>
9115
9116 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
9117 c_print_type.
9118 * c-typeprint.c (c_print_type_1): Add "language" parameter.
9119 (c_print_type): Update.
9120 (c_print_type): New overload.
9121 (c_type_print_varspec_prefix, c_type_print_args)
9122 (c_type_print_varspec_suffix, c_print_type_no_offsets)
9123 (c_type_print_base_struct_union, c_type_print_base_1)
9124 (cp_type_print_method_args): Add "language" parameter.
9125 (c_type_print_base): Update.
9126 * c-lang.h (c_print_type): Add new overload.
9127
9128 2018-06-01 Tom Tromey <tom@tromey.com>
9129
9130 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
9131 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
9132
9133 2018-06-01 Alan Hayward <alan.hayward@arm.com>
9134
9135 * aarch64-tdep.c (aarch64_sve_register_names): New const
9136 var.
9137 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
9138 (AARCH64_SVE_Z_REGS_NUM): New define.
9139 (AARCH64_SVE_P_REGS_NUM): Likewise.
9140 (AARCH64_SVE_NUM_REGS): Likewise.
9141
9142 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
9143
9144 * nat/linux-ptrace.h [__alpha__]
9145 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
9146 definitions.
9147
9148 2018-05-31 Maciej W. Rozycki <macro@mips.com>
9149
9150 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
9151 the endianness selected.
9152 * NEWS: Document `set endian auto' mode operation update.
9153
9154 2018-05-31 Alan Hayward <alan.hayward@arm.com>
9155
9156 * Makefile.in: Add new header.
9157 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
9158 (sve_vl_from_vg): Likewise.
9159 (sve_vq_from_vl): Likewise.
9160 (sve_vl_from_vq): Likewise.
9161 (sve_vq_from_vg): Likewise.
9162 (sve_vg_from_vq): Likewise.
9163 * configure.nat: Add new c file.
9164 * nat/aarch64-sve-linux-ptrace.c: New file.
9165 * nat/aarch64-sve-linux-ptrace.h: New file.
9166
9167 2018-05-31 Alan Hayward <alan.hayward@arm.com>
9168
9169 * aarch64-linux-nat.c (aarch64_linux_read_description):
9170 Add parmeter zero.
9171 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
9172 Likewise.
9173 * aarch64-tdep.c (tdesc_aarch64_list): Add.
9174 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
9175 (aarch64_gdbarch_init): Add parmeter zero.
9176 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
9177 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
9178 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
9179 parmeter.
9180 * doc/gdb.texinfo: Describe SVE feature
9181 * features/aarch64-sve.c: New file.
9182
9183 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
9184
9185 PR gdb/23210
9186 * gdbarch.sh (significant_addr_bit): Default to zero when
9187 not set by target architecture.
9188 * gdbarch.c: Re-generated.
9189 * utils.c (address_significant): Update.
9190
9191 2018-05-30 Joel Brobecker <brobecker@adacore.com>
9192
9193 * stack.c (func_command): Remove trailing newline in call to error.
9194
9195 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9196
9197 * regcache.h (regcache_raw_collect): Remove, update callers to
9198 use regcache::raw_collect.
9199 * regcache.c (regcache_raw_collect): Remove.
9200
9201 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9202
9203 * regcache.h (regcache_raw_supply): Remove, update callers to
9204 use detached_regcache::raw_supply.
9205 * regcache.c (regcache_raw_supply): Remove.
9206
9207 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9208
9209 * regcache.h (regcache_cooked_write_part): Remove, update
9210 callers to use regcache::cooked_write_part.
9211 * regcache.c (regcache_cooked_write_part): Remove.
9212
9213 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9214
9215 * regcache.h (regcache_cooked_read_part): Remove, update callers
9216 to use readable_regcache::cooked_read_part.
9217 * regcache.c (regcache_cooked_read_part): Remove.
9218
9219 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9220
9221 * regcache.h (regcache_cooked_read_value): Remove, update
9222 callers to use readable_regcache::cooked_read_value.
9223 * regcache.c (regcache_cooked_read_value): Remove.
9224
9225 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9226
9227 * regcache.h (regcache_cooked_write): Remove, update callers to
9228 use regcache::cooked_write.
9229 * regcache.c (regcache_cooked_write): Remove.
9230
9231 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9232
9233 * regcache.h (regcache_invalidate): Remove, update callers to
9234 use detached_regcache::invalidate instead.
9235 * regcache.c (regcache_invalidate): Remove.
9236
9237 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9238
9239 * regcache.h (regcache_raw_write_part): Remove, update callers
9240 to use regcache::raw_write_part instead.
9241 * regcache.c (regcache_raw_write_part): Remove.
9242
9243 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9244
9245 * regcache.h (regcache_raw_read_part): Remove, update callers to
9246 use readable_regcache::raw_read_part instead.
9247 * regcache.c (regcache_raw_read_part): Remove.
9248
9249 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9250
9251 * regcache.h (regcache_cooked_read): Remove, update callers to
9252 use readable_regcache::cooked_read instead.
9253 * regcache.c (regcache_cooked_read): Remove.
9254
9255 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9256
9257 * regcache.h (regcache_raw_write): Remove, update callers to use
9258 regcache::raw_write instead.
9259 * regcache.c (regcache_raw_write): Remove.
9260
9261 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9262
9263 * regcache.h (regcache_raw_read): Remove, update callers to use
9264 readable_regcache::raw_read instead.
9265 * regcache.c (regcache_raw_read): Remove.
9266
9267 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9268
9269 * regcache.h (regcache_raw_update): Remove, update callers to
9270 use readable_regcache::raw_update instead.
9271 * regcache.c (regcache_raw_update): Remove.
9272
9273 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9274
9275 * regcache.h (regcache_register_status): Remove, update callers
9276 to use reg_buffer::get_register_status directly instead.
9277 * regcache.c (regcache_register_status): Remove.
9278
9279 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9280
9281 * regcache.h (regcache_get_ptid): Remove, update all callers to
9282 call regcache::ptid instead.
9283 * regcache.c (regcache_get_ptid): Remove.
9284
9285 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9286
9287 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
9288
9289 2018-05-30 Pedro Alves <palves@redhat.com>
9290
9291 * common/common-exceptions.h (exception_rethrow): Use
9292 ATTRIBUTE_NORETURN.
9293
9294 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
9295
9296 * breakpoint.c (print_solib_event, check_status_catch_solib):
9297 Remove struct keyword in range-based for loops.
9298 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
9299 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
9300 Likewise.
9301 * linespec.c (find_superclass_methods, search_minsyms_for_name):
9302 Likewise.
9303 * symfile.c (addr_info_make_relative): Likewise.
9304 * thread.c (value_in_thread_stack_temporaries): Likewise.
9305
9306 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
9307
9308 PR gdb/16841
9309 * valops.c (value_struct_elt_for_reference): Call check_typedef on
9310 aggregate type to get its real type before accessing it.
9311
9312 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
9313
9314 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
9315 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
9316 * coff-pe-read.c (add_pe_forwarded_sym): Replace
9317 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
9318 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
9319 * jit.c (jit_breakpoint_re_set_internal): Likewise.
9320 * printcmd.c (info_address_command): Likewise.
9321
9322 2018-05-29 Tom Tromey <tom@tromey.com>
9323
9324 * windows-nat.c (handle_exception): Update fall-through comment.
9325
9326 2018-05-29 Tom Tromey <tom@tromey.com>
9327
9328 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
9329 (struct program_space) <added_solibs>: Now a std::vector.
9330 * breakpoint.c (print_solib_event): Update.
9331 (check_status_catch_solib): Update.
9332 * progspace.c (clear_program_space_solib_cache): Update.
9333 * solib.c (update_solib_list): Update.
9334
9335 2018-05-29 Tom Tromey <tom@tromey.com>
9336
9337 * python/py-type.c (typy_richcompare): Update.
9338 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
9339 * gdbtypes.h (types_deeply_equal): Return bool.
9340 (types_equal): Likewise.
9341 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
9342 declare VEC.
9343 (check_types_equal): Change worklist to std::vector. Return
9344 bool.
9345 (struct type_equality_entry): Add constructor.
9346 (compare_maybe_null_strings): Return bool.
9347 (check_types_worklist): Return bool. Change worklist to
9348 std::vector.
9349 (types_deeply_equal): Use std::vector.
9350 (types_equal): Return bool.
9351 (compare_maybe_null_strings): Simplify.
9352
9353 2018-05-29 Tom Tromey <tom@tromey.com>
9354
9355 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
9356
9357 2018-05-29 Tom Tromey <tom@tromey.com>
9358
9359 * objc-lang.h: Don't include cp-support.h.
9360 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
9361 declare VEC.
9362
9363 2018-05-27 Tom Tromey <tom@tromey.com>
9364
9365 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
9366
9367 2018-05-25 Tom Tromey <tom@tromey.com>
9368
9369 * value.c (value::location): Initialize.
9370
9371 2018-05-25 Tom Tromey <tom@tromey.com>
9372
9373 * dbxread.c (init_bincl_list): Remove.
9374 (bincl_list): Now a std::vector.
9375 (bincls_allocated, next_bincl): Remove.
9376 (free_bincl_list, do_free_bincl_list_cleanup)
9377 (make_cleanup_free_bincl_list): Remove.
9378 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
9379 unique_xmalloc_ptr.
9380 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
9381 (struct header_file_location): Add constructor.
9382 (add_bincl_to_list): Remove.
9383
9384 2018-05-25 Tom Tromey <tom@tromey.com>
9385
9386 * tui/tui.c (tui_enable): Update.
9387 * mi/mi-interp.c (mi_interp::init): Update.
9388 * interps.h (class interp) <name>: New method.
9389 <m_name>: Rename from name.
9390 (~scoped_restore_interp): Update.
9391 * interps.c (interp::interp): Update.
9392 (interp_add, interp_set, interp_lookup_existing)
9393 (current_interp_named_p): Update.
9394
9395 2018-05-25 Tom Tromey <tom@tromey.com>
9396
9397 * interps.c (interp_name): Remove.
9398 * mi/mi-interp.c (mi_interp::init): Update.
9399 * interps.h (interp_name): Remove.
9400 (~scoped_restore_interp): Update.
9401 * tui/tui.c (tui_enable): Update.
9402
9403 2018-05-25 Tom Tromey <tom@tromey.com>
9404
9405 * utils.c (fputs_maybe_filtered): Update.
9406 * linespec.c (decode_line_full): Update.
9407 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
9408 (mi_print_breakpoint_for_event, mi_solib_loaded)
9409 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
9410 (mi_user_selected_context_changed): Update.
9411 * mi/mi-main.c (mi_execute_command): Update.
9412 * cli/cli-script.c (execute_control_command): Update.
9413 * python/python.c (execute_gdb_command): Update.
9414 * solib.c (info_sharedlibrary_command): Update.
9415 * interps.c (interp_ui_out): Remove.
9416 * interps.h (interp_ui_out): Remove.
9417
9418 2018-05-25 Tom Tromey <tom@tromey.com>
9419
9420 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
9421 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
9422 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
9423
9424 2018-05-25 Tom Tromey <tom@tromey.com>
9425
9426 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
9427 * interps.c (interp_exec): Use scoped_restore.
9428
9429 2018-05-25 Tom Tromey <tom@tromey.com>
9430
9431 * remote.c (remote_target::remote_file_get): Use
9432 gdb::byte_vector.
9433 (remote_target::remote_file_put): Likewise.
9434
9435 2018-05-25 Tom Tromey <tom@tromey.com>
9436
9437 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
9438 a std::string.
9439 (get_pe_section_index, add_pe_exported_sym): Update.
9440 (read_pe_exported_syms): Use gdb::def_vector.
9441
9442 2018-05-25 Tom Tromey <tom@tromey.com>
9443
9444 * frame.c (remove_prev_frame): Remove.
9445 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
9446
9447 2018-05-25 Maciej W. Rozycki <macro@mips.com>
9448
9449 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
9450 Remove prototypes.
9451 * mips-linux-nat.c (supply_fpregset): Always call
9452 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
9453 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
9454 `mips_fill_fpregset'.
9455 * mips-linux-tdep.c (mips_supply_fpregset)
9456 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
9457 (mips_fill_fpregset_wrapper): Remove functions.
9458 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
9459 (mips_linux_fpregset): Remove variable.
9460 (mips_linux_iterate_over_regset_sections): Use
9461 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
9462 (mips_linux_o32_sigframe_init): Remove comment.
9463
9464 2018-05-25 Pedro Alves <palves@redhat.com>
9465
9466 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
9467 (struct readahead_cache, struct packet_reg, struct
9468 remote_arch_state, class remote_state): Move higher up in the
9469 file.
9470 (remote_target::m_remote_state): Now an object instead of a pointer.
9471 (remote_target::get_remote_state): Adjust.
9472
9473 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9474
9475 * stack.c (select_and_print_frame): Delete.
9476 (struct function_bounds): Move struct within function.
9477 (func_command): Most content moved into new function
9478 find_frame_for_function, use new function, print result, add
9479 function comment.
9480 (find_frame_for_function): New function, now returns a result.
9481
9482 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9483
9484 * stack.c (iterate_over_block_arg_vars): Fix comment.
9485 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
9486
9487 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9488
9489 PR gdb/23203
9490 * frame.c
9491 (scoped_restore_selected_frame::scoped_restore_selected_frame):
9492 Define.
9493 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
9494 Define.
9495 * frame.h (class scoped_restore_selected_frame): New class.
9496 * stack.c (print_frame_local_vars): Remove catching and rethrowing
9497 of any exception, use scoped_restore_selected_frame to restore the
9498 frame instead.
9499
9500 2018-05-24 Pedro Alves <palves@redhat.com>
9501
9502 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
9503 override.
9504
9505 2018-05-23 Tom Tromey <tom@tromey.com>
9506
9507 * complaints.c (struct complaints): Remove.
9508 (symfile_complaint_book): Remove.
9509 (series): New global.
9510 (complaint_internal): Update.
9511 (clear_complaints): Update.
9512
9513 2018-05-23 Tom Tromey <tom@tromey.com>
9514
9515 * complaints.c (counters): New global.
9516 (struct complain): Remove.
9517 (struct complaints) <root>: Remove.
9518 (complaint_sentinel): Remove.
9519 (symfile_complaint_book): Update.
9520 (find_complaint) Remove.
9521 (complaint_internal, clear_complaints): Update.
9522
9523 2018-05-23 Tom Tromey <tom@tromey.com>
9524
9525 * complaints.c (struct complain) <file, line>: Remove.
9526 (find_complaint): Remove file, line parameters.
9527 (complaint_internal): Update.
9528
9529 2018-05-23 Tom Tromey <tom@tromey.com>
9530
9531 * complaints.c (vcomplaint): Remove.
9532 (complaint_internal) Merge in contents of vcomplaint.
9533
9534 2018-05-23 Tom Tromey <tom@tromey.com>
9535
9536 * complaints.c (struct complaints) <explanation>: Remove.
9537 (symfile_explanations): Remove.
9538 (symfile_complaint_book): Update.
9539 (vcomplaint): Update.
9540 (struct explanation): Remove.
9541
9542 2018-05-23 Tom Tromey <tom@tromey.com>
9543
9544 * complaints.c (symfile_complaints): Remove.
9545 (complaint_internal): Remove "complaints" parameter.
9546 (clear_complaints, vcomplaint): Remove "c" parameter.
9547 (get_complaints): Remove.
9548 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
9549 (dwarf2_debug_line_missing_file_complaint)
9550 (dwarf2_debug_line_missing_end_sequence_complaint)
9551 (dwarf2_complex_location_expr_complaint)
9552 (dwarf2_const_value_length_mismatch_complaint)
9553 (dwarf2_section_buffer_overflow_complaint)
9554 (dwarf2_macro_malformed_definition_complaint)
9555 (dwarf2_invalid_attrib_class_complaint)
9556 (create_addrmap_from_index, dw2_symtab_iter_next)
9557 (dw2_expand_marked_cus)
9558 (dw2_debug_names_iterator::find_vec_in_debug_names)
9559 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
9560 (create_debug_type_hash_table, init_cutu_and_read_dies)
9561 (partial_die_parent_scope, add_partial_enumeration)
9562 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
9563 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
9564 (read_import_statement, read_file_scope, create_dwo_cu_reader)
9565 (create_cus_hash_table, create_dwp_hash_table)
9566 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
9567 (dwarf2_rnglists_process, dwarf2_ranges_process)
9568 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
9569 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
9570 (handle_struct_member_die, process_structure_scope)
9571 (read_array_type, read_common_block, read_module_type)
9572 (read_tag_pointer_type, read_typedef, read_base_type)
9573 (read_subrange_type, load_partial_dies, partial_die_info::read)
9574 (partial_die_info::read, partial_die_info::read)
9575 (partial_die_info::read, read_checked_initial_length_and_offset)
9576 (dwarf2_string_attr, read_formatted_entries)
9577 (dwarf_decode_line_header)
9578 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
9579 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
9580 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
9581 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9582 (get_signatured_type, get_DW_AT_signature_type)
9583 (decode_locdesc, file_file_name, consume_improper_spaces)
9584 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
9585 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9586 (dwarf2_symbol_mark_computed, set_die_type)
9587 (read_attribute_value): Update.
9588 * stap-probe.c (handle_stap_probe, get_stap_base_address):
9589 Update.
9590 * dbxread.c (unknown_symtype_complaint)
9591 (lbrac_mismatch_complaint, repeated_header_complaint)
9592 (set_namestring, function_outside_compilation_unit_complaint)
9593 (read_dbx_symtab, process_one_symbol): Update.
9594 * gdbtypes.c (stub_noname_complaint): Update.
9595 * windows-nat.c (handle_unload_dll): Update.
9596 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
9597 (decode_base_type): Update.
9598 * xcoffread.c (bf_notfound_complaint, ef_complaint)
9599 (eb_complaint, record_include_begin, record_include_end)
9600 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
9601 (process_xcoff_symbol, read_symbol)
9602 (function_outside_compilation_unit_complaint)
9603 (scan_xcoff_symtab): Update.
9604 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
9605 * buildsym.c (finish_block_internal, make_blockvector)
9606 (end_symtab_get_static_block, augment_type_symtab): Update.
9607 * dtrace-probe.c (dtrace_process_dof)
9608 (dtrace_static_probe_ops::get_probes): Update.
9609 * complaints.h (struct complaint): Don't declare.
9610 (symfile_complaints): Remove.
9611 (complaint_internal): Remove "complaints" parameter.
9612 (complaint): Likewise.
9613 (clear_complaints): Likewise.
9614 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9615 (reread_symbols): Update.
9616 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
9617 (dwarf2_frame_cache, decode_frame_entry): Update.
9618 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
9619 * objc-lang.c (lookup_objc_class, lookup_child_selector)
9620 (info_selectors_command): Update.
9621 * macrotab.c (macro_include, check_for_redefinition)
9622 (macro_undef): Update.
9623 * objfiles.c (filter_overlapping_sections): Update.
9624 * stabsread.c (invalid_cpp_abbrev_complaint)
9625 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
9626 (define_symbol, error_type, read_type, rs6000_builtin_type)
9627 (stabs_method_name_from_physname, read_member_functions)
9628 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
9629 (attach_fields_to_type, complain_about_struct_wipeout)
9630 (read_range_type, read_args, common_block_start)
9631 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
9632 Update.
9633 * mdebugread.c (index_complaint, unknown_ext_complaint)
9634 (basic_type_complaint, bad_tag_guess_complaint)
9635 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
9636 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
9637 (parse_procedure, parse_lines)
9638 (function_outside_compilation_unit_complaint)
9639 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
9640 (bad_tag_guess_complaint, reg_value_complaint): Update.
9641 * cp-support.c (demangled_name_complaint): Update.
9642 * macroscope.c (sal_macro_scope): Update.
9643 * dwarf-index-write.c (class debug_names): Update.
9644
9645 2018-05-23 Tom Tromey <tom@tromey.com>
9646
9647 * complaints.c (clear_complaints): Remove "noisy" parameter.
9648 * complaints.h (clear_complaints): Update.
9649 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9650 (reread_symbols): Update.
9651
9652 2018-05-23 Tom Tromey <tom@tromey.com>
9653
9654 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
9655 SUBSEQUENT_MESSAGE.
9656 (vcomplaint, clear_complaints): Update.
9657 (symfile_explanations): Remove some messages.
9658
9659 2018-05-23 Tom Tromey <tom@tromey.com>
9660
9661 * complaints.c (internal_complaint): Remove.
9662 * complaints.h (internal_complaint): Remove.
9663
9664 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9665
9666 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
9667
9668 2018-05-22 Pedro Alves <palves@redhat.com>
9669
9670 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
9671 (remote_fileio_badfd, remote_fileio_return_errno)
9672 (remote_fileio_return_success, remote_fileio_func_open)
9673 (remote_fileio_func_open, remote_fileio_func_close)
9674 (remote_fileio_func_read, remote_fileio_func_write)
9675 (remote_fileio_func_lseek, remote_fileio_func_rename)
9676 (remote_fileio_func_unlink, remote_fileio_func_stat)
9677 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
9678 (remote_fileio_func_isatty, remote_fileio_func_system): Add
9679 remote_target parameter.
9680 (remote_fio_func_map) <func>: Add remote_target parameter.
9681 (do_remote_fileio_request, remote_fileio_request):
9682 * remote-fileio.h (remote_fileio_request):
9683 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
9684 remote_target parameter.
9685 (remote_notif_process, handle_notification): Adjust to pass down
9686 the remote.
9687 (remote_notif_state_allocate): Add remote_target parameter. Save
9688 it.
9689 * remote-notif.h (struct remote_target): Forward declare.
9690 (struct notif_client) <parse, ack, can_get_pending_events>: Add
9691 remote_target parameter.
9692 (struct remote_notif_state) <remote>: New field.
9693 (remote_notif_ack, remote_notif_parse): Add remote_target
9694 parameter.
9695 (remote_notif_state_allocate, remote_notif_state_allocate): Add
9696 remote_target parameter.
9697 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
9698 (threads_listing_context, rmt_thread_action, protocol_feature)
9699 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
9700 (packet_result, struct threads_listing_context, remote_state):
9701 Move definitions and declarations higher up.
9702 (remote_target) <~remote_target>: Declare.
9703 (remote_download_command_source, remote_file_put, remote_file_get)
9704 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
9705 (remote_hostio_pread_vFile, remote_hostio_send_command)
9706 (remote_hostio_set_filesystem, remote_hostio_open)
9707 (remote_hostio_close, remote_hostio_unlink, remote_state)
9708 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
9709 (get_memory_write_packet_size, get_memory_read_packet_size)
9710 (append_pending_thread_resumptions, remote_detach_1)
9711 (append_resumption, remote_resume_with_vcont)
9712 (add_current_inferior_and_thread, wait_ns, wait_as)
9713 (process_stop_reply, remote_notice_new_inferior)
9714 (process_initial_stop_replies, remote_add_thread)
9715 (btrace_sync_conf, remote_btrace_maybe_reopen)
9716 (remove_new_fork_children, kill_new_fork_children)
9717 (discard_pending_stop_replies, stop_reply_queue_length)
9718 (check_pending_events_prevent_wildcard_vcont)
9719 (discard_pending_stop_replies_in_queue, stop_reply)
9720 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
9721 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
9722 (remote_interrupt_as, remote_interrupt_ns)
9723 (remote_get_noisy_reply, remote_query_attached)
9724 (remote_add_inferior, remote_current_thread, get_current_thread)
9725 (set_thread, set_general_thread, set_continue_thread)
9726 (set_general_process, write_ptid)
9727 (remote_unpack_thread_info_response, remote_get_threadinfo)
9728 (parse_threadlist_response, remote_get_threadlist)
9729 (remote_threadlist_iterator, remote_get_threads_with_ql)
9730 (remote_get_threads_with_qxfer)
9731 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
9732 (get_offsets, remote_check_symbols, remote_supported_packet)
9733 (remote_query_supported, remote_packet_size)
9734 (remote_serial_quit_handler, remote_detach_pid)
9735 (remote_vcont_probe, remote_resume_with_hc)
9736 (send_interrupt_sequence, interrupt_query)
9737 (remote_notif_get_pending_events, fetch_register_using_p)
9738 (send_g_packet, process_g_packet, fetch_registers_using_g)
9739 (store_register_using_P, store_registers_using_G)
9740 (set_remote_traceframe, check_binary_download)
9741 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
9742 (remote_xfer_live_readonly_partial, remote_read_bytes)
9743 (remote_send_printf, remote_flash_write, readchar)
9744 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
9745 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
9746 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
9747 (extended_remote_disable_randomization, extended_remote_run)
9748 (send_environment_packet, extended_remote_environment_support)
9749 (extended_remote_set_inferior_cwd, remote_write_qxfer)
9750 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
9751 (packet_command): Now methods of ...
9752 (remote_target): ... this class.
9753 (m_remote_state) <remote_target>: New field.
9754 (struct remote_state) <stop_reply_queue,
9755 remote_async_inferior_event_token, wait_forever_enabled_p>: New
9756 fields.
9757 (remote_state::remote_state): Allocate stop_reply_queue.
9758 (remote_state): Delete global.
9759 (get_remote_state_raw): Delete.
9760 (remote_target::get_remote_state): Allocate m_remote_state on
9761 demand.
9762 (get_current_remote_target): New.
9763 (remote_ops, extended_remote_ops): Delete.
9764 (wait_forever_enabled_p, remote_async_inferior_event_token):
9765 Delete, moved to struct remote_state.
9766 (remote_target::close): Delete self. Destruction bits split to
9767 ...
9768 (remote_target::~remote_target): ... this.
9769 (show_memory_packet_size): Adjust to use
9770 get_current_remote_target.
9771 (struct protocol_feature) <func>: Add remote_target parameter.
9772 All callers adjusted.
9773 (curr_quit_handler_target): New.
9774 (remote_serial_quit_handler): Reimplement.
9775 (remote_target::open_1): Adjust to use get_current_remote_target.
9776 Heap-allocate remote_target/extended_remote_target instances.
9777 (vcont_builder::vcont_builder): Add remote_target parameter, and
9778 save it in m_remote. All callers adjusted.
9779 (vcont_builder::m_remote): New field.
9780 (vcont_builder::restart, vcont_builder::flush)
9781 (vcont_builder::push_action): Use it.
9782 (remote_target::commit_resume): Use it.
9783 (struct queue_iter_param) <remote>: New field.
9784 (remote_target::remove_new_fork_children): Fill in 'remote' field.
9785 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
9786 (check_pending_event_prevents_wildcard_vcont_callback)
9787 (remote_target::check_pending_events_prevent_wildcard_vcont)
9788 (remote_target::discard_pending_stop_replies)
9789 (remote_target::discard_pending_stop_replies_in_queue)
9790 (remote_target::remote_notif_remove_queued_reply): Fill in
9791 'remote' field.
9792 (remote_notif_get_pending_events): New.
9793 (remote_target::readchar, remote_target::remote_serial_write):
9794 Save/restore curr_quit_handler_target.
9795 (putpkt): New.
9796 (kill_new_fork_children): Fill in 'remote' field.
9797 (packet_command): Use get_current_remote_target, defer to
9798 remote_target method of same name.
9799 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
9800 parameter, and save it in m_remote. All callers adjusted.
9801 (scoped_remote_fd::release): Use m_remote.
9802 (scoped_remote_fd::m_remote): New field.
9803 (remote_file_put, remote_file_get, remote_file_delete): Use
9804 get_current_remote_target, defer to remote_target method of same
9805 name.
9806 (remote_btrace_reset): Add remote_state paremeter. Update all
9807 callers.
9808 (remote_async_inferior_event_handler). Pass down 'data'.
9809 (remote_new_objfile): Use get_current_remote_target.
9810 (remote_target::vcont_r_supported): New.
9811 (set_range_stepping): Use get_current_remote_target and
9812 remote_target::vcont_r_supported.
9813 (_initialize_remote): Don't allocate 'remote_state' and
9814 'stop_reply_queue' globals.
9815 * remote.h (struct remote_target): Forward declare.
9816 (getpkt, putpkt, remote_notif_get_pending_events): Add
9817 'remote_target' parameter.
9818
9819 2018-05-22 Pedro Alves <palves@redhat.com>
9820
9821 * remote.c (vcont_builder): Now a class. Make all data members
9822 private.
9823 (vcont_builder) <vcont_builder, restart, flush, push_action>:
9824 Declare methods.
9825 (vcont_builder_restart): Rename to ...
9826 (vcont_builder::restart): ... this.
9827 (vcont_builder_flush): Rename to ...
9828 (vcont_builder::flush): ... this.
9829 (vcont_builder_push_action): Rename to ...
9830 (vcont_builder::push_action): ... this.
9831 (remote_target::commit_resume): Adjust.
9832
9833 2018-05-22 Pedro Alves <palves@redhat.com>
9834
9835 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
9836 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
9837 (get_fixed_memory_packet_size): New.
9838 (get_memory_packet_size): Use it.
9839 (set_memory_packet_size): Don't override the config size with
9840 DEFAULT_MAX_MEMORY_PACKET_SIZE.
9841 (show_memory_packet_size): Use get_fixed_memory_packet_size.
9842 Don't refer to get_memory_packet_size if not connected to a remote
9843 target. Show "(default)" if configured size is 0.
9844
9845 2018-05-22 Pedro Alves <palves@redhat.com>
9846
9847 * remote.c (remote_target::mourn_inferior): Move
9848 discard_pending_stop_replies call here from ...
9849 (_initialize_remote): ... here.
9850
9851 2018-05-22 Pedro Alves <palves@redhat.com>
9852
9853 * remote.c (compare_section_command): Remove set_general_process
9854 call.
9855
9856 2018-05-22 Pedro Alves <palves@redhat.com>
9857
9858 * remote.c (struct packet_reg, struct remote_arch_state):
9859 Move higher up in the file.
9860 (remote_state) <m_arch_states>: Store remote_arch_state values
9861 instead of remote_arch_state pointers.
9862 (remote_state::get_remote_arch_state): Adjust.
9863
9864 2018-05-22 Pedro Alves <palves@redhat.com>
9865
9866 * remote.c: Include <unordered_map>.
9867 (remote_state): Now a class.
9868 (remote_state) <get_remote_arch_state>: Declare method.
9869 <get_remote_arch_state>: New field.
9870 (remote_arch_state) <remote_arch_state>: Declare ctor.
9871 <regs>: Now a unique_ptr.
9872 (remote_gdbarch_data_handle): Delete.
9873 (get_remote_arch_state): Delete.
9874 (remote_state::get_remote_arch_state): New.
9875 (get_remote_state): Adjust to call remote_state's
9876 get_remote_arch_state method.
9877 (init_remote_state): Delete, bits factored out to ...
9878 (remote_arch_state::remote_arch_state): ... this new method.
9879 (get_remote_packet_size, get_memory_packet_size)
9880 (process_g_packet, remote_target::fetch_registers)
9881 (remote_target::prepare_to_store, store_registers_using_G)
9882 (remote_target::store_registers, remote_target::get_trace_status):
9883 Adjust to call remote_state's method.
9884 (_initialize_remote): Remove reference to
9885 remote_gdbarch_data_handle.
9886
9887 2018-05-22 Pedro Alves <palves@redhat.com>
9888
9889 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
9890 pread>: New method declarations.
9891 (remote_target::open_1): Adjust.
9892 (readahead_cache_invalidate): Rename to ...
9893 (readahead_cache::invalidate): ... this, and adjust to be a class
9894 method.
9895 (readahead_cache_invalidate_fd): Rename to ...
9896 (readahead_cache::invalidate_fd): ... this, and adjust to be a
9897 class method.
9898 (remote_hostio_pwrite): Adjust.
9899 (remote_hostio_pread_from_cache): Rename to ...
9900 (readahead_cache::pread): ... this, and adjust to be a class
9901 method.
9902 (remote_hostio_close): Adjust.
9903
9904 2018-05-22 Pedro Alves <palves@redhat.com>
9905
9906 * remote.c (remote_hostio_close_cleanup): Delete.
9907 (class scoped_remote_fd): New.
9908 (remote_file_put, remote_file_get): Use it.
9909
9910 2018-05-22 Pedro Alves <palves@redhat.com>
9911
9912 (struct vCont_action_support): Use bool and initialize all fields.
9913 (struct readahead_cache): Initialize all fields.
9914 (remote_state): Use bool and initialize all fields.
9915 (remote_state::remote_state, remote_state::~remote_state): New.
9916 (new_remote_state): Delete.
9917 (_initialize_remote): Use new to allocate remote_state.
9918
9919 2018-05-22 Pedro Alves <palves@redhat.com>
9920 張俊芝 <zjz@zjz.name>
9921
9922 PR gdb/22973
9923 * c-exp.y: Include "c-support.h".
9924 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
9925 of tolower. Use c_ident_is_alpha to scan names.
9926 * c-lang.c: Include "c-support.h".
9927 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
9928 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
9929 * c-support.h: New file, with bits factored out from ...
9930 * cp-name-parser.y: ... this file.
9931 Include "c-support.h".
9932 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
9933 c-support.h and renamed.
9934 (symbol_end, yylex): Adjust.
9935
9936 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9937
9938 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
9939 parameter type to CORE_ADDR.
9940 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
9941 parameter type in declaration to CORE_ADDR.
9942 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
9943 target_auxv_search to get AT_HWCAP and use the result to get the
9944 target description.
9945 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
9946 to CORE_ADDR. Remove the cast of the return value to unsigned
9947 long. Fix error predicate of target_auxv_search.
9948 (ppc_linux_nat_target::read_description): Change the type of the
9949 hwcap variable to CORE_ADDR.
9950
9951 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9952
9953 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
9954 if the size of fpscr is larger than 32 bits.
9955
9956 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9957
9958 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
9959 (ppc32_linux_vsxregmap): New global.
9960 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
9961 regcache_supply_regset, and regcache_collect_regset.
9962 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
9963 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
9964 (fetch_vsx_register, store_vsx_register): Remove.
9965 (fetch_vsx_registers): Add regno parameter. Get regset using
9966 ppc_linux_vsxregset. Use regset to supply registers.
9967 (store_vsx_registers): Add regno parameter. Get regset using
9968 ppc_linux_vsxregset. Use regset to collect registers.
9969 (fetch_register): Call fetch_vsx_registers instead of
9970 fetch_vsx_register.
9971 (store_register): Call store_vsx_registers instead of
9972 store_vsx_register.
9973 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
9974 new regno parameter.
9975 (store_ppc_registers): Call store_vsx_registers with -1 for the
9976 new regno parameter.
9977 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
9978 (ppc_collect_vsxregset): Remove.
9979
9980 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9981
9982 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
9983 offset fields.
9984 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
9985 for vector register offset fields.
9986 (ppc64_fbsd_reg_offsets): Likewise.
9987 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9988 to vector register offset fields.
9989 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9990 to vector register offset fields.
9991 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
9992 vector register offset fields.
9993 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
9994 initializers for vector register offset fields.
9995 (rs6000_aix64_reg_offsets): Likewise.
9996 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
9997 (ppc_supply_vrregset): Remove.
9998 (ppc_collect_vrregset): Remove.
9999 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
10000 (ppc_linux_vrregset) : New function.
10001 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
10002 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
10003 (ppc32_linux_vrregset): Remove.
10004 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
10005 and use result instead of ppc32_linux_vrregset.
10006 (ppc32_linux_reg_offsets): Remove initializers for vector register
10007 offset fields.
10008 (ppc64_linux_reg_offsets): Likewise.
10009 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
10010 * ppc-linux-nat.c: Include regset.h.
10011 (gdb_vrregset_t): Adjust comment to account for little-endian
10012 mode.
10013 (supply_vrregset, fill_vrregset): Remove.
10014 (fetch_altivec_register, store_altivec_register): Remove.
10015 (fetch_altivec_registers): Add regno parameter. Get regset using
10016 ppc_linux_vrregset. Use regset to supply registers.
10017 (store_altivec_registers): Add regno parameter. Get regset using
10018 ppc_linux_vrregset. Use regset to collect registers.
10019 (fetch_register): Call fetch_altivec_registers instead of
10020 fetch_altivec_register.
10021 (store_register): Call store_altivec_registers instead of
10022 store_altivec_register.
10023 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
10024 the new regno parameter.
10025 (store_ppc_registers): Call store_altivec_registers with -1 for
10026 the new regno parameter.
10027
10028 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10029
10030 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
10031 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
10032 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
10033 (gdb_vrregset_t): Change array type size to
10034 PPC_LINUX_SIZEOF_VRREGSET.
10035 (gdb_vsxregset_t): Change array type size to
10036 PPC_LINUX_SIZEOF_VSXREGSET.
10037 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
10038 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
10039 PPC_LINUX_SIZEOF_VSXREGSET.
10040
10041 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10042
10043 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
10044 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
10045 nat/ppc-linux.c.
10046 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
10047 ppc_linux_target_wordsize with tid.
10048 (ppc_linux_nat_target::read_description): Call ppc_linux_target
10049 wordsize with tid.
10050 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
10051 (ppc64_64bit_inferior_p): Add static and inline specifiers.
10052 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
10053 tid parameter. Remove static specifier.
10054 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
10055 (ppc_linux_target_wordsize): New declaration.
10056
10057 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10058
10059 * arch/ppc-linux-common.c: New file.
10060 * arch/ppc-linux-common.h: New file.
10061 * arch/ppc-linux-tdesc.h: New file.
10062 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
10063 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
10064 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
10065 arch/ppc-linux-tdesc.h.
10066 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
10067 arch/ppc-linux-tdesc.h.
10068 (ppc_linux_nat_target::read_description): Remove target
10069 description matching code. Fill a ppc_linux_features struct and
10070 call ppc_linux_match_description with it. Move comment about ISA
10071 2.05 to ppc-linux-common.c.
10072 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
10073 arch/ppc-linux-tdesc.h.
10074 (ppc_linux_core_read_description): Remove target description
10075 matching code. Fill a ppc_linux_features struct and call
10076 ppc_linux_match_description with it.
10077 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
10078 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
10079 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
10080 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
10081 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
10082 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
10083 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
10084 (tdesc_powerpc_e500l): Remove.
10085
10086 2018-05-22 Joel Brobecker <brobecker@adacore.com>
10087
10088 * ada-lang.c (catch_assert_command): Pass empty string instead
10089 of NULL for excep_string argument.
10090
10091 2018-05-22 Maciej W. Rozycki <macro@mips.com>
10092
10093 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
10094 the width of the requested register exceeds the width of the
10095 `ptrace' data type.
10096
10097 2018-05-21 Tom Tromey <tom@tromey.com>
10098
10099 * printcmd.c (output_command): Remove.
10100 (output_command_const): Rename to output_command.
10101 * valprint.h (output_command): Rename from output_command_const.
10102 * tracepoint.c (trace_dump_actions): Call output_command.
10103
10104 2018-05-21 Tom Tromey <tom@tromey.com>
10105
10106 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
10107 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
10108 * ada-lang.h (create_ada_exception_catchpoint): Update.
10109 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
10110 std::string.
10111 (create_excep_cond_exprs, ~ada_catchpoint)
10112 (should_stop_exception, print_one_exception)
10113 (print_mention_exception, print_recreate_exception): Update.
10114 (ada_get_next_arg): Remove.
10115 (catch_ada_exception_command_split): Use std::string. Change type
10116 of "excep_string", "cond_string".
10117 (catch_ada_exception_command): Update.
10118 (create_ada_exception_catchpoint): Change type of excep_string.
10119 (ada_exception_sal): Remove excep_string parameter.
10120 (~ada_catchpoint): Remove.
10121
10122 2018-05-21 Tom Tromey <tom@tromey.com>
10123
10124 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
10125 cleanup.
10126
10127 2018-05-21 Tom Tromey <tom@tromey.com>
10128
10129 * ada-lang.c (ada_exception_message_1, ada_exception_message):
10130 Return unique_xmalloc_ptr.
10131 (print_it_exception): Update.
10132
10133 2018-05-21 Tom Tromey <tom@tromey.com>
10134
10135 * tracepoint.c (trace_dump_actions): Use std::string.
10136
10137 2018-05-21 Tom Tromey <tom@tromey.com>
10138
10139 * symfile.c (reread_symbols): Use std::string for original_name.
10140
10141 2018-05-21 Tom Tromey <tom@tromey.com>
10142
10143 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
10144 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
10145 constructor.
10146
10147 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
10148
10149 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
10150 instance to...
10151 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
10152 * objfiles.c (get_objfile_bfd_data): Allocate
10153 objfile_per_bfd_storage with obstack_new when allocating on
10154 obstack.
10155
10156 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
10157
10158 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
10159 OBSTACK_ZALLOC.
10160 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
10161 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
10162 * mdebugread.c (mdebug_build_psymtabs): Likewise.
10163 (add_pending): Likewise.
10164 (parse_symbol): Likewise.
10165 (parse_partial_symbols): Likewise.
10166 (psymtab_to_symtab_1): Likewise.
10167 (new_psymtab): Likewise.
10168 (elfmdebug_build_psymtabs): Likewise.
10169 * minsyms.c (terminate_minimal_symbol_table): Likewise.
10170 * objfiles.c (get_objfile_bfd_data): Likewise.
10171 (objfile_register_static_link): Likewise.
10172 * psymtab.c (allocate_psymtab): Likewise.
10173 * stabsread.c (read_member_functions): Likewise.
10174 * xcoffread.c (xcoff_end_psymtab): Likewise.
10175
10176 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
10177
10178 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
10179 compiler supports std::is_trivially_constructible.
10180 * common/poison.h: Include obstack.h.
10181 (IsMallocable): Define to is_trivially_constructible if the
10182 compiler supports it, define to true_type otherwise.
10183 (xobnew): New.
10184 (XOBNEW): Redefine.
10185 (xobnewvec): New.
10186 (XOBNEWVEC): Redefine.
10187 * gdb_obstack.h (obstack_zalloc): New.
10188 (OBSTACK_ZALLOC): Redefine.
10189 (obstack_calloc): New.
10190 (OBSTACK_CALLOC): Redefine.
10191 (obstack_new): New.
10192 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
10193 (gdbarch_obstack): New declaration in gdbarch.h, definition in
10194 gdbarch.c.
10195 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
10196 obstack_calloc/obstack_zalloc.
10197 (gdbarch_obstack_zalloc): Remove.
10198 * target-descriptions.c (tdesc_data_init): Use obstack_new.
10199
10200 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10201
10202 * stack.c (backtrace_command_1): Remove useless variable int i.
10203
10204 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10205
10206 * stack.c (print_frame_info): Fix comment.
10207
10208 2018-05-18 Tom Tromey <tom@tromey.com>
10209
10210 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
10211 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
10212 (~dwarf2_per_objfile): Update
10213 (dwarf2_get_dwz_file): Use new.
10214 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
10215 unique_ptr.
10216
10217 2018-05-18 Tom Tromey <tom@tromey.com>
10218
10219 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
10220 unique_ptr.
10221 * dwarf2read.c (struct dwp_file): Add constructor and
10222 initializers.
10223 (open_and_init_dwp_file): Return a unique_ptr.
10224 (dwarf2_per_objfile, create_dwp_hash_table)
10225 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
10226 (lookup_dwo_unit_in_dwp): Update.
10227 (open_and_init_dwp_file, get_dwp_file): Update.
10228
10229 2018-05-18 Tom Tromey <tom@tromey.com>
10230
10231 * dwarf2read.c (dwarf2_per_objfile): Update.
10232 (struct mapped_index): Add initializers.
10233 (dwarf2_read_index): Use new.
10234 (dw2_symtab_iter_init): Update.
10235 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
10236 unique_ptr.
10237
10238 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
10239
10240 * dwarf2read.c (mapped_index) <total_size>: Remove.
10241
10242 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
10243
10244 * unittests/format_pieces-selftests.c (test_format_specifier):
10245 Add ARI comments.
10246
10247 2018-05-18 Tom Tromey <tom@tromey.com>
10248
10249 * c-typeprint.c (maybe_print_hole): New function.
10250 (c_print_type_struct_field_offset): Update.
10251 (c_type_print_base_struct_union): Call maybe_print_hole.
10252
10253 2018-05-17 Keith Seitz <keiths@redhat.com>
10254
10255 * breakpoint.c (build_bpstat_chain): New function, moved from
10256 bpstat_stop_status.
10257 (bpstat_stop_status): Add optional parameter, `stop_chain'.
10258 If no stop chain is passed, call build_bpstat_chain to build it.
10259 * breakpoint.h (build_bpstat_chain): Declare.
10260 (bpstat_stop_status): Move documentation here from breakpoint.c.
10261 * infrun.c (handle_signal_stop): Before eliding inlined frames,
10262 build the stop chain and pass it to skip_inline_frames.
10263 Pass this stop chain to bpstat_stop_status.
10264 * inline-frame.c: Include breakpoint.h.
10265 (stopped_by_user_bp_inline_frame): New function.
10266 (skip_inline_frames): Add parameter `stop_chain'.
10267 Move documention to inline-frame.h.
10268 If non-NULL, use stopped_by_user_bp_inline_frame to determine
10269 whether the frame should be elided.
10270 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
10271 Add moved documentation and update for new parameter.
10272
10273 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
10274
10275 PR cli/14975
10276 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10277 unittests/format_pieces-selftests.c.
10278 * common/format.h (format_piece) <operator==>: New.
10279 (format_pieces) <operator[]>: Remove.
10280 * common/format.c (format_pieces::format_pieces): Handle \e.
10281 * unittests/format_pieces-selftests.c: New.
10282
10283 2018-05-17 Tom Tromey <tom@tromey.com>
10284
10285 PR symtab/23010:
10286 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
10287 (dw2_instantiate_symtab): Add skip_partial parameter.
10288 (dw2_find_last_source_symtab, dw2_map_expand_apply)
10289 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
10290 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
10291 (dw2_expand_symtabs_matching_one)
10292 (dw2_find_pc_sect_compunit_symtab)
10293 (dw2_debug_names_lookup_symbol)
10294 (dw2_debug_names_expand_symtabs_for_function): Update.
10295 (init_cutu_and_read_dies): Add skip_partial parameter.
10296 (process_psymtab_comp_unit, build_type_psymtabs_1)
10297 (process_skeletonless_type_unit, load_partial_comp_unit)
10298 (psymtab_to_symtab_1): Update.
10299 (load_full_comp_unit): Add skip_partial parameter.
10300 (process_imported_unit_die, dwarf2_read_addr_index)
10301 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
10302 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
10303 (read_signatured_type): Update.
10304
10305 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
10306
10307 * value.c (release_value): Remove unused variable.
10308 (record_latest_value): Likewise.
10309 (access_value_history): Likewise.
10310 (preserve_values): Likewise.
10311
10312 2018-05-17 Tom Tromey <tom@tromey.com>
10313
10314 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
10315 Initialize.
10316
10317 2018-05-16 Maciej W. Rozycki <macro@mips.com>
10318
10319 PR gdb/22286
10320 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
10321 Also handle registers whose width is not a multiple of
10322 PTRACE_TYPE_RET.
10323 (linux_nat_trad_target::store_register): Likewise.
10324
10325 2018-05-16 Tom Tromey <tom@tromey.com>
10326
10327 * gdbcore.h (core_bfd): Redefine.
10328 * corelow.c (core_target::close): Update.
10329 (core_target_open): Update.
10330 * progspace.h (struct program_space) <cbfd>: Now a
10331 gdb_bfd_ref_ptr.
10332
10333 2018-05-16 Tom Tromey <tom@tromey.com>
10334
10335 PR cli/19551:
10336 * symfile-add-flags.h (enum symfile_add_flags)
10337 <SYMFILE_NOT_FILENAME>: New constant.
10338 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
10339 objfile name from BFD.
10340 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
10341 * minidebug.c (find_separate_debug_file_in_section): Put
10342 ".gnu_debugdata" into BFD's file name.
10343
10344 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
10345
10346 * regcache.c (regcache_read_ftype, regcache_write_ftype):
10347 Remove.
10348
10349 2018-05-15 Tamar Christina <tamar.christina@arm.com>
10350
10351 PR binutils/21446
10352 * aarch64-tdep.c (aarch64_analyze_prologue,
10353 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
10354 Indicate not interested in errors.
10355
10356 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10357
10358 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
10359 Supply the MIPS_ZERO_REGNUM register.
10360
10361 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10362
10363 * mips-tdep.c (mask_address_var): Make variable static.
10364
10365 2018-05-14 Tom Tromey <tom@tromey.com>
10366
10367 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
10368
10369 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
10370
10371 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
10372 FXSAVE_ADDR for the mxcsr register.
10373
10374 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
10375
10376 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
10377
10378 2018-05-11 Pedro Alves <palves@redhat.com>
10379
10380 * corelow.c (core_target) <core_target>: No longer inline.
10381 Initialize m_core_gdbarch, m_core_vec and build the section table
10382 here.
10383 <~core_target>: New.
10384 <core_gdbarch, get_core_register_section>: New methods.
10385 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
10386 factored out from ...
10387 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
10388 (core_ops): Delete.
10389 (sniff_core_bfd): Add gdbarch parameter.
10390 (core_close): Delete, merged into ...
10391 (core_target::close): ... here. Delete self.
10392 (core_close_cleanup): Delete.
10393 (core_target_open): Allocate a core_target on the heap. Use a
10394 unique_ptr instead of a cleanup. Bits moved into the core_target
10395 ctor. Adjust to use core_target methods instead of globals.
10396 (get_core_register_section): Rename to ...
10397 (core_target::get_core_register_section): ... this and adjust.
10398 (struct get_core_registers_cb_data): New.
10399 (get_core_registers_cb): Use it. Use bool.
10400 (core_target::fetch_registers, core_target::files_info)
10401 (core_target::xfer_partial, core_target::read_description)
10402 (core_target::pid_to, core_target::thread_name): Adjust to
10403 reference class fields instead of globals.
10404 * target.h (struct target_ops_deleter, target_ops_up): New.
10405
10406 2018-05-11 Pedro Alves <palves@redhat.com>
10407
10408 * corefile.c (core_file_command): Move to corelow.c.
10409 * corelow.c (the_core_target): Delete.
10410 (core_file_command): Moved from corefile.c. Check exec_bfd
10411 instead of the_core_target. Use target_detach instead of calling
10412 into the_core_target directly.
10413 (maybe_say_no_core_file_now): New.
10414 (core_target::detach): Use it.
10415 (_initialize_corelow): Remove references to the_core_target.
10416 * gdbcore.h (the_core_target): Delete.
10417
10418 2018-05-11 Tom Tromey <tromey@redhat.com>
10419 Pedro Alves <palves@redhat.com>
10420
10421 * corefile.c (core_bfd): Remove.
10422 * gdbcore.h (core_bfd): Now a macro.
10423 * progspace.h (struct program_space) <cbfd>: New field.
10424
10425 2018-05-11 Tom Tromey <tom@tromey.com>
10426
10427 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
10428 gdb::def_vector.
10429
10430 2018-05-10 Tom Tromey <tom@tromey.com>
10431
10432 * configure: Rebuild.
10433 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
10434
10435 2018-05-10 Joel Brobecker <brobecker@adacore.com>
10436
10437 PR server/23158:
10438 * regformats/regdat.sh: Adjust script, following the addition
10439 of the new expedite_regs parameter to init_target_desc.
10440
10441 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
10442
10443 PR gdb/23127
10444 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
10445 set_gdbarch_significant_addr_bit.
10446 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
10447 set_gdbarch_significant_addr_bit.
10448 * utils.c (address_significant): Update to sign extend addr.
10449
10450 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
10451
10452 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
10453 (xtensa_linux_init_abi): Limit tdep->num_regs by
10454 tdep->num_nopriv_regs.
10455 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
10456 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
10457 not initialized.
10458
10459 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
10460
10461 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
10462
10463 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
10464
10465 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
10466 (I387_MXCSR_INIT_VAL): New constant.
10467 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
10468 buffer if it was supplied by the inferior.
10469 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
10470 (i387_xsave_get_clear_bv): New function.
10471 (i387_supply_xsave): Only read x87 control registers from the
10472 xsave buffer if the feature is enabled, and the state will have
10473 been written, otherwise, provide a suitable default.
10474 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
10475 including x87 control registers. Update control registers if they
10476 have changed from the default value, and mark features as enabled
10477 as required.
10478 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
10479
10480 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
10481
10482 * spu-tdep.c (info_spu_event_command): Fix output formatting.
10483
10484 2018-05-07 Tom Tromey <tom@tromey.com>
10485
10486 * configure: Rebuild.
10487 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
10488
10489 2018-05-07 Tom Tromey <tom@tromey.com>
10490
10491 PR tdep/20362:
10492 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
10493 bit. Use correct value for VDIV.
10494
10495 2018-05-04 Tom Tromey <tom@tromey.com>
10496
10497 * configure: Rebuild.
10498 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
10499
10500 2018-05-04 Tom Tromey <tom@tromey.com>
10501
10502 * linux-record.c (record_linux_system_call) <case
10503 RECORD_SYS_RECVFROM>: Add "break".
10504
10505 2018-05-04 Tom Tromey <tom@tromey.com>
10506
10507 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
10508 Add missing "break".
10509 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
10510 Add missing "break".
10511
10512 2018-05-04 Tom Tromey <tom@tromey.com>
10513
10514 * rs6000-tdep.c (ppc_process_record_op4)
10515 (ppc_process_record_op63): Add fall-through comment.
10516
10517 2018-05-04 Tom Tromey <tom@tromey.com>
10518
10519 * i386-tdep.c (i386_process_record): Add fall-through comment.
10520
10521 2018-05-04 Tom Tromey <tom@tromey.com>
10522
10523 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
10524 comment.
10525
10526 2018-05-04 Tom Tromey <tom@tromey.com>
10527
10528 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
10529 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
10530 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
10531 comment.
10532 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
10533 comment.
10534 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
10535 comment.
10536
10537 2018-05-04 Tom Tromey <tom@tromey.com>
10538
10539 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
10540
10541 2018-05-04 Tom Tromey <tom@tromey.com>
10542
10543 * s390-tdep.c (s390_process_record): Fix fall-through comments.
10544 * xcoffread.c (scan_xcoff_symtab): Move comment later.
10545 * symfile.c (section_is_mapped): Fix fall-through comment.
10546 * stabsread.c (define_symbol, read_member_functions): Fix
10547 fall-through comment.
10548 * s390-linux-tdep.c (s390_process_record): Fix fall-through
10549 comment.
10550 * remote.c (remote_wait_as): Fix fall-through comment.
10551 * p-exp.y (yylex): Fix fall-through comment.
10552 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
10553 comment.
10554 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
10555 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
10556 * jv-exp.y (yylex): Fix fall-through comment.
10557 * go-exp.y (lex_one_token): Fix fall-through comment.
10558 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
10559 fall-through comment.
10560 * f-exp.y (yylex): Fix fall-through comment.
10561 * dwarf2read.c (process_die): Fix fall-through comments.
10562 * dbxread.c (process_one_symbol): Fix fall-through comment.
10563 * d-exp.y (lex_one_token): Fix fall-through comment.
10564 * cp-name-parser.y (yylex): Fix fall-through comment.
10565 * coffread.c (coff_symtab_read): Fix fall-through comment.
10566 * c-exp.y (lex_one_token): Fix fall-through comment.
10567 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
10568 comment.
10569 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
10570 comment.
10571
10572 2018-05-04 Tom Tromey <tom@tromey.com>
10573
10574 PR python/22730:
10575 * NEWS: Mention gdb.execute change.
10576 * gdbcmd.h (execute_control_command): Don't declare.
10577 * python/python.c (execute_gdb_command): Use read_command_lines_1,
10578 execute_control_commands, execute_control_commands_to_string.
10579 * cli/cli-script.h (execute_control_commands)
10580 (execute_control_commands_to_string): Declare.
10581 (execute_control_command): Add from_tty parameter.
10582 * cli/cli-script.c (execute_control_commands)
10583 (execute_control_commands_to_string): New functions.
10584 (execute_user_command): Use execute_control_commands.
10585 (execute_control_command_1): Add "from_tty" parameter. Update.
10586 (execute_control_command): Likewise.
10587
10588 2018-05-04 Tom Tromey <tom@tromey.com>
10589
10590 PR python/22731:
10591 * NEWS: Mention that breakpoint commands are writable.
10592 * python/py-breakpoint.c (bppy_set_commands): New function.
10593 (breakpoint_object_getset) <"commands">: Use it.
10594
10595 2018-05-04 Tom Tromey <tom@tromey.com>
10596
10597 * tracepoint.c (actions_command): Update.
10598 * mi/mi-cmd-break.c (mi_command_line_array)
10599 (mi_command_line_array_cnt, mi_command_line_array_ptr)
10600 (mi_read_next_line): Remove.
10601 (mi_cmd_break_commands): Update.
10602 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
10603 function_view.
10604 * cli/cli-script.c (get_command_line): Update.
10605 (process_next_line): Use function_view. Constify.
10606 (recurse_read_control_structure, read_command_lines)
10607 (read_command_lines_1): Change argument types to function_view.
10608 (do_define_command, document_command): Update.
10609 * breakpoint.h (check_tracepoint_command): Don't declare.
10610 * breakpoint.c (check_tracepoint_command): Remove.
10611 (commands_command_1, create_tracepoint_from_upload): Update.
10612
10613 2018-05-04 Tom Tromey <tom@tromey.com>
10614
10615 PR gdb/11750:
10616 * cli/cli-script.h (enum command_control_type) <define_control>:
10617 New constant.
10618 * cli/cli-script.c (multi_line_command_p): Handle define_control.
10619 (build_command_line, execute_control_command_1)
10620 (process_next_line): Likewise.
10621 (do_define_command): New function, extracted from define_command.
10622 (define_command): Use it.
10623
10624 2018-05-04 Tom Tromey <tom@tromey.com>
10625
10626 * tracepoint.c (actions_command): Update.
10627 * cli/cli-script.h (read_command_lines): Update.
10628 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
10629 (MAX_TMPBUF): Remove define.
10630 (define_command): Use string_printf.
10631 (document_command): Likewise.
10632 * breakpoint.c (commands_command_1): Update.
10633
10634 2018-05-04 Tom Tromey <tom@tromey.com>
10635
10636 * top.c (execute_command): Update.
10637 * cli/cli-script.h (print_command_lines): Now varargs.
10638 * cli/cli-script.c (print_command_lines): Now varargs.
10639 (execute_control_command_1) <case while_control, case if_control>:
10640 Update.
10641
10642 2018-05-04 Tom Tromey <tom@tromey.com>
10643
10644 * tracepoint.c (all_tracepoint_actions): Rename from
10645 all_tracepoint_actions_and_cleanup. Change return type.
10646 (actions_command, encode_actions_1, encode_actions)
10647 (trace_dump_actions, tdump_command): Update.
10648 * remote.c (remote_download_command_source): Update.
10649 * python/python.c (gdbpy_eval_from_control_command)
10650 (python_command, python_interactive_command): Update.
10651 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10652 * guile/guile.c (guile_command)
10653 (gdbscm_eval_from_control_command, guile_command): Update.
10654 * compile/compile.c (compile_code_command)
10655 (compile_print_command, compile_to_object): Update.
10656 * cli/cli-script.h (struct command_lines_deleter): New.
10657 (counted_command_line): New typedef.
10658 (struct command_line): Add constructor, destructor.
10659 <body_list>: Remove.
10660 <body_list_0, body_list_1>: New members.
10661 (command_line_up): Remove typedef.
10662 (read_command_lines, read_command_lines_1, get_command_line):
10663 Update.
10664 (copy_command_lines): Don't declare.
10665 * cli/cli-script.c (build_command_line): Use "new".
10666 (get_command_line): Return counted_command_line.
10667 (print_command_lines, execute_user_command)
10668 (execute_control_command_1, while_command, if_command): Update.
10669 (realloc_body_list): Remove.
10670 (process_next_line, recurse_read_control_structure): Update.
10671 (read_command_lines, read_command_lines_1): Return counted_command_line.
10672 (free_command_lines): Use "delete".
10673 (copy_command_lines): Remove.
10674 (define_command, document_command, show_user_1): Update.
10675 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
10676 a counted_command_line.
10677 * breakpoint.h (counted_command_line): Remove typedef.
10678 (breakpoint_set_commands): Update.
10679 * breakpoint.c (check_no_tracepoint_commands)
10680 (validate_commands_for_breakpoint): Update.
10681 (breakpoint_set_commands): Change commands to be a
10682 counted_command_line.
10683 (commands_command_1, update_dprintf_command_list)
10684 (create_tracepoint_from_upload): Update.
10685
10686 2018-05-04 Tom Tromey <tom@tromey.com>
10687
10688 * cli/cli-decode.h (cmd_list_element): New constructor.
10689 (~cmd_list_element): New destructor.
10690 (struct cmd_list_element): Add initializers.
10691 * cli/cli-decode.c (do_add_cmd): Use "new".
10692 (delete_cmd): Use "delete".
10693
10694 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
10695 Pedro Alves <palves@redhat.com>
10696
10697 PR breakpoints/19806 and support for PR external/20207.
10698 * NEWS: Mention Aarch64 watchpoint improvements.
10699 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
10700 watchpoints and PR external/20207 watchpoints.
10701 * nat/aarch64-linux-hw-point.c
10702 (kernel_supports_any_contiguous_range): New.
10703 (aarch64_watchpoint_offset): New.
10704 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
10705 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
10706 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
10707 (aarch64_align_watchpoint): New parameters aligned_offset_p and
10708 next_addr_orig_p. Support PR external/20207 watchpoints.
10709 (aarch64_downgrade_regs): New.
10710 (aarch64_dr_state_insert_one_point): New parameters offset and
10711 addr_orig.
10712 (aarch64_dr_state_remove_one_point): Likewise.
10713 (aarch64_handle_breakpoint): Update caller.
10714 (aarch64_handle_aligned_watchpoint): Likewise.
10715 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
10716 aligned_offset.
10717 (aarch64_linux_set_debug_regs): Remove const from state. Call
10718 aarch64_downgrade_regs.
10719 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
10720 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
10721 (DR_CONTROL_MASK): ... this.
10722 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
10723 (unsigned int aarch64_watchpoint_offset): New prototype.
10724 (aarch64_linux_set_debug_regs): Remove const from state.
10725 * utils.c (align_up, align_down): Move to ...
10726 * common/common-utils.c (align_up, align_down): ... here.
10727 * utils.h (align_up, align_down): Move to ...
10728 * common/common-utils.h (align_up, align_down): ... here.
10729
10730 2018-05-04 Joel Brobecker <brobecker@adacore.com>
10731
10732 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
10733 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
10734 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
10735 Re-implement to match the ABI as summarized in GCC's
10736 gcc/config/sparc/sparc.c. All callers updated.
10737 (sparc32_store_arguments): Remove assertion.
10738
10739 2018-05-04 Tom Tromey <tom@tromey.com>
10740
10741 * printcmd.c: Don't include tui.h.
10742 (decode_format): Use skip_spaces.
10743
10744 2018-05-04 Tom Tromey <tom@tromey.com>
10745
10746 PR gdb/22619:
10747 * printcmd.c (last_count): New global.
10748 (x_command): Use saved count when repeating.
10749
10750 2018-05-04 Tom Tromey <tom@tromey.com>
10751
10752 * nto-procfs.c (do_closedir_cleanup): Remove.
10753 (procfs_pidlist): Use gdb_dir_up.
10754 * procfs.c (do_closedir_cleanup): Remove.
10755 (proc_update_threads): Use gdb_dir_up.
10756 * common/filestuff.h (struct gdb_dir_deleter): New.
10757 (gdb_dir_up): New typedef.
10758
10759 2018-05-04 Tom Tromey <tom@tromey.com>
10760
10761 * ada-lang.c (print_mention_exception): Use std::string.
10762
10763 2018-05-04 Tom Tromey <tom@tromey.com>
10764
10765 * ada-lang.c (create_excep_cond_exprs): Update.
10766 (ada_exception_catchpoint_cond_string): Use std::string.
10767
10768 2018-05-04 Tom Tromey <tom@tromey.com>
10769
10770 * ada-lang.c (xget_renaming_scope): Return std::string.
10771 (old_renaming_is_invisible): Update.
10772
10773 2018-05-04 Tom Tromey <tom@tromey.com>
10774
10775 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
10776 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
10777
10778 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
10779
10780 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
10781
10782 2018-05-04 Tom Tromey <tom@tromey.com>
10783
10784 * remote.c (remote_query_supported_append): Change type.
10785 (remote_check_symbols): Update.
10786
10787 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
10788
10789 PR gdb/11420
10790 * configure.ac: Prepend libpython.
10791 * python/python-config.py: Likewise.
10792 * configure: Regenerate.
10793
10794 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
10795
10796 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
10797
10798 2018-05-03 Pedro Alves <palves@redhat.com>
10799
10800 * s390-linux-nat.c
10801 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
10802 override. Write 'true' instead of '1'.
10803 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
10804 declaration.
10805
10806 2018-05-02 Pedro Alves <palves@redhat.com>
10807
10808 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
10809 add_inf_child_target.
10810 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
10811 add_inf_child_target.
10812 * aix-thread.c (aix_thread_target_info): New.
10813 (aix_thread_target) <shortname, longname, doc>: Delete.
10814 <info>: New.
10815 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
10816 add_inf_child_target.
10817 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
10818 add_inf_child_target.
10819 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
10820 add_inf_child_target.
10821 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
10822 add_inf_child_target.
10823 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
10824 add_inf_child_target.
10825 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
10826 add_inf_child_target.
10827 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
10828 add_inf_child_target.
10829 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
10830 add_inf_child_target.
10831 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
10832 add_inf_child_target.
10833 * bfd-target.c (target_bfd_target_info): New.
10834 (target_bfd) <shortname, longname, doc>: Delete.
10835 <info>: New.
10836 * bsd-kvm.c (bsd_kvm_target_info): New.
10837 (bsd_kvm_target) <shortname, longname, doc>: Delete.
10838 <info>: New.
10839 (bsd_kvm_target::open): Rename to ...
10840 (bsd_kvm_target_open): ... this. Adjust.
10841 * bsd-uthread.c (bsd_uthread_target_info): New.
10842 (bsd_uthread_target) <shortname, longname, doc>: Delete.
10843 <info>: New.
10844 * corefile.c (core_file_command): Adjust.
10845 * corelow.c (core_target_info): New.
10846 (core_target) <shortname, longname, doc>: Delete.
10847 <info>: New.
10848 (core_target::open): Rename to ...
10849 (core_target_open): ... this. Adjust.
10850 * ctf.c (ctf_target_info): New.
10851 (ctf_target) <shortname, longname, doc>: Delete.
10852 <info>: New.
10853 (ctf_target::open): Rename to ...
10854 (ctf_target_open): ... this.
10855 (_initialize_ctf): Adjust.
10856 * exec.c (exec_target_info): New.
10857 (exec_target) <shortname, longname, doc>: Delete.
10858 <info>: New.
10859 (exec_target::open): Rename to ...
10860 (exec_target_open): ... this.
10861 * gdbcore.h (core_target_open): Declare.
10862 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
10863 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
10864 add_inf_child_target.
10865 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
10866 add_inf_child_target.
10867 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
10868 add_inf_child_target.
10869 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
10870 add_inf_child_target.
10871 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
10872 add_inf_child_target.
10873 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
10874 add_inf_child_target.
10875 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
10876 add_inf_child_target.
10877 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
10878 add_inf_child_target.
10879 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
10880 add_inf_child_target.
10881 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
10882 add_inf_child_target.
10883 * inf-child.c (inf_child_target_info): New.
10884 (inf_child_target::info): New.
10885 (inf_child_open_target): Remove 'target' parameter. Use
10886 get_native_target instead.
10887 (inf_child_target::open): Delete.
10888 (add_inf_child_target): New.
10889 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
10890 Delete.
10891 <info>: New.
10892 (add_inf_child_target): Declare.
10893 (inf_child_open_target): Declare.
10894 * linux-thread-db.c (thread_db_target_info): New.
10895 (thread_db_target) <shortname, longname, doc>: Delete.
10896 <info>: New.
10897 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
10898 add_inf_child_target.
10899 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
10900 add_inf_child_target.
10901 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
10902 add_inf_child_target.
10903 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
10904 add_inf_child_target.
10905 * make-target-delegates (print_class): Adjust.
10906 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
10907 add_inf_child_target.
10908 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
10909 add_inf_child_target.
10910 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
10911 add_inf_child_target.
10912 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
10913 add_inf_child_target.
10914 * nto-procfs.c (nto_native_target_info): New.
10915 (nto_procfs_target_native) <shortname, longname, doc>:
10916 Delete.
10917 <info>: New.
10918 (nto_procfs_target_info): New.
10919 (nto_procfs_target_procfs) <shortname, longname, doc>:
10920 Delete.
10921 <info>: New.
10922 (init_procfs_targets): Adjust.
10923 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
10924 add_inf_child_target.
10925 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
10926 add_inf_child_target.
10927 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
10928 add_inf_child_target.
10929 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
10930 add_inf_child_target.
10931 * ravenscar-thread.c (ravenscar_target_info): New.
10932 (ravenscar_thread_target) <shortname, longname, doc>:
10933 Delete.
10934 <info>: New.
10935 * record-btrace.c (record_btrace_target_info):
10936 (record_btrace_target) <shortname, longname, doc>: Delete.
10937 <info>: New.
10938 (record_btrace_target::open): Rename to ...
10939 (record_btrace_target_open): ... this. Adjust.
10940 * record-full.c (record_longname, record_doc): New.
10941 (record_full_base_target) <shortname, longname, doc>: Delete.
10942 <info>: New.
10943 (record_full_target_info): New.
10944 (record_full_target): <shortname>: Delete.
10945 <info>: New.
10946 (record_full_core_open_1, record_full_open_1): Update comments.
10947 (record_full_base_target::open): Rename to ...
10948 (record_full_open): ... this.
10949 (cmd_record_full_restore): Update.
10950 (_initialize_record_full): Update.
10951 * remote-sim.c (remote_sim_target_info): New.
10952 (gdbsim_target) <shortname, longname, doc>: Delete.
10953 <info>: New.
10954 (gdbsim_target::open): Rename to ...
10955 (gdbsim_target_open): ... this.
10956 (_initialize_remote_sim): Adjust.
10957 * remote.c (remote_doc): New.
10958 (remote_target_info): New.
10959 (remote_target) <shortname, longname, doc>: Delete.
10960 <info>: New.
10961 (extended_remote_target_info): New.
10962 (extended_remote_target) <shortname, longname, doc>: Delete.
10963 <info>: New.
10964 (remote_target::open_1): Make static. Adjust.
10965 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
10966 * s390-linux-nat.c (_initialize_s390_nat): Use
10967 add_inf_child_target.
10968 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
10969 add_inf_child_target.
10970 * sol-thread.c (thread_db_target_info): New.
10971 (sol_thread_target) <shortname, longname, doc>: Delete.
10972 <info>: New.
10973 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
10974 add_inf_child_target.
10975 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
10976 add_inf_child_target.
10977 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
10978 add_inf_child_target.
10979 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
10980 add_inf_child_target.
10981 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
10982 add_inf_child_target.
10983 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
10984 add_inf_child_target.
10985 * spu-linux-nat.c (_initialize_spu_nat): Use
10986 add_inf_child_target.
10987 * spu-multiarch.c (spu_multiarch_target_info): New.
10988 (spu_multiarch_target) <shortname, longname, doc>: Delete.
10989 <info>: New.
10990 * target-delegates.c: Regenerate.
10991 * target.c: Include <unordered_map>.
10992 (target_ops_p): Delete.
10993 (DEF_VEC_P(target_ops_p)): Delete.
10994 (target_factories): New.
10995 (test_target_info): New.
10996 (test_target_ops::info): New.
10997 (open_target): Adjust to use target_factories.
10998 (add_target_with_completer): Rename to ...
10999 (add_target): ... this. Change prototype. Register target_info
11000 and open callback in target_factories. Register target_info in
11001 command context instead of target_ops.
11002 (add_target): Delete old implementation.
11003 (add_deprecated_target_alias): Change prototype. Adjust.
11004 (the_native_target): New.
11005 (set_native_target, get_native_target): New.
11006 (find_default_run_target): Use the_native_target.
11007 (find_attach_target, find_run_target): Simplify.
11008 (target_ops::open): Delete.
11009 (dummy_target_info): New.
11010 (dummy_target::shortname, dummy_target::longname)
11011 (dummy_target::doc): Delete.
11012 (dummy_target::info): New.
11013 (debug_target::shortname, debug_target::longname)
11014 (debug_target::doc): Delete.
11015 (debug_target::info): New.
11016 * target.h (struct target_info): New.
11017 (target_ops::~target_ops): Add comment.
11018 (target_ops::info): New.
11019 (target_ops::shortname, target_ops::longname, target_ops::doc): No
11020 longer virtual. Implement in terms of target_info.
11021 (set_native_target, get_native_target): Declare.
11022 (target_open_ftype): New.
11023 (add_target, add_target_with_completer)
11024 (add_deprecated_target_alias): Change prototype.
11025 (test_target) <shortname, longname, doc>: Delete.
11026 <info>: New.
11027 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
11028 add_inf_child_target.
11029 * tracefile-tfile.c (tfile_target_info): New.
11030 (tfile_target) <shortname, longname, doc>: Delete.
11031 <info>: New.
11032 (tfile_target::open): Rename to ...
11033 (tfile_target_open): ... this.
11034 (_initialize_tracefile_tfile): Adjust.
11035 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
11036 add_inf_child_target.
11037 * windows-nat.c (_initialize_windows_nat): Use
11038 add_inf_child_target.
11039 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
11040 add_inf_child_target.
11041
11042 2018-05-02 Pedro Alves <palves@redhat.com>
11043
11044 * linux-nat.h (linux_nat_target) <low_new_thread,
11045 low_delete_thread, low_new_fork, low_forget_process,
11046 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
11047 New virtual methods.
11048 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
11049 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
11050 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
11051 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
11052 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
11053 Delete.
11054 * linux-fork.c (delete_fork): Adjust to call low method.
11055 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
11056 (linux_nat_new_fork, linux_nat_forget_process_hook)
11057 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
11058 (linux_nat_status_is_event):
11059 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
11060 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
11061 to call low method.
11062 (sigtrap_is_event): Rename to ...
11063 (linux_nat_target::low_status_is_event): ... this.
11064 (linux_nat_set_status_is_event): Delete.
11065 (save_stop_reason, linux_nat_wait_1)
11066 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
11067 low methods.
11068 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
11069 (linux_nat_set_new_fork, linux_nat_set_forget_process)
11070 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
11071 (linux_nat_set_prepare_to_resume): Delete.
11072 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
11073 low virtual methods.
11074 * amd64-linux-nat.c: Likewise.
11075 * arm-linux-nat.c: Likewise.
11076 * i386-linux-nat.c: Likewise.
11077 * ia64-linux-nat.c: Likewise.
11078 * mips-linux-nat.c: Likewise.
11079 * ppc-linux-nat.c: Likewise.
11080 * s390-linux-nat.c: Likewise.
11081 * sparc64-linux-nat.c: Likewise.
11082 * x86-linux-nat.c: Likewise.
11083 * x86-linux-nat.h: Include "nat/x86-linux.h".
11084 (x86_linux_nat_target) <low_new_fork, low_forget_process,
11085 low_prepare_to_resume, low_new_thread, low_delete_thread>:
11086 Override methods.
11087
11088 2018-05-02 Pedro Alves <palves@redhat.com>
11089
11090 * target.h (target_ops)
11091 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11092 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
11093 stopped_by_watchpoint, have_continuable_watchpoint,
11094 stopped_data_address, watchpoint_addr_within_range,
11095 can_accel_watchpoint_condition, can_run, thread_alive,
11096 has_all_memory, has_memory, has_stack, has_registers,
11097 has_execution, can_async_p, is_async_p, supports_non_stop,
11098 always_non_stop_p, can_execute_reverse, supports_multi_process,
11099 supports_enable_disable_tracepoint,
11100 supports_disable_randomization, supports_string_tracing,
11101 supports_evaluation_of_breakpoint_conditions,
11102 can_run_breakpoint_commands, filesystem_is_local,
11103 can_download_tracepoint, get_trace_state_variable_value,
11104 set_trace_notes, get_tib_address, use_agent, can_use_agent,
11105 record_is_replaying, record_will_replay,
11106 augmented_libraries_svr4_read>: Adjust to return bool.
11107 * aarch64-linux-nat.c: All implementations adjusted.
11108 * aix-thread.c: All implementations adjusted.
11109 * arm-linux-nat.c: All implementations adjusted.
11110 * breakpoint.c: All implementations adjusted.
11111 * bsd-kvm.c: All implementations adjusted.
11112 * bsd-uthread.c: All implementations adjusted.
11113 * corelow.c: All implementations adjusted.
11114 * ctf.c: All implementations adjusted.
11115 * darwin-nat.c: All implementations adjusted.
11116 * darwin-nat.h: All implementations adjusted.
11117 * exec.c: All implementations adjusted.
11118 * fbsd-nat.c: All implementations adjusted.
11119 * fbsd-nat.h: All implementations adjusted.
11120 * gnu-nat.c: All implementations adjusted.
11121 * gnu-nat.h: All implementations adjusted.
11122 * go32-nat.c: All implementations adjusted.
11123 * ia64-linux-nat.c: All implementations adjusted.
11124 * inf-child.c: All implementations adjusted.
11125 * inf-child.h: All implementations adjusted.
11126 * inf-ptrace.c: All implementations adjusted.
11127 * inf-ptrace.h: All implementations adjusted.
11128 * linux-nat.c: All implementations adjusted.
11129 * linux-nat.h: All implementations adjusted.
11130 * mips-linux-nat.c: All implementations adjusted.
11131 * nto-procfs.c: All implementations adjusted.
11132 * ppc-linux-nat.c: All implementations adjusted.
11133 * procfs.c: All implementations adjusted.
11134 * ravenscar-thread.c: All implementations adjusted.
11135 * record-btrace.c: All implementations adjusted.
11136 * record-full.c: All implementations adjusted.
11137 * remote-sim.c: All implementations adjusted.
11138 * remote.c: All implementations adjusted.
11139 * s390-linux-nat.c: All implementations adjusted.
11140 * sol-thread.c: All implementations adjusted.
11141 * spu-multiarch.c: All implementations adjusted.
11142 * target-delegates.c: All implementations adjusted.
11143 * target.c: All implementations adjusted.
11144 * target.h: All implementations adjusted.
11145 * tracefile-tfile.c: All implementations adjusted.
11146 * tracefile.c: All implementations adjusted.
11147 * tracefile.h: All implementations adjusted.
11148 * windows-nat.c: All implementations adjusted.
11149 * x86-linux-nat.h: All implementations adjusted.
11150 * x86-nat.h: All implementations adjusted.
11151
11152 2018-05-02 Pedro Alves <palves@redhat.com>
11153
11154 * make-target-delegates (scan_target_h): Don't trim lines here.
11155 Replace sequences of tabs and/or whitespace with a single
11156 whitespace.
11157 (top level, parsing methods): Trim each line before processing it
11158 here.
11159
11160 2018-05-02 Pedro Alves <palves@redhat.com>
11161 John Baldwin <jhb@freebsd.org>
11162
11163 * target.h (enum strata) <debug_stratum>: New.
11164 (struct target_ops) <all delegation methods>: Replace by C++
11165 virtual methods, and drop "to_" prefix. All references updated
11166 throughout.
11167 <to_shortname, to_longname, to_doc, to_data,
11168 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
11169 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
11170 virtual methods. All references updated throughout.
11171 <can_attach, supports_terminal_ours, can_create_inferior,
11172 get_thread_control_capabilities, attach_no_wait>: New
11173 virtual methods.
11174 <insert_breakpoint, remove_breakpoint>: Now
11175 TARGET_DEFAULT_NORETURN methods.
11176 <info_proc>: Now returns bool.
11177 <to_magic>: Delete.
11178 (OPS_MAGIC): Delete.
11179 (current_target): Delete. All references replaced by references
11180 to ...
11181 (target_stack): ... this. New.
11182 (target_shortname, target_longname): Adjust.
11183 (target_can_run): Now a function declaration.
11184 (default_child_has_all_memory, default_child_has_memory)
11185 (default_child_has_stack, default_child_has_registers)
11186 (default_child_has_execution): Remove target_ops parameter.
11187 (complete_target_initialization): Delete.
11188 (memory_breakpoint_target): New template class.
11189 (test_target_ops): Refactor as a C++ class with virtual methods.
11190 * make-target-delegates (NAME_PART): Tighten.
11191 (POINTER_PART, CP_SYMBOL): New.
11192 (SIMPLE_RETURN_PART): Reimplement.
11193 (VEC_RETURN_PART): Expect less.
11194 (RETURN_PART, VIRTUAL_PART): New.
11195 (METHOD): Adjust to C++ virtual methods.
11196 (scan_target_h): Remove reference to C99.
11197 (dname): Output "target_ops::" prefix.
11198 (write_function_header): Adjust to output a C++ class method.
11199 (write_declaration): New.
11200 (write_delegator): Adjust to output a C++ class method.
11201 (tdname): Output "dummy_target::" prefix.
11202 (write_tdefault, write_debugmethod): Adjust to output a C++ class
11203 method.
11204 (tdefault_names, debug_names): Delete.
11205 (return_types, tdefaults, styles, argtypes_array): New.
11206 (top level): All methods are delegators.
11207 (print_class): New.
11208 (top level): Print dummy_target and debug_target classes.
11209 * target-delegates.c: Regenerate.
11210 * target-debug.h (target_debug_print_enum_info_proc_what)
11211 (target_debug_print_thread_control_capabilities)
11212 (target_debug_print_thread_info_p): New.
11213 * target.c (dummy_target): Delete.
11214 (the_dummy_target, the_debug_target): New.
11215 (target_stack): Now extern.
11216 (set_targetdebug): Push/unpush debug target.
11217 (default_child_has_all_memory, default_child_has_memory)
11218 (default_child_has_stack, default_child_has_registers)
11219 (default_child_has_execution): Remove target_ops parameter.
11220 (complete_target_initialization): Delete.
11221 (add_target_with_completer): No longer call
11222 complete_target_initialization.
11223 (target_supports_terminal_ours): Use regular delegation.
11224 (update_current_target): Delete.
11225 (push_target): No longer check magic number. Don't call
11226 update_current_target.
11227 (unpush_target): Don't call update_current_target.
11228 (target_is_pushed): No longer check magic number.
11229 (target_require_runnable): Skip for all stratums over
11230 process_stratum.
11231 (target_ops::info_proc): New.
11232 (target_info_proc): Use find_target_at and
11233 find_default_run_target.
11234 (target_supports_disable_randomization): Use regular delegation.
11235 (target_get_osdata): Use find_target_at.
11236 (target_ops::open, target_ops::close, target_ops::can_attach)
11237 (target_ops::attach, target_ops::can_create_inferior)
11238 (target_ops::create_inferior, target_ops::can_run)
11239 (target_can_run): New.
11240 (default_fileio_target): Use regular delegation.
11241 (target_ops::fileio_open, target_ops::fileio_pwrite)
11242 (target_ops::fileio_pread, target_ops::fileio_fstat)
11243 (target_ops::fileio_close, target_ops::fileio_unlink)
11244 (target_ops::fileio_readlink): New.
11245 (target_fileio_open_1, target_fileio_unlink)
11246 (target_fileio_readlink): Always call the target method. Handle
11247 FILEIO_ENOSYS.
11248 (return_zero, return_zero_has_execution): Delete.
11249 (init_dummy_target): Delete.
11250 (dummy_target::dummy_target, dummy_target::shortname)
11251 (dummy_target::longname, dummy_target::doc)
11252 (debug_target::debug_target, debug_target::shortname)
11253 (debug_target::longname, debug_target::doc): New.
11254 (target_supports_delete_record): Use regular delegation.
11255 (setup_target_debug): Delete.
11256 (maintenance_print_target_stack): Skip debug_stratum.
11257 (initialize_targets): Instantiate the_dummy_target and
11258 the_debug_target.
11259 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
11260 use target_stack.
11261 (target_auxv_search, fprint_target_auxv): Adjust.
11262 (info_auxv_command): Adjust to use target_stack.
11263 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
11264 * exceptions.c (print_flush): Handle a NULL target_stack.
11265 * regcache.c (target_ops_no_register): Refactor as class with
11266 virtual methods.
11267
11268 * exec.c (exec_target): New class.
11269 (exec_ops): Now an exec_target.
11270 (exec_open, exec_close_1, exec_get_section_table)
11271 (exec_xfer_partial, exec_files_info, exec_has_memory)
11272 (exec_make_note_section): Refactor as exec_target methods.
11273 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
11274 Delete.
11275 (exec_target::find_memory_regions): New.
11276 (_initialize_exec): Don't call init_exec_ops.
11277 * gdbcore.h (exec_file_clear): Delete.
11278
11279 * corefile.c (core_target): Delete.
11280 (core_file_command): Adjust.
11281 * corelow.c (core_target): New class.
11282 (the_core_target): New.
11283 (core_close): Remove target_ops parameter.
11284 (core_close_cleanup): Adjust.
11285 (core_target::close): New.
11286 (core_open, core_detach, get_core_registers, core_files_info)
11287 (core_xfer_partial, core_thread_alive, core_read_description)
11288 (core_pid_to_str, core_thread_name, core_has_memory)
11289 (core_has_stack, core_has_registers, core_info_proc): Rework as
11290 core_target methods.
11291 (ignore, core_remove_breakpoint, init_core_ops): Delete.
11292 (_initialize_corelow): Initialize the_core_target.
11293 * gdbcore.h (core_target): Delete.
11294 (the_core_target): New.
11295
11296 * ctf.c: (ctf_target): New class.
11297 (ctf_ops): Now a ctf_target.
11298 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
11299 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
11300 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
11301 methods.
11302 (init_ctf_ops): Delete.
11303 (_initialize_ctf): Don't call it.
11304 * tracefile-tfile.c (tfile_target): New class.
11305 (tfile_ops): Now a tfile_target.
11306 (tfile_open, tfile_close, tfile_files_info)
11307 (tfile_get_tracepoint_status, tfile_trace_find)
11308 (tfile_fetch_registers, tfile_xfer_partial)
11309 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
11310 Refactor as tfile_target methods.
11311 (tfile_xfer_partial_features): Remove target_ops parameter.
11312 (init_tfile_ops): Delete.
11313 (_initialize_tracefile_tfile): Don't call it.
11314 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
11315 (tracefile_has_stack, tracefile_has_registers)
11316 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
11317 tracefile_target methods.
11318 (init_tracefile_ops): Delete.
11319 (tracefile_target::tracefile_target): New.
11320 * tracefile.h: Include "target.h".
11321 (tracefile_target): New class.
11322 (init_tracefile_ops): Delete.
11323
11324 * spu-multiarch.c (spu_multiarch_target): New class.
11325 (spu_ops): Now a spu_multiarch_target.
11326 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
11327 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
11328 (spu_search_memory, spu_mourn_inferior): Refactor as
11329 spu_multiarch_target methods.
11330 (init_spu_ops): Delete.
11331 (_initialize_spu_multiarch): Remove references to init_spu_ops,
11332 complete_target_initialization.
11333
11334 * ravenscar-thread.c (ravenscar_thread_target): New class.
11335 (ravenscar_ops): Now a ravenscar_thread_target.
11336 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
11337 (ravenscar_thread_alive, ravenscar_pid_to_str)
11338 (ravenscar_fetch_registers, ravenscar_store_registers)
11339 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
11340 (ravenscar_stopped_by_hw_breakpoint)
11341 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
11342 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
11343 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
11344 methods.
11345 (init_ravenscar_thread_ops): Delete.
11346 (_initialize_ravenscar): Remove references to
11347 init_ravenscar_thread_ops and complete_target_initialization.
11348
11349 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
11350 (bsd_uthread_target): New class.
11351 (bsd_uthread_ops): Now a bsd_uthread_target.
11352 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
11353 (bsd_uthread_close, bsd_uthread_mourn_inferior)
11354 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
11355 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
11356 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
11357 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
11358 (bsd_uthread_target): Delete function.
11359 (_initialize_bsd_uthread): Remove reference to
11360 complete_target_initialization.
11361
11362 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
11363 (target_bfd): ... this new class.
11364 (target_bfd_xfer_partial, target_bfd_get_section_table)
11365 (target_bfd_close): Refactor as target_bfd methods.
11366 (target_bfd::~target_bfd): New.
11367 (target_bfd_reopen): Adjust.
11368 (target_bfd::close): New.
11369
11370 * record-btrace.c (record_btrace_target): New class.
11371 (record_btrace_ops): Now a record_btrace_target.
11372 (record_btrace_open, record_btrace_stop_recording)
11373 (record_btrace_disconnect, record_btrace_close)
11374 (record_btrace_async, record_btrace_info)
11375 (record_btrace_insn_history, record_btrace_insn_history_range)
11376 (record_btrace_insn_history_from, record_btrace_call_history)
11377 (record_btrace_call_history_range)
11378 (record_btrace_call_history_from, record_btrace_record_method)
11379 (record_btrace_is_replaying, record_btrace_will_replay)
11380 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
11381 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
11382 (record_btrace_store_registers, record_btrace_prepare_to_store)
11383 (record_btrace_to_get_unwinder)
11384 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
11385 (record_btrace_commit_resume, record_btrace_wait)
11386 (record_btrace_stop, record_btrace_can_execute_reverse)
11387 (record_btrace_stopped_by_sw_breakpoint)
11388 (record_btrace_supports_stopped_by_sw_breakpoint)
11389 (record_btrace_stopped_by_hw_breakpoint)
11390 (record_btrace_supports_stopped_by_hw_breakpoint)
11391 (record_btrace_update_thread_list, record_btrace_thread_alive)
11392 (record_btrace_goto_begin, record_btrace_goto_end)
11393 (record_btrace_goto, record_btrace_stop_replaying_all)
11394 (record_btrace_execution_direction)
11395 (record_btrace_prepare_to_generate_core)
11396 (record_btrace_done_generating_core): Refactor as
11397 record_btrace_target methods.
11398 (init_record_btrace_ops): Delete.
11399 (_initialize_record_btrace): Remove reference to
11400 init_record_btrace_ops.
11401 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
11402 the execution_direction global.
11403 (record_full_base_target, record_full_target)
11404 (record_full_core_target): New classes.
11405 (record_full_ops): Now a record_full_target.
11406 (record_full_core_ops): Now a record_full_core_target.
11407 (record_full_target::detach, record_full_target::disconnect)
11408 (record_full_core_target::disconnect)
11409 (record_full_target::mourn_inferior, record_full_target::kill):
11410 New.
11411 (record_full_open, record_full_close, record_full_async): Refactor
11412 as methods of the record_full_base_target class.
11413 (record_full_resume, record_full_commit_resume): Refactor
11414 as methods of the record_full_target class.
11415 (record_full_wait, record_full_stopped_by_watchpoint)
11416 (record_full_stopped_data_address)
11417 (record_full_stopped_by_sw_breakpoint)
11418 (record_full_supports_stopped_by_sw_breakpoint)
11419 (record_full_stopped_by_hw_breakpoint)
11420 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
11421 methods of the record_full_base_target class.
11422 (record_full_store_registers, record_full_xfer_partial)
11423 (record_full_insert_breakpoint, record_full_remove_breakpoint):
11424 Refactor as methods of the record_full_target class.
11425 (record_full_can_execute_reverse, record_full_get_bookmark)
11426 (record_full_goto_bookmark, record_full_execution_direction)
11427 (record_full_record_method, record_full_info, record_full_delete)
11428 (record_full_is_replaying, record_full_will_replay)
11429 (record_full_goto_begin, record_full_goto_end, record_full_goto)
11430 (record_full_stop_replaying): Refactor as methods of the
11431 record_full_base_target class.
11432 (record_full_core_resume, record_full_core_kill)
11433 (record_full_core_fetch_registers)
11434 (record_full_core_prepare_to_store)
11435 (record_full_core_store_registers, record_full_core_xfer_partial)
11436 (record_full_core_insert_breakpoint)
11437 (record_full_core_remove_breakpoint)
11438 (record_full_core_has_execution): Refactor
11439 as methods of the record_full_core_target class.
11440 (record_full_base_target::supports_delete_record): New.
11441 (init_record_full_ops): Delete.
11442 (init_record_full_core_ops): Delete.
11443 (record_full_save): Refactor as method of the
11444 record_full_base_target class.
11445 (_initialize_record_full): Remove references to
11446 init_record_full_ops and init_record_full_core_ops.
11447
11448 * remote.c (remote_target, extended_remote_target): New classes.
11449 (remote_ops): Now a remote_target.
11450 (extended_remote_ops): Now an extended_remote_target.
11451 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
11452 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
11453 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
11454 (remote_pass_signals, remote_set_syscall_catchpoint)
11455 (remote_program_signals, )
11456 (remote_thread_always_alive): Remove target_ops parameter.
11457 (remote_thread_alive, remote_thread_name)
11458 (remote_update_thread_list, remote_threads_extra_info)
11459 (remote_static_tracepoint_marker_at)
11460 (remote_static_tracepoint_markers_by_strid)
11461 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
11462 (remote_open): Refactor as methods of remote_target.
11463 (extended_remote_open, extended_remote_detach)
11464 (extended_remote_attach, extended_remote_post_attach):
11465 (extended_remote_supports_disable_randomization)
11466 (extended_remote_create_inferior): : Refactor as method of
11467 extended_remote_target.
11468 (remote_set_permissions, remote_open_1, remote_detach)
11469 (remote_follow_fork, remote_follow_exec, remote_disconnect)
11470 (remote_resume, remote_commit_resume, remote_stop)
11471 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
11472 (remote_terminal_ours, remote_wait, remote_fetch_registers)
11473 (remote_prepare_to_store, remote_store_registers)
11474 (remote_flash_erase, remote_flash_done, remote_files_info)
11475 (remote_kill, remote_mourn, remote_insert_breakpoint)
11476 (remote_remove_breakpoint, remote_insert_watchpoint)
11477 (remote_watchpoint_addr_within_range)
11478 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
11479 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
11480 (remote_supports_stopped_by_sw_breakpoint)
11481 (remote_stopped_by_hw_breakpoint)
11482 (remote_supports_stopped_by_hw_breakpoint)
11483 (remote_stopped_by_watchpoint, remote_stopped_data_address)
11484 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
11485 (remote_verify_memory): Refactor as methods of remote_target.
11486 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
11487 parameter.
11488 (remote_xfer_partial, remote_get_memory_xfer_limit)
11489 (remote_search_memory, remote_rcmd, remote_memory_map)
11490 (remote_pid_to_str, remote_get_thread_local_address)
11491 (remote_get_tib_address, remote_read_description): Refactor as
11492 methods of remote_target.
11493 (remote_target::fileio_open, remote_target::fileio_pwrite)
11494 (remote_target::fileio_pread, remote_target::fileio_close): New.
11495 (remote_hostio_readlink, remote_hostio_fstat)
11496 (remote_filesystem_is_local, remote_can_execute_reverse)
11497 (remote_supports_non_stop, remote_supports_disable_randomization)
11498 (remote_supports_multi_process, remote_supports_cond_breakpoints)
11499 (remote_supports_enable_disable_tracepoint)
11500 (remote_supports_string_tracing)
11501 (remote_can_run_breakpoint_commands, remote_trace_init)
11502 (remote_download_tracepoint, remote_can_download_tracepoint)
11503 (remote_download_trace_state_variable, remote_enable_tracepoint)
11504 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
11505 (remote_trace_start, remote_get_trace_status)
11506 (remote_get_tracepoint_status, remote_trace_stop)
11507 (remote_trace_find, remote_get_trace_state_variable_value)
11508 (remote_save_trace_data, remote_get_raw_trace_data)
11509 (remote_set_disconnected_tracing, remote_core_of_thread)
11510 (remote_set_circular_trace_buffer, remote_traceframe_info)
11511 (remote_get_min_fast_tracepoint_insn_len)
11512 (remote_set_trace_buffer_size, remote_set_trace_notes)
11513 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
11514 (remote_disable_btrace, remote_teardown_btrace)
11515 (remote_read_btrace, remote_btrace_conf)
11516 (remote_augmented_libraries_svr4_read, remote_load)
11517 (remote_pid_to_exec_file, remote_can_do_single_step)
11518 (remote_execution_direction, remote_thread_handle_to_thread_info):
11519 Refactor as methods of remote_target.
11520 (init_remote_ops, init_extended_remote_ops): Delete.
11521 (remote_can_async_p, remote_is_async_p, remote_async)
11522 (remote_thread_events, remote_upload_tracepoints)
11523 (remote_upload_trace_state_variables): Refactor as methods of
11524 remote_target.
11525 (_initialize_remote): Remove references to init_remote_ops and
11526 init_extended_remote_ops.
11527
11528 * remote-sim.c (gdbsim_target): New class.
11529 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
11530 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
11531 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
11532 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
11533 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
11534 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
11535 Refactor as methods of gdbsim_target.
11536 (gdbsim_ops): Now a gdbsim_target.
11537 (init_gdbsim_ops): Delete.
11538 (gdbsim_cntrl_c): Adjust.
11539 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
11540
11541 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
11542 (the_amd64_linux_nat_target): New.
11543 (amd64_linux_fetch_inferior_registers)
11544 (amd64_linux_store_inferior_registers): Refactor as methods of
11545 amd64_linux_nat_target.
11546 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
11547 * i386-linux-nat.c: Don't include "linux-nat.h".
11548 (i386_linux_nat_target): New class.
11549 (the_i386_linux_nat_target): New.
11550 (i386_linux_fetch_inferior_registers)
11551 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
11552 as methods of i386_linux_nat_target.
11553 (_initialize_i386_linux_nat): Adjust. Set linux_target.
11554 * inf-child.c (inf_child_ops): Delete.
11555 (inf_child_fetch_inferior_registers)
11556 (inf_child_store_inferior_registers): Delete.
11557 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
11558 methods of inf_child_target.
11559 (inf_child_target::supports_terminal_ours)
11560 (inf_child_target::terminal_init)
11561 (inf_child_target::terminal_inferior)
11562 (inf_child_target::terminal_ours_for_output)
11563 (inf_child_target::terminal_ours, inf_child_target::interrupt)
11564 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
11565 New.
11566 (inf_child_open, inf_child_disconnect, inf_child_close)
11567 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
11568 (inf_child_post_startup_inferior, inf_child_can_run)
11569 (inf_child_pid_to_exec_file): Refactor as methods of
11570 inf_child_target.
11571 (inf_child_follow_fork): Delete.
11572 (inf_child_target::can_create_inferior)
11573 (inf_child_target::can_attach): New.
11574 (inf_child_target::has_all_memory, inf_child_target::has_memory)
11575 (inf_child_target::has_stack, inf_child_target::has_registers)
11576 (inf_child_target::has_execution): New.
11577 (inf_child_fileio_open, inf_child_fileio_pwrite)
11578 (inf_child_fileio_pread, inf_child_fileio_fstat)
11579 (inf_child_fileio_close, inf_child_fileio_unlink)
11580 (inf_child_fileio_readlink, inf_child_use_agent)
11581 (inf_child_can_use_agent): Refactor as methods of
11582 inf_child_target.
11583 (return_zero, inf_child_target): Delete.
11584 (inf_child_target::inf_child_target): New.
11585 * inf-child.h: Include "target.h".
11586 (inf_child_target): Delete function prototype.
11587 (inf_child_target): New class.
11588 (inf_child_open_target, inf_child_mourn_inferior)
11589 (inf_child_maybe_unpush_target): Delete.
11590 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
11591 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
11592 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
11593 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
11594 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
11595 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
11596 (inf_ptrace_wait, inf_ptrace_xfer_partial)
11597 (inf_ptrace_thread_alive, inf_ptrace_files_info)
11598 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
11599 methods of inf_ptrace_target.
11600 (inf_ptrace_target): Delete function.
11601 * inf-ptrace.h: Include "inf-child.h".
11602 (inf_ptrace_target): Delete function declaration.
11603 (inf_ptrace_target): New class.
11604 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
11605 * linux-nat.c (linux_target): New.
11606 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
11607 (linux_nat_target::~linux_nat_target): New.
11608 (linux_child_post_attach, linux_child_post_startup_inferior)
11609 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
11610 (linux_child_remove_fork_catchpoint)
11611 (linux_child_insert_vfork_catchpoint)
11612 (linux_child_remove_vfork_catchpoint)
11613 (linux_child_insert_exec_catchpoint)
11614 (linux_child_remove_exec_catchpoint)
11615 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
11616 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
11617 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
11618 (linux_nat_stopped_data_address)
11619 (linux_nat_stopped_by_sw_breakpoint)
11620 (linux_nat_supports_stopped_by_sw_breakpoint)
11621 (linux_nat_stopped_by_hw_breakpoint)
11622 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
11623 (linux_nat_kill, linux_nat_mourn_inferior)
11624 (linux_nat_xfer_partial, linux_nat_thread_alive)
11625 (linux_nat_update_thread_list, linux_nat_pid_to_str)
11626 (linux_nat_thread_name, linux_child_pid_to_exec_file)
11627 (linux_child_static_tracepoint_markers_by_strid)
11628 (linux_nat_is_async_p, linux_nat_can_async_p)
11629 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
11630 (linux_nat_supports_multi_process)
11631 (linux_nat_supports_disable_randomization, linux_nat_async)
11632 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
11633 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
11634 (linux_nat_fileio_open, linux_nat_fileio_readlink)
11635 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
11636 methods of linux_nat_target.
11637 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
11638 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
11639 parameter.
11640 (check_stopped_by_watchpoint): Adjust.
11641 (linux_xfer_partial): Delete.
11642 (linux_target_install_ops, linux_target, linux_nat_add_target):
11643 Delete.
11644 (linux_nat_target::linux_nat_target): New.
11645 * linux-nat.h: Include "inf-ptrace.h".
11646 (linux_nat_target): New.
11647 (linux_target, linux_target_install_ops, linux_nat_add_target):
11648 Delete function declarations.
11649 (linux_target): Declare global.
11650 * linux-thread-db.c (thread_db_target): New.
11651 (thread_db_target::thread_db_target): New.
11652 (thread_db_ops): Delete.
11653 (the_thread_db_target): New.
11654 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
11655 (thread_db_update_thread_list, thread_db_pid_to_str)
11656 (thread_db_extra_thread_info)
11657 (thread_db_thread_handle_to_thread_info)
11658 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
11659 (thread_db_resume): Refactor as methods of thread_db_target.
11660 (init_thread_db_ops): Delete.
11661 (_initialize_thread_db): Remove reference to init_thread_db_ops.
11662 * x86-linux-nat.c: Don't include "linux-nat.h".
11663 (super_post_startup_inferior): Delete.
11664 (x86_linux_nat_target::~x86_linux_nat_target): New.
11665 (x86_linux_child_post_startup_inferior)
11666 (x86_linux_read_description, x86_linux_enable_btrace)
11667 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
11668 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
11669 methods of x86_linux_nat_target.
11670 (x86_linux_create_target): Delete. Bits folded ...
11671 (x86_linux_add_target): ... here. Now takes a linux_nat_target
11672 pointer.
11673 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
11674 (x86_linux_nat_target): New class.
11675 (x86_linux_create_target): Delete.
11676 (x86_linux_add_target): Now takes a linux_nat_target pointer.
11677 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
11678 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
11679 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
11680 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
11681 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
11682 make extern.
11683 (x86_use_watchpoints): Delete.
11684 * x86-nat.h: Include "breakpoint.h" and "target.h".
11685 (x86_use_watchpoints): Delete.
11686 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
11687 (x86_stopped_by_watchpoint, x86_stopped_data_address)
11688 (x86_insert_watchpoint, x86_remove_watchpoint)
11689 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
11690 (x86_stopped_by_hw_breakpoint): New declarations.
11691 (x86_nat_target): New template class.
11692
11693 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
11694 (the_ppc_linux_nat_target): New.
11695 (ppc_linux_fetch_inferior_registers)
11696 (ppc_linux_can_use_hw_breakpoint)
11697 (ppc_linux_region_ok_for_hw_watchpoint)
11698 (ppc_linux_ranged_break_num_registers)
11699 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
11700 (ppc_linux_insert_mask_watchpoint)
11701 (ppc_linux_remove_mask_watchpoint)
11702 (ppc_linux_can_accel_watchpoint_condition)
11703 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
11704 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
11705 (ppc_linux_watchpoint_addr_within_range)
11706 (ppc_linux_masked_watch_num_registers)
11707 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
11708 (ppc_linux_read_description): Refactor as methods of
11709 ppc_linux_nat_target.
11710 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
11711
11712 * procfs.c (procfs_xfer_partial): Delete forward declaration.
11713 (procfs_target): New class.
11714 (the_procfs_target): New.
11715 (procfs_target): Delete function.
11716 (procfs_auxv_parse, procfs_attach, procfs_detach)
11717 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
11718 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
11719 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
11720 (procfs_create_inferior, procfs_update_thread_list)
11721 (procfs_thread_alive, procfs_pid_to_str)
11722 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
11723 (procfs_stopped_data_address, procfs_insert_watchpoint)
11724 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
11725 (proc_find_memory_regions, procfs_info_proc)
11726 (procfs_make_note_section): Refactor as methods of procfs_target.
11727 (_initialize_procfs): Adjust.
11728 * sol-thread.c (sol_thread_target): New class.
11729 (sol_thread_ops): Now a sol_thread_target.
11730 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
11731 (sol_thread_fetch_registers, sol_thread_store_registers)
11732 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
11733 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
11734 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
11735 (init_sol_thread_ops): Delete.
11736 (_initialize_sol_thread): Adjust. Remove references to
11737 init_sol_thread_ops and complete_target_initialization.
11738
11739 * windows-nat.c (windows_nat_target): New class.
11740 (windows_fetch_inferior_registers)
11741 (windows_store_inferior_registers, windows_resume, windows_wait)
11742 (windows_attach, windows_detach, windows_pid_to_exec_file)
11743 (windows_files_info, windows_create_inferior)
11744 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
11745 (windows_close, windows_pid_to_str, windows_xfer_partial)
11746 (windows_get_tib_address, windows_get_ada_task_ptid)
11747 (windows_thread_name, windows_thread_alive): Refactor as
11748 windows_nat_target methods.
11749 (do_initial_windows_stuff): Adjust.
11750 (windows_target): Delete function.
11751 (_initialize_windows_nat): Adjust.
11752
11753 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
11754 (darwin_mourn_inferior, darwin_kill_inferior)
11755 (darwin_create_inferior, darwin_attach, darwin_detach)
11756 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
11757 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
11758 (darwin_supports_multi_process): Refactor as darwin_nat_target
11759 methods.
11760 (darwin_resume_to, darwin_files_info): Delete.
11761 (_initialize_darwin_inferior): Rename to ...
11762 (_initialize_darwin_nat): ... this. Adjust to C++ification.
11763 * darwin-nat.h: Include "inf-child.h".
11764 (darwin_nat_target): New class.
11765 (darwin_complete_target): Delete.
11766 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
11767 (darwin_target): New.
11768 (i386_darwin_fetch_inferior_registers)
11769 (i386_darwin_store_inferior_registers): Refactor as methods of
11770 darwin_nat_target.
11771 (darwin_complete_target): Delete, with ...
11772 (_initialize_i386_darwin_nat): ... bits factored out here.
11773
11774 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
11775 (the_alpha_linux_nat_target): New.
11776 (alpha_linux_register_u_offset): Refactor as
11777 alpha_linux_nat_target method.
11778 (_initialize_alpha_linux_nat): Adjust.
11779 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
11780 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11781 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
11782 methods of linux_nat_trad_target.
11783 (linux_trad_target): Delete.
11784 * linux-nat-trad.h (linux_trad_target): Delete function.
11785 (linux_nat_trad_target): New class.
11786 * mips-linux-nat.c (mips_linux_nat_target): New class.
11787 (super_fetch_registers, super_store_registers, super_close):
11788 Delete.
11789 (the_mips_linux_nat_target): New.
11790 (mips64_linux_regsets_fetch_registers)
11791 (mips64_linux_regsets_store_registers)
11792 (mips64_linux_fetch_registers, mips64_linux_store_registers)
11793 (mips_linux_register_u_offset, mips_linux_read_description)
11794 (mips_linux_can_use_hw_breakpoint)
11795 (mips_linux_stopped_by_watchpoint)
11796 (mips_linux_stopped_data_address)
11797 (mips_linux_region_ok_for_hw_watchpoint)
11798 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
11799 (mips_linux_close): Refactor as methods of mips_linux_nat.
11800 (_initialize_mips_linux_nat): Adjust to C++ification.
11801
11802 * aix-thread.c (aix_thread_target): New class.
11803 (aix_thread_ops): Now an aix_thread_target.
11804 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
11805 (aix_thread_fetch_registers, aix_thread_store_registers)
11806 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
11807 (aix_thread_thread_alive, aix_thread_pid_to_str)
11808 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
11809 Refactor as methods of aix_thread_target.
11810 (init_aix_thread_ops): Delete.
11811 (_initialize_aix_thread): Remove references to init_aix_thread_ops
11812 and complete_target_initialization.
11813 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
11814 (rs6000_nat_target): New class.
11815 (the_rs6000_nat_target): New.
11816 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
11817 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
11818 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
11819 (super_create_inferior): Delete.
11820 (_initialize_rs6000_nat): Adjust to C++ification.
11821
11822 * arm-linux-nat.c (arm_linux_nat_target): New class.
11823 (the_arm_linux_nat_target): New.
11824 (arm_linux_fetch_inferior_registers)
11825 (arm_linux_store_inferior_registers, arm_linux_read_description)
11826 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
11827 (arm_linux_remove_hw_breakpoint)
11828 (arm_linux_region_ok_for_hw_watchpoint)
11829 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
11830 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
11831 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
11832 arm_linux_nat_target.
11833 (_initialize_arm_linux_nat): Adjust to C++ification.
11834
11835 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
11836 (the_aarch64_linux_nat_target): New.
11837 (aarch64_linux_fetch_inferior_registers)
11838 (aarch64_linux_store_inferior_registers)
11839 (aarch64_linux_child_post_startup_inferior)
11840 (aarch64_linux_read_description)
11841 (aarch64_linux_can_use_hw_breakpoint)
11842 (aarch64_linux_insert_hw_breakpoint)
11843 (aarch64_linux_remove_hw_breakpoint)
11844 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
11845 (aarch64_linux_region_ok_for_hw_watchpoint)
11846 (aarch64_linux_stopped_data_address)
11847 (aarch64_linux_stopped_by_watchpoint)
11848 (aarch64_linux_watchpoint_addr_within_range)
11849 (aarch64_linux_can_do_single_step): Refactor as methods of
11850 aarch64_linux_nat_target.
11851 (super_post_startup_inferior): Delete.
11852 (_initialize_aarch64_linux_nat): Adjust to C++ification.
11853
11854 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
11855 (the_hppa_linux_nat_target): New.
11856 (hppa_linux_fetch_inferior_registers)
11857 (hppa_linux_store_inferior_registers): Refactor as methods of
11858 hppa_linux_nat_target.
11859 (_initialize_hppa_linux_nat): Adjust to C++ification.
11860
11861 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
11862 (the_ia64_linux_nat_target): New.
11863 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
11864 (ia64_linux_stopped_data_address)
11865 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
11866 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
11867 ia64_linux_nat_target methods.
11868 (super_xfer_partial): Delete.
11869 (_initialize_ia64_linux_nat): Adjust to C++ification.
11870
11871 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
11872 (the_m32r_linux_nat_target): New.
11873 (m32r_linux_fetch_inferior_registers)
11874 (m32r_linux_store_inferior_registers): Refactor as
11875 m32r_linux_nat_target methods.
11876 (_initialize_m32r_linux_nat): Adjust to C++ification.
11877
11878 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
11879 (the_m68k_linux_nat_target): New.
11880 (m68k_linux_fetch_inferior_registers)
11881 (m68k_linux_store_inferior_registers): Refactor as
11882 m68k_linux_nat_target methods.
11883 (_initialize_m68k_linux_nat): Adjust to C++ification.
11884
11885 * s390-linux-nat.c (s390_linux_nat_target): New class.
11886 (the_s390_linux_nat_target): New.
11887 (s390_linux_fetch_inferior_registers)
11888 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
11889 (s390_insert_watchpoint, s390_remove_watchpoint)
11890 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
11891 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
11892 (s390_auxv_parse, s390_read_description): Refactor as methods of
11893 s390_linux_nat_target.
11894 (_initialize_s390_nat): Adjust to C++ification.
11895
11896 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
11897 (the_sparc_linux_nat_target): New.
11898 (_initialize_sparc_linux_nat): Adjust to C++ification.
11899 * sparc-nat.c (sparc_fetch_inferior_registers)
11900 (sparc_store_inferior_registers): Remove target_ops parameter.
11901 * sparc-nat.h (sparc_fetch_inferior_registers)
11902 (sparc_store_inferior_registers): Remove target_ops parameter.
11903 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
11904 (the_sparc64_linux_nat_target): New.
11905 (_initialize_sparc64_linux_nat): Adjust to C++ification.
11906
11907 * spu-linux-nat.c (spu_linux_nat_target): New class.
11908 (the_spu_linux_nat_target): New.
11909 (spu_child_post_startup_inferior, spu_child_post_attach)
11910 (spu_child_wait, spu_fetch_inferior_registers)
11911 (spu_store_inferior_registers, spu_xfer_partial)
11912 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
11913 methods.
11914 (_initialize_spu_nat): Adjust to C++ification.
11915
11916 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
11917 (the_tilegx_linux_nat_target): New.
11918 (fetch_inferior_registers, store_inferior_registers):
11919 Refactor as methods.
11920 (_initialize_tile_linux_nat): Adjust to C++ification.
11921
11922 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
11923 (the_xtensa_linux_nat_target): New.
11924 (xtensa_linux_fetch_inferior_registers)
11925 (xtensa_linux_store_inferior_registers): Refactor as
11926 xtensa_linux_nat_target methods.
11927 (_initialize_xtensa_linux_nat): Adjust to C++ification.
11928
11929 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
11930 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
11931 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
11932 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
11933 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
11934 (fbsd_stopped_by_sw_breakpoint)
11935 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
11936 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
11937 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
11938 (fbsd_post_startup_inferior, fbsd_post_attach)
11939 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
11940 (fbsd_set_syscall_catchpoint)
11941 (super_xfer_partial, super_resume, super_wait)
11942 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
11943 (fbsd_handle_debug_trap): Remove target_ops parameter.
11944 (fbsd_nat_add_target): Delete.
11945 * fbsd-nat.h: Include "inf-ptrace.h".
11946 (fbsd_nat_add_target): Delete.
11947 (USE_SIGTRAP_SIGINFO): Define.
11948 (fbsd_nat_target): New class.
11949
11950 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
11951 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
11952 (amd64bsd_target): Delete.
11953 * amd64-bsd-nat.h: New file.
11954 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
11955 "x86-bsd-nat.h".
11956 (amd64_fbsd_nat_target): New class.
11957 (the_amd64_fbsd_nat_target): New.
11958 (amd64fbsd_read_description): Refactor as method of
11959 amd64_fbsd_nat_target.
11960 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11961 (_initialize_amd64fbsd_nat): Adjust to C++ification.
11962 * amd64-nat.h (amd64bsd_target): Delete function declaration.
11963 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
11964 (i386bsd_store_inferior_registers): Remove target_ops parameter.
11965 (i386bsd_target): Delete.
11966 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
11967 (i386bsd_fetch_inferior_registers)
11968 (i386bsd_store_inferior_registers): Declare.
11969 (i386_bsd_nat_target): New class.
11970 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
11971 (the_i386_fbsd_nat_target): New.
11972 (i386fbsd_resume, i386fbsd_read_description): Refactor as
11973 i386_fbsd_nat_target methods.
11974 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11975 (_initialize_i386fbsd_nat): Adjust to C++ification.
11976 * x86-bsd-nat.c (super_mourn_inferior): Delete.
11977 (x86bsd_mourn_inferior, x86bsd_target): Delete.
11978 (_initialize_x86_bsd_nat): Adjust to C++ification.
11979 * x86-bsd-nat.h: Include "x86-nat.h".
11980 (x86bsd_target): Delete declaration.
11981 (x86bsd_nat_target): New class.
11982
11983 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
11984 (the_aarch64_fbsd_nat_target): New.
11985 (aarch64_fbsd_fetch_inferior_registers)
11986 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
11987 aarch64_fbsd_nat_target.
11988 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
11989 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
11990 (the_alpha_bsd_nat_target): New.
11991 (alphabsd_fetch_inferior_registers)
11992 (alphabsd_store_inferior_registers): Refactor as
11993 alpha_bsd_nat_target methods.
11994 (_initialize_alphabsd_nat): Refactor as methods of
11995 alpha_bsd_nat_target.
11996 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
11997 (the_amd64_nbsd_nat_target): New.
11998 (_initialize_amd64nbsd_nat): Adjust to C++ification.
11999 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
12000 (the_amd64_obsd_nat_target): New.
12001 (_initialize_amd64obsd_nat): Adjust to C++ification.
12002 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
12003 (the_arm_fbsd_nat_target): New.
12004 (arm_fbsd_fetch_inferior_registers)
12005 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
12006 (_initialize_arm_fbsd_nat): Refactor as methods of
12007 arm_fbsd_nat_target.
12008 (_initialize_arm_fbsd_nat): Adjust to C++ification.
12009 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
12010 (the_arm_netbsd_nat_target): New.
12011 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
12012 arm_netbsd_nat_target.
12013 (_initialize_arm_netbsd_nat): Adjust to C++ification.
12014 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
12015 (the_hppa_nbsd_nat_target): New.
12016 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
12017 hppa_nbsd_nat_target methods.
12018 (_initialize_hppanbsd_nat): Adjust to C++ification.
12019 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
12020 (the_hppa_obsd_nat_target): New.
12021 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
12022 methods of hppa_obsd_nat_target.
12023 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
12024 add_target.
12025 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
12026 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
12027 add_target.
12028 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
12029 (_initialize_i386obsd_nat): Use add_target.
12030 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
12031 (the_m68k_bsd_nat_target): New.
12032 (m68kbsd_fetch_inferior_registers)
12033 (m68kbsd_store_inferior_registers): Refactor as methods of
12034 m68k_bsd_nat_target.
12035 (_initialize_m68kbsd_nat): Adjust to C++ification.
12036 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
12037 (the_mips_fbsd_nat_target): New.
12038 (mips_fbsd_fetch_inferior_registers)
12039 (mips_fbsd_store_inferior_registers): Refactor as methods of
12040 mips_fbsd_nat_target.
12041 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
12042 add_target.
12043 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
12044 (the_mips_nbsd_nat_target): New.
12045 (mipsnbsd_fetch_inferior_registers)
12046 (mipsnbsd_store_inferior_registers): Refactor as methods of
12047 mips_nbsd_nat_target.
12048 (_initialize_mipsnbsd_nat): Adjust to C++ification.
12049 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
12050 (the_mips64_obsd_nat_target): New.
12051 (mips64obsd_fetch_inferior_registers)
12052 (mips64obsd_store_inferior_registers): Refactor as methods of
12053 mips64_obsd_nat_target.
12054 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
12055 add_target.
12056 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
12057 nbsd_nat_target.
12058 * nbsd-nat.h: Include "inf-ptrace.h".
12059 (nbsd_nat_target): New class.
12060 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
12061 (obsd_wait): Refactor as methods of obsd_nat_target.
12062 (obsd_add_target): Delete.
12063 * obsd-nat.h: Include "inf-ptrace.h".
12064 (obsd_nat_target): New class.
12065 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
12066 (the_ppc_fbsd_nat_target): New.
12067 (ppcfbsd_fetch_inferior_registers)
12068 (ppcfbsd_store_inferior_registers): Refactor as methods of
12069 ppc_fbsd_nat_target.
12070 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
12071 add_target.
12072 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
12073 (the_ppc_nbsd_nat_target): New.
12074 (ppcnbsd_fetch_inferior_registers)
12075 (ppcnbsd_store_inferior_registers): Refactor as methods of
12076 ppc_nbsd_nat_target.
12077 (_initialize_ppcnbsd_nat): Adjust to C++ification.
12078 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
12079 (the_ppc_obsd_nat_target): New.
12080 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
12081 methods of ppc_obsd_nat_target.
12082 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
12083 add_target.
12084 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
12085 (the_sh_nbsd_nat_target): New.
12086 (shnbsd_fetch_inferior_registers)
12087 (shnbsd_store_inferior_registers): Refactor as methods of
12088 sh_nbsd_nat_target.
12089 (_initialize_shnbsd_nat): Adjust to C++ification.
12090 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
12091 (inf_ptrace_xfer_partial): Delete.
12092 (sparc_xfer_partial, sparc_target): Delete.
12093 * sparc-nat.h (sparc_fetch_inferior_registers)
12094 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
12095 (sparc_target): Delete function declaration.
12096 (sparc_target): New template class.
12097 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
12098 (_initialize_sparcnbsd_nat): Adjust to C++ification.
12099 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
12100 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
12101 add_target.
12102 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
12103 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
12104 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
12105 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
12106 add_target.
12107 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
12108 (the_vax_bsd_nat_target): New.
12109 (vaxbsd_fetch_inferior_registers)
12110 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
12111 methods.
12112 (_initialize_vaxbsd_nat): Adjust to C++ification.
12113
12114 * bsd-kvm.c (bsd_kvm_target): New class.
12115 (bsd_kvm_ops): Now a bsd_kvm_target.
12116 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
12117 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
12118 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
12119 bsd_kvm_target.
12120 (bsd_kvm_return_one): Delete.
12121 (bsd_kvm_add_target): Adjust to C++ification.
12122
12123 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
12124 (nto_procfs_target_procfs): New classes.
12125 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
12126 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
12127 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
12128 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
12129 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
12130 (procfs_remove_hw_breakpoint, procfs_resume)
12131 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
12132 (procfs_kill_inferior, procfs_store_registers)
12133 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
12134 as methods of nto_procfs_target.
12135 (nto_procfs_ops): Now an nto_procfs_target_procfs.
12136 (nto_native_ops): Delete.
12137 (procfs_open, procfs_native_open): Delete.
12138 (nto_native_ops): Now an nto_procfs_target_native.
12139 (init_procfs_targets): Adjust to C++ification.
12140 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
12141 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
12142 Refactor as methods of nto_procfs_target.
12143
12144 * go32-nat.c (go32_nat_target): New class.
12145 (the_go32_nat_target): New.
12146 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
12147 (go32_store_registers, go32_xfer_partial, go32_files_info)
12148 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
12149 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
12150 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
12151 (go32_pid_to_str): Refactor as methods of go32_nat_target.
12152 (go32_target): Delete.
12153 (_initialize_go32_nat): Adjust to C++ification.
12154
12155 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
12156 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
12157 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
12158 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
12159 gnu_nat_target.
12160 (gnu_target): Delete.
12161 * gnu-nat.h (gnu_target): Delete.
12162 (gnu_nat_target): New class.
12163 * i386-gnu-nat.c (gnu_base_target): New.
12164 (i386_gnu_nat_target): New class.
12165 (the_i386_gnu_nat_target): New.
12166 (_initialize_i386gnu_nat): Adjust to C++ification.
12167
12168 2018-05-02 Pedro Alves <palves@redhat.com>
12169
12170 * bfd-target.c (target_bfd_xclose): Rename to ...
12171 (target_bfd_close): ... this.
12172 (target_bfd_reopen): Adjust.
12173 * target.c (target_close): Remove references to to_xclose.
12174 * target.h (target_ops::to_xclose): Delete.
12175 (target_ops::to_close): Update comments.
12176
12177 2018-05-02 Pedro Alves <palves@redhat.com>
12178
12179 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
12180 "linux-nat.h".
12181 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
12182 * inf-ptrace.c (inf_ptrace_register_u_offset)
12183 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
12184 (inf_ptrace_store_register, inf_ptrace_store_registers)
12185 (inf_ptrace_trad_target): Move to ...
12186 * linux-nat-trad.c: ... this new file.
12187 * linux-nat-trad.h: New file.
12188 * linux-nat.c (linux_target_install_ops): Make extern.
12189 (linux_trad_target): Delete.
12190 * linux-nat.h (linux_trad_target): Delete declaration.
12191 (linux_target_install_ops): Declare.
12192 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
12193 "linux-nat.h".
12194
12195 2018-05-02 Pedro Alves <palves@redhat.com>
12196
12197 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
12198 procfs_target/add_target here.
12199 * procfs.c (procfs_target): Make static.
12200 (_initialize_procfs): Call add_target here.
12201 * procfs.h (struct target_ops): Remove forward declaration.
12202 (procfs_target): Remove declaration.
12203 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
12204
12205 2018-05-02 Pedro Alves <palves@redhat.com>
12206
12207 * procfs.c (procfs_stopped_by_watchpoint)
12208 (procfs_insert_watchpoint, procfs_remove_watchpoint)
12209 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
12210 Forward declare.
12211 (procfs_use_watchpoints): Delete, move contents...
12212 (procfs_target): ... here.
12213 * procfs.h (procfs_use_watchpoints): Delete declaration.
12214 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
12215 procfs_use_watchpoints.
12216 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
12217 procfs_use_watchpoints.
12218
12219 2018-05-02 Tom Tromey <tom@tromey.com>
12220
12221 PR python/20084:
12222 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
12223 and var_zuinteger_unlimited.
12224 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
12225 and PARAM_ZUINTEGER_UNLIMITED.
12226 (set_parameter_value): Handle var_zuinteger and
12227 var_zuinteger_unlimited.
12228 (add_setshow_generic): Likewise.
12229 (parmpy_init): Likewise.
12230
12231 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
12232
12233 PR rust/23124
12234 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
12235 pointer is not null before dereferencing it.
12236
12237 2018-04-30 Tom Tromey <tom@tromey.com>
12238
12239 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
12240 is_mi_like_p.
12241
12242 2018-04-30 Tom Tromey <tom@tromey.com>
12243
12244 * breakpoint.c (mention): Remove use of is_mi_like_p.
12245 (print_mention_ranged_breakpoint): Likewise.
12246 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
12247 of is_mi_like_p.
12248
12249 2018-04-30 Tom Tromey <tom@tromey.com>
12250
12251 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
12252
12253 2018-04-30 Tom Tromey <tom@tromey.com>
12254
12255 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
12256 (info_spu_event_command): Remove some uses of is_mi_like_p.
12257
12258 2018-04-30 Tom Tromey <tom@tromey.com>
12259
12260 * python/py-framefilter.c (py_print_single_arg)
12261 (enumerate_locals, py_print_args, py_print_frame): Remove some
12262 uses of is_mi_like_p.
12263
12264 2018-04-30 Tom Tromey <tom@tromey.com>
12265
12266 * ui-out.c: Update.
12267 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
12268 * ui-out.h (ui_out::is_mi_like_p): Now const.
12269 (ui_out::do_is_mi_like_p): Now const.
12270 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
12271
12272 2018-04-30 Tom Tromey <tom@tromey.com>
12273
12274 * varobj.c (varobj_set_visualizer): Use new_reference.
12275 * python/python.c (gdbpy_decode_line): Use new_reference.
12276 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
12277 new_reference.
12278
12279 2018-04-30 Tom Tromey <tom@tromey.com>
12280
12281 * varobj.c (install_new_value): Use new_reference.
12282 * value.h (value_incref): Return void. Swap intro comment with
12283 value_decref.
12284 * value.c (set_value_parent): Use new_reference.
12285 (value_incref): Return void. Update intro comment.
12286 (release_value): Use new_reference.
12287 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
12288
12289 2018-04-30 Tom Tromey <tom@tromey.com>
12290
12291 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
12292 * gdb_bfd.h (new_bfd_ref): Remove.
12293 (gdb_bfd_open): Update comment.
12294 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
12295 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
12296 (gdb_bfd_fdopenr): Use new_reference.
12297 * exec.c (exec_file_attach): Use new_reference.
12298
12299 2018-04-30 Tom Tromey <tom@tromey.com>
12300
12301 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
12302 method.
12303
12304 2018-04-30 Tom Tromey <tom@tromey.com>
12305
12306 * jit.c (jit_read_code_entry): Use type_align.
12307 * i386-tdep.c (i386_gdbarch_init): Don't call
12308 set_gdbarch_long_long_align_bit.
12309 * gdbarch.sh: Remove long_long_align_bit.
12310 * gdbarch.c, gdbarch.h: Rebuild.
12311 * arc-tdep.c (arc_type_align): New function.
12312 (arc_gdbarch_init): Use arc_type_align. Don't call
12313 set_gdbarch_long_long_align_bit.
12314
12315 2018-04-30 Tom Tromey <tom@tromey.com>
12316
12317 * rust-lang.c (rust_type_alignment): Remove.
12318 (rust_composite_type): Use type_align.
12319
12320 2018-04-30 Tom Tromey <tom@tromey.com>
12321
12322 * NEWS: Mention Type.align.
12323 * python/py-type.c (typy_get_alignof): New function.
12324 (type_object_getset): Add "alignof".
12325
12326 2018-04-30 Tom Tromey <tom@tromey.com>
12327
12328 PR exp/17095:
12329 * NEWS: Update.
12330 * std-operator.def (UNOP_ALIGNOF): New operator.
12331 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
12332 New.
12333 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
12334 * c-lang.c (c_op_print_tab): Add alignof.
12335 * c-exp.y (ALIGNOF): New token.
12336 (exp): Add "ALIGNOF" production.
12337 (ident_tokens): Add _Alignof and alignof.
12338
12339 2018-04-30 Tom Tromey <tom@tromey.com>
12340
12341 * i386-tdep.c (i386_type_align): New function.
12342 (i386_gdbarch_init): Update.
12343 * gdbarch.sh (type_align): New method.
12344 * gdbarch.c, gdbarch.h: Rebuild.
12345 * arch-utils.h (default_type_align): Declare.
12346 * arch-utils.c (default_type_align): New function.
12347 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
12348 (struct type) <align_log2>: New field.
12349 <instance_flags>: Now a bitfield.
12350 (TYPE_RAW_ALIGN): New macro.
12351 (type_align, type_raw_align, set_type_align): Declare.
12352 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
12353 functions.
12354 * dwarf2read.c (quirk_rust_enum): Set type alignment.
12355 (get_alignment, maybe_set_alignment): New functions.
12356 (read_structure_type, read_enumeration_type, read_array_type)
12357 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
12358 (read_subrange_type, read_base_type): Set type alignment.
12359
12360 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
12361
12362 * dwarf2read.c (read_index_from_section): Use bool.
12363
12364 2018-04-29 Fabian Groffen <grobian@gentoo.org>
12365
12366 PR gdb/22950
12367 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
12368 with #ifdef.
12369
12370 2018-04-29 John Reiser <jreiser@BitWagon.com>
12371
12372 PR build/22873
12373 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
12374 last step, and do it atomically.
12375
12376 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
12377
12378 * compile/compile-c-types.c (convert_int, convert_float):
12379 Update for C FE v1.
12380
12381 2018-04-27 Tom Tromey <tom@tromey.com>
12382
12383 PR rust/22545:
12384 * rust-lang.c (rust_inclusive_range_type_p): New function.
12385 (rust_range): Handle inclusive ranges.
12386 (rust_compute_range): Likewise.
12387 * rust-exp.y (struct rust_op) <inclusive>: New field.
12388 (DOTDOTEQ): New constant.
12389 (range_expr): Add "..=" productions.
12390 (operator_tokens): Add "..=" token.
12391 (ast_range): Add "inclusive" parameter.
12392 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
12393 ranges.
12394 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
12395 bounds values.
12396 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
12397 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
12398 Update comments.
12399 * expprint.c (print_subexp_standard): Handle new bounds values.
12400 (dump_subexp_body_standard): Likewise.
12401
12402 2018-04-27 Tom Tromey <tom@tromey.com>
12403
12404 * configure: Rebuild.
12405 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
12406 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
12407 "OVERRIDE".
12408 (class symbol_needs_eval_context): Likewise.
12409 * dwarf2read.c (mock_mapped_index::symbol_name_count)
12410 (mock_mapped_index::symbol_name_at): Use "override". Remove
12411 "virtual".
12412 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
12413 "override".
12414 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
12415 * aarch64-tdep.c (instruction_reader::read): Use "override".
12416 (instruction_reader_test::read): Likewise.
12417 * arm-tdep.c (instruction_reader::read): Use "override".
12418 (instruction_reader_thumb::read): Likewise.
12419
12420 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
12421
12422 PR remote/9665
12423 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
12424 instead of remote_send.
12425 (remote_send): Remove.
12426
12427 2018-04-26 Pedro Alves <palves@redhat.com>
12428
12429 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
12430 find_function_start_sal instead of find_pc_line.
12431
12432 2018-04-26 Pedro Alves <palves@redhat.com>
12433
12434 * breakpoint.c (set_breakpoint_location_function): Handle
12435 mst_data_gnu_ifunc.
12436 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
12437 * elfread.c (elf_symtab_read): Give data symbols with
12438 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
12439 (elf_rel_plt_read): Update comment.
12440 * linespec.c (convert_linespec_to_sals): Handle
12441 mst_data_gnu_ifunc.
12442 (minsym_found): Handle mst_data_gnu_ifunc.
12443 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
12444 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
12445 * parse.c (find_minsym_type_and_address): Handle
12446 mst_data_gnu_ifunc.
12447 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
12448 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
12449 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
12450 comment.
12451 <mst_data_gnu_ifunc>: New enumerator.
12452
12453 2018-04-26 Pedro Alves <palves@redhat.com>
12454
12455 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
12456 (lookup_minimal_symbol_by_pc_section): ... this. Replace
12457 'want_trampoline' parameter by a lookup_msym_prefer parameter.
12458 Handle it.
12459 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
12460 (lookup_minimal_symbol_by_pc): Adjust.
12461 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
12462 (lookup_solib_trampoline_symbol_by_pc): Adjust.
12463 * minsyms.h (lookup_msym_prefer): New enum.
12464 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12465 parameter by a lookup_msym_prefer parameter.
12466
12467 2018-04-26 Pedro Alves <palves@redhat.com>
12468
12469 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
12470 ends in "@plt" instead of looking at the symbol's section.
12471
12472 2018-04-26 Pedro Alves <palves@redhat.com>
12473
12474 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
12475 all references.
12476 (find_pc_partial_function_gnu_ifunc): Rename to ...
12477 (find_pc_partial_function): ... this, and remove references to
12478 'is_gnu_ifunc_p'.
12479 (find_pc_partial_function): Delete old implementation.
12480 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
12481
12482 2018-04-26 Pedro Alves <palves@redhat.com>
12483
12484 * linespec.c (struct bound_minimal_symbol_search_key): New.
12485 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
12486 skip first line if we found a GNU ifunc minimal symbol by name.
12487 (compare_msymbols): Change parameters to work with a destructured
12488 lhs minsym.
12489 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
12490 functions.
12491
12492 2018-04-26 Pedro Alves <palves@redhat.com>
12493
12494 * breakpoint.c (set_breakpoint_location_function): Don't resolve
12495 ifunc targets here. Instead, if we have an ifunc minsym, use its
12496 address/name.
12497 (add_location_to_breakpoint): Store the minsym and the objfile in
12498 the breakpoint location.
12499 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
12500 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
12501 Record the minsym in the sal.
12502 * symtab.h (symtab_and_line) <msymbol>: New field.
12503
12504 2018-04-26 Pedro Alves <palves@redhat.com>
12505
12506 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
12507 unless we actually resolved the ifunc.
12508
12509 2018-04-26 Pedro Alves <palves@redhat.com>
12510
12511 * c-exp.y (variable production): Prefer ifunc minsyms over
12512 regular function symbols.
12513 * symtab.c (find_gnu_ifunc): New function.
12514 * minsyms.h (lookup_msym_prefer): New enum.
12515 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12516 parameter by a lookup_msym_prefer parameter.
12517 * symtab.h (find_gnu_ifunc): New declaration.
12518
12519 2018-04-26 Pedro Alves <palves@redhat.com>
12520
12521 * blockframe.c (find_gnu_ifunc_target_type): New function.
12522 (find_function_type): New.
12523 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
12524 return a value with a memory address.
12525 (eval_call): For calls to GNU ifunc functions, try to find the
12526 type of the target function from the type that the resolver
12527 returns.
12528 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
12529 symbols.
12530 * infcall.c (find_function_return_type): Delete.
12531 (find_function_addr): Add 'function_type' parameter. For calls to
12532 GNU ifunc functions, try to find the type of the target function
12533 from the type that the resolver returns, and return it via
12534 FUNCTION_TYPE.
12535 (call_function_by_hand_dummy): Adjust to use the function type
12536 returned by find_function_addr.
12537 (find_function_addr): Add 'function_type' parameter and move
12538 description here.
12539 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
12540 declarations.
12541
12542 2018-04-26 Pedro Alves <palves@redhat.com>
12543
12544 * c-exp.y (variable production): Skip finding an alias for ifunc
12545 symbols.
12546
12547 2018-04-26 Pedro Alves <palves@redhat.com>
12548
12549 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
12550
12551 2018-04-25 Pedro Alves <palves@redhat.com>
12552
12553 * infcmd.c (kill_command): Print the pid as string, not the whole
12554 thread's ptid. Add comment. s/has been killed/killed/ in output
12555 message.
12556 * remote.c (remote_detach_1): Print the pid as string, not the
12557 whole thread's ptid.
12558
12559 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12560 Sergio Durigan Junior <sergiodj@redhat.com>
12561 Pedro Alves <palves@redhat.com>
12562
12563 * infcmd.c (kill_command): Print message when inferior has
12564 been killed.
12565 * inferior.c (print_inferior_events): Remove 'static'. Set as
12566 '1'.
12567 (add_inferior): Improve message printed when
12568 'print_inferior_events' is on.
12569 (exit_inferior): Remove message printed when
12570 'print_inferior_events' is on.
12571 (detach_inferior): Improve message printed when
12572 'print_inferior_events' is on.
12573 (initialize_inferiors): Use 'add_inferior_silent' to set
12574 'current_inferior_'.
12575 * inferior.h (print_inferior_events): Declare here as
12576 'extern'.
12577 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
12578 '[Detaching...]' messages when 'print_inferior_events' is on.
12579 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
12580 as prefix/suffix for messages. Remove periods. Fix erroneous
12581 'Detaching after fork from child...', replace it by '... from
12582 parent...'.
12583 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
12584 prefix/suffix when printing 'Detaching...' messages. Print
12585 them when 'print_inferior_events' is on.
12586 * remote.c (remote_detach_1): Print message when detaching
12587 from inferior and '!is_fork_parent'.
12588
12589 2018-04-24 Tom Tromey <tom@tromey.com>
12590
12591 * cli-out.h: Reindent.
12592
12593 2018-04-24 Tom Tromey <tom@tromey.com>
12594
12595 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
12596 (cli_ui_out::do_field_string): Use fputs_filtered.
12597 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
12598
12599 2018-04-23 Tom Tromey <tom@tromey.com>
12600
12601 * guile/scm-frame.c (gdbscm_frame_read_var): Use
12602 gdb::unique_xmalloc_ptr.
12603
12604 2018-04-23 Tom Tromey <tom@tromey.com>
12605
12606 * configure: Rebuild.
12607
12608 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
12609
12610 PR gdb/23095
12611 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
12612 prepare_for_testing. Set normal_bp to r_debug_state if target
12613 is bsd.
12614
12615 2018-04-21 Pedro Alves <palves@redhat.com>
12616 Rajendra SY <rajendra.sy@gmail.com>
12617
12618 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
12619 * remote.c (extended_remote_attach): In all-stop mode, mark the
12620 thread as executing.
12621
12622 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12623
12624 * thread.c (thread_apply_all_command): Fix comment.
12625 (thread_command): Fix comment.
12626
12627 2018-04-10 Alan Hayward <alan.hayward@arm.com>
12628
12629 * common/tdesc.h (tdesc_create_feature): Remove xml filename
12630 parameter.
12631 * features/aarch64-core.c (create_feature_aarch64_core):
12632 Regenerate.
12633 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
12634 Likewise.
12635 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
12636 Likewise.
12637 * features/i386/32bit-avx512.c
12638 (create_feature_i386_32bit_avx512): Likewise.
12639 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
12640 Likewise.
12641 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
12642 Likewise.
12643 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
12644 Likewise.
12645 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
12646 Likewise.
12647 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
12648 Likewise.
12649 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
12650 Likewise.
12651 * features/i386/64bit-avx512.c
12652 (create_feature_i386_64bit_avx512): Likewise.
12653 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
12654 Likewise.
12655 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
12656 Likewise.
12657 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
12658 Likewise.
12659 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
12660 Likewise.
12661 * features/i386/64bit-segments.c
12662 (create_feature_i386_64bit_segments): Likewise.
12663 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
12664 Likewise.
12665 * features/i386/x32-core.c
12666 (create_feature_i386_x32_core): Likewise.
12667 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
12668 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
12669 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
12670 * target-descriptions.c: In generated code, don't pass xml
12671 filename.
12672
12673 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12674
12675 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
12676 (print_xml_feature::visit_post): Likewise.
12677 (print_xml_feature::visit): Likewise.
12678 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
12679 (print_xml_feature): Add new class.
12680 * regformats/regdat.sh: Null xmltarget on feature targets.
12681 * target-descriptions.c (struct target_desc): Add xmltarget.
12682 (maintenance_check_tdesc_xml_convert): Add unittest function.
12683 (tdesc_get_features_xml): Add function to get xml.
12684 (maintenance_check_xml_descriptions): Test xml generation.
12685 * xml-tdesc.c (string_read_description_xml): Add function.
12686 * xml-tdesc.h (string_read_description_xml): Add declaration.
12687
12688 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12689
12690 * features/Makefile: Add feature marker to targets with new style
12691 target descriptions.
12692 * regformats/aarch64.dat: Regenerate.
12693 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
12694 * regformats/i386/amd64-avx-linux.dat: Likewise.
12695 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
12696 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
12697 * regformats/i386/amd64-linux.dat: Likewise.
12698 * regformats/i386/amd64-mpx-linux.dat: Likewise.
12699 * regformats/i386/amd64.dat: Likewise.
12700 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
12701 * regformats/i386/i386-avx-linux.dat: Likewise.
12702 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
12703 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
12704 * regformats/i386/i386-linux.dat: Likewise.
12705 * regformats/i386/i386-mmx-linux.dat: Likewise.
12706 * regformats/i386/i386-mpx-linux.dat: Likewise.
12707 * regformats/i386/i386.dat: Likewise.
12708 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
12709 * regformats/i386/x32-avx-linux.dat: Likewise.
12710 * regformats/i386/x32-linux.dat: Likewise.
12711 * regformats/tic6x-c62x-linux.dat: Likewise.
12712 * regformats/tic6x-c64x-linux.dat: Likewise.
12713 * regformats/tic6x-c64xp-linux.dat: Likewise.
12714 * regformats/regdat.sh: Parse feature marker.
12715
12716 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12717
12718 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
12719 (tdesc_osabi_name): Likewise.
12720 * target-descriptions.c (tdesc_architecture_name): Add new
12721 function.
12722 (tdesc_osabi_name): Likewise.
12723
12724 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12725
12726 * common/tdesc.c (tdesc_predefined_type): Move to here.
12727 (tdesc_named_type): Likewise.
12728 (tdesc_create_vector): Likewise.
12729 (tdesc_create_struct): Likewise.
12730 (tdesc_set_struct_size): Likewise.
12731 (tdesc_create_union): Likewise.
12732 (tdesc_create_flags): Likewise.
12733 (tdesc_create_enum): Likewise.
12734 (tdesc_add_field): Likewise.
12735 (tdesc_add_typed_bitfield): Likewise.
12736 (tdesc_add_bitfield): Likewise.
12737 (tdesc_add_flag): Likewise.
12738 (tdesc_add_enum_value): Likewise.
12739 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
12740 (struct tdesc_type_vector): Likewise.
12741 (struct tdesc_type_field): Likewise.
12742 (struct tdesc_type_with_fields): Likewise.
12743 (tdesc_create_enum): Add declaration.
12744 (tdesc_add_typed_bitfield): Likewise.
12745 (tdesc_add_enum_value): Likewise.
12746 * target-descriptions.c (tdesc_type_field): Move from here.
12747 (tdesc_type_builtin): Likewise.
12748 (tdesc_type_vector): Likewise.
12749 (tdesc_type_with_fields): Likewise.
12750 (tdesc_predefined_types): Likewise.
12751 (tdesc_named_type): Likewise.
12752 (tdesc_create_vector): Likewise.
12753 (tdesc_create_struct): Likewise.
12754 (tdesc_set_struct_size): Likewise.
12755 (tdesc_create_union): Likewise.
12756 (tdesc_create_flags): Likewise.
12757 (tdesc_create_enum): Likewise.
12758 (tdesc_add_field): Likewise.
12759 (tdesc_add_typed_bitfield): Likewise.
12760 (tdesc_add_bitfield): Likewise.
12761 (tdesc_add_flag): Likewise.
12762 (tdesc_add_enum_value): Likewise.
12763 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
12764 (tdesc_add_typed_bitfield): Likewise.
12765 (tdesc_add_enum_value): Likewise.
12766
12767 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12768
12769 * common/tdesc.c (tdesc_feature::accept): Move to here.
12770 (tdesc_feature::operator==): Likewise.
12771 (tdesc_create_reg): Likewise.
12772 * common/tdesc.h (tdesc_type_kind): Likewise.
12773 (struct tdesc_type): Likewise.
12774 (struct tdesc_feature): Likewise.
12775 * regformats/regdat.sh: Create a feature.
12776 * target-descriptions.c (tdesc_type_kind): Move from here.
12777 (tdesc_type): Likewise.
12778 (tdesc_type_up): Likewise.
12779 (tdesc_feature): Likewise.
12780 (tdesc_create_reg): Likewise.
12781
12782 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12783
12784 * Makefile.in: Add arch/tdesc.c
12785 * common/tdesc.c: New file.
12786 * common/tdesc.h (tdesc_element_visitor): Move to here.
12787 (tdesc_element): Likewise.
12788 (tdesc_reg): Likewise.
12789 (tdesc_reg_up): Likewise.
12790 * regformats/regdef.h (reg): Add offset to constructors.
12791 * target-descriptions.c (tdesc_element_visitor): Move from here.
12792 (tdesc_element): Likewise.
12793 (tdesc_reg): Likewise.
12794 (tdesc_reg_up): Likewise.
12795
12796 2018-04-17 Tom Tromey <tom@tromey.com>
12797
12798 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
12799 discriminant field.
12800
12801 2018-04-17 Tom Tromey <tom@tromey.com>
12802
12803 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
12804
12805 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
12806
12807 * symtab.c (print_symbol_info): Skip printing filename and line
12808 number when `last' is NULL.
12809 (symtab_symbol_info): Use empty string instead of NULL for first
12810 invocation of print_symbol_info.
12811 (rbreak_command): Pass NULL to `last' parameter of
12812 print_symbol_info.
12813
12814 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
12815
12816 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
12817 instead of nullptr.
12818
12819 2018-04-16 Pedro Alves <palves@redhat.com>
12820
12821 * MAINTAINERS (sh): Remove.
12822 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
12823 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
12824 (ALLDEPFILES): Remove sh64-tdep.c.
12825 * NEWS: Mentions that support for SH-5/SH64 is removed.
12826 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
12827 (sh*-*-openbsd*): Ditto.
12828 (sh64-*-elf*): Remove.
12829 (sh*): Remove.
12830 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
12831 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
12832 * sh-tdep.c: No longer include "sh64-tdep.h".
12833 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
12834 * sh64-tdep.c, sh64-tdep.h: Remove files.
12835
12836 2018-04-16 Pedro Alves <palves@redhat.com>
12837
12838 * MAINTAINERS: Remove m88k.
12839 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
12840 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
12841 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
12842 * NEWS: Mention that support for m88k was removed.
12843 * configure.host (m88*-*-*): Remove support.
12844 * configure.nat (m88k-*-*): Remove support.
12845 * configure.tgt (m88*-*-openbsd*): Remove.
12846 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
12847
12848 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
12849
12850 * configure.tgt (x86_tobjs): New variable.
12851 (amd64_tobjs, i386_tobjs): Use it.
12852
12853 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12854
12855 * symtab.c (print_symbol_info): Precede the symbol definition by
12856 the line number when available.
12857 * NEWS: Advertise this enhancement.
12858
12859 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12860
12861 * NEWS (New options): announce set/show record btrace cpu.
12862 * btrace.c: Include record-btrace.h.
12863 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
12864 the vendor is unknown.
12865 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
12866 Maybe overwrite the btrace configuration's cpu.
12867 (btrace_compute_ftrace): Add cpu parameter. Update callers.
12868 (btrace_fetch): Add cpu parameter. Update callers.
12869 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
12870 Maybe overwrite the btrace configuration's cpu. Skip enabling
12871 errata workarounds if the vendor is unknown.
12872 * python/py-record-btrace.c: Include record-btrace.h.
12873 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
12874 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
12875 * record-btrace.c (record_btrace_cpu_state_kind): New.
12876 (record_btrace_cpu): New.
12877 (set_record_btrace_cpu_cmdlist): New.
12878 (record_btrace_get_cpu): New.
12879 (require_btrace_thread, record_btrace_info)
12880 (record_btrace_resume_thread): Call record_btrace_get_cpu.
12881 (cmd_set_record_btrace_cpu_none): New.
12882 (cmd_set_record_btrace_cpu_auto): New.
12883 (cmd_set_record_btrace_cpu): New.
12884 (cmd_show_record_btrace_cpu): New.
12885 (_initialize_record_btrace): Initialize set/show record btrace cpu
12886 commands.
12887 * record-btrace.h (record_btrace_get_cpu): New.
12888
12889 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12890
12891 * record.c (set_record_command): Fix typo in message.
12892
12893 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12894
12895 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
12896
12897 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12898
12899 * infrun.c (process_event_stop_test): Call
12900 gdbarch_in_indirect_branch_thunk.
12901 * gdbarch.sh (in_indirect_branch_thunk): New.
12902 * gdbarch.c: Regenerated.
12903 * gdbarch.h: Regenerated.
12904 * x86-tdep.h: New.
12905 * x86-tdep.c: New.
12906 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
12907 (HFILES_NO_SRCDIR): Add x86-tdep.h.
12908 (ALLDEPFILES): Add x86-tdep.c.
12909 * arch-utils.h (default_in_indirect_branch_thunk): New.
12910 * arch-utils.c (default_in_indirect_branch_thunk): New.
12911 * i386-tdep: Include x86-tdep.h.
12912 (i386_in_indirect_branch_thunk): New.
12913 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
12914 function.
12915 * amd64-tdep: Include x86-tdep.h.
12916 (amd64_in_indirect_branch_thunk): New.
12917 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
12918
12919 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12920
12921 PR gdb/23053
12922 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
12923 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
12924 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
12925 regression.
12926
12927 2018-04-12 Tom Tromey <tom@tromey.com>
12928
12929 * rust-lang.c (rust_print_struct_def): Remove univariant code.
12930 (rust_evaluate_subexp): Likewise.
12931
12932 2018-04-12 Pedro Alves <palves@redhat.com>
12933
12934 * procfs.c (procfs_detach): Make forward declaration's prototype
12935 match definition's protototype.
12936 (proc_get_LDT_entry): Remove stale do_cleanups call.
12937
12938 2018-04-12 Pedro Alves <palves@redhat.com>
12939
12940 * target.h (target_ops::to_has_exited): Delete.
12941 (target_has_exited): Delete.
12942 * target-delegates.c: Regenerate.
12943
12944 2018-04-11 Pedro Alves <palves@redhat.com>
12945
12946 * target.c (fileio_fh_t::t): Add comment.
12947 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12948 (target_fileio_close): Handle a NULL target.
12949 (invalidate_fileio_fh): New.
12950 (target_close): Call it.
12951 * remote.c (remote_hostio_send_command): No longer check whether
12952 remote_desc is open.
12953
12954 2018-04-11 Pedro Alves <palves@redhat.com>
12955
12956 * target.c (fileio_fh_t): Make it a named struct instead of a
12957 typedef.
12958 (fileio_fh_t::is_closed): New method.
12959 (DEF_VEC_O (fileio_fh_t)): Remove.
12960 (fileio_fhandles): Now a std::vector.
12961 (is_closed_fileio_fh): Delete.
12962 (acquire_fileio_fd): Adjust. Rename parameters.
12963 (release_fileio_fd): Adjust.
12964 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
12965 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12966 (target_fileio_close): Adjust.
12967
12968 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
12969
12970 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
12971 index.
12972
12973 2018-04-10 Pedro Alves <palves@redhat.com>
12974
12975 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
12976 (scoped_finish_thread_state): New class.
12977 * infcmd.c (run_command_1): Use it instead of finish_thread_state
12978 cleanup.
12979 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
12980 (fetch_inferior_event, normal_stop): Likewise.
12981 * thread.c (finish_thread_state_cleanup): Delete.
12982
12983 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12984 Pedro Alves <palves@redhat.com>
12985
12986 * value.c: Include "selftest.h" and "common/array-view.h".
12987 (struct range) <operator ==>: New.
12988 (test_ranges_contain): New.
12989 (check_ranges_vector): New.
12990 (test_insert_into_bit_range_vector): New.
12991 (_initialize_values): Register selftests.
12992 * common/array-view.h (operator==, operator!=): New.
12993
12994 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12995
12996 * common/gdb_vecs.h (unordered_remove): Add overload that takes
12997 an iterator.
12998 * inline-frame.c: Include <algorithm>.
12999 (struct inline_state): Add constructor.
13000 (inline_state_s): Remove.
13001 (DEF_VEC_O(inline_state_s)): Remove.
13002 (inline_states): Change type to std::vector.
13003 (find_inline_frame_state): Adjust to std::vector.
13004 (allocate_inline_frame_state): Remove.
13005 (clear_inline_frame_state): Adjust to std::vector.
13006 (skip_inline_frames): Adjust to std::vector.
13007
13008 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13009
13010 * tracepoint.h (struct trace_state_variable): Add constructor.
13011 <name>: Change type to std::string.
13012 * tracepoint.c (tsv_s): Remove.
13013 (DEF_VEC_O(tsv_s)): Remove.
13014 (tvariables): Change to std::vector.
13015 (create_trace_state_variable): Adjust to std::vector.
13016 (find_trace_state_variable): Likewise.
13017 (find_trace_state_variable_by_number): Likewise.
13018 (delete_trace_state_variable): Likewise.
13019 (trace_variable_command): Adjust to std::string.
13020 (delete_trace_variable_command): Likewise.
13021 (tvariables_info_1): Adjust to std::vector.
13022 (save_trace_state_variables): Likewise.
13023 (start_tracing): Likewise.
13024 (merge_uploaded_trace_state_variables): Adjust to std::vector
13025 and std::string.
13026 * target.h (struct target_ops)
13027 <to_download_trace_state_variable>: Pass reference to
13028 trace_state_variable.
13029 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
13030 * target-delegates.c: Re-generate.
13031 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
13032 (mi_tsv_deleted): Likewise.
13033 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
13034 * remote.c (remote_download_trace_state_variable): Change
13035 pointer to reference and adjust.
13036 * make-target-delegates (parse_argtypes): Handle references.
13037 (write_function_header): Likewise.
13038 (munge_type): Likewise.
13039
13040 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13041
13042 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13043 string_view-selftests.c.
13044 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
13045 testsuite.
13046 * unittests/basic_string_view/cons/char/1.cc: Likewise.
13047 * unittests/basic_string_view/cons/char/2.cc: Likewise.
13048 * unittests/basic_string_view/cons/char/3.cc: Likewise.
13049 * unittests/basic_string_view/element_access/char/1.cc:
13050 Likewise.
13051 * unittests/basic_string_view/element_access/char/empty.cc:
13052 Likewise.
13053 * unittests/basic_string_view/element_access/char/front_back.cc:
13054 Likewise.
13055 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
13056 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
13057 Likewise.
13058 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
13059 Likewise.
13060 * unittests/basic_string_view/modifiers/swap/char/1.cc:
13061 Likewise.
13062 * unittests/basic_string_view/operations/compare/char/1.cc:
13063 Likewise.
13064 * unittests/basic_string_view/operations/compare/char/13650.cc:
13065 Likewise.
13066 * unittests/basic_string_view/operations/copy/char/1.cc:
13067 Likewise.
13068 * unittests/basic_string_view/operations/data/char/1.cc:
13069 Likewise.
13070 * unittests/basic_string_view/operations/find/char/1.cc:
13071 Likewise.
13072 * unittests/basic_string_view/operations/find/char/2.cc:
13073 Likewise.
13074 * unittests/basic_string_view/operations/find/char/3.cc:
13075 Likewise.
13076 * unittests/basic_string_view/operations/find/char/4.cc:
13077 Likewise.
13078 * unittests/basic_string_view/operations/rfind/char/1.cc:
13079 Likewise.
13080 * unittests/basic_string_view/operations/rfind/char/2.cc:
13081 Likewise.
13082 * unittests/basic_string_view/operations/rfind/char/3.cc:
13083 Likewise.
13084 * unittests/basic_string_view/operations/substr/char/1.cc:
13085 Likewise.
13086 * unittests/basic_string_view/operators/char/2.cc: Likewise.
13087 * unittests/string_view-selftests.c: New file.
13088
13089 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13090
13091 * unittests/basic_string_view/capacity/1.cc: New file.
13092 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
13093 * unittests/basic_string_view/cons/char/1.cc: New file.
13094 * unittests/basic_string_view/cons/char/2.cc: New file.
13095 * unittests/basic_string_view/cons/char/3.cc: New file.
13096 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
13097 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
13098 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
13099 * unittests/basic_string_view/element_access/char/1.cc: New file.
13100 * unittests/basic_string_view/element_access/char/2.cc: New file.
13101 * unittests/basic_string_view/element_access/char/empty.cc: New file.
13102 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
13103 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
13104 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
13105 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
13106 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
13107 * unittests/basic_string_view/include.cc: New file.
13108 * unittests/basic_string_view/inserters/char/1.cc: New file.
13109 * unittests/basic_string_view/inserters/char/2.cc: New file.
13110 * unittests/basic_string_view/inserters/char/3.cc: New file.
13111 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
13112 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
13113 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
13114 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
13115 * unittests/basic_string_view/literals/types.cc: New file.
13116 * unittests/basic_string_view/literals/values.cc: New file.
13117 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
13118 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
13119 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
13120 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
13121 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
13122 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
13123 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
13124 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
13125 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
13126 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
13127 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
13128 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
13129 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
13130 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
13131 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
13132 * unittests/basic_string_view/operations/data/char/1.cc: New file.
13133 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
13134 * unittests/basic_string_view/operations/find/char/1.cc: New file.
13135 * unittests/basic_string_view/operations/find/char/2.cc: New file.
13136 * unittests/basic_string_view/operations/find/char/3.cc: New file.
13137 * unittests/basic_string_view/operations/find/char/4.cc: New file.
13138 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
13139 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
13140 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
13141 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
13142 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
13143 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
13144 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
13145 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
13146 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
13147 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
13148 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
13149 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
13150 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
13151 * unittests/basic_string_view/operators/char/2.cc: New file.
13152 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
13153 * unittests/basic_string_view/range_access/char/1.cc: New file.
13154 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
13155 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
13156 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
13157 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
13158 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
13159 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
13160 * unittests/basic_string_view/requirements/typedefs.cc: New file.
13161 * unittests/basic_string_view/typedefs.cc: New file.
13162 * unittests/basic_string_view/types/1.cc: New file.
13163
13164 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13165
13166 * common/gdb_string_view.h: Remove libstdc++ implementation
13167 details, adjust to gdb reality.
13168 * common/gdb_string_view.tcc: Likewise.
13169 * cli/cli-script.c (struct string_view): Remove.
13170 (user_args) <m_args>: Change element type to gdb::string_view.
13171 (user_args::insert_args): Adjust.
13172
13173 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13174
13175 * common/gdb_string_view.h: New file.
13176 * common/gdb_string_view.tcc: New file.
13177
13178 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13179
13180 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
13181 * configure: Re-generate.
13182
13183 2018-04-09 Pedro Alves <palves@redhat.com>
13184
13185 * gdbarch.sh: Include "observable.h" instead of "observer.h".
13186 (set_target_gdbarch): Call
13187 gdb::observers::architecture_changed.notify instead of
13188 observer_notify_architecture_changed.
13189
13190 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13191
13192 * tracepoint.c (struct current_traceframe_cleanup): Remove.
13193 (do_restore_current_traceframe_cleanup): Remove.
13194 (restore_current_traceframe_cleanup_dtor): Remove.
13195 (make_cleanup_restore_current_traceframe): Remove.
13196 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
13197 New.
13198 * tracepoint.h (struct scoped_restore_current_traceframe): New.
13199 * infrun.c (fetch_inferior_event): Use
13200 scoped_restore_current_traceframe.
13201
13202 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13203
13204 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
13205 Remove.
13206 <n_allocated_type_units>: Remove.
13207 <all_type_units>: Change to std::vector.
13208 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
13209 to std::vector change.
13210 (dwarf2_per_objfile::get_cutu): Likewise.
13211 (dwarf2_per_objfile::get_tu): Likewise.
13212 (create_signatured_type_table_from_index): Likewise.
13213 (create_signatured_type_table_from_debug_names): Likewise.
13214 (dw2_symtab_iter_next): Likewise.
13215 (dw2_print_stats): Likewise.
13216 (dw2_expand_all_symtabs): Likewise.
13217 (dw2_expand_marked_cus): Likewise.
13218 (dw2_debug_names_iterator::next): Likewise.
13219 (dwarf2_initialize_objfile): Likewise.
13220 (add_signatured_type_cu_to_table): Likewise.
13221 (create_all_type_units): Likewise.
13222 (add_type_unit): Likewise.
13223 (struct tu_abbrev_offset): Add constructor.
13224 (build_type_psymtabs_1): Adjust to std::vector change.
13225 (print_tu_stats): Likewise.
13226 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
13227 (write_debug_names): Likewise.
13228
13229 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13230
13231 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
13232 Make an std::vector.
13233 <n_comp_units>: Remove.
13234 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
13235 to std::vector change.
13236 (dwarf2_per_objfile::get_cutu): Likewise.
13237 (dwarf2_per_objfile::get_cu): Likewise.
13238 (create_cus_from_index): Likewise.
13239 (create_addrmap_from_index): Likewise.
13240 (create_addrmap_from_aranges): Likewise.
13241 (dwarf2_read_index): Likewise.
13242 (dw2_find_last_source_symtab): Likewise.
13243 (dw2_map_symtabs_matching_filename): Likewise.
13244 (dw2_symtab_iter_next): Likewise.
13245 (dw2_print_stats): Likewise.
13246 (dw2_expand_all_symtabs): Likewise.
13247 (dw2_expand_symtabs_with_fullname): Likewise.
13248 (dw2_expand_marked_cus): Likewise.
13249 (dw2_map_symbol_filenames): Likewise.
13250 (create_cus_from_debug_names): Likewise.
13251 (dwarf2_read_debug_names): Likewise.
13252 (dw2_debug_names_iterator::next): Likewise.
13253 (dwarf2_initialize_objfile): Likewise.
13254 (set_partial_user): Likewise.
13255 (dwarf2_build_psymtabs_hard): Likewise.
13256 (read_comp_units_from_section): Remove arguments, adjust to
13257 std::vector change.
13258 (create_all_comp_units): Adjust to std::vector and
13259 read_comp_units_from_section changes.
13260 (dwarf2_find_containing_comp_unit): Adjust to std::vector
13261 change.
13262 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
13263 (psyms_seen_size): Likewise.
13264 (write_gdbindex): Likewise.
13265 (write_debug_names): Likewise.
13266
13267 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13268
13269 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
13270 with dwarf2_per_objfile.
13271 (create_cus_from_index): Likewise.
13272 (create_signatured_type_table_from_index): Likewise.
13273 (dwarf2_read_index): Likewise.
13274 (dwarf2_initialize_objfile): Likewise.
13275 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
13276 per_cu rather than get_dwarf2_per_objfile.
13277
13278 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13279
13280 * dwarf2read.h (struct signatured_type): Forward declare.
13281 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
13282 New methods.
13283 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
13284 (dw2_get_cutu): ...this.
13285 (dwarf2_per_objfile::get_cu): Rename from...
13286 (dw2_get_cu): ...this.
13287 (dwarf2_per_objfile::get_tu): New.
13288 (create_addrmap_from_index): Adjust.
13289 (create_addrmap_from_aranges): Adjust.
13290 (dw2_find_last_source_symtab): Adjust.
13291 (dw2_map_symtabs_matching_filename): Adjust.
13292 (dw2_symtab_iter_next): Adjust.
13293 (dw2_print_stats): Adjust.
13294 (dw2_expand_all_symtabs): Adjust.
13295 (dw2_expand_symtabs_with_fullname): Adjust.
13296 (dw2_expand_marked_cus): Adjust.
13297 (dw_expand_symtabs_matching_file_matcher): Adjust.
13298 (dw2_map_symbol_filenames): Adjust.
13299 (dw2_debug_names_iterator::next): Adjust.
13300 (dwarf2_initialize_objfile): Adjust.
13301 (set_partial_user): Adjust.
13302 (dwarf2_build_psymtabs_hard): Adjust.
13303
13304 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13305
13306 * dwarf2read.c (create_signatured_type_table_from_debug_names):
13307 Remove unused variables.
13308 (dw2_map_symtabs_matching_filename): Likewise.
13309 (dwarf2_record_block_ranges): Likewise.
13310 (dwarf2_read_addr_index): Likewise.
13311 (follow_die_offset): Likewise.
13312
13313 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13314
13315 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
13316 to symbol_file_add_main.
13317
13318 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13319
13320 PR mi/22299
13321 * mi/mi-console.c (do_fputc_async_safe): New.
13322 (mi_console_file::write_async_safe): New.
13323 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
13324 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
13325 New.
13326 * ui-file.c (ui_file::putstrn): Adjust call to
13327 fputstrn_unfiltered.
13328 * utils.c (printchar): Replace do_fputs and do_fprintf
13329 parameters by do_fputc.
13330 (fputstr_filtered): Adjust call to printchar.
13331 (fputstr_unfiltered): Likewise.
13332 (fputstrn_filtered): Likewise.
13333 (fputstrn_unfiltered): Add do_fputc parameter, pass to
13334 printchar.
13335 * utils.h (do_fputc_ftype): New typedef.
13336 (fputstrn_unfiltered): Add do_fputc parameter.
13337
13338 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13339
13340 * regformats/i386/i386-avx.dat: Remove.
13341
13342 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13343
13344 PR gdb/22979
13345 * amd64-tdep.c (amd64_none_init_abi): New function.
13346 (amd64_x32_none_init_abi): New function.
13347 (_initialize_amd64_tdep): Register handlers for x86-64 and
13348 x64_32 with GDB_OSABI_NONE.
13349 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
13350 GDB_OSABI_NONE osabi.
13351
13352 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13353
13354 PR gdb/22980
13355 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
13356 GDB_OSABI_NONE.
13357 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
13358 * osabi.c (gdb_osabi_names): Add "unknown" entry.
13359
13360 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13361
13362 * common/byte-vector.h (char_vector): New type.
13363 * target.h (target_read_alloc): Return
13364 gdb::optional<byte_vector>.
13365 (target_read_stralloc): Return gdb::optional<char_vector>.
13366 (target_get_osdata): Return gdb::optional<char_vector>.
13367 * target.c (target_read_alloc_1): Templatize. Replacement
13368 manual memory management with vector.
13369 (target_read_alloc): Change return type, adjust.
13370 (target_read_stralloc): Change return type, adjust.
13371 (target_get_osdata): Change return type, adjust.
13372 * auxv.c (struct auxv_info) <length>: Remove.
13373 <data>: Change type to gdb::optional<byte_vector>.
13374 (auxv_inferior_data_cleanup): Free auxv_info with delete.
13375 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
13376 (target_auxv_search): Adjust.
13377 (fprint_target_auxv): Adjust.
13378 * avr-tdep.c (avr_io_reg_read_command): Adjust.
13379 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
13380 (linux_make_corefile_notes): Adjust.
13381 * osdata.c (get_osdata): Adjust.
13382 * remote.c (remote_get_threads_with_qxfer): Adjust.
13383 (remote_memory_map): Adjust.
13384 (remote_traceframe_info): Adjust.
13385 (btrace_read_config): Adjust.
13386 (remote_read_btrace): Adjust.
13387 (remote_pid_to_exec_file): Adjust.
13388 * solib-aix.c (solib_aix_get_library_list): Adjust.
13389 * solib-dsbt.c (decode_loadmap): Don't free buf.
13390 (dsbt_get_initial_loadmaps): Adjust.
13391 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
13392 * solib-target.c (solib_target_current_sos): Adjust.
13393 * tracepoint.c (sdata_make_value): Adjust.
13394 * xml-support.c (xinclude_start_include): Adjust.
13395 (xml_fetch_content_from_file): Adjust.
13396 * xml-support.h (xml_fetch_another): Change return type.
13397 (xml_fetch_content_from_file): Change return type.
13398 * xml-syscall.c (xml_init_syscalls_info): Adjust.
13399 * xml-tdesc.c (file_read_description_xml): Adjust.
13400 (fetch_available_features_from_target): Change return type.
13401 (target_fetch_description_xml): Adjust.
13402 (target_read_description_xml): Adjust.
13403
13404 2018-04-06 Tom Tromey <tom@tromey.com>
13405
13406 * value.c (~value): Update.
13407 (struct value) <contents>: Now unique_xmalloc_ptr.
13408 (value_contents_bits_eq, allocate_value_contents)
13409 (value_contents_raw, value_contents_all_raw)
13410 (value_contents_for_printing, value_contents_for_printing_const)
13411 (set_value_enclosing_type): Update.
13412
13413 2018-04-06 Tom Tromey <tom@tromey.com>
13414
13415 * value.c (range_s): Remove typedef, VEC.
13416 (struct range): Add operator<.
13417 (range_lessthan): Remove.
13418 (ranges_contain): Change type.
13419 (~value): Update.
13420 (struct value) <unavailable, optimized_out>: Now std::vector.
13421 (value_entirely_available)
13422 (value_entirely_covered_by_range_vector)
13423 (value_entirely_unavailable, value_entirely_optimized_out):
13424 Update.
13425 (insert_into_bit_range_vector): Change argument type.
13426 (find_first_range_overlap): Likewise.
13427 (struct ranges_and_idx, value_contents_bits_eq)
13428 (require_not_optimized_out, require_available): Update.
13429 (ranges_copy_adjusted): Change argument types.
13430 (value_optimized_out, value_copy, value_fetch_lazy): Update.
13431
13432 2018-04-06 Tom Tromey <tom@tromey.com>
13433
13434 * value.c (~value): Update.
13435 (struct value) <parent>: Now a value_ref_ptr.
13436 (value_parent, set_value_parent, value_address, value_copy):
13437 Update.
13438
13439 2018-04-06 Tom Tromey <tom@tromey.com>
13440
13441 * value.c (struct value): Add constructor, destructor, and member
13442 initializers.
13443 (allocate_value_lazy, value_decref): Update.
13444
13445 2018-04-06 Tom Tromey <tom@tromey.com>
13446
13447 * value.c (struct value) <released, next>: Remove.
13448 (all_values): Now a std::vector.
13449 (allocate_value_lazy): Update.
13450 (value_next): Remove.
13451 (value_mark, value_free_to_mark, release_value)
13452 (value_release_to_mark): Update.
13453
13454 2018-04-06 Tom Tromey <tom@tromey.com>
13455
13456 * value.h (fetch_subexp_value, value_release_to_mark): Update.
13457 (free_value_chain): Remove.
13458 * value.c (free_value_chain): Remove.
13459 (value_release_to_mark): Return a std::vector.
13460 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
13461 std::vector.
13462 (check_condition): Update.
13463 * eval.c (fetch_subexp_value): Change "val_chain" to a
13464 std::vector.
13465 * breakpoint.c (update_watchpoint): Update.
13466 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
13467
13468 2018-04-06 Tom Tromey <tom@tromey.com>
13469
13470 * value.h (free_all_values): Remove.
13471 * value.c (free_all_values): Remove.
13472
13473 2018-04-06 Tom Tromey <tom@tromey.com>
13474
13475 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
13476 (value_history_chain, value_history_count): Remove.
13477 (value_history): New global.
13478 (record_latest_value, access_value_history, show_values)
13479 (preserve_values): Update.
13480
13481 2018-04-06 Tom Tromey <tom@tromey.com>
13482
13483 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
13484 * varobj.c (varobj_set_display_format, varobj_set_value)
13485 (install_default_visualizer, construct_visualizer)
13486 (install_new_value, ~varobj, varobj_get_value_type)
13487 (my_value_of_variable, varobj_editable_p): Update.
13488 * c-varobj.c (c_describe_child, c_value_of_variable)
13489 (cplus_number_of_children, cplus_describe_child): Update.
13490 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
13491 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
13492 (ada_value_of_variable, ada_value_is_changeable_p): Update.
13493
13494 2018-04-06 Tom Tromey <tom@tromey.com>
13495
13496 * printcmd.c (last_examine_address): Change type to
13497 value_ref_ptr.
13498 (do_examine, x_command): Update.
13499
13500 2018-04-06 Tom Tromey <tom@tromey.com>
13501
13502 * value.c (release_value): Update.
13503 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
13504 (struct bpstats) <val>: Now a value_ref_ptr.
13505 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13506 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13507 (~watchpoint, print_it_watchpoint, watch_command_1)
13508 (invalidate_bp_value_on_memory_change): Update.
13509
13510 2018-04-06 Tom Tromey <tom@tromey.com>
13511
13512 * varobj.c (varobj_clear_saved_item)
13513 (update_dynamic_varobj_children, install_new_value, ~varobj):
13514 Update.
13515 * value.h (value_incref): Move declaration earlier.
13516 (value_decref): Rename from value_free.
13517 (struct value_ref_policy): New.
13518 (value_ref_ptr): New typedef.
13519 (struct value_deleter): Remove.
13520 (gdb_value_up): Remove typedef.
13521 (release_value): Change return type.
13522 (release_value_or_incref): Remove.
13523 * value.c (set_value_parent): Update.
13524 (value_incref): Change return type.
13525 (value_decref): Rename from value_free.
13526 (value_free_to_mark, free_all_values, free_value_chain): Update.
13527 (release_value): Return value_ref_ptr.
13528 (release_value_or_incref): Remove.
13529 (record_latest_value, set_internalvar, clear_internalvar):
13530 Update.
13531 * stack.c (info_frame_command): Don't call value_free.
13532 * python/py-value.c (valpy_dealloc, valpy_new)
13533 (value_to_value_object): Update.
13534 * printcmd.c (do_examine): Update.
13535 * opencl-lang.c (lval_func_free_closure): Update.
13536 * mi/mi-main.c (register_changed_p): Don't call value_free.
13537 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
13538 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
13539 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
13540 value_free.
13541 * guile/scm-value.c (vlscm_free_value_smob)
13542 (vlscm_scm_from_value): Update.
13543 * frame.c (frame_register_unwind, frame_unwind_register_signed)
13544 (frame_unwind_register_unsigned, get_frame_register_bytes)
13545 (put_frame_register_bytes): Don't call value_free.
13546 * findvar.c (address_from_register): Don't call value_free.
13547 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
13548 * dwarf2loc.c (entry_data_value_free_closure)
13549 (value_of_dwarf_reg_entry, free_pieced_value_closure)
13550 (dwarf2_evaluate_loc_desc_full): Update.
13551 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13552 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13553 (~watchpoint, watch_command_1)
13554 (invalidate_bp_value_on_memory_change): Update.
13555 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
13556
13557 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
13558
13559 PR gdb/23022
13560 * warning.m4: Add -Wno-error=deprecated-register.
13561 * configure: Re-generate.
13562
13563 2018-04-05 Tom Tromey <tom@tromey.com>
13564
13565 * linespec.h: Remove include of "vec.h".
13566
13567 2018-04-05 Tom Tromey <tom@tromey.com>
13568
13569 * linespec.c (typep): Remove typedef.
13570 (find_methods, find_superclass_methods): Take a std::vector.
13571 (find_method): Use std::vector.
13572
13573 2018-04-05 Tom Tromey <tom@tromey.com>
13574
13575 * utils.c (compare_strings): Remove.
13576 * utils.h (compare_strings): Remove.
13577 * objc-lang.h (find_imps): Update.
13578 * objc-lang.c (find_methods): Take a std::vector.
13579 (uniquify_strings, find_imps): Likewise.
13580 * linespec.c (find_methods): Take a std::vector.
13581 (decode_objc): Use std::vector.
13582 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
13583 a std::vector.
13584 (find_method, find_function_symbols): Use std::vector.
13585
13586 2018-04-05 Tom Tromey <tom@tromey.com>
13587
13588 * completer.c (completion_tracker::completion_tracker): Remove
13589 cast.
13590 (completion_tracker::discard_completions): Likewise.
13591 * breakpoint.c (ambiguous_names_p): Remove cast.
13592 * ada-lang.c (_initialize_ada_language): Remove cast.
13593 * utils.h (streq): Update.
13594 (streq_hash): Add new declaration.
13595 * utils.c (streq): Return bool.
13596 (streq_hash): New function.
13597
13598 2018-04-05 Tom Tromey <tom@tromey.com>
13599
13600 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
13601 Remove a string copy.
13602
13603 2018-04-05 Tom Tromey <tom@tromey.com>
13604
13605 * linespec.c (filter_results): Use std::vector.
13606 (decode_line_2, decode_line_full): Update.
13607
13608 2018-04-05 Tom Tromey <tom@tromey.com>
13609
13610 * linespec.c (canonical_to_fullform): Return std::string.
13611 (filter_results): Update.
13612 (struct decode_line_2_item): Add constructor.
13613 <fullform, displayform>: Now std::string.
13614 (decode_line_2_compare_items): Now a std::sort comparator.
13615 (decode_line_2): Update.
13616
13617 2018-04-05 Tom Tromey <tom@tromey.com>
13618
13619 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
13620 (unexpected_linespec_error): Update.
13621 (linespec_parse_basic, parse_linespec): Update.
13622
13623 2018-04-05 Tom Tromey <tom@tromey.com>
13624
13625 * linespec.c (linespec_parse_basic): Reindent.
13626
13627 2018-04-05 Tom Tromey <tom@tromey.com>
13628
13629 * minsyms.h (iterate_over_minimal_symbols): Update.
13630 * minsyms.c (iterate_over_minimal_symbols): Take a
13631 gdb::function_view.
13632 * linespec.c (struct collect_minsyms): Remove.
13633 (compare_msyms): Now a std::sort comparator.
13634 (add_minsym): Add parameters.
13635 (search_minsyms_for_name): Update. Use std::vector.
13636
13637 2018-04-03 Tom Tromey <tom@tromey.com>
13638
13639 * mipsread.c (read_alphacoff_dynamic_symtab): Use
13640 gdb::byte_vector.
13641
13642 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13643
13644 * MAINTAINERS (Write After Approval): Add Weimin Pan.
13645
13646 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13647
13648 PR gdb/16959
13649 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
13650 printing static type.
13651
13652 2018-04-01 Tom Tromey <tom@tromey.com>
13653
13654 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
13655 (rs6000_xfer_shared_libraries): Update.
13656
13657 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
13658
13659 * common/gdb_vecs.h (char_ptr): Remove.
13660 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
13661
13662 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13663
13664 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
13665 with std::vector.
13666 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
13667
13668 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13669
13670 * tracepoint.h (struct uploaded_tp): Initialize fields.
13671 <actions, step_actions, cmd_strings>: Change type to
13672 std::vector<char *>.
13673 * tracepoint.c (get_uploaded_tp): Allocate with new.
13674 (free_uploaded_tps): Free with delete.
13675 (parse_tracepoint_definition): Adjust to std::vector change.
13676 * breakpoint.c (read_uploaded_action): Likewise.
13677 (create_tracepoint_from_upload): Likewise.
13678 * ctf.c (ctf_write_uploaded_tp): Likewise.
13679 (SET_ARRAY_FIELD): Likewise.
13680 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
13681
13682 2018-03-30 Tom Tromey <tom@tromey.com>
13683
13684 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
13685 std::unique_ptr.
13686 (svr4_keep_data_in_core): Update.
13687 (svr4_read_so_list): Update.
13688
13689 2018-03-30 Tom Tromey <tom@tromey.com>
13690
13691 * windows-nat.c (handle_output_debug_string, handle_exception):
13692 Update.
13693 * target.h (target_read_string): Update.
13694 * target.c (target_read_string): Change "string" to
13695 unique_xmalloc_ptr.
13696 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
13697 Update.
13698 * solib-frv.c (frv_current_sos): Update.
13699 * solib-dsbt.c (dsbt_current_sos): Update.
13700 * solib-darwin.c (darwin_current_sos): Update.
13701 * linux-thread-db.c (inferior_has_bug): Update.
13702 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
13703 Update. Remove alloca.
13704 * ada-lang.c (ada_main_name): Update.
13705
13706 2018-03-30 Tom Tromey <tom@tromey.com>
13707
13708 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
13709 (struct dwo_file_deleter): New.
13710 (dwo_file_up): New typedef.
13711 (open_and_init_dwo_file): Use dwo_file_up.
13712 (free_dwo_file_cleanup): Remove.
13713
13714 2018-03-30 Tom Tromey <tom@tromey.com>
13715
13716 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
13717 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
13718
13719 2018-03-30 Tom Tromey <tom@tromey.com>
13720
13721 * dwarf2read.c (class free_cached_comp_units): New class.
13722 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
13723 (free_cached_comp_units): Remove function.
13724
13725 2018-03-30 Tom Tromey <tom@tromey.com>
13726
13727 * utils.h (make_cleanup_unpush_target): Remove.
13728 * inf-ptrace.c (struct target_unpusher): New.
13729 (target_unpush_up) New typedef.
13730 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
13731 target_unpush_up.
13732 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
13733
13734 2018-03-27 Tom Tromey <tom@tromey.com>
13735
13736 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
13737
13738 2018-03-27 Pedro Alves <palves@redhat.com>
13739 Tom Tromey <tom@tromey.com>
13740
13741 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
13742 destructor. Now a class.
13743 (gdb_readline_wrapper_cleanup): Remove function.
13744 (gdb_readline_wrapper): Remove cleanups.
13745
13746 2018-03-27 Tom Tromey <tom@tromey.com>
13747
13748 * typeprint.h (struct type_print_options) <local_typedefs,
13749 global_typedefs>: Remove "struct" keyword.
13750 (class typedef_hash_table): New class.
13751 (recursively_update_typedef_hash, add_template_parameters)
13752 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
13753 (find_typedef_in_hash): Don't declare.
13754 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
13755 (typedef_hash_table::recursively_update): Rename from
13756 recursively_update_typedef_hash. Now a member.
13757 (typedef_hash_table::add_template_parameters): Rename from
13758 add_template_parameters. Now a member.
13759 (typedef_hash_table::typedef_hash_table): Now a constructor;
13760 rename from create_typedef_hash.
13761 (typedef_hash_table::~typedef_hash_table): Now a destructor;
13762 rename from free_typedef_hash.
13763 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
13764 (do_free_global_table): Remove.
13765 (typedef_hash_table::typedef_hash_table): New constructor; renamed
13766 from copy_type_recursive.
13767 (create_global_typedef_table): Remove.
13768 (typedef_hash_table::find_global_typedef): Now a member of
13769 typedef_hash_table.
13770 (typedef_hash_table::find_typedef): Rename from
13771 find_typedef_in_hash; now a member.
13772 (whatis_exp): Update.
13773 * extension.h (struct ext_lang_type_printers): Add constructor and
13774 destructor.
13775 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
13776 declare.
13777 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
13778 Now a constructor; rename from start_ext_lang_type_printers.
13779 (ext_lang_type_printers): Now a destructor; rename from
13780 free_ext_lang_type_printers.
13781 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
13782 Update.
13783 (c_type_print_base_struct_union): Update. Remove cleanups.
13784
13785 2018-03-27 Tom Tromey <tom@tromey.com>
13786
13787 * dwarf-index-write.c: Include <cmath>.
13788
13789 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13790
13791 * NEWS: Add entry describing new "set|show varsize-limit" command.
13792 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
13793 command.
13794 * printcmd.c (_initialize_printcmd): Add "set var" alias of
13795 "set variable".
13796
13797 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
13798
13799 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
13800 dwarf-index-write.c
13801 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
13802 * dwarf-index-common.c: New file.
13803 * dwarf-index-common.h: New file.
13804 * dwarf-index-write.c: New file.
13805 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
13806 (struct dwarf2_section_info): Move from here.
13807 (dwarf2_section_info_def): Likewise.
13808 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
13809 (offset_type): Likewise.
13810 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
13811 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
13812 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
13813 (byte_swap): Likewise.
13814 (MAYBE_SWAP): Likewise.
13815 (dwarf2_per_cu_ptr): Likewise.
13816 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
13817 (struct tu_stats): Likewise.
13818 (struct dwarf2_per_objfile): Likewise.
13819 (struct dwarf2_per_cu_data): Likewise.
13820 (struct signatured_type): Likewise.
13821 (sig_type_ptr): Likewise.
13822 (DEF_VEC_P (sig_type_ptr)): Likewise.
13823 (INDEX4_SUFFIX): Likewise.
13824 (INDEX5_SUFFIX): Likewise.
13825 (DEBUG_STR_SUFFIX): Likewise.
13826 (dwarf2_read_section): Make non-static.
13827 (mapped_index_string_hash): Move from here.
13828 (dwarf5_djb_hash): Likewise.
13829 (file_write): Likewise.
13830 (class data_buf): Likewise.
13831 (struct symtab_index_entry): Likewise.
13832 (struct mapped_symtab): Likewise.
13833 (find_slot): Likewise.
13834 (hash_expand): Likewise.
13835 (add_index_entry): Likewise.
13836 (uniquify_cu_indices): Likewise.
13837 (class c_str_view): Likewise.
13838 (class c_str_view_hasher): Likewise.
13839 (class vector_hasher): Likewise.
13840 (write_hash_table): Likewise.
13841 (psym_index_map): Likewise.
13842 (struct addrmap_index_data): Likewise.
13843 (add_address_entry): Likewise.
13844 (add_address_entry_worker): Likewise.
13845 (write_address_map): Likewise.
13846 (symbol_kind): Likewise.
13847 (write_psymbols): Likewise.
13848 (struct signatured_type_index_data): Likewise.
13849 (write_one_signatured_type): Likewise.
13850 (recursively_count_psymbols): Likewise.
13851 (recursively_write_psymbols): Likewise.
13852 (class debug_names): Likewise.
13853 (check_dwarf64_offsets): Likewise.
13854 (psyms_seen_size): Likewise.
13855 (write_gdbindex): Likewise.
13856 (write_debug_names): Likewise.
13857 (assert_file_size): Likewise.
13858 (write_psymtabs_to_index): Likewise.
13859 (save_gdb_index_command): Likewise.
13860 (_initialize_dwarf2_read): Don't register the "save gdb-index"
13861 command.
13862 * dwarf2read.h: New file.
13863
13864 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13865
13866 PR gdb/22670
13867 * dwarf2read.c (dwarf2_physname): Do not return the demangled
13868 symbol name if the CU's language stores symbol names in linkage
13869 format.
13870 * language.h (struct language_defn)
13871 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
13872 all instances of this struct.
13873
13874 2018-03-26 Tom Tromey <tom@tromey.com>
13875
13876 * stack.c (backtrace_command_1): Remove verbose code.
13877
13878 2018-03-26 Tom Tromey <tom@tromey.com>
13879
13880 * python/py-framefilter.c (py_print_type): Don't catch
13881 exceptions. Return void.
13882 (py_print_value): Likewise.
13883 (py_print_single_arg): Likewise.
13884 (enumerate_args): Don't catch exceptions.
13885 (py_print_args): Likewise.
13886 (py_print_frame): Likewise.
13887 (gdbpy_apply_frame_filter): Catch exceptions here.
13888
13889 2018-03-26 Tom Tromey <tom@tromey.com>
13890
13891 * stack.c (_initialize_stack): Remove trailing newlines from help
13892 text. Add "Usage" line to "backtrace" help.
13893
13894 2018-03-26 Tom Tromey <tom@tromey.com>
13895
13896 PR python/16486:
13897 * python/py-framefilter.c (py_print_args): Call wrap_hint.
13898
13899 2018-03-26 Tom Tromey <tom@tromey.com>
13900
13901 * python/py-framefilter.c (py_print_single_arg): Return
13902 EXT_LANG_BT_ERROR from catch.
13903
13904 2018-03-26 Tom Tromey <tom@tromey.com>
13905
13906 PR backtrace/15584:
13907 * stack.c (backtrace_command_1): Move some code into no-filters
13908 "if".
13909
13910 2018-03-26 Tom Tromey <tom@tromey.com>
13911
13912 * python/py-framefilter.c (throw_quit_or_print_exception): New
13913 function.
13914 (gdbpy_apply_frame_filter): Use it.
13915
13916 2018-03-26 Tom Tromey <tom@tromey.com>
13917
13918 PR cli/17716:
13919 * python/py-framefilter.c (py_print_type, py_print_value)
13920 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
13921 RETURN_MASK_ERROR.
13922
13923 2018-03-26 Tom Tromey <tom@tromey.com>
13924
13925 * python/py-framefilter.c (enumerate_args): Use
13926 gdb::unique_xmalloc_ptr.
13927
13928 2018-03-26 Tom Tromey <tom@tromey.com>
13929
13930 * python/py-framefilter.c (py_print_frame): Return
13931 EXT_LANG_BT_OK.
13932 (gdbpy_apply_frame_filter): Update comment.
13933 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
13934 Remove.
13935 <EXT_LANG_BT_NO_FILTERS>: Change value.
13936
13937 2018-03-26 Tom Tromey <tom@tromey.com>
13938
13939 PR backtrace/15582:
13940 * stack.c (backtrace_command): Parse "hide" argument.
13941 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
13942 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
13943 constant.
13944
13945 2018-03-26 Tom Tromey <tom@tromey.com>
13946
13947 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
13948 add "flags".
13949 (backtrace_command): Remove "fulltrace", add "flags".
13950
13951 2018-03-26 Tom Tromey <tom@tromey.com>
13952
13953 * stack.c (backtrace_command): Rewrite command line parsing.
13954
13955 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13956
13957 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
13958
13959 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13960
13961 * filename-seen-cache.h: Add include guard.
13962
13963 2018-03-26 Keith Seitz <keiths@redhat.com>
13964
13965 * symfile.c (place_section): Remove "struct" from section_addr_info
13966 in comment.
13967 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
13968 "struct" keyword from section_addr_info.
13969
13970 2018-03-26 Alan Hayward <alan.hayward@arm.com>
13971
13972 * regformats/regdef.h (reg): Add constructors.
13973
13974 2018-03-25 Pedro Alves <palves@redhat.com>
13975
13976 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
13977 if then/else bodies in var_func_name extraction.
13978
13979 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
13980
13981 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
13982 lookup_minimal_symbol() to find symbol entry.
13983 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
13984
13985 2018-03-23 Keith Seitz <keiths@redhat.com>
13986
13987 PR c++/22968
13988 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
13989 nested type definitions for C++, too.
13990
13991 2018-03-23 Tom Tromey <tom@tromey.com>
13992
13993 * machoread.c (struct oso_el): Add a constructor. Don't define as
13994 a typedef.
13995 (macho_register_oso): Remove.
13996 (macho_symtab_read): Take a std::vector.
13997 (oso_el_compare_name): Now a std::sort comparator.
13998 (macho_symfile_read_all_oso): Take a std::vector.
13999 (macho_symfile_read): Use std::vector. Remove cleanups.
14000
14001 2018-03-22 Tom Tromey <tom@tromey.com>
14002
14003 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
14004 (record_full_goto_bookmark): Use std::string.
14005
14006 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
14007
14008 PR tdep/18295
14009 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
14010 a single mask.
14011
14012 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
14013
14014 * rs6000-tdep.c (store_insn_p): New function.
14015 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
14016 and cr_reg to their unshifted values. Use store_insn_p to
14017 match LR saves using either R1 or fdata->alloca_reg. Use
14018 store_insn_p to match CR saves. Set alloca_reg_offset
14019 when alloca_reg and framep are set. Remove lr_reg shift
14020 when assigning to fdata->lr_register.
14021
14022 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
14023
14024 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
14025 command line args instead of emitting a warning.
14026
14027 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14028
14029 * tracepoint.h (struct static_tracepoint_marker): Initialize
14030 fields, define default constructor, move constructor and move
14031 assignment, disable the rest.
14032 <str_id, extra>: Make std::string.
14033 (release_static_tracepoint_marker): Remove.
14034 (free_current_marker): Remove.
14035 * tracepoint.c (free_current_marker): Remove.
14036 (parse_static_tracepoint_marker_definition): Adjust to
14037 std::string, use new hex2str overload.
14038 (release_static_tracepoint_marker): Remove.
14039 (print_one_static_tracepoint_marker): Get marker by reference
14040 and adjust to std::string.
14041 (info_static_tracepoint_markers_command): Adjust to std::vector
14042 changes
14043 * target.h (static_tracepoint_marker_p): Remove typedef.
14044 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
14045 (struct target_ops) <to_static_tracepoint_marker_at>: Return
14046 bool.
14047 <to_static_tracepoint_markers_by_strid>: Return std::vector.
14048 * target-debug.h
14049 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
14050 (target_debug_print_std_vector_static_tracepoint_marker): New.
14051 (target_debug_print_struct_static_tracepoint_marker_p): Rename
14052 to...
14053 (target_debug_print_static_tracepoint_marker_p): ... this.
14054 * target-delegates.c: Re-generate.
14055 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
14056 Make std::string.
14057 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
14058 (decode_static_tracepoint_spec): Adjust to std::vector.
14059 (tracepoint_print_one_detail): Adjust to std::string.
14060 (strace_marker_decode_location): Adjust to std::string.
14061 (update_static_tracepoint): Adjust to std::string, remove call
14062 to release_static_tracepoint_marker.
14063 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
14064 Adjust to std::vector.
14065 * remote.c (remote_static_tracepoint_marker_at): Return bool.
14066 (remote_static_tracepoint_markers_by_strid): Adjust to
14067 std::vector.
14068 * common/rsp-low.h (hex2str): New overload with explicit count
14069 of bytes.
14070 * common/rsp-low.c (hex2str): New overload with explicit count
14071 of bytes.
14072 * unittests/rsp-low-selftests.c (test_hex2str): New function.
14073 (_initialize_rsp_low_selftests): Add test_hex2str test.
14074 * unittests/tracepoint-selftests.c
14075 (test_parse_static_tracepoint_marker_definition): Adjust to
14076 std::string.
14077
14078 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14079
14080 * tracepoint.c (parse_static_tracepoint_marker_definition):
14081 Consider case where the definition is followed by more
14082 definitions.
14083 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14084 tracepoint-selftests.c.
14085 * unittests/tracepoint-selftests.c: New.
14086
14087 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
14088
14089 * MAINTAINERS (Write After Approval): Add Pedro Franco de
14090 Carvalho.
14091
14092 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
14093
14094 * symtab.c (find_pc_sect_line): fixed indentation.
14095
14096 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
14097
14098 * symtab.c (find_pc_sect_line): now uses binary search.
14099
14100 2018-03-19 Tom Tromey <tom@tromey.com>
14101
14102 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
14103 "IDENT" production.
14104
14105 2018-03-19 Pedro Alves <palves@redhat.com>
14106 Tom Tromey <tom@tromey.com>
14107
14108 * unittests/observable-selftests.c: New file.
14109 * common/observable.h: New file.
14110 * observable.h: New file.
14111 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
14112 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
14113 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
14114 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
14115 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
14116 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
14117 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
14118 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
14119 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
14120 python/py-breakpoint.c, python/py-finishbreakpoint.c,
14121 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
14122 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
14123 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
14124 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
14125 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
14126 tui/tui-interp.c, valops.c: Update all users.
14127 * tui/tui-hooks.c (tui_bp_created_observer)
14128 (tui_bp_deleted_observer, tui_bp_modified_observer)
14129 (tui_inferior_exit_observer, tui_before_prompt_observer)
14130 (tui_normal_stop_observer, tui_register_changed_observer):
14131 Remove.
14132 (tui_observers_token): New global.
14133 (attach_or_detach, tui_attach_detach_observers): New functions.
14134 (tui_install_hooks, tui_remove_hooks): Use
14135 tui_attach_detach_observers.
14136 * record-btrace.c (record_btrace_thread_observer): Remove.
14137 (record_btrace_thread_observer_token): New global.
14138 * observer.sh: Remove.
14139 * observer.c: Rename to observable.c.
14140 * observable.c (namespace gdb_observers): Define new objects.
14141 (observer_debug): Move into gdb_observers namespace.
14142 (struct observer, struct observer_list, xalloc_observer_list_node)
14143 (xfree_observer_list_node, generic_observer_attach)
14144 (generic_observer_detach, generic_observer_notify): Remove.
14145 (_initialize_observer): Update.
14146 Don't include observer.inc.
14147 * Makefile.in (generated_files): Remove observer.h, observer.inc.
14148 (clean mostlyclean): Likewise.
14149 (observer.h, observer.inc): Remove targets.
14150 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
14151 (COMMON_SFILES): Use observable.c, not observer.c.
14152 * .gitignore: Remove observer.h.
14153
14154 2018-03-18 Tom Tromey <tom@tromey.com>
14155
14156 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
14157 gdb::def_vector.
14158 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
14159
14160 2018-03-17 Tom Tromey <tom@tromey.com>
14161
14162 * auto-load.c (auto_load_objfile_script_1): Use std::string.
14163
14164 2018-03-17 Tom Tromey <tom@tromey.com>
14165
14166 * target.c (class scoped_target_fd): New.
14167 (target_fileio_close_cleanup): Remove.
14168 (target_fileio_read_alloc_1): Use scoped_target_fd.
14169
14170 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
14171
14172 * silent-rules.mk: New.
14173 * Makefile.in: Include silent-rules.mk
14174 (srcdir, VPATH, top_srcdir): Move up.
14175 (COMPILE): Add ECHO_CXX.
14176 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
14177 (init.c): Add ECHO_INIT_C.
14178 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
14179 (version.c): Add ECHO_GEN.
14180 (printcmd.o): Add ECHO_CXX.
14181 (target-float.o): Add ECHO_CXX.
14182 (ada-exp.o): Add ECHO_CXX.
14183 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
14184 (insight$(EXEEXT)): Add ECHO_CXXLD.
14185 * gnulib/configure.ac: Add AM_SILENT_RULES.
14186 * gnulib/aclocal.m4: Re-generate.
14187 * gnulib/configure: Re-generate.
14188 * gnulib/import/Makefile.in: Re-generate.
14189
14190 2018-03-16 Tom Tromey <tom@tromey.com>
14191
14192 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
14193 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
14194 * utils.c (do_free_section_addr_info)
14195 (make_cleanup_free_section_addr_info): Remove.
14196 * symfile.h (struct other_sections): Add constructor.
14197 (struct section_addr_info): Remove.
14198 (section_addr_info): New typedef.
14199 (struct sym_fns) <sym_offsets>: Change type of parameter.
14200 (build_section_addr_info_from_objfile)
14201 (relative_addr_info_to_section_offsets, addr_info_make_relative)
14202 (default_symfile_offsets, symbol_file_add)
14203 (symbol_file_add_from_bfd)
14204 (build_section_addr_info_from_section_table): Update.
14205 (alloc_section_addr_info, free_section_addr_info): Don't declare.
14206 * symfile.c (alloc_section_addr_info): Remove.
14207 (build_section_addr_info_from_section_table): Change return type.
14208 Update.
14209 (build_section_addr_info_from_bfd)
14210 (build_section_addr_info_from_objfile): Likewise.
14211 (free_section_addr_info): Remove.
14212 (relative_addr_info_to_section_offsets): Change type of "addrs".
14213 (addrs_section_compar): Now a std::sort comparator.
14214 (addrs_section_sort): Change return type.
14215 (addr_info_make_relative): Change type of "addrs". Update.
14216 (default_symfile_offsets, syms_from_objfile_1)
14217 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
14218 (symbol_file_add_separate): Update.
14219 (symbol_file_add): Change type of "addrs". Update.
14220 (add_symbol_file_command): Update. Remove cleanups.
14221 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
14222 cleanups.
14223 * symfile-debug.c (debug_sym_offsets): Change type of "info".
14224 * solib.c (solib_read_symbols): Update.
14225 * objfiles.c (objfile_relocate): Update. Remove cleanups.
14226 * machoread.c (macho_symfile_offsets): Update.
14227 * jit.c (jit_bfd_try_read_symtab): Update.
14228
14229 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
14230
14231 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14232 unittests/utils-selftests.c.
14233 * unittests/utils-selftests.c: New file.
14234
14235 2018-03-14 Tom Tromey <tom@tromey.com>
14236
14237 PR cli/14977:
14238 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
14239 for NULL.
14240
14241 2018-03-14 Tom Tromey <tom@tromey.com>
14242
14243 PR cli/19918:
14244 * printcmd.c (printf_pointer): Allow "-" in format.
14245
14246 2018-03-14 Tom Tromey <tom@tromey.com>
14247
14248 * printcmd.c (_initialize_printcmd): Add usage to printf.
14249
14250 2018-03-14 Yao Qi <qiyao@sourceware.org>
14251
14252 * MAINTAINERS: Update my email address.
14253
14254 2018-03-13 Tom Tromey <tom@tromey.com>
14255
14256 * machoread.c (macho_check_dsym): Change filenamep to a
14257 std::string*.
14258 (macho_symfile_read): Update.
14259 * symfile.c (load_command): Use std::string.
14260
14261 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
14262
14263 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
14264 to error message string.
14265 (riscv_register_name): Use xsnprintf instead of sprintf.
14266 (riscv_insn::fetch_instruction): Use gdb_assert instead of
14267 internal_error.
14268 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
14269 error.
14270 (riscv_push_dummy_call): Likewise.
14271
14272 2018-03-12 Tom Tromey <tom@tromey.com>
14273
14274 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
14275 Use gdb::byte_vector.
14276 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
14277
14278 2018-03-12 Yao Qi <yao.qi@linaro.org>
14279
14280 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
14281 parameter type to readable_regcache.
14282 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
14283 the declaration.
14284
14285 2018-03-11 Tom Tromey <tom@tromey.com>
14286
14287 * dwarf2read.c (struct nextfield): Add initializers.
14288 (struct nextfnfield): Remove.
14289 (struct fnfieldlist): Add initializers. Remove "length" and
14290 "head", use std::vector.
14291 (struct decl_field_list): Remove.
14292 (struct field_info): Add initializers.
14293 <fields, baseclasses>: Now std::vector.
14294 <nbaseclasses, nfnfields, typedef_field_list_count,
14295 nested_types_list_count>: Remove.
14296 (dwarf2_add_field, dwarf2_add_type_defn)
14297 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
14298 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
14299 (process_structure_scope): Update.
14300
14301 2018-03-11 Tom Tromey <tom@tromey.com>
14302
14303 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
14304 for use by std::sort.
14305 (build_type_psymtabs_1): Use std::vector.
14306
14307 2018-03-09 Eli Zaretskii <eliz@gnu.org>
14308
14309 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
14310 and LIBMPFR in the printed configuration.
14311
14312 2018-03-08 Tom Tromey <tom@tromey.com>
14313
14314 * source.c (get_filename_and_charpos): Use scoped_fd.
14315 * nto-procfs.c (procfs_open_1): Use scoped_fd.
14316 (procfs_pidlist): Likewise.
14317 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
14318 (iterate_over_mappings): Likewise.
14319
14320 2018-03-08 Tom Tromey <tom@tromey.com>
14321
14322 * infcall.c (struct call_return_meta_info)
14323 <stack_temporaries_enabled>: Remove.
14324 (get_call_return_value, call_function_by_hand_dummy): Update.
14325 * thread.c (disable_thread_stack_temporaries): Remove.
14326 (enable_thread_stack_temporaries): Remove.
14327 (thread_stack_temporaries_enabled_p): Return bool.
14328 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
14329 (get_last_thread_stack_temporary): Update.
14330 * eval.c (evaluate_subexp): Update.
14331 * gdbthread.h (class enable_thread_stack_temporaries): Now a
14332 class, not a function.
14333 (value_ptr, value_vec): Remove typedefs.
14334 (class thread_info) <stack_temporaries_enabled>: Now bool.
14335 <stack_temporaries>: Now a std::vector.
14336 (thread_stack_temporaries_enabled_p)
14337 (value_in_thread_stack_temporaries): Return bool.
14338
14339 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
14340
14341 * remote.c (putpkt_binary): Fix omitted bytes reporting.
14342 (getpkt_or_notif_sane_1): Likewise.
14343
14344 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14345
14346 * build-id.c (build_id_to_debug_bfd): Use std::string.
14347
14348 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14349
14350 * build-id.c (find_separate_debug_file_by_buildid): Return
14351 std::string.
14352 * build-id.h (find_separate_debug_file_by_buildid): Return
14353 std::string.
14354 * coffread.c (coff_symfile_read): Adjust to std::string.
14355 * elfread.c (elf_symfile_read): Adjust to std::string.
14356 * symfile.c (separate_debug_file_exists): Change parameter to
14357 std::string.
14358 (find_separate_debug_file): Return std::string.
14359 (find_separate_debug_file_by_debuglink): Return std::string.
14360 * symfile.h (find_separate_debug_file_by_debuglink): Return
14361 std::string.
14362
14363 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14364
14365 * common/xml-utils.c (xml_escape_text): Move code to...
14366 (xml_escape_text_append): ... this new function.
14367 * common/xml-utils.h (xml_escape_text_append): New declaration.
14368 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
14369 New function.
14370 (_initialize_xml_utils): register test_xml_escape_text_append as
14371 a selftest.
14372
14373 2018-03-07 Alan Hayward <alan.hayward@arm.com>
14374
14375 * defs.h: Remove MAX_REGISTER_SIZE.
14376 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
14377 asserts.
14378 * python/py-unwind.c (pyuw_sniffer): Likewise.
14379
14380 2018-03-07 Tom Tromey <tom@tromey.com>
14381
14382 * linux-tdep.c (linux_info_proc): Update.
14383 * target.h (struct target_ops) <to_fileio_readlink>: Return
14384 optional<string>.
14385 (target_fileio_readlink): Return optional<string>.
14386 * remote.c (remote_hostio_readlink): Return optional<string>.
14387 * inf-child.c (inf_child_fileio_readlink): Return
14388 optional<string>.
14389 * target.c (target_fileio_readlink): Return optional<string>.
14390
14391 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
14392
14393 * regcache.c (cooked_read_test): Add riscv to the list of
14394 architectures that have a save_reggroup.
14395
14396 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
14397
14398 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
14399 value is not a dynamic class object.
14400
14401 2018-03-06 Tom Tromey <tom@tromey.com>
14402
14403 * rust-exp.y: Formatting fixes.
14404
14405 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14406
14407 * riscv-tdep.c (riscv_register_name): Remove target description
14408 support.
14409 (riscv_gdbarch_init): Remove target description check.
14410
14411 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14412
14413 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
14414 comment.
14415 * riscv-tdep.h: Likewise.
14416
14417 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14418
14419 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
14420 (riscv_pseudo_register_write): Delete.
14421 (riscv_gdbarch_init): Remove all use of pseudo registers.
14422
14423 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14424
14425 * record-btrace.c (btrace_print_lines): Replace cleanup
14426 parameter with RAII equivalents.
14427 (btrace_insn_history): Replace cleanup with RAII equivalents.
14428 * ui-out.h (make_cleanup_ui_out_list_begin_end,
14429 make_cleanup_ui_out_tuple_begin_end): Remove.
14430 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
14431 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
14432 make_cleanup_ui_out_list_begin_end): Remove.
14433
14434 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14435
14436 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
14437 parameter types to std::vector. Use bool.
14438 (record_btrace_wait): Replace VEC(tp_t) with
14439 std::vector<thread_info *>.
14440 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
14441
14442 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14443
14444 * record-btrace.c (record_btrace_disable_callback): Remove.
14445 (struct scoped_btrace_disable): New.
14446 (record_btrace_open): Use scoped_btrace_disable.
14447
14448 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14449
14450 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
14451 reading values from registers.
14452
14453 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14454
14455 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
14456 where appropriate.
14457
14458 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14459
14460 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
14461 change parameter type. Use GDB's print functions, and use
14462 core_addr_to_string where appropriate.
14463 (riscv_push_dummy_call): Use core_addr_to_string where
14464 appropriate, update call to riscv_print_arg_location, and reindent
14465 a few lines.
14466 (riscv_return_value): Update call to riscv_print_arg_location.
14467
14468 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14469 Tim Newsome <tim@sifive.com>
14470 Albert Ou <a0u@eecs.berkeley.edu>
14471 Darius Rad <darius@bluespec.com>
14472
14473 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
14474 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
14475 (ALLDEPFILES): Add riscv-tdep.c
14476 * configure.tgt: Add riscv support.
14477 * riscv-tdep.c: New file.
14478 * riscv-tdep.h: New file.
14479 * NEWS: Mention new target.
14480 * MAINTAINERS: Add entry for riscv.
14481
14482 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14483
14484 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
14485 fields within aggregates.
14486
14487 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
14488
14489 * record-btrace.c (btrace_print_lines): Change type of flags to
14490 gdb_disassembly_flags.
14491
14492 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14493
14494 * fbsd-nat.c: Include "inf-ptrace.h".
14495 (USE_SIGTRAP_SIGINFO): Conditionally define.
14496 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
14497 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
14498 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
14499 function.
14500 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
14501 Likewise.
14502 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
14503 Likewise.
14504 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
14505 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
14506 "supports_stopped_by_hw_breakpoint" target methods.
14507
14508 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14509
14510 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
14511 * fbsd-nat.c (debug_fbsd_nat): New variable.
14512 (show_fbsd_nat_debug): New function.
14513 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
14514 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
14515
14516 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14517
14518 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
14519 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
14520 prototype.
14521 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
14522 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
14523 method.
14524
14525 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14526
14527 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
14528 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
14529
14530 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14531
14532 * charset.c (struct charset_vector): New.
14533 (charsets): Change type to charset_vector.
14534 (find_charset_names): Adjust.
14535 (add_one): Adjust.
14536 (_initialize_charset): Adjust.
14537
14538 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14539
14540 * progspace.h (struct program_space) <deleted_solibs>: Change
14541 type to std::vector<std::string>.
14542 * progspace.c (clear_program_space_solib_cache): Adjust.
14543 * breakpoint.c (print_solib_event): Adjust.
14544 (check_status_catch_solib): Adjust.
14545 * solib.c (update_solib_list): Adjust.
14546 * ui-out.h (class ui_out) <field_string>: New overload.
14547 * ui-out.c (ui_out::field_string): New overload.
14548
14549 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14550
14551 * progspace.h (struct program_space): Add constructor and
14552 destructor, initialize fields.
14553 (add_program_space): Remove.
14554 * progspace.c (add_program_space): Rename to...
14555 (program_space::program_space): ... this.
14556 (release_program_space): Rename to...
14557 (program_space::~program_space): ... this.
14558 (delete_program_space): Use delete to delete program_space.
14559 (initialize_progspace): Use new to allocate program_space.
14560 * inferior.c (add_inferior_with_spaces): Likewise.
14561 (clone_inferior_command): Likewise.
14562 * infrun.c (follow_fork_inferior): Likewise.
14563 (handle_vfork_child_exec_or_exit): Likewise.
14564
14565 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14566
14567 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
14568 (delim_string_to_char_ptr_vec): Return std::vector of
14569 gdb::unique_xmalloc_ptr.
14570 (dirnames_to_char_ptr_vec_append): Take std::vector of
14571 gdb::unique_xmalloc_ptr.
14572 (dirnames_to_char_ptr_vec): Return std::vector of
14573 gdb::unique_xmalloc_ptr.
14574 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
14575 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
14576 (delim_string_to_char_ptr_vec): Return an std::vector of
14577 gdb::unique_xmalloc_ptr, adjust the code.
14578 (dirnames_to_char_ptr_vec_append): Take an std::vector of
14579 gdb::unique_xmalloc_ptr, adjust the code.
14580 (dirnames_to_char_ptr_vec): Return an std::vector of
14581 gdb::unique_xmalloc_ptr, adjust the code.
14582 * auto-load.c (auto_load_safe_path_vec): Change type to
14583 std::vector of gdb::unique_xmalloc_ptr.
14584 (auto_load_expand_dir_vars): Return an std::vector of
14585 gdb::unique_xmalloc_ptr, adjust the code.
14586 (auto_load_safe_path_vec_update): Adjust.
14587 (filename_is_in_auto_load_safe_path_vec): Adjust.
14588 (auto_load_objfile_script_1): Adjust.
14589 * build-id.c (build_id_to_debug_bfd): Adjust.
14590 * linux-thread-db.c (thread_db_load_search): Adjust.
14591 * source.c (add_path): Adjust.
14592 (openp): Adjust.
14593 * symfile.c (find_separate_debug_file): Adjust.
14594 * utils.c (do_free_char_ptr_vec): Remove.
14595 (make_cleanup_free_char_ptr_vec): Remove.
14596
14597 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
14598
14599 PR gdb/22907
14600 * common/pathstuff.c: Conditionally include "<windows.h>".
14601
14602 2018-03-01 Georg Sauthoff <mail@georg.so>
14603
14604 PR gdb/22888
14605 * gcore.in: Quote variables and switch interpreter to bash.
14606
14607 2018-03-01 Tom Tromey <tom@tromey.com>
14608
14609 * dwarf2read.c (alloc_discriminant_info): Fix default_index
14610 assertion. Add assertion for discriminant_index.
14611 (quirk_rust_enum): Use correct base type name in univariant case.
14612
14613 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
14614
14615 * record.c (get_call_history_modifiers): Return a
14616 record_print_flags.
14617 (cmd_record_call_history): Adjust.
14618 * record-btrace.c (record_btrace_call_history): Adjust.
14619 (record_btrace_call_history_range): Adjust.
14620 (record_btrace_call_history_from): Adjust.
14621 * target-debug.h (target_debug_print_record_print_flags): New.
14622 * target-delegates.c: Re-generate.
14623 * target.c (target_call_history): Change flags type.
14624 (target_call_history_from): Likewise.
14625 (target_call_history_range): Likewise.
14626 * target.h (struct target_ops) <target_call_history>: Likewise.
14627 (target_call_history_from): Likewise.
14628 (target_call_history_range): Likewise.
14629
14630 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14631 Simon Marchi <simon.marchi@polymtl.ca>
14632
14633 * common/common-utils.c: Include "sys/stat.h".
14634 (is_regular_file): Move here from "source.c"; change return
14635 type to "bool".
14636 * common/common-utils.h (is_regular_file): New prototype.
14637 * common/pathstuff.c (contains_dir_separator): New function.
14638 * common/pathstuff.h (contains_dir_separator): New prototype.
14639 * source.c: Don't include "sys/stat.h".
14640 (is_regular_file): Move to "common/common-utils.c".
14641
14642 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14643
14644 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
14645 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
14646 * auto-load.c: Include "common/pathstuff.h".
14647 * common/common-def.h (current_directory): Move here.
14648 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
14649 function.
14650 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
14651 prototype.
14652 * common/pathstuff.c: New file.
14653 * common/pathstuff.h: New file.
14654 * compile/compile.c: Include "common/pathstuff.h".
14655 * defs.h (current_directory): Move to "common/common-defs.h".
14656 * dwarf2read.c: Include "common/pathstuff.h".
14657 * exec.c: Likewise.
14658 * guile/scm-safe-call.c: Likewise.
14659 * linux-thread-db.c: Likewise.
14660 * main.c: Likewise.
14661 * nto-tdep.c: Likewise.
14662 * objfiles.c: Likewise.
14663 * source.c: Likewise.
14664 * symtab.c: Likewise.
14665 * utils.c: Include "common/pathstuff.h".
14666 (gdb_realpath): Move to "common/pathstuff.c".
14667 (gdb_realpath_keepfile): Likewise.
14668 (gdb_abspath): Likewise.
14669 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
14670 (gdb_realpath_keepfile): Likewise.
14671 (gdb_abspath): Likewise.
14672
14673 2018-02-28 John Baldwin <jhb@FreeBSD.org>
14674
14675 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
14676 wildcard process pid for super_resume for kernels with a
14677 specific bug.
14678
14679 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
14680
14681 * compile/compile.c (get_args): Add additional comments
14682 explaining function.
14683
14684 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
14685 Tom Tromey <tom@tromey.com>
14686
14687 * target.h (memory_write_request_s): Remove typedef. Don't define
14688 VEC.
14689 (target_write_memory_blocks): Change argument to std::vector.
14690 (struct memory_write_request): Add constructor.
14691 * target-memory.c (compare_block_starting_address): Return bool.
14692 Change argument types.
14693 (claim_memory): Change arguments to use std::vector.
14694 (split_regular_and_flash_blocks, blocks_to_erase)
14695 (compute_garbled_blocks): Likewise.
14696 (cleanup_request_data, cleanup_write_requests_vector): Remove.
14697 (target_write_memory_blocks): Change argument to std::vector.
14698 * symfile.c (struct load_section_data): Add constructor and
14699 destructor. Use std::vector for "requests".
14700 (struct load_progress_data): Add initializers.
14701 (load_section_callback): Update. Use "new".
14702 (clear_memory_write_data): Remove.
14703 (generic_load): Update.
14704
14705 2018-02-27 Alan Hayward <alan.hayward@arm.com>
14706
14707 * arch/aarch64.h: Use common/tdesc.h.
14708
14709 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14710
14711 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
14712 architecture with a 64-bit ABI.
14713
14714 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14715
14716 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
14717 ahead of target description loading.
14718
14719 2018-02-26 Tom Tromey <tom@tromey.com>
14720
14721 * stack.c (backtrace_command_1): Update.
14722 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
14723 of "flags".
14724 * python/py-framefilter.c (py_print_frame)
14725 (gdbpy_apply_frame_filter): Change type of "flags".
14726 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
14727 of "flags".
14728 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
14729 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
14730 * extension.h (enum frame_filter_flag): Rename from
14731 frame_filter_flags.
14732 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
14733 (apply_ext_lang_frame_filter): Change type of "flags".
14734 * extension.c (apply_ext_lang_frame_filter): Change type of
14735 "flags".
14736 * extension-priv.h (struct extension_language_ops)
14737 <apply_frame_filter>: Change type of "flags".
14738
14739 2018-02-26 Tom Tromey <tom@tromey.com>
14740
14741 PR python/16497:
14742 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
14743 off-by-one in py_end computation.
14744 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
14745 PRINT_MORE_FRAMES.
14746 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
14747 constant.
14748
14749 2018-02-26 Tom Tromey <tom@tromey.com>
14750
14751 * dwarf2read.c (struct variant_field): New.
14752 (struct nextfield) <variant>: New field.
14753 (dwarf2_add_field): Handle DW_TAG_variant_part.
14754 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
14755 discriminated union.
14756 (read_structure_type): Handle DW_TAG_variant_part.
14757 (handle_struct_member_die): New function, extracted from
14758 process_structure_scope. Handle DW_TAG_variant.
14759 (process_structure_scope): Handle discriminated unions. Call
14760 handle_struct_member_die.
14761
14762 2018-02-26 Tom Tromey <tom@tromey.com>
14763
14764 * rust-lang.h (rust_last_path_segment): Declare.
14765 * rust-lang.c (rust_last_path_segment): Now public. Change
14766 contract.
14767 (struct disr_info): Remove.
14768 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
14769 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
14770 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
14771 (rust_enum_p, rust_enum_variant): New function.
14772 (rust_underscore_fields): Remove "offset" parameter.
14773 (rust_print_enum): New function.
14774 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
14775 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
14776 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
14777 enums.
14778 (rust_internal_print_type): New function, from rust_print_type.
14779 Remove enum code.
14780 (rust_print_type): Call rust_internal_print_type.
14781 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
14782 Update enum handling.
14783 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
14784 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
14785 (rust_union_quirks): New functions.
14786 (process_full_comp_unit, process_full_type_unit): Call
14787 rust_union_quirks.
14788 (process_structure_scope): Update rust_unions if necessary.
14789
14790 2018-02-26 Tom Tromey <tom@tromey.com>
14791
14792 * value.h (value_union_variant): Declare.
14793 * valops.c (value_union_variant): New function.
14794 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
14795 (struct discriminant_info): New.
14796 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
14797 enumerator.
14798 (struct main_type) <flag_discriminated_union>: New field.
14799
14800 2018-02-26 Tom Tromey <tom@tromey.com>
14801
14802 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14803 unittests/unpack-selftests.c.
14804 * unittests/unpack-selftests.c: New file.
14805 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
14806
14807 2018-02-26 Yao Qi <yao.qi@linaro.org>
14808
14809 * dwarf2read.c (struct partial_die_info) <read>: New method.
14810 (read_partial_die): Remove the declaration.
14811 (load_partial_dies): Update.
14812 (partial_die_info::partial_die_info):
14813 (read_partial_die): Change it to partial_die_info::read.
14814
14815 2018-02-26 Yao Qi <yao.qi@linaro.org>
14816
14817 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
14818 (fixup_partial_die): Remove declaration.
14819 (scan_partial_symbols): Update.
14820 (partial_die_parent_scope): Likewise.
14821 (partial_die_full_name): Likewise.
14822 (fixup_partial_die): Change it to partial_die_info::fixup.
14823
14824 2018-02-26 Yao Qi <yao.qi@linaro.org>
14825
14826 * dwarf2read.c (read_partial_die): Update the declaration.
14827 (load_partial_dies): Caller update.
14828 (read_partial_die): Remove one argument abbrev_len.
14829
14830 2018-02-26 Yao Qi <yao.qi@linaro.org>
14831
14832 * dwarf2read.c (struct partial_die_info): Add ctor, delete
14833 assignment operator.
14834 (load_partial_dies): Use ctor and copy ctor.
14835 (read_partial_die): Update.
14836 (dwarf2_cu::find_partial_die): Use ctor.
14837
14838 2018-02-26 Yao Qi <yao.qi@linaro.org>
14839
14840 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
14841 (find_partial_die_in_comp_unit): Change it to
14842 dwarf2_cu::find_partial_die.
14843 (find_partial_die): Update.
14844
14845 2018-02-26 Yao Qi <yao.qi@linaro.org>
14846
14847 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
14848 is NULL.
14849
14850 2018-02-26 Yao Qi <yao.qi@linaro.org>
14851
14852 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
14853
14854 2018-02-26 Alan Hayward <alan.hayward@arm.com>
14855
14856 * arch/amd64.h: Use common/tdesc.h.
14857 * arch/i386.c: Likewise.
14858 * arch/i386.h: Likewise.
14859 * arch/tic6x.c: Likewise.
14860 * arch/tdesc.h: Move file from here...
14861 * common/tdesc.h: ...to here.
14862 * features/aarch64-core.c: Regenerate.
14863 * features/aarch64-fpu.c: Regenerate.
14864 * features/i386/32bit-avx.c: Regenerate.
14865 * features/i386/32bit-avx512.c: Regenerate.
14866 * features/i386/32bit-core.c: Regenerate.
14867 * features/i386/32bit-linux.c: Regenerate.
14868 * features/i386/32bit-mpx.c: Regenerate.
14869 * features/i386/32bit-pkeys.c: Regenerate.
14870 * features/i386/32bit-sse.c: Regenerate.
14871 * features/i386/64bit-avx.c: Regenerate.
14872 * features/i386/64bit-avx512.c: Regenerate.
14873 * features/i386/64bit-core.c: Regenerate.
14874 * features/i386/64bit-linux.c: Regenerate.
14875 * features/i386/64bit-mpx.c: Regenerate.
14876 * features/i386/64bit-pkeys.c: Regenerate.
14877 * features/i386/64bit-segments.c: Regenerate.
14878 * features/i386/64bit-sse.c: Regenerate.
14879 * features/i386/x32-core.c: Regenerate.
14880 * features/tic6x-c6xp.c: Regenerate.
14881 * features/tic6x-core.c: Regenerate.
14882 * features/tic6x-gp.c: Regenerate.
14883 * target-descriptions.c: Use common/tdesc.h.
14884 * target-descriptions.h: Likewise.
14885
14886 2018-02-24 Tom Tromey <tom@tromey.com>
14887
14888 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
14889 (try_thread_db_load_from_dir, thread_db_load_search): Use
14890 std::string.
14891 (info_auto_load_libthread_db_compare): Return bool. Change
14892 argument types.
14893 (info_auto_load_libthread_db): Use std::vector, std::string.
14894 Remove cleanups.
14895
14896 2018-02-24 Tom Tromey <tom@tromey.com>
14897
14898 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
14899 std::string.
14900 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
14901 std::string*.
14902 * gdbarch.c: Rebuild.
14903 * gdbarch.h: Rebuild.
14904 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
14905 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
14906 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
14907 std::string*.
14908
14909 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
14910
14911 * gdbtypes.h (sect_offset): Change type to uint64_t.
14912 (sect_offset_str): New function.
14913 * dwarf2read.c (create_addrmap_from_aranges): Use
14914 sect_offset_str.
14915 (error_check_comp_unit_head): Likewise.
14916 (create_debug_type_hash_table): Likewise.
14917 (read_cutu_die_from_dwo): Likewise.
14918 (init_cutu_and_read_dies): Likewise.
14919 (init_cutu_and_read_dies_no_follow): Likewise.
14920 (process_psymtab_comp_unit_reader): Likewise.
14921 (partial_die_parent_scope): Likewise.
14922 (peek_die_abbrev): Likewise.
14923 (process_queue): Likewise.
14924 (dwarf2_physname): Likewise.
14925 (read_namespace_alias): Likewise.
14926 (read_import_statement): Likewise.
14927 (create_dwo_cu_reader): Likewise.
14928 (create_cus_hash_table): Likewise.
14929 (lookup_dwo_cutu): Likewise.
14930 (inherit_abstract_dies): Likewise.
14931 (read_func_scope): Likewise.
14932 (read_call_site_scope): Likewise.
14933 (dwarf2_add_member_fn): Likewise.
14934 (read_common_block): Likewise.
14935 (read_module_type): Likewise.
14936 (read_typedef): Likewise.
14937 (read_subrange_type): Likewise.
14938 (load_partial_dies): Likewise.
14939 (read_partial_die): Likewise.
14940 (find_partial_die): Likewise.
14941 (read_str_index): Likewise.
14942 (dwarf2_string_attr): Likewise.
14943 (build_error_marker_type): Likewise.
14944 (lookup_die_type): Likewise.
14945 (dump_die_shallow): Likewise.
14946 (follow_die_ref): Likewise.
14947 (dwarf2_fetch_die_loc_sect_off): Likewise.
14948 (dwarf2_fetch_constant_bytes): Likewise.
14949 (follow_die_sig): Likewise.
14950 (get_signatured_type): Likewise.
14951 (get_DW_AT_signature_type): Likewise.
14952 (dwarf2_find_containing_comp_unit): Likewise.
14953 (set_die_type): Likewise.
14954
14955 2018-02-21 John Baldwin <jhb@FreeBSD.org>
14956
14957 * arch/aarch64.c: Include "common-defs.h".
14958 * arch/amd64.c: Likewise.
14959 * arch/i386.c: Likewise.
14960
14961 2018-02-21 Tom Tromey <tom@tromey.com>
14962
14963 * value.h: (extract_field_op): Update.
14964 * eval.c (extract_field_op): Return a const char *.
14965 * expression.h (parse_expression_for_completion): Update.
14966 * completer.c (complete_expression): Update.
14967 (add_struct_fields): Make fieldname const.
14968 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
14969 (mark_completion_tag, parse_exp_in_context_1): Update.
14970 (parse_expression_for_completion): Change "name" to
14971 unique_xmalloc_ptr*.
14972
14973 2018-02-21 Tom Tromey <tom@tromey.com>
14974
14975 * infcall.c (call_function_by_hand_dummy): Use std::vector.
14976
14977 2018-02-21 Yao Qi <yao.qi@linaro.org>
14978
14979 * avr-tdep.c (avr_read_pc): Change parameter type to
14980 readable_regcache.
14981 * gdbarch.sh (read_pc): Likewise.
14982 * gdbarch.c: Re-generated.
14983 * gdbarch.h: Re-generated.
14984 * hppa-tdep.c (hppa_read_pc): Change parameter type to
14985 readable_regcache.
14986 * ia64-tdep.c (ia64_read_pc): Likewise.
14987 * mips-tdep.c (mips_read_pc): Likewise.
14988 * spu-tdep.c (spu_read_pc): Likewise.
14989
14990 2018-02-21 Yao Qi <yao.qi@linaro.org>
14991
14992 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
14993 * regcache-dump.c: New file.
14994 * regcache.c: Move register_dump to regcache-dump.c.
14995 (maintenance_print_registers): Likewise.
14996 (maintenance_print_raw_registers): Likewise.
14997 (maintenance_print_cooked_registers): Likewise.
14998 (maintenance_print_register_groups): Likewise.
14999 (maintenance_print_remote_registers): Likewise.
15000 (_initialize_regcache): Likewise.
15001 * regcache.h (register_dump): Moved from regcache.c.
15002
15003 2018-02-21 Yao Qi <yao.qi@linaro.org>
15004
15005 * regcache.c (regcache::regcache): Update.
15006 (regcache::invalidate): Move it to detached_regcache::invalidate.
15007 (get_thread_arch_aspace_regcache): Update.
15008 (regcache::raw_update): Update.
15009 (regcache::cooked_read): Remove some code.
15010 (regcache::cooked_read_value): Likewise.
15011 (regcache::raw_write): Remove assert on m_readonly_p.
15012 (regcache::raw_supply_integer): Move it to
15013 detached_regcache::raw_supply_integer.
15014 (regcache::raw_supply_zeroed): Likewise.
15015 * regcache.h (detached_regcache) <raw_supply_integer>: New
15016 declaration.
15017 <raw_supply_zeroed, invalidate>: Likewise.
15018 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
15019 <invalidate>: Likewise.
15020 <m_readonly_p>: Removed.
15021
15022 2018-02-21 Yao Qi <yao.qi@linaro.org>
15023
15024 * infcmd.c (get_return_value): Let stop_regs point to
15025 get_current_regcache.
15026 * regcache.c (regcache::regcache): Remove.
15027 (register_dump_reg_buffer): New class.
15028 (regcache_print): Adjust.
15029 * regcache.h (regcache): Remove constructors.
15030
15031 2018-02-21 Yao Qi <yao.qi@linaro.org>
15032
15033 * regcache.c (class register_dump): New class.
15034 (register_dump_regcache, register_dump_none): New class.
15035 (register_dump_remote, register_dump_groups): New class.
15036 (regcache_print): Update.
15037 * regcache.h (regcache_dump_what): Move it to regcache.c.
15038 (regcache) <dump>: Remove.
15039
15040 2018-02-21 Yao Qi <yao.qi@linaro.org>
15041
15042 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
15043 reg_buffer_rw *.
15044 (jit_unwind_reg_set_impl): Call raw_supply.
15045 (jit_frame_sniffer): Use reg_buffer_rw.
15046 * record-full.c (record_full_core_regbuf): Change its type.
15047 (record_full_core_open_1): Use reg_buffer_rw.
15048 (record_full_close): Likewise.
15049 (record_full_core_fetch_registers): Use regcache->raw_supply.
15050 (record_full_core_store_registers): Likewise.
15051 * regcache.c (regcache::get_register_status): Move it to
15052 reg_buffer.
15053 (regcache_raw_set_cached_value): Remove.
15054 (regcache::raw_set_cached_value): Remove.
15055 (regcache::raw_write): Call raw_supply.
15056 (regcache::raw_supply): Move it to reg_buffer_rw.
15057 * regcache.h (regcache_raw_set_cached_value): Remove.
15058 (reg_buffer_rw): New class.
15059
15060 2018-02-21 Yao Qi <yao.qi@linaro.org>
15061
15062 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
15063 readonly_detached_regcache.
15064 (dummy_frame_prev_register): Use regcache->cooked_read.
15065 * frame.c (frame_save_as_regcache): Change return type.
15066 (frame_pop): Update.
15067 * frame.h (frame_save_as_regcache): Update declaration.
15068 * inferior.h (get_infcall_suspend_state_regcache): Update
15069 declaration.
15070 * infrun.c (infcall_suspend_state) <registers>: use
15071 readonly_detached_regcache.
15072 (save_infcall_suspend_state): Don't use regcache_dup.
15073 (get_infcall_suspend_state_regcache): Change return type.
15074 * linux-fork.c (struct fork_info) <savedregs>: Change to
15075 readonly_detached_regcache.
15076 <pc>: New field.
15077 (fork_save_infrun_state): Don't use regcache_dup.
15078 (info_checkpoints_command): Adjust.
15079 * mi/mi-main.c (register_changed_p): Update declaration.
15080 (mi_cmd_data_list_changed_registers): Use
15081 readonly_detached_regcache.
15082 (register_changed_p): Change parameter type to
15083 readonly_detached_regcache.
15084 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
15085 readonly_detached_regcache.
15086 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
15087 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
15088 New.
15089 (regcache::save): Move it to reg_buffer.
15090 (regcache::restore): Change parameter type.
15091 (regcache_dup): Remove.
15092 * regcache.h (reg_buffer) <save>: New method.
15093 (readonly_detached_regcache): New class.
15094 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
15095 readonly_detached_regcache.
15096 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
15097
15098 2018-02-21 Yao Qi <yao.qi@linaro.org>
15099
15100 * frame.c (frame_save_as_regcache): Use regcache method save.
15101 (frame_pop): Use regcache method restore.
15102 * infrun.c (restore_infcall_suspend_state): Likewise.
15103 * linux-fork.c (fork_load_infrun_state): Likewise.
15104 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
15105 save.
15106 * regcache.c (regcache_save): Remove.
15107 (regcache::restore): More asserts.
15108 (regcache_cpy): Remove.
15109 * regcache.h (regcache_save): Remove the declaration.
15110 (regcache::restore): Move from private to public.
15111 Remove the friend declaration of regcache_cpy.
15112 (regcache_cpy): Remove declaration.
15113
15114 2018-02-21 Yao Qi <yao.qi@linaro.org>
15115
15116 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
15117 parameter type to 'readable_regcache *'.
15118 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15119 * arm-tdep.c (arm_neon_quad_read): Likewise.
15120 (arm_pseudo_read): Likewise.
15121 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15122 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15123 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15124 * gdbarch.c: Re-generated.
15125 * gdbarch.h: Re-generated.
15126 * gdbarch.sh (pseudo_register_read): Change parameter type to
15127 'readable_regcache *'.
15128 (pseudo_register_read_value): Likewise.
15129 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
15130 (h8300_pseudo_register_read): Likewise.
15131 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
15132 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15133 (i386_pseudo_register_read_into_value): Likewise.
15134 (i386_pseudo_register_read_value): Likewise.
15135 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
15136 declaration.
15137 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
15138 * m32c-tdep.c (m32c_raw_read): Likewise.
15139 (m32c_read_flg): Likewise.
15140 (m32c_banked_register): Likewise.
15141 (m32c_banked_read): Likewise.
15142 (m32c_sb_read): Likewise.
15143 (m32c_part_read): Likewise.
15144 (m32c_cat_read): Likewise.
15145 (m32c_r3r2r1r0_read): Likewise.
15146 (m32c_pseudo_register_read): Likewise.
15147 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15148 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15149 (mep_pseudo_cr64_read): Likewise.
15150 (mep_pseudo_register_read): Likewise.
15151 * mips-tdep.c (mips_pseudo_register_read): Likewise.
15152 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15153 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15154 * regcache.c (regcache::raw_read): Move it to readable_regcache.
15155 (regcache::cooked_read): Likewise.
15156 (regcache::cooked_read_value): Likewise.
15157 (regcache_cooked_read_signed):
15158 (regcache::cooked_read): Likewise.
15159 * regcache.h (readable_regcache): New class.
15160 (regcache): Inherit readable_regcache. Move some methods to
15161 readable_regcache.
15162 * rl78-tdep.c (rl78_pseudo_register_read): Change
15163 parameter type to 'readable_regcache *'.
15164 * rs6000-tdep.c (do_regcache_raw_read): Remove.
15165 (e500_pseudo_register_read): Change parameter type to
15166 'readable_regcache *'.
15167 (dfp_pseudo_register_read): Likewise.
15168 (vsx_pseudo_register_read): Likewise.
15169 (efpr_pseudo_register_read): Likewise.
15170 * s390-tdep.c (s390_pseudo_register_read): Likewise.
15171 * sh-tdep.c (sh_pseudo_register_read): Likewise.
15172 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
15173 (sh64_pseudo_register_read): Likewise.
15174 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15175 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15176 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15177 (spu_pseudo_register_read): Likewise.
15178 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15179 (xtensa_pseudo_register_read): Likewise.
15180
15181 2018-02-21 Yao Qi <yao.qi@linaro.org>
15182
15183 * regcache.c (regcache::regcache): Call reg_buffer ctor.
15184 (regcache::arch): Move it to reg_buffer::arch.
15185 (regcache::register_buffer): Likewise.
15186 (regcache::assert_regnum): Likewise.
15187 (regcache::num_raw_registers): Likewise.
15188 * regcache.h (reg_buffer): New class.
15189 (regcache): Inherit reg_buffer.
15190
15191 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
15192
15193 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
15194 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
15195
15196 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
15197
15198 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
15199
15200 2018-02-19 Alan Hayward <alan.hayward@arm.com>
15201
15202 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
15203 (SFILES): Remove common/*.c files.
15204 (COMMON_OBS): Remove some *.o files built from common/*.c files.
15205 * common/common.host: Add common reference.
15206 * configure.ac: Likewise.
15207 * configure: Regenerate.
15208
15209 2018-02-16 Yao Qi <yao.qi@linaro.org>
15210
15211 * block.c (block_namespace_info): Inherit allocate_on_obstack.
15212 (block_initialize_namespace): Use new.
15213 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
15214 (dwarf2_free_objfile): Use delete.
15215 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
15216 (copy_type_recursive): Use new.
15217 * gdb_obstack.h (allocate_on_obstack): New.
15218
15219 2018-02-15 Yao Qi <yao.qi@linaro.org>
15220
15221 PR gdb/22849
15222 * inferior.c (exit_inferior_1): Reset inf->control.
15223
15224 2018-02-15 Joel Brobecker <brobecker@adacore.com>
15225
15226 * ada-lang.c (ada_to_fixed_value_create): Delete advance
15227 declaration.
15228
15229 2018-02-14 Pedro Alves <palves@redhat.com>
15230
15231 * frame-unwind.c (frame_unwind_try_unwinder): Always call
15232 frame_cleanup_after_sniffer on exception.
15233
15234 2018-02-14 Tom Tromey <tom@tromey.com>
15235
15236 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
15237 const.
15238 (solib_bfd_open): Make pathname const.
15239 * solib.c (solib_bfd_open): Make pathname const.
15240 * solib-spu.c (spu_bfd_fopen): Make name const.
15241 (spu_bfd_open): Make pathname const.
15242 * solib-darwin.c (darwin_bfd_open): Make pathname const.
15243 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
15244
15245 2018-02-14 Tom Tromey <tom@tromey.com>
15246
15247 * symfile.c (symfile_bfd_open): Update.
15248 * source.h (openp, source_full_path_of, find_and_open_source):
15249 Change argument type to unique_xmalloc_ptr.
15250 * source.c (openp): Take a unique_xmalloc_ptr.
15251 (source_full_path_of, find_and_open_source): Likewise.
15252 (open_source_file, symtab_to_fullname): Update.
15253 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
15254 unique_xmalloc_ptr.
15255 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
15256 (exec_file_find): Update.
15257 * psymtab.c (psymtab_to_fullname): Update.
15258 * nto-tdep.h (nto_find_and_open_solib): Update.
15259 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
15260 unique_xmalloc_ptr.
15261 * exec.c (exec_file_attach): Update.
15262 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
15263 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
15264
15265 2018-02-14 Tom Tromey <tom@tromey.com>
15266
15267 * solib.c: Include source.h.
15268 * nto-tdep.c: Include source.h.
15269 * mi/mi-cmd-env.c: Include source.h.
15270 * infcmd.c: Include source.h.
15271 * exec.c: Include source.h.
15272 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
15273 (add_path, directory_switch, source_path, init_source_path): Move
15274 declarations...
15275 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
15276 (add_path, directory_switch, source_path, init_source_path):
15277 ...here.
15278
15279 2018-02-14 Tom Tromey <tom@tromey.com>
15280
15281 * solist.h (exec_file_find, solib_find): Return
15282 unique_xmalloc_ptr.
15283 (solib_bfd_fopen): Take a const char *.
15284 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
15285 (exec_file_find, solib_find): Likewise.
15286 (solib_bfd_fopen): Do not take ownership of "pathname".
15287 (solib_bfd_open): Use unique_xmalloc_ptr.
15288 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
15289 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
15290 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
15291 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
15292
15293 2018-02-14 Joel Brobecker <brobecker@adacore.com>
15294
15295 * ada-lang.c (name_match_type_from_name): Remove reference to
15296 ada_name_for_lookup in function's documentation.
15297 * ada-lang.h (ada_name_for_lookup): Delete declaration.
15298
15299 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
15300
15301 * defs.h (enum openp_flags): New enum.
15302 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
15303 Move to enum openp_flags.
15304 (openp_flags): New enum flags.
15305 (openp): Change parameter type to openp_flags.
15306 * source.c (openp): Change parameter type to openp_flags.
15307 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
15308 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
15309
15310 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
15311
15312 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
15313 per-command.
15314
15315 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
15316
15317 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
15318 into...
15319 (class dwarf2_queue_guard): ...the destructor of this new class.
15320 (dw2_do_instantiate_symtab): Create instance of the new class
15321 dwarf2_queue_guard, remove cleanup.
15322
15323 2018-02-09 Tom Tromey <tom@tromey.com>
15324
15325 * source.c (find_source_lines): Don't reference past the end of
15326 the vector.
15327
15328 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15329
15330 * remote.c (remote_btrace_maybe_reopen): Change error message.
15331 * btrace.c (btrace_enable): Likewise.
15332 (parse_xml_btrace): Likewise.
15333 (parse_xml_btrace_conf): Likewise.
15334
15335 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15336
15337 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
15338 (linux_enable_pt, linux_enable_bts): Call
15339 diagnose_perf_event_open_fail.
15340
15341 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15342
15343 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
15344 Remove parameter and change return type. Update callers. Move it.
15345 (linux_enable_bts, linux_enable_pt): Improve error message.
15346 (linux_enable_pt): Remove zero buffer size check.
15347 (linux_enable_btrace): Improve error messages. Remove NULL return
15348 check.
15349
15350 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15351
15352 * btrace.c (btrace_enable): Remove target_supports_btrace call.
15353 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
15354 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
15355 (linux_supports_pt, linux_supports_btrace): Remove.
15356 (linux_enable_bts): Call cpu_supports_bts.
15357 * nat/linux-btrace.h (linux_supports_btrace): Remove.
15358 * remote.c (remote_supports_btrace): Remove.
15359 (init_remote_ops): Remove remote_supports_btrace.
15360 * target-delegates.c: Regenerated.
15361 * target.c (target_supports_btrace): Remove.
15362 * target.h (target_ops) <to_supports_btrace>: Remove
15363 (target_supports_btrace): Remove.
15364 * x86-linux-nat.c (x86_linux_create_target): Remove
15365 linux_supports_btrace.
15366
15367 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15368
15369 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
15370 btrace failed.
15371 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
15372 exception and use message in own exception.
15373
15374 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15375
15376 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
15377 (perf_event_pt_event_type): Use gdb_file_up.
15378 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
15379 scoped_fd, and scoped_mmap.
15380
15381 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15382
15383 * common/scoped_mmap.h: New.
15384 * unittests/scoped_mmap-selftest.c: New.
15385 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15386 unittests/scoped_mmap-selftest.c.
15387
15388 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15389
15390 * common/scoped_fd.h: New.
15391 * unittests/scoped_fd-selftest.c: New.
15392 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15393 unittests/scoped_fd-selftest.c.
15394
15395 2018-02-09 Tom Tromey <tom@tromey.com>
15396
15397 * auto-load.c (auto_load_section_scripts): Use
15398 gdb::unique_xmalloc_ptr.
15399
15400 2018-02-09 Tom Tromey <tom@tromey.com>
15401
15402 * auto-load.c (execute_script_contents): Use std::string.
15403
15404 2018-02-09 Joel Brobecker <brobecker@adacore.com>
15405
15406 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
15407 Python function, rather than a new command.
15408
15409 2018-02-08 Tom Tromey <tom@tromey.com>
15410
15411 * solib.c (solib_find_1): Use std::string.
15412 (solib_bfd_fopen): Use unique_xmalloc_ptr.
15413
15414 2018-02-08 Tom Tromey <tom@tromey.com>
15415
15416 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
15417
15418 2018-02-08 Tom Tromey <tom@tromey.com>
15419
15420 * source.c (find_source_lines): Use gdb::def_vector.
15421
15422 2018-02-08 Tom Tromey <tom@tromey.com>
15423
15424 * macrocmd.c (struct temporary_macro_definition): New.
15425 (macro_define_command): Use temporary_macro_definition. Remove
15426 cleanups.
15427 (free_macro_definition_ptr): Remove.
15428
15429 2018-02-08 Tom Tromey <tom@tromey.com>
15430
15431 * macroexp.c (maybe_expand): Use std::string.
15432
15433 2018-02-08 Tom Tromey <tom@tromey.com>
15434
15435 * macroexp.c (struct macro_buffer): Add initializers for some
15436 members.
15437 (init_buffer, init_shared_buffer, free_buffer)
15438 (free_buffer_return_text): Remove.
15439 (macro_buffer): New constructors.
15440 (~macro_buffer): New destructor.
15441 (macro_buffer::set_shared): New method.
15442 (macro_buffer::resize_buffer, macro_buffer::appendc)
15443 (macro_buffer::appendmem): Now methods, not free functions.
15444 (set_token, append_tokens_without_splicing, stringify)
15445 (macro_stringify): Update.
15446 (gather_arguments): Change return type. Remove argc_p argument,
15447 add args_ptr argument. Use std::vector.
15448 (substitute_args): Remove argc argument. Accept std::vector.
15449 (expand): Update. Use std::vector.
15450 (scan, macro_expand, macro_expand_next): Update.
15451
15452 2018-02-08 Tom Tromey <tom@tromey.com>
15453
15454 * symtab.c (default_collect_symbol_completion_matches_break_on):
15455 Use unique_xmalloc_ptr.
15456 * macroscope.h: (sal_macro_scope, user_macro_scope)
15457 (default_macro_scope): Return unique_xmalloc_ptr.
15458 * macroscope.c (sal_macro_scope, user_macro_scope)
15459 (default_macro_scope): Return unique_xmalloc_ptr.
15460 * macroexp.h (macro_expand, macro_expand_once): Return
15461 unique_xmalloc_ptr.
15462 * macroexp.c (macro_expand, macro_expand_once): Return
15463 unique_xmalloc_ptr.
15464 * macrocmd.c (macro_expand_command, macro_expand_once_command)
15465 (info_macro_command, info_macros_command): Use
15466 unique_xmalloc_ptr.
15467 * compile/compile-c-support.c (write_macro_definitions): Use
15468 unique_xmalloc_ptr.
15469 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
15470
15471 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
15472
15473 * value.c (value_static_field): Assign field type instead of
15474 containing type when returning an optimized out value.
15475
15476 2018-02-06 Yao Qi <yao.qi@linaro.org>
15477
15478 * ft32-tdep.c (ft32_read_pc): Remove.
15479 (ft32_write_pc): Remove.
15480 (ft32_gdbarch_init): Update.
15481 * m32r-tdep.c (m32r_read_pc): Remove.
15482 (m32r_gdbarch_init): Update.
15483 * mep-tdep.c (mep_read_pc): Remove.
15484 (mep_gdbarch_init): Update.
15485 * microblaze-tdep.c (microblaze_write_pc): Remove.
15486 (microblaze_gdbarch_init): Update.
15487 * mn10300-tdep.c (mn10300_read_pc): Remove.
15488 (mn10300_write_pc): Remove.
15489 (mn10300_gdbarch_init): Update.
15490 * moxie-tdep.c (moxie_read_pc): Remove.
15491 (moxie_write_pc): Remove.
15492 (moxie_gdbarch_init): Update.
15493
15494 2018-02-06 Yao Qi <yao.qi@linaro.org>
15495
15496 * expprint.c (print_subexp_standard): Handle
15497 OP_F77_UNDETERMINED_ARGLIST.
15498 (dump_subexp_body_standard): Likewise.
15499
15500 2018-02-05 Alan Hayward <alan.hayward@arm.com>
15501
15502 * target-descriptions.c (tdesc_element_visitor) Add empty
15503 implementations.
15504 (tdesc_type): Move make_gdb_type from here.
15505 (tdesc_type_builtin): Likewise.
15506 (tdesc_type_vector): Likewise.
15507 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
15508 (make_gdb_type_struct): Move from tdesc_type_with_fields.
15509 (make_gdb_type_union): Likewise.
15510 (make_gdb_type_flags): Likewise.
15511 (make_gdb_type_enum): Likewise.
15512 (make_gdb_type): New function.
15513 (tdesc_register_type): Use static make_gdb_type.
15514
15515 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
15516
15517 * infcmd.c (default_print_one_register_info): Align natural-format
15518 column values consistently one under another.
15519 (pad_to_column): New function.
15520
15521 2018-02-05 Joel Brobecker <brobecker@adacore.com>
15522
15523 * dwarf2read.c (dwarf2_physname): Move commment.
15524
15525 2018-02-01 Leszek Swirski <leszeks@google.com>
15526
15527 * varobj.c (varobj_formatted_print_options): Allow recursive
15528 pretty printing if pretty printing is enabled.
15529
15530 2018-02-01 Leszek Swirski <leszeks@google.com>
15531
15532 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
15533 names after a structop as a filename.
15534
15535 2018-02-01 Yao Qi <yao.qi@linaro.org>
15536
15537 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
15538 (arm_record_coproc_data_proc): Likewise.
15539
15540 2018-02-01 Yao Qi <yao.qi@linaro.org>
15541
15542 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
15543
15544 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
15545
15546 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
15547 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
15548
15549 2018-01-31 Pedro Alves <palves@redhat.com>
15550
15551 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
15552 * inflow.c (child_terminal_save_inferior): Wrap reference to
15553 tcgetpgrp in HAVE_TERMIOS_H.
15554 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
15555 _WIN32.
15556 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
15557 always iterate over all inferiors.
15558 (gdbsim_cntrl_c): Adjust.
15559 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
15560
15561 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15562
15563 * gdbtypes.c (lookup_array_range_type): Make sure the array's
15564 index type is objfile-owned if the element type is as well.
15565
15566 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15567
15568 GDB 8.1 released.
15569
15570 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
15571
15572 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
15573 "features/s390x-linux64.c".
15574 (_initialize_s390_linux_tdep): Remove initialization of tdescs
15575 s390_linux32 and s390x_linux64.
15576 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
15577 default tdesc.
15578 * s390-tdep.c: Include "features/s390-linux32.c" and
15579 "features/s390x-linux64.c".
15580 (s390_tdesc_valid): Add check for tdesc_has_registers.
15581 (s390_gdbarch_init): Make sure there is always a valid tdesc.
15582 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
15583 tdesc_s390x_linux64.
15584 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
15585 tdesc_s390x_linux64 to...
15586 * s390-tdep.h: ...here.
15587
15588 2018-01-30 Pedro Alves <palves@redhat.com>
15589
15590 PR gdb/13211
15591 * config.in, configure: Regenerate.
15592 * configure.ac: Check for getpgid.
15593 * go32-nat.c (go32_pass_ctrlc): New.
15594 (go32_target): Install it.
15595 * inf-child.c (inf_child_target): Install
15596 child_terminal_save_inferior, child_pass_ctrlc and
15597 child_interrupt.
15598 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
15599 (inf_ptrace_target): No longer install it.
15600 * infcmd.c (interrupt_target_1): Adjust.
15601 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
15602 (child_interrupt): Declare.
15603 (inferior::terminal_state): New.
15604 * inflow.c (struct terminal_info): Update comments.
15605 (inferior_process_group): Delete.
15606 (terminal_is_ours): Delete.
15607 (gdb_tty_state): New.
15608 (child_terminal_init): Adjust.
15609 (is_gdb_terminal, sharing_input_terminal_1)
15610 (sharing_input_terminal): New functions.
15611 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
15612 Set the process's actual process group in the foreground if
15613 possible. Handle is_ours_for_output/is_ours distinction. Don't
15614 mark terminal as the inferior's if not sharing GDB's terminal.
15615 Don't check attach_flag.
15616 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
15617 pass down a target_terminal_state.
15618 (child_terminal_save_inferior): New, factored out from ...
15619 (child_terminal_ours_1): ... this. Handle
15620 target_terminal_state::is_ours_for_output.
15621 (child_interrupt, child_pass_ctrlc): New.
15622 (inflow_inferior_exit): Clear the inferior's terminal_state.
15623 (copy_terminal_info): Copy the inferior's terminal state.
15624 (_initialize_inflow): Remove reference to terminal_is_ours.
15625 * inflow.h (inferior_process_group): Delete.
15626 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
15627 * procfs.c (procfs_target): Don't install procfs_interrupt.
15628 (procfs_interrupt): Delete.
15629 * remote.c (remote_serial_quit_handler): Adjust.
15630 (remote_interrupt): Remove ptid parameter. Adjust.
15631 * target-delegates.c: Regenerate.
15632 * target.c: Include "terminal.h".
15633 (target_terminal::terminal_state): Rename to ...
15634 (target_terminal::m_terminal_state): ... this.
15635 (target_terminal::init): Adjust.
15636 (target_terminal::inferior): Adjust to per-inferior
15637 terminal_state.
15638 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
15639 (target_terminal::ours, target_terminal::ours_for_output): Use
15640 target_terminal_is_ours_kind.
15641 (target_interrupt): Remove ptid parameter. Adjust.
15642 (default_target_pass_ctrlc): Adjust.
15643 * target.h (target_ops::to_terminal_save_inferior): New field.
15644 (target_ops::to_interrupt): Remove ptid_t parameter.
15645 (target_interrupt): Remove ptid_t parameter. Update comment.
15646 (target_pass_ctrlc): Update comment.
15647 * target/target.h (target_terminal_state): New scoped enum,
15648 factored out of ...
15649 (target_terminal::terminal_state): ... here.
15650 (target_terminal::inferior): Update comments.
15651 (target_terminal::restore_inferior): New.
15652 (target_terminal::is_inferior, target_terminal::is_ours)
15653 (target_terminal::is_ours_for_output): Adjust.
15654 (target_terminal::scoped_restore_terminal_state): Adjust to
15655 rename, and call restore_inferior() instead of inferior().
15656 (target_terminal::scoped_restore_terminal_state::m_state): Change
15657 type.
15658 (target_terminal::terminal_state): Rename to ...
15659 (target_terminal::m_terminal_state): ... this and change type.
15660
15661 2018-01-30 Pedro Alves <palves@redhat.com>
15662
15663 * linux-nat.c (wait_for_signal): New function.
15664 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
15665 directly.
15666 (async_terminal_is_ours)
15667 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
15668 (linux_nat_add_target): Don't override
15669 to_terminal_inferior/to_terminal_ours.
15670
15671 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
15672
15673 * remote.c (remote_follow_fork): Don't call "detach_inferior".
15674
15675 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
15676
15677 * dwarf2read.c (free_dwo_files): Add forward-declaration.
15678 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
15679 dwarf2_per_objfile_free here.
15680 (dwarf2_per_objfile_free): Remove.
15681 (_initialize_dwarf2_read): Don't register
15682 dwarf2_per_objfile_free as a registry cleanup.
15683
15684 2018-01-27 Eli Zaretskii <eliz@gnu.org>
15685
15686 Avoid compilation errors in MinGW native builds
15687
15688 The error is triggered by including python-internal.h, and the
15689 error message is:
15690
15691 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
15692 from build-gnulib/import/math.h:27,
15693 from d:/usr/Python26/include/pyport.h:235,
15694 from d:/usr/Python26/include/Python.h:58,
15695 from python/python-internal.h:94,
15696 from python/py-arch.c:24:
15697 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
15698 using ::hypot;
15699 ^~~~~
15700
15701 This happens because Python headers define 'hypot' to expand t
15702 '_hypot' in the Windows builds.
15703 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
15704 'hypoth'. This avoids a compilation error.
15705
15706 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15707
15708 * MAINTAINERS (Write After Approval): Fix ordering.
15709
15710 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15711
15712 * MAINTAINERS (Write After Approval): Add Alan Hayward.
15713
15714 2018-01-26 Alan Modra <amodra@gmail.com>
15715
15716 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
15717 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
15718 Remove nop. Make const. Comment.
15719 (powerpc32_plt_stub_so_2): New.
15720 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
15721 Correct count. Update uses.
15722 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
15723 Move common code reading PLT entry word. Correct
15724 powerpc32_plt_stub PLT address calculation.
15725 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
15726 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
15727 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
15728 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
15729 (ppc64_standard_linkage8): Likewise.
15730 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
15731 Correct insns description.
15732 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
15733
15734 2018-01-24 Pedro Alves <palves@redhat.com>
15735
15736 GCC PR libstdc++/83906
15737 * gdbtypes.c (operator==(const dynamic_prop &,
15738 const dynamic_prop &)): New.
15739 (operator==(const range_bounds &, const range_bounds &)): New.
15740 (check_types_equal): Use them instead of memcmp.
15741 * gdbtypes.h (operator==(const dynamic_prop &,
15742 const dynamic_prop &)): Declare.
15743 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
15744 (operator==(const range_bounds &, const range_bounds &)): Declare.
15745 (operator!=(const range_bounds &, const range_bounds &)): Declare.
15746
15747 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15748
15749 * s390-linux-tdep.c (s390_record_address_mask)
15750 (s390_record_calc_disp_common, s390_record_calc_disp)
15751 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15752 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15753 (s390_process_record): Move to s390-tdep.c.
15754 (s390_linux_init_abi_any): Adjust.
15755 * s390-tdep.c (s390_record_address_mask)
15756 (s390_record_calc_disp_common, s390_record_calc_disp)
15757 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15758 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15759 (s390_process_record): Moved from s390-linux-tdep.c
15760 (s390_gdbarch_init): Adjust.
15761
15762 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15763
15764 * s390-linux-nat.c (s390-tdep.h): New include.
15765 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
15766 (HFILES_NO_SRCDIR): Add s390-tdep.h.
15767 (ALLDEPFILES): Add s390-tdep.c.
15768 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
15769 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
15770 * s390-tdep.h: ...this. New file.
15771 * s390-linux-tdep.c (s390-tdep.h): New include.
15772 (_initialize_s390_tdep): Rename to...
15773 (_initialize_s390_linux_tdep): ...this and adjust.
15774 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
15775 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
15776 s390-tdep.h.
15777 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
15778 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
15779 (s390_is_partial_instruction, s390_software_single_step)
15780 (is_non_branch_ril, s390_displaced_step_copy_insn)
15781 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
15782 (s390_prologue_data, s390_addr, s390_store, s390_load)
15783 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
15784 (s390_register_call_saved, s390_guess_tracepoint_registers)
15785 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
15786 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
15787 (s390_pseudo_register_name, s390_pseudo_register_type)
15788 (s390_pseudo_register_read, s390_pseudo_register_write)
15789 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
15790 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
15791 (s390_addr_bits_remove, s390_address_class_type_flags)
15792 (s390_address_class_type_flags_to_name)
15793 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
15794 (s390_function_arg_float, s390_function_arg_vector)
15795 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
15796 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
15797 (s390_frame_align, s390_register_return_value, s390_return_value)
15798 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
15799 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
15800 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
15801 (s390_trad_frame_prev_register, s390_unwind_cache)
15802 (s390_prologue_frame_unwind_cache)
15803 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
15804 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
15805 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
15806 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
15807 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
15808 (s390_frame_base_address, s390_local_base_address)
15809 (s390_frame_base, s390_gcc_target_options)
15810 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
15811 (s390_validate_reg_range, s390_tdesc_valid)
15812 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
15813 * s390-tdep.c: ...this. New file.
15814
15815 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15816
15817 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
15818 (s390_process_record, s390_gdbarch_tdep_alloc)
15819 (s390_linux_init_abi_any): Use/set new hook.
15820
15821 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15822
15823 * s390-linux-tdep.c (osabi.h): New include.
15824 (s390_linux_init_abi_31, s390_linux_init_abi_64)
15825 (s390_linux_init_abi_any): New functions.
15826 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
15827
15828 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15829
15830 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
15831 tdesc_has_registers check
15832
15833 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15834
15835 * s390-linux-tdep.c (s390_tdesc_valid): New function.
15836 (s390_validate_reg_range): New macro.
15837 (s390_gdbarch_init): Adjust.
15838
15839 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15840
15841 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
15842 (s390_gdbarch_tdep_alloc): Adjust.
15843 (s390_gdbarch_init): Adjust.
15844
15845 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15846
15847 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
15848 <have_tdb>: Change type to bool.
15849 (s390_gdbarch_tdep_alloc): Adjust.
15850 (s390_gdbarch_init): Adjust.
15851
15852 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15853
15854 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
15855 (gdbarch_tdep) <have_upper, have_vx>: New fields.
15856 (s390_gdbarch_tdep_alloc): New function.
15857 (s390_gdbarch_init): Allocate tdep at start and use its fields
15858 instead of separate variables.
15859
15860 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15861
15862 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
15863 when looking for cached gdbarch and add comment for remaining.
15864
15865 2018-01-22 Pedro Alves <palves@redhat.com>
15866 Sergio Durigan Junior <sergiodj@redhat.com>
15867
15868 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
15869 case.
15870
15871 2018-01-22 Maciej W. Rozycki <macro@mips.com>
15872
15873 * MAINTAINERS: Update my company e-mail address.
15874
15875 2018-01-22 Yao Qi <yao.qi@linaro.org>
15876
15877 * regcache.c (cooked_write_test): New function.
15878 (_initialize_regcache): Register the test.
15879
15880 2018-01-22 Yao Qi <yao.qi@linaro.org>
15881
15882 * ia64-tdep.c (ia64_pseudo_register_read): Call
15883 regcache->cooked_read instead of regcache_cooked_read_unsigned.
15884 * m32c-tdep.c (m32c_cat_read): Likewise.
15885 (m32c_r3r2r1r0_read): Likewise.
15886 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15887 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15888
15889 2018-01-22 Yao Qi <yao.qi@linaro.org>
15890
15891 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
15892 method raw_read instead of regcache_raw_read.
15893 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15894 * arm-tdep.c (arm_neon_quad_read): Likewise.
15895 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15896 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15897 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15898 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
15899 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15900 (i386_pseudo_register_read_into_value): Likewise.
15901 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15902 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15903 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15904 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
15905 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
15906 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15907 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15908 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15909 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
15910
15911 2018-01-22 Yao Qi <yao.qi@linaro.org>
15912
15913 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
15914 * configure.tgt: Remove target mt.
15915 * mt-tdep.c: Remove.
15916 * regcache.c (cooked_read_test): Remove the check for mt.
15917
15918 2018-01-22 Yao Qi <yao.qi@linaro.org>
15919
15920 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
15921 instead of gdbarch_pseudo_register_read_value.
15922
15923 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15924
15925 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
15926 language is Ada.
15927
15928 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15929
15930 * linespec.c (create_sals_line_offset): Remove code that preserved
15931 the symtab_and_line's line number.
15932
15933 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15934
15935 * varobj.c (varobj_create): Don't set valid_block when creating a
15936 floating varobj.
15937
15938 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15939
15940 * varobj.c (varobj_create): Remove out of date comment.
15941
15942 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15943
15944 PR mi/20395
15945 * ada-exp.y (write_var_from_sym): Pass extra parameter when
15946 updating innermost block.
15947 * parse.c (innermost_block_tracker::update): Take extra type
15948 parameter, and check types match before updating innermost block.
15949 (write_dollar_variable): Update innermost block for registers.
15950 * parser-defs.h (enum innermost_block_tracker_type): New enum.
15951 (innermost_block_tracker::innermost_block_tracker): Initialise
15952 m_types member.
15953 (innermost_block_tracker::reset): Take type parameter.
15954 (innermost_block_tracker::update): Take type parameter, and pass
15955 type through as needed.
15956 (innermost_block_tracker::m_types): New member.
15957 * varobj.c (varobj_create): Pass type when reseting innermost
15958 block.
15959
15960 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15961
15962 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
15963 * ada-lang.c (resolve_subexp): Likewise.
15964 * breakpoint.c (set_breakpoint_condition) Likewise.
15965 (watch_command_1) Likewise.
15966 * c-exp.y (variable): Likewise.
15967 * d-exp.y (PrimaryExpression): Likewise.
15968 * f-exp.y (variable): Likewise.
15969 * go-exp.y (variable): Likewise.
15970 * m2-exp.y (variable): Likewise.
15971 * objfiles.c (objfile::~objfile): Likewise.
15972 * p-exp.y (variable): Likewise.
15973 * parse.c (innermost_block): Change type.
15974 * parser-defs.h (class innermost_block_tracker): New.
15975 (innermost_block): Change to innermost_block_tracker.
15976 * printcmd.c (display_command): Switch to innermost_block API.
15977 (do_one_display): Likewise.
15978 * rust-exp.y (do_one_display): Likewise.
15979 * symfile.c (clear_symtab_users): Likewise.
15980 * varobj.c (varobj_create): Switch to innermost_block API, replace
15981 use of innermost_block with block stored on varobj object.
15982
15983 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15984
15985 * expression.h (innermost_block): Remove declaration.
15986 * varobj.c: Add 'parser-defs.h' include.
15987
15988 2018-01-19 Tom Tromey <tom@tromey.com>
15989
15990 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
15991 symbols in the static and global blocks.
15992
15993 2018-01-19 James Clarke <jrtc27@jrtc27.com>
15994
15995 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
15996 gdb_ptrace.h, and move including gdb_wait.h ...
15997 * nat/linux-ptrace.h: ... to here.
15998
15999 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
16000
16001 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
16002 inf_ptrace_detach_success.
16003 (inf_ptrace_detach_success): Add inferior parameter, use it
16004 instead of inferior_ptid, pass it to detach_inferior.
16005 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
16006 parameter.
16007 * inferior.c (detach_inferior): Add overload that takes an
16008 inferior object.
16009 * inferior.h (detach_inferior): Likewise.
16010 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
16011 use inferior_ptid, adjust call to inf_ptrace_detach_success.
16012 * linux-thread-db.c (thread_db_detach): Use inf parameter.
16013
16014 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
16015
16016 * target.h (struct target_ops) <to_detach>: Add inferior
16017 parameter.
16018 (target_detach): Likewise.
16019 * target.c (dispose_inferior): Pass inferior down.
16020 (target_detach): Pass inferior down. Assert that it is equal to
16021 the current inferior.
16022 * aix-thread.c (aix_thread_detach): Pass inferior down.
16023 * corefile.c (core_file_command): Pass current_inferior() down.
16024 * corelow.c (core_detach): Add inferior parameter.
16025 * darwin-nat.c (darwin_detach): Likewise.
16026 * gnu-nat.c (gnu_detach): Likewise.
16027 * inf-ptrace.c (inf_ptrace_detach): Likewise.
16028 * infcmd.c (detach_command): Pass current_inferior() down to
16029 target_detach.
16030 * infrun.c (follow_fork_inferior): Pass parent_inf to
16031 target_detach.
16032 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
16033 target_detach.
16034 * linux-nat.c (linux_nat_detach): Add inferior parameter.
16035 * linux-thread-db.c (thread_db_detach): Likewise.
16036 * nto-procfs.c (procfs_detach): Likewise.
16037 * procfs.c (procfs_detach): Likewise.
16038 * record.c (record_detach): Likewise.
16039 * record.h (struct inferior): Forward-declare.
16040 (record_detach): Add inferior parameter.
16041 * remote-sim.c (gdbsim_detach): Likewise.
16042 * remote.c (remote_detach_1): Likewise.
16043 (remote_detach): Likewise.
16044 (extended_remote_detach): Likewise.
16045 * sol-thread.c (sol_thread_detach): Likewise.
16046 * target-debug.h (target_debug_print_inferior_p): New macro.
16047 * target-delegates.c: Re-generate.
16048 * top.c (kill_or_detach): Pass inferior down to target_detach.
16049 * windows-nat.c (windows_detach): Add inferior parameter.
16050
16051 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
16052
16053 * target.h (struct target_ops) <to_detach>: Remove args
16054 parameter.
16055 (target_detach): Likewise.
16056 * target.c (dispose_inferior): Adjust.
16057 (target_detach): Remove args parameter, adjust.
16058 * aix-thread.c (aix_thread_detach): Adjust.
16059 * corefile.c (core_file_command): Adjust.
16060 * corelow.c (core_detach): Adjust.
16061 * darwin-nat.c (darwin_detach): Adjust.
16062 * gnu-nat.c (gnu_detach): Adjust.
16063 * inf-ptrace.c (inf_ptrace_detach): Adjust.
16064 * infcmd.c (detach_command): Adjust
16065 * infrun.c (follow_fork_inferior): Adjust.
16066 (handle_vfork_child_exec_or_exit): Adjust.
16067 * linux-fork.c (linux_fork_detach): Remove args parameter.
16068 * linux-fork.h (linux_fork_detach): Likewise.
16069 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
16070 * linux-thread-db.c (thread_db_detach): Likewise.
16071 * nto-procfs.c (procfs_detach): Likewise.
16072 * procfs.c (procfs_detach): Likewise.
16073 (do_detach): Remove signo parameter.
16074 * record.c (record_detach): Remove args parameter.
16075 * record.h (record_detach): Likewise.
16076 * remote-sim.c (gdbsim_detach): Likewise.
16077 * remote.c (remote_detach_1): Likewise.
16078 (remote_detach): Likewise.
16079 (extended_remote_detach): Likewise.
16080 * sol-thread.c (sol_thread_detach): Likewise.
16081 * target-delegates.c: Re-generate.
16082 * top.c (struct qt_args) <args>: Remove field.
16083 (kill_or_detach): Don't pass args.
16084 (quit_force): Don't set args.
16085 * windows-nat.c (windows_detach): Remove args parameter.
16086
16087 2018-01-19 Yao Qi <yao.qi@linaro.org>
16088
16089 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
16090 (arm_linux_init_abi): Install it.
16091
16092 2018-01-19 Yao Qi <yao.qi@linaro.org>
16093
16094 * osabi.c (gdb_osabi_names): Extend the regexp for
16095 arm-linux-gnueabihf.
16096
16097 2018-01-18 Yao Qi <yao.qi@linaro.org>
16098
16099 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
16100 m_abbrevs.
16101 (abbrev_table::add_abbrev): Update.
16102 (abbrev_table::lookup_abbrev): Update.
16103
16104 2018-01-18 Yao Qi <yao.qi@linaro.org>
16105
16106 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
16107
16108 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
16109
16110 * compile/compile.c (compile_to_object): Convert "triplet_rx"
16111 to "std::string".
16112
16113 2018-01-17 Tom Tromey <tom@tromey.com>
16114
16115 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
16116
16117 2018-01-17 Tom Tromey <tom@tromey.com>
16118
16119 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
16120 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
16121 (create_array_type_with_stride): Update.
16122 * dwarf2read.c (set_die_type): Update.
16123
16124 2018-01-17 Tom Tromey <tom@tromey.com>
16125
16126 * dwarf2read.c (delayed_method_info): Remove typedef.
16127 (dwarf2_cu::method_info): Now a std::vector.
16128 (add_to_method_list): Update.
16129 (free_delayed_list): Remove.
16130 (compute_delayed_physnames): Update.
16131 (process_full_comp_unit, process_full_type_unit): Clear the method
16132 list. Remove cleanups.
16133 (psymtab_include_file_name): Add name_holder parameter. Use
16134 unique_xmalloc_ptr.
16135 (dwarf_decode_lines): Update.
16136
16137 2018-01-17 Tom Tromey <tom@tromey.com>
16138 Simon Marchi <simon.marchi@ericsson.com>
16139
16140 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
16141 (dwarf2_per_objfile::free_cached_comp_units)
16142 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
16143 (init_cutu_and_read_dies_no_follow): Update.
16144 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
16145 (dwarf2_cu::~dwarf2_cu): New.
16146 (free_heap_comp_unit, free_stack_comp_unit): Remove.
16147 (age_cached_comp_units, free_one_cached_comp_unit): Update.
16148
16149 2018-01-17 Tom Tromey <tom@tromey.com>
16150 Simon Marchi <simon.marchi@ericsson.com>
16151
16152 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
16153 (struct die_reader_specs) <abbrev_table>: New member.
16154 (struct abbrev_table): Add constructor.
16155 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
16156 <abbrev_obstack>: Now an auto_obstack.
16157 (abbrev_table_up): New typedef.
16158 (init_cu_die_reader): Add abbrev_table parameter.
16159 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
16160 Add result_dwo_abbrev_table.
16161 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
16162 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
16163 Update.
16164 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
16165 parameter.
16166 (skip_children): Update.
16167 (abbrev_table::alloc_abbrev): Rename from
16168 abbrev_table_alloc_abbrev.
16169 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
16170 (abbrev_table::lookup_abbrev): Rename from
16171 abbrev_table_lookup_abbrev.
16172 (abbrev_table_read_table): Return abbrev_table_up.
16173 (abbrev_table_free, abbrev_table_free_cleanup)
16174 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
16175 (load_partial_dies): Update.
16176
16177 2018-01-17 Tom Tromey <tom@tromey.com>
16178
16179 * dwarf2read.c (dwarf2_compute_name): Update comment.
16180 (read_func_scope, read_variable): Update.
16181 (new_symbol): Remove.
16182 (new_symbol_full): Rename to new_symbol.
16183
16184 2018-01-17 Mike Gulick <mgulick@mathworks.com>
16185
16186 PR gdb/16577
16187 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
16188 a warning instead of throwing an error, set section size to 0 and return
16189 NULL.
16190 * gdb_bfd.h (gdb_bfd_map_section): Update description.
16191
16192 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
16193
16194 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
16195 std::string.
16196 (linux_ptrace_attach_fail_reason_string): Likewise.
16197 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
16198 Likewise.
16199 (linux_ptrace_attach_fail_reason_string): Likewise.
16200 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
16201
16202 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
16203
16204 * linux-nat.c (linux_nat_attach): Remove xstrdup.
16205
16206 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
16207
16208 PR gdb/21559
16209 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
16210 checking for fs_base/gs_base fields in struct user_regs_struct.
16211 * configure: Regenerate.
16212
16213 2018-01-17 Yao Qi <yao.qi@linaro.org>
16214
16215 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
16216 function.
16217 (aarch64_linux_init_abi): Install it to gdbarch hook
16218 gcc_target_options.
16219
16220 2018-01-15 Pedro Alves <palves@redhat.com>
16221
16222 * common/signals-state-save-restore.c
16223 (save_original_signals_state): Fix typos.
16224
16225 2017-01-12 Tom Tromey <tom@tromey.com>
16226 Sergio Durigan Junior <sergiodj@redhat.com>
16227
16228 * Makefile.in (install-only): Install gdb-add-index.
16229
16230 2018-01-12 John Baldwin <jhb@FreeBSD.org>
16231
16232 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
16233
16234 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
16235
16236 * infrun.c (keep_going_pass_signal): Clear step-over info when
16237 insert_breakpoints fails.
16238
16239 2018-01-11 Pedro Alves <palves@redhat.com>
16240
16241 PR gdb/22583
16242 * infrun.c (resume): Rename to ...
16243 (resume_1): ... this.
16244 (resume): Reimplement as wrapper around resume_1.
16245
16246 2018-01-11 Pedro Alves <palves@redhat.com>
16247
16248 PR remote/22597
16249 * remote.c (remote_parse_stop_reply): Default to the last-set
16250 general thread instead of to 'magic_null_ptid'.
16251
16252 2018-01-10 Pedro Alves <palves@redhat.com>
16253
16254 * language.h (language_get_symbol_name_matcher): Rename ...
16255 (get_symbol_name_matcher): ... this.
16256 * language.c (language_get_symbol_name_matcher): Ditto.
16257 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
16258 callers adjusted.
16259
16260 2018-01-10 Pedro Alves <palves@redhat.com>
16261
16262 PR gdb/22670
16263 * dwarf2read.c
16264 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
16265 Adjust to use language_get_symbol_name_matcher instead of
16266 language_defn::la_get_symbol_name_matcher.
16267 * language.c (language_get_symbol_name_matcher): If in Ada mode
16268 and the lookup name is a verbatim match, return Ada's matcher.
16269 * language.h (language_get_symbol_name_matcher): Adjust comment.
16270 (ada_lookup_name_info::verbatim_p):: New method.
16271
16272 2018-01-10 Pedro Alves <palves@redhat.com>
16273
16274 PR gdb/22670
16275 * ada-lang.c (ada_collect_symbol_completion_matches): If the
16276 minsym's language is language_auto or language_cplus, pass down
16277 language_ada instead.
16278 * symtab.c (compare_symbol_name): Don't frob symbol language here.
16279
16280 2018-01-10 Pedro Alves <palves@redhat.com>
16281
16282 PR gdb/22670
16283 * minsyms.c (linkage_name_str): New function.
16284 (iterate_over_minimal_symbols): Use it.
16285
16286 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16287
16288 * NEWS: Document that 'info proc' now works on FreeBSD.
16289
16290 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16291
16292 * configure.ac: Check for kinfo_getfile in libutil.
16293 * configure: Regenerate.
16294 * config.in: Regenerate.
16295 * fbsd-nat.c: Include "fbsd-tdep.h".
16296 (fbsd_fetch_cmdline): New.
16297 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
16298 rather than calling error.
16299 (fbsd_info_proc): New.
16300 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
16301 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
16302 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
16303
16304 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16305
16306 * fbsd-nat.c (struct free_deleter): Remove.
16307 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
16308
16309 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16310
16311 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
16312 NULL for an empty pathname.
16313
16314 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16315
16316 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
16317 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
16318 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
16319 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
16320 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
16321 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
16322 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
16323 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
16324 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
16325 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
16326 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
16327 (fbsd_core_fetch_timeval, fbsd_print_sigset)
16328 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
16329 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
16330 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
16331
16332 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
16333
16334 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
16335 (gnu_xfer_auxv): New function.
16336 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
16337 TARGET_OBJECT_AUXV.
16338
16339 2018-01-08 Yao Qi <yao.qi@linaro.org>
16340 Simon Marchi <simon.marchi@ericsson.com>
16341
16342 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
16343 common/selftest.c.
16344 (COMMON_OBS): Remove selftest.o.
16345 * configure.ac: Append selftest-arch.c and common/selftest.c to
16346 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
16347 * configure: Re-generated.
16348 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
16349 GDB_SELF_TEST.
16350 (maintenance_info_selftests): Likewise.
16351
16352 2018-01-08 Xavier Roirand <roirand@adacore.com>
16353
16354 * ada-valprint.c (val_print_packed_array_elements): Use
16355 proper number of elements when printing an array indexed
16356 by an enumeration type.
16357
16358 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16359
16360 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
16361 (dw2_get_file_names_reader): Adjust.
16362 (lookup_dwo_signatured_type): Adjust.
16363 (lookup_dwp_signatured_type): Adjust.
16364 (lookup_signatured_type): Adjust.
16365 (create_type_unit_group): Adjust.
16366 (get_type_unit_group): Adjust.
16367 (process_psymtab_comp_unit_reader): Adjust.
16368 (build_type_psymtabs_reader): Adjust.
16369 (scan_partial_symbols): Adjust.
16370 (add_partial_symbol): Adjust.
16371 (add_partial_subprogram): Adjust.
16372 (peek_die_abbrev): Adjust.
16373 (fixup_go_packaging): Adjust.
16374 (process_imported_unit_die): Adjust.
16375 (dwarf2_compute_name): Adjust.
16376 (dwarf2_physname): Adjust.
16377 (read_import_statement): Adjust.
16378 (handle_DW_AT_stmt_list): Adjust.
16379 (read_file_scope): Adjust.
16380 (read_func_scope): Adjust.
16381 (read_lexical_block_scope): Adjust.
16382 (read_call_site_scope): Adjust.
16383 (read_variable): Adjust.
16384 (dwarf2_rnglists_process): Adjust.
16385 (dwarf2_ranges_process): Adjust.
16386 (dwarf2_ranges_read): Adjust.
16387 (dwarf2_get_pc_bounds): Adjust.
16388 (dwarf2_record_block_ranges): Adjust.
16389 (dwarf2_add_field): Adjust.
16390 (dwarf2_add_member_fn): Adjust.
16391 (read_structure_type): Adjust.
16392 (process_structure_scope): Adjust.
16393 (read_enumeration_type): Adjust.
16394 (read_array_type): Adjust.
16395 (mark_common_block_symbol_computed): Adjust.
16396 (read_common_block): Adjust.
16397 (read_namespace_type): Adjust.
16398 (read_namespace): Adjust.
16399 (read_module_type): Adjust.
16400 (read_tag_pointer_type): Adjust.
16401 (read_tag_ptr_to_member_type): Adjust.
16402 (read_tag_string_type): Adjust.
16403 (read_subroutine_type): Adjust.
16404 (read_typedef): Adjust.
16405 (read_base_type): Adjust.
16406 (attr_to_dynamic_prop): Adjust.
16407 (read_subrange_type): Adjust.
16408 (read_unspecified_type): Adjust.
16409 (dwarf2_read_abbrevs): Adjust.
16410 (load_partial_dies): Adjust.
16411 (read_partial_die): Adjust.
16412 (find_partial_die): Adjust.
16413 (guess_partial_die_structure_name): Adjust.
16414 (fixup_partial_die): Adjust.
16415 (read_attribute_value): Adjust.
16416 (read_addr_index): Adjust.
16417 (read_addr_index_from_leb128): Adjust.
16418 (read_str_index): Adjust.
16419 (dwarf2_string_attr): Adjust.
16420 (get_debug_line_section): Adjust.
16421 (dwarf_decode_line_header): Adjust.
16422 (lnp_state_machine::check_line_address): Adjust.
16423 (dwarf_decode_lines_1): Adjust.
16424 (dwarf_decode_lines): Adjust.
16425 (dwarf2_start_symtab): Adjust.
16426 (var_decode_location): Adjust.
16427 (new_symbol_full): Adjust.
16428 (dwarf2_const_value_data): Adjust.
16429 (dwarf2_const_value_attr): Adjust.
16430 (dwarf2_const_value): Adjust.
16431 (die_type): Adjust.
16432 (die_containing_type): Adjust.
16433 (build_error_marker_type): Adjust.
16434 (lookup_die_type): Adjust.
16435 (guess_full_die_structure_name): Adjust.
16436 (anonymous_struct_prefix): Adjust.
16437 (determine_prefix): Adjust.
16438 (dwarf2_name): Adjust.
16439 (follow_die_ref_or_sig): Adjust.
16440 (follow_die_offset): Adjust.
16441 (follow_die_ref): Adjust.
16442 (follow_die_sig_1): Adjust.
16443 (follow_die_sig): Adjust.
16444 (get_signatured_type): Adjust.
16445 (get_DW_AT_signature_type): Adjust.
16446 (decode_locdesc): Adjust.
16447 (dwarf_decode_macros): Adjust.
16448 (cu_debug_loc_section): Adjust.
16449 (fill_in_loclist_baton): Adjust.
16450 (dwarf2_symbol_mark_computed): Adjust.
16451 (init_one_comp_unit): Don't assign
16452 dwarf2_cu::dwarf2_per_objfile.
16453 (set_die_type): Adjust.
16454
16455 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16456
16457 * dwarf2read.c (struct mapped_debug_names): Add constructor.
16458 <dwarf2_per_objfile>: New field.
16459 (dwarf2_per_objfile): Remove global.
16460 (get_dwarf2_per_objfile): New function.
16461 (set_dwarf2_per_objfile): New function.
16462 (dwarf2_build_psymtabs_hard): Change objfile parameter to
16463 dwarf2_per_objfile.
16464 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16465 (read_abbrev_offset): Likewise.
16466 (read_indirect_string): Likewise.
16467 (read_indirect_line_string): Likewise.
16468 (read_indirect_string_at_offset): Likewise.
16469 (read_indirect_string_from_dwz): Likewise.
16470 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16471 dwarf2_per_objfile.
16472 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16473 (create_all_comp_units): Change objfile parameter to
16474 dwarf2_per_objfile.
16475 (create_all_type_units): Likewise.
16476 (process_queue): Add dwarf2_per_objfile parameter.
16477 (read_and_check_comp_unit_head): Likewise.
16478 (lookup_dwo_unit_in_dwp): Likewise.
16479 (get_dwp_file): Likewise.
16480 (process_cu_includes): Likewise.
16481 (struct free_dwo_file_cleanup_data): New struct.
16482 (dwarf2_has_info): Use get_dwarf2_per_objfile and
16483 set_dwarf2_per_objfile.
16484 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
16485 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
16486 context, adjust calls.
16487 (dw2_instantiate_symtab): Likewise.
16488 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
16489 (dw2_get_cu): Likewise.
16490 (create_cu_from_index_list): Change objfile parameter to
16491 dwarf2_per_objfile.
16492 (create_cus_from_index_list): Get dwarf2_per_objfile from
16493 context, adjust calls.
16494 (create_cus_from_index): Likewise.
16495 (create_signatured_type_table_from_index): Change objfile
16496 parameter to dwarf2_per_objfile.
16497 (create_signatured_type_table_from_debug_names): Change objfile
16498 parameter to dwarf2_per_objfile.
16499 (create_addrmap_from_index): Likewise.
16500 (create_addrmap_from_aranges): Likewise.
16501 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
16502 (dw2_setup): Remove.
16503 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
16504 context.
16505 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
16506 get_dwarf2_per_objfile.
16507 (dw2_forget_cached_source_info): Likewise.
16508 (dw2_map_symtabs_matching_filename): Likewise.
16509 (struct dw2_symtab_iterator) <index>: Remove.
16510 <dwarf2_per_objfile>: New field.
16511 (dw2_symtab_iter_init): Replace index parameter with
16512 dwarf2_per_objfile.
16513 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
16514 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
16515 (dw2_print_stats): Likewise.
16516 (dw2_dump): Likewise.
16517 (dw2_expand_symtabs_for_function): Likewise.
16518 (dw2_expand_all_symtabs): Likewise.
16519 (dw2_expand_symtabs_with_fullname): Likewise.
16520 (dw2_expand_marked_cus): Replace index and objfile parameters
16521 with dwarf2_per_objfile.
16522 (dw_expand_symtabs_matching_file_matcher): Add
16523 dwarf2_per_objfile parameter and adjust calls.
16524 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
16525 adjust calls.
16526 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
16527 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
16528 adjust calls.
16529 (create_cus_from_debug_names_list): Replace objfile parameter
16530 with dwarf2_per_objfile and adjust calls.
16531 (create_cus_from_debug_names): Likewise.
16532 (dwarf2_read_debug_names): Likewise.
16533 (mapped_debug_names::namei_to_name): Adjust call.
16534 (dw2_debug_names_iterator::next): Likewise.
16535 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
16536 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
16537 (dw2_debug_names_dump): Likewise.
16538 (dw2_debug_names_expand_symtabs_for_function): Likewise.
16539 (dw2_debug_names_expand_symtabs_matching): Likewise.
16540 (dwarf2_initialize_objfile): Likewise.
16541 (dwarf2_build_psymtabs): Likewise.
16542 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
16543 this_cu.
16544 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
16545 (read_and_check_comp_unit_head): Likewise.
16546 (read_abbrev_offset): Likewise.
16547 (create_debug_type_hash_table): Likewise.
16548 (create_debug_types_hash_table): Likewise.
16549 (create_all_type_units): Replace objfile parameter with
16550 dwarf2_per_objfile.
16551 (add_type_unit): Add dwarf2_per_objfile parameter.
16552 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
16553 with dwarf2_per_objfile.
16554 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
16555 (lookup_dwp_signatured_type): Likewise.
16556 (lookup_signatured_type): Likewise.
16557 (read_cutu_die_from_dwo): Likewise.
16558 (init_tu_and_read_dwo_dies): Likewise.
16559 (init_cutu_and_read_dies): Likewise.
16560 (init_cutu_and_read_dies_no_follow): Likewise.
16561 (allocate_type_unit_groups_table): Add objfile parameter.
16562 (create_type_unit_group): Use dwarf2_per_objfile from cu.
16563 (get_type_unit_group): Likewise.
16564 (process_psymtab_comp_unit): Update call.
16565 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
16566 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
16567 (print_tu_stats): Likewise.
16568 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
16569 in void* parameter.
16570 (build_type_psymtabs): Change objfile parameter to
16571 dwarf2_per_objfile.
16572 (process_skeletonless_type_unit): Use dwarf2_per_objfile
16573 passed in void* parameter.
16574 (process_skeletonless_type_units): Change objfile parameter to
16575 dwarf2_per_objfile.
16576 (set_partial_user): Likewise.
16577 (dwarf2_build_psymtabs_hard): Likewise.
16578 (read_comp_units_from_section): Likewise.
16579 (create_all_comp_units): Likewise.
16580 (scan_partial_symbols): Update calls.
16581 (add_partial_symbol): Likewise.
16582 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
16583 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
16584 (process_queue): Add dwarf2_per_objfile parameter.
16585 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
16586 (compute_compunit_symtab_includes): Likewise.
16587 (process_cu_includes): Add dwarf2_per_objfile parameter.
16588 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
16589 (process_full_type_unit): Likewise.
16590 (process_imported_unit_die): Update call.
16591 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
16592 (read_file_scope): Likewise.
16593 (allocate_dwo_file_hash_table): Add objfile parameter.
16594 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
16595 (create_cus_hash_table): Likewise.
16596 (create_dwp_hash_table): Likewise.
16597 (create_dwo_unit_in_dwp_v1): Likewise.
16598 (create_dwp_v2_section): Likewise.
16599 (create_dwo_unit_in_dwp_v2): Likewise.
16600 (lookup_dwo_unit_in_dwp): Likewise.
16601 (try_open_dwop_file): Likewise.
16602 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
16603 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
16604 cleanup to include a reference to dwarf2_per_objfile.
16605 (open_dwp_file): Add dwarf2_per_objfile parameter.
16606 (open_and_init_dwp_file): Likewise.
16607 (get_dwp_file): Likewise.
16608 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
16609 (queue_and_load_all_dwo_tus): Update call.
16610 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
16611 data.
16612 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
16613 (dwarf2_ranges_process): Likewise.
16614 (dwarf2_get_pc_bounds): Likewise.
16615 (mark_common_block_symbol_computed): Likewise.
16616 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16617 (dwarf2_read_abbrevs): Update call.
16618 (read_partial_die): Use dwarf2_per_objfile from cu.
16619 (find_partial_die): Likewise.
16620 (fixup_partial_die): Likewise.
16621 (read_attribute_value): Likewise.
16622 (read_indirect_string_at_offset_from): Add objfile parameter.
16623 (read_indirect_string_at_offset): Add dwarf2_per_objfile
16624 parameter.
16625 (read_indirect_string_from_dwz): Add objfile parameter.
16626 (read_indirect_string): Add objfile parameter.
16627 (read_addr_index_1): Add dwarf2_per_objfile parameter.
16628 (read_addr_index): Use dwarf2_per_objfile from cu.
16629 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
16630 call dw2_setup.
16631 (read_str_index): Use dwarf2_per_objfile from cu.
16632 (get_debug_line_section): Likewise.
16633 (read_formatted_entries): Add dwarf2_per_objfile parameter.
16634 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
16635 (new_symbol_full): Use dwarf2_per_objfile from cu.
16636 (build_error_marker_type): Likewise.
16637 (lookup_die_type): Likewise.
16638 (determine_prefix): Likewise.
16639 (follow_die_offset): Likewise.
16640 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
16641 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
16642 (dwarf2_fetch_die_type_sect_off): Likewise.
16643 (dwarf2_get_die_type): Likewise.
16644 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
16645 (get_signatured_type): Likewise.
16646 (get_DW_AT_signature_type): Likewise.
16647 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
16648 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
16649 (cu_debug_loc_section): Likewise.
16650 (fill_in_loclist_baton): Likewise.
16651 (dwarf2_symbol_mark_computed): Likewise.
16652 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16653 dwarf2_per_objfile.
16654 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
16655 parameter.
16656 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16657 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
16658 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
16659 (set_die_type): Use dwarf2_free_objfile from cu.
16660 (get_die_type_at_offset): Likewise.
16661 (dwarf2_per_objfile_free): Don't assign global variable.
16662 (debug_names) <constructor>: Add dwarf2_per_objfile
16663 parameter, update m_debugstrlookup construction.
16664 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
16665 parameter.
16666 <m_dwarf2_per_objfile>: New field.
16667 <lookup>: Use m_dwarf2_per_objfile.
16668 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
16669 (psyms_seen_size): Likewise.
16670 (write_gdbindex): Replace objfile parameter with
16671 dwarf2_per_objfile.
16672 (write_debug_names): Likewise.
16673 (write_psymtabs_to_index): Likewise.
16674 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
16675 calls.
16676
16677 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16678
16679 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
16680 <dwarf2_per_objfile>: New field.
16681 (struct dwarf2_per_cu_data) <objfile>: Remove.
16682 <dwarf2_per_objfile>: New field.
16683 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
16684 of objfile.
16685 (create_signatured_type_table_from_index): Likewise.
16686 (create_debug_type_hash_table): Likewise.
16687 (fill_in_sig_entry_from_dwo_entry): Likewise.
16688 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
16689 (create_type_unit_group): Assign dwarf2_per_objfile instead of
16690 objfile.
16691 (create_partial_symtab): Access objfile through
16692 dwarf2_per_objfile.
16693 (process_psymtab_comp_unit_reader): Likewise.
16694 (read_comp_units_from_section): Likewise.
16695 (scan_partial_symbols): Likewise.
16696 (add_partial_symbol): Likewise.
16697 (add_partial_subprogram): Likewise.
16698 (peek_die_abbrev): Likewise.
16699 (fixup_go_packaging): Likewise.
16700 (process_full_comp_unit): Likewise.
16701 (process_full_type_unit): Likewise.
16702 (process_imported_unit_die): Likewise.
16703 (dwarf2_compute_name): Likewise.
16704 (dwarf2_physname): Likewise.
16705 (read_import_statement): Likewise.
16706 (create_cus_hash_table): Assign dwarf2_physname instead of
16707 objfile.
16708 (read_func_scope): Access objfile through dwarf2_per_objfile.
16709 (read_lexical_block_scope): Likewise.
16710 (read_call_site_scope): Likewise.
16711 (read_variable): Likewise.
16712 (dwarf2_rnglists_process): Likewise.
16713 (dwarf2_ranges_process): Likewise.
16714 (dwarf2_ranges_read): Likewise.
16715 (dwarf2_record_block_ranges): Likewise.
16716 (dwarf2_add_field): Likewise.
16717 (dwarf2_add_member_fn): Likewise.
16718 (read_structure_type): Likewise.
16719 (process_structure_scope): Likewise.
16720 (read_enumeration_type): Likewise.
16721 (read_array_type): Likewise.
16722 (read_common_block): Likewise.
16723 (read_namespace_type): Likewise.
16724 (read_namespace): Likewise.
16725 (read_module_type): Likewise.
16726 (read_tag_pointer_type): Likewise.
16727 (read_tag_ptr_to_member_type): Likewise.
16728 (read_tag_string_type): Likewise.
16729 (read_subroutine_type): Likewise.
16730 (read_typedef): Likewise.
16731 (read_base_type): Likewise.
16732 (attr_to_dynamic_prop): Likewise.
16733 (read_subrange_type): Likewise.
16734 (read_unspecified_type): Likewise.
16735 (load_partial_dies): Likewise.
16736 (read_partial_die): Likewise.
16737 (find_partial_die): Likewise.
16738 (guess_partial_die_structure_name): Likewise.
16739 (fixup_partial_die): Likewise.
16740 (read_attribute_value): Likewise.
16741 (read_addr_index_from_leb128): Likewise.
16742 (dwarf2_read_addr_index): Likewise.
16743 (dwarf2_string_attr): Likewise.
16744 (lnp_state_machine::check_line_address): Likewise.
16745 (dwarf_decode_lines_1): Likewise.
16746 (dwarf_decode_lines): Likewise.
16747 (dwarf2_start_symtab): Likewise.
16748 (var_decode_location): Likewise.
16749 (new_symbol_full): Likewise.
16750 (dwarf2_const_value_data): Likewise.
16751 (dwarf2_const_value_attr): Likewise.
16752 (dwarf2_const_value): Likewise.
16753 (die_type): Likewise.
16754 (die_containing_type): Likewise.
16755 (lookup_die_type): Likewise.
16756 (guess_full_die_structure_name): Likewise.
16757 (anonymous_struct_prefix): Likewise.
16758 (dwarf2_name): Likewise.
16759 (follow_die_ref_or_sig): Likewise.
16760 (follow_die_offset): Likewise.
16761 (follow_die_ref): Likewise.
16762 (dwarf2_fetch_die_loc_sect_off): Likewise.
16763 (dwarf2_fetch_constant_bytes): Likewise.
16764 (dwarf2_fetch_die_type_sect_off): Likewise.
16765 (dwarf2_get_die_type): Likewise.
16766 (follow_die_sig): Likewise.
16767 (decode_locdesc): Likewise.
16768 (dwarf2_per_cu_objfile): Likewise.
16769 (dwarf2_per_cu_text_offset): Likewise.
16770 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
16771 objfile.
16772 (set_die_type): Access objfile through
16773 dwarf2_per_objfile.
16774
16775 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16776
16777 * valprint.c (converted_character_d): Remove typedef.
16778 (DEF_VEC_O (converted_character_d)): Remove.
16779 (count_next_character): Use std::vector.
16780 (print_converted_chars_to_obstack): Likewise.
16781 (generic_printstr): Likewise.
16782
16783 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16784
16785 * xml-support.h (struct gdb_xml_value): Add constructor.
16786 <value>: Change type to unique_xmalloc_ptr.
16787 (gdb_xml_value_s): Remove typedef.
16788 (DEF_VEC_O (gdb_xml_value_s)): Remove.
16789 (gdb_xml_element_start_handler): Change parameter type to
16790 std::vector.
16791 (xml_find_attribute): Likewise.
16792 * xml-support.c (xml_find_attribute): Change parameter type to
16793 std::vector and adjust.
16794 (gdb_xml_values_cleanup): Remove.
16795 (gdb_xml_parser::start_element): Adjust to std::vector.
16796 (xinclude_start_include): Change paraeter type to std::vector
16797 and adjust.
16798 * btrace.c (check_xml_btrace_version): Likewise.
16799 (parse_xml_btrace_block): Likewise.
16800 (parse_xml_btrace_pt_config_cpu): Likewise.
16801 (parse_xml_btrace_pt): Likewise.
16802 (parse_xml_btrace_conf_bts): Likewise.
16803 (parse_xml_btrace_conf_pt): Likewise.
16804 * memory-map.c (memory_map_start_memory): Likewise.
16805 (memory_map_start_property): Likewise.
16806 * osdata.c (osdata_start_osdata): Likewise.
16807 (osdata_start_item): Likewise.
16808 (osdata_start_column): Likewise.
16809 * remote.c (start_thread): Likewise.
16810 * solib-aix.c (library_list_start_library): Likewise.
16811 (library_list_start_list): Likewise.
16812 * solib-svr4.c (library_list_start_library): Likewise.
16813 (svr4_library_list_start_list): Likewise.
16814 * solib-target.c (library_list_start_segment): Likewise.
16815 (library_list_start_section): Likewise.
16816 (library_list_start_library): Likewise.
16817 (library_list_start_list): Likewise.
16818 * tracepoint.c (traceframe_info_start_memory): Likewise.
16819 (traceframe_info_start_tvar): Likewise.
16820 * xml-syscall.c (syscall_start_syscall): Likewise.
16821 * xml-tdesc.c (tdesc_start_target): Likewise.
16822 (tdesc_start_feature): Likewise.
16823 (tdesc_start_reg): Likewise.
16824 (tdesc_start_union): Likewise.
16825 (tdesc_start_struct): Likewise.
16826 (tdesc_start_flags): Likewise.
16827 (tdesc_start_enum): Likewise.
16828 (tdesc_start_field): Likewise.
16829 (tdesc_start_enum_value): Likewise.
16830 (tdesc_start_vector): Likewise.
16831
16832 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16833
16834 * extension.h (struct xmethod_worker) <clone>: Remove.
16835 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
16836 Remove.
16837 (python_xmethod_worker::clone): Remove.
16838 * valops.c (find_overload_match): Use std::move instead of
16839 clone.
16840
16841 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16842
16843 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
16844 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
16845 <free_xmethod_worker_data>: Remove.
16846 <get_matching_xmethod_workers>: Chance VEC to std::vector.
16847 <get_xmethod_arg_types>: Remove.
16848 <get_xmethod_result_type>: Remove.
16849 <invoke_xmethod>: Remove.
16850 * extension.c (new_xmethod_worker): Remove.
16851 (clone_xmethod_worker): Remove.
16852 (get_matching_xmethod_workers): Return void, pass std::vector by
16853 pointer.
16854 (get_xmethod_arg_types): Rename to...
16855 (xmethod_worker::get_arg_types): ... this, and adjust.
16856 (get_xmethod_result_type): Rename to...
16857 (xmethod_worker::get_result_type): ... this, and adjust.
16858 (invoke_xmethod): Remove.
16859 (free_xmethod_worker): Remove.
16860 (free_xmethod_worker_vec): Remove.
16861 * extension.h (enum ext_lang_rc): Move here from
16862 extension-priv.h.
16863 (struct xmethod_worker): Add constructor and destructor.
16864 <data>: Remove.
16865 <value>: Remove.
16866 <invoke, clone, do_get_result_type, do_get_arg_types>: New
16867 virtual pure methods.
16868 <get_arg_types, get_result_type>: New methods.
16869 (xmethod_worker_ptr): Remove typedef.
16870 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
16871 (xmethod_worker_vec): Remove typedef.
16872 (xmethod_worker_up): New typedef.
16873 (invoke_xmethod): Remove.
16874 (clone_xmethod_worker): Remove.
16875 (free_xmethod_worker): Remove.
16876 (free_xmethod_worker_vec): Remove.
16877 (get_xmethod_arg_types): Remove.
16878 (get_xmethod_result_type): Remove.
16879 * valops.c (find_method_list): Use std::vector, don't use
16880 intermediate vector.
16881 (value_find_oload_method_list): Use std::vector.
16882 (find_overload_match): Use std::vector.
16883 (find_oload_champ): Use std::vector.
16884 * value.c (value_free): Use operator delete.
16885 (value_of_xmethod): Rename to...
16886 (value_from_xmethod): ... this. Don't assign
16887 xmethod_worker::value, take rvalue-reference.
16888 (result_type_of_xmethod): Adjust.
16889 (call_xmethod): Adjust.
16890 * value.h: Include extension.h.
16891 (struct xmethod_worker): Don't forward-declare.
16892 (value_of_xmethod): Rename to...
16893 (value_from_xmethod): ... this, take rvalue-reference.
16894 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
16895 (struct python_xmethod_worker): ... this, add constructor and
16896 destructor.
16897 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
16898 (gdbpy_free_xmethod_worker_data): Rename to...
16899 (python_xmethod_worker::~python_xmethod_worker): ... this and
16900 adjust.
16901 (gdbpy_clone_xmethod_worker_data): Rename to...
16902 (python_xmethod_worker::clone): ... this and adjust.
16903 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
16904 temporary vector.
16905 (gdbpy_get_xmethod_arg_types): Rename to...
16906 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
16907 (gdbpy_get_xmethod_result_type): Rename to...
16908 (python_xmethod_worker::do_get_result_type): ... this and
16909 adjust.
16910 (gdbpy_invoke_xmethod): Rename to...
16911 (python_xmethod_worker::invoke): ... this and adjust.
16912 (new_python_xmethod_worker): Rename to...
16913 (python_xmethod_worker::python_xmethod_worker): ... this and
16914 adjust.
16915 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
16916 Remove.
16917 (gdbpy_free_xmethod_worker_data): Remove.
16918 (gdbpy_get_matching_xmethod_workers): Use std::vector.
16919 (gdbpy_get_xmethod_arg_types): Remove.
16920 (gdbpy_get_xmethod_result_type): Remove.
16921 (gdbpy_invoke_xmethod): Remove.
16922 * python/python.c (python_extension_ops): Remove obsolete
16923 callbacks.
16924
16925 2018-01-05 Pedro Alves <palves@redhat.com>
16926
16927 PR gdb/18653
16928 * common/signals-state-save-restore.c
16929 (save_original_signals_state): New parameter 'quiet'. Warn if we
16930 find a custom handler preinstalled, instead of internal erroring.
16931 But only warn if !quiet.
16932 * common/signals-state-save-restore.h
16933 (save_original_signals_state): New parameter 'quiet'.
16934 * main.c (captured_main_1): Move save_original_signals_state call
16935 after option handling, and pass QUIET.
16936
16937 2018-01-05 Pedro Alves <palves@redhat.com>
16938
16939 * spu-tdep.c (spu_catch_start): Pass
16940 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
16941
16942 2018-01-05 Pedro Alves <palves@redhat.com>
16943
16944 PR gdb/22670
16945 * ada-lang.c (literal_symbol_name_matcher): New function.
16946 (ada_get_symbol_name_matcher): Use it for
16947 symbol_name_match_type::SEARCH_NAME.
16948 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
16949 it down instead of assuming symbol_name_match_type::FULL.
16950 * block.h (block_lookup_symbol): New parameter 'match_type'.
16951 * c-valprint.c (print_unpacked_pointer): Use
16952 lookup_symbol_search_name instead of lookup_symbol.
16953 * compile/compile-object-load.c (get_out_value_type): Pass down
16954 symbol_name_match_type::SEARCH_NAME.
16955 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
16956 symbol_name_match_type::FULL.
16957 * cp-support.c (cp_get_symbol_name_matcher): Handle
16958 symbol_name_match_type::SEARCH_NAME.
16959 * infrun.c (insert_exception_resume_breakpoint): Use
16960 lookup_symbol_search_name.
16961 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
16962 * psymtab.c (maintenance_check_psymtabs): Use
16963 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
16964 * stack.c (print_frame_args): Use lookup_symbol_search_name and
16965 SYMBOL_SEARCH_NAME.
16966 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
16967 if symbol_name_match_type::SEARCH_NAME.
16968 (lookup_symbol_in_language): Pass down
16969 symbol_name_match_type::FULL.
16970 (lookup_symbol_search_name): New.
16971 (lookup_language_this): Pass down
16972 symbol_name_match_type::SEARCH_NAME.
16973 (lookup_symbol_aux, lookup_local_symbol): New parameter
16974 'match_type'. Pass it down.
16975 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
16976 (lookup_symbol_search_name): New declaration.
16977 (lookup_symbol_in_block): New 'match_type' parameter.
16978
16979 2018-01-05 Pedro Alves <palves@redhat.com>
16980
16981 PR gdb/22670
16982 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
16983 ada_lookup_symbol.
16984 (ada_lookup_symbol): Reimplement in terms of
16985 ada_lookup_symbol_list, bits factored out from
16986 ada_lookup_encoded_symbol.
16987
16988 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16989
16990 * ada-exp.y (write_object_renaming): When subscripting an array
16991 using a symbol as the index, pass the block in call to
16992 ada_lookup_encoded_symbol when looking that symbol up.
16993
16994 2018-01-05 Jerome Guitton <guitton@adacore.com>
16995
16996 * ada-lang.c (ada_array_length): Use ada_index_type instead of
16997 TYPE_INDEX_TYPE.
16998
16999 2018-01-05 Joel Brobecker <brobecker@adacore.com>
17000
17001 * ada-lang.c (ada_to_fixed_value_create): Add handling of
17002 the case where VALUE_LVAL (val0) is not lval_memory.
17003
17004 2018-01-05 Xavier Roirand <roirand@adacore.com>
17005
17006 * ada-valprint.c (print_optional_low_bound): Handle
17007 character-indexed array printing like boolean-indexed array
17008 printing.
17009
17010 2018-01-05 Joel Brobecker <brobecker@adacore.com>
17011
17012 * NEWS: Create a new section for the next release branch.
17013 Rename the section of the current branch, now that it has
17014 been cut.
17015
17016 2018-01-05 Joel Brobecker <brobecker@adacore.com>
17017
17018 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
17019 * version.in: Bump version to 8.1.50.DATE-git.
17020
17021 2018-01-03 Xavier Roirand <roirand@adacore.com>
17022
17023 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
17024 Add field.
17025 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
17026 Add field.
17027 (default_exception_support_info) <catch_handlers_sym>: Add field.
17028 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
17029 (ada_exception_name_addr_1): Add "catch handlers" handling.
17030 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
17031 Update all callers.
17032 (create_excep_cond_exprs) <ex>: Add parameter.
17033 (re_set_exception): Update create_excep_cond_exprs call.
17034 (print_it_exception, print_one_exception, print_mention_exception)
17035 (print_recreate_exception): Add "catch handler" handling.
17036 (allocate_location_catch_handlers, re_set_catch_handlers)
17037 (check_status_catch_handlers, print_it_catch_handlers)
17038 (print_one_catch_handlers, print_mention_catch_handlers)
17039 (print_recreate_catch_handlers): New function.
17040 (catch_handlers_breakpoint_ops): New variable.
17041 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
17042 Add parameter. Add "catch handler" handling.
17043 (ada_exception_sym_name, ada_exception_breakpoint_ops):
17044 Add "catch handler" handling.
17045 (ada_exception_catchpoint_cond_string): Add "catch handler"
17046 handling.
17047 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
17048 call.
17049 (catch_ada_handlers_command): New function.
17050 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
17051 operations structure.
17052 (_initialize_ada_language): Add "catch handlers" command entry.
17053 * NEWS: Document "catch handlers" feature.
17054
17055 2018-01-02 Joel Brobecker <brobecker@adacore.com>
17056
17057 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
17058 account when creating the array type of the slice.
17059 (ada_value_slice): Likewise.
17060
17061 2018-01-02 Joel Brobecker <brobecker@adacore.com>
17062
17063 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
17064 New enum value.
17065 (create_array_type_with_stride): Add byte_stride_prop parameter.
17066 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
17067 New parameter. Update all callers in this file.
17068 (array_type_has_dynamic_stride): New function.
17069 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
17070 of arrays with dynamic byte strides.
17071 * dwarf2read.c (read_array_type): Add support for dynamic
17072 DW_AT_byte_stride attributes.
17073
17074 2018-01-02 Joel Brobecker <brobecker@adacore.com>
17075
17076 * dwarf2read.c (read_unspecified_type): Treat
17077 DW_TAG_enumeration_type DIEs from Ada units as stubs.
17078
17079 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17080
17081 Update copyright year range in all GDB files.
17082
17083 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
17084
17085 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
17086 and gdb/testsuite/gdb.base/step-line.c.
17087
17088 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17089
17090 * copyright.py (main): Dump the contents of
17091 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
17092 even if BY_HAND is empty.
17093
17094 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17095
17096 * top.c (print_gdb_version): Update Copyright year in version
17097 message.
17098
17099 2018-01-01 Joel Brobecker <brobecker@adacore.com>
17100
17101 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
17102
17103 For older changes see ChangeLog-2017.
17104 \f
17105 Local Variables:
17106 mode: change-log
17107 left-margin: 8
17108 fill-column: 74
17109 version-control: never
17110 coding: utf-8
17111 End:
This page took 0.356977 seconds and 3 git commands to generate.