]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
Add support for 'info proc files' on FreeBSD core dumps.
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2
3 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
4 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
5 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
6 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
7 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
8 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
9 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
10 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
11 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
12 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
13 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
14 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
15 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
16 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
17 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
18 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
19 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
20 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
21 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
22 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
23 (struct fbsd_sockaddr_un): New types.
24 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
25 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
26 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
27 (fbsd_core_info_proc_files): New functions.
28 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
29 IP_ALL.
30 * fbsd-tdep.h (fbsd_info_proc_files_header)
31 (fbsd_info_proc_files_entry): New.
32
33 2018-09-18 John Baldwin <jhb@FreeBSD.org>
34
35 * defs.h (enum info_proc_what) [IP_FILES]: New value.
36 * infcmd.c (info_proc_cmd_files): New function.
37 (_initialize_infcmd): Register 'info proc files' command.
38
39 2018-09-18 John Baldwin <jhb@FreeBSD.org>
40
41 * gnulib/aclocal-m4-deps.mk: Re-generate.
42 * gnulib/aclocal.m4: Re-generate.
43 * gnulib/config.in: Re-generate.
44 * gnulib/configure: Re-generate.
45 * gnulib/import/Makefile.am: Re-generate.
46 * gnulib/import/Makefile.in: Re-generate.
47 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
48 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
49 * gnulib/import/arpa_inet.in.h: New file.
50 * gnulib/import/inet_ntop.c: New file.
51 * gnulib/import/m4/arpa_inet_h.m4: New file.
52 * gnulib/import/m4/inet_ntop.m4: New file.
53 * gnulib/import/m4/netinet_in_h.m4: New file.
54 * gnulib/import/m4/socklen.m4: New file.
55 * gnulib/import/m4/sockpfaf.m4: New file.
56 * gnulib/import/m4/stdalign.m4: New file.
57 * gnulib/import/m4/sys_uio_h.m4: New file.
58 * gnulib/import/netinet_in.in.h: New file.
59 * gnulib/import/stdalign.in.h: New file.
60 * gnulib/import/sys_socket.c: New file.
61 * gnulib/import/sys_socket.in.h: New file.
62 * gnulib/import/sys_uio.in.h: New file.
63 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
64 module.
65
66 2018-09-18 John Baldwin <jhb@FreeBSD.org>
67
68 * gnulib/aclocal-m4-deps.mk: New file.
69 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
70 deterministically.
71
72 2018-09-18 John Baldwin <jhb@FreeBSD.org>
73
74 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
75 KVE_PATH.
76
77 2018-09-18 Tom Tromey <tom@tromey.com>
78
79 * compile/compile-object-load.c (struct
80 link_hash_table_cleanup_data): Add constructor and destructor.
81 Use DISABLE_COPY_AND_ASSIGN.
82 (~link_hash_table_cleanup_data): Rename from
83 link_hash_table_free. Now a destructor.
84 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
85
86 2018-09-18 Tom Tromey <tom@tromey.com>
87
88 * compile/compile-object-run.c (do_module_cleanup): Use delete.
89 * compile/compile-object-load.c (struct munmap_list): Move to
90 header file.
91 (munmap_list::add): Rename from munmap_list_add; rewrite.
92 (munmap_list::~munmap_list): Rename from munmap_list_free.
93 (munmap_listp_free_cleanup): Remove.
94 (compile_object_load): Update.
95 * compile/compile-object-load.h (struct munmap_list): Move from
96 compile-object-load.c. Rewrite.
97
98 2018-09-18 Alan Hayward <alan.hayward@arm.com>
99
100 * aarch64-tdep.c (pass_in_v): Use register size.
101 (aarch64_extract_return_value): Likewise.
102 (aarch64_store_return_value): Likewise.
103
104 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
105
106 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
107 rlim_t.
108
109 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
110
111 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
112 Fix short help line.
113
114 2018-09-17 Tom Tromey <tom@tromey.com>
115
116 PR python/20445:
117 * configure: Rebuild.
118 * configure.ac: Conditionally use -DNDEBUG for Python.
119
120 2018-09-17 Tom Tromey <tom@tromey.com>
121
122 * configure: Rebuild.
123 * configure.ac: Use gmp as a library dependency when checking for
124 mpfr.
125
126 2018-09-17 Pedro Alves <palves@redhat.com>
127
128 * python/py-inferior.c (find_inferior_object): Delete.
129
130 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
131
132 * compile/compile-cplus-types.c
133 (compile_cplus_instance::enter_scope): Don't use new_scope after
134 std::move.
135
136 2018-09-17 Tom Tromey <tom@tromey.com>
137
138 * common/pathstuff.c (get_standard_cache_dir): Use
139 ~/Library/Caches on macOS.
140 * common/pathstuff.h (get_standard_cache_dir): Update comment.
141
142 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
143
144 PR python/23669
145 * breakpoint.c (commands_cmd_element): New.
146 (_initialize_breakpoint): Assign commands_cmd_element.
147 * breakpoint.h (commands_cmd_element): New.
148 * cli/cli-script.c (while_cmd_element, if_command,
149 define_cmd_element): New.
150 (command_name_equals): Remove.
151 (process_next_line): Compare commands by pointer, not by name.
152 (_initialize_cli_script): Assign the various cmd_list_element
153 variables.
154 * compile/compile.c (compile_cmd_element): New.
155 (_initialize_compile): Assign compile_cmd_element.
156 * compile/compile.h (compile_cmd_element): New.
157 * guile/guile.c (guile_cmd_element): New.
158 (install_gdb_commands): Assign guile_cmd_element.
159 * guile/guile.h (guile_cmd_element): New.
160 * python/python.c (python_cmd_element): New.
161 (_initialize_python): Assign python_cmd_element.
162 * python/python.h (python_cmd_element): New.
163 * tracepoint.c (while_stepping_cmd_element): New.
164 (_initialize_tracepoint): Assign while_stepping_cmd_element.
165 * tracepoint.h (while_stepping_cmd_element): New.
166
167 2018-09-17 Tom Tromey <tom@tromey.com>
168
169 * infrun.c (save_infcall_suspend_state): Return
170 infcall_suspend_state_up.
171 (save_infcall_control_state): Return infcall_control_state_up.
172 * inferior.h (save_infcall_suspend_state)
173 (save_infcall_control_state): Declare later. Return unique
174 pointers.
175
176 2018-09-17 Tom Tromey <tom@tromey.com>
177
178 * infrun.c (struct stop_context): Declare constructor,
179 destructor, "changed" method.
180 (stop_context::stop_context): Rename from save_stop_context.
181 (stop_context::~stop_context): Rename from
182 release_stop_context_cleanup.
183 (normal_stop): Update.
184 (stop_context::changed): Rename from stop_context_changed. Return
185 bool.
186
187 2018-09-17 Tom Tromey <tom@tromey.com>
188
189 * inferior.h (struct infcall_suspend_state_deleter): New.
190 (infcall_suspend_state_up): New typedef.
191 (struct infcall_control_state_deleter): New.
192 (infcall_control_state_up): New typedef.
193 (make_cleanup_restore_infcall_suspend_state)
194 (make_cleanup_restore_infcall_control_state): Don't declare.
195 * infcall.c (call_function_by_hand_dummy): Update.
196 * infrun.c (do_restore_infcall_suspend_state_cleanup)
197 (make_cleanup_restore_infcall_suspend_state): Remove.
198 (do_restore_infcall_control_state_cleanup)
199 (make_cleanup_restore_infcall_control_state): Remove.
200
201 2018-09-17 Tom Tromey <tom@tromey.com>
202
203 * gdbthread.h (struct thread_control_state): Add initializer.
204 (class thread_info) <control>: Remove initializer.
205 * inferior.h (struct inferior_control_state): Add initializer.
206 (class inferior) <control>: Remove initializer.
207 (exit_inferior_1): Update.
208 * infrun.c (struct infcall_control_state): Add constructors.
209 (save_infcall_control_state): Use new.
210 (restore_infcall_control_state, discard_infcall_control_state):
211 Use delete.
212
213 2018-09-17 Tom Tromey <tom@tromey.com>
214
215 * infrun.c (struct infcall_suspend_state) <registers>: Now a
216 unique_ptr.
217 <siginfo_data>: Now a unique_xmalloc_ptr.
218 (save_infcall_suspend_state, restore_infcall_suspend_state)
219 (discard_infcall_suspend_state)
220 (get_infcall_suspend_state_regcache): Update.
221
222 2018-09-17 Tom Tromey <tom@tromey.com>
223
224 * gdbthread.h (struct thread_suspend_state): Add initializers.
225 (class thread_info) <suspend>: Remove initializer.
226 * infrun.c (struct infcall_suspend_state): Add initializers.
227 (save_infcall_suspend_state): Use new.
228 (discard_infcall_suspend_state): Use delete.
229
230 2018-09-16 Tom Tromey <tom@tromey.com>
231
232 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
233 Remove.
234 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
235 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
236 (py_varobj_iter_new): Likewise.
237 (py_varobj_get_iterator): Use gdbpy_ref.
238
239 2018-09-16 Tom Tromey <tom@tromey.com>
240
241 * python/py-threadevent.c (py_get_event_thread): Simplify.
242 * python/py-inferior.c (infpy_thread_from_thread_handle):
243 Return immediately after calling thread_to_thread_object. Use
244 Py_RETURN_NONE.
245 (thread_to_thread_object): Set the exception on a NULL return.
246
247 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
248
249 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
250
251 2018-09-16 Tom Tromey <tom@tromey.com>
252
253 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
254 Remove.
255
256 2018-09-16 Tom Tromey <tom@tromey.com>
257
258 * python/python-internal.h (thread_to_thread_object): Change
259 return type.
260 * python/py-inferior.c (thread_to_thread_object): Return a new
261 reference.
262 (infpy_thread_from_thread_handle): Update.
263 * python/py-infthread.c (gdbpy_selected_thread): Update.
264 * python/py-stopevent.c (create_stop_event_object): Update.
265 * python/py-threadevent.c (py_get_event_thread): Return a new
266 reference.
267 (py_get_event_thread): Update.
268 * python/py-event.h (py_get_event_thread): Change return type.
269 * python/py-continueevent.c (create_continue_event_object):
270 Update.
271
272 2018-09-16 Tom Tromey <tom@tromey.com>
273
274 * python/py-progspace.c (pspy_get_objfiles): Update.
275 * python/python-internal.h (objfile_to_objfile_object): Change
276 return type.
277 * python/py-newobjfileevent.c (create_new_objfile_event_object):
278 Update.
279 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
280 Update.
281 * python/python.c (gdbpy_get_current_objfile): Update.
282 (gdbpy_objfiles): Update.
283 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
284 Update.
285 (objfile_to_objfile_object): Return a new reference.
286 * python/py-symtab.c (stpy_get_objfile): Update.
287 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
288 Update.
289
290 2018-09-16 Tom Tromey <tom@tromey.com>
291
292 * python/py-inferior.c (infpy_get_progspace): Update.
293 * python/python-internal.h (pspace_to_pspace_object): Change
294 return type.
295 * python/py-newobjfileevent.c
296 (create_clear_objfiles_event_object): Update.
297 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
298 Update.
299 * python/python.c (gdbpy_get_current_progspace): Update.
300 (gdbpy_progspaces): Update.
301 * python/py-progspace.c (pspace_to_pspace_object): Return a new
302 reference.
303 * python/py-objfile.c (objfpy_get_progspace): Update.
304 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
305 Update.
306
307 2018-09-16 Tom Tromey <tom@tromey.com>
308
309 * python/lib/gdb/__init__.py (current_progspace, objfiles)
310 (solib_name, block_for_pc, find_pc_line): New functions.
311 (execute_unwinders): Update.
312 * python/py-block.c (gdbpy_block_for_pc): Remove.
313 * python/py-inferior.c (infpy_get_progspace): New function.
314 (inferior_object_getset) <progspace>: Add.
315 * python/py-progspace.c (pspy_objfiles): Rewrite.
316 (pspy_solib_name, pspy_block_for_pc)
317 (pspy_find_pc_line, pspy_is_valid): New functions.
318 (progspace_object_methods): Add entries for solib_name,
319 block_for_pc, find_pc_line, is_valid.
320 * python/python-internal.h (gdbpy_block_for_pc)
321 (build_objfiles_list): Don't declare.
322 * python/python.c: Don't include solib.h.
323 (gdbpy_solib_name, gdbpy_find_pc_line)
324 (gdbpy_get_current_progspace, build_objfiles_list)
325 (gdbpy_objfiles): Remove.
326 (GdbMethods) <current_progspace, objfiles, block_for_pc,
327 solib_name, find_pc_line>: Remove entries.
328
329 2018-09-16 Tom Tromey <tom@tromey.com>
330
331 * top.c (new_ui_command): Use GNU style for metasyntactic
332 variables.
333 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
334 variables.
335 * maint.c (maintenance_translate_address): Remove "<>" around
336 text.
337 * interps.c (interpreter_exec_cmd): Use GNU style for
338 metasyntactic variables.
339 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
340 metasyntactic variables.
341 * tracepoint.c (tfind_range_command): Use GNU style for
342 metasyntactic variables.
343 (tfind_outside_command): Likewise.
344 (_initialize_tracepoint): Likewise.
345 * remote.c (extended_remote_target::create_inferior): Use GNU
346 style for metasyntactic variables.
347 * sparc64-tdep.c (adi_examine_command): Use GNU style for
348 metasyntactic variables.
349 (adi_assign_command): Likewise.
350
351 2018-09-16 Tom Tromey <tom@tromey.com>
352
353 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
354 metasyntactic variables. Print message if no disassembler options
355 are available.
356
357 2018-09-15 Tom Tromey <tom@tromey.com>
358
359 * infcmd.c (get_inferior_args): Return const char *.
360 * inferior.h (get_inferior_args): Return type now const.
361 * linux-tdep.c (linux_fill_prpsinfo): Update.
362 * procfs.c (procfs_target::make_corefile_notes): Update.
363
364 2018-09-07 Tom Tromey <tom@tromey.com>
365
366 * python/python.c (execute_gdb_command): Call bpstat_do_actions
367 inside the TRY.
368
369 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
370
371 * nios2-tdep.c (nios2_type_align): New.
372 (nios2_gdb_arch_init): Install type_align hook.
373
374 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
375
376 * eval.c (fake_method::fake_method): Call xzalloc directly for a
377 type that is neither object file owned, nor gdbarch owned.
378 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
379 gdbarch is non-NULL.
380 (alloc_type_instance): Allocate non-objfile owned types on the
381 gdbarch obstack.
382 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
383 using TYPE_ALLOC to ensure memory is allocated on the correct
384 obstack.
385 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
386 obstack, or the gdbarch obstack.
387 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
388
389 2018-09-14 Tom Tromey <tom@tromey.com>
390
391 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
392 block.
393
394 2018-09-14 Tom Tromey <tom@tromey.com>
395
396 * nat/fork-inferior.c (get_startup_shell): Remove "static".
397
398 2018-09-13 Tom Tromey <tom@tromey.com>
399
400 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
401 static.
402
403 2018-09-13 Tom Tromey <tom@tromey.com>
404
405 * exec.c (try_open_exec_file): Use std::string.
406
407 2018-09-13 Tom Tromey <tom@tromey.com>
408
409 * utils.h (gdb_bfd_errmsg): Return std::string.
410 * exec.c (exec_file_attach): Update.
411 * compile/compile-object-load.c (compile_object_load): Update.
412 * utils.c (gdb_bfd_errmsg): Return std::string.
413
414 2018-09-13 Tom Tromey <tom@tromey.com>
415
416 * procfs.c (struct procinfo_deleter): New.
417 (procinfo_up): New typedef.
418 (do_destroy_procinfo_cleanup): Remove.
419 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
420
421 2018-09-13 Tom Tromey <tom@tromey.com>
422
423 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
424
425 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
426 2018-09-13 Tom Tromey <tom@tromey.com>
427
428 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
429 (pspy_get_objfiles): New function.
430 (progspace_object_methods): New.
431 (pspace_object_type): Add tp_methods callback.
432 * python/python-internal.h (build_objfiles_list): New
433 declaration.
434 * python/python.c (build_objfiles_list): New function.
435 (gdbpy_objfiles): Implement using build_objfiles_list.
436 * NEWS: Mention the Progspace.objfiles method.
437
438 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
439
440 * python/py-inferior.c (infpy_get_progspace): New function.
441 (inferior_object_getset): Add progspace property.
442 * NEWS: Mention the new property.
443
444 2018-09-13 Tom Tromey <tom@tromey.com>
445
446 PR rust/23650:
447 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
448
449 2018-09-13 Tom Tromey <tom@tromey.com>
450
451 PR rust/23626:
452 * rust-lang.c (rust_enum_variant): Now static.
453 (rust_empty_enum_p): New function.
454 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
455 Handle empty enum.
456
457 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
458
459 * python/py-inferior.c (infpy_repr): New.
460 (inferior_object_type): Register infpy_repr.
461 * python/py-objfile.c (objfpy_repr): New.
462 (objfile_object_type): Register objfpy_repr.
463
464 2018-09-12 John Baldwin <jhb@FreeBSD.org>
465
466 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
467
468 2018-09-12 John Baldwin <jhb@FreeBSD.org>
469
470 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
471 typo.
472
473 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
474
475 * common/common-utils.c: Don't include '<sys/stat.h>'.
476 (is_regular_file): Move to...
477 * common/filestuff.c (is_regular_file): ... here.
478 * common/common-utils.h (is_regular_file): Move to...
479 * common/filestuff.h (is_regular_file): ... here.
480
481 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
482
483 * skip.c (debug_skip): New variable.
484 (skiplist_entry::do_skip_file_p): Add debug output.
485 (skiplist_entry::do_skip_gfile_p): Likewise.
486 (skiplist_entry::skip_function_p): Likewise.
487 (_initialize_step_skip): Create debug command.
488 * NEWS: Mention set/show debug skip.
489
490 2018-09-11 Xavier Roirand <roirand@adacore.com>
491
492 * darwin-nat.c (should_disable_startup_with_shell):
493 New function.
494 (darwin_nat_target::create_inferior): Add call.
495
496 2018-09-11 Xavier Roirand <roirand@adacore.com>
497
498 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
499 inf_port, msg_state>: Initialize.
500 (struct darwin_thread_info) <signaled, single_step>: Change
501 type and initialize.
502 (struct darwin_thread_info) <event>: Initialize.
503
504 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
505
506 PR gdb/23555
507 PR gdb/23558
508 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
509 guesses.
510
511 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
512
513 Revert:
514 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
515
516 PR gdb/23555
517 PR gdb/23558
518 * gnulib/aclocal.m4: Regenerate.
519 * gnulib/config.in: Regenerate.
520 * gnulib/configure: Regenerate.
521 * gnulib/import/Makefile.am: Update.
522 * gnulib/import/Makefile.in: Update.
523 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
524 * gnulib/import/_Noreturn.h: ... this.
525 * gnulib/import/alloca.in.h: Update.
526 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
527 * gnulib/import/arg-nonnull.h: ... this.
528 * gnulib/import/assure.h: Update.
529 * gnulib/import/at-func.c: Update.
530 * gnulib/import/basename-lgpl.c: Update.
531 * gnulib/import/extra/snippet/c++defs.h: Rename to...
532 * gnulib/import/c++defs.h: ... this.
533 * gnulib/import/canonicalize-lgpl.c: Update.
534 * gnulib/import/cdefs.h: Update.
535 * gnulib/import/chdir-long.c: Update.
536 * gnulib/import/chdir-long.h: Update.
537 * gnulib/import/cloexec.c: Update.
538 * gnulib/import/cloexec.h: Update.
539 * gnulib/import/close.c: Update.
540 * gnulib/import/closedir.c: Update.
541 * gnulib/import/config.charset: Update.
542 * gnulib/import/dirent-private.h: Update.
543 * gnulib/import/dirent.in.h: Update.
544 * gnulib/import/dirfd.c: Update.
545 * gnulib/import/dirname-lgpl.c: Update.
546 * gnulib/import/dirname.h: Update.
547 * gnulib/import/dosname.h: Update.
548 * gnulib/import/dup-safer-flag.c: Update.
549 * gnulib/import/dup-safer.c: Update.
550 * gnulib/import/dup.c: Update.
551 * gnulib/import/dup2.c: Update.
552 * gnulib/import/errno.in.h: Update.
553 * gnulib/import/error.c: Update.
554 * gnulib/import/error.h: Update.
555 * gnulib/import/exitfail.c: Update.
556 * gnulib/import/exitfail.h: Update.
557 * gnulib/import/extra/update-copyright: Update.
558 * gnulib/import/fchdir.c: Update.
559 * gnulib/import/fcntl.c: Update.
560 * gnulib/import/fcntl.in.h: Update.
561 * gnulib/import/fd-hook.c: Update.
562 * gnulib/import/fd-hook.h: Update.
563 * gnulib/import/fd-safer-flag.c: Update.
564 * gnulib/import/fd-safer.c: Update.
565 * gnulib/import/fdopendir.c: Update.
566 * gnulib/import/filename.h: Update.
567 * gnulib/import/filenamecat-lgpl.c: Update.
568 * gnulib/import/filenamecat.h: Update.
569 * gnulib/import/flexmember.h: Update.
570 * gnulib/import/float+.h: Update.
571 * gnulib/import/float.c: Update.
572 * gnulib/import/float.in.h: Update.
573 * gnulib/import/fnmatch.c: Update.
574 * gnulib/import/fnmatch.in.h: Update.
575 * gnulib/import/fnmatch_loop.c: Update.
576 * gnulib/import/fpucw.h: Update.
577 * gnulib/import/frexp.c: Update.
578 * gnulib/import/frexpl.c: Update.
579 * gnulib/import/fstat.c: Update.
580 * gnulib/import/fstatat.c: Update.
581 * gnulib/import/getcwd-lgpl.c: Update.
582 * gnulib/import/getcwd.c: Update.
583 * gnulib/import/getdtablesize.c: Update.
584 * gnulib/import/getlogin_r.c: Update.
585 * gnulib/import/getprogname.c: Update.
586 * gnulib/import/getprogname.h: Update.
587 * gnulib/import/gettext.h: Update.
588 * gnulib/import/gettimeofday.c: Update.
589 * gnulib/import/glob-libc.h: Update.
590 * gnulib/import/glob.c: Update.
591 * gnulib/import/glob.in.h: Update.
592 * gnulib/import/glob_internal.h: Update.
593 * gnulib/import/glob_pattern_p.c: Update.
594 * gnulib/import/globfree.c: Update.
595 * gnulib/import/hard-locale.c: Update.
596 * gnulib/import/hard-locale.h: Update.
597 * gnulib/import/intprops.h: Update.
598 * gnulib/import/inttypes.in.h: Update.
599 * gnulib/import/isnan.c: Update.
600 * gnulib/import/isnand-nolibm.h: Update.
601 * gnulib/import/isnand.c: Update.
602 * gnulib/import/isnanl-nolibm.h: Update.
603 * gnulib/import/isnanl.c: Update.
604 * gnulib/import/itold.c: Update.
605 * gnulib/import/libc-config.h: Update.
606 * gnulib/import/limits.in.h: Update.
607 * gnulib/import/localcharset.c: Update.
608 * gnulib/import/localcharset.h: Update.
609 * gnulib/import/localtime-buffer.c: Update.
610 * gnulib/import/localtime-buffer.h: Update.
611 * gnulib/import/lstat.c: Update.
612 * gnulib/import/m4/00gnulib.m4: Update.
613 * gnulib/import/m4/__inline.m4: Update.
614 * gnulib/import/m4/absolute-header.m4: Update.
615 * gnulib/import/m4/alloca.m4: Update.
616 * gnulib/import/m4/builtin-expect.m4: Update.
617 * gnulib/import/m4/canonicalize.m4: Update.
618 * gnulib/import/m4/chdir-long.m4: Update.
619 * gnulib/import/m4/close.m4: Update.
620 * gnulib/import/m4/closedir.m4: Update.
621 * gnulib/import/m4/configmake.m4: Update.
622 * gnulib/import/m4/d-ino.m4: Update.
623 * gnulib/import/m4/d-type.m4: Update.
624 * gnulib/import/m4/dirent_h.m4: Update.
625 * gnulib/import/m4/dirfd.m4: Update.
626 * gnulib/import/m4/dirname.m4: Update.
627 * gnulib/import/m4/double-slash-root.m4: Update.
628 * gnulib/import/m4/dup.m4: Update.
629 * gnulib/import/m4/dup2.m4: Update.
630 * gnulib/import/m4/eealloc.m4: Update.
631 * gnulib/import/m4/environ.m4: Update.
632 * gnulib/import/m4/errno_h.m4: Update.
633 * gnulib/import/m4/error.m4: Update.
634 * gnulib/import/m4/exponentd.m4: Update.
635 * gnulib/import/m4/exponentl.m4: Update.
636 * gnulib/import/m4/extensions.m4: Update.
637 * gnulib/import/m4/extern-inline.m4: Update.
638 * gnulib/import/m4/fchdir.m4: Update.
639 * gnulib/import/m4/fcntl-o.m4: Update.
640 * gnulib/import/m4/fcntl.m4: Update.
641 * gnulib/import/m4/fcntl_h.m4: Update.
642 * gnulib/import/m4/fdopendir.m4: Update.
643 * gnulib/import/m4/filenamecat.m4: Update.
644 * gnulib/import/m4/flexmember.m4: Update.
645 * gnulib/import/m4/float_h.m4: Update.
646 * gnulib/import/m4/fnmatch.m4: Update.
647 * gnulib/import/m4/fnmatch_h.m4: Update.
648 * gnulib/import/m4/fpieee.m4: Update.
649 * gnulib/import/m4/frexp.m4: Update.
650 * gnulib/import/m4/frexpl.m4: Update.
651 * gnulib/import/m4/fstat.m4: Update.
652 * gnulib/import/m4/fstatat.m4: Update.
653 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
654 * gnulib/import/m4/getcwd-path-max.m4: Update.
655 * gnulib/import/m4/getcwd.m4: Update.
656 * gnulib/import/m4/getdtablesize.m4: Update.
657 * gnulib/import/m4/getlogin.m4: Update.
658 * gnulib/import/m4/getlogin_r.m4: Update.
659 * gnulib/import/m4/getpagesize.m4: Update.
660 * gnulib/import/m4/getprogname.m4: Update.
661 * gnulib/import/m4/gettimeofday.m4: Update.
662 * gnulib/import/m4/glibc21.m4: Update.
663 * gnulib/import/m4/glob.m4: Update.
664 * gnulib/import/m4/glob_h.m4: Update.
665 * gnulib/import/m4/gnulib-cache.m4: Update.
666 * gnulib/import/m4/gnulib-common.m4: Update.
667 * gnulib/import/m4/gnulib-comp.m4: Update.
668 * gnulib/import/m4/gnulib-tool.m4: Update.
669 * gnulib/import/m4/hard-locale.m4: Update.
670 * gnulib/import/m4/include_next.m4: Update.
671 * gnulib/import/m4/inttypes-pri.m4: Update.
672 * gnulib/import/m4/inttypes.m4: Update.
673 * gnulib/import/m4/isnand.m4: Update.
674 * gnulib/import/m4/isnanl.m4: Update.
675 * gnulib/import/m4/largefile.m4: Update.
676 * gnulib/import/m4/limits-h.m4: Update.
677 * gnulib/import/m4/localcharset.m4: Update.
678 * gnulib/import/m4/locale-fr.m4: Update.
679 * gnulib/import/m4/locale-ja.m4: Update.
680 * gnulib/import/m4/locale-zh.m4: Update.
681 * gnulib/import/m4/localtime-buffer.m4: Update.
682 * gnulib/import/m4/longlong.m4: Update.
683 * gnulib/import/m4/lstat.m4: Update.
684 * gnulib/import/m4/malloc.m4: Update.
685 * gnulib/import/m4/malloca.m4: Update.
686 * gnulib/import/m4/math_h.m4: Update.
687 * gnulib/import/m4/mbrtowc.m4: Update.
688 * gnulib/import/m4/mbsinit.m4: Update.
689 * gnulib/import/m4/mbsrtowcs.m4: Update.
690 * gnulib/import/m4/mbstate_t.m4: Update.
691 * gnulib/import/m4/memchr.m4: Update.
692 * gnulib/import/m4/memmem.m4: Update.
693 * gnulib/import/m4/mempcpy.m4: Update.
694 * gnulib/import/m4/memrchr.m4: Update.
695 * gnulib/import/m4/mkdir.m4: Update.
696 * gnulib/import/m4/mkstemp.m4: Update.
697 * gnulib/import/m4/mmap-anon.m4: Update.
698 * gnulib/import/m4/mode_t.m4: Update.
699 * gnulib/import/m4/msvc-inval.m4: Update.
700 * gnulib/import/m4/msvc-nothrow.m4: Update.
701 * gnulib/import/m4/multiarch.m4: Update.
702 * gnulib/import/m4/nocrash.m4: Update.
703 * gnulib/import/m4/off_t.m4: Update.
704 * gnulib/import/m4/onceonly.m4: Update.
705 * gnulib/import/m4/open-cloexec.m4: Update.
706 * gnulib/import/m4/open.m4: Update.
707 * gnulib/import/m4/openat.m4: Update.
708 * gnulib/import/m4/opendir.m4: Update.
709 * gnulib/import/m4/pathmax.m4: Update.
710 * gnulib/import/m4/rawmemchr.m4: Update.
711 * gnulib/import/m4/readdir.m4: Update.
712 * gnulib/import/m4/readlink.m4: Update.
713 * gnulib/import/m4/realloc.m4: Update.
714 * gnulib/import/m4/rename.m4: Update.
715 * gnulib/import/m4/rewinddir.m4: Update.
716 * gnulib/import/m4/rmdir.m4: Update.
717 * gnulib/import/m4/save-cwd.m4: Update.
718 * gnulib/import/m4/secure_getenv.m4: Update.
719 * gnulib/import/m4/setenv.m4: Update.
720 * gnulib/import/m4/signal_h.m4: Update.
721 * gnulib/import/m4/ssize_t.m4: Update.
722 * gnulib/import/m4/stat-time.m4: Update.
723 * gnulib/import/m4/stat.m4: Update.
724 * gnulib/import/m4/std-gnu11.m4: Update.
725 * gnulib/import/m4/stdbool.m4: Update.
726 * gnulib/import/m4/stddef_h.m4: Update.
727 * gnulib/import/m4/stdint.m4: Update.
728 * gnulib/import/m4/stdio_h.m4: Update.
729 * gnulib/import/m4/stdlib_h.m4: Update.
730 * gnulib/import/m4/strchrnul.m4: Update.
731 * gnulib/import/m4/strdup.m4: Update.
732 * gnulib/import/m4/strerror.m4: Update.
733 * gnulib/import/m4/string_h.m4: Update.
734 * gnulib/import/m4/strstr.m4: Update.
735 * gnulib/import/m4/strtok_r.m4: Update.
736 * gnulib/import/m4/sys_socket_h.m4: Update.
737 * gnulib/import/m4/sys_stat_h.m4: Update.
738 * gnulib/import/m4/sys_time_h.m4: Update.
739 * gnulib/import/m4/sys_types_h.m4: Update.
740 * gnulib/import/m4/tempname.m4: Update.
741 * gnulib/import/m4/time_h.m4: Update.
742 * gnulib/import/m4/unistd-safer.m4: Update.
743 * gnulib/import/m4/unistd_h.m4: Update.
744 * gnulib/import/m4/warn-on-use.m4: Update.
745 * gnulib/import/m4/wchar_h.m4: Update.
746 * gnulib/import/m4/wchar_t.m4: Update.
747 * gnulib/import/m4/wctype_h.m4: Update.
748 * gnulib/import/m4/wint_t.m4: Update.
749 * gnulib/import/malloc.c: Update.
750 * gnulib/import/malloc/scratch_buffer.h: Update.
751 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
752 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
753 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
754 * gnulib/import/malloca.c: Update.
755 * gnulib/import/malloca.h: Update.
756 * gnulib/import/malloca.valgrind: Update.
757 * gnulib/import/math.in.h: Update.
758 * gnulib/import/mbrtowc.c: Update.
759 * gnulib/import/mbsinit.c: Update.
760 * gnulib/import/mbsrtowcs-impl.h: Update.
761 * gnulib/import/mbsrtowcs-state.c: Update.
762 * gnulib/import/mbsrtowcs.c: Update.
763 * gnulib/import/memchr.c: Update.
764 * gnulib/import/memmem.c: Update.
765 * gnulib/import/mempcpy.c: Update.
766 * gnulib/import/memrchr.c: Update.
767 * gnulib/import/mkdir.c: Update.
768 * gnulib/import/mkstemp.c: Update.
769 * gnulib/import/msvc-inval.c: Update.
770 * gnulib/import/msvc-inval.h: Update.
771 * gnulib/import/msvc-nothrow.c: Update.
772 * gnulib/import/msvc-nothrow.h: Update.
773 * gnulib/import/open.c: Update.
774 * gnulib/import/openat-die.c: Update.
775 * gnulib/import/openat-priv.h: Update.
776 * gnulib/import/openat-proc.c: Update.
777 * gnulib/import/openat.c: Update.
778 * gnulib/import/openat.h: Update.
779 * gnulib/import/opendir.c: Update.
780 * gnulib/import/pathmax.h: Update.
781 * gnulib/import/pipe-safer.c: Update.
782 * gnulib/import/rawmemchr.c: Update.
783 * gnulib/import/readdir.c: Update.
784 * gnulib/import/readlink.c: Update.
785 * gnulib/import/realloc.c: Update.
786 * gnulib/import/ref-add.sin: Update.
787 * gnulib/import/ref-del.sin: Update.
788 * gnulib/import/rename.c: Update.
789 * gnulib/import/rewinddir.c: Update.
790 * gnulib/import/rmdir.c: Update.
791 * gnulib/import/same-inode.h: Update.
792 * gnulib/import/save-cwd.c: Update.
793 * gnulib/import/save-cwd.h: Update.
794 * gnulib/import/scratch_buffer.h: Update.
795 * gnulib/import/secure_getenv.c: Update.
796 * gnulib/import/setenv.c: Update.
797 * gnulib/import/signal.in.h: Update.
798 * gnulib/import/stat-time.c: Update.
799 * gnulib/import/stat-time.h: Update.
800 * gnulib/import/stat-w32.c: Update.
801 * gnulib/import/stat-w32.h: Update.
802 * gnulib/import/stat.c: Update.
803 * gnulib/import/stdbool.in.h: Update.
804 * gnulib/import/stddef.in.h: Update.
805 * gnulib/import/stdint.in.h: Update.
806 * gnulib/import/stdio.in.h: Update.
807 * gnulib/import/stdlib.in.h: Update.
808 * gnulib/import/str-two-way.h: Update.
809 * gnulib/import/strchrnul.c: Update.
810 * gnulib/import/strdup.c: Update.
811 * gnulib/import/streq.h: Update.
812 * gnulib/import/strerror-override.c: Update.
813 * gnulib/import/strerror-override.h: Update.
814 * gnulib/import/strerror.c: Update.
815 * gnulib/import/string.in.h: Update.
816 * gnulib/import/stripslash.c: Update.
817 * gnulib/import/strnlen1.c: Update.
818 * gnulib/import/strnlen1.h: Update.
819 * gnulib/import/strstr.c: Update.
820 * gnulib/import/strtok_r.c: Update.
821 * gnulib/import/sys_stat.in.h: Update.
822 * gnulib/import/sys_time.in.h: Update.
823 * gnulib/import/sys_types.in.h: Update.
824 * gnulib/import/tempname.c: Update.
825 * gnulib/import/tempname.h: Update.
826 * gnulib/import/time.in.h: Update.
827 * gnulib/import/unistd--.h: Update.
828 * gnulib/import/unistd-safer.h: Update.
829 * gnulib/import/unistd.in.h: Update.
830 * gnulib/import/unsetenv.c: Update.
831 * gnulib/import/verify.h: Update.
832 * gnulib/import/extra/snippet/warn-on-use.h: Update.
833 * gnulib/import/wchar.in.h: Update.
834 * gnulib/import/wctype.in.h: Update.
835 * gnulib/import/xalloc-oversized.h: Update.
836 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
837 "53e2c179f26a890fa6685af4b6c1397ee370433b".
838
839 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
840
841 * record-btrace.c (get_thread_current_frame): Remove
842 old_inferior_ptid.
843
844 2018-09-10 Jerome Guitton <guitton@adacore.com>
845
846 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
847 with check_tag to 1 if and only if the type is tagged and the
848 component being searched cannot been found in the current
849 view. Otherwise, always call ada_to_fixed_type with
850 check_tag to 0.
851
852 2018-09-10 Xavier Roirand <roirand@adacore.com>
853
854 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
855 declaration.
856 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
857 * ada-varobj.c (ada_varobj_get_number_of_children,
858 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
859
860 2018-09-10 Xavier Roirand <roirand@adacore.com>
861
862 * ada-valprint.c (ada_value_print): Use type instead of
863 enclosing type.
864
865 2018-09-10 Xavier Roirand <roirand@adacore.com>
866
867 * ada-lang.c (ada_value_subscript): Handle case when parameter is
868 an array of access to unconstrained array.
869
870 2018-09-10 Xavier Roirand <roirand@adacore.com>
871
872 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
873 (ada_check_typedef): Use it.
874
875 2018-09-10 Xavier Roirand <roirand@adacore.com>
876
877 * ada-varobj.c (ada_varobj_describe_struct_child)
878 (ada_varobj_describe_child): Handle union case like struct one.
879
880 2018-09-10 Tom Tromey <tom@tromey.com>
881
882 PR python/18380:
883 * python/python.c (_initialize_python): Make example in "python"
884 help work in Python 3.
885
886 2018-09-10 Eli Zaretskii <eliz@gnu.org>
887
888 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
889 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
890 $(EXEEXT) to the script, as it is not a program.
891
892 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
893
894 * python/py-prettyprint.c (pretty_print_one_value): Return
895 gdbpy_ref<>.
896 (print_string_repr): Adjust.
897 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
898 * python/python-internal.h (apply_varobj_pretty_printer): Return
899 gdbpy_ref<>.
900 * varobj.c (varobj_value_get_print_value): Adjust.
901
902 2018-09-08 Tom Tromey <tom@tromey.com>
903
904 PR python/16047:
905 * python/py-prettyprint.c (pretty_print_one_value): Check for
906 to_string method.
907
908 2018-09-08 Joel Brobecker <brobecker@adacore.com>
909
910 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
911 replace_operator_with_call.
912
913 2018-09-08 Joel Brobecker <brobecker@adacore.com>
914
915 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
916
917 2018-09-08 Joel Brobecker <brobecker@adacore.com>
918
919 * ada-typeprint.c (print_range): Print the bounds using TYPE
920 rather than its TYPE_TARGET_TYPE.
921
922 2018-09-08 Joel Brobecker <brobecker@adacore.com>
923
924 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
925 call to ada_to_fixed_value_create.
926
927 2018-09-08 Jerome Guitton <guitton@adacore.com>
928
929 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
930
931 2018-09-08 Joel Brobecker <brobecker@adacore.com>
932
933 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
934 by calls to error.
935
936 2018-09-08 Joel Brobecker <brobecker@adacore.com>
937
938 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
939 Move update of loop variable "fi".
940
941 2018-09-08 Joel Brobecker <brobecker@adacore.com>
942
943 * ada-lang.c (value_assign_to_component): In the case of
944 big-endian targets, extract the bits of the given VAL
945 using an src_offset of zero if container is not a scalar.
946
947 2018-09-06 Simon Ser <contact@emersion.fr>
948
949 PR gdb/23105
950 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
951 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
952 * fbsd-tdep.c (fbsd_make_note_desc): New.
953 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
954 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
955 * target.h (enum target_object) Add FreeBSD-specific
956 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
957
958 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
959
960 * compile/compile-c.h (generate_c_for_variable_locations):
961 Change reference to pointer.
962 * compile/compile-c-support.c (compile_program) <compute>:
963 Likewise.
964 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
965 (generate_c_for_for_one_variable): Likewise
966 (generate_c_for_variable_locations): Likewise
967 * compile/compile-c-types.c (compile_c_instance::convert_type):
968 Likewise
969 * compile/compile-cplus-symbols.c (convert_one_symbol):
970 std::move the scope passed to enter_scope.
971 * compile/compile-cplus-types.c
972 (compile_cplus_instance::enter_scope): Make parameter
973 rvalue-reference.
974 (compile_cplus_instance::new_scope): Change reference to
975 pointer.
976 (compile_cplus_instance::convert_type): Likewise
977 (compile_cplus_convert_typedef): std::move the scope passed to
978 enter_scope.
979 (compile_cplus_convert_struct_or_union): Likewise.
980 (compile_cplus_convert_enum): Likewise.
981 (compile_cplus_convert_namespace): Likewise.
982 * compile/compile-cplus.h (compile_cplus_instance)
983 <enter_scope>: Make parameter rvalue-reference.
984 * compile/compile-internal.h (compile_instance)
985 <get_cached_type>: Likewise
986 * compile/compile-loc2c.c (push): Likewise
987 (pushf): Likewise
988 (unary): Likewise
989 (binary): Likewise
990 (print_label): Likewise
991 (pushf_register_address): Likewise
992 (pushf_register): Likewise
993 (do_compile_dwarf_expr_to_c): Likewise
994 (compile_dwarf_expr_to_c): Likewise
995 (compile_dwarf_bounds_to_c): Likewise
996 * compile/compile.c (compile_instance::get_cached_type):
997 Likewise
998 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
999 (compile_dwarf_bounds_to_c): Likewise
1000 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
1001 (dwarf2_compile_property_to_c): Likewise
1002 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
1003 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1004 Likewise
1005
1006 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1007
1008 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
1009 * tui/tui-data.c (init_content_element): Don't initialize it.
1010
1011 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1012
1013 * tui/tui-data.h (struct tui_win_info)
1014 <detail::opaque>: Remove.
1015 * tui/tui-data.c (init_win_info): Remove assignment.
1016
1017 2018-09-05 Tom Tromey <tom@tromey.com>
1018
1019 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
1020 -Wformat-nonliteral.
1021 * target-float.c (host_float_ops<T>::to_string)
1022 (host_float_ops<T>::from_string): Use
1023 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1024 * configure: Rebuild.
1025
1026 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
1027
1028 * printcmd.c (printf_c_string): Use
1029 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1030 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
1031
1032 2018-09-05 Tom Tromey <tom@tromey.com>
1033
1034 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
1035
1036 2018-09-05 Tom de Vries <tdevries@suse.de>
1037
1038 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1039 with resolve_abstract_p == true.
1040 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1041 defaulting to false. Propagate resolve_abstract_p to
1042 dwarf2_fetch_die_loc_sect_off.
1043 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1044 parameter, defaulting to false.
1045 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1046 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1047 parameter.
1048 * dwarf2read.h (struct die_info): Forward-declare.
1049 (die_info_ptr): New typedef.
1050 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1051
1052 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1053
1054 GDB 8.2 released.
1055
1056 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1057 Pedro Alves <palves@redhat.com>
1058
1059 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1060 "aclocal-m4-deps.mk". Include file here.
1061 $(srcdir)/aclocal.m4: Add "configure.ac".
1062 * gnulib/aclocal-m4-deps.mk: New file.
1063 * gnulib/update-gnulib.sh: Automatically update
1064 "aclocal-m4-deps.mk".
1065
1066 2018-09-04 Tom Tromey <tom@tromey.com>
1067
1068 * configure: Rebuild.
1069 * configure.ac: Remove multi-ice code.
1070
1071 2018-09-04 Tom Tromey <tom@tromey.com>
1072
1073 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
1074 (ada-exp.o): Update.
1075
1076 2018-09-04 Tom Tromey <tom@tromey.com>
1077
1078 * Makefile.in (printcmd.o, target-float.o): Remove.
1079 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
1080
1081 2018-09-04 Tom Tromey <tom@tromey.com>
1082
1083 * gnulib/Makefile.in: Remove obsolete comment.
1084 * Makefile.in: Remove obsolete comment.
1085
1086 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
1087
1088 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
1089 line with '+'.
1090
1091 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1092
1093 * riscv-tdep.c: Add 'prologue-value.h' include.
1094 (struct riscv_unwind_cache): New struct.
1095 (riscv_debug_unwinder): New global.
1096 (riscv_scan_prologue): Update arguments, capture register details
1097 from prologue scan.
1098 (riscv_skip_prologue): Reformat arguments line, move end of
1099 prologue calculation into riscv_scan_prologue.
1100 (riscv_frame_cache): Update return type, create
1101 riscv_unwind_cache, scan the prologue, and fill in remaining cache
1102 details.
1103 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
1104 (riscv_frame_prev_register): Use the trad_frame within the
1105 riscv_unwind_cache.
1106 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
1107 flag.
1108
1109 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1110
1111 * trad-frame.h (trad_frame_set_realreg): Declare.
1112 (trad_frame_set_addr): Declare.
1113 * trad-frame.c (trad_frame_set_realreg): Define new function.
1114 (trad_frame_set_addr): Define new function.
1115 (trad_frame_set_reg_realreg): Use new function.
1116 (trad_frame_set_reg_addr): Use new function.
1117
1118 2018-09-01 Keith Seitz <keiths@redhat.com>
1119
1120 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
1121 pulongest instead of "%lld".
1122 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
1123 ATTRIBUTE_UNUSED.
1124
1125 2018-08-31 Tom Tromey <tom@tromey.com>
1126
1127 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
1128 variant part type.
1129
1130 2018-08-31 Pedro Alves <palves@redhat.com>
1131
1132 * gdbarch.h: Regenerate.
1133
1134 2018-08-31 Pedro Alves <palves@redhat.com>
1135
1136 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
1137 * target.h (Hardware watchpoint interfaces): Describe
1138 continuable/steppable/non-steppable watchpoints.
1139 * gdbarch.h, gdbarch.c: Regenerate.
1140
1141 2018-08-31 Pedro Alves <palves@redhat.com>
1142
1143 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
1144 Delete.
1145 * s390-linux-nat.c
1146 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
1147 * target.h (target_ops::have_continuable_watchpoint): Delete.
1148 (target_have_continuable_watchpoint): Delete.
1149 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
1150 * target-delegates.c: Regenerate.
1151
1152 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1153
1154 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
1155 the files present in "gnulib/import/m4/".
1156
1157 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1158
1159 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
1160 c.sw, c.swsp, and c.sdsp.
1161
1162 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1163
1164 * riscv-tdep.c (struct riscv_inferior_data): Delete.
1165 (riscv_read_misa_reg): Don't cache value read into inferior data.
1166 (riscv_new_inferior_data): Delete.
1167 (riscv_inferior_data_cleanup): Delete.
1168 (riscv_inferior_data): Delete.
1169 (riscv_invalidate_inferior_data): Delete.
1170 (_initialize_riscv_tdep): Remove initialisation of inferior data.
1171
1172 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
1173
1174 * compile/compile-cplus-types.c
1175 (compile_cplus_instance::leave_scope): Take the address of scope
1176 object.
1177 (compile_cplus_instance::convert_qualified_base): Compare quals
1178 to 0.
1179
1180 2018-08-30 Keith Seitz <keiths@redhat.com>
1181
1182 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
1183 Use "%s" and host_address_to_string instead of "%p" in printf.
1184
1185 2018-08-29 Keith Seitz <keiths@redhat.com>
1186
1187 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
1188 and compile-cplus-types.c.
1189 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
1190 * c-lang.c (cplus_language_defn): Set C++ compile functions.
1191 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
1192 Declare.
1193 * compile/compile-c-support.c: Include compile-cplus.h.
1194 (load_libcompile): Templatize.
1195 (get_compile_context): "New" function.
1196 (c_get_compile_context): Use get_compile_context.
1197 (cplus_get_compile_context): New function.
1198 (cplus_push_user_expression, cplus_pop_user_expression)
1199 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
1200 (cplus_compute_program): Define new structs/functions.
1201 * compile/compile-cplus-symmbols.c: New file.
1202 * compile/compile-cplus-types.c: New file.
1203 * compile/compile-cplus.h: New file.
1204 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
1205 Declare.
1206 * compile/compile-object-load.c (get_out_value_type): Use
1207 strncmp_iw when comparing symbol names.
1208 (compile_object_load): Add mst_bss and mst_data.
1209 * compile/compile.c (_initialize_compile): Remove
1210 -Wno-implicit-function-declaration from `compile_args'.
1211 * compile/gcc-cp-plugin.h: New file.
1212 * NEWS: Mention C++ compile support and new debug options.
1213
1214 2018-08-29 Keith Seitz <keiths@redhat.com>
1215
1216 * linespec.c (collect_info::add_symbol): Make virtual.
1217 (struct symbol_searcher_collect_info): New struct.
1218 (symbol_searcher::find_all_symbols): New method.
1219 * symtab.h (class symbol_searcher): New class.
1220
1221 2018-08-29 Keith Seitz <keiths@redhat.com>
1222
1223 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1224 Change to vector of block_symbol. Update all users.
1225 (struct collect_info) <symbols>: Likewise.
1226 (collect_info::add_symbol): Take block_symbol as argument.
1227 Update all callers.
1228 (decode_compound_collector) <m_symbols>: Change type to vector
1229 of block_symbol. Update all users.
1230 (decode_compound_collector::operator ()): Change parameter type
1231 to block_symbol.
1232 (find_method, find_function_symbols, find_linespec_symbols)
1233 (find_label_symbols_in_block, find_label_symbols): Change symbol
1234 vectors to block_symbol vectors.
1235 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1236 block_symbol.
1237
1238 2018-08-29 Keith Seitz <keiths@redhat.com>
1239
1240 * linespec.c (symbolp): Remove typedef and VEC definitions.
1241 (bound_minimal_symbol_d): Likewise.
1242
1243 2018-08-29 Keith Seitz <keiths@redhat.com>
1244
1245 * linespec.c (decode_compound_collector::decode_compound_collector):
1246 Remove initialization for `m_symtabs'.
1247 (decode_compound_collector::release_symbols): Change return type
1248 to std::vector. Update all callers.
1249 (class decode_compound_collector) <m_symbols>: Change type to
1250 std::vector.
1251 (lookup_prefix_sym): Change return type to std::vector. Update all
1252 callers.
1253 (compare_symbols): Remove.
1254 (std_compare_symbols): Rename to `compare_symbols'.
1255 (find_method): Change `sym_classes' parameter to std::vector.
1256 Update all callers. Use std::sort to sort sym_classes.
1257 (find_linespec_symbols): Remove cleanup.
1258
1259 2018-08-29 Keith Seitz <keiths@redhat.com>
1260
1261 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1262 std::vector. Update all users.
1263 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1264 (struct collect_info) <minimal_symbols>: Likewise.
1265 (compare_msymbols): Return bool. Change parameters to const
1266 bound_minimal_symbol references.
1267 (find_method, find_function_symbols, find_linespec_symbols): Change
1268 `minsyms' parameter to std::vector. Update all callers.
1269
1270 2018-08-29 Keith Seitz <keiths@redhat.com>
1271
1272 * linespec.c (struct linespec) <label_symbols>: Change type to
1273 std::vector. Update all users.
1274 (find_label_symbols_in_block): Change `result' parameter to
1275 std::vector. Update all callers.
1276 (find_label_symbols): Return std::vector. Update all callers.
1277
1278 2018-08-29 Keith Seitz <keiths@redhat.com>
1279
1280 * linespec.c (struct linespec) <function_symbols>: Change type to
1281 std::vector. Update all users.
1282 (struct collect_info) <function_symbols>: Likewise.
1283 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1284 (std_compare_symbols): New function.
1285 (find_method, find_function_symbols, find_linespec_symbols)
1286 (find_label_symbols_in_block): Change `symbols' parameter to
1287 std::vector. Update all callers.
1288 (find_label_symbols): Likewise for `function_symbols' and
1289 `label_funcs_ret'.
1290
1291 2018-08-29 Keith Seitz <keiths@redhat.com>
1292
1293 * linespec.c (symtab_vector_up): Define.
1294 (struct linespec) <file_symtabs>: Change type to std::vector *.
1295 Update all uses.
1296 (struct collect_info) <file_symtabs>: Likewise.
1297 (collect_symtabs_from_filename): Return symtab_vector_up.
1298 Update all callers.
1299 (decode_objc): Remove cleanup.
1300 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1301 (symtab_collector::release_symtabs): Return symtab_vector_up.
1302 Update all callers.
1303 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1304 Update all users.
1305 (collect_symtabs_from_filename, symtabs_from_filename): Return
1306 symtab_vector_up. Update all callers.
1307
1308 2018-08-29 Tom Tromey <tom@tromey.com>
1309
1310 * csky-tdep.c (csky_analyze_prologue): Use
1311 core_addr_to_string_nz.
1312
1313 2018-08-29 Tom Tromey <tom@tromey.com>
1314
1315 * windows-nat.c (struct xlate_exception) <them>: Change type to
1316 DWORD.
1317 (xlate): Fix formatting. Remove last entry.
1318 (struct xlate_exception, xlate): Comment out.
1319 (windows_nat_target::resume): Use ranged for.
1320
1321 2018-08-29 Jim Wilson <jimw@sifive.com>
1322
1323 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1324 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1325 of NT_PRFPREG.
1326 (riscv_linux_nat_target::store_registers): Likewise.
1327
1328 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1329
1330 PR gdb/23555
1331 PR gdb/23558
1332 * gnulib/aclocal.m4: Regenerate.
1333 * gnulib/config.in: Regenerate.
1334 * gnulib/configure: Regenerate.
1335 * gnulib/import/Makefile.am: Update.
1336 * gnulib/import/Makefile.in: Update.
1337 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1338 * gnulib/import/_Noreturn.h: ... this.
1339 * gnulib/import/alloca.in.h: Update.
1340 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1341 * gnulib/import/arg-nonnull.h: ... this.
1342 * gnulib/import/assure.h: Update.
1343 * gnulib/import/at-func.c: Update.
1344 * gnulib/import/basename-lgpl.c: Update.
1345 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1346 * gnulib/import/c++defs.h: ... this.
1347 * gnulib/import/canonicalize-lgpl.c: Update.
1348 * gnulib/import/cdefs.h: Update.
1349 * gnulib/import/chdir-long.c: Update.
1350 * gnulib/import/chdir-long.h: Update.
1351 * gnulib/import/cloexec.c: Update.
1352 * gnulib/import/cloexec.h: Update.
1353 * gnulib/import/close.c: Update.
1354 * gnulib/import/closedir.c: Update.
1355 * gnulib/import/config.charset: Update.
1356 * gnulib/import/dirent-private.h: Update.
1357 * gnulib/import/dirent.in.h: Update.
1358 * gnulib/import/dirfd.c: Update.
1359 * gnulib/import/dirname-lgpl.c: Update.
1360 * gnulib/import/dirname.h: Update.
1361 * gnulib/import/dosname.h: Update.
1362 * gnulib/import/dup-safer-flag.c: Update.
1363 * gnulib/import/dup-safer.c: Update.
1364 * gnulib/import/dup.c: Update.
1365 * gnulib/import/dup2.c: Update.
1366 * gnulib/import/errno.in.h: Update.
1367 * gnulib/import/error.c: Update.
1368 * gnulib/import/error.h: Update.
1369 * gnulib/import/exitfail.c: Update.
1370 * gnulib/import/exitfail.h: Update.
1371 * gnulib/import/extra/update-copyright: Update.
1372 * gnulib/import/fchdir.c: Update.
1373 * gnulib/import/fcntl.c: Update.
1374 * gnulib/import/fcntl.in.h: Update.
1375 * gnulib/import/fd-hook.c: Update.
1376 * gnulib/import/fd-hook.h: Update.
1377 * gnulib/import/fd-safer-flag.c: Update.
1378 * gnulib/import/fd-safer.c: Update.
1379 * gnulib/import/fdopendir.c: Update.
1380 * gnulib/import/filename.h: Update.
1381 * gnulib/import/filenamecat-lgpl.c: Update.
1382 * gnulib/import/filenamecat.h: Update.
1383 * gnulib/import/flexmember.h: Update.
1384 * gnulib/import/float+.h: Update.
1385 * gnulib/import/float.c: Update.
1386 * gnulib/import/float.in.h: Update.
1387 * gnulib/import/fnmatch.c: Update.
1388 * gnulib/import/fnmatch.in.h: Update.
1389 * gnulib/import/fnmatch_loop.c: Update.
1390 * gnulib/import/fpucw.h: Update.
1391 * gnulib/import/frexp.c: Update.
1392 * gnulib/import/frexpl.c: Update.
1393 * gnulib/import/fstat.c: Update.
1394 * gnulib/import/fstatat.c: Update.
1395 * gnulib/import/getcwd-lgpl.c: Update.
1396 * gnulib/import/getcwd.c: Update.
1397 * gnulib/import/getdtablesize.c: Update.
1398 * gnulib/import/getlogin_r.c: Update.
1399 * gnulib/import/getprogname.c: Update.
1400 * gnulib/import/getprogname.h: Update.
1401 * gnulib/import/gettext.h: Update.
1402 * gnulib/import/gettimeofday.c: Update.
1403 * gnulib/import/glob-libc.h: Update.
1404 * gnulib/import/glob.c: Update.
1405 * gnulib/import/glob.in.h: Update.
1406 * gnulib/import/glob_internal.h: Update.
1407 * gnulib/import/glob_pattern_p.c: Update.
1408 * gnulib/import/globfree.c: Update.
1409 * gnulib/import/hard-locale.c: Update.
1410 * gnulib/import/hard-locale.h: Update.
1411 * gnulib/import/intprops.h: Update.
1412 * gnulib/import/inttypes.in.h: Update.
1413 * gnulib/import/isnan.c: Update.
1414 * gnulib/import/isnand-nolibm.h: Update.
1415 * gnulib/import/isnand.c: Update.
1416 * gnulib/import/isnanl-nolibm.h: Update.
1417 * gnulib/import/isnanl.c: Update.
1418 * gnulib/import/itold.c: Update.
1419 * gnulib/import/libc-config.h: Update.
1420 * gnulib/import/limits.in.h: Update.
1421 * gnulib/import/localcharset.c: Update.
1422 * gnulib/import/localcharset.h: Update.
1423 * gnulib/import/localtime-buffer.c: Update.
1424 * gnulib/import/localtime-buffer.h: Update.
1425 * gnulib/import/lstat.c: Update.
1426 * gnulib/import/m4/00gnulib.m4: Update.
1427 * gnulib/import/m4/__inline.m4: Update.
1428 * gnulib/import/m4/absolute-header.m4: Update.
1429 * gnulib/import/m4/alloca.m4: Update.
1430 * gnulib/import/m4/builtin-expect.m4: Update.
1431 * gnulib/import/m4/canonicalize.m4: Update.
1432 * gnulib/import/m4/chdir-long.m4: Update.
1433 * gnulib/import/m4/close.m4: Update.
1434 * gnulib/import/m4/closedir.m4: Update.
1435 * gnulib/import/m4/configmake.m4: Update.
1436 * gnulib/import/m4/d-ino.m4: Update.
1437 * gnulib/import/m4/d-type.m4: Update.
1438 * gnulib/import/m4/dirent_h.m4: Update.
1439 * gnulib/import/m4/dirfd.m4: Update.
1440 * gnulib/import/m4/dirname.m4: Update.
1441 * gnulib/import/m4/double-slash-root.m4: Update.
1442 * gnulib/import/m4/dup.m4: Update.
1443 * gnulib/import/m4/dup2.m4: Update.
1444 * gnulib/import/m4/eealloc.m4: Update.
1445 * gnulib/import/m4/environ.m4: Update.
1446 * gnulib/import/m4/errno_h.m4: Update.
1447 * gnulib/import/m4/error.m4: Update.
1448 * gnulib/import/m4/exponentd.m4: Update.
1449 * gnulib/import/m4/exponentl.m4: Update.
1450 * gnulib/import/m4/extensions.m4: Update.
1451 * gnulib/import/m4/extern-inline.m4: Update.
1452 * gnulib/import/m4/fchdir.m4: Update.
1453 * gnulib/import/m4/fcntl-o.m4: Update.
1454 * gnulib/import/m4/fcntl.m4: Update.
1455 * gnulib/import/m4/fcntl_h.m4: Update.
1456 * gnulib/import/m4/fdopendir.m4: Update.
1457 * gnulib/import/m4/filenamecat.m4: Update.
1458 * gnulib/import/m4/flexmember.m4: Update.
1459 * gnulib/import/m4/float_h.m4: Update.
1460 * gnulib/import/m4/fnmatch.m4: Update.
1461 * gnulib/import/m4/fnmatch_h.m4: Update.
1462 * gnulib/import/m4/fpieee.m4: Update.
1463 * gnulib/import/m4/frexp.m4: Update.
1464 * gnulib/import/m4/frexpl.m4: Update.
1465 * gnulib/import/m4/fstat.m4: Update.
1466 * gnulib/import/m4/fstatat.m4: Update.
1467 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1468 * gnulib/import/m4/getcwd-path-max.m4: Update.
1469 * gnulib/import/m4/getcwd.m4: Update.
1470 * gnulib/import/m4/getdtablesize.m4: Update.
1471 * gnulib/import/m4/getlogin.m4: Update.
1472 * gnulib/import/m4/getlogin_r.m4: Update.
1473 * gnulib/import/m4/getpagesize.m4: Update.
1474 * gnulib/import/m4/getprogname.m4: Update.
1475 * gnulib/import/m4/gettimeofday.m4: Update.
1476 * gnulib/import/m4/glibc21.m4: Update.
1477 * gnulib/import/m4/glob.m4: Update.
1478 * gnulib/import/m4/glob_h.m4: Update.
1479 * gnulib/import/m4/gnulib-cache.m4: Update.
1480 * gnulib/import/m4/gnulib-common.m4: Update.
1481 * gnulib/import/m4/gnulib-comp.m4: Update.
1482 * gnulib/import/m4/gnulib-tool.m4: Update.
1483 * gnulib/import/m4/hard-locale.m4: Update.
1484 * gnulib/import/m4/include_next.m4: Update.
1485 * gnulib/import/m4/inttypes-pri.m4: Update.
1486 * gnulib/import/m4/inttypes.m4: Update.
1487 * gnulib/import/m4/isnand.m4: Update.
1488 * gnulib/import/m4/isnanl.m4: Update.
1489 * gnulib/import/m4/largefile.m4: Update.
1490 * gnulib/import/m4/limits-h.m4: Update.
1491 * gnulib/import/m4/localcharset.m4: Update.
1492 * gnulib/import/m4/locale-fr.m4: Update.
1493 * gnulib/import/m4/locale-ja.m4: Update.
1494 * gnulib/import/m4/locale-zh.m4: Update.
1495 * gnulib/import/m4/localtime-buffer.m4: Update.
1496 * gnulib/import/m4/longlong.m4: Update.
1497 * gnulib/import/m4/lstat.m4: Update.
1498 * gnulib/import/m4/malloc.m4: Update.
1499 * gnulib/import/m4/malloca.m4: Update.
1500 * gnulib/import/m4/math_h.m4: Update.
1501 * gnulib/import/m4/mbrtowc.m4: Update.
1502 * gnulib/import/m4/mbsinit.m4: Update.
1503 * gnulib/import/m4/mbsrtowcs.m4: Update.
1504 * gnulib/import/m4/mbstate_t.m4: Update.
1505 * gnulib/import/m4/memchr.m4: Update.
1506 * gnulib/import/m4/memmem.m4: Update.
1507 * gnulib/import/m4/mempcpy.m4: Update.
1508 * gnulib/import/m4/memrchr.m4: Update.
1509 * gnulib/import/m4/mkdir.m4: Update.
1510 * gnulib/import/m4/mkstemp.m4: Update.
1511 * gnulib/import/m4/mmap-anon.m4: Update.
1512 * gnulib/import/m4/mode_t.m4: Update.
1513 * gnulib/import/m4/msvc-inval.m4: Update.
1514 * gnulib/import/m4/msvc-nothrow.m4: Update.
1515 * gnulib/import/m4/multiarch.m4: Update.
1516 * gnulib/import/m4/nocrash.m4: Update.
1517 * gnulib/import/m4/off_t.m4: Update.
1518 * gnulib/import/m4/onceonly.m4: Update.
1519 * gnulib/import/m4/open-cloexec.m4: Update.
1520 * gnulib/import/m4/open.m4: Update.
1521 * gnulib/import/m4/openat.m4: Update.
1522 * gnulib/import/m4/opendir.m4: Update.
1523 * gnulib/import/m4/pathmax.m4: Update.
1524 * gnulib/import/m4/rawmemchr.m4: Update.
1525 * gnulib/import/m4/readdir.m4: Update.
1526 * gnulib/import/m4/readlink.m4: Update.
1527 * gnulib/import/m4/realloc.m4: Update.
1528 * gnulib/import/m4/rename.m4: Update.
1529 * gnulib/import/m4/rewinddir.m4: Update.
1530 * gnulib/import/m4/rmdir.m4: Update.
1531 * gnulib/import/m4/save-cwd.m4: Update.
1532 * gnulib/import/m4/secure_getenv.m4: Update.
1533 * gnulib/import/m4/setenv.m4: Update.
1534 * gnulib/import/m4/signal_h.m4: Update.
1535 * gnulib/import/m4/ssize_t.m4: Update.
1536 * gnulib/import/m4/stat-time.m4: Update.
1537 * gnulib/import/m4/stat.m4: Update.
1538 * gnulib/import/m4/std-gnu11.m4: Update.
1539 * gnulib/import/m4/stdbool.m4: Update.
1540 * gnulib/import/m4/stddef_h.m4: Update.
1541 * gnulib/import/m4/stdint.m4: Update.
1542 * gnulib/import/m4/stdio_h.m4: Update.
1543 * gnulib/import/m4/stdlib_h.m4: Update.
1544 * gnulib/import/m4/strchrnul.m4: Update.
1545 * gnulib/import/m4/strdup.m4: Update.
1546 * gnulib/import/m4/strerror.m4: Update.
1547 * gnulib/import/m4/string_h.m4: Update.
1548 * gnulib/import/m4/strstr.m4: Update.
1549 * gnulib/import/m4/strtok_r.m4: Update.
1550 * gnulib/import/m4/sys_socket_h.m4: Update.
1551 * gnulib/import/m4/sys_stat_h.m4: Update.
1552 * gnulib/import/m4/sys_time_h.m4: Update.
1553 * gnulib/import/m4/sys_types_h.m4: Update.
1554 * gnulib/import/m4/tempname.m4: Update.
1555 * gnulib/import/m4/time_h.m4: Update.
1556 * gnulib/import/m4/unistd-safer.m4: Update.
1557 * gnulib/import/m4/unistd_h.m4: Update.
1558 * gnulib/import/m4/warn-on-use.m4: Update.
1559 * gnulib/import/m4/wchar_h.m4: Update.
1560 * gnulib/import/m4/wchar_t.m4: Update.
1561 * gnulib/import/m4/wctype_h.m4: Update.
1562 * gnulib/import/m4/wint_t.m4: Update.
1563 * gnulib/import/malloc.c: Update.
1564 * gnulib/import/malloc/scratch_buffer.h: Update.
1565 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1566 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1567 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1568 * gnulib/import/malloca.c: Update.
1569 * gnulib/import/malloca.h: Update.
1570 * gnulib/import/malloca.valgrind: Update.
1571 * gnulib/import/math.in.h: Update.
1572 * gnulib/import/mbrtowc.c: Update.
1573 * gnulib/import/mbsinit.c: Update.
1574 * gnulib/import/mbsrtowcs-impl.h: Update.
1575 * gnulib/import/mbsrtowcs-state.c: Update.
1576 * gnulib/import/mbsrtowcs.c: Update.
1577 * gnulib/import/memchr.c: Update.
1578 * gnulib/import/memmem.c: Update.
1579 * gnulib/import/mempcpy.c: Update.
1580 * gnulib/import/memrchr.c: Update.
1581 * gnulib/import/mkdir.c: Update.
1582 * gnulib/import/mkstemp.c: Update.
1583 * gnulib/import/msvc-inval.c: Update.
1584 * gnulib/import/msvc-inval.h: Update.
1585 * gnulib/import/msvc-nothrow.c: Update.
1586 * gnulib/import/msvc-nothrow.h: Update.
1587 * gnulib/import/open.c: Update.
1588 * gnulib/import/openat-die.c: Update.
1589 * gnulib/import/openat-priv.h: Update.
1590 * gnulib/import/openat-proc.c: Update.
1591 * gnulib/import/openat.c: Update.
1592 * gnulib/import/openat.h: Update.
1593 * gnulib/import/opendir.c: Update.
1594 * gnulib/import/pathmax.h: Update.
1595 * gnulib/import/pipe-safer.c: Update.
1596 * gnulib/import/rawmemchr.c: Update.
1597 * gnulib/import/readdir.c: Update.
1598 * gnulib/import/readlink.c: Update.
1599 * gnulib/import/realloc.c: Update.
1600 * gnulib/import/ref-add.sin: Update.
1601 * gnulib/import/ref-del.sin: Update.
1602 * gnulib/import/rename.c: Update.
1603 * gnulib/import/rewinddir.c: Update.
1604 * gnulib/import/rmdir.c: Update.
1605 * gnulib/import/same-inode.h: Update.
1606 * gnulib/import/save-cwd.c: Update.
1607 * gnulib/import/save-cwd.h: Update.
1608 * gnulib/import/scratch_buffer.h: Update.
1609 * gnulib/import/secure_getenv.c: Update.
1610 * gnulib/import/setenv.c: Update.
1611 * gnulib/import/signal.in.h: Update.
1612 * gnulib/import/stat-time.c: Update.
1613 * gnulib/import/stat-time.h: Update.
1614 * gnulib/import/stat-w32.c: Update.
1615 * gnulib/import/stat-w32.h: Update.
1616 * gnulib/import/stat.c: Update.
1617 * gnulib/import/stdbool.in.h: Update.
1618 * gnulib/import/stddef.in.h: Update.
1619 * gnulib/import/stdint.in.h: Update.
1620 * gnulib/import/stdio.in.h: Update.
1621 * gnulib/import/stdlib.in.h: Update.
1622 * gnulib/import/str-two-way.h: Update.
1623 * gnulib/import/strchrnul.c: Update.
1624 * gnulib/import/strdup.c: Update.
1625 * gnulib/import/streq.h: Update.
1626 * gnulib/import/strerror-override.c: Update.
1627 * gnulib/import/strerror-override.h: Update.
1628 * gnulib/import/strerror.c: Update.
1629 * gnulib/import/string.in.h: Update.
1630 * gnulib/import/stripslash.c: Update.
1631 * gnulib/import/strnlen1.c: Update.
1632 * gnulib/import/strnlen1.h: Update.
1633 * gnulib/import/strstr.c: Update.
1634 * gnulib/import/strtok_r.c: Update.
1635 * gnulib/import/sys_stat.in.h: Update.
1636 * gnulib/import/sys_time.in.h: Update.
1637 * gnulib/import/sys_types.in.h: Update.
1638 * gnulib/import/tempname.c: Update.
1639 * gnulib/import/tempname.h: Update.
1640 * gnulib/import/time.in.h: Update.
1641 * gnulib/import/unistd--.h: Update.
1642 * gnulib/import/unistd-safer.h: Update.
1643 * gnulib/import/unistd.in.h: Update.
1644 * gnulib/import/unsetenv.c: Update.
1645 * gnulib/import/verify.h: Update.
1646 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1647 * gnulib/import/wchar.in.h: Update.
1648 * gnulib/import/wctype.in.h: Update.
1649 * gnulib/import/xalloc-oversized.h: Update.
1650 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1651 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1652
1653 2018-08-16 Gary Benson <gbenson@redhat.com>
1654
1655 PR gdb/13000:
1656 * gdb/main.c (captured_main_1): Exit with nonzero status
1657 in batch mode if the last command to be executed failed.
1658 * NEWS: Mention the above.
1659
1660 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1661
1662 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1663 end of warning message.
1664
1665 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1666
1667 PR gdb/22943:
1668 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1669 (aarch64_extract_return_value): Use
1670 aapcs_is_vfp_call_or_return_candidate.
1671 (aarch64_return_in_memory): Likewise.
1672 (aarch64_store_return_value): Likewise.
1673
1674 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1675
1676 * aarch64-tdep.c
1677 (aapcs_is_vfp_call_or_return_candidate): Make static
1678 (pass_in_v_or_stack): Remove function.
1679 (pass_in_v_vfp_candidate): New function.
1680 (aarch64_push_dummy_call): Check for float register candidates.
1681
1682 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1683
1684 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1685 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1686 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1687
1688 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1689
1690 PR build/23399
1691 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1692 (struct ipa_sym_addresses): Rename to...
1693 (struct ipa_sym_addresses_common): ... this.
1694 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1695
1696 2018-08-28 Tom Tromey <tom@tromey.com>
1697
1698 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1699 (token_fifo): Now a std::vector.
1700 (yylex, c_parse): Update.
1701 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1702 (token_fifo): Now a std::vector.
1703 (yylex, d_parse): Update.
1704 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1705 (token_fifo): Now a std::vector.
1706 (yylex, go_parse): Update.
1707
1708 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1709
1710 * parser-defs.h (struct type_stack) <elements>: Change type to
1711 std::vector<union type_stack_elt>.
1712 <depth, size>: Remove.
1713 * parse.c (parse_exp_in_context_1): Adjust.
1714 (type_stack_reserve): Remove.
1715 (check_type_stack_depth): Remove.
1716 (insert_into_type_stack): Adjust to std::vector.
1717 (insert_type): Likewise.
1718 (push_type): Likewise.
1719 (push_type_int): Likewise.
1720 (insert_type_address_space): Likewise.
1721 (pop_type): Likewise.
1722 (pop_type_int): Likewise.
1723 (pop_typelist): Likewise.
1724 (pop_type_stack): Likewise.
1725 (append_type_stack): Likewise.
1726 (push_type_stack): Likewise.
1727 (get_type_stack): Likewise.
1728 (type_stack_cleanup): Likewise.
1729 (push_typelist): Likewise.
1730 (follow_types): Likewise.
1731 (_initialize_parse): Likewise.
1732
1733 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1734
1735 * NEWS: Mention csky target.
1736
1737 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1738 Hafiz Abid Qadeer <abidh@codesourcery.com>
1739 Don Breazeal <donb@codesourcery.com>
1740
1741 * csky-linux-tdep.c: New file.
1742 * csky-tdep.c: Likewise.
1743 * csky-tdep.h: Likewise.
1744 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1745 csky-tdep.o.
1746 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1747 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1748 * configure.tgt: Add csky support.
1749
1750 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1751
1752 * python/py-framefilter.c (py_print_frame): Print frame architecture
1753 when printing on an MI output.
1754
1755 2018-08-27 Tom Tromey <tom@tromey.com>
1756
1757 PR build/23087:
1758 * configure: Rebuild.
1759 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1760
1761 2018-08-27 Tom Tromey <tom@tromey.com>
1762
1763 * aarch64-linux-tdep.c
1764 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1765 casts to int.
1766
1767 2018-08-27 Tom Tromey <tom@tromey.com>
1768
1769 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1770 unsigned.
1771 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1772 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1773 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1774 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1775 unsigned.
1776
1777 2018-08-27 Tom Tromey <tom@tromey.com>
1778
1779 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1780 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1781
1782 2018-08-27 Tom Tromey <tom@tromey.com>
1783
1784 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1785 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1786 ULONGEST_MAX.
1787 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1788 ULONGEST_MAX.
1789 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1790 ULONGEST_MAX.
1791 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1792 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1793 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1794 ULONGEST_MAX.
1795 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1796 (ppc64_linux_sigaction_tramp_frame)
1797 (ppc32_linux_sighandler_tramp_frame)
1798 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1799 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1800 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1801 * mn10300-linux-tdep.c (am33_linux_sigframe)
1802 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1803 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1804 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1805 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1806 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1807 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1808 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1809 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1810 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1811 * microblaze-linux-tdep.c
1812 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1813 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1814 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1815 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1816 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1817 * common/common-types.h (ULONGEST_MAX): New define.
1818 (CORE_ADDR_MAX): Fix formatting.
1819 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1820 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1821 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1822 (arm_linux_rt_sigreturn_tramp_frame)
1823 (arm_eabi_linux_sigreturn_tramp_frame)
1824 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1825 (thumb2_eabi_linux_sigreturn_tramp_frame)
1826 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1827 (arm_linux_restart_syscall_tramp_frame)
1828 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1829 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1830 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1831 ULONGEST_MAX.
1832 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1833
1834 2018-08-27 Tom Tromey <tom@tromey.com>
1835
1836 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1837 CORE_ADDR_MAX.
1838 * mips-tdep.c (mips_deal_with_atomic_sequence)
1839 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1840 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1841 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1842 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1843 CORE_ADDR_MAX.
1844 * aarch64-tdep.c (aarch64_software_single_step): Use
1845 CORE_ADDR_MAX.
1846
1847 2018-08-27 Tom Tromey <tom@tromey.com>
1848
1849 * linespec.c (complete_linespec_component): Add cast to "char".
1850 * completer.c (completion_tracker::build_completion_result): Add
1851 cast to "char".
1852
1853 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1854
1855 * solist.h (struct solist, struct target_so_ops): Fix
1856 indentation.
1857
1858 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1859
1860 * ada-tasks.c (ada_task_info_s): Remove typedef.
1861 (DEF_VEC_O(ada_task_info_s)): Remove.
1862 (struct ada_tasks_inferior_data): Initialize fields.
1863 <task_list>: Make an std::vector.
1864 (get_ada_tasks_inferior_data): Allocate with new.
1865 (ada_get_task_number): Adjust.
1866 (get_task_number_from_id): Likewise.
1867 (valid_task_id): Likewise.
1868 (ada_get_task_info_from_ptid): Likewise.
1869 (iterate_over_live_ada_tasks): Likewise.
1870 (add_ada_task): Likewise.
1871 (read_known_tasks): Likewise.
1872 (ada_build_task_list): Likewise.
1873 (print_ada_task_info): Likewise.
1874 (info_task): Likewise.
1875 (task_command_1): Likewise.
1876
1877 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1878
1879 * ada-lang.c (add_angle_brackets): Return std::string.
1880
1881 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1882
1883 * python/py-threadevent.c (py_get_event_thread): Initialize
1884 pythread.
1885
1886 2018-08-24 Pedro Alves <palves@redhat.com>
1887
1888 * python/py-bpevent.c (create_breakpoint_event_object): Use
1889 copy-initialization.
1890 * python/py-continueevent.c (emit_continue_event): Use
1891 copy-initialization.
1892 * python/py-exitedevent.c (create_exited_event_object): Return a
1893 gdbpy_ref<>.
1894 (emit_exited_event): Use copy-initialization.
1895 * python/py-inferior.c (python_new_inferior)
1896 (python_inferior_deleted, add_thread_object): Use
1897 copy-initialization.
1898 * python/py-infevents.c (create_inferior_call_event_object)
1899 (create_register_changed_event_object)
1900 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1901 (emit_inferior_call_event, emit_memory_changed_event)
1902 (emit_register_changed_event): Use copy-initialization.
1903 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1904 Return a gdbpy_ref<>.
1905 (emit_new_objfile_event): Use copy-initialization.
1906 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1907 (emit_clear_objfiles_event): Use copy-initialization.
1908 * python/py-signalevent.c (create_signal_event_object): Use
1909 copy-initialization.
1910 * python/py-threadevent.c (create_thread_event_object): Use
1911 copy-initialization.
1912
1913 2018-08-24 Pedro Alves <palves@redhat.com>
1914 Simon Marchi <simon.marchi@ericsson.com>
1915
1916 PR gdb/23379
1917 * python/py-continueevent.c: Include "gdbthread.h".
1918 (create_continue_event_object): Add intro comment. Add 'ptid'
1919 parameter. Use it to find thread to pass to
1920 create_thread_event_object.
1921 (emit_continue_event): Pass PTID down to
1922 create_continue_event_object.
1923 * python/py-event.h (py_get_event_thread): Declare.
1924 (create_thread_event_object): Remove default from 'thread'
1925 parameter.
1926 * python/py-stopevent.c (create_stop_event_object): Use
1927 py_get_event_thread.
1928 * python/py-threadevent.c (get_event_thread): Rename to ...
1929 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1930 and use it to find the thread.
1931 (create_thread_event_object): Assert that THREAD isn't null.
1932 Don't find the event thread here.
1933
1934 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1935
1936 * block.h (blockrange, blockranges): New struct declarations.
1937 (struct block): Add new field named `ranges'.
1938 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1939 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
1940 macros for accessing ranges in struct block.
1941 (make_blockranges): New declaration.
1942 block.c (make_blockranges): New function.
1943 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
1944 for block.
1945 * symtab.h (find_pc_partial_function): Add new parameter `block'.
1946 * blockframe.c (cache_pc_function_block): New static global.
1947 (clear_pc_function_cache): Clear cache_pc_function_block.
1948 (find_pc_partial_function): Move comment to symtab.h. Add
1949 support for non-contiguous blocks.
1950 * cli/cli-cmds.c (block.h): Include.
1951 (print_disassembly): Handle printing of non-contiguous blocks.
1952 (disassemble_current_function): Likewise.
1953 (disassemble_command): Likewise.
1954
1955 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
1956 BLOCK_START.
1957 * blockframe.c (get_pc_function_start): Likewise.
1958 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
1959 (gcc_symbol_address): Likewise.
1960 * compile/compile-object-run.c (compile_object_run): Likewise.
1961 * compile/compile.c (get_expr_block_and_pc): Likewise.
1962 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
1963 (func_addr_to_tail_call_list): Likewise.
1964 * findvar.c (default_read_var_value): Likewise.
1965 * inline-frame.c (inline_frame_this_id): Likewise.
1966 (skip-inline_frames): Likewise.
1967 * infcmd.c (until_next_command): Likewise.
1968 * linespec.c (convert_linespec_to_sals): Likewise.
1969 * parse.c (parse_exp_in_context_1): Likewise.
1970 * printcmd.c (build_address_symbolic): likewise.
1971 (info_address_command): Likewise.
1972 symtab.c (find_function_start_sal): Likewise.
1973 (skip_prologue_sal): Likewise.
1974 (find_function_alias_target): Likewise.
1975 (find_gnu_ifunc): Likewise.
1976 * stack.c (find_frame_funname): Likewise.
1977 * symtab.c (fixup_symbol_section): Likewise.
1978 (find_function_start_sal): Likewise.
1979 (skip_prologue_sal): Likewsie.
1980 (find_function_alias_target): Likewise.
1981 (find_gnu_ifunc): Likewise.
1982 * tracepoint.c (info_scope_command): Likewise.
1983 * value.c (value_fn_field): Likewise.
1984
1985 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
1986 in place of find_pc_partial_function.
1987 * blockframe.c (find_function_entry_range_from_pc): New function.
1988 * symtab.h (find_function_entry_range_from_pc): Declare and document.
1989 * objfiles.c (objfile_relocate1): Relocate start and end addresses
1990 for each range in a block.
1991
1992
1993 2018-08-23 Xavier Roirand <roirand@adacore.com>
1994
1995 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
1996 incrementation.
1997
1998 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
1999
2000 * solib-svr4.c (read_program_headers_from_bfd): Return
2001 gdb::optional<gdb::byte_vector>.
2002 (svr4_exec_displacement): Adjust.
2003
2004 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2005
2006 * solib-svr4.c (read_program_header): Return
2007 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
2008 (find_program_interpreter): Return
2009 gdb::optional<gdb::byte_vector>.
2010 (scan_dyntag_auxv): Adjust.
2011 (enable_break): Adjust.
2012 (svr4_exec_displacement): Adjust.
2013
2014 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2015
2016 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
2017 * inf-child.c (inf_child_target::terminal_save_inferior): New.
2018
2019 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2020
2021 * guile/scm-string.c (gdbscm_scm_from_printf): Use
2022 string_vprintf.
2023 * guile/scm-utils.c (gdbscm_printf): Likewise.
2024 * serial.c (serial_printf): Likewise.
2025 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
2026
2027 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
2028
2029 * stack.c (print_frame): Print frame architecture when printing on
2030 an MI output.
2031 * NEWS: Mention new "arch" attribute in frame output.
2032
2033 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2034
2035 * arch/aarch64.h (aarch64_regnum): Update comment.
2036
2037 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2038
2039 * NEWS: Add SVE to 8.2 section.
2040
2041 2018-08-21 Pedro Alves <palves@redhat.com>
2042
2043 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2044 out from gdbscm_parse_function_args.
2045 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2046 gdbscm_parse_function_args_1.
2047
2048 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2049
2050 PR gdb/17816
2051 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2052 operator.
2053
2054 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2055
2056 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2057
2058 2018-08-19 Michael Spang <spang@google.com>
2059
2060 PR gdb/11786
2061 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2062 for PT_TLS segments.
2063
2064 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2065
2066 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2067 dwarf_variable_value.
2068 * dwarf2-frame.c (class dwarf_expr_executor):
2069 Add override for dwarf_variable_value.
2070 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2071 (class symbol_needs_eval_context): Likewise.
2072 (indirect_synthetic_pointer): Add forward declaration.
2073 (sect_variable_value): New function.
2074 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
2075 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
2076 for DW_OP_GNU_variable_value.
2077
2078 2018-08-16 Tom Tromey <tom@tromey.com>
2079
2080 * top.c (read_command_file): Update.
2081 (command_line_input): Remove "repeat" argument.
2082 * ada-lang.c (get_selections): Update.
2083 * linespec.c (decode_line_2): Update.
2084 * defs.h (command_line_input): Remove argument.
2085 * cli/cli-script.c (read_next_line): Update.
2086 * python/py-gdb-readline.c: Update.
2087
2088 2018-08-17 Tom Tromey <tom@tromey.com>
2089
2090 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
2091 command_line_input.
2092
2093 2018-08-15 Tom Tromey <tom@tromey.com>
2094
2095 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
2096
2097 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
2098
2099 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
2100 If used, use find_pc_partial_function to find address range
2101 to disassemble.
2102 * mi/mi-main.c (mi_cmd_list_features): Report
2103 "data-disassemble-a-option" feature.
2104 * NEWS: Mention new -data-disassemble option -a.
2105
2106 2018-08-13 Tom Tromey <tom@tromey.com>
2107
2108 * common/common-defs.h (_FORTIFY_SOURCE): Define.
2109
2110 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2111
2112 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
2113 (aarch64_linux_collect_sve_regset): Likewise.
2114 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
2115 * regcache.h (regcache_map_entry_size): New function.
2116
2117 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2118
2119 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
2120 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
2121 (SVE_HEADER_VL_LENGTH): Likewise.
2122 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
2123 (SVE_HEADER_FLAGS_LENGTH): Likewise.
2124 (SVE_HEADER_RESERVED_LENGTH): Likewise.
2125 (SVE_HEADER_SIZE_OFFSET): Likewise.
2126 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
2127 (SVE_HEADER_VL_OFFSET): Likewise.
2128 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
2129 (SVE_HEADER_FLAGS_OFFSET): Likewise.
2130 (SVE_HEADER_RESERVED_OFFSET): Likewise.
2131 (SVE_HEADER_SIZE): Likewise.
2132 (aarch64_linux_core_read_vq): Add function.
2133 (aarch64_linux_core_read_description): Check for SVE section.
2134
2135 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2136
2137 * aarch64-fbsd-tdep.c
2138 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
2139 collect_size.
2140 * aarch64-linux-tdep.c
2141 (aarch64_linux_iterate_over_regset_sections): Likewise.
2142 * alpha-linux-tdep.c
2143 (alpha_linux_iterate_over_regset_sections):
2144 * alpha-nbsd-tdep.c
2145 (alphanbsd_iterate_over_regset_sections): Likewise.
2146 * amd64-fbsd-tdep.c
2147 (amd64fbsd_iterate_over_regset_sections): Likewise.
2148 * amd64-linux-tdep.c
2149 (amd64_linux_iterate_over_regset_sections): Likewise.
2150 * arm-bsd-tdep.c
2151 (armbsd_iterate_over_regset_sections): Likewise.
2152 * arm-fbsd-tdep.c
2153 (arm_fbsd_iterate_over_regset_sections): Likewise.
2154 * arm-linux-tdep.c
2155 (arm_linux_iterate_over_regset_sections): Likewise.
2156 * corelow.c (get_core_registers_cb): Likewise.
2157 (core_target::fetch_registers): Likewise.
2158 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
2159 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
2160 * gdbarch.h (void): Regenerate.
2161 * gdbarch.sh: Add supply_size and collect_size.
2162 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
2163 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
2164 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
2165 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
2166 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
2167 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
2168 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
2169 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
2170 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
2171 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
2172 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
2173 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
2174 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
2175 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
2176 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
2177 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
2178 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
2179 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
2180 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
2181 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
2182 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
2183 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
2184 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
2185 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
2186 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
2187 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
2188 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
2189 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
2190 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
2191 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
2192
2193 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
2194
2195 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
2196 with string_printf.
2197
2198 2018-08-10 Keith Seitz <keiths@redhat.com>
2199
2200 * compile/compile-c-support.c (add_code_header, add_code_footer):
2201 Move into policy class.
2202 (c_push_user_expression, pop_user_expression_nop)
2203 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
2204 (compile_program): New host class.
2205 (c_compile_program): New typedef.
2206 (c_compute_porgram): Use c_compile_program.
2207
2208 2018-08-10 Keith Seitz <keiths@redhat.com>
2209
2210 * compile/compile-internal.h (compile_instance::~compile_instance):
2211 Remove calls to htab_delete.
2212 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
2213 * compile.c (compile_instance::compile_instance): Initialize
2214 htab unique pointers.
2215 (compile_instance::get_cached_type, compile_instance::insert_type)
2216 (compile_instance::error_symbol_once): Update for unique_ptr.
2217
2218 2018-08-10 Keith Seitz <keiths@redhat.com>
2219
2220 * compile/compile-c-symbols.c (struct symbol_error)
2221 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2222 (compile_instance::insert_symbol_error)
2223 (compile_instance::error_symbol_once): Move to ...
2224 * compile/compile.c: ... here.
2225
2226 2018-08-10 Keith Seitz <keiths@redhat.com>
2227
2228 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2229 instead of `new_compile_instance'.
2230 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2231 Update description.
2232 If the symbol error map is not initialized, create it.
2233 (generate_c_for_for_one_symbol): Do not check/initialize
2234 the symbol error map.
2235 * compile/compile-c-types.c (compile_c_instance): Make a class.
2236 Update all callers.
2237 (compile_instance::compile_instance): Initialize the type cache.
2238 (get_cached_type): New function.
2239 (insert_type): Update description.
2240 (compile_c_instance::m_default_cflags): Define.
2241 (convert_type): Update description. Use get_cached_type.
2242 (delete_instance): Moved to destructor.
2243 (new_compile_instance): Moved to constructor.
2244 * compile/compile-c.h (compile_c_instance): Make class inheriting
2245 from compile_instance.
2246 <base>: Remove field.
2247 <type_map, symbol_err_map>: Move to base class.
2248 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2249 * compile/compile-internal.h (compile_instance): Make class.
2250 <type_map_t, symbol_err_map_t>: Define.
2251 <fe>: Rename to `m_gcc_fe'.
2252 <scope, block, gcc_target_options>: Add `m_' prefix.
2253 <m_type_map, m_symbol_err_map>: New fields, moved from
2254 compile_c_instance.
2255 <destroy>: Remove.
2256 (convert_type, new_compile_instance): Remove.
2257 * compile/compile.c (cleanup_compile_instance): Remove.
2258 (compile_to_object): Use unique_ptr to eliminate cleanups.
2259 (compile_instance::set_print_callback, compile_instance::version)
2260 (compile_instance::set_verbose)
2261 (compile_instance::set_driver_filename)
2262 (compile_instance::set_triplet_regexp)
2263 (compile_instance::set_arguments)
2264 (compile_instance::set_source_file)
2265 (compile_instance::compile): Define.
2266
2267 2018-08-10 Keith Seitz <keiths@redhat.com>
2268
2269 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2270 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2271 gcc-c-fe.def to define C plugin.
2272 (delete_instance): Delete `c_plugin'.
2273 (new_compile_instance): Initialize `c_plugin'.
2274 * compile/compile-c.h: Include gcc_c_plugin.h.
2275 (struct compile_c_instance) <c_plugin>: New member.
2276 * gcc-c-plugin.h: New file.
2277 Update all callers with API change.
2278
2279 2018-08-10 Keith Seitz <keiths@redhat.com>
2280
2281 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2282 (HFILES_NO_SRCDIR): ... to here.
2283 Add compile-internal.h and compile-c.h.
2284 * compile/compile-c-support.c: Include compile-c.h.
2285 * compile/compile-c-symbols.c: Include compile-c.h.
2286 (generate_c_for_variable_locations): Update comment.
2287 * compile/compile-c-types.c: Include compile-c.h.
2288 * compile/compile-c.h: New file -- moved C language declarations
2289 from other files here.
2290 * compile/compile-internal.h: Do not include hashtab.h or
2291 common/enum-flags.h.
2292 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2293 (gcc_convert_symbol, gcc_symbol_address)
2294 (generate_c_for_variable_locations, c_get_mode_for_size)
2295 (c_get_range_decl_name): Definitions moved to compile-c.h.
2296 * compile/compile-loc2c.c: Include compile-c.h.
2297
2298 2018-08-10 Keith Seitz <keiths@redhat.com>
2299
2300 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2301 (c_symbol_substitution_name): ... this.
2302 Update all callers.
2303
2304 2018-08-10 Keith Seitz <keiths@redhat.com>
2305
2306 * compile/compile-c-support.c (c_compute_program): Use
2307 unique_xmalloc_ptr to eliminate cleanup.
2308 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2309 Return a unique_xmalloc_ptr and eliminate cleanup.
2310 * compile/compile-internal.h (generate_c_for_variable_locations):
2311 Return unique_xmalloc_ptr and update description.
2312
2313 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2314
2315 * corelow.c (core_target::get_core_register_section): Rename
2316 min_size to section_min_size.
2317
2318 2018-08-09 Jim Wilson <jimw@sifive.com>
2319
2320 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2321 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2322 * NEWS: Mention new GNU/Linux RISC-V target.
2323 * configure.host: Add riscv*-*-linux*.
2324 * configure.nat: Add riscv*.
2325 * configure.tgt: Add riscv*-*-linux*.
2326 * riscv-linux-nat.c: New file.
2327 * riscv-linux-tdep.c: New file.
2328
2329 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2330
2331 * infrun.c (resume): Make static, add forward declaration.
2332 (proceed): Update header comment.
2333 * infrun.h (resume): Delete declaration.
2334
2335 2018-08-09 Tom Tromey <tom@tromey.com>
2336
2337 * riscv-tdep.h: Minor formatting fixes.
2338
2339 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2340
2341 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2342 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2343 (test_mkdir_recursive): Likewise.
2344 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2345
2346 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2347
2348 * valarith.c (value_subscripted_rvalue): If an array is not in
2349 memory, and we don't know the upper bound, then we can't know that
2350 the requested element exists or not.
2351
2352 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2353
2354 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2355 (target_options_to_string): Add comment.
2356
2357 2018-08-08 Tom Tromey <tom@tromey.com>
2358
2359 * unittests/scoped_mmap-selftests.c: Check result of "write".
2360
2361 2018-08-08 Jim Wilson <jimw@sifive.com>
2362
2363 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2364 (decode_register_index_short): New.
2365 (decode_j_type_insn, decode_cj_type_insn): New.
2366 (decode_b_type_insn, decode_cb_type_insn): New.
2367 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2368 local xlen. Check xlen when decoding ambiguous compressed insns. In
2369 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2370 is_c_sw_insn instead of is_sw_insn.
2371 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2372 (riscv_software_single_step): New.
2373 * riscv-tdep.h (riscv_software_single_step): Declare.
2374
2375 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2376 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2377
2378 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2379
2380 PR gdb/18050:
2381 * target.c (dispose_inferior): Don't dispose of inferiors that are
2382 already killed.
2383
2384 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2385
2386 * remote.c (remote_target::download_tracepoint): Change char* to
2387 const char*.
2388
2389 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2390
2391 * target.h (target_options_to_string): Return an std::string.
2392 * target.c (str_comma_list_concat_elem): Return void, use
2393 std::string.
2394 (do_option): Likewise.
2395 (target_options_to_string): Return an std::string.
2396 * linux-nat.c (linux_nat_target::wait): Adjust.
2397 * target-debug.h (target_debug_print_options): Adjust.
2398
2399 2018-08-07 Tom Tromey <tom@tromey.com>
2400
2401 * Makefile.in (CPPFLAGS): New variable.
2402 (INTERNAL_CPPFLAGS): Use it.
2403
2404 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2405
2406 * NEWS: Mention the index cache.
2407
2408 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2409
2410 * common/pathstuff.h (get_standard_cache_dir): New.
2411 * common/pathstuff.c (get_standard_cache_dir): New.
2412 * build-id.h (build_id_to_string): New.
2413 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2414 DEBUG_STR_SUFFIX): Move to here.
2415 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2416 DEBUG_STR_SUFFIX): Move from there.
2417 (write_psymtabs_to_index): Make non-static, add basename
2418 parameter. Write to temporary files, rename when done.
2419 (save_gdb_index_command): Adjust call to
2420 write_psymtabs_to_index.
2421 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2422 field.
2423 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2424 (get_gdb_index_contents_from_cache): New.
2425 (get_gdb_index_contents_from_cache_dwz): New.
2426 (dwarf2_initialize_objfile): Read index from cache.
2427 (dwarf2_build_psymtabs): Save to index.
2428 * dwarf-index-cache.h: New file.
2429 * dwarf-index-cache.c: New file.
2430 * dwarf-index-write.h: New file.
2431
2432 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2433
2434 * gnulib/aclocal.m4: Re-generate.
2435 * gnulib/config.in: Re-generate.
2436 * gnulib/configure: Re-generate.
2437 * gnulib/import/Makefile.am: Re-generate.
2438 * gnulib/import/Makefile.in: Re-generate.
2439 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2440 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2441 * gnulib/import/m4/mkdir.m4: New file.
2442 * gnulib/import/mkdir.c: New file.
2443 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2444 module.
2445
2446 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2447
2448 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2449 * common/scoped_mmap.c: New file.
2450 * common/scoped_mmap.h (destroy): New method.
2451 (~scoped_mmap, reset): Use destroy.
2452 (scoped_mmap): New move constructor.
2453 (mmap_file): New declaration.
2454 * unittests/scoped_mmap-selftests.c (test_normal,
2455 test_invalid_filename, run_tests): New functions.
2456 (_initialize_scoped_mmap_selftests): Register selftest.
2457
2458 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2459
2460 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2461 (read_gdb_index_from_buffer): ... this. Remove section
2462 parameter, add buffer parameter.
2463 (get_gdb_index_contents_ftype,
2464 get_gdb_index_contents_dwz_ftype): New typedefs.
2465 (dwarf2_read_gdb_index): Add callback parameters to get the
2466 index contents.
2467 (get_gdb_index_contents_from_section): New.
2468 (dwarf2_initialize_objfile): Update call to
2469 dwarf2_read_gdb_index.
2470
2471 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2472
2473 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2474 (gdb_open_cloexec): Likewise.
2475 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2476 (commandline_from_pid): Likewise.
2477 (linux_xfer_osdata_threads): Likewise.
2478 (linux_xfer_osdata_fds): Likewise.
2479 * ada-lang.c (is_package_name): Likewise.
2480 * auxv.c (procfs_xfer_auxv): Likewise.
2481 * breakpoint.c (print_one_breakpoint_location): Use
2482 uiout::field_fmt.
2483 (print_one_catch_solib): Use string_printf.
2484 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2485 (add_pe_forwarded_sym): Likewise.
2486 * dwarf2read.c (create_type_unit_group): Likewise.
2487 (build_error_marker_type): Likewise.
2488 * infcall.c (get_function_name): Likewise.
2489 * valprint.c (print_converted_chars_to_obstack): Likewise.
2490 * xtensa-tdep.c (xtensa_register_type): Likewise.
2491
2492 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2493
2494 * remote.c (remote_target::download_tracepoint): Fix format
2495 string errors.
2496
2497 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2498
2499 * tracefile.c: Include common/byte-vector.h.
2500 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2501 with trace_regblock_size if needed. Update uses of buf.
2502
2503 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2504
2505 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2506 std::vector<unsigned char>.
2507 * tracepoint.c (collection_list::collection_list): Remove
2508 m_regs_mask initializer from initializer list. Resize
2509 m_regs_mask using the largest remote register number.
2510 (collection_list::add_remote_register): Remove size check on
2511 m_regs_mask. Use at to access element.
2512 (collection_list::stringify): Change type of temp_buf to
2513 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2514 stringify the register mask. Use pack_hex_byte for the register
2515 mask.
2516
2517 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2518
2519 * tracepoint.h (class collection_list) <add_register>: Remove.
2520 <add_remote_register, add_ax_registers, add_local_register>:
2521 Declare.
2522 <add_memrange>: Add scope parameter.
2523 * tracepoint.c (encode_actions_1): Likewise.
2524 (collection_list::add_register): Rename to ...
2525 (collection_list::add_remote_register): ... this. Update
2526 comment.
2527 (collection_list::add_ax_registers, add_local_register): New
2528 methods.
2529 (collection_list::add_memrange): Add scope parameter. Call
2530 add_local_register instead of add_register.
2531 (finalize_tracepoint_aexpr): New function.
2532 (collection_list::collect_symbol): Update calls to add_memrange.
2533 Call add_local_register instead of add_register. Call
2534 add_ax_registers. Call finalize_tracepoint_aexpr.
2535 (encode_actions_1): Get remote regnos for $reg action. Call
2536 add_remote_register, add_ax_registers, and add_local_register.
2537 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2538 (validate_actionline): Call finalize_tracepoint_aexpr.
2539
2540 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2541
2542 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2543 Replace array buf with gdb::char_vector buf, of size
2544 get_remote_packet_size (). Replace references to buf and
2545 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2546 and xsnprintf with snprintf. Raise errors if the buffer is too
2547 small.
2548
2549 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2550
2551 * remote.c (remote_target::download_tracepoint): Fix the has_more
2552 predicate in the QTDP action list iteration.
2553
2554 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2555
2556 * remote.c (remote_target::download_tracepoint): Fix indentation
2557 in for block.
2558
2559 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2560
2561 * proc-api.c (_initialize_proc_api): Remove c, unused.
2562 * procfs.c (procfs_init_inferior): Remove signals, unused.
2563 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2564 unused.
2565
2566 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2567 Andrew Burgess <andrew.burgess@embecosm.com>
2568
2569 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2570 'W_STOPCODE (0)' as this could be ambiguous.
2571
2572 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2573
2574 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2575 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2576 "ai_socktype").
2577
2578 2018-08-02 Tom Tromey <tom@tromey.com>
2579
2580 PR symtab/16842.
2581 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2582 symbols.
2583 (process_structure_scope): Likewise.
2584
2585 2018-08-02 Xavier Roirand <roirand@adacore.com>
2586
2587 PR gdb/22629:
2588 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2589 kill inferior.
2590
2591 2018-08-02 Tom Tromey <tom@tromey.com>
2592
2593 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2594 (darwin_suspend_inferior, darwin_resume_inferior)
2595 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2596 (darwin_check_new_threads): Check result of get_darwin_inferior.
2597
2598 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2599
2600 GDB 8.1.1 released.
2601
2602 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2603
2604 * varobj.c (varobj_get_path_expr_parent): Report an error if
2605 parent is a dynamic varobj.
2606
2607 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2608
2609 * gnulib/aclocal.m4: Re-generate.
2610 * gnulib/config.in: Re-generate.
2611 * gnulib/configure: Re-generate.
2612 * gnulib/import/Makefile.in: Re-generate.
2613 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2614 * gnulib/import/m4/onceonly.m4: Re-generate.
2615
2616 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2617
2618 * target-descriptions.c (struct xml_test_tdesc): New.
2619 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2620 (record_xml_tdesc): Update.
2621 (maintenance_check_xml_descriptions): Update.
2622 * target-descriptions.h (record_xml_tdesc): Update comment.
2623
2624 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2625
2626 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2627 checking array bounds are defined.
2628
2629 2018-07-30 Tom Tromey <tom@tromey.com>
2630
2631 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2632 irreflexivity violation.
2633
2634 2018-07-30 Tom Tromey <tom@tromey.com>
2635
2636 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2637 * value.c (unpack_long): Remove lint code.
2638 * valops.c (value_ind): Remove lint code.
2639 * valarith.c (value_x_binop, value_x_unop, value_equal)
2640 (value_pos): Remove lint code.
2641
2642 2018-07-28 Tom de Vries <tdevries@suse.de>
2643
2644 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2645 with undefined upper bound as <optimized out>.
2646
2647 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2648
2649 * gcore.in: Rename variable "name" to "prefix". Expand
2650 "usage" text.
2651
2652 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2653
2654 * windows-nat.c (windows_nat_target::create_inferior): Update to
2655 call close() in global namespace.
2656
2657 2018-07-26 Tom Tromey <tom@tromey.com>
2658
2659 * dwarf-index-write.c (add_address_entry): Don't add objfile
2660 offsets.
2661 * dbxread.c (find_stab_function): Rename from
2662 find_stab_function_addr. Return a bound_minimal_symbol.
2663 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2664 Don't add objfile offsets.
2665 (end_psymtab): Use raw_text_low, raw_text_high,
2666 MSYMBOL_VALUE_RAW_ADDRESS.
2667 (read_ofile_symtab): Update.
2668 (process_one_symbol): Update.
2669 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2670 offsets.
2671 (dw2_relocate): Remove.
2672 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2673 searching addrmap.
2674 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2675 Update.
2676 (process_psymtab_comp_unit_reader, add_partial_symbol)
2677 (add_partial_subprogram, dwarf2_ranges_read): Update.
2678 (load_partial_dies): Update.
2679 (add_address_entry): Don't add objfile offsets.
2680 (dwarf2_build_include_psymtabs): Update.
2681 (create_addrmap_from_aranges): Don't add objfile offsets.
2682 (dw2_find_pc_sect_compunit_symtab): Update.
2683 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2684 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2685 Update.
2686 (parse_partial_symbols): Don't add objfile offsets. Use
2687 raw_text_low, raw_text_high. Update.
2688 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2689 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2690 or call 'relocate' quick function. Clear psymbol_map.
2691 * psympriv.h (struct partial_symbol) <address>: Add section
2692 offset.
2693 <set_unrelocated_address>: Rename from set_address.
2694 <raw_text_low, raw_text_high>: New methods.
2695 <text_low, text_high>: Add objfile parameter.
2696 (add_psymbol_to_bcache): Add 'section' parameter. Call
2697 set_unrelocated_address.
2698 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2699 (find_pc_psymbol): Update.
2700 (fixup_psymbol_section, relocate_psymtabs): Remove.
2701 (dump_psymtab, psym_functions): Update.
2702 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2703 parameter.
2704 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2705 (start_psymtab_common): Update.
2706 * symfile-debug.c (debug_qf_relocate): Remove.
2707 (debug_sym_quick_functions): Update.
2708 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2709 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2710 Update.
2711
2712 2018-07-26 Tom Tromey <tromey@redhat.com>
2713
2714 * dbxread.c (end_psymtab): Use text_high_valid and
2715 text_low_valid.
2716 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2717 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2718 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2719 Update comment.
2720 <text_low_valid, text_high_valid>: New fields.
2721 <set_text_low, set_text_high>: Update.
2722 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2723
2724 2018-07-26 Tom Tromey <tom@tromey.com>
2725
2726 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2727 Update.
2728 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2729 textlow and texthigh fields.
2730 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2731 Update.
2732 * mdebugread.c (parse_lines, parse_partial_symbols)
2733 (psymtab_to_symtab_1): Update.
2734 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2735 Rename fields. Update comment. Now private.
2736 <text_low, text_high, set_text_low, set_text_high>: New methods.
2737 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2738 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2739 (start_psymtab_common, maintenance_info_psymtabs)
2740 (maintenance_check_psymtabs): Update.
2741 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2742 texthigh fields.
2743 (scan_xcoff_symtab): Update.
2744
2745 2018-07-26 Tom Tromey <tromey@redhat.com>
2746
2747 * psympriv.h (struct partial_symbol) <unrelocated_address,
2748 address, set_address>: New methods.
2749 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2750 (fixup_psymbol_section, relocate_psymtabs): Update.
2751 (print_partial_symbols): Add 'objfile' parameter. Update.
2752 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2753 Update.
2754
2755 2018-07-26 Tom Tromey <tom@tromey.com>
2756
2757 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2758 (debug_names::write_psymbols): Update.
2759 * psympriv.h (struct partial_symbol): Derive from
2760 general_symbol_info.
2761 <obj_section>: New method.
2762 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2763 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2764 (find_pc_sect_psymbol, fixup_psymbol_section)
2765 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2766 (print_partial_symbols, recursively_search_psymtabs)
2767 (compare_psymbols, psymbol_hash, psymbol_compare)
2768 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2769 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2770
2771 2018-07-26 Tom Tromey <tromey@redhat.com>
2772
2773 * dbxread.c (end_psymtab): Remove dead code.
2774
2775 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2776
2777 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2778 DWARF unwinders are disabled.
2779 * dwarf2-frame.c: Add dwarf2read.h include.
2780 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2781 disabled.
2782 (dwarf2_frame_unwinders_enabled_p): Define.
2783 (show_dwarf_unwinders_enabled_p): New function.
2784 (_initialize_dwarf2_frame): Register switch to control DWARF
2785 unwinder use.
2786 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2787 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2788 (show_dwarf_cmdlist): Remove static keyword.
2789 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2790 (show_dwarf_cmdlist): Declare.
2791 * NEWS: Document new feature.
2792
2793 2018-07-26 Tom de Vries <tdevries@suse.de>
2794
2795 PR breakpoints/23366
2796 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2797
2798 2018-07-26 Tom de Vries <tdevries@suse.de>
2799
2800 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2801 DW_AT_count can't be translated to a dynamic prop.
2802
2803 2018-07-25 Tom de Vries <tdevries@suse.de>
2804
2805 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2806 try/catch.
2807
2808 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2809
2810 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2811
2812 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2813
2814 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2815
2816 2018-07-24 Keith Seitz <keiths@redhat.comt
2817
2818 PR symtab/23010
2819 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2820 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2821 instead of add_symbol_to_list.
2822 (read_file_scope): Call prepare_one_comp_unit before reading
2823 any other DIEs.
2824
2825 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2826
2827 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2828
2829 2018-07-24 Tom Tromey <tom@tromey.com>
2830
2831 * utils.c (malloc, realloc, free): Don't declare.
2832 * configure, config.in: Rebuild.
2833 * configure.ac: Don't check for declarations of free, malloc, or
2834 realloc.
2835
2836 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2837
2838 * aarch64-linux-nat.c
2839 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2840 variable.
2841 * arm-linux-nat.c (fetch_regs): Likewise.
2842 (store_regs): Likewise.
2843 (fetch_vfp_regs): Likewise.
2844 (store_vfp_regs): Likewise.
2845 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2846 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2847 (arm_linux_nat_target::insert_watchpoint): Likewise.
2848 (arm_linux_nat_target::remove_watchpoint): Likewise.
2849 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2850 Likewise.
2851 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2852 Likewise.
2853 * ppc-linux-nat.c (fetch_register): Likewise.
2854 (fetch_all_gp_regs): Likewise.
2855 (fetch_ppc_registers): Likewise.
2856 (store_all_gp_regs): Likewise.
2857 (store_ppc_registers): Likewise.
2858 (hwdebug_insert_point): Likewise.
2859 (can_use_watchpoint_cond_accel): Likewise.
2860 * remote-sim.c (gdb_os_write_stdout): Likewise.
2861
2862 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2863 Tom Tromey <tom@tromey.com>
2864
2865 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2866 test for it.
2867 * configure: Rebuild.
2868
2869 2018-07-22 Tom Tromey <tom@tromey.com>
2870
2871 * regformats/regdat.sh: Define xmltarget_${name} inside
2872 #ifndef IN_PROCESS_AGENT.
2873
2874 2018-07-22 Tom Tromey <tom@tromey.com>
2875
2876 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2877
2878 2018-07-22 Tom Tromey <tom@tromey.com>
2879
2880 * symfile.c (reread_symbols): Notify iter, not objfile.
2881
2882 2018-07-22 Tom Tromey <tom@tromey.com>
2883
2884 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2885 Use arch_ops.
2886 (ravenscar_thread_target::prepare_to_store): Likewise.
2887
2888 2018-07-22 Tom Tromey <tom@tromey.com>
2889
2890 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2891 unused variable. Call value_fetch_lazy when needed.
2892 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2893 Remove unused variable. Call value_fetch_lazy when needed.
2894
2895 2018-07-22 Tom Tromey <tom@tromey.com>
2896
2897 * m32c-tdep.c (mark_dma): Return void.
2898 (make_regs): Remove unused declarations.
2899
2900 2018-07-22 Tom Tromey <tom@tromey.com>
2901
2902 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2903 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2904 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2905 bkscm_get_valid_block_smob_arg_unsafe for effect.
2906
2907 2018-07-22 Tom Tromey <tom@tromey.com>
2908
2909 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2910 value_type.
2911
2912 2018-07-22 Tom Tromey <tom@tromey.com>
2913
2914 * windows-nat.c (saved_context): Conditionally define.
2915 * remote.c (remote_target::remote_btrace_maybe_reopen):
2916 Conditionally declare "warned".
2917 * inflow.c (sigquit_ours): Conditionally define.
2918 (new_tty): Move "tty" declaration inside #if.
2919 * guile/guile.c (guile_datadir): Conditionally define.
2920 * charset.c (set_be_le_names): Move some declarations inside #if.
2921 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2922 #if.
2923 (parse_xml_btrace_conf): Likewise.
2924
2925 2018-07-22 Tom Tromey <tom@tromey.com>
2926
2927 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2928
2929 2018-07-22 Tom Tromey <tom@tromey.com>
2930
2931 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2932 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2933 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2934 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2935 * stack.c (frame_apply_level_command): Remove unused variable.
2936 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2937 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2938 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2939 unused variable.
2940 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
2941 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
2942 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
2943 variable.
2944 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
2945 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
2946 variable.
2947 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
2948 Remove unused variable.
2949 * cli/cli-script.c (recurse_read_control_structure): Remove unused
2950 variable.
2951 * common/tdesc.c (print_xml_feature::visit): Remove unused
2952 variable.
2953 * compile/compile-object-load.c (store_regs): Remove unused
2954 variables.
2955 * complaints.c (clear_complaints): Remove unused variable.
2956 * corelow.c (core_target_open): Remove unused variable.
2957 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
2958 variable.
2959 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
2960 variable.
2961 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
2962 variable.
2963 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
2964 variable.
2965 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
2966 variable.
2967 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
2968 variable.
2969 * ia64-tdep.c (examine_prologue): Remove unused variable.
2970 * infcall.c (run_inferior_call): Remove unused variable.
2971 * inferior.c (exit_inferior): Remove unused variable.
2972 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
2973 * linespec.c (decode_line_2): Remove unused variable.
2974 * linux-nat.c (super_close): Remove.
2975 * linux-tdep.c (linux_info_proc): Remove unused variable.
2976 * mi/mi-main.c (mi_execute_command): Remove unused variable.
2977 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
2978 Remove unused variable.
2979 * parse.c (find_minsym_type_and_address): Remove unused variable.
2980 * printcmd.c (info_symbol_command, printf_floating): Remove unused
2981 variable.
2982 * python/py-breakpoint.c (bppy_set_commands): Remove unused
2983 variable.
2984 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
2985 variables.
2986 * record-btrace.c (record_btrace_target::store_registers): Remove
2987 unused variable.
2988 (cmd_show_record_btrace_cpu): Remove unused variable.
2989 * riscv-tdep.c (riscv_register_reggroup_p)
2990 (riscv_push_dummy_call, riscv_return_value): Remove unused
2991 variable.
2992 * rust-exp.y (literal): Remove unused variable.
2993 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
2994 unused variable.
2995 <STRUCTOP_ANONYMOUS>: Likewise.
2996 * s390-linux-tdep.c (s390_linux_init_abi_31)
2997 (s390_linux_init_abi_64): Remove unused variable.
2998 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
2999 (file_select_thread, net_windows_open, _initialize_ser_windows):
3000 Remove unused variables.
3001 * symtab.c (find_pc_sect_line): Remove unused variable.
3002 * target-memory.c (compute_garbled_blocks): Remove unused
3003 variable.
3004 (target_write_memory_blocks): Remove unused variable.
3005 * target.c (target_stack::unpush): Remove unused variables.
3006 * tracepoint.c (start_tracing, all_tracepoint_actions)
3007 (merge_uploaded_trace_state_variables)
3008 (print_one_static_tracepoint_marker): Remove unused variable.
3009 * unittests/basic_string_view/element_access/char/1.cc (test01):
3010 Remove unused variable.
3011 * windows-nat.c (windows_continue, windows_add_all_dlls)
3012 (do_initial_windows_stuff, windows_nat_target::create_inferior):
3013 Remove unused variables.
3014
3015 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
3016
3017 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
3018 attr_profile in HAVE_ELF.
3019 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
3020 HAVE_ELF.
3021
3022 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
3023
3024 * frame.c (frame_register_unwind): Change parameter name.
3025 (frame_unwind_register): Likewise.
3026 (frame_unwind_register_value): Likewise.
3027 (frame_unwind_register_signed): Likewise.
3028 (frame_unwind_register_unsigned): Likewise.
3029 * frame.h (frame_register_unwind): Likewise.
3030 (frame_unwind_register): Likewise.
3031 (frame_unwind_register_value): Likewise.
3032 (frame_unwind_register_signed): Likewise.
3033 (frame_unwind_register_unsigned): Likewise.
3034 (frame_unwind_arch): Likewise.
3035
3036 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3037
3038 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3039 ISA maintenance.
3040
3041 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3042
3043 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3044 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3045 hand.
3046
3047 2018-07-20 Keith Seitz <keiths@redhat.com>
3048
3049 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3050 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3051 m_compunit_symtab, m_language>: Add "m_" prefix.
3052 Update all uses.
3053 * buildsym.c: Update all uses.
3054
3055 2018-07-20 Tom Tromey <tom@tromey.com>
3056
3057 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3058 * buildsym.h (record_line_ftype): Remove typedef.
3059
3060 2018-07-20 Tom Tromey <tom@tromey.com>
3061
3062 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3063 (end_expandable_symtab): Likewise.
3064 (end_symtab_get_static_block): Likewise.
3065 (end_symtab_from_static_block): Likewise.
3066 * buildsym-legacy.c (augment_type_symtab): Remove.
3067 (end_expandable_symtab): Remove.
3068 (end_symtab_get_static_block): Remove.
3069 (end_symtab_from_static_block): Remove.
3070
3071 2018-07-20 Tom Tromey <tom@tromey.com>
3072
3073 * dwarf2read.c: Include buildsym.h.
3074 (struct dwarf2_cu) <builder>: New method.
3075 (fixup_go_packaging): Update.
3076 (process_full_comp_unit, process_full_type_unit): Update. Don't
3077 use scoped_free_pendings.
3078 (using_directives): Add "cu" parameter, remove "language".
3079 (read_import_statement, setup_type_unit_groups, )
3080 (read_func_scope, read_lexical_block_scope)
3081 (dwarf2_record_block_ranges, read_namespace): Update.
3082 (lnp_state_machine::lnp_state_machine): Add cu parameter.
3083 (lnp_state_machine::handle_end_sequence): Update.
3084 (class lnp_state_machine) <m_cu>: New member.
3085 <m_record_line_callback>: Remove.
3086 <m_currently_recording_lines>: New member.
3087 (lnp_state_machine::handle_set_file): Update.
3088 (noop_record_line): Remove.
3089 (dwarf_record_line_p): Add cu parameter.
3090 (dwarf_record_line_1, dwarf_finish_line): Likewise.
3091 (lnp_state_machine::record_line)
3092 (lnp_state_machine::lnp_state_machine)
3093 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3094 (dwarf_decode_lines): Update.
3095 (dwarf2_start_subfile): Add cu parameter.
3096 (dwarf2_start_symtab, new_symbol): Update.
3097 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
3098 Remove dwarf2_per_objfile parameter.
3099 (dwarf_decode_macros): Update.
3100
3101 2018-07-20 Tom Tromey <tom@tromey.com>
3102
3103 * stabsread.c (define_symbol): Update.
3104 * buildsym-legacy.h (get_buildsym_compunit): Declare.
3105 * dwarf2read.c (new_symbol): Update.
3106 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
3107 * cp-namespace.c: Include buildsym.h.
3108 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
3109 * buildsym-legacy.c (get_buildsym_compunit): New function.
3110
3111 2018-07-20 Tom Tromey <tom@tromey.com>
3112
3113 * xcoffread.c: Include buildsym-legacy.h.
3114 * windows-nat.c: Include buildsym-legacy.h.
3115 * stabsread.c: Include buildsym-legacy.h.
3116 * mdebugread.c: Include buildsym-legacy.h.
3117 * buildsym-legacy.h: New file.
3118 * buildsym-legacy.c: New file, from buildsym.c.
3119 * go32-nat.c: Include buildsym-legacy.h.
3120 * dwarf2read.c: Include buildsym-legacy.h.
3121 * dbxread.c: Include buildsym-legacy.h.
3122 * cp-namespace.c: Include buildsym-legacy.h.
3123 * coffread.c: Include buildsym-legacy.h.
3124 * buildsym.h: Move some contents to buildsym-legacy.h.
3125 * buildsym.c: Include buildsym-legacy.h. Move many functions to
3126 buildsym-legacy.c.
3127 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
3128
3129 2018-07-20 Tom Tromey <tom@tromey.com>
3130
3131 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
3132 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
3133 (buildsym_compunit::buildsym_compunit)
3134 (buildsym_compunit::~buildsym_compunit)
3135 (buildsym_compunit::get_macro_table): Define.
3136
3137 2018-07-20 Tom Tromey <tom@tromey.com>
3138
3139 * buildsym.c (reset_symtab_globals): Remove.
3140 (buildsym_compunit::end_symtab_from_static_block): Update.
3141 (buildsym_compunit::augment_type_symtab): Update.
3142 (end_symtab_from_static_block): Call free_buildsym_compunit.
3143 (augment_type_symtab, end_symtab, end_expandable_symtab):
3144 Likewise.
3145
3146 2018-07-20 Tom Tromey <tom@tromey.com>
3147
3148 * arch-utils.c: Do not include buildsym.h.
3149 * mipsread.c: Do not include buildsym.h.
3150 * machoread.c: Do not include buildsym.h.
3151 * elfread.c: Do not include buildsym.h.
3152
3153 2018-07-20 Tom Tromey <tom@tromey.com>
3154
3155 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
3156 initialization.
3157 (buildsym_compunit): Add new constructor.
3158 (struct buildsym_compunit) <get_last_source_file, finish_block,
3159 record_block_range, start_subfile, patch_subfile_names,
3160 push_subfile, pop_subfile, record_line, get_compunit_symtab,
3161 set_last_source_start_addr, get_last_source_start_addr,
3162 get_local_using_directives, set_local_using_directives,
3163 get_global_using_directives, outermost_context_p,
3164 get_current_context_stack, get_context_stack_depth,
3165 get_current_subfile, get_local_symbols, get_file_symbols,
3166 get_global_symbols, record_debugformat, record_producer,
3167 push_context, pop_context, end_symtab_get_static_block,
3168 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
3169 New public methods.
3170 <record_pending_block, finish_block_internal, make_blockvector,
3171 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
3172 private methods.
3173 Update all users.
3174
3175 2018-05-22 Tom Tromey <tom@tromey.com>
3176
3177 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3178 parameter.
3179 (finish_block_internal): Update.
3180
3181 2018-07-20 Tom Tromey <tom@tromey.com>
3182
3183 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3184 parameter.
3185 (finish_block_internal): Update.
3186
3187 2018-07-20 Tom Tromey <tom@tromey.com>
3188
3189 * buildsym.h (EXTERN): Don't define or undef.
3190 * buildsym.c (EXTERN): Don't define.
3191
3192 2018-07-20 Tom Tromey <tom@tromey.com>
3193
3194 * buildsym.c: Remove TODO comment.
3195
3196 2018-07-20 Tom Tromey <tom@tromey.com>
3197
3198 * coffread.c (coff_symtab_read): Update.
3199 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3200 (xcoff_new_init): Update.
3201 * mipsread.c (mipscoff_new_init): Update.
3202 * mdebugread.c (mdebug_build_psymtabs): Update.
3203 * elfread.c (elf_new_init): Update.
3204 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3205 Update.
3206 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
3207 (coffstab_build_psymtabs, elfstab_build_psymtabs)
3208 (stabsect_build_psymtabs): Update.
3209 * buildsym.h (buildsym_init): Don't declare.
3210 * buildsym.c: Update comment.
3211 (prepare_for_building): Remove.
3212 (start_symtab, restart_symtab): Update.
3213 (reset_symtab_globals): Update comment.
3214 (buildsym_init): Remove.
3215
3216 2018-07-20 Tom Tromey <tom@tromey.com>
3217
3218 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
3219 * stabsread.c (patch_block_stabs, define_symbol, read_type)
3220 (read_enum_type, common_block_start, common_block_end)
3221 (cleanup_undefined_types_1, finish_global_stabs): Update.
3222 * mdebugread.c (psymtab_to_symtab_1): Update.
3223 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3224 (read_lexical_block_scope, new_symbol): Update.
3225 * dbxread.c (process_one_symbol): Update.
3226 * coffread.c (coff_symtab_read, process_coff_symbol)
3227 (coff_read_enum_type): Update.
3228 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3229 declare.
3230 (get_local_symbols, get_file_symbols, get_global_symbols): New
3231 functions.
3232 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3233 m_global_symbols.
3234 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3235 (~scoped_free_pendings): Update.
3236 (finish_block, prepare_for_building, reset_symtab_globals)
3237 (end_symtab_get_static_block, end_symtab_with_blockvector)
3238 (augment_type_symtab, push_context): Update.
3239 (get_local_symbols, get_file_symbols, get_global_symbols): New
3240 functions.
3241 (buildsym_init): Update.
3242
3243 2018-07-20 Tom Tromey <tom@tromey.com>
3244
3245 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3246 (process_full_type_unit): Likewise.
3247 (dwarf2_start_symtab): Set list_in_scope.
3248
3249 2018-07-20 Tom Tromey <tom@tromey.com>
3250
3251 * dwarf2read.c (process_psymtab_comp_unit_reader)
3252 (build_type_psymtabs_reader): Do not set list_in_scope.
3253
3254 2018-07-20 Tom Tromey <tom@tromey.com>
3255
3256 * buildsym.c (free_pendings): Remove.
3257 (add_symbol_to_list, scoped_free_pendings)
3258 (finish_block_internal, buildsym_init): Update.
3259
3260 2018-07-20 Tom Tromey <tom@tromey.com>
3261
3262 * xcoffread.c (read_xcoff_symtab): Update.
3263 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3264 Update.
3265 * dbxread.c (process_one_symbol): Update.
3266 * coffread.c (coff_symtab_read): Update.
3267 * buildsym.h (finish_block): Update.
3268 * buildsym.c (finish_block): Remove "listhead" argument.
3269 (end_symtab_get_static_block): Update.
3270
3271 2018-07-20 Tom Tromey <tom@tromey.com>
3272
3273 * buildsym.h (class scoped_free_pendings): Remove constructor.
3274 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3275 method.
3276 <m_pending_block_obstack, m_pending_blocks>: New members.
3277 (pending_block_obstack, pending_blocks): Remove.
3278 (scoped_free_pendings::scoped_free_pendings): Default.
3279 (~scoped_free_pendings): Update.
3280 (free_pending_blocks): Remove.
3281 (finish_block_internal, record_pending_block, make_blockvector)
3282 (end_symtab_get_static_block, augment_type_symtab, push_context)
3283 (buildsym_init): Update.
3284
3285 2018-07-20 Tom Tromey <tom@tromey.com>
3286
3287 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3288 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3289 members.
3290 (pending_addrmap, pending_addrmap_obstack)
3291 (pending_addrmap_interesting): Remove.
3292 (scoped_free_pendings, record_block_range, make_blockvector)
3293 (prepare_for_building, reset_symtab_globals, buildsym_init):
3294 Update.
3295
3296 2018-07-20 Tom Tromey <tom@tromey.com>
3297
3298 * xcoffread.c (process_linenos): Update.
3299 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3300 * mdebugread.c (psymtab_to_symtab_1): Update.
3301 * dwarf2read.c (setup_type_unit_groups)
3302 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3303 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3304 * dbxread.c (process_one_symbol): Update.
3305 * coffread.c (coff_symtab_read, enter_linenos)
3306 (process_coff_symbol): Update.
3307 * buildsym.h (current_subfile): Don't declare.
3308 (get_current_subfile): Declare.
3309 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3310 member.
3311 (start_subfile, free_buildsym_compunit, push_subfile)
3312 (prepare_for_building, start_symtab): Update.
3313 (get_current_subfile): New function.
3314
3315 2018-07-20 Tom Tromey <tom@tromey.com>
3316
3317 * coffread.c (coff_symtab_read): Update.
3318 * xcoffread.c (read_xcoff_symtab): Update.
3319 * dwarf2read.c (new_symbol): Update.
3320 (read_func_scope, read_lexical_block_scope): Update.
3321 * dbxread.c (process_one_symbol): Update.
3322 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3323 (outermost_context_p): Remove macro.
3324 (outermost_context_p, get_current_context_stack)
3325 (get_context_stack_depth): Declare.
3326 (pop_context): Return struct context_stack.
3327 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3328 member.
3329 (context_stack_size): Remove.
3330 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3331 (prepare_for_building, end_symtab_get_static_block)
3332 (augment_type_symtab, push_context): Update.
3333 (pop_context): Return struct context_stack.
3334 (outermost_context_p, get_current_context_stack)
3335 (get_context_stack_depth): New functions.
3336 (buildsym_init): Update.
3337
3338 2018-07-20 Tom Tromey <tom@tromey.com>
3339
3340 * rust-exp.y: Now a pure parser. Update all rules.
3341 (%union): Move earlier.
3342 (current_parser, work_obstack): Remove globals.
3343 (rust_parser, ~rust_parser): Update.
3344 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3345 lex_character, lex_number, lex_string, lex_identifier,
3346 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3347 convert_name, convert_params_to_expression,
3348 convert_ast_to_expression, ast_basic_type, ast_operation,
3349 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3350 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3351 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3352 ast_array_type, ast_slice_type, ast_reference_type,
3353 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3354 (rust_parse): Update.
3355 (rustyyerror, rustyylex): Add parser parameter.
3356 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3357 (rust_lex_stringish_test, rust_lex_test_sequence)
3358 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3359 (rust_lex_test_push_back, rust_lex_tests): Update.
3360
3361 2018-07-19 Pedro Alves <palves@redhat.com>
3362
3363 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3364 gdb::unique_xmalloc_ptr.
3365 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3366 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3367 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3368 copy-initialization.
3369 * guile/scm-pretty-print.c (ppscm_print_children): Use
3370 gdb::unique_xmalloc_ptr instead of cleanups.
3371 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3372 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3373 gdb::unique_xmalloc_ptr.
3374 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3375 Adjust to use gdb::unique_xmalloc_ptr.
3376 * guile/scm-utils.c (extract_arg): Adjust.
3377 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3378 gdb::unique_xmalloc_ptr instead of a cleanup.
3379
3380 2018-07-19 Tom Tromey <tom@tromey.com>
3381
3382 * utils.c (do_value_free_to_mark)
3383 (make_cleanup_value_free_to_mark): Remove.
3384 * utils.h (make_cleanup_value_free_to_mark): Remove.
3385
3386 2018-07-19 Pedro Alves <palves@redhat.com>
3387
3388 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3389 forwarding reference.
3390
3391 2018-07-18 Pedro Alves <palves@redhat.com>
3392
3393 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3394 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3395 cleanup.
3396
3397 2018-07-18 Pedro Alves <palves@redhat.com>
3398
3399 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3400 exceptions.
3401 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3402 (gdbscm_wrap): New.
3403 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3404 directly instead of a cleanup.
3405 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3406 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3407 (vlscm_binop_gdbthrow): New, factored out from ...
3408 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3409 (vlscm_rich_compare): Use gdbscm_wrap.
3410 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3411 instead of a cleanup.
3412 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3413 cleanup.
3414 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3415 Use xfree directly instead of a cleanup.
3416 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3417 Adjust to use gdbscm_wrap and scoped_value_mark.
3418 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3419 (gdbscm_value_address, gdbscm_value_dereference)
3420 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3421 scoped_value_mark.
3422 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3423 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3424 scoped_value_mark.
3425 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3426 gdbscm_wrap and scoped_value_mark.
3427 (gdbscm_value_to_string): Use xfree directly instead of a
3428 cleanup. Move 'buffer' unique_ptr to TRY scope.
3429 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3430 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3431 scoped_value_mark.
3432 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3433 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3434 scoped_value_mark.
3435 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3436 gdbscm_wrap.
3437
3438 2018-07-18 Tom de Vries <tdevries@suse.de>
3439
3440 * findvar.c (default_read_var_value): Also resolve dynamic type for
3441 LOC_OPTIMIZED_OUT vars.
3442
3443 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3444
3445 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3446 decoding.
3447
3448 2018-07-17 Tom Tromey <tom@tromey.com>
3449
3450 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3451 (compute_enum_list, pascm_set_param_value_x)
3452 (gdbscm_parameter_value): Update.
3453 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3454 (gdbscm_scm_to_host_string): Update.
3455 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3456 Update.
3457 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3458 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3459 * guile/scm-string.c (gdbscm_scm_to_string): Return
3460 unique_xmalloc_ptr.
3461 (gdbscm_scm_to_host_string): Likewise.
3462
3463 2018-07-17 Tom Tromey <tom@tromey.com>
3464
3465 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3466 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3467 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3468 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3469 unique_xmalloc_ptr.
3470
3471 2018-07-17 Tom Tromey <tom@tromey.com>
3472
3473 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3474 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3475 Update.
3476 * guile/scm-cmd.c (cmdscm_function): Update.
3477 * guile/scm-pretty-print.c
3478 (ppscm_print_exception_unless_memory_error): Update.
3479 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3480 Return unique_xmalloc_ptr.
3481
3482 2018-07-17 Tom Tromey <tom@tromey.com>
3483
3484 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3485 Use string_printf.
3486
3487 2018-07-17 Jim Wilson <jimw@sifive.com>
3488
3489 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3490 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3491 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3492 unecessary braces after EF_RISCV_RVC test. Delete call to
3493 set_gdbarch_decr_pc_after_break.
3494
3495 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3496 RISCV_LAST_FP_REGNUM + 1.
3497 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3498
3499 2018-07-17 Tom Tromey <tom@tromey.com>
3500
3501 * configure.ac: Remove --disable-gdbcli.
3502 * configure: Rebuild.
3503 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3504 (SUBDIR_CLI_CFLAGS): Remove.
3505 (SFILES): Use SUBDIR_CLI_SRCS.
3506 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3507
3508 2018-07-17 Tom Tromey <tom@tromey.com>
3509
3510 PR gdb/18624:
3511 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3512
3513 2018-07-16 Jim Wilson <jimw@sifive.com>
3514
3515 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3516
3517 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3518
3519 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3520 variable.
3521 (libunwind_frame_sniffer): Likewise.
3522 (libunwind_frame_prev_register): Likewise.
3523 (libunwind_sigtramp_frame_sniffer): Likewise.
3524 * ia64-tdep.c (ia64_access_reg): Likewise.
3525 (ia64_access_rse_reg): Likewise.
3526 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3527 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3528
3529 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3530
3531 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3532
3533 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3534
3535 * remote-sim.c (gdbsim_target::close,
3536 gdbsim_target::mourn_inferior): Remove unused variables.
3537
3538 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3539
3540 * ia64-tdep.c (ktab_buf): New global.
3541 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3542 (get_kernel_table): Adjust.
3543
3544 2018-07-16 Tom Tromey <tom@tromey.com>
3545
3546 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3547 * dwarf2read.c (using_directives, new_symbol): Use
3548 outermost_context_p.
3549 * dbxread.c (process_one_symbol): Use outermost_context_p.
3550 * coffread.c (coff_symtab_read): Use outermost_context_p.
3551
3552 2018-07-16 Tom Tromey <tom@tromey.com>
3553
3554 * dwarf2read.c (using_directives, read_func_scope)
3555 (read_lexical_block_scope): Update.
3556 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3557 * buildsym.h (local_using_directives, global_using_directives):
3558 Don't declare.
3559 (get_local_using_directives, set_local_using_directives)
3560 (get_global_using_directives): Declare.
3561 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3562 m_global_using_directives>: New members.
3563 (finish_block_internal, prepare_for_building)
3564 (reset_symtab_globals, end_symtab_get_static_block)
3565 (push_context): Update.
3566 (get_local_using_directives, set_local_using_directives)
3567 (get_global_using_directives): New functions.
3568 (buildsym_init): Update.
3569
3570 2018-07-16 Tom Tromey <tom@tromey.com>
3571
3572 * xcoffread.c (xcoff_initial_scan): Don't call
3573 free_pending_blocks.
3574 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3575 * buildsym.h (class scoped_free_pendings): Add constructor.
3576 (free_pending_blocks): Don't declare.
3577 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3578 (free_pending_blocks): Now static.
3579
3580 2018-07-16 Tom Tromey <tom@tromey.com>
3581
3582 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3583 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3584 member.
3585 (struct subfile_stack): Remove.
3586 (subfile_stack): Remove.
3587 (push_subfile, pop_subfile, buildsym_init): Update.
3588
3589 2018-07-16 Tom Tromey <tom@tromey.com>
3590
3591 * buildsym.c (push_subfile): Use gdb_assert.
3592 (pop_subfile): Use gdb_assert.
3593
3594 2018-07-16 Tom Tromey <tom@tromey.com>
3595
3596 * buildsym.h (merge_symbol_lists): Remove.
3597 * buildsym.c (merge_symbol_lists): Remove.
3598
3599 2018-07-16 Tom Tromey <tom@tromey.com>
3600
3601 * stabsread.c (scan_file_globals): Update comment.
3602 * stabsread.h (scan_file_globals): Move from buildsym.h.
3603 * buildsym.h (scan_file_globals): Move to stabsread.h.
3604
3605 2018-07-16 Tom Tromey <tom@tromey.com>
3606
3607 * xcoffread.c (xcoff_new_init): Update.
3608 * mipsread.c (mipscoff_new_init): Update.
3609 * mdebugread.c (mdebug_build_psymtabs): Update.
3610 * elfread.c (elf_new_init): Update.
3611 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3612 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3613 * buildsym.h (buildsym_new_init): Don't declare.
3614 * buildsym.c (buildsym_new_init): Remove.
3615
3616 2018-07-16 Tom Tromey <tom@tromey.com>
3617
3618 * stabsread.h (within_function): Move from buildsym.h.
3619 * stabsread.c (start_stabs): Clear within_function.
3620 * coffread.c (coff_start_symtab): Clear within_function.
3621 * buildsym.h (within_function): Move to stabsread.h.
3622 * buildsym.c (prepare_for_building): Update.
3623
3624 2018-07-16 Tom Tromey <tom@tromey.com>
3625
3626 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3627 * dwarf2read.c (dwarf2_start_symtab): Don't set
3628 processing_gcc_compilation.
3629 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3630
3631 2018-07-16 Tom Tromey <tom@tromey.com>
3632
3633 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3634 (next_symbol_text_func): Move from buildsym.h.
3635 * stabsread.c (hashname): Move from buildsym.c.
3636 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3637 (next_symbol_text_func, hashname): Move to stabsread.h.
3638 * buildsym.c: Don't include bcache.h
3639 (hashname): Move to stasbread.c.
3640
3641 2018-07-16 Tom Tromey <tom@tromey.com>
3642
3643 * buildsym.h (context_stack_size): Don't declare.
3644 * buildsym.c (context_stack_size): New global.
3645
3646 2018-07-16 Tom Tromey <tom@tromey.com>
3647
3648 * dbxread.c (processing_acc_compilation): New global.
3649 * buildsym.h (processing_acc_compilation): Don't declare.
3650
3651 2018-07-16 Tom Tromey <tom@tromey.com>
3652
3653 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3654 * dbxread.c (read_ofile_symtab): Update.
3655 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3656 * buildsym.h (last_source_start_addr): Remove.
3657 (set_last_source_start_addr, get_last_source_start_addr):
3658 Declare.
3659 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3660 parameter.
3661 (struct buildsym_compunit) <m_last_source_start_addr>: New
3662 member.
3663 (prepare_for_building): Remove start_addr parameter.
3664 (start_symtab, restart_symtab, end_symtab_get_static_block)
3665 (end_symtab_with_blockvector): Update.
3666 (set_last_source_start_addr, get_last_source_start_addr): New
3667 functions.
3668
3669 2018-07-16 Tom Tromey <tom@tromey.com>
3670
3671 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3672 member.
3673 (have_line_numbers): Remove.
3674 (record_line, prepare_for_building, end_symtab_get_static_block)
3675 (augment_type_symtab): Update.
3676
3677 2018-07-16 Tom Tromey <tom@tromey.com>
3678
3679 * buildsym.c (~buildsym_compunit): Free the macro table.
3680 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3681 methods.
3682 <m_pending_macros>: New member.
3683 (pending_macros): Remove.
3684 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3685 (reset_symtab_globals, end_symtab_get_static_block)
3686 (end_symtab_with_blockvector, augment_type_symtab)
3687 (buildsym_init): Update.
3688
3689 2018-07-16 Tom Tromey <tom@tromey.com>
3690
3691 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3692 parameter.
3693 (buildsym_compunit::set_last_source_file): New method.
3694 <m_last_source_file>: New member.
3695 (prepare_for_building): Remove "name" parameter.
3696 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3697 (last_source_file): Remove.
3698 (set_last_source_file, get_last_source_file): Update.
3699
3700 2018-07-16 Tom Tromey <tom@tromey.com>
3701
3702 * buildsym.c (prepare_for_building): Add assert.
3703
3704 2018-07-16 Tom Tromey <tom@tromey.com>
3705
3706 * buildsym.c (~buildsym_compunit): Update.
3707 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3708 (start_subfile, patch_subfile_names)
3709 (end_symtab_with_blockvector): Update.
3710
3711 2018-07-16 Tom Tromey <tom@tromey.com>
3712
3713 * buildsym.c (struct buildsym_compunit): Add constructor,
3714 destructor, initializers.
3715 (start_buildsym_compunit): Remove.
3716 (free_buildsym_compunit): Use "delete".
3717 (start_symtab, restart_symtab): Use "new".
3718
3719 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3720
3721 * symfile.c (set_objfile_default_section_offset): Remove struct
3722 keyword.
3723
3724 2018-07-14 Stafford Horne <shorne@gmail.com>
3725
3726 * (Responsible Maintainers): Add myself as or1k maintainer.
3727
3728 2018-07-13 Tom Tromey <tom@tromey.com>
3729
3730 * symfile.c (set_objfile_default_section_offset): Use extra braces
3731 around initializer.
3732
3733 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3734
3735 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3736 non-branching basr.
3737
3738 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3739
3740 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3741 unittests/cli-utils-selftests.c
3742 * unittests/cli-utils-selftests.c: New file.
3743
3744 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3745
3746 * NEWS: Mention new commands. Mention change to 'thread apply'.
3747
3748 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3749
3750 * thread.c (thr_try_catch_cmd): New function.
3751 (thread_apply_all_command): Handle qcs flags.
3752 (thread_apply_command): Handle qcs flags.
3753 (taas_command): New function.
3754 (tfaas_command): New function.
3755 (_initialize_thread): Update to setup the new commands 'taas
3756 and 'tfaas'. Change doc string for 'thread apply'.
3757
3758 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3759
3760 * stack.c: (trailing_outermost_frame): New function, mostly
3761 extracted from backtrace_command_1.
3762 (leading_innermost_frame): New function.
3763 (backtrace_command_1): Update to call trailing_outermost_frame.
3764 (frame_apply_command_count): New function.
3765 (frame_apply_level_command): New function.
3766 (frame_apply_all_command): New function.
3767 (frame_apply_command): New function.
3768 (faas_command): New function.
3769 (frame_cmd_list): New variable.
3770 (_initialize_stack): Update to setup the new commands 'frame apply'
3771 and 'faas'.
3772
3773 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3774
3775 * cli-utils.c (number_or_range_parser::get_number): Only handle
3776 numbers or convenience var as numbers.
3777 (parse_flags): New function.
3778 (parse_flags_qcs): New function.
3779 (number_or_range_parser::finished): Ensure parsing end is detected
3780 before end of string.
3781 * cli-utils.h (parse_flags): New function.
3782 (parse_flags_qcs): New function.
3783 (number_or_range_parser): Remove m_finished bool.
3784 (number_or_range_parser::skip_range): Set m_in_range to false.
3785
3786 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3787
3788 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3789 on Windows.
3790
3791 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3792 Jan Kratochvil <jan.kratochvil@redhat.com>
3793 Paul Fertser <fercerpav@gmail.com>
3794 Tsutomu Seki <sekiriki@gmail.com>
3795 Pedro Alves <palves@redhat.com>
3796
3797 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3798 'unittests/parse-connection-spec-selftests.c'.
3799 (COMMON_SFILES): Add 'common/netstuff.c'.
3800 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3801 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3802 * common/netstuff.c: New file.
3803 * common/netstuff.h: New file.
3804 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3805 (wait_for_connect): Update comment. New parameter
3806 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3807 Use 'sock' directly instead of 'scb->fd'.
3808 (try_connect): New function, with code from 'net_open'.
3809 (net_open): Rewrite main loop to deal with multiple
3810 sockets/addresses. Handle IPv6-style hostnames; implement
3811 support for IPv6 connections.
3812 * unittests/parse-connection-spec-selftests.c: New file.
3813
3814 2018-07-11 Pedro Alves <palves@redhat.com>
3815
3816 PR gdb/23377
3817 * remote.c (remote_target::remote_detach_pid): Call
3818 set_current_process.
3819
3820 2018-07-11 Pedro Alves <palves@redhat.com>
3821
3822 * h8300-tdep.c (h8300_gdbarch_init): Remove
3823 set_gdbarch_ecoff_reg_to_regnum calls.
3824
3825 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3826
3827 PR c++/23373
3828 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3829 offsets/sizes for static members of a class/struct.
3830
3831 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3832
3833 * target-descriptions.c (tdesc_register_bitsize): Rename.
3834 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3835 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3836 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3837
3838 2018-07-10 Tom Tromey <tom@tromey.com>
3839
3840 * breakpoint.c (moribund_locations): Now static and a
3841 std::vector.
3842 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3843 (build_bpstat_chain, update_global_location_list)
3844 (breakpoint_retire_moribund): Update.
3845 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3846 VEC.
3847
3848 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3849
3850 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3851 (riscv_register_reggroup_p): Use new function, remove unneeded
3852 parenthesis.
3853 (riscv_push_dummy_call): Extend assert to compare against xlen or
3854 flen based on register type.
3855
3856 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3857
3858 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3859
3860 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3861
3862 * remote.c (show_hardware_watchpoint_limit): New function.
3863 (show_hardware_watchpoint_length_limit): New function.
3864 (show_hardware_breakpoint_limit): New function.
3865 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3866 where appropriate, update help text.
3867
3868 2018-07-09 Tom Tromey <tom@tromey.com>
3869
3870 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3871 (CLIBS): Don't mention NAT_CLIBS.
3872
3873 2018-07-09 Tom Tromey <tom@tromey.com>
3874
3875 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3876 (LIBGDB_OBS, clean mostlyclean): Update.
3877 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3878
3879 2018-07-09 Tom Tromey <tom@tromey.com>
3880
3881 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3882 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3883 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3884
3885 2018-07-09 Tom Tromey <tom@tromey.com>
3886
3887 * Makefile.in (ALLDEPFILES): Remove exec.c.
3888 (COMMON_OBS): Remove exec.o.
3889 (COMMON_SFILES): Add exec.c.
3890
3891 2018-07-09 Tom Tromey <tom@tromey.com>
3892
3893 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3894
3895 2018-07-09 Tom Tromey <tom@tromey.com>
3896
3897 * Makefile.in (clean mostlyclean): Remove stamp-version.
3898 (version.c): Depend on stamp-version.
3899 (stamp-version): New rule, from version.c rule.
3900
3901 2018-07-09 Tom Tromey <tom@tromey.com>
3902
3903 * Makefile.in (init.c): Depend on stamp-init.
3904 (stamp-init): New rule, from init.c rule.
3905 (clean mostlyclean): Remove stamp-init.
3906
3907 2018-07-09 Tom Tromey <tom@tromey.com>
3908
3909 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3910 SUBDIR_GCC_COMPILE_SRCS.
3911
3912 2018-07-09 Tom Tromey <tom@tromey.com>
3913
3914 * Makefile.in (init.c): Remove some unused sed rules.
3915
3916 2018-07-09 Tom Tromey <tom@tromey.com>
3917
3918 * Makefile.in (TSOBS): Remove.
3919 (INIT_FILES): Update.
3920 (LIBGDB_OBS): Update.
3921 (COMMON_SFILES): Add inflow.c.
3922 (SFILES): Remove inflow.c.
3923
3924 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3925
3926 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3927
3928 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3929
3930 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3931 get_saveloc_name, is_signal_frame_name, step_name,
3932 init_remote_name, create_addr_space_name,
3933 destroy_addr_space_name, search_unwind_table_name,
3934 find_dyn_list_name): Constify.
3935
3936 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3937
3938 * darwin-nat.c (darwin_pthread_kill): New function.
3939 (darwin_resume_thread): Use darwin_pthread_kill.
3940
3941 2018-07-05 Tom de Vries <tdevries@suse.de>
3942
3943 * macroexp.c (macro_buffer) <operator=>: New member function.
3944
3945 2018-07-04 Tom Tromey <tom@tromey.com>
3946
3947 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
3948
3949 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
3950
3951 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
3952 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
3953 * maint.c: Likewise.
3954 * top.c: Likewise.
3955
3956 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3957
3958 * NEWS: Create a new section for the next release branch.
3959 Rename the section of the current branch, now that it has
3960 been cut.
3961
3962 2018-07-04 Joel Brobecker <brobecker@adacore.com>
3963
3964 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
3965 * version.in: Bump version to 8.2.50.DATE-git.
3966
3967 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
3968 Pedro Alves <palves@redhat.com>
3969
3970 * linux-nat.c (linux_init_ptrace): Rename to ...
3971 (linux_init_ptrace_procfs): ... this. Call
3972 linux_proc_init_warnings.
3973 (linux_nat_target::post_attach)
3974 (linux_nat_target::post_startup_inferior): Adjust.
3975 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
3976 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
3977
3978 2018-07-04 Tom de Vries <tdevries@suse.de>
3979
3980 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
3981 check ...
3982 (read_comp_unit_head): ... here.
3983
3984 2018-07-03 Tom Tromey <tom@tromey.com>
3985
3986 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
3987 (stop_tracing, tstatus_command)
3988 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
3989 (print_one_static_tracepoint_marker): Update.
3990 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
3991 std::vector.
3992 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
3993 VEC.
3994 (all_tracepoints, static_tracepoints_here): Return std::vector.
3995
3996 2018-07-03 Tom Tromey <tom@tromey.com>
3997
3998 * common/ptid.c (ptid_equal): Remove.
3999 * common/ptid.h (ptid_equal): Don't declare.
4000 * ada-tasks.c: Update.
4001 * breakpoint.c: Update.
4002 * common/agent.c: Update.
4003 * corelow.c: Update.
4004 * darwin-nat-info.c: Update.
4005 * darwin-nat.c: Update.
4006 * dcache.c: Update.
4007 * dtrace-probe.c: Update.
4008 * dummy-frame.c: Update.
4009 * fbsd-nat.c: Update.
4010 * frame.c: Update.
4011 * gdbthread.h: Update.
4012 * gnu-nat.c: Update.
4013 * go32-nat.c: Update.
4014 * inf-loop.c: Update.
4015 * inf-ptrace.c: Update.
4016 * infcall.c: Update.
4017 * infcmd.c: Update.
4018 * inflow.c: Update.
4019 * infrun.c: Update.
4020 * linux-fork.c: Update.
4021 * linux-nat.c: Update.
4022 * linux-thread-db.c: Update.
4023 * mi/mi-cmd-var.c: Update.
4024 * mi/mi-interp.c: Update.
4025 * mi/mi-main.c: Update.
4026 * nto-procfs.c: Update.
4027 * ppc-linux-tdep.c: Update.
4028 * procfs.c: Update.
4029 * python/py-inferior.c: Update.
4030 * python/py-record-btrace.c: Update.
4031 * python/py-record.c: Update.
4032 * ravenscar-thread.c: Update.
4033 * regcache.c: Update.
4034 * remote-sim.c: Update.
4035 * remote.c: Update.
4036 * sol-thread.c: Update.
4037 * solib.c: Update.
4038 * target.c: Update.
4039 * tui/tui-stack.c: Update.
4040 * varobj.c: Update.
4041 * windows-nat.c: Update.
4042 * windows-tdep.c: Update.
4043
4044 2018-07-03 Tom Tromey <tom@tromey.com>
4045
4046 * common/ptid.c (ptid_match): Remove.
4047 * common/ptid.h (ptid_match): Don't declare.
4048 * fbsd-nat.c: Update.
4049 * infcmd.c: Update.
4050 * infrun.c: Update.
4051 * linux-nat.c: Update.
4052 * record-btrace.c: Update.
4053 * regcache.c: Update.
4054 * remote.c: Update.
4055
4056 2018-07-03 Tom Tromey <tom@tromey.com>
4057
4058 * common/ptid.c (ptid_tid_p): Remove.
4059 * common/ptid.h (ptid_tid_p): Don't declare.
4060 * sol-thread.c: Update.
4061
4062 2018-07-03 Tom Tromey <tom@tromey.com>
4063
4064 * common/ptid.c (ptid_lwp_p): Remove.
4065 * common/ptid.h (ptid_lwp_p): Don't declare.
4066 * fbsd-nat.c: Update.
4067 * linux-nat.c: Update.
4068 * nat/linux-procfs.c: Update.
4069 * nat/x86-linux-dregs.c: Update.
4070 * sol-thread.c: Update.
4071
4072 2018-07-03 Tom Tromey <tom@tromey.com>
4073
4074 * common/ptid.c (ptid_is_pid): Remove.
4075 * common/ptid.h (ptid_is_pid): Don't declare.
4076 * infrun.c: Update.
4077 * linux-nat.c: Update.
4078 * mi/mi-interp.c: Update.
4079 * remote.c: Update.
4080 * thread.c: Update.
4081
4082 2018-07-03 Tom Tromey <tom@tromey.com>
4083
4084 * common/ptid.c (ptid_get_tid): Remove.
4085 * common/ptid.h (ptid_get_tid): Don't declare.
4086 * ada-tasks.c: Update.
4087 * aix-thread.c: Update.
4088 * bsd-uthread.c: Update.
4089 * darwin-nat.c: Update.
4090 * fbsd-nat.c: Update.
4091 * i386-darwin-nat.c: Update.
4092 * infrun.c: Update.
4093 * linux-tdep.c: Update.
4094 * nto-procfs.c: Update.
4095 * ppc-ravenscar-thread.c: Update.
4096 * python/py-infthread.c: Update.
4097 * ravenscar-thread.c: Update.
4098 * sol-thread.c: Update.
4099 * sparc-ravenscar-thread.c: Update.
4100 * windows-nat.c: Update.
4101
4102 2018-07-03 Tom Tromey <tom@tromey.com>
4103
4104 * common/ptid.c (ptid_get_lwp): Remove.
4105 * common/ptid.h (ptid_get_lwp): Don't declare.
4106 * aarch64-linux-nat.c: Update.
4107 * ada-tasks.c: Update.
4108 * aix-thread.c: Update.
4109 * amd64-linux-nat.c: Update.
4110 * arm-linux-nat.c: Update.
4111 * corelow.c: Update.
4112 * fbsd-nat.c: Update.
4113 * fbsd-tdep.c: Update.
4114 * gnu-nat.c: Update.
4115 * i386-cygwin-tdep.c: Update.
4116 * i386-gnu-nat.c: Update.
4117 * i386-linux-nat.c: Update.
4118 * ia64-linux-nat.c: Update.
4119 * inf-ptrace.c: Update.
4120 * infrun.c: Update.
4121 * linux-fork.c: Update.
4122 * linux-nat.c: Update.
4123 * linux-tdep.c: Update.
4124 * linux-thread-db.c: Update.
4125 * mips-linux-nat.c: Update.
4126 * nat/aarch64-linux-hw-point.c: Update.
4127 * nat/aarch64-linux.c: Update.
4128 * nat/linux-btrace.c: Update.
4129 * nat/linux-osdata.c: Update.
4130 * nat/linux-procfs.c: Update.
4131 * nat/x86-linux-dregs.c: Update.
4132 * obsd-nat.c: Update.
4133 * ppc-fbsd-nat.c: Update.
4134 * ppc-linux-nat.c: Update.
4135 * procfs.c: Update.
4136 * python/py-infthread.c: Update.
4137 * ravenscar-thread.c: Update.
4138 * remote.c: Update.
4139 * s390-linux-nat.c: Update.
4140 * sol-thread.c: Update.
4141 * sol2-tdep.c: Update.
4142 * spu-linux-nat.c: Update.
4143 * x86-linux-nat.c: Update.
4144 * xtensa-linux-nat.c: Update.
4145
4146 2018-07-03 Tom Tromey <tom@tromey.com>
4147
4148 * common/ptid.c (ptid_get_pid): Remove.
4149 * common/ptid.h (ptid_get_pid): Don't declare.
4150 * aarch64-linux-nat.c: Update.
4151 * ada-lang.c: Update.
4152 * aix-thread.c: Update.
4153 * alpha-bsd-nat.c: Update.
4154 * amd64-fbsd-nat.c: Update.
4155 * amd64-linux-nat.c: Update.
4156 * arm-linux-nat.c: Update.
4157 * arm-nbsd-nat.c: Update.
4158 * auxv.c: Update.
4159 * break-catch-syscall.c: Update.
4160 * breakpoint.c: Update.
4161 * bsd-uthread.c: Update.
4162 * corelow.c: Update.
4163 * ctf.c: Update.
4164 * darwin-nat.c: Update.
4165 * fbsd-nat.c: Update.
4166 * fbsd-tdep.c: Update.
4167 * gcore.c: Update.
4168 * gnu-nat.c: Update.
4169 * hppa-nbsd-nat.c: Update.
4170 * hppa-obsd-nat.c: Update.
4171 * i386-fbsd-nat.c: Update.
4172 * ia64-linux-nat.c: Update.
4173 * inf-ptrace.c: Update.
4174 * infcmd.c: Update.
4175 * inferior.c: Update.
4176 * inferior.h: Update.
4177 * inflow.c: Update.
4178 * infrun.c: Update.
4179 * linux-fork.c: Update.
4180 * linux-nat.c: Update.
4181 * linux-tdep.c: Update.
4182 * linux-thread-db.c: Update.
4183 * m68k-bsd-nat.c: Update.
4184 * mi/mi-interp.c: Update.
4185 * mi/mi-main.c: Update.
4186 * mips-linux-nat.c: Update.
4187 * mips-nbsd-nat.c: Update.
4188 * mips64-obsd-nat.c: Update.
4189 * nat/aarch64-linux-hw-point.c: Update.
4190 * nat/aarch64-linux.c: Update.
4191 * nat/linux-btrace.c: Update.
4192 * nat/linux-osdata.c: Update.
4193 * nat/linux-procfs.c: Update.
4194 * nat/x86-linux-dregs.c: Update.
4195 * nto-procfs.c: Update.
4196 * obsd-nat.c: Update.
4197 * ppc-linux-nat.c: Update.
4198 * ppc-nbsd-nat.c: Update.
4199 * ppc-obsd-nat.c: Update.
4200 * proc-service.c: Update.
4201 * procfs.c: Update.
4202 * python/py-inferior.c: Update.
4203 * python/py-infthread.c: Update.
4204 * ravenscar-thread.c: Update.
4205 * record.c: Update.
4206 * remote-sim.c: Update.
4207 * remote.c: Update.
4208 * rs6000-nat.c: Update.
4209 * s390-linux-nat.c: Update.
4210 * sh-nbsd-nat.c: Update.
4211 * sol-thread.c: Update.
4212 * sparc-nat.c: Update.
4213 * sparc64-tdep.c: Update.
4214 * spu-linux-nat.c: Update.
4215 * spu-tdep.c: Update.
4216 * target-debug.h: Update.
4217 * target.c: Update.
4218 * thread.c: Update.
4219 * tid-parse.c: Update.
4220 * tracefile-tfile.c: Update.
4221 * vax-bsd-nat.c: Update.
4222 * windows-nat.c: Update.
4223 * x86-linux-nat.c: Update.
4224 * x86-nat.c: Update.
4225
4226 2018-07-03 Tom Tromey <tom@tromey.com>
4227
4228 * common/ptid.c (pid_to_ptid): Remove.
4229 * common/ptid.h (pid_to_ptid): Don't declare.
4230 * aix-thread.c: Update.
4231 * arm-linux-nat.c: Update.
4232 * common/ptid.c: Update.
4233 * common/ptid.h: Update.
4234 * corelow.c: Update.
4235 * ctf.c: Update.
4236 * darwin-nat.c: Update.
4237 * fbsd-nat.c: Update.
4238 * fork-child.c: Update.
4239 * gnu-nat.c: Update.
4240 * go32-nat.c: Update.
4241 * inf-ptrace.c: Update.
4242 * infcmd.c: Update.
4243 * inferior.c: Update.
4244 * infrun.c: Update.
4245 * linux-fork.c: Update.
4246 * linux-nat.c: Update.
4247 * nat/aarch64-linux-hw-point.c: Update.
4248 * nat/fork-inferior.c: Update.
4249 * nat/x86-linux-dregs.c: Update.
4250 * nto-procfs.c: Update.
4251 * obsd-nat.c: Update.
4252 * procfs.c: Update.
4253 * progspace.c: Update.
4254 * remote.c: Update.
4255 * rs6000-nat.c: Update.
4256 * s390-linux-nat.c: Update.
4257 * sol-thread.c: Update.
4258 * spu-linux-nat.c: Update.
4259 * target.c: Update.
4260 * top.c: Update.
4261 * tracefile-tfile.c: Update.
4262 * windows-nat.c: Update.
4263
4264 2018-07-03 Tom Tromey <tom@tromey.com>
4265
4266 * common/ptid.h (ptid_build): Don't declare.
4267 * common/ptid.c (ptid_build): Remove.
4268 * aix-thread.c: Update.
4269 * bsd-kvm.c: Update.
4270 * bsd-uthread.c: Update.
4271 * common/agent.c: Update.
4272 * common/ptid.c: Update.
4273 * common/ptid.h: Update.
4274 * corelow.c: Update.
4275 * darwin-nat.c: Update.
4276 * fbsd-nat.c: Update.
4277 * gnu-nat.c: Update.
4278 * linux-fork.c: Update.
4279 * linux-nat.c: Update.
4280 * linux-thread-db.c: Update.
4281 * nat/linux-osdata.c: Update.
4282 * nat/linux-procfs.c: Update.
4283 * nto-procfs.c: Update.
4284 * obsd-nat.c: Update.
4285 * proc-service.c: Update.
4286 * procfs.c: Update.
4287 * ravenscar-thread.c: Update.
4288 * remote-sim.c: Update.
4289 * remote.c: Update.
4290 * sol-thread.c: Update.
4291 * target.c: Update.
4292 * windows-nat.c: Update.
4293
4294 2018-07-03 Tom Tromey <tom@tromey.com>
4295
4296 * infrun.c (follow_exec): Use exit_inferior_silent.
4297 * inferior.c (exit_inferior_num_silent): Remove.
4298 * inferior.h (exit_inferior_num_silent): Don't declare.
4299
4300 2018-07-03 Tom Tromey <tom@tromey.com>
4301
4302 PR cli/23340:
4303 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4304 inferior_ptid on error.
4305
4306 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4307 Simon Marchi <simon.marchi@polymtl.ca>
4308
4309 PR tdep/8282
4310 * disasm.h (gdb_disassembler): Add
4311 `m_disassembler_options_holder'. member
4312 * disasm.c (get_all_disassembler_options): New function.
4313 (gdb_disassembler::gdb_disassembler): Use it.
4314 (gdb_buffered_insn_length_init_dis): Likewise.
4315 (gdb_buffered_insn_length): Adjust accordingly.
4316 (set_disassembler_options): Handle options with arguments.
4317 (show_disassembler_options_sfunc): Likewise. Add a leading new
4318 line if showing options with descriptions.
4319 (disassembler_options_completer): Adapt to using the
4320 `disasm_options_and_args_t' structure.
4321 * mips-tdep.c (mips_disassembler_options): New variable.
4322 (mips_disassembler_options_o32): Likewise.
4323 (mips_disassembler_options_n32): Likewise.
4324 (mips_disassembler_options_n64): Likewise.
4325 (gdb_print_insn_mips): Don't set `disassembler_options'.
4326 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4327 functions.
4328 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4329 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4330 `gdbarch_disassembler_options_implicit' and
4331 `gdbarch_valid_disassembler_options'.
4332 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4333 `disasm_options_and_args_t' structure.
4334 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4335 method.
4336 (valid_disassembler_options): Switch from `disasm_options_t' to
4337 the `disasm_options_and_args_t' structure.
4338 * NEWS: Document `set disassembler-options' support for the MIPS
4339 target.
4340 * gdbarch.h: Regenerate.
4341 * gdbarch.c: Regenerate.
4342
4343 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4344
4345 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4346
4347 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4348
4349 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4350 parameter in call to amd64_target_description.
4351 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4352 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4353 (amd64fbsd_init_abi): Likewise.
4354 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4355 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4356 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4357 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4358
4359 2018-06-29 Pedro Alves <palves@redhat.com>
4360
4361 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4362 "segments" parameter.
4363 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4364 (_initialize_amd64_tdep): Update call to
4365 amd64_create_target_description.
4366 (amd64_target_description): Add "segments" parameter. Adjust
4367 the implementation to use it.
4368 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4369 call to amd64_create_target_description.
4370 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4371 * gdb/arch/amd64.h (amd64_create_target_description): Add
4372 "segments" register.
4373 * gdb/arch/amd64.c (amd64_create_target_description): Add
4374 "segments" parameter. Call create_feature_i386_64bit_segments
4375 only if SEGMENTS is true.
4376 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4377 call to amd64_create_target_description.
4378
4379 2018-06-29 Pedro Alves <palves@redhat.com>
4380
4381 * thread.c (thread_target_id_str): New, factored out from ...
4382 (print_thread_info_1): ... here. Use it to compute the max
4383 "Target Id" column width.
4384
4385 2018-06-29 Pedro Alves <palves@redhat.com>
4386
4387 * remote.c (remote_target::extra_thread_info): Delete
4388 'display_buf' and 'n' locals. from the cache, regardless of
4389 packet mechanims is in use. Use cache for qThreadExtra and qP
4390 methods too.
4391
4392 2018-06-29 Pedro Alves <palves@redhat.com>
4393
4394 * blockframe.c (find_pc_sect_containing_function): New function.
4395 * breakpoint.c (print_breakpoint_location): Don't call
4396 find_pc_sect_function.
4397 * linespec.c (create_sals_line_offset): Record the location's
4398 symbol in the sal.
4399 * linespec.c (convert_address_location_to_sals): Fill in sal's
4400 symbol with find_pc_sect_containing_function.
4401 * symtab.c (find_function_start_sal): Rename to ...
4402 (find_function_start_sal_1): ... this.
4403 (find_function_start_sal): Reimplement as wrapper around
4404 find_function_start_sal_1, and use
4405 find_pc_sect_containing_function to fill in the sal's symbol.
4406 (find_function_start_sal(symbol*, bool)): Adjust.
4407 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4408 comments.
4409 (find_pc_sect_containing_function): Declare.
4410
4411 2018-06-29 Pedro Alves <palves@redhat.com>
4412
4413 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4414 true if the the location has no symbol.
4415
4416 2018-06-28 Tom Tromey <tom@tromey.com>
4417
4418 * NEWS: Mention --enable-codesign.
4419 * silent-rules.mk (ECHO_SIGN): New variable.
4420 * configure.ac: Add --enable-codesign.
4421 * configure: Rebuild.
4422 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4423 (gdb$(EXEEXT)): Optionally invoke codesign.
4424
4425 2018-06-28 Pedro Alves <palves@redhat.com>
4426
4427 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4428 comments.
4429 (switch_to_thread_no_regs): Adjust comment.
4430 * infcmd.c (stop_pc): Delete.
4431 (post_create_inferior, info_program_command): Replace references
4432 to stop_pc with references to thread_info->suspend.stop_pc.
4433 * inferior.h (stop_pc): Delete declaration.
4434 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4435 (handle_inferior_event_1, handle_signal_stop)
4436 (process_event_stop_test, keep_going_stepped_thread)
4437 (handle_step_into_function, handle_step_into_function_backward)
4438 (print_stop_location): Replace references to stop_pc with
4439 references to thread_info->suspend.stop_pc.
4440 (struct infcall_suspend_state) <stop_pc>: Delete field.
4441 (save_infcall_suspend_state, restore_infcall_suspend_state):
4442 Remove references to inf_stat->stop_pc.
4443 * linux-fork.c (fork_load_infrun_state): Likewise.
4444 * record-btrace.c (record_btrace_set_replay): Likewise.
4445 * record-full.c (record_full_goto_entry): Likewise.
4446 * remote.c (print_one_stopped_thread): Likewise.
4447 * target.c (target_resume): Extend comment.
4448 * thread.c (set_executing_thread): New.
4449 (set_executing): Use it.
4450 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4451 Remove references to stop_pc.
4452
4453 2018-06-28 Pedro Alves <palves@redhat.com>
4454
4455 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4456 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4457
4458 2018-06-28 Tom Tromey <tom@tromey.com>
4459
4460 * coffread.c (coff_symfile_finish): Update.
4461 * xcoffread.c (xcoff_symfile_finish): Update.
4462 * elfread.c (elf_symfile_finish): Update.
4463 * symfile.h (dwarf2_free_objfile): Don't declare.
4464 * dwarf2read.c (_initialize_dwarf2_read): Use
4465 register_objfile_data_with_cleanup.
4466 (dwarf2_free_objfile): Now static. Change signature.
4467
4468 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4469
4470 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4471 option "-o" to add-symbol-file-load to add an offset to each
4472 section's load address.
4473 * symfile.c (set_objfile_default_section_offset): New function.
4474
4475 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4476
4477 * symfile.c (add_symbol_file_command): Make sure that sections
4478 with the same name are sorted in the same order.
4479
4480 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4481
4482 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4483 require the second argument. If omitted, load sections at the
4484 addresses specified in the file.
4485
4486 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4487
4488 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4489 (_initialize_symfile): Add option "-o" to symbol-file to add an
4490 offset to each section of the symbol file.
4491
4492 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4493
4494 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4495
4496 2018-06-27 Tom Tromey <tom@tromey.com>
4497
4498 * stack.c (_initialize_stack): Update "func" help text.
4499
4500 2018-06-27 Tom Tromey <tom@tromey.com>
4501
4502 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4503 std::vector.
4504 (unwind_infopy_str, pyuw_create_unwind_info)
4505 (unwind_infopy_add_saved_register, pyuw_sniffer)
4506 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4507 Update.
4508 (struct saved_reg): Add constructor.
4509 <value>: Now a gdbpy_ref<>.
4510
4511 2018-06-27 Tom Tromey <tom@tromey.com>
4512
4513 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4514
4515 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4516
4517 * gdb-gdb.py.in: Format using autopep8.
4518
4519 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4520
4521 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4522 (type_lookup_function): Recognize CORE_ADDR values.
4523
4524 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4525
4526 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4527 print tag_name.
4528
4529 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4530
4531 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4532 <__lt__>: Add.
4533
4534 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4535
4536 * gdb-gdb.py: Move to...
4537 * gdb-gdb.py.in: ... here.
4538 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4539 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4540 dependencies.
4541 (distclean): Remove gdb-gdb.py when cleaning.
4542 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4543 * configure: Re-generate.
4544
4545 2018-06-27 Pedro Alves <palves@redhat.com>
4546
4547 * proc-service.c (get_ps_regcache): New.
4548 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4549 (ps_lsetfpregs): Use it.
4550
4551 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4552
4553 PR gdb/21695
4554 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4555 (dwarf_decode_lines_1): Adjust.
4556
4557 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4558
4559 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4560 override.
4561 <info_proc>: Likewise.
4562
4563 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4564
4565 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4566 to windows_fetch_one_register, and only handle the case of
4567 fetching one register. Move the code that reloads the context
4568 and iterates over all registers if R is negative to...
4569 (windows_nat_target::fetch_registers): ... here.
4570 (do_windows_store_inferior_registers): Rename to
4571 windows_store_one_register, and only handle the case of storing
4572 one register. Move the code that handles the case where r is
4573 negative to...
4574 (windows_nat_target::store_registers) ... here.
4575
4576 2018-06-26 Tom Tromey <tom@tromey.com>
4577
4578 PR rust/22574:
4579 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4580 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4581 Update.
4582 (rust_internal_print_type): Add podata parameter.
4583 (rust_print_type): Update.
4584
4585 2018-06-26 Tom Tromey <tom@tromey.com>
4586
4587 * typeprint.h (struct print_offset_data) <update, finish,
4588 maybe_print_hole>: New methods.
4589 <indentation>: New constant.
4590 * typeprint.c (print_offset_data::indentation): Define.
4591 (print_offset_data::maybe_print_hole, print_offset_data::update)
4592 (print_offset_data::finish): Move from c-typeprint.c and rename.
4593 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4594 (print_spaces_filtered_with_print_options): Update.
4595 (c_print_type_union_field_offset, maybe_print_hole)
4596 (c_print_type_struct_field_offset): Move to typeprint.c and
4597 rename.
4598 (c_type_print_base_struct_union): Update.
4599
4600 2018-06-25 Pedro Alves <palves@redhat.com>
4601
4602 * gdbthread.h (thread_info_ref, delete_thread)
4603 (delete_thread_silent, first_thread_of_inferior)
4604 (any_thread_of_inferior, switch_to_thread)
4605 (enable_thread_stack_temporaries)
4606 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4607 (get_last_thread_stack_temporary)
4608 (value_in_thread_stack_temporaries, can_access_registers_thread):
4609 Spell out "struct thread_info" instead of just "thread_info".
4610 * inferior.h (notice_new_inferior): Likewise.
4611
4612 2018-06-25 Pedro Alves <palves@redhat.com>
4613
4614 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4615 pass thread_info pointer to delete_thread.
4616 (windows_nat_target::detach): Pass inferior pointer to
4617 detach_inferior.
4618 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4619 delete_thread.
4620 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4621 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4622 and pass a thread_info pointer to delete_thread.
4623 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4624 pass thread_info pointer to delete_thread.
4625 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4626 delete_thread_silent call.
4627 * procfs.c (procfs_target::detach): Pass inferior pointer to
4628 detach_inferior.
4629 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4630 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4631 delete_thread_silent call.
4632 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4633 pass thread_info pointer to delete_thread.
4634 (windows_nat_target::detach): Pass inferior pointer to
4635 delete_inferior.
4636
4637 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4638
4639 * regcache.c (readable_regcache::read_part): Fix asserts.
4640 (reg_buffer::raw_collect_part): New function.
4641 (regcache::write_part): Fix asserts.
4642 (reg_buffer::raw_supply_part): New function.
4643 (regcache::transfer_regset_register): New helper function.
4644 (regcache::transfer_regset): Call new functions.
4645 (regcache_supply_regset): Use gdb_byte*.
4646 (regcache::supply_regset): Likewise.
4647 (regcache_collect_regset): Likewise.
4648 (regcache::collect_regset): Likewise.
4649 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4650 (reg_buffer::raw_supply_part): Likewise.
4651 (regcache::transfer_regset_register): Likewise.
4652 (regcache::transfer_regset): Use gdb_byte*.
4653
4654 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4655
4656 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4657
4658 2018-06-21 Pedro Alves <palves@redhat.com>
4659
4660 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4661 instead of a ptid_t. All callers adjusted.
4662 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4663 adjusted.
4664 (print_ada_task_info, display_current_task_id, task_command_1):
4665 Adjust.
4666 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4667 inferior_thread.
4668 (breakpoint_kind): Adjust.
4669 (remove_breakpoints_pid): Rename to ...
4670 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4671 pointer. All callers adjusted.
4672 (bpstat_clear_actions): Use inferior_thread.
4673 (get_bpstat_thread): New.
4674 (bpstat_do_actions): Use it.
4675 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4676 to take a thread_info pointer. All callers adjusted.
4677 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4678 (breakpoint_re_set_thread): Use inferior_thread.
4679 * breakpoint.h (struct inferior): Forward declare.
4680 (bpstat_stop_status): Update.
4681 (remove_breakpoints_pid): Delete.
4682 (remove_breakpoints_inf): New.
4683 * bsd-uthread.c (bsd_uthread_target::wait)
4684 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4685 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4686 (maint_btrace_packet_history_cmd)
4687 (maint_btrace_clear_packet_history_cmd): Adjust.
4688 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4689 inferior_thread.
4690 * cli/cli-interp.c: Include "inferior.h".
4691 * common/refcounted-object.h (struct
4692 refcounted_object_ref_policy): New.
4693 * compile/compile-object-load.c: Include gdbthread.h.
4694 (store_regs): Use inferior_thread.
4695 * corelow.c (core_target::close): Use current_inferior.
4696 (core_target_open): Adjust to use first_thread_of_inferior and use
4697 the current inferior.
4698 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4699 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4700 <thread>: ... this new field. All references adjusted.
4701 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4702 Take a thread_info pointer instead of a ptid_t.
4703 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4704 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4705 thread_info pointer instead of a ptid_t.
4706 * elfread.c: Include "inferior.h".
4707 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4708 Use inferior_thread.
4709 * eval.c (evaluate_subexp): Likewise.
4710 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4711 inferior_thread.
4712 * gdb_proc_service.h (struct thread_info): Forward declare.
4713 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4714 <thread>: ... this new field. All references adjusted.
4715 * gdbarch.h, gdbarch.c: Regenerate.
4716 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4717 'thread' parameter. All implementations and callers adjusted.
4718 * gdbthread.h (thread_info) <set_running>: New method.
4719 (delete_thread, delete_thread_silent): Take a thread_info pointer
4720 instead of a ptid.
4721 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4722 (first_thread_of_process): Delete, replaced by ...
4723 (first_thread_of_inferior): ... this new function. All callers
4724 adjusted.
4725 (any_live_thread_of_process): Delete, replaced by ...
4726 (any_live_thread_of_inferior): ... this new function. All callers
4727 adjusted.
4728 (switch_to_thread, switch_to_no_thread): Declare.
4729 (is_executing): Delete.
4730 (enable_thread_stack_temporaries): Update comment.
4731 <enable_thread_stack_temporaries>: Take a thread_info pointer
4732 instead of a ptid_t. Incref the thread.
4733 <~enable_thread_stack_temporaries>: Decref the thread.
4734 <m_ptid>: Delete
4735 <m_thr>: New.
4736 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4737 (get_last_thread_stack_temporary)
4738 (value_in_thread_stack_temporaries, can_access_registers_thread):
4739 Take a thread_info pointer instead of a ptid_t. All callers
4740 adjusted.
4741 * infcall.c (get_call_return_value): Use inferior_thread.
4742 (run_inferior_call): Work with thread pointers instead of ptid_t.
4743 (call_function_by_hand_dummy): Work with thread pointers instead
4744 of ptid_t. Use thread_info_ref.
4745 * infcmd.c (proceed_thread_callback): Access thread's state
4746 directly.
4747 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4748 access thread's state directly.
4749 (continue_command): Use inferior_thread.
4750 (info_program_command): Use find_thread_ptid and access thread
4751 state directly.
4752 (proceed_after_attach_callback): Use thread state directly.
4753 (notice_new_inferior): Take a thread_info pointer instead of a
4754 ptid_t. All callers adjusted.
4755 (exit_inferior): Take an inferior pointer instead of a pid. All
4756 callers adjusted.
4757 (exit_inferior_silent): New.
4758 (detach_inferior): Delete.
4759 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4760 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4761 (detach_inferior_command, kill_inferior_command): Use
4762 find_inferior_id instead of valid_gdb_inferior_id and
4763 gdb_inferior_id_to_pid.
4764 (inferior_command): Use inferior and thread pointers.
4765 * inferior.h (struct thread_info): Forward declare.
4766 (notice_new_inferior): Take a thread_info pointer instead of a
4767 ptid_t. All callers adjusted.
4768 (detach_inferior): Delete declaration.
4769 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4770 instead of a pid. All callers adjusted.
4771 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4772 (valid_gdb_inferior_id): Delete.
4773 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4774 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4775 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4776 ...
4777 <inf>: ... this new field.
4778 <step_ptid>: Delete, replaced by ...
4779 <step_thread>: ... this new field.
4780 (get_displaced_stepping_state): Take an inferior pointer instead
4781 of a pid. All callers adjusted.
4782 (displaced_step_in_progress_any_inferior): Adjust.
4783 (displaced_step_in_progress_thread): Take a thread pointer instead
4784 of a ptid_t. All callers adjusted.
4785 (displaced_step_in_progress, add_displaced_stepping_state): Take
4786 an inferior pointer instead of a pid. All callers adjusted.
4787 (get_displaced_step_closure_by_addr): Adjust.
4788 (remove_displaced_stepping_state): Take an inferior pointer
4789 instead of a pid. All callers adjusted.
4790 (displaced_step_prepare_throw, displaced_step_prepare)
4791 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4792 All callers adjusted.
4793 (start_step_over): Adjust.
4794 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4795 displaced step queue.
4796 (do_target_resume): Adjust.
4797 (fetch_inferior_event): Use inferior_thread.
4798 (context_switch, get_inferior_stop_soon): Take an
4799 execution_control_state pointer instead of a ptid_t. All callers
4800 adjusted.
4801 (switch_to_thread_cleanup): Delete.
4802 (stop_all_threads): Use scoped_restore_current_thread.
4803 * inline-frame.c: Include "gdbthread.h".
4804 (inline_state) <inline_state>: Take a thread pointer instead of a
4805 ptid_t. All callers adjusted.
4806 <ptid>: Delete, replaced by ...
4807 <thread>: ... this new field.
4808 (find_inline_frame_state): Take a thread pointer instead of a
4809 ptid_t. All callers adjusted.
4810 (skip_inline_frames, step_into_inline_frame)
4811 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4812 pointer instead of a ptid_t. All callers adjusted.
4813 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4814 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4815 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4816 pointers directly.
4817 * linux-nat.c (get_detach_signal): Likewise.
4818 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4819 (thread_db_notice_clone): Adjust.
4820 (thread_db_find_new_threads_silently)
4821 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4822 a thread pointer instead of a ptid_t. All callers adjusted.
4823 * mi/mi-cmd-var.c: Include "inferior.h".
4824 (mi_cmd_var_update_iter): Update to use thread pointers.
4825 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4826 inferior directly.
4827 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4828 out to ...
4829 (mi_output_running): ... this new function.
4830 (mi_on_resume_1): Adjust to use it.
4831 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4832 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4833 directly.
4834 (interrupt_thread_callback): : Adjust to use thread and inferior
4835 pointers.
4836 * proc-service.c: Include "gdbthread.h".
4837 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4838 * progspace-and-thread.c: Include "inferior.h".
4839 * progspace.c: Include "inferior.h".
4840 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4841 hold a reference to an inferior_object.
4842 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4843 inferior_thread.
4844 * python/py-inferior.c (struct inferior_object): Give the type a
4845 tag name instead of a typedef.
4846 (python_on_normal_stop): No need to check if the current thread is
4847 listed.
4848 (inferior_to_inferior_object): Change return type to
4849 inferior_object. All callers adjusted.
4850 (find_thread_object): Delete, bits factored out to ...
4851 (thread_to_thread_object): ... this new function.
4852 * python/py-infthread.c (create_thread_object): Use
4853 inferior_to_inferior_object.
4854 (thpy_is_stopped): Use thread pointer directly.
4855 (gdbpy_selected_thread): Use inferior_thread.
4856 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4857 field, replaced with ...
4858 <thread>: ... this new field. All users adjusted.
4859 (btpy_insn_or_gap_new): Drop const.
4860 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4861 callers adjusted.
4862 * python/py-record.c: Include "gdbthread.h".
4863 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4864 a ptid_t. All callers adjusted.
4865 (gdbpy_current_recording): Use inferior_thread.
4866 * python/py-record.h (recpy_record_object) <ptid>: Delete
4867 field, replaced with ...
4868 <thread>: ... this new field. All users adjusted.
4869 (recpy_element_object) <ptid>: Delete
4870 field, replaced with ...
4871 <thread>: ... this new field. All users adjusted.
4872 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4873 a ptid_t. All callers adjusted.
4874 * python/py-threadevent.c: Include "gdbthread.h".
4875 (get_event_thread): Use thread_to_thread_object.
4876 * python/python-internal.h (struct inferior_object): Forward
4877 declare.
4878 (find_thread_object, find_inferior_object): Delete declarations.
4879 (thread_to_thread_object, inferior_to_inferior_object): New
4880 declarations.
4881 * record-btrace.c: Include "inferior.h".
4882 (require_btrace_thread): Use inferior_thread.
4883 (record_btrace_frame_sniffer)
4884 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4885 (get_thread_current_frame): Use scoped_restore_current_thread and
4886 switch_to_thread.
4887 (get_thread_current_frame): Use thread pointer directly.
4888 (record_btrace_replay_at_breakpoint): Use thread's inferior
4889 pointer directly.
4890 * record-full.c: Include "inferior.h".
4891 * regcache.c: Include "gdbthread.h".
4892 (get_thread_arch_regcache): Use the inferior's address space
4893 directly.
4894 (get_thread_regcache, registers_changed_thread): New.
4895 * regcache.h (get_thread_regcache(thread_info *thread)): New
4896 overload.
4897 (registers_changed_thread): New.
4898 (remote_target) <remote_detach_1>: Swap order of parameters.
4899 (remote_add_thread): <remote_add_thread>: Return the new thread.
4900 (get_remote_thread_info(ptid_t)): New overload.
4901 (remote_target::remote_notice_new_inferior): Use thread pointers
4902 directly.
4903 (remote_target::process_initial_stop_replies): Use
4904 thread_info::set_running.
4905 (remote_target::remote_detach_1, remote_target::detach)
4906 (extended_remote_target::detach): Adjust.
4907 * stack.c (frame_show_address): Use inferior_thread.
4908 * target-debug.h (target_debug_print_thread_info_pp): New.
4909 * target-delegates.c: Regenerate.
4910 * target.c (default_thread_address_space): Delete.
4911 (memory_xfer_partial_1): Use current_inferior.
4912 (target_detach): Use current_inferior.
4913 (target_thread_address_space): Delete.
4914 (generic_mourn_inferior): Use current_inferior.
4915 * target.h (struct target_ops) <thread_address_space>: Delete.
4916 (target_thread_address_space): Delete.
4917 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4918 pointers directly.
4919 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4920 thread pointer instead of a ptid_t. Adjust all callers.
4921 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4922 (first_thread_of_process): Delete, replaced by ...
4923 (first_thread_of_inferior): ... this new function. All callers
4924 adjusted.
4925 (any_thread_of_process): Rename to ...
4926 (any_thread_of_inferior): ... this, and take an inferior pointer.
4927 (any_live_thread_of_process): Rename to ...
4928 (any_live_thread_of_inferior): ... this, and take an inferior
4929 pointer.
4930 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4931 (value_in_thread_stack_temporaries)
4932 (get_last_thread_stack_temporary): Take a thread pointer instead
4933 of a ptid_t. Adjust all callers.
4934 (thread_info::set_running): New.
4935 (validate_registers_access): Use inferior_thread.
4936 (can_access_registers_ptid): Rename to ...
4937 (can_access_registers_thread): ... this, and take a thread
4938 pointer.
4939 (print_thread_info_1): Adjust to compare thread pointers instead
4940 of ptids.
4941 (switch_to_no_thread, switch_to_thread): Make extern.
4942 (scoped_restore_current_thread::~scoped_restore_current_thread):
4943 Use m_thread pointer directly.
4944 (scoped_restore_current_thread::scoped_restore_current_thread):
4945 Use inferior_thread.
4946 (thread_command): Use thread pointer directly.
4947 (thread_num_make_value_helper): Use inferior_thread.
4948 * top.c (execute_command): Use inferior_thread.
4949 * tui/tui-interp.c: Include "inferior.h".
4950 * varobj.c (varobj_create): Use inferior_thread.
4951 (value_of_root_1): Use find_thread_global_id instead of
4952 global_thread_id_to_ptid.
4953
4954 2018-06-21 Alan Hayward <alan.hayward@arm.com>
4955
4956 * regcache.c (readable_regcache::read_part): Avoid memcpy when
4957 possible.
4958 (regcache::write_part): Likewise.
4959 (readable_regcache::cooked_read_part): Update comment.
4960 (readable_regcache::cooked_write_part): Likewise.
4961 * regcache.h: (readable_regcache::read_part): Likewise.
4962 (regcache::write_part): Likewise.
4963
4964 2018-06-21 Richard Bunt <richard.bunt@arm.com>
4965 Dirk Schubert <dirk.schubert@arm.com>
4966
4967 * aarch64-linux-nat.c (post_attach): New.
4968 (aarch64_linux_nat_target::post_attach): Override post_attach to
4969 record the number of hardware debug registers.
4970
4971 2018-06-20 Tom Tromey <tom@tromey.com>
4972
4973 * python/py-param.c (add_setshow_generic): Make parameters const.
4974 (parmpy_init): Update.
4975
4976 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4977
4978 * regcache.h (regcache_cooked_read_ftype): Rename to...
4979 (register_read_ftype): ...this, change type to function_view.
4980 (class reg_buffer) <save>: Remove src parameter.
4981 (readonly_detached_regcache) <readonly_detached_regcache>: Make
4982 parameter non-const in first overload. Remove src parameter in
4983 second overload.
4984 * regcache.c (do_cooked_read): Remove.
4985 (readonly_detached_regcache::readonly_detached_regcache): Make
4986 parameter non-const, adjust call to other constructor.
4987 (reg_buffer::save): Remove src parameter.
4988 * frame.c (do_frame_register_read): Remove.
4989 (frame_save_as_regcache): Use lambda function.
4990 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
4991 parameter to ppu2spu_data *.
4992 (ppu2spu_sniffer): Use lambda function.
4993
4994 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
4995
4996 * record-full.c (record_full_target::insert_breakpoint): Remove
4997 "struct" keyword, add const.
4998
4999 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5000
5001 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
5002 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
5003 * configure.ac: Remove AC_PREREQ, add missing quoting.
5004 * gnulib/configure.ac: Modernize usage of
5005 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
5006 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
5007 (AUTOMAKE_VERSION): Bump to 1.15.1.
5008 * configure: Re-generate.
5009 * config.in: Re-generate.
5010 * aclocal.m4: Re-generate.
5011 * gnulib/aclocal.m4: Re-generate.
5012 * gnulib/config.in: Re-generate.
5013 * gnulib/configure: Re-generate.
5014 * gnulib/import/Makefile.in: Re-generate.
5015
5016 2018-06-19 Pedro Alves <palves@redhat.com>
5017
5018 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
5019 (lookup_minimal_symbol_by_pc_section): ... here with
5020 gdb_assert_not_reached added.
5021
5022 2018-06-19 Pedro Alves <palves@redhat.com>
5023
5024 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
5025 parameter with a block parameter. Compare location's block symbol
5026 with the frame's block instead of addresses.
5027 (skip_inline_frames): Pass the current block instead of the
5028 frame's address. Break out as soon as we determine the frame
5029 should not be skipped.
5030
5031 2018-06-18 Tom Tromey <tom@tromey.com>
5032
5033 * solib-aix.c (solib_aix_get_section_offsets): Return
5034 unique_xmalloc_ptr.
5035 (solib_aix_solib_create_inferior_hook): Update.
5036
5037 2018-06-18 Tom Tromey <tom@tromey.com>
5038
5039 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5040
5041 2018-06-18 Tom Tromey <tom@tromey.com>
5042
5043 * solib-frv.c (frv_relocate_main_executable): Use
5044 unique_xmalloc_ptr.
5045 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5046 unique_xmalloc_ptr.
5047
5048 2018-06-18 Tom Tromey <tom@tromey.com>
5049
5050 * objfiles.h (inhibit_section_map_updates): Update.
5051 (resume_section_map_updates, resume_section_map_updates_cleanup):
5052 Remove.
5053 * solib-svr4.c (svr4_handle_solib_event): Update.
5054 * objfiles.c (inhibit_section_map_updates): Return
5055 scoped_restore_tmpl<int>.
5056 (resume_section_map_updates, resume_section_map_updates_cleanup):
5057 Remove.
5058
5059 2018-06-18 Tom Tromey <tom@tromey.com>
5060
5061 * valprint.h (read_string): Update.
5062 * valprint.c (read_string): Change type of "buffer".
5063 (val_print_string): Update.
5064 * python/py-value.c (valpy_string): Update.
5065 * language.h (struct language_defn) <la_get_string>: Change
5066 type of "buffer".
5067 (default_get_string, c_get_string): Update.
5068 * language.c (default_get_string): Change type of "buffer".
5069 * guile/scm-value.c (gdbscm_value_to_string): Update.
5070 * c-lang.c (c_get_string): Change type of "buffer".
5071
5072 2018-06-18 Tom Tromey <tom@tromey.com>
5073
5074 * ser-mingw.c (struct pipe_state_destroyer): New.
5075 (pipe_state_up): New typedef.
5076 (cleanup_pipe_state): Remove.
5077 (pipe_windows_open): Use pipe_state_up. Don't release argv.
5078
5079 2018-06-18 Tom Tromey <tom@tromey.com>
5080
5081 * rust-lang.h (rust_yyerror): Don't declare.
5082 * rust-lang.c (rust_language_defn): Update.
5083 * rust-exp.y (yyerror): Now static.
5084 * parse.c (parse_exp_in_context_1): Update.
5085 * p-lang.h (p_yyerror): Don't declare.
5086 * p-lang.c (p_language_defn): Update.
5087 * p-exp.y (yyerror): Now static.
5088 * opencl-lang.c (opencl_language_defn): Update.
5089 * objc-lang.c (objc_language_defn): Update.
5090 * m2-lang.h (m2_yyerror): Don't declare.
5091 * m2-lang.c (m2_language_defn): Update.
5092 * m2-exp.y (yyerror): Now static.
5093 * language.h (struct language_defn) <la_error>: Remove.
5094 * language.c (unk_lang_error): Remove.
5095 (unknown_language_defn, auto_language_defn): Remove.
5096 * go-lang.h (go_yyerror): Don't declare.
5097 * go-lang.c (go_language_defn): Update.
5098 * go-exp.y (yyerror): Now static.
5099 * f-lang.h (f_yyerror): Don't declare.
5100 * f-lang.c (f_language_defn): Update.
5101 * f-exp.y (yyerror): Now static.
5102 * d-lang.h (d_yyerror): Don't declare.
5103 * d-lang.c (d_language_defn): Update.
5104 * d-exp.y (yyerror): Now static.
5105 * c-lang.h (c_yyerror): Don't declare.
5106 * c-lang.c (c_language_defn, cplus_language_defn)
5107 (asm_language_defn, minimal_language_defn): Update.
5108 * c-exp.y (yyerror): Now static.
5109 * ada-lang.h (ada_yyerror): Don't declare.
5110 * ada-lang.c (ada_language_defn): Update.
5111 * ada-exp.y (yyerror): Now static.
5112
5113 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5114
5115 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
5116 (store_sveregs_to_thread): Likewise.
5117 (aarch64_linux_fetch_inferior_registers): Check for SVE.
5118 (aarch64_linux_store_inferior_registers): Likewise.
5119 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
5120 function.
5121 (aarch64_sve_regs_copy_to_regcache): Likewise.
5122 (aarch64_sve_regs_copy_from_regcache): Likewise.
5123 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
5124 declaration.
5125 (aarch64_sve_regs_copy_to_regcache): Likewise.
5126 (aarch64_sve_regs_copy_from_regcache): Likewise.
5127 (sve_context): Structure from Linux headers.
5128 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
5129 (SVE_SIG_ZREG_SIZE): Likewise.
5130 (SVE_SIG_PREG_SIZE): Likewise.
5131 (SVE_SIG_FFR_SIZE): Likewise.
5132 (SVE_SIG_REGS_OFFSET): Likewise.
5133 (SVE_SIG_ZREGS_OFFSET): Likewise.
5134 (SVE_SIG_ZREG_OFFSET): Likewise.
5135 (SVE_SIG_ZREGS_SIZE): Likewise.
5136 (SVE_SIG_PREGS_OFFSET): Likewise.
5137 (SVE_SIG_PREG_OFFSET): Likewise.
5138 (SVE_SIG_PREGS_SIZE): Likewise.
5139 (SVE_SIG_FFR_OFFSET): Likewise.
5140 (SVE_SIG_REGS_SIZE): Likewise.
5141 (SVE_SIG_CONTEXT_SIZE): Likewise.
5142 (SVE_PT_REGS_MASK): Likewise.
5143 (SVE_PT_REGS_FPSIMD): Likewise.
5144 (SVE_PT_REGS_SVE): Likewise.
5145 (SVE_PT_VL_INHERIT): Likewise.
5146 (SVE_PT_VL_ONEXEC): Likewise.
5147 (SVE_PT_REGS_OFFSET): Likewise.
5148 (SVE_PT_FPSIMD_OFFSET): Likewise.
5149 (SVE_PT_FPSIMD_SIZE): Likewise.
5150 (SVE_PT_SVE_ZREG_SIZE): Likewise.
5151 (SVE_PT_SVE_PREG_SIZE): Likewise.
5152 (SVE_PT_SVE_FFR_SIZE): Likewise.
5153 (SVE_PT_SVE_FPSR_SIZE): Likewise.
5154 (SVE_PT_SVE_FPCR_SIZE): Likewise.
5155 (__SVE_SIG_TO_PT): Likewise.
5156 (SVE_PT_SVE_OFFSET): Likewise.
5157 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
5158 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
5159 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
5160 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
5161 (SVE_PT_SVE_PREG_OFFSET): Likewise.
5162 (SVE_PT_SVE_PREGS_SIZE): Likewise.
5163 (SVE_PT_SVE_FFR_OFFSET): Likewise.
5164 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
5165 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
5166 (SVE_PT_SVE_SIZE): Likewise.
5167 (SVE_PT_SIZE): Likewise.
5168 (HAS_SVE_STATE): New define.
5169
5170 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5171
5172 * nat/aarch64-sve-linux-sigcontext.h: New file.
5173 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
5174 new files.
5175 (SVE_VQ_MIN): Likewise.
5176 (SVE_VQ_MAX): Likewise.
5177 (SVE_VL_MIN): Likewise.
5178 (SVE_VL_MAX): Likewise.
5179 (SVE_NUM_ZREGS): Likewise.
5180 (SVE_NUM_PREGS): Likewise.
5181 (sve_vl_valid): Likewise.
5182 (struct user_sve_header): Likewise.
5183
5184 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
5185 Richard Bunt <Richard.Bunt@arm.com>
5186
5187 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
5188 was requested by GDB.
5189
5190 2018-06-15 Tom de Vries <tdevries@suse.de>
5191
5192 * MAINTAINERS (Write After Approval): Add Tom de Vries.
5193
5194 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
5195
5196 * gnulib/update-gnulib.sh: Print expected versions of
5197 autoconf/aclocal.
5198
5199 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
5200
5201 * arch-utils.c (default_type_align): Use type_length_units.
5202 * gdbtypes.c (type_align): Use type_length_units.
5203
5204 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5205
5206 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
5207 of 'define' command.
5208
5209 2018-06-14 Tom de Vries <tdevries@suse.de>
5210
5211 PR cli/22573
5212 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5213 get_no_prettyformat_print_options.
5214
5215 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
5216
5217 * sparc-nat.h: Include target.h.
5218 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
5219 <fetch_registers>: Remove this argument in function call.
5220 <store_registers>: Remove this argument in function call, remove
5221 extra semicolon.
5222 <low_forget_process>: Call sparc64_forget_process instead of
5223 sparc_forget_process.
5224
5225 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5226
5227 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5228 (procfs_target::make_corefile_notes): Adjust to new
5229 target_read_alloc return type.
5230
5231 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5232 Stephen Roberts <stephen.roberts@arm.com>
5233
5234 PR gdb/22882
5235 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5236 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5237 Move should_notify_stop local into more inner scope.
5238
5239 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5240 Stephen Roberts <stephen.roberts@arm.com>
5241
5242 PR gdb/22882
5243 * infrun.c (resume_1): Add call to mark_async_event_handler.
5244
5245 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5246
5247 * infrun.c (do_target_wait): Change old version of $pc printed.
5248
5249 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5250
5251 * dwarf2read.c (read_index_from_section): Rename to...
5252 (read_gdb_index_from_section): ... this, update all callers.
5253 (dwarf2_read_index): Rename to...
5254 (dwarf2_read_gdb_index): ... this, update all callers.
5255
5256 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5257
5258 * gdb/hppa-linux-nat.c
5259 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5260 hppa_linux_nat_target::fetch_registers.
5261
5262 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5263
5264 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5265 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5266 (AARCH64_DWARF_SVE_FFR): Likewise.
5267 (AARCH64_DWARF_SVE_P0): Likewise.
5268 (AARCH64_DWARF_SVE_Z0): Likewise.
5269
5270 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5271
5272 * common/common-regcache.h (raw_compare): New function.
5273 * regcache.c (regcache::raw_compare): Likewise.
5274 * regcache.h (regcache::raw_compare): New declaration.
5275
5276 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5277
5278 * common/common-regcache.h (reg_buffer_common): New structure.
5279 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5280 (reg_buffer::raw_supply): Likewise.
5281 (reg_buffer::raw_supply_integer): Likewise.
5282 (reg_buffer::raw_supply_zeroed): Likewise.
5283 (reg_buffer::raw_collect): Likewise.
5284 (reg_buffer::raw_collect_integer): Likewise.
5285 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5286 (reg_buffer::raw_supply): Likewise.
5287 (reg_buffer::raw_supply_integer): Likewise.
5288 (reg_buffer::raw_supply_zeroed): Likewise.
5289 (reg_buffer::raw_collect): Likewise.
5290 (reg_buffer::raw_collect_integer): Likewise.
5291
5292 2018-06-10 Tom Tromey <tom@tromey.com>
5293
5294 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5295 (class remote_state) <stop_reply_queue>: Now std::vector.
5296 (remote_state::~remote_state)
5297 (remote_target::stop_reply_queue_length): Update.
5298 (struct queue_iter_param, remove_child_of_pending_fork)
5299 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5300 (check_pending_event_prevents_wildcard_vcont_callback)
5301 (remove_stop_reply_for_inferior)
5302 (remove_stop_reply_of_remote_state)
5303 (remote_notif_remove_once_on_match)
5304 (stop_reply_match_ptid_and_ws)
5305 (remote_kill_child_of_pending_fork): Remove.
5306 (remote_target::remove_new_fork_children)
5307 (remote_target::check_pending_events_prevent_wildcard_vcont)
5308 (remote_target::discard_pending_stop_replies)
5309 (remote_target::discard_pending_stop_replies_in_queue)
5310 (remote_target::remote_notif_remove_queued_reply)
5311 (remote_target::queued_stop_reply)
5312 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5313 (remote_target::wait, remote_target::kill_new_fork_children)
5314 (remote_target::async): Update.
5315
5316 2018-06-10 Tom Tromey <tom@tromey.com>
5317
5318 * record-full.c (record_full_arch_list_cleanups): Remove.
5319 (record_full_message): Use try/catch.
5320 (record_full_wait_cleanups): Remove.
5321 (record_full_wait_1): Use try/catch.
5322 (record_full_restore): Likewise.
5323
5324 2018-06-10 Tom Tromey <tom@tromey.com>
5325
5326 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5327 declare VEC. Add constructor.
5328 <in_target_beneath>: Now bool.
5329 (record_full_breakpoints): Now a std::vector, static.
5330 (record_full_sync_record_breakpoints)
5331 (record_full_init_record_breakpoints)
5332 (record_full_target::insert_breakpoint)
5333 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5334
5335 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5336
5337 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5338 * serial.c (serial_interface_lookup): Remove struct keyword.
5339
5340 2018-06-10 Tom Tromey <tom@tromey.com>
5341
5342 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5343 method.
5344 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5345 a method.
5346 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5347 method.
5348 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5349 "beneath" as a method.
5350 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5351 Use "beneath" as a method.
5352
5353 2018-06-10 Tom Tromey <tom@tromey.com>
5354
5355 * tracefile.c (struct trace_file_writer_deleter): New.
5356 <operator()>: Rename from trace_file_writer_xfree.
5357 (trace_file_writer_up): New typedef.
5358 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5359
5360 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5361
5362 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5363 <m_registers, m_register_status>: Change type to
5364 std::unique_ptr.
5365 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5366 XCNEWVEC.
5367
5368 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5369
5370 * common/common-regcache.h (enum register_status): Add
5371 underlying type "signed char".
5372 * regcache.h (reg_buffer) <m_register_status>: Change type to
5373 register_status *.
5374 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5375 register_status instead of signed char.
5376 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5377 (reg_buffer::get_register_status): Remove cast.
5378 (readable_regcache::raw_read): Remove cast.
5379 (readable_regcache::cooked_read): Remove cast.
5380
5381 2018-06-09 Tom Tromey <tom@tromey.com>
5382
5383 * source.c (reverse_search_command, forward_search_command): Use
5384 scoped_fd.
5385
5386 2018-06-09 Tom Tromey <tom@tromey.com>
5387
5388 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5389 (serial_ops_list): Now static, std::vector.
5390 (serial_interface_lookup, serial_add_interface): Update.
5391
5392 2018-06-09 Tom Tromey <tom@tromey.com>
5393
5394 * dwarf2read.c (process_cu_includes): Update.
5395 (process_full_comp_unit): Update.
5396 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5397 std::vector.
5398
5399 2018-06-08 Paul Koning <paul_koning@dell.com>
5400
5401 PR gdb/23252
5402
5403 * python/python.c (do_start_initialization):
5404 Avoid call to internal Python API.
5405 (init__gdb_module): New function.
5406
5407 2018-06-08 Gary Benson <gbenson@redhat.com>
5408
5409 * linux-thread-db.c (valprint.h): New include.
5410 (struct check_thread_db_info): New structure.
5411 (check_thread_db_on_load, tdb_testinfo): New static globals.
5412 (check_thread_db, check_thread_db_callback): New functions.
5413 (try_thread_db_load_1): Run integrity checks if requested.
5414 (maintenance_check_libthread_db): New function.
5415 (_initialize_thread_db): Register "maint check libthread-db"
5416 and "maint set/show check-libthread-db".
5417 * NEWS: Mention the above new commands.
5418
5419 2018-06-08 Tom Tromey <tom@tromey.com>
5420
5421 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5422 now a method.
5423
5424 2018-06-08 Tom Tromey <tom@tromey.com>
5425
5426 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5427
5428 2018-06-08 Tom Tromey <tom@tromey.com>
5429
5430 * common/btrace-common.h (struct btrace_data): Add constructor,
5431 destructor, move assignment operator.
5432 <empty, clear, fini>: New methods.
5433 <format>: Initialize.
5434 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5435 (btrace_data_empty): Don't declare.
5436 * common/btrace-common.c (btrace_data_init): Remove.
5437 (btrace_data::fini): Rename from btrace_data_fini.
5438 (btrace_data::empty): Rename from btrace_data_empty.
5439 (btrace_data::clear): Rename from btrace_data_clear. Return
5440 bool.
5441 * btrace.h (make_cleanup_btrace_data): Don't declare.
5442 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5443 (parse_xml_btrace): Update.
5444 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5445 (maint_btrace_clear_packet_history_cmd): Update.
5446
5447 2018-06-07 Pedro Alves <palves@redhat.com>
5448
5449 * target.h (target_ops) <beneath>: Now a method. All references
5450 updated.
5451 (class target_stack): New.
5452 * target.c (g_target_stack): New.
5453 (g_current_top_target): Delete.
5454 (current_top_target): Get the top target out of g_target_stack.
5455 (target_stack::push, target_stack::unpush): New.
5456 (push_target, unpush_target): Reimplement.
5457 (target_is_pushed): Reimplement in terms of g_target_stack.
5458 (target_ops::beneath, target_stack::find_beneath): New.
5459
5460 2018-06-07 Pedro Alves <palves@redhat.com>
5461
5462 * target.h (find_target_beneath): Delete declaration.
5463 * target.c (find_target_beneath): Delete definition.
5464 * aix-thread.c: All callers of find_target_beneath adjusted to
5465 call target_ops::beneath instead.
5466 * bsd-uthread.c: Likewise.
5467 * linux-thread-db.c: Likewise.
5468 * ravenscar-thread.c: Likewise.
5469 * sol-thread.c: Likewise.
5470 * spu-multiarch.c: Likewise.
5471
5472 2018-06-07 Pedro Alves <palves@redhat.com>
5473
5474 * target.h (target_ops) <beneath>: Now a method. All references
5475 updated.
5476 (target_ops) <m_beneath>: New.
5477 * target.c (target_ops::beneath): New.
5478 * corelow.c: Adjust all references to target_ops::beneath.
5479 * linux-thread-db.c: Likewise.
5480 * make-target-delegates: Likewise.
5481 * record-btrace.c: Likewise.
5482 * record-full.c: Likewise.
5483 * remote.c: Likewise.
5484 * target.c: Likewise.
5485 * target-delegates.c: Regenerate.
5486
5487 2018-06-07 Pedro Alves <palves@redhat.com>
5488
5489 * target.h (target_stack): Delete.
5490 (current_top_target): Declare function.
5491 * target.c (target_stack): Delete.
5492 (g_current_top_target): New.
5493 (current_top_target): New function.
5494 * auxv.c: Use current_top_target instead of target_stack
5495 throughout.
5496 * avr-tdep.c: Likewise.
5497 * breakpoint.c: Likewise.
5498 * corefile.c: Likewise.
5499 * elfread.c: Likewise.
5500 * eval.c: Likewise.
5501 * exceptions.c: Likewise.
5502 * frame.c: Likewise.
5503 * gdbarch-selftests.c: Likewise.
5504 * gnu-v3-abi.c: Likewise.
5505 * ia64-tdep.c: Likewise.
5506 * ia64-vms-tdep.c: Likewise.
5507 * infcall.c: Likewise.
5508 * infcmd.c: Likewise.
5509 * infrun.c: Likewise.
5510 * linespec.c: Likewise.
5511 * linux-tdep.c: Likewise.
5512 * minsyms.c: Likewise.
5513 * ppc-linux-nat.c: Likewise.
5514 * ppc-linux-tdep.c: Likewise.
5515 * procfs.c: Likewise.
5516 * regcache.c: Likewise.
5517 * remote.c: Likewise.
5518 * rs6000-tdep.c: Likewise.
5519 * s390-linux-nat.c: Likewise.
5520 * s390-tdep.c: Likewise.
5521 * solib-aix.c: Likewise.
5522 * solib-darwin.c: Likewise.
5523 * solib-dsbt.c: Likewise.
5524 * solib-spu.c: Likewise.
5525 * solib-svr4.c: Likewise.
5526 * solib-target.c: Likewise.
5527 * sparc-tdep.c: Likewise.
5528 * sparc64-tdep.c: Likewise.
5529 * spu-tdep.c: Likewise.
5530 * symfile.c: Likewise.
5531 * symtab.c: Likewise.
5532 * target-descriptions.c: Likewise.
5533 * target-memory.c: Likewise.
5534 * target.c: Likewise.
5535 * target.h: Likewise.
5536 * tracefile-tfile.c: Likewise.
5537 * tracepoint.c: Likewise.
5538 * valops.c: Likewise.
5539 * valprint.c: Likewise.
5540 * value.c: Likewise.
5541 * windows-tdep.c: Likewise.
5542 * mi/mi-main.c: Likewise.
5543
5544 2018-06-07 Tom Tromey <tom@tromey.com>
5545
5546 * valprint.h (build_address_symbolic): Declare.
5547 * printcmd.c (print_address_symbolic): Update.
5548 (build_address_symbolic): Change "name" and "filename" to
5549 std::string.
5550 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5551 Update.
5552 * defs.h (build_address_symbolic): Remove declaration.
5553
5554 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5555
5556 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5557 (aarch64_vnv_type): Add function.
5558 (aarch64_pseudo_register_name): Add V regs for SVE.
5559 (aarch64_pseudo_register_type): Likewise.
5560 (aarch64_pseudo_register_reggroup_p): Likewise.
5561 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5562 (aarch64_pseudo_read_value): Add V regs for SVE.
5563 (aarch64_pseudo_write_2): Use V0 offset for SVE
5564 (aarch64_pseudo_write): Add V regs for SVE.
5565 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5566
5567 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5568
5569 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5570 (sve_vl_from_vq): Likewise.
5571
5572 2018-06-05 Tom Tromey <tom@tromey.com>
5573
5574 * cli/cli-cmds.c (show_version): Update.
5575 * top.c (print_gdb_version): Add "interactive" parameter.
5576 Update.
5577 * main.c (captured_main_1): Update.
5578 * top.h (print_gdb_version): Add "interactive" parameter and a
5579 comment.
5580
5581 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5582
5583 * common/enum-flags.h: Add trailing semicolon to example in
5584 comment.
5585
5586 2018-06-05 Tom Tromey <tom@tromey.com>
5587
5588 PR cli/12326:
5589 * NEWS: Add entry about pager.
5590 * utils.c (pagination_disabled_for_command): New global.
5591 (prompt_for_continue): Allow "c" response to prompt.
5592 (reinitialize_more_filter): Clear
5593 pagination_disabled_for_command.
5594 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5595
5596 2018-06-04 Tom Tromey <tom@tromey.com>
5597
5598 * ada-lang.h (ada_lookup_symbol_list): Update.
5599 * ada-lang.c (resolve_subexp): Update.
5600 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5601 parameter.
5602 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5603 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5604 results parameter to std::vector.
5605 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5606 Update.
5607 * ada-exp.y (block_lookup): Update.
5608 (select_possible_type_sym): Change type of syms. Remove nsyms
5609 parameter.
5610 (write_var_or_type, write_name_assoc): Update.
5611
5612 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5613
5614 * windows-nat.c (windows_nat_target::xfer_partial): Return
5615 TARGET_XFER_E_IO if we need to delegate to the target beneath
5616 but BENEATH is NULL.
5617
5618 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5619
5620 * Makefile.in (config.status): Add configure.nat as a
5621 dependency.
5622
5623 2018-06-04 Tom Tromey <tom@tromey.com>
5624
5625 * cp-name-parser.y (cpname_state): Add method declarations.
5626 (HANDLE_QUAL): Update.
5627 (cpname_state::d_grab, cpname_state::fill_comp)
5628 (cpname_state::make_operator, cpname_state::make_dtor)
5629 (cpname_state::make_builtin_type, cpname_state::make_name)
5630 (cpname_state::d_qualify, cpname_state::d_int_type)
5631 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5632 (%union): Move earlier.
5633
5634 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5635
5636 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5637
5638 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5639
5640 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5641 (aarch64_pseudo_write_1): Likewise.
5642 (aarch64_pseudo_read_value): Use helper.
5643 (aarch64_pseudo_write): Likewise.
5644
5645 2018-06-04 Pedro Alves <palves@redhat.com>
5646
5647 * darwin-nat.c (darwin_ops): Delete.
5648 (darwin_attach_pid): Use get_native_target.
5649
5650 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5651
5652 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5653 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5654
5655 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5656
5657 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5658 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5659 (aarch64_gdbarch_init): Check for SVE.
5660 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5661
5662 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5663
5664 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5665 * aarch64-tdep.h (aarch64_read_description): Likewise.
5666 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5667 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5668 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5669 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5670 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5671
5672 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5673
5674 * value.c (value_fetch_lazy_bitfield): New.
5675 (value_fetch_lazy_memory): New.
5676 (value_fetch_lazy_register): New.
5677 (value_fetch_lazy): Factor out to smaller functions.
5678
5679 2018-06-01 Tom Tromey <tom@tromey.com>
5680
5681 * cp-name-parser.y (backslashable, represented): Now const.
5682
5683 2018-06-01 Tom Tromey <tom@tromey.com>
5684
5685 * cp-name-parser.y: Include parser-defs.h.
5686 (parser_fprintf): Remove declaration.
5687
5688 2018-06-01 Tom Tromey <tom@tromey.com>
5689
5690 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5691 %parse-param.
5692 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5693 (global_result): Remove globals.
5694 (struct cpname_state): New.
5695 (yyparse): Don't declare.
5696 (yylex, yyerror): Move declarations after %union.
5697 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5698 (make_name): Add state parameter.
5699 Update all callers.
5700 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5701 parameter.
5702 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5703 Update.
5704 (yylex): Add lvalp, state parameters.
5705 (yyerror): Add state parameter.
5706 (cp_demangled_name_to_comp): Update.
5707
5708 2018-06-01 Tom Tromey <tom@tromey.com>
5709
5710 * cp-name-parser.y (parser_fprintf): Declare.
5711 (GDB_YY_REMAP_PREFIX): Define.
5712 Include yy-remap.h. Don't redefine yy* identifiers.
5713
5714 2018-06-01 Tom Tromey <tom@tromey.com>
5715
5716 * python/py-type.c (typy_legacy_template_argument): Update.
5717 * cp-support.h (cp_demangled_name_to_comp): Update.
5718 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5719 parameter to be a "std::string *".
5720 (main): Update.
5721
5722 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5723
5724 * ada-lex.l: Include "diagnostics.h" instead of
5725 "common/diagnostics.h".
5726 * unittests/environ-selftests.c: Likewise.
5727 * common/diagnostics.h: Moved to ../include.
5728
5729 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5730
5731 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5732 to language_mode_manual while calling breakpoint_re_set_one.
5733
5734 2018-06-01 Tom Tromey <tom@tromey.com>
5735
5736 * valops.c (value_cast_structs, destructor_name_p): Update.
5737 * symtab.c (gdb_mangle_name): Update.
5738 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5739 Update.
5740 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5741 (pascal_object_print_value_fields, pascal_object_print_value):
5742 Update.
5743 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5744 * linespec.c (find_methods): Update.
5745 * gdbtypes.h (type_name_no_tag): Remove.
5746 (type_name_or_error): Rename from type_name_no_tag_or_error.
5747 * gdbtypes.c (type_name_no_tag): Remove.
5748 (type_name_or_error): Rename from type_name_no_tag_or_error.
5749 (lookup_struct_elt_type, check_typedef): Update.
5750 * expprint.c (print_subexp_standard): Update.
5751 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5752 * d-namespace.c (d_lookup_nested_symbol): Update.
5753 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5754 (cp_print_class_member): Update.
5755 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5756 * completer.c (add_struct_fields): Update.
5757 * c-typeprint.c (cp_type_print_derivation_info)
5758 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5759 Update.
5760 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5761 (ada_prefer_type, ada_is_exception_sym): Update.
5762
5763 2018-06-01 Tom Tromey <tom@tromey.com>
5764
5765 * valops.c (enum_constant_from_type, value_namespace_elt)
5766 (value_maybe_namespace_elt): Update.
5767 * valarith.c (find_size_for_pointer_math): Update.
5768 * target-descriptions.c (make_gdb_type): Update.
5769 * symmisc.c (print_symbol): Update.
5770 * stabsread.c (define_symbol, read_type)
5771 (complain_about_struct_wipeout, add_undefined_type)
5772 (cleanup_undefined_types_1): Update.
5773 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5774 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5775 (rust_internal_print_type, rust_composite_type)
5776 (rust_evaluate_funcall, rust_evaluate_subexp)
5777 (rust_inclusive_range_type_p): Update.
5778 * python/py-type.c (typy_get_tag): Update.
5779 * p-typeprint.c (pascal_type_print_base): Update.
5780 * mdebugread.c (parse_symbol, parse_type): Update.
5781 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5782 Update.
5783 * guile/scm-type.c (gdbscm_type_tag): Update.
5784 * go-lang.c (sixg_string_p): Update.
5785 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5786 Update.
5787 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5788 (TYPE_TAG_NAME): Remove.
5789 * gdbtypes.c (type_name_no_tag): Simplify.
5790 (check_typedef, check_types_equal, recursive_dump_type)
5791 (copy_type_recursive, arch_composite_type): Update.
5792 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5793 in summary mode when needed.
5794 * eval.c (evaluate_funcall): Update.
5795 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5796 (process_structure_scope, read_enumeration_type)
5797 (read_namespace_type, read_module_type, determine_prefix): Update.
5798 * cp-support.c (inspect_type): Update.
5799 * coffread.c (process_coff_symbol, decode_base_type): Update.
5800 * c-varobj.c (c_is_path_expr_parent): Update.
5801 * c-typeprint.c (c_type_print_base_struct_union): Update.
5802 (c_type_print_base_1): Update. Print struct/class/union/enum in
5803 summary when using C language.
5804 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5805 (gen_maybe_namespace_elt): Update.
5806 * ada-lang.c (ada_type_name): Simplify.
5807 (empty_record, ada_template_to_fixed_record_type_1)
5808 (template_to_static_fixed_type)
5809 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5810
5811 2018-06-01 Tom Tromey <tom@tromey.com>
5812
5813 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5814 c_print_type.
5815 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5816 (c_print_type): Update.
5817 (c_print_type): New overload.
5818 (c_type_print_varspec_prefix, c_type_print_args)
5819 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5820 (c_type_print_base_struct_union, c_type_print_base_1)
5821 (cp_type_print_method_args): Add "language" parameter.
5822 (c_type_print_base): Update.
5823 * c-lang.h (c_print_type): Add new overload.
5824
5825 2018-06-01 Tom Tromey <tom@tromey.com>
5826
5827 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5828 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5829
5830 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5831
5832 * aarch64-tdep.c (aarch64_sve_register_names): New const
5833 var.
5834 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5835 (AARCH64_SVE_Z_REGS_NUM): New define.
5836 (AARCH64_SVE_P_REGS_NUM): Likewise.
5837 (AARCH64_SVE_NUM_REGS): Likewise.
5838
5839 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5840
5841 * nat/linux-ptrace.h [__alpha__]
5842 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5843 definitions.
5844
5845 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5846
5847 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5848 the endianness selected.
5849 * NEWS: Document `set endian auto' mode operation update.
5850
5851 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5852
5853 * Makefile.in: Add new header.
5854 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5855 (sve_vl_from_vg): Likewise.
5856 (sve_vq_from_vl): Likewise.
5857 (sve_vl_from_vq): Likewise.
5858 (sve_vq_from_vg): Likewise.
5859 (sve_vg_from_vq): Likewise.
5860 * configure.nat: Add new c file.
5861 * nat/aarch64-sve-linux-ptrace.c: New file.
5862 * nat/aarch64-sve-linux-ptrace.h: New file.
5863
5864 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5865
5866 * aarch64-linux-nat.c (aarch64_linux_read_description):
5867 Add parmeter zero.
5868 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5869 Likewise.
5870 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5871 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5872 (aarch64_gdbarch_init): Add parmeter zero.
5873 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5874 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5875 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5876 parmeter.
5877 * doc/gdb.texinfo: Describe SVE feature
5878 * features/aarch64-sve.c: New file.
5879
5880 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5881
5882 PR gdb/23210
5883 * gdbarch.sh (significant_addr_bit): Default to zero when
5884 not set by target architecture.
5885 * gdbarch.c: Re-generated.
5886 * utils.c (address_significant): Update.
5887
5888 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5889
5890 * stack.c (func_command): Remove trailing newline in call to error.
5891
5892 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5893
5894 * regcache.h (regcache_raw_collect): Remove, update callers to
5895 use regcache::raw_collect.
5896 * regcache.c (regcache_raw_collect): Remove.
5897
5898 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5899
5900 * regcache.h (regcache_raw_supply): Remove, update callers to
5901 use detached_regcache::raw_supply.
5902 * regcache.c (regcache_raw_supply): Remove.
5903
5904 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5905
5906 * regcache.h (regcache_cooked_write_part): Remove, update
5907 callers to use regcache::cooked_write_part.
5908 * regcache.c (regcache_cooked_write_part): Remove.
5909
5910 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5911
5912 * regcache.h (regcache_cooked_read_part): Remove, update callers
5913 to use readable_regcache::cooked_read_part.
5914 * regcache.c (regcache_cooked_read_part): Remove.
5915
5916 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5917
5918 * regcache.h (regcache_cooked_read_value): Remove, update
5919 callers to use readable_regcache::cooked_read_value.
5920 * regcache.c (regcache_cooked_read_value): Remove.
5921
5922 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5923
5924 * regcache.h (regcache_cooked_write): Remove, update callers to
5925 use regcache::cooked_write.
5926 * regcache.c (regcache_cooked_write): Remove.
5927
5928 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5929
5930 * regcache.h (regcache_invalidate): Remove, update callers to
5931 use detached_regcache::invalidate instead.
5932 * regcache.c (regcache_invalidate): Remove.
5933
5934 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5935
5936 * regcache.h (regcache_raw_write_part): Remove, update callers
5937 to use regcache::raw_write_part instead.
5938 * regcache.c (regcache_raw_write_part): Remove.
5939
5940 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5941
5942 * regcache.h (regcache_raw_read_part): Remove, update callers to
5943 use readable_regcache::raw_read_part instead.
5944 * regcache.c (regcache_raw_read_part): Remove.
5945
5946 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5947
5948 * regcache.h (regcache_cooked_read): Remove, update callers to
5949 use readable_regcache::cooked_read instead.
5950 * regcache.c (regcache_cooked_read): Remove.
5951
5952 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5953
5954 * regcache.h (regcache_raw_write): Remove, update callers to use
5955 regcache::raw_write instead.
5956 * regcache.c (regcache_raw_write): Remove.
5957
5958 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5959
5960 * regcache.h (regcache_raw_read): Remove, update callers to use
5961 readable_regcache::raw_read instead.
5962 * regcache.c (regcache_raw_read): Remove.
5963
5964 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5965
5966 * regcache.h (regcache_raw_update): Remove, update callers to
5967 use readable_regcache::raw_update instead.
5968 * regcache.c (regcache_raw_update): Remove.
5969
5970 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5971
5972 * regcache.h (regcache_register_status): Remove, update callers
5973 to use reg_buffer::get_register_status directly instead.
5974 * regcache.c (regcache_register_status): Remove.
5975
5976 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5977
5978 * regcache.h (regcache_get_ptid): Remove, update all callers to
5979 call regcache::ptid instead.
5980 * regcache.c (regcache_get_ptid): Remove.
5981
5982 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5983
5984 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
5985
5986 2018-05-30 Pedro Alves <palves@redhat.com>
5987
5988 * common/common-exceptions.h (exception_rethrow): Use
5989 ATTRIBUTE_NORETURN.
5990
5991 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
5992
5993 * breakpoint.c (print_solib_event, check_status_catch_solib):
5994 Remove struct keyword in range-based for loops.
5995 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
5996 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
5997 Likewise.
5998 * linespec.c (find_superclass_methods, search_minsyms_for_name):
5999 Likewise.
6000 * symfile.c (addr_info_make_relative): Likewise.
6001 * thread.c (value_in_thread_stack_temporaries): Likewise.
6002
6003 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
6004
6005 PR gdb/16841
6006 * valops.c (value_struct_elt_for_reference): Call check_typedef on
6007 aggregate type to get its real type before accessing it.
6008
6009 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
6010
6011 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
6012 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
6013 * coff-pe-read.c (add_pe_forwarded_sym): Replace
6014 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
6015 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
6016 * jit.c (jit_breakpoint_re_set_internal): Likewise.
6017 * printcmd.c (info_address_command): Likewise.
6018
6019 2018-05-29 Tom Tromey <tom@tromey.com>
6020
6021 * windows-nat.c (handle_exception): Update fall-through comment.
6022
6023 2018-05-29 Tom Tromey <tom@tromey.com>
6024
6025 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
6026 (struct program_space) <added_solibs>: Now a std::vector.
6027 * breakpoint.c (print_solib_event): Update.
6028 (check_status_catch_solib): Update.
6029 * progspace.c (clear_program_space_solib_cache): Update.
6030 * solib.c (update_solib_list): Update.
6031
6032 2018-05-29 Tom Tromey <tom@tromey.com>
6033
6034 * python/py-type.c (typy_richcompare): Update.
6035 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
6036 * gdbtypes.h (types_deeply_equal): Return bool.
6037 (types_equal): Likewise.
6038 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6039 declare VEC.
6040 (check_types_equal): Change worklist to std::vector. Return
6041 bool.
6042 (struct type_equality_entry): Add constructor.
6043 (compare_maybe_null_strings): Return bool.
6044 (check_types_worklist): Return bool. Change worklist to
6045 std::vector.
6046 (types_deeply_equal): Use std::vector.
6047 (types_equal): Return bool.
6048 (compare_maybe_null_strings): Simplify.
6049
6050 2018-05-29 Tom Tromey <tom@tromey.com>
6051
6052 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6053
6054 2018-05-29 Tom Tromey <tom@tromey.com>
6055
6056 * objc-lang.h: Don't include cp-support.h.
6057 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6058 declare VEC.
6059
6060 2018-05-27 Tom Tromey <tom@tromey.com>
6061
6062 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6063
6064 2018-05-25 Tom Tromey <tom@tromey.com>
6065
6066 * value.c (value::location): Initialize.
6067
6068 2018-05-25 Tom Tromey <tom@tromey.com>
6069
6070 * dbxread.c (init_bincl_list): Remove.
6071 (bincl_list): Now a std::vector.
6072 (bincls_allocated, next_bincl): Remove.
6073 (free_bincl_list, do_free_bincl_list_cleanup)
6074 (make_cleanup_free_bincl_list): Remove.
6075 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
6076 unique_xmalloc_ptr.
6077 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
6078 (struct header_file_location): Add constructor.
6079 (add_bincl_to_list): Remove.
6080
6081 2018-05-25 Tom Tromey <tom@tromey.com>
6082
6083 * tui/tui.c (tui_enable): Update.
6084 * mi/mi-interp.c (mi_interp::init): Update.
6085 * interps.h (class interp) <name>: New method.
6086 <m_name>: Rename from name.
6087 (~scoped_restore_interp): Update.
6088 * interps.c (interp::interp): Update.
6089 (interp_add, interp_set, interp_lookup_existing)
6090 (current_interp_named_p): Update.
6091
6092 2018-05-25 Tom Tromey <tom@tromey.com>
6093
6094 * interps.c (interp_name): Remove.
6095 * mi/mi-interp.c (mi_interp::init): Update.
6096 * interps.h (interp_name): Remove.
6097 (~scoped_restore_interp): Update.
6098 * tui/tui.c (tui_enable): Update.
6099
6100 2018-05-25 Tom Tromey <tom@tromey.com>
6101
6102 * utils.c (fputs_maybe_filtered): Update.
6103 * linespec.c (decode_line_full): Update.
6104 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
6105 (mi_print_breakpoint_for_event, mi_solib_loaded)
6106 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6107 (mi_user_selected_context_changed): Update.
6108 * mi/mi-main.c (mi_execute_command): Update.
6109 * cli/cli-script.c (execute_control_command): Update.
6110 * python/python.c (execute_gdb_command): Update.
6111 * solib.c (info_sharedlibrary_command): Update.
6112 * interps.c (interp_ui_out): Remove.
6113 * interps.h (interp_ui_out): Remove.
6114
6115 2018-05-25 Tom Tromey <tom@tromey.com>
6116
6117 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
6118 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
6119 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
6120
6121 2018-05-25 Tom Tromey <tom@tromey.com>
6122
6123 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
6124 * interps.c (interp_exec): Use scoped_restore.
6125
6126 2018-05-25 Tom Tromey <tom@tromey.com>
6127
6128 * remote.c (remote_target::remote_file_get): Use
6129 gdb::byte_vector.
6130 (remote_target::remote_file_put): Likewise.
6131
6132 2018-05-25 Tom Tromey <tom@tromey.com>
6133
6134 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
6135 a std::string.
6136 (get_pe_section_index, add_pe_exported_sym): Update.
6137 (read_pe_exported_syms): Use gdb::def_vector.
6138
6139 2018-05-25 Tom Tromey <tom@tromey.com>
6140
6141 * frame.c (remove_prev_frame): Remove.
6142 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
6143
6144 2018-05-25 Maciej W. Rozycki <macro@mips.com>
6145
6146 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
6147 Remove prototypes.
6148 * mips-linux-nat.c (supply_fpregset): Always call
6149 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
6150 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
6151 `mips_fill_fpregset'.
6152 * mips-linux-tdep.c (mips_supply_fpregset)
6153 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
6154 (mips_fill_fpregset_wrapper): Remove functions.
6155 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
6156 (mips_linux_fpregset): Remove variable.
6157 (mips_linux_iterate_over_regset_sections): Use
6158 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
6159 (mips_linux_o32_sigframe_init): Remove comment.
6160
6161 2018-05-25 Pedro Alves <palves@redhat.com>
6162
6163 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
6164 (struct readahead_cache, struct packet_reg, struct
6165 remote_arch_state, class remote_state): Move higher up in the
6166 file.
6167 (remote_target::m_remote_state): Now an object instead of a pointer.
6168 (remote_target::get_remote_state): Adjust.
6169
6170 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6171
6172 * stack.c (select_and_print_frame): Delete.
6173 (struct function_bounds): Move struct within function.
6174 (func_command): Most content moved into new function
6175 find_frame_for_function, use new function, print result, add
6176 function comment.
6177 (find_frame_for_function): New function, now returns a result.
6178
6179 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6180
6181 * stack.c (iterate_over_block_arg_vars): Fix comment.
6182 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
6183
6184 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6185
6186 PR gdb/23203
6187 * frame.c
6188 (scoped_restore_selected_frame::scoped_restore_selected_frame):
6189 Define.
6190 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
6191 Define.
6192 * frame.h (class scoped_restore_selected_frame): New class.
6193 * stack.c (print_frame_local_vars): Remove catching and rethrowing
6194 of any exception, use scoped_restore_selected_frame to restore the
6195 frame instead.
6196
6197 2018-05-24 Pedro Alves <palves@redhat.com>
6198
6199 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
6200 override.
6201
6202 2018-05-23 Tom Tromey <tom@tromey.com>
6203
6204 * complaints.c (struct complaints): Remove.
6205 (symfile_complaint_book): Remove.
6206 (series): New global.
6207 (complaint_internal): Update.
6208 (clear_complaints): Update.
6209
6210 2018-05-23 Tom Tromey <tom@tromey.com>
6211
6212 * complaints.c (counters): New global.
6213 (struct complain): Remove.
6214 (struct complaints) <root>: Remove.
6215 (complaint_sentinel): Remove.
6216 (symfile_complaint_book): Update.
6217 (find_complaint) Remove.
6218 (complaint_internal, clear_complaints): Update.
6219
6220 2018-05-23 Tom Tromey <tom@tromey.com>
6221
6222 * complaints.c (struct complain) <file, line>: Remove.
6223 (find_complaint): Remove file, line parameters.
6224 (complaint_internal): Update.
6225
6226 2018-05-23 Tom Tromey <tom@tromey.com>
6227
6228 * complaints.c (vcomplaint): Remove.
6229 (complaint_internal) Merge in contents of vcomplaint.
6230
6231 2018-05-23 Tom Tromey <tom@tromey.com>
6232
6233 * complaints.c (struct complaints) <explanation>: Remove.
6234 (symfile_explanations): Remove.
6235 (symfile_complaint_book): Update.
6236 (vcomplaint): Update.
6237 (struct explanation): Remove.
6238
6239 2018-05-23 Tom Tromey <tom@tromey.com>
6240
6241 * complaints.c (symfile_complaints): Remove.
6242 (complaint_internal): Remove "complaints" parameter.
6243 (clear_complaints, vcomplaint): Remove "c" parameter.
6244 (get_complaints): Remove.
6245 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6246 (dwarf2_debug_line_missing_file_complaint)
6247 (dwarf2_debug_line_missing_end_sequence_complaint)
6248 (dwarf2_complex_location_expr_complaint)
6249 (dwarf2_const_value_length_mismatch_complaint)
6250 (dwarf2_section_buffer_overflow_complaint)
6251 (dwarf2_macro_malformed_definition_complaint)
6252 (dwarf2_invalid_attrib_class_complaint)
6253 (create_addrmap_from_index, dw2_symtab_iter_next)
6254 (dw2_expand_marked_cus)
6255 (dw2_debug_names_iterator::find_vec_in_debug_names)
6256 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6257 (create_debug_type_hash_table, init_cutu_and_read_dies)
6258 (partial_die_parent_scope, add_partial_enumeration)
6259 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6260 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6261 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6262 (create_cus_hash_table, create_dwp_hash_table)
6263 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6264 (dwarf2_rnglists_process, dwarf2_ranges_process)
6265 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6266 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6267 (handle_struct_member_die, process_structure_scope)
6268 (read_array_type, read_common_block, read_module_type)
6269 (read_tag_pointer_type, read_typedef, read_base_type)
6270 (read_subrange_type, load_partial_dies, partial_die_info::read)
6271 (partial_die_info::read, partial_die_info::read)
6272 (partial_die_info::read, read_checked_initial_length_and_offset)
6273 (dwarf2_string_attr, read_formatted_entries)
6274 (dwarf_decode_line_header)
6275 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6276 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6277 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6278 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6279 (get_signatured_type, get_DW_AT_signature_type)
6280 (decode_locdesc, file_file_name, consume_improper_spaces)
6281 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6282 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6283 (dwarf2_symbol_mark_computed, set_die_type)
6284 (read_attribute_value): Update.
6285 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6286 Update.
6287 * dbxread.c (unknown_symtype_complaint)
6288 (lbrac_mismatch_complaint, repeated_header_complaint)
6289 (set_namestring, function_outside_compilation_unit_complaint)
6290 (read_dbx_symtab, process_one_symbol): Update.
6291 * gdbtypes.c (stub_noname_complaint): Update.
6292 * windows-nat.c (handle_unload_dll): Update.
6293 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6294 (decode_base_type): Update.
6295 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6296 (eb_complaint, record_include_begin, record_include_end)
6297 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6298 (process_xcoff_symbol, read_symbol)
6299 (function_outside_compilation_unit_complaint)
6300 (scan_xcoff_symtab): Update.
6301 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6302 * buildsym.c (finish_block_internal, make_blockvector)
6303 (end_symtab_get_static_block, augment_type_symtab): Update.
6304 * dtrace-probe.c (dtrace_process_dof)
6305 (dtrace_static_probe_ops::get_probes): Update.
6306 * complaints.h (struct complaint): Don't declare.
6307 (symfile_complaints): Remove.
6308 (complaint_internal): Remove "complaints" parameter.
6309 (complaint): Likewise.
6310 (clear_complaints): Likewise.
6311 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6312 (reread_symbols): Update.
6313 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6314 (dwarf2_frame_cache, decode_frame_entry): Update.
6315 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6316 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6317 (info_selectors_command): Update.
6318 * macrotab.c (macro_include, check_for_redefinition)
6319 (macro_undef): Update.
6320 * objfiles.c (filter_overlapping_sections): Update.
6321 * stabsread.c (invalid_cpp_abbrev_complaint)
6322 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6323 (define_symbol, error_type, read_type, rs6000_builtin_type)
6324 (stabs_method_name_from_physname, read_member_functions)
6325 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6326 (attach_fields_to_type, complain_about_struct_wipeout)
6327 (read_range_type, read_args, common_block_start)
6328 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6329 Update.
6330 * mdebugread.c (index_complaint, unknown_ext_complaint)
6331 (basic_type_complaint, bad_tag_guess_complaint)
6332 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6333 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6334 (parse_procedure, parse_lines)
6335 (function_outside_compilation_unit_complaint)
6336 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6337 (bad_tag_guess_complaint, reg_value_complaint): Update.
6338 * cp-support.c (demangled_name_complaint): Update.
6339 * macroscope.c (sal_macro_scope): Update.
6340 * dwarf-index-write.c (class debug_names): Update.
6341
6342 2018-05-23 Tom Tromey <tom@tromey.com>
6343
6344 * complaints.c (clear_complaints): Remove "noisy" parameter.
6345 * complaints.h (clear_complaints): Update.
6346 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6347 (reread_symbols): Update.
6348
6349 2018-05-23 Tom Tromey <tom@tromey.com>
6350
6351 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6352 SUBSEQUENT_MESSAGE.
6353 (vcomplaint, clear_complaints): Update.
6354 (symfile_explanations): Remove some messages.
6355
6356 2018-05-23 Tom Tromey <tom@tromey.com>
6357
6358 * complaints.c (internal_complaint): Remove.
6359 * complaints.h (internal_complaint): Remove.
6360
6361 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6362
6363 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6364
6365 2018-05-22 Pedro Alves <palves@redhat.com>
6366
6367 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6368 (remote_fileio_badfd, remote_fileio_return_errno)
6369 (remote_fileio_return_success, remote_fileio_func_open)
6370 (remote_fileio_func_open, remote_fileio_func_close)
6371 (remote_fileio_func_read, remote_fileio_func_write)
6372 (remote_fileio_func_lseek, remote_fileio_func_rename)
6373 (remote_fileio_func_unlink, remote_fileio_func_stat)
6374 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6375 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6376 remote_target parameter.
6377 (remote_fio_func_map) <func>: Add remote_target parameter.
6378 (do_remote_fileio_request, remote_fileio_request):
6379 * remote-fileio.h (remote_fileio_request):
6380 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6381 remote_target parameter.
6382 (remote_notif_process, handle_notification): Adjust to pass down
6383 the remote.
6384 (remote_notif_state_allocate): Add remote_target parameter. Save
6385 it.
6386 * remote-notif.h (struct remote_target): Forward declare.
6387 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6388 remote_target parameter.
6389 (struct remote_notif_state) <remote>: New field.
6390 (remote_notif_ack, remote_notif_parse): Add remote_target
6391 parameter.
6392 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6393 remote_target parameter.
6394 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6395 (threads_listing_context, rmt_thread_action, protocol_feature)
6396 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6397 (packet_result, struct threads_listing_context, remote_state):
6398 Move definitions and declarations higher up.
6399 (remote_target) <~remote_target>: Declare.
6400 (remote_download_command_source, remote_file_put, remote_file_get)
6401 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6402 (remote_hostio_pread_vFile, remote_hostio_send_command)
6403 (remote_hostio_set_filesystem, remote_hostio_open)
6404 (remote_hostio_close, remote_hostio_unlink, remote_state)
6405 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6406 (get_memory_write_packet_size, get_memory_read_packet_size)
6407 (append_pending_thread_resumptions, remote_detach_1)
6408 (append_resumption, remote_resume_with_vcont)
6409 (add_current_inferior_and_thread, wait_ns, wait_as)
6410 (process_stop_reply, remote_notice_new_inferior)
6411 (process_initial_stop_replies, remote_add_thread)
6412 (btrace_sync_conf, remote_btrace_maybe_reopen)
6413 (remove_new_fork_children, kill_new_fork_children)
6414 (discard_pending_stop_replies, stop_reply_queue_length)
6415 (check_pending_events_prevent_wildcard_vcont)
6416 (discard_pending_stop_replies_in_queue, stop_reply)
6417 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6418 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6419 (remote_interrupt_as, remote_interrupt_ns)
6420 (remote_get_noisy_reply, remote_query_attached)
6421 (remote_add_inferior, remote_current_thread, get_current_thread)
6422 (set_thread, set_general_thread, set_continue_thread)
6423 (set_general_process, write_ptid)
6424 (remote_unpack_thread_info_response, remote_get_threadinfo)
6425 (parse_threadlist_response, remote_get_threadlist)
6426 (remote_threadlist_iterator, remote_get_threads_with_ql)
6427 (remote_get_threads_with_qxfer)
6428 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6429 (get_offsets, remote_check_symbols, remote_supported_packet)
6430 (remote_query_supported, remote_packet_size)
6431 (remote_serial_quit_handler, remote_detach_pid)
6432 (remote_vcont_probe, remote_resume_with_hc)
6433 (send_interrupt_sequence, interrupt_query)
6434 (remote_notif_get_pending_events, fetch_register_using_p)
6435 (send_g_packet, process_g_packet, fetch_registers_using_g)
6436 (store_register_using_P, store_registers_using_G)
6437 (set_remote_traceframe, check_binary_download)
6438 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6439 (remote_xfer_live_readonly_partial, remote_read_bytes)
6440 (remote_send_printf, remote_flash_write, readchar)
6441 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6442 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6443 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6444 (extended_remote_disable_randomization, extended_remote_run)
6445 (send_environment_packet, extended_remote_environment_support)
6446 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6447 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6448 (packet_command): Now methods of ...
6449 (remote_target): ... this class.
6450 (m_remote_state) <remote_target>: New field.
6451 (struct remote_state) <stop_reply_queue,
6452 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6453 fields.
6454 (remote_state::remote_state): Allocate stop_reply_queue.
6455 (remote_state): Delete global.
6456 (get_remote_state_raw): Delete.
6457 (remote_target::get_remote_state): Allocate m_remote_state on
6458 demand.
6459 (get_current_remote_target): New.
6460 (remote_ops, extended_remote_ops): Delete.
6461 (wait_forever_enabled_p, remote_async_inferior_event_token):
6462 Delete, moved to struct remote_state.
6463 (remote_target::close): Delete self. Destruction bits split to
6464 ...
6465 (remote_target::~remote_target): ... this.
6466 (show_memory_packet_size): Adjust to use
6467 get_current_remote_target.
6468 (struct protocol_feature) <func>: Add remote_target parameter.
6469 All callers adjusted.
6470 (curr_quit_handler_target): New.
6471 (remote_serial_quit_handler): Reimplement.
6472 (remote_target::open_1): Adjust to use get_current_remote_target.
6473 Heap-allocate remote_target/extended_remote_target instances.
6474 (vcont_builder::vcont_builder): Add remote_target parameter, and
6475 save it in m_remote. All callers adjusted.
6476 (vcont_builder::m_remote): New field.
6477 (vcont_builder::restart, vcont_builder::flush)
6478 (vcont_builder::push_action): Use it.
6479 (remote_target::commit_resume): Use it.
6480 (struct queue_iter_param) <remote>: New field.
6481 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6482 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6483 (check_pending_event_prevents_wildcard_vcont_callback)
6484 (remote_target::check_pending_events_prevent_wildcard_vcont)
6485 (remote_target::discard_pending_stop_replies)
6486 (remote_target::discard_pending_stop_replies_in_queue)
6487 (remote_target::remote_notif_remove_queued_reply): Fill in
6488 'remote' field.
6489 (remote_notif_get_pending_events): New.
6490 (remote_target::readchar, remote_target::remote_serial_write):
6491 Save/restore curr_quit_handler_target.
6492 (putpkt): New.
6493 (kill_new_fork_children): Fill in 'remote' field.
6494 (packet_command): Use get_current_remote_target, defer to
6495 remote_target method of same name.
6496 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6497 parameter, and save it in m_remote. All callers adjusted.
6498 (scoped_remote_fd::release): Use m_remote.
6499 (scoped_remote_fd::m_remote): New field.
6500 (remote_file_put, remote_file_get, remote_file_delete): Use
6501 get_current_remote_target, defer to remote_target method of same
6502 name.
6503 (remote_btrace_reset): Add remote_state paremeter. Update all
6504 callers.
6505 (remote_async_inferior_event_handler). Pass down 'data'.
6506 (remote_new_objfile): Use get_current_remote_target.
6507 (remote_target::vcont_r_supported): New.
6508 (set_range_stepping): Use get_current_remote_target and
6509 remote_target::vcont_r_supported.
6510 (_initialize_remote): Don't allocate 'remote_state' and
6511 'stop_reply_queue' globals.
6512 * remote.h (struct remote_target): Forward declare.
6513 (getpkt, putpkt, remote_notif_get_pending_events): Add
6514 'remote_target' parameter.
6515
6516 2018-05-22 Pedro Alves <palves@redhat.com>
6517
6518 * remote.c (vcont_builder): Now a class. Make all data members
6519 private.
6520 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6521 Declare methods.
6522 (vcont_builder_restart): Rename to ...
6523 (vcont_builder::restart): ... this.
6524 (vcont_builder_flush): Rename to ...
6525 (vcont_builder::flush): ... this.
6526 (vcont_builder_push_action): Rename to ...
6527 (vcont_builder::push_action): ... this.
6528 (remote_target::commit_resume): Adjust.
6529
6530 2018-05-22 Pedro Alves <palves@redhat.com>
6531
6532 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6533 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6534 (get_fixed_memory_packet_size): New.
6535 (get_memory_packet_size): Use it.
6536 (set_memory_packet_size): Don't override the config size with
6537 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6538 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6539 Don't refer to get_memory_packet_size if not connected to a remote
6540 target. Show "(default)" if configured size is 0.
6541
6542 2018-05-22 Pedro Alves <palves@redhat.com>
6543
6544 * remote.c (remote_target::mourn_inferior): Move
6545 discard_pending_stop_replies call here from ...
6546 (_initialize_remote): ... here.
6547
6548 2018-05-22 Pedro Alves <palves@redhat.com>
6549
6550 * remote.c (compare_section_command): Remove set_general_process
6551 call.
6552
6553 2018-05-22 Pedro Alves <palves@redhat.com>
6554
6555 * remote.c (struct packet_reg, struct remote_arch_state):
6556 Move higher up in the file.
6557 (remote_state) <m_arch_states>: Store remote_arch_state values
6558 instead of remote_arch_state pointers.
6559 (remote_state::get_remote_arch_state): Adjust.
6560
6561 2018-05-22 Pedro Alves <palves@redhat.com>
6562
6563 * remote.c: Include <unordered_map>.
6564 (remote_state): Now a class.
6565 (remote_state) <get_remote_arch_state>: Declare method.
6566 <get_remote_arch_state>: New field.
6567 (remote_arch_state) <remote_arch_state>: Declare ctor.
6568 <regs>: Now a unique_ptr.
6569 (remote_gdbarch_data_handle): Delete.
6570 (get_remote_arch_state): Delete.
6571 (remote_state::get_remote_arch_state): New.
6572 (get_remote_state): Adjust to call remote_state's
6573 get_remote_arch_state method.
6574 (init_remote_state): Delete, bits factored out to ...
6575 (remote_arch_state::remote_arch_state): ... this new method.
6576 (get_remote_packet_size, get_memory_packet_size)
6577 (process_g_packet, remote_target::fetch_registers)
6578 (remote_target::prepare_to_store, store_registers_using_G)
6579 (remote_target::store_registers, remote_target::get_trace_status):
6580 Adjust to call remote_state's method.
6581 (_initialize_remote): Remove reference to
6582 remote_gdbarch_data_handle.
6583
6584 2018-05-22 Pedro Alves <palves@redhat.com>
6585
6586 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6587 pread>: New method declarations.
6588 (remote_target::open_1): Adjust.
6589 (readahead_cache_invalidate): Rename to ...
6590 (readahead_cache::invalidate): ... this, and adjust to be a class
6591 method.
6592 (readahead_cache_invalidate_fd): Rename to ...
6593 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6594 class method.
6595 (remote_hostio_pwrite): Adjust.
6596 (remote_hostio_pread_from_cache): Rename to ...
6597 (readahead_cache::pread): ... this, and adjust to be a class
6598 method.
6599 (remote_hostio_close): Adjust.
6600
6601 2018-05-22 Pedro Alves <palves@redhat.com>
6602
6603 * remote.c (remote_hostio_close_cleanup): Delete.
6604 (class scoped_remote_fd): New.
6605 (remote_file_put, remote_file_get): Use it.
6606
6607 2018-05-22 Pedro Alves <palves@redhat.com>
6608
6609 (struct vCont_action_support): Use bool and initialize all fields.
6610 (struct readahead_cache): Initialize all fields.
6611 (remote_state): Use bool and initialize all fields.
6612 (remote_state::remote_state, remote_state::~remote_state): New.
6613 (new_remote_state): Delete.
6614 (_initialize_remote): Use new to allocate remote_state.
6615
6616 2018-05-22 Pedro Alves <palves@redhat.com>
6617 張俊芝 <zjz@zjz.name>
6618
6619 PR gdb/22973
6620 * c-exp.y: Include "c-support.h".
6621 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6622 of tolower. Use c_ident_is_alpha to scan names.
6623 * c-lang.c: Include "c-support.h".
6624 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6625 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6626 * c-support.h: New file, with bits factored out from ...
6627 * cp-name-parser.y: ... this file.
6628 Include "c-support.h".
6629 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6630 c-support.h and renamed.
6631 (symbol_end, yylex): Adjust.
6632
6633 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6634
6635 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6636 parameter type to CORE_ADDR.
6637 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6638 parameter type in declaration to CORE_ADDR.
6639 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6640 target_auxv_search to get AT_HWCAP and use the result to get the
6641 target description.
6642 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6643 to CORE_ADDR. Remove the cast of the return value to unsigned
6644 long. Fix error predicate of target_auxv_search.
6645 (ppc_linux_nat_target::read_description): Change the type of the
6646 hwcap variable to CORE_ADDR.
6647
6648 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6649
6650 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6651 if the size of fpscr is larger than 32 bits.
6652
6653 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6654
6655 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6656 (ppc32_linux_vsxregmap): New global.
6657 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6658 regcache_supply_regset, and regcache_collect_regset.
6659 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6660 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6661 (fetch_vsx_register, store_vsx_register): Remove.
6662 (fetch_vsx_registers): Add regno parameter. Get regset using
6663 ppc_linux_vsxregset. Use regset to supply registers.
6664 (store_vsx_registers): Add regno parameter. Get regset using
6665 ppc_linux_vsxregset. Use regset to collect registers.
6666 (fetch_register): Call fetch_vsx_registers instead of
6667 fetch_vsx_register.
6668 (store_register): Call store_vsx_registers instead of
6669 store_vsx_register.
6670 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6671 new regno parameter.
6672 (store_ppc_registers): Call store_vsx_registers with -1 for the
6673 new regno parameter.
6674 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6675 (ppc_collect_vsxregset): Remove.
6676
6677 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6678
6679 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6680 offset fields.
6681 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6682 for vector register offset fields.
6683 (ppc64_fbsd_reg_offsets): Likewise.
6684 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6685 to vector register offset fields.
6686 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6687 to vector register offset fields.
6688 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6689 vector register offset fields.
6690 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6691 initializers for vector register offset fields.
6692 (rs6000_aix64_reg_offsets): Likewise.
6693 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6694 (ppc_supply_vrregset): Remove.
6695 (ppc_collect_vrregset): Remove.
6696 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6697 (ppc_linux_vrregset) : New function.
6698 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6699 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6700 (ppc32_linux_vrregset): Remove.
6701 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6702 and use result instead of ppc32_linux_vrregset.
6703 (ppc32_linux_reg_offsets): Remove initializers for vector register
6704 offset fields.
6705 (ppc64_linux_reg_offsets): Likewise.
6706 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6707 * ppc-linux-nat.c: Include regset.h.
6708 (gdb_vrregset_t): Adjust comment to account for little-endian
6709 mode.
6710 (supply_vrregset, fill_vrregset): Remove.
6711 (fetch_altivec_register, store_altivec_register): Remove.
6712 (fetch_altivec_registers): Add regno parameter. Get regset using
6713 ppc_linux_vrregset. Use regset to supply registers.
6714 (store_altivec_registers): Add regno parameter. Get regset using
6715 ppc_linux_vrregset. Use regset to collect registers.
6716 (fetch_register): Call fetch_altivec_registers instead of
6717 fetch_altivec_register.
6718 (store_register): Call store_altivec_registers instead of
6719 store_altivec_register.
6720 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6721 the new regno parameter.
6722 (store_ppc_registers): Call store_altivec_registers with -1 for
6723 the new regno parameter.
6724
6725 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6726
6727 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6728 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6729 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6730 (gdb_vrregset_t): Change array type size to
6731 PPC_LINUX_SIZEOF_VRREGSET.
6732 (gdb_vsxregset_t): Change array type size to
6733 PPC_LINUX_SIZEOF_VSXREGSET.
6734 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6735 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6736 PPC_LINUX_SIZEOF_VSXREGSET.
6737
6738 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6739
6740 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6741 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6742 nat/ppc-linux.c.
6743 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6744 ppc_linux_target_wordsize with tid.
6745 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6746 wordsize with tid.
6747 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6748 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6749 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6750 tid parameter. Remove static specifier.
6751 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6752 (ppc_linux_target_wordsize): New declaration.
6753
6754 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6755
6756 * arch/ppc-linux-common.c: New file.
6757 * arch/ppc-linux-common.h: New file.
6758 * arch/ppc-linux-tdesc.h: New file.
6759 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6760 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6761 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6762 arch/ppc-linux-tdesc.h.
6763 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6764 arch/ppc-linux-tdesc.h.
6765 (ppc_linux_nat_target::read_description): Remove target
6766 description matching code. Fill a ppc_linux_features struct and
6767 call ppc_linux_match_description with it. Move comment about ISA
6768 2.05 to ppc-linux-common.c.
6769 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6770 arch/ppc-linux-tdesc.h.
6771 (ppc_linux_core_read_description): Remove target description
6772 matching code. Fill a ppc_linux_features struct and call
6773 ppc_linux_match_description with it.
6774 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6775 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6776 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6777 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6778 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6779 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6780 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6781 (tdesc_powerpc_e500l): Remove.
6782
6783 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6784
6785 * ada-lang.c (catch_assert_command): Pass empty string instead
6786 of NULL for excep_string argument.
6787
6788 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6789
6790 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6791 the width of the requested register exceeds the width of the
6792 `ptrace' data type.
6793
6794 2018-05-21 Tom Tromey <tom@tromey.com>
6795
6796 * printcmd.c (output_command): Remove.
6797 (output_command_const): Rename to output_command.
6798 * valprint.h (output_command): Rename from output_command_const.
6799 * tracepoint.c (trace_dump_actions): Call output_command.
6800
6801 2018-05-21 Tom Tromey <tom@tromey.com>
6802
6803 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6804 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6805 * ada-lang.h (create_ada_exception_catchpoint): Update.
6806 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6807 std::string.
6808 (create_excep_cond_exprs, ~ada_catchpoint)
6809 (should_stop_exception, print_one_exception)
6810 (print_mention_exception, print_recreate_exception): Update.
6811 (ada_get_next_arg): Remove.
6812 (catch_ada_exception_command_split): Use std::string. Change type
6813 of "excep_string", "cond_string".
6814 (catch_ada_exception_command): Update.
6815 (create_ada_exception_catchpoint): Change type of excep_string.
6816 (ada_exception_sal): Remove excep_string parameter.
6817 (~ada_catchpoint): Remove.
6818
6819 2018-05-21 Tom Tromey <tom@tromey.com>
6820
6821 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6822 cleanup.
6823
6824 2018-05-21 Tom Tromey <tom@tromey.com>
6825
6826 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6827 Return unique_xmalloc_ptr.
6828 (print_it_exception): Update.
6829
6830 2018-05-21 Tom Tromey <tom@tromey.com>
6831
6832 * tracepoint.c (trace_dump_actions): Use std::string.
6833
6834 2018-05-21 Tom Tromey <tom@tromey.com>
6835
6836 * symfile.c (reread_symbols): Use std::string for original_name.
6837
6838 2018-05-21 Tom Tromey <tom@tromey.com>
6839
6840 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6841 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6842 constructor.
6843
6844 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6845
6846 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6847 instance to...
6848 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6849 * objfiles.c (get_objfile_bfd_data): Allocate
6850 objfile_per_bfd_storage with obstack_new when allocating on
6851 obstack.
6852
6853 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6854
6855 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6856 OBSTACK_ZALLOC.
6857 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6858 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6859 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6860 (add_pending): Likewise.
6861 (parse_symbol): Likewise.
6862 (parse_partial_symbols): Likewise.
6863 (psymtab_to_symtab_1): Likewise.
6864 (new_psymtab): Likewise.
6865 (elfmdebug_build_psymtabs): Likewise.
6866 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6867 * objfiles.c (get_objfile_bfd_data): Likewise.
6868 (objfile_register_static_link): Likewise.
6869 * psymtab.c (allocate_psymtab): Likewise.
6870 * stabsread.c (read_member_functions): Likewise.
6871 * xcoffread.c (xcoff_end_psymtab): Likewise.
6872
6873 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6874
6875 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6876 compiler supports std::is_trivially_constructible.
6877 * common/poison.h: Include obstack.h.
6878 (IsMallocable): Define to is_trivially_constructible if the
6879 compiler supports it, define to true_type otherwise.
6880 (xobnew): New.
6881 (XOBNEW): Redefine.
6882 (xobnewvec): New.
6883 (XOBNEWVEC): Redefine.
6884 * gdb_obstack.h (obstack_zalloc): New.
6885 (OBSTACK_ZALLOC): Redefine.
6886 (obstack_calloc): New.
6887 (OBSTACK_CALLOC): Redefine.
6888 (obstack_new): New.
6889 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6890 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6891 gdbarch.c.
6892 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6893 obstack_calloc/obstack_zalloc.
6894 (gdbarch_obstack_zalloc): Remove.
6895 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6896
6897 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6898
6899 * stack.c (backtrace_command_1): Remove useless variable int i.
6900
6901 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6902
6903 * stack.c (print_frame_info): Fix comment.
6904
6905 2018-05-18 Tom Tromey <tom@tromey.com>
6906
6907 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6908 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6909 (~dwarf2_per_objfile): Update
6910 (dwarf2_get_dwz_file): Use new.
6911 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6912 unique_ptr.
6913
6914 2018-05-18 Tom Tromey <tom@tromey.com>
6915
6916 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6917 unique_ptr.
6918 * dwarf2read.c (struct dwp_file): Add constructor and
6919 initializers.
6920 (open_and_init_dwp_file): Return a unique_ptr.
6921 (dwarf2_per_objfile, create_dwp_hash_table)
6922 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6923 (lookup_dwo_unit_in_dwp): Update.
6924 (open_and_init_dwp_file, get_dwp_file): Update.
6925
6926 2018-05-18 Tom Tromey <tom@tromey.com>
6927
6928 * dwarf2read.c (dwarf2_per_objfile): Update.
6929 (struct mapped_index): Add initializers.
6930 (dwarf2_read_index): Use new.
6931 (dw2_symtab_iter_init): Update.
6932 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6933 unique_ptr.
6934
6935 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6936
6937 * dwarf2read.c (mapped_index) <total_size>: Remove.
6938
6939 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6940
6941 * unittests/format_pieces-selftests.c (test_format_specifier):
6942 Add ARI comments.
6943
6944 2018-05-18 Tom Tromey <tom@tromey.com>
6945
6946 * c-typeprint.c (maybe_print_hole): New function.
6947 (c_print_type_struct_field_offset): Update.
6948 (c_type_print_base_struct_union): Call maybe_print_hole.
6949
6950 2018-05-17 Keith Seitz <keiths@redhat.com>
6951
6952 * breakpoint.c (build_bpstat_chain): New function, moved from
6953 bpstat_stop_status.
6954 (bpstat_stop_status): Add optional parameter, `stop_chain'.
6955 If no stop chain is passed, call build_bpstat_chain to build it.
6956 * breakpoint.h (build_bpstat_chain): Declare.
6957 (bpstat_stop_status): Move documentation here from breakpoint.c.
6958 * infrun.c (handle_signal_stop): Before eliding inlined frames,
6959 build the stop chain and pass it to skip_inline_frames.
6960 Pass this stop chain to bpstat_stop_status.
6961 * inline-frame.c: Include breakpoint.h.
6962 (stopped_by_user_bp_inline_frame): New function.
6963 (skip_inline_frames): Add parameter `stop_chain'.
6964 Move documention to inline-frame.h.
6965 If non-NULL, use stopped_by_user_bp_inline_frame to determine
6966 whether the frame should be elided.
6967 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
6968 Add moved documentation and update for new parameter.
6969
6970 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
6971
6972 PR cli/14975
6973 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6974 unittests/format_pieces-selftests.c.
6975 * common/format.h (format_piece) <operator==>: New.
6976 (format_pieces) <operator[]>: Remove.
6977 * common/format.c (format_pieces::format_pieces): Handle \e.
6978 * unittests/format_pieces-selftests.c: New.
6979
6980 2018-05-17 Tom Tromey <tom@tromey.com>
6981
6982 PR symtab/23010:
6983 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
6984 (dw2_instantiate_symtab): Add skip_partial parameter.
6985 (dw2_find_last_source_symtab, dw2_map_expand_apply)
6986 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
6987 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
6988 (dw2_expand_symtabs_matching_one)
6989 (dw2_find_pc_sect_compunit_symtab)
6990 (dw2_debug_names_lookup_symbol)
6991 (dw2_debug_names_expand_symtabs_for_function): Update.
6992 (init_cutu_and_read_dies): Add skip_partial parameter.
6993 (process_psymtab_comp_unit, build_type_psymtabs_1)
6994 (process_skeletonless_type_unit, load_partial_comp_unit)
6995 (psymtab_to_symtab_1): Update.
6996 (load_full_comp_unit): Add skip_partial parameter.
6997 (process_imported_unit_die, dwarf2_read_addr_index)
6998 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
6999 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
7000 (read_signatured_type): Update.
7001
7002 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7003
7004 * value.c (release_value): Remove unused variable.
7005 (record_latest_value): Likewise.
7006 (access_value_history): Likewise.
7007 (preserve_values): Likewise.
7008
7009 2018-05-17 Tom Tromey <tom@tromey.com>
7010
7011 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
7012 Initialize.
7013
7014 2018-05-16 Maciej W. Rozycki <macro@mips.com>
7015
7016 PR gdb/22286
7017 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
7018 Also handle registers whose width is not a multiple of
7019 PTRACE_TYPE_RET.
7020 (linux_nat_trad_target::store_register): Likewise.
7021
7022 2018-05-16 Tom Tromey <tom@tromey.com>
7023
7024 * gdbcore.h (core_bfd): Redefine.
7025 * corelow.c (core_target::close): Update.
7026 (core_target_open): Update.
7027 * progspace.h (struct program_space) <cbfd>: Now a
7028 gdb_bfd_ref_ptr.
7029
7030 2018-05-16 Tom Tromey <tom@tromey.com>
7031
7032 PR cli/19551:
7033 * symfile-add-flags.h (enum symfile_add_flags)
7034 <SYMFILE_NOT_FILENAME>: New constant.
7035 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
7036 objfile name from BFD.
7037 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7038 * minidebug.c (find_separate_debug_file_in_section): Put
7039 ".gnu_debugdata" into BFD's file name.
7040
7041 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7042
7043 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7044 Remove.
7045
7046 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7047
7048 PR binutils/21446
7049 * aarch64-tdep.c (aarch64_analyze_prologue,
7050 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7051 Indicate not interested in errors.
7052
7053 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7054
7055 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7056 Supply the MIPS_ZERO_REGNUM register.
7057
7058 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7059
7060 * mips-tdep.c (mask_address_var): Make variable static.
7061
7062 2018-05-14 Tom Tromey <tom@tromey.com>
7063
7064 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7065
7066 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7067
7068 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7069 FXSAVE_ADDR for the mxcsr register.
7070
7071 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7072
7073 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
7074
7075 2018-05-11 Pedro Alves <palves@redhat.com>
7076
7077 * corelow.c (core_target) <core_target>: No longer inline.
7078 Initialize m_core_gdbarch, m_core_vec and build the section table
7079 here.
7080 <~core_target>: New.
7081 <core_gdbarch, get_core_register_section>: New methods.
7082 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
7083 factored out from ...
7084 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
7085 (core_ops): Delete.
7086 (sniff_core_bfd): Add gdbarch parameter.
7087 (core_close): Delete, merged into ...
7088 (core_target::close): ... here. Delete self.
7089 (core_close_cleanup): Delete.
7090 (core_target_open): Allocate a core_target on the heap. Use a
7091 unique_ptr instead of a cleanup. Bits moved into the core_target
7092 ctor. Adjust to use core_target methods instead of globals.
7093 (get_core_register_section): Rename to ...
7094 (core_target::get_core_register_section): ... this and adjust.
7095 (struct get_core_registers_cb_data): New.
7096 (get_core_registers_cb): Use it. Use bool.
7097 (core_target::fetch_registers, core_target::files_info)
7098 (core_target::xfer_partial, core_target::read_description)
7099 (core_target::pid_to, core_target::thread_name): Adjust to
7100 reference class fields instead of globals.
7101 * target.h (struct target_ops_deleter, target_ops_up): New.
7102
7103 2018-05-11 Pedro Alves <palves@redhat.com>
7104
7105 * corefile.c (core_file_command): Move to corelow.c.
7106 * corelow.c (the_core_target): Delete.
7107 (core_file_command): Moved from corefile.c. Check exec_bfd
7108 instead of the_core_target. Use target_detach instead of calling
7109 into the_core_target directly.
7110 (maybe_say_no_core_file_now): New.
7111 (core_target::detach): Use it.
7112 (_initialize_corelow): Remove references to the_core_target.
7113 * gdbcore.h (the_core_target): Delete.
7114
7115 2018-05-11 Tom Tromey <tromey@redhat.com>
7116 Pedro Alves <palves@redhat.com>
7117
7118 * corefile.c (core_bfd): Remove.
7119 * gdbcore.h (core_bfd): Now a macro.
7120 * progspace.h (struct program_space) <cbfd>: New field.
7121
7122 2018-05-11 Tom Tromey <tom@tromey.com>
7123
7124 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
7125 gdb::def_vector.
7126
7127 2018-05-10 Tom Tromey <tom@tromey.com>
7128
7129 * configure: Rebuild.
7130 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
7131
7132 2018-05-10 Joel Brobecker <brobecker@adacore.com>
7133
7134 PR server/23158:
7135 * regformats/regdat.sh: Adjust script, following the addition
7136 of the new expedite_regs parameter to init_target_desc.
7137
7138 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
7139
7140 PR gdb/23127
7141 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
7142 set_gdbarch_significant_addr_bit.
7143 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
7144 set_gdbarch_significant_addr_bit.
7145 * utils.c (address_significant): Update to sign extend addr.
7146
7147 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
7148
7149 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
7150 (xtensa_linux_init_abi): Limit tdep->num_regs by
7151 tdep->num_nopriv_regs.
7152 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
7153 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
7154 not initialized.
7155
7156 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
7157
7158 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
7159
7160 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
7161
7162 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
7163 (I387_MXCSR_INIT_VAL): New constant.
7164 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
7165 buffer if it was supplied by the inferior.
7166 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
7167 (i387_xsave_get_clear_bv): New function.
7168 (i387_supply_xsave): Only read x87 control registers from the
7169 xsave buffer if the feature is enabled, and the state will have
7170 been written, otherwise, provide a suitable default.
7171 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
7172 including x87 control registers. Update control registers if they
7173 have changed from the default value, and mark features as enabled
7174 as required.
7175 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
7176
7177 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
7178
7179 * spu-tdep.c (info_spu_event_command): Fix output formatting.
7180
7181 2018-05-07 Tom Tromey <tom@tromey.com>
7182
7183 * configure: Rebuild.
7184 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
7185
7186 2018-05-07 Tom Tromey <tom@tromey.com>
7187
7188 PR tdep/20362:
7189 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
7190 bit. Use correct value for VDIV.
7191
7192 2018-05-04 Tom Tromey <tom@tromey.com>
7193
7194 * configure: Rebuild.
7195 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
7196
7197 2018-05-04 Tom Tromey <tom@tromey.com>
7198
7199 * linux-record.c (record_linux_system_call) <case
7200 RECORD_SYS_RECVFROM>: Add "break".
7201
7202 2018-05-04 Tom Tromey <tom@tromey.com>
7203
7204 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
7205 Add missing "break".
7206 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
7207 Add missing "break".
7208
7209 2018-05-04 Tom Tromey <tom@tromey.com>
7210
7211 * rs6000-tdep.c (ppc_process_record_op4)
7212 (ppc_process_record_op63): Add fall-through comment.
7213
7214 2018-05-04 Tom Tromey <tom@tromey.com>
7215
7216 * i386-tdep.c (i386_process_record): Add fall-through comment.
7217
7218 2018-05-04 Tom Tromey <tom@tromey.com>
7219
7220 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7221 comment.
7222
7223 2018-05-04 Tom Tromey <tom@tromey.com>
7224
7225 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7226 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7227 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7228 comment.
7229 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7230 comment.
7231 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7232 comment.
7233
7234 2018-05-04 Tom Tromey <tom@tromey.com>
7235
7236 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7237
7238 2018-05-04 Tom Tromey <tom@tromey.com>
7239
7240 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7241 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7242 * symfile.c (section_is_mapped): Fix fall-through comment.
7243 * stabsread.c (define_symbol, read_member_functions): Fix
7244 fall-through comment.
7245 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7246 comment.
7247 * remote.c (remote_wait_as): Fix fall-through comment.
7248 * p-exp.y (yylex): Fix fall-through comment.
7249 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7250 comment.
7251 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7252 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7253 * jv-exp.y (yylex): Fix fall-through comment.
7254 * go-exp.y (lex_one_token): Fix fall-through comment.
7255 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7256 fall-through comment.
7257 * f-exp.y (yylex): Fix fall-through comment.
7258 * dwarf2read.c (process_die): Fix fall-through comments.
7259 * dbxread.c (process_one_symbol): Fix fall-through comment.
7260 * d-exp.y (lex_one_token): Fix fall-through comment.
7261 * cp-name-parser.y (yylex): Fix fall-through comment.
7262 * coffread.c (coff_symtab_read): Fix fall-through comment.
7263 * c-exp.y (lex_one_token): Fix fall-through comment.
7264 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7265 comment.
7266 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7267 comment.
7268
7269 2018-05-04 Tom Tromey <tom@tromey.com>
7270
7271 PR python/22730:
7272 * NEWS: Mention gdb.execute change.
7273 * gdbcmd.h (execute_control_command): Don't declare.
7274 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7275 execute_control_commands, execute_control_commands_to_string.
7276 * cli/cli-script.h (execute_control_commands)
7277 (execute_control_commands_to_string): Declare.
7278 (execute_control_command): Add from_tty parameter.
7279 * cli/cli-script.c (execute_control_commands)
7280 (execute_control_commands_to_string): New functions.
7281 (execute_user_command): Use execute_control_commands.
7282 (execute_control_command_1): Add "from_tty" parameter. Update.
7283 (execute_control_command): Likewise.
7284
7285 2018-05-04 Tom Tromey <tom@tromey.com>
7286
7287 PR python/22731:
7288 * NEWS: Mention that breakpoint commands are writable.
7289 * python/py-breakpoint.c (bppy_set_commands): New function.
7290 (breakpoint_object_getset) <"commands">: Use it.
7291
7292 2018-05-04 Tom Tromey <tom@tromey.com>
7293
7294 * tracepoint.c (actions_command): Update.
7295 * mi/mi-cmd-break.c (mi_command_line_array)
7296 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7297 (mi_read_next_line): Remove.
7298 (mi_cmd_break_commands): Update.
7299 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7300 function_view.
7301 * cli/cli-script.c (get_command_line): Update.
7302 (process_next_line): Use function_view. Constify.
7303 (recurse_read_control_structure, read_command_lines)
7304 (read_command_lines_1): Change argument types to function_view.
7305 (do_define_command, document_command): Update.
7306 * breakpoint.h (check_tracepoint_command): Don't declare.
7307 * breakpoint.c (check_tracepoint_command): Remove.
7308 (commands_command_1, create_tracepoint_from_upload): Update.
7309
7310 2018-05-04 Tom Tromey <tom@tromey.com>
7311
7312 PR gdb/11750:
7313 * cli/cli-script.h (enum command_control_type) <define_control>:
7314 New constant.
7315 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7316 (build_command_line, execute_control_command_1)
7317 (process_next_line): Likewise.
7318 (do_define_command): New function, extracted from define_command.
7319 (define_command): Use it.
7320
7321 2018-05-04 Tom Tromey <tom@tromey.com>
7322
7323 * tracepoint.c (actions_command): Update.
7324 * cli/cli-script.h (read_command_lines): Update.
7325 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7326 (MAX_TMPBUF): Remove define.
7327 (define_command): Use string_printf.
7328 (document_command): Likewise.
7329 * breakpoint.c (commands_command_1): Update.
7330
7331 2018-05-04 Tom Tromey <tom@tromey.com>
7332
7333 * top.c (execute_command): Update.
7334 * cli/cli-script.h (print_command_lines): Now varargs.
7335 * cli/cli-script.c (print_command_lines): Now varargs.
7336 (execute_control_command_1) <case while_control, case if_control>:
7337 Update.
7338
7339 2018-05-04 Tom Tromey <tom@tromey.com>
7340
7341 * tracepoint.c (all_tracepoint_actions): Rename from
7342 all_tracepoint_actions_and_cleanup. Change return type.
7343 (actions_command, encode_actions_1, encode_actions)
7344 (trace_dump_actions, tdump_command): Update.
7345 * remote.c (remote_download_command_source): Update.
7346 * python/python.c (gdbpy_eval_from_control_command)
7347 (python_command, python_interactive_command): Update.
7348 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7349 * guile/guile.c (guile_command)
7350 (gdbscm_eval_from_control_command, guile_command): Update.
7351 * compile/compile.c (compile_code_command)
7352 (compile_print_command, compile_to_object): Update.
7353 * cli/cli-script.h (struct command_lines_deleter): New.
7354 (counted_command_line): New typedef.
7355 (struct command_line): Add constructor, destructor.
7356 <body_list>: Remove.
7357 <body_list_0, body_list_1>: New members.
7358 (command_line_up): Remove typedef.
7359 (read_command_lines, read_command_lines_1, get_command_line):
7360 Update.
7361 (copy_command_lines): Don't declare.
7362 * cli/cli-script.c (build_command_line): Use "new".
7363 (get_command_line): Return counted_command_line.
7364 (print_command_lines, execute_user_command)
7365 (execute_control_command_1, while_command, if_command): Update.
7366 (realloc_body_list): Remove.
7367 (process_next_line, recurse_read_control_structure): Update.
7368 (read_command_lines, read_command_lines_1): Return counted_command_line.
7369 (free_command_lines): Use "delete".
7370 (copy_command_lines): Remove.
7371 (define_command, document_command, show_user_1): Update.
7372 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7373 a counted_command_line.
7374 * breakpoint.h (counted_command_line): Remove typedef.
7375 (breakpoint_set_commands): Update.
7376 * breakpoint.c (check_no_tracepoint_commands)
7377 (validate_commands_for_breakpoint): Update.
7378 (breakpoint_set_commands): Change commands to be a
7379 counted_command_line.
7380 (commands_command_1, update_dprintf_command_list)
7381 (create_tracepoint_from_upload): Update.
7382
7383 2018-05-04 Tom Tromey <tom@tromey.com>
7384
7385 * cli/cli-decode.h (cmd_list_element): New constructor.
7386 (~cmd_list_element): New destructor.
7387 (struct cmd_list_element): Add initializers.
7388 * cli/cli-decode.c (do_add_cmd): Use "new".
7389 (delete_cmd): Use "delete".
7390
7391 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7392 Pedro Alves <palves@redhat.com>
7393
7394 PR breakpoints/19806 and support for PR external/20207.
7395 * NEWS: Mention Aarch64 watchpoint improvements.
7396 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7397 watchpoints and PR external/20207 watchpoints.
7398 * nat/aarch64-linux-hw-point.c
7399 (kernel_supports_any_contiguous_range): New.
7400 (aarch64_watchpoint_offset): New.
7401 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7402 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7403 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7404 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7405 next_addr_orig_p. Support PR external/20207 watchpoints.
7406 (aarch64_downgrade_regs): New.
7407 (aarch64_dr_state_insert_one_point): New parameters offset and
7408 addr_orig.
7409 (aarch64_dr_state_remove_one_point): Likewise.
7410 (aarch64_handle_breakpoint): Update caller.
7411 (aarch64_handle_aligned_watchpoint): Likewise.
7412 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7413 aligned_offset.
7414 (aarch64_linux_set_debug_regs): Remove const from state. Call
7415 aarch64_downgrade_regs.
7416 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7417 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7418 (DR_CONTROL_MASK): ... this.
7419 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7420 (unsigned int aarch64_watchpoint_offset): New prototype.
7421 (aarch64_linux_set_debug_regs): Remove const from state.
7422 * utils.c (align_up, align_down): Move to ...
7423 * common/common-utils.c (align_up, align_down): ... here.
7424 * utils.h (align_up, align_down): Move to ...
7425 * common/common-utils.h (align_up, align_down): ... here.
7426
7427 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7428
7429 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7430 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7431 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7432 Re-implement to match the ABI as summarized in GCC's
7433 gcc/config/sparc/sparc.c. All callers updated.
7434 (sparc32_store_arguments): Remove assertion.
7435
7436 2018-05-04 Tom Tromey <tom@tromey.com>
7437
7438 * printcmd.c: Don't include tui.h.
7439 (decode_format): Use skip_spaces.
7440
7441 2018-05-04 Tom Tromey <tom@tromey.com>
7442
7443 PR gdb/22619:
7444 * printcmd.c (last_count): New global.
7445 (x_command): Use saved count when repeating.
7446
7447 2018-05-04 Tom Tromey <tom@tromey.com>
7448
7449 * nto-procfs.c (do_closedir_cleanup): Remove.
7450 (procfs_pidlist): Use gdb_dir_up.
7451 * procfs.c (do_closedir_cleanup): Remove.
7452 (proc_update_threads): Use gdb_dir_up.
7453 * common/filestuff.h (struct gdb_dir_deleter): New.
7454 (gdb_dir_up): New typedef.
7455
7456 2018-05-04 Tom Tromey <tom@tromey.com>
7457
7458 * ada-lang.c (print_mention_exception): Use std::string.
7459
7460 2018-05-04 Tom Tromey <tom@tromey.com>
7461
7462 * ada-lang.c (create_excep_cond_exprs): Update.
7463 (ada_exception_catchpoint_cond_string): Use std::string.
7464
7465 2018-05-04 Tom Tromey <tom@tromey.com>
7466
7467 * ada-lang.c (xget_renaming_scope): Return std::string.
7468 (old_renaming_is_invisible): Update.
7469
7470 2018-05-04 Tom Tromey <tom@tromey.com>
7471
7472 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7473 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7474
7475 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7476
7477 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7478
7479 2018-05-04 Tom Tromey <tom@tromey.com>
7480
7481 * remote.c (remote_query_supported_append): Change type.
7482 (remote_check_symbols): Update.
7483
7484 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7485
7486 PR gdb/11420
7487 * configure.ac: Prepend libpython.
7488 * python/python-config.py: Likewise.
7489 * configure: Regenerate.
7490
7491 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7492
7493 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7494
7495 2018-05-03 Pedro Alves <palves@redhat.com>
7496
7497 * s390-linux-nat.c
7498 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7499 override. Write 'true' instead of '1'.
7500 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7501 declaration.
7502
7503 2018-05-02 Pedro Alves <palves@redhat.com>
7504
7505 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7506 add_inf_child_target.
7507 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7508 add_inf_child_target.
7509 * aix-thread.c (aix_thread_target_info): New.
7510 (aix_thread_target) <shortname, longname, doc>: Delete.
7511 <info>: New.
7512 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7513 add_inf_child_target.
7514 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7515 add_inf_child_target.
7516 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7517 add_inf_child_target.
7518 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7519 add_inf_child_target.
7520 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7521 add_inf_child_target.
7522 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7523 add_inf_child_target.
7524 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7525 add_inf_child_target.
7526 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7527 add_inf_child_target.
7528 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7529 add_inf_child_target.
7530 * bfd-target.c (target_bfd_target_info): New.
7531 (target_bfd) <shortname, longname, doc>: Delete.
7532 <info>: New.
7533 * bsd-kvm.c (bsd_kvm_target_info): New.
7534 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7535 <info>: New.
7536 (bsd_kvm_target::open): Rename to ...
7537 (bsd_kvm_target_open): ... this. Adjust.
7538 * bsd-uthread.c (bsd_uthread_target_info): New.
7539 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7540 <info>: New.
7541 * corefile.c (core_file_command): Adjust.
7542 * corelow.c (core_target_info): New.
7543 (core_target) <shortname, longname, doc>: Delete.
7544 <info>: New.
7545 (core_target::open): Rename to ...
7546 (core_target_open): ... this. Adjust.
7547 * ctf.c (ctf_target_info): New.
7548 (ctf_target) <shortname, longname, doc>: Delete.
7549 <info>: New.
7550 (ctf_target::open): Rename to ...
7551 (ctf_target_open): ... this.
7552 (_initialize_ctf): Adjust.
7553 * exec.c (exec_target_info): New.
7554 (exec_target) <shortname, longname, doc>: Delete.
7555 <info>: New.
7556 (exec_target::open): Rename to ...
7557 (exec_target_open): ... this.
7558 * gdbcore.h (core_target_open): Declare.
7559 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7560 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7561 add_inf_child_target.
7562 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7563 add_inf_child_target.
7564 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7565 add_inf_child_target.
7566 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7567 add_inf_child_target.
7568 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7569 add_inf_child_target.
7570 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7571 add_inf_child_target.
7572 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7573 add_inf_child_target.
7574 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7575 add_inf_child_target.
7576 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7577 add_inf_child_target.
7578 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7579 add_inf_child_target.
7580 * inf-child.c (inf_child_target_info): New.
7581 (inf_child_target::info): New.
7582 (inf_child_open_target): Remove 'target' parameter. Use
7583 get_native_target instead.
7584 (inf_child_target::open): Delete.
7585 (add_inf_child_target): New.
7586 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7587 Delete.
7588 <info>: New.
7589 (add_inf_child_target): Declare.
7590 (inf_child_open_target): Declare.
7591 * linux-thread-db.c (thread_db_target_info): New.
7592 (thread_db_target) <shortname, longname, doc>: Delete.
7593 <info>: New.
7594 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7595 add_inf_child_target.
7596 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7597 add_inf_child_target.
7598 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7599 add_inf_child_target.
7600 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7601 add_inf_child_target.
7602 * make-target-delegates (print_class): Adjust.
7603 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7604 add_inf_child_target.
7605 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7606 add_inf_child_target.
7607 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7608 add_inf_child_target.
7609 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7610 add_inf_child_target.
7611 * nto-procfs.c (nto_native_target_info): New.
7612 (nto_procfs_target_native) <shortname, longname, doc>:
7613 Delete.
7614 <info>: New.
7615 (nto_procfs_target_info): New.
7616 (nto_procfs_target_procfs) <shortname, longname, doc>:
7617 Delete.
7618 <info>: New.
7619 (init_procfs_targets): Adjust.
7620 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7621 add_inf_child_target.
7622 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7623 add_inf_child_target.
7624 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7625 add_inf_child_target.
7626 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7627 add_inf_child_target.
7628 * ravenscar-thread.c (ravenscar_target_info): New.
7629 (ravenscar_thread_target) <shortname, longname, doc>:
7630 Delete.
7631 <info>: New.
7632 * record-btrace.c (record_btrace_target_info):
7633 (record_btrace_target) <shortname, longname, doc>: Delete.
7634 <info>: New.
7635 (record_btrace_target::open): Rename to ...
7636 (record_btrace_target_open): ... this. Adjust.
7637 * record-full.c (record_longname, record_doc): New.
7638 (record_full_base_target) <shortname, longname, doc>: Delete.
7639 <info>: New.
7640 (record_full_target_info): New.
7641 (record_full_target): <shortname>: Delete.
7642 <info>: New.
7643 (record_full_core_open_1, record_full_open_1): Update comments.
7644 (record_full_base_target::open): Rename to ...
7645 (record_full_open): ... this.
7646 (cmd_record_full_restore): Update.
7647 (_initialize_record_full): Update.
7648 * remote-sim.c (remote_sim_target_info): New.
7649 (gdbsim_target) <shortname, longname, doc>: Delete.
7650 <info>: New.
7651 (gdbsim_target::open): Rename to ...
7652 (gdbsim_target_open): ... this.
7653 (_initialize_remote_sim): Adjust.
7654 * remote.c (remote_doc): New.
7655 (remote_target_info): New.
7656 (remote_target) <shortname, longname, doc>: Delete.
7657 <info>: New.
7658 (extended_remote_target_info): New.
7659 (extended_remote_target) <shortname, longname, doc>: Delete.
7660 <info>: New.
7661 (remote_target::open_1): Make static. Adjust.
7662 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7663 * s390-linux-nat.c (_initialize_s390_nat): Use
7664 add_inf_child_target.
7665 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7666 add_inf_child_target.
7667 * sol-thread.c (thread_db_target_info): New.
7668 (sol_thread_target) <shortname, longname, doc>: Delete.
7669 <info>: New.
7670 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7671 add_inf_child_target.
7672 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7673 add_inf_child_target.
7674 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7675 add_inf_child_target.
7676 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7677 add_inf_child_target.
7678 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7679 add_inf_child_target.
7680 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7681 add_inf_child_target.
7682 * spu-linux-nat.c (_initialize_spu_nat): Use
7683 add_inf_child_target.
7684 * spu-multiarch.c (spu_multiarch_target_info): New.
7685 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7686 <info>: New.
7687 * target-delegates.c: Regenerate.
7688 * target.c: Include <unordered_map>.
7689 (target_ops_p): Delete.
7690 (DEF_VEC_P(target_ops_p)): Delete.
7691 (target_factories): New.
7692 (test_target_info): New.
7693 (test_target_ops::info): New.
7694 (open_target): Adjust to use target_factories.
7695 (add_target_with_completer): Rename to ...
7696 (add_target): ... this. Change prototype. Register target_info
7697 and open callback in target_factories. Register target_info in
7698 command context instead of target_ops.
7699 (add_target): Delete old implementation.
7700 (add_deprecated_target_alias): Change prototype. Adjust.
7701 (the_native_target): New.
7702 (set_native_target, get_native_target): New.
7703 (find_default_run_target): Use the_native_target.
7704 (find_attach_target, find_run_target): Simplify.
7705 (target_ops::open): Delete.
7706 (dummy_target_info): New.
7707 (dummy_target::shortname, dummy_target::longname)
7708 (dummy_target::doc): Delete.
7709 (dummy_target::info): New.
7710 (debug_target::shortname, debug_target::longname)
7711 (debug_target::doc): Delete.
7712 (debug_target::info): New.
7713 * target.h (struct target_info): New.
7714 (target_ops::~target_ops): Add comment.
7715 (target_ops::info): New.
7716 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7717 longer virtual. Implement in terms of target_info.
7718 (set_native_target, get_native_target): Declare.
7719 (target_open_ftype): New.
7720 (add_target, add_target_with_completer)
7721 (add_deprecated_target_alias): Change prototype.
7722 (test_target) <shortname, longname, doc>: Delete.
7723 <info>: New.
7724 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7725 add_inf_child_target.
7726 * tracefile-tfile.c (tfile_target_info): New.
7727 (tfile_target) <shortname, longname, doc>: Delete.
7728 <info>: New.
7729 (tfile_target::open): Rename to ...
7730 (tfile_target_open): ... this.
7731 (_initialize_tracefile_tfile): Adjust.
7732 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7733 add_inf_child_target.
7734 * windows-nat.c (_initialize_windows_nat): Use
7735 add_inf_child_target.
7736 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7737 add_inf_child_target.
7738
7739 2018-05-02 Pedro Alves <palves@redhat.com>
7740
7741 * linux-nat.h (linux_nat_target) <low_new_thread,
7742 low_delete_thread, low_new_fork, low_forget_process,
7743 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7744 New virtual methods.
7745 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7746 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7747 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7748 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7749 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7750 Delete.
7751 * linux-fork.c (delete_fork): Adjust to call low method.
7752 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7753 (linux_nat_new_fork, linux_nat_forget_process_hook)
7754 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7755 (linux_nat_status_is_event):
7756 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7757 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7758 to call low method.
7759 (sigtrap_is_event): Rename to ...
7760 (linux_nat_target::low_status_is_event): ... this.
7761 (linux_nat_set_status_is_event): Delete.
7762 (save_stop_reason, linux_nat_wait_1)
7763 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7764 low methods.
7765 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7766 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7767 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7768 (linux_nat_set_prepare_to_resume): Delete.
7769 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7770 low virtual methods.
7771 * amd64-linux-nat.c: Likewise.
7772 * arm-linux-nat.c: Likewise.
7773 * i386-linux-nat.c: Likewise.
7774 * ia64-linux-nat.c: Likewise.
7775 * mips-linux-nat.c: Likewise.
7776 * ppc-linux-nat.c: Likewise.
7777 * s390-linux-nat.c: Likewise.
7778 * sparc64-linux-nat.c: Likewise.
7779 * x86-linux-nat.c: Likewise.
7780 * x86-linux-nat.h: Include "nat/x86-linux.h".
7781 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7782 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7783 Override methods.
7784
7785 2018-05-02 Pedro Alves <palves@redhat.com>
7786
7787 * target.h (target_ops)
7788 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7789 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7790 stopped_by_watchpoint, have_continuable_watchpoint,
7791 stopped_data_address, watchpoint_addr_within_range,
7792 can_accel_watchpoint_condition, can_run, thread_alive,
7793 has_all_memory, has_memory, has_stack, has_registers,
7794 has_execution, can_async_p, is_async_p, supports_non_stop,
7795 always_non_stop_p, can_execute_reverse, supports_multi_process,
7796 supports_enable_disable_tracepoint,
7797 supports_disable_randomization, supports_string_tracing,
7798 supports_evaluation_of_breakpoint_conditions,
7799 can_run_breakpoint_commands, filesystem_is_local,
7800 can_download_tracepoint, get_trace_state_variable_value,
7801 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7802 record_is_replaying, record_will_replay,
7803 augmented_libraries_svr4_read>: Adjust to return bool.
7804 * aarch64-linux-nat.c: All implementations adjusted.
7805 * aix-thread.c: All implementations adjusted.
7806 * arm-linux-nat.c: All implementations adjusted.
7807 * breakpoint.c: All implementations adjusted.
7808 * bsd-kvm.c: All implementations adjusted.
7809 * bsd-uthread.c: All implementations adjusted.
7810 * corelow.c: All implementations adjusted.
7811 * ctf.c: All implementations adjusted.
7812 * darwin-nat.c: All implementations adjusted.
7813 * darwin-nat.h: All implementations adjusted.
7814 * exec.c: All implementations adjusted.
7815 * fbsd-nat.c: All implementations adjusted.
7816 * fbsd-nat.h: All implementations adjusted.
7817 * gnu-nat.c: All implementations adjusted.
7818 * gnu-nat.h: All implementations adjusted.
7819 * go32-nat.c: All implementations adjusted.
7820 * ia64-linux-nat.c: All implementations adjusted.
7821 * inf-child.c: All implementations adjusted.
7822 * inf-child.h: All implementations adjusted.
7823 * inf-ptrace.c: All implementations adjusted.
7824 * inf-ptrace.h: All implementations adjusted.
7825 * linux-nat.c: All implementations adjusted.
7826 * linux-nat.h: All implementations adjusted.
7827 * mips-linux-nat.c: All implementations adjusted.
7828 * nto-procfs.c: All implementations adjusted.
7829 * ppc-linux-nat.c: All implementations adjusted.
7830 * procfs.c: All implementations adjusted.
7831 * ravenscar-thread.c: All implementations adjusted.
7832 * record-btrace.c: All implementations adjusted.
7833 * record-full.c: All implementations adjusted.
7834 * remote-sim.c: All implementations adjusted.
7835 * remote.c: All implementations adjusted.
7836 * s390-linux-nat.c: All implementations adjusted.
7837 * sol-thread.c: All implementations adjusted.
7838 * spu-multiarch.c: All implementations adjusted.
7839 * target-delegates.c: All implementations adjusted.
7840 * target.c: All implementations adjusted.
7841 * target.h: All implementations adjusted.
7842 * tracefile-tfile.c: All implementations adjusted.
7843 * tracefile.c: All implementations adjusted.
7844 * tracefile.h: All implementations adjusted.
7845 * windows-nat.c: All implementations adjusted.
7846 * x86-linux-nat.h: All implementations adjusted.
7847 * x86-nat.h: All implementations adjusted.
7848
7849 2018-05-02 Pedro Alves <palves@redhat.com>
7850
7851 * make-target-delegates (scan_target_h): Don't trim lines here.
7852 Replace sequences of tabs and/or whitespace with a single
7853 whitespace.
7854 (top level, parsing methods): Trim each line before processing it
7855 here.
7856
7857 2018-05-02 Pedro Alves <palves@redhat.com>
7858 John Baldwin <jhb@freebsd.org>
7859
7860 * target.h (enum strata) <debug_stratum>: New.
7861 (struct target_ops) <all delegation methods>: Replace by C++
7862 virtual methods, and drop "to_" prefix. All references updated
7863 throughout.
7864 <to_shortname, to_longname, to_doc, to_data,
7865 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7866 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7867 virtual methods. All references updated throughout.
7868 <can_attach, supports_terminal_ours, can_create_inferior,
7869 get_thread_control_capabilities, attach_no_wait>: New
7870 virtual methods.
7871 <insert_breakpoint, remove_breakpoint>: Now
7872 TARGET_DEFAULT_NORETURN methods.
7873 <info_proc>: Now returns bool.
7874 <to_magic>: Delete.
7875 (OPS_MAGIC): Delete.
7876 (current_target): Delete. All references replaced by references
7877 to ...
7878 (target_stack): ... this. New.
7879 (target_shortname, target_longname): Adjust.
7880 (target_can_run): Now a function declaration.
7881 (default_child_has_all_memory, default_child_has_memory)
7882 (default_child_has_stack, default_child_has_registers)
7883 (default_child_has_execution): Remove target_ops parameter.
7884 (complete_target_initialization): Delete.
7885 (memory_breakpoint_target): New template class.
7886 (test_target_ops): Refactor as a C++ class with virtual methods.
7887 * make-target-delegates (NAME_PART): Tighten.
7888 (POINTER_PART, CP_SYMBOL): New.
7889 (SIMPLE_RETURN_PART): Reimplement.
7890 (VEC_RETURN_PART): Expect less.
7891 (RETURN_PART, VIRTUAL_PART): New.
7892 (METHOD): Adjust to C++ virtual methods.
7893 (scan_target_h): Remove reference to C99.
7894 (dname): Output "target_ops::" prefix.
7895 (write_function_header): Adjust to output a C++ class method.
7896 (write_declaration): New.
7897 (write_delegator): Adjust to output a C++ class method.
7898 (tdname): Output "dummy_target::" prefix.
7899 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7900 method.
7901 (tdefault_names, debug_names): Delete.
7902 (return_types, tdefaults, styles, argtypes_array): New.
7903 (top level): All methods are delegators.
7904 (print_class): New.
7905 (top level): Print dummy_target and debug_target classes.
7906 * target-delegates.c: Regenerate.
7907 * target-debug.h (target_debug_print_enum_info_proc_what)
7908 (target_debug_print_thread_control_capabilities)
7909 (target_debug_print_thread_info_p): New.
7910 * target.c (dummy_target): Delete.
7911 (the_dummy_target, the_debug_target): New.
7912 (target_stack): Now extern.
7913 (set_targetdebug): Push/unpush debug target.
7914 (default_child_has_all_memory, default_child_has_memory)
7915 (default_child_has_stack, default_child_has_registers)
7916 (default_child_has_execution): Remove target_ops parameter.
7917 (complete_target_initialization): Delete.
7918 (add_target_with_completer): No longer call
7919 complete_target_initialization.
7920 (target_supports_terminal_ours): Use regular delegation.
7921 (update_current_target): Delete.
7922 (push_target): No longer check magic number. Don't call
7923 update_current_target.
7924 (unpush_target): Don't call update_current_target.
7925 (target_is_pushed): No longer check magic number.
7926 (target_require_runnable): Skip for all stratums over
7927 process_stratum.
7928 (target_ops::info_proc): New.
7929 (target_info_proc): Use find_target_at and
7930 find_default_run_target.
7931 (target_supports_disable_randomization): Use regular delegation.
7932 (target_get_osdata): Use find_target_at.
7933 (target_ops::open, target_ops::close, target_ops::can_attach)
7934 (target_ops::attach, target_ops::can_create_inferior)
7935 (target_ops::create_inferior, target_ops::can_run)
7936 (target_can_run): New.
7937 (default_fileio_target): Use regular delegation.
7938 (target_ops::fileio_open, target_ops::fileio_pwrite)
7939 (target_ops::fileio_pread, target_ops::fileio_fstat)
7940 (target_ops::fileio_close, target_ops::fileio_unlink)
7941 (target_ops::fileio_readlink): New.
7942 (target_fileio_open_1, target_fileio_unlink)
7943 (target_fileio_readlink): Always call the target method. Handle
7944 FILEIO_ENOSYS.
7945 (return_zero, return_zero_has_execution): Delete.
7946 (init_dummy_target): Delete.
7947 (dummy_target::dummy_target, dummy_target::shortname)
7948 (dummy_target::longname, dummy_target::doc)
7949 (debug_target::debug_target, debug_target::shortname)
7950 (debug_target::longname, debug_target::doc): New.
7951 (target_supports_delete_record): Use regular delegation.
7952 (setup_target_debug): Delete.
7953 (maintenance_print_target_stack): Skip debug_stratum.
7954 (initialize_targets): Instantiate the_dummy_target and
7955 the_debug_target.
7956 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
7957 use target_stack.
7958 (target_auxv_search, fprint_target_auxv): Adjust.
7959 (info_auxv_command): Adjust to use target_stack.
7960 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
7961 * exceptions.c (print_flush): Handle a NULL target_stack.
7962 * regcache.c (target_ops_no_register): Refactor as class with
7963 virtual methods.
7964
7965 * exec.c (exec_target): New class.
7966 (exec_ops): Now an exec_target.
7967 (exec_open, exec_close_1, exec_get_section_table)
7968 (exec_xfer_partial, exec_files_info, exec_has_memory)
7969 (exec_make_note_section): Refactor as exec_target methods.
7970 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
7971 Delete.
7972 (exec_target::find_memory_regions): New.
7973 (_initialize_exec): Don't call init_exec_ops.
7974 * gdbcore.h (exec_file_clear): Delete.
7975
7976 * corefile.c (core_target): Delete.
7977 (core_file_command): Adjust.
7978 * corelow.c (core_target): New class.
7979 (the_core_target): New.
7980 (core_close): Remove target_ops parameter.
7981 (core_close_cleanup): Adjust.
7982 (core_target::close): New.
7983 (core_open, core_detach, get_core_registers, core_files_info)
7984 (core_xfer_partial, core_thread_alive, core_read_description)
7985 (core_pid_to_str, core_thread_name, core_has_memory)
7986 (core_has_stack, core_has_registers, core_info_proc): Rework as
7987 core_target methods.
7988 (ignore, core_remove_breakpoint, init_core_ops): Delete.
7989 (_initialize_corelow): Initialize the_core_target.
7990 * gdbcore.h (core_target): Delete.
7991 (the_core_target): New.
7992
7993 * ctf.c: (ctf_target): New class.
7994 (ctf_ops): Now a ctf_target.
7995 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
7996 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
7997 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
7998 methods.
7999 (init_ctf_ops): Delete.
8000 (_initialize_ctf): Don't call it.
8001 * tracefile-tfile.c (tfile_target): New class.
8002 (tfile_ops): Now a tfile_target.
8003 (tfile_open, tfile_close, tfile_files_info)
8004 (tfile_get_tracepoint_status, tfile_trace_find)
8005 (tfile_fetch_registers, tfile_xfer_partial)
8006 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
8007 Refactor as tfile_target methods.
8008 (tfile_xfer_partial_features): Remove target_ops parameter.
8009 (init_tfile_ops): Delete.
8010 (_initialize_tracefile_tfile): Don't call it.
8011 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
8012 (tracefile_has_stack, tracefile_has_registers)
8013 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
8014 tracefile_target methods.
8015 (init_tracefile_ops): Delete.
8016 (tracefile_target::tracefile_target): New.
8017 * tracefile.h: Include "target.h".
8018 (tracefile_target): New class.
8019 (init_tracefile_ops): Delete.
8020
8021 * spu-multiarch.c (spu_multiarch_target): New class.
8022 (spu_ops): Now a spu_multiarch_target.
8023 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
8024 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
8025 (spu_search_memory, spu_mourn_inferior): Refactor as
8026 spu_multiarch_target methods.
8027 (init_spu_ops): Delete.
8028 (_initialize_spu_multiarch): Remove references to init_spu_ops,
8029 complete_target_initialization.
8030
8031 * ravenscar-thread.c (ravenscar_thread_target): New class.
8032 (ravenscar_ops): Now a ravenscar_thread_target.
8033 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
8034 (ravenscar_thread_alive, ravenscar_pid_to_str)
8035 (ravenscar_fetch_registers, ravenscar_store_registers)
8036 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
8037 (ravenscar_stopped_by_hw_breakpoint)
8038 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8039 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8040 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8041 methods.
8042 (init_ravenscar_thread_ops): Delete.
8043 (_initialize_ravenscar): Remove references to
8044 init_ravenscar_thread_ops and complete_target_initialization.
8045
8046 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8047 (bsd_uthread_target): New class.
8048 (bsd_uthread_ops): Now a bsd_uthread_target.
8049 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8050 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8051 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8052 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8053 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8054 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8055 (bsd_uthread_target): Delete function.
8056 (_initialize_bsd_uthread): Remove reference to
8057 complete_target_initialization.
8058
8059 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8060 (target_bfd): ... this new class.
8061 (target_bfd_xfer_partial, target_bfd_get_section_table)
8062 (target_bfd_close): Refactor as target_bfd methods.
8063 (target_bfd::~target_bfd): New.
8064 (target_bfd_reopen): Adjust.
8065 (target_bfd::close): New.
8066
8067 * record-btrace.c (record_btrace_target): New class.
8068 (record_btrace_ops): Now a record_btrace_target.
8069 (record_btrace_open, record_btrace_stop_recording)
8070 (record_btrace_disconnect, record_btrace_close)
8071 (record_btrace_async, record_btrace_info)
8072 (record_btrace_insn_history, record_btrace_insn_history_range)
8073 (record_btrace_insn_history_from, record_btrace_call_history)
8074 (record_btrace_call_history_range)
8075 (record_btrace_call_history_from, record_btrace_record_method)
8076 (record_btrace_is_replaying, record_btrace_will_replay)
8077 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
8078 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
8079 (record_btrace_store_registers, record_btrace_prepare_to_store)
8080 (record_btrace_to_get_unwinder)
8081 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
8082 (record_btrace_commit_resume, record_btrace_wait)
8083 (record_btrace_stop, record_btrace_can_execute_reverse)
8084 (record_btrace_stopped_by_sw_breakpoint)
8085 (record_btrace_supports_stopped_by_sw_breakpoint)
8086 (record_btrace_stopped_by_hw_breakpoint)
8087 (record_btrace_supports_stopped_by_hw_breakpoint)
8088 (record_btrace_update_thread_list, record_btrace_thread_alive)
8089 (record_btrace_goto_begin, record_btrace_goto_end)
8090 (record_btrace_goto, record_btrace_stop_replaying_all)
8091 (record_btrace_execution_direction)
8092 (record_btrace_prepare_to_generate_core)
8093 (record_btrace_done_generating_core): Refactor as
8094 record_btrace_target methods.
8095 (init_record_btrace_ops): Delete.
8096 (_initialize_record_btrace): Remove reference to
8097 init_record_btrace_ops.
8098 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
8099 the execution_direction global.
8100 (record_full_base_target, record_full_target)
8101 (record_full_core_target): New classes.
8102 (record_full_ops): Now a record_full_target.
8103 (record_full_core_ops): Now a record_full_core_target.
8104 (record_full_target::detach, record_full_target::disconnect)
8105 (record_full_core_target::disconnect)
8106 (record_full_target::mourn_inferior, record_full_target::kill):
8107 New.
8108 (record_full_open, record_full_close, record_full_async): Refactor
8109 as methods of the record_full_base_target class.
8110 (record_full_resume, record_full_commit_resume): Refactor
8111 as methods of the record_full_target class.
8112 (record_full_wait, record_full_stopped_by_watchpoint)
8113 (record_full_stopped_data_address)
8114 (record_full_stopped_by_sw_breakpoint)
8115 (record_full_supports_stopped_by_sw_breakpoint)
8116 (record_full_stopped_by_hw_breakpoint)
8117 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
8118 methods of the record_full_base_target class.
8119 (record_full_store_registers, record_full_xfer_partial)
8120 (record_full_insert_breakpoint, record_full_remove_breakpoint):
8121 Refactor as methods of the record_full_target class.
8122 (record_full_can_execute_reverse, record_full_get_bookmark)
8123 (record_full_goto_bookmark, record_full_execution_direction)
8124 (record_full_record_method, record_full_info, record_full_delete)
8125 (record_full_is_replaying, record_full_will_replay)
8126 (record_full_goto_begin, record_full_goto_end, record_full_goto)
8127 (record_full_stop_replaying): Refactor as methods of the
8128 record_full_base_target class.
8129 (record_full_core_resume, record_full_core_kill)
8130 (record_full_core_fetch_registers)
8131 (record_full_core_prepare_to_store)
8132 (record_full_core_store_registers, record_full_core_xfer_partial)
8133 (record_full_core_insert_breakpoint)
8134 (record_full_core_remove_breakpoint)
8135 (record_full_core_has_execution): Refactor
8136 as methods of the record_full_core_target class.
8137 (record_full_base_target::supports_delete_record): New.
8138 (init_record_full_ops): Delete.
8139 (init_record_full_core_ops): Delete.
8140 (record_full_save): Refactor as method of the
8141 record_full_base_target class.
8142 (_initialize_record_full): Remove references to
8143 init_record_full_ops and init_record_full_core_ops.
8144
8145 * remote.c (remote_target, extended_remote_target): New classes.
8146 (remote_ops): Now a remote_target.
8147 (extended_remote_ops): Now an extended_remote_target.
8148 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
8149 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
8150 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
8151 (remote_pass_signals, remote_set_syscall_catchpoint)
8152 (remote_program_signals, )
8153 (remote_thread_always_alive): Remove target_ops parameter.
8154 (remote_thread_alive, remote_thread_name)
8155 (remote_update_thread_list, remote_threads_extra_info)
8156 (remote_static_tracepoint_marker_at)
8157 (remote_static_tracepoint_markers_by_strid)
8158 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
8159 (remote_open): Refactor as methods of remote_target.
8160 (extended_remote_open, extended_remote_detach)
8161 (extended_remote_attach, extended_remote_post_attach):
8162 (extended_remote_supports_disable_randomization)
8163 (extended_remote_create_inferior): : Refactor as method of
8164 extended_remote_target.
8165 (remote_set_permissions, remote_open_1, remote_detach)
8166 (remote_follow_fork, remote_follow_exec, remote_disconnect)
8167 (remote_resume, remote_commit_resume, remote_stop)
8168 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
8169 (remote_terminal_ours, remote_wait, remote_fetch_registers)
8170 (remote_prepare_to_store, remote_store_registers)
8171 (remote_flash_erase, remote_flash_done, remote_files_info)
8172 (remote_kill, remote_mourn, remote_insert_breakpoint)
8173 (remote_remove_breakpoint, remote_insert_watchpoint)
8174 (remote_watchpoint_addr_within_range)
8175 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
8176 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
8177 (remote_supports_stopped_by_sw_breakpoint)
8178 (remote_stopped_by_hw_breakpoint)
8179 (remote_supports_stopped_by_hw_breakpoint)
8180 (remote_stopped_by_watchpoint, remote_stopped_data_address)
8181 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
8182 (remote_verify_memory): Refactor as methods of remote_target.
8183 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
8184 parameter.
8185 (remote_xfer_partial, remote_get_memory_xfer_limit)
8186 (remote_search_memory, remote_rcmd, remote_memory_map)
8187 (remote_pid_to_str, remote_get_thread_local_address)
8188 (remote_get_tib_address, remote_read_description): Refactor as
8189 methods of remote_target.
8190 (remote_target::fileio_open, remote_target::fileio_pwrite)
8191 (remote_target::fileio_pread, remote_target::fileio_close): New.
8192 (remote_hostio_readlink, remote_hostio_fstat)
8193 (remote_filesystem_is_local, remote_can_execute_reverse)
8194 (remote_supports_non_stop, remote_supports_disable_randomization)
8195 (remote_supports_multi_process, remote_supports_cond_breakpoints)
8196 (remote_supports_enable_disable_tracepoint)
8197 (remote_supports_string_tracing)
8198 (remote_can_run_breakpoint_commands, remote_trace_init)
8199 (remote_download_tracepoint, remote_can_download_tracepoint)
8200 (remote_download_trace_state_variable, remote_enable_tracepoint)
8201 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
8202 (remote_trace_start, remote_get_trace_status)
8203 (remote_get_tracepoint_status, remote_trace_stop)
8204 (remote_trace_find, remote_get_trace_state_variable_value)
8205 (remote_save_trace_data, remote_get_raw_trace_data)
8206 (remote_set_disconnected_tracing, remote_core_of_thread)
8207 (remote_set_circular_trace_buffer, remote_traceframe_info)
8208 (remote_get_min_fast_tracepoint_insn_len)
8209 (remote_set_trace_buffer_size, remote_set_trace_notes)
8210 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
8211 (remote_disable_btrace, remote_teardown_btrace)
8212 (remote_read_btrace, remote_btrace_conf)
8213 (remote_augmented_libraries_svr4_read, remote_load)
8214 (remote_pid_to_exec_file, remote_can_do_single_step)
8215 (remote_execution_direction, remote_thread_handle_to_thread_info):
8216 Refactor as methods of remote_target.
8217 (init_remote_ops, init_extended_remote_ops): Delete.
8218 (remote_can_async_p, remote_is_async_p, remote_async)
8219 (remote_thread_events, remote_upload_tracepoints)
8220 (remote_upload_trace_state_variables): Refactor as methods of
8221 remote_target.
8222 (_initialize_remote): Remove references to init_remote_ops and
8223 init_extended_remote_ops.
8224
8225 * remote-sim.c (gdbsim_target): New class.
8226 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8227 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8228 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8229 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8230 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8231 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8232 Refactor as methods of gdbsim_target.
8233 (gdbsim_ops): Now a gdbsim_target.
8234 (init_gdbsim_ops): Delete.
8235 (gdbsim_cntrl_c): Adjust.
8236 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8237
8238 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8239 (the_amd64_linux_nat_target): New.
8240 (amd64_linux_fetch_inferior_registers)
8241 (amd64_linux_store_inferior_registers): Refactor as methods of
8242 amd64_linux_nat_target.
8243 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8244 * i386-linux-nat.c: Don't include "linux-nat.h".
8245 (i386_linux_nat_target): New class.
8246 (the_i386_linux_nat_target): New.
8247 (i386_linux_fetch_inferior_registers)
8248 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8249 as methods of i386_linux_nat_target.
8250 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8251 * inf-child.c (inf_child_ops): Delete.
8252 (inf_child_fetch_inferior_registers)
8253 (inf_child_store_inferior_registers): Delete.
8254 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8255 methods of inf_child_target.
8256 (inf_child_target::supports_terminal_ours)
8257 (inf_child_target::terminal_init)
8258 (inf_child_target::terminal_inferior)
8259 (inf_child_target::terminal_ours_for_output)
8260 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8261 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8262 New.
8263 (inf_child_open, inf_child_disconnect, inf_child_close)
8264 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8265 (inf_child_post_startup_inferior, inf_child_can_run)
8266 (inf_child_pid_to_exec_file): Refactor as methods of
8267 inf_child_target.
8268 (inf_child_follow_fork): Delete.
8269 (inf_child_target::can_create_inferior)
8270 (inf_child_target::can_attach): New.
8271 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8272 (inf_child_target::has_stack, inf_child_target::has_registers)
8273 (inf_child_target::has_execution): New.
8274 (inf_child_fileio_open, inf_child_fileio_pwrite)
8275 (inf_child_fileio_pread, inf_child_fileio_fstat)
8276 (inf_child_fileio_close, inf_child_fileio_unlink)
8277 (inf_child_fileio_readlink, inf_child_use_agent)
8278 (inf_child_can_use_agent): Refactor as methods of
8279 inf_child_target.
8280 (return_zero, inf_child_target): Delete.
8281 (inf_child_target::inf_child_target): New.
8282 * inf-child.h: Include "target.h".
8283 (inf_child_target): Delete function prototype.
8284 (inf_child_target): New class.
8285 (inf_child_open_target, inf_child_mourn_inferior)
8286 (inf_child_maybe_unpush_target): Delete.
8287 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8288 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8289 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8290 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8291 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8292 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8293 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8294 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8295 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8296 methods of inf_ptrace_target.
8297 (inf_ptrace_target): Delete function.
8298 * inf-ptrace.h: Include "inf-child.h".
8299 (inf_ptrace_target): Delete function declaration.
8300 (inf_ptrace_target): New class.
8301 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8302 * linux-nat.c (linux_target): New.
8303 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8304 (linux_nat_target::~linux_nat_target): New.
8305 (linux_child_post_attach, linux_child_post_startup_inferior)
8306 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8307 (linux_child_remove_fork_catchpoint)
8308 (linux_child_insert_vfork_catchpoint)
8309 (linux_child_remove_vfork_catchpoint)
8310 (linux_child_insert_exec_catchpoint)
8311 (linux_child_remove_exec_catchpoint)
8312 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8313 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8314 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8315 (linux_nat_stopped_data_address)
8316 (linux_nat_stopped_by_sw_breakpoint)
8317 (linux_nat_supports_stopped_by_sw_breakpoint)
8318 (linux_nat_stopped_by_hw_breakpoint)
8319 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8320 (linux_nat_kill, linux_nat_mourn_inferior)
8321 (linux_nat_xfer_partial, linux_nat_thread_alive)
8322 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8323 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8324 (linux_child_static_tracepoint_markers_by_strid)
8325 (linux_nat_is_async_p, linux_nat_can_async_p)
8326 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8327 (linux_nat_supports_multi_process)
8328 (linux_nat_supports_disable_randomization, linux_nat_async)
8329 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8330 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8331 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8332 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8333 methods of linux_nat_target.
8334 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8335 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8336 parameter.
8337 (check_stopped_by_watchpoint): Adjust.
8338 (linux_xfer_partial): Delete.
8339 (linux_target_install_ops, linux_target, linux_nat_add_target):
8340 Delete.
8341 (linux_nat_target::linux_nat_target): New.
8342 * linux-nat.h: Include "inf-ptrace.h".
8343 (linux_nat_target): New.
8344 (linux_target, linux_target_install_ops, linux_nat_add_target):
8345 Delete function declarations.
8346 (linux_target): Declare global.
8347 * linux-thread-db.c (thread_db_target): New.
8348 (thread_db_target::thread_db_target): New.
8349 (thread_db_ops): Delete.
8350 (the_thread_db_target): New.
8351 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8352 (thread_db_update_thread_list, thread_db_pid_to_str)
8353 (thread_db_extra_thread_info)
8354 (thread_db_thread_handle_to_thread_info)
8355 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8356 (thread_db_resume): Refactor as methods of thread_db_target.
8357 (init_thread_db_ops): Delete.
8358 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8359 * x86-linux-nat.c: Don't include "linux-nat.h".
8360 (super_post_startup_inferior): Delete.
8361 (x86_linux_nat_target::~x86_linux_nat_target): New.
8362 (x86_linux_child_post_startup_inferior)
8363 (x86_linux_read_description, x86_linux_enable_btrace)
8364 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8365 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8366 methods of x86_linux_nat_target.
8367 (x86_linux_create_target): Delete. Bits folded ...
8368 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8369 pointer.
8370 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8371 (x86_linux_nat_target): New class.
8372 (x86_linux_create_target): Delete.
8373 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8374 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8375 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8376 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8377 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8378 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8379 make extern.
8380 (x86_use_watchpoints): Delete.
8381 * x86-nat.h: Include "breakpoint.h" and "target.h".
8382 (x86_use_watchpoints): Delete.
8383 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8384 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8385 (x86_insert_watchpoint, x86_remove_watchpoint)
8386 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8387 (x86_stopped_by_hw_breakpoint): New declarations.
8388 (x86_nat_target): New template class.
8389
8390 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8391 (the_ppc_linux_nat_target): New.
8392 (ppc_linux_fetch_inferior_registers)
8393 (ppc_linux_can_use_hw_breakpoint)
8394 (ppc_linux_region_ok_for_hw_watchpoint)
8395 (ppc_linux_ranged_break_num_registers)
8396 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8397 (ppc_linux_insert_mask_watchpoint)
8398 (ppc_linux_remove_mask_watchpoint)
8399 (ppc_linux_can_accel_watchpoint_condition)
8400 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8401 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8402 (ppc_linux_watchpoint_addr_within_range)
8403 (ppc_linux_masked_watch_num_registers)
8404 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8405 (ppc_linux_read_description): Refactor as methods of
8406 ppc_linux_nat_target.
8407 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8408
8409 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8410 (procfs_target): New class.
8411 (the_procfs_target): New.
8412 (procfs_target): Delete function.
8413 (procfs_auxv_parse, procfs_attach, procfs_detach)
8414 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8415 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8416 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8417 (procfs_create_inferior, procfs_update_thread_list)
8418 (procfs_thread_alive, procfs_pid_to_str)
8419 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8420 (procfs_stopped_data_address, procfs_insert_watchpoint)
8421 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8422 (proc_find_memory_regions, procfs_info_proc)
8423 (procfs_make_note_section): Refactor as methods of procfs_target.
8424 (_initialize_procfs): Adjust.
8425 * sol-thread.c (sol_thread_target): New class.
8426 (sol_thread_ops): Now a sol_thread_target.
8427 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8428 (sol_thread_fetch_registers, sol_thread_store_registers)
8429 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8430 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8431 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8432 (init_sol_thread_ops): Delete.
8433 (_initialize_sol_thread): Adjust. Remove references to
8434 init_sol_thread_ops and complete_target_initialization.
8435
8436 * windows-nat.c (windows_nat_target): New class.
8437 (windows_fetch_inferior_registers)
8438 (windows_store_inferior_registers, windows_resume, windows_wait)
8439 (windows_attach, windows_detach, windows_pid_to_exec_file)
8440 (windows_files_info, windows_create_inferior)
8441 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8442 (windows_close, windows_pid_to_str, windows_xfer_partial)
8443 (windows_get_tib_address, windows_get_ada_task_ptid)
8444 (windows_thread_name, windows_thread_alive): Refactor as
8445 windows_nat_target methods.
8446 (do_initial_windows_stuff): Adjust.
8447 (windows_target): Delete function.
8448 (_initialize_windows_nat): Adjust.
8449
8450 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8451 (darwin_mourn_inferior, darwin_kill_inferior)
8452 (darwin_create_inferior, darwin_attach, darwin_detach)
8453 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8454 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8455 (darwin_supports_multi_process): Refactor as darwin_nat_target
8456 methods.
8457 (darwin_resume_to, darwin_files_info): Delete.
8458 (_initialize_darwin_inferior): Rename to ...
8459 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8460 * darwin-nat.h: Include "inf-child.h".
8461 (darwin_nat_target): New class.
8462 (darwin_complete_target): Delete.
8463 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8464 (darwin_target): New.
8465 (i386_darwin_fetch_inferior_registers)
8466 (i386_darwin_store_inferior_registers): Refactor as methods of
8467 darwin_nat_target.
8468 (darwin_complete_target): Delete, with ...
8469 (_initialize_i386_darwin_nat): ... bits factored out here.
8470
8471 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8472 (the_alpha_linux_nat_target): New.
8473 (alpha_linux_register_u_offset): Refactor as
8474 alpha_linux_nat_target method.
8475 (_initialize_alpha_linux_nat): Adjust.
8476 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8477 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8478 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8479 methods of linux_nat_trad_target.
8480 (linux_trad_target): Delete.
8481 * linux-nat-trad.h (linux_trad_target): Delete function.
8482 (linux_nat_trad_target): New class.
8483 * mips-linux-nat.c (mips_linux_nat_target): New class.
8484 (super_fetch_registers, super_store_registers, super_close):
8485 Delete.
8486 (the_mips_linux_nat_target): New.
8487 (mips64_linux_regsets_fetch_registers)
8488 (mips64_linux_regsets_store_registers)
8489 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8490 (mips_linux_register_u_offset, mips_linux_read_description)
8491 (mips_linux_can_use_hw_breakpoint)
8492 (mips_linux_stopped_by_watchpoint)
8493 (mips_linux_stopped_data_address)
8494 (mips_linux_region_ok_for_hw_watchpoint)
8495 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8496 (mips_linux_close): Refactor as methods of mips_linux_nat.
8497 (_initialize_mips_linux_nat): Adjust to C++ification.
8498
8499 * aix-thread.c (aix_thread_target): New class.
8500 (aix_thread_ops): Now an aix_thread_target.
8501 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8502 (aix_thread_fetch_registers, aix_thread_store_registers)
8503 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8504 (aix_thread_thread_alive, aix_thread_pid_to_str)
8505 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8506 Refactor as methods of aix_thread_target.
8507 (init_aix_thread_ops): Delete.
8508 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8509 and complete_target_initialization.
8510 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8511 (rs6000_nat_target): New class.
8512 (the_rs6000_nat_target): New.
8513 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8514 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8515 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8516 (super_create_inferior): Delete.
8517 (_initialize_rs6000_nat): Adjust to C++ification.
8518
8519 * arm-linux-nat.c (arm_linux_nat_target): New class.
8520 (the_arm_linux_nat_target): New.
8521 (arm_linux_fetch_inferior_registers)
8522 (arm_linux_store_inferior_registers, arm_linux_read_description)
8523 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8524 (arm_linux_remove_hw_breakpoint)
8525 (arm_linux_region_ok_for_hw_watchpoint)
8526 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8527 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8528 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8529 arm_linux_nat_target.
8530 (_initialize_arm_linux_nat): Adjust to C++ification.
8531
8532 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8533 (the_aarch64_linux_nat_target): New.
8534 (aarch64_linux_fetch_inferior_registers)
8535 (aarch64_linux_store_inferior_registers)
8536 (aarch64_linux_child_post_startup_inferior)
8537 (aarch64_linux_read_description)
8538 (aarch64_linux_can_use_hw_breakpoint)
8539 (aarch64_linux_insert_hw_breakpoint)
8540 (aarch64_linux_remove_hw_breakpoint)
8541 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8542 (aarch64_linux_region_ok_for_hw_watchpoint)
8543 (aarch64_linux_stopped_data_address)
8544 (aarch64_linux_stopped_by_watchpoint)
8545 (aarch64_linux_watchpoint_addr_within_range)
8546 (aarch64_linux_can_do_single_step): Refactor as methods of
8547 aarch64_linux_nat_target.
8548 (super_post_startup_inferior): Delete.
8549 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8550
8551 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8552 (the_hppa_linux_nat_target): New.
8553 (hppa_linux_fetch_inferior_registers)
8554 (hppa_linux_store_inferior_registers): Refactor as methods of
8555 hppa_linux_nat_target.
8556 (_initialize_hppa_linux_nat): Adjust to C++ification.
8557
8558 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8559 (the_ia64_linux_nat_target): New.
8560 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8561 (ia64_linux_stopped_data_address)
8562 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8563 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8564 ia64_linux_nat_target methods.
8565 (super_xfer_partial): Delete.
8566 (_initialize_ia64_linux_nat): Adjust to C++ification.
8567
8568 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8569 (the_m32r_linux_nat_target): New.
8570 (m32r_linux_fetch_inferior_registers)
8571 (m32r_linux_store_inferior_registers): Refactor as
8572 m32r_linux_nat_target methods.
8573 (_initialize_m32r_linux_nat): Adjust to C++ification.
8574
8575 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8576 (the_m68k_linux_nat_target): New.
8577 (m68k_linux_fetch_inferior_registers)
8578 (m68k_linux_store_inferior_registers): Refactor as
8579 m68k_linux_nat_target methods.
8580 (_initialize_m68k_linux_nat): Adjust to C++ification.
8581
8582 * s390-linux-nat.c (s390_linux_nat_target): New class.
8583 (the_s390_linux_nat_target): New.
8584 (s390_linux_fetch_inferior_registers)
8585 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8586 (s390_insert_watchpoint, s390_remove_watchpoint)
8587 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8588 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8589 (s390_auxv_parse, s390_read_description): Refactor as methods of
8590 s390_linux_nat_target.
8591 (_initialize_s390_nat): Adjust to C++ification.
8592
8593 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8594 (the_sparc_linux_nat_target): New.
8595 (_initialize_sparc_linux_nat): Adjust to C++ification.
8596 * sparc-nat.c (sparc_fetch_inferior_registers)
8597 (sparc_store_inferior_registers): Remove target_ops parameter.
8598 * sparc-nat.h (sparc_fetch_inferior_registers)
8599 (sparc_store_inferior_registers): Remove target_ops parameter.
8600 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8601 (the_sparc64_linux_nat_target): New.
8602 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8603
8604 * spu-linux-nat.c (spu_linux_nat_target): New class.
8605 (the_spu_linux_nat_target): New.
8606 (spu_child_post_startup_inferior, spu_child_post_attach)
8607 (spu_child_wait, spu_fetch_inferior_registers)
8608 (spu_store_inferior_registers, spu_xfer_partial)
8609 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8610 methods.
8611 (_initialize_spu_nat): Adjust to C++ification.
8612
8613 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8614 (the_tilegx_linux_nat_target): New.
8615 (fetch_inferior_registers, store_inferior_registers):
8616 Refactor as methods.
8617 (_initialize_tile_linux_nat): Adjust to C++ification.
8618
8619 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8620 (the_xtensa_linux_nat_target): New.
8621 (xtensa_linux_fetch_inferior_registers)
8622 (xtensa_linux_store_inferior_registers): Refactor as
8623 xtensa_linux_nat_target methods.
8624 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8625
8626 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8627 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8628 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8629 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8630 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8631 (fbsd_stopped_by_sw_breakpoint)
8632 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8633 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8634 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8635 (fbsd_post_startup_inferior, fbsd_post_attach)
8636 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8637 (fbsd_set_syscall_catchpoint)
8638 (super_xfer_partial, super_resume, super_wait)
8639 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8640 (fbsd_handle_debug_trap): Remove target_ops parameter.
8641 (fbsd_nat_add_target): Delete.
8642 * fbsd-nat.h: Include "inf-ptrace.h".
8643 (fbsd_nat_add_target): Delete.
8644 (USE_SIGTRAP_SIGINFO): Define.
8645 (fbsd_nat_target): New class.
8646
8647 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8648 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8649 (amd64bsd_target): Delete.
8650 * amd64-bsd-nat.h: New file.
8651 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8652 "x86-bsd-nat.h".
8653 (amd64_fbsd_nat_target): New class.
8654 (the_amd64_fbsd_nat_target): New.
8655 (amd64fbsd_read_description): Refactor as method of
8656 amd64_fbsd_nat_target.
8657 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8658 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8659 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8660 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8661 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8662 (i386bsd_target): Delete.
8663 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8664 (i386bsd_fetch_inferior_registers)
8665 (i386bsd_store_inferior_registers): Declare.
8666 (i386_bsd_nat_target): New class.
8667 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8668 (the_i386_fbsd_nat_target): New.
8669 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8670 i386_fbsd_nat_target methods.
8671 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8672 (_initialize_i386fbsd_nat): Adjust to C++ification.
8673 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8674 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8675 (_initialize_x86_bsd_nat): Adjust to C++ification.
8676 * x86-bsd-nat.h: Include "x86-nat.h".
8677 (x86bsd_target): Delete declaration.
8678 (x86bsd_nat_target): New class.
8679
8680 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8681 (the_aarch64_fbsd_nat_target): New.
8682 (aarch64_fbsd_fetch_inferior_registers)
8683 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8684 aarch64_fbsd_nat_target.
8685 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8686 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8687 (the_alpha_bsd_nat_target): New.
8688 (alphabsd_fetch_inferior_registers)
8689 (alphabsd_store_inferior_registers): Refactor as
8690 alpha_bsd_nat_target methods.
8691 (_initialize_alphabsd_nat): Refactor as methods of
8692 alpha_bsd_nat_target.
8693 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8694 (the_amd64_nbsd_nat_target): New.
8695 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8696 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8697 (the_amd64_obsd_nat_target): New.
8698 (_initialize_amd64obsd_nat): Adjust to C++ification.
8699 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8700 (the_arm_fbsd_nat_target): New.
8701 (arm_fbsd_fetch_inferior_registers)
8702 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8703 (_initialize_arm_fbsd_nat): Refactor as methods of
8704 arm_fbsd_nat_target.
8705 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8706 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8707 (the_arm_netbsd_nat_target): New.
8708 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8709 arm_netbsd_nat_target.
8710 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8711 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8712 (the_hppa_nbsd_nat_target): New.
8713 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8714 hppa_nbsd_nat_target methods.
8715 (_initialize_hppanbsd_nat): Adjust to C++ification.
8716 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8717 (the_hppa_obsd_nat_target): New.
8718 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8719 methods of hppa_obsd_nat_target.
8720 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8721 add_target.
8722 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8723 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8724 add_target.
8725 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8726 (_initialize_i386obsd_nat): Use add_target.
8727 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8728 (the_m68k_bsd_nat_target): New.
8729 (m68kbsd_fetch_inferior_registers)
8730 (m68kbsd_store_inferior_registers): Refactor as methods of
8731 m68k_bsd_nat_target.
8732 (_initialize_m68kbsd_nat): Adjust to C++ification.
8733 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8734 (the_mips_fbsd_nat_target): New.
8735 (mips_fbsd_fetch_inferior_registers)
8736 (mips_fbsd_store_inferior_registers): Refactor as methods of
8737 mips_fbsd_nat_target.
8738 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8739 add_target.
8740 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8741 (the_mips_nbsd_nat_target): New.
8742 (mipsnbsd_fetch_inferior_registers)
8743 (mipsnbsd_store_inferior_registers): Refactor as methods of
8744 mips_nbsd_nat_target.
8745 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8746 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8747 (the_mips64_obsd_nat_target): New.
8748 (mips64obsd_fetch_inferior_registers)
8749 (mips64obsd_store_inferior_registers): Refactor as methods of
8750 mips64_obsd_nat_target.
8751 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8752 add_target.
8753 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8754 nbsd_nat_target.
8755 * nbsd-nat.h: Include "inf-ptrace.h".
8756 (nbsd_nat_target): New class.
8757 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8758 (obsd_wait): Refactor as methods of obsd_nat_target.
8759 (obsd_add_target): Delete.
8760 * obsd-nat.h: Include "inf-ptrace.h".
8761 (obsd_nat_target): New class.
8762 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8763 (the_ppc_fbsd_nat_target): New.
8764 (ppcfbsd_fetch_inferior_registers)
8765 (ppcfbsd_store_inferior_registers): Refactor as methods of
8766 ppc_fbsd_nat_target.
8767 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8768 add_target.
8769 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8770 (the_ppc_nbsd_nat_target): New.
8771 (ppcnbsd_fetch_inferior_registers)
8772 (ppcnbsd_store_inferior_registers): Refactor as methods of
8773 ppc_nbsd_nat_target.
8774 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8775 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8776 (the_ppc_obsd_nat_target): New.
8777 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8778 methods of ppc_obsd_nat_target.
8779 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8780 add_target.
8781 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8782 (the_sh_nbsd_nat_target): New.
8783 (shnbsd_fetch_inferior_registers)
8784 (shnbsd_store_inferior_registers): Refactor as methods of
8785 sh_nbsd_nat_target.
8786 (_initialize_shnbsd_nat): Adjust to C++ification.
8787 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8788 (inf_ptrace_xfer_partial): Delete.
8789 (sparc_xfer_partial, sparc_target): Delete.
8790 * sparc-nat.h (sparc_fetch_inferior_registers)
8791 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8792 (sparc_target): Delete function declaration.
8793 (sparc_target): New template class.
8794 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8795 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8796 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8797 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8798 add_target.
8799 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8800 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8801 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8802 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8803 add_target.
8804 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8805 (the_vax_bsd_nat_target): New.
8806 (vaxbsd_fetch_inferior_registers)
8807 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8808 methods.
8809 (_initialize_vaxbsd_nat): Adjust to C++ification.
8810
8811 * bsd-kvm.c (bsd_kvm_target): New class.
8812 (bsd_kvm_ops): Now a bsd_kvm_target.
8813 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8814 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8815 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8816 bsd_kvm_target.
8817 (bsd_kvm_return_one): Delete.
8818 (bsd_kvm_add_target): Adjust to C++ification.
8819
8820 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8821 (nto_procfs_target_procfs): New classes.
8822 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8823 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8824 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8825 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8826 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8827 (procfs_remove_hw_breakpoint, procfs_resume)
8828 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8829 (procfs_kill_inferior, procfs_store_registers)
8830 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8831 as methods of nto_procfs_target.
8832 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8833 (nto_native_ops): Delete.
8834 (procfs_open, procfs_native_open): Delete.
8835 (nto_native_ops): Now an nto_procfs_target_native.
8836 (init_procfs_targets): Adjust to C++ification.
8837 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8838 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8839 Refactor as methods of nto_procfs_target.
8840
8841 * go32-nat.c (go32_nat_target): New class.
8842 (the_go32_nat_target): New.
8843 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8844 (go32_store_registers, go32_xfer_partial, go32_files_info)
8845 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8846 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8847 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8848 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8849 (go32_target): Delete.
8850 (_initialize_go32_nat): Adjust to C++ification.
8851
8852 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8853 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8854 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8855 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8856 gnu_nat_target.
8857 (gnu_target): Delete.
8858 * gnu-nat.h (gnu_target): Delete.
8859 (gnu_nat_target): New class.
8860 * i386-gnu-nat.c (gnu_base_target): New.
8861 (i386_gnu_nat_target): New class.
8862 (the_i386_gnu_nat_target): New.
8863 (_initialize_i386gnu_nat): Adjust to C++ification.
8864
8865 2018-05-02 Pedro Alves <palves@redhat.com>
8866
8867 * bfd-target.c (target_bfd_xclose): Rename to ...
8868 (target_bfd_close): ... this.
8869 (target_bfd_reopen): Adjust.
8870 * target.c (target_close): Remove references to to_xclose.
8871 * target.h (target_ops::to_xclose): Delete.
8872 (target_ops::to_close): Update comments.
8873
8874 2018-05-02 Pedro Alves <palves@redhat.com>
8875
8876 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8877 "linux-nat.h".
8878 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8879 * inf-ptrace.c (inf_ptrace_register_u_offset)
8880 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8881 (inf_ptrace_store_register, inf_ptrace_store_registers)
8882 (inf_ptrace_trad_target): Move to ...
8883 * linux-nat-trad.c: ... this new file.
8884 * linux-nat-trad.h: New file.
8885 * linux-nat.c (linux_target_install_ops): Make extern.
8886 (linux_trad_target): Delete.
8887 * linux-nat.h (linux_trad_target): Delete declaration.
8888 (linux_target_install_ops): Declare.
8889 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8890 "linux-nat.h".
8891
8892 2018-05-02 Pedro Alves <palves@redhat.com>
8893
8894 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8895 procfs_target/add_target here.
8896 * procfs.c (procfs_target): Make static.
8897 (_initialize_procfs): Call add_target here.
8898 * procfs.h (struct target_ops): Remove forward declaration.
8899 (procfs_target): Remove declaration.
8900 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8901
8902 2018-05-02 Pedro Alves <palves@redhat.com>
8903
8904 * procfs.c (procfs_stopped_by_watchpoint)
8905 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8906 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8907 Forward declare.
8908 (procfs_use_watchpoints): Delete, move contents...
8909 (procfs_target): ... here.
8910 * procfs.h (procfs_use_watchpoints): Delete declaration.
8911 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8912 procfs_use_watchpoints.
8913 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8914 procfs_use_watchpoints.
8915
8916 2018-05-02 Tom Tromey <tom@tromey.com>
8917
8918 PR python/20084:
8919 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8920 and var_zuinteger_unlimited.
8921 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8922 and PARAM_ZUINTEGER_UNLIMITED.
8923 (set_parameter_value): Handle var_zuinteger and
8924 var_zuinteger_unlimited.
8925 (add_setshow_generic): Likewise.
8926 (parmpy_init): Likewise.
8927
8928 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8929
8930 PR rust/23124
8931 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8932 pointer is not null before dereferencing it.
8933
8934 2018-04-30 Tom Tromey <tom@tromey.com>
8935
8936 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8937 is_mi_like_p.
8938
8939 2018-04-30 Tom Tromey <tom@tromey.com>
8940
8941 * breakpoint.c (mention): Remove use of is_mi_like_p.
8942 (print_mention_ranged_breakpoint): Likewise.
8943 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
8944 of is_mi_like_p.
8945
8946 2018-04-30 Tom Tromey <tom@tromey.com>
8947
8948 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
8949
8950 2018-04-30 Tom Tromey <tom@tromey.com>
8951
8952 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
8953 (info_spu_event_command): Remove some uses of is_mi_like_p.
8954
8955 2018-04-30 Tom Tromey <tom@tromey.com>
8956
8957 * python/py-framefilter.c (py_print_single_arg)
8958 (enumerate_locals, py_print_args, py_print_frame): Remove some
8959 uses of is_mi_like_p.
8960
8961 2018-04-30 Tom Tromey <tom@tromey.com>
8962
8963 * ui-out.c: Update.
8964 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
8965 * ui-out.h (ui_out::is_mi_like_p): Now const.
8966 (ui_out::do_is_mi_like_p): Now const.
8967 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
8968
8969 2018-04-30 Tom Tromey <tom@tromey.com>
8970
8971 * varobj.c (varobj_set_visualizer): Use new_reference.
8972 * python/python.c (gdbpy_decode_line): Use new_reference.
8973 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
8974 new_reference.
8975
8976 2018-04-30 Tom Tromey <tom@tromey.com>
8977
8978 * varobj.c (install_new_value): Use new_reference.
8979 * value.h (value_incref): Return void. Swap intro comment with
8980 value_decref.
8981 * value.c (set_value_parent): Use new_reference.
8982 (value_incref): Return void. Update intro comment.
8983 (release_value): Use new_reference.
8984 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
8985
8986 2018-04-30 Tom Tromey <tom@tromey.com>
8987
8988 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
8989 * gdb_bfd.h (new_bfd_ref): Remove.
8990 (gdb_bfd_open): Update comment.
8991 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
8992 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
8993 (gdb_bfd_fdopenr): Use new_reference.
8994 * exec.c (exec_file_attach): Use new_reference.
8995
8996 2018-04-30 Tom Tromey <tom@tromey.com>
8997
8998 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
8999 method.
9000
9001 2018-04-30 Tom Tromey <tom@tromey.com>
9002
9003 * jit.c (jit_read_code_entry): Use type_align.
9004 * i386-tdep.c (i386_gdbarch_init): Don't call
9005 set_gdbarch_long_long_align_bit.
9006 * gdbarch.sh: Remove long_long_align_bit.
9007 * gdbarch.c, gdbarch.h: Rebuild.
9008 * arc-tdep.c (arc_type_align): New function.
9009 (arc_gdbarch_init): Use arc_type_align. Don't call
9010 set_gdbarch_long_long_align_bit.
9011
9012 2018-04-30 Tom Tromey <tom@tromey.com>
9013
9014 * rust-lang.c (rust_type_alignment): Remove.
9015 (rust_composite_type): Use type_align.
9016
9017 2018-04-30 Tom Tromey <tom@tromey.com>
9018
9019 * NEWS: Mention Type.align.
9020 * python/py-type.c (typy_get_alignof): New function.
9021 (type_object_getset): Add "alignof".
9022
9023 2018-04-30 Tom Tromey <tom@tromey.com>
9024
9025 PR exp/17095:
9026 * NEWS: Update.
9027 * std-operator.def (UNOP_ALIGNOF): New operator.
9028 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
9029 New.
9030 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
9031 * c-lang.c (c_op_print_tab): Add alignof.
9032 * c-exp.y (ALIGNOF): New token.
9033 (exp): Add "ALIGNOF" production.
9034 (ident_tokens): Add _Alignof and alignof.
9035
9036 2018-04-30 Tom Tromey <tom@tromey.com>
9037
9038 * i386-tdep.c (i386_type_align): New function.
9039 (i386_gdbarch_init): Update.
9040 * gdbarch.sh (type_align): New method.
9041 * gdbarch.c, gdbarch.h: Rebuild.
9042 * arch-utils.h (default_type_align): Declare.
9043 * arch-utils.c (default_type_align): New function.
9044 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9045 (struct type) <align_log2>: New field.
9046 <instance_flags>: Now a bitfield.
9047 (TYPE_RAW_ALIGN): New macro.
9048 (type_align, type_raw_align, set_type_align): Declare.
9049 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9050 functions.
9051 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9052 (get_alignment, maybe_set_alignment): New functions.
9053 (read_structure_type, read_enumeration_type, read_array_type)
9054 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9055 (read_subrange_type, read_base_type): Set type alignment.
9056
9057 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9058
9059 * dwarf2read.c (read_index_from_section): Use bool.
9060
9061 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9062
9063 PR gdb/22950
9064 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9065 with #ifdef.
9066
9067 2018-04-29 John Reiser <jreiser@BitWagon.com>
9068
9069 PR build/22873
9070 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9071 last step, and do it atomically.
9072
9073 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
9074
9075 * compile/compile-c-types.c (convert_int, convert_float):
9076 Update for C FE v1.
9077
9078 2018-04-27 Tom Tromey <tom@tromey.com>
9079
9080 PR rust/22545:
9081 * rust-lang.c (rust_inclusive_range_type_p): New function.
9082 (rust_range): Handle inclusive ranges.
9083 (rust_compute_range): Likewise.
9084 * rust-exp.y (struct rust_op) <inclusive>: New field.
9085 (DOTDOTEQ): New constant.
9086 (range_expr): Add "..=" productions.
9087 (operator_tokens): Add "..=" token.
9088 (ast_range): Add "inclusive" parameter.
9089 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
9090 ranges.
9091 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
9092 bounds values.
9093 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
9094 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
9095 Update comments.
9096 * expprint.c (print_subexp_standard): Handle new bounds values.
9097 (dump_subexp_body_standard): Likewise.
9098
9099 2018-04-27 Tom Tromey <tom@tromey.com>
9100
9101 * configure: Rebuild.
9102 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
9103 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
9104 "OVERRIDE".
9105 (class symbol_needs_eval_context): Likewise.
9106 * dwarf2read.c (mock_mapped_index::symbol_name_count)
9107 (mock_mapped_index::symbol_name_at): Use "override". Remove
9108 "virtual".
9109 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
9110 "override".
9111 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
9112 * aarch64-tdep.c (instruction_reader::read): Use "override".
9113 (instruction_reader_test::read): Likewise.
9114 * arm-tdep.c (instruction_reader::read): Use "override".
9115 (instruction_reader_thumb::read): Likewise.
9116
9117 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
9118
9119 PR remote/9665
9120 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
9121 instead of remote_send.
9122 (remote_send): Remove.
9123
9124 2018-04-26 Pedro Alves <palves@redhat.com>
9125
9126 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
9127 find_function_start_sal instead of find_pc_line.
9128
9129 2018-04-26 Pedro Alves <palves@redhat.com>
9130
9131 * breakpoint.c (set_breakpoint_location_function): Handle
9132 mst_data_gnu_ifunc.
9133 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
9134 * elfread.c (elf_symtab_read): Give data symbols with
9135 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
9136 (elf_rel_plt_read): Update comment.
9137 * linespec.c (convert_linespec_to_sals): Handle
9138 mst_data_gnu_ifunc.
9139 (minsym_found): Handle mst_data_gnu_ifunc.
9140 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
9141 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
9142 * parse.c (find_minsym_type_and_address): Handle
9143 mst_data_gnu_ifunc.
9144 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
9145 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
9146 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
9147 comment.
9148 <mst_data_gnu_ifunc>: New enumerator.
9149
9150 2018-04-26 Pedro Alves <palves@redhat.com>
9151
9152 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
9153 (lookup_minimal_symbol_by_pc_section): ... this. Replace
9154 'want_trampoline' parameter by a lookup_msym_prefer parameter.
9155 Handle it.
9156 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
9157 (lookup_minimal_symbol_by_pc): Adjust.
9158 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
9159 (lookup_solib_trampoline_symbol_by_pc): Adjust.
9160 * minsyms.h (lookup_msym_prefer): New enum.
9161 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9162 parameter by a lookup_msym_prefer parameter.
9163
9164 2018-04-26 Pedro Alves <palves@redhat.com>
9165
9166 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
9167 ends in "@plt" instead of looking at the symbol's section.
9168
9169 2018-04-26 Pedro Alves <palves@redhat.com>
9170
9171 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
9172 all references.
9173 (find_pc_partial_function_gnu_ifunc): Rename to ...
9174 (find_pc_partial_function): ... this, and remove references to
9175 'is_gnu_ifunc_p'.
9176 (find_pc_partial_function): Delete old implementation.
9177 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
9178
9179 2018-04-26 Pedro Alves <palves@redhat.com>
9180
9181 * linespec.c (struct bound_minimal_symbol_search_key): New.
9182 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
9183 skip first line if we found a GNU ifunc minimal symbol by name.
9184 (compare_msymbols): Change parameters to work with a destructured
9185 lhs minsym.
9186 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
9187 functions.
9188
9189 2018-04-26 Pedro Alves <palves@redhat.com>
9190
9191 * breakpoint.c (set_breakpoint_location_function): Don't resolve
9192 ifunc targets here. Instead, if we have an ifunc minsym, use its
9193 address/name.
9194 (add_location_to_breakpoint): Store the minsym and the objfile in
9195 the breakpoint location.
9196 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
9197 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
9198 Record the minsym in the sal.
9199 * symtab.h (symtab_and_line) <msymbol>: New field.
9200
9201 2018-04-26 Pedro Alves <palves@redhat.com>
9202
9203 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
9204 unless we actually resolved the ifunc.
9205
9206 2018-04-26 Pedro Alves <palves@redhat.com>
9207
9208 * c-exp.y (variable production): Prefer ifunc minsyms over
9209 regular function symbols.
9210 * symtab.c (find_gnu_ifunc): New function.
9211 * minsyms.h (lookup_msym_prefer): New enum.
9212 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9213 parameter by a lookup_msym_prefer parameter.
9214 * symtab.h (find_gnu_ifunc): New declaration.
9215
9216 2018-04-26 Pedro Alves <palves@redhat.com>
9217
9218 * blockframe.c (find_gnu_ifunc_target_type): New function.
9219 (find_function_type): New.
9220 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9221 return a value with a memory address.
9222 (eval_call): For calls to GNU ifunc functions, try to find the
9223 type of the target function from the type that the resolver
9224 returns.
9225 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9226 symbols.
9227 * infcall.c (find_function_return_type): Delete.
9228 (find_function_addr): Add 'function_type' parameter. For calls to
9229 GNU ifunc functions, try to find the type of the target function
9230 from the type that the resolver returns, and return it via
9231 FUNCTION_TYPE.
9232 (call_function_by_hand_dummy): Adjust to use the function type
9233 returned by find_function_addr.
9234 (find_function_addr): Add 'function_type' parameter and move
9235 description here.
9236 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9237 declarations.
9238
9239 2018-04-26 Pedro Alves <palves@redhat.com>
9240
9241 * c-exp.y (variable production): Skip finding an alias for ifunc
9242 symbols.
9243
9244 2018-04-26 Pedro Alves <palves@redhat.com>
9245
9246 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9247
9248 2018-04-25 Pedro Alves <palves@redhat.com>
9249
9250 * infcmd.c (kill_command): Print the pid as string, not the whole
9251 thread's ptid. Add comment. s/has been killed/killed/ in output
9252 message.
9253 * remote.c (remote_detach_1): Print the pid as string, not the
9254 whole thread's ptid.
9255
9256 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9257 Sergio Durigan Junior <sergiodj@redhat.com>
9258 Pedro Alves <palves@redhat.com>
9259
9260 * infcmd.c (kill_command): Print message when inferior has
9261 been killed.
9262 * inferior.c (print_inferior_events): Remove 'static'. Set as
9263 '1'.
9264 (add_inferior): Improve message printed when
9265 'print_inferior_events' is on.
9266 (exit_inferior): Remove message printed when
9267 'print_inferior_events' is on.
9268 (detach_inferior): Improve message printed when
9269 'print_inferior_events' is on.
9270 (initialize_inferiors): Use 'add_inferior_silent' to set
9271 'current_inferior_'.
9272 * inferior.h (print_inferior_events): Declare here as
9273 'extern'.
9274 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9275 '[Detaching...]' messages when 'print_inferior_events' is on.
9276 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9277 as prefix/suffix for messages. Remove periods. Fix erroneous
9278 'Detaching after fork from child...', replace it by '... from
9279 parent...'.
9280 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9281 prefix/suffix when printing 'Detaching...' messages. Print
9282 them when 'print_inferior_events' is on.
9283 * remote.c (remote_detach_1): Print message when detaching
9284 from inferior and '!is_fork_parent'.
9285
9286 2018-04-24 Tom Tromey <tom@tromey.com>
9287
9288 * cli-out.h: Reindent.
9289
9290 2018-04-24 Tom Tromey <tom@tromey.com>
9291
9292 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9293 (cli_ui_out::do_field_string): Use fputs_filtered.
9294 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9295
9296 2018-04-23 Tom Tromey <tom@tromey.com>
9297
9298 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9299 gdb::unique_xmalloc_ptr.
9300
9301 2018-04-23 Tom Tromey <tom@tromey.com>
9302
9303 * configure: Rebuild.
9304
9305 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9306
9307 PR gdb/23095
9308 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9309 prepare_for_testing. Set normal_bp to r_debug_state if target
9310 is bsd.
9311
9312 2018-04-21 Pedro Alves <palves@redhat.com>
9313 Rajendra SY <rajendra.sy@gmail.com>
9314
9315 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9316 * remote.c (extended_remote_attach): In all-stop mode, mark the
9317 thread as executing.
9318
9319 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9320
9321 * thread.c (thread_apply_all_command): Fix comment.
9322 (thread_command): Fix comment.
9323
9324 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9325
9326 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9327 parameter.
9328 * features/aarch64-core.c (create_feature_aarch64_core):
9329 Regenerate.
9330 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9331 Likewise.
9332 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9333 Likewise.
9334 * features/i386/32bit-avx512.c
9335 (create_feature_i386_32bit_avx512): Likewise.
9336 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9337 Likewise.
9338 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9339 Likewise.
9340 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9341 Likewise.
9342 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9343 Likewise.
9344 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9345 Likewise.
9346 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9347 Likewise.
9348 * features/i386/64bit-avx512.c
9349 (create_feature_i386_64bit_avx512): Likewise.
9350 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9351 Likewise.
9352 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9353 Likewise.
9354 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9355 Likewise.
9356 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9357 Likewise.
9358 * features/i386/64bit-segments.c
9359 (create_feature_i386_64bit_segments): Likewise.
9360 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9361 Likewise.
9362 * features/i386/x32-core.c
9363 (create_feature_i386_x32_core): Likewise.
9364 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9365 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9366 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9367 * target-descriptions.c: In generated code, don't pass xml
9368 filename.
9369
9370 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9371
9372 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9373 (print_xml_feature::visit_post): Likewise.
9374 (print_xml_feature::visit): Likewise.
9375 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9376 (print_xml_feature): Add new class.
9377 * regformats/regdat.sh: Null xmltarget on feature targets.
9378 * target-descriptions.c (struct target_desc): Add xmltarget.
9379 (maintenance_check_tdesc_xml_convert): Add unittest function.
9380 (tdesc_get_features_xml): Add function to get xml.
9381 (maintenance_check_xml_descriptions): Test xml generation.
9382 * xml-tdesc.c (string_read_description_xml): Add function.
9383 * xml-tdesc.h (string_read_description_xml): Add declaration.
9384
9385 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9386
9387 * features/Makefile: Add feature marker to targets with new style
9388 target descriptions.
9389 * regformats/aarch64.dat: Regenerate.
9390 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9391 * regformats/i386/amd64-avx-linux.dat: Likewise.
9392 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9393 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9394 * regformats/i386/amd64-linux.dat: Likewise.
9395 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9396 * regformats/i386/amd64.dat: Likewise.
9397 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9398 * regformats/i386/i386-avx-linux.dat: Likewise.
9399 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9400 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9401 * regformats/i386/i386-linux.dat: Likewise.
9402 * regformats/i386/i386-mmx-linux.dat: Likewise.
9403 * regformats/i386/i386-mpx-linux.dat: Likewise.
9404 * regformats/i386/i386.dat: Likewise.
9405 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9406 * regformats/i386/x32-avx-linux.dat: Likewise.
9407 * regformats/i386/x32-linux.dat: Likewise.
9408 * regformats/tic6x-c62x-linux.dat: Likewise.
9409 * regformats/tic6x-c64x-linux.dat: Likewise.
9410 * regformats/tic6x-c64xp-linux.dat: Likewise.
9411 * regformats/regdat.sh: Parse feature marker.
9412
9413 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9414
9415 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9416 (tdesc_osabi_name): Likewise.
9417 * target-descriptions.c (tdesc_architecture_name): Add new
9418 function.
9419 (tdesc_osabi_name): Likewise.
9420
9421 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9422
9423 * common/tdesc.c (tdesc_predefined_type): Move to here.
9424 (tdesc_named_type): Likewise.
9425 (tdesc_create_vector): Likewise.
9426 (tdesc_create_struct): Likewise.
9427 (tdesc_set_struct_size): Likewise.
9428 (tdesc_create_union): Likewise.
9429 (tdesc_create_flags): Likewise.
9430 (tdesc_create_enum): Likewise.
9431 (tdesc_add_field): Likewise.
9432 (tdesc_add_typed_bitfield): Likewise.
9433 (tdesc_add_bitfield): Likewise.
9434 (tdesc_add_flag): Likewise.
9435 (tdesc_add_enum_value): Likewise.
9436 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9437 (struct tdesc_type_vector): Likewise.
9438 (struct tdesc_type_field): Likewise.
9439 (struct tdesc_type_with_fields): Likewise.
9440 (tdesc_create_enum): Add declaration.
9441 (tdesc_add_typed_bitfield): Likewise.
9442 (tdesc_add_enum_value): Likewise.
9443 * target-descriptions.c (tdesc_type_field): Move from here.
9444 (tdesc_type_builtin): Likewise.
9445 (tdesc_type_vector): Likewise.
9446 (tdesc_type_with_fields): Likewise.
9447 (tdesc_predefined_types): Likewise.
9448 (tdesc_named_type): Likewise.
9449 (tdesc_create_vector): Likewise.
9450 (tdesc_create_struct): Likewise.
9451 (tdesc_set_struct_size): Likewise.
9452 (tdesc_create_union): Likewise.
9453 (tdesc_create_flags): Likewise.
9454 (tdesc_create_enum): Likewise.
9455 (tdesc_add_field): Likewise.
9456 (tdesc_add_typed_bitfield): Likewise.
9457 (tdesc_add_bitfield): Likewise.
9458 (tdesc_add_flag): Likewise.
9459 (tdesc_add_enum_value): Likewise.
9460 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9461 (tdesc_add_typed_bitfield): Likewise.
9462 (tdesc_add_enum_value): Likewise.
9463
9464 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9465
9466 * common/tdesc.c (tdesc_feature::accept): Move to here.
9467 (tdesc_feature::operator==): Likewise.
9468 (tdesc_create_reg): Likewise.
9469 * common/tdesc.h (tdesc_type_kind): Likewise.
9470 (struct tdesc_type): Likewise.
9471 (struct tdesc_feature): Likewise.
9472 * regformats/regdat.sh: Create a feature.
9473 * target-descriptions.c (tdesc_type_kind): Move from here.
9474 (tdesc_type): Likewise.
9475 (tdesc_type_up): Likewise.
9476 (tdesc_feature): Likewise.
9477 (tdesc_create_reg): Likewise.
9478
9479 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9480
9481 * Makefile.in: Add arch/tdesc.c
9482 * common/tdesc.c: New file.
9483 * common/tdesc.h (tdesc_element_visitor): Move to here.
9484 (tdesc_element): Likewise.
9485 (tdesc_reg): Likewise.
9486 (tdesc_reg_up): Likewise.
9487 * regformats/regdef.h (reg): Add offset to constructors.
9488 * target-descriptions.c (tdesc_element_visitor): Move from here.
9489 (tdesc_element): Likewise.
9490 (tdesc_reg): Likewise.
9491 (tdesc_reg_up): Likewise.
9492
9493 2018-04-17 Tom Tromey <tom@tromey.com>
9494
9495 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9496 discriminant field.
9497
9498 2018-04-17 Tom Tromey <tom@tromey.com>
9499
9500 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9501
9502 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9503
9504 * symtab.c (print_symbol_info): Skip printing filename and line
9505 number when `last' is NULL.
9506 (symtab_symbol_info): Use empty string instead of NULL for first
9507 invocation of print_symbol_info.
9508 (rbreak_command): Pass NULL to `last' parameter of
9509 print_symbol_info.
9510
9511 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9512
9513 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9514 instead of nullptr.
9515
9516 2018-04-16 Pedro Alves <palves@redhat.com>
9517
9518 * MAINTAINERS (sh): Remove.
9519 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9520 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9521 (ALLDEPFILES): Remove sh64-tdep.c.
9522 * NEWS: Mentions that support for SH-5/SH64 is removed.
9523 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9524 (sh*-*-openbsd*): Ditto.
9525 (sh64-*-elf*): Remove.
9526 (sh*): Remove.
9527 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9528 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9529 * sh-tdep.c: No longer include "sh64-tdep.h".
9530 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9531 * sh64-tdep.c, sh64-tdep.h: Remove files.
9532
9533 2018-04-16 Pedro Alves <palves@redhat.com>
9534
9535 * MAINTAINERS: Remove m88k.
9536 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9537 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9538 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9539 * NEWS: Mention that support for m88k was removed.
9540 * configure.host (m88*-*-*): Remove support.
9541 * configure.nat (m88k-*-*): Remove support.
9542 * configure.tgt (m88*-*-openbsd*): Remove.
9543 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9544
9545 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9546
9547 * configure.tgt (x86_tobjs): New variable.
9548 (amd64_tobjs, i386_tobjs): Use it.
9549
9550 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9551
9552 * symtab.c (print_symbol_info): Precede the symbol definition by
9553 the line number when available.
9554 * NEWS: Advertise this enhancement.
9555
9556 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9557
9558 * NEWS (New options): announce set/show record btrace cpu.
9559 * btrace.c: Include record-btrace.h.
9560 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9561 the vendor is unknown.
9562 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9563 Maybe overwrite the btrace configuration's cpu.
9564 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9565 (btrace_fetch): Add cpu parameter. Update callers.
9566 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9567 Maybe overwrite the btrace configuration's cpu. Skip enabling
9568 errata workarounds if the vendor is unknown.
9569 * python/py-record-btrace.c: Include record-btrace.h.
9570 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9571 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9572 * record-btrace.c (record_btrace_cpu_state_kind): New.
9573 (record_btrace_cpu): New.
9574 (set_record_btrace_cpu_cmdlist): New.
9575 (record_btrace_get_cpu): New.
9576 (require_btrace_thread, record_btrace_info)
9577 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9578 (cmd_set_record_btrace_cpu_none): New.
9579 (cmd_set_record_btrace_cpu_auto): New.
9580 (cmd_set_record_btrace_cpu): New.
9581 (cmd_show_record_btrace_cpu): New.
9582 (_initialize_record_btrace): Initialize set/show record btrace cpu
9583 commands.
9584 * record-btrace.h (record_btrace_get_cpu): New.
9585
9586 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9587
9588 * record.c (set_record_command): Fix typo in message.
9589
9590 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9591
9592 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9593
9594 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9595
9596 * infrun.c (process_event_stop_test): Call
9597 gdbarch_in_indirect_branch_thunk.
9598 * gdbarch.sh (in_indirect_branch_thunk): New.
9599 * gdbarch.c: Regenerated.
9600 * gdbarch.h: Regenerated.
9601 * x86-tdep.h: New.
9602 * x86-tdep.c: New.
9603 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9604 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9605 (ALLDEPFILES): Add x86-tdep.c.
9606 * arch-utils.h (default_in_indirect_branch_thunk): New.
9607 * arch-utils.c (default_in_indirect_branch_thunk): New.
9608 * i386-tdep: Include x86-tdep.h.
9609 (i386_in_indirect_branch_thunk): New.
9610 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9611 function.
9612 * amd64-tdep: Include x86-tdep.h.
9613 (amd64_in_indirect_branch_thunk): New.
9614 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9615
9616 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9617
9618 PR gdb/23053
9619 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9620 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9621 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9622 regression.
9623
9624 2018-04-12 Tom Tromey <tom@tromey.com>
9625
9626 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9627 (rust_evaluate_subexp): Likewise.
9628
9629 2018-04-12 Pedro Alves <palves@redhat.com>
9630
9631 * procfs.c (procfs_detach): Make forward declaration's prototype
9632 match definition's protototype.
9633 (proc_get_LDT_entry): Remove stale do_cleanups call.
9634
9635 2018-04-12 Pedro Alves <palves@redhat.com>
9636
9637 * target.h (target_ops::to_has_exited): Delete.
9638 (target_has_exited): Delete.
9639 * target-delegates.c: Regenerate.
9640
9641 2018-04-11 Pedro Alves <palves@redhat.com>
9642
9643 * target.c (fileio_fh_t::t): Add comment.
9644 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9645 (target_fileio_close): Handle a NULL target.
9646 (invalidate_fileio_fh): New.
9647 (target_close): Call it.
9648 * remote.c (remote_hostio_send_command): No longer check whether
9649 remote_desc is open.
9650
9651 2018-04-11 Pedro Alves <palves@redhat.com>
9652
9653 * target.c (fileio_fh_t): Make it a named struct instead of a
9654 typedef.
9655 (fileio_fh_t::is_closed): New method.
9656 (DEF_VEC_O (fileio_fh_t)): Remove.
9657 (fileio_fhandles): Now a std::vector.
9658 (is_closed_fileio_fh): Delete.
9659 (acquire_fileio_fd): Adjust. Rename parameters.
9660 (release_fileio_fd): Adjust.
9661 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9662 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9663 (target_fileio_close): Adjust.
9664
9665 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9666
9667 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9668 index.
9669
9670 2018-04-10 Pedro Alves <palves@redhat.com>
9671
9672 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9673 (scoped_finish_thread_state): New class.
9674 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9675 cleanup.
9676 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9677 (fetch_inferior_event, normal_stop): Likewise.
9678 * thread.c (finish_thread_state_cleanup): Delete.
9679
9680 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9681 Pedro Alves <palves@redhat.com>
9682
9683 * value.c: Include "selftest.h" and "common/array-view.h".
9684 (struct range) <operator ==>: New.
9685 (test_ranges_contain): New.
9686 (check_ranges_vector): New.
9687 (test_insert_into_bit_range_vector): New.
9688 (_initialize_values): Register selftests.
9689 * common/array-view.h (operator==, operator!=): New.
9690
9691 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9692
9693 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9694 an iterator.
9695 * inline-frame.c: Include <algorithm>.
9696 (struct inline_state): Add constructor.
9697 (inline_state_s): Remove.
9698 (DEF_VEC_O(inline_state_s)): Remove.
9699 (inline_states): Change type to std::vector.
9700 (find_inline_frame_state): Adjust to std::vector.
9701 (allocate_inline_frame_state): Remove.
9702 (clear_inline_frame_state): Adjust to std::vector.
9703 (skip_inline_frames): Adjust to std::vector.
9704
9705 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9706
9707 * tracepoint.h (struct trace_state_variable): Add constructor.
9708 <name>: Change type to std::string.
9709 * tracepoint.c (tsv_s): Remove.
9710 (DEF_VEC_O(tsv_s)): Remove.
9711 (tvariables): Change to std::vector.
9712 (create_trace_state_variable): Adjust to std::vector.
9713 (find_trace_state_variable): Likewise.
9714 (find_trace_state_variable_by_number): Likewise.
9715 (delete_trace_state_variable): Likewise.
9716 (trace_variable_command): Adjust to std::string.
9717 (delete_trace_variable_command): Likewise.
9718 (tvariables_info_1): Adjust to std::vector.
9719 (save_trace_state_variables): Likewise.
9720 (start_tracing): Likewise.
9721 (merge_uploaded_trace_state_variables): Adjust to std::vector
9722 and std::string.
9723 * target.h (struct target_ops)
9724 <to_download_trace_state_variable>: Pass reference to
9725 trace_state_variable.
9726 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9727 * target-delegates.c: Re-generate.
9728 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9729 (mi_tsv_deleted): Likewise.
9730 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9731 * remote.c (remote_download_trace_state_variable): Change
9732 pointer to reference and adjust.
9733 * make-target-delegates (parse_argtypes): Handle references.
9734 (write_function_header): Likewise.
9735 (munge_type): Likewise.
9736
9737 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9738
9739 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9740 string_view-selftests.c.
9741 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9742 testsuite.
9743 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9744 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9745 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9746 * unittests/basic_string_view/element_access/char/1.cc:
9747 Likewise.
9748 * unittests/basic_string_view/element_access/char/empty.cc:
9749 Likewise.
9750 * unittests/basic_string_view/element_access/char/front_back.cc:
9751 Likewise.
9752 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9753 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9754 Likewise.
9755 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9756 Likewise.
9757 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9758 Likewise.
9759 * unittests/basic_string_view/operations/compare/char/1.cc:
9760 Likewise.
9761 * unittests/basic_string_view/operations/compare/char/13650.cc:
9762 Likewise.
9763 * unittests/basic_string_view/operations/copy/char/1.cc:
9764 Likewise.
9765 * unittests/basic_string_view/operations/data/char/1.cc:
9766 Likewise.
9767 * unittests/basic_string_view/operations/find/char/1.cc:
9768 Likewise.
9769 * unittests/basic_string_view/operations/find/char/2.cc:
9770 Likewise.
9771 * unittests/basic_string_view/operations/find/char/3.cc:
9772 Likewise.
9773 * unittests/basic_string_view/operations/find/char/4.cc:
9774 Likewise.
9775 * unittests/basic_string_view/operations/rfind/char/1.cc:
9776 Likewise.
9777 * unittests/basic_string_view/operations/rfind/char/2.cc:
9778 Likewise.
9779 * unittests/basic_string_view/operations/rfind/char/3.cc:
9780 Likewise.
9781 * unittests/basic_string_view/operations/substr/char/1.cc:
9782 Likewise.
9783 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9784 * unittests/string_view-selftests.c: New file.
9785
9786 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9787
9788 * unittests/basic_string_view/capacity/1.cc: New file.
9789 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9790 * unittests/basic_string_view/cons/char/1.cc: New file.
9791 * unittests/basic_string_view/cons/char/2.cc: New file.
9792 * unittests/basic_string_view/cons/char/3.cc: New file.
9793 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9794 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9795 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9796 * unittests/basic_string_view/element_access/char/1.cc: New file.
9797 * unittests/basic_string_view/element_access/char/2.cc: New file.
9798 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9799 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9800 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9801 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9802 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9803 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9804 * unittests/basic_string_view/include.cc: New file.
9805 * unittests/basic_string_view/inserters/char/1.cc: New file.
9806 * unittests/basic_string_view/inserters/char/2.cc: New file.
9807 * unittests/basic_string_view/inserters/char/3.cc: New file.
9808 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9809 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9810 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9811 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9812 * unittests/basic_string_view/literals/types.cc: New file.
9813 * unittests/basic_string_view/literals/values.cc: New file.
9814 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9815 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9816 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9817 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9818 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9819 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9820 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9821 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9822 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9823 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9824 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9825 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9826 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9827 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9828 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9829 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9830 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9831 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9832 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9833 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9834 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9835 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9836 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9837 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9838 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9839 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9840 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9841 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9842 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9843 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9844 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9845 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9846 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9847 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9848 * unittests/basic_string_view/operators/char/2.cc: New file.
9849 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9850 * unittests/basic_string_view/range_access/char/1.cc: New file.
9851 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9852 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9853 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9854 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9855 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9856 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9857 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9858 * unittests/basic_string_view/typedefs.cc: New file.
9859 * unittests/basic_string_view/types/1.cc: New file.
9860
9861 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9862
9863 * common/gdb_string_view.h: Remove libstdc++ implementation
9864 details, adjust to gdb reality.
9865 * common/gdb_string_view.tcc: Likewise.
9866 * cli/cli-script.c (struct string_view): Remove.
9867 (user_args) <m_args>: Change element type to gdb::string_view.
9868 (user_args::insert_args): Adjust.
9869
9870 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9871
9872 * common/gdb_string_view.h: New file.
9873 * common/gdb_string_view.tcc: New file.
9874
9875 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9876
9877 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9878 * configure: Re-generate.
9879
9880 2018-04-09 Pedro Alves <palves@redhat.com>
9881
9882 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9883 (set_target_gdbarch): Call
9884 gdb::observers::architecture_changed.notify instead of
9885 observer_notify_architecture_changed.
9886
9887 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9888
9889 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9890 (do_restore_current_traceframe_cleanup): Remove.
9891 (restore_current_traceframe_cleanup_dtor): Remove.
9892 (make_cleanup_restore_current_traceframe): Remove.
9893 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9894 New.
9895 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9896 * infrun.c (fetch_inferior_event): Use
9897 scoped_restore_current_traceframe.
9898
9899 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9900
9901 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9902 Remove.
9903 <n_allocated_type_units>: Remove.
9904 <all_type_units>: Change to std::vector.
9905 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9906 to std::vector change.
9907 (dwarf2_per_objfile::get_cutu): Likewise.
9908 (dwarf2_per_objfile::get_tu): Likewise.
9909 (create_signatured_type_table_from_index): Likewise.
9910 (create_signatured_type_table_from_debug_names): Likewise.
9911 (dw2_symtab_iter_next): Likewise.
9912 (dw2_print_stats): Likewise.
9913 (dw2_expand_all_symtabs): Likewise.
9914 (dw2_expand_marked_cus): Likewise.
9915 (dw2_debug_names_iterator::next): Likewise.
9916 (dwarf2_initialize_objfile): Likewise.
9917 (add_signatured_type_cu_to_table): Likewise.
9918 (create_all_type_units): Likewise.
9919 (add_type_unit): Likewise.
9920 (struct tu_abbrev_offset): Add constructor.
9921 (build_type_psymtabs_1): Adjust to std::vector change.
9922 (print_tu_stats): Likewise.
9923 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9924 (write_debug_names): Likewise.
9925
9926 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9927
9928 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9929 Make an std::vector.
9930 <n_comp_units>: Remove.
9931 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9932 to std::vector change.
9933 (dwarf2_per_objfile::get_cutu): Likewise.
9934 (dwarf2_per_objfile::get_cu): Likewise.
9935 (create_cus_from_index): Likewise.
9936 (create_addrmap_from_index): Likewise.
9937 (create_addrmap_from_aranges): Likewise.
9938 (dwarf2_read_index): Likewise.
9939 (dw2_find_last_source_symtab): Likewise.
9940 (dw2_map_symtabs_matching_filename): Likewise.
9941 (dw2_symtab_iter_next): Likewise.
9942 (dw2_print_stats): Likewise.
9943 (dw2_expand_all_symtabs): Likewise.
9944 (dw2_expand_symtabs_with_fullname): Likewise.
9945 (dw2_expand_marked_cus): Likewise.
9946 (dw2_map_symbol_filenames): Likewise.
9947 (create_cus_from_debug_names): Likewise.
9948 (dwarf2_read_debug_names): Likewise.
9949 (dw2_debug_names_iterator::next): Likewise.
9950 (dwarf2_initialize_objfile): Likewise.
9951 (set_partial_user): Likewise.
9952 (dwarf2_build_psymtabs_hard): Likewise.
9953 (read_comp_units_from_section): Remove arguments, adjust to
9954 std::vector change.
9955 (create_all_comp_units): Adjust to std::vector and
9956 read_comp_units_from_section changes.
9957 (dwarf2_find_containing_comp_unit): Adjust to std::vector
9958 change.
9959 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9960 (psyms_seen_size): Likewise.
9961 (write_gdbindex): Likewise.
9962 (write_debug_names): Likewise.
9963
9964 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9965
9966 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
9967 with dwarf2_per_objfile.
9968 (create_cus_from_index): Likewise.
9969 (create_signatured_type_table_from_index): Likewise.
9970 (dwarf2_read_index): Likewise.
9971 (dwarf2_initialize_objfile): Likewise.
9972 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
9973 per_cu rather than get_dwarf2_per_objfile.
9974
9975 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9976
9977 * dwarf2read.h (struct signatured_type): Forward declare.
9978 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
9979 New methods.
9980 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
9981 (dw2_get_cutu): ...this.
9982 (dwarf2_per_objfile::get_cu): Rename from...
9983 (dw2_get_cu): ...this.
9984 (dwarf2_per_objfile::get_tu): New.
9985 (create_addrmap_from_index): Adjust.
9986 (create_addrmap_from_aranges): Adjust.
9987 (dw2_find_last_source_symtab): Adjust.
9988 (dw2_map_symtabs_matching_filename): Adjust.
9989 (dw2_symtab_iter_next): Adjust.
9990 (dw2_print_stats): Adjust.
9991 (dw2_expand_all_symtabs): Adjust.
9992 (dw2_expand_symtabs_with_fullname): Adjust.
9993 (dw2_expand_marked_cus): Adjust.
9994 (dw_expand_symtabs_matching_file_matcher): Adjust.
9995 (dw2_map_symbol_filenames): Adjust.
9996 (dw2_debug_names_iterator::next): Adjust.
9997 (dwarf2_initialize_objfile): Adjust.
9998 (set_partial_user): Adjust.
9999 (dwarf2_build_psymtabs_hard): Adjust.
10000
10001 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10002
10003 * dwarf2read.c (create_signatured_type_table_from_debug_names):
10004 Remove unused variables.
10005 (dw2_map_symtabs_matching_filename): Likewise.
10006 (dwarf2_record_block_ranges): Likewise.
10007 (dwarf2_read_addr_index): Likewise.
10008 (follow_die_offset): Likewise.
10009
10010 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10011
10012 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
10013 to symbol_file_add_main.
10014
10015 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10016
10017 PR mi/22299
10018 * mi/mi-console.c (do_fputc_async_safe): New.
10019 (mi_console_file::write_async_safe): New.
10020 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
10021 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
10022 New.
10023 * ui-file.c (ui_file::putstrn): Adjust call to
10024 fputstrn_unfiltered.
10025 * utils.c (printchar): Replace do_fputs and do_fprintf
10026 parameters by do_fputc.
10027 (fputstr_filtered): Adjust call to printchar.
10028 (fputstr_unfiltered): Likewise.
10029 (fputstrn_filtered): Likewise.
10030 (fputstrn_unfiltered): Add do_fputc parameter, pass to
10031 printchar.
10032 * utils.h (do_fputc_ftype): New typedef.
10033 (fputstrn_unfiltered): Add do_fputc parameter.
10034
10035 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10036
10037 * regformats/i386/i386-avx.dat: Remove.
10038
10039 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10040
10041 PR gdb/22979
10042 * amd64-tdep.c (amd64_none_init_abi): New function.
10043 (amd64_x32_none_init_abi): New function.
10044 (_initialize_amd64_tdep): Register handlers for x86-64 and
10045 x64_32 with GDB_OSABI_NONE.
10046 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10047 GDB_OSABI_NONE osabi.
10048
10049 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10050
10051 PR gdb/22980
10052 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10053 GDB_OSABI_NONE.
10054 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10055 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10056
10057 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10058
10059 * common/byte-vector.h (char_vector): New type.
10060 * target.h (target_read_alloc): Return
10061 gdb::optional<byte_vector>.
10062 (target_read_stralloc): Return gdb::optional<char_vector>.
10063 (target_get_osdata): Return gdb::optional<char_vector>.
10064 * target.c (target_read_alloc_1): Templatize. Replacement
10065 manual memory management with vector.
10066 (target_read_alloc): Change return type, adjust.
10067 (target_read_stralloc): Change return type, adjust.
10068 (target_get_osdata): Change return type, adjust.
10069 * auxv.c (struct auxv_info) <length>: Remove.
10070 <data>: Change type to gdb::optional<byte_vector>.
10071 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10072 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
10073 (target_auxv_search): Adjust.
10074 (fprint_target_auxv): Adjust.
10075 * avr-tdep.c (avr_io_reg_read_command): Adjust.
10076 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
10077 (linux_make_corefile_notes): Adjust.
10078 * osdata.c (get_osdata): Adjust.
10079 * remote.c (remote_get_threads_with_qxfer): Adjust.
10080 (remote_memory_map): Adjust.
10081 (remote_traceframe_info): Adjust.
10082 (btrace_read_config): Adjust.
10083 (remote_read_btrace): Adjust.
10084 (remote_pid_to_exec_file): Adjust.
10085 * solib-aix.c (solib_aix_get_library_list): Adjust.
10086 * solib-dsbt.c (decode_loadmap): Don't free buf.
10087 (dsbt_get_initial_loadmaps): Adjust.
10088 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
10089 * solib-target.c (solib_target_current_sos): Adjust.
10090 * tracepoint.c (sdata_make_value): Adjust.
10091 * xml-support.c (xinclude_start_include): Adjust.
10092 (xml_fetch_content_from_file): Adjust.
10093 * xml-support.h (xml_fetch_another): Change return type.
10094 (xml_fetch_content_from_file): Change return type.
10095 * xml-syscall.c (xml_init_syscalls_info): Adjust.
10096 * xml-tdesc.c (file_read_description_xml): Adjust.
10097 (fetch_available_features_from_target): Change return type.
10098 (target_fetch_description_xml): Adjust.
10099 (target_read_description_xml): Adjust.
10100
10101 2018-04-06 Tom Tromey <tom@tromey.com>
10102
10103 * value.c (~value): Update.
10104 (struct value) <contents>: Now unique_xmalloc_ptr.
10105 (value_contents_bits_eq, allocate_value_contents)
10106 (value_contents_raw, value_contents_all_raw)
10107 (value_contents_for_printing, value_contents_for_printing_const)
10108 (set_value_enclosing_type): Update.
10109
10110 2018-04-06 Tom Tromey <tom@tromey.com>
10111
10112 * value.c (range_s): Remove typedef, VEC.
10113 (struct range): Add operator<.
10114 (range_lessthan): Remove.
10115 (ranges_contain): Change type.
10116 (~value): Update.
10117 (struct value) <unavailable, optimized_out>: Now std::vector.
10118 (value_entirely_available)
10119 (value_entirely_covered_by_range_vector)
10120 (value_entirely_unavailable, value_entirely_optimized_out):
10121 Update.
10122 (insert_into_bit_range_vector): Change argument type.
10123 (find_first_range_overlap): Likewise.
10124 (struct ranges_and_idx, value_contents_bits_eq)
10125 (require_not_optimized_out, require_available): Update.
10126 (ranges_copy_adjusted): Change argument types.
10127 (value_optimized_out, value_copy, value_fetch_lazy): Update.
10128
10129 2018-04-06 Tom Tromey <tom@tromey.com>
10130
10131 * value.c (~value): Update.
10132 (struct value) <parent>: Now a value_ref_ptr.
10133 (value_parent, set_value_parent, value_address, value_copy):
10134 Update.
10135
10136 2018-04-06 Tom Tromey <tom@tromey.com>
10137
10138 * value.c (struct value): Add constructor, destructor, and member
10139 initializers.
10140 (allocate_value_lazy, value_decref): Update.
10141
10142 2018-04-06 Tom Tromey <tom@tromey.com>
10143
10144 * value.c (struct value) <released, next>: Remove.
10145 (all_values): Now a std::vector.
10146 (allocate_value_lazy): Update.
10147 (value_next): Remove.
10148 (value_mark, value_free_to_mark, release_value)
10149 (value_release_to_mark): Update.
10150
10151 2018-04-06 Tom Tromey <tom@tromey.com>
10152
10153 * value.h (fetch_subexp_value, value_release_to_mark): Update.
10154 (free_value_chain): Remove.
10155 * value.c (free_value_chain): Remove.
10156 (value_release_to_mark): Return a std::vector.
10157 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
10158 std::vector.
10159 (check_condition): Update.
10160 * eval.c (fetch_subexp_value): Change "val_chain" to a
10161 std::vector.
10162 * breakpoint.c (update_watchpoint): Update.
10163 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
10164
10165 2018-04-06 Tom Tromey <tom@tromey.com>
10166
10167 * value.h (free_all_values): Remove.
10168 * value.c (free_all_values): Remove.
10169
10170 2018-04-06 Tom Tromey <tom@tromey.com>
10171
10172 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
10173 (value_history_chain, value_history_count): Remove.
10174 (value_history): New global.
10175 (record_latest_value, access_value_history, show_values)
10176 (preserve_values): Update.
10177
10178 2018-04-06 Tom Tromey <tom@tromey.com>
10179
10180 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
10181 * varobj.c (varobj_set_display_format, varobj_set_value)
10182 (install_default_visualizer, construct_visualizer)
10183 (install_new_value, ~varobj, varobj_get_value_type)
10184 (my_value_of_variable, varobj_editable_p): Update.
10185 * c-varobj.c (c_describe_child, c_value_of_variable)
10186 (cplus_number_of_children, cplus_describe_child): Update.
10187 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
10188 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
10189 (ada_value_of_variable, ada_value_is_changeable_p): Update.
10190
10191 2018-04-06 Tom Tromey <tom@tromey.com>
10192
10193 * printcmd.c (last_examine_address): Change type to
10194 value_ref_ptr.
10195 (do_examine, x_command): Update.
10196
10197 2018-04-06 Tom Tromey <tom@tromey.com>
10198
10199 * value.c (release_value): Update.
10200 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
10201 (struct bpstats) <val>: Now a value_ref_ptr.
10202 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10203 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10204 (~watchpoint, print_it_watchpoint, watch_command_1)
10205 (invalidate_bp_value_on_memory_change): Update.
10206
10207 2018-04-06 Tom Tromey <tom@tromey.com>
10208
10209 * varobj.c (varobj_clear_saved_item)
10210 (update_dynamic_varobj_children, install_new_value, ~varobj):
10211 Update.
10212 * value.h (value_incref): Move declaration earlier.
10213 (value_decref): Rename from value_free.
10214 (struct value_ref_policy): New.
10215 (value_ref_ptr): New typedef.
10216 (struct value_deleter): Remove.
10217 (gdb_value_up): Remove typedef.
10218 (release_value): Change return type.
10219 (release_value_or_incref): Remove.
10220 * value.c (set_value_parent): Update.
10221 (value_incref): Change return type.
10222 (value_decref): Rename from value_free.
10223 (value_free_to_mark, free_all_values, free_value_chain): Update.
10224 (release_value): Return value_ref_ptr.
10225 (release_value_or_incref): Remove.
10226 (record_latest_value, set_internalvar, clear_internalvar):
10227 Update.
10228 * stack.c (info_frame_command): Don't call value_free.
10229 * python/py-value.c (valpy_dealloc, valpy_new)
10230 (value_to_value_object): Update.
10231 * printcmd.c (do_examine): Update.
10232 * opencl-lang.c (lval_func_free_closure): Update.
10233 * mi/mi-main.c (register_changed_p): Don't call value_free.
10234 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10235 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10236 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10237 value_free.
10238 * guile/scm-value.c (vlscm_free_value_smob)
10239 (vlscm_scm_from_value): Update.
10240 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10241 (frame_unwind_register_unsigned, get_frame_register_bytes)
10242 (put_frame_register_bytes): Don't call value_free.
10243 * findvar.c (address_from_register): Don't call value_free.
10244 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10245 * dwarf2loc.c (entry_data_value_free_closure)
10246 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10247 (dwarf2_evaluate_loc_desc_full): Update.
10248 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10249 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10250 (~watchpoint, watch_command_1)
10251 (invalidate_bp_value_on_memory_change): Update.
10252 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10253
10254 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10255
10256 PR gdb/23022
10257 * warning.m4: Add -Wno-error=deprecated-register.
10258 * configure: Re-generate.
10259
10260 2018-04-05 Tom Tromey <tom@tromey.com>
10261
10262 * linespec.h: Remove include of "vec.h".
10263
10264 2018-04-05 Tom Tromey <tom@tromey.com>
10265
10266 * linespec.c (typep): Remove typedef.
10267 (find_methods, find_superclass_methods): Take a std::vector.
10268 (find_method): Use std::vector.
10269
10270 2018-04-05 Tom Tromey <tom@tromey.com>
10271
10272 * utils.c (compare_strings): Remove.
10273 * utils.h (compare_strings): Remove.
10274 * objc-lang.h (find_imps): Update.
10275 * objc-lang.c (find_methods): Take a std::vector.
10276 (uniquify_strings, find_imps): Likewise.
10277 * linespec.c (find_methods): Take a std::vector.
10278 (decode_objc): Use std::vector.
10279 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10280 a std::vector.
10281 (find_method, find_function_symbols): Use std::vector.
10282
10283 2018-04-05 Tom Tromey <tom@tromey.com>
10284
10285 * completer.c (completion_tracker::completion_tracker): Remove
10286 cast.
10287 (completion_tracker::discard_completions): Likewise.
10288 * breakpoint.c (ambiguous_names_p): Remove cast.
10289 * ada-lang.c (_initialize_ada_language): Remove cast.
10290 * utils.h (streq): Update.
10291 (streq_hash): Add new declaration.
10292 * utils.c (streq): Return bool.
10293 (streq_hash): New function.
10294
10295 2018-04-05 Tom Tromey <tom@tromey.com>
10296
10297 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10298 Remove a string copy.
10299
10300 2018-04-05 Tom Tromey <tom@tromey.com>
10301
10302 * linespec.c (filter_results): Use std::vector.
10303 (decode_line_2, decode_line_full): Update.
10304
10305 2018-04-05 Tom Tromey <tom@tromey.com>
10306
10307 * linespec.c (canonical_to_fullform): Return std::string.
10308 (filter_results): Update.
10309 (struct decode_line_2_item): Add constructor.
10310 <fullform, displayform>: Now std::string.
10311 (decode_line_2_compare_items): Now a std::sort comparator.
10312 (decode_line_2): Update.
10313
10314 2018-04-05 Tom Tromey <tom@tromey.com>
10315
10316 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10317 (unexpected_linespec_error): Update.
10318 (linespec_parse_basic, parse_linespec): Update.
10319
10320 2018-04-05 Tom Tromey <tom@tromey.com>
10321
10322 * linespec.c (linespec_parse_basic): Reindent.
10323
10324 2018-04-05 Tom Tromey <tom@tromey.com>
10325
10326 * minsyms.h (iterate_over_minimal_symbols): Update.
10327 * minsyms.c (iterate_over_minimal_symbols): Take a
10328 gdb::function_view.
10329 * linespec.c (struct collect_minsyms): Remove.
10330 (compare_msyms): Now a std::sort comparator.
10331 (add_minsym): Add parameters.
10332 (search_minsyms_for_name): Update. Use std::vector.
10333
10334 2018-04-03 Tom Tromey <tom@tromey.com>
10335
10336 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10337 gdb::byte_vector.
10338
10339 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10340
10341 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10342
10343 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10344
10345 PR gdb/16959
10346 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10347 printing static type.
10348
10349 2018-04-01 Tom Tromey <tom@tromey.com>
10350
10351 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10352 (rs6000_xfer_shared_libraries): Update.
10353
10354 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10355
10356 * common/gdb_vecs.h (char_ptr): Remove.
10357 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10358
10359 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10360
10361 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10362 with std::vector.
10363 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10364
10365 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10366
10367 * tracepoint.h (struct uploaded_tp): Initialize fields.
10368 <actions, step_actions, cmd_strings>: Change type to
10369 std::vector<char *>.
10370 * tracepoint.c (get_uploaded_tp): Allocate with new.
10371 (free_uploaded_tps): Free with delete.
10372 (parse_tracepoint_definition): Adjust to std::vector change.
10373 * breakpoint.c (read_uploaded_action): Likewise.
10374 (create_tracepoint_from_upload): Likewise.
10375 * ctf.c (ctf_write_uploaded_tp): Likewise.
10376 (SET_ARRAY_FIELD): Likewise.
10377 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10378
10379 2018-03-30 Tom Tromey <tom@tromey.com>
10380
10381 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10382 std::unique_ptr.
10383 (svr4_keep_data_in_core): Update.
10384 (svr4_read_so_list): Update.
10385
10386 2018-03-30 Tom Tromey <tom@tromey.com>
10387
10388 * windows-nat.c (handle_output_debug_string, handle_exception):
10389 Update.
10390 * target.h (target_read_string): Update.
10391 * target.c (target_read_string): Change "string" to
10392 unique_xmalloc_ptr.
10393 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10394 Update.
10395 * solib-frv.c (frv_current_sos): Update.
10396 * solib-dsbt.c (dsbt_current_sos): Update.
10397 * solib-darwin.c (darwin_current_sos): Update.
10398 * linux-thread-db.c (inferior_has_bug): Update.
10399 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10400 Update. Remove alloca.
10401 * ada-lang.c (ada_main_name): Update.
10402
10403 2018-03-30 Tom Tromey <tom@tromey.com>
10404
10405 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10406 (struct dwo_file_deleter): New.
10407 (dwo_file_up): New typedef.
10408 (open_and_init_dwo_file): Use dwo_file_up.
10409 (free_dwo_file_cleanup): Remove.
10410
10411 2018-03-30 Tom Tromey <tom@tromey.com>
10412
10413 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10414 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10415
10416 2018-03-30 Tom Tromey <tom@tromey.com>
10417
10418 * dwarf2read.c (class free_cached_comp_units): New class.
10419 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10420 (free_cached_comp_units): Remove function.
10421
10422 2018-03-30 Tom Tromey <tom@tromey.com>
10423
10424 * utils.h (make_cleanup_unpush_target): Remove.
10425 * inf-ptrace.c (struct target_unpusher): New.
10426 (target_unpush_up) New typedef.
10427 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10428 target_unpush_up.
10429 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10430
10431 2018-03-27 Tom Tromey <tom@tromey.com>
10432
10433 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10434
10435 2018-03-27 Pedro Alves <palves@redhat.com>
10436 Tom Tromey <tom@tromey.com>
10437
10438 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10439 destructor. Now a class.
10440 (gdb_readline_wrapper_cleanup): Remove function.
10441 (gdb_readline_wrapper): Remove cleanups.
10442
10443 2018-03-27 Tom Tromey <tom@tromey.com>
10444
10445 * typeprint.h (struct type_print_options) <local_typedefs,
10446 global_typedefs>: Remove "struct" keyword.
10447 (class typedef_hash_table): New class.
10448 (recursively_update_typedef_hash, add_template_parameters)
10449 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10450 (find_typedef_in_hash): Don't declare.
10451 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10452 (typedef_hash_table::recursively_update): Rename from
10453 recursively_update_typedef_hash. Now a member.
10454 (typedef_hash_table::add_template_parameters): Rename from
10455 add_template_parameters. Now a member.
10456 (typedef_hash_table::typedef_hash_table): Now a constructor;
10457 rename from create_typedef_hash.
10458 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10459 rename from free_typedef_hash.
10460 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10461 (do_free_global_table): Remove.
10462 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10463 from copy_type_recursive.
10464 (create_global_typedef_table): Remove.
10465 (typedef_hash_table::find_global_typedef): Now a member of
10466 typedef_hash_table.
10467 (typedef_hash_table::find_typedef): Rename from
10468 find_typedef_in_hash; now a member.
10469 (whatis_exp): Update.
10470 * extension.h (struct ext_lang_type_printers): Add constructor and
10471 destructor.
10472 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10473 declare.
10474 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10475 Now a constructor; rename from start_ext_lang_type_printers.
10476 (ext_lang_type_printers): Now a destructor; rename from
10477 free_ext_lang_type_printers.
10478 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10479 Update.
10480 (c_type_print_base_struct_union): Update. Remove cleanups.
10481
10482 2018-03-27 Tom Tromey <tom@tromey.com>
10483
10484 * dwarf-index-write.c: Include <cmath>.
10485
10486 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10487
10488 * NEWS: Add entry describing new "set|show varsize-limit" command.
10489 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10490 command.
10491 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10492 "set variable".
10493
10494 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10495
10496 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10497 dwarf-index-write.c
10498 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10499 * dwarf-index-common.c: New file.
10500 * dwarf-index-common.h: New file.
10501 * dwarf-index-write.c: New file.
10502 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10503 (struct dwarf2_section_info): Move from here.
10504 (dwarf2_section_info_def): Likewise.
10505 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10506 (offset_type): Likewise.
10507 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10508 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10509 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10510 (byte_swap): Likewise.
10511 (MAYBE_SWAP): Likewise.
10512 (dwarf2_per_cu_ptr): Likewise.
10513 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10514 (struct tu_stats): Likewise.
10515 (struct dwarf2_per_objfile): Likewise.
10516 (struct dwarf2_per_cu_data): Likewise.
10517 (struct signatured_type): Likewise.
10518 (sig_type_ptr): Likewise.
10519 (DEF_VEC_P (sig_type_ptr)): Likewise.
10520 (INDEX4_SUFFIX): Likewise.
10521 (INDEX5_SUFFIX): Likewise.
10522 (DEBUG_STR_SUFFIX): Likewise.
10523 (dwarf2_read_section): Make non-static.
10524 (mapped_index_string_hash): Move from here.
10525 (dwarf5_djb_hash): Likewise.
10526 (file_write): Likewise.
10527 (class data_buf): Likewise.
10528 (struct symtab_index_entry): Likewise.
10529 (struct mapped_symtab): Likewise.
10530 (find_slot): Likewise.
10531 (hash_expand): Likewise.
10532 (add_index_entry): Likewise.
10533 (uniquify_cu_indices): Likewise.
10534 (class c_str_view): Likewise.
10535 (class c_str_view_hasher): Likewise.
10536 (class vector_hasher): Likewise.
10537 (write_hash_table): Likewise.
10538 (psym_index_map): Likewise.
10539 (struct addrmap_index_data): Likewise.
10540 (add_address_entry): Likewise.
10541 (add_address_entry_worker): Likewise.
10542 (write_address_map): Likewise.
10543 (symbol_kind): Likewise.
10544 (write_psymbols): Likewise.
10545 (struct signatured_type_index_data): Likewise.
10546 (write_one_signatured_type): Likewise.
10547 (recursively_count_psymbols): Likewise.
10548 (recursively_write_psymbols): Likewise.
10549 (class debug_names): Likewise.
10550 (check_dwarf64_offsets): Likewise.
10551 (psyms_seen_size): Likewise.
10552 (write_gdbindex): Likewise.
10553 (write_debug_names): Likewise.
10554 (assert_file_size): Likewise.
10555 (write_psymtabs_to_index): Likewise.
10556 (save_gdb_index_command): Likewise.
10557 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10558 command.
10559 * dwarf2read.h: New file.
10560
10561 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10562
10563 PR gdb/22670
10564 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10565 symbol name if the CU's language stores symbol names in linkage
10566 format.
10567 * language.h (struct language_defn)
10568 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10569 all instances of this struct.
10570
10571 2018-03-26 Tom Tromey <tom@tromey.com>
10572
10573 * stack.c (backtrace_command_1): Remove verbose code.
10574
10575 2018-03-26 Tom Tromey <tom@tromey.com>
10576
10577 * python/py-framefilter.c (py_print_type): Don't catch
10578 exceptions. Return void.
10579 (py_print_value): Likewise.
10580 (py_print_single_arg): Likewise.
10581 (enumerate_args): Don't catch exceptions.
10582 (py_print_args): Likewise.
10583 (py_print_frame): Likewise.
10584 (gdbpy_apply_frame_filter): Catch exceptions here.
10585
10586 2018-03-26 Tom Tromey <tom@tromey.com>
10587
10588 * stack.c (_initialize_stack): Remove trailing newlines from help
10589 text. Add "Usage" line to "backtrace" help.
10590
10591 2018-03-26 Tom Tromey <tom@tromey.com>
10592
10593 PR python/16486:
10594 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10595
10596 2018-03-26 Tom Tromey <tom@tromey.com>
10597
10598 * python/py-framefilter.c (py_print_single_arg): Return
10599 EXT_LANG_BT_ERROR from catch.
10600
10601 2018-03-26 Tom Tromey <tom@tromey.com>
10602
10603 PR backtrace/15584:
10604 * stack.c (backtrace_command_1): Move some code into no-filters
10605 "if".
10606
10607 2018-03-26 Tom Tromey <tom@tromey.com>
10608
10609 * python/py-framefilter.c (throw_quit_or_print_exception): New
10610 function.
10611 (gdbpy_apply_frame_filter): Use it.
10612
10613 2018-03-26 Tom Tromey <tom@tromey.com>
10614
10615 PR cli/17716:
10616 * python/py-framefilter.c (py_print_type, py_print_value)
10617 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10618 RETURN_MASK_ERROR.
10619
10620 2018-03-26 Tom Tromey <tom@tromey.com>
10621
10622 * python/py-framefilter.c (enumerate_args): Use
10623 gdb::unique_xmalloc_ptr.
10624
10625 2018-03-26 Tom Tromey <tom@tromey.com>
10626
10627 * python/py-framefilter.c (py_print_frame): Return
10628 EXT_LANG_BT_OK.
10629 (gdbpy_apply_frame_filter): Update comment.
10630 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10631 Remove.
10632 <EXT_LANG_BT_NO_FILTERS>: Change value.
10633
10634 2018-03-26 Tom Tromey <tom@tromey.com>
10635
10636 PR backtrace/15582:
10637 * stack.c (backtrace_command): Parse "hide" argument.
10638 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10639 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10640 constant.
10641
10642 2018-03-26 Tom Tromey <tom@tromey.com>
10643
10644 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10645 add "flags".
10646 (backtrace_command): Remove "fulltrace", add "flags".
10647
10648 2018-03-26 Tom Tromey <tom@tromey.com>
10649
10650 * stack.c (backtrace_command): Rewrite command line parsing.
10651
10652 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10653
10654 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10655
10656 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10657
10658 * filename-seen-cache.h: Add include guard.
10659
10660 2018-03-26 Keith Seitz <keiths@redhat.com>
10661
10662 * symfile.c (place_section): Remove "struct" from section_addr_info
10663 in comment.
10664 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10665 "struct" keyword from section_addr_info.
10666
10667 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10668
10669 * regformats/regdef.h (reg): Add constructors.
10670
10671 2018-03-25 Pedro Alves <palves@redhat.com>
10672
10673 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10674 if then/else bodies in var_func_name extraction.
10675
10676 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10677
10678 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10679 lookup_minimal_symbol() to find symbol entry.
10680 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10681
10682 2018-03-23 Keith Seitz <keiths@redhat.com>
10683
10684 PR c++/22968
10685 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10686 nested type definitions for C++, too.
10687
10688 2018-03-23 Tom Tromey <tom@tromey.com>
10689
10690 * machoread.c (struct oso_el): Add a constructor. Don't define as
10691 a typedef.
10692 (macho_register_oso): Remove.
10693 (macho_symtab_read): Take a std::vector.
10694 (oso_el_compare_name): Now a std::sort comparator.
10695 (macho_symfile_read_all_oso): Take a std::vector.
10696 (macho_symfile_read): Use std::vector. Remove cleanups.
10697
10698 2018-03-22 Tom Tromey <tom@tromey.com>
10699
10700 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10701 (record_full_goto_bookmark): Use std::string.
10702
10703 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10704
10705 PR tdep/18295
10706 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10707 a single mask.
10708
10709 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10710
10711 * rs6000-tdep.c (store_insn_p): New function.
10712 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10713 and cr_reg to their unshifted values. Use store_insn_p to
10714 match LR saves using either R1 or fdata->alloca_reg. Use
10715 store_insn_p to match CR saves. Set alloca_reg_offset
10716 when alloca_reg and framep are set. Remove lr_reg shift
10717 when assigning to fdata->lr_register.
10718
10719 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10720
10721 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10722 command line args instead of emitting a warning.
10723
10724 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10725
10726 * tracepoint.h (struct static_tracepoint_marker): Initialize
10727 fields, define default constructor, move constructor and move
10728 assignment, disable the rest.
10729 <str_id, extra>: Make std::string.
10730 (release_static_tracepoint_marker): Remove.
10731 (free_current_marker): Remove.
10732 * tracepoint.c (free_current_marker): Remove.
10733 (parse_static_tracepoint_marker_definition): Adjust to
10734 std::string, use new hex2str overload.
10735 (release_static_tracepoint_marker): Remove.
10736 (print_one_static_tracepoint_marker): Get marker by reference
10737 and adjust to std::string.
10738 (info_static_tracepoint_markers_command): Adjust to std::vector
10739 changes
10740 * target.h (static_tracepoint_marker_p): Remove typedef.
10741 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10742 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10743 bool.
10744 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10745 * target-debug.h
10746 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10747 (target_debug_print_std_vector_static_tracepoint_marker): New.
10748 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10749 to...
10750 (target_debug_print_static_tracepoint_marker_p): ... this.
10751 * target-delegates.c: Re-generate.
10752 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10753 Make std::string.
10754 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10755 (decode_static_tracepoint_spec): Adjust to std::vector.
10756 (tracepoint_print_one_detail): Adjust to std::string.
10757 (strace_marker_decode_location): Adjust to std::string.
10758 (update_static_tracepoint): Adjust to std::string, remove call
10759 to release_static_tracepoint_marker.
10760 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10761 Adjust to std::vector.
10762 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10763 (remote_static_tracepoint_markers_by_strid): Adjust to
10764 std::vector.
10765 * common/rsp-low.h (hex2str): New overload with explicit count
10766 of bytes.
10767 * common/rsp-low.c (hex2str): New overload with explicit count
10768 of bytes.
10769 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10770 (_initialize_rsp_low_selftests): Add test_hex2str test.
10771 * unittests/tracepoint-selftests.c
10772 (test_parse_static_tracepoint_marker_definition): Adjust to
10773 std::string.
10774
10775 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10776
10777 * tracepoint.c (parse_static_tracepoint_marker_definition):
10778 Consider case where the definition is followed by more
10779 definitions.
10780 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10781 tracepoint-selftests.c.
10782 * unittests/tracepoint-selftests.c: New.
10783
10784 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10785
10786 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10787 Carvalho.
10788
10789 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10790
10791 * symtab.c (find_pc_sect_line): fixed indentation.
10792
10793 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10794
10795 * symtab.c (find_pc_sect_line): now uses binary search.
10796
10797 2018-03-19 Tom Tromey <tom@tromey.com>
10798
10799 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10800 "IDENT" production.
10801
10802 2018-03-19 Pedro Alves <palves@redhat.com>
10803 Tom Tromey <tom@tromey.com>
10804
10805 * unittests/observable-selftests.c: New file.
10806 * common/observable.h: New file.
10807 * observable.h: New file.
10808 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10809 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10810 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10811 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10812 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10813 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10814 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10815 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10816 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10817 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10818 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10819 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10820 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10821 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10822 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10823 tui/tui-interp.c, valops.c: Update all users.
10824 * tui/tui-hooks.c (tui_bp_created_observer)
10825 (tui_bp_deleted_observer, tui_bp_modified_observer)
10826 (tui_inferior_exit_observer, tui_before_prompt_observer)
10827 (tui_normal_stop_observer, tui_register_changed_observer):
10828 Remove.
10829 (tui_observers_token): New global.
10830 (attach_or_detach, tui_attach_detach_observers): New functions.
10831 (tui_install_hooks, tui_remove_hooks): Use
10832 tui_attach_detach_observers.
10833 * record-btrace.c (record_btrace_thread_observer): Remove.
10834 (record_btrace_thread_observer_token): New global.
10835 * observer.sh: Remove.
10836 * observer.c: Rename to observable.c.
10837 * observable.c (namespace gdb_observers): Define new objects.
10838 (observer_debug): Move into gdb_observers namespace.
10839 (struct observer, struct observer_list, xalloc_observer_list_node)
10840 (xfree_observer_list_node, generic_observer_attach)
10841 (generic_observer_detach, generic_observer_notify): Remove.
10842 (_initialize_observer): Update.
10843 Don't include observer.inc.
10844 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10845 (clean mostlyclean): Likewise.
10846 (observer.h, observer.inc): Remove targets.
10847 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10848 (COMMON_SFILES): Use observable.c, not observer.c.
10849 * .gitignore: Remove observer.h.
10850
10851 2018-03-18 Tom Tromey <tom@tromey.com>
10852
10853 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10854 gdb::def_vector.
10855 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10856
10857 2018-03-17 Tom Tromey <tom@tromey.com>
10858
10859 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10860
10861 2018-03-17 Tom Tromey <tom@tromey.com>
10862
10863 * target.c (class scoped_target_fd): New.
10864 (target_fileio_close_cleanup): Remove.
10865 (target_fileio_read_alloc_1): Use scoped_target_fd.
10866
10867 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10868
10869 * silent-rules.mk: New.
10870 * Makefile.in: Include silent-rules.mk
10871 (srcdir, VPATH, top_srcdir): Move up.
10872 (COMPILE): Add ECHO_CXX.
10873 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10874 (init.c): Add ECHO_INIT_C.
10875 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10876 (version.c): Add ECHO_GEN.
10877 (printcmd.o): Add ECHO_CXX.
10878 (target-float.o): Add ECHO_CXX.
10879 (ada-exp.o): Add ECHO_CXX.
10880 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10881 (insight$(EXEEXT)): Add ECHO_CXXLD.
10882 * gnulib/configure.ac: Add AM_SILENT_RULES.
10883 * gnulib/aclocal.m4: Re-generate.
10884 * gnulib/configure: Re-generate.
10885 * gnulib/import/Makefile.in: Re-generate.
10886
10887 2018-03-16 Tom Tromey <tom@tromey.com>
10888
10889 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10890 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10891 * utils.c (do_free_section_addr_info)
10892 (make_cleanup_free_section_addr_info): Remove.
10893 * symfile.h (struct other_sections): Add constructor.
10894 (struct section_addr_info): Remove.
10895 (section_addr_info): New typedef.
10896 (struct sym_fns) <sym_offsets>: Change type of parameter.
10897 (build_section_addr_info_from_objfile)
10898 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10899 (default_symfile_offsets, symbol_file_add)
10900 (symbol_file_add_from_bfd)
10901 (build_section_addr_info_from_section_table): Update.
10902 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10903 * symfile.c (alloc_section_addr_info): Remove.
10904 (build_section_addr_info_from_section_table): Change return type.
10905 Update.
10906 (build_section_addr_info_from_bfd)
10907 (build_section_addr_info_from_objfile): Likewise.
10908 (free_section_addr_info): Remove.
10909 (relative_addr_info_to_section_offsets): Change type of "addrs".
10910 (addrs_section_compar): Now a std::sort comparator.
10911 (addrs_section_sort): Change return type.
10912 (addr_info_make_relative): Change type of "addrs". Update.
10913 (default_symfile_offsets, syms_from_objfile_1)
10914 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10915 (symbol_file_add_separate): Update.
10916 (symbol_file_add): Change type of "addrs". Update.
10917 (add_symbol_file_command): Update. Remove cleanups.
10918 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10919 cleanups.
10920 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10921 * solib.c (solib_read_symbols): Update.
10922 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10923 * machoread.c (macho_symfile_offsets): Update.
10924 * jit.c (jit_bfd_try_read_symtab): Update.
10925
10926 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10927
10928 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10929 unittests/utils-selftests.c.
10930 * unittests/utils-selftests.c: New file.
10931
10932 2018-03-14 Tom Tromey <tom@tromey.com>
10933
10934 PR cli/14977:
10935 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10936 for NULL.
10937
10938 2018-03-14 Tom Tromey <tom@tromey.com>
10939
10940 PR cli/19918:
10941 * printcmd.c (printf_pointer): Allow "-" in format.
10942
10943 2018-03-14 Tom Tromey <tom@tromey.com>
10944
10945 * printcmd.c (_initialize_printcmd): Add usage to printf.
10946
10947 2018-03-14 Yao Qi <qiyao@sourceware.org>
10948
10949 * MAINTAINERS: Update my email address.
10950
10951 2018-03-13 Tom Tromey <tom@tromey.com>
10952
10953 * machoread.c (macho_check_dsym): Change filenamep to a
10954 std::string*.
10955 (macho_symfile_read): Update.
10956 * symfile.c (load_command): Use std::string.
10957
10958 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
10959
10960 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
10961 to error message string.
10962 (riscv_register_name): Use xsnprintf instead of sprintf.
10963 (riscv_insn::fetch_instruction): Use gdb_assert instead of
10964 internal_error.
10965 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
10966 error.
10967 (riscv_push_dummy_call): Likewise.
10968
10969 2018-03-12 Tom Tromey <tom@tromey.com>
10970
10971 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
10972 Use gdb::byte_vector.
10973 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
10974
10975 2018-03-12 Yao Qi <yao.qi@linaro.org>
10976
10977 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
10978 parameter type to readable_regcache.
10979 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
10980 the declaration.
10981
10982 2018-03-11 Tom Tromey <tom@tromey.com>
10983
10984 * dwarf2read.c (struct nextfield): Add initializers.
10985 (struct nextfnfield): Remove.
10986 (struct fnfieldlist): Add initializers. Remove "length" and
10987 "head", use std::vector.
10988 (struct decl_field_list): Remove.
10989 (struct field_info): Add initializers.
10990 <fields, baseclasses>: Now std::vector.
10991 <nbaseclasses, nfnfields, typedef_field_list_count,
10992 nested_types_list_count>: Remove.
10993 (dwarf2_add_field, dwarf2_add_type_defn)
10994 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
10995 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
10996 (process_structure_scope): Update.
10997
10998 2018-03-11 Tom Tromey <tom@tromey.com>
10999
11000 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
11001 for use by std::sort.
11002 (build_type_psymtabs_1): Use std::vector.
11003
11004 2018-03-09 Eli Zaretskii <eliz@gnu.org>
11005
11006 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
11007 and LIBMPFR in the printed configuration.
11008
11009 2018-03-08 Tom Tromey <tom@tromey.com>
11010
11011 * source.c (get_filename_and_charpos): Use scoped_fd.
11012 * nto-procfs.c (procfs_open_1): Use scoped_fd.
11013 (procfs_pidlist): Likewise.
11014 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
11015 (iterate_over_mappings): Likewise.
11016
11017 2018-03-08 Tom Tromey <tom@tromey.com>
11018
11019 * infcall.c (struct call_return_meta_info)
11020 <stack_temporaries_enabled>: Remove.
11021 (get_call_return_value, call_function_by_hand_dummy): Update.
11022 * thread.c (disable_thread_stack_temporaries): Remove.
11023 (enable_thread_stack_temporaries): Remove.
11024 (thread_stack_temporaries_enabled_p): Return bool.
11025 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
11026 (get_last_thread_stack_temporary): Update.
11027 * eval.c (evaluate_subexp): Update.
11028 * gdbthread.h (class enable_thread_stack_temporaries): Now a
11029 class, not a function.
11030 (value_ptr, value_vec): Remove typedefs.
11031 (class thread_info) <stack_temporaries_enabled>: Now bool.
11032 <stack_temporaries>: Now a std::vector.
11033 (thread_stack_temporaries_enabled_p)
11034 (value_in_thread_stack_temporaries): Return bool.
11035
11036 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
11037
11038 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11039 (getpkt_or_notif_sane_1): Likewise.
11040
11041 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11042
11043 * build-id.c (build_id_to_debug_bfd): Use std::string.
11044
11045 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11046
11047 * build-id.c (find_separate_debug_file_by_buildid): Return
11048 std::string.
11049 * build-id.h (find_separate_debug_file_by_buildid): Return
11050 std::string.
11051 * coffread.c (coff_symfile_read): Adjust to std::string.
11052 * elfread.c (elf_symfile_read): Adjust to std::string.
11053 * symfile.c (separate_debug_file_exists): Change parameter to
11054 std::string.
11055 (find_separate_debug_file): Return std::string.
11056 (find_separate_debug_file_by_debuglink): Return std::string.
11057 * symfile.h (find_separate_debug_file_by_debuglink): Return
11058 std::string.
11059
11060 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11061
11062 * common/xml-utils.c (xml_escape_text): Move code to...
11063 (xml_escape_text_append): ... this new function.
11064 * common/xml-utils.h (xml_escape_text_append): New declaration.
11065 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11066 New function.
11067 (_initialize_xml_utils): register test_xml_escape_text_append as
11068 a selftest.
11069
11070 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11071
11072 * defs.h: Remove MAX_REGISTER_SIZE.
11073 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
11074 asserts.
11075 * python/py-unwind.c (pyuw_sniffer): Likewise.
11076
11077 2018-03-07 Tom Tromey <tom@tromey.com>
11078
11079 * linux-tdep.c (linux_info_proc): Update.
11080 * target.h (struct target_ops) <to_fileio_readlink>: Return
11081 optional<string>.
11082 (target_fileio_readlink): Return optional<string>.
11083 * remote.c (remote_hostio_readlink): Return optional<string>.
11084 * inf-child.c (inf_child_fileio_readlink): Return
11085 optional<string>.
11086 * target.c (target_fileio_readlink): Return optional<string>.
11087
11088 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
11089
11090 * regcache.c (cooked_read_test): Add riscv to the list of
11091 architectures that have a save_reggroup.
11092
11093 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
11094
11095 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
11096 value is not a dynamic class object.
11097
11098 2018-03-06 Tom Tromey <tom@tromey.com>
11099
11100 * rust-exp.y: Formatting fixes.
11101
11102 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11103
11104 * riscv-tdep.c (riscv_register_name): Remove target description
11105 support.
11106 (riscv_gdbarch_init): Remove target description check.
11107
11108 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11109
11110 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
11111 comment.
11112 * riscv-tdep.h: Likewise.
11113
11114 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11115
11116 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
11117 (riscv_pseudo_register_write): Delete.
11118 (riscv_gdbarch_init): Remove all use of pseudo registers.
11119
11120 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11121
11122 * record-btrace.c (btrace_print_lines): Replace cleanup
11123 parameter with RAII equivalents.
11124 (btrace_insn_history): Replace cleanup with RAII equivalents.
11125 * ui-out.h (make_cleanup_ui_out_list_begin_end,
11126 make_cleanup_ui_out_tuple_begin_end): Remove.
11127 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
11128 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
11129 make_cleanup_ui_out_list_begin_end): Remove.
11130
11131 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11132
11133 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
11134 parameter types to std::vector. Use bool.
11135 (record_btrace_wait): Replace VEC(tp_t) with
11136 std::vector<thread_info *>.
11137 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
11138
11139 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11140
11141 * record-btrace.c (record_btrace_disable_callback): Remove.
11142 (struct scoped_btrace_disable): New.
11143 (record_btrace_open): Use scoped_btrace_disable.
11144
11145 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11146
11147 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
11148 reading values from registers.
11149
11150 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11151
11152 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
11153 where appropriate.
11154
11155 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11156
11157 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
11158 change parameter type. Use GDB's print functions, and use
11159 core_addr_to_string where appropriate.
11160 (riscv_push_dummy_call): Use core_addr_to_string where
11161 appropriate, update call to riscv_print_arg_location, and reindent
11162 a few lines.
11163 (riscv_return_value): Update call to riscv_print_arg_location.
11164
11165 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11166 Tim Newsome <tim@sifive.com>
11167 Albert Ou <a0u@eecs.berkeley.edu>
11168 Darius Rad <darius@bluespec.com>
11169
11170 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
11171 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
11172 (ALLDEPFILES): Add riscv-tdep.c
11173 * configure.tgt: Add riscv support.
11174 * riscv-tdep.c: New file.
11175 * riscv-tdep.h: New file.
11176 * NEWS: Mention new target.
11177 * MAINTAINERS: Add entry for riscv.
11178
11179 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11180
11181 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
11182 fields within aggregates.
11183
11184 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
11185
11186 * record-btrace.c (btrace_print_lines): Change type of flags to
11187 gdb_disassembly_flags.
11188
11189 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11190
11191 * fbsd-nat.c: Include "inf-ptrace.h".
11192 (USE_SIGTRAP_SIGINFO): Conditionally define.
11193 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
11194 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
11195 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
11196 function.
11197 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
11198 Likewise.
11199 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
11200 Likewise.
11201 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
11202 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
11203 "supports_stopped_by_hw_breakpoint" target methods.
11204
11205 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11206
11207 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
11208 * fbsd-nat.c (debug_fbsd_nat): New variable.
11209 (show_fbsd_nat_debug): New function.
11210 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
11211 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
11212
11213 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11214
11215 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
11216 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
11217 prototype.
11218 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
11219 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11220 method.
11221
11222 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11223
11224 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11225 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11226
11227 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11228
11229 * charset.c (struct charset_vector): New.
11230 (charsets): Change type to charset_vector.
11231 (find_charset_names): Adjust.
11232 (add_one): Adjust.
11233 (_initialize_charset): Adjust.
11234
11235 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11236
11237 * progspace.h (struct program_space) <deleted_solibs>: Change
11238 type to std::vector<std::string>.
11239 * progspace.c (clear_program_space_solib_cache): Adjust.
11240 * breakpoint.c (print_solib_event): Adjust.
11241 (check_status_catch_solib): Adjust.
11242 * solib.c (update_solib_list): Adjust.
11243 * ui-out.h (class ui_out) <field_string>: New overload.
11244 * ui-out.c (ui_out::field_string): New overload.
11245
11246 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11247
11248 * progspace.h (struct program_space): Add constructor and
11249 destructor, initialize fields.
11250 (add_program_space): Remove.
11251 * progspace.c (add_program_space): Rename to...
11252 (program_space::program_space): ... this.
11253 (release_program_space): Rename to...
11254 (program_space::~program_space): ... this.
11255 (delete_program_space): Use delete to delete program_space.
11256 (initialize_progspace): Use new to allocate program_space.
11257 * inferior.c (add_inferior_with_spaces): Likewise.
11258 (clone_inferior_command): Likewise.
11259 * infrun.c (follow_fork_inferior): Likewise.
11260 (handle_vfork_child_exec_or_exit): Likewise.
11261
11262 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11263
11264 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11265 (delim_string_to_char_ptr_vec): Return std::vector of
11266 gdb::unique_xmalloc_ptr.
11267 (dirnames_to_char_ptr_vec_append): Take std::vector of
11268 gdb::unique_xmalloc_ptr.
11269 (dirnames_to_char_ptr_vec): Return std::vector of
11270 gdb::unique_xmalloc_ptr.
11271 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11272 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11273 (delim_string_to_char_ptr_vec): Return an std::vector of
11274 gdb::unique_xmalloc_ptr, adjust the code.
11275 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11276 gdb::unique_xmalloc_ptr, adjust the code.
11277 (dirnames_to_char_ptr_vec): Return an std::vector of
11278 gdb::unique_xmalloc_ptr, adjust the code.
11279 * auto-load.c (auto_load_safe_path_vec): Change type to
11280 std::vector of gdb::unique_xmalloc_ptr.
11281 (auto_load_expand_dir_vars): Return an std::vector of
11282 gdb::unique_xmalloc_ptr, adjust the code.
11283 (auto_load_safe_path_vec_update): Adjust.
11284 (filename_is_in_auto_load_safe_path_vec): Adjust.
11285 (auto_load_objfile_script_1): Adjust.
11286 * build-id.c (build_id_to_debug_bfd): Adjust.
11287 * linux-thread-db.c (thread_db_load_search): Adjust.
11288 * source.c (add_path): Adjust.
11289 (openp): Adjust.
11290 * symfile.c (find_separate_debug_file): Adjust.
11291 * utils.c (do_free_char_ptr_vec): Remove.
11292 (make_cleanup_free_char_ptr_vec): Remove.
11293
11294 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11295
11296 PR gdb/22907
11297 * common/pathstuff.c: Conditionally include "<windows.h>".
11298
11299 2018-03-01 Georg Sauthoff <mail@georg.so>
11300
11301 PR gdb/22888
11302 * gcore.in: Quote variables and switch interpreter to bash.
11303
11304 2018-03-01 Tom Tromey <tom@tromey.com>
11305
11306 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11307 assertion. Add assertion for discriminant_index.
11308 (quirk_rust_enum): Use correct base type name in univariant case.
11309
11310 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11311
11312 * record.c (get_call_history_modifiers): Return a
11313 record_print_flags.
11314 (cmd_record_call_history): Adjust.
11315 * record-btrace.c (record_btrace_call_history): Adjust.
11316 (record_btrace_call_history_range): Adjust.
11317 (record_btrace_call_history_from): Adjust.
11318 * target-debug.h (target_debug_print_record_print_flags): New.
11319 * target-delegates.c: Re-generate.
11320 * target.c (target_call_history): Change flags type.
11321 (target_call_history_from): Likewise.
11322 (target_call_history_range): Likewise.
11323 * target.h (struct target_ops) <target_call_history>: Likewise.
11324 (target_call_history_from): Likewise.
11325 (target_call_history_range): Likewise.
11326
11327 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11328 Simon Marchi <simon.marchi@polymtl.ca>
11329
11330 * common/common-utils.c: Include "sys/stat.h".
11331 (is_regular_file): Move here from "source.c"; change return
11332 type to "bool".
11333 * common/common-utils.h (is_regular_file): New prototype.
11334 * common/pathstuff.c (contains_dir_separator): New function.
11335 * common/pathstuff.h (contains_dir_separator): New prototype.
11336 * source.c: Don't include "sys/stat.h".
11337 (is_regular_file): Move to "common/common-utils.c".
11338
11339 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11340
11341 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11342 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11343 * auto-load.c: Include "common/pathstuff.h".
11344 * common/common-def.h (current_directory): Move here.
11345 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11346 function.
11347 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11348 prototype.
11349 * common/pathstuff.c: New file.
11350 * common/pathstuff.h: New file.
11351 * compile/compile.c: Include "common/pathstuff.h".
11352 * defs.h (current_directory): Move to "common/common-defs.h".
11353 * dwarf2read.c: Include "common/pathstuff.h".
11354 * exec.c: Likewise.
11355 * guile/scm-safe-call.c: Likewise.
11356 * linux-thread-db.c: Likewise.
11357 * main.c: Likewise.
11358 * nto-tdep.c: Likewise.
11359 * objfiles.c: Likewise.
11360 * source.c: Likewise.
11361 * symtab.c: Likewise.
11362 * utils.c: Include "common/pathstuff.h".
11363 (gdb_realpath): Move to "common/pathstuff.c".
11364 (gdb_realpath_keepfile): Likewise.
11365 (gdb_abspath): Likewise.
11366 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11367 (gdb_realpath_keepfile): Likewise.
11368 (gdb_abspath): Likewise.
11369
11370 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11371
11372 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11373 wildcard process pid for super_resume for kernels with a
11374 specific bug.
11375
11376 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11377
11378 * compile/compile.c (get_args): Add additional comments
11379 explaining function.
11380
11381 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11382 Tom Tromey <tom@tromey.com>
11383
11384 * target.h (memory_write_request_s): Remove typedef. Don't define
11385 VEC.
11386 (target_write_memory_blocks): Change argument to std::vector.
11387 (struct memory_write_request): Add constructor.
11388 * target-memory.c (compare_block_starting_address): Return bool.
11389 Change argument types.
11390 (claim_memory): Change arguments to use std::vector.
11391 (split_regular_and_flash_blocks, blocks_to_erase)
11392 (compute_garbled_blocks): Likewise.
11393 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11394 (target_write_memory_blocks): Change argument to std::vector.
11395 * symfile.c (struct load_section_data): Add constructor and
11396 destructor. Use std::vector for "requests".
11397 (struct load_progress_data): Add initializers.
11398 (load_section_callback): Update. Use "new".
11399 (clear_memory_write_data): Remove.
11400 (generic_load): Update.
11401
11402 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11403
11404 * arch/aarch64.h: Use common/tdesc.h.
11405
11406 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11407
11408 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11409 architecture with a 64-bit ABI.
11410
11411 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11412
11413 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11414 ahead of target description loading.
11415
11416 2018-02-26 Tom Tromey <tom@tromey.com>
11417
11418 * stack.c (backtrace_command_1): Update.
11419 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11420 of "flags".
11421 * python/py-framefilter.c (py_print_frame)
11422 (gdbpy_apply_frame_filter): Change type of "flags".
11423 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11424 of "flags".
11425 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11426 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11427 * extension.h (enum frame_filter_flag): Rename from
11428 frame_filter_flags.
11429 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11430 (apply_ext_lang_frame_filter): Change type of "flags".
11431 * extension.c (apply_ext_lang_frame_filter): Change type of
11432 "flags".
11433 * extension-priv.h (struct extension_language_ops)
11434 <apply_frame_filter>: Change type of "flags".
11435
11436 2018-02-26 Tom Tromey <tom@tromey.com>
11437
11438 PR python/16497:
11439 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11440 off-by-one in py_end computation.
11441 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11442 PRINT_MORE_FRAMES.
11443 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11444 constant.
11445
11446 2018-02-26 Tom Tromey <tom@tromey.com>
11447
11448 * dwarf2read.c (struct variant_field): New.
11449 (struct nextfield) <variant>: New field.
11450 (dwarf2_add_field): Handle DW_TAG_variant_part.
11451 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11452 discriminated union.
11453 (read_structure_type): Handle DW_TAG_variant_part.
11454 (handle_struct_member_die): New function, extracted from
11455 process_structure_scope. Handle DW_TAG_variant.
11456 (process_structure_scope): Handle discriminated unions. Call
11457 handle_struct_member_die.
11458
11459 2018-02-26 Tom Tromey <tom@tromey.com>
11460
11461 * rust-lang.h (rust_last_path_segment): Declare.
11462 * rust-lang.c (rust_last_path_segment): Now public. Change
11463 contract.
11464 (struct disr_info): Remove.
11465 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11466 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11467 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11468 (rust_enum_p, rust_enum_variant): New function.
11469 (rust_underscore_fields): Remove "offset" parameter.
11470 (rust_print_enum): New function.
11471 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11472 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11473 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11474 enums.
11475 (rust_internal_print_type): New function, from rust_print_type.
11476 Remove enum code.
11477 (rust_print_type): Call rust_internal_print_type.
11478 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11479 Update enum handling.
11480 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11481 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11482 (rust_union_quirks): New functions.
11483 (process_full_comp_unit, process_full_type_unit): Call
11484 rust_union_quirks.
11485 (process_structure_scope): Update rust_unions if necessary.
11486
11487 2018-02-26 Tom Tromey <tom@tromey.com>
11488
11489 * value.h (value_union_variant): Declare.
11490 * valops.c (value_union_variant): New function.
11491 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11492 (struct discriminant_info): New.
11493 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11494 enumerator.
11495 (struct main_type) <flag_discriminated_union>: New field.
11496
11497 2018-02-26 Tom Tromey <tom@tromey.com>
11498
11499 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11500 unittests/unpack-selftests.c.
11501 * unittests/unpack-selftests.c: New file.
11502 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11503
11504 2018-02-26 Yao Qi <yao.qi@linaro.org>
11505
11506 * dwarf2read.c (struct partial_die_info) <read>: New method.
11507 (read_partial_die): Remove the declaration.
11508 (load_partial_dies): Update.
11509 (partial_die_info::partial_die_info):
11510 (read_partial_die): Change it to partial_die_info::read.
11511
11512 2018-02-26 Yao Qi <yao.qi@linaro.org>
11513
11514 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11515 (fixup_partial_die): Remove declaration.
11516 (scan_partial_symbols): Update.
11517 (partial_die_parent_scope): Likewise.
11518 (partial_die_full_name): Likewise.
11519 (fixup_partial_die): Change it to partial_die_info::fixup.
11520
11521 2018-02-26 Yao Qi <yao.qi@linaro.org>
11522
11523 * dwarf2read.c (read_partial_die): Update the declaration.
11524 (load_partial_dies): Caller update.
11525 (read_partial_die): Remove one argument abbrev_len.
11526
11527 2018-02-26 Yao Qi <yao.qi@linaro.org>
11528
11529 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11530 assignment operator.
11531 (load_partial_dies): Use ctor and copy ctor.
11532 (read_partial_die): Update.
11533 (dwarf2_cu::find_partial_die): Use ctor.
11534
11535 2018-02-26 Yao Qi <yao.qi@linaro.org>
11536
11537 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11538 (find_partial_die_in_comp_unit): Change it to
11539 dwarf2_cu::find_partial_die.
11540 (find_partial_die): Update.
11541
11542 2018-02-26 Yao Qi <yao.qi@linaro.org>
11543
11544 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11545 is NULL.
11546
11547 2018-02-26 Yao Qi <yao.qi@linaro.org>
11548
11549 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11550
11551 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11552
11553 * arch/amd64.h: Use common/tdesc.h.
11554 * arch/i386.c: Likewise.
11555 * arch/i386.h: Likewise.
11556 * arch/tic6x.c: Likewise.
11557 * arch/tdesc.h: Move file from here...
11558 * common/tdesc.h: ...to here.
11559 * features/aarch64-core.c: Regenerate.
11560 * features/aarch64-fpu.c: Regenerate.
11561 * features/i386/32bit-avx.c: Regenerate.
11562 * features/i386/32bit-avx512.c: Regenerate.
11563 * features/i386/32bit-core.c: Regenerate.
11564 * features/i386/32bit-linux.c: Regenerate.
11565 * features/i386/32bit-mpx.c: Regenerate.
11566 * features/i386/32bit-pkeys.c: Regenerate.
11567 * features/i386/32bit-sse.c: Regenerate.
11568 * features/i386/64bit-avx.c: Regenerate.
11569 * features/i386/64bit-avx512.c: Regenerate.
11570 * features/i386/64bit-core.c: Regenerate.
11571 * features/i386/64bit-linux.c: Regenerate.
11572 * features/i386/64bit-mpx.c: Regenerate.
11573 * features/i386/64bit-pkeys.c: Regenerate.
11574 * features/i386/64bit-segments.c: Regenerate.
11575 * features/i386/64bit-sse.c: Regenerate.
11576 * features/i386/x32-core.c: Regenerate.
11577 * features/tic6x-c6xp.c: Regenerate.
11578 * features/tic6x-core.c: Regenerate.
11579 * features/tic6x-gp.c: Regenerate.
11580 * target-descriptions.c: Use common/tdesc.h.
11581 * target-descriptions.h: Likewise.
11582
11583 2018-02-24 Tom Tromey <tom@tromey.com>
11584
11585 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11586 (try_thread_db_load_from_dir, thread_db_load_search): Use
11587 std::string.
11588 (info_auto_load_libthread_db_compare): Return bool. Change
11589 argument types.
11590 (info_auto_load_libthread_db): Use std::vector, std::string.
11591 Remove cleanups.
11592
11593 2018-02-24 Tom Tromey <tom@tromey.com>
11594
11595 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11596 std::string.
11597 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11598 std::string*.
11599 * gdbarch.c: Rebuild.
11600 * gdbarch.h: Rebuild.
11601 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11602 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11603 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11604 std::string*.
11605
11606 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11607
11608 * gdbtypes.h (sect_offset): Change type to uint64_t.
11609 (sect_offset_str): New function.
11610 * dwarf2read.c (create_addrmap_from_aranges): Use
11611 sect_offset_str.
11612 (error_check_comp_unit_head): Likewise.
11613 (create_debug_type_hash_table): Likewise.
11614 (read_cutu_die_from_dwo): Likewise.
11615 (init_cutu_and_read_dies): Likewise.
11616 (init_cutu_and_read_dies_no_follow): Likewise.
11617 (process_psymtab_comp_unit_reader): Likewise.
11618 (partial_die_parent_scope): Likewise.
11619 (peek_die_abbrev): Likewise.
11620 (process_queue): Likewise.
11621 (dwarf2_physname): Likewise.
11622 (read_namespace_alias): Likewise.
11623 (read_import_statement): Likewise.
11624 (create_dwo_cu_reader): Likewise.
11625 (create_cus_hash_table): Likewise.
11626 (lookup_dwo_cutu): Likewise.
11627 (inherit_abstract_dies): Likewise.
11628 (read_func_scope): Likewise.
11629 (read_call_site_scope): Likewise.
11630 (dwarf2_add_member_fn): Likewise.
11631 (read_common_block): Likewise.
11632 (read_module_type): Likewise.
11633 (read_typedef): Likewise.
11634 (read_subrange_type): Likewise.
11635 (load_partial_dies): Likewise.
11636 (read_partial_die): Likewise.
11637 (find_partial_die): Likewise.
11638 (read_str_index): Likewise.
11639 (dwarf2_string_attr): Likewise.
11640 (build_error_marker_type): Likewise.
11641 (lookup_die_type): Likewise.
11642 (dump_die_shallow): Likewise.
11643 (follow_die_ref): Likewise.
11644 (dwarf2_fetch_die_loc_sect_off): Likewise.
11645 (dwarf2_fetch_constant_bytes): Likewise.
11646 (follow_die_sig): Likewise.
11647 (get_signatured_type): Likewise.
11648 (get_DW_AT_signature_type): Likewise.
11649 (dwarf2_find_containing_comp_unit): Likewise.
11650 (set_die_type): Likewise.
11651
11652 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11653
11654 * arch/aarch64.c: Include "common-defs.h".
11655 * arch/amd64.c: Likewise.
11656 * arch/i386.c: Likewise.
11657
11658 2018-02-21 Tom Tromey <tom@tromey.com>
11659
11660 * value.h: (extract_field_op): Update.
11661 * eval.c (extract_field_op): Return a const char *.
11662 * expression.h (parse_expression_for_completion): Update.
11663 * completer.c (complete_expression): Update.
11664 (add_struct_fields): Make fieldname const.
11665 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11666 (mark_completion_tag, parse_exp_in_context_1): Update.
11667 (parse_expression_for_completion): Change "name" to
11668 unique_xmalloc_ptr*.
11669
11670 2018-02-21 Tom Tromey <tom@tromey.com>
11671
11672 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11673
11674 2018-02-21 Yao Qi <yao.qi@linaro.org>
11675
11676 * avr-tdep.c (avr_read_pc): Change parameter type to
11677 readable_regcache.
11678 * gdbarch.sh (read_pc): Likewise.
11679 * gdbarch.c: Re-generated.
11680 * gdbarch.h: Re-generated.
11681 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11682 readable_regcache.
11683 * ia64-tdep.c (ia64_read_pc): Likewise.
11684 * mips-tdep.c (mips_read_pc): Likewise.
11685 * spu-tdep.c (spu_read_pc): Likewise.
11686
11687 2018-02-21 Yao Qi <yao.qi@linaro.org>
11688
11689 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11690 * regcache-dump.c: New file.
11691 * regcache.c: Move register_dump to regcache-dump.c.
11692 (maintenance_print_registers): Likewise.
11693 (maintenance_print_raw_registers): Likewise.
11694 (maintenance_print_cooked_registers): Likewise.
11695 (maintenance_print_register_groups): Likewise.
11696 (maintenance_print_remote_registers): Likewise.
11697 (_initialize_regcache): Likewise.
11698 * regcache.h (register_dump): Moved from regcache.c.
11699
11700 2018-02-21 Yao Qi <yao.qi@linaro.org>
11701
11702 * regcache.c (regcache::regcache): Update.
11703 (regcache::invalidate): Move it to detached_regcache::invalidate.
11704 (get_thread_arch_aspace_regcache): Update.
11705 (regcache::raw_update): Update.
11706 (regcache::cooked_read): Remove some code.
11707 (regcache::cooked_read_value): Likewise.
11708 (regcache::raw_write): Remove assert on m_readonly_p.
11709 (regcache::raw_supply_integer): Move it to
11710 detached_regcache::raw_supply_integer.
11711 (regcache::raw_supply_zeroed): Likewise.
11712 * regcache.h (detached_regcache) <raw_supply_integer>: New
11713 declaration.
11714 <raw_supply_zeroed, invalidate>: Likewise.
11715 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11716 <invalidate>: Likewise.
11717 <m_readonly_p>: Removed.
11718
11719 2018-02-21 Yao Qi <yao.qi@linaro.org>
11720
11721 * infcmd.c (get_return_value): Let stop_regs point to
11722 get_current_regcache.
11723 * regcache.c (regcache::regcache): Remove.
11724 (register_dump_reg_buffer): New class.
11725 (regcache_print): Adjust.
11726 * regcache.h (regcache): Remove constructors.
11727
11728 2018-02-21 Yao Qi <yao.qi@linaro.org>
11729
11730 * regcache.c (class register_dump): New class.
11731 (register_dump_regcache, register_dump_none): New class.
11732 (register_dump_remote, register_dump_groups): New class.
11733 (regcache_print): Update.
11734 * regcache.h (regcache_dump_what): Move it to regcache.c.
11735 (regcache) <dump>: Remove.
11736
11737 2018-02-21 Yao Qi <yao.qi@linaro.org>
11738
11739 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11740 reg_buffer_rw *.
11741 (jit_unwind_reg_set_impl): Call raw_supply.
11742 (jit_frame_sniffer): Use reg_buffer_rw.
11743 * record-full.c (record_full_core_regbuf): Change its type.
11744 (record_full_core_open_1): Use reg_buffer_rw.
11745 (record_full_close): Likewise.
11746 (record_full_core_fetch_registers): Use regcache->raw_supply.
11747 (record_full_core_store_registers): Likewise.
11748 * regcache.c (regcache::get_register_status): Move it to
11749 reg_buffer.
11750 (regcache_raw_set_cached_value): Remove.
11751 (regcache::raw_set_cached_value): Remove.
11752 (regcache::raw_write): Call raw_supply.
11753 (regcache::raw_supply): Move it to reg_buffer_rw.
11754 * regcache.h (regcache_raw_set_cached_value): Remove.
11755 (reg_buffer_rw): New class.
11756
11757 2018-02-21 Yao Qi <yao.qi@linaro.org>
11758
11759 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11760 readonly_detached_regcache.
11761 (dummy_frame_prev_register): Use regcache->cooked_read.
11762 * frame.c (frame_save_as_regcache): Change return type.
11763 (frame_pop): Update.
11764 * frame.h (frame_save_as_regcache): Update declaration.
11765 * inferior.h (get_infcall_suspend_state_regcache): Update
11766 declaration.
11767 * infrun.c (infcall_suspend_state) <registers>: use
11768 readonly_detached_regcache.
11769 (save_infcall_suspend_state): Don't use regcache_dup.
11770 (get_infcall_suspend_state_regcache): Change return type.
11771 * linux-fork.c (struct fork_info) <savedregs>: Change to
11772 readonly_detached_regcache.
11773 <pc>: New field.
11774 (fork_save_infrun_state): Don't use regcache_dup.
11775 (info_checkpoints_command): Adjust.
11776 * mi/mi-main.c (register_changed_p): Update declaration.
11777 (mi_cmd_data_list_changed_registers): Use
11778 readonly_detached_regcache.
11779 (register_changed_p): Change parameter type to
11780 readonly_detached_regcache.
11781 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11782 readonly_detached_regcache.
11783 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11784 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11785 New.
11786 (regcache::save): Move it to reg_buffer.
11787 (regcache::restore): Change parameter type.
11788 (regcache_dup): Remove.
11789 * regcache.h (reg_buffer) <save>: New method.
11790 (readonly_detached_regcache): New class.
11791 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11792 readonly_detached_regcache.
11793 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11794
11795 2018-02-21 Yao Qi <yao.qi@linaro.org>
11796
11797 * frame.c (frame_save_as_regcache): Use regcache method save.
11798 (frame_pop): Use regcache method restore.
11799 * infrun.c (restore_infcall_suspend_state): Likewise.
11800 * linux-fork.c (fork_load_infrun_state): Likewise.
11801 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11802 save.
11803 * regcache.c (regcache_save): Remove.
11804 (regcache::restore): More asserts.
11805 (regcache_cpy): Remove.
11806 * regcache.h (regcache_save): Remove the declaration.
11807 (regcache::restore): Move from private to public.
11808 Remove the friend declaration of regcache_cpy.
11809 (regcache_cpy): Remove declaration.
11810
11811 2018-02-21 Yao Qi <yao.qi@linaro.org>
11812
11813 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11814 parameter type to 'readable_regcache *'.
11815 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11816 * arm-tdep.c (arm_neon_quad_read): Likewise.
11817 (arm_pseudo_read): Likewise.
11818 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11819 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11820 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11821 * gdbarch.c: Re-generated.
11822 * gdbarch.h: Re-generated.
11823 * gdbarch.sh (pseudo_register_read): Change parameter type to
11824 'readable_regcache *'.
11825 (pseudo_register_read_value): Likewise.
11826 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11827 (h8300_pseudo_register_read): Likewise.
11828 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11829 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11830 (i386_pseudo_register_read_into_value): Likewise.
11831 (i386_pseudo_register_read_value): Likewise.
11832 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11833 declaration.
11834 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11835 * m32c-tdep.c (m32c_raw_read): Likewise.
11836 (m32c_read_flg): Likewise.
11837 (m32c_banked_register): Likewise.
11838 (m32c_banked_read): Likewise.
11839 (m32c_sb_read): Likewise.
11840 (m32c_part_read): Likewise.
11841 (m32c_cat_read): Likewise.
11842 (m32c_r3r2r1r0_read): Likewise.
11843 (m32c_pseudo_register_read): Likewise.
11844 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11845 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11846 (mep_pseudo_cr64_read): Likewise.
11847 (mep_pseudo_register_read): Likewise.
11848 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11849 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11850 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11851 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11852 (regcache::cooked_read): Likewise.
11853 (regcache::cooked_read_value): Likewise.
11854 (regcache_cooked_read_signed):
11855 (regcache::cooked_read): Likewise.
11856 * regcache.h (readable_regcache): New class.
11857 (regcache): Inherit readable_regcache. Move some methods to
11858 readable_regcache.
11859 * rl78-tdep.c (rl78_pseudo_register_read): Change
11860 parameter type to 'readable_regcache *'.
11861 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11862 (e500_pseudo_register_read): Change parameter type to
11863 'readable_regcache *'.
11864 (dfp_pseudo_register_read): Likewise.
11865 (vsx_pseudo_register_read): Likewise.
11866 (efpr_pseudo_register_read): Likewise.
11867 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11868 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11869 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11870 (sh64_pseudo_register_read): Likewise.
11871 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11872 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11873 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11874 (spu_pseudo_register_read): Likewise.
11875 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11876 (xtensa_pseudo_register_read): Likewise.
11877
11878 2018-02-21 Yao Qi <yao.qi@linaro.org>
11879
11880 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11881 (regcache::arch): Move it to reg_buffer::arch.
11882 (regcache::register_buffer): Likewise.
11883 (regcache::assert_regnum): Likewise.
11884 (regcache::num_raw_registers): Likewise.
11885 * regcache.h (reg_buffer): New class.
11886 (regcache): Inherit reg_buffer.
11887
11888 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11889
11890 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11891 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11892
11893 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11894
11895 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11896
11897 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11898
11899 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11900 (SFILES): Remove common/*.c files.
11901 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11902 * common/common.host: Add common reference.
11903 * configure.ac: Likewise.
11904 * configure: Regenerate.
11905
11906 2018-02-16 Yao Qi <yao.qi@linaro.org>
11907
11908 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11909 (block_initialize_namespace): Use new.
11910 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11911 (dwarf2_free_objfile): Use delete.
11912 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11913 (copy_type_recursive): Use new.
11914 * gdb_obstack.h (allocate_on_obstack): New.
11915
11916 2018-02-15 Yao Qi <yao.qi@linaro.org>
11917
11918 PR gdb/22849
11919 * inferior.c (exit_inferior_1): Reset inf->control.
11920
11921 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11922
11923 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11924 declaration.
11925
11926 2018-02-14 Pedro Alves <palves@redhat.com>
11927
11928 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11929 frame_cleanup_after_sniffer on exception.
11930
11931 2018-02-14 Tom Tromey <tom@tromey.com>
11932
11933 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11934 const.
11935 (solib_bfd_open): Make pathname const.
11936 * solib.c (solib_bfd_open): Make pathname const.
11937 * solib-spu.c (spu_bfd_fopen): Make name const.
11938 (spu_bfd_open): Make pathname const.
11939 * solib-darwin.c (darwin_bfd_open): Make pathname const.
11940 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
11941
11942 2018-02-14 Tom Tromey <tom@tromey.com>
11943
11944 * symfile.c (symfile_bfd_open): Update.
11945 * source.h (openp, source_full_path_of, find_and_open_source):
11946 Change argument type to unique_xmalloc_ptr.
11947 * source.c (openp): Take a unique_xmalloc_ptr.
11948 (source_full_path_of, find_and_open_source): Likewise.
11949 (open_source_file, symtab_to_fullname): Update.
11950 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
11951 unique_xmalloc_ptr.
11952 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
11953 (exec_file_find): Update.
11954 * psymtab.c (psymtab_to_fullname): Update.
11955 * nto-tdep.h (nto_find_and_open_solib): Update.
11956 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
11957 unique_xmalloc_ptr.
11958 * exec.c (exec_file_attach): Update.
11959 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
11960 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
11961
11962 2018-02-14 Tom Tromey <tom@tromey.com>
11963
11964 * solib.c: Include source.h.
11965 * nto-tdep.c: Include source.h.
11966 * mi/mi-cmd-env.c: Include source.h.
11967 * infcmd.c: Include source.h.
11968 * exec.c: Include source.h.
11969 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
11970 (add_path, directory_switch, source_path, init_source_path): Move
11971 declarations...
11972 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
11973 (add_path, directory_switch, source_path, init_source_path):
11974 ...here.
11975
11976 2018-02-14 Tom Tromey <tom@tromey.com>
11977
11978 * solist.h (exec_file_find, solib_find): Return
11979 unique_xmalloc_ptr.
11980 (solib_bfd_fopen): Take a const char *.
11981 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
11982 (exec_file_find, solib_find): Likewise.
11983 (solib_bfd_fopen): Do not take ownership of "pathname".
11984 (solib_bfd_open): Use unique_xmalloc_ptr.
11985 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
11986 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
11987 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
11988 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
11989
11990 2018-02-14 Joel Brobecker <brobecker@adacore.com>
11991
11992 * ada-lang.c (name_match_type_from_name): Remove reference to
11993 ada_name_for_lookup in function's documentation.
11994 * ada-lang.h (ada_name_for_lookup): Delete declaration.
11995
11996 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
11997
11998 * defs.h (enum openp_flags): New enum.
11999 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
12000 Move to enum openp_flags.
12001 (openp_flags): New enum flags.
12002 (openp): Change parameter type to openp_flags.
12003 * source.c (openp): Change parameter type to openp_flags.
12004 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
12005 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
12006
12007 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12008
12009 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
12010 per-command.
12011
12012 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
12013
12014 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
12015 into...
12016 (class dwarf2_queue_guard): ...the destructor of this new class.
12017 (dw2_do_instantiate_symtab): Create instance of the new class
12018 dwarf2_queue_guard, remove cleanup.
12019
12020 2018-02-09 Tom Tromey <tom@tromey.com>
12021
12022 * source.c (find_source_lines): Don't reference past the end of
12023 the vector.
12024
12025 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12026
12027 * remote.c (remote_btrace_maybe_reopen): Change error message.
12028 * btrace.c (btrace_enable): Likewise.
12029 (parse_xml_btrace): Likewise.
12030 (parse_xml_btrace_conf): Likewise.
12031
12032 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12033
12034 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
12035 (linux_enable_pt, linux_enable_bts): Call
12036 diagnose_perf_event_open_fail.
12037
12038 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12039
12040 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12041 Remove parameter and change return type. Update callers. Move it.
12042 (linux_enable_bts, linux_enable_pt): Improve error message.
12043 (linux_enable_pt): Remove zero buffer size check.
12044 (linux_enable_btrace): Improve error messages. Remove NULL return
12045 check.
12046
12047 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12048
12049 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12050 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12051 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12052 (linux_supports_pt, linux_supports_btrace): Remove.
12053 (linux_enable_bts): Call cpu_supports_bts.
12054 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12055 * remote.c (remote_supports_btrace): Remove.
12056 (init_remote_ops): Remove remote_supports_btrace.
12057 * target-delegates.c: Regenerated.
12058 * target.c (target_supports_btrace): Remove.
12059 * target.h (target_ops) <to_supports_btrace>: Remove
12060 (target_supports_btrace): Remove.
12061 * x86-linux-nat.c (x86_linux_create_target): Remove
12062 linux_supports_btrace.
12063
12064 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12065
12066 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12067 btrace failed.
12068 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12069 exception and use message in own exception.
12070
12071 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12072
12073 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
12074 (perf_event_pt_event_type): Use gdb_file_up.
12075 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
12076 scoped_fd, and scoped_mmap.
12077
12078 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12079
12080 * common/scoped_mmap.h: New.
12081 * unittests/scoped_mmap-selftest.c: New.
12082 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12083 unittests/scoped_mmap-selftest.c.
12084
12085 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12086
12087 * common/scoped_fd.h: New.
12088 * unittests/scoped_fd-selftest.c: New.
12089 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12090 unittests/scoped_fd-selftest.c.
12091
12092 2018-02-09 Tom Tromey <tom@tromey.com>
12093
12094 * auto-load.c (auto_load_section_scripts): Use
12095 gdb::unique_xmalloc_ptr.
12096
12097 2018-02-09 Tom Tromey <tom@tromey.com>
12098
12099 * auto-load.c (execute_script_contents): Use std::string.
12100
12101 2018-02-09 Joel Brobecker <brobecker@adacore.com>
12102
12103 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
12104 Python function, rather than a new command.
12105
12106 2018-02-08 Tom Tromey <tom@tromey.com>
12107
12108 * solib.c (solib_find_1): Use std::string.
12109 (solib_bfd_fopen): Use unique_xmalloc_ptr.
12110
12111 2018-02-08 Tom Tromey <tom@tromey.com>
12112
12113 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
12114
12115 2018-02-08 Tom Tromey <tom@tromey.com>
12116
12117 * source.c (find_source_lines): Use gdb::def_vector.
12118
12119 2018-02-08 Tom Tromey <tom@tromey.com>
12120
12121 * macrocmd.c (struct temporary_macro_definition): New.
12122 (macro_define_command): Use temporary_macro_definition. Remove
12123 cleanups.
12124 (free_macro_definition_ptr): Remove.
12125
12126 2018-02-08 Tom Tromey <tom@tromey.com>
12127
12128 * macroexp.c (maybe_expand): Use std::string.
12129
12130 2018-02-08 Tom Tromey <tom@tromey.com>
12131
12132 * macroexp.c (struct macro_buffer): Add initializers for some
12133 members.
12134 (init_buffer, init_shared_buffer, free_buffer)
12135 (free_buffer_return_text): Remove.
12136 (macro_buffer): New constructors.
12137 (~macro_buffer): New destructor.
12138 (macro_buffer::set_shared): New method.
12139 (macro_buffer::resize_buffer, macro_buffer::appendc)
12140 (macro_buffer::appendmem): Now methods, not free functions.
12141 (set_token, append_tokens_without_splicing, stringify)
12142 (macro_stringify): Update.
12143 (gather_arguments): Change return type. Remove argc_p argument,
12144 add args_ptr argument. Use std::vector.
12145 (substitute_args): Remove argc argument. Accept std::vector.
12146 (expand): Update. Use std::vector.
12147 (scan, macro_expand, macro_expand_next): Update.
12148
12149 2018-02-08 Tom Tromey <tom@tromey.com>
12150
12151 * symtab.c (default_collect_symbol_completion_matches_break_on):
12152 Use unique_xmalloc_ptr.
12153 * macroscope.h: (sal_macro_scope, user_macro_scope)
12154 (default_macro_scope): Return unique_xmalloc_ptr.
12155 * macroscope.c (sal_macro_scope, user_macro_scope)
12156 (default_macro_scope): Return unique_xmalloc_ptr.
12157 * macroexp.h (macro_expand, macro_expand_once): Return
12158 unique_xmalloc_ptr.
12159 * macroexp.c (macro_expand, macro_expand_once): Return
12160 unique_xmalloc_ptr.
12161 * macrocmd.c (macro_expand_command, macro_expand_once_command)
12162 (info_macro_command, info_macros_command): Use
12163 unique_xmalloc_ptr.
12164 * compile/compile-c-support.c (write_macro_definitions): Use
12165 unique_xmalloc_ptr.
12166 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
12167
12168 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
12169
12170 * value.c (value_static_field): Assign field type instead of
12171 containing type when returning an optimized out value.
12172
12173 2018-02-06 Yao Qi <yao.qi@linaro.org>
12174
12175 * ft32-tdep.c (ft32_read_pc): Remove.
12176 (ft32_write_pc): Remove.
12177 (ft32_gdbarch_init): Update.
12178 * m32r-tdep.c (m32r_read_pc): Remove.
12179 (m32r_gdbarch_init): Update.
12180 * mep-tdep.c (mep_read_pc): Remove.
12181 (mep_gdbarch_init): Update.
12182 * microblaze-tdep.c (microblaze_write_pc): Remove.
12183 (microblaze_gdbarch_init): Update.
12184 * mn10300-tdep.c (mn10300_read_pc): Remove.
12185 (mn10300_write_pc): Remove.
12186 (mn10300_gdbarch_init): Update.
12187 * moxie-tdep.c (moxie_read_pc): Remove.
12188 (moxie_write_pc): Remove.
12189 (moxie_gdbarch_init): Update.
12190
12191 2018-02-06 Yao Qi <yao.qi@linaro.org>
12192
12193 * expprint.c (print_subexp_standard): Handle
12194 OP_F77_UNDETERMINED_ARGLIST.
12195 (dump_subexp_body_standard): Likewise.
12196
12197 2018-02-05 Alan Hayward <alan.hayward@arm.com>
12198
12199 * target-descriptions.c (tdesc_element_visitor) Add empty
12200 implementations.
12201 (tdesc_type): Move make_gdb_type from here.
12202 (tdesc_type_builtin): Likewise.
12203 (tdesc_type_vector): Likewise.
12204 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
12205 (make_gdb_type_struct): Move from tdesc_type_with_fields.
12206 (make_gdb_type_union): Likewise.
12207 (make_gdb_type_flags): Likewise.
12208 (make_gdb_type_enum): Likewise.
12209 (make_gdb_type): New function.
12210 (tdesc_register_type): Use static make_gdb_type.
12211
12212 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
12213
12214 * infcmd.c (default_print_one_register_info): Align natural-format
12215 column values consistently one under another.
12216 (pad_to_column): New function.
12217
12218 2018-02-05 Joel Brobecker <brobecker@adacore.com>
12219
12220 * dwarf2read.c (dwarf2_physname): Move commment.
12221
12222 2018-02-01 Leszek Swirski <leszeks@google.com>
12223
12224 * varobj.c (varobj_formatted_print_options): Allow recursive
12225 pretty printing if pretty printing is enabled.
12226
12227 2018-02-01 Leszek Swirski <leszeks@google.com>
12228
12229 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12230 names after a structop as a filename.
12231
12232 2018-02-01 Yao Qi <yao.qi@linaro.org>
12233
12234 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12235 (arm_record_coproc_data_proc): Likewise.
12236
12237 2018-02-01 Yao Qi <yao.qi@linaro.org>
12238
12239 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12240
12241 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12242
12243 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12244 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12245
12246 2018-01-31 Pedro Alves <palves@redhat.com>
12247
12248 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12249 * inflow.c (child_terminal_save_inferior): Wrap reference to
12250 tcgetpgrp in HAVE_TERMIOS_H.
12251 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12252 _WIN32.
12253 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12254 always iterate over all inferiors.
12255 (gdbsim_cntrl_c): Adjust.
12256 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12257
12258 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12259
12260 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12261 index type is objfile-owned if the element type is as well.
12262
12263 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12264
12265 GDB 8.1 released.
12266
12267 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12268
12269 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12270 "features/s390x-linux64.c".
12271 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12272 s390_linux32 and s390x_linux64.
12273 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12274 default tdesc.
12275 * s390-tdep.c: Include "features/s390-linux32.c" and
12276 "features/s390x-linux64.c".
12277 (s390_tdesc_valid): Add check for tdesc_has_registers.
12278 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12279 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12280 tdesc_s390x_linux64.
12281 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12282 tdesc_s390x_linux64 to...
12283 * s390-tdep.h: ...here.
12284
12285 2018-01-30 Pedro Alves <palves@redhat.com>
12286
12287 PR gdb/13211
12288 * config.in, configure: Regenerate.
12289 * configure.ac: Check for getpgid.
12290 * go32-nat.c (go32_pass_ctrlc): New.
12291 (go32_target): Install it.
12292 * inf-child.c (inf_child_target): Install
12293 child_terminal_save_inferior, child_pass_ctrlc and
12294 child_interrupt.
12295 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12296 (inf_ptrace_target): No longer install it.
12297 * infcmd.c (interrupt_target_1): Adjust.
12298 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12299 (child_interrupt): Declare.
12300 (inferior::terminal_state): New.
12301 * inflow.c (struct terminal_info): Update comments.
12302 (inferior_process_group): Delete.
12303 (terminal_is_ours): Delete.
12304 (gdb_tty_state): New.
12305 (child_terminal_init): Adjust.
12306 (is_gdb_terminal, sharing_input_terminal_1)
12307 (sharing_input_terminal): New functions.
12308 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12309 Set the process's actual process group in the foreground if
12310 possible. Handle is_ours_for_output/is_ours distinction. Don't
12311 mark terminal as the inferior's if not sharing GDB's terminal.
12312 Don't check attach_flag.
12313 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12314 pass down a target_terminal_state.
12315 (child_terminal_save_inferior): New, factored out from ...
12316 (child_terminal_ours_1): ... this. Handle
12317 target_terminal_state::is_ours_for_output.
12318 (child_interrupt, child_pass_ctrlc): New.
12319 (inflow_inferior_exit): Clear the inferior's terminal_state.
12320 (copy_terminal_info): Copy the inferior's terminal state.
12321 (_initialize_inflow): Remove reference to terminal_is_ours.
12322 * inflow.h (inferior_process_group): Delete.
12323 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12324 * procfs.c (procfs_target): Don't install procfs_interrupt.
12325 (procfs_interrupt): Delete.
12326 * remote.c (remote_serial_quit_handler): Adjust.
12327 (remote_interrupt): Remove ptid parameter. Adjust.
12328 * target-delegates.c: Regenerate.
12329 * target.c: Include "terminal.h".
12330 (target_terminal::terminal_state): Rename to ...
12331 (target_terminal::m_terminal_state): ... this.
12332 (target_terminal::init): Adjust.
12333 (target_terminal::inferior): Adjust to per-inferior
12334 terminal_state.
12335 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12336 (target_terminal::ours, target_terminal::ours_for_output): Use
12337 target_terminal_is_ours_kind.
12338 (target_interrupt): Remove ptid parameter. Adjust.
12339 (default_target_pass_ctrlc): Adjust.
12340 * target.h (target_ops::to_terminal_save_inferior): New field.
12341 (target_ops::to_interrupt): Remove ptid_t parameter.
12342 (target_interrupt): Remove ptid_t parameter. Update comment.
12343 (target_pass_ctrlc): Update comment.
12344 * target/target.h (target_terminal_state): New scoped enum,
12345 factored out of ...
12346 (target_terminal::terminal_state): ... here.
12347 (target_terminal::inferior): Update comments.
12348 (target_terminal::restore_inferior): New.
12349 (target_terminal::is_inferior, target_terminal::is_ours)
12350 (target_terminal::is_ours_for_output): Adjust.
12351 (target_terminal::scoped_restore_terminal_state): Adjust to
12352 rename, and call restore_inferior() instead of inferior().
12353 (target_terminal::scoped_restore_terminal_state::m_state): Change
12354 type.
12355 (target_terminal::terminal_state): Rename to ...
12356 (target_terminal::m_terminal_state): ... this and change type.
12357
12358 2018-01-30 Pedro Alves <palves@redhat.com>
12359
12360 * linux-nat.c (wait_for_signal): New function.
12361 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12362 directly.
12363 (async_terminal_is_ours)
12364 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12365 (linux_nat_add_target): Don't override
12366 to_terminal_inferior/to_terminal_ours.
12367
12368 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12369
12370 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12371
12372 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12373
12374 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12375 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12376 dwarf2_per_objfile_free here.
12377 (dwarf2_per_objfile_free): Remove.
12378 (_initialize_dwarf2_read): Don't register
12379 dwarf2_per_objfile_free as a registry cleanup.
12380
12381 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12382
12383 Avoid compilation errors in MinGW native builds
12384
12385 The error is triggered by including python-internal.h, and the
12386 error message is:
12387
12388 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12389 from build-gnulib/import/math.h:27,
12390 from d:/usr/Python26/include/pyport.h:235,
12391 from d:/usr/Python26/include/Python.h:58,
12392 from python/python-internal.h:94,
12393 from python/py-arch.c:24:
12394 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12395 using ::hypot;
12396 ^~~~~
12397
12398 This happens because Python headers define 'hypot' to expand t
12399 '_hypot' in the Windows builds.
12400 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12401 'hypoth'. This avoids a compilation error.
12402
12403 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12404
12405 * MAINTAINERS (Write After Approval): Fix ordering.
12406
12407 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12408
12409 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12410
12411 2018-01-26 Alan Modra <amodra@gmail.com>
12412
12413 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12414 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12415 Remove nop. Make const. Comment.
12416 (powerpc32_plt_stub_so_2): New.
12417 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12418 Correct count. Update uses.
12419 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12420 Move common code reading PLT entry word. Correct
12421 powerpc32_plt_stub PLT address calculation.
12422 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12423 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12424 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12425 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12426 (ppc64_standard_linkage8): Likewise.
12427 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12428 Correct insns description.
12429 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12430
12431 2018-01-24 Pedro Alves <palves@redhat.com>
12432
12433 GCC PR libstdc++/83906
12434 * gdbtypes.c (operator==(const dynamic_prop &,
12435 const dynamic_prop &)): New.
12436 (operator==(const range_bounds &, const range_bounds &)): New.
12437 (check_types_equal): Use them instead of memcmp.
12438 * gdbtypes.h (operator==(const dynamic_prop &,
12439 const dynamic_prop &)): Declare.
12440 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12441 (operator==(const range_bounds &, const range_bounds &)): Declare.
12442 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12443
12444 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12445
12446 * s390-linux-tdep.c (s390_record_address_mask)
12447 (s390_record_calc_disp_common, s390_record_calc_disp)
12448 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12449 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12450 (s390_process_record): Move to s390-tdep.c.
12451 (s390_linux_init_abi_any): Adjust.
12452 * s390-tdep.c (s390_record_address_mask)
12453 (s390_record_calc_disp_common, s390_record_calc_disp)
12454 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12455 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12456 (s390_process_record): Moved from s390-linux-tdep.c
12457 (s390_gdbarch_init): Adjust.
12458
12459 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12460
12461 * s390-linux-nat.c (s390-tdep.h): New include.
12462 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12463 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12464 (ALLDEPFILES): Add s390-tdep.c.
12465 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12466 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12467 * s390-tdep.h: ...this. New file.
12468 * s390-linux-tdep.c (s390-tdep.h): New include.
12469 (_initialize_s390_tdep): Rename to...
12470 (_initialize_s390_linux_tdep): ...this and adjust.
12471 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12472 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12473 s390-tdep.h.
12474 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12475 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12476 (s390_is_partial_instruction, s390_software_single_step)
12477 (is_non_branch_ril, s390_displaced_step_copy_insn)
12478 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12479 (s390_prologue_data, s390_addr, s390_store, s390_load)
12480 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12481 (s390_register_call_saved, s390_guess_tracepoint_registers)
12482 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12483 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12484 (s390_pseudo_register_name, s390_pseudo_register_type)
12485 (s390_pseudo_register_read, s390_pseudo_register_write)
12486 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12487 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12488 (s390_addr_bits_remove, s390_address_class_type_flags)
12489 (s390_address_class_type_flags_to_name)
12490 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12491 (s390_function_arg_float, s390_function_arg_vector)
12492 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12493 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12494 (s390_frame_align, s390_register_return_value, s390_return_value)
12495 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12496 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12497 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12498 (s390_trad_frame_prev_register, s390_unwind_cache)
12499 (s390_prologue_frame_unwind_cache)
12500 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12501 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12502 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12503 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12504 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12505 (s390_frame_base_address, s390_local_base_address)
12506 (s390_frame_base, s390_gcc_target_options)
12507 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12508 (s390_validate_reg_range, s390_tdesc_valid)
12509 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12510 * s390-tdep.c: ...this. New file.
12511
12512 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12513
12514 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12515 (s390_process_record, s390_gdbarch_tdep_alloc)
12516 (s390_linux_init_abi_any): Use/set new hook.
12517
12518 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12519
12520 * s390-linux-tdep.c (osabi.h): New include.
12521 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12522 (s390_linux_init_abi_any): New functions.
12523 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12524
12525 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12526
12527 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12528 tdesc_has_registers check
12529
12530 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12531
12532 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12533 (s390_validate_reg_range): New macro.
12534 (s390_gdbarch_init): Adjust.
12535
12536 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12537
12538 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12539 (s390_gdbarch_tdep_alloc): Adjust.
12540 (s390_gdbarch_init): Adjust.
12541
12542 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12543
12544 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12545 <have_tdb>: Change type to bool.
12546 (s390_gdbarch_tdep_alloc): Adjust.
12547 (s390_gdbarch_init): Adjust.
12548
12549 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12550
12551 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12552 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12553 (s390_gdbarch_tdep_alloc): New function.
12554 (s390_gdbarch_init): Allocate tdep at start and use its fields
12555 instead of separate variables.
12556
12557 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12558
12559 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12560 when looking for cached gdbarch and add comment for remaining.
12561
12562 2018-01-22 Pedro Alves <palves@redhat.com>
12563 Sergio Durigan Junior <sergiodj@redhat.com>
12564
12565 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12566 case.
12567
12568 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12569
12570 * MAINTAINERS: Update my company e-mail address.
12571
12572 2018-01-22 Yao Qi <yao.qi@linaro.org>
12573
12574 * regcache.c (cooked_write_test): New function.
12575 (_initialize_regcache): Register the test.
12576
12577 2018-01-22 Yao Qi <yao.qi@linaro.org>
12578
12579 * ia64-tdep.c (ia64_pseudo_register_read): Call
12580 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12581 * m32c-tdep.c (m32c_cat_read): Likewise.
12582 (m32c_r3r2r1r0_read): Likewise.
12583 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12584 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12585
12586 2018-01-22 Yao Qi <yao.qi@linaro.org>
12587
12588 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12589 method raw_read instead of regcache_raw_read.
12590 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12591 * arm-tdep.c (arm_neon_quad_read): Likewise.
12592 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12593 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12594 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12595 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12596 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12597 (i386_pseudo_register_read_into_value): Likewise.
12598 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12599 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12600 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12601 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12602 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12603 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12604 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12605 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12606 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12607
12608 2018-01-22 Yao Qi <yao.qi@linaro.org>
12609
12610 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12611 * configure.tgt: Remove target mt.
12612 * mt-tdep.c: Remove.
12613 * regcache.c (cooked_read_test): Remove the check for mt.
12614
12615 2018-01-22 Yao Qi <yao.qi@linaro.org>
12616
12617 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12618 instead of gdbarch_pseudo_register_read_value.
12619
12620 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12621
12622 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12623 language is Ada.
12624
12625 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12626
12627 * linespec.c (create_sals_line_offset): Remove code that preserved
12628 the symtab_and_line's line number.
12629
12630 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12631
12632 * varobj.c (varobj_create): Don't set valid_block when creating a
12633 floating varobj.
12634
12635 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12636
12637 * varobj.c (varobj_create): Remove out of date comment.
12638
12639 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12640
12641 PR mi/20395
12642 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12643 updating innermost block.
12644 * parse.c (innermost_block_tracker::update): Take extra type
12645 parameter, and check types match before updating innermost block.
12646 (write_dollar_variable): Update innermost block for registers.
12647 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12648 (innermost_block_tracker::innermost_block_tracker): Initialise
12649 m_types member.
12650 (innermost_block_tracker::reset): Take type parameter.
12651 (innermost_block_tracker::update): Take type parameter, and pass
12652 type through as needed.
12653 (innermost_block_tracker::m_types): New member.
12654 * varobj.c (varobj_create): Pass type when reseting innermost
12655 block.
12656
12657 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12658
12659 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12660 * ada-lang.c (resolve_subexp): Likewise.
12661 * breakpoint.c (set_breakpoint_condition) Likewise.
12662 (watch_command_1) Likewise.
12663 * c-exp.y (variable): Likewise.
12664 * d-exp.y (PrimaryExpression): Likewise.
12665 * f-exp.y (variable): Likewise.
12666 * go-exp.y (variable): Likewise.
12667 * m2-exp.y (variable): Likewise.
12668 * objfiles.c (objfile::~objfile): Likewise.
12669 * p-exp.y (variable): Likewise.
12670 * parse.c (innermost_block): Change type.
12671 * parser-defs.h (class innermost_block_tracker): New.
12672 (innermost_block): Change to innermost_block_tracker.
12673 * printcmd.c (display_command): Switch to innermost_block API.
12674 (do_one_display): Likewise.
12675 * rust-exp.y (do_one_display): Likewise.
12676 * symfile.c (clear_symtab_users): Likewise.
12677 * varobj.c (varobj_create): Switch to innermost_block API, replace
12678 use of innermost_block with block stored on varobj object.
12679
12680 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12681
12682 * expression.h (innermost_block): Remove declaration.
12683 * varobj.c: Add 'parser-defs.h' include.
12684
12685 2018-01-19 Tom Tromey <tom@tromey.com>
12686
12687 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12688 symbols in the static and global blocks.
12689
12690 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12691
12692 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12693 gdb_ptrace.h, and move including gdb_wait.h ...
12694 * nat/linux-ptrace.h: ... to here.
12695
12696 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12697
12698 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12699 inf_ptrace_detach_success.
12700 (inf_ptrace_detach_success): Add inferior parameter, use it
12701 instead of inferior_ptid, pass it to detach_inferior.
12702 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12703 parameter.
12704 * inferior.c (detach_inferior): Add overload that takes an
12705 inferior object.
12706 * inferior.h (detach_inferior): Likewise.
12707 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12708 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12709 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12710
12711 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12712
12713 * target.h (struct target_ops) <to_detach>: Add inferior
12714 parameter.
12715 (target_detach): Likewise.
12716 * target.c (dispose_inferior): Pass inferior down.
12717 (target_detach): Pass inferior down. Assert that it is equal to
12718 the current inferior.
12719 * aix-thread.c (aix_thread_detach): Pass inferior down.
12720 * corefile.c (core_file_command): Pass current_inferior() down.
12721 * corelow.c (core_detach): Add inferior parameter.
12722 * darwin-nat.c (darwin_detach): Likewise.
12723 * gnu-nat.c (gnu_detach): Likewise.
12724 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12725 * infcmd.c (detach_command): Pass current_inferior() down to
12726 target_detach.
12727 * infrun.c (follow_fork_inferior): Pass parent_inf to
12728 target_detach.
12729 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12730 target_detach.
12731 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12732 * linux-thread-db.c (thread_db_detach): Likewise.
12733 * nto-procfs.c (procfs_detach): Likewise.
12734 * procfs.c (procfs_detach): Likewise.
12735 * record.c (record_detach): Likewise.
12736 * record.h (struct inferior): Forward-declare.
12737 (record_detach): Add inferior parameter.
12738 * remote-sim.c (gdbsim_detach): Likewise.
12739 * remote.c (remote_detach_1): Likewise.
12740 (remote_detach): Likewise.
12741 (extended_remote_detach): Likewise.
12742 * sol-thread.c (sol_thread_detach): Likewise.
12743 * target-debug.h (target_debug_print_inferior_p): New macro.
12744 * target-delegates.c: Re-generate.
12745 * top.c (kill_or_detach): Pass inferior down to target_detach.
12746 * windows-nat.c (windows_detach): Add inferior parameter.
12747
12748 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12749
12750 * target.h (struct target_ops) <to_detach>: Remove args
12751 parameter.
12752 (target_detach): Likewise.
12753 * target.c (dispose_inferior): Adjust.
12754 (target_detach): Remove args parameter, adjust.
12755 * aix-thread.c (aix_thread_detach): Adjust.
12756 * corefile.c (core_file_command): Adjust.
12757 * corelow.c (core_detach): Adjust.
12758 * darwin-nat.c (darwin_detach): Adjust.
12759 * gnu-nat.c (gnu_detach): Adjust.
12760 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12761 * infcmd.c (detach_command): Adjust
12762 * infrun.c (follow_fork_inferior): Adjust.
12763 (handle_vfork_child_exec_or_exit): Adjust.
12764 * linux-fork.c (linux_fork_detach): Remove args parameter.
12765 * linux-fork.h (linux_fork_detach): Likewise.
12766 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12767 * linux-thread-db.c (thread_db_detach): Likewise.
12768 * nto-procfs.c (procfs_detach): Likewise.
12769 * procfs.c (procfs_detach): Likewise.
12770 (do_detach): Remove signo parameter.
12771 * record.c (record_detach): Remove args parameter.
12772 * record.h (record_detach): Likewise.
12773 * remote-sim.c (gdbsim_detach): Likewise.
12774 * remote.c (remote_detach_1): Likewise.
12775 (remote_detach): Likewise.
12776 (extended_remote_detach): Likewise.
12777 * sol-thread.c (sol_thread_detach): Likewise.
12778 * target-delegates.c: Re-generate.
12779 * top.c (struct qt_args) <args>: Remove field.
12780 (kill_or_detach): Don't pass args.
12781 (quit_force): Don't set args.
12782 * windows-nat.c (windows_detach): Remove args parameter.
12783
12784 2018-01-19 Yao Qi <yao.qi@linaro.org>
12785
12786 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12787 (arm_linux_init_abi): Install it.
12788
12789 2018-01-19 Yao Qi <yao.qi@linaro.org>
12790
12791 * osabi.c (gdb_osabi_names): Extend the regexp for
12792 arm-linux-gnueabihf.
12793
12794 2018-01-18 Yao Qi <yao.qi@linaro.org>
12795
12796 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12797 m_abbrevs.
12798 (abbrev_table::add_abbrev): Update.
12799 (abbrev_table::lookup_abbrev): Update.
12800
12801 2018-01-18 Yao Qi <yao.qi@linaro.org>
12802
12803 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12804
12805 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12806
12807 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12808 to "std::string".
12809
12810 2018-01-17 Tom Tromey <tom@tromey.com>
12811
12812 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12813
12814 2018-01-17 Tom Tromey <tom@tromey.com>
12815
12816 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12817 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12818 (create_array_type_with_stride): Update.
12819 * dwarf2read.c (set_die_type): Update.
12820
12821 2018-01-17 Tom Tromey <tom@tromey.com>
12822
12823 * dwarf2read.c (delayed_method_info): Remove typedef.
12824 (dwarf2_cu::method_info): Now a std::vector.
12825 (add_to_method_list): Update.
12826 (free_delayed_list): Remove.
12827 (compute_delayed_physnames): Update.
12828 (process_full_comp_unit, process_full_type_unit): Clear the method
12829 list. Remove cleanups.
12830 (psymtab_include_file_name): Add name_holder parameter. Use
12831 unique_xmalloc_ptr.
12832 (dwarf_decode_lines): Update.
12833
12834 2018-01-17 Tom Tromey <tom@tromey.com>
12835 Simon Marchi <simon.marchi@ericsson.com>
12836
12837 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12838 (dwarf2_per_objfile::free_cached_comp_units)
12839 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12840 (init_cutu_and_read_dies_no_follow): Update.
12841 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12842 (dwarf2_cu::~dwarf2_cu): New.
12843 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12844 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12845
12846 2018-01-17 Tom Tromey <tom@tromey.com>
12847 Simon Marchi <simon.marchi@ericsson.com>
12848
12849 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12850 (struct die_reader_specs) <abbrev_table>: New member.
12851 (struct abbrev_table): Add constructor.
12852 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12853 <abbrev_obstack>: Now an auto_obstack.
12854 (abbrev_table_up): New typedef.
12855 (init_cu_die_reader): Add abbrev_table parameter.
12856 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12857 Add result_dwo_abbrev_table.
12858 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12859 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12860 Update.
12861 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12862 parameter.
12863 (skip_children): Update.
12864 (abbrev_table::alloc_abbrev): Rename from
12865 abbrev_table_alloc_abbrev.
12866 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12867 (abbrev_table::lookup_abbrev): Rename from
12868 abbrev_table_lookup_abbrev.
12869 (abbrev_table_read_table): Return abbrev_table_up.
12870 (abbrev_table_free, abbrev_table_free_cleanup)
12871 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12872 (load_partial_dies): Update.
12873
12874 2018-01-17 Tom Tromey <tom@tromey.com>
12875
12876 * dwarf2read.c (dwarf2_compute_name): Update comment.
12877 (read_func_scope, read_variable): Update.
12878 (new_symbol): Remove.
12879 (new_symbol_full): Rename to new_symbol.
12880
12881 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12882
12883 PR gdb/16577
12884 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12885 a warning instead of throwing an error, set section size to 0 and return
12886 NULL.
12887 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12888
12889 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12890
12891 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12892 std::string.
12893 (linux_ptrace_attach_fail_reason_string): Likewise.
12894 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12895 Likewise.
12896 (linux_ptrace_attach_fail_reason_string): Likewise.
12897 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12898
12899 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12900
12901 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12902
12903 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12904
12905 PR gdb/21559
12906 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12907 checking for fs_base/gs_base fields in struct user_regs_struct.
12908 * configure: Regenerate.
12909
12910 2018-01-17 Yao Qi <yao.qi@linaro.org>
12911
12912 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12913 function.
12914 (aarch64_linux_init_abi): Install it to gdbarch hook
12915 gcc_target_options.
12916
12917 2018-01-15 Pedro Alves <palves@redhat.com>
12918
12919 * common/signals-state-save-restore.c
12920 (save_original_signals_state): Fix typos.
12921
12922 2017-01-12 Tom Tromey <tom@tromey.com>
12923 Sergio Durigan Junior <sergiodj@redhat.com>
12924
12925 * Makefile.in (install-only): Install gdb-add-index.
12926
12927 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12928
12929 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12930
12931 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12932
12933 * infrun.c (keep_going_pass_signal): Clear step-over info when
12934 insert_breakpoints fails.
12935
12936 2018-01-11 Pedro Alves <palves@redhat.com>
12937
12938 PR gdb/22583
12939 * infrun.c (resume): Rename to ...
12940 (resume_1): ... this.
12941 (resume): Reimplement as wrapper around resume_1.
12942
12943 2018-01-11 Pedro Alves <palves@redhat.com>
12944
12945 PR remote/22597
12946 * remote.c (remote_parse_stop_reply): Default to the last-set
12947 general thread instead of to 'magic_null_ptid'.
12948
12949 2018-01-10 Pedro Alves <palves@redhat.com>
12950
12951 * language.h (language_get_symbol_name_matcher): Rename ...
12952 (get_symbol_name_matcher): ... this.
12953 * language.c (language_get_symbol_name_matcher): Ditto.
12954 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
12955 callers adjusted.
12956
12957 2018-01-10 Pedro Alves <palves@redhat.com>
12958
12959 PR gdb/22670
12960 * dwarf2read.c
12961 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
12962 Adjust to use language_get_symbol_name_matcher instead of
12963 language_defn::la_get_symbol_name_matcher.
12964 * language.c (language_get_symbol_name_matcher): If in Ada mode
12965 and the lookup name is a verbatim match, return Ada's matcher.
12966 * language.h (language_get_symbol_name_matcher): Adjust comment.
12967 (ada_lookup_name_info::verbatim_p):: New method.
12968
12969 2018-01-10 Pedro Alves <palves@redhat.com>
12970
12971 PR gdb/22670
12972 * ada-lang.c (ada_collect_symbol_completion_matches): If the
12973 minsym's language is language_auto or language_cplus, pass down
12974 language_ada instead.
12975 * symtab.c (compare_symbol_name): Don't frob symbol language here.
12976
12977 2018-01-10 Pedro Alves <palves@redhat.com>
12978
12979 PR gdb/22670
12980 * minsyms.c (linkage_name_str): New function.
12981 (iterate_over_minimal_symbols): Use it.
12982
12983 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12984
12985 * NEWS: Document that 'info proc' now works on FreeBSD.
12986
12987 2018-01-09 John Baldwin <jhb@FreeBSD.org>
12988
12989 * configure.ac: Check for kinfo_getfile in libutil.
12990 * configure: Regenerate.
12991 * config.in: Regenerate.
12992 * fbsd-nat.c: Include "fbsd-tdep.h".
12993 (fbsd_fetch_cmdline): New.
12994 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
12995 rather than calling error.
12996 (fbsd_info_proc): New.
12997 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
12998 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
12999 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
13000
13001 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13002
13003 * fbsd-nat.c (struct free_deleter): Remove.
13004 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
13005
13006 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13007
13008 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
13009 NULL for an empty pathname.
13010
13011 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13012
13013 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
13014 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
13015 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
13016 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
13017 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
13018 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
13019 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
13020 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
13021 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
13022 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
13023 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
13024 (fbsd_core_fetch_timeval, fbsd_print_sigset)
13025 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
13026 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
13027 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
13028
13029 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
13030
13031 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
13032 (gnu_xfer_auxv): New function.
13033 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
13034 TARGET_OBJECT_AUXV.
13035
13036 2018-01-08 Yao Qi <yao.qi@linaro.org>
13037 Simon Marchi <simon.marchi@ericsson.com>
13038
13039 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13040 common/selftest.c.
13041 (COMMON_OBS): Remove selftest.o.
13042 * configure.ac: Append selftest-arch.c and common/selftest.c to
13043 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13044 * configure: Re-generated.
13045 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13046 GDB_SELF_TEST.
13047 (maintenance_info_selftests): Likewise.
13048
13049 2018-01-08 Xavier Roirand <roirand@adacore.com>
13050
13051 * ada-valprint.c (val_print_packed_array_elements): Use
13052 proper number of elements when printing an array indexed
13053 by an enumeration type.
13054
13055 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13056
13057 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13058 (dw2_get_file_names_reader): Adjust.
13059 (lookup_dwo_signatured_type): Adjust.
13060 (lookup_dwp_signatured_type): Adjust.
13061 (lookup_signatured_type): Adjust.
13062 (create_type_unit_group): Adjust.
13063 (get_type_unit_group): Adjust.
13064 (process_psymtab_comp_unit_reader): Adjust.
13065 (build_type_psymtabs_reader): Adjust.
13066 (scan_partial_symbols): Adjust.
13067 (add_partial_symbol): Adjust.
13068 (add_partial_subprogram): Adjust.
13069 (peek_die_abbrev): Adjust.
13070 (fixup_go_packaging): Adjust.
13071 (process_imported_unit_die): Adjust.
13072 (dwarf2_compute_name): Adjust.
13073 (dwarf2_physname): Adjust.
13074 (read_import_statement): Adjust.
13075 (handle_DW_AT_stmt_list): Adjust.
13076 (read_file_scope): Adjust.
13077 (read_func_scope): Adjust.
13078 (read_lexical_block_scope): Adjust.
13079 (read_call_site_scope): Adjust.
13080 (read_variable): Adjust.
13081 (dwarf2_rnglists_process): Adjust.
13082 (dwarf2_ranges_process): Adjust.
13083 (dwarf2_ranges_read): Adjust.
13084 (dwarf2_get_pc_bounds): Adjust.
13085 (dwarf2_record_block_ranges): Adjust.
13086 (dwarf2_add_field): Adjust.
13087 (dwarf2_add_member_fn): Adjust.
13088 (read_structure_type): Adjust.
13089 (process_structure_scope): Adjust.
13090 (read_enumeration_type): Adjust.
13091 (read_array_type): Adjust.
13092 (mark_common_block_symbol_computed): Adjust.
13093 (read_common_block): Adjust.
13094 (read_namespace_type): Adjust.
13095 (read_namespace): Adjust.
13096 (read_module_type): Adjust.
13097 (read_tag_pointer_type): Adjust.
13098 (read_tag_ptr_to_member_type): Adjust.
13099 (read_tag_string_type): Adjust.
13100 (read_subroutine_type): Adjust.
13101 (read_typedef): Adjust.
13102 (read_base_type): Adjust.
13103 (attr_to_dynamic_prop): Adjust.
13104 (read_subrange_type): Adjust.
13105 (read_unspecified_type): Adjust.
13106 (dwarf2_read_abbrevs): Adjust.
13107 (load_partial_dies): Adjust.
13108 (read_partial_die): Adjust.
13109 (find_partial_die): Adjust.
13110 (guess_partial_die_structure_name): Adjust.
13111 (fixup_partial_die): Adjust.
13112 (read_attribute_value): Adjust.
13113 (read_addr_index): Adjust.
13114 (read_addr_index_from_leb128): Adjust.
13115 (read_str_index): Adjust.
13116 (dwarf2_string_attr): Adjust.
13117 (get_debug_line_section): Adjust.
13118 (dwarf_decode_line_header): Adjust.
13119 (lnp_state_machine::check_line_address): Adjust.
13120 (dwarf_decode_lines_1): Adjust.
13121 (dwarf_decode_lines): Adjust.
13122 (dwarf2_start_symtab): Adjust.
13123 (var_decode_location): Adjust.
13124 (new_symbol_full): Adjust.
13125 (dwarf2_const_value_data): Adjust.
13126 (dwarf2_const_value_attr): Adjust.
13127 (dwarf2_const_value): Adjust.
13128 (die_type): Adjust.
13129 (die_containing_type): Adjust.
13130 (build_error_marker_type): Adjust.
13131 (lookup_die_type): Adjust.
13132 (guess_full_die_structure_name): Adjust.
13133 (anonymous_struct_prefix): Adjust.
13134 (determine_prefix): Adjust.
13135 (dwarf2_name): Adjust.
13136 (follow_die_ref_or_sig): Adjust.
13137 (follow_die_offset): Adjust.
13138 (follow_die_ref): Adjust.
13139 (follow_die_sig_1): Adjust.
13140 (follow_die_sig): Adjust.
13141 (get_signatured_type): Adjust.
13142 (get_DW_AT_signature_type): Adjust.
13143 (decode_locdesc): Adjust.
13144 (dwarf_decode_macros): Adjust.
13145 (cu_debug_loc_section): Adjust.
13146 (fill_in_loclist_baton): Adjust.
13147 (dwarf2_symbol_mark_computed): Adjust.
13148 (init_one_comp_unit): Don't assign
13149 dwarf2_cu::dwarf2_per_objfile.
13150 (set_die_type): Adjust.
13151
13152 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13153
13154 * dwarf2read.c (struct mapped_debug_names): Add constructor.
13155 <dwarf2_per_objfile>: New field.
13156 (dwarf2_per_objfile): Remove global.
13157 (get_dwarf2_per_objfile): New function.
13158 (set_dwarf2_per_objfile): New function.
13159 (dwarf2_build_psymtabs_hard): Change objfile parameter to
13160 dwarf2_per_objfile.
13161 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13162 (read_abbrev_offset): Likewise.
13163 (read_indirect_string): Likewise.
13164 (read_indirect_line_string): Likewise.
13165 (read_indirect_string_at_offset): Likewise.
13166 (read_indirect_string_from_dwz): Likewise.
13167 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13168 dwarf2_per_objfile.
13169 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13170 (create_all_comp_units): Change objfile parameter to
13171 dwarf2_per_objfile.
13172 (create_all_type_units): Likewise.
13173 (process_queue): Add dwarf2_per_objfile parameter.
13174 (read_and_check_comp_unit_head): Likewise.
13175 (lookup_dwo_unit_in_dwp): Likewise.
13176 (get_dwp_file): Likewise.
13177 (process_cu_includes): Likewise.
13178 (struct free_dwo_file_cleanup_data): New struct.
13179 (dwarf2_has_info): Use get_dwarf2_per_objfile and
13180 set_dwarf2_per_objfile.
13181 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
13182 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
13183 context, adjust calls.
13184 (dw2_instantiate_symtab): Likewise.
13185 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
13186 (dw2_get_cu): Likewise.
13187 (create_cu_from_index_list): Change objfile parameter to
13188 dwarf2_per_objfile.
13189 (create_cus_from_index_list): Get dwarf2_per_objfile from
13190 context, adjust calls.
13191 (create_cus_from_index): Likewise.
13192 (create_signatured_type_table_from_index): Change objfile
13193 parameter to dwarf2_per_objfile.
13194 (create_signatured_type_table_from_debug_names): Change objfile
13195 parameter to dwarf2_per_objfile.
13196 (create_addrmap_from_index): Likewise.
13197 (create_addrmap_from_aranges): Likewise.
13198 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
13199 (dw2_setup): Remove.
13200 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
13201 context.
13202 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
13203 get_dwarf2_per_objfile.
13204 (dw2_forget_cached_source_info): Likewise.
13205 (dw2_map_symtabs_matching_filename): Likewise.
13206 (struct dw2_symtab_iterator) <index>: Remove.
13207 <dwarf2_per_objfile>: New field.
13208 (dw2_symtab_iter_init): Replace index parameter with
13209 dwarf2_per_objfile.
13210 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
13211 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
13212 (dw2_print_stats): Likewise.
13213 (dw2_dump): Likewise.
13214 (dw2_expand_symtabs_for_function): Likewise.
13215 (dw2_expand_all_symtabs): Likewise.
13216 (dw2_expand_symtabs_with_fullname): Likewise.
13217 (dw2_expand_marked_cus): Replace index and objfile parameters
13218 with dwarf2_per_objfile.
13219 (dw_expand_symtabs_matching_file_matcher): Add
13220 dwarf2_per_objfile parameter and adjust calls.
13221 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13222 adjust calls.
13223 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13224 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13225 adjust calls.
13226 (create_cus_from_debug_names_list): Replace objfile parameter
13227 with dwarf2_per_objfile and adjust calls.
13228 (create_cus_from_debug_names): Likewise.
13229 (dwarf2_read_debug_names): Likewise.
13230 (mapped_debug_names::namei_to_name): Adjust call.
13231 (dw2_debug_names_iterator::next): Likewise.
13232 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13233 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13234 (dw2_debug_names_dump): Likewise.
13235 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13236 (dw2_debug_names_expand_symtabs_matching): Likewise.
13237 (dwarf2_initialize_objfile): Likewise.
13238 (dwarf2_build_psymtabs): Likewise.
13239 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13240 this_cu.
13241 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13242 (read_and_check_comp_unit_head): Likewise.
13243 (read_abbrev_offset): Likewise.
13244 (create_debug_type_hash_table): Likewise.
13245 (create_debug_types_hash_table): Likewise.
13246 (create_all_type_units): Replace objfile parameter with
13247 dwarf2_per_objfile.
13248 (add_type_unit): Add dwarf2_per_objfile parameter.
13249 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13250 with dwarf2_per_objfile.
13251 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13252 (lookup_dwp_signatured_type): Likewise.
13253 (lookup_signatured_type): Likewise.
13254 (read_cutu_die_from_dwo): Likewise.
13255 (init_tu_and_read_dwo_dies): Likewise.
13256 (init_cutu_and_read_dies): Likewise.
13257 (init_cutu_and_read_dies_no_follow): Likewise.
13258 (allocate_type_unit_groups_table): Add objfile parameter.
13259 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13260 (get_type_unit_group): Likewise.
13261 (process_psymtab_comp_unit): Update call.
13262 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13263 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13264 (print_tu_stats): Likewise.
13265 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13266 in void* parameter.
13267 (build_type_psymtabs): Change objfile parameter to
13268 dwarf2_per_objfile.
13269 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13270 passed in void* parameter.
13271 (process_skeletonless_type_units): Change objfile parameter to
13272 dwarf2_per_objfile.
13273 (set_partial_user): Likewise.
13274 (dwarf2_build_psymtabs_hard): Likewise.
13275 (read_comp_units_from_section): Likewise.
13276 (create_all_comp_units): Likewise.
13277 (scan_partial_symbols): Update calls.
13278 (add_partial_symbol): Likewise.
13279 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13280 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13281 (process_queue): Add dwarf2_per_objfile parameter.
13282 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13283 (compute_compunit_symtab_includes): Likewise.
13284 (process_cu_includes): Add dwarf2_per_objfile parameter.
13285 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13286 (process_full_type_unit): Likewise.
13287 (process_imported_unit_die): Update call.
13288 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13289 (read_file_scope): Likewise.
13290 (allocate_dwo_file_hash_table): Add objfile parameter.
13291 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13292 (create_cus_hash_table): Likewise.
13293 (create_dwp_hash_table): Likewise.
13294 (create_dwo_unit_in_dwp_v1): Likewise.
13295 (create_dwp_v2_section): Likewise.
13296 (create_dwo_unit_in_dwp_v2): Likewise.
13297 (lookup_dwo_unit_in_dwp): Likewise.
13298 (try_open_dwop_file): Likewise.
13299 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13300 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13301 cleanup to include a reference to dwarf2_per_objfile.
13302 (open_dwp_file): Add dwarf2_per_objfile parameter.
13303 (open_and_init_dwp_file): Likewise.
13304 (get_dwp_file): Likewise.
13305 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13306 (queue_and_load_all_dwo_tus): Update call.
13307 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13308 data.
13309 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13310 (dwarf2_ranges_process): Likewise.
13311 (dwarf2_get_pc_bounds): Likewise.
13312 (mark_common_block_symbol_computed): Likewise.
13313 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13314 (dwarf2_read_abbrevs): Update call.
13315 (read_partial_die): Use dwarf2_per_objfile from cu.
13316 (find_partial_die): Likewise.
13317 (fixup_partial_die): Likewise.
13318 (read_attribute_value): Likewise.
13319 (read_indirect_string_at_offset_from): Add objfile parameter.
13320 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13321 parameter.
13322 (read_indirect_string_from_dwz): Add objfile parameter.
13323 (read_indirect_string): Add objfile parameter.
13324 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13325 (read_addr_index): Use dwarf2_per_objfile from cu.
13326 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13327 call dw2_setup.
13328 (read_str_index): Use dwarf2_per_objfile from cu.
13329 (get_debug_line_section): Likewise.
13330 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13331 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13332 (new_symbol_full): Use dwarf2_per_objfile from cu.
13333 (build_error_marker_type): Likewise.
13334 (lookup_die_type): Likewise.
13335 (determine_prefix): Likewise.
13336 (follow_die_offset): Likewise.
13337 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13338 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13339 (dwarf2_fetch_die_type_sect_off): Likewise.
13340 (dwarf2_get_die_type): Likewise.
13341 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13342 (get_signatured_type): Likewise.
13343 (get_DW_AT_signature_type): Likewise.
13344 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13345 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13346 (cu_debug_loc_section): Likewise.
13347 (fill_in_loclist_baton): Likewise.
13348 (dwarf2_symbol_mark_computed): Likewise.
13349 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13350 dwarf2_per_objfile.
13351 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13352 parameter.
13353 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13354 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13355 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13356 (set_die_type): Use dwarf2_free_objfile from cu.
13357 (get_die_type_at_offset): Likewise.
13358 (dwarf2_per_objfile_free): Don't assign global variable.
13359 (debug_names) <constructor>: Add dwarf2_per_objfile
13360 parameter, update m_debugstrlookup construction.
13361 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13362 parameter.
13363 <m_dwarf2_per_objfile>: New field.
13364 <lookup>: Use m_dwarf2_per_objfile.
13365 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13366 (psyms_seen_size): Likewise.
13367 (write_gdbindex): Replace objfile parameter with
13368 dwarf2_per_objfile.
13369 (write_debug_names): Likewise.
13370 (write_psymtabs_to_index): Likewise.
13371 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13372 calls.
13373
13374 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13375
13376 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13377 <dwarf2_per_objfile>: New field.
13378 (struct dwarf2_per_cu_data) <objfile>: Remove.
13379 <dwarf2_per_objfile>: New field.
13380 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13381 of objfile.
13382 (create_signatured_type_table_from_index): Likewise.
13383 (create_debug_type_hash_table): Likewise.
13384 (fill_in_sig_entry_from_dwo_entry): Likewise.
13385 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13386 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13387 objfile.
13388 (create_partial_symtab): Access objfile through
13389 dwarf2_per_objfile.
13390 (process_psymtab_comp_unit_reader): Likewise.
13391 (read_comp_units_from_section): Likewise.
13392 (scan_partial_symbols): Likewise.
13393 (add_partial_symbol): Likewise.
13394 (add_partial_subprogram): Likewise.
13395 (peek_die_abbrev): Likewise.
13396 (fixup_go_packaging): Likewise.
13397 (process_full_comp_unit): Likewise.
13398 (process_full_type_unit): Likewise.
13399 (process_imported_unit_die): Likewise.
13400 (dwarf2_compute_name): Likewise.
13401 (dwarf2_physname): Likewise.
13402 (read_import_statement): Likewise.
13403 (create_cus_hash_table): Assign dwarf2_physname instead of
13404 objfile.
13405 (read_func_scope): Access objfile through dwarf2_per_objfile.
13406 (read_lexical_block_scope): Likewise.
13407 (read_call_site_scope): Likewise.
13408 (read_variable): Likewise.
13409 (dwarf2_rnglists_process): Likewise.
13410 (dwarf2_ranges_process): Likewise.
13411 (dwarf2_ranges_read): Likewise.
13412 (dwarf2_record_block_ranges): Likewise.
13413 (dwarf2_add_field): Likewise.
13414 (dwarf2_add_member_fn): Likewise.
13415 (read_structure_type): Likewise.
13416 (process_structure_scope): Likewise.
13417 (read_enumeration_type): Likewise.
13418 (read_array_type): Likewise.
13419 (read_common_block): Likewise.
13420 (read_namespace_type): Likewise.
13421 (read_namespace): Likewise.
13422 (read_module_type): Likewise.
13423 (read_tag_pointer_type): Likewise.
13424 (read_tag_ptr_to_member_type): Likewise.
13425 (read_tag_string_type): Likewise.
13426 (read_subroutine_type): Likewise.
13427 (read_typedef): Likewise.
13428 (read_base_type): Likewise.
13429 (attr_to_dynamic_prop): Likewise.
13430 (read_subrange_type): Likewise.
13431 (read_unspecified_type): Likewise.
13432 (load_partial_dies): Likewise.
13433 (read_partial_die): Likewise.
13434 (find_partial_die): Likewise.
13435 (guess_partial_die_structure_name): Likewise.
13436 (fixup_partial_die): Likewise.
13437 (read_attribute_value): Likewise.
13438 (read_addr_index_from_leb128): Likewise.
13439 (dwarf2_read_addr_index): Likewise.
13440 (dwarf2_string_attr): Likewise.
13441 (lnp_state_machine::check_line_address): Likewise.
13442 (dwarf_decode_lines_1): Likewise.
13443 (dwarf_decode_lines): Likewise.
13444 (dwarf2_start_symtab): Likewise.
13445 (var_decode_location): Likewise.
13446 (new_symbol_full): Likewise.
13447 (dwarf2_const_value_data): Likewise.
13448 (dwarf2_const_value_attr): Likewise.
13449 (dwarf2_const_value): Likewise.
13450 (die_type): Likewise.
13451 (die_containing_type): Likewise.
13452 (lookup_die_type): Likewise.
13453 (guess_full_die_structure_name): Likewise.
13454 (anonymous_struct_prefix): Likewise.
13455 (dwarf2_name): Likewise.
13456 (follow_die_ref_or_sig): Likewise.
13457 (follow_die_offset): Likewise.
13458 (follow_die_ref): Likewise.
13459 (dwarf2_fetch_die_loc_sect_off): Likewise.
13460 (dwarf2_fetch_constant_bytes): Likewise.
13461 (dwarf2_fetch_die_type_sect_off): Likewise.
13462 (dwarf2_get_die_type): Likewise.
13463 (follow_die_sig): Likewise.
13464 (decode_locdesc): Likewise.
13465 (dwarf2_per_cu_objfile): Likewise.
13466 (dwarf2_per_cu_text_offset): Likewise.
13467 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13468 objfile.
13469 (set_die_type): Access objfile through
13470 dwarf2_per_objfile.
13471
13472 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13473
13474 * valprint.c (converted_character_d): Remove typedef.
13475 (DEF_VEC_O (converted_character_d)): Remove.
13476 (count_next_character): Use std::vector.
13477 (print_converted_chars_to_obstack): Likewise.
13478 (generic_printstr): Likewise.
13479
13480 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13481
13482 * xml-support.h (struct gdb_xml_value): Add constructor.
13483 <value>: Change type to unique_xmalloc_ptr.
13484 (gdb_xml_value_s): Remove typedef.
13485 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13486 (gdb_xml_element_start_handler): Change parameter type to
13487 std::vector.
13488 (xml_find_attribute): Likewise.
13489 * xml-support.c (xml_find_attribute): Change parameter type to
13490 std::vector and adjust.
13491 (gdb_xml_values_cleanup): Remove.
13492 (gdb_xml_parser::start_element): Adjust to std::vector.
13493 (xinclude_start_include): Change paraeter type to std::vector
13494 and adjust.
13495 * btrace.c (check_xml_btrace_version): Likewise.
13496 (parse_xml_btrace_block): Likewise.
13497 (parse_xml_btrace_pt_config_cpu): Likewise.
13498 (parse_xml_btrace_pt): Likewise.
13499 (parse_xml_btrace_conf_bts): Likewise.
13500 (parse_xml_btrace_conf_pt): Likewise.
13501 * memory-map.c (memory_map_start_memory): Likewise.
13502 (memory_map_start_property): Likewise.
13503 * osdata.c (osdata_start_osdata): Likewise.
13504 (osdata_start_item): Likewise.
13505 (osdata_start_column): Likewise.
13506 * remote.c (start_thread): Likewise.
13507 * solib-aix.c (library_list_start_library): Likewise.
13508 (library_list_start_list): Likewise.
13509 * solib-svr4.c (library_list_start_library): Likewise.
13510 (svr4_library_list_start_list): Likewise.
13511 * solib-target.c (library_list_start_segment): Likewise.
13512 (library_list_start_section): Likewise.
13513 (library_list_start_library): Likewise.
13514 (library_list_start_list): Likewise.
13515 * tracepoint.c (traceframe_info_start_memory): Likewise.
13516 (traceframe_info_start_tvar): Likewise.
13517 * xml-syscall.c (syscall_start_syscall): Likewise.
13518 * xml-tdesc.c (tdesc_start_target): Likewise.
13519 (tdesc_start_feature): Likewise.
13520 (tdesc_start_reg): Likewise.
13521 (tdesc_start_union): Likewise.
13522 (tdesc_start_struct): Likewise.
13523 (tdesc_start_flags): Likewise.
13524 (tdesc_start_enum): Likewise.
13525 (tdesc_start_field): Likewise.
13526 (tdesc_start_enum_value): Likewise.
13527 (tdesc_start_vector): Likewise.
13528
13529 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13530
13531 * extension.h (struct xmethod_worker) <clone>: Remove.
13532 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13533 Remove.
13534 (python_xmethod_worker::clone): Remove.
13535 * valops.c (find_overload_match): Use std::move instead of
13536 clone.
13537
13538 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13539
13540 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13541 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13542 <free_xmethod_worker_data>: Remove.
13543 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13544 <get_xmethod_arg_types>: Remove.
13545 <get_xmethod_result_type>: Remove.
13546 <invoke_xmethod>: Remove.
13547 * extension.c (new_xmethod_worker): Remove.
13548 (clone_xmethod_worker): Remove.
13549 (get_matching_xmethod_workers): Return void, pass std::vector by
13550 pointer.
13551 (get_xmethod_arg_types): Rename to...
13552 (xmethod_worker::get_arg_types): ... this, and adjust.
13553 (get_xmethod_result_type): Rename to...
13554 (xmethod_worker::get_result_type): ... this, and adjust.
13555 (invoke_xmethod): Remove.
13556 (free_xmethod_worker): Remove.
13557 (free_xmethod_worker_vec): Remove.
13558 * extension.h (enum ext_lang_rc): Move here from
13559 extension-priv.h.
13560 (struct xmethod_worker): Add constructor and destructor.
13561 <data>: Remove.
13562 <value>: Remove.
13563 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13564 virtual pure methods.
13565 <get_arg_types, get_result_type>: New methods.
13566 (xmethod_worker_ptr): Remove typedef.
13567 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13568 (xmethod_worker_vec): Remove typedef.
13569 (xmethod_worker_up): New typedef.
13570 (invoke_xmethod): Remove.
13571 (clone_xmethod_worker): Remove.
13572 (free_xmethod_worker): Remove.
13573 (free_xmethod_worker_vec): Remove.
13574 (get_xmethod_arg_types): Remove.
13575 (get_xmethod_result_type): Remove.
13576 * valops.c (find_method_list): Use std::vector, don't use
13577 intermediate vector.
13578 (value_find_oload_method_list): Use std::vector.
13579 (find_overload_match): Use std::vector.
13580 (find_oload_champ): Use std::vector.
13581 * value.c (value_free): Use operator delete.
13582 (value_of_xmethod): Rename to...
13583 (value_from_xmethod): ... this. Don't assign
13584 xmethod_worker::value, take rvalue-reference.
13585 (result_type_of_xmethod): Adjust.
13586 (call_xmethod): Adjust.
13587 * value.h: Include extension.h.
13588 (struct xmethod_worker): Don't forward-declare.
13589 (value_of_xmethod): Rename to...
13590 (value_from_xmethod): ... this, take rvalue-reference.
13591 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13592 (struct python_xmethod_worker): ... this, add constructor and
13593 destructor.
13594 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13595 (gdbpy_free_xmethod_worker_data): Rename to...
13596 (python_xmethod_worker::~python_xmethod_worker): ... this and
13597 adjust.
13598 (gdbpy_clone_xmethod_worker_data): Rename to...
13599 (python_xmethod_worker::clone): ... this and adjust.
13600 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13601 temporary vector.
13602 (gdbpy_get_xmethod_arg_types): Rename to...
13603 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13604 (gdbpy_get_xmethod_result_type): Rename to...
13605 (python_xmethod_worker::do_get_result_type): ... this and
13606 adjust.
13607 (gdbpy_invoke_xmethod): Rename to...
13608 (python_xmethod_worker::invoke): ... this and adjust.
13609 (new_python_xmethod_worker): Rename to...
13610 (python_xmethod_worker::python_xmethod_worker): ... this and
13611 adjust.
13612 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13613 Remove.
13614 (gdbpy_free_xmethod_worker_data): Remove.
13615 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13616 (gdbpy_get_xmethod_arg_types): Remove.
13617 (gdbpy_get_xmethod_result_type): Remove.
13618 (gdbpy_invoke_xmethod): Remove.
13619 * python/python.c (python_extension_ops): Remove obsolete
13620 callbacks.
13621
13622 2018-01-05 Pedro Alves <palves@redhat.com>
13623
13624 PR gdb/18653
13625 * common/signals-state-save-restore.c
13626 (save_original_signals_state): New parameter 'quiet'. Warn if we
13627 find a custom handler preinstalled, instead of internal erroring.
13628 But only warn if !quiet.
13629 * common/signals-state-save-restore.h
13630 (save_original_signals_state): New parameter 'quiet'.
13631 * main.c (captured_main_1): Move save_original_signals_state call
13632 after option handling, and pass QUIET.
13633
13634 2018-01-05 Pedro Alves <palves@redhat.com>
13635
13636 * spu-tdep.c (spu_catch_start): Pass
13637 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13638
13639 2018-01-05 Pedro Alves <palves@redhat.com>
13640
13641 PR gdb/22670
13642 * ada-lang.c (literal_symbol_name_matcher): New function.
13643 (ada_get_symbol_name_matcher): Use it for
13644 symbol_name_match_type::SEARCH_NAME.
13645 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13646 it down instead of assuming symbol_name_match_type::FULL.
13647 * block.h (block_lookup_symbol): New parameter 'match_type'.
13648 * c-valprint.c (print_unpacked_pointer): Use
13649 lookup_symbol_search_name instead of lookup_symbol.
13650 * compile/compile-object-load.c (get_out_value_type): Pass down
13651 symbol_name_match_type::SEARCH_NAME.
13652 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13653 symbol_name_match_type::FULL.
13654 * cp-support.c (cp_get_symbol_name_matcher): Handle
13655 symbol_name_match_type::SEARCH_NAME.
13656 * infrun.c (insert_exception_resume_breakpoint): Use
13657 lookup_symbol_search_name.
13658 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13659 * psymtab.c (maintenance_check_psymtabs): Use
13660 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13661 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13662 SYMBOL_SEARCH_NAME.
13663 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13664 if symbol_name_match_type::SEARCH_NAME.
13665 (lookup_symbol_in_language): Pass down
13666 symbol_name_match_type::FULL.
13667 (lookup_symbol_search_name): New.
13668 (lookup_language_this): Pass down
13669 symbol_name_match_type::SEARCH_NAME.
13670 (lookup_symbol_aux, lookup_local_symbol): New parameter
13671 'match_type'. Pass it down.
13672 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13673 (lookup_symbol_search_name): New declaration.
13674 (lookup_symbol_in_block): New 'match_type' parameter.
13675
13676 2018-01-05 Pedro Alves <palves@redhat.com>
13677
13678 PR gdb/22670
13679 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13680 ada_lookup_symbol.
13681 (ada_lookup_symbol): Reimplement in terms of
13682 ada_lookup_symbol_list, bits factored out from
13683 ada_lookup_encoded_symbol.
13684
13685 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13686
13687 * ada-exp.y (write_object_renaming): When subscripting an array
13688 using a symbol as the index, pass the block in call to
13689 ada_lookup_encoded_symbol when looking that symbol up.
13690
13691 2018-01-05 Jerome Guitton <guitton@adacore.com>
13692
13693 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13694 TYPE_INDEX_TYPE.
13695
13696 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13697
13698 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13699 the case where VALUE_LVAL (val0) is not lval_memory.
13700
13701 2018-01-05 Xavier Roirand <roirand@adacore.com>
13702
13703 * ada-valprint.c (print_optional_low_bound): Handle
13704 character-indexed array printing like boolean-indexed array
13705 printing.
13706
13707 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13708
13709 * NEWS: Create a new section for the next release branch.
13710 Rename the section of the current branch, now that it has
13711 been cut.
13712
13713 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13714
13715 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13716 * version.in: Bump version to 8.1.50.DATE-git.
13717
13718 2018-01-03 Xavier Roirand <roirand@adacore.com>
13719
13720 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13721 Add field.
13722 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13723 Add field.
13724 (default_exception_support_info) <catch_handlers_sym>: Add field.
13725 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13726 (ada_exception_name_addr_1): Add "catch handlers" handling.
13727 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13728 Update all callers.
13729 (create_excep_cond_exprs) <ex>: Add parameter.
13730 (re_set_exception): Update create_excep_cond_exprs call.
13731 (print_it_exception, print_one_exception, print_mention_exception)
13732 (print_recreate_exception): Add "catch handler" handling.
13733 (allocate_location_catch_handlers, re_set_catch_handlers)
13734 (check_status_catch_handlers, print_it_catch_handlers)
13735 (print_one_catch_handlers, print_mention_catch_handlers)
13736 (print_recreate_catch_handlers): New function.
13737 (catch_handlers_breakpoint_ops): New variable.
13738 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13739 Add parameter. Add "catch handler" handling.
13740 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13741 Add "catch handler" handling.
13742 (ada_exception_catchpoint_cond_string): Add "catch handler"
13743 handling.
13744 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13745 call.
13746 (catch_ada_handlers_command): New function.
13747 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13748 operations structure.
13749 (_initialize_ada_language): Add "catch handlers" command entry.
13750 * NEWS: Document "catch handlers" feature.
13751
13752 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13753
13754 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13755 account when creating the array type of the slice.
13756 (ada_value_slice): Likewise.
13757
13758 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13759
13760 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13761 New enum value.
13762 (create_array_type_with_stride): Add byte_stride_prop parameter.
13763 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13764 New parameter. Update all callers in this file.
13765 (array_type_has_dynamic_stride): New function.
13766 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13767 of arrays with dynamic byte strides.
13768 * dwarf2read.c (read_array_type): Add support for dynamic
13769 DW_AT_byte_stride attributes.
13770
13771 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13772
13773 * dwarf2read.c (read_unspecified_type): Treat
13774 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13775
13776 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13777
13778 Update copyright year range in all GDB files.
13779
13780 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13781
13782 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13783 and gdb/testsuite/gdb.base/step-line.c.
13784
13785 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13786
13787 * copyright.py (main): Dump the contents of
13788 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13789 even if BY_HAND is empty.
13790
13791 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13792
13793 * top.c (print_gdb_version): Update Copyright year in version
13794 message.
13795
13796 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13797
13798 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13799
13800 For older changes see ChangeLog-2017.
13801 \f
13802 Local Variables:
13803 mode: change-log
13804 left-margin: 8
13805 fill-column: 74
13806 version-control: never
13807 coding: utf-8
13808 End: