Darwin: Handle unrelocated dyld.
[binutils-gdb.git] / gdb / ChangeLog
1 2018-09-19 Xavier Roirand <roirand@adacore.com>
2
3 PR gdb/20981:
4 * solib-darwin.c (darwin_get_dyld_bfd): New function.
5 (darwin_solib_get_all_image_info_addr_at_init): Update call.
6 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
7
8 2018-09-19 John Baldwin <jhb@FreeBSD.org>
9
10 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
11 (fbsd_print_sockaddr_in6): Likewise.
12
13 2018-09-19 Richard Bunt <richard.bunt@arm.com>
14 Chris January <chris.january@arm.com>
15
16 * eval.c (skip_undetermined_arglist): Skip argument list helper.
17 (evaluate_subexp_standard): Return a dummy type when
18 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
19 OP_F77_UNDETERMINED_ARGLIST case.
20 * expression.h (enum noside): Update comment.
21
22 2018-09-19 George Vasick <george.vasick@oracle.com>
23
24 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
25
26 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
27 April Chin <april.chin@oracle.com>
28 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
29
30 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
31 uint_t lwpid_t.
32 (create_procinfo): Print pids in /proc without leading zeros.
33
34 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
35
36 * nios2-tdep.c (nios2_gcc_target_options): New.
37 (nios2_gdb_arch_init): Install new hook.
38
39 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
40
41 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
42 New file.
43 * update-gnulib.sh: Apply patch.
44 * configure: Re-generate.
45
46 2018-09-18 John Baldwin <jhb@FreeBSD.org>
47
48 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
49 description. Make "info proc" command descriptions more
50 consistent.
51
52 2018-09-18 John Baldwin <jhb@FreeBSD.org>
53
54 * NEWS: Mention 'info proc files' command.
55
56 2018-09-18 John Baldwin <jhb@FreeBSD.org>
57
58 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
59 descriptors for IP_FILES and IP_ALL.
60
61 2018-09-18 John Baldwin <jhb@FreeBSD.org>
62
63 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
64 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
65 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
66 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
67 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
68 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
69 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
70 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
71 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
72 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
73 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
74 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
75 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
76 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
77 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
78 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
79 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
80 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
81 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
82 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
83 (struct fbsd_sockaddr_un): New types.
84 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
85 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
86 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
87 (fbsd_core_info_proc_files): New functions.
88 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
89 IP_ALL.
90 * fbsd-tdep.h (fbsd_info_proc_files_header)
91 (fbsd_info_proc_files_entry): New.
92
93 2018-09-18 John Baldwin <jhb@FreeBSD.org>
94
95 * defs.h (enum info_proc_what) [IP_FILES]: New value.
96 * infcmd.c (info_proc_cmd_files): New function.
97 (_initialize_infcmd): Register 'info proc files' command.
98
99 2018-09-18 John Baldwin <jhb@FreeBSD.org>
100
101 * gnulib/aclocal-m4-deps.mk: Re-generate.
102 * gnulib/aclocal.m4: Re-generate.
103 * gnulib/config.in: Re-generate.
104 * gnulib/configure: Re-generate.
105 * gnulib/import/Makefile.am: Re-generate.
106 * gnulib/import/Makefile.in: Re-generate.
107 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
108 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
109 * gnulib/import/arpa_inet.in.h: New file.
110 * gnulib/import/inet_ntop.c: New file.
111 * gnulib/import/m4/arpa_inet_h.m4: New file.
112 * gnulib/import/m4/inet_ntop.m4: New file.
113 * gnulib/import/m4/netinet_in_h.m4: New file.
114 * gnulib/import/m4/socklen.m4: New file.
115 * gnulib/import/m4/sockpfaf.m4: New file.
116 * gnulib/import/m4/stdalign.m4: New file.
117 * gnulib/import/m4/sys_uio_h.m4: New file.
118 * gnulib/import/netinet_in.in.h: New file.
119 * gnulib/import/stdalign.in.h: New file.
120 * gnulib/import/sys_socket.c: New file.
121 * gnulib/import/sys_socket.in.h: New file.
122 * gnulib/import/sys_uio.in.h: New file.
123 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
124 module.
125
126 2018-09-18 John Baldwin <jhb@FreeBSD.org>
127
128 * gnulib/aclocal-m4-deps.mk: New file.
129 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
130 deterministically.
131
132 2018-09-18 John Baldwin <jhb@FreeBSD.org>
133
134 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
135 KVE_PATH.
136
137 2018-09-18 Tom Tromey <tom@tromey.com>
138
139 * compile/compile-object-load.c (struct
140 link_hash_table_cleanup_data): Add constructor and destructor.
141 Use DISABLE_COPY_AND_ASSIGN.
142 (~link_hash_table_cleanup_data): Rename from
143 link_hash_table_free. Now a destructor.
144 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
145
146 2018-09-18 Tom Tromey <tom@tromey.com>
147
148 * compile/compile-object-run.c (do_module_cleanup): Use delete.
149 * compile/compile-object-load.c (struct munmap_list): Move to
150 header file.
151 (munmap_list::add): Rename from munmap_list_add; rewrite.
152 (munmap_list::~munmap_list): Rename from munmap_list_free.
153 (munmap_listp_free_cleanup): Remove.
154 (compile_object_load): Update.
155 * compile/compile-object-load.h (struct munmap_list): Move from
156 compile-object-load.c. Rewrite.
157
158 2018-09-18 Alan Hayward <alan.hayward@arm.com>
159
160 * aarch64-tdep.c (pass_in_v): Use register size.
161 (aarch64_extract_return_value): Likewise.
162 (aarch64_store_return_value): Likewise.
163
164 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
165
166 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
167 rlim_t.
168
169 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
170
171 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
172 Fix short help line.
173
174 2018-09-17 Tom Tromey <tom@tromey.com>
175
176 PR python/20445:
177 * configure: Rebuild.
178 * configure.ac: Conditionally use -DNDEBUG for Python.
179
180 2018-09-17 Tom Tromey <tom@tromey.com>
181
182 * configure: Rebuild.
183 * configure.ac: Use gmp as a library dependency when checking for
184 mpfr.
185
186 2018-09-17 Pedro Alves <palves@redhat.com>
187
188 * python/py-inferior.c (find_inferior_object): Delete.
189
190 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
191
192 * compile/compile-cplus-types.c
193 (compile_cplus_instance::enter_scope): Don't use new_scope after
194 std::move.
195
196 2018-09-17 Tom Tromey <tom@tromey.com>
197
198 * common/pathstuff.c (get_standard_cache_dir): Use
199 ~/Library/Caches on macOS.
200 * common/pathstuff.h (get_standard_cache_dir): Update comment.
201
202 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
203
204 PR python/23669
205 * breakpoint.c (commands_cmd_element): New.
206 (_initialize_breakpoint): Assign commands_cmd_element.
207 * breakpoint.h (commands_cmd_element): New.
208 * cli/cli-script.c (while_cmd_element, if_command,
209 define_cmd_element): New.
210 (command_name_equals): Remove.
211 (process_next_line): Compare commands by pointer, not by name.
212 (_initialize_cli_script): Assign the various cmd_list_element
213 variables.
214 * compile/compile.c (compile_cmd_element): New.
215 (_initialize_compile): Assign compile_cmd_element.
216 * compile/compile.h (compile_cmd_element): New.
217 * guile/guile.c (guile_cmd_element): New.
218 (install_gdb_commands): Assign guile_cmd_element.
219 * guile/guile.h (guile_cmd_element): New.
220 * python/python.c (python_cmd_element): New.
221 (_initialize_python): Assign python_cmd_element.
222 * python/python.h (python_cmd_element): New.
223 * tracepoint.c (while_stepping_cmd_element): New.
224 (_initialize_tracepoint): Assign while_stepping_cmd_element.
225 * tracepoint.h (while_stepping_cmd_element): New.
226
227 2018-09-17 Tom Tromey <tom@tromey.com>
228
229 * infrun.c (save_infcall_suspend_state): Return
230 infcall_suspend_state_up.
231 (save_infcall_control_state): Return infcall_control_state_up.
232 * inferior.h (save_infcall_suspend_state)
233 (save_infcall_control_state): Declare later. Return unique
234 pointers.
235
236 2018-09-17 Tom Tromey <tom@tromey.com>
237
238 * infrun.c (struct stop_context): Declare constructor,
239 destructor, "changed" method.
240 (stop_context::stop_context): Rename from save_stop_context.
241 (stop_context::~stop_context): Rename from
242 release_stop_context_cleanup.
243 (normal_stop): Update.
244 (stop_context::changed): Rename from stop_context_changed. Return
245 bool.
246
247 2018-09-17 Tom Tromey <tom@tromey.com>
248
249 * inferior.h (struct infcall_suspend_state_deleter): New.
250 (infcall_suspend_state_up): New typedef.
251 (struct infcall_control_state_deleter): New.
252 (infcall_control_state_up): New typedef.
253 (make_cleanup_restore_infcall_suspend_state)
254 (make_cleanup_restore_infcall_control_state): Don't declare.
255 * infcall.c (call_function_by_hand_dummy): Update.
256 * infrun.c (do_restore_infcall_suspend_state_cleanup)
257 (make_cleanup_restore_infcall_suspend_state): Remove.
258 (do_restore_infcall_control_state_cleanup)
259 (make_cleanup_restore_infcall_control_state): Remove.
260
261 2018-09-17 Tom Tromey <tom@tromey.com>
262
263 * gdbthread.h (struct thread_control_state): Add initializer.
264 (class thread_info) <control>: Remove initializer.
265 * inferior.h (struct inferior_control_state): Add initializer.
266 (class inferior) <control>: Remove initializer.
267 (exit_inferior_1): Update.
268 * infrun.c (struct infcall_control_state): Add constructors.
269 (save_infcall_control_state): Use new.
270 (restore_infcall_control_state, discard_infcall_control_state):
271 Use delete.
272
273 2018-09-17 Tom Tromey <tom@tromey.com>
274
275 * infrun.c (struct infcall_suspend_state) <registers>: Now a
276 unique_ptr.
277 <siginfo_data>: Now a unique_xmalloc_ptr.
278 (save_infcall_suspend_state, restore_infcall_suspend_state)
279 (discard_infcall_suspend_state)
280 (get_infcall_suspend_state_regcache): Update.
281
282 2018-09-17 Tom Tromey <tom@tromey.com>
283
284 * gdbthread.h (struct thread_suspend_state): Add initializers.
285 (class thread_info) <suspend>: Remove initializer.
286 * infrun.c (struct infcall_suspend_state): Add initializers.
287 (save_infcall_suspend_state): Use new.
288 (discard_infcall_suspend_state): Use delete.
289
290 2018-09-16 Tom Tromey <tom@tromey.com>
291
292 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
293 Remove.
294 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
295 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
296 (py_varobj_iter_new): Likewise.
297 (py_varobj_get_iterator): Use gdbpy_ref.
298
299 2018-09-16 Tom Tromey <tom@tromey.com>
300
301 * python/py-threadevent.c (py_get_event_thread): Simplify.
302 * python/py-inferior.c (infpy_thread_from_thread_handle):
303 Return immediately after calling thread_to_thread_object. Use
304 Py_RETURN_NONE.
305 (thread_to_thread_object): Set the exception on a NULL return.
306
307 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
308
309 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
310
311 2018-09-16 Tom Tromey <tom@tromey.com>
312
313 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
314 Remove.
315
316 2018-09-16 Tom Tromey <tom@tromey.com>
317
318 * python/python-internal.h (thread_to_thread_object): Change
319 return type.
320 * python/py-inferior.c (thread_to_thread_object): Return a new
321 reference.
322 (infpy_thread_from_thread_handle): Update.
323 * python/py-infthread.c (gdbpy_selected_thread): Update.
324 * python/py-stopevent.c (create_stop_event_object): Update.
325 * python/py-threadevent.c (py_get_event_thread): Return a new
326 reference.
327 (py_get_event_thread): Update.
328 * python/py-event.h (py_get_event_thread): Change return type.
329 * python/py-continueevent.c (create_continue_event_object):
330 Update.
331
332 2018-09-16 Tom Tromey <tom@tromey.com>
333
334 * python/py-progspace.c (pspy_get_objfiles): Update.
335 * python/python-internal.h (objfile_to_objfile_object): Change
336 return type.
337 * python/py-newobjfileevent.c (create_new_objfile_event_object):
338 Update.
339 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
340 Update.
341 * python/python.c (gdbpy_get_current_objfile): Update.
342 (gdbpy_objfiles): Update.
343 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
344 Update.
345 (objfile_to_objfile_object): Return a new reference.
346 * python/py-symtab.c (stpy_get_objfile): Update.
347 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
348 Update.
349
350 2018-09-16 Tom Tromey <tom@tromey.com>
351
352 * python/py-inferior.c (infpy_get_progspace): Update.
353 * python/python-internal.h (pspace_to_pspace_object): Change
354 return type.
355 * python/py-newobjfileevent.c
356 (create_clear_objfiles_event_object): Update.
357 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
358 Update.
359 * python/python.c (gdbpy_get_current_progspace): Update.
360 (gdbpy_progspaces): Update.
361 * python/py-progspace.c (pspace_to_pspace_object): Return a new
362 reference.
363 * python/py-objfile.c (objfpy_get_progspace): Update.
364 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
365 Update.
366
367 2018-09-16 Tom Tromey <tom@tromey.com>
368
369 * python/lib/gdb/__init__.py (current_progspace, objfiles)
370 (solib_name, block_for_pc, find_pc_line): New functions.
371 (execute_unwinders): Update.
372 * python/py-block.c (gdbpy_block_for_pc): Remove.
373 * python/py-inferior.c (infpy_get_progspace): New function.
374 (inferior_object_getset) <progspace>: Add.
375 * python/py-progspace.c (pspy_objfiles): Rewrite.
376 (pspy_solib_name, pspy_block_for_pc)
377 (pspy_find_pc_line, pspy_is_valid): New functions.
378 (progspace_object_methods): Add entries for solib_name,
379 block_for_pc, find_pc_line, is_valid.
380 * python/python-internal.h (gdbpy_block_for_pc)
381 (build_objfiles_list): Don't declare.
382 * python/python.c: Don't include solib.h.
383 (gdbpy_solib_name, gdbpy_find_pc_line)
384 (gdbpy_get_current_progspace, build_objfiles_list)
385 (gdbpy_objfiles): Remove.
386 (GdbMethods) <current_progspace, objfiles, block_for_pc,
387 solib_name, find_pc_line>: Remove entries.
388
389 2018-09-16 Tom Tromey <tom@tromey.com>
390
391 * top.c (new_ui_command): Use GNU style for metasyntactic
392 variables.
393 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
394 variables.
395 * maint.c (maintenance_translate_address): Remove "<>" around
396 text.
397 * interps.c (interpreter_exec_cmd): Use GNU style for
398 metasyntactic variables.
399 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
400 metasyntactic variables.
401 * tracepoint.c (tfind_range_command): Use GNU style for
402 metasyntactic variables.
403 (tfind_outside_command): Likewise.
404 (_initialize_tracepoint): Likewise.
405 * remote.c (extended_remote_target::create_inferior): Use GNU
406 style for metasyntactic variables.
407 * sparc64-tdep.c (adi_examine_command): Use GNU style for
408 metasyntactic variables.
409 (adi_assign_command): Likewise.
410
411 2018-09-16 Tom Tromey <tom@tromey.com>
412
413 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
414 metasyntactic variables. Print message if no disassembler options
415 are available.
416
417 2018-09-15 Tom Tromey <tom@tromey.com>
418
419 * infcmd.c (get_inferior_args): Return const char *.
420 * inferior.h (get_inferior_args): Return type now const.
421 * linux-tdep.c (linux_fill_prpsinfo): Update.
422 * procfs.c (procfs_target::make_corefile_notes): Update.
423
424 2018-09-07 Tom Tromey <tom@tromey.com>
425
426 * python/python.c (execute_gdb_command): Call bpstat_do_actions
427 inside the TRY.
428
429 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
430
431 * nios2-tdep.c (nios2_type_align): New.
432 (nios2_gdb_arch_init): Install type_align hook.
433
434 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
435
436 * eval.c (fake_method::fake_method): Call xzalloc directly for a
437 type that is neither object file owned, nor gdbarch owned.
438 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
439 gdbarch is non-NULL.
440 (alloc_type_instance): Allocate non-objfile owned types on the
441 gdbarch obstack.
442 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
443 using TYPE_ALLOC to ensure memory is allocated on the correct
444 obstack.
445 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
446 obstack, or the gdbarch obstack.
447 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
448
449 2018-09-14 Tom Tromey <tom@tromey.com>
450
451 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
452 block.
453
454 2018-09-14 Tom Tromey <tom@tromey.com>
455
456 * nat/fork-inferior.c (get_startup_shell): Remove "static".
457
458 2018-09-13 Tom Tromey <tom@tromey.com>
459
460 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
461 static.
462
463 2018-09-13 Tom Tromey <tom@tromey.com>
464
465 * exec.c (try_open_exec_file): Use std::string.
466
467 2018-09-13 Tom Tromey <tom@tromey.com>
468
469 * utils.h (gdb_bfd_errmsg): Return std::string.
470 * exec.c (exec_file_attach): Update.
471 * compile/compile-object-load.c (compile_object_load): Update.
472 * utils.c (gdb_bfd_errmsg): Return std::string.
473
474 2018-09-13 Tom Tromey <tom@tromey.com>
475
476 * procfs.c (struct procinfo_deleter): New.
477 (procinfo_up): New typedef.
478 (do_destroy_procinfo_cleanup): Remove.
479 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
480
481 2018-09-13 Tom Tromey <tom@tromey.com>
482
483 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
484
485 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
486 2018-09-13 Tom Tromey <tom@tromey.com>
487
488 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
489 (pspy_get_objfiles): New function.
490 (progspace_object_methods): New.
491 (pspace_object_type): Add tp_methods callback.
492 * python/python-internal.h (build_objfiles_list): New
493 declaration.
494 * python/python.c (build_objfiles_list): New function.
495 (gdbpy_objfiles): Implement using build_objfiles_list.
496 * NEWS: Mention the Progspace.objfiles method.
497
498 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
499
500 * python/py-inferior.c (infpy_get_progspace): New function.
501 (inferior_object_getset): Add progspace property.
502 * NEWS: Mention the new property.
503
504 2018-09-13 Tom Tromey <tom@tromey.com>
505
506 PR rust/23650:
507 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
508
509 2018-09-13 Tom Tromey <tom@tromey.com>
510
511 PR rust/23626:
512 * rust-lang.c (rust_enum_variant): Now static.
513 (rust_empty_enum_p): New function.
514 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
515 Handle empty enum.
516
517 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
518
519 * python/py-inferior.c (infpy_repr): New.
520 (inferior_object_type): Register infpy_repr.
521 * python/py-objfile.c (objfpy_repr): New.
522 (objfile_object_type): Register objfpy_repr.
523
524 2018-09-12 John Baldwin <jhb@FreeBSD.org>
525
526 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
527
528 2018-09-12 John Baldwin <jhb@FreeBSD.org>
529
530 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
531 typo.
532
533 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
534
535 * common/common-utils.c: Don't include '<sys/stat.h>'.
536 (is_regular_file): Move to...
537 * common/filestuff.c (is_regular_file): ... here.
538 * common/common-utils.h (is_regular_file): Move to...
539 * common/filestuff.h (is_regular_file): ... here.
540
541 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
542
543 * skip.c (debug_skip): New variable.
544 (skiplist_entry::do_skip_file_p): Add debug output.
545 (skiplist_entry::do_skip_gfile_p): Likewise.
546 (skiplist_entry::skip_function_p): Likewise.
547 (_initialize_step_skip): Create debug command.
548 * NEWS: Mention set/show debug skip.
549
550 2018-09-11 Xavier Roirand <roirand@adacore.com>
551
552 * darwin-nat.c (should_disable_startup_with_shell):
553 New function.
554 (darwin_nat_target::create_inferior): Add call.
555
556 2018-09-11 Xavier Roirand <roirand@adacore.com>
557
558 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
559 inf_port, msg_state>: Initialize.
560 (struct darwin_thread_info) <signaled, single_step>: Change
561 type and initialize.
562 (struct darwin_thread_info) <event>: Initialize.
563
564 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
565
566 PR gdb/23555
567 PR gdb/23558
568 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
569 guesses.
570
571 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
572
573 Revert:
574 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
575
576 PR gdb/23555
577 PR gdb/23558
578 * gnulib/aclocal.m4: Regenerate.
579 * gnulib/config.in: Regenerate.
580 * gnulib/configure: Regenerate.
581 * gnulib/import/Makefile.am: Update.
582 * gnulib/import/Makefile.in: Update.
583 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
584 * gnulib/import/_Noreturn.h: ... this.
585 * gnulib/import/alloca.in.h: Update.
586 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
587 * gnulib/import/arg-nonnull.h: ... this.
588 * gnulib/import/assure.h: Update.
589 * gnulib/import/at-func.c: Update.
590 * gnulib/import/basename-lgpl.c: Update.
591 * gnulib/import/extra/snippet/c++defs.h: Rename to...
592 * gnulib/import/c++defs.h: ... this.
593 * gnulib/import/canonicalize-lgpl.c: Update.
594 * gnulib/import/cdefs.h: Update.
595 * gnulib/import/chdir-long.c: Update.
596 * gnulib/import/chdir-long.h: Update.
597 * gnulib/import/cloexec.c: Update.
598 * gnulib/import/cloexec.h: Update.
599 * gnulib/import/close.c: Update.
600 * gnulib/import/closedir.c: Update.
601 * gnulib/import/config.charset: Update.
602 * gnulib/import/dirent-private.h: Update.
603 * gnulib/import/dirent.in.h: Update.
604 * gnulib/import/dirfd.c: Update.
605 * gnulib/import/dirname-lgpl.c: Update.
606 * gnulib/import/dirname.h: Update.
607 * gnulib/import/dosname.h: Update.
608 * gnulib/import/dup-safer-flag.c: Update.
609 * gnulib/import/dup-safer.c: Update.
610 * gnulib/import/dup.c: Update.
611 * gnulib/import/dup2.c: Update.
612 * gnulib/import/errno.in.h: Update.
613 * gnulib/import/error.c: Update.
614 * gnulib/import/error.h: Update.
615 * gnulib/import/exitfail.c: Update.
616 * gnulib/import/exitfail.h: Update.
617 * gnulib/import/extra/update-copyright: Update.
618 * gnulib/import/fchdir.c: Update.
619 * gnulib/import/fcntl.c: Update.
620 * gnulib/import/fcntl.in.h: Update.
621 * gnulib/import/fd-hook.c: Update.
622 * gnulib/import/fd-hook.h: Update.
623 * gnulib/import/fd-safer-flag.c: Update.
624 * gnulib/import/fd-safer.c: Update.
625 * gnulib/import/fdopendir.c: Update.
626 * gnulib/import/filename.h: Update.
627 * gnulib/import/filenamecat-lgpl.c: Update.
628 * gnulib/import/filenamecat.h: Update.
629 * gnulib/import/flexmember.h: Update.
630 * gnulib/import/float+.h: Update.
631 * gnulib/import/float.c: Update.
632 * gnulib/import/float.in.h: Update.
633 * gnulib/import/fnmatch.c: Update.
634 * gnulib/import/fnmatch.in.h: Update.
635 * gnulib/import/fnmatch_loop.c: Update.
636 * gnulib/import/fpucw.h: Update.
637 * gnulib/import/frexp.c: Update.
638 * gnulib/import/frexpl.c: Update.
639 * gnulib/import/fstat.c: Update.
640 * gnulib/import/fstatat.c: Update.
641 * gnulib/import/getcwd-lgpl.c: Update.
642 * gnulib/import/getcwd.c: Update.
643 * gnulib/import/getdtablesize.c: Update.
644 * gnulib/import/getlogin_r.c: Update.
645 * gnulib/import/getprogname.c: Update.
646 * gnulib/import/getprogname.h: Update.
647 * gnulib/import/gettext.h: Update.
648 * gnulib/import/gettimeofday.c: Update.
649 * gnulib/import/glob-libc.h: Update.
650 * gnulib/import/glob.c: Update.
651 * gnulib/import/glob.in.h: Update.
652 * gnulib/import/glob_internal.h: Update.
653 * gnulib/import/glob_pattern_p.c: Update.
654 * gnulib/import/globfree.c: Update.
655 * gnulib/import/hard-locale.c: Update.
656 * gnulib/import/hard-locale.h: Update.
657 * gnulib/import/intprops.h: Update.
658 * gnulib/import/inttypes.in.h: Update.
659 * gnulib/import/isnan.c: Update.
660 * gnulib/import/isnand-nolibm.h: Update.
661 * gnulib/import/isnand.c: Update.
662 * gnulib/import/isnanl-nolibm.h: Update.
663 * gnulib/import/isnanl.c: Update.
664 * gnulib/import/itold.c: Update.
665 * gnulib/import/libc-config.h: Update.
666 * gnulib/import/limits.in.h: Update.
667 * gnulib/import/localcharset.c: Update.
668 * gnulib/import/localcharset.h: Update.
669 * gnulib/import/localtime-buffer.c: Update.
670 * gnulib/import/localtime-buffer.h: Update.
671 * gnulib/import/lstat.c: Update.
672 * gnulib/import/m4/00gnulib.m4: Update.
673 * gnulib/import/m4/__inline.m4: Update.
674 * gnulib/import/m4/absolute-header.m4: Update.
675 * gnulib/import/m4/alloca.m4: Update.
676 * gnulib/import/m4/builtin-expect.m4: Update.
677 * gnulib/import/m4/canonicalize.m4: Update.
678 * gnulib/import/m4/chdir-long.m4: Update.
679 * gnulib/import/m4/close.m4: Update.
680 * gnulib/import/m4/closedir.m4: Update.
681 * gnulib/import/m4/configmake.m4: Update.
682 * gnulib/import/m4/d-ino.m4: Update.
683 * gnulib/import/m4/d-type.m4: Update.
684 * gnulib/import/m4/dirent_h.m4: Update.
685 * gnulib/import/m4/dirfd.m4: Update.
686 * gnulib/import/m4/dirname.m4: Update.
687 * gnulib/import/m4/double-slash-root.m4: Update.
688 * gnulib/import/m4/dup.m4: Update.
689 * gnulib/import/m4/dup2.m4: Update.
690 * gnulib/import/m4/eealloc.m4: Update.
691 * gnulib/import/m4/environ.m4: Update.
692 * gnulib/import/m4/errno_h.m4: Update.
693 * gnulib/import/m4/error.m4: Update.
694 * gnulib/import/m4/exponentd.m4: Update.
695 * gnulib/import/m4/exponentl.m4: Update.
696 * gnulib/import/m4/extensions.m4: Update.
697 * gnulib/import/m4/extern-inline.m4: Update.
698 * gnulib/import/m4/fchdir.m4: Update.
699 * gnulib/import/m4/fcntl-o.m4: Update.
700 * gnulib/import/m4/fcntl.m4: Update.
701 * gnulib/import/m4/fcntl_h.m4: Update.
702 * gnulib/import/m4/fdopendir.m4: Update.
703 * gnulib/import/m4/filenamecat.m4: Update.
704 * gnulib/import/m4/flexmember.m4: Update.
705 * gnulib/import/m4/float_h.m4: Update.
706 * gnulib/import/m4/fnmatch.m4: Update.
707 * gnulib/import/m4/fnmatch_h.m4: Update.
708 * gnulib/import/m4/fpieee.m4: Update.
709 * gnulib/import/m4/frexp.m4: Update.
710 * gnulib/import/m4/frexpl.m4: Update.
711 * gnulib/import/m4/fstat.m4: Update.
712 * gnulib/import/m4/fstatat.m4: Update.
713 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
714 * gnulib/import/m4/getcwd-path-max.m4: Update.
715 * gnulib/import/m4/getcwd.m4: Update.
716 * gnulib/import/m4/getdtablesize.m4: Update.
717 * gnulib/import/m4/getlogin.m4: Update.
718 * gnulib/import/m4/getlogin_r.m4: Update.
719 * gnulib/import/m4/getpagesize.m4: Update.
720 * gnulib/import/m4/getprogname.m4: Update.
721 * gnulib/import/m4/gettimeofday.m4: Update.
722 * gnulib/import/m4/glibc21.m4: Update.
723 * gnulib/import/m4/glob.m4: Update.
724 * gnulib/import/m4/glob_h.m4: Update.
725 * gnulib/import/m4/gnulib-cache.m4: Update.
726 * gnulib/import/m4/gnulib-common.m4: Update.
727 * gnulib/import/m4/gnulib-comp.m4: Update.
728 * gnulib/import/m4/gnulib-tool.m4: Update.
729 * gnulib/import/m4/hard-locale.m4: Update.
730 * gnulib/import/m4/include_next.m4: Update.
731 * gnulib/import/m4/inttypes-pri.m4: Update.
732 * gnulib/import/m4/inttypes.m4: Update.
733 * gnulib/import/m4/isnand.m4: Update.
734 * gnulib/import/m4/isnanl.m4: Update.
735 * gnulib/import/m4/largefile.m4: Update.
736 * gnulib/import/m4/limits-h.m4: Update.
737 * gnulib/import/m4/localcharset.m4: Update.
738 * gnulib/import/m4/locale-fr.m4: Update.
739 * gnulib/import/m4/locale-ja.m4: Update.
740 * gnulib/import/m4/locale-zh.m4: Update.
741 * gnulib/import/m4/localtime-buffer.m4: Update.
742 * gnulib/import/m4/longlong.m4: Update.
743 * gnulib/import/m4/lstat.m4: Update.
744 * gnulib/import/m4/malloc.m4: Update.
745 * gnulib/import/m4/malloca.m4: Update.
746 * gnulib/import/m4/math_h.m4: Update.
747 * gnulib/import/m4/mbrtowc.m4: Update.
748 * gnulib/import/m4/mbsinit.m4: Update.
749 * gnulib/import/m4/mbsrtowcs.m4: Update.
750 * gnulib/import/m4/mbstate_t.m4: Update.
751 * gnulib/import/m4/memchr.m4: Update.
752 * gnulib/import/m4/memmem.m4: Update.
753 * gnulib/import/m4/mempcpy.m4: Update.
754 * gnulib/import/m4/memrchr.m4: Update.
755 * gnulib/import/m4/mkdir.m4: Update.
756 * gnulib/import/m4/mkstemp.m4: Update.
757 * gnulib/import/m4/mmap-anon.m4: Update.
758 * gnulib/import/m4/mode_t.m4: Update.
759 * gnulib/import/m4/msvc-inval.m4: Update.
760 * gnulib/import/m4/msvc-nothrow.m4: Update.
761 * gnulib/import/m4/multiarch.m4: Update.
762 * gnulib/import/m4/nocrash.m4: Update.
763 * gnulib/import/m4/off_t.m4: Update.
764 * gnulib/import/m4/onceonly.m4: Update.
765 * gnulib/import/m4/open-cloexec.m4: Update.
766 * gnulib/import/m4/open.m4: Update.
767 * gnulib/import/m4/openat.m4: Update.
768 * gnulib/import/m4/opendir.m4: Update.
769 * gnulib/import/m4/pathmax.m4: Update.
770 * gnulib/import/m4/rawmemchr.m4: Update.
771 * gnulib/import/m4/readdir.m4: Update.
772 * gnulib/import/m4/readlink.m4: Update.
773 * gnulib/import/m4/realloc.m4: Update.
774 * gnulib/import/m4/rename.m4: Update.
775 * gnulib/import/m4/rewinddir.m4: Update.
776 * gnulib/import/m4/rmdir.m4: Update.
777 * gnulib/import/m4/save-cwd.m4: Update.
778 * gnulib/import/m4/secure_getenv.m4: Update.
779 * gnulib/import/m4/setenv.m4: Update.
780 * gnulib/import/m4/signal_h.m4: Update.
781 * gnulib/import/m4/ssize_t.m4: Update.
782 * gnulib/import/m4/stat-time.m4: Update.
783 * gnulib/import/m4/stat.m4: Update.
784 * gnulib/import/m4/std-gnu11.m4: Update.
785 * gnulib/import/m4/stdbool.m4: Update.
786 * gnulib/import/m4/stddef_h.m4: Update.
787 * gnulib/import/m4/stdint.m4: Update.
788 * gnulib/import/m4/stdio_h.m4: Update.
789 * gnulib/import/m4/stdlib_h.m4: Update.
790 * gnulib/import/m4/strchrnul.m4: Update.
791 * gnulib/import/m4/strdup.m4: Update.
792 * gnulib/import/m4/strerror.m4: Update.
793 * gnulib/import/m4/string_h.m4: Update.
794 * gnulib/import/m4/strstr.m4: Update.
795 * gnulib/import/m4/strtok_r.m4: Update.
796 * gnulib/import/m4/sys_socket_h.m4: Update.
797 * gnulib/import/m4/sys_stat_h.m4: Update.
798 * gnulib/import/m4/sys_time_h.m4: Update.
799 * gnulib/import/m4/sys_types_h.m4: Update.
800 * gnulib/import/m4/tempname.m4: Update.
801 * gnulib/import/m4/time_h.m4: Update.
802 * gnulib/import/m4/unistd-safer.m4: Update.
803 * gnulib/import/m4/unistd_h.m4: Update.
804 * gnulib/import/m4/warn-on-use.m4: Update.
805 * gnulib/import/m4/wchar_h.m4: Update.
806 * gnulib/import/m4/wchar_t.m4: Update.
807 * gnulib/import/m4/wctype_h.m4: Update.
808 * gnulib/import/m4/wint_t.m4: Update.
809 * gnulib/import/malloc.c: Update.
810 * gnulib/import/malloc/scratch_buffer.h: Update.
811 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
812 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
813 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
814 * gnulib/import/malloca.c: Update.
815 * gnulib/import/malloca.h: Update.
816 * gnulib/import/malloca.valgrind: Update.
817 * gnulib/import/math.in.h: Update.
818 * gnulib/import/mbrtowc.c: Update.
819 * gnulib/import/mbsinit.c: Update.
820 * gnulib/import/mbsrtowcs-impl.h: Update.
821 * gnulib/import/mbsrtowcs-state.c: Update.
822 * gnulib/import/mbsrtowcs.c: Update.
823 * gnulib/import/memchr.c: Update.
824 * gnulib/import/memmem.c: Update.
825 * gnulib/import/mempcpy.c: Update.
826 * gnulib/import/memrchr.c: Update.
827 * gnulib/import/mkdir.c: Update.
828 * gnulib/import/mkstemp.c: Update.
829 * gnulib/import/msvc-inval.c: Update.
830 * gnulib/import/msvc-inval.h: Update.
831 * gnulib/import/msvc-nothrow.c: Update.
832 * gnulib/import/msvc-nothrow.h: Update.
833 * gnulib/import/open.c: Update.
834 * gnulib/import/openat-die.c: Update.
835 * gnulib/import/openat-priv.h: Update.
836 * gnulib/import/openat-proc.c: Update.
837 * gnulib/import/openat.c: Update.
838 * gnulib/import/openat.h: Update.
839 * gnulib/import/opendir.c: Update.
840 * gnulib/import/pathmax.h: Update.
841 * gnulib/import/pipe-safer.c: Update.
842 * gnulib/import/rawmemchr.c: Update.
843 * gnulib/import/readdir.c: Update.
844 * gnulib/import/readlink.c: Update.
845 * gnulib/import/realloc.c: Update.
846 * gnulib/import/ref-add.sin: Update.
847 * gnulib/import/ref-del.sin: Update.
848 * gnulib/import/rename.c: Update.
849 * gnulib/import/rewinddir.c: Update.
850 * gnulib/import/rmdir.c: Update.
851 * gnulib/import/same-inode.h: Update.
852 * gnulib/import/save-cwd.c: Update.
853 * gnulib/import/save-cwd.h: Update.
854 * gnulib/import/scratch_buffer.h: Update.
855 * gnulib/import/secure_getenv.c: Update.
856 * gnulib/import/setenv.c: Update.
857 * gnulib/import/signal.in.h: Update.
858 * gnulib/import/stat-time.c: Update.
859 * gnulib/import/stat-time.h: Update.
860 * gnulib/import/stat-w32.c: Update.
861 * gnulib/import/stat-w32.h: Update.
862 * gnulib/import/stat.c: Update.
863 * gnulib/import/stdbool.in.h: Update.
864 * gnulib/import/stddef.in.h: Update.
865 * gnulib/import/stdint.in.h: Update.
866 * gnulib/import/stdio.in.h: Update.
867 * gnulib/import/stdlib.in.h: Update.
868 * gnulib/import/str-two-way.h: Update.
869 * gnulib/import/strchrnul.c: Update.
870 * gnulib/import/strdup.c: Update.
871 * gnulib/import/streq.h: Update.
872 * gnulib/import/strerror-override.c: Update.
873 * gnulib/import/strerror-override.h: Update.
874 * gnulib/import/strerror.c: Update.
875 * gnulib/import/string.in.h: Update.
876 * gnulib/import/stripslash.c: Update.
877 * gnulib/import/strnlen1.c: Update.
878 * gnulib/import/strnlen1.h: Update.
879 * gnulib/import/strstr.c: Update.
880 * gnulib/import/strtok_r.c: Update.
881 * gnulib/import/sys_stat.in.h: Update.
882 * gnulib/import/sys_time.in.h: Update.
883 * gnulib/import/sys_types.in.h: Update.
884 * gnulib/import/tempname.c: Update.
885 * gnulib/import/tempname.h: Update.
886 * gnulib/import/time.in.h: Update.
887 * gnulib/import/unistd--.h: Update.
888 * gnulib/import/unistd-safer.h: Update.
889 * gnulib/import/unistd.in.h: Update.
890 * gnulib/import/unsetenv.c: Update.
891 * gnulib/import/verify.h: Update.
892 * gnulib/import/extra/snippet/warn-on-use.h: Update.
893 * gnulib/import/wchar.in.h: Update.
894 * gnulib/import/wctype.in.h: Update.
895 * gnulib/import/xalloc-oversized.h: Update.
896 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
897 "53e2c179f26a890fa6685af4b6c1397ee370433b".
898
899 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
900
901 * record-btrace.c (get_thread_current_frame): Remove
902 old_inferior_ptid.
903
904 2018-09-10 Jerome Guitton <guitton@adacore.com>
905
906 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
907 with check_tag to 1 if and only if the type is tagged and the
908 component being searched cannot been found in the current
909 view. Otherwise, always call ada_to_fixed_type with
910 check_tag to 0.
911
912 2018-09-10 Xavier Roirand <roirand@adacore.com>
913
914 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
915 declaration.
916 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
917 * ada-varobj.c (ada_varobj_get_number_of_children,
918 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
919
920 2018-09-10 Xavier Roirand <roirand@adacore.com>
921
922 * ada-valprint.c (ada_value_print): Use type instead of
923 enclosing type.
924
925 2018-09-10 Xavier Roirand <roirand@adacore.com>
926
927 * ada-lang.c (ada_value_subscript): Handle case when parameter is
928 an array of access to unconstrained array.
929
930 2018-09-10 Xavier Roirand <roirand@adacore.com>
931
932 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
933 (ada_check_typedef): Use it.
934
935 2018-09-10 Xavier Roirand <roirand@adacore.com>
936
937 * ada-varobj.c (ada_varobj_describe_struct_child)
938 (ada_varobj_describe_child): Handle union case like struct one.
939
940 2018-09-10 Tom Tromey <tom@tromey.com>
941
942 PR python/18380:
943 * python/python.c (_initialize_python): Make example in "python"
944 help work in Python 3.
945
946 2018-09-10 Eli Zaretskii <eliz@gnu.org>
947
948 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
949 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
950 $(EXEEXT) to the script, as it is not a program.
951
952 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
953
954 * python/py-prettyprint.c (pretty_print_one_value): Return
955 gdbpy_ref<>.
956 (print_string_repr): Adjust.
957 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
958 * python/python-internal.h (apply_varobj_pretty_printer): Return
959 gdbpy_ref<>.
960 * varobj.c (varobj_value_get_print_value): Adjust.
961
962 2018-09-08 Tom Tromey <tom@tromey.com>
963
964 PR python/16047:
965 * python/py-prettyprint.c (pretty_print_one_value): Check for
966 to_string method.
967
968 2018-09-08 Joel Brobecker <brobecker@adacore.com>
969
970 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
971 replace_operator_with_call.
972
973 2018-09-08 Joel Brobecker <brobecker@adacore.com>
974
975 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
976
977 2018-09-08 Joel Brobecker <brobecker@adacore.com>
978
979 * ada-typeprint.c (print_range): Print the bounds using TYPE
980 rather than its TYPE_TARGET_TYPE.
981
982 2018-09-08 Joel Brobecker <brobecker@adacore.com>
983
984 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
985 call to ada_to_fixed_value_create.
986
987 2018-09-08 Jerome Guitton <guitton@adacore.com>
988
989 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
990
991 2018-09-08 Joel Brobecker <brobecker@adacore.com>
992
993 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
994 by calls to error.
995
996 2018-09-08 Joel Brobecker <brobecker@adacore.com>
997
998 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
999 Move update of loop variable "fi".
1000
1001 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1002
1003 * ada-lang.c (value_assign_to_component): In the case of
1004 big-endian targets, extract the bits of the given VAL
1005 using an src_offset of zero if container is not a scalar.
1006
1007 2018-09-06 Simon Ser <contact@emersion.fr>
1008
1009 PR gdb/23105
1010 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
1011 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1012 * fbsd-tdep.c (fbsd_make_note_desc): New.
1013 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
1014 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
1015 * target.h (enum target_object) Add FreeBSD-specific
1016 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1017
1018 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1019
1020 * compile/compile-c.h (generate_c_for_variable_locations):
1021 Change reference to pointer.
1022 * compile/compile-c-support.c (compile_program) <compute>:
1023 Likewise.
1024 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
1025 (generate_c_for_for_one_variable): Likewise
1026 (generate_c_for_variable_locations): Likewise
1027 * compile/compile-c-types.c (compile_c_instance::convert_type):
1028 Likewise
1029 * compile/compile-cplus-symbols.c (convert_one_symbol):
1030 std::move the scope passed to enter_scope.
1031 * compile/compile-cplus-types.c
1032 (compile_cplus_instance::enter_scope): Make parameter
1033 rvalue-reference.
1034 (compile_cplus_instance::new_scope): Change reference to
1035 pointer.
1036 (compile_cplus_instance::convert_type): Likewise
1037 (compile_cplus_convert_typedef): std::move the scope passed to
1038 enter_scope.
1039 (compile_cplus_convert_struct_or_union): Likewise.
1040 (compile_cplus_convert_enum): Likewise.
1041 (compile_cplus_convert_namespace): Likewise.
1042 * compile/compile-cplus.h (compile_cplus_instance)
1043 <enter_scope>: Make parameter rvalue-reference.
1044 * compile/compile-internal.h (compile_instance)
1045 <get_cached_type>: Likewise
1046 * compile/compile-loc2c.c (push): Likewise
1047 (pushf): Likewise
1048 (unary): Likewise
1049 (binary): Likewise
1050 (print_label): Likewise
1051 (pushf_register_address): Likewise
1052 (pushf_register): Likewise
1053 (do_compile_dwarf_expr_to_c): Likewise
1054 (compile_dwarf_expr_to_c): Likewise
1055 (compile_dwarf_bounds_to_c): Likewise
1056 * compile/compile.c (compile_instance::get_cached_type):
1057 Likewise
1058 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
1059 (compile_dwarf_bounds_to_c): Likewise
1060 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
1061 (dwarf2_compile_property_to_c): Likewise
1062 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
1063 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1064 Likewise
1065
1066 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1067
1068 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
1069 * tui/tui-data.c (init_content_element): Don't initialize it.
1070
1071 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1072
1073 * tui/tui-data.h (struct tui_win_info)
1074 <detail::opaque>: Remove.
1075 * tui/tui-data.c (init_win_info): Remove assignment.
1076
1077 2018-09-05 Tom Tromey <tom@tromey.com>
1078
1079 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
1080 -Wformat-nonliteral.
1081 * target-float.c (host_float_ops<T>::to_string)
1082 (host_float_ops<T>::from_string): Use
1083 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1084 * configure: Rebuild.
1085
1086 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
1087
1088 * printcmd.c (printf_c_string): Use
1089 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1090 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
1091
1092 2018-09-05 Tom Tromey <tom@tromey.com>
1093
1094 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
1095
1096 2018-09-05 Tom de Vries <tdevries@suse.de>
1097
1098 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1099 with resolve_abstract_p == true.
1100 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1101 defaulting to false. Propagate resolve_abstract_p to
1102 dwarf2_fetch_die_loc_sect_off.
1103 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1104 parameter, defaulting to false.
1105 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1106 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1107 parameter.
1108 * dwarf2read.h (struct die_info): Forward-declare.
1109 (die_info_ptr): New typedef.
1110 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1111
1112 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1113
1114 GDB 8.2 released.
1115
1116 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1117 Pedro Alves <palves@redhat.com>
1118
1119 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1120 "aclocal-m4-deps.mk". Include file here.
1121 $(srcdir)/aclocal.m4: Add "configure.ac".
1122 * gnulib/aclocal-m4-deps.mk: New file.
1123 * gnulib/update-gnulib.sh: Automatically update
1124 "aclocal-m4-deps.mk".
1125
1126 2018-09-04 Tom Tromey <tom@tromey.com>
1127
1128 * configure: Rebuild.
1129 * configure.ac: Remove multi-ice code.
1130
1131 2018-09-04 Tom Tromey <tom@tromey.com>
1132
1133 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
1134 (ada-exp.o): Update.
1135
1136 2018-09-04 Tom Tromey <tom@tromey.com>
1137
1138 * Makefile.in (printcmd.o, target-float.o): Remove.
1139 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
1140
1141 2018-09-04 Tom Tromey <tom@tromey.com>
1142
1143 * gnulib/Makefile.in: Remove obsolete comment.
1144 * Makefile.in: Remove obsolete comment.
1145
1146 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
1147
1148 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
1149 line with '+'.
1150
1151 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1152
1153 * riscv-tdep.c: Add 'prologue-value.h' include.
1154 (struct riscv_unwind_cache): New struct.
1155 (riscv_debug_unwinder): New global.
1156 (riscv_scan_prologue): Update arguments, capture register details
1157 from prologue scan.
1158 (riscv_skip_prologue): Reformat arguments line, move end of
1159 prologue calculation into riscv_scan_prologue.
1160 (riscv_frame_cache): Update return type, create
1161 riscv_unwind_cache, scan the prologue, and fill in remaining cache
1162 details.
1163 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
1164 (riscv_frame_prev_register): Use the trad_frame within the
1165 riscv_unwind_cache.
1166 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
1167 flag.
1168
1169 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1170
1171 * trad-frame.h (trad_frame_set_realreg): Declare.
1172 (trad_frame_set_addr): Declare.
1173 * trad-frame.c (trad_frame_set_realreg): Define new function.
1174 (trad_frame_set_addr): Define new function.
1175 (trad_frame_set_reg_realreg): Use new function.
1176 (trad_frame_set_reg_addr): Use new function.
1177
1178 2018-09-01 Keith Seitz <keiths@redhat.com>
1179
1180 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
1181 pulongest instead of "%lld".
1182 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
1183 ATTRIBUTE_UNUSED.
1184
1185 2018-08-31 Tom Tromey <tom@tromey.com>
1186
1187 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
1188 variant part type.
1189
1190 2018-08-31 Pedro Alves <palves@redhat.com>
1191
1192 * gdbarch.h: Regenerate.
1193
1194 2018-08-31 Pedro Alves <palves@redhat.com>
1195
1196 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
1197 * target.h (Hardware watchpoint interfaces): Describe
1198 continuable/steppable/non-steppable watchpoints.
1199 * gdbarch.h, gdbarch.c: Regenerate.
1200
1201 2018-08-31 Pedro Alves <palves@redhat.com>
1202
1203 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
1204 Delete.
1205 * s390-linux-nat.c
1206 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
1207 * target.h (target_ops::have_continuable_watchpoint): Delete.
1208 (target_have_continuable_watchpoint): Delete.
1209 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
1210 * target-delegates.c: Regenerate.
1211
1212 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1213
1214 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
1215 the files present in "gnulib/import/m4/".
1216
1217 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1218
1219 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
1220 c.sw, c.swsp, and c.sdsp.
1221
1222 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1223
1224 * riscv-tdep.c (struct riscv_inferior_data): Delete.
1225 (riscv_read_misa_reg): Don't cache value read into inferior data.
1226 (riscv_new_inferior_data): Delete.
1227 (riscv_inferior_data_cleanup): Delete.
1228 (riscv_inferior_data): Delete.
1229 (riscv_invalidate_inferior_data): Delete.
1230 (_initialize_riscv_tdep): Remove initialisation of inferior data.
1231
1232 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
1233
1234 * compile/compile-cplus-types.c
1235 (compile_cplus_instance::leave_scope): Take the address of scope
1236 object.
1237 (compile_cplus_instance::convert_qualified_base): Compare quals
1238 to 0.
1239
1240 2018-08-30 Keith Seitz <keiths@redhat.com>
1241
1242 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
1243 Use "%s" and host_address_to_string instead of "%p" in printf.
1244
1245 2018-08-29 Keith Seitz <keiths@redhat.com>
1246
1247 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
1248 and compile-cplus-types.c.
1249 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
1250 * c-lang.c (cplus_language_defn): Set C++ compile functions.
1251 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
1252 Declare.
1253 * compile/compile-c-support.c: Include compile-cplus.h.
1254 (load_libcompile): Templatize.
1255 (get_compile_context): "New" function.
1256 (c_get_compile_context): Use get_compile_context.
1257 (cplus_get_compile_context): New function.
1258 (cplus_push_user_expression, cplus_pop_user_expression)
1259 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
1260 (cplus_compute_program): Define new structs/functions.
1261 * compile/compile-cplus-symmbols.c: New file.
1262 * compile/compile-cplus-types.c: New file.
1263 * compile/compile-cplus.h: New file.
1264 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
1265 Declare.
1266 * compile/compile-object-load.c (get_out_value_type): Use
1267 strncmp_iw when comparing symbol names.
1268 (compile_object_load): Add mst_bss and mst_data.
1269 * compile/compile.c (_initialize_compile): Remove
1270 -Wno-implicit-function-declaration from `compile_args'.
1271 * compile/gcc-cp-plugin.h: New file.
1272 * NEWS: Mention C++ compile support and new debug options.
1273
1274 2018-08-29 Keith Seitz <keiths@redhat.com>
1275
1276 * linespec.c (collect_info::add_symbol): Make virtual.
1277 (struct symbol_searcher_collect_info): New struct.
1278 (symbol_searcher::find_all_symbols): New method.
1279 * symtab.h (class symbol_searcher): New class.
1280
1281 2018-08-29 Keith Seitz <keiths@redhat.com>
1282
1283 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1284 Change to vector of block_symbol. Update all users.
1285 (struct collect_info) <symbols>: Likewise.
1286 (collect_info::add_symbol): Take block_symbol as argument.
1287 Update all callers.
1288 (decode_compound_collector) <m_symbols>: Change type to vector
1289 of block_symbol. Update all users.
1290 (decode_compound_collector::operator ()): Change parameter type
1291 to block_symbol.
1292 (find_method, find_function_symbols, find_linespec_symbols)
1293 (find_label_symbols_in_block, find_label_symbols): Change symbol
1294 vectors to block_symbol vectors.
1295 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1296 block_symbol.
1297
1298 2018-08-29 Keith Seitz <keiths@redhat.com>
1299
1300 * linespec.c (symbolp): Remove typedef and VEC definitions.
1301 (bound_minimal_symbol_d): Likewise.
1302
1303 2018-08-29 Keith Seitz <keiths@redhat.com>
1304
1305 * linespec.c (decode_compound_collector::decode_compound_collector):
1306 Remove initialization for `m_symtabs'.
1307 (decode_compound_collector::release_symbols): Change return type
1308 to std::vector. Update all callers.
1309 (class decode_compound_collector) <m_symbols>: Change type to
1310 std::vector.
1311 (lookup_prefix_sym): Change return type to std::vector. Update all
1312 callers.
1313 (compare_symbols): Remove.
1314 (std_compare_symbols): Rename to `compare_symbols'.
1315 (find_method): Change `sym_classes' parameter to std::vector.
1316 Update all callers. Use std::sort to sort sym_classes.
1317 (find_linespec_symbols): Remove cleanup.
1318
1319 2018-08-29 Keith Seitz <keiths@redhat.com>
1320
1321 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1322 std::vector. Update all users.
1323 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1324 (struct collect_info) <minimal_symbols>: Likewise.
1325 (compare_msymbols): Return bool. Change parameters to const
1326 bound_minimal_symbol references.
1327 (find_method, find_function_symbols, find_linespec_symbols): Change
1328 `minsyms' parameter to std::vector. Update all callers.
1329
1330 2018-08-29 Keith Seitz <keiths@redhat.com>
1331
1332 * linespec.c (struct linespec) <label_symbols>: Change type to
1333 std::vector. Update all users.
1334 (find_label_symbols_in_block): Change `result' parameter to
1335 std::vector. Update all callers.
1336 (find_label_symbols): Return std::vector. Update all callers.
1337
1338 2018-08-29 Keith Seitz <keiths@redhat.com>
1339
1340 * linespec.c (struct linespec) <function_symbols>: Change type to
1341 std::vector. Update all users.
1342 (struct collect_info) <function_symbols>: Likewise.
1343 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1344 (std_compare_symbols): New function.
1345 (find_method, find_function_symbols, find_linespec_symbols)
1346 (find_label_symbols_in_block): Change `symbols' parameter to
1347 std::vector. Update all callers.
1348 (find_label_symbols): Likewise for `function_symbols' and
1349 `label_funcs_ret'.
1350
1351 2018-08-29 Keith Seitz <keiths@redhat.com>
1352
1353 * linespec.c (symtab_vector_up): Define.
1354 (struct linespec) <file_symtabs>: Change type to std::vector *.
1355 Update all uses.
1356 (struct collect_info) <file_symtabs>: Likewise.
1357 (collect_symtabs_from_filename): Return symtab_vector_up.
1358 Update all callers.
1359 (decode_objc): Remove cleanup.
1360 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1361 (symtab_collector::release_symtabs): Return symtab_vector_up.
1362 Update all callers.
1363 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1364 Update all users.
1365 (collect_symtabs_from_filename, symtabs_from_filename): Return
1366 symtab_vector_up. Update all callers.
1367
1368 2018-08-29 Tom Tromey <tom@tromey.com>
1369
1370 * csky-tdep.c (csky_analyze_prologue): Use
1371 core_addr_to_string_nz.
1372
1373 2018-08-29 Tom Tromey <tom@tromey.com>
1374
1375 * windows-nat.c (struct xlate_exception) <them>: Change type to
1376 DWORD.
1377 (xlate): Fix formatting. Remove last entry.
1378 (struct xlate_exception, xlate): Comment out.
1379 (windows_nat_target::resume): Use ranged for.
1380
1381 2018-08-29 Jim Wilson <jimw@sifive.com>
1382
1383 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1384 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1385 of NT_PRFPREG.
1386 (riscv_linux_nat_target::store_registers): Likewise.
1387
1388 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1389
1390 PR gdb/23555
1391 PR gdb/23558
1392 * gnulib/aclocal.m4: Regenerate.
1393 * gnulib/config.in: Regenerate.
1394 * gnulib/configure: Regenerate.
1395 * gnulib/import/Makefile.am: Update.
1396 * gnulib/import/Makefile.in: Update.
1397 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1398 * gnulib/import/_Noreturn.h: ... this.
1399 * gnulib/import/alloca.in.h: Update.
1400 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1401 * gnulib/import/arg-nonnull.h: ... this.
1402 * gnulib/import/assure.h: Update.
1403 * gnulib/import/at-func.c: Update.
1404 * gnulib/import/basename-lgpl.c: Update.
1405 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1406 * gnulib/import/c++defs.h: ... this.
1407 * gnulib/import/canonicalize-lgpl.c: Update.
1408 * gnulib/import/cdefs.h: Update.
1409 * gnulib/import/chdir-long.c: Update.
1410 * gnulib/import/chdir-long.h: Update.
1411 * gnulib/import/cloexec.c: Update.
1412 * gnulib/import/cloexec.h: Update.
1413 * gnulib/import/close.c: Update.
1414 * gnulib/import/closedir.c: Update.
1415 * gnulib/import/config.charset: Update.
1416 * gnulib/import/dirent-private.h: Update.
1417 * gnulib/import/dirent.in.h: Update.
1418 * gnulib/import/dirfd.c: Update.
1419 * gnulib/import/dirname-lgpl.c: Update.
1420 * gnulib/import/dirname.h: Update.
1421 * gnulib/import/dosname.h: Update.
1422 * gnulib/import/dup-safer-flag.c: Update.
1423 * gnulib/import/dup-safer.c: Update.
1424 * gnulib/import/dup.c: Update.
1425 * gnulib/import/dup2.c: Update.
1426 * gnulib/import/errno.in.h: Update.
1427 * gnulib/import/error.c: Update.
1428 * gnulib/import/error.h: Update.
1429 * gnulib/import/exitfail.c: Update.
1430 * gnulib/import/exitfail.h: Update.
1431 * gnulib/import/extra/update-copyright: Update.
1432 * gnulib/import/fchdir.c: Update.
1433 * gnulib/import/fcntl.c: Update.
1434 * gnulib/import/fcntl.in.h: Update.
1435 * gnulib/import/fd-hook.c: Update.
1436 * gnulib/import/fd-hook.h: Update.
1437 * gnulib/import/fd-safer-flag.c: Update.
1438 * gnulib/import/fd-safer.c: Update.
1439 * gnulib/import/fdopendir.c: Update.
1440 * gnulib/import/filename.h: Update.
1441 * gnulib/import/filenamecat-lgpl.c: Update.
1442 * gnulib/import/filenamecat.h: Update.
1443 * gnulib/import/flexmember.h: Update.
1444 * gnulib/import/float+.h: Update.
1445 * gnulib/import/float.c: Update.
1446 * gnulib/import/float.in.h: Update.
1447 * gnulib/import/fnmatch.c: Update.
1448 * gnulib/import/fnmatch.in.h: Update.
1449 * gnulib/import/fnmatch_loop.c: Update.
1450 * gnulib/import/fpucw.h: Update.
1451 * gnulib/import/frexp.c: Update.
1452 * gnulib/import/frexpl.c: Update.
1453 * gnulib/import/fstat.c: Update.
1454 * gnulib/import/fstatat.c: Update.
1455 * gnulib/import/getcwd-lgpl.c: Update.
1456 * gnulib/import/getcwd.c: Update.
1457 * gnulib/import/getdtablesize.c: Update.
1458 * gnulib/import/getlogin_r.c: Update.
1459 * gnulib/import/getprogname.c: Update.
1460 * gnulib/import/getprogname.h: Update.
1461 * gnulib/import/gettext.h: Update.
1462 * gnulib/import/gettimeofday.c: Update.
1463 * gnulib/import/glob-libc.h: Update.
1464 * gnulib/import/glob.c: Update.
1465 * gnulib/import/glob.in.h: Update.
1466 * gnulib/import/glob_internal.h: Update.
1467 * gnulib/import/glob_pattern_p.c: Update.
1468 * gnulib/import/globfree.c: Update.
1469 * gnulib/import/hard-locale.c: Update.
1470 * gnulib/import/hard-locale.h: Update.
1471 * gnulib/import/intprops.h: Update.
1472 * gnulib/import/inttypes.in.h: Update.
1473 * gnulib/import/isnan.c: Update.
1474 * gnulib/import/isnand-nolibm.h: Update.
1475 * gnulib/import/isnand.c: Update.
1476 * gnulib/import/isnanl-nolibm.h: Update.
1477 * gnulib/import/isnanl.c: Update.
1478 * gnulib/import/itold.c: Update.
1479 * gnulib/import/libc-config.h: Update.
1480 * gnulib/import/limits.in.h: Update.
1481 * gnulib/import/localcharset.c: Update.
1482 * gnulib/import/localcharset.h: Update.
1483 * gnulib/import/localtime-buffer.c: Update.
1484 * gnulib/import/localtime-buffer.h: Update.
1485 * gnulib/import/lstat.c: Update.
1486 * gnulib/import/m4/00gnulib.m4: Update.
1487 * gnulib/import/m4/__inline.m4: Update.
1488 * gnulib/import/m4/absolute-header.m4: Update.
1489 * gnulib/import/m4/alloca.m4: Update.
1490 * gnulib/import/m4/builtin-expect.m4: Update.
1491 * gnulib/import/m4/canonicalize.m4: Update.
1492 * gnulib/import/m4/chdir-long.m4: Update.
1493 * gnulib/import/m4/close.m4: Update.
1494 * gnulib/import/m4/closedir.m4: Update.
1495 * gnulib/import/m4/configmake.m4: Update.
1496 * gnulib/import/m4/d-ino.m4: Update.
1497 * gnulib/import/m4/d-type.m4: Update.
1498 * gnulib/import/m4/dirent_h.m4: Update.
1499 * gnulib/import/m4/dirfd.m4: Update.
1500 * gnulib/import/m4/dirname.m4: Update.
1501 * gnulib/import/m4/double-slash-root.m4: Update.
1502 * gnulib/import/m4/dup.m4: Update.
1503 * gnulib/import/m4/dup2.m4: Update.
1504 * gnulib/import/m4/eealloc.m4: Update.
1505 * gnulib/import/m4/environ.m4: Update.
1506 * gnulib/import/m4/errno_h.m4: Update.
1507 * gnulib/import/m4/error.m4: Update.
1508 * gnulib/import/m4/exponentd.m4: Update.
1509 * gnulib/import/m4/exponentl.m4: Update.
1510 * gnulib/import/m4/extensions.m4: Update.
1511 * gnulib/import/m4/extern-inline.m4: Update.
1512 * gnulib/import/m4/fchdir.m4: Update.
1513 * gnulib/import/m4/fcntl-o.m4: Update.
1514 * gnulib/import/m4/fcntl.m4: Update.
1515 * gnulib/import/m4/fcntl_h.m4: Update.
1516 * gnulib/import/m4/fdopendir.m4: Update.
1517 * gnulib/import/m4/filenamecat.m4: Update.
1518 * gnulib/import/m4/flexmember.m4: Update.
1519 * gnulib/import/m4/float_h.m4: Update.
1520 * gnulib/import/m4/fnmatch.m4: Update.
1521 * gnulib/import/m4/fnmatch_h.m4: Update.
1522 * gnulib/import/m4/fpieee.m4: Update.
1523 * gnulib/import/m4/frexp.m4: Update.
1524 * gnulib/import/m4/frexpl.m4: Update.
1525 * gnulib/import/m4/fstat.m4: Update.
1526 * gnulib/import/m4/fstatat.m4: Update.
1527 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1528 * gnulib/import/m4/getcwd-path-max.m4: Update.
1529 * gnulib/import/m4/getcwd.m4: Update.
1530 * gnulib/import/m4/getdtablesize.m4: Update.
1531 * gnulib/import/m4/getlogin.m4: Update.
1532 * gnulib/import/m4/getlogin_r.m4: Update.
1533 * gnulib/import/m4/getpagesize.m4: Update.
1534 * gnulib/import/m4/getprogname.m4: Update.
1535 * gnulib/import/m4/gettimeofday.m4: Update.
1536 * gnulib/import/m4/glibc21.m4: Update.
1537 * gnulib/import/m4/glob.m4: Update.
1538 * gnulib/import/m4/glob_h.m4: Update.
1539 * gnulib/import/m4/gnulib-cache.m4: Update.
1540 * gnulib/import/m4/gnulib-common.m4: Update.
1541 * gnulib/import/m4/gnulib-comp.m4: Update.
1542 * gnulib/import/m4/gnulib-tool.m4: Update.
1543 * gnulib/import/m4/hard-locale.m4: Update.
1544 * gnulib/import/m4/include_next.m4: Update.
1545 * gnulib/import/m4/inttypes-pri.m4: Update.
1546 * gnulib/import/m4/inttypes.m4: Update.
1547 * gnulib/import/m4/isnand.m4: Update.
1548 * gnulib/import/m4/isnanl.m4: Update.
1549 * gnulib/import/m4/largefile.m4: Update.
1550 * gnulib/import/m4/limits-h.m4: Update.
1551 * gnulib/import/m4/localcharset.m4: Update.
1552 * gnulib/import/m4/locale-fr.m4: Update.
1553 * gnulib/import/m4/locale-ja.m4: Update.
1554 * gnulib/import/m4/locale-zh.m4: Update.
1555 * gnulib/import/m4/localtime-buffer.m4: Update.
1556 * gnulib/import/m4/longlong.m4: Update.
1557 * gnulib/import/m4/lstat.m4: Update.
1558 * gnulib/import/m4/malloc.m4: Update.
1559 * gnulib/import/m4/malloca.m4: Update.
1560 * gnulib/import/m4/math_h.m4: Update.
1561 * gnulib/import/m4/mbrtowc.m4: Update.
1562 * gnulib/import/m4/mbsinit.m4: Update.
1563 * gnulib/import/m4/mbsrtowcs.m4: Update.
1564 * gnulib/import/m4/mbstate_t.m4: Update.
1565 * gnulib/import/m4/memchr.m4: Update.
1566 * gnulib/import/m4/memmem.m4: Update.
1567 * gnulib/import/m4/mempcpy.m4: Update.
1568 * gnulib/import/m4/memrchr.m4: Update.
1569 * gnulib/import/m4/mkdir.m4: Update.
1570 * gnulib/import/m4/mkstemp.m4: Update.
1571 * gnulib/import/m4/mmap-anon.m4: Update.
1572 * gnulib/import/m4/mode_t.m4: Update.
1573 * gnulib/import/m4/msvc-inval.m4: Update.
1574 * gnulib/import/m4/msvc-nothrow.m4: Update.
1575 * gnulib/import/m4/multiarch.m4: Update.
1576 * gnulib/import/m4/nocrash.m4: Update.
1577 * gnulib/import/m4/off_t.m4: Update.
1578 * gnulib/import/m4/onceonly.m4: Update.
1579 * gnulib/import/m4/open-cloexec.m4: Update.
1580 * gnulib/import/m4/open.m4: Update.
1581 * gnulib/import/m4/openat.m4: Update.
1582 * gnulib/import/m4/opendir.m4: Update.
1583 * gnulib/import/m4/pathmax.m4: Update.
1584 * gnulib/import/m4/rawmemchr.m4: Update.
1585 * gnulib/import/m4/readdir.m4: Update.
1586 * gnulib/import/m4/readlink.m4: Update.
1587 * gnulib/import/m4/realloc.m4: Update.
1588 * gnulib/import/m4/rename.m4: Update.
1589 * gnulib/import/m4/rewinddir.m4: Update.
1590 * gnulib/import/m4/rmdir.m4: Update.
1591 * gnulib/import/m4/save-cwd.m4: Update.
1592 * gnulib/import/m4/secure_getenv.m4: Update.
1593 * gnulib/import/m4/setenv.m4: Update.
1594 * gnulib/import/m4/signal_h.m4: Update.
1595 * gnulib/import/m4/ssize_t.m4: Update.
1596 * gnulib/import/m4/stat-time.m4: Update.
1597 * gnulib/import/m4/stat.m4: Update.
1598 * gnulib/import/m4/std-gnu11.m4: Update.
1599 * gnulib/import/m4/stdbool.m4: Update.
1600 * gnulib/import/m4/stddef_h.m4: Update.
1601 * gnulib/import/m4/stdint.m4: Update.
1602 * gnulib/import/m4/stdio_h.m4: Update.
1603 * gnulib/import/m4/stdlib_h.m4: Update.
1604 * gnulib/import/m4/strchrnul.m4: Update.
1605 * gnulib/import/m4/strdup.m4: Update.
1606 * gnulib/import/m4/strerror.m4: Update.
1607 * gnulib/import/m4/string_h.m4: Update.
1608 * gnulib/import/m4/strstr.m4: Update.
1609 * gnulib/import/m4/strtok_r.m4: Update.
1610 * gnulib/import/m4/sys_socket_h.m4: Update.
1611 * gnulib/import/m4/sys_stat_h.m4: Update.
1612 * gnulib/import/m4/sys_time_h.m4: Update.
1613 * gnulib/import/m4/sys_types_h.m4: Update.
1614 * gnulib/import/m4/tempname.m4: Update.
1615 * gnulib/import/m4/time_h.m4: Update.
1616 * gnulib/import/m4/unistd-safer.m4: Update.
1617 * gnulib/import/m4/unistd_h.m4: Update.
1618 * gnulib/import/m4/warn-on-use.m4: Update.
1619 * gnulib/import/m4/wchar_h.m4: Update.
1620 * gnulib/import/m4/wchar_t.m4: Update.
1621 * gnulib/import/m4/wctype_h.m4: Update.
1622 * gnulib/import/m4/wint_t.m4: Update.
1623 * gnulib/import/malloc.c: Update.
1624 * gnulib/import/malloc/scratch_buffer.h: Update.
1625 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1626 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1627 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1628 * gnulib/import/malloca.c: Update.
1629 * gnulib/import/malloca.h: Update.
1630 * gnulib/import/malloca.valgrind: Update.
1631 * gnulib/import/math.in.h: Update.
1632 * gnulib/import/mbrtowc.c: Update.
1633 * gnulib/import/mbsinit.c: Update.
1634 * gnulib/import/mbsrtowcs-impl.h: Update.
1635 * gnulib/import/mbsrtowcs-state.c: Update.
1636 * gnulib/import/mbsrtowcs.c: Update.
1637 * gnulib/import/memchr.c: Update.
1638 * gnulib/import/memmem.c: Update.
1639 * gnulib/import/mempcpy.c: Update.
1640 * gnulib/import/memrchr.c: Update.
1641 * gnulib/import/mkdir.c: Update.
1642 * gnulib/import/mkstemp.c: Update.
1643 * gnulib/import/msvc-inval.c: Update.
1644 * gnulib/import/msvc-inval.h: Update.
1645 * gnulib/import/msvc-nothrow.c: Update.
1646 * gnulib/import/msvc-nothrow.h: Update.
1647 * gnulib/import/open.c: Update.
1648 * gnulib/import/openat-die.c: Update.
1649 * gnulib/import/openat-priv.h: Update.
1650 * gnulib/import/openat-proc.c: Update.
1651 * gnulib/import/openat.c: Update.
1652 * gnulib/import/openat.h: Update.
1653 * gnulib/import/opendir.c: Update.
1654 * gnulib/import/pathmax.h: Update.
1655 * gnulib/import/pipe-safer.c: Update.
1656 * gnulib/import/rawmemchr.c: Update.
1657 * gnulib/import/readdir.c: Update.
1658 * gnulib/import/readlink.c: Update.
1659 * gnulib/import/realloc.c: Update.
1660 * gnulib/import/ref-add.sin: Update.
1661 * gnulib/import/ref-del.sin: Update.
1662 * gnulib/import/rename.c: Update.
1663 * gnulib/import/rewinddir.c: Update.
1664 * gnulib/import/rmdir.c: Update.
1665 * gnulib/import/same-inode.h: Update.
1666 * gnulib/import/save-cwd.c: Update.
1667 * gnulib/import/save-cwd.h: Update.
1668 * gnulib/import/scratch_buffer.h: Update.
1669 * gnulib/import/secure_getenv.c: Update.
1670 * gnulib/import/setenv.c: Update.
1671 * gnulib/import/signal.in.h: Update.
1672 * gnulib/import/stat-time.c: Update.
1673 * gnulib/import/stat-time.h: Update.
1674 * gnulib/import/stat-w32.c: Update.
1675 * gnulib/import/stat-w32.h: Update.
1676 * gnulib/import/stat.c: Update.
1677 * gnulib/import/stdbool.in.h: Update.
1678 * gnulib/import/stddef.in.h: Update.
1679 * gnulib/import/stdint.in.h: Update.
1680 * gnulib/import/stdio.in.h: Update.
1681 * gnulib/import/stdlib.in.h: Update.
1682 * gnulib/import/str-two-way.h: Update.
1683 * gnulib/import/strchrnul.c: Update.
1684 * gnulib/import/strdup.c: Update.
1685 * gnulib/import/streq.h: Update.
1686 * gnulib/import/strerror-override.c: Update.
1687 * gnulib/import/strerror-override.h: Update.
1688 * gnulib/import/strerror.c: Update.
1689 * gnulib/import/string.in.h: Update.
1690 * gnulib/import/stripslash.c: Update.
1691 * gnulib/import/strnlen1.c: Update.
1692 * gnulib/import/strnlen1.h: Update.
1693 * gnulib/import/strstr.c: Update.
1694 * gnulib/import/strtok_r.c: Update.
1695 * gnulib/import/sys_stat.in.h: Update.
1696 * gnulib/import/sys_time.in.h: Update.
1697 * gnulib/import/sys_types.in.h: Update.
1698 * gnulib/import/tempname.c: Update.
1699 * gnulib/import/tempname.h: Update.
1700 * gnulib/import/time.in.h: Update.
1701 * gnulib/import/unistd--.h: Update.
1702 * gnulib/import/unistd-safer.h: Update.
1703 * gnulib/import/unistd.in.h: Update.
1704 * gnulib/import/unsetenv.c: Update.
1705 * gnulib/import/verify.h: Update.
1706 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1707 * gnulib/import/wchar.in.h: Update.
1708 * gnulib/import/wctype.in.h: Update.
1709 * gnulib/import/xalloc-oversized.h: Update.
1710 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1711 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1712
1713 2018-08-16 Gary Benson <gbenson@redhat.com>
1714
1715 PR gdb/13000:
1716 * gdb/main.c (captured_main_1): Exit with nonzero status
1717 in batch mode if the last command to be executed failed.
1718 * NEWS: Mention the above.
1719
1720 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1721
1722 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1723 end of warning message.
1724
1725 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1726
1727 PR gdb/22943:
1728 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1729 (aarch64_extract_return_value): Use
1730 aapcs_is_vfp_call_or_return_candidate.
1731 (aarch64_return_in_memory): Likewise.
1732 (aarch64_store_return_value): Likewise.
1733
1734 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1735
1736 * aarch64-tdep.c
1737 (aapcs_is_vfp_call_or_return_candidate): Make static
1738 (pass_in_v_or_stack): Remove function.
1739 (pass_in_v_vfp_candidate): New function.
1740 (aarch64_push_dummy_call): Check for float register candidates.
1741
1742 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1743
1744 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1745 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1746 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1747
1748 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1749
1750 PR build/23399
1751 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1752 (struct ipa_sym_addresses): Rename to...
1753 (struct ipa_sym_addresses_common): ... this.
1754 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1755
1756 2018-08-28 Tom Tromey <tom@tromey.com>
1757
1758 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1759 (token_fifo): Now a std::vector.
1760 (yylex, c_parse): Update.
1761 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1762 (token_fifo): Now a std::vector.
1763 (yylex, d_parse): Update.
1764 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1765 (token_fifo): Now a std::vector.
1766 (yylex, go_parse): Update.
1767
1768 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1769
1770 * parser-defs.h (struct type_stack) <elements>: Change type to
1771 std::vector<union type_stack_elt>.
1772 <depth, size>: Remove.
1773 * parse.c (parse_exp_in_context_1): Adjust.
1774 (type_stack_reserve): Remove.
1775 (check_type_stack_depth): Remove.
1776 (insert_into_type_stack): Adjust to std::vector.
1777 (insert_type): Likewise.
1778 (push_type): Likewise.
1779 (push_type_int): Likewise.
1780 (insert_type_address_space): Likewise.
1781 (pop_type): Likewise.
1782 (pop_type_int): Likewise.
1783 (pop_typelist): Likewise.
1784 (pop_type_stack): Likewise.
1785 (append_type_stack): Likewise.
1786 (push_type_stack): Likewise.
1787 (get_type_stack): Likewise.
1788 (type_stack_cleanup): Likewise.
1789 (push_typelist): Likewise.
1790 (follow_types): Likewise.
1791 (_initialize_parse): Likewise.
1792
1793 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1794
1795 * NEWS: Mention csky target.
1796
1797 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1798 Hafiz Abid Qadeer <abidh@codesourcery.com>
1799 Don Breazeal <donb@codesourcery.com>
1800
1801 * csky-linux-tdep.c: New file.
1802 * csky-tdep.c: Likewise.
1803 * csky-tdep.h: Likewise.
1804 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1805 csky-tdep.o.
1806 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1807 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1808 * configure.tgt: Add csky support.
1809
1810 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1811
1812 * python/py-framefilter.c (py_print_frame): Print frame architecture
1813 when printing on an MI output.
1814
1815 2018-08-27 Tom Tromey <tom@tromey.com>
1816
1817 PR build/23087:
1818 * configure: Rebuild.
1819 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1820
1821 2018-08-27 Tom Tromey <tom@tromey.com>
1822
1823 * aarch64-linux-tdep.c
1824 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1825 casts to int.
1826
1827 2018-08-27 Tom Tromey <tom@tromey.com>
1828
1829 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1830 unsigned.
1831 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1832 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1833 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1834 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1835 unsigned.
1836
1837 2018-08-27 Tom Tromey <tom@tromey.com>
1838
1839 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1840 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1841
1842 2018-08-27 Tom Tromey <tom@tromey.com>
1843
1844 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1845 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1846 ULONGEST_MAX.
1847 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1848 ULONGEST_MAX.
1849 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1850 ULONGEST_MAX.
1851 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1852 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1853 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1854 ULONGEST_MAX.
1855 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1856 (ppc64_linux_sigaction_tramp_frame)
1857 (ppc32_linux_sighandler_tramp_frame)
1858 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1859 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1860 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1861 * mn10300-linux-tdep.c (am33_linux_sigframe)
1862 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1863 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1864 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1865 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1866 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1867 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1868 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1869 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1870 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1871 * microblaze-linux-tdep.c
1872 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1873 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1874 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1875 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1876 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1877 * common/common-types.h (ULONGEST_MAX): New define.
1878 (CORE_ADDR_MAX): Fix formatting.
1879 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
1880 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
1881 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
1882 (arm_linux_rt_sigreturn_tramp_frame)
1883 (arm_eabi_linux_sigreturn_tramp_frame)
1884 (arm_eabi_linux_rt_sigreturn_tramp_frame)
1885 (thumb2_eabi_linux_sigreturn_tramp_frame)
1886 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
1887 (arm_linux_restart_syscall_tramp_frame)
1888 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
1889 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
1890 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
1891 ULONGEST_MAX.
1892 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
1893
1894 2018-08-27 Tom Tromey <tom@tromey.com>
1895
1896 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
1897 CORE_ADDR_MAX.
1898 * mips-tdep.c (mips_deal_with_atomic_sequence)
1899 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
1900 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
1901 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
1902 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
1903 CORE_ADDR_MAX.
1904 * aarch64-tdep.c (aarch64_software_single_step): Use
1905 CORE_ADDR_MAX.
1906
1907 2018-08-27 Tom Tromey <tom@tromey.com>
1908
1909 * linespec.c (complete_linespec_component): Add cast to "char".
1910 * completer.c (completion_tracker::build_completion_result): Add
1911 cast to "char".
1912
1913 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1914
1915 * solist.h (struct solist, struct target_so_ops): Fix
1916 indentation.
1917
1918 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1919
1920 * ada-tasks.c (ada_task_info_s): Remove typedef.
1921 (DEF_VEC_O(ada_task_info_s)): Remove.
1922 (struct ada_tasks_inferior_data): Initialize fields.
1923 <task_list>: Make an std::vector.
1924 (get_ada_tasks_inferior_data): Allocate with new.
1925 (ada_get_task_number): Adjust.
1926 (get_task_number_from_id): Likewise.
1927 (valid_task_id): Likewise.
1928 (ada_get_task_info_from_ptid): Likewise.
1929 (iterate_over_live_ada_tasks): Likewise.
1930 (add_ada_task): Likewise.
1931 (read_known_tasks): Likewise.
1932 (ada_build_task_list): Likewise.
1933 (print_ada_task_info): Likewise.
1934 (info_task): Likewise.
1935 (task_command_1): Likewise.
1936
1937 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
1938
1939 * ada-lang.c (add_angle_brackets): Return std::string.
1940
1941 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
1942
1943 * python/py-threadevent.c (py_get_event_thread): Initialize
1944 pythread.
1945
1946 2018-08-24 Pedro Alves <palves@redhat.com>
1947
1948 * python/py-bpevent.c (create_breakpoint_event_object): Use
1949 copy-initialization.
1950 * python/py-continueevent.c (emit_continue_event): Use
1951 copy-initialization.
1952 * python/py-exitedevent.c (create_exited_event_object): Return a
1953 gdbpy_ref<>.
1954 (emit_exited_event): Use copy-initialization.
1955 * python/py-inferior.c (python_new_inferior)
1956 (python_inferior_deleted, add_thread_object): Use
1957 copy-initialization.
1958 * python/py-infevents.c (create_inferior_call_event_object)
1959 (create_register_changed_event_object)
1960 (create_memory_changed_event_object): Return a gdbpy_ref<>.
1961 (emit_inferior_call_event, emit_memory_changed_event)
1962 (emit_register_changed_event): Use copy-initialization.
1963 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1964 Return a gdbpy_ref<>.
1965 (emit_new_objfile_event): Use copy-initialization.
1966 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
1967 (emit_clear_objfiles_event): Use copy-initialization.
1968 * python/py-signalevent.c (create_signal_event_object): Use
1969 copy-initialization.
1970 * python/py-threadevent.c (create_thread_event_object): Use
1971 copy-initialization.
1972
1973 2018-08-24 Pedro Alves <palves@redhat.com>
1974 Simon Marchi <simon.marchi@ericsson.com>
1975
1976 PR gdb/23379
1977 * python/py-continueevent.c: Include "gdbthread.h".
1978 (create_continue_event_object): Add intro comment. Add 'ptid'
1979 parameter. Use it to find thread to pass to
1980 create_thread_event_object.
1981 (emit_continue_event): Pass PTID down to
1982 create_continue_event_object.
1983 * python/py-event.h (py_get_event_thread): Declare.
1984 (create_thread_event_object): Remove default from 'thread'
1985 parameter.
1986 * python/py-stopevent.c (create_stop_event_object): Use
1987 py_get_event_thread.
1988 * python/py-threadevent.c (get_event_thread): Rename to ...
1989 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
1990 and use it to find the thread.
1991 (create_thread_event_object): Assert that THREAD isn't null.
1992 Don't find the event thread here.
1993
1994 2018-08-23 Kevin Buettner <kevinb@redhat.com>
1995
1996 * block.h (blockrange, blockranges): New struct declarations.
1997 (struct block): Add new field named `ranges'.
1998 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
1999 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
2000 macros for accessing ranges in struct block.
2001 (make_blockranges): New declaration.
2002 block.c (make_blockranges): New function.
2003 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
2004 for block.
2005 * symtab.h (find_pc_partial_function): Add new parameter `block'.
2006 * blockframe.c (cache_pc_function_block): New static global.
2007 (clear_pc_function_cache): Clear cache_pc_function_block.
2008 (find_pc_partial_function): Move comment to symtab.h. Add
2009 support for non-contiguous blocks.
2010 * cli/cli-cmds.c (block.h): Include.
2011 (print_disassembly): Handle printing of non-contiguous blocks.
2012 (disassemble_current_function): Likewise.
2013 (disassemble_command): Likewise.
2014
2015 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
2016 BLOCK_START.
2017 * blockframe.c (get_pc_function_start): Likewise.
2018 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
2019 (gcc_symbol_address): Likewise.
2020 * compile/compile-object-run.c (compile_object_run): Likewise.
2021 * compile/compile.c (get_expr_block_and_pc): Likewise.
2022 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
2023 (func_addr_to_tail_call_list): Likewise.
2024 * findvar.c (default_read_var_value): Likewise.
2025 * inline-frame.c (inline_frame_this_id): Likewise.
2026 (skip-inline_frames): Likewise.
2027 * infcmd.c (until_next_command): Likewise.
2028 * linespec.c (convert_linespec_to_sals): Likewise.
2029 * parse.c (parse_exp_in_context_1): Likewise.
2030 * printcmd.c (build_address_symbolic): likewise.
2031 (info_address_command): Likewise.
2032 symtab.c (find_function_start_sal): Likewise.
2033 (skip_prologue_sal): Likewise.
2034 (find_function_alias_target): Likewise.
2035 (find_gnu_ifunc): Likewise.
2036 * stack.c (find_frame_funname): Likewise.
2037 * symtab.c (fixup_symbol_section): Likewise.
2038 (find_function_start_sal): Likewise.
2039 (skip_prologue_sal): Likewsie.
2040 (find_function_alias_target): Likewise.
2041 (find_gnu_ifunc): Likewise.
2042 * tracepoint.c (info_scope_command): Likewise.
2043 * value.c (value_fn_field): Likewise.
2044
2045 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
2046 in place of find_pc_partial_function.
2047 * blockframe.c (find_function_entry_range_from_pc): New function.
2048 * symtab.h (find_function_entry_range_from_pc): Declare and document.
2049 * objfiles.c (objfile_relocate1): Relocate start and end addresses
2050 for each range in a block.
2051
2052
2053 2018-08-23 Xavier Roirand <roirand@adacore.com>
2054
2055 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
2056 incrementation.
2057
2058 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2059
2060 * solib-svr4.c (read_program_headers_from_bfd): Return
2061 gdb::optional<gdb::byte_vector>.
2062 (svr4_exec_displacement): Adjust.
2063
2064 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2065
2066 * solib-svr4.c (read_program_header): Return
2067 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
2068 (find_program_interpreter): Return
2069 gdb::optional<gdb::byte_vector>.
2070 (scan_dyntag_auxv): Adjust.
2071 (enable_break): Adjust.
2072 (svr4_exec_displacement): Adjust.
2073
2074 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2075
2076 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
2077 * inf-child.c (inf_child_target::terminal_save_inferior): New.
2078
2079 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2080
2081 * guile/scm-string.c (gdbscm_scm_from_printf): Use
2082 string_vprintf.
2083 * guile/scm-utils.c (gdbscm_printf): Likewise.
2084 * serial.c (serial_printf): Likewise.
2085 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
2086
2087 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
2088
2089 * stack.c (print_frame): Print frame architecture when printing on
2090 an MI output.
2091 * NEWS: Mention new "arch" attribute in frame output.
2092
2093 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2094
2095 * arch/aarch64.h (aarch64_regnum): Update comment.
2096
2097 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2098
2099 * NEWS: Add SVE to 8.2 section.
2100
2101 2018-08-21 Pedro Alves <palves@redhat.com>
2102
2103 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2104 out from gdbscm_parse_function_args.
2105 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2106 gdbscm_parse_function_args_1.
2107
2108 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2109
2110 PR gdb/17816
2111 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2112 operator.
2113
2114 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2115
2116 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2117
2118 2018-08-19 Michael Spang <spang@google.com>
2119
2120 PR gdb/11786
2121 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2122 for PT_TLS segments.
2123
2124 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2125
2126 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2127 dwarf_variable_value.
2128 * dwarf2-frame.c (class dwarf_expr_executor):
2129 Add override for dwarf_variable_value.
2130 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2131 (class symbol_needs_eval_context): Likewise.
2132 (indirect_synthetic_pointer): Add forward declaration.
2133 (sect_variable_value): New function.
2134 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
2135 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
2136 for DW_OP_GNU_variable_value.
2137
2138 2018-08-16 Tom Tromey <tom@tromey.com>
2139
2140 * top.c (read_command_file): Update.
2141 (command_line_input): Remove "repeat" argument.
2142 * ada-lang.c (get_selections): Update.
2143 * linespec.c (decode_line_2): Update.
2144 * defs.h (command_line_input): Remove argument.
2145 * cli/cli-script.c (read_next_line): Update.
2146 * python/py-gdb-readline.c: Update.
2147
2148 2018-08-17 Tom Tromey <tom@tromey.com>
2149
2150 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
2151 command_line_input.
2152
2153 2018-08-15 Tom Tromey <tom@tromey.com>
2154
2155 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
2156
2157 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
2158
2159 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
2160 If used, use find_pc_partial_function to find address range
2161 to disassemble.
2162 * mi/mi-main.c (mi_cmd_list_features): Report
2163 "data-disassemble-a-option" feature.
2164 * NEWS: Mention new -data-disassemble option -a.
2165
2166 2018-08-13 Tom Tromey <tom@tromey.com>
2167
2168 * common/common-defs.h (_FORTIFY_SOURCE): Define.
2169
2170 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2171
2172 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
2173 (aarch64_linux_collect_sve_regset): Likewise.
2174 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
2175 * regcache.h (regcache_map_entry_size): New function.
2176
2177 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2178
2179 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
2180 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
2181 (SVE_HEADER_VL_LENGTH): Likewise.
2182 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
2183 (SVE_HEADER_FLAGS_LENGTH): Likewise.
2184 (SVE_HEADER_RESERVED_LENGTH): Likewise.
2185 (SVE_HEADER_SIZE_OFFSET): Likewise.
2186 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
2187 (SVE_HEADER_VL_OFFSET): Likewise.
2188 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
2189 (SVE_HEADER_FLAGS_OFFSET): Likewise.
2190 (SVE_HEADER_RESERVED_OFFSET): Likewise.
2191 (SVE_HEADER_SIZE): Likewise.
2192 (aarch64_linux_core_read_vq): Add function.
2193 (aarch64_linux_core_read_description): Check for SVE section.
2194
2195 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2196
2197 * aarch64-fbsd-tdep.c
2198 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
2199 collect_size.
2200 * aarch64-linux-tdep.c
2201 (aarch64_linux_iterate_over_regset_sections): Likewise.
2202 * alpha-linux-tdep.c
2203 (alpha_linux_iterate_over_regset_sections):
2204 * alpha-nbsd-tdep.c
2205 (alphanbsd_iterate_over_regset_sections): Likewise.
2206 * amd64-fbsd-tdep.c
2207 (amd64fbsd_iterate_over_regset_sections): Likewise.
2208 * amd64-linux-tdep.c
2209 (amd64_linux_iterate_over_regset_sections): Likewise.
2210 * arm-bsd-tdep.c
2211 (armbsd_iterate_over_regset_sections): Likewise.
2212 * arm-fbsd-tdep.c
2213 (arm_fbsd_iterate_over_regset_sections): Likewise.
2214 * arm-linux-tdep.c
2215 (arm_linux_iterate_over_regset_sections): Likewise.
2216 * corelow.c (get_core_registers_cb): Likewise.
2217 (core_target::fetch_registers): Likewise.
2218 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
2219 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
2220 * gdbarch.h (void): Regenerate.
2221 * gdbarch.sh: Add supply_size and collect_size.
2222 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
2223 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
2224 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
2225 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
2226 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
2227 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
2228 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
2229 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
2230 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
2231 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
2232 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
2233 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
2234 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
2235 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
2236 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
2237 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
2238 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
2239 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
2240 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
2241 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
2242 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
2243 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
2244 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
2245 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
2246 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
2247 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
2248 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
2249 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
2250 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
2251 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
2252
2253 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
2254
2255 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
2256 with string_printf.
2257
2258 2018-08-10 Keith Seitz <keiths@redhat.com>
2259
2260 * compile/compile-c-support.c (add_code_header, add_code_footer):
2261 Move into policy class.
2262 (c_push_user_expression, pop_user_expression_nop)
2263 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
2264 (compile_program): New host class.
2265 (c_compile_program): New typedef.
2266 (c_compute_porgram): Use c_compile_program.
2267
2268 2018-08-10 Keith Seitz <keiths@redhat.com>
2269
2270 * compile/compile-internal.h (compile_instance::~compile_instance):
2271 Remove calls to htab_delete.
2272 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
2273 * compile.c (compile_instance::compile_instance): Initialize
2274 htab unique pointers.
2275 (compile_instance::get_cached_type, compile_instance::insert_type)
2276 (compile_instance::error_symbol_once): Update for unique_ptr.
2277
2278 2018-08-10 Keith Seitz <keiths@redhat.com>
2279
2280 * compile/compile-c-symbols.c (struct symbol_error)
2281 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2282 (compile_instance::insert_symbol_error)
2283 (compile_instance::error_symbol_once): Move to ...
2284 * compile/compile.c: ... here.
2285
2286 2018-08-10 Keith Seitz <keiths@redhat.com>
2287
2288 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2289 instead of `new_compile_instance'.
2290 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2291 Update description.
2292 If the symbol error map is not initialized, create it.
2293 (generate_c_for_for_one_symbol): Do not check/initialize
2294 the symbol error map.
2295 * compile/compile-c-types.c (compile_c_instance): Make a class.
2296 Update all callers.
2297 (compile_instance::compile_instance): Initialize the type cache.
2298 (get_cached_type): New function.
2299 (insert_type): Update description.
2300 (compile_c_instance::m_default_cflags): Define.
2301 (convert_type): Update description. Use get_cached_type.
2302 (delete_instance): Moved to destructor.
2303 (new_compile_instance): Moved to constructor.
2304 * compile/compile-c.h (compile_c_instance): Make class inheriting
2305 from compile_instance.
2306 <base>: Remove field.
2307 <type_map, symbol_err_map>: Move to base class.
2308 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2309 * compile/compile-internal.h (compile_instance): Make class.
2310 <type_map_t, symbol_err_map_t>: Define.
2311 <fe>: Rename to `m_gcc_fe'.
2312 <scope, block, gcc_target_options>: Add `m_' prefix.
2313 <m_type_map, m_symbol_err_map>: New fields, moved from
2314 compile_c_instance.
2315 <destroy>: Remove.
2316 (convert_type, new_compile_instance): Remove.
2317 * compile/compile.c (cleanup_compile_instance): Remove.
2318 (compile_to_object): Use unique_ptr to eliminate cleanups.
2319 (compile_instance::set_print_callback, compile_instance::version)
2320 (compile_instance::set_verbose)
2321 (compile_instance::set_driver_filename)
2322 (compile_instance::set_triplet_regexp)
2323 (compile_instance::set_arguments)
2324 (compile_instance::set_source_file)
2325 (compile_instance::compile): Define.
2326
2327 2018-08-10 Keith Seitz <keiths@redhat.com>
2328
2329 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2330 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2331 gcc-c-fe.def to define C plugin.
2332 (delete_instance): Delete `c_plugin'.
2333 (new_compile_instance): Initialize `c_plugin'.
2334 * compile/compile-c.h: Include gcc_c_plugin.h.
2335 (struct compile_c_instance) <c_plugin>: New member.
2336 * gcc-c-plugin.h: New file.
2337 Update all callers with API change.
2338
2339 2018-08-10 Keith Seitz <keiths@redhat.com>
2340
2341 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2342 (HFILES_NO_SRCDIR): ... to here.
2343 Add compile-internal.h and compile-c.h.
2344 * compile/compile-c-support.c: Include compile-c.h.
2345 * compile/compile-c-symbols.c: Include compile-c.h.
2346 (generate_c_for_variable_locations): Update comment.
2347 * compile/compile-c-types.c: Include compile-c.h.
2348 * compile/compile-c.h: New file -- moved C language declarations
2349 from other files here.
2350 * compile/compile-internal.h: Do not include hashtab.h or
2351 common/enum-flags.h.
2352 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2353 (gcc_convert_symbol, gcc_symbol_address)
2354 (generate_c_for_variable_locations, c_get_mode_for_size)
2355 (c_get_range_decl_name): Definitions moved to compile-c.h.
2356 * compile/compile-loc2c.c: Include compile-c.h.
2357
2358 2018-08-10 Keith Seitz <keiths@redhat.com>
2359
2360 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2361 (c_symbol_substitution_name): ... this.
2362 Update all callers.
2363
2364 2018-08-10 Keith Seitz <keiths@redhat.com>
2365
2366 * compile/compile-c-support.c (c_compute_program): Use
2367 unique_xmalloc_ptr to eliminate cleanup.
2368 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2369 Return a unique_xmalloc_ptr and eliminate cleanup.
2370 * compile/compile-internal.h (generate_c_for_variable_locations):
2371 Return unique_xmalloc_ptr and update description.
2372
2373 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2374
2375 * corelow.c (core_target::get_core_register_section): Rename
2376 min_size to section_min_size.
2377
2378 2018-08-09 Jim Wilson <jimw@sifive.com>
2379
2380 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2381 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2382 * NEWS: Mention new GNU/Linux RISC-V target.
2383 * configure.host: Add riscv*-*-linux*.
2384 * configure.nat: Add riscv*.
2385 * configure.tgt: Add riscv*-*-linux*.
2386 * riscv-linux-nat.c: New file.
2387 * riscv-linux-tdep.c: New file.
2388
2389 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2390
2391 * infrun.c (resume): Make static, add forward declaration.
2392 (proceed): Update header comment.
2393 * infrun.h (resume): Delete declaration.
2394
2395 2018-08-09 Tom Tromey <tom@tromey.com>
2396
2397 * riscv-tdep.h: Minor formatting fixes.
2398
2399 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2400
2401 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2402 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2403 (test_mkdir_recursive): Likewise.
2404 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2405
2406 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2407
2408 * valarith.c (value_subscripted_rvalue): If an array is not in
2409 memory, and we don't know the upper bound, then we can't know that
2410 the requested element exists or not.
2411
2412 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2413
2414 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2415 (target_options_to_string): Add comment.
2416
2417 2018-08-08 Tom Tromey <tom@tromey.com>
2418
2419 * unittests/scoped_mmap-selftests.c: Check result of "write".
2420
2421 2018-08-08 Jim Wilson <jimw@sifive.com>
2422
2423 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2424 (decode_register_index_short): New.
2425 (decode_j_type_insn, decode_cj_type_insn): New.
2426 (decode_b_type_insn, decode_cb_type_insn): New.
2427 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2428 local xlen. Check xlen when decoding ambiguous compressed insns. In
2429 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2430 is_c_sw_insn instead of is_sw_insn.
2431 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2432 (riscv_software_single_step): New.
2433 * riscv-tdep.h (riscv_software_single_step): Declare.
2434
2435 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2436 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2437
2438 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2439
2440 PR gdb/18050:
2441 * target.c (dispose_inferior): Don't dispose of inferiors that are
2442 already killed.
2443
2444 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2445
2446 * remote.c (remote_target::download_tracepoint): Change char* to
2447 const char*.
2448
2449 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2450
2451 * target.h (target_options_to_string): Return an std::string.
2452 * target.c (str_comma_list_concat_elem): Return void, use
2453 std::string.
2454 (do_option): Likewise.
2455 (target_options_to_string): Return an std::string.
2456 * linux-nat.c (linux_nat_target::wait): Adjust.
2457 * target-debug.h (target_debug_print_options): Adjust.
2458
2459 2018-08-07 Tom Tromey <tom@tromey.com>
2460
2461 * Makefile.in (CPPFLAGS): New variable.
2462 (INTERNAL_CPPFLAGS): Use it.
2463
2464 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2465
2466 * NEWS: Mention the index cache.
2467
2468 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2469
2470 * common/pathstuff.h (get_standard_cache_dir): New.
2471 * common/pathstuff.c (get_standard_cache_dir): New.
2472 * build-id.h (build_id_to_string): New.
2473 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2474 DEBUG_STR_SUFFIX): Move to here.
2475 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2476 DEBUG_STR_SUFFIX): Move from there.
2477 (write_psymtabs_to_index): Make non-static, add basename
2478 parameter. Write to temporary files, rename when done.
2479 (save_gdb_index_command): Adjust call to
2480 write_psymtabs_to_index.
2481 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2482 field.
2483 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2484 (get_gdb_index_contents_from_cache): New.
2485 (get_gdb_index_contents_from_cache_dwz): New.
2486 (dwarf2_initialize_objfile): Read index from cache.
2487 (dwarf2_build_psymtabs): Save to index.
2488 * dwarf-index-cache.h: New file.
2489 * dwarf-index-cache.c: New file.
2490 * dwarf-index-write.h: New file.
2491
2492 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2493
2494 * gnulib/aclocal.m4: Re-generate.
2495 * gnulib/config.in: Re-generate.
2496 * gnulib/configure: Re-generate.
2497 * gnulib/import/Makefile.am: Re-generate.
2498 * gnulib/import/Makefile.in: Re-generate.
2499 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2500 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2501 * gnulib/import/m4/mkdir.m4: New file.
2502 * gnulib/import/mkdir.c: New file.
2503 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2504 module.
2505
2506 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2507
2508 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2509 * common/scoped_mmap.c: New file.
2510 * common/scoped_mmap.h (destroy): New method.
2511 (~scoped_mmap, reset): Use destroy.
2512 (scoped_mmap): New move constructor.
2513 (mmap_file): New declaration.
2514 * unittests/scoped_mmap-selftests.c (test_normal,
2515 test_invalid_filename, run_tests): New functions.
2516 (_initialize_scoped_mmap_selftests): Register selftest.
2517
2518 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2519
2520 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2521 (read_gdb_index_from_buffer): ... this. Remove section
2522 parameter, add buffer parameter.
2523 (get_gdb_index_contents_ftype,
2524 get_gdb_index_contents_dwz_ftype): New typedefs.
2525 (dwarf2_read_gdb_index): Add callback parameters to get the
2526 index contents.
2527 (get_gdb_index_contents_from_section): New.
2528 (dwarf2_initialize_objfile): Update call to
2529 dwarf2_read_gdb_index.
2530
2531 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2532
2533 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2534 (gdb_open_cloexec): Likewise.
2535 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2536 (commandline_from_pid): Likewise.
2537 (linux_xfer_osdata_threads): Likewise.
2538 (linux_xfer_osdata_fds): Likewise.
2539 * ada-lang.c (is_package_name): Likewise.
2540 * auxv.c (procfs_xfer_auxv): Likewise.
2541 * breakpoint.c (print_one_breakpoint_location): Use
2542 uiout::field_fmt.
2543 (print_one_catch_solib): Use string_printf.
2544 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2545 (add_pe_forwarded_sym): Likewise.
2546 * dwarf2read.c (create_type_unit_group): Likewise.
2547 (build_error_marker_type): Likewise.
2548 * infcall.c (get_function_name): Likewise.
2549 * valprint.c (print_converted_chars_to_obstack): Likewise.
2550 * xtensa-tdep.c (xtensa_register_type): Likewise.
2551
2552 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2553
2554 * remote.c (remote_target::download_tracepoint): Fix format
2555 string errors.
2556
2557 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2558
2559 * tracefile.c: Include common/byte-vector.h.
2560 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2561 with trace_regblock_size if needed. Update uses of buf.
2562
2563 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2564
2565 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2566 std::vector<unsigned char>.
2567 * tracepoint.c (collection_list::collection_list): Remove
2568 m_regs_mask initializer from initializer list. Resize
2569 m_regs_mask using the largest remote register number.
2570 (collection_list::add_remote_register): Remove size check on
2571 m_regs_mask. Use at to access element.
2572 (collection_list::stringify): Change type of temp_buf to
2573 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2574 stringify the register mask. Use pack_hex_byte for the register
2575 mask.
2576
2577 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2578
2579 * tracepoint.h (class collection_list) <add_register>: Remove.
2580 <add_remote_register, add_ax_registers, add_local_register>:
2581 Declare.
2582 <add_memrange>: Add scope parameter.
2583 * tracepoint.c (encode_actions_1): Likewise.
2584 (collection_list::add_register): Rename to ...
2585 (collection_list::add_remote_register): ... this. Update
2586 comment.
2587 (collection_list::add_ax_registers, add_local_register): New
2588 methods.
2589 (collection_list::add_memrange): Add scope parameter. Call
2590 add_local_register instead of add_register.
2591 (finalize_tracepoint_aexpr): New function.
2592 (collection_list::collect_symbol): Update calls to add_memrange.
2593 Call add_local_register instead of add_register. Call
2594 add_ax_registers. Call finalize_tracepoint_aexpr.
2595 (encode_actions_1): Get remote regnos for $reg action. Call
2596 add_remote_register, add_ax_registers, and add_local_register.
2597 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2598 (validate_actionline): Call finalize_tracepoint_aexpr.
2599
2600 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2601
2602 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2603 Replace array buf with gdb::char_vector buf, of size
2604 get_remote_packet_size (). Replace references to buf and
2605 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2606 and xsnprintf with snprintf. Raise errors if the buffer is too
2607 small.
2608
2609 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2610
2611 * remote.c (remote_target::download_tracepoint): Fix the has_more
2612 predicate in the QTDP action list iteration.
2613
2614 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2615
2616 * remote.c (remote_target::download_tracepoint): Fix indentation
2617 in for block.
2618
2619 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2620
2621 * proc-api.c (_initialize_proc_api): Remove c, unused.
2622 * procfs.c (procfs_init_inferior): Remove signals, unused.
2623 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2624 unused.
2625
2626 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2627 Andrew Burgess <andrew.burgess@embecosm.com>
2628
2629 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2630 'W_STOPCODE (0)' as this could be ambiguous.
2631
2632 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2633
2634 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2635 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2636 "ai_socktype").
2637
2638 2018-08-02 Tom Tromey <tom@tromey.com>
2639
2640 PR symtab/16842.
2641 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2642 symbols.
2643 (process_structure_scope): Likewise.
2644
2645 2018-08-02 Xavier Roirand <roirand@adacore.com>
2646
2647 PR gdb/22629:
2648 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2649 kill inferior.
2650
2651 2018-08-02 Tom Tromey <tom@tromey.com>
2652
2653 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2654 (darwin_suspend_inferior, darwin_resume_inferior)
2655 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2656 (darwin_check_new_threads): Check result of get_darwin_inferior.
2657
2658 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2659
2660 GDB 8.1.1 released.
2661
2662 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2663
2664 * varobj.c (varobj_get_path_expr_parent): Report an error if
2665 parent is a dynamic varobj.
2666
2667 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2668
2669 * gnulib/aclocal.m4: Re-generate.
2670 * gnulib/config.in: Re-generate.
2671 * gnulib/configure: Re-generate.
2672 * gnulib/import/Makefile.in: Re-generate.
2673 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2674 * gnulib/import/m4/onceonly.m4: Re-generate.
2675
2676 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2677
2678 * target-descriptions.c (struct xml_test_tdesc): New.
2679 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2680 (record_xml_tdesc): Update.
2681 (maintenance_check_xml_descriptions): Update.
2682 * target-descriptions.h (record_xml_tdesc): Update comment.
2683
2684 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2685
2686 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2687 checking array bounds are defined.
2688
2689 2018-07-30 Tom Tromey <tom@tromey.com>
2690
2691 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2692 irreflexivity violation.
2693
2694 2018-07-30 Tom Tromey <tom@tromey.com>
2695
2696 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2697 * value.c (unpack_long): Remove lint code.
2698 * valops.c (value_ind): Remove lint code.
2699 * valarith.c (value_x_binop, value_x_unop, value_equal)
2700 (value_pos): Remove lint code.
2701
2702 2018-07-28 Tom de Vries <tdevries@suse.de>
2703
2704 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2705 with undefined upper bound as <optimized out>.
2706
2707 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2708
2709 * gcore.in: Rename variable "name" to "prefix". Expand
2710 "usage" text.
2711
2712 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2713
2714 * windows-nat.c (windows_nat_target::create_inferior): Update to
2715 call close() in global namespace.
2716
2717 2018-07-26 Tom Tromey <tom@tromey.com>
2718
2719 * dwarf-index-write.c (add_address_entry): Don't add objfile
2720 offsets.
2721 * dbxread.c (find_stab_function): Rename from
2722 find_stab_function_addr. Return a bound_minimal_symbol.
2723 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2724 Don't add objfile offsets.
2725 (end_psymtab): Use raw_text_low, raw_text_high,
2726 MSYMBOL_VALUE_RAW_ADDRESS.
2727 (read_ofile_symtab): Update.
2728 (process_one_symbol): Update.
2729 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2730 offsets.
2731 (dw2_relocate): Remove.
2732 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2733 searching addrmap.
2734 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2735 Update.
2736 (process_psymtab_comp_unit_reader, add_partial_symbol)
2737 (add_partial_subprogram, dwarf2_ranges_read): Update.
2738 (load_partial_dies): Update.
2739 (add_address_entry): Don't add objfile offsets.
2740 (dwarf2_build_include_psymtabs): Update.
2741 (create_addrmap_from_aranges): Don't add objfile offsets.
2742 (dw2_find_pc_sect_compunit_symtab): Update.
2743 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2744 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2745 Update.
2746 (parse_partial_symbols): Don't add objfile offsets. Use
2747 raw_text_low, raw_text_high. Update.
2748 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2749 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2750 or call 'relocate' quick function. Clear psymbol_map.
2751 * psympriv.h (struct partial_symbol) <address>: Add section
2752 offset.
2753 <set_unrelocated_address>: Rename from set_address.
2754 <raw_text_low, raw_text_high>: New methods.
2755 <text_low, text_high>: Add objfile parameter.
2756 (add_psymbol_to_bcache): Add 'section' parameter. Call
2757 set_unrelocated_address.
2758 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2759 (find_pc_psymbol): Update.
2760 (fixup_psymbol_section, relocate_psymtabs): Remove.
2761 (dump_psymtab, psym_functions): Update.
2762 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2763 parameter.
2764 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2765 (start_psymtab_common): Update.
2766 * symfile-debug.c (debug_qf_relocate): Remove.
2767 (debug_sym_quick_functions): Update.
2768 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2769 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2770 Update.
2771
2772 2018-07-26 Tom Tromey <tromey@redhat.com>
2773
2774 * dbxread.c (end_psymtab): Use text_high_valid and
2775 text_low_valid.
2776 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2777 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2778 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2779 Update comment.
2780 <text_low_valid, text_high_valid>: New fields.
2781 <set_text_low, set_text_high>: Update.
2782 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2783
2784 2018-07-26 Tom Tromey <tom@tromey.com>
2785
2786 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2787 Update.
2788 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2789 textlow and texthigh fields.
2790 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2791 Update.
2792 * mdebugread.c (parse_lines, parse_partial_symbols)
2793 (psymtab_to_symtab_1): Update.
2794 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2795 Rename fields. Update comment. Now private.
2796 <text_low, text_high, set_text_low, set_text_high>: New methods.
2797 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2798 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2799 (start_psymtab_common, maintenance_info_psymtabs)
2800 (maintenance_check_psymtabs): Update.
2801 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2802 texthigh fields.
2803 (scan_xcoff_symtab): Update.
2804
2805 2018-07-26 Tom Tromey <tromey@redhat.com>
2806
2807 * psympriv.h (struct partial_symbol) <unrelocated_address,
2808 address, set_address>: New methods.
2809 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2810 (fixup_psymbol_section, relocate_psymtabs): Update.
2811 (print_partial_symbols): Add 'objfile' parameter. Update.
2812 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2813 Update.
2814
2815 2018-07-26 Tom Tromey <tom@tromey.com>
2816
2817 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2818 (debug_names::write_psymbols): Update.
2819 * psympriv.h (struct partial_symbol): Derive from
2820 general_symbol_info.
2821 <obj_section>: New method.
2822 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2823 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2824 (find_pc_sect_psymbol, fixup_psymbol_section)
2825 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2826 (print_partial_symbols, recursively_search_psymtabs)
2827 (compare_psymbols, psymbol_hash, psymbol_compare)
2828 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2829 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2830
2831 2018-07-26 Tom Tromey <tromey@redhat.com>
2832
2833 * dbxread.c (end_psymtab): Remove dead code.
2834
2835 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2836
2837 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2838 DWARF unwinders are disabled.
2839 * dwarf2-frame.c: Add dwarf2read.h include.
2840 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2841 disabled.
2842 (dwarf2_frame_unwinders_enabled_p): Define.
2843 (show_dwarf_unwinders_enabled_p): New function.
2844 (_initialize_dwarf2_frame): Register switch to control DWARF
2845 unwinder use.
2846 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2847 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2848 (show_dwarf_cmdlist): Remove static keyword.
2849 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2850 (show_dwarf_cmdlist): Declare.
2851 * NEWS: Document new feature.
2852
2853 2018-07-26 Tom de Vries <tdevries@suse.de>
2854
2855 PR breakpoints/23366
2856 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2857
2858 2018-07-26 Tom de Vries <tdevries@suse.de>
2859
2860 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2861 DW_AT_count can't be translated to a dynamic prop.
2862
2863 2018-07-25 Tom de Vries <tdevries@suse.de>
2864
2865 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2866 try/catch.
2867
2868 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2869
2870 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2871
2872 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2873
2874 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2875
2876 2018-07-24 Keith Seitz <keiths@redhat.comt
2877
2878 PR symtab/23010
2879 * dwarf2read.c (dw2_add_symbol_to_list): New function.
2880 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
2881 instead of add_symbol_to_list.
2882 (read_file_scope): Call prepare_one_comp_unit before reading
2883 any other DIEs.
2884
2885 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
2886
2887 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
2888
2889 2018-07-24 Tom Tromey <tom@tromey.com>
2890
2891 * utils.c (malloc, realloc, free): Don't declare.
2892 * configure, config.in: Rebuild.
2893 * configure.ac: Don't check for declarations of free, malloc, or
2894 realloc.
2895
2896 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2897
2898 * aarch64-linux-nat.c
2899 (aarch64_linux_nat_target::stopped_data_address): Remove unused
2900 variable.
2901 * arm-linux-nat.c (fetch_regs): Likewise.
2902 (store_regs): Likewise.
2903 (fetch_vfp_regs): Likewise.
2904 (store_vfp_regs): Likewise.
2905 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
2906 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
2907 (arm_linux_nat_target::insert_watchpoint): Likewise.
2908 (arm_linux_nat_target::remove_watchpoint): Likewise.
2909 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
2910 Likewise.
2911 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
2912 Likewise.
2913 * ppc-linux-nat.c (fetch_register): Likewise.
2914 (fetch_all_gp_regs): Likewise.
2915 (fetch_ppc_registers): Likewise.
2916 (store_all_gp_regs): Likewise.
2917 (store_ppc_registers): Likewise.
2918 (hwdebug_insert_point): Likewise.
2919 (can_use_watchpoint_cond_accel): Likewise.
2920 * remote-sim.c (gdb_os_write_stdout): Likewise.
2921
2922 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2923 Tom Tromey <tom@tromey.com>
2924
2925 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
2926 test for it.
2927 * configure: Rebuild.
2928
2929 2018-07-22 Tom Tromey <tom@tromey.com>
2930
2931 * regformats/regdat.sh: Define xmltarget_${name} inside
2932 #ifndef IN_PROCESS_AGENT.
2933
2934 2018-07-22 Tom Tromey <tom@tromey.com>
2935
2936 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
2937
2938 2018-07-22 Tom Tromey <tom@tromey.com>
2939
2940 * symfile.c (reread_symbols): Notify iter, not objfile.
2941
2942 2018-07-22 Tom Tromey <tom@tromey.com>
2943
2944 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
2945 Use arch_ops.
2946 (ravenscar_thread_target::prepare_to_store): Likewise.
2947
2948 2018-07-22 Tom Tromey <tom@tromey.com>
2949
2950 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
2951 unused variable. Call value_fetch_lazy when needed.
2952 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
2953 Remove unused variable. Call value_fetch_lazy when needed.
2954
2955 2018-07-22 Tom Tromey <tom@tromey.com>
2956
2957 * m32c-tdep.c (mark_dma): Return void.
2958 (make_regs): Remove unused declarations.
2959
2960 2018-07-22 Tom Tromey <tom@tromey.com>
2961
2962 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
2963 cmdscm_get_valid_command_smob_arg_unsafe for effect.
2964 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
2965 bkscm_get_valid_block_smob_arg_unsafe for effect.
2966
2967 2018-07-22 Tom Tromey <tom@tromey.com>
2968
2969 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
2970 value_type.
2971
2972 2018-07-22 Tom Tromey <tom@tromey.com>
2973
2974 * windows-nat.c (saved_context): Conditionally define.
2975 * remote.c (remote_target::remote_btrace_maybe_reopen):
2976 Conditionally declare "warned".
2977 * inflow.c (sigquit_ours): Conditionally define.
2978 (new_tty): Move "tty" declaration inside #if.
2979 * guile/guile.c (guile_datadir): Conditionally define.
2980 * charset.c (set_be_le_names): Move some declarations inside #if.
2981 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
2982 #if.
2983 (parse_xml_btrace_conf): Likewise.
2984
2985 2018-07-22 Tom Tromey <tom@tromey.com>
2986
2987 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
2988
2989 2018-07-22 Tom Tromey <tom@tromey.com>
2990
2991 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
2992 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
2993 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
2994 * buildsym-legacy.c (get_macro_table): Remove unused variable.
2995 * stack.c (frame_apply_level_command): Remove unused variable.
2996 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
2997 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
2998 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
2999 unused variable.
3000 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
3001 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
3002 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
3003 variable.
3004 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
3005 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
3006 variable.
3007 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
3008 Remove unused variable.
3009 * cli/cli-script.c (recurse_read_control_structure): Remove unused
3010 variable.
3011 * common/tdesc.c (print_xml_feature::visit): Remove unused
3012 variable.
3013 * compile/compile-object-load.c (store_regs): Remove unused
3014 variables.
3015 * complaints.c (clear_complaints): Remove unused variable.
3016 * corelow.c (core_target_open): Remove unused variable.
3017 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
3018 variable.
3019 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
3020 variable.
3021 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
3022 variable.
3023 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
3024 variable.
3025 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
3026 variable.
3027 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
3028 variable.
3029 * ia64-tdep.c (examine_prologue): Remove unused variable.
3030 * infcall.c (run_inferior_call): Remove unused variable.
3031 * inferior.c (exit_inferior): Remove unused variable.
3032 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
3033 * linespec.c (decode_line_2): Remove unused variable.
3034 * linux-nat.c (super_close): Remove.
3035 * linux-tdep.c (linux_info_proc): Remove unused variable.
3036 * mi/mi-main.c (mi_execute_command): Remove unused variable.
3037 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
3038 Remove unused variable.
3039 * parse.c (find_minsym_type_and_address): Remove unused variable.
3040 * printcmd.c (info_symbol_command, printf_floating): Remove unused
3041 variable.
3042 * python/py-breakpoint.c (bppy_set_commands): Remove unused
3043 variable.
3044 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
3045 variables.
3046 * record-btrace.c (record_btrace_target::store_registers): Remove
3047 unused variable.
3048 (cmd_show_record_btrace_cpu): Remove unused variable.
3049 * riscv-tdep.c (riscv_register_reggroup_p)
3050 (riscv_push_dummy_call, riscv_return_value): Remove unused
3051 variable.
3052 * rust-exp.y (literal): Remove unused variable.
3053 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
3054 unused variable.
3055 <STRUCTOP_ANONYMOUS>: Likewise.
3056 * s390-linux-tdep.c (s390_linux_init_abi_31)
3057 (s390_linux_init_abi_64): Remove unused variable.
3058 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
3059 (file_select_thread, net_windows_open, _initialize_ser_windows):
3060 Remove unused variables.
3061 * symtab.c (find_pc_sect_line): Remove unused variable.
3062 * target-memory.c (compute_garbled_blocks): Remove unused
3063 variable.
3064 (target_write_memory_blocks): Remove unused variable.
3065 * target.c (target_stack::unpush): Remove unused variables.
3066 * tracepoint.c (start_tracing, all_tracepoint_actions)
3067 (merge_uploaded_trace_state_variables)
3068 (print_one_static_tracepoint_marker): Remove unused variable.
3069 * unittests/basic_string_view/element_access/char/1.cc (test01):
3070 Remove unused variable.
3071 * windows-nat.c (windows_continue, windows_add_all_dlls)
3072 (do_initial_windows_stuff, windows_nat_target::create_inferior):
3073 Remove unused variables.
3074
3075 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
3076
3077 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
3078 attr_profile in HAVE_ELF.
3079 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
3080 HAVE_ELF.
3081
3082 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
3083
3084 * frame.c (frame_register_unwind): Change parameter name.
3085 (frame_unwind_register): Likewise.
3086 (frame_unwind_register_value): Likewise.
3087 (frame_unwind_register_signed): Likewise.
3088 (frame_unwind_register_unsigned): Likewise.
3089 * frame.h (frame_register_unwind): Likewise.
3090 (frame_unwind_register): Likewise.
3091 (frame_unwind_register_value): Likewise.
3092 (frame_unwind_register_signed): Likewise.
3093 (frame_unwind_register_unsigned): Likewise.
3094 (frame_unwind_arch): Likewise.
3095
3096 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3097
3098 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3099 ISA maintenance.
3100
3101 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3102
3103 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3104 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3105 hand.
3106
3107 2018-07-20 Keith Seitz <keiths@redhat.com>
3108
3109 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3110 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3111 m_compunit_symtab, m_language>: Add "m_" prefix.
3112 Update all uses.
3113 * buildsym.c: Update all uses.
3114
3115 2018-07-20 Tom Tromey <tom@tromey.com>
3116
3117 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3118 * buildsym.h (record_line_ftype): Remove typedef.
3119
3120 2018-07-20 Tom Tromey <tom@tromey.com>
3121
3122 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3123 (end_expandable_symtab): Likewise.
3124 (end_symtab_get_static_block): Likewise.
3125 (end_symtab_from_static_block): Likewise.
3126 * buildsym-legacy.c (augment_type_symtab): Remove.
3127 (end_expandable_symtab): Remove.
3128 (end_symtab_get_static_block): Remove.
3129 (end_symtab_from_static_block): Remove.
3130
3131 2018-07-20 Tom Tromey <tom@tromey.com>
3132
3133 * dwarf2read.c: Include buildsym.h.
3134 (struct dwarf2_cu) <builder>: New method.
3135 (fixup_go_packaging): Update.
3136 (process_full_comp_unit, process_full_type_unit): Update. Don't
3137 use scoped_free_pendings.
3138 (using_directives): Add "cu" parameter, remove "language".
3139 (read_import_statement, setup_type_unit_groups, )
3140 (read_func_scope, read_lexical_block_scope)
3141 (dwarf2_record_block_ranges, read_namespace): Update.
3142 (lnp_state_machine::lnp_state_machine): Add cu parameter.
3143 (lnp_state_machine::handle_end_sequence): Update.
3144 (class lnp_state_machine) <m_cu>: New member.
3145 <m_record_line_callback>: Remove.
3146 <m_currently_recording_lines>: New member.
3147 (lnp_state_machine::handle_set_file): Update.
3148 (noop_record_line): Remove.
3149 (dwarf_record_line_p): Add cu parameter.
3150 (dwarf_record_line_1, dwarf_finish_line): Likewise.
3151 (lnp_state_machine::record_line)
3152 (lnp_state_machine::lnp_state_machine)
3153 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3154 (dwarf_decode_lines): Update.
3155 (dwarf2_start_subfile): Add cu parameter.
3156 (dwarf2_start_symtab, new_symbol): Update.
3157 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
3158 Remove dwarf2_per_objfile parameter.
3159 (dwarf_decode_macros): Update.
3160
3161 2018-07-20 Tom Tromey <tom@tromey.com>
3162
3163 * stabsread.c (define_symbol): Update.
3164 * buildsym-legacy.h (get_buildsym_compunit): Declare.
3165 * dwarf2read.c (new_symbol): Update.
3166 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
3167 * cp-namespace.c: Include buildsym.h.
3168 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
3169 * buildsym-legacy.c (get_buildsym_compunit): New function.
3170
3171 2018-07-20 Tom Tromey <tom@tromey.com>
3172
3173 * xcoffread.c: Include buildsym-legacy.h.
3174 * windows-nat.c: Include buildsym-legacy.h.
3175 * stabsread.c: Include buildsym-legacy.h.
3176 * mdebugread.c: Include buildsym-legacy.h.
3177 * buildsym-legacy.h: New file.
3178 * buildsym-legacy.c: New file, from buildsym.c.
3179 * go32-nat.c: Include buildsym-legacy.h.
3180 * dwarf2read.c: Include buildsym-legacy.h.
3181 * dbxread.c: Include buildsym-legacy.h.
3182 * cp-namespace.c: Include buildsym-legacy.h.
3183 * coffread.c: Include buildsym-legacy.h.
3184 * buildsym.h: Move some contents to buildsym-legacy.h.
3185 * buildsym.c: Include buildsym-legacy.h. Move many functions to
3186 buildsym-legacy.c.
3187 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
3188
3189 2018-07-20 Tom Tromey <tom@tromey.com>
3190
3191 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
3192 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
3193 (buildsym_compunit::buildsym_compunit)
3194 (buildsym_compunit::~buildsym_compunit)
3195 (buildsym_compunit::get_macro_table): Define.
3196
3197 2018-07-20 Tom Tromey <tom@tromey.com>
3198
3199 * buildsym.c (reset_symtab_globals): Remove.
3200 (buildsym_compunit::end_symtab_from_static_block): Update.
3201 (buildsym_compunit::augment_type_symtab): Update.
3202 (end_symtab_from_static_block): Call free_buildsym_compunit.
3203 (augment_type_symtab, end_symtab, end_expandable_symtab):
3204 Likewise.
3205
3206 2018-07-20 Tom Tromey <tom@tromey.com>
3207
3208 * arch-utils.c: Do not include buildsym.h.
3209 * mipsread.c: Do not include buildsym.h.
3210 * machoread.c: Do not include buildsym.h.
3211 * elfread.c: Do not include buildsym.h.
3212
3213 2018-07-20 Tom Tromey <tom@tromey.com>
3214
3215 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
3216 initialization.
3217 (buildsym_compunit): Add new constructor.
3218 (struct buildsym_compunit) <get_last_source_file, finish_block,
3219 record_block_range, start_subfile, patch_subfile_names,
3220 push_subfile, pop_subfile, record_line, get_compunit_symtab,
3221 set_last_source_start_addr, get_last_source_start_addr,
3222 get_local_using_directives, set_local_using_directives,
3223 get_global_using_directives, outermost_context_p,
3224 get_current_context_stack, get_context_stack_depth,
3225 get_current_subfile, get_local_symbols, get_file_symbols,
3226 get_global_symbols, record_debugformat, record_producer,
3227 push_context, pop_context, end_symtab_get_static_block,
3228 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
3229 New public methods.
3230 <record_pending_block, finish_block_internal, make_blockvector,
3231 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
3232 private methods.
3233 Update all users.
3234
3235 2018-05-22 Tom Tromey <tom@tromey.com>
3236
3237 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3238 parameter.
3239 (finish_block_internal): Update.
3240
3241 2018-07-20 Tom Tromey <tom@tromey.com>
3242
3243 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3244 parameter.
3245 (finish_block_internal): Update.
3246
3247 2018-07-20 Tom Tromey <tom@tromey.com>
3248
3249 * buildsym.h (EXTERN): Don't define or undef.
3250 * buildsym.c (EXTERN): Don't define.
3251
3252 2018-07-20 Tom Tromey <tom@tromey.com>
3253
3254 * buildsym.c: Remove TODO comment.
3255
3256 2018-07-20 Tom Tromey <tom@tromey.com>
3257
3258 * coffread.c (coff_symtab_read): Update.
3259 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3260 (xcoff_new_init): Update.
3261 * mipsread.c (mipscoff_new_init): Update.
3262 * mdebugread.c (mdebug_build_psymtabs): Update.
3263 * elfread.c (elf_new_init): Update.
3264 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3265 Update.
3266 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
3267 (coffstab_build_psymtabs, elfstab_build_psymtabs)
3268 (stabsect_build_psymtabs): Update.
3269 * buildsym.h (buildsym_init): Don't declare.
3270 * buildsym.c: Update comment.
3271 (prepare_for_building): Remove.
3272 (start_symtab, restart_symtab): Update.
3273 (reset_symtab_globals): Update comment.
3274 (buildsym_init): Remove.
3275
3276 2018-07-20 Tom Tromey <tom@tromey.com>
3277
3278 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
3279 * stabsread.c (patch_block_stabs, define_symbol, read_type)
3280 (read_enum_type, common_block_start, common_block_end)
3281 (cleanup_undefined_types_1, finish_global_stabs): Update.
3282 * mdebugread.c (psymtab_to_symtab_1): Update.
3283 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3284 (read_lexical_block_scope, new_symbol): Update.
3285 * dbxread.c (process_one_symbol): Update.
3286 * coffread.c (coff_symtab_read, process_coff_symbol)
3287 (coff_read_enum_type): Update.
3288 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3289 declare.
3290 (get_local_symbols, get_file_symbols, get_global_symbols): New
3291 functions.
3292 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3293 m_global_symbols.
3294 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3295 (~scoped_free_pendings): Update.
3296 (finish_block, prepare_for_building, reset_symtab_globals)
3297 (end_symtab_get_static_block, end_symtab_with_blockvector)
3298 (augment_type_symtab, push_context): Update.
3299 (get_local_symbols, get_file_symbols, get_global_symbols): New
3300 functions.
3301 (buildsym_init): Update.
3302
3303 2018-07-20 Tom Tromey <tom@tromey.com>
3304
3305 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3306 (process_full_type_unit): Likewise.
3307 (dwarf2_start_symtab): Set list_in_scope.
3308
3309 2018-07-20 Tom Tromey <tom@tromey.com>
3310
3311 * dwarf2read.c (process_psymtab_comp_unit_reader)
3312 (build_type_psymtabs_reader): Do not set list_in_scope.
3313
3314 2018-07-20 Tom Tromey <tom@tromey.com>
3315
3316 * buildsym.c (free_pendings): Remove.
3317 (add_symbol_to_list, scoped_free_pendings)
3318 (finish_block_internal, buildsym_init): Update.
3319
3320 2018-07-20 Tom Tromey <tom@tromey.com>
3321
3322 * xcoffread.c (read_xcoff_symtab): Update.
3323 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3324 Update.
3325 * dbxread.c (process_one_symbol): Update.
3326 * coffread.c (coff_symtab_read): Update.
3327 * buildsym.h (finish_block): Update.
3328 * buildsym.c (finish_block): Remove "listhead" argument.
3329 (end_symtab_get_static_block): Update.
3330
3331 2018-07-20 Tom Tromey <tom@tromey.com>
3332
3333 * buildsym.h (class scoped_free_pendings): Remove constructor.
3334 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3335 method.
3336 <m_pending_block_obstack, m_pending_blocks>: New members.
3337 (pending_block_obstack, pending_blocks): Remove.
3338 (scoped_free_pendings::scoped_free_pendings): Default.
3339 (~scoped_free_pendings): Update.
3340 (free_pending_blocks): Remove.
3341 (finish_block_internal, record_pending_block, make_blockvector)
3342 (end_symtab_get_static_block, augment_type_symtab, push_context)
3343 (buildsym_init): Update.
3344
3345 2018-07-20 Tom Tromey <tom@tromey.com>
3346
3347 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3348 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3349 members.
3350 (pending_addrmap, pending_addrmap_obstack)
3351 (pending_addrmap_interesting): Remove.
3352 (scoped_free_pendings, record_block_range, make_blockvector)
3353 (prepare_for_building, reset_symtab_globals, buildsym_init):
3354 Update.
3355
3356 2018-07-20 Tom Tromey <tom@tromey.com>
3357
3358 * xcoffread.c (process_linenos): Update.
3359 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3360 * mdebugread.c (psymtab_to_symtab_1): Update.
3361 * dwarf2read.c (setup_type_unit_groups)
3362 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3363 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3364 * dbxread.c (process_one_symbol): Update.
3365 * coffread.c (coff_symtab_read, enter_linenos)
3366 (process_coff_symbol): Update.
3367 * buildsym.h (current_subfile): Don't declare.
3368 (get_current_subfile): Declare.
3369 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3370 member.
3371 (start_subfile, free_buildsym_compunit, push_subfile)
3372 (prepare_for_building, start_symtab): Update.
3373 (get_current_subfile): New function.
3374
3375 2018-07-20 Tom Tromey <tom@tromey.com>
3376
3377 * coffread.c (coff_symtab_read): Update.
3378 * xcoffread.c (read_xcoff_symtab): Update.
3379 * dwarf2read.c (new_symbol): Update.
3380 (read_func_scope, read_lexical_block_scope): Update.
3381 * dbxread.c (process_one_symbol): Update.
3382 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3383 (outermost_context_p): Remove macro.
3384 (outermost_context_p, get_current_context_stack)
3385 (get_context_stack_depth): Declare.
3386 (pop_context): Return struct context_stack.
3387 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3388 member.
3389 (context_stack_size): Remove.
3390 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3391 (prepare_for_building, end_symtab_get_static_block)
3392 (augment_type_symtab, push_context): Update.
3393 (pop_context): Return struct context_stack.
3394 (outermost_context_p, get_current_context_stack)
3395 (get_context_stack_depth): New functions.
3396 (buildsym_init): Update.
3397
3398 2018-07-20 Tom Tromey <tom@tromey.com>
3399
3400 * rust-exp.y: Now a pure parser. Update all rules.
3401 (%union): Move earlier.
3402 (current_parser, work_obstack): Remove globals.
3403 (rust_parser, ~rust_parser): Update.
3404 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3405 lex_character, lex_number, lex_string, lex_identifier,
3406 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3407 convert_name, convert_params_to_expression,
3408 convert_ast_to_expression, ast_basic_type, ast_operation,
3409 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3410 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3411 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3412 ast_array_type, ast_slice_type, ast_reference_type,
3413 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3414 (rust_parse): Update.
3415 (rustyyerror, rustyylex): Add parser parameter.
3416 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3417 (rust_lex_stringish_test, rust_lex_test_sequence)
3418 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3419 (rust_lex_test_push_back, rust_lex_tests): Update.
3420
3421 2018-07-19 Pedro Alves <palves@redhat.com>
3422
3423 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3424 gdb::unique_xmalloc_ptr.
3425 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3426 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3427 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3428 copy-initialization.
3429 * guile/scm-pretty-print.c (ppscm_print_children): Use
3430 gdb::unique_xmalloc_ptr instead of cleanups.
3431 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3432 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3433 gdb::unique_xmalloc_ptr.
3434 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3435 Adjust to use gdb::unique_xmalloc_ptr.
3436 * guile/scm-utils.c (extract_arg): Adjust.
3437 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3438 gdb::unique_xmalloc_ptr instead of a cleanup.
3439
3440 2018-07-19 Tom Tromey <tom@tromey.com>
3441
3442 * utils.c (do_value_free_to_mark)
3443 (make_cleanup_value_free_to_mark): Remove.
3444 * utils.h (make_cleanup_value_free_to_mark): Remove.
3445
3446 2018-07-19 Pedro Alves <palves@redhat.com>
3447
3448 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3449 forwarding reference.
3450
3451 2018-07-18 Pedro Alves <palves@redhat.com>
3452
3453 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3454 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3455 cleanup.
3456
3457 2018-07-18 Pedro Alves <palves@redhat.com>
3458
3459 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3460 exceptions.
3461 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3462 (gdbscm_wrap): New.
3463 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3464 directly instead of a cleanup.
3465 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3466 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3467 (vlscm_binop_gdbthrow): New, factored out from ...
3468 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3469 (vlscm_rich_compare): Use gdbscm_wrap.
3470 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3471 instead of a cleanup.
3472 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3473 cleanup.
3474 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3475 Use xfree directly instead of a cleanup.
3476 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3477 Adjust to use gdbscm_wrap and scoped_value_mark.
3478 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3479 (gdbscm_value_address, gdbscm_value_dereference)
3480 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3481 scoped_value_mark.
3482 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3483 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3484 scoped_value_mark.
3485 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3486 gdbscm_wrap and scoped_value_mark.
3487 (gdbscm_value_to_string): Use xfree directly instead of a
3488 cleanup. Move 'buffer' unique_ptr to TRY scope.
3489 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3490 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3491 scoped_value_mark.
3492 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3493 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3494 scoped_value_mark.
3495 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3496 gdbscm_wrap.
3497
3498 2018-07-18 Tom de Vries <tdevries@suse.de>
3499
3500 * findvar.c (default_read_var_value): Also resolve dynamic type for
3501 LOC_OPTIMIZED_OUT vars.
3502
3503 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3504
3505 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3506 decoding.
3507
3508 2018-07-17 Tom Tromey <tom@tromey.com>
3509
3510 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3511 (compute_enum_list, pascm_set_param_value_x)
3512 (gdbscm_parameter_value): Update.
3513 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3514 (gdbscm_scm_to_host_string): Update.
3515 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3516 Update.
3517 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3518 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3519 * guile/scm-string.c (gdbscm_scm_to_string): Return
3520 unique_xmalloc_ptr.
3521 (gdbscm_scm_to_host_string): Likewise.
3522
3523 2018-07-17 Tom Tromey <tom@tromey.com>
3524
3525 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3526 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3527 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3528 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3529 unique_xmalloc_ptr.
3530
3531 2018-07-17 Tom Tromey <tom@tromey.com>
3532
3533 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3534 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3535 Update.
3536 * guile/scm-cmd.c (cmdscm_function): Update.
3537 * guile/scm-pretty-print.c
3538 (ppscm_print_exception_unless_memory_error): Update.
3539 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3540 Return unique_xmalloc_ptr.
3541
3542 2018-07-17 Tom Tromey <tom@tromey.com>
3543
3544 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3545 Use string_printf.
3546
3547 2018-07-17 Jim Wilson <jimw@sifive.com>
3548
3549 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3550 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3551 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3552 unecessary braces after EF_RISCV_RVC test. Delete call to
3553 set_gdbarch_decr_pc_after_break.
3554
3555 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3556 RISCV_LAST_FP_REGNUM + 1.
3557 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3558
3559 2018-07-17 Tom Tromey <tom@tromey.com>
3560
3561 * configure.ac: Remove --disable-gdbcli.
3562 * configure: Rebuild.
3563 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3564 (SUBDIR_CLI_CFLAGS): Remove.
3565 (SFILES): Use SUBDIR_CLI_SRCS.
3566 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3567
3568 2018-07-17 Tom Tromey <tom@tromey.com>
3569
3570 PR gdb/18624:
3571 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3572
3573 2018-07-16 Jim Wilson <jimw@sifive.com>
3574
3575 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3576
3577 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3578
3579 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3580 variable.
3581 (libunwind_frame_sniffer): Likewise.
3582 (libunwind_frame_prev_register): Likewise.
3583 (libunwind_sigtramp_frame_sniffer): Likewise.
3584 * ia64-tdep.c (ia64_access_reg): Likewise.
3585 (ia64_access_rse_reg): Likewise.
3586 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3587 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3588
3589 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3590
3591 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3592
3593 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3594
3595 * remote-sim.c (gdbsim_target::close,
3596 gdbsim_target::mourn_inferior): Remove unused variables.
3597
3598 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3599
3600 * ia64-tdep.c (ktab_buf): New global.
3601 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3602 (get_kernel_table): Adjust.
3603
3604 2018-07-16 Tom Tromey <tom@tromey.com>
3605
3606 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3607 * dwarf2read.c (using_directives, new_symbol): Use
3608 outermost_context_p.
3609 * dbxread.c (process_one_symbol): Use outermost_context_p.
3610 * coffread.c (coff_symtab_read): Use outermost_context_p.
3611
3612 2018-07-16 Tom Tromey <tom@tromey.com>
3613
3614 * dwarf2read.c (using_directives, read_func_scope)
3615 (read_lexical_block_scope): Update.
3616 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3617 * buildsym.h (local_using_directives, global_using_directives):
3618 Don't declare.
3619 (get_local_using_directives, set_local_using_directives)
3620 (get_global_using_directives): Declare.
3621 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3622 m_global_using_directives>: New members.
3623 (finish_block_internal, prepare_for_building)
3624 (reset_symtab_globals, end_symtab_get_static_block)
3625 (push_context): Update.
3626 (get_local_using_directives, set_local_using_directives)
3627 (get_global_using_directives): New functions.
3628 (buildsym_init): Update.
3629
3630 2018-07-16 Tom Tromey <tom@tromey.com>
3631
3632 * xcoffread.c (xcoff_initial_scan): Don't call
3633 free_pending_blocks.
3634 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3635 * buildsym.h (class scoped_free_pendings): Add constructor.
3636 (free_pending_blocks): Don't declare.
3637 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3638 (free_pending_blocks): Now static.
3639
3640 2018-07-16 Tom Tromey <tom@tromey.com>
3641
3642 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3643 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3644 member.
3645 (struct subfile_stack): Remove.
3646 (subfile_stack): Remove.
3647 (push_subfile, pop_subfile, buildsym_init): Update.
3648
3649 2018-07-16 Tom Tromey <tom@tromey.com>
3650
3651 * buildsym.c (push_subfile): Use gdb_assert.
3652 (pop_subfile): Use gdb_assert.
3653
3654 2018-07-16 Tom Tromey <tom@tromey.com>
3655
3656 * buildsym.h (merge_symbol_lists): Remove.
3657 * buildsym.c (merge_symbol_lists): Remove.
3658
3659 2018-07-16 Tom Tromey <tom@tromey.com>
3660
3661 * stabsread.c (scan_file_globals): Update comment.
3662 * stabsread.h (scan_file_globals): Move from buildsym.h.
3663 * buildsym.h (scan_file_globals): Move to stabsread.h.
3664
3665 2018-07-16 Tom Tromey <tom@tromey.com>
3666
3667 * xcoffread.c (xcoff_new_init): Update.
3668 * mipsread.c (mipscoff_new_init): Update.
3669 * mdebugread.c (mdebug_build_psymtabs): Update.
3670 * elfread.c (elf_new_init): Update.
3671 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3672 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3673 * buildsym.h (buildsym_new_init): Don't declare.
3674 * buildsym.c (buildsym_new_init): Remove.
3675
3676 2018-07-16 Tom Tromey <tom@tromey.com>
3677
3678 * stabsread.h (within_function): Move from buildsym.h.
3679 * stabsread.c (start_stabs): Clear within_function.
3680 * coffread.c (coff_start_symtab): Clear within_function.
3681 * buildsym.h (within_function): Move to stabsread.h.
3682 * buildsym.c (prepare_for_building): Update.
3683
3684 2018-07-16 Tom Tromey <tom@tromey.com>
3685
3686 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3687 * dwarf2read.c (dwarf2_start_symtab): Don't set
3688 processing_gcc_compilation.
3689 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3690
3691 2018-07-16 Tom Tromey <tom@tromey.com>
3692
3693 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3694 (next_symbol_text_func): Move from buildsym.h.
3695 * stabsread.c (hashname): Move from buildsym.c.
3696 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3697 (next_symbol_text_func, hashname): Move to stabsread.h.
3698 * buildsym.c: Don't include bcache.h
3699 (hashname): Move to stasbread.c.
3700
3701 2018-07-16 Tom Tromey <tom@tromey.com>
3702
3703 * buildsym.h (context_stack_size): Don't declare.
3704 * buildsym.c (context_stack_size): New global.
3705
3706 2018-07-16 Tom Tromey <tom@tromey.com>
3707
3708 * dbxread.c (processing_acc_compilation): New global.
3709 * buildsym.h (processing_acc_compilation): Don't declare.
3710
3711 2018-07-16 Tom Tromey <tom@tromey.com>
3712
3713 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3714 * dbxread.c (read_ofile_symtab): Update.
3715 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3716 * buildsym.h (last_source_start_addr): Remove.
3717 (set_last_source_start_addr, get_last_source_start_addr):
3718 Declare.
3719 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3720 parameter.
3721 (struct buildsym_compunit) <m_last_source_start_addr>: New
3722 member.
3723 (prepare_for_building): Remove start_addr parameter.
3724 (start_symtab, restart_symtab, end_symtab_get_static_block)
3725 (end_symtab_with_blockvector): Update.
3726 (set_last_source_start_addr, get_last_source_start_addr): New
3727 functions.
3728
3729 2018-07-16 Tom Tromey <tom@tromey.com>
3730
3731 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3732 member.
3733 (have_line_numbers): Remove.
3734 (record_line, prepare_for_building, end_symtab_get_static_block)
3735 (augment_type_symtab): Update.
3736
3737 2018-07-16 Tom Tromey <tom@tromey.com>
3738
3739 * buildsym.c (~buildsym_compunit): Free the macro table.
3740 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3741 methods.
3742 <m_pending_macros>: New member.
3743 (pending_macros): Remove.
3744 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3745 (reset_symtab_globals, end_symtab_get_static_block)
3746 (end_symtab_with_blockvector, augment_type_symtab)
3747 (buildsym_init): Update.
3748
3749 2018-07-16 Tom Tromey <tom@tromey.com>
3750
3751 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3752 parameter.
3753 (buildsym_compunit::set_last_source_file): New method.
3754 <m_last_source_file>: New member.
3755 (prepare_for_building): Remove "name" parameter.
3756 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3757 (last_source_file): Remove.
3758 (set_last_source_file, get_last_source_file): Update.
3759
3760 2018-07-16 Tom Tromey <tom@tromey.com>
3761
3762 * buildsym.c (prepare_for_building): Add assert.
3763
3764 2018-07-16 Tom Tromey <tom@tromey.com>
3765
3766 * buildsym.c (~buildsym_compunit): Update.
3767 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3768 (start_subfile, patch_subfile_names)
3769 (end_symtab_with_blockvector): Update.
3770
3771 2018-07-16 Tom Tromey <tom@tromey.com>
3772
3773 * buildsym.c (struct buildsym_compunit): Add constructor,
3774 destructor, initializers.
3775 (start_buildsym_compunit): Remove.
3776 (free_buildsym_compunit): Use "delete".
3777 (start_symtab, restart_symtab): Use "new".
3778
3779 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3780
3781 * symfile.c (set_objfile_default_section_offset): Remove struct
3782 keyword.
3783
3784 2018-07-14 Stafford Horne <shorne@gmail.com>
3785
3786 * (Responsible Maintainers): Add myself as or1k maintainer.
3787
3788 2018-07-13 Tom Tromey <tom@tromey.com>
3789
3790 * symfile.c (set_objfile_default_section_offset): Use extra braces
3791 around initializer.
3792
3793 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3794
3795 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3796 non-branching basr.
3797
3798 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3799
3800 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3801 unittests/cli-utils-selftests.c
3802 * unittests/cli-utils-selftests.c: New file.
3803
3804 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3805
3806 * NEWS: Mention new commands. Mention change to 'thread apply'.
3807
3808 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3809
3810 * thread.c (thr_try_catch_cmd): New function.
3811 (thread_apply_all_command): Handle qcs flags.
3812 (thread_apply_command): Handle qcs flags.
3813 (taas_command): New function.
3814 (tfaas_command): New function.
3815 (_initialize_thread): Update to setup the new commands 'taas
3816 and 'tfaas'. Change doc string for 'thread apply'.
3817
3818 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3819
3820 * stack.c: (trailing_outermost_frame): New function, mostly
3821 extracted from backtrace_command_1.
3822 (leading_innermost_frame): New function.
3823 (backtrace_command_1): Update to call trailing_outermost_frame.
3824 (frame_apply_command_count): New function.
3825 (frame_apply_level_command): New function.
3826 (frame_apply_all_command): New function.
3827 (frame_apply_command): New function.
3828 (faas_command): New function.
3829 (frame_cmd_list): New variable.
3830 (_initialize_stack): Update to setup the new commands 'frame apply'
3831 and 'faas'.
3832
3833 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3834
3835 * cli-utils.c (number_or_range_parser::get_number): Only handle
3836 numbers or convenience var as numbers.
3837 (parse_flags): New function.
3838 (parse_flags_qcs): New function.
3839 (number_or_range_parser::finished): Ensure parsing end is detected
3840 before end of string.
3841 * cli-utils.h (parse_flags): New function.
3842 (parse_flags_qcs): New function.
3843 (number_or_range_parser): Remove m_finished bool.
3844 (number_or_range_parser::skip_range): Set m_in_range to false.
3845
3846 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3847
3848 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3849 on Windows.
3850
3851 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3852 Jan Kratochvil <jan.kratochvil@redhat.com>
3853 Paul Fertser <fercerpav@gmail.com>
3854 Tsutomu Seki <sekiriki@gmail.com>
3855 Pedro Alves <palves@redhat.com>
3856
3857 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3858 'unittests/parse-connection-spec-selftests.c'.
3859 (COMMON_SFILES): Add 'common/netstuff.c'.
3860 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3861 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3862 * common/netstuff.c: New file.
3863 * common/netstuff.h: New file.
3864 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3865 (wait_for_connect): Update comment. New parameter
3866 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3867 Use 'sock' directly instead of 'scb->fd'.
3868 (try_connect): New function, with code from 'net_open'.
3869 (net_open): Rewrite main loop to deal with multiple
3870 sockets/addresses. Handle IPv6-style hostnames; implement
3871 support for IPv6 connections.
3872 * unittests/parse-connection-spec-selftests.c: New file.
3873
3874 2018-07-11 Pedro Alves <palves@redhat.com>
3875
3876 PR gdb/23377
3877 * remote.c (remote_target::remote_detach_pid): Call
3878 set_current_process.
3879
3880 2018-07-11 Pedro Alves <palves@redhat.com>
3881
3882 * h8300-tdep.c (h8300_gdbarch_init): Remove
3883 set_gdbarch_ecoff_reg_to_regnum calls.
3884
3885 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3886
3887 PR c++/23373
3888 * c-typeprint.c (c_type_print_base_struct_union): Don't print
3889 offsets/sizes for static members of a class/struct.
3890
3891 2018-07-11 Alan Hayward <alan.hayward@arm.com>
3892
3893 * target-descriptions.c (tdesc_register_bitsize): Rename.
3894 * target-descriptions.h (tdesc_register_bitsize): Likewise.
3895 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
3896 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
3897
3898 2018-07-10 Tom Tromey <tom@tromey.com>
3899
3900 * breakpoint.c (moribund_locations): Now static and a
3901 std::vector.
3902 (breakpoint_init_inferior, moribund_breakpoint_here_p)
3903 (build_bpstat_chain, update_global_location_list)
3904 (breakpoint_retire_moribund): Update.
3905 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
3906 VEC.
3907
3908 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3909
3910 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
3911 (riscv_register_reggroup_p): Use new function, remove unneeded
3912 parenthesis.
3913 (riscv_push_dummy_call): Extend assert to compare against xlen or
3914 flen based on register type.
3915
3916 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
3917
3918 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
3919
3920 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
3921
3922 * remote.c (show_hardware_watchpoint_limit): New function.
3923 (show_hardware_watchpoint_length_limit): New function.
3924 (show_hardware_breakpoint_limit): New function.
3925 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
3926 where appropriate, update help text.
3927
3928 2018-07-09 Tom Tromey <tom@tromey.com>
3929
3930 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
3931 (CLIBS): Don't mention NAT_CLIBS.
3932
3933 2018-07-09 Tom Tromey <tom@tromey.com>
3934
3935 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
3936 (LIBGDB_OBS, clean mostlyclean): Update.
3937 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
3938
3939 2018-07-09 Tom Tromey <tom@tromey.com>
3940
3941 * Makefile.in (%.c: %.y): Use ECHO_YACC.
3942 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
3943 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
3944
3945 2018-07-09 Tom Tromey <tom@tromey.com>
3946
3947 * Makefile.in (ALLDEPFILES): Remove exec.c.
3948 (COMMON_OBS): Remove exec.o.
3949 (COMMON_SFILES): Add exec.c.
3950
3951 2018-07-09 Tom Tromey <tom@tromey.com>
3952
3953 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
3954
3955 2018-07-09 Tom Tromey <tom@tromey.com>
3956
3957 * Makefile.in (clean mostlyclean): Remove stamp-version.
3958 (version.c): Depend on stamp-version.
3959 (stamp-version): New rule, from version.c rule.
3960
3961 2018-07-09 Tom Tromey <tom@tromey.com>
3962
3963 * Makefile.in (init.c): Depend on stamp-init.
3964 (stamp-init): New rule, from init.c rule.
3965 (clean mostlyclean): Remove stamp-init.
3966
3967 2018-07-09 Tom Tromey <tom@tromey.com>
3968
3969 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
3970 SUBDIR_GCC_COMPILE_SRCS.
3971
3972 2018-07-09 Tom Tromey <tom@tromey.com>
3973
3974 * Makefile.in (init.c): Remove some unused sed rules.
3975
3976 2018-07-09 Tom Tromey <tom@tromey.com>
3977
3978 * Makefile.in (TSOBS): Remove.
3979 (INIT_FILES): Update.
3980 (LIBGDB_OBS): Update.
3981 (COMMON_SFILES): Add inflow.c.
3982 (SFILES): Remove inflow.c.
3983
3984 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
3985
3986 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
3987
3988 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
3989
3990 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
3991 get_saveloc_name, is_signal_frame_name, step_name,
3992 init_remote_name, create_addr_space_name,
3993 destroy_addr_space_name, search_unwind_table_name,
3994 find_dyn_list_name): Constify.
3995
3996 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
3997
3998 * darwin-nat.c (darwin_pthread_kill): New function.
3999 (darwin_resume_thread): Use darwin_pthread_kill.
4000
4001 2018-07-05 Tom de Vries <tdevries@suse.de>
4002
4003 * macroexp.c (macro_buffer) <operator=>: New member function.
4004
4005 2018-07-04 Tom Tromey <tom@tromey.com>
4006
4007 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
4008
4009 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
4010
4011 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
4012 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
4013 * maint.c: Likewise.
4014 * top.c: Likewise.
4015
4016 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4017
4018 * NEWS: Create a new section for the next release branch.
4019 Rename the section of the current branch, now that it has
4020 been cut.
4021
4022 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4023
4024 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
4025 * version.in: Bump version to 8.2.50.DATE-git.
4026
4027 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4028 Pedro Alves <palves@redhat.com>
4029
4030 * linux-nat.c (linux_init_ptrace): Rename to ...
4031 (linux_init_ptrace_procfs): ... this. Call
4032 linux_proc_init_warnings.
4033 (linux_nat_target::post_attach)
4034 (linux_nat_target::post_startup_inferior): Adjust.
4035 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
4036 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
4037
4038 2018-07-04 Tom de Vries <tdevries@suse.de>
4039
4040 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
4041 check ...
4042 (read_comp_unit_head): ... here.
4043
4044 2018-07-03 Tom Tromey <tom@tromey.com>
4045
4046 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
4047 (stop_tracing, tstatus_command)
4048 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
4049 (print_one_static_tracepoint_marker): Update.
4050 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
4051 std::vector.
4052 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
4053 VEC.
4054 (all_tracepoints, static_tracepoints_here): Return std::vector.
4055
4056 2018-07-03 Tom Tromey <tom@tromey.com>
4057
4058 * common/ptid.c (ptid_equal): Remove.
4059 * common/ptid.h (ptid_equal): Don't declare.
4060 * ada-tasks.c: Update.
4061 * breakpoint.c: Update.
4062 * common/agent.c: Update.
4063 * corelow.c: Update.
4064 * darwin-nat-info.c: Update.
4065 * darwin-nat.c: Update.
4066 * dcache.c: Update.
4067 * dtrace-probe.c: Update.
4068 * dummy-frame.c: Update.
4069 * fbsd-nat.c: Update.
4070 * frame.c: Update.
4071 * gdbthread.h: Update.
4072 * gnu-nat.c: Update.
4073 * go32-nat.c: Update.
4074 * inf-loop.c: Update.
4075 * inf-ptrace.c: Update.
4076 * infcall.c: Update.
4077 * infcmd.c: Update.
4078 * inflow.c: Update.
4079 * infrun.c: Update.
4080 * linux-fork.c: Update.
4081 * linux-nat.c: Update.
4082 * linux-thread-db.c: Update.
4083 * mi/mi-cmd-var.c: Update.
4084 * mi/mi-interp.c: Update.
4085 * mi/mi-main.c: Update.
4086 * nto-procfs.c: Update.
4087 * ppc-linux-tdep.c: Update.
4088 * procfs.c: Update.
4089 * python/py-inferior.c: Update.
4090 * python/py-record-btrace.c: Update.
4091 * python/py-record.c: Update.
4092 * ravenscar-thread.c: Update.
4093 * regcache.c: Update.
4094 * remote-sim.c: Update.
4095 * remote.c: Update.
4096 * sol-thread.c: Update.
4097 * solib.c: Update.
4098 * target.c: Update.
4099 * tui/tui-stack.c: Update.
4100 * varobj.c: Update.
4101 * windows-nat.c: Update.
4102 * windows-tdep.c: Update.
4103
4104 2018-07-03 Tom Tromey <tom@tromey.com>
4105
4106 * common/ptid.c (ptid_match): Remove.
4107 * common/ptid.h (ptid_match): Don't declare.
4108 * fbsd-nat.c: Update.
4109 * infcmd.c: Update.
4110 * infrun.c: Update.
4111 * linux-nat.c: Update.
4112 * record-btrace.c: Update.
4113 * regcache.c: Update.
4114 * remote.c: Update.
4115
4116 2018-07-03 Tom Tromey <tom@tromey.com>
4117
4118 * common/ptid.c (ptid_tid_p): Remove.
4119 * common/ptid.h (ptid_tid_p): Don't declare.
4120 * sol-thread.c: Update.
4121
4122 2018-07-03 Tom Tromey <tom@tromey.com>
4123
4124 * common/ptid.c (ptid_lwp_p): Remove.
4125 * common/ptid.h (ptid_lwp_p): Don't declare.
4126 * fbsd-nat.c: Update.
4127 * linux-nat.c: Update.
4128 * nat/linux-procfs.c: Update.
4129 * nat/x86-linux-dregs.c: Update.
4130 * sol-thread.c: Update.
4131
4132 2018-07-03 Tom Tromey <tom@tromey.com>
4133
4134 * common/ptid.c (ptid_is_pid): Remove.
4135 * common/ptid.h (ptid_is_pid): Don't declare.
4136 * infrun.c: Update.
4137 * linux-nat.c: Update.
4138 * mi/mi-interp.c: Update.
4139 * remote.c: Update.
4140 * thread.c: Update.
4141
4142 2018-07-03 Tom Tromey <tom@tromey.com>
4143
4144 * common/ptid.c (ptid_get_tid): Remove.
4145 * common/ptid.h (ptid_get_tid): Don't declare.
4146 * ada-tasks.c: Update.
4147 * aix-thread.c: Update.
4148 * bsd-uthread.c: Update.
4149 * darwin-nat.c: Update.
4150 * fbsd-nat.c: Update.
4151 * i386-darwin-nat.c: Update.
4152 * infrun.c: Update.
4153 * linux-tdep.c: Update.
4154 * nto-procfs.c: Update.
4155 * ppc-ravenscar-thread.c: Update.
4156 * python/py-infthread.c: Update.
4157 * ravenscar-thread.c: Update.
4158 * sol-thread.c: Update.
4159 * sparc-ravenscar-thread.c: Update.
4160 * windows-nat.c: Update.
4161
4162 2018-07-03 Tom Tromey <tom@tromey.com>
4163
4164 * common/ptid.c (ptid_get_lwp): Remove.
4165 * common/ptid.h (ptid_get_lwp): Don't declare.
4166 * aarch64-linux-nat.c: Update.
4167 * ada-tasks.c: Update.
4168 * aix-thread.c: Update.
4169 * amd64-linux-nat.c: Update.
4170 * arm-linux-nat.c: Update.
4171 * corelow.c: Update.
4172 * fbsd-nat.c: Update.
4173 * fbsd-tdep.c: Update.
4174 * gnu-nat.c: Update.
4175 * i386-cygwin-tdep.c: Update.
4176 * i386-gnu-nat.c: Update.
4177 * i386-linux-nat.c: Update.
4178 * ia64-linux-nat.c: Update.
4179 * inf-ptrace.c: Update.
4180 * infrun.c: Update.
4181 * linux-fork.c: Update.
4182 * linux-nat.c: Update.
4183 * linux-tdep.c: Update.
4184 * linux-thread-db.c: Update.
4185 * mips-linux-nat.c: Update.
4186 * nat/aarch64-linux-hw-point.c: Update.
4187 * nat/aarch64-linux.c: Update.
4188 * nat/linux-btrace.c: Update.
4189 * nat/linux-osdata.c: Update.
4190 * nat/linux-procfs.c: Update.
4191 * nat/x86-linux-dregs.c: Update.
4192 * obsd-nat.c: Update.
4193 * ppc-fbsd-nat.c: Update.
4194 * ppc-linux-nat.c: Update.
4195 * procfs.c: Update.
4196 * python/py-infthread.c: Update.
4197 * ravenscar-thread.c: Update.
4198 * remote.c: Update.
4199 * s390-linux-nat.c: Update.
4200 * sol-thread.c: Update.
4201 * sol2-tdep.c: Update.
4202 * spu-linux-nat.c: Update.
4203 * x86-linux-nat.c: Update.
4204 * xtensa-linux-nat.c: Update.
4205
4206 2018-07-03 Tom Tromey <tom@tromey.com>
4207
4208 * common/ptid.c (ptid_get_pid): Remove.
4209 * common/ptid.h (ptid_get_pid): Don't declare.
4210 * aarch64-linux-nat.c: Update.
4211 * ada-lang.c: Update.
4212 * aix-thread.c: Update.
4213 * alpha-bsd-nat.c: Update.
4214 * amd64-fbsd-nat.c: Update.
4215 * amd64-linux-nat.c: Update.
4216 * arm-linux-nat.c: Update.
4217 * arm-nbsd-nat.c: Update.
4218 * auxv.c: Update.
4219 * break-catch-syscall.c: Update.
4220 * breakpoint.c: Update.
4221 * bsd-uthread.c: Update.
4222 * corelow.c: Update.
4223 * ctf.c: Update.
4224 * darwin-nat.c: Update.
4225 * fbsd-nat.c: Update.
4226 * fbsd-tdep.c: Update.
4227 * gcore.c: Update.
4228 * gnu-nat.c: Update.
4229 * hppa-nbsd-nat.c: Update.
4230 * hppa-obsd-nat.c: Update.
4231 * i386-fbsd-nat.c: Update.
4232 * ia64-linux-nat.c: Update.
4233 * inf-ptrace.c: Update.
4234 * infcmd.c: Update.
4235 * inferior.c: Update.
4236 * inferior.h: Update.
4237 * inflow.c: Update.
4238 * infrun.c: Update.
4239 * linux-fork.c: Update.
4240 * linux-nat.c: Update.
4241 * linux-tdep.c: Update.
4242 * linux-thread-db.c: Update.
4243 * m68k-bsd-nat.c: Update.
4244 * mi/mi-interp.c: Update.
4245 * mi/mi-main.c: Update.
4246 * mips-linux-nat.c: Update.
4247 * mips-nbsd-nat.c: Update.
4248 * mips64-obsd-nat.c: Update.
4249 * nat/aarch64-linux-hw-point.c: Update.
4250 * nat/aarch64-linux.c: Update.
4251 * nat/linux-btrace.c: Update.
4252 * nat/linux-osdata.c: Update.
4253 * nat/linux-procfs.c: Update.
4254 * nat/x86-linux-dregs.c: Update.
4255 * nto-procfs.c: Update.
4256 * obsd-nat.c: Update.
4257 * ppc-linux-nat.c: Update.
4258 * ppc-nbsd-nat.c: Update.
4259 * ppc-obsd-nat.c: Update.
4260 * proc-service.c: Update.
4261 * procfs.c: Update.
4262 * python/py-inferior.c: Update.
4263 * python/py-infthread.c: Update.
4264 * ravenscar-thread.c: Update.
4265 * record.c: Update.
4266 * remote-sim.c: Update.
4267 * remote.c: Update.
4268 * rs6000-nat.c: Update.
4269 * s390-linux-nat.c: Update.
4270 * sh-nbsd-nat.c: Update.
4271 * sol-thread.c: Update.
4272 * sparc-nat.c: Update.
4273 * sparc64-tdep.c: Update.
4274 * spu-linux-nat.c: Update.
4275 * spu-tdep.c: Update.
4276 * target-debug.h: Update.
4277 * target.c: Update.
4278 * thread.c: Update.
4279 * tid-parse.c: Update.
4280 * tracefile-tfile.c: Update.
4281 * vax-bsd-nat.c: Update.
4282 * windows-nat.c: Update.
4283 * x86-linux-nat.c: Update.
4284 * x86-nat.c: Update.
4285
4286 2018-07-03 Tom Tromey <tom@tromey.com>
4287
4288 * common/ptid.c (pid_to_ptid): Remove.
4289 * common/ptid.h (pid_to_ptid): Don't declare.
4290 * aix-thread.c: Update.
4291 * arm-linux-nat.c: Update.
4292 * common/ptid.c: Update.
4293 * common/ptid.h: Update.
4294 * corelow.c: Update.
4295 * ctf.c: Update.
4296 * darwin-nat.c: Update.
4297 * fbsd-nat.c: Update.
4298 * fork-child.c: Update.
4299 * gnu-nat.c: Update.
4300 * go32-nat.c: Update.
4301 * inf-ptrace.c: Update.
4302 * infcmd.c: Update.
4303 * inferior.c: Update.
4304 * infrun.c: Update.
4305 * linux-fork.c: Update.
4306 * linux-nat.c: Update.
4307 * nat/aarch64-linux-hw-point.c: Update.
4308 * nat/fork-inferior.c: Update.
4309 * nat/x86-linux-dregs.c: Update.
4310 * nto-procfs.c: Update.
4311 * obsd-nat.c: Update.
4312 * procfs.c: Update.
4313 * progspace.c: Update.
4314 * remote.c: Update.
4315 * rs6000-nat.c: Update.
4316 * s390-linux-nat.c: Update.
4317 * sol-thread.c: Update.
4318 * spu-linux-nat.c: Update.
4319 * target.c: Update.
4320 * top.c: Update.
4321 * tracefile-tfile.c: Update.
4322 * windows-nat.c: Update.
4323
4324 2018-07-03 Tom Tromey <tom@tromey.com>
4325
4326 * common/ptid.h (ptid_build): Don't declare.
4327 * common/ptid.c (ptid_build): Remove.
4328 * aix-thread.c: Update.
4329 * bsd-kvm.c: Update.
4330 * bsd-uthread.c: Update.
4331 * common/agent.c: Update.
4332 * common/ptid.c: Update.
4333 * common/ptid.h: Update.
4334 * corelow.c: Update.
4335 * darwin-nat.c: Update.
4336 * fbsd-nat.c: Update.
4337 * gnu-nat.c: Update.
4338 * linux-fork.c: Update.
4339 * linux-nat.c: Update.
4340 * linux-thread-db.c: Update.
4341 * nat/linux-osdata.c: Update.
4342 * nat/linux-procfs.c: Update.
4343 * nto-procfs.c: Update.
4344 * obsd-nat.c: Update.
4345 * proc-service.c: Update.
4346 * procfs.c: Update.
4347 * ravenscar-thread.c: Update.
4348 * remote-sim.c: Update.
4349 * remote.c: Update.
4350 * sol-thread.c: Update.
4351 * target.c: Update.
4352 * windows-nat.c: Update.
4353
4354 2018-07-03 Tom Tromey <tom@tromey.com>
4355
4356 * infrun.c (follow_exec): Use exit_inferior_silent.
4357 * inferior.c (exit_inferior_num_silent): Remove.
4358 * inferior.h (exit_inferior_num_silent): Don't declare.
4359
4360 2018-07-03 Tom Tromey <tom@tromey.com>
4361
4362 PR cli/23340:
4363 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4364 inferior_ptid on error.
4365
4366 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4367 Simon Marchi <simon.marchi@polymtl.ca>
4368
4369 PR tdep/8282
4370 * disasm.h (gdb_disassembler): Add
4371 `m_disassembler_options_holder'. member
4372 * disasm.c (get_all_disassembler_options): New function.
4373 (gdb_disassembler::gdb_disassembler): Use it.
4374 (gdb_buffered_insn_length_init_dis): Likewise.
4375 (gdb_buffered_insn_length): Adjust accordingly.
4376 (set_disassembler_options): Handle options with arguments.
4377 (show_disassembler_options_sfunc): Likewise. Add a leading new
4378 line if showing options with descriptions.
4379 (disassembler_options_completer): Adapt to using the
4380 `disasm_options_and_args_t' structure.
4381 * mips-tdep.c (mips_disassembler_options): New variable.
4382 (mips_disassembler_options_o32): Likewise.
4383 (mips_disassembler_options_n32): Likewise.
4384 (mips_disassembler_options_n64): Likewise.
4385 (gdb_print_insn_mips): Don't set `disassembler_options'.
4386 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4387 functions.
4388 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4389 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4390 `gdbarch_disassembler_options_implicit' and
4391 `gdbarch_valid_disassembler_options'.
4392 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4393 `disasm_options_and_args_t' structure.
4394 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4395 method.
4396 (valid_disassembler_options): Switch from `disasm_options_t' to
4397 the `disasm_options_and_args_t' structure.
4398 * NEWS: Document `set disassembler-options' support for the MIPS
4399 target.
4400 * gdbarch.h: Regenerate.
4401 * gdbarch.c: Regenerate.
4402
4403 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4404
4405 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4406
4407 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4408
4409 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4410 parameter in call to amd64_target_description.
4411 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4412 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4413 (amd64fbsd_init_abi): Likewise.
4414 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4415 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4416 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4417 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4418
4419 2018-06-29 Pedro Alves <palves@redhat.com>
4420
4421 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4422 "segments" parameter.
4423 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4424 (_initialize_amd64_tdep): Update call to
4425 amd64_create_target_description.
4426 (amd64_target_description): Add "segments" parameter. Adjust
4427 the implementation to use it.
4428 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4429 call to amd64_create_target_description.
4430 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4431 * gdb/arch/amd64.h (amd64_create_target_description): Add
4432 "segments" register.
4433 * gdb/arch/amd64.c (amd64_create_target_description): Add
4434 "segments" parameter. Call create_feature_i386_64bit_segments
4435 only if SEGMENTS is true.
4436 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4437 call to amd64_create_target_description.
4438
4439 2018-06-29 Pedro Alves <palves@redhat.com>
4440
4441 * thread.c (thread_target_id_str): New, factored out from ...
4442 (print_thread_info_1): ... here. Use it to compute the max
4443 "Target Id" column width.
4444
4445 2018-06-29 Pedro Alves <palves@redhat.com>
4446
4447 * remote.c (remote_target::extra_thread_info): Delete
4448 'display_buf' and 'n' locals. from the cache, regardless of
4449 packet mechanims is in use. Use cache for qThreadExtra and qP
4450 methods too.
4451
4452 2018-06-29 Pedro Alves <palves@redhat.com>
4453
4454 * blockframe.c (find_pc_sect_containing_function): New function.
4455 * breakpoint.c (print_breakpoint_location): Don't call
4456 find_pc_sect_function.
4457 * linespec.c (create_sals_line_offset): Record the location's
4458 symbol in the sal.
4459 * linespec.c (convert_address_location_to_sals): Fill in sal's
4460 symbol with find_pc_sect_containing_function.
4461 * symtab.c (find_function_start_sal): Rename to ...
4462 (find_function_start_sal_1): ... this.
4463 (find_function_start_sal): Reimplement as wrapper around
4464 find_function_start_sal_1, and use
4465 find_pc_sect_containing_function to fill in the sal's symbol.
4466 (find_function_start_sal(symbol*, bool)): Adjust.
4467 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4468 comments.
4469 (find_pc_sect_containing_function): Declare.
4470
4471 2018-06-29 Pedro Alves <palves@redhat.com>
4472
4473 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4474 true if the the location has no symbol.
4475
4476 2018-06-28 Tom Tromey <tom@tromey.com>
4477
4478 * NEWS: Mention --enable-codesign.
4479 * silent-rules.mk (ECHO_SIGN): New variable.
4480 * configure.ac: Add --enable-codesign.
4481 * configure: Rebuild.
4482 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4483 (gdb$(EXEEXT)): Optionally invoke codesign.
4484
4485 2018-06-28 Pedro Alves <palves@redhat.com>
4486
4487 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4488 comments.
4489 (switch_to_thread_no_regs): Adjust comment.
4490 * infcmd.c (stop_pc): Delete.
4491 (post_create_inferior, info_program_command): Replace references
4492 to stop_pc with references to thread_info->suspend.stop_pc.
4493 * inferior.h (stop_pc): Delete declaration.
4494 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4495 (handle_inferior_event_1, handle_signal_stop)
4496 (process_event_stop_test, keep_going_stepped_thread)
4497 (handle_step_into_function, handle_step_into_function_backward)
4498 (print_stop_location): Replace references to stop_pc with
4499 references to thread_info->suspend.stop_pc.
4500 (struct infcall_suspend_state) <stop_pc>: Delete field.
4501 (save_infcall_suspend_state, restore_infcall_suspend_state):
4502 Remove references to inf_stat->stop_pc.
4503 * linux-fork.c (fork_load_infrun_state): Likewise.
4504 * record-btrace.c (record_btrace_set_replay): Likewise.
4505 * record-full.c (record_full_goto_entry): Likewise.
4506 * remote.c (print_one_stopped_thread): Likewise.
4507 * target.c (target_resume): Extend comment.
4508 * thread.c (set_executing_thread): New.
4509 (set_executing): Use it.
4510 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4511 Remove references to stop_pc.
4512
4513 2018-06-28 Pedro Alves <palves@redhat.com>
4514
4515 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4516 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4517
4518 2018-06-28 Tom Tromey <tom@tromey.com>
4519
4520 * coffread.c (coff_symfile_finish): Update.
4521 * xcoffread.c (xcoff_symfile_finish): Update.
4522 * elfread.c (elf_symfile_finish): Update.
4523 * symfile.h (dwarf2_free_objfile): Don't declare.
4524 * dwarf2read.c (_initialize_dwarf2_read): Use
4525 register_objfile_data_with_cleanup.
4526 (dwarf2_free_objfile): Now static. Change signature.
4527
4528 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4529
4530 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4531 option "-o" to add-symbol-file-load to add an offset to each
4532 section's load address.
4533 * symfile.c (set_objfile_default_section_offset): New function.
4534
4535 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4536
4537 * symfile.c (add_symbol_file_command): Make sure that sections
4538 with the same name are sorted in the same order.
4539
4540 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4541
4542 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4543 require the second argument. If omitted, load sections at the
4544 addresses specified in the file.
4545
4546 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4547
4548 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4549 (_initialize_symfile): Add option "-o" to symbol-file to add an
4550 offset to each section of the symbol file.
4551
4552 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4553
4554 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4555
4556 2018-06-27 Tom Tromey <tom@tromey.com>
4557
4558 * stack.c (_initialize_stack): Update "func" help text.
4559
4560 2018-06-27 Tom Tromey <tom@tromey.com>
4561
4562 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4563 std::vector.
4564 (unwind_infopy_str, pyuw_create_unwind_info)
4565 (unwind_infopy_add_saved_register, pyuw_sniffer)
4566 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4567 Update.
4568 (struct saved_reg): Add constructor.
4569 <value>: Now a gdbpy_ref<>.
4570
4571 2018-06-27 Tom Tromey <tom@tromey.com>
4572
4573 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4574
4575 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4576
4577 * gdb-gdb.py.in: Format using autopep8.
4578
4579 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4580
4581 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4582 (type_lookup_function): Recognize CORE_ADDR values.
4583
4584 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4585
4586 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4587 print tag_name.
4588
4589 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4590
4591 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4592 <__lt__>: Add.
4593
4594 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4595
4596 * gdb-gdb.py: Move to...
4597 * gdb-gdb.py.in: ... here.
4598 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4599 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4600 dependencies.
4601 (distclean): Remove gdb-gdb.py when cleaning.
4602 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4603 * configure: Re-generate.
4604
4605 2018-06-27 Pedro Alves <palves@redhat.com>
4606
4607 * proc-service.c (get_ps_regcache): New.
4608 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4609 (ps_lsetfpregs): Use it.
4610
4611 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4612
4613 PR gdb/21695
4614 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4615 (dwarf_decode_lines_1): Adjust.
4616
4617 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4618
4619 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4620 override.
4621 <info_proc>: Likewise.
4622
4623 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4624
4625 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4626 to windows_fetch_one_register, and only handle the case of
4627 fetching one register. Move the code that reloads the context
4628 and iterates over all registers if R is negative to...
4629 (windows_nat_target::fetch_registers): ... here.
4630 (do_windows_store_inferior_registers): Rename to
4631 windows_store_one_register, and only handle the case of storing
4632 one register. Move the code that handles the case where r is
4633 negative to...
4634 (windows_nat_target::store_registers) ... here.
4635
4636 2018-06-26 Tom Tromey <tom@tromey.com>
4637
4638 PR rust/22574:
4639 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4640 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4641 Update.
4642 (rust_internal_print_type): Add podata parameter.
4643 (rust_print_type): Update.
4644
4645 2018-06-26 Tom Tromey <tom@tromey.com>
4646
4647 * typeprint.h (struct print_offset_data) <update, finish,
4648 maybe_print_hole>: New methods.
4649 <indentation>: New constant.
4650 * typeprint.c (print_offset_data::indentation): Define.
4651 (print_offset_data::maybe_print_hole, print_offset_data::update)
4652 (print_offset_data::finish): Move from c-typeprint.c and rename.
4653 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4654 (print_spaces_filtered_with_print_options): Update.
4655 (c_print_type_union_field_offset, maybe_print_hole)
4656 (c_print_type_struct_field_offset): Move to typeprint.c and
4657 rename.
4658 (c_type_print_base_struct_union): Update.
4659
4660 2018-06-25 Pedro Alves <palves@redhat.com>
4661
4662 * gdbthread.h (thread_info_ref, delete_thread)
4663 (delete_thread_silent, first_thread_of_inferior)
4664 (any_thread_of_inferior, switch_to_thread)
4665 (enable_thread_stack_temporaries)
4666 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4667 (get_last_thread_stack_temporary)
4668 (value_in_thread_stack_temporaries, can_access_registers_thread):
4669 Spell out "struct thread_info" instead of just "thread_info".
4670 * inferior.h (notice_new_inferior): Likewise.
4671
4672 2018-06-25 Pedro Alves <palves@redhat.com>
4673
4674 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4675 pass thread_info pointer to delete_thread.
4676 (windows_nat_target::detach): Pass inferior pointer to
4677 detach_inferior.
4678 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4679 delete_thread.
4680 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4681 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4682 and pass a thread_info pointer to delete_thread.
4683 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4684 pass thread_info pointer to delete_thread.
4685 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4686 delete_thread_silent call.
4687 * procfs.c (procfs_target::detach): Pass inferior pointer to
4688 detach_inferior.
4689 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4690 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4691 delete_thread_silent call.
4692 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4693 pass thread_info pointer to delete_thread.
4694 (windows_nat_target::detach): Pass inferior pointer to
4695 delete_inferior.
4696
4697 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4698
4699 * regcache.c (readable_regcache::read_part): Fix asserts.
4700 (reg_buffer::raw_collect_part): New function.
4701 (regcache::write_part): Fix asserts.
4702 (reg_buffer::raw_supply_part): New function.
4703 (regcache::transfer_regset_register): New helper function.
4704 (regcache::transfer_regset): Call new functions.
4705 (regcache_supply_regset): Use gdb_byte*.
4706 (regcache::supply_regset): Likewise.
4707 (regcache_collect_regset): Likewise.
4708 (regcache::collect_regset): Likewise.
4709 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4710 (reg_buffer::raw_supply_part): Likewise.
4711 (regcache::transfer_regset_register): Likewise.
4712 (regcache::transfer_regset): Use gdb_byte*.
4713
4714 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4715
4716 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4717
4718 2018-06-21 Pedro Alves <palves@redhat.com>
4719
4720 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4721 instead of a ptid_t. All callers adjusted.
4722 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4723 adjusted.
4724 (print_ada_task_info, display_current_task_id, task_command_1):
4725 Adjust.
4726 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4727 inferior_thread.
4728 (breakpoint_kind): Adjust.
4729 (remove_breakpoints_pid): Rename to ...
4730 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4731 pointer. All callers adjusted.
4732 (bpstat_clear_actions): Use inferior_thread.
4733 (get_bpstat_thread): New.
4734 (bpstat_do_actions): Use it.
4735 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4736 to take a thread_info pointer. All callers adjusted.
4737 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4738 (breakpoint_re_set_thread): Use inferior_thread.
4739 * breakpoint.h (struct inferior): Forward declare.
4740 (bpstat_stop_status): Update.
4741 (remove_breakpoints_pid): Delete.
4742 (remove_breakpoints_inf): New.
4743 * bsd-uthread.c (bsd_uthread_target::wait)
4744 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4745 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4746 (maint_btrace_packet_history_cmd)
4747 (maint_btrace_clear_packet_history_cmd): Adjust.
4748 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4749 inferior_thread.
4750 * cli/cli-interp.c: Include "inferior.h".
4751 * common/refcounted-object.h (struct
4752 refcounted_object_ref_policy): New.
4753 * compile/compile-object-load.c: Include gdbthread.h.
4754 (store_regs): Use inferior_thread.
4755 * corelow.c (core_target::close): Use current_inferior.
4756 (core_target_open): Adjust to use first_thread_of_inferior and use
4757 the current inferior.
4758 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4759 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4760 <thread>: ... this new field. All references adjusted.
4761 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4762 Take a thread_info pointer instead of a ptid_t.
4763 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4764 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4765 thread_info pointer instead of a ptid_t.
4766 * elfread.c: Include "inferior.h".
4767 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4768 Use inferior_thread.
4769 * eval.c (evaluate_subexp): Likewise.
4770 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4771 inferior_thread.
4772 * gdb_proc_service.h (struct thread_info): Forward declare.
4773 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4774 <thread>: ... this new field. All references adjusted.
4775 * gdbarch.h, gdbarch.c: Regenerate.
4776 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4777 'thread' parameter. All implementations and callers adjusted.
4778 * gdbthread.h (thread_info) <set_running>: New method.
4779 (delete_thread, delete_thread_silent): Take a thread_info pointer
4780 instead of a ptid.
4781 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4782 (first_thread_of_process): Delete, replaced by ...
4783 (first_thread_of_inferior): ... this new function. All callers
4784 adjusted.
4785 (any_live_thread_of_process): Delete, replaced by ...
4786 (any_live_thread_of_inferior): ... this new function. All callers
4787 adjusted.
4788 (switch_to_thread, switch_to_no_thread): Declare.
4789 (is_executing): Delete.
4790 (enable_thread_stack_temporaries): Update comment.
4791 <enable_thread_stack_temporaries>: Take a thread_info pointer
4792 instead of a ptid_t. Incref the thread.
4793 <~enable_thread_stack_temporaries>: Decref the thread.
4794 <m_ptid>: Delete
4795 <m_thr>: New.
4796 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4797 (get_last_thread_stack_temporary)
4798 (value_in_thread_stack_temporaries, can_access_registers_thread):
4799 Take a thread_info pointer instead of a ptid_t. All callers
4800 adjusted.
4801 * infcall.c (get_call_return_value): Use inferior_thread.
4802 (run_inferior_call): Work with thread pointers instead of ptid_t.
4803 (call_function_by_hand_dummy): Work with thread pointers instead
4804 of ptid_t. Use thread_info_ref.
4805 * infcmd.c (proceed_thread_callback): Access thread's state
4806 directly.
4807 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4808 access thread's state directly.
4809 (continue_command): Use inferior_thread.
4810 (info_program_command): Use find_thread_ptid and access thread
4811 state directly.
4812 (proceed_after_attach_callback): Use thread state directly.
4813 (notice_new_inferior): Take a thread_info pointer instead of a
4814 ptid_t. All callers adjusted.
4815 (exit_inferior): Take an inferior pointer instead of a pid. All
4816 callers adjusted.
4817 (exit_inferior_silent): New.
4818 (detach_inferior): Delete.
4819 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4820 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4821 (detach_inferior_command, kill_inferior_command): Use
4822 find_inferior_id instead of valid_gdb_inferior_id and
4823 gdb_inferior_id_to_pid.
4824 (inferior_command): Use inferior and thread pointers.
4825 * inferior.h (struct thread_info): Forward declare.
4826 (notice_new_inferior): Take a thread_info pointer instead of a
4827 ptid_t. All callers adjusted.
4828 (detach_inferior): Delete declaration.
4829 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4830 instead of a pid. All callers adjusted.
4831 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4832 (valid_gdb_inferior_id): Delete.
4833 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4834 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4835 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4836 ...
4837 <inf>: ... this new field.
4838 <step_ptid>: Delete, replaced by ...
4839 <step_thread>: ... this new field.
4840 (get_displaced_stepping_state): Take an inferior pointer instead
4841 of a pid. All callers adjusted.
4842 (displaced_step_in_progress_any_inferior): Adjust.
4843 (displaced_step_in_progress_thread): Take a thread pointer instead
4844 of a ptid_t. All callers adjusted.
4845 (displaced_step_in_progress, add_displaced_stepping_state): Take
4846 an inferior pointer instead of a pid. All callers adjusted.
4847 (get_displaced_step_closure_by_addr): Adjust.
4848 (remove_displaced_stepping_state): Take an inferior pointer
4849 instead of a pid. All callers adjusted.
4850 (displaced_step_prepare_throw, displaced_step_prepare)
4851 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4852 All callers adjusted.
4853 (start_step_over): Adjust.
4854 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4855 displaced step queue.
4856 (do_target_resume): Adjust.
4857 (fetch_inferior_event): Use inferior_thread.
4858 (context_switch, get_inferior_stop_soon): Take an
4859 execution_control_state pointer instead of a ptid_t. All callers
4860 adjusted.
4861 (switch_to_thread_cleanup): Delete.
4862 (stop_all_threads): Use scoped_restore_current_thread.
4863 * inline-frame.c: Include "gdbthread.h".
4864 (inline_state) <inline_state>: Take a thread pointer instead of a
4865 ptid_t. All callers adjusted.
4866 <ptid>: Delete, replaced by ...
4867 <thread>: ... this new field.
4868 (find_inline_frame_state): Take a thread pointer instead of a
4869 ptid_t. All callers adjusted.
4870 (skip_inline_frames, step_into_inline_frame)
4871 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4872 pointer instead of a ptid_t. All callers adjusted.
4873 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4874 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4875 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4876 pointers directly.
4877 * linux-nat.c (get_detach_signal): Likewise.
4878 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4879 (thread_db_notice_clone): Adjust.
4880 (thread_db_find_new_threads_silently)
4881 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
4882 a thread pointer instead of a ptid_t. All callers adjusted.
4883 * mi/mi-cmd-var.c: Include "inferior.h".
4884 (mi_cmd_var_update_iter): Update to use thread pointers.
4885 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
4886 inferior directly.
4887 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
4888 out to ...
4889 (mi_output_running): ... this new function.
4890 (mi_on_resume_1): Adjust to use it.
4891 (mi_user_selected_context_changed): Adjust to use inferior_thread.
4892 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
4893 directly.
4894 (interrupt_thread_callback): : Adjust to use thread and inferior
4895 pointers.
4896 * proc-service.c: Include "gdbthread.h".
4897 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
4898 * progspace-and-thread.c: Include "inferior.h".
4899 * progspace.c: Include "inferior.h".
4900 * python/py-exitedevent.c (create_exited_event_object): Adjust to
4901 hold a reference to an inferior_object.
4902 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
4903 inferior_thread.
4904 * python/py-inferior.c (struct inferior_object): Give the type a
4905 tag name instead of a typedef.
4906 (python_on_normal_stop): No need to check if the current thread is
4907 listed.
4908 (inferior_to_inferior_object): Change return type to
4909 inferior_object. All callers adjusted.
4910 (find_thread_object): Delete, bits factored out to ...
4911 (thread_to_thread_object): ... this new function.
4912 * python/py-infthread.c (create_thread_object): Use
4913 inferior_to_inferior_object.
4914 (thpy_is_stopped): Use thread pointer directly.
4915 (gdbpy_selected_thread): Use inferior_thread.
4916 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
4917 field, replaced with ...
4918 <thread>: ... this new field. All users adjusted.
4919 (btpy_insn_or_gap_new): Drop const.
4920 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
4921 callers adjusted.
4922 * python/py-record.c: Include "gdbthread.h".
4923 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4924 a ptid_t. All callers adjusted.
4925 (gdbpy_current_recording): Use inferior_thread.
4926 * python/py-record.h (recpy_record_object) <ptid>: Delete
4927 field, replaced with ...
4928 <thread>: ... this new field. All users adjusted.
4929 (recpy_element_object) <ptid>: Delete
4930 field, replaced with ...
4931 <thread>: ... this new field. All users adjusted.
4932 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
4933 a ptid_t. All callers adjusted.
4934 * python/py-threadevent.c: Include "gdbthread.h".
4935 (get_event_thread): Use thread_to_thread_object.
4936 * python/python-internal.h (struct inferior_object): Forward
4937 declare.
4938 (find_thread_object, find_inferior_object): Delete declarations.
4939 (thread_to_thread_object, inferior_to_inferior_object): New
4940 declarations.
4941 * record-btrace.c: Include "inferior.h".
4942 (require_btrace_thread): Use inferior_thread.
4943 (record_btrace_frame_sniffer)
4944 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
4945 (get_thread_current_frame): Use scoped_restore_current_thread and
4946 switch_to_thread.
4947 (get_thread_current_frame): Use thread pointer directly.
4948 (record_btrace_replay_at_breakpoint): Use thread's inferior
4949 pointer directly.
4950 * record-full.c: Include "inferior.h".
4951 * regcache.c: Include "gdbthread.h".
4952 (get_thread_arch_regcache): Use the inferior's address space
4953 directly.
4954 (get_thread_regcache, registers_changed_thread): New.
4955 * regcache.h (get_thread_regcache(thread_info *thread)): New
4956 overload.
4957 (registers_changed_thread): New.
4958 (remote_target) <remote_detach_1>: Swap order of parameters.
4959 (remote_add_thread): <remote_add_thread>: Return the new thread.
4960 (get_remote_thread_info(ptid_t)): New overload.
4961 (remote_target::remote_notice_new_inferior): Use thread pointers
4962 directly.
4963 (remote_target::process_initial_stop_replies): Use
4964 thread_info::set_running.
4965 (remote_target::remote_detach_1, remote_target::detach)
4966 (extended_remote_target::detach): Adjust.
4967 * stack.c (frame_show_address): Use inferior_thread.
4968 * target-debug.h (target_debug_print_thread_info_pp): New.
4969 * target-delegates.c: Regenerate.
4970 * target.c (default_thread_address_space): Delete.
4971 (memory_xfer_partial_1): Use current_inferior.
4972 (target_detach): Use current_inferior.
4973 (target_thread_address_space): Delete.
4974 (generic_mourn_inferior): Use current_inferior.
4975 * target.h (struct target_ops) <thread_address_space>: Delete.
4976 (target_thread_address_space): Delete.
4977 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
4978 pointers directly.
4979 (delete_thread_1, delete_thread, delete_thread_silent): Take a
4980 thread pointer instead of a ptid_t. Adjust all callers.
4981 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
4982 (first_thread_of_process): Delete, replaced by ...
4983 (first_thread_of_inferior): ... this new function. All callers
4984 adjusted.
4985 (any_thread_of_process): Rename to ...
4986 (any_thread_of_inferior): ... this, and take an inferior pointer.
4987 (any_live_thread_of_process): Rename to ...
4988 (any_live_thread_of_inferior): ... this, and take an inferior
4989 pointer.
4990 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4991 (value_in_thread_stack_temporaries)
4992 (get_last_thread_stack_temporary): Take a thread pointer instead
4993 of a ptid_t. Adjust all callers.
4994 (thread_info::set_running): New.
4995 (validate_registers_access): Use inferior_thread.
4996 (can_access_registers_ptid): Rename to ...
4997 (can_access_registers_thread): ... this, and take a thread
4998 pointer.
4999 (print_thread_info_1): Adjust to compare thread pointers instead
5000 of ptids.
5001 (switch_to_no_thread, switch_to_thread): Make extern.
5002 (scoped_restore_current_thread::~scoped_restore_current_thread):
5003 Use m_thread pointer directly.
5004 (scoped_restore_current_thread::scoped_restore_current_thread):
5005 Use inferior_thread.
5006 (thread_command): Use thread pointer directly.
5007 (thread_num_make_value_helper): Use inferior_thread.
5008 * top.c (execute_command): Use inferior_thread.
5009 * tui/tui-interp.c: Include "inferior.h".
5010 * varobj.c (varobj_create): Use inferior_thread.
5011 (value_of_root_1): Use find_thread_global_id instead of
5012 global_thread_id_to_ptid.
5013
5014 2018-06-21 Alan Hayward <alan.hayward@arm.com>
5015
5016 * regcache.c (readable_regcache::read_part): Avoid memcpy when
5017 possible.
5018 (regcache::write_part): Likewise.
5019 (readable_regcache::cooked_read_part): Update comment.
5020 (readable_regcache::cooked_write_part): Likewise.
5021 * regcache.h: (readable_regcache::read_part): Likewise.
5022 (regcache::write_part): Likewise.
5023
5024 2018-06-21 Richard Bunt <richard.bunt@arm.com>
5025 Dirk Schubert <dirk.schubert@arm.com>
5026
5027 * aarch64-linux-nat.c (post_attach): New.
5028 (aarch64_linux_nat_target::post_attach): Override post_attach to
5029 record the number of hardware debug registers.
5030
5031 2018-06-20 Tom Tromey <tom@tromey.com>
5032
5033 * python/py-param.c (add_setshow_generic): Make parameters const.
5034 (parmpy_init): Update.
5035
5036 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5037
5038 * regcache.h (regcache_cooked_read_ftype): Rename to...
5039 (register_read_ftype): ...this, change type to function_view.
5040 (class reg_buffer) <save>: Remove src parameter.
5041 (readonly_detached_regcache) <readonly_detached_regcache>: Make
5042 parameter non-const in first overload. Remove src parameter in
5043 second overload.
5044 * regcache.c (do_cooked_read): Remove.
5045 (readonly_detached_regcache::readonly_detached_regcache): Make
5046 parameter non-const, adjust call to other constructor.
5047 (reg_buffer::save): Remove src parameter.
5048 * frame.c (do_frame_register_read): Remove.
5049 (frame_save_as_regcache): Use lambda function.
5050 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
5051 parameter to ppu2spu_data *.
5052 (ppu2spu_sniffer): Use lambda function.
5053
5054 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5055
5056 * record-full.c (record_full_target::insert_breakpoint): Remove
5057 "struct" keyword, add const.
5058
5059 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5060
5061 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
5062 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
5063 * configure.ac: Remove AC_PREREQ, add missing quoting.
5064 * gnulib/configure.ac: Modernize usage of
5065 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
5066 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
5067 (AUTOMAKE_VERSION): Bump to 1.15.1.
5068 * configure: Re-generate.
5069 * config.in: Re-generate.
5070 * aclocal.m4: Re-generate.
5071 * gnulib/aclocal.m4: Re-generate.
5072 * gnulib/config.in: Re-generate.
5073 * gnulib/configure: Re-generate.
5074 * gnulib/import/Makefile.in: Re-generate.
5075
5076 2018-06-19 Pedro Alves <palves@redhat.com>
5077
5078 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
5079 (lookup_minimal_symbol_by_pc_section): ... here with
5080 gdb_assert_not_reached added.
5081
5082 2018-06-19 Pedro Alves <palves@redhat.com>
5083
5084 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
5085 parameter with a block parameter. Compare location's block symbol
5086 with the frame's block instead of addresses.
5087 (skip_inline_frames): Pass the current block instead of the
5088 frame's address. Break out as soon as we determine the frame
5089 should not be skipped.
5090
5091 2018-06-18 Tom Tromey <tom@tromey.com>
5092
5093 * solib-aix.c (solib_aix_get_section_offsets): Return
5094 unique_xmalloc_ptr.
5095 (solib_aix_solib_create_inferior_hook): Update.
5096
5097 2018-06-18 Tom Tromey <tom@tromey.com>
5098
5099 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5100
5101 2018-06-18 Tom Tromey <tom@tromey.com>
5102
5103 * solib-frv.c (frv_relocate_main_executable): Use
5104 unique_xmalloc_ptr.
5105 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5106 unique_xmalloc_ptr.
5107
5108 2018-06-18 Tom Tromey <tom@tromey.com>
5109
5110 * objfiles.h (inhibit_section_map_updates): Update.
5111 (resume_section_map_updates, resume_section_map_updates_cleanup):
5112 Remove.
5113 * solib-svr4.c (svr4_handle_solib_event): Update.
5114 * objfiles.c (inhibit_section_map_updates): Return
5115 scoped_restore_tmpl<int>.
5116 (resume_section_map_updates, resume_section_map_updates_cleanup):
5117 Remove.
5118
5119 2018-06-18 Tom Tromey <tom@tromey.com>
5120
5121 * valprint.h (read_string): Update.
5122 * valprint.c (read_string): Change type of "buffer".
5123 (val_print_string): Update.
5124 * python/py-value.c (valpy_string): Update.
5125 * language.h (struct language_defn) <la_get_string>: Change
5126 type of "buffer".
5127 (default_get_string, c_get_string): Update.
5128 * language.c (default_get_string): Change type of "buffer".
5129 * guile/scm-value.c (gdbscm_value_to_string): Update.
5130 * c-lang.c (c_get_string): Change type of "buffer".
5131
5132 2018-06-18 Tom Tromey <tom@tromey.com>
5133
5134 * ser-mingw.c (struct pipe_state_destroyer): New.
5135 (pipe_state_up): New typedef.
5136 (cleanup_pipe_state): Remove.
5137 (pipe_windows_open): Use pipe_state_up. Don't release argv.
5138
5139 2018-06-18 Tom Tromey <tom@tromey.com>
5140
5141 * rust-lang.h (rust_yyerror): Don't declare.
5142 * rust-lang.c (rust_language_defn): Update.
5143 * rust-exp.y (yyerror): Now static.
5144 * parse.c (parse_exp_in_context_1): Update.
5145 * p-lang.h (p_yyerror): Don't declare.
5146 * p-lang.c (p_language_defn): Update.
5147 * p-exp.y (yyerror): Now static.
5148 * opencl-lang.c (opencl_language_defn): Update.
5149 * objc-lang.c (objc_language_defn): Update.
5150 * m2-lang.h (m2_yyerror): Don't declare.
5151 * m2-lang.c (m2_language_defn): Update.
5152 * m2-exp.y (yyerror): Now static.
5153 * language.h (struct language_defn) <la_error>: Remove.
5154 * language.c (unk_lang_error): Remove.
5155 (unknown_language_defn, auto_language_defn): Remove.
5156 * go-lang.h (go_yyerror): Don't declare.
5157 * go-lang.c (go_language_defn): Update.
5158 * go-exp.y (yyerror): Now static.
5159 * f-lang.h (f_yyerror): Don't declare.
5160 * f-lang.c (f_language_defn): Update.
5161 * f-exp.y (yyerror): Now static.
5162 * d-lang.h (d_yyerror): Don't declare.
5163 * d-lang.c (d_language_defn): Update.
5164 * d-exp.y (yyerror): Now static.
5165 * c-lang.h (c_yyerror): Don't declare.
5166 * c-lang.c (c_language_defn, cplus_language_defn)
5167 (asm_language_defn, minimal_language_defn): Update.
5168 * c-exp.y (yyerror): Now static.
5169 * ada-lang.h (ada_yyerror): Don't declare.
5170 * ada-lang.c (ada_language_defn): Update.
5171 * ada-exp.y (yyerror): Now static.
5172
5173 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5174
5175 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
5176 (store_sveregs_to_thread): Likewise.
5177 (aarch64_linux_fetch_inferior_registers): Check for SVE.
5178 (aarch64_linux_store_inferior_registers): Likewise.
5179 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
5180 function.
5181 (aarch64_sve_regs_copy_to_regcache): Likewise.
5182 (aarch64_sve_regs_copy_from_regcache): Likewise.
5183 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
5184 declaration.
5185 (aarch64_sve_regs_copy_to_regcache): Likewise.
5186 (aarch64_sve_regs_copy_from_regcache): Likewise.
5187 (sve_context): Structure from Linux headers.
5188 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
5189 (SVE_SIG_ZREG_SIZE): Likewise.
5190 (SVE_SIG_PREG_SIZE): Likewise.
5191 (SVE_SIG_FFR_SIZE): Likewise.
5192 (SVE_SIG_REGS_OFFSET): Likewise.
5193 (SVE_SIG_ZREGS_OFFSET): Likewise.
5194 (SVE_SIG_ZREG_OFFSET): Likewise.
5195 (SVE_SIG_ZREGS_SIZE): Likewise.
5196 (SVE_SIG_PREGS_OFFSET): Likewise.
5197 (SVE_SIG_PREG_OFFSET): Likewise.
5198 (SVE_SIG_PREGS_SIZE): Likewise.
5199 (SVE_SIG_FFR_OFFSET): Likewise.
5200 (SVE_SIG_REGS_SIZE): Likewise.
5201 (SVE_SIG_CONTEXT_SIZE): Likewise.
5202 (SVE_PT_REGS_MASK): Likewise.
5203 (SVE_PT_REGS_FPSIMD): Likewise.
5204 (SVE_PT_REGS_SVE): Likewise.
5205 (SVE_PT_VL_INHERIT): Likewise.
5206 (SVE_PT_VL_ONEXEC): Likewise.
5207 (SVE_PT_REGS_OFFSET): Likewise.
5208 (SVE_PT_FPSIMD_OFFSET): Likewise.
5209 (SVE_PT_FPSIMD_SIZE): Likewise.
5210 (SVE_PT_SVE_ZREG_SIZE): Likewise.
5211 (SVE_PT_SVE_PREG_SIZE): Likewise.
5212 (SVE_PT_SVE_FFR_SIZE): Likewise.
5213 (SVE_PT_SVE_FPSR_SIZE): Likewise.
5214 (SVE_PT_SVE_FPCR_SIZE): Likewise.
5215 (__SVE_SIG_TO_PT): Likewise.
5216 (SVE_PT_SVE_OFFSET): Likewise.
5217 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
5218 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
5219 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
5220 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
5221 (SVE_PT_SVE_PREG_OFFSET): Likewise.
5222 (SVE_PT_SVE_PREGS_SIZE): Likewise.
5223 (SVE_PT_SVE_FFR_OFFSET): Likewise.
5224 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
5225 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
5226 (SVE_PT_SVE_SIZE): Likewise.
5227 (SVE_PT_SIZE): Likewise.
5228 (HAS_SVE_STATE): New define.
5229
5230 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5231
5232 * nat/aarch64-sve-linux-sigcontext.h: New file.
5233 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
5234 new files.
5235 (SVE_VQ_MIN): Likewise.
5236 (SVE_VQ_MAX): Likewise.
5237 (SVE_VL_MIN): Likewise.
5238 (SVE_VL_MAX): Likewise.
5239 (SVE_NUM_ZREGS): Likewise.
5240 (SVE_NUM_PREGS): Likewise.
5241 (sve_vl_valid): Likewise.
5242 (struct user_sve_header): Likewise.
5243
5244 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
5245 Richard Bunt <Richard.Bunt@arm.com>
5246
5247 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
5248 was requested by GDB.
5249
5250 2018-06-15 Tom de Vries <tdevries@suse.de>
5251
5252 * MAINTAINERS (Write After Approval): Add Tom de Vries.
5253
5254 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
5255
5256 * gnulib/update-gnulib.sh: Print expected versions of
5257 autoconf/aclocal.
5258
5259 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
5260
5261 * arch-utils.c (default_type_align): Use type_length_units.
5262 * gdbtypes.c (type_align): Use type_length_units.
5263
5264 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5265
5266 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
5267 of 'define' command.
5268
5269 2018-06-14 Tom de Vries <tdevries@suse.de>
5270
5271 PR cli/22573
5272 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5273 get_no_prettyformat_print_options.
5274
5275 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
5276
5277 * sparc-nat.h: Include target.h.
5278 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
5279 <fetch_registers>: Remove this argument in function call.
5280 <store_registers>: Remove this argument in function call, remove
5281 extra semicolon.
5282 <low_forget_process>: Call sparc64_forget_process instead of
5283 sparc_forget_process.
5284
5285 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5286
5287 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5288 (procfs_target::make_corefile_notes): Adjust to new
5289 target_read_alloc return type.
5290
5291 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5292 Stephen Roberts <stephen.roberts@arm.com>
5293
5294 PR gdb/22882
5295 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5296 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5297 Move should_notify_stop local into more inner scope.
5298
5299 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5300 Stephen Roberts <stephen.roberts@arm.com>
5301
5302 PR gdb/22882
5303 * infrun.c (resume_1): Add call to mark_async_event_handler.
5304
5305 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5306
5307 * infrun.c (do_target_wait): Change old version of $pc printed.
5308
5309 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5310
5311 * dwarf2read.c (read_index_from_section): Rename to...
5312 (read_gdb_index_from_section): ... this, update all callers.
5313 (dwarf2_read_index): Rename to...
5314 (dwarf2_read_gdb_index): ... this, update all callers.
5315
5316 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5317
5318 * gdb/hppa-linux-nat.c
5319 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5320 hppa_linux_nat_target::fetch_registers.
5321
5322 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5323
5324 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5325 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5326 (AARCH64_DWARF_SVE_FFR): Likewise.
5327 (AARCH64_DWARF_SVE_P0): Likewise.
5328 (AARCH64_DWARF_SVE_Z0): Likewise.
5329
5330 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5331
5332 * common/common-regcache.h (raw_compare): New function.
5333 * regcache.c (regcache::raw_compare): Likewise.
5334 * regcache.h (regcache::raw_compare): New declaration.
5335
5336 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5337
5338 * common/common-regcache.h (reg_buffer_common): New structure.
5339 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5340 (reg_buffer::raw_supply): Likewise.
5341 (reg_buffer::raw_supply_integer): Likewise.
5342 (reg_buffer::raw_supply_zeroed): Likewise.
5343 (reg_buffer::raw_collect): Likewise.
5344 (reg_buffer::raw_collect_integer): Likewise.
5345 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5346 (reg_buffer::raw_supply): Likewise.
5347 (reg_buffer::raw_supply_integer): Likewise.
5348 (reg_buffer::raw_supply_zeroed): Likewise.
5349 (reg_buffer::raw_collect): Likewise.
5350 (reg_buffer::raw_collect_integer): Likewise.
5351
5352 2018-06-10 Tom Tromey <tom@tromey.com>
5353
5354 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5355 (class remote_state) <stop_reply_queue>: Now std::vector.
5356 (remote_state::~remote_state)
5357 (remote_target::stop_reply_queue_length): Update.
5358 (struct queue_iter_param, remove_child_of_pending_fork)
5359 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5360 (check_pending_event_prevents_wildcard_vcont_callback)
5361 (remove_stop_reply_for_inferior)
5362 (remove_stop_reply_of_remote_state)
5363 (remote_notif_remove_once_on_match)
5364 (stop_reply_match_ptid_and_ws)
5365 (remote_kill_child_of_pending_fork): Remove.
5366 (remote_target::remove_new_fork_children)
5367 (remote_target::check_pending_events_prevent_wildcard_vcont)
5368 (remote_target::discard_pending_stop_replies)
5369 (remote_target::discard_pending_stop_replies_in_queue)
5370 (remote_target::remote_notif_remove_queued_reply)
5371 (remote_target::queued_stop_reply)
5372 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5373 (remote_target::wait, remote_target::kill_new_fork_children)
5374 (remote_target::async): Update.
5375
5376 2018-06-10 Tom Tromey <tom@tromey.com>
5377
5378 * record-full.c (record_full_arch_list_cleanups): Remove.
5379 (record_full_message): Use try/catch.
5380 (record_full_wait_cleanups): Remove.
5381 (record_full_wait_1): Use try/catch.
5382 (record_full_restore): Likewise.
5383
5384 2018-06-10 Tom Tromey <tom@tromey.com>
5385
5386 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5387 declare VEC. Add constructor.
5388 <in_target_beneath>: Now bool.
5389 (record_full_breakpoints): Now a std::vector, static.
5390 (record_full_sync_record_breakpoints)
5391 (record_full_init_record_breakpoints)
5392 (record_full_target::insert_breakpoint)
5393 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5394
5395 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5396
5397 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5398 * serial.c (serial_interface_lookup): Remove struct keyword.
5399
5400 2018-06-10 Tom Tromey <tom@tromey.com>
5401
5402 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5403 method.
5404 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5405 a method.
5406 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5407 method.
5408 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5409 "beneath" as a method.
5410 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5411 Use "beneath" as a method.
5412
5413 2018-06-10 Tom Tromey <tom@tromey.com>
5414
5415 * tracefile.c (struct trace_file_writer_deleter): New.
5416 <operator()>: Rename from trace_file_writer_xfree.
5417 (trace_file_writer_up): New typedef.
5418 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5419
5420 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5421
5422 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5423 <m_registers, m_register_status>: Change type to
5424 std::unique_ptr.
5425 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5426 XCNEWVEC.
5427
5428 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5429
5430 * common/common-regcache.h (enum register_status): Add
5431 underlying type "signed char".
5432 * regcache.h (reg_buffer) <m_register_status>: Change type to
5433 register_status *.
5434 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5435 register_status instead of signed char.
5436 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5437 (reg_buffer::get_register_status): Remove cast.
5438 (readable_regcache::raw_read): Remove cast.
5439 (readable_regcache::cooked_read): Remove cast.
5440
5441 2018-06-09 Tom Tromey <tom@tromey.com>
5442
5443 * source.c (reverse_search_command, forward_search_command): Use
5444 scoped_fd.
5445
5446 2018-06-09 Tom Tromey <tom@tromey.com>
5447
5448 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5449 (serial_ops_list): Now static, std::vector.
5450 (serial_interface_lookup, serial_add_interface): Update.
5451
5452 2018-06-09 Tom Tromey <tom@tromey.com>
5453
5454 * dwarf2read.c (process_cu_includes): Update.
5455 (process_full_comp_unit): Update.
5456 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5457 std::vector.
5458
5459 2018-06-08 Paul Koning <paul_koning@dell.com>
5460
5461 PR gdb/23252
5462
5463 * python/python.c (do_start_initialization):
5464 Avoid call to internal Python API.
5465 (init__gdb_module): New function.
5466
5467 2018-06-08 Gary Benson <gbenson@redhat.com>
5468
5469 * linux-thread-db.c (valprint.h): New include.
5470 (struct check_thread_db_info): New structure.
5471 (check_thread_db_on_load, tdb_testinfo): New static globals.
5472 (check_thread_db, check_thread_db_callback): New functions.
5473 (try_thread_db_load_1): Run integrity checks if requested.
5474 (maintenance_check_libthread_db): New function.
5475 (_initialize_thread_db): Register "maint check libthread-db"
5476 and "maint set/show check-libthread-db".
5477 * NEWS: Mention the above new commands.
5478
5479 2018-06-08 Tom Tromey <tom@tromey.com>
5480
5481 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5482 now a method.
5483
5484 2018-06-08 Tom Tromey <tom@tromey.com>
5485
5486 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5487
5488 2018-06-08 Tom Tromey <tom@tromey.com>
5489
5490 * common/btrace-common.h (struct btrace_data): Add constructor,
5491 destructor, move assignment operator.
5492 <empty, clear, fini>: New methods.
5493 <format>: Initialize.
5494 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5495 (btrace_data_empty): Don't declare.
5496 * common/btrace-common.c (btrace_data_init): Remove.
5497 (btrace_data::fini): Rename from btrace_data_fini.
5498 (btrace_data::empty): Rename from btrace_data_empty.
5499 (btrace_data::clear): Rename from btrace_data_clear. Return
5500 bool.
5501 * btrace.h (make_cleanup_btrace_data): Don't declare.
5502 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5503 (parse_xml_btrace): Update.
5504 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5505 (maint_btrace_clear_packet_history_cmd): Update.
5506
5507 2018-06-07 Pedro Alves <palves@redhat.com>
5508
5509 * target.h (target_ops) <beneath>: Now a method. All references
5510 updated.
5511 (class target_stack): New.
5512 * target.c (g_target_stack): New.
5513 (g_current_top_target): Delete.
5514 (current_top_target): Get the top target out of g_target_stack.
5515 (target_stack::push, target_stack::unpush): New.
5516 (push_target, unpush_target): Reimplement.
5517 (target_is_pushed): Reimplement in terms of g_target_stack.
5518 (target_ops::beneath, target_stack::find_beneath): New.
5519
5520 2018-06-07 Pedro Alves <palves@redhat.com>
5521
5522 * target.h (find_target_beneath): Delete declaration.
5523 * target.c (find_target_beneath): Delete definition.
5524 * aix-thread.c: All callers of find_target_beneath adjusted to
5525 call target_ops::beneath instead.
5526 * bsd-uthread.c: Likewise.
5527 * linux-thread-db.c: Likewise.
5528 * ravenscar-thread.c: Likewise.
5529 * sol-thread.c: Likewise.
5530 * spu-multiarch.c: Likewise.
5531
5532 2018-06-07 Pedro Alves <palves@redhat.com>
5533
5534 * target.h (target_ops) <beneath>: Now a method. All references
5535 updated.
5536 (target_ops) <m_beneath>: New.
5537 * target.c (target_ops::beneath): New.
5538 * corelow.c: Adjust all references to target_ops::beneath.
5539 * linux-thread-db.c: Likewise.
5540 * make-target-delegates: Likewise.
5541 * record-btrace.c: Likewise.
5542 * record-full.c: Likewise.
5543 * remote.c: Likewise.
5544 * target.c: Likewise.
5545 * target-delegates.c: Regenerate.
5546
5547 2018-06-07 Pedro Alves <palves@redhat.com>
5548
5549 * target.h (target_stack): Delete.
5550 (current_top_target): Declare function.
5551 * target.c (target_stack): Delete.
5552 (g_current_top_target): New.
5553 (current_top_target): New function.
5554 * auxv.c: Use current_top_target instead of target_stack
5555 throughout.
5556 * avr-tdep.c: Likewise.
5557 * breakpoint.c: Likewise.
5558 * corefile.c: Likewise.
5559 * elfread.c: Likewise.
5560 * eval.c: Likewise.
5561 * exceptions.c: Likewise.
5562 * frame.c: Likewise.
5563 * gdbarch-selftests.c: Likewise.
5564 * gnu-v3-abi.c: Likewise.
5565 * ia64-tdep.c: Likewise.
5566 * ia64-vms-tdep.c: Likewise.
5567 * infcall.c: Likewise.
5568 * infcmd.c: Likewise.
5569 * infrun.c: Likewise.
5570 * linespec.c: Likewise.
5571 * linux-tdep.c: Likewise.
5572 * minsyms.c: Likewise.
5573 * ppc-linux-nat.c: Likewise.
5574 * ppc-linux-tdep.c: Likewise.
5575 * procfs.c: Likewise.
5576 * regcache.c: Likewise.
5577 * remote.c: Likewise.
5578 * rs6000-tdep.c: Likewise.
5579 * s390-linux-nat.c: Likewise.
5580 * s390-tdep.c: Likewise.
5581 * solib-aix.c: Likewise.
5582 * solib-darwin.c: Likewise.
5583 * solib-dsbt.c: Likewise.
5584 * solib-spu.c: Likewise.
5585 * solib-svr4.c: Likewise.
5586 * solib-target.c: Likewise.
5587 * sparc-tdep.c: Likewise.
5588 * sparc64-tdep.c: Likewise.
5589 * spu-tdep.c: Likewise.
5590 * symfile.c: Likewise.
5591 * symtab.c: Likewise.
5592 * target-descriptions.c: Likewise.
5593 * target-memory.c: Likewise.
5594 * target.c: Likewise.
5595 * target.h: Likewise.
5596 * tracefile-tfile.c: Likewise.
5597 * tracepoint.c: Likewise.
5598 * valops.c: Likewise.
5599 * valprint.c: Likewise.
5600 * value.c: Likewise.
5601 * windows-tdep.c: Likewise.
5602 * mi/mi-main.c: Likewise.
5603
5604 2018-06-07 Tom Tromey <tom@tromey.com>
5605
5606 * valprint.h (build_address_symbolic): Declare.
5607 * printcmd.c (print_address_symbolic): Update.
5608 (build_address_symbolic): Change "name" and "filename" to
5609 std::string.
5610 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5611 Update.
5612 * defs.h (build_address_symbolic): Remove declaration.
5613
5614 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5615
5616 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5617 (aarch64_vnv_type): Add function.
5618 (aarch64_pseudo_register_name): Add V regs for SVE.
5619 (aarch64_pseudo_register_type): Likewise.
5620 (aarch64_pseudo_register_reggroup_p): Likewise.
5621 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5622 (aarch64_pseudo_read_value): Add V regs for SVE.
5623 (aarch64_pseudo_write_2): Use V0 offset for SVE
5624 (aarch64_pseudo_write): Add V regs for SVE.
5625 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5626
5627 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5628
5629 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5630 (sve_vl_from_vq): Likewise.
5631
5632 2018-06-05 Tom Tromey <tom@tromey.com>
5633
5634 * cli/cli-cmds.c (show_version): Update.
5635 * top.c (print_gdb_version): Add "interactive" parameter.
5636 Update.
5637 * main.c (captured_main_1): Update.
5638 * top.h (print_gdb_version): Add "interactive" parameter and a
5639 comment.
5640
5641 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5642
5643 * common/enum-flags.h: Add trailing semicolon to example in
5644 comment.
5645
5646 2018-06-05 Tom Tromey <tom@tromey.com>
5647
5648 PR cli/12326:
5649 * NEWS: Add entry about pager.
5650 * utils.c (pagination_disabled_for_command): New global.
5651 (prompt_for_continue): Allow "c" response to prompt.
5652 (reinitialize_more_filter): Clear
5653 pagination_disabled_for_command.
5654 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5655
5656 2018-06-04 Tom Tromey <tom@tromey.com>
5657
5658 * ada-lang.h (ada_lookup_symbol_list): Update.
5659 * ada-lang.c (resolve_subexp): Update.
5660 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5661 parameter.
5662 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5663 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5664 results parameter to std::vector.
5665 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5666 Update.
5667 * ada-exp.y (block_lookup): Update.
5668 (select_possible_type_sym): Change type of syms. Remove nsyms
5669 parameter.
5670 (write_var_or_type, write_name_assoc): Update.
5671
5672 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5673
5674 * windows-nat.c (windows_nat_target::xfer_partial): Return
5675 TARGET_XFER_E_IO if we need to delegate to the target beneath
5676 but BENEATH is NULL.
5677
5678 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5679
5680 * Makefile.in (config.status): Add configure.nat as a
5681 dependency.
5682
5683 2018-06-04 Tom Tromey <tom@tromey.com>
5684
5685 * cp-name-parser.y (cpname_state): Add method declarations.
5686 (HANDLE_QUAL): Update.
5687 (cpname_state::d_grab, cpname_state::fill_comp)
5688 (cpname_state::make_operator, cpname_state::make_dtor)
5689 (cpname_state::make_builtin_type, cpname_state::make_name)
5690 (cpname_state::d_qualify, cpname_state::d_int_type)
5691 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5692 (%union): Move earlier.
5693
5694 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5695
5696 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5697
5698 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5699
5700 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5701 (aarch64_pseudo_write_1): Likewise.
5702 (aarch64_pseudo_read_value): Use helper.
5703 (aarch64_pseudo_write): Likewise.
5704
5705 2018-06-04 Pedro Alves <palves@redhat.com>
5706
5707 * darwin-nat.c (darwin_ops): Delete.
5708 (darwin_attach_pid): Use get_native_target.
5709
5710 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5711
5712 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5713 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5714
5715 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5716
5717 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5718 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5719 (aarch64_gdbarch_init): Check for SVE.
5720 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5721
5722 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5723
5724 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5725 * aarch64-tdep.h (aarch64_read_description): Likewise.
5726 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5727 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5728 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5729 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5730 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5731
5732 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5733
5734 * value.c (value_fetch_lazy_bitfield): New.
5735 (value_fetch_lazy_memory): New.
5736 (value_fetch_lazy_register): New.
5737 (value_fetch_lazy): Factor out to smaller functions.
5738
5739 2018-06-01 Tom Tromey <tom@tromey.com>
5740
5741 * cp-name-parser.y (backslashable, represented): Now const.
5742
5743 2018-06-01 Tom Tromey <tom@tromey.com>
5744
5745 * cp-name-parser.y: Include parser-defs.h.
5746 (parser_fprintf): Remove declaration.
5747
5748 2018-06-01 Tom Tromey <tom@tromey.com>
5749
5750 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5751 %parse-param.
5752 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5753 (global_result): Remove globals.
5754 (struct cpname_state): New.
5755 (yyparse): Don't declare.
5756 (yylex, yyerror): Move declarations after %union.
5757 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5758 (make_name): Add state parameter.
5759 Update all callers.
5760 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5761 parameter.
5762 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5763 Update.
5764 (yylex): Add lvalp, state parameters.
5765 (yyerror): Add state parameter.
5766 (cp_demangled_name_to_comp): Update.
5767
5768 2018-06-01 Tom Tromey <tom@tromey.com>
5769
5770 * cp-name-parser.y (parser_fprintf): Declare.
5771 (GDB_YY_REMAP_PREFIX): Define.
5772 Include yy-remap.h. Don't redefine yy* identifiers.
5773
5774 2018-06-01 Tom Tromey <tom@tromey.com>
5775
5776 * python/py-type.c (typy_legacy_template_argument): Update.
5777 * cp-support.h (cp_demangled_name_to_comp): Update.
5778 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5779 parameter to be a "std::string *".
5780 (main): Update.
5781
5782 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5783
5784 * ada-lex.l: Include "diagnostics.h" instead of
5785 "common/diagnostics.h".
5786 * unittests/environ-selftests.c: Likewise.
5787 * common/diagnostics.h: Moved to ../include.
5788
5789 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5790
5791 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5792 to language_mode_manual while calling breakpoint_re_set_one.
5793
5794 2018-06-01 Tom Tromey <tom@tromey.com>
5795
5796 * valops.c (value_cast_structs, destructor_name_p): Update.
5797 * symtab.c (gdb_mangle_name): Update.
5798 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5799 Update.
5800 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5801 (pascal_object_print_value_fields, pascal_object_print_value):
5802 Update.
5803 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5804 * linespec.c (find_methods): Update.
5805 * gdbtypes.h (type_name_no_tag): Remove.
5806 (type_name_or_error): Rename from type_name_no_tag_or_error.
5807 * gdbtypes.c (type_name_no_tag): Remove.
5808 (type_name_or_error): Rename from type_name_no_tag_or_error.
5809 (lookup_struct_elt_type, check_typedef): Update.
5810 * expprint.c (print_subexp_standard): Update.
5811 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5812 * d-namespace.c (d_lookup_nested_symbol): Update.
5813 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5814 (cp_print_class_member): Update.
5815 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5816 * completer.c (add_struct_fields): Update.
5817 * c-typeprint.c (cp_type_print_derivation_info)
5818 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5819 Update.
5820 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5821 (ada_prefer_type, ada_is_exception_sym): Update.
5822
5823 2018-06-01 Tom Tromey <tom@tromey.com>
5824
5825 * valops.c (enum_constant_from_type, value_namespace_elt)
5826 (value_maybe_namespace_elt): Update.
5827 * valarith.c (find_size_for_pointer_math): Update.
5828 * target-descriptions.c (make_gdb_type): Update.
5829 * symmisc.c (print_symbol): Update.
5830 * stabsread.c (define_symbol, read_type)
5831 (complain_about_struct_wipeout, add_undefined_type)
5832 (cleanup_undefined_types_1): Update.
5833 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5834 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5835 (rust_internal_print_type, rust_composite_type)
5836 (rust_evaluate_funcall, rust_evaluate_subexp)
5837 (rust_inclusive_range_type_p): Update.
5838 * python/py-type.c (typy_get_tag): Update.
5839 * p-typeprint.c (pascal_type_print_base): Update.
5840 * mdebugread.c (parse_symbol, parse_type): Update.
5841 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5842 Update.
5843 * guile/scm-type.c (gdbscm_type_tag): Update.
5844 * go-lang.c (sixg_string_p): Update.
5845 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5846 Update.
5847 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5848 (TYPE_TAG_NAME): Remove.
5849 * gdbtypes.c (type_name_no_tag): Simplify.
5850 (check_typedef, check_types_equal, recursive_dump_type)
5851 (copy_type_recursive, arch_composite_type): Update.
5852 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5853 in summary mode when needed.
5854 * eval.c (evaluate_funcall): Update.
5855 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5856 (process_structure_scope, read_enumeration_type)
5857 (read_namespace_type, read_module_type, determine_prefix): Update.
5858 * cp-support.c (inspect_type): Update.
5859 * coffread.c (process_coff_symbol, decode_base_type): Update.
5860 * c-varobj.c (c_is_path_expr_parent): Update.
5861 * c-typeprint.c (c_type_print_base_struct_union): Update.
5862 (c_type_print_base_1): Update. Print struct/class/union/enum in
5863 summary when using C language.
5864 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5865 (gen_maybe_namespace_elt): Update.
5866 * ada-lang.c (ada_type_name): Simplify.
5867 (empty_record, ada_template_to_fixed_record_type_1)
5868 (template_to_static_fixed_type)
5869 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5870
5871 2018-06-01 Tom Tromey <tom@tromey.com>
5872
5873 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5874 c_print_type.
5875 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5876 (c_print_type): Update.
5877 (c_print_type): New overload.
5878 (c_type_print_varspec_prefix, c_type_print_args)
5879 (c_type_print_varspec_suffix, c_print_type_no_offsets)
5880 (c_type_print_base_struct_union, c_type_print_base_1)
5881 (cp_type_print_method_args): Add "language" parameter.
5882 (c_type_print_base): Update.
5883 * c-lang.h (c_print_type): Add new overload.
5884
5885 2018-06-01 Tom Tromey <tom@tromey.com>
5886
5887 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
5888 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
5889
5890 2018-06-01 Alan Hayward <alan.hayward@arm.com>
5891
5892 * aarch64-tdep.c (aarch64_sve_register_names): New const
5893 var.
5894 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
5895 (AARCH64_SVE_Z_REGS_NUM): New define.
5896 (AARCH64_SVE_P_REGS_NUM): Likewise.
5897 (AARCH64_SVE_NUM_REGS): Likewise.
5898
5899 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
5900
5901 * nat/linux-ptrace.h [__alpha__]
5902 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
5903 definitions.
5904
5905 2018-05-31 Maciej W. Rozycki <macro@mips.com>
5906
5907 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
5908 the endianness selected.
5909 * NEWS: Document `set endian auto' mode operation update.
5910
5911 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5912
5913 * Makefile.in: Add new header.
5914 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
5915 (sve_vl_from_vg): Likewise.
5916 (sve_vq_from_vl): Likewise.
5917 (sve_vl_from_vq): Likewise.
5918 (sve_vq_from_vg): Likewise.
5919 (sve_vg_from_vq): Likewise.
5920 * configure.nat: Add new c file.
5921 * nat/aarch64-sve-linux-ptrace.c: New file.
5922 * nat/aarch64-sve-linux-ptrace.h: New file.
5923
5924 2018-05-31 Alan Hayward <alan.hayward@arm.com>
5925
5926 * aarch64-linux-nat.c (aarch64_linux_read_description):
5927 Add parmeter zero.
5928 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
5929 Likewise.
5930 * aarch64-tdep.c (tdesc_aarch64_list): Add.
5931 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
5932 (aarch64_gdbarch_init): Add parmeter zero.
5933 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
5934 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
5935 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
5936 parmeter.
5937 * doc/gdb.texinfo: Describe SVE feature
5938 * features/aarch64-sve.c: New file.
5939
5940 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
5941
5942 PR gdb/23210
5943 * gdbarch.sh (significant_addr_bit): Default to zero when
5944 not set by target architecture.
5945 * gdbarch.c: Re-generated.
5946 * utils.c (address_significant): Update.
5947
5948 2018-05-30 Joel Brobecker <brobecker@adacore.com>
5949
5950 * stack.c (func_command): Remove trailing newline in call to error.
5951
5952 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5953
5954 * regcache.h (regcache_raw_collect): Remove, update callers to
5955 use regcache::raw_collect.
5956 * regcache.c (regcache_raw_collect): Remove.
5957
5958 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5959
5960 * regcache.h (regcache_raw_supply): Remove, update callers to
5961 use detached_regcache::raw_supply.
5962 * regcache.c (regcache_raw_supply): Remove.
5963
5964 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5965
5966 * regcache.h (regcache_cooked_write_part): Remove, update
5967 callers to use regcache::cooked_write_part.
5968 * regcache.c (regcache_cooked_write_part): Remove.
5969
5970 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5971
5972 * regcache.h (regcache_cooked_read_part): Remove, update callers
5973 to use readable_regcache::cooked_read_part.
5974 * regcache.c (regcache_cooked_read_part): Remove.
5975
5976 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5977
5978 * regcache.h (regcache_cooked_read_value): Remove, update
5979 callers to use readable_regcache::cooked_read_value.
5980 * regcache.c (regcache_cooked_read_value): Remove.
5981
5982 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5983
5984 * regcache.h (regcache_cooked_write): Remove, update callers to
5985 use regcache::cooked_write.
5986 * regcache.c (regcache_cooked_write): Remove.
5987
5988 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5989
5990 * regcache.h (regcache_invalidate): Remove, update callers to
5991 use detached_regcache::invalidate instead.
5992 * regcache.c (regcache_invalidate): Remove.
5993
5994 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
5995
5996 * regcache.h (regcache_raw_write_part): Remove, update callers
5997 to use regcache::raw_write_part instead.
5998 * regcache.c (regcache_raw_write_part): Remove.
5999
6000 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6001
6002 * regcache.h (regcache_raw_read_part): Remove, update callers to
6003 use readable_regcache::raw_read_part instead.
6004 * regcache.c (regcache_raw_read_part): Remove.
6005
6006 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6007
6008 * regcache.h (regcache_cooked_read): Remove, update callers to
6009 use readable_regcache::cooked_read instead.
6010 * regcache.c (regcache_cooked_read): Remove.
6011
6012 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6013
6014 * regcache.h (regcache_raw_write): Remove, update callers to use
6015 regcache::raw_write instead.
6016 * regcache.c (regcache_raw_write): Remove.
6017
6018 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6019
6020 * regcache.h (regcache_raw_read): Remove, update callers to use
6021 readable_regcache::raw_read instead.
6022 * regcache.c (regcache_raw_read): Remove.
6023
6024 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6025
6026 * regcache.h (regcache_raw_update): Remove, update callers to
6027 use readable_regcache::raw_update instead.
6028 * regcache.c (regcache_raw_update): Remove.
6029
6030 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6031
6032 * regcache.h (regcache_register_status): Remove, update callers
6033 to use reg_buffer::get_register_status directly instead.
6034 * regcache.c (regcache_register_status): Remove.
6035
6036 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6037
6038 * regcache.h (regcache_get_ptid): Remove, update all callers to
6039 call regcache::ptid instead.
6040 * regcache.c (regcache_get_ptid): Remove.
6041
6042 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6043
6044 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
6045
6046 2018-05-30 Pedro Alves <palves@redhat.com>
6047
6048 * common/common-exceptions.h (exception_rethrow): Use
6049 ATTRIBUTE_NORETURN.
6050
6051 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
6052
6053 * breakpoint.c (print_solib_event, check_status_catch_solib):
6054 Remove struct keyword in range-based for loops.
6055 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
6056 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
6057 Likewise.
6058 * linespec.c (find_superclass_methods, search_minsyms_for_name):
6059 Likewise.
6060 * symfile.c (addr_info_make_relative): Likewise.
6061 * thread.c (value_in_thread_stack_temporaries): Likewise.
6062
6063 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
6064
6065 PR gdb/16841
6066 * valops.c (value_struct_elt_for_reference): Call check_typedef on
6067 aggregate type to get its real type before accessing it.
6068
6069 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
6070
6071 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
6072 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
6073 * coff-pe-read.c (add_pe_forwarded_sym): Replace
6074 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
6075 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
6076 * jit.c (jit_breakpoint_re_set_internal): Likewise.
6077 * printcmd.c (info_address_command): Likewise.
6078
6079 2018-05-29 Tom Tromey <tom@tromey.com>
6080
6081 * windows-nat.c (handle_exception): Update fall-through comment.
6082
6083 2018-05-29 Tom Tromey <tom@tromey.com>
6084
6085 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
6086 (struct program_space) <added_solibs>: Now a std::vector.
6087 * breakpoint.c (print_solib_event): Update.
6088 (check_status_catch_solib): Update.
6089 * progspace.c (clear_program_space_solib_cache): Update.
6090 * solib.c (update_solib_list): Update.
6091
6092 2018-05-29 Tom Tromey <tom@tromey.com>
6093
6094 * python/py-type.c (typy_richcompare): Update.
6095 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
6096 * gdbtypes.h (types_deeply_equal): Return bool.
6097 (types_equal): Likewise.
6098 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6099 declare VEC.
6100 (check_types_equal): Change worklist to std::vector. Return
6101 bool.
6102 (struct type_equality_entry): Add constructor.
6103 (compare_maybe_null_strings): Return bool.
6104 (check_types_worklist): Return bool. Change worklist to
6105 std::vector.
6106 (types_deeply_equal): Use std::vector.
6107 (types_equal): Return bool.
6108 (compare_maybe_null_strings): Simplify.
6109
6110 2018-05-29 Tom Tromey <tom@tromey.com>
6111
6112 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6113
6114 2018-05-29 Tom Tromey <tom@tromey.com>
6115
6116 * objc-lang.h: Don't include cp-support.h.
6117 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6118 declare VEC.
6119
6120 2018-05-27 Tom Tromey <tom@tromey.com>
6121
6122 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6123
6124 2018-05-25 Tom Tromey <tom@tromey.com>
6125
6126 * value.c (value::location): Initialize.
6127
6128 2018-05-25 Tom Tromey <tom@tromey.com>
6129
6130 * dbxread.c (init_bincl_list): Remove.
6131 (bincl_list): Now a std::vector.
6132 (bincls_allocated, next_bincl): Remove.
6133 (free_bincl_list, do_free_bincl_list_cleanup)
6134 (make_cleanup_free_bincl_list): Remove.
6135 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
6136 unique_xmalloc_ptr.
6137 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
6138 (struct header_file_location): Add constructor.
6139 (add_bincl_to_list): Remove.
6140
6141 2018-05-25 Tom Tromey <tom@tromey.com>
6142
6143 * tui/tui.c (tui_enable): Update.
6144 * mi/mi-interp.c (mi_interp::init): Update.
6145 * interps.h (class interp) <name>: New method.
6146 <m_name>: Rename from name.
6147 (~scoped_restore_interp): Update.
6148 * interps.c (interp::interp): Update.
6149 (interp_add, interp_set, interp_lookup_existing)
6150 (current_interp_named_p): Update.
6151
6152 2018-05-25 Tom Tromey <tom@tromey.com>
6153
6154 * interps.c (interp_name): Remove.
6155 * mi/mi-interp.c (mi_interp::init): Update.
6156 * interps.h (interp_name): Remove.
6157 (~scoped_restore_interp): Update.
6158 * tui/tui.c (tui_enable): Update.
6159
6160 2018-05-25 Tom Tromey <tom@tromey.com>
6161
6162 * utils.c (fputs_maybe_filtered): Update.
6163 * linespec.c (decode_line_full): Update.
6164 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
6165 (mi_print_breakpoint_for_event, mi_solib_loaded)
6166 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6167 (mi_user_selected_context_changed): Update.
6168 * mi/mi-main.c (mi_execute_command): Update.
6169 * cli/cli-script.c (execute_control_command): Update.
6170 * python/python.c (execute_gdb_command): Update.
6171 * solib.c (info_sharedlibrary_command): Update.
6172 * interps.c (interp_ui_out): Remove.
6173 * interps.h (interp_ui_out): Remove.
6174
6175 2018-05-25 Tom Tromey <tom@tromey.com>
6176
6177 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
6178 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
6179 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
6180
6181 2018-05-25 Tom Tromey <tom@tromey.com>
6182
6183 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
6184 * interps.c (interp_exec): Use scoped_restore.
6185
6186 2018-05-25 Tom Tromey <tom@tromey.com>
6187
6188 * remote.c (remote_target::remote_file_get): Use
6189 gdb::byte_vector.
6190 (remote_target::remote_file_put): Likewise.
6191
6192 2018-05-25 Tom Tromey <tom@tromey.com>
6193
6194 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
6195 a std::string.
6196 (get_pe_section_index, add_pe_exported_sym): Update.
6197 (read_pe_exported_syms): Use gdb::def_vector.
6198
6199 2018-05-25 Tom Tromey <tom@tromey.com>
6200
6201 * frame.c (remove_prev_frame): Remove.
6202 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
6203
6204 2018-05-25 Maciej W. Rozycki <macro@mips.com>
6205
6206 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
6207 Remove prototypes.
6208 * mips-linux-nat.c (supply_fpregset): Always call
6209 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
6210 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
6211 `mips_fill_fpregset'.
6212 * mips-linux-tdep.c (mips_supply_fpregset)
6213 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
6214 (mips_fill_fpregset_wrapper): Remove functions.
6215 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
6216 (mips_linux_fpregset): Remove variable.
6217 (mips_linux_iterate_over_regset_sections): Use
6218 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
6219 (mips_linux_o32_sigframe_init): Remove comment.
6220
6221 2018-05-25 Pedro Alves <palves@redhat.com>
6222
6223 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
6224 (struct readahead_cache, struct packet_reg, struct
6225 remote_arch_state, class remote_state): Move higher up in the
6226 file.
6227 (remote_target::m_remote_state): Now an object instead of a pointer.
6228 (remote_target::get_remote_state): Adjust.
6229
6230 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6231
6232 * stack.c (select_and_print_frame): Delete.
6233 (struct function_bounds): Move struct within function.
6234 (func_command): Most content moved into new function
6235 find_frame_for_function, use new function, print result, add
6236 function comment.
6237 (find_frame_for_function): New function, now returns a result.
6238
6239 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6240
6241 * stack.c (iterate_over_block_arg_vars): Fix comment.
6242 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
6243
6244 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6245
6246 PR gdb/23203
6247 * frame.c
6248 (scoped_restore_selected_frame::scoped_restore_selected_frame):
6249 Define.
6250 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
6251 Define.
6252 * frame.h (class scoped_restore_selected_frame): New class.
6253 * stack.c (print_frame_local_vars): Remove catching and rethrowing
6254 of any exception, use scoped_restore_selected_frame to restore the
6255 frame instead.
6256
6257 2018-05-24 Pedro Alves <palves@redhat.com>
6258
6259 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
6260 override.
6261
6262 2018-05-23 Tom Tromey <tom@tromey.com>
6263
6264 * complaints.c (struct complaints): Remove.
6265 (symfile_complaint_book): Remove.
6266 (series): New global.
6267 (complaint_internal): Update.
6268 (clear_complaints): Update.
6269
6270 2018-05-23 Tom Tromey <tom@tromey.com>
6271
6272 * complaints.c (counters): New global.
6273 (struct complain): Remove.
6274 (struct complaints) <root>: Remove.
6275 (complaint_sentinel): Remove.
6276 (symfile_complaint_book): Update.
6277 (find_complaint) Remove.
6278 (complaint_internal, clear_complaints): Update.
6279
6280 2018-05-23 Tom Tromey <tom@tromey.com>
6281
6282 * complaints.c (struct complain) <file, line>: Remove.
6283 (find_complaint): Remove file, line parameters.
6284 (complaint_internal): Update.
6285
6286 2018-05-23 Tom Tromey <tom@tromey.com>
6287
6288 * complaints.c (vcomplaint): Remove.
6289 (complaint_internal) Merge in contents of vcomplaint.
6290
6291 2018-05-23 Tom Tromey <tom@tromey.com>
6292
6293 * complaints.c (struct complaints) <explanation>: Remove.
6294 (symfile_explanations): Remove.
6295 (symfile_complaint_book): Update.
6296 (vcomplaint): Update.
6297 (struct explanation): Remove.
6298
6299 2018-05-23 Tom Tromey <tom@tromey.com>
6300
6301 * complaints.c (symfile_complaints): Remove.
6302 (complaint_internal): Remove "complaints" parameter.
6303 (clear_complaints, vcomplaint): Remove "c" parameter.
6304 (get_complaints): Remove.
6305 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6306 (dwarf2_debug_line_missing_file_complaint)
6307 (dwarf2_debug_line_missing_end_sequence_complaint)
6308 (dwarf2_complex_location_expr_complaint)
6309 (dwarf2_const_value_length_mismatch_complaint)
6310 (dwarf2_section_buffer_overflow_complaint)
6311 (dwarf2_macro_malformed_definition_complaint)
6312 (dwarf2_invalid_attrib_class_complaint)
6313 (create_addrmap_from_index, dw2_symtab_iter_next)
6314 (dw2_expand_marked_cus)
6315 (dw2_debug_names_iterator::find_vec_in_debug_names)
6316 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6317 (create_debug_type_hash_table, init_cutu_and_read_dies)
6318 (partial_die_parent_scope, add_partial_enumeration)
6319 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6320 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6321 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6322 (create_cus_hash_table, create_dwp_hash_table)
6323 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6324 (dwarf2_rnglists_process, dwarf2_ranges_process)
6325 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6326 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6327 (handle_struct_member_die, process_structure_scope)
6328 (read_array_type, read_common_block, read_module_type)
6329 (read_tag_pointer_type, read_typedef, read_base_type)
6330 (read_subrange_type, load_partial_dies, partial_die_info::read)
6331 (partial_die_info::read, partial_die_info::read)
6332 (partial_die_info::read, read_checked_initial_length_and_offset)
6333 (dwarf2_string_attr, read_formatted_entries)
6334 (dwarf_decode_line_header)
6335 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6336 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6337 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6338 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6339 (get_signatured_type, get_DW_AT_signature_type)
6340 (decode_locdesc, file_file_name, consume_improper_spaces)
6341 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6342 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6343 (dwarf2_symbol_mark_computed, set_die_type)
6344 (read_attribute_value): Update.
6345 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6346 Update.
6347 * dbxread.c (unknown_symtype_complaint)
6348 (lbrac_mismatch_complaint, repeated_header_complaint)
6349 (set_namestring, function_outside_compilation_unit_complaint)
6350 (read_dbx_symtab, process_one_symbol): Update.
6351 * gdbtypes.c (stub_noname_complaint): Update.
6352 * windows-nat.c (handle_unload_dll): Update.
6353 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6354 (decode_base_type): Update.
6355 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6356 (eb_complaint, record_include_begin, record_include_end)
6357 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6358 (process_xcoff_symbol, read_symbol)
6359 (function_outside_compilation_unit_complaint)
6360 (scan_xcoff_symtab): Update.
6361 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6362 * buildsym.c (finish_block_internal, make_blockvector)
6363 (end_symtab_get_static_block, augment_type_symtab): Update.
6364 * dtrace-probe.c (dtrace_process_dof)
6365 (dtrace_static_probe_ops::get_probes): Update.
6366 * complaints.h (struct complaint): Don't declare.
6367 (symfile_complaints): Remove.
6368 (complaint_internal): Remove "complaints" parameter.
6369 (complaint): Likewise.
6370 (clear_complaints): Likewise.
6371 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6372 (reread_symbols): Update.
6373 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6374 (dwarf2_frame_cache, decode_frame_entry): Update.
6375 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6376 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6377 (info_selectors_command): Update.
6378 * macrotab.c (macro_include, check_for_redefinition)
6379 (macro_undef): Update.
6380 * objfiles.c (filter_overlapping_sections): Update.
6381 * stabsread.c (invalid_cpp_abbrev_complaint)
6382 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6383 (define_symbol, error_type, read_type, rs6000_builtin_type)
6384 (stabs_method_name_from_physname, read_member_functions)
6385 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6386 (attach_fields_to_type, complain_about_struct_wipeout)
6387 (read_range_type, read_args, common_block_start)
6388 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6389 Update.
6390 * mdebugread.c (index_complaint, unknown_ext_complaint)
6391 (basic_type_complaint, bad_tag_guess_complaint)
6392 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6393 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6394 (parse_procedure, parse_lines)
6395 (function_outside_compilation_unit_complaint)
6396 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6397 (bad_tag_guess_complaint, reg_value_complaint): Update.
6398 * cp-support.c (demangled_name_complaint): Update.
6399 * macroscope.c (sal_macro_scope): Update.
6400 * dwarf-index-write.c (class debug_names): Update.
6401
6402 2018-05-23 Tom Tromey <tom@tromey.com>
6403
6404 * complaints.c (clear_complaints): Remove "noisy" parameter.
6405 * complaints.h (clear_complaints): Update.
6406 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6407 (reread_symbols): Update.
6408
6409 2018-05-23 Tom Tromey <tom@tromey.com>
6410
6411 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6412 SUBSEQUENT_MESSAGE.
6413 (vcomplaint, clear_complaints): Update.
6414 (symfile_explanations): Remove some messages.
6415
6416 2018-05-23 Tom Tromey <tom@tromey.com>
6417
6418 * complaints.c (internal_complaint): Remove.
6419 * complaints.h (internal_complaint): Remove.
6420
6421 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6422
6423 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6424
6425 2018-05-22 Pedro Alves <palves@redhat.com>
6426
6427 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6428 (remote_fileio_badfd, remote_fileio_return_errno)
6429 (remote_fileio_return_success, remote_fileio_func_open)
6430 (remote_fileio_func_open, remote_fileio_func_close)
6431 (remote_fileio_func_read, remote_fileio_func_write)
6432 (remote_fileio_func_lseek, remote_fileio_func_rename)
6433 (remote_fileio_func_unlink, remote_fileio_func_stat)
6434 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6435 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6436 remote_target parameter.
6437 (remote_fio_func_map) <func>: Add remote_target parameter.
6438 (do_remote_fileio_request, remote_fileio_request):
6439 * remote-fileio.h (remote_fileio_request):
6440 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6441 remote_target parameter.
6442 (remote_notif_process, handle_notification): Adjust to pass down
6443 the remote.
6444 (remote_notif_state_allocate): Add remote_target parameter. Save
6445 it.
6446 * remote-notif.h (struct remote_target): Forward declare.
6447 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6448 remote_target parameter.
6449 (struct remote_notif_state) <remote>: New field.
6450 (remote_notif_ack, remote_notif_parse): Add remote_target
6451 parameter.
6452 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6453 remote_target parameter.
6454 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6455 (threads_listing_context, rmt_thread_action, protocol_feature)
6456 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6457 (packet_result, struct threads_listing_context, remote_state):
6458 Move definitions and declarations higher up.
6459 (remote_target) <~remote_target>: Declare.
6460 (remote_download_command_source, remote_file_put, remote_file_get)
6461 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6462 (remote_hostio_pread_vFile, remote_hostio_send_command)
6463 (remote_hostio_set_filesystem, remote_hostio_open)
6464 (remote_hostio_close, remote_hostio_unlink, remote_state)
6465 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6466 (get_memory_write_packet_size, get_memory_read_packet_size)
6467 (append_pending_thread_resumptions, remote_detach_1)
6468 (append_resumption, remote_resume_with_vcont)
6469 (add_current_inferior_and_thread, wait_ns, wait_as)
6470 (process_stop_reply, remote_notice_new_inferior)
6471 (process_initial_stop_replies, remote_add_thread)
6472 (btrace_sync_conf, remote_btrace_maybe_reopen)
6473 (remove_new_fork_children, kill_new_fork_children)
6474 (discard_pending_stop_replies, stop_reply_queue_length)
6475 (check_pending_events_prevent_wildcard_vcont)
6476 (discard_pending_stop_replies_in_queue, stop_reply)
6477 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6478 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6479 (remote_interrupt_as, remote_interrupt_ns)
6480 (remote_get_noisy_reply, remote_query_attached)
6481 (remote_add_inferior, remote_current_thread, get_current_thread)
6482 (set_thread, set_general_thread, set_continue_thread)
6483 (set_general_process, write_ptid)
6484 (remote_unpack_thread_info_response, remote_get_threadinfo)
6485 (parse_threadlist_response, remote_get_threadlist)
6486 (remote_threadlist_iterator, remote_get_threads_with_ql)
6487 (remote_get_threads_with_qxfer)
6488 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6489 (get_offsets, remote_check_symbols, remote_supported_packet)
6490 (remote_query_supported, remote_packet_size)
6491 (remote_serial_quit_handler, remote_detach_pid)
6492 (remote_vcont_probe, remote_resume_with_hc)
6493 (send_interrupt_sequence, interrupt_query)
6494 (remote_notif_get_pending_events, fetch_register_using_p)
6495 (send_g_packet, process_g_packet, fetch_registers_using_g)
6496 (store_register_using_P, store_registers_using_G)
6497 (set_remote_traceframe, check_binary_download)
6498 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6499 (remote_xfer_live_readonly_partial, remote_read_bytes)
6500 (remote_send_printf, remote_flash_write, readchar)
6501 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6502 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6503 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6504 (extended_remote_disable_randomization, extended_remote_run)
6505 (send_environment_packet, extended_remote_environment_support)
6506 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6507 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6508 (packet_command): Now methods of ...
6509 (remote_target): ... this class.
6510 (m_remote_state) <remote_target>: New field.
6511 (struct remote_state) <stop_reply_queue,
6512 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6513 fields.
6514 (remote_state::remote_state): Allocate stop_reply_queue.
6515 (remote_state): Delete global.
6516 (get_remote_state_raw): Delete.
6517 (remote_target::get_remote_state): Allocate m_remote_state on
6518 demand.
6519 (get_current_remote_target): New.
6520 (remote_ops, extended_remote_ops): Delete.
6521 (wait_forever_enabled_p, remote_async_inferior_event_token):
6522 Delete, moved to struct remote_state.
6523 (remote_target::close): Delete self. Destruction bits split to
6524 ...
6525 (remote_target::~remote_target): ... this.
6526 (show_memory_packet_size): Adjust to use
6527 get_current_remote_target.
6528 (struct protocol_feature) <func>: Add remote_target parameter.
6529 All callers adjusted.
6530 (curr_quit_handler_target): New.
6531 (remote_serial_quit_handler): Reimplement.
6532 (remote_target::open_1): Adjust to use get_current_remote_target.
6533 Heap-allocate remote_target/extended_remote_target instances.
6534 (vcont_builder::vcont_builder): Add remote_target parameter, and
6535 save it in m_remote. All callers adjusted.
6536 (vcont_builder::m_remote): New field.
6537 (vcont_builder::restart, vcont_builder::flush)
6538 (vcont_builder::push_action): Use it.
6539 (remote_target::commit_resume): Use it.
6540 (struct queue_iter_param) <remote>: New field.
6541 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6542 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6543 (check_pending_event_prevents_wildcard_vcont_callback)
6544 (remote_target::check_pending_events_prevent_wildcard_vcont)
6545 (remote_target::discard_pending_stop_replies)
6546 (remote_target::discard_pending_stop_replies_in_queue)
6547 (remote_target::remote_notif_remove_queued_reply): Fill in
6548 'remote' field.
6549 (remote_notif_get_pending_events): New.
6550 (remote_target::readchar, remote_target::remote_serial_write):
6551 Save/restore curr_quit_handler_target.
6552 (putpkt): New.
6553 (kill_new_fork_children): Fill in 'remote' field.
6554 (packet_command): Use get_current_remote_target, defer to
6555 remote_target method of same name.
6556 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6557 parameter, and save it in m_remote. All callers adjusted.
6558 (scoped_remote_fd::release): Use m_remote.
6559 (scoped_remote_fd::m_remote): New field.
6560 (remote_file_put, remote_file_get, remote_file_delete): Use
6561 get_current_remote_target, defer to remote_target method of same
6562 name.
6563 (remote_btrace_reset): Add remote_state paremeter. Update all
6564 callers.
6565 (remote_async_inferior_event_handler). Pass down 'data'.
6566 (remote_new_objfile): Use get_current_remote_target.
6567 (remote_target::vcont_r_supported): New.
6568 (set_range_stepping): Use get_current_remote_target and
6569 remote_target::vcont_r_supported.
6570 (_initialize_remote): Don't allocate 'remote_state' and
6571 'stop_reply_queue' globals.
6572 * remote.h (struct remote_target): Forward declare.
6573 (getpkt, putpkt, remote_notif_get_pending_events): Add
6574 'remote_target' parameter.
6575
6576 2018-05-22 Pedro Alves <palves@redhat.com>
6577
6578 * remote.c (vcont_builder): Now a class. Make all data members
6579 private.
6580 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6581 Declare methods.
6582 (vcont_builder_restart): Rename to ...
6583 (vcont_builder::restart): ... this.
6584 (vcont_builder_flush): Rename to ...
6585 (vcont_builder::flush): ... this.
6586 (vcont_builder_push_action): Rename to ...
6587 (vcont_builder::push_action): ... this.
6588 (remote_target::commit_resume): Adjust.
6589
6590 2018-05-22 Pedro Alves <palves@redhat.com>
6591
6592 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6593 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6594 (get_fixed_memory_packet_size): New.
6595 (get_memory_packet_size): Use it.
6596 (set_memory_packet_size): Don't override the config size with
6597 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6598 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6599 Don't refer to get_memory_packet_size if not connected to a remote
6600 target. Show "(default)" if configured size is 0.
6601
6602 2018-05-22 Pedro Alves <palves@redhat.com>
6603
6604 * remote.c (remote_target::mourn_inferior): Move
6605 discard_pending_stop_replies call here from ...
6606 (_initialize_remote): ... here.
6607
6608 2018-05-22 Pedro Alves <palves@redhat.com>
6609
6610 * remote.c (compare_section_command): Remove set_general_process
6611 call.
6612
6613 2018-05-22 Pedro Alves <palves@redhat.com>
6614
6615 * remote.c (struct packet_reg, struct remote_arch_state):
6616 Move higher up in the file.
6617 (remote_state) <m_arch_states>: Store remote_arch_state values
6618 instead of remote_arch_state pointers.
6619 (remote_state::get_remote_arch_state): Adjust.
6620
6621 2018-05-22 Pedro Alves <palves@redhat.com>
6622
6623 * remote.c: Include <unordered_map>.
6624 (remote_state): Now a class.
6625 (remote_state) <get_remote_arch_state>: Declare method.
6626 <get_remote_arch_state>: New field.
6627 (remote_arch_state) <remote_arch_state>: Declare ctor.
6628 <regs>: Now a unique_ptr.
6629 (remote_gdbarch_data_handle): Delete.
6630 (get_remote_arch_state): Delete.
6631 (remote_state::get_remote_arch_state): New.
6632 (get_remote_state): Adjust to call remote_state's
6633 get_remote_arch_state method.
6634 (init_remote_state): Delete, bits factored out to ...
6635 (remote_arch_state::remote_arch_state): ... this new method.
6636 (get_remote_packet_size, get_memory_packet_size)
6637 (process_g_packet, remote_target::fetch_registers)
6638 (remote_target::prepare_to_store, store_registers_using_G)
6639 (remote_target::store_registers, remote_target::get_trace_status):
6640 Adjust to call remote_state's method.
6641 (_initialize_remote): Remove reference to
6642 remote_gdbarch_data_handle.
6643
6644 2018-05-22 Pedro Alves <palves@redhat.com>
6645
6646 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6647 pread>: New method declarations.
6648 (remote_target::open_1): Adjust.
6649 (readahead_cache_invalidate): Rename to ...
6650 (readahead_cache::invalidate): ... this, and adjust to be a class
6651 method.
6652 (readahead_cache_invalidate_fd): Rename to ...
6653 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6654 class method.
6655 (remote_hostio_pwrite): Adjust.
6656 (remote_hostio_pread_from_cache): Rename to ...
6657 (readahead_cache::pread): ... this, and adjust to be a class
6658 method.
6659 (remote_hostio_close): Adjust.
6660
6661 2018-05-22 Pedro Alves <palves@redhat.com>
6662
6663 * remote.c (remote_hostio_close_cleanup): Delete.
6664 (class scoped_remote_fd): New.
6665 (remote_file_put, remote_file_get): Use it.
6666
6667 2018-05-22 Pedro Alves <palves@redhat.com>
6668
6669 (struct vCont_action_support): Use bool and initialize all fields.
6670 (struct readahead_cache): Initialize all fields.
6671 (remote_state): Use bool and initialize all fields.
6672 (remote_state::remote_state, remote_state::~remote_state): New.
6673 (new_remote_state): Delete.
6674 (_initialize_remote): Use new to allocate remote_state.
6675
6676 2018-05-22 Pedro Alves <palves@redhat.com>
6677 張俊芝 <zjz@zjz.name>
6678
6679 PR gdb/22973
6680 * c-exp.y: Include "c-support.h".
6681 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6682 of tolower. Use c_ident_is_alpha to scan names.
6683 * c-lang.c: Include "c-support.h".
6684 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6685 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6686 * c-support.h: New file, with bits factored out from ...
6687 * cp-name-parser.y: ... this file.
6688 Include "c-support.h".
6689 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6690 c-support.h and renamed.
6691 (symbol_end, yylex): Adjust.
6692
6693 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6694
6695 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6696 parameter type to CORE_ADDR.
6697 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6698 parameter type in declaration to CORE_ADDR.
6699 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6700 target_auxv_search to get AT_HWCAP and use the result to get the
6701 target description.
6702 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6703 to CORE_ADDR. Remove the cast of the return value to unsigned
6704 long. Fix error predicate of target_auxv_search.
6705 (ppc_linux_nat_target::read_description): Change the type of the
6706 hwcap variable to CORE_ADDR.
6707
6708 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6709
6710 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6711 if the size of fpscr is larger than 32 bits.
6712
6713 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6714
6715 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6716 (ppc32_linux_vsxregmap): New global.
6717 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6718 regcache_supply_regset, and regcache_collect_regset.
6719 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6720 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6721 (fetch_vsx_register, store_vsx_register): Remove.
6722 (fetch_vsx_registers): Add regno parameter. Get regset using
6723 ppc_linux_vsxregset. Use regset to supply registers.
6724 (store_vsx_registers): Add regno parameter. Get regset using
6725 ppc_linux_vsxregset. Use regset to collect registers.
6726 (fetch_register): Call fetch_vsx_registers instead of
6727 fetch_vsx_register.
6728 (store_register): Call store_vsx_registers instead of
6729 store_vsx_register.
6730 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6731 new regno parameter.
6732 (store_ppc_registers): Call store_vsx_registers with -1 for the
6733 new regno parameter.
6734 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6735 (ppc_collect_vsxregset): Remove.
6736
6737 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6738
6739 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6740 offset fields.
6741 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6742 for vector register offset fields.
6743 (ppc64_fbsd_reg_offsets): Likewise.
6744 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6745 to vector register offset fields.
6746 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6747 to vector register offset fields.
6748 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6749 vector register offset fields.
6750 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6751 initializers for vector register offset fields.
6752 (rs6000_aix64_reg_offsets): Likewise.
6753 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6754 (ppc_supply_vrregset): Remove.
6755 (ppc_collect_vrregset): Remove.
6756 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6757 (ppc_linux_vrregset) : New function.
6758 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6759 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6760 (ppc32_linux_vrregset): Remove.
6761 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6762 and use result instead of ppc32_linux_vrregset.
6763 (ppc32_linux_reg_offsets): Remove initializers for vector register
6764 offset fields.
6765 (ppc64_linux_reg_offsets): Likewise.
6766 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6767 * ppc-linux-nat.c: Include regset.h.
6768 (gdb_vrregset_t): Adjust comment to account for little-endian
6769 mode.
6770 (supply_vrregset, fill_vrregset): Remove.
6771 (fetch_altivec_register, store_altivec_register): Remove.
6772 (fetch_altivec_registers): Add regno parameter. Get regset using
6773 ppc_linux_vrregset. Use regset to supply registers.
6774 (store_altivec_registers): Add regno parameter. Get regset using
6775 ppc_linux_vrregset. Use regset to collect registers.
6776 (fetch_register): Call fetch_altivec_registers instead of
6777 fetch_altivec_register.
6778 (store_register): Call store_altivec_registers instead of
6779 store_altivec_register.
6780 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6781 the new regno parameter.
6782 (store_ppc_registers): Call store_altivec_registers with -1 for
6783 the new regno parameter.
6784
6785 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6786
6787 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6788 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6789 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6790 (gdb_vrregset_t): Change array type size to
6791 PPC_LINUX_SIZEOF_VRREGSET.
6792 (gdb_vsxregset_t): Change array type size to
6793 PPC_LINUX_SIZEOF_VSXREGSET.
6794 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6795 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6796 PPC_LINUX_SIZEOF_VSXREGSET.
6797
6798 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6799
6800 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6801 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6802 nat/ppc-linux.c.
6803 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6804 ppc_linux_target_wordsize with tid.
6805 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6806 wordsize with tid.
6807 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6808 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6809 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6810 tid parameter. Remove static specifier.
6811 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6812 (ppc_linux_target_wordsize): New declaration.
6813
6814 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6815
6816 * arch/ppc-linux-common.c: New file.
6817 * arch/ppc-linux-common.h: New file.
6818 * arch/ppc-linux-tdesc.h: New file.
6819 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6820 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6821 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6822 arch/ppc-linux-tdesc.h.
6823 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6824 arch/ppc-linux-tdesc.h.
6825 (ppc_linux_nat_target::read_description): Remove target
6826 description matching code. Fill a ppc_linux_features struct and
6827 call ppc_linux_match_description with it. Move comment about ISA
6828 2.05 to ppc-linux-common.c.
6829 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6830 arch/ppc-linux-tdesc.h.
6831 (ppc_linux_core_read_description): Remove target description
6832 matching code. Fill a ppc_linux_features struct and call
6833 ppc_linux_match_description with it.
6834 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6835 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6836 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6837 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6838 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6839 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6840 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6841 (tdesc_powerpc_e500l): Remove.
6842
6843 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6844
6845 * ada-lang.c (catch_assert_command): Pass empty string instead
6846 of NULL for excep_string argument.
6847
6848 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6849
6850 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6851 the width of the requested register exceeds the width of the
6852 `ptrace' data type.
6853
6854 2018-05-21 Tom Tromey <tom@tromey.com>
6855
6856 * printcmd.c (output_command): Remove.
6857 (output_command_const): Rename to output_command.
6858 * valprint.h (output_command): Rename from output_command_const.
6859 * tracepoint.c (trace_dump_actions): Call output_command.
6860
6861 2018-05-21 Tom Tromey <tom@tromey.com>
6862
6863 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6864 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6865 * ada-lang.h (create_ada_exception_catchpoint): Update.
6866 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6867 std::string.
6868 (create_excep_cond_exprs, ~ada_catchpoint)
6869 (should_stop_exception, print_one_exception)
6870 (print_mention_exception, print_recreate_exception): Update.
6871 (ada_get_next_arg): Remove.
6872 (catch_ada_exception_command_split): Use std::string. Change type
6873 of "excep_string", "cond_string".
6874 (catch_ada_exception_command): Update.
6875 (create_ada_exception_catchpoint): Change type of excep_string.
6876 (ada_exception_sal): Remove excep_string parameter.
6877 (~ada_catchpoint): Remove.
6878
6879 2018-05-21 Tom Tromey <tom@tromey.com>
6880
6881 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
6882 cleanup.
6883
6884 2018-05-21 Tom Tromey <tom@tromey.com>
6885
6886 * ada-lang.c (ada_exception_message_1, ada_exception_message):
6887 Return unique_xmalloc_ptr.
6888 (print_it_exception): Update.
6889
6890 2018-05-21 Tom Tromey <tom@tromey.com>
6891
6892 * tracepoint.c (trace_dump_actions): Use std::string.
6893
6894 2018-05-21 Tom Tromey <tom@tromey.com>
6895
6896 * symfile.c (reread_symbols): Use std::string for original_name.
6897
6898 2018-05-21 Tom Tromey <tom@tromey.com>
6899
6900 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
6901 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
6902 constructor.
6903
6904 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
6905
6906 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
6907 instance to...
6908 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
6909 * objfiles.c (get_objfile_bfd_data): Allocate
6910 objfile_per_bfd_storage with obstack_new when allocating on
6911 obstack.
6912
6913 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6914
6915 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
6916 OBSTACK_ZALLOC.
6917 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
6918 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
6919 * mdebugread.c (mdebug_build_psymtabs): Likewise.
6920 (add_pending): Likewise.
6921 (parse_symbol): Likewise.
6922 (parse_partial_symbols): Likewise.
6923 (psymtab_to_symtab_1): Likewise.
6924 (new_psymtab): Likewise.
6925 (elfmdebug_build_psymtabs): Likewise.
6926 * minsyms.c (terminate_minimal_symbol_table): Likewise.
6927 * objfiles.c (get_objfile_bfd_data): Likewise.
6928 (objfile_register_static_link): Likewise.
6929 * psymtab.c (allocate_psymtab): Likewise.
6930 * stabsread.c (read_member_functions): Likewise.
6931 * xcoffread.c (xcoff_end_psymtab): Likewise.
6932
6933 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
6934
6935 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
6936 compiler supports std::is_trivially_constructible.
6937 * common/poison.h: Include obstack.h.
6938 (IsMallocable): Define to is_trivially_constructible if the
6939 compiler supports it, define to true_type otherwise.
6940 (xobnew): New.
6941 (XOBNEW): Redefine.
6942 (xobnewvec): New.
6943 (XOBNEWVEC): Redefine.
6944 * gdb_obstack.h (obstack_zalloc): New.
6945 (OBSTACK_ZALLOC): Redefine.
6946 (obstack_calloc): New.
6947 (OBSTACK_CALLOC): Redefine.
6948 (obstack_new): New.
6949 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
6950 (gdbarch_obstack): New declaration in gdbarch.h, definition in
6951 gdbarch.c.
6952 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
6953 obstack_calloc/obstack_zalloc.
6954 (gdbarch_obstack_zalloc): Remove.
6955 * target-descriptions.c (tdesc_data_init): Use obstack_new.
6956
6957 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6958
6959 * stack.c (backtrace_command_1): Remove useless variable int i.
6960
6961 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6962
6963 * stack.c (print_frame_info): Fix comment.
6964
6965 2018-05-18 Tom Tromey <tom@tromey.com>
6966
6967 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
6968 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
6969 (~dwarf2_per_objfile): Update
6970 (dwarf2_get_dwz_file): Use new.
6971 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
6972 unique_ptr.
6973
6974 2018-05-18 Tom Tromey <tom@tromey.com>
6975
6976 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
6977 unique_ptr.
6978 * dwarf2read.c (struct dwp_file): Add constructor and
6979 initializers.
6980 (open_and_init_dwp_file): Return a unique_ptr.
6981 (dwarf2_per_objfile, create_dwp_hash_table)
6982 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
6983 (lookup_dwo_unit_in_dwp): Update.
6984 (open_and_init_dwp_file, get_dwp_file): Update.
6985
6986 2018-05-18 Tom Tromey <tom@tromey.com>
6987
6988 * dwarf2read.c (dwarf2_per_objfile): Update.
6989 (struct mapped_index): Add initializers.
6990 (dwarf2_read_index): Use new.
6991 (dw2_symtab_iter_init): Update.
6992 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
6993 unique_ptr.
6994
6995 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
6996
6997 * dwarf2read.c (mapped_index) <total_size>: Remove.
6998
6999 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7000
7001 * unittests/format_pieces-selftests.c (test_format_specifier):
7002 Add ARI comments.
7003
7004 2018-05-18 Tom Tromey <tom@tromey.com>
7005
7006 * c-typeprint.c (maybe_print_hole): New function.
7007 (c_print_type_struct_field_offset): Update.
7008 (c_type_print_base_struct_union): Call maybe_print_hole.
7009
7010 2018-05-17 Keith Seitz <keiths@redhat.com>
7011
7012 * breakpoint.c (build_bpstat_chain): New function, moved from
7013 bpstat_stop_status.
7014 (bpstat_stop_status): Add optional parameter, `stop_chain'.
7015 If no stop chain is passed, call build_bpstat_chain to build it.
7016 * breakpoint.h (build_bpstat_chain): Declare.
7017 (bpstat_stop_status): Move documentation here from breakpoint.c.
7018 * infrun.c (handle_signal_stop): Before eliding inlined frames,
7019 build the stop chain and pass it to skip_inline_frames.
7020 Pass this stop chain to bpstat_stop_status.
7021 * inline-frame.c: Include breakpoint.h.
7022 (stopped_by_user_bp_inline_frame): New function.
7023 (skip_inline_frames): Add parameter `stop_chain'.
7024 Move documention to inline-frame.h.
7025 If non-NULL, use stopped_by_user_bp_inline_frame to determine
7026 whether the frame should be elided.
7027 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
7028 Add moved documentation and update for new parameter.
7029
7030 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7031
7032 PR cli/14975
7033 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7034 unittests/format_pieces-selftests.c.
7035 * common/format.h (format_piece) <operator==>: New.
7036 (format_pieces) <operator[]>: Remove.
7037 * common/format.c (format_pieces::format_pieces): Handle \e.
7038 * unittests/format_pieces-selftests.c: New.
7039
7040 2018-05-17 Tom Tromey <tom@tromey.com>
7041
7042 PR symtab/23010:
7043 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
7044 (dw2_instantiate_symtab): Add skip_partial parameter.
7045 (dw2_find_last_source_symtab, dw2_map_expand_apply)
7046 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
7047 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
7048 (dw2_expand_symtabs_matching_one)
7049 (dw2_find_pc_sect_compunit_symtab)
7050 (dw2_debug_names_lookup_symbol)
7051 (dw2_debug_names_expand_symtabs_for_function): Update.
7052 (init_cutu_and_read_dies): Add skip_partial parameter.
7053 (process_psymtab_comp_unit, build_type_psymtabs_1)
7054 (process_skeletonless_type_unit, load_partial_comp_unit)
7055 (psymtab_to_symtab_1): Update.
7056 (load_full_comp_unit): Add skip_partial parameter.
7057 (process_imported_unit_die, dwarf2_read_addr_index)
7058 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
7059 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
7060 (read_signatured_type): Update.
7061
7062 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7063
7064 * value.c (release_value): Remove unused variable.
7065 (record_latest_value): Likewise.
7066 (access_value_history): Likewise.
7067 (preserve_values): Likewise.
7068
7069 2018-05-17 Tom Tromey <tom@tromey.com>
7070
7071 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
7072 Initialize.
7073
7074 2018-05-16 Maciej W. Rozycki <macro@mips.com>
7075
7076 PR gdb/22286
7077 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
7078 Also handle registers whose width is not a multiple of
7079 PTRACE_TYPE_RET.
7080 (linux_nat_trad_target::store_register): Likewise.
7081
7082 2018-05-16 Tom Tromey <tom@tromey.com>
7083
7084 * gdbcore.h (core_bfd): Redefine.
7085 * corelow.c (core_target::close): Update.
7086 (core_target_open): Update.
7087 * progspace.h (struct program_space) <cbfd>: Now a
7088 gdb_bfd_ref_ptr.
7089
7090 2018-05-16 Tom Tromey <tom@tromey.com>
7091
7092 PR cli/19551:
7093 * symfile-add-flags.h (enum symfile_add_flags)
7094 <SYMFILE_NOT_FILENAME>: New constant.
7095 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
7096 objfile name from BFD.
7097 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7098 * minidebug.c (find_separate_debug_file_in_section): Put
7099 ".gnu_debugdata" into BFD's file name.
7100
7101 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7102
7103 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7104 Remove.
7105
7106 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7107
7108 PR binutils/21446
7109 * aarch64-tdep.c (aarch64_analyze_prologue,
7110 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7111 Indicate not interested in errors.
7112
7113 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7114
7115 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7116 Supply the MIPS_ZERO_REGNUM register.
7117
7118 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7119
7120 * mips-tdep.c (mask_address_var): Make variable static.
7121
7122 2018-05-14 Tom Tromey <tom@tromey.com>
7123
7124 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7125
7126 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7127
7128 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7129 FXSAVE_ADDR for the mxcsr register.
7130
7131 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7132
7133 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
7134
7135 2018-05-11 Pedro Alves <palves@redhat.com>
7136
7137 * corelow.c (core_target) <core_target>: No longer inline.
7138 Initialize m_core_gdbarch, m_core_vec and build the section table
7139 here.
7140 <~core_target>: New.
7141 <core_gdbarch, get_core_register_section>: New methods.
7142 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
7143 factored out from ...
7144 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
7145 (core_ops): Delete.
7146 (sniff_core_bfd): Add gdbarch parameter.
7147 (core_close): Delete, merged into ...
7148 (core_target::close): ... here. Delete self.
7149 (core_close_cleanup): Delete.
7150 (core_target_open): Allocate a core_target on the heap. Use a
7151 unique_ptr instead of a cleanup. Bits moved into the core_target
7152 ctor. Adjust to use core_target methods instead of globals.
7153 (get_core_register_section): Rename to ...
7154 (core_target::get_core_register_section): ... this and adjust.
7155 (struct get_core_registers_cb_data): New.
7156 (get_core_registers_cb): Use it. Use bool.
7157 (core_target::fetch_registers, core_target::files_info)
7158 (core_target::xfer_partial, core_target::read_description)
7159 (core_target::pid_to, core_target::thread_name): Adjust to
7160 reference class fields instead of globals.
7161 * target.h (struct target_ops_deleter, target_ops_up): New.
7162
7163 2018-05-11 Pedro Alves <palves@redhat.com>
7164
7165 * corefile.c (core_file_command): Move to corelow.c.
7166 * corelow.c (the_core_target): Delete.
7167 (core_file_command): Moved from corefile.c. Check exec_bfd
7168 instead of the_core_target. Use target_detach instead of calling
7169 into the_core_target directly.
7170 (maybe_say_no_core_file_now): New.
7171 (core_target::detach): Use it.
7172 (_initialize_corelow): Remove references to the_core_target.
7173 * gdbcore.h (the_core_target): Delete.
7174
7175 2018-05-11 Tom Tromey <tromey@redhat.com>
7176 Pedro Alves <palves@redhat.com>
7177
7178 * corefile.c (core_bfd): Remove.
7179 * gdbcore.h (core_bfd): Now a macro.
7180 * progspace.h (struct program_space) <cbfd>: New field.
7181
7182 2018-05-11 Tom Tromey <tom@tromey.com>
7183
7184 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
7185 gdb::def_vector.
7186
7187 2018-05-10 Tom Tromey <tom@tromey.com>
7188
7189 * configure: Rebuild.
7190 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
7191
7192 2018-05-10 Joel Brobecker <brobecker@adacore.com>
7193
7194 PR server/23158:
7195 * regformats/regdat.sh: Adjust script, following the addition
7196 of the new expedite_regs parameter to init_target_desc.
7197
7198 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
7199
7200 PR gdb/23127
7201 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
7202 set_gdbarch_significant_addr_bit.
7203 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
7204 set_gdbarch_significant_addr_bit.
7205 * utils.c (address_significant): Update to sign extend addr.
7206
7207 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
7208
7209 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
7210 (xtensa_linux_init_abi): Limit tdep->num_regs by
7211 tdep->num_nopriv_regs.
7212 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
7213 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
7214 not initialized.
7215
7216 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
7217
7218 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
7219
7220 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
7221
7222 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
7223 (I387_MXCSR_INIT_VAL): New constant.
7224 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
7225 buffer if it was supplied by the inferior.
7226 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
7227 (i387_xsave_get_clear_bv): New function.
7228 (i387_supply_xsave): Only read x87 control registers from the
7229 xsave buffer if the feature is enabled, and the state will have
7230 been written, otherwise, provide a suitable default.
7231 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
7232 including x87 control registers. Update control registers if they
7233 have changed from the default value, and mark features as enabled
7234 as required.
7235 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
7236
7237 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
7238
7239 * spu-tdep.c (info_spu_event_command): Fix output formatting.
7240
7241 2018-05-07 Tom Tromey <tom@tromey.com>
7242
7243 * configure: Rebuild.
7244 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
7245
7246 2018-05-07 Tom Tromey <tom@tromey.com>
7247
7248 PR tdep/20362:
7249 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
7250 bit. Use correct value for VDIV.
7251
7252 2018-05-04 Tom Tromey <tom@tromey.com>
7253
7254 * configure: Rebuild.
7255 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
7256
7257 2018-05-04 Tom Tromey <tom@tromey.com>
7258
7259 * linux-record.c (record_linux_system_call) <case
7260 RECORD_SYS_RECVFROM>: Add "break".
7261
7262 2018-05-04 Tom Tromey <tom@tromey.com>
7263
7264 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
7265 Add missing "break".
7266 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
7267 Add missing "break".
7268
7269 2018-05-04 Tom Tromey <tom@tromey.com>
7270
7271 * rs6000-tdep.c (ppc_process_record_op4)
7272 (ppc_process_record_op63): Add fall-through comment.
7273
7274 2018-05-04 Tom Tromey <tom@tromey.com>
7275
7276 * i386-tdep.c (i386_process_record): Add fall-through comment.
7277
7278 2018-05-04 Tom Tromey <tom@tromey.com>
7279
7280 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7281 comment.
7282
7283 2018-05-04 Tom Tromey <tom@tromey.com>
7284
7285 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7286 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7287 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7288 comment.
7289 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7290 comment.
7291 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7292 comment.
7293
7294 2018-05-04 Tom Tromey <tom@tromey.com>
7295
7296 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7297
7298 2018-05-04 Tom Tromey <tom@tromey.com>
7299
7300 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7301 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7302 * symfile.c (section_is_mapped): Fix fall-through comment.
7303 * stabsread.c (define_symbol, read_member_functions): Fix
7304 fall-through comment.
7305 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7306 comment.
7307 * remote.c (remote_wait_as): Fix fall-through comment.
7308 * p-exp.y (yylex): Fix fall-through comment.
7309 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7310 comment.
7311 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7312 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7313 * jv-exp.y (yylex): Fix fall-through comment.
7314 * go-exp.y (lex_one_token): Fix fall-through comment.
7315 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7316 fall-through comment.
7317 * f-exp.y (yylex): Fix fall-through comment.
7318 * dwarf2read.c (process_die): Fix fall-through comments.
7319 * dbxread.c (process_one_symbol): Fix fall-through comment.
7320 * d-exp.y (lex_one_token): Fix fall-through comment.
7321 * cp-name-parser.y (yylex): Fix fall-through comment.
7322 * coffread.c (coff_symtab_read): Fix fall-through comment.
7323 * c-exp.y (lex_one_token): Fix fall-through comment.
7324 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7325 comment.
7326 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7327 comment.
7328
7329 2018-05-04 Tom Tromey <tom@tromey.com>
7330
7331 PR python/22730:
7332 * NEWS: Mention gdb.execute change.
7333 * gdbcmd.h (execute_control_command): Don't declare.
7334 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7335 execute_control_commands, execute_control_commands_to_string.
7336 * cli/cli-script.h (execute_control_commands)
7337 (execute_control_commands_to_string): Declare.
7338 (execute_control_command): Add from_tty parameter.
7339 * cli/cli-script.c (execute_control_commands)
7340 (execute_control_commands_to_string): New functions.
7341 (execute_user_command): Use execute_control_commands.
7342 (execute_control_command_1): Add "from_tty" parameter. Update.
7343 (execute_control_command): Likewise.
7344
7345 2018-05-04 Tom Tromey <tom@tromey.com>
7346
7347 PR python/22731:
7348 * NEWS: Mention that breakpoint commands are writable.
7349 * python/py-breakpoint.c (bppy_set_commands): New function.
7350 (breakpoint_object_getset) <"commands">: Use it.
7351
7352 2018-05-04 Tom Tromey <tom@tromey.com>
7353
7354 * tracepoint.c (actions_command): Update.
7355 * mi/mi-cmd-break.c (mi_command_line_array)
7356 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7357 (mi_read_next_line): Remove.
7358 (mi_cmd_break_commands): Update.
7359 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7360 function_view.
7361 * cli/cli-script.c (get_command_line): Update.
7362 (process_next_line): Use function_view. Constify.
7363 (recurse_read_control_structure, read_command_lines)
7364 (read_command_lines_1): Change argument types to function_view.
7365 (do_define_command, document_command): Update.
7366 * breakpoint.h (check_tracepoint_command): Don't declare.
7367 * breakpoint.c (check_tracepoint_command): Remove.
7368 (commands_command_1, create_tracepoint_from_upload): Update.
7369
7370 2018-05-04 Tom Tromey <tom@tromey.com>
7371
7372 PR gdb/11750:
7373 * cli/cli-script.h (enum command_control_type) <define_control>:
7374 New constant.
7375 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7376 (build_command_line, execute_control_command_1)
7377 (process_next_line): Likewise.
7378 (do_define_command): New function, extracted from define_command.
7379 (define_command): Use it.
7380
7381 2018-05-04 Tom Tromey <tom@tromey.com>
7382
7383 * tracepoint.c (actions_command): Update.
7384 * cli/cli-script.h (read_command_lines): Update.
7385 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7386 (MAX_TMPBUF): Remove define.
7387 (define_command): Use string_printf.
7388 (document_command): Likewise.
7389 * breakpoint.c (commands_command_1): Update.
7390
7391 2018-05-04 Tom Tromey <tom@tromey.com>
7392
7393 * top.c (execute_command): Update.
7394 * cli/cli-script.h (print_command_lines): Now varargs.
7395 * cli/cli-script.c (print_command_lines): Now varargs.
7396 (execute_control_command_1) <case while_control, case if_control>:
7397 Update.
7398
7399 2018-05-04 Tom Tromey <tom@tromey.com>
7400
7401 * tracepoint.c (all_tracepoint_actions): Rename from
7402 all_tracepoint_actions_and_cleanup. Change return type.
7403 (actions_command, encode_actions_1, encode_actions)
7404 (trace_dump_actions, tdump_command): Update.
7405 * remote.c (remote_download_command_source): Update.
7406 * python/python.c (gdbpy_eval_from_control_command)
7407 (python_command, python_interactive_command): Update.
7408 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7409 * guile/guile.c (guile_command)
7410 (gdbscm_eval_from_control_command, guile_command): Update.
7411 * compile/compile.c (compile_code_command)
7412 (compile_print_command, compile_to_object): Update.
7413 * cli/cli-script.h (struct command_lines_deleter): New.
7414 (counted_command_line): New typedef.
7415 (struct command_line): Add constructor, destructor.
7416 <body_list>: Remove.
7417 <body_list_0, body_list_1>: New members.
7418 (command_line_up): Remove typedef.
7419 (read_command_lines, read_command_lines_1, get_command_line):
7420 Update.
7421 (copy_command_lines): Don't declare.
7422 * cli/cli-script.c (build_command_line): Use "new".
7423 (get_command_line): Return counted_command_line.
7424 (print_command_lines, execute_user_command)
7425 (execute_control_command_1, while_command, if_command): Update.
7426 (realloc_body_list): Remove.
7427 (process_next_line, recurse_read_control_structure): Update.
7428 (read_command_lines, read_command_lines_1): Return counted_command_line.
7429 (free_command_lines): Use "delete".
7430 (copy_command_lines): Remove.
7431 (define_command, document_command, show_user_1): Update.
7432 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7433 a counted_command_line.
7434 * breakpoint.h (counted_command_line): Remove typedef.
7435 (breakpoint_set_commands): Update.
7436 * breakpoint.c (check_no_tracepoint_commands)
7437 (validate_commands_for_breakpoint): Update.
7438 (breakpoint_set_commands): Change commands to be a
7439 counted_command_line.
7440 (commands_command_1, update_dprintf_command_list)
7441 (create_tracepoint_from_upload): Update.
7442
7443 2018-05-04 Tom Tromey <tom@tromey.com>
7444
7445 * cli/cli-decode.h (cmd_list_element): New constructor.
7446 (~cmd_list_element): New destructor.
7447 (struct cmd_list_element): Add initializers.
7448 * cli/cli-decode.c (do_add_cmd): Use "new".
7449 (delete_cmd): Use "delete".
7450
7451 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7452 Pedro Alves <palves@redhat.com>
7453
7454 PR breakpoints/19806 and support for PR external/20207.
7455 * NEWS: Mention Aarch64 watchpoint improvements.
7456 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7457 watchpoints and PR external/20207 watchpoints.
7458 * nat/aarch64-linux-hw-point.c
7459 (kernel_supports_any_contiguous_range): New.
7460 (aarch64_watchpoint_offset): New.
7461 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7462 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7463 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7464 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7465 next_addr_orig_p. Support PR external/20207 watchpoints.
7466 (aarch64_downgrade_regs): New.
7467 (aarch64_dr_state_insert_one_point): New parameters offset and
7468 addr_orig.
7469 (aarch64_dr_state_remove_one_point): Likewise.
7470 (aarch64_handle_breakpoint): Update caller.
7471 (aarch64_handle_aligned_watchpoint): Likewise.
7472 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7473 aligned_offset.
7474 (aarch64_linux_set_debug_regs): Remove const from state. Call
7475 aarch64_downgrade_regs.
7476 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7477 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7478 (DR_CONTROL_MASK): ... this.
7479 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7480 (unsigned int aarch64_watchpoint_offset): New prototype.
7481 (aarch64_linux_set_debug_regs): Remove const from state.
7482 * utils.c (align_up, align_down): Move to ...
7483 * common/common-utils.c (align_up, align_down): ... here.
7484 * utils.h (align_up, align_down): Move to ...
7485 * common/common-utils.h (align_up, align_down): ... here.
7486
7487 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7488
7489 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7490 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7491 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7492 Re-implement to match the ABI as summarized in GCC's
7493 gcc/config/sparc/sparc.c. All callers updated.
7494 (sparc32_store_arguments): Remove assertion.
7495
7496 2018-05-04 Tom Tromey <tom@tromey.com>
7497
7498 * printcmd.c: Don't include tui.h.
7499 (decode_format): Use skip_spaces.
7500
7501 2018-05-04 Tom Tromey <tom@tromey.com>
7502
7503 PR gdb/22619:
7504 * printcmd.c (last_count): New global.
7505 (x_command): Use saved count when repeating.
7506
7507 2018-05-04 Tom Tromey <tom@tromey.com>
7508
7509 * nto-procfs.c (do_closedir_cleanup): Remove.
7510 (procfs_pidlist): Use gdb_dir_up.
7511 * procfs.c (do_closedir_cleanup): Remove.
7512 (proc_update_threads): Use gdb_dir_up.
7513 * common/filestuff.h (struct gdb_dir_deleter): New.
7514 (gdb_dir_up): New typedef.
7515
7516 2018-05-04 Tom Tromey <tom@tromey.com>
7517
7518 * ada-lang.c (print_mention_exception): Use std::string.
7519
7520 2018-05-04 Tom Tromey <tom@tromey.com>
7521
7522 * ada-lang.c (create_excep_cond_exprs): Update.
7523 (ada_exception_catchpoint_cond_string): Use std::string.
7524
7525 2018-05-04 Tom Tromey <tom@tromey.com>
7526
7527 * ada-lang.c (xget_renaming_scope): Return std::string.
7528 (old_renaming_is_invisible): Update.
7529
7530 2018-05-04 Tom Tromey <tom@tromey.com>
7531
7532 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7533 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7534
7535 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7536
7537 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7538
7539 2018-05-04 Tom Tromey <tom@tromey.com>
7540
7541 * remote.c (remote_query_supported_append): Change type.
7542 (remote_check_symbols): Update.
7543
7544 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7545
7546 PR gdb/11420
7547 * configure.ac: Prepend libpython.
7548 * python/python-config.py: Likewise.
7549 * configure: Regenerate.
7550
7551 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7552
7553 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7554
7555 2018-05-03 Pedro Alves <palves@redhat.com>
7556
7557 * s390-linux-nat.c
7558 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7559 override. Write 'true' instead of '1'.
7560 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7561 declaration.
7562
7563 2018-05-02 Pedro Alves <palves@redhat.com>
7564
7565 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7566 add_inf_child_target.
7567 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7568 add_inf_child_target.
7569 * aix-thread.c (aix_thread_target_info): New.
7570 (aix_thread_target) <shortname, longname, doc>: Delete.
7571 <info>: New.
7572 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7573 add_inf_child_target.
7574 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7575 add_inf_child_target.
7576 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7577 add_inf_child_target.
7578 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7579 add_inf_child_target.
7580 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7581 add_inf_child_target.
7582 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7583 add_inf_child_target.
7584 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7585 add_inf_child_target.
7586 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7587 add_inf_child_target.
7588 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7589 add_inf_child_target.
7590 * bfd-target.c (target_bfd_target_info): New.
7591 (target_bfd) <shortname, longname, doc>: Delete.
7592 <info>: New.
7593 * bsd-kvm.c (bsd_kvm_target_info): New.
7594 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7595 <info>: New.
7596 (bsd_kvm_target::open): Rename to ...
7597 (bsd_kvm_target_open): ... this. Adjust.
7598 * bsd-uthread.c (bsd_uthread_target_info): New.
7599 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7600 <info>: New.
7601 * corefile.c (core_file_command): Adjust.
7602 * corelow.c (core_target_info): New.
7603 (core_target) <shortname, longname, doc>: Delete.
7604 <info>: New.
7605 (core_target::open): Rename to ...
7606 (core_target_open): ... this. Adjust.
7607 * ctf.c (ctf_target_info): New.
7608 (ctf_target) <shortname, longname, doc>: Delete.
7609 <info>: New.
7610 (ctf_target::open): Rename to ...
7611 (ctf_target_open): ... this.
7612 (_initialize_ctf): Adjust.
7613 * exec.c (exec_target_info): New.
7614 (exec_target) <shortname, longname, doc>: Delete.
7615 <info>: New.
7616 (exec_target::open): Rename to ...
7617 (exec_target_open): ... this.
7618 * gdbcore.h (core_target_open): Declare.
7619 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7620 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7621 add_inf_child_target.
7622 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7623 add_inf_child_target.
7624 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7625 add_inf_child_target.
7626 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7627 add_inf_child_target.
7628 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7629 add_inf_child_target.
7630 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7631 add_inf_child_target.
7632 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7633 add_inf_child_target.
7634 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7635 add_inf_child_target.
7636 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7637 add_inf_child_target.
7638 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7639 add_inf_child_target.
7640 * inf-child.c (inf_child_target_info): New.
7641 (inf_child_target::info): New.
7642 (inf_child_open_target): Remove 'target' parameter. Use
7643 get_native_target instead.
7644 (inf_child_target::open): Delete.
7645 (add_inf_child_target): New.
7646 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7647 Delete.
7648 <info>: New.
7649 (add_inf_child_target): Declare.
7650 (inf_child_open_target): Declare.
7651 * linux-thread-db.c (thread_db_target_info): New.
7652 (thread_db_target) <shortname, longname, doc>: Delete.
7653 <info>: New.
7654 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7655 add_inf_child_target.
7656 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7657 add_inf_child_target.
7658 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7659 add_inf_child_target.
7660 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7661 add_inf_child_target.
7662 * make-target-delegates (print_class): Adjust.
7663 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7664 add_inf_child_target.
7665 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7666 add_inf_child_target.
7667 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7668 add_inf_child_target.
7669 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7670 add_inf_child_target.
7671 * nto-procfs.c (nto_native_target_info): New.
7672 (nto_procfs_target_native) <shortname, longname, doc>:
7673 Delete.
7674 <info>: New.
7675 (nto_procfs_target_info): New.
7676 (nto_procfs_target_procfs) <shortname, longname, doc>:
7677 Delete.
7678 <info>: New.
7679 (init_procfs_targets): Adjust.
7680 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7681 add_inf_child_target.
7682 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7683 add_inf_child_target.
7684 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7685 add_inf_child_target.
7686 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7687 add_inf_child_target.
7688 * ravenscar-thread.c (ravenscar_target_info): New.
7689 (ravenscar_thread_target) <shortname, longname, doc>:
7690 Delete.
7691 <info>: New.
7692 * record-btrace.c (record_btrace_target_info):
7693 (record_btrace_target) <shortname, longname, doc>: Delete.
7694 <info>: New.
7695 (record_btrace_target::open): Rename to ...
7696 (record_btrace_target_open): ... this. Adjust.
7697 * record-full.c (record_longname, record_doc): New.
7698 (record_full_base_target) <shortname, longname, doc>: Delete.
7699 <info>: New.
7700 (record_full_target_info): New.
7701 (record_full_target): <shortname>: Delete.
7702 <info>: New.
7703 (record_full_core_open_1, record_full_open_1): Update comments.
7704 (record_full_base_target::open): Rename to ...
7705 (record_full_open): ... this.
7706 (cmd_record_full_restore): Update.
7707 (_initialize_record_full): Update.
7708 * remote-sim.c (remote_sim_target_info): New.
7709 (gdbsim_target) <shortname, longname, doc>: Delete.
7710 <info>: New.
7711 (gdbsim_target::open): Rename to ...
7712 (gdbsim_target_open): ... this.
7713 (_initialize_remote_sim): Adjust.
7714 * remote.c (remote_doc): New.
7715 (remote_target_info): New.
7716 (remote_target) <shortname, longname, doc>: Delete.
7717 <info>: New.
7718 (extended_remote_target_info): New.
7719 (extended_remote_target) <shortname, longname, doc>: Delete.
7720 <info>: New.
7721 (remote_target::open_1): Make static. Adjust.
7722 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7723 * s390-linux-nat.c (_initialize_s390_nat): Use
7724 add_inf_child_target.
7725 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7726 add_inf_child_target.
7727 * sol-thread.c (thread_db_target_info): New.
7728 (sol_thread_target) <shortname, longname, doc>: Delete.
7729 <info>: New.
7730 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7731 add_inf_child_target.
7732 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7733 add_inf_child_target.
7734 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7735 add_inf_child_target.
7736 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7737 add_inf_child_target.
7738 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7739 add_inf_child_target.
7740 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7741 add_inf_child_target.
7742 * spu-linux-nat.c (_initialize_spu_nat): Use
7743 add_inf_child_target.
7744 * spu-multiarch.c (spu_multiarch_target_info): New.
7745 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7746 <info>: New.
7747 * target-delegates.c: Regenerate.
7748 * target.c: Include <unordered_map>.
7749 (target_ops_p): Delete.
7750 (DEF_VEC_P(target_ops_p)): Delete.
7751 (target_factories): New.
7752 (test_target_info): New.
7753 (test_target_ops::info): New.
7754 (open_target): Adjust to use target_factories.
7755 (add_target_with_completer): Rename to ...
7756 (add_target): ... this. Change prototype. Register target_info
7757 and open callback in target_factories. Register target_info in
7758 command context instead of target_ops.
7759 (add_target): Delete old implementation.
7760 (add_deprecated_target_alias): Change prototype. Adjust.
7761 (the_native_target): New.
7762 (set_native_target, get_native_target): New.
7763 (find_default_run_target): Use the_native_target.
7764 (find_attach_target, find_run_target): Simplify.
7765 (target_ops::open): Delete.
7766 (dummy_target_info): New.
7767 (dummy_target::shortname, dummy_target::longname)
7768 (dummy_target::doc): Delete.
7769 (dummy_target::info): New.
7770 (debug_target::shortname, debug_target::longname)
7771 (debug_target::doc): Delete.
7772 (debug_target::info): New.
7773 * target.h (struct target_info): New.
7774 (target_ops::~target_ops): Add comment.
7775 (target_ops::info): New.
7776 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7777 longer virtual. Implement in terms of target_info.
7778 (set_native_target, get_native_target): Declare.
7779 (target_open_ftype): New.
7780 (add_target, add_target_with_completer)
7781 (add_deprecated_target_alias): Change prototype.
7782 (test_target) <shortname, longname, doc>: Delete.
7783 <info>: New.
7784 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7785 add_inf_child_target.
7786 * tracefile-tfile.c (tfile_target_info): New.
7787 (tfile_target) <shortname, longname, doc>: Delete.
7788 <info>: New.
7789 (tfile_target::open): Rename to ...
7790 (tfile_target_open): ... this.
7791 (_initialize_tracefile_tfile): Adjust.
7792 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7793 add_inf_child_target.
7794 * windows-nat.c (_initialize_windows_nat): Use
7795 add_inf_child_target.
7796 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7797 add_inf_child_target.
7798
7799 2018-05-02 Pedro Alves <palves@redhat.com>
7800
7801 * linux-nat.h (linux_nat_target) <low_new_thread,
7802 low_delete_thread, low_new_fork, low_forget_process,
7803 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7804 New virtual methods.
7805 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7806 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7807 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7808 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7809 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7810 Delete.
7811 * linux-fork.c (delete_fork): Adjust to call low method.
7812 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7813 (linux_nat_new_fork, linux_nat_forget_process_hook)
7814 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7815 (linux_nat_status_is_event):
7816 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7817 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7818 to call low method.
7819 (sigtrap_is_event): Rename to ...
7820 (linux_nat_target::low_status_is_event): ... this.
7821 (linux_nat_set_status_is_event): Delete.
7822 (save_stop_reason, linux_nat_wait_1)
7823 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7824 low methods.
7825 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7826 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7827 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7828 (linux_nat_set_prepare_to_resume): Delete.
7829 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7830 low virtual methods.
7831 * amd64-linux-nat.c: Likewise.
7832 * arm-linux-nat.c: Likewise.
7833 * i386-linux-nat.c: Likewise.
7834 * ia64-linux-nat.c: Likewise.
7835 * mips-linux-nat.c: Likewise.
7836 * ppc-linux-nat.c: Likewise.
7837 * s390-linux-nat.c: Likewise.
7838 * sparc64-linux-nat.c: Likewise.
7839 * x86-linux-nat.c: Likewise.
7840 * x86-linux-nat.h: Include "nat/x86-linux.h".
7841 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7842 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7843 Override methods.
7844
7845 2018-05-02 Pedro Alves <palves@redhat.com>
7846
7847 * target.h (target_ops)
7848 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7849 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7850 stopped_by_watchpoint, have_continuable_watchpoint,
7851 stopped_data_address, watchpoint_addr_within_range,
7852 can_accel_watchpoint_condition, can_run, thread_alive,
7853 has_all_memory, has_memory, has_stack, has_registers,
7854 has_execution, can_async_p, is_async_p, supports_non_stop,
7855 always_non_stop_p, can_execute_reverse, supports_multi_process,
7856 supports_enable_disable_tracepoint,
7857 supports_disable_randomization, supports_string_tracing,
7858 supports_evaluation_of_breakpoint_conditions,
7859 can_run_breakpoint_commands, filesystem_is_local,
7860 can_download_tracepoint, get_trace_state_variable_value,
7861 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7862 record_is_replaying, record_will_replay,
7863 augmented_libraries_svr4_read>: Adjust to return bool.
7864 * aarch64-linux-nat.c: All implementations adjusted.
7865 * aix-thread.c: All implementations adjusted.
7866 * arm-linux-nat.c: All implementations adjusted.
7867 * breakpoint.c: All implementations adjusted.
7868 * bsd-kvm.c: All implementations adjusted.
7869 * bsd-uthread.c: All implementations adjusted.
7870 * corelow.c: All implementations adjusted.
7871 * ctf.c: All implementations adjusted.
7872 * darwin-nat.c: All implementations adjusted.
7873 * darwin-nat.h: All implementations adjusted.
7874 * exec.c: All implementations adjusted.
7875 * fbsd-nat.c: All implementations adjusted.
7876 * fbsd-nat.h: All implementations adjusted.
7877 * gnu-nat.c: All implementations adjusted.
7878 * gnu-nat.h: All implementations adjusted.
7879 * go32-nat.c: All implementations adjusted.
7880 * ia64-linux-nat.c: All implementations adjusted.
7881 * inf-child.c: All implementations adjusted.
7882 * inf-child.h: All implementations adjusted.
7883 * inf-ptrace.c: All implementations adjusted.
7884 * inf-ptrace.h: All implementations adjusted.
7885 * linux-nat.c: All implementations adjusted.
7886 * linux-nat.h: All implementations adjusted.
7887 * mips-linux-nat.c: All implementations adjusted.
7888 * nto-procfs.c: All implementations adjusted.
7889 * ppc-linux-nat.c: All implementations adjusted.
7890 * procfs.c: All implementations adjusted.
7891 * ravenscar-thread.c: All implementations adjusted.
7892 * record-btrace.c: All implementations adjusted.
7893 * record-full.c: All implementations adjusted.
7894 * remote-sim.c: All implementations adjusted.
7895 * remote.c: All implementations adjusted.
7896 * s390-linux-nat.c: All implementations adjusted.
7897 * sol-thread.c: All implementations adjusted.
7898 * spu-multiarch.c: All implementations adjusted.
7899 * target-delegates.c: All implementations adjusted.
7900 * target.c: All implementations adjusted.
7901 * target.h: All implementations adjusted.
7902 * tracefile-tfile.c: All implementations adjusted.
7903 * tracefile.c: All implementations adjusted.
7904 * tracefile.h: All implementations adjusted.
7905 * windows-nat.c: All implementations adjusted.
7906 * x86-linux-nat.h: All implementations adjusted.
7907 * x86-nat.h: All implementations adjusted.
7908
7909 2018-05-02 Pedro Alves <palves@redhat.com>
7910
7911 * make-target-delegates (scan_target_h): Don't trim lines here.
7912 Replace sequences of tabs and/or whitespace with a single
7913 whitespace.
7914 (top level, parsing methods): Trim each line before processing it
7915 here.
7916
7917 2018-05-02 Pedro Alves <palves@redhat.com>
7918 John Baldwin <jhb@freebsd.org>
7919
7920 * target.h (enum strata) <debug_stratum>: New.
7921 (struct target_ops) <all delegation methods>: Replace by C++
7922 virtual methods, and drop "to_" prefix. All references updated
7923 throughout.
7924 <to_shortname, to_longname, to_doc, to_data,
7925 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
7926 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
7927 virtual methods. All references updated throughout.
7928 <can_attach, supports_terminal_ours, can_create_inferior,
7929 get_thread_control_capabilities, attach_no_wait>: New
7930 virtual methods.
7931 <insert_breakpoint, remove_breakpoint>: Now
7932 TARGET_DEFAULT_NORETURN methods.
7933 <info_proc>: Now returns bool.
7934 <to_magic>: Delete.
7935 (OPS_MAGIC): Delete.
7936 (current_target): Delete. All references replaced by references
7937 to ...
7938 (target_stack): ... this. New.
7939 (target_shortname, target_longname): Adjust.
7940 (target_can_run): Now a function declaration.
7941 (default_child_has_all_memory, default_child_has_memory)
7942 (default_child_has_stack, default_child_has_registers)
7943 (default_child_has_execution): Remove target_ops parameter.
7944 (complete_target_initialization): Delete.
7945 (memory_breakpoint_target): New template class.
7946 (test_target_ops): Refactor as a C++ class with virtual methods.
7947 * make-target-delegates (NAME_PART): Tighten.
7948 (POINTER_PART, CP_SYMBOL): New.
7949 (SIMPLE_RETURN_PART): Reimplement.
7950 (VEC_RETURN_PART): Expect less.
7951 (RETURN_PART, VIRTUAL_PART): New.
7952 (METHOD): Adjust to C++ virtual methods.
7953 (scan_target_h): Remove reference to C99.
7954 (dname): Output "target_ops::" prefix.
7955 (write_function_header): Adjust to output a C++ class method.
7956 (write_declaration): New.
7957 (write_delegator): Adjust to output a C++ class method.
7958 (tdname): Output "dummy_target::" prefix.
7959 (write_tdefault, write_debugmethod): Adjust to output a C++ class
7960 method.
7961 (tdefault_names, debug_names): Delete.
7962 (return_types, tdefaults, styles, argtypes_array): New.
7963 (top level): All methods are delegators.
7964 (print_class): New.
7965 (top level): Print dummy_target and debug_target classes.
7966 * target-delegates.c: Regenerate.
7967 * target-debug.h (target_debug_print_enum_info_proc_what)
7968 (target_debug_print_thread_control_capabilities)
7969 (target_debug_print_thread_info_p): New.
7970 * target.c (dummy_target): Delete.
7971 (the_dummy_target, the_debug_target): New.
7972 (target_stack): Now extern.
7973 (set_targetdebug): Push/unpush debug target.
7974 (default_child_has_all_memory, default_child_has_memory)
7975 (default_child_has_stack, default_child_has_registers)
7976 (default_child_has_execution): Remove target_ops parameter.
7977 (complete_target_initialization): Delete.
7978 (add_target_with_completer): No longer call
7979 complete_target_initialization.
7980 (target_supports_terminal_ours): Use regular delegation.
7981 (update_current_target): Delete.
7982 (push_target): No longer check magic number. Don't call
7983 update_current_target.
7984 (unpush_target): Don't call update_current_target.
7985 (target_is_pushed): No longer check magic number.
7986 (target_require_runnable): Skip for all stratums over
7987 process_stratum.
7988 (target_ops::info_proc): New.
7989 (target_info_proc): Use find_target_at and
7990 find_default_run_target.
7991 (target_supports_disable_randomization): Use regular delegation.
7992 (target_get_osdata): Use find_target_at.
7993 (target_ops::open, target_ops::close, target_ops::can_attach)
7994 (target_ops::attach, target_ops::can_create_inferior)
7995 (target_ops::create_inferior, target_ops::can_run)
7996 (target_can_run): New.
7997 (default_fileio_target): Use regular delegation.
7998 (target_ops::fileio_open, target_ops::fileio_pwrite)
7999 (target_ops::fileio_pread, target_ops::fileio_fstat)
8000 (target_ops::fileio_close, target_ops::fileio_unlink)
8001 (target_ops::fileio_readlink): New.
8002 (target_fileio_open_1, target_fileio_unlink)
8003 (target_fileio_readlink): Always call the target method. Handle
8004 FILEIO_ENOSYS.
8005 (return_zero, return_zero_has_execution): Delete.
8006 (init_dummy_target): Delete.
8007 (dummy_target::dummy_target, dummy_target::shortname)
8008 (dummy_target::longname, dummy_target::doc)
8009 (debug_target::debug_target, debug_target::shortname)
8010 (debug_target::longname, debug_target::doc): New.
8011 (target_supports_delete_record): Use regular delegation.
8012 (setup_target_debug): Delete.
8013 (maintenance_print_target_stack): Skip debug_stratum.
8014 (initialize_targets): Instantiate the_dummy_target and
8015 the_debug_target.
8016 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
8017 use target_stack.
8018 (target_auxv_search, fprint_target_auxv): Adjust.
8019 (info_auxv_command): Adjust to use target_stack.
8020 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
8021 * exceptions.c (print_flush): Handle a NULL target_stack.
8022 * regcache.c (target_ops_no_register): Refactor as class with
8023 virtual methods.
8024
8025 * exec.c (exec_target): New class.
8026 (exec_ops): Now an exec_target.
8027 (exec_open, exec_close_1, exec_get_section_table)
8028 (exec_xfer_partial, exec_files_info, exec_has_memory)
8029 (exec_make_note_section): Refactor as exec_target methods.
8030 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
8031 Delete.
8032 (exec_target::find_memory_regions): New.
8033 (_initialize_exec): Don't call init_exec_ops.
8034 * gdbcore.h (exec_file_clear): Delete.
8035
8036 * corefile.c (core_target): Delete.
8037 (core_file_command): Adjust.
8038 * corelow.c (core_target): New class.
8039 (the_core_target): New.
8040 (core_close): Remove target_ops parameter.
8041 (core_close_cleanup): Adjust.
8042 (core_target::close): New.
8043 (core_open, core_detach, get_core_registers, core_files_info)
8044 (core_xfer_partial, core_thread_alive, core_read_description)
8045 (core_pid_to_str, core_thread_name, core_has_memory)
8046 (core_has_stack, core_has_registers, core_info_proc): Rework as
8047 core_target methods.
8048 (ignore, core_remove_breakpoint, init_core_ops): Delete.
8049 (_initialize_corelow): Initialize the_core_target.
8050 * gdbcore.h (core_target): Delete.
8051 (the_core_target): New.
8052
8053 * ctf.c: (ctf_target): New class.
8054 (ctf_ops): Now a ctf_target.
8055 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
8056 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
8057 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
8058 methods.
8059 (init_ctf_ops): Delete.
8060 (_initialize_ctf): Don't call it.
8061 * tracefile-tfile.c (tfile_target): New class.
8062 (tfile_ops): Now a tfile_target.
8063 (tfile_open, tfile_close, tfile_files_info)
8064 (tfile_get_tracepoint_status, tfile_trace_find)
8065 (tfile_fetch_registers, tfile_xfer_partial)
8066 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
8067 Refactor as tfile_target methods.
8068 (tfile_xfer_partial_features): Remove target_ops parameter.
8069 (init_tfile_ops): Delete.
8070 (_initialize_tracefile_tfile): Don't call it.
8071 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
8072 (tracefile_has_stack, tracefile_has_registers)
8073 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
8074 tracefile_target methods.
8075 (init_tracefile_ops): Delete.
8076 (tracefile_target::tracefile_target): New.
8077 * tracefile.h: Include "target.h".
8078 (tracefile_target): New class.
8079 (init_tracefile_ops): Delete.
8080
8081 * spu-multiarch.c (spu_multiarch_target): New class.
8082 (spu_ops): Now a spu_multiarch_target.
8083 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
8084 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
8085 (spu_search_memory, spu_mourn_inferior): Refactor as
8086 spu_multiarch_target methods.
8087 (init_spu_ops): Delete.
8088 (_initialize_spu_multiarch): Remove references to init_spu_ops,
8089 complete_target_initialization.
8090
8091 * ravenscar-thread.c (ravenscar_thread_target): New class.
8092 (ravenscar_ops): Now a ravenscar_thread_target.
8093 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
8094 (ravenscar_thread_alive, ravenscar_pid_to_str)
8095 (ravenscar_fetch_registers, ravenscar_store_registers)
8096 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
8097 (ravenscar_stopped_by_hw_breakpoint)
8098 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8099 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8100 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8101 methods.
8102 (init_ravenscar_thread_ops): Delete.
8103 (_initialize_ravenscar): Remove references to
8104 init_ravenscar_thread_ops and complete_target_initialization.
8105
8106 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8107 (bsd_uthread_target): New class.
8108 (bsd_uthread_ops): Now a bsd_uthread_target.
8109 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8110 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8111 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8112 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8113 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8114 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8115 (bsd_uthread_target): Delete function.
8116 (_initialize_bsd_uthread): Remove reference to
8117 complete_target_initialization.
8118
8119 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8120 (target_bfd): ... this new class.
8121 (target_bfd_xfer_partial, target_bfd_get_section_table)
8122 (target_bfd_close): Refactor as target_bfd methods.
8123 (target_bfd::~target_bfd): New.
8124 (target_bfd_reopen): Adjust.
8125 (target_bfd::close): New.
8126
8127 * record-btrace.c (record_btrace_target): New class.
8128 (record_btrace_ops): Now a record_btrace_target.
8129 (record_btrace_open, record_btrace_stop_recording)
8130 (record_btrace_disconnect, record_btrace_close)
8131 (record_btrace_async, record_btrace_info)
8132 (record_btrace_insn_history, record_btrace_insn_history_range)
8133 (record_btrace_insn_history_from, record_btrace_call_history)
8134 (record_btrace_call_history_range)
8135 (record_btrace_call_history_from, record_btrace_record_method)
8136 (record_btrace_is_replaying, record_btrace_will_replay)
8137 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
8138 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
8139 (record_btrace_store_registers, record_btrace_prepare_to_store)
8140 (record_btrace_to_get_unwinder)
8141 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
8142 (record_btrace_commit_resume, record_btrace_wait)
8143 (record_btrace_stop, record_btrace_can_execute_reverse)
8144 (record_btrace_stopped_by_sw_breakpoint)
8145 (record_btrace_supports_stopped_by_sw_breakpoint)
8146 (record_btrace_stopped_by_hw_breakpoint)
8147 (record_btrace_supports_stopped_by_hw_breakpoint)
8148 (record_btrace_update_thread_list, record_btrace_thread_alive)
8149 (record_btrace_goto_begin, record_btrace_goto_end)
8150 (record_btrace_goto, record_btrace_stop_replaying_all)
8151 (record_btrace_execution_direction)
8152 (record_btrace_prepare_to_generate_core)
8153 (record_btrace_done_generating_core): Refactor as
8154 record_btrace_target methods.
8155 (init_record_btrace_ops): Delete.
8156 (_initialize_record_btrace): Remove reference to
8157 init_record_btrace_ops.
8158 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
8159 the execution_direction global.
8160 (record_full_base_target, record_full_target)
8161 (record_full_core_target): New classes.
8162 (record_full_ops): Now a record_full_target.
8163 (record_full_core_ops): Now a record_full_core_target.
8164 (record_full_target::detach, record_full_target::disconnect)
8165 (record_full_core_target::disconnect)
8166 (record_full_target::mourn_inferior, record_full_target::kill):
8167 New.
8168 (record_full_open, record_full_close, record_full_async): Refactor
8169 as methods of the record_full_base_target class.
8170 (record_full_resume, record_full_commit_resume): Refactor
8171 as methods of the record_full_target class.
8172 (record_full_wait, record_full_stopped_by_watchpoint)
8173 (record_full_stopped_data_address)
8174 (record_full_stopped_by_sw_breakpoint)
8175 (record_full_supports_stopped_by_sw_breakpoint)
8176 (record_full_stopped_by_hw_breakpoint)
8177 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
8178 methods of the record_full_base_target class.
8179 (record_full_store_registers, record_full_xfer_partial)
8180 (record_full_insert_breakpoint, record_full_remove_breakpoint):
8181 Refactor as methods of the record_full_target class.
8182 (record_full_can_execute_reverse, record_full_get_bookmark)
8183 (record_full_goto_bookmark, record_full_execution_direction)
8184 (record_full_record_method, record_full_info, record_full_delete)
8185 (record_full_is_replaying, record_full_will_replay)
8186 (record_full_goto_begin, record_full_goto_end, record_full_goto)
8187 (record_full_stop_replaying): Refactor as methods of the
8188 record_full_base_target class.
8189 (record_full_core_resume, record_full_core_kill)
8190 (record_full_core_fetch_registers)
8191 (record_full_core_prepare_to_store)
8192 (record_full_core_store_registers, record_full_core_xfer_partial)
8193 (record_full_core_insert_breakpoint)
8194 (record_full_core_remove_breakpoint)
8195 (record_full_core_has_execution): Refactor
8196 as methods of the record_full_core_target class.
8197 (record_full_base_target::supports_delete_record): New.
8198 (init_record_full_ops): Delete.
8199 (init_record_full_core_ops): Delete.
8200 (record_full_save): Refactor as method of the
8201 record_full_base_target class.
8202 (_initialize_record_full): Remove references to
8203 init_record_full_ops and init_record_full_core_ops.
8204
8205 * remote.c (remote_target, extended_remote_target): New classes.
8206 (remote_ops): Now a remote_target.
8207 (extended_remote_ops): Now an extended_remote_target.
8208 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
8209 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
8210 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
8211 (remote_pass_signals, remote_set_syscall_catchpoint)
8212 (remote_program_signals, )
8213 (remote_thread_always_alive): Remove target_ops parameter.
8214 (remote_thread_alive, remote_thread_name)
8215 (remote_update_thread_list, remote_threads_extra_info)
8216 (remote_static_tracepoint_marker_at)
8217 (remote_static_tracepoint_markers_by_strid)
8218 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
8219 (remote_open): Refactor as methods of remote_target.
8220 (extended_remote_open, extended_remote_detach)
8221 (extended_remote_attach, extended_remote_post_attach):
8222 (extended_remote_supports_disable_randomization)
8223 (extended_remote_create_inferior): : Refactor as method of
8224 extended_remote_target.
8225 (remote_set_permissions, remote_open_1, remote_detach)
8226 (remote_follow_fork, remote_follow_exec, remote_disconnect)
8227 (remote_resume, remote_commit_resume, remote_stop)
8228 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
8229 (remote_terminal_ours, remote_wait, remote_fetch_registers)
8230 (remote_prepare_to_store, remote_store_registers)
8231 (remote_flash_erase, remote_flash_done, remote_files_info)
8232 (remote_kill, remote_mourn, remote_insert_breakpoint)
8233 (remote_remove_breakpoint, remote_insert_watchpoint)
8234 (remote_watchpoint_addr_within_range)
8235 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
8236 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
8237 (remote_supports_stopped_by_sw_breakpoint)
8238 (remote_stopped_by_hw_breakpoint)
8239 (remote_supports_stopped_by_hw_breakpoint)
8240 (remote_stopped_by_watchpoint, remote_stopped_data_address)
8241 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
8242 (remote_verify_memory): Refactor as methods of remote_target.
8243 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
8244 parameter.
8245 (remote_xfer_partial, remote_get_memory_xfer_limit)
8246 (remote_search_memory, remote_rcmd, remote_memory_map)
8247 (remote_pid_to_str, remote_get_thread_local_address)
8248 (remote_get_tib_address, remote_read_description): Refactor as
8249 methods of remote_target.
8250 (remote_target::fileio_open, remote_target::fileio_pwrite)
8251 (remote_target::fileio_pread, remote_target::fileio_close): New.
8252 (remote_hostio_readlink, remote_hostio_fstat)
8253 (remote_filesystem_is_local, remote_can_execute_reverse)
8254 (remote_supports_non_stop, remote_supports_disable_randomization)
8255 (remote_supports_multi_process, remote_supports_cond_breakpoints)
8256 (remote_supports_enable_disable_tracepoint)
8257 (remote_supports_string_tracing)
8258 (remote_can_run_breakpoint_commands, remote_trace_init)
8259 (remote_download_tracepoint, remote_can_download_tracepoint)
8260 (remote_download_trace_state_variable, remote_enable_tracepoint)
8261 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
8262 (remote_trace_start, remote_get_trace_status)
8263 (remote_get_tracepoint_status, remote_trace_stop)
8264 (remote_trace_find, remote_get_trace_state_variable_value)
8265 (remote_save_trace_data, remote_get_raw_trace_data)
8266 (remote_set_disconnected_tracing, remote_core_of_thread)
8267 (remote_set_circular_trace_buffer, remote_traceframe_info)
8268 (remote_get_min_fast_tracepoint_insn_len)
8269 (remote_set_trace_buffer_size, remote_set_trace_notes)
8270 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
8271 (remote_disable_btrace, remote_teardown_btrace)
8272 (remote_read_btrace, remote_btrace_conf)
8273 (remote_augmented_libraries_svr4_read, remote_load)
8274 (remote_pid_to_exec_file, remote_can_do_single_step)
8275 (remote_execution_direction, remote_thread_handle_to_thread_info):
8276 Refactor as methods of remote_target.
8277 (init_remote_ops, init_extended_remote_ops): Delete.
8278 (remote_can_async_p, remote_is_async_p, remote_async)
8279 (remote_thread_events, remote_upload_tracepoints)
8280 (remote_upload_trace_state_variables): Refactor as methods of
8281 remote_target.
8282 (_initialize_remote): Remove references to init_remote_ops and
8283 init_extended_remote_ops.
8284
8285 * remote-sim.c (gdbsim_target): New class.
8286 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8287 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8288 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8289 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8290 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8291 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8292 Refactor as methods of gdbsim_target.
8293 (gdbsim_ops): Now a gdbsim_target.
8294 (init_gdbsim_ops): Delete.
8295 (gdbsim_cntrl_c): Adjust.
8296 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8297
8298 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8299 (the_amd64_linux_nat_target): New.
8300 (amd64_linux_fetch_inferior_registers)
8301 (amd64_linux_store_inferior_registers): Refactor as methods of
8302 amd64_linux_nat_target.
8303 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8304 * i386-linux-nat.c: Don't include "linux-nat.h".
8305 (i386_linux_nat_target): New class.
8306 (the_i386_linux_nat_target): New.
8307 (i386_linux_fetch_inferior_registers)
8308 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8309 as methods of i386_linux_nat_target.
8310 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8311 * inf-child.c (inf_child_ops): Delete.
8312 (inf_child_fetch_inferior_registers)
8313 (inf_child_store_inferior_registers): Delete.
8314 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8315 methods of inf_child_target.
8316 (inf_child_target::supports_terminal_ours)
8317 (inf_child_target::terminal_init)
8318 (inf_child_target::terminal_inferior)
8319 (inf_child_target::terminal_ours_for_output)
8320 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8321 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8322 New.
8323 (inf_child_open, inf_child_disconnect, inf_child_close)
8324 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8325 (inf_child_post_startup_inferior, inf_child_can_run)
8326 (inf_child_pid_to_exec_file): Refactor as methods of
8327 inf_child_target.
8328 (inf_child_follow_fork): Delete.
8329 (inf_child_target::can_create_inferior)
8330 (inf_child_target::can_attach): New.
8331 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8332 (inf_child_target::has_stack, inf_child_target::has_registers)
8333 (inf_child_target::has_execution): New.
8334 (inf_child_fileio_open, inf_child_fileio_pwrite)
8335 (inf_child_fileio_pread, inf_child_fileio_fstat)
8336 (inf_child_fileio_close, inf_child_fileio_unlink)
8337 (inf_child_fileio_readlink, inf_child_use_agent)
8338 (inf_child_can_use_agent): Refactor as methods of
8339 inf_child_target.
8340 (return_zero, inf_child_target): Delete.
8341 (inf_child_target::inf_child_target): New.
8342 * inf-child.h: Include "target.h".
8343 (inf_child_target): Delete function prototype.
8344 (inf_child_target): New class.
8345 (inf_child_open_target, inf_child_mourn_inferior)
8346 (inf_child_maybe_unpush_target): Delete.
8347 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8348 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8349 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8350 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8351 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8352 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8353 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8354 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8355 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8356 methods of inf_ptrace_target.
8357 (inf_ptrace_target): Delete function.
8358 * inf-ptrace.h: Include "inf-child.h".
8359 (inf_ptrace_target): Delete function declaration.
8360 (inf_ptrace_target): New class.
8361 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8362 * linux-nat.c (linux_target): New.
8363 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8364 (linux_nat_target::~linux_nat_target): New.
8365 (linux_child_post_attach, linux_child_post_startup_inferior)
8366 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8367 (linux_child_remove_fork_catchpoint)
8368 (linux_child_insert_vfork_catchpoint)
8369 (linux_child_remove_vfork_catchpoint)
8370 (linux_child_insert_exec_catchpoint)
8371 (linux_child_remove_exec_catchpoint)
8372 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8373 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8374 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8375 (linux_nat_stopped_data_address)
8376 (linux_nat_stopped_by_sw_breakpoint)
8377 (linux_nat_supports_stopped_by_sw_breakpoint)
8378 (linux_nat_stopped_by_hw_breakpoint)
8379 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8380 (linux_nat_kill, linux_nat_mourn_inferior)
8381 (linux_nat_xfer_partial, linux_nat_thread_alive)
8382 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8383 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8384 (linux_child_static_tracepoint_markers_by_strid)
8385 (linux_nat_is_async_p, linux_nat_can_async_p)
8386 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8387 (linux_nat_supports_multi_process)
8388 (linux_nat_supports_disable_randomization, linux_nat_async)
8389 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8390 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8391 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8392 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8393 methods of linux_nat_target.
8394 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8395 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8396 parameter.
8397 (check_stopped_by_watchpoint): Adjust.
8398 (linux_xfer_partial): Delete.
8399 (linux_target_install_ops, linux_target, linux_nat_add_target):
8400 Delete.
8401 (linux_nat_target::linux_nat_target): New.
8402 * linux-nat.h: Include "inf-ptrace.h".
8403 (linux_nat_target): New.
8404 (linux_target, linux_target_install_ops, linux_nat_add_target):
8405 Delete function declarations.
8406 (linux_target): Declare global.
8407 * linux-thread-db.c (thread_db_target): New.
8408 (thread_db_target::thread_db_target): New.
8409 (thread_db_ops): Delete.
8410 (the_thread_db_target): New.
8411 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8412 (thread_db_update_thread_list, thread_db_pid_to_str)
8413 (thread_db_extra_thread_info)
8414 (thread_db_thread_handle_to_thread_info)
8415 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8416 (thread_db_resume): Refactor as methods of thread_db_target.
8417 (init_thread_db_ops): Delete.
8418 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8419 * x86-linux-nat.c: Don't include "linux-nat.h".
8420 (super_post_startup_inferior): Delete.
8421 (x86_linux_nat_target::~x86_linux_nat_target): New.
8422 (x86_linux_child_post_startup_inferior)
8423 (x86_linux_read_description, x86_linux_enable_btrace)
8424 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8425 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8426 methods of x86_linux_nat_target.
8427 (x86_linux_create_target): Delete. Bits folded ...
8428 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8429 pointer.
8430 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8431 (x86_linux_nat_target): New class.
8432 (x86_linux_create_target): Delete.
8433 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8434 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8435 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8436 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8437 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8438 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8439 make extern.
8440 (x86_use_watchpoints): Delete.
8441 * x86-nat.h: Include "breakpoint.h" and "target.h".
8442 (x86_use_watchpoints): Delete.
8443 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8444 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8445 (x86_insert_watchpoint, x86_remove_watchpoint)
8446 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8447 (x86_stopped_by_hw_breakpoint): New declarations.
8448 (x86_nat_target): New template class.
8449
8450 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8451 (the_ppc_linux_nat_target): New.
8452 (ppc_linux_fetch_inferior_registers)
8453 (ppc_linux_can_use_hw_breakpoint)
8454 (ppc_linux_region_ok_for_hw_watchpoint)
8455 (ppc_linux_ranged_break_num_registers)
8456 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8457 (ppc_linux_insert_mask_watchpoint)
8458 (ppc_linux_remove_mask_watchpoint)
8459 (ppc_linux_can_accel_watchpoint_condition)
8460 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8461 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8462 (ppc_linux_watchpoint_addr_within_range)
8463 (ppc_linux_masked_watch_num_registers)
8464 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8465 (ppc_linux_read_description): Refactor as methods of
8466 ppc_linux_nat_target.
8467 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8468
8469 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8470 (procfs_target): New class.
8471 (the_procfs_target): New.
8472 (procfs_target): Delete function.
8473 (procfs_auxv_parse, procfs_attach, procfs_detach)
8474 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8475 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8476 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8477 (procfs_create_inferior, procfs_update_thread_list)
8478 (procfs_thread_alive, procfs_pid_to_str)
8479 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8480 (procfs_stopped_data_address, procfs_insert_watchpoint)
8481 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8482 (proc_find_memory_regions, procfs_info_proc)
8483 (procfs_make_note_section): Refactor as methods of procfs_target.
8484 (_initialize_procfs): Adjust.
8485 * sol-thread.c (sol_thread_target): New class.
8486 (sol_thread_ops): Now a sol_thread_target.
8487 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8488 (sol_thread_fetch_registers, sol_thread_store_registers)
8489 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8490 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8491 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8492 (init_sol_thread_ops): Delete.
8493 (_initialize_sol_thread): Adjust. Remove references to
8494 init_sol_thread_ops and complete_target_initialization.
8495
8496 * windows-nat.c (windows_nat_target): New class.
8497 (windows_fetch_inferior_registers)
8498 (windows_store_inferior_registers, windows_resume, windows_wait)
8499 (windows_attach, windows_detach, windows_pid_to_exec_file)
8500 (windows_files_info, windows_create_inferior)
8501 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8502 (windows_close, windows_pid_to_str, windows_xfer_partial)
8503 (windows_get_tib_address, windows_get_ada_task_ptid)
8504 (windows_thread_name, windows_thread_alive): Refactor as
8505 windows_nat_target methods.
8506 (do_initial_windows_stuff): Adjust.
8507 (windows_target): Delete function.
8508 (_initialize_windows_nat): Adjust.
8509
8510 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8511 (darwin_mourn_inferior, darwin_kill_inferior)
8512 (darwin_create_inferior, darwin_attach, darwin_detach)
8513 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8514 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8515 (darwin_supports_multi_process): Refactor as darwin_nat_target
8516 methods.
8517 (darwin_resume_to, darwin_files_info): Delete.
8518 (_initialize_darwin_inferior): Rename to ...
8519 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8520 * darwin-nat.h: Include "inf-child.h".
8521 (darwin_nat_target): New class.
8522 (darwin_complete_target): Delete.
8523 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8524 (darwin_target): New.
8525 (i386_darwin_fetch_inferior_registers)
8526 (i386_darwin_store_inferior_registers): Refactor as methods of
8527 darwin_nat_target.
8528 (darwin_complete_target): Delete, with ...
8529 (_initialize_i386_darwin_nat): ... bits factored out here.
8530
8531 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8532 (the_alpha_linux_nat_target): New.
8533 (alpha_linux_register_u_offset): Refactor as
8534 alpha_linux_nat_target method.
8535 (_initialize_alpha_linux_nat): Adjust.
8536 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8537 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8538 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8539 methods of linux_nat_trad_target.
8540 (linux_trad_target): Delete.
8541 * linux-nat-trad.h (linux_trad_target): Delete function.
8542 (linux_nat_trad_target): New class.
8543 * mips-linux-nat.c (mips_linux_nat_target): New class.
8544 (super_fetch_registers, super_store_registers, super_close):
8545 Delete.
8546 (the_mips_linux_nat_target): New.
8547 (mips64_linux_regsets_fetch_registers)
8548 (mips64_linux_regsets_store_registers)
8549 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8550 (mips_linux_register_u_offset, mips_linux_read_description)
8551 (mips_linux_can_use_hw_breakpoint)
8552 (mips_linux_stopped_by_watchpoint)
8553 (mips_linux_stopped_data_address)
8554 (mips_linux_region_ok_for_hw_watchpoint)
8555 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8556 (mips_linux_close): Refactor as methods of mips_linux_nat.
8557 (_initialize_mips_linux_nat): Adjust to C++ification.
8558
8559 * aix-thread.c (aix_thread_target): New class.
8560 (aix_thread_ops): Now an aix_thread_target.
8561 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8562 (aix_thread_fetch_registers, aix_thread_store_registers)
8563 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8564 (aix_thread_thread_alive, aix_thread_pid_to_str)
8565 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8566 Refactor as methods of aix_thread_target.
8567 (init_aix_thread_ops): Delete.
8568 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8569 and complete_target_initialization.
8570 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8571 (rs6000_nat_target): New class.
8572 (the_rs6000_nat_target): New.
8573 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8574 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8575 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8576 (super_create_inferior): Delete.
8577 (_initialize_rs6000_nat): Adjust to C++ification.
8578
8579 * arm-linux-nat.c (arm_linux_nat_target): New class.
8580 (the_arm_linux_nat_target): New.
8581 (arm_linux_fetch_inferior_registers)
8582 (arm_linux_store_inferior_registers, arm_linux_read_description)
8583 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8584 (arm_linux_remove_hw_breakpoint)
8585 (arm_linux_region_ok_for_hw_watchpoint)
8586 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8587 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8588 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8589 arm_linux_nat_target.
8590 (_initialize_arm_linux_nat): Adjust to C++ification.
8591
8592 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8593 (the_aarch64_linux_nat_target): New.
8594 (aarch64_linux_fetch_inferior_registers)
8595 (aarch64_linux_store_inferior_registers)
8596 (aarch64_linux_child_post_startup_inferior)
8597 (aarch64_linux_read_description)
8598 (aarch64_linux_can_use_hw_breakpoint)
8599 (aarch64_linux_insert_hw_breakpoint)
8600 (aarch64_linux_remove_hw_breakpoint)
8601 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8602 (aarch64_linux_region_ok_for_hw_watchpoint)
8603 (aarch64_linux_stopped_data_address)
8604 (aarch64_linux_stopped_by_watchpoint)
8605 (aarch64_linux_watchpoint_addr_within_range)
8606 (aarch64_linux_can_do_single_step): Refactor as methods of
8607 aarch64_linux_nat_target.
8608 (super_post_startup_inferior): Delete.
8609 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8610
8611 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8612 (the_hppa_linux_nat_target): New.
8613 (hppa_linux_fetch_inferior_registers)
8614 (hppa_linux_store_inferior_registers): Refactor as methods of
8615 hppa_linux_nat_target.
8616 (_initialize_hppa_linux_nat): Adjust to C++ification.
8617
8618 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8619 (the_ia64_linux_nat_target): New.
8620 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8621 (ia64_linux_stopped_data_address)
8622 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8623 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8624 ia64_linux_nat_target methods.
8625 (super_xfer_partial): Delete.
8626 (_initialize_ia64_linux_nat): Adjust to C++ification.
8627
8628 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8629 (the_m32r_linux_nat_target): New.
8630 (m32r_linux_fetch_inferior_registers)
8631 (m32r_linux_store_inferior_registers): Refactor as
8632 m32r_linux_nat_target methods.
8633 (_initialize_m32r_linux_nat): Adjust to C++ification.
8634
8635 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8636 (the_m68k_linux_nat_target): New.
8637 (m68k_linux_fetch_inferior_registers)
8638 (m68k_linux_store_inferior_registers): Refactor as
8639 m68k_linux_nat_target methods.
8640 (_initialize_m68k_linux_nat): Adjust to C++ification.
8641
8642 * s390-linux-nat.c (s390_linux_nat_target): New class.
8643 (the_s390_linux_nat_target): New.
8644 (s390_linux_fetch_inferior_registers)
8645 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8646 (s390_insert_watchpoint, s390_remove_watchpoint)
8647 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8648 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8649 (s390_auxv_parse, s390_read_description): Refactor as methods of
8650 s390_linux_nat_target.
8651 (_initialize_s390_nat): Adjust to C++ification.
8652
8653 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8654 (the_sparc_linux_nat_target): New.
8655 (_initialize_sparc_linux_nat): Adjust to C++ification.
8656 * sparc-nat.c (sparc_fetch_inferior_registers)
8657 (sparc_store_inferior_registers): Remove target_ops parameter.
8658 * sparc-nat.h (sparc_fetch_inferior_registers)
8659 (sparc_store_inferior_registers): Remove target_ops parameter.
8660 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8661 (the_sparc64_linux_nat_target): New.
8662 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8663
8664 * spu-linux-nat.c (spu_linux_nat_target): New class.
8665 (the_spu_linux_nat_target): New.
8666 (spu_child_post_startup_inferior, spu_child_post_attach)
8667 (spu_child_wait, spu_fetch_inferior_registers)
8668 (spu_store_inferior_registers, spu_xfer_partial)
8669 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8670 methods.
8671 (_initialize_spu_nat): Adjust to C++ification.
8672
8673 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8674 (the_tilegx_linux_nat_target): New.
8675 (fetch_inferior_registers, store_inferior_registers):
8676 Refactor as methods.
8677 (_initialize_tile_linux_nat): Adjust to C++ification.
8678
8679 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8680 (the_xtensa_linux_nat_target): New.
8681 (xtensa_linux_fetch_inferior_registers)
8682 (xtensa_linux_store_inferior_registers): Refactor as
8683 xtensa_linux_nat_target methods.
8684 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8685
8686 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8687 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8688 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8689 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8690 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8691 (fbsd_stopped_by_sw_breakpoint)
8692 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8693 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8694 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8695 (fbsd_post_startup_inferior, fbsd_post_attach)
8696 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8697 (fbsd_set_syscall_catchpoint)
8698 (super_xfer_partial, super_resume, super_wait)
8699 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8700 (fbsd_handle_debug_trap): Remove target_ops parameter.
8701 (fbsd_nat_add_target): Delete.
8702 * fbsd-nat.h: Include "inf-ptrace.h".
8703 (fbsd_nat_add_target): Delete.
8704 (USE_SIGTRAP_SIGINFO): Define.
8705 (fbsd_nat_target): New class.
8706
8707 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8708 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8709 (amd64bsd_target): Delete.
8710 * amd64-bsd-nat.h: New file.
8711 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8712 "x86-bsd-nat.h".
8713 (amd64_fbsd_nat_target): New class.
8714 (the_amd64_fbsd_nat_target): New.
8715 (amd64fbsd_read_description): Refactor as method of
8716 amd64_fbsd_nat_target.
8717 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8718 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8719 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8720 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8721 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8722 (i386bsd_target): Delete.
8723 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8724 (i386bsd_fetch_inferior_registers)
8725 (i386bsd_store_inferior_registers): Declare.
8726 (i386_bsd_nat_target): New class.
8727 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8728 (the_i386_fbsd_nat_target): New.
8729 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8730 i386_fbsd_nat_target methods.
8731 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8732 (_initialize_i386fbsd_nat): Adjust to C++ification.
8733 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8734 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8735 (_initialize_x86_bsd_nat): Adjust to C++ification.
8736 * x86-bsd-nat.h: Include "x86-nat.h".
8737 (x86bsd_target): Delete declaration.
8738 (x86bsd_nat_target): New class.
8739
8740 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8741 (the_aarch64_fbsd_nat_target): New.
8742 (aarch64_fbsd_fetch_inferior_registers)
8743 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8744 aarch64_fbsd_nat_target.
8745 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8746 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8747 (the_alpha_bsd_nat_target): New.
8748 (alphabsd_fetch_inferior_registers)
8749 (alphabsd_store_inferior_registers): Refactor as
8750 alpha_bsd_nat_target methods.
8751 (_initialize_alphabsd_nat): Refactor as methods of
8752 alpha_bsd_nat_target.
8753 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8754 (the_amd64_nbsd_nat_target): New.
8755 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8756 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8757 (the_amd64_obsd_nat_target): New.
8758 (_initialize_amd64obsd_nat): Adjust to C++ification.
8759 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8760 (the_arm_fbsd_nat_target): New.
8761 (arm_fbsd_fetch_inferior_registers)
8762 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8763 (_initialize_arm_fbsd_nat): Refactor as methods of
8764 arm_fbsd_nat_target.
8765 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8766 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8767 (the_arm_netbsd_nat_target): New.
8768 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8769 arm_netbsd_nat_target.
8770 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8771 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8772 (the_hppa_nbsd_nat_target): New.
8773 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8774 hppa_nbsd_nat_target methods.
8775 (_initialize_hppanbsd_nat): Adjust to C++ification.
8776 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8777 (the_hppa_obsd_nat_target): New.
8778 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8779 methods of hppa_obsd_nat_target.
8780 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8781 add_target.
8782 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8783 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8784 add_target.
8785 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8786 (_initialize_i386obsd_nat): Use add_target.
8787 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8788 (the_m68k_bsd_nat_target): New.
8789 (m68kbsd_fetch_inferior_registers)
8790 (m68kbsd_store_inferior_registers): Refactor as methods of
8791 m68k_bsd_nat_target.
8792 (_initialize_m68kbsd_nat): Adjust to C++ification.
8793 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8794 (the_mips_fbsd_nat_target): New.
8795 (mips_fbsd_fetch_inferior_registers)
8796 (mips_fbsd_store_inferior_registers): Refactor as methods of
8797 mips_fbsd_nat_target.
8798 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8799 add_target.
8800 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8801 (the_mips_nbsd_nat_target): New.
8802 (mipsnbsd_fetch_inferior_registers)
8803 (mipsnbsd_store_inferior_registers): Refactor as methods of
8804 mips_nbsd_nat_target.
8805 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8806 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8807 (the_mips64_obsd_nat_target): New.
8808 (mips64obsd_fetch_inferior_registers)
8809 (mips64obsd_store_inferior_registers): Refactor as methods of
8810 mips64_obsd_nat_target.
8811 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8812 add_target.
8813 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8814 nbsd_nat_target.
8815 * nbsd-nat.h: Include "inf-ptrace.h".
8816 (nbsd_nat_target): New class.
8817 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8818 (obsd_wait): Refactor as methods of obsd_nat_target.
8819 (obsd_add_target): Delete.
8820 * obsd-nat.h: Include "inf-ptrace.h".
8821 (obsd_nat_target): New class.
8822 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8823 (the_ppc_fbsd_nat_target): New.
8824 (ppcfbsd_fetch_inferior_registers)
8825 (ppcfbsd_store_inferior_registers): Refactor as methods of
8826 ppc_fbsd_nat_target.
8827 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8828 add_target.
8829 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8830 (the_ppc_nbsd_nat_target): New.
8831 (ppcnbsd_fetch_inferior_registers)
8832 (ppcnbsd_store_inferior_registers): Refactor as methods of
8833 ppc_nbsd_nat_target.
8834 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8835 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8836 (the_ppc_obsd_nat_target): New.
8837 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8838 methods of ppc_obsd_nat_target.
8839 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8840 add_target.
8841 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8842 (the_sh_nbsd_nat_target): New.
8843 (shnbsd_fetch_inferior_registers)
8844 (shnbsd_store_inferior_registers): Refactor as methods of
8845 sh_nbsd_nat_target.
8846 (_initialize_shnbsd_nat): Adjust to C++ification.
8847 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8848 (inf_ptrace_xfer_partial): Delete.
8849 (sparc_xfer_partial, sparc_target): Delete.
8850 * sparc-nat.h (sparc_fetch_inferior_registers)
8851 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8852 (sparc_target): Delete function declaration.
8853 (sparc_target): New template class.
8854 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8855 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8856 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8857 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8858 add_target.
8859 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8860 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8861 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8862 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8863 add_target.
8864 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8865 (the_vax_bsd_nat_target): New.
8866 (vaxbsd_fetch_inferior_registers)
8867 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8868 methods.
8869 (_initialize_vaxbsd_nat): Adjust to C++ification.
8870
8871 * bsd-kvm.c (bsd_kvm_target): New class.
8872 (bsd_kvm_ops): Now a bsd_kvm_target.
8873 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8874 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8875 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8876 bsd_kvm_target.
8877 (bsd_kvm_return_one): Delete.
8878 (bsd_kvm_add_target): Adjust to C++ification.
8879
8880 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
8881 (nto_procfs_target_procfs): New classes.
8882 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
8883 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
8884 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
8885 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
8886 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
8887 (procfs_remove_hw_breakpoint, procfs_resume)
8888 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
8889 (procfs_kill_inferior, procfs_store_registers)
8890 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
8891 as methods of nto_procfs_target.
8892 (nto_procfs_ops): Now an nto_procfs_target_procfs.
8893 (nto_native_ops): Delete.
8894 (procfs_open, procfs_native_open): Delete.
8895 (nto_native_ops): Now an nto_procfs_target_native.
8896 (init_procfs_targets): Adjust to C++ification.
8897 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
8898 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
8899 Refactor as methods of nto_procfs_target.
8900
8901 * go32-nat.c (go32_nat_target): New class.
8902 (the_go32_nat_target): New.
8903 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
8904 (go32_store_registers, go32_xfer_partial, go32_files_info)
8905 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
8906 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
8907 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
8908 (go32_pid_to_str): Refactor as methods of go32_nat_target.
8909 (go32_target): Delete.
8910 (_initialize_go32_nat): Adjust to C++ification.
8911
8912 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
8913 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
8914 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
8915 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
8916 gnu_nat_target.
8917 (gnu_target): Delete.
8918 * gnu-nat.h (gnu_target): Delete.
8919 (gnu_nat_target): New class.
8920 * i386-gnu-nat.c (gnu_base_target): New.
8921 (i386_gnu_nat_target): New class.
8922 (the_i386_gnu_nat_target): New.
8923 (_initialize_i386gnu_nat): Adjust to C++ification.
8924
8925 2018-05-02 Pedro Alves <palves@redhat.com>
8926
8927 * bfd-target.c (target_bfd_xclose): Rename to ...
8928 (target_bfd_close): ... this.
8929 (target_bfd_reopen): Adjust.
8930 * target.c (target_close): Remove references to to_xclose.
8931 * target.h (target_ops::to_xclose): Delete.
8932 (target_ops::to_close): Update comments.
8933
8934 2018-05-02 Pedro Alves <palves@redhat.com>
8935
8936 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
8937 "linux-nat.h".
8938 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
8939 * inf-ptrace.c (inf_ptrace_register_u_offset)
8940 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8941 (inf_ptrace_store_register, inf_ptrace_store_registers)
8942 (inf_ptrace_trad_target): Move to ...
8943 * linux-nat-trad.c: ... this new file.
8944 * linux-nat-trad.h: New file.
8945 * linux-nat.c (linux_target_install_ops): Make extern.
8946 (linux_trad_target): Delete.
8947 * linux-nat.h (linux_trad_target): Delete declaration.
8948 (linux_target_install_ops): Declare.
8949 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
8950 "linux-nat.h".
8951
8952 2018-05-02 Pedro Alves <palves@redhat.com>
8953
8954 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8955 procfs_target/add_target here.
8956 * procfs.c (procfs_target): Make static.
8957 (_initialize_procfs): Call add_target here.
8958 * procfs.h (struct target_ops): Remove forward declaration.
8959 (procfs_target): Remove declaration.
8960 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
8961
8962 2018-05-02 Pedro Alves <palves@redhat.com>
8963
8964 * procfs.c (procfs_stopped_by_watchpoint)
8965 (procfs_insert_watchpoint, procfs_remove_watchpoint)
8966 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
8967 Forward declare.
8968 (procfs_use_watchpoints): Delete, move contents...
8969 (procfs_target): ... here.
8970 * procfs.h (procfs_use_watchpoints): Delete declaration.
8971 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
8972 procfs_use_watchpoints.
8973 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
8974 procfs_use_watchpoints.
8975
8976 2018-05-02 Tom Tromey <tom@tromey.com>
8977
8978 PR python/20084:
8979 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
8980 and var_zuinteger_unlimited.
8981 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
8982 and PARAM_ZUINTEGER_UNLIMITED.
8983 (set_parameter_value): Handle var_zuinteger and
8984 var_zuinteger_unlimited.
8985 (add_setshow_generic): Likewise.
8986 (parmpy_init): Likewise.
8987
8988 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
8989
8990 PR rust/23124
8991 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
8992 pointer is not null before dereferencing it.
8993
8994 2018-04-30 Tom Tromey <tom@tromey.com>
8995
8996 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
8997 is_mi_like_p.
8998
8999 2018-04-30 Tom Tromey <tom@tromey.com>
9000
9001 * breakpoint.c (mention): Remove use of is_mi_like_p.
9002 (print_mention_ranged_breakpoint): Likewise.
9003 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
9004 of is_mi_like_p.
9005
9006 2018-04-30 Tom Tromey <tom@tromey.com>
9007
9008 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
9009
9010 2018-04-30 Tom Tromey <tom@tromey.com>
9011
9012 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
9013 (info_spu_event_command): Remove some uses of is_mi_like_p.
9014
9015 2018-04-30 Tom Tromey <tom@tromey.com>
9016
9017 * python/py-framefilter.c (py_print_single_arg)
9018 (enumerate_locals, py_print_args, py_print_frame): Remove some
9019 uses of is_mi_like_p.
9020
9021 2018-04-30 Tom Tromey <tom@tromey.com>
9022
9023 * ui-out.c: Update.
9024 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
9025 * ui-out.h (ui_out::is_mi_like_p): Now const.
9026 (ui_out::do_is_mi_like_p): Now const.
9027 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
9028
9029 2018-04-30 Tom Tromey <tom@tromey.com>
9030
9031 * varobj.c (varobj_set_visualizer): Use new_reference.
9032 * python/python.c (gdbpy_decode_line): Use new_reference.
9033 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
9034 new_reference.
9035
9036 2018-04-30 Tom Tromey <tom@tromey.com>
9037
9038 * varobj.c (install_new_value): Use new_reference.
9039 * value.h (value_incref): Return void. Swap intro comment with
9040 value_decref.
9041 * value.c (set_value_parent): Use new_reference.
9042 (value_incref): Return void. Update intro comment.
9043 (release_value): Use new_reference.
9044 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
9045
9046 2018-04-30 Tom Tromey <tom@tromey.com>
9047
9048 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
9049 * gdb_bfd.h (new_bfd_ref): Remove.
9050 (gdb_bfd_open): Update comment.
9051 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
9052 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
9053 (gdb_bfd_fdopenr): Use new_reference.
9054 * exec.c (exec_file_attach): Use new_reference.
9055
9056 2018-04-30 Tom Tromey <tom@tromey.com>
9057
9058 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
9059 method.
9060
9061 2018-04-30 Tom Tromey <tom@tromey.com>
9062
9063 * jit.c (jit_read_code_entry): Use type_align.
9064 * i386-tdep.c (i386_gdbarch_init): Don't call
9065 set_gdbarch_long_long_align_bit.
9066 * gdbarch.sh: Remove long_long_align_bit.
9067 * gdbarch.c, gdbarch.h: Rebuild.
9068 * arc-tdep.c (arc_type_align): New function.
9069 (arc_gdbarch_init): Use arc_type_align. Don't call
9070 set_gdbarch_long_long_align_bit.
9071
9072 2018-04-30 Tom Tromey <tom@tromey.com>
9073
9074 * rust-lang.c (rust_type_alignment): Remove.
9075 (rust_composite_type): Use type_align.
9076
9077 2018-04-30 Tom Tromey <tom@tromey.com>
9078
9079 * NEWS: Mention Type.align.
9080 * python/py-type.c (typy_get_alignof): New function.
9081 (type_object_getset): Add "alignof".
9082
9083 2018-04-30 Tom Tromey <tom@tromey.com>
9084
9085 PR exp/17095:
9086 * NEWS: Update.
9087 * std-operator.def (UNOP_ALIGNOF): New operator.
9088 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
9089 New.
9090 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
9091 * c-lang.c (c_op_print_tab): Add alignof.
9092 * c-exp.y (ALIGNOF): New token.
9093 (exp): Add "ALIGNOF" production.
9094 (ident_tokens): Add _Alignof and alignof.
9095
9096 2018-04-30 Tom Tromey <tom@tromey.com>
9097
9098 * i386-tdep.c (i386_type_align): New function.
9099 (i386_gdbarch_init): Update.
9100 * gdbarch.sh (type_align): New method.
9101 * gdbarch.c, gdbarch.h: Rebuild.
9102 * arch-utils.h (default_type_align): Declare.
9103 * arch-utils.c (default_type_align): New function.
9104 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9105 (struct type) <align_log2>: New field.
9106 <instance_flags>: Now a bitfield.
9107 (TYPE_RAW_ALIGN): New macro.
9108 (type_align, type_raw_align, set_type_align): Declare.
9109 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9110 functions.
9111 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9112 (get_alignment, maybe_set_alignment): New functions.
9113 (read_structure_type, read_enumeration_type, read_array_type)
9114 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9115 (read_subrange_type, read_base_type): Set type alignment.
9116
9117 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9118
9119 * dwarf2read.c (read_index_from_section): Use bool.
9120
9121 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9122
9123 PR gdb/22950
9124 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9125 with #ifdef.
9126
9127 2018-04-29 John Reiser <jreiser@BitWagon.com>
9128
9129 PR build/22873
9130 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9131 last step, and do it atomically.
9132
9133 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
9134
9135 * compile/compile-c-types.c (convert_int, convert_float):
9136 Update for C FE v1.
9137
9138 2018-04-27 Tom Tromey <tom@tromey.com>
9139
9140 PR rust/22545:
9141 * rust-lang.c (rust_inclusive_range_type_p): New function.
9142 (rust_range): Handle inclusive ranges.
9143 (rust_compute_range): Likewise.
9144 * rust-exp.y (struct rust_op) <inclusive>: New field.
9145 (DOTDOTEQ): New constant.
9146 (range_expr): Add "..=" productions.
9147 (operator_tokens): Add "..=" token.
9148 (ast_range): Add "inclusive" parameter.
9149 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
9150 ranges.
9151 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
9152 bounds values.
9153 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
9154 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
9155 Update comments.
9156 * expprint.c (print_subexp_standard): Handle new bounds values.
9157 (dump_subexp_body_standard): Likewise.
9158
9159 2018-04-27 Tom Tromey <tom@tromey.com>
9160
9161 * configure: Rebuild.
9162 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
9163 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
9164 "OVERRIDE".
9165 (class symbol_needs_eval_context): Likewise.
9166 * dwarf2read.c (mock_mapped_index::symbol_name_count)
9167 (mock_mapped_index::symbol_name_at): Use "override". Remove
9168 "virtual".
9169 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
9170 "override".
9171 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
9172 * aarch64-tdep.c (instruction_reader::read): Use "override".
9173 (instruction_reader_test::read): Likewise.
9174 * arm-tdep.c (instruction_reader::read): Use "override".
9175 (instruction_reader_thumb::read): Likewise.
9176
9177 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
9178
9179 PR remote/9665
9180 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
9181 instead of remote_send.
9182 (remote_send): Remove.
9183
9184 2018-04-26 Pedro Alves <palves@redhat.com>
9185
9186 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
9187 find_function_start_sal instead of find_pc_line.
9188
9189 2018-04-26 Pedro Alves <palves@redhat.com>
9190
9191 * breakpoint.c (set_breakpoint_location_function): Handle
9192 mst_data_gnu_ifunc.
9193 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
9194 * elfread.c (elf_symtab_read): Give data symbols with
9195 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
9196 (elf_rel_plt_read): Update comment.
9197 * linespec.c (convert_linespec_to_sals): Handle
9198 mst_data_gnu_ifunc.
9199 (minsym_found): Handle mst_data_gnu_ifunc.
9200 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
9201 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
9202 * parse.c (find_minsym_type_and_address): Handle
9203 mst_data_gnu_ifunc.
9204 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
9205 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
9206 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
9207 comment.
9208 <mst_data_gnu_ifunc>: New enumerator.
9209
9210 2018-04-26 Pedro Alves <palves@redhat.com>
9211
9212 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
9213 (lookup_minimal_symbol_by_pc_section): ... this. Replace
9214 'want_trampoline' parameter by a lookup_msym_prefer parameter.
9215 Handle it.
9216 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
9217 (lookup_minimal_symbol_by_pc): Adjust.
9218 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
9219 (lookup_solib_trampoline_symbol_by_pc): Adjust.
9220 * minsyms.h (lookup_msym_prefer): New enum.
9221 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9222 parameter by a lookup_msym_prefer parameter.
9223
9224 2018-04-26 Pedro Alves <palves@redhat.com>
9225
9226 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
9227 ends in "@plt" instead of looking at the symbol's section.
9228
9229 2018-04-26 Pedro Alves <palves@redhat.com>
9230
9231 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
9232 all references.
9233 (find_pc_partial_function_gnu_ifunc): Rename to ...
9234 (find_pc_partial_function): ... this, and remove references to
9235 'is_gnu_ifunc_p'.
9236 (find_pc_partial_function): Delete old implementation.
9237 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
9238
9239 2018-04-26 Pedro Alves <palves@redhat.com>
9240
9241 * linespec.c (struct bound_minimal_symbol_search_key): New.
9242 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
9243 skip first line if we found a GNU ifunc minimal symbol by name.
9244 (compare_msymbols): Change parameters to work with a destructured
9245 lhs minsym.
9246 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
9247 functions.
9248
9249 2018-04-26 Pedro Alves <palves@redhat.com>
9250
9251 * breakpoint.c (set_breakpoint_location_function): Don't resolve
9252 ifunc targets here. Instead, if we have an ifunc minsym, use its
9253 address/name.
9254 (add_location_to_breakpoint): Store the minsym and the objfile in
9255 the breakpoint location.
9256 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
9257 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
9258 Record the minsym in the sal.
9259 * symtab.h (symtab_and_line) <msymbol>: New field.
9260
9261 2018-04-26 Pedro Alves <palves@redhat.com>
9262
9263 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
9264 unless we actually resolved the ifunc.
9265
9266 2018-04-26 Pedro Alves <palves@redhat.com>
9267
9268 * c-exp.y (variable production): Prefer ifunc minsyms over
9269 regular function symbols.
9270 * symtab.c (find_gnu_ifunc): New function.
9271 * minsyms.h (lookup_msym_prefer): New enum.
9272 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9273 parameter by a lookup_msym_prefer parameter.
9274 * symtab.h (find_gnu_ifunc): New declaration.
9275
9276 2018-04-26 Pedro Alves <palves@redhat.com>
9277
9278 * blockframe.c (find_gnu_ifunc_target_type): New function.
9279 (find_function_type): New.
9280 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9281 return a value with a memory address.
9282 (eval_call): For calls to GNU ifunc functions, try to find the
9283 type of the target function from the type that the resolver
9284 returns.
9285 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9286 symbols.
9287 * infcall.c (find_function_return_type): Delete.
9288 (find_function_addr): Add 'function_type' parameter. For calls to
9289 GNU ifunc functions, try to find the type of the target function
9290 from the type that the resolver returns, and return it via
9291 FUNCTION_TYPE.
9292 (call_function_by_hand_dummy): Adjust to use the function type
9293 returned by find_function_addr.
9294 (find_function_addr): Add 'function_type' parameter and move
9295 description here.
9296 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9297 declarations.
9298
9299 2018-04-26 Pedro Alves <palves@redhat.com>
9300
9301 * c-exp.y (variable production): Skip finding an alias for ifunc
9302 symbols.
9303
9304 2018-04-26 Pedro Alves <palves@redhat.com>
9305
9306 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9307
9308 2018-04-25 Pedro Alves <palves@redhat.com>
9309
9310 * infcmd.c (kill_command): Print the pid as string, not the whole
9311 thread's ptid. Add comment. s/has been killed/killed/ in output
9312 message.
9313 * remote.c (remote_detach_1): Print the pid as string, not the
9314 whole thread's ptid.
9315
9316 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9317 Sergio Durigan Junior <sergiodj@redhat.com>
9318 Pedro Alves <palves@redhat.com>
9319
9320 * infcmd.c (kill_command): Print message when inferior has
9321 been killed.
9322 * inferior.c (print_inferior_events): Remove 'static'. Set as
9323 '1'.
9324 (add_inferior): Improve message printed when
9325 'print_inferior_events' is on.
9326 (exit_inferior): Remove message printed when
9327 'print_inferior_events' is on.
9328 (detach_inferior): Improve message printed when
9329 'print_inferior_events' is on.
9330 (initialize_inferiors): Use 'add_inferior_silent' to set
9331 'current_inferior_'.
9332 * inferior.h (print_inferior_events): Declare here as
9333 'extern'.
9334 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9335 '[Detaching...]' messages when 'print_inferior_events' is on.
9336 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9337 as prefix/suffix for messages. Remove periods. Fix erroneous
9338 'Detaching after fork from child...', replace it by '... from
9339 parent...'.
9340 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9341 prefix/suffix when printing 'Detaching...' messages. Print
9342 them when 'print_inferior_events' is on.
9343 * remote.c (remote_detach_1): Print message when detaching
9344 from inferior and '!is_fork_parent'.
9345
9346 2018-04-24 Tom Tromey <tom@tromey.com>
9347
9348 * cli-out.h: Reindent.
9349
9350 2018-04-24 Tom Tromey <tom@tromey.com>
9351
9352 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9353 (cli_ui_out::do_field_string): Use fputs_filtered.
9354 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9355
9356 2018-04-23 Tom Tromey <tom@tromey.com>
9357
9358 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9359 gdb::unique_xmalloc_ptr.
9360
9361 2018-04-23 Tom Tromey <tom@tromey.com>
9362
9363 * configure: Rebuild.
9364
9365 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9366
9367 PR gdb/23095
9368 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9369 prepare_for_testing. Set normal_bp to r_debug_state if target
9370 is bsd.
9371
9372 2018-04-21 Pedro Alves <palves@redhat.com>
9373 Rajendra SY <rajendra.sy@gmail.com>
9374
9375 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9376 * remote.c (extended_remote_attach): In all-stop mode, mark the
9377 thread as executing.
9378
9379 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9380
9381 * thread.c (thread_apply_all_command): Fix comment.
9382 (thread_command): Fix comment.
9383
9384 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9385
9386 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9387 parameter.
9388 * features/aarch64-core.c (create_feature_aarch64_core):
9389 Regenerate.
9390 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9391 Likewise.
9392 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9393 Likewise.
9394 * features/i386/32bit-avx512.c
9395 (create_feature_i386_32bit_avx512): Likewise.
9396 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9397 Likewise.
9398 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9399 Likewise.
9400 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9401 Likewise.
9402 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9403 Likewise.
9404 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9405 Likewise.
9406 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9407 Likewise.
9408 * features/i386/64bit-avx512.c
9409 (create_feature_i386_64bit_avx512): Likewise.
9410 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9411 Likewise.
9412 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9413 Likewise.
9414 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9415 Likewise.
9416 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9417 Likewise.
9418 * features/i386/64bit-segments.c
9419 (create_feature_i386_64bit_segments): Likewise.
9420 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9421 Likewise.
9422 * features/i386/x32-core.c
9423 (create_feature_i386_x32_core): Likewise.
9424 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9425 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9426 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9427 * target-descriptions.c: In generated code, don't pass xml
9428 filename.
9429
9430 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9431
9432 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9433 (print_xml_feature::visit_post): Likewise.
9434 (print_xml_feature::visit): Likewise.
9435 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9436 (print_xml_feature): Add new class.
9437 * regformats/regdat.sh: Null xmltarget on feature targets.
9438 * target-descriptions.c (struct target_desc): Add xmltarget.
9439 (maintenance_check_tdesc_xml_convert): Add unittest function.
9440 (tdesc_get_features_xml): Add function to get xml.
9441 (maintenance_check_xml_descriptions): Test xml generation.
9442 * xml-tdesc.c (string_read_description_xml): Add function.
9443 * xml-tdesc.h (string_read_description_xml): Add declaration.
9444
9445 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9446
9447 * features/Makefile: Add feature marker to targets with new style
9448 target descriptions.
9449 * regformats/aarch64.dat: Regenerate.
9450 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9451 * regformats/i386/amd64-avx-linux.dat: Likewise.
9452 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9453 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9454 * regformats/i386/amd64-linux.dat: Likewise.
9455 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9456 * regformats/i386/amd64.dat: Likewise.
9457 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9458 * regformats/i386/i386-avx-linux.dat: Likewise.
9459 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9460 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9461 * regformats/i386/i386-linux.dat: Likewise.
9462 * regformats/i386/i386-mmx-linux.dat: Likewise.
9463 * regformats/i386/i386-mpx-linux.dat: Likewise.
9464 * regformats/i386/i386.dat: Likewise.
9465 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9466 * regformats/i386/x32-avx-linux.dat: Likewise.
9467 * regformats/i386/x32-linux.dat: Likewise.
9468 * regformats/tic6x-c62x-linux.dat: Likewise.
9469 * regformats/tic6x-c64x-linux.dat: Likewise.
9470 * regformats/tic6x-c64xp-linux.dat: Likewise.
9471 * regformats/regdat.sh: Parse feature marker.
9472
9473 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9474
9475 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9476 (tdesc_osabi_name): Likewise.
9477 * target-descriptions.c (tdesc_architecture_name): Add new
9478 function.
9479 (tdesc_osabi_name): Likewise.
9480
9481 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9482
9483 * common/tdesc.c (tdesc_predefined_type): Move to here.
9484 (tdesc_named_type): Likewise.
9485 (tdesc_create_vector): Likewise.
9486 (tdesc_create_struct): Likewise.
9487 (tdesc_set_struct_size): Likewise.
9488 (tdesc_create_union): Likewise.
9489 (tdesc_create_flags): Likewise.
9490 (tdesc_create_enum): Likewise.
9491 (tdesc_add_field): Likewise.
9492 (tdesc_add_typed_bitfield): Likewise.
9493 (tdesc_add_bitfield): Likewise.
9494 (tdesc_add_flag): Likewise.
9495 (tdesc_add_enum_value): Likewise.
9496 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9497 (struct tdesc_type_vector): Likewise.
9498 (struct tdesc_type_field): Likewise.
9499 (struct tdesc_type_with_fields): Likewise.
9500 (tdesc_create_enum): Add declaration.
9501 (tdesc_add_typed_bitfield): Likewise.
9502 (tdesc_add_enum_value): Likewise.
9503 * target-descriptions.c (tdesc_type_field): Move from here.
9504 (tdesc_type_builtin): Likewise.
9505 (tdesc_type_vector): Likewise.
9506 (tdesc_type_with_fields): Likewise.
9507 (tdesc_predefined_types): Likewise.
9508 (tdesc_named_type): Likewise.
9509 (tdesc_create_vector): Likewise.
9510 (tdesc_create_struct): Likewise.
9511 (tdesc_set_struct_size): Likewise.
9512 (tdesc_create_union): Likewise.
9513 (tdesc_create_flags): Likewise.
9514 (tdesc_create_enum): Likewise.
9515 (tdesc_add_field): Likewise.
9516 (tdesc_add_typed_bitfield): Likewise.
9517 (tdesc_add_bitfield): Likewise.
9518 (tdesc_add_flag): Likewise.
9519 (tdesc_add_enum_value): Likewise.
9520 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9521 (tdesc_add_typed_bitfield): Likewise.
9522 (tdesc_add_enum_value): Likewise.
9523
9524 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9525
9526 * common/tdesc.c (tdesc_feature::accept): Move to here.
9527 (tdesc_feature::operator==): Likewise.
9528 (tdesc_create_reg): Likewise.
9529 * common/tdesc.h (tdesc_type_kind): Likewise.
9530 (struct tdesc_type): Likewise.
9531 (struct tdesc_feature): Likewise.
9532 * regformats/regdat.sh: Create a feature.
9533 * target-descriptions.c (tdesc_type_kind): Move from here.
9534 (tdesc_type): Likewise.
9535 (tdesc_type_up): Likewise.
9536 (tdesc_feature): Likewise.
9537 (tdesc_create_reg): Likewise.
9538
9539 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9540
9541 * Makefile.in: Add arch/tdesc.c
9542 * common/tdesc.c: New file.
9543 * common/tdesc.h (tdesc_element_visitor): Move to here.
9544 (tdesc_element): Likewise.
9545 (tdesc_reg): Likewise.
9546 (tdesc_reg_up): Likewise.
9547 * regformats/regdef.h (reg): Add offset to constructors.
9548 * target-descriptions.c (tdesc_element_visitor): Move from here.
9549 (tdesc_element): Likewise.
9550 (tdesc_reg): Likewise.
9551 (tdesc_reg_up): Likewise.
9552
9553 2018-04-17 Tom Tromey <tom@tromey.com>
9554
9555 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9556 discriminant field.
9557
9558 2018-04-17 Tom Tromey <tom@tromey.com>
9559
9560 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9561
9562 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9563
9564 * symtab.c (print_symbol_info): Skip printing filename and line
9565 number when `last' is NULL.
9566 (symtab_symbol_info): Use empty string instead of NULL for first
9567 invocation of print_symbol_info.
9568 (rbreak_command): Pass NULL to `last' parameter of
9569 print_symbol_info.
9570
9571 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9572
9573 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9574 instead of nullptr.
9575
9576 2018-04-16 Pedro Alves <palves@redhat.com>
9577
9578 * MAINTAINERS (sh): Remove.
9579 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9580 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9581 (ALLDEPFILES): Remove sh64-tdep.c.
9582 * NEWS: Mentions that support for SH-5/SH64 is removed.
9583 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9584 (sh*-*-openbsd*): Ditto.
9585 (sh64-*-elf*): Remove.
9586 (sh*): Remove.
9587 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9588 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9589 * sh-tdep.c: No longer include "sh64-tdep.h".
9590 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9591 * sh64-tdep.c, sh64-tdep.h: Remove files.
9592
9593 2018-04-16 Pedro Alves <palves@redhat.com>
9594
9595 * MAINTAINERS: Remove m88k.
9596 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9597 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9598 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9599 * NEWS: Mention that support for m88k was removed.
9600 * configure.host (m88*-*-*): Remove support.
9601 * configure.nat (m88k-*-*): Remove support.
9602 * configure.tgt (m88*-*-openbsd*): Remove.
9603 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9604
9605 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9606
9607 * configure.tgt (x86_tobjs): New variable.
9608 (amd64_tobjs, i386_tobjs): Use it.
9609
9610 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9611
9612 * symtab.c (print_symbol_info): Precede the symbol definition by
9613 the line number when available.
9614 * NEWS: Advertise this enhancement.
9615
9616 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9617
9618 * NEWS (New options): announce set/show record btrace cpu.
9619 * btrace.c: Include record-btrace.h.
9620 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9621 the vendor is unknown.
9622 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9623 Maybe overwrite the btrace configuration's cpu.
9624 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9625 (btrace_fetch): Add cpu parameter. Update callers.
9626 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9627 Maybe overwrite the btrace configuration's cpu. Skip enabling
9628 errata workarounds if the vendor is unknown.
9629 * python/py-record-btrace.c: Include record-btrace.h.
9630 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9631 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9632 * record-btrace.c (record_btrace_cpu_state_kind): New.
9633 (record_btrace_cpu): New.
9634 (set_record_btrace_cpu_cmdlist): New.
9635 (record_btrace_get_cpu): New.
9636 (require_btrace_thread, record_btrace_info)
9637 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9638 (cmd_set_record_btrace_cpu_none): New.
9639 (cmd_set_record_btrace_cpu_auto): New.
9640 (cmd_set_record_btrace_cpu): New.
9641 (cmd_show_record_btrace_cpu): New.
9642 (_initialize_record_btrace): Initialize set/show record btrace cpu
9643 commands.
9644 * record-btrace.h (record_btrace_get_cpu): New.
9645
9646 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9647
9648 * record.c (set_record_command): Fix typo in message.
9649
9650 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9651
9652 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9653
9654 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9655
9656 * infrun.c (process_event_stop_test): Call
9657 gdbarch_in_indirect_branch_thunk.
9658 * gdbarch.sh (in_indirect_branch_thunk): New.
9659 * gdbarch.c: Regenerated.
9660 * gdbarch.h: Regenerated.
9661 * x86-tdep.h: New.
9662 * x86-tdep.c: New.
9663 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9664 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9665 (ALLDEPFILES): Add x86-tdep.c.
9666 * arch-utils.h (default_in_indirect_branch_thunk): New.
9667 * arch-utils.c (default_in_indirect_branch_thunk): New.
9668 * i386-tdep: Include x86-tdep.h.
9669 (i386_in_indirect_branch_thunk): New.
9670 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9671 function.
9672 * amd64-tdep: Include x86-tdep.h.
9673 (amd64_in_indirect_branch_thunk): New.
9674 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9675
9676 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9677
9678 PR gdb/23053
9679 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9680 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9681 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9682 regression.
9683
9684 2018-04-12 Tom Tromey <tom@tromey.com>
9685
9686 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9687 (rust_evaluate_subexp): Likewise.
9688
9689 2018-04-12 Pedro Alves <palves@redhat.com>
9690
9691 * procfs.c (procfs_detach): Make forward declaration's prototype
9692 match definition's protototype.
9693 (proc_get_LDT_entry): Remove stale do_cleanups call.
9694
9695 2018-04-12 Pedro Alves <palves@redhat.com>
9696
9697 * target.h (target_ops::to_has_exited): Delete.
9698 (target_has_exited): Delete.
9699 * target-delegates.c: Regenerate.
9700
9701 2018-04-11 Pedro Alves <palves@redhat.com>
9702
9703 * target.c (fileio_fh_t::t): Add comment.
9704 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9705 (target_fileio_close): Handle a NULL target.
9706 (invalidate_fileio_fh): New.
9707 (target_close): Call it.
9708 * remote.c (remote_hostio_send_command): No longer check whether
9709 remote_desc is open.
9710
9711 2018-04-11 Pedro Alves <palves@redhat.com>
9712
9713 * target.c (fileio_fh_t): Make it a named struct instead of a
9714 typedef.
9715 (fileio_fh_t::is_closed): New method.
9716 (DEF_VEC_O (fileio_fh_t)): Remove.
9717 (fileio_fhandles): Now a std::vector.
9718 (is_closed_fileio_fh): Delete.
9719 (acquire_fileio_fd): Adjust. Rename parameters.
9720 (release_fileio_fd): Adjust.
9721 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9722 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9723 (target_fileio_close): Adjust.
9724
9725 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9726
9727 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9728 index.
9729
9730 2018-04-10 Pedro Alves <palves@redhat.com>
9731
9732 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9733 (scoped_finish_thread_state): New class.
9734 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9735 cleanup.
9736 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9737 (fetch_inferior_event, normal_stop): Likewise.
9738 * thread.c (finish_thread_state_cleanup): Delete.
9739
9740 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9741 Pedro Alves <palves@redhat.com>
9742
9743 * value.c: Include "selftest.h" and "common/array-view.h".
9744 (struct range) <operator ==>: New.
9745 (test_ranges_contain): New.
9746 (check_ranges_vector): New.
9747 (test_insert_into_bit_range_vector): New.
9748 (_initialize_values): Register selftests.
9749 * common/array-view.h (operator==, operator!=): New.
9750
9751 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9752
9753 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9754 an iterator.
9755 * inline-frame.c: Include <algorithm>.
9756 (struct inline_state): Add constructor.
9757 (inline_state_s): Remove.
9758 (DEF_VEC_O(inline_state_s)): Remove.
9759 (inline_states): Change type to std::vector.
9760 (find_inline_frame_state): Adjust to std::vector.
9761 (allocate_inline_frame_state): Remove.
9762 (clear_inline_frame_state): Adjust to std::vector.
9763 (skip_inline_frames): Adjust to std::vector.
9764
9765 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9766
9767 * tracepoint.h (struct trace_state_variable): Add constructor.
9768 <name>: Change type to std::string.
9769 * tracepoint.c (tsv_s): Remove.
9770 (DEF_VEC_O(tsv_s)): Remove.
9771 (tvariables): Change to std::vector.
9772 (create_trace_state_variable): Adjust to std::vector.
9773 (find_trace_state_variable): Likewise.
9774 (find_trace_state_variable_by_number): Likewise.
9775 (delete_trace_state_variable): Likewise.
9776 (trace_variable_command): Adjust to std::string.
9777 (delete_trace_variable_command): Likewise.
9778 (tvariables_info_1): Adjust to std::vector.
9779 (save_trace_state_variables): Likewise.
9780 (start_tracing): Likewise.
9781 (merge_uploaded_trace_state_variables): Adjust to std::vector
9782 and std::string.
9783 * target.h (struct target_ops)
9784 <to_download_trace_state_variable>: Pass reference to
9785 trace_state_variable.
9786 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9787 * target-delegates.c: Re-generate.
9788 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9789 (mi_tsv_deleted): Likewise.
9790 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9791 * remote.c (remote_download_trace_state_variable): Change
9792 pointer to reference and adjust.
9793 * make-target-delegates (parse_argtypes): Handle references.
9794 (write_function_header): Likewise.
9795 (munge_type): Likewise.
9796
9797 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9798
9799 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9800 string_view-selftests.c.
9801 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9802 testsuite.
9803 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9804 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9805 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9806 * unittests/basic_string_view/element_access/char/1.cc:
9807 Likewise.
9808 * unittests/basic_string_view/element_access/char/empty.cc:
9809 Likewise.
9810 * unittests/basic_string_view/element_access/char/front_back.cc:
9811 Likewise.
9812 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9813 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9814 Likewise.
9815 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9816 Likewise.
9817 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9818 Likewise.
9819 * unittests/basic_string_view/operations/compare/char/1.cc:
9820 Likewise.
9821 * unittests/basic_string_view/operations/compare/char/13650.cc:
9822 Likewise.
9823 * unittests/basic_string_view/operations/copy/char/1.cc:
9824 Likewise.
9825 * unittests/basic_string_view/operations/data/char/1.cc:
9826 Likewise.
9827 * unittests/basic_string_view/operations/find/char/1.cc:
9828 Likewise.
9829 * unittests/basic_string_view/operations/find/char/2.cc:
9830 Likewise.
9831 * unittests/basic_string_view/operations/find/char/3.cc:
9832 Likewise.
9833 * unittests/basic_string_view/operations/find/char/4.cc:
9834 Likewise.
9835 * unittests/basic_string_view/operations/rfind/char/1.cc:
9836 Likewise.
9837 * unittests/basic_string_view/operations/rfind/char/2.cc:
9838 Likewise.
9839 * unittests/basic_string_view/operations/rfind/char/3.cc:
9840 Likewise.
9841 * unittests/basic_string_view/operations/substr/char/1.cc:
9842 Likewise.
9843 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9844 * unittests/string_view-selftests.c: New file.
9845
9846 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9847
9848 * unittests/basic_string_view/capacity/1.cc: New file.
9849 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9850 * unittests/basic_string_view/cons/char/1.cc: New file.
9851 * unittests/basic_string_view/cons/char/2.cc: New file.
9852 * unittests/basic_string_view/cons/char/3.cc: New file.
9853 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9854 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9855 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9856 * unittests/basic_string_view/element_access/char/1.cc: New file.
9857 * unittests/basic_string_view/element_access/char/2.cc: New file.
9858 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9859 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9860 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9861 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9862 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9863 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9864 * unittests/basic_string_view/include.cc: New file.
9865 * unittests/basic_string_view/inserters/char/1.cc: New file.
9866 * unittests/basic_string_view/inserters/char/2.cc: New file.
9867 * unittests/basic_string_view/inserters/char/3.cc: New file.
9868 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9869 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9870 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9871 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9872 * unittests/basic_string_view/literals/types.cc: New file.
9873 * unittests/basic_string_view/literals/values.cc: New file.
9874 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9875 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9876 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9877 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9878 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9879 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
9880 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
9881 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
9882 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
9883 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
9884 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
9885 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
9886 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
9887 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
9888 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
9889 * unittests/basic_string_view/operations/data/char/1.cc: New file.
9890 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
9891 * unittests/basic_string_view/operations/find/char/1.cc: New file.
9892 * unittests/basic_string_view/operations/find/char/2.cc: New file.
9893 * unittests/basic_string_view/operations/find/char/3.cc: New file.
9894 * unittests/basic_string_view/operations/find/char/4.cc: New file.
9895 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
9896 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
9897 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
9898 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
9899 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
9900 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
9901 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
9902 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
9903 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
9904 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
9905 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
9906 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
9907 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
9908 * unittests/basic_string_view/operators/char/2.cc: New file.
9909 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
9910 * unittests/basic_string_view/range_access/char/1.cc: New file.
9911 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
9912 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
9913 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
9914 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
9915 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
9916 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
9917 * unittests/basic_string_view/requirements/typedefs.cc: New file.
9918 * unittests/basic_string_view/typedefs.cc: New file.
9919 * unittests/basic_string_view/types/1.cc: New file.
9920
9921 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9922
9923 * common/gdb_string_view.h: Remove libstdc++ implementation
9924 details, adjust to gdb reality.
9925 * common/gdb_string_view.tcc: Likewise.
9926 * cli/cli-script.c (struct string_view): Remove.
9927 (user_args) <m_args>: Change element type to gdb::string_view.
9928 (user_args::insert_args): Adjust.
9929
9930 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9931
9932 * common/gdb_string_view.h: New file.
9933 * common/gdb_string_view.tcc: New file.
9934
9935 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9936
9937 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
9938 * configure: Re-generate.
9939
9940 2018-04-09 Pedro Alves <palves@redhat.com>
9941
9942 * gdbarch.sh: Include "observable.h" instead of "observer.h".
9943 (set_target_gdbarch): Call
9944 gdb::observers::architecture_changed.notify instead of
9945 observer_notify_architecture_changed.
9946
9947 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9948
9949 * tracepoint.c (struct current_traceframe_cleanup): Remove.
9950 (do_restore_current_traceframe_cleanup): Remove.
9951 (restore_current_traceframe_cleanup_dtor): Remove.
9952 (make_cleanup_restore_current_traceframe): Remove.
9953 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
9954 New.
9955 * tracepoint.h (struct scoped_restore_current_traceframe): New.
9956 * infrun.c (fetch_inferior_event): Use
9957 scoped_restore_current_traceframe.
9958
9959 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9960
9961 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
9962 Remove.
9963 <n_allocated_type_units>: Remove.
9964 <all_type_units>: Change to std::vector.
9965 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9966 to std::vector change.
9967 (dwarf2_per_objfile::get_cutu): Likewise.
9968 (dwarf2_per_objfile::get_tu): Likewise.
9969 (create_signatured_type_table_from_index): Likewise.
9970 (create_signatured_type_table_from_debug_names): Likewise.
9971 (dw2_symtab_iter_next): Likewise.
9972 (dw2_print_stats): Likewise.
9973 (dw2_expand_all_symtabs): Likewise.
9974 (dw2_expand_marked_cus): Likewise.
9975 (dw2_debug_names_iterator::next): Likewise.
9976 (dwarf2_initialize_objfile): Likewise.
9977 (add_signatured_type_cu_to_table): Likewise.
9978 (create_all_type_units): Likewise.
9979 (add_type_unit): Likewise.
9980 (struct tu_abbrev_offset): Add constructor.
9981 (build_type_psymtabs_1): Adjust to std::vector change.
9982 (print_tu_stats): Likewise.
9983 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
9984 (write_debug_names): Likewise.
9985
9986 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
9987
9988 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
9989 Make an std::vector.
9990 <n_comp_units>: Remove.
9991 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
9992 to std::vector change.
9993 (dwarf2_per_objfile::get_cutu): Likewise.
9994 (dwarf2_per_objfile::get_cu): Likewise.
9995 (create_cus_from_index): Likewise.
9996 (create_addrmap_from_index): Likewise.
9997 (create_addrmap_from_aranges): Likewise.
9998 (dwarf2_read_index): Likewise.
9999 (dw2_find_last_source_symtab): Likewise.
10000 (dw2_map_symtabs_matching_filename): Likewise.
10001 (dw2_symtab_iter_next): Likewise.
10002 (dw2_print_stats): Likewise.
10003 (dw2_expand_all_symtabs): Likewise.
10004 (dw2_expand_symtabs_with_fullname): Likewise.
10005 (dw2_expand_marked_cus): Likewise.
10006 (dw2_map_symbol_filenames): Likewise.
10007 (create_cus_from_debug_names): Likewise.
10008 (dwarf2_read_debug_names): Likewise.
10009 (dw2_debug_names_iterator::next): Likewise.
10010 (dwarf2_initialize_objfile): Likewise.
10011 (set_partial_user): Likewise.
10012 (dwarf2_build_psymtabs_hard): Likewise.
10013 (read_comp_units_from_section): Remove arguments, adjust to
10014 std::vector change.
10015 (create_all_comp_units): Adjust to std::vector and
10016 read_comp_units_from_section changes.
10017 (dwarf2_find_containing_comp_unit): Adjust to std::vector
10018 change.
10019 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10020 (psyms_seen_size): Likewise.
10021 (write_gdbindex): Likewise.
10022 (write_debug_names): Likewise.
10023
10024 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10025
10026 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
10027 with dwarf2_per_objfile.
10028 (create_cus_from_index): Likewise.
10029 (create_signatured_type_table_from_index): Likewise.
10030 (dwarf2_read_index): Likewise.
10031 (dwarf2_initialize_objfile): Likewise.
10032 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
10033 per_cu rather than get_dwarf2_per_objfile.
10034
10035 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10036
10037 * dwarf2read.h (struct signatured_type): Forward declare.
10038 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
10039 New methods.
10040 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
10041 (dw2_get_cutu): ...this.
10042 (dwarf2_per_objfile::get_cu): Rename from...
10043 (dw2_get_cu): ...this.
10044 (dwarf2_per_objfile::get_tu): New.
10045 (create_addrmap_from_index): Adjust.
10046 (create_addrmap_from_aranges): Adjust.
10047 (dw2_find_last_source_symtab): Adjust.
10048 (dw2_map_symtabs_matching_filename): Adjust.
10049 (dw2_symtab_iter_next): Adjust.
10050 (dw2_print_stats): Adjust.
10051 (dw2_expand_all_symtabs): Adjust.
10052 (dw2_expand_symtabs_with_fullname): Adjust.
10053 (dw2_expand_marked_cus): Adjust.
10054 (dw_expand_symtabs_matching_file_matcher): Adjust.
10055 (dw2_map_symbol_filenames): Adjust.
10056 (dw2_debug_names_iterator::next): Adjust.
10057 (dwarf2_initialize_objfile): Adjust.
10058 (set_partial_user): Adjust.
10059 (dwarf2_build_psymtabs_hard): Adjust.
10060
10061 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10062
10063 * dwarf2read.c (create_signatured_type_table_from_debug_names):
10064 Remove unused variables.
10065 (dw2_map_symtabs_matching_filename): Likewise.
10066 (dwarf2_record_block_ranges): Likewise.
10067 (dwarf2_read_addr_index): Likewise.
10068 (follow_die_offset): Likewise.
10069
10070 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10071
10072 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
10073 to symbol_file_add_main.
10074
10075 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10076
10077 PR mi/22299
10078 * mi/mi-console.c (do_fputc_async_safe): New.
10079 (mi_console_file::write_async_safe): New.
10080 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
10081 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
10082 New.
10083 * ui-file.c (ui_file::putstrn): Adjust call to
10084 fputstrn_unfiltered.
10085 * utils.c (printchar): Replace do_fputs and do_fprintf
10086 parameters by do_fputc.
10087 (fputstr_filtered): Adjust call to printchar.
10088 (fputstr_unfiltered): Likewise.
10089 (fputstrn_filtered): Likewise.
10090 (fputstrn_unfiltered): Add do_fputc parameter, pass to
10091 printchar.
10092 * utils.h (do_fputc_ftype): New typedef.
10093 (fputstrn_unfiltered): Add do_fputc parameter.
10094
10095 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10096
10097 * regformats/i386/i386-avx.dat: Remove.
10098
10099 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10100
10101 PR gdb/22979
10102 * amd64-tdep.c (amd64_none_init_abi): New function.
10103 (amd64_x32_none_init_abi): New function.
10104 (_initialize_amd64_tdep): Register handlers for x86-64 and
10105 x64_32 with GDB_OSABI_NONE.
10106 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10107 GDB_OSABI_NONE osabi.
10108
10109 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10110
10111 PR gdb/22980
10112 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10113 GDB_OSABI_NONE.
10114 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10115 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10116
10117 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10118
10119 * common/byte-vector.h (char_vector): New type.
10120 * target.h (target_read_alloc): Return
10121 gdb::optional<byte_vector>.
10122 (target_read_stralloc): Return gdb::optional<char_vector>.
10123 (target_get_osdata): Return gdb::optional<char_vector>.
10124 * target.c (target_read_alloc_1): Templatize. Replacement
10125 manual memory management with vector.
10126 (target_read_alloc): Change return type, adjust.
10127 (target_read_stralloc): Change return type, adjust.
10128 (target_get_osdata): Change return type, adjust.
10129 * auxv.c (struct auxv_info) <length>: Remove.
10130 <data>: Change type to gdb::optional<byte_vector>.
10131 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10132 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
10133 (target_auxv_search): Adjust.
10134 (fprint_target_auxv): Adjust.
10135 * avr-tdep.c (avr_io_reg_read_command): Adjust.
10136 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
10137 (linux_make_corefile_notes): Adjust.
10138 * osdata.c (get_osdata): Adjust.
10139 * remote.c (remote_get_threads_with_qxfer): Adjust.
10140 (remote_memory_map): Adjust.
10141 (remote_traceframe_info): Adjust.
10142 (btrace_read_config): Adjust.
10143 (remote_read_btrace): Adjust.
10144 (remote_pid_to_exec_file): Adjust.
10145 * solib-aix.c (solib_aix_get_library_list): Adjust.
10146 * solib-dsbt.c (decode_loadmap): Don't free buf.
10147 (dsbt_get_initial_loadmaps): Adjust.
10148 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
10149 * solib-target.c (solib_target_current_sos): Adjust.
10150 * tracepoint.c (sdata_make_value): Adjust.
10151 * xml-support.c (xinclude_start_include): Adjust.
10152 (xml_fetch_content_from_file): Adjust.
10153 * xml-support.h (xml_fetch_another): Change return type.
10154 (xml_fetch_content_from_file): Change return type.
10155 * xml-syscall.c (xml_init_syscalls_info): Adjust.
10156 * xml-tdesc.c (file_read_description_xml): Adjust.
10157 (fetch_available_features_from_target): Change return type.
10158 (target_fetch_description_xml): Adjust.
10159 (target_read_description_xml): Adjust.
10160
10161 2018-04-06 Tom Tromey <tom@tromey.com>
10162
10163 * value.c (~value): Update.
10164 (struct value) <contents>: Now unique_xmalloc_ptr.
10165 (value_contents_bits_eq, allocate_value_contents)
10166 (value_contents_raw, value_contents_all_raw)
10167 (value_contents_for_printing, value_contents_for_printing_const)
10168 (set_value_enclosing_type): Update.
10169
10170 2018-04-06 Tom Tromey <tom@tromey.com>
10171
10172 * value.c (range_s): Remove typedef, VEC.
10173 (struct range): Add operator<.
10174 (range_lessthan): Remove.
10175 (ranges_contain): Change type.
10176 (~value): Update.
10177 (struct value) <unavailable, optimized_out>: Now std::vector.
10178 (value_entirely_available)
10179 (value_entirely_covered_by_range_vector)
10180 (value_entirely_unavailable, value_entirely_optimized_out):
10181 Update.
10182 (insert_into_bit_range_vector): Change argument type.
10183 (find_first_range_overlap): Likewise.
10184 (struct ranges_and_idx, value_contents_bits_eq)
10185 (require_not_optimized_out, require_available): Update.
10186 (ranges_copy_adjusted): Change argument types.
10187 (value_optimized_out, value_copy, value_fetch_lazy): Update.
10188
10189 2018-04-06 Tom Tromey <tom@tromey.com>
10190
10191 * value.c (~value): Update.
10192 (struct value) <parent>: Now a value_ref_ptr.
10193 (value_parent, set_value_parent, value_address, value_copy):
10194 Update.
10195
10196 2018-04-06 Tom Tromey <tom@tromey.com>
10197
10198 * value.c (struct value): Add constructor, destructor, and member
10199 initializers.
10200 (allocate_value_lazy, value_decref): Update.
10201
10202 2018-04-06 Tom Tromey <tom@tromey.com>
10203
10204 * value.c (struct value) <released, next>: Remove.
10205 (all_values): Now a std::vector.
10206 (allocate_value_lazy): Update.
10207 (value_next): Remove.
10208 (value_mark, value_free_to_mark, release_value)
10209 (value_release_to_mark): Update.
10210
10211 2018-04-06 Tom Tromey <tom@tromey.com>
10212
10213 * value.h (fetch_subexp_value, value_release_to_mark): Update.
10214 (free_value_chain): Remove.
10215 * value.c (free_value_chain): Remove.
10216 (value_release_to_mark): Return a std::vector.
10217 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
10218 std::vector.
10219 (check_condition): Update.
10220 * eval.c (fetch_subexp_value): Change "val_chain" to a
10221 std::vector.
10222 * breakpoint.c (update_watchpoint): Update.
10223 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
10224
10225 2018-04-06 Tom Tromey <tom@tromey.com>
10226
10227 * value.h (free_all_values): Remove.
10228 * value.c (free_all_values): Remove.
10229
10230 2018-04-06 Tom Tromey <tom@tromey.com>
10231
10232 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
10233 (value_history_chain, value_history_count): Remove.
10234 (value_history): New global.
10235 (record_latest_value, access_value_history, show_values)
10236 (preserve_values): Update.
10237
10238 2018-04-06 Tom Tromey <tom@tromey.com>
10239
10240 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
10241 * varobj.c (varobj_set_display_format, varobj_set_value)
10242 (install_default_visualizer, construct_visualizer)
10243 (install_new_value, ~varobj, varobj_get_value_type)
10244 (my_value_of_variable, varobj_editable_p): Update.
10245 * c-varobj.c (c_describe_child, c_value_of_variable)
10246 (cplus_number_of_children, cplus_describe_child): Update.
10247 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
10248 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
10249 (ada_value_of_variable, ada_value_is_changeable_p): Update.
10250
10251 2018-04-06 Tom Tromey <tom@tromey.com>
10252
10253 * printcmd.c (last_examine_address): Change type to
10254 value_ref_ptr.
10255 (do_examine, x_command): Update.
10256
10257 2018-04-06 Tom Tromey <tom@tromey.com>
10258
10259 * value.c (release_value): Update.
10260 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
10261 (struct bpstats) <val>: Now a value_ref_ptr.
10262 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10263 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10264 (~watchpoint, print_it_watchpoint, watch_command_1)
10265 (invalidate_bp_value_on_memory_change): Update.
10266
10267 2018-04-06 Tom Tromey <tom@tromey.com>
10268
10269 * varobj.c (varobj_clear_saved_item)
10270 (update_dynamic_varobj_children, install_new_value, ~varobj):
10271 Update.
10272 * value.h (value_incref): Move declaration earlier.
10273 (value_decref): Rename from value_free.
10274 (struct value_ref_policy): New.
10275 (value_ref_ptr): New typedef.
10276 (struct value_deleter): Remove.
10277 (gdb_value_up): Remove typedef.
10278 (release_value): Change return type.
10279 (release_value_or_incref): Remove.
10280 * value.c (set_value_parent): Update.
10281 (value_incref): Change return type.
10282 (value_decref): Rename from value_free.
10283 (value_free_to_mark, free_all_values, free_value_chain): Update.
10284 (release_value): Return value_ref_ptr.
10285 (release_value_or_incref): Remove.
10286 (record_latest_value, set_internalvar, clear_internalvar):
10287 Update.
10288 * stack.c (info_frame_command): Don't call value_free.
10289 * python/py-value.c (valpy_dealloc, valpy_new)
10290 (value_to_value_object): Update.
10291 * printcmd.c (do_examine): Update.
10292 * opencl-lang.c (lval_func_free_closure): Update.
10293 * mi/mi-main.c (register_changed_p): Don't call value_free.
10294 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10295 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10296 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10297 value_free.
10298 * guile/scm-value.c (vlscm_free_value_smob)
10299 (vlscm_scm_from_value): Update.
10300 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10301 (frame_unwind_register_unsigned, get_frame_register_bytes)
10302 (put_frame_register_bytes): Don't call value_free.
10303 * findvar.c (address_from_register): Don't call value_free.
10304 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10305 * dwarf2loc.c (entry_data_value_free_closure)
10306 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10307 (dwarf2_evaluate_loc_desc_full): Update.
10308 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10309 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10310 (~watchpoint, watch_command_1)
10311 (invalidate_bp_value_on_memory_change): Update.
10312 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10313
10314 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10315
10316 PR gdb/23022
10317 * warning.m4: Add -Wno-error=deprecated-register.
10318 * configure: Re-generate.
10319
10320 2018-04-05 Tom Tromey <tom@tromey.com>
10321
10322 * linespec.h: Remove include of "vec.h".
10323
10324 2018-04-05 Tom Tromey <tom@tromey.com>
10325
10326 * linespec.c (typep): Remove typedef.
10327 (find_methods, find_superclass_methods): Take a std::vector.
10328 (find_method): Use std::vector.
10329
10330 2018-04-05 Tom Tromey <tom@tromey.com>
10331
10332 * utils.c (compare_strings): Remove.
10333 * utils.h (compare_strings): Remove.
10334 * objc-lang.h (find_imps): Update.
10335 * objc-lang.c (find_methods): Take a std::vector.
10336 (uniquify_strings, find_imps): Likewise.
10337 * linespec.c (find_methods): Take a std::vector.
10338 (decode_objc): Use std::vector.
10339 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10340 a std::vector.
10341 (find_method, find_function_symbols): Use std::vector.
10342
10343 2018-04-05 Tom Tromey <tom@tromey.com>
10344
10345 * completer.c (completion_tracker::completion_tracker): Remove
10346 cast.
10347 (completion_tracker::discard_completions): Likewise.
10348 * breakpoint.c (ambiguous_names_p): Remove cast.
10349 * ada-lang.c (_initialize_ada_language): Remove cast.
10350 * utils.h (streq): Update.
10351 (streq_hash): Add new declaration.
10352 * utils.c (streq): Return bool.
10353 (streq_hash): New function.
10354
10355 2018-04-05 Tom Tromey <tom@tromey.com>
10356
10357 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10358 Remove a string copy.
10359
10360 2018-04-05 Tom Tromey <tom@tromey.com>
10361
10362 * linespec.c (filter_results): Use std::vector.
10363 (decode_line_2, decode_line_full): Update.
10364
10365 2018-04-05 Tom Tromey <tom@tromey.com>
10366
10367 * linespec.c (canonical_to_fullform): Return std::string.
10368 (filter_results): Update.
10369 (struct decode_line_2_item): Add constructor.
10370 <fullform, displayform>: Now std::string.
10371 (decode_line_2_compare_items): Now a std::sort comparator.
10372 (decode_line_2): Update.
10373
10374 2018-04-05 Tom Tromey <tom@tromey.com>
10375
10376 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10377 (unexpected_linespec_error): Update.
10378 (linespec_parse_basic, parse_linespec): Update.
10379
10380 2018-04-05 Tom Tromey <tom@tromey.com>
10381
10382 * linespec.c (linespec_parse_basic): Reindent.
10383
10384 2018-04-05 Tom Tromey <tom@tromey.com>
10385
10386 * minsyms.h (iterate_over_minimal_symbols): Update.
10387 * minsyms.c (iterate_over_minimal_symbols): Take a
10388 gdb::function_view.
10389 * linespec.c (struct collect_minsyms): Remove.
10390 (compare_msyms): Now a std::sort comparator.
10391 (add_minsym): Add parameters.
10392 (search_minsyms_for_name): Update. Use std::vector.
10393
10394 2018-04-03 Tom Tromey <tom@tromey.com>
10395
10396 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10397 gdb::byte_vector.
10398
10399 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10400
10401 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10402
10403 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10404
10405 PR gdb/16959
10406 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10407 printing static type.
10408
10409 2018-04-01 Tom Tromey <tom@tromey.com>
10410
10411 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10412 (rs6000_xfer_shared_libraries): Update.
10413
10414 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10415
10416 * common/gdb_vecs.h (char_ptr): Remove.
10417 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10418
10419 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10420
10421 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10422 with std::vector.
10423 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10424
10425 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10426
10427 * tracepoint.h (struct uploaded_tp): Initialize fields.
10428 <actions, step_actions, cmd_strings>: Change type to
10429 std::vector<char *>.
10430 * tracepoint.c (get_uploaded_tp): Allocate with new.
10431 (free_uploaded_tps): Free with delete.
10432 (parse_tracepoint_definition): Adjust to std::vector change.
10433 * breakpoint.c (read_uploaded_action): Likewise.
10434 (create_tracepoint_from_upload): Likewise.
10435 * ctf.c (ctf_write_uploaded_tp): Likewise.
10436 (SET_ARRAY_FIELD): Likewise.
10437 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10438
10439 2018-03-30 Tom Tromey <tom@tromey.com>
10440
10441 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10442 std::unique_ptr.
10443 (svr4_keep_data_in_core): Update.
10444 (svr4_read_so_list): Update.
10445
10446 2018-03-30 Tom Tromey <tom@tromey.com>
10447
10448 * windows-nat.c (handle_output_debug_string, handle_exception):
10449 Update.
10450 * target.h (target_read_string): Update.
10451 * target.c (target_read_string): Change "string" to
10452 unique_xmalloc_ptr.
10453 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10454 Update.
10455 * solib-frv.c (frv_current_sos): Update.
10456 * solib-dsbt.c (dsbt_current_sos): Update.
10457 * solib-darwin.c (darwin_current_sos): Update.
10458 * linux-thread-db.c (inferior_has_bug): Update.
10459 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10460 Update. Remove alloca.
10461 * ada-lang.c (ada_main_name): Update.
10462
10463 2018-03-30 Tom Tromey <tom@tromey.com>
10464
10465 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10466 (struct dwo_file_deleter): New.
10467 (dwo_file_up): New typedef.
10468 (open_and_init_dwo_file): Use dwo_file_up.
10469 (free_dwo_file_cleanup): Remove.
10470
10471 2018-03-30 Tom Tromey <tom@tromey.com>
10472
10473 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10474 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10475
10476 2018-03-30 Tom Tromey <tom@tromey.com>
10477
10478 * dwarf2read.c (class free_cached_comp_units): New class.
10479 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10480 (free_cached_comp_units): Remove function.
10481
10482 2018-03-30 Tom Tromey <tom@tromey.com>
10483
10484 * utils.h (make_cleanup_unpush_target): Remove.
10485 * inf-ptrace.c (struct target_unpusher): New.
10486 (target_unpush_up) New typedef.
10487 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10488 target_unpush_up.
10489 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10490
10491 2018-03-27 Tom Tromey <tom@tromey.com>
10492
10493 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10494
10495 2018-03-27 Pedro Alves <palves@redhat.com>
10496 Tom Tromey <tom@tromey.com>
10497
10498 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10499 destructor. Now a class.
10500 (gdb_readline_wrapper_cleanup): Remove function.
10501 (gdb_readline_wrapper): Remove cleanups.
10502
10503 2018-03-27 Tom Tromey <tom@tromey.com>
10504
10505 * typeprint.h (struct type_print_options) <local_typedefs,
10506 global_typedefs>: Remove "struct" keyword.
10507 (class typedef_hash_table): New class.
10508 (recursively_update_typedef_hash, add_template_parameters)
10509 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10510 (find_typedef_in_hash): Don't declare.
10511 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10512 (typedef_hash_table::recursively_update): Rename from
10513 recursively_update_typedef_hash. Now a member.
10514 (typedef_hash_table::add_template_parameters): Rename from
10515 add_template_parameters. Now a member.
10516 (typedef_hash_table::typedef_hash_table): Now a constructor;
10517 rename from create_typedef_hash.
10518 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10519 rename from free_typedef_hash.
10520 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10521 (do_free_global_table): Remove.
10522 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10523 from copy_type_recursive.
10524 (create_global_typedef_table): Remove.
10525 (typedef_hash_table::find_global_typedef): Now a member of
10526 typedef_hash_table.
10527 (typedef_hash_table::find_typedef): Rename from
10528 find_typedef_in_hash; now a member.
10529 (whatis_exp): Update.
10530 * extension.h (struct ext_lang_type_printers): Add constructor and
10531 destructor.
10532 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10533 declare.
10534 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10535 Now a constructor; rename from start_ext_lang_type_printers.
10536 (ext_lang_type_printers): Now a destructor; rename from
10537 free_ext_lang_type_printers.
10538 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10539 Update.
10540 (c_type_print_base_struct_union): Update. Remove cleanups.
10541
10542 2018-03-27 Tom Tromey <tom@tromey.com>
10543
10544 * dwarf-index-write.c: Include <cmath>.
10545
10546 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10547
10548 * NEWS: Add entry describing new "set|show varsize-limit" command.
10549 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10550 command.
10551 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10552 "set variable".
10553
10554 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10555
10556 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10557 dwarf-index-write.c
10558 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10559 * dwarf-index-common.c: New file.
10560 * dwarf-index-common.h: New file.
10561 * dwarf-index-write.c: New file.
10562 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10563 (struct dwarf2_section_info): Move from here.
10564 (dwarf2_section_info_def): Likewise.
10565 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10566 (offset_type): Likewise.
10567 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10568 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10569 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10570 (byte_swap): Likewise.
10571 (MAYBE_SWAP): Likewise.
10572 (dwarf2_per_cu_ptr): Likewise.
10573 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10574 (struct tu_stats): Likewise.
10575 (struct dwarf2_per_objfile): Likewise.
10576 (struct dwarf2_per_cu_data): Likewise.
10577 (struct signatured_type): Likewise.
10578 (sig_type_ptr): Likewise.
10579 (DEF_VEC_P (sig_type_ptr)): Likewise.
10580 (INDEX4_SUFFIX): Likewise.
10581 (INDEX5_SUFFIX): Likewise.
10582 (DEBUG_STR_SUFFIX): Likewise.
10583 (dwarf2_read_section): Make non-static.
10584 (mapped_index_string_hash): Move from here.
10585 (dwarf5_djb_hash): Likewise.
10586 (file_write): Likewise.
10587 (class data_buf): Likewise.
10588 (struct symtab_index_entry): Likewise.
10589 (struct mapped_symtab): Likewise.
10590 (find_slot): Likewise.
10591 (hash_expand): Likewise.
10592 (add_index_entry): Likewise.
10593 (uniquify_cu_indices): Likewise.
10594 (class c_str_view): Likewise.
10595 (class c_str_view_hasher): Likewise.
10596 (class vector_hasher): Likewise.
10597 (write_hash_table): Likewise.
10598 (psym_index_map): Likewise.
10599 (struct addrmap_index_data): Likewise.
10600 (add_address_entry): Likewise.
10601 (add_address_entry_worker): Likewise.
10602 (write_address_map): Likewise.
10603 (symbol_kind): Likewise.
10604 (write_psymbols): Likewise.
10605 (struct signatured_type_index_data): Likewise.
10606 (write_one_signatured_type): Likewise.
10607 (recursively_count_psymbols): Likewise.
10608 (recursively_write_psymbols): Likewise.
10609 (class debug_names): Likewise.
10610 (check_dwarf64_offsets): Likewise.
10611 (psyms_seen_size): Likewise.
10612 (write_gdbindex): Likewise.
10613 (write_debug_names): Likewise.
10614 (assert_file_size): Likewise.
10615 (write_psymtabs_to_index): Likewise.
10616 (save_gdb_index_command): Likewise.
10617 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10618 command.
10619 * dwarf2read.h: New file.
10620
10621 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10622
10623 PR gdb/22670
10624 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10625 symbol name if the CU's language stores symbol names in linkage
10626 format.
10627 * language.h (struct language_defn)
10628 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10629 all instances of this struct.
10630
10631 2018-03-26 Tom Tromey <tom@tromey.com>
10632
10633 * stack.c (backtrace_command_1): Remove verbose code.
10634
10635 2018-03-26 Tom Tromey <tom@tromey.com>
10636
10637 * python/py-framefilter.c (py_print_type): Don't catch
10638 exceptions. Return void.
10639 (py_print_value): Likewise.
10640 (py_print_single_arg): Likewise.
10641 (enumerate_args): Don't catch exceptions.
10642 (py_print_args): Likewise.
10643 (py_print_frame): Likewise.
10644 (gdbpy_apply_frame_filter): Catch exceptions here.
10645
10646 2018-03-26 Tom Tromey <tom@tromey.com>
10647
10648 * stack.c (_initialize_stack): Remove trailing newlines from help
10649 text. Add "Usage" line to "backtrace" help.
10650
10651 2018-03-26 Tom Tromey <tom@tromey.com>
10652
10653 PR python/16486:
10654 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10655
10656 2018-03-26 Tom Tromey <tom@tromey.com>
10657
10658 * python/py-framefilter.c (py_print_single_arg): Return
10659 EXT_LANG_BT_ERROR from catch.
10660
10661 2018-03-26 Tom Tromey <tom@tromey.com>
10662
10663 PR backtrace/15584:
10664 * stack.c (backtrace_command_1): Move some code into no-filters
10665 "if".
10666
10667 2018-03-26 Tom Tromey <tom@tromey.com>
10668
10669 * python/py-framefilter.c (throw_quit_or_print_exception): New
10670 function.
10671 (gdbpy_apply_frame_filter): Use it.
10672
10673 2018-03-26 Tom Tromey <tom@tromey.com>
10674
10675 PR cli/17716:
10676 * python/py-framefilter.c (py_print_type, py_print_value)
10677 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10678 RETURN_MASK_ERROR.
10679
10680 2018-03-26 Tom Tromey <tom@tromey.com>
10681
10682 * python/py-framefilter.c (enumerate_args): Use
10683 gdb::unique_xmalloc_ptr.
10684
10685 2018-03-26 Tom Tromey <tom@tromey.com>
10686
10687 * python/py-framefilter.c (py_print_frame): Return
10688 EXT_LANG_BT_OK.
10689 (gdbpy_apply_frame_filter): Update comment.
10690 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10691 Remove.
10692 <EXT_LANG_BT_NO_FILTERS>: Change value.
10693
10694 2018-03-26 Tom Tromey <tom@tromey.com>
10695
10696 PR backtrace/15582:
10697 * stack.c (backtrace_command): Parse "hide" argument.
10698 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10699 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10700 constant.
10701
10702 2018-03-26 Tom Tromey <tom@tromey.com>
10703
10704 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10705 add "flags".
10706 (backtrace_command): Remove "fulltrace", add "flags".
10707
10708 2018-03-26 Tom Tromey <tom@tromey.com>
10709
10710 * stack.c (backtrace_command): Rewrite command line parsing.
10711
10712 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10713
10714 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10715
10716 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10717
10718 * filename-seen-cache.h: Add include guard.
10719
10720 2018-03-26 Keith Seitz <keiths@redhat.com>
10721
10722 * symfile.c (place_section): Remove "struct" from section_addr_info
10723 in comment.
10724 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10725 "struct" keyword from section_addr_info.
10726
10727 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10728
10729 * regformats/regdef.h (reg): Add constructors.
10730
10731 2018-03-25 Pedro Alves <palves@redhat.com>
10732
10733 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10734 if then/else bodies in var_func_name extraction.
10735
10736 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10737
10738 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10739 lookup_minimal_symbol() to find symbol entry.
10740 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10741
10742 2018-03-23 Keith Seitz <keiths@redhat.com>
10743
10744 PR c++/22968
10745 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10746 nested type definitions for C++, too.
10747
10748 2018-03-23 Tom Tromey <tom@tromey.com>
10749
10750 * machoread.c (struct oso_el): Add a constructor. Don't define as
10751 a typedef.
10752 (macho_register_oso): Remove.
10753 (macho_symtab_read): Take a std::vector.
10754 (oso_el_compare_name): Now a std::sort comparator.
10755 (macho_symfile_read_all_oso): Take a std::vector.
10756 (macho_symfile_read): Use std::vector. Remove cleanups.
10757
10758 2018-03-22 Tom Tromey <tom@tromey.com>
10759
10760 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10761 (record_full_goto_bookmark): Use std::string.
10762
10763 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10764
10765 PR tdep/18295
10766 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10767 a single mask.
10768
10769 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10770
10771 * rs6000-tdep.c (store_insn_p): New function.
10772 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10773 and cr_reg to their unshifted values. Use store_insn_p to
10774 match LR saves using either R1 or fdata->alloca_reg. Use
10775 store_insn_p to match CR saves. Set alloca_reg_offset
10776 when alloca_reg and framep are set. Remove lr_reg shift
10777 when assigning to fdata->lr_register.
10778
10779 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10780
10781 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10782 command line args instead of emitting a warning.
10783
10784 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10785
10786 * tracepoint.h (struct static_tracepoint_marker): Initialize
10787 fields, define default constructor, move constructor and move
10788 assignment, disable the rest.
10789 <str_id, extra>: Make std::string.
10790 (release_static_tracepoint_marker): Remove.
10791 (free_current_marker): Remove.
10792 * tracepoint.c (free_current_marker): Remove.
10793 (parse_static_tracepoint_marker_definition): Adjust to
10794 std::string, use new hex2str overload.
10795 (release_static_tracepoint_marker): Remove.
10796 (print_one_static_tracepoint_marker): Get marker by reference
10797 and adjust to std::string.
10798 (info_static_tracepoint_markers_command): Adjust to std::vector
10799 changes
10800 * target.h (static_tracepoint_marker_p): Remove typedef.
10801 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10802 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10803 bool.
10804 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10805 * target-debug.h
10806 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10807 (target_debug_print_std_vector_static_tracepoint_marker): New.
10808 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10809 to...
10810 (target_debug_print_static_tracepoint_marker_p): ... this.
10811 * target-delegates.c: Re-generate.
10812 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10813 Make std::string.
10814 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10815 (decode_static_tracepoint_spec): Adjust to std::vector.
10816 (tracepoint_print_one_detail): Adjust to std::string.
10817 (strace_marker_decode_location): Adjust to std::string.
10818 (update_static_tracepoint): Adjust to std::string, remove call
10819 to release_static_tracepoint_marker.
10820 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10821 Adjust to std::vector.
10822 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10823 (remote_static_tracepoint_markers_by_strid): Adjust to
10824 std::vector.
10825 * common/rsp-low.h (hex2str): New overload with explicit count
10826 of bytes.
10827 * common/rsp-low.c (hex2str): New overload with explicit count
10828 of bytes.
10829 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10830 (_initialize_rsp_low_selftests): Add test_hex2str test.
10831 * unittests/tracepoint-selftests.c
10832 (test_parse_static_tracepoint_marker_definition): Adjust to
10833 std::string.
10834
10835 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10836
10837 * tracepoint.c (parse_static_tracepoint_marker_definition):
10838 Consider case where the definition is followed by more
10839 definitions.
10840 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10841 tracepoint-selftests.c.
10842 * unittests/tracepoint-selftests.c: New.
10843
10844 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10845
10846 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10847 Carvalho.
10848
10849 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10850
10851 * symtab.c (find_pc_sect_line): fixed indentation.
10852
10853 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10854
10855 * symtab.c (find_pc_sect_line): now uses binary search.
10856
10857 2018-03-19 Tom Tromey <tom@tromey.com>
10858
10859 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10860 "IDENT" production.
10861
10862 2018-03-19 Pedro Alves <palves@redhat.com>
10863 Tom Tromey <tom@tromey.com>
10864
10865 * unittests/observable-selftests.c: New file.
10866 * common/observable.h: New file.
10867 * observable.h: New file.
10868 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10869 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10870 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10871 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10872 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10873 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10874 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10875 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10876 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10877 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10878 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10879 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
10880 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
10881 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
10882 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
10883 tui/tui-interp.c, valops.c: Update all users.
10884 * tui/tui-hooks.c (tui_bp_created_observer)
10885 (tui_bp_deleted_observer, tui_bp_modified_observer)
10886 (tui_inferior_exit_observer, tui_before_prompt_observer)
10887 (tui_normal_stop_observer, tui_register_changed_observer):
10888 Remove.
10889 (tui_observers_token): New global.
10890 (attach_or_detach, tui_attach_detach_observers): New functions.
10891 (tui_install_hooks, tui_remove_hooks): Use
10892 tui_attach_detach_observers.
10893 * record-btrace.c (record_btrace_thread_observer): Remove.
10894 (record_btrace_thread_observer_token): New global.
10895 * observer.sh: Remove.
10896 * observer.c: Rename to observable.c.
10897 * observable.c (namespace gdb_observers): Define new objects.
10898 (observer_debug): Move into gdb_observers namespace.
10899 (struct observer, struct observer_list, xalloc_observer_list_node)
10900 (xfree_observer_list_node, generic_observer_attach)
10901 (generic_observer_detach, generic_observer_notify): Remove.
10902 (_initialize_observer): Update.
10903 Don't include observer.inc.
10904 * Makefile.in (generated_files): Remove observer.h, observer.inc.
10905 (clean mostlyclean): Likewise.
10906 (observer.h, observer.inc): Remove targets.
10907 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
10908 (COMMON_SFILES): Use observable.c, not observer.c.
10909 * .gitignore: Remove observer.h.
10910
10911 2018-03-18 Tom Tromey <tom@tromey.com>
10912
10913 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
10914 gdb::def_vector.
10915 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
10916
10917 2018-03-17 Tom Tromey <tom@tromey.com>
10918
10919 * auto-load.c (auto_load_objfile_script_1): Use std::string.
10920
10921 2018-03-17 Tom Tromey <tom@tromey.com>
10922
10923 * target.c (class scoped_target_fd): New.
10924 (target_fileio_close_cleanup): Remove.
10925 (target_fileio_read_alloc_1): Use scoped_target_fd.
10926
10927 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
10928
10929 * silent-rules.mk: New.
10930 * Makefile.in: Include silent-rules.mk
10931 (srcdir, VPATH, top_srcdir): Move up.
10932 (COMPILE): Add ECHO_CXX.
10933 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
10934 (init.c): Add ECHO_INIT_C.
10935 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
10936 (version.c): Add ECHO_GEN.
10937 (printcmd.o): Add ECHO_CXX.
10938 (target-float.o): Add ECHO_CXX.
10939 (ada-exp.o): Add ECHO_CXX.
10940 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
10941 (insight$(EXEEXT)): Add ECHO_CXXLD.
10942 * gnulib/configure.ac: Add AM_SILENT_RULES.
10943 * gnulib/aclocal.m4: Re-generate.
10944 * gnulib/configure: Re-generate.
10945 * gnulib/import/Makefile.in: Re-generate.
10946
10947 2018-03-16 Tom Tromey <tom@tromey.com>
10948
10949 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
10950 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
10951 * utils.c (do_free_section_addr_info)
10952 (make_cleanup_free_section_addr_info): Remove.
10953 * symfile.h (struct other_sections): Add constructor.
10954 (struct section_addr_info): Remove.
10955 (section_addr_info): New typedef.
10956 (struct sym_fns) <sym_offsets>: Change type of parameter.
10957 (build_section_addr_info_from_objfile)
10958 (relative_addr_info_to_section_offsets, addr_info_make_relative)
10959 (default_symfile_offsets, symbol_file_add)
10960 (symbol_file_add_from_bfd)
10961 (build_section_addr_info_from_section_table): Update.
10962 (alloc_section_addr_info, free_section_addr_info): Don't declare.
10963 * symfile.c (alloc_section_addr_info): Remove.
10964 (build_section_addr_info_from_section_table): Change return type.
10965 Update.
10966 (build_section_addr_info_from_bfd)
10967 (build_section_addr_info_from_objfile): Likewise.
10968 (free_section_addr_info): Remove.
10969 (relative_addr_info_to_section_offsets): Change type of "addrs".
10970 (addrs_section_compar): Now a std::sort comparator.
10971 (addrs_section_sort): Change return type.
10972 (addr_info_make_relative): Change type of "addrs". Update.
10973 (default_symfile_offsets, syms_from_objfile_1)
10974 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
10975 (symbol_file_add_separate): Update.
10976 (symbol_file_add): Change type of "addrs". Update.
10977 (add_symbol_file_command): Update. Remove cleanups.
10978 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
10979 cleanups.
10980 * symfile-debug.c (debug_sym_offsets): Change type of "info".
10981 * solib.c (solib_read_symbols): Update.
10982 * objfiles.c (objfile_relocate): Update. Remove cleanups.
10983 * machoread.c (macho_symfile_offsets): Update.
10984 * jit.c (jit_bfd_try_read_symtab): Update.
10985
10986 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
10987
10988 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10989 unittests/utils-selftests.c.
10990 * unittests/utils-selftests.c: New file.
10991
10992 2018-03-14 Tom Tromey <tom@tromey.com>
10993
10994 PR cli/14977:
10995 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
10996 for NULL.
10997
10998 2018-03-14 Tom Tromey <tom@tromey.com>
10999
11000 PR cli/19918:
11001 * printcmd.c (printf_pointer): Allow "-" in format.
11002
11003 2018-03-14 Tom Tromey <tom@tromey.com>
11004
11005 * printcmd.c (_initialize_printcmd): Add usage to printf.
11006
11007 2018-03-14 Yao Qi <qiyao@sourceware.org>
11008
11009 * MAINTAINERS: Update my email address.
11010
11011 2018-03-13 Tom Tromey <tom@tromey.com>
11012
11013 * machoread.c (macho_check_dsym): Change filenamep to a
11014 std::string*.
11015 (macho_symfile_read): Update.
11016 * symfile.c (load_command): Use std::string.
11017
11018 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
11019
11020 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
11021 to error message string.
11022 (riscv_register_name): Use xsnprintf instead of sprintf.
11023 (riscv_insn::fetch_instruction): Use gdb_assert instead of
11024 internal_error.
11025 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
11026 error.
11027 (riscv_push_dummy_call): Likewise.
11028
11029 2018-03-12 Tom Tromey <tom@tromey.com>
11030
11031 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
11032 Use gdb::byte_vector.
11033 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
11034
11035 2018-03-12 Yao Qi <yao.qi@linaro.org>
11036
11037 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
11038 parameter type to readable_regcache.
11039 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
11040 the declaration.
11041
11042 2018-03-11 Tom Tromey <tom@tromey.com>
11043
11044 * dwarf2read.c (struct nextfield): Add initializers.
11045 (struct nextfnfield): Remove.
11046 (struct fnfieldlist): Add initializers. Remove "length" and
11047 "head", use std::vector.
11048 (struct decl_field_list): Remove.
11049 (struct field_info): Add initializers.
11050 <fields, baseclasses>: Now std::vector.
11051 <nbaseclasses, nfnfields, typedef_field_list_count,
11052 nested_types_list_count>: Remove.
11053 (dwarf2_add_field, dwarf2_add_type_defn)
11054 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
11055 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
11056 (process_structure_scope): Update.
11057
11058 2018-03-11 Tom Tromey <tom@tromey.com>
11059
11060 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
11061 for use by std::sort.
11062 (build_type_psymtabs_1): Use std::vector.
11063
11064 2018-03-09 Eli Zaretskii <eliz@gnu.org>
11065
11066 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
11067 and LIBMPFR in the printed configuration.
11068
11069 2018-03-08 Tom Tromey <tom@tromey.com>
11070
11071 * source.c (get_filename_and_charpos): Use scoped_fd.
11072 * nto-procfs.c (procfs_open_1): Use scoped_fd.
11073 (procfs_pidlist): Likewise.
11074 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
11075 (iterate_over_mappings): Likewise.
11076
11077 2018-03-08 Tom Tromey <tom@tromey.com>
11078
11079 * infcall.c (struct call_return_meta_info)
11080 <stack_temporaries_enabled>: Remove.
11081 (get_call_return_value, call_function_by_hand_dummy): Update.
11082 * thread.c (disable_thread_stack_temporaries): Remove.
11083 (enable_thread_stack_temporaries): Remove.
11084 (thread_stack_temporaries_enabled_p): Return bool.
11085 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
11086 (get_last_thread_stack_temporary): Update.
11087 * eval.c (evaluate_subexp): Update.
11088 * gdbthread.h (class enable_thread_stack_temporaries): Now a
11089 class, not a function.
11090 (value_ptr, value_vec): Remove typedefs.
11091 (class thread_info) <stack_temporaries_enabled>: Now bool.
11092 <stack_temporaries>: Now a std::vector.
11093 (thread_stack_temporaries_enabled_p)
11094 (value_in_thread_stack_temporaries): Return bool.
11095
11096 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
11097
11098 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11099 (getpkt_or_notif_sane_1): Likewise.
11100
11101 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11102
11103 * build-id.c (build_id_to_debug_bfd): Use std::string.
11104
11105 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11106
11107 * build-id.c (find_separate_debug_file_by_buildid): Return
11108 std::string.
11109 * build-id.h (find_separate_debug_file_by_buildid): Return
11110 std::string.
11111 * coffread.c (coff_symfile_read): Adjust to std::string.
11112 * elfread.c (elf_symfile_read): Adjust to std::string.
11113 * symfile.c (separate_debug_file_exists): Change parameter to
11114 std::string.
11115 (find_separate_debug_file): Return std::string.
11116 (find_separate_debug_file_by_debuglink): Return std::string.
11117 * symfile.h (find_separate_debug_file_by_debuglink): Return
11118 std::string.
11119
11120 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11121
11122 * common/xml-utils.c (xml_escape_text): Move code to...
11123 (xml_escape_text_append): ... this new function.
11124 * common/xml-utils.h (xml_escape_text_append): New declaration.
11125 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11126 New function.
11127 (_initialize_xml_utils): register test_xml_escape_text_append as
11128 a selftest.
11129
11130 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11131
11132 * defs.h: Remove MAX_REGISTER_SIZE.
11133 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
11134 asserts.
11135 * python/py-unwind.c (pyuw_sniffer): Likewise.
11136
11137 2018-03-07 Tom Tromey <tom@tromey.com>
11138
11139 * linux-tdep.c (linux_info_proc): Update.
11140 * target.h (struct target_ops) <to_fileio_readlink>: Return
11141 optional<string>.
11142 (target_fileio_readlink): Return optional<string>.
11143 * remote.c (remote_hostio_readlink): Return optional<string>.
11144 * inf-child.c (inf_child_fileio_readlink): Return
11145 optional<string>.
11146 * target.c (target_fileio_readlink): Return optional<string>.
11147
11148 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
11149
11150 * regcache.c (cooked_read_test): Add riscv to the list of
11151 architectures that have a save_reggroup.
11152
11153 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
11154
11155 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
11156 value is not a dynamic class object.
11157
11158 2018-03-06 Tom Tromey <tom@tromey.com>
11159
11160 * rust-exp.y: Formatting fixes.
11161
11162 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11163
11164 * riscv-tdep.c (riscv_register_name): Remove target description
11165 support.
11166 (riscv_gdbarch_init): Remove target description check.
11167
11168 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11169
11170 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
11171 comment.
11172 * riscv-tdep.h: Likewise.
11173
11174 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11175
11176 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
11177 (riscv_pseudo_register_write): Delete.
11178 (riscv_gdbarch_init): Remove all use of pseudo registers.
11179
11180 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11181
11182 * record-btrace.c (btrace_print_lines): Replace cleanup
11183 parameter with RAII equivalents.
11184 (btrace_insn_history): Replace cleanup with RAII equivalents.
11185 * ui-out.h (make_cleanup_ui_out_list_begin_end,
11186 make_cleanup_ui_out_tuple_begin_end): Remove.
11187 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
11188 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
11189 make_cleanup_ui_out_list_begin_end): Remove.
11190
11191 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11192
11193 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
11194 parameter types to std::vector. Use bool.
11195 (record_btrace_wait): Replace VEC(tp_t) with
11196 std::vector<thread_info *>.
11197 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
11198
11199 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11200
11201 * record-btrace.c (record_btrace_disable_callback): Remove.
11202 (struct scoped_btrace_disable): New.
11203 (record_btrace_open): Use scoped_btrace_disable.
11204
11205 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11206
11207 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
11208 reading values from registers.
11209
11210 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11211
11212 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
11213 where appropriate.
11214
11215 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11216
11217 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
11218 change parameter type. Use GDB's print functions, and use
11219 core_addr_to_string where appropriate.
11220 (riscv_push_dummy_call): Use core_addr_to_string where
11221 appropriate, update call to riscv_print_arg_location, and reindent
11222 a few lines.
11223 (riscv_return_value): Update call to riscv_print_arg_location.
11224
11225 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11226 Tim Newsome <tim@sifive.com>
11227 Albert Ou <a0u@eecs.berkeley.edu>
11228 Darius Rad <darius@bluespec.com>
11229
11230 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
11231 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
11232 (ALLDEPFILES): Add riscv-tdep.c
11233 * configure.tgt: Add riscv support.
11234 * riscv-tdep.c: New file.
11235 * riscv-tdep.h: New file.
11236 * NEWS: Mention new target.
11237 * MAINTAINERS: Add entry for riscv.
11238
11239 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11240
11241 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
11242 fields within aggregates.
11243
11244 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
11245
11246 * record-btrace.c (btrace_print_lines): Change type of flags to
11247 gdb_disassembly_flags.
11248
11249 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11250
11251 * fbsd-nat.c: Include "inf-ptrace.h".
11252 (USE_SIGTRAP_SIGINFO): Conditionally define.
11253 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
11254 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
11255 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
11256 function.
11257 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
11258 Likewise.
11259 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
11260 Likewise.
11261 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
11262 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
11263 "supports_stopped_by_hw_breakpoint" target methods.
11264
11265 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11266
11267 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
11268 * fbsd-nat.c (debug_fbsd_nat): New variable.
11269 (show_fbsd_nat_debug): New function.
11270 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
11271 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
11272
11273 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11274
11275 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
11276 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
11277 prototype.
11278 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
11279 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11280 method.
11281
11282 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11283
11284 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11285 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11286
11287 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11288
11289 * charset.c (struct charset_vector): New.
11290 (charsets): Change type to charset_vector.
11291 (find_charset_names): Adjust.
11292 (add_one): Adjust.
11293 (_initialize_charset): Adjust.
11294
11295 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11296
11297 * progspace.h (struct program_space) <deleted_solibs>: Change
11298 type to std::vector<std::string>.
11299 * progspace.c (clear_program_space_solib_cache): Adjust.
11300 * breakpoint.c (print_solib_event): Adjust.
11301 (check_status_catch_solib): Adjust.
11302 * solib.c (update_solib_list): Adjust.
11303 * ui-out.h (class ui_out) <field_string>: New overload.
11304 * ui-out.c (ui_out::field_string): New overload.
11305
11306 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11307
11308 * progspace.h (struct program_space): Add constructor and
11309 destructor, initialize fields.
11310 (add_program_space): Remove.
11311 * progspace.c (add_program_space): Rename to...
11312 (program_space::program_space): ... this.
11313 (release_program_space): Rename to...
11314 (program_space::~program_space): ... this.
11315 (delete_program_space): Use delete to delete program_space.
11316 (initialize_progspace): Use new to allocate program_space.
11317 * inferior.c (add_inferior_with_spaces): Likewise.
11318 (clone_inferior_command): Likewise.
11319 * infrun.c (follow_fork_inferior): Likewise.
11320 (handle_vfork_child_exec_or_exit): Likewise.
11321
11322 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11323
11324 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11325 (delim_string_to_char_ptr_vec): Return std::vector of
11326 gdb::unique_xmalloc_ptr.
11327 (dirnames_to_char_ptr_vec_append): Take std::vector of
11328 gdb::unique_xmalloc_ptr.
11329 (dirnames_to_char_ptr_vec): Return std::vector of
11330 gdb::unique_xmalloc_ptr.
11331 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11332 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11333 (delim_string_to_char_ptr_vec): Return an std::vector of
11334 gdb::unique_xmalloc_ptr, adjust the code.
11335 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11336 gdb::unique_xmalloc_ptr, adjust the code.
11337 (dirnames_to_char_ptr_vec): Return an std::vector of
11338 gdb::unique_xmalloc_ptr, adjust the code.
11339 * auto-load.c (auto_load_safe_path_vec): Change type to
11340 std::vector of gdb::unique_xmalloc_ptr.
11341 (auto_load_expand_dir_vars): Return an std::vector of
11342 gdb::unique_xmalloc_ptr, adjust the code.
11343 (auto_load_safe_path_vec_update): Adjust.
11344 (filename_is_in_auto_load_safe_path_vec): Adjust.
11345 (auto_load_objfile_script_1): Adjust.
11346 * build-id.c (build_id_to_debug_bfd): Adjust.
11347 * linux-thread-db.c (thread_db_load_search): Adjust.
11348 * source.c (add_path): Adjust.
11349 (openp): Adjust.
11350 * symfile.c (find_separate_debug_file): Adjust.
11351 * utils.c (do_free_char_ptr_vec): Remove.
11352 (make_cleanup_free_char_ptr_vec): Remove.
11353
11354 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11355
11356 PR gdb/22907
11357 * common/pathstuff.c: Conditionally include "<windows.h>".
11358
11359 2018-03-01 Georg Sauthoff <mail@georg.so>
11360
11361 PR gdb/22888
11362 * gcore.in: Quote variables and switch interpreter to bash.
11363
11364 2018-03-01 Tom Tromey <tom@tromey.com>
11365
11366 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11367 assertion. Add assertion for discriminant_index.
11368 (quirk_rust_enum): Use correct base type name in univariant case.
11369
11370 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11371
11372 * record.c (get_call_history_modifiers): Return a
11373 record_print_flags.
11374 (cmd_record_call_history): Adjust.
11375 * record-btrace.c (record_btrace_call_history): Adjust.
11376 (record_btrace_call_history_range): Adjust.
11377 (record_btrace_call_history_from): Adjust.
11378 * target-debug.h (target_debug_print_record_print_flags): New.
11379 * target-delegates.c: Re-generate.
11380 * target.c (target_call_history): Change flags type.
11381 (target_call_history_from): Likewise.
11382 (target_call_history_range): Likewise.
11383 * target.h (struct target_ops) <target_call_history>: Likewise.
11384 (target_call_history_from): Likewise.
11385 (target_call_history_range): Likewise.
11386
11387 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11388 Simon Marchi <simon.marchi@polymtl.ca>
11389
11390 * common/common-utils.c: Include "sys/stat.h".
11391 (is_regular_file): Move here from "source.c"; change return
11392 type to "bool".
11393 * common/common-utils.h (is_regular_file): New prototype.
11394 * common/pathstuff.c (contains_dir_separator): New function.
11395 * common/pathstuff.h (contains_dir_separator): New prototype.
11396 * source.c: Don't include "sys/stat.h".
11397 (is_regular_file): Move to "common/common-utils.c".
11398
11399 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11400
11401 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11402 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11403 * auto-load.c: Include "common/pathstuff.h".
11404 * common/common-def.h (current_directory): Move here.
11405 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11406 function.
11407 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11408 prototype.
11409 * common/pathstuff.c: New file.
11410 * common/pathstuff.h: New file.
11411 * compile/compile.c: Include "common/pathstuff.h".
11412 * defs.h (current_directory): Move to "common/common-defs.h".
11413 * dwarf2read.c: Include "common/pathstuff.h".
11414 * exec.c: Likewise.
11415 * guile/scm-safe-call.c: Likewise.
11416 * linux-thread-db.c: Likewise.
11417 * main.c: Likewise.
11418 * nto-tdep.c: Likewise.
11419 * objfiles.c: Likewise.
11420 * source.c: Likewise.
11421 * symtab.c: Likewise.
11422 * utils.c: Include "common/pathstuff.h".
11423 (gdb_realpath): Move to "common/pathstuff.c".
11424 (gdb_realpath_keepfile): Likewise.
11425 (gdb_abspath): Likewise.
11426 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11427 (gdb_realpath_keepfile): Likewise.
11428 (gdb_abspath): Likewise.
11429
11430 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11431
11432 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11433 wildcard process pid for super_resume for kernels with a
11434 specific bug.
11435
11436 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11437
11438 * compile/compile.c (get_args): Add additional comments
11439 explaining function.
11440
11441 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11442 Tom Tromey <tom@tromey.com>
11443
11444 * target.h (memory_write_request_s): Remove typedef. Don't define
11445 VEC.
11446 (target_write_memory_blocks): Change argument to std::vector.
11447 (struct memory_write_request): Add constructor.
11448 * target-memory.c (compare_block_starting_address): Return bool.
11449 Change argument types.
11450 (claim_memory): Change arguments to use std::vector.
11451 (split_regular_and_flash_blocks, blocks_to_erase)
11452 (compute_garbled_blocks): Likewise.
11453 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11454 (target_write_memory_blocks): Change argument to std::vector.
11455 * symfile.c (struct load_section_data): Add constructor and
11456 destructor. Use std::vector for "requests".
11457 (struct load_progress_data): Add initializers.
11458 (load_section_callback): Update. Use "new".
11459 (clear_memory_write_data): Remove.
11460 (generic_load): Update.
11461
11462 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11463
11464 * arch/aarch64.h: Use common/tdesc.h.
11465
11466 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11467
11468 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11469 architecture with a 64-bit ABI.
11470
11471 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11472
11473 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11474 ahead of target description loading.
11475
11476 2018-02-26 Tom Tromey <tom@tromey.com>
11477
11478 * stack.c (backtrace_command_1): Update.
11479 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11480 of "flags".
11481 * python/py-framefilter.c (py_print_frame)
11482 (gdbpy_apply_frame_filter): Change type of "flags".
11483 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11484 of "flags".
11485 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11486 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11487 * extension.h (enum frame_filter_flag): Rename from
11488 frame_filter_flags.
11489 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11490 (apply_ext_lang_frame_filter): Change type of "flags".
11491 * extension.c (apply_ext_lang_frame_filter): Change type of
11492 "flags".
11493 * extension-priv.h (struct extension_language_ops)
11494 <apply_frame_filter>: Change type of "flags".
11495
11496 2018-02-26 Tom Tromey <tom@tromey.com>
11497
11498 PR python/16497:
11499 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11500 off-by-one in py_end computation.
11501 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11502 PRINT_MORE_FRAMES.
11503 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11504 constant.
11505
11506 2018-02-26 Tom Tromey <tom@tromey.com>
11507
11508 * dwarf2read.c (struct variant_field): New.
11509 (struct nextfield) <variant>: New field.
11510 (dwarf2_add_field): Handle DW_TAG_variant_part.
11511 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11512 discriminated union.
11513 (read_structure_type): Handle DW_TAG_variant_part.
11514 (handle_struct_member_die): New function, extracted from
11515 process_structure_scope. Handle DW_TAG_variant.
11516 (process_structure_scope): Handle discriminated unions. Call
11517 handle_struct_member_die.
11518
11519 2018-02-26 Tom Tromey <tom@tromey.com>
11520
11521 * rust-lang.h (rust_last_path_segment): Declare.
11522 * rust-lang.c (rust_last_path_segment): Now public. Change
11523 contract.
11524 (struct disr_info): Remove.
11525 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11526 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11527 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11528 (rust_enum_p, rust_enum_variant): New function.
11529 (rust_underscore_fields): Remove "offset" parameter.
11530 (rust_print_enum): New function.
11531 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11532 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11533 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11534 enums.
11535 (rust_internal_print_type): New function, from rust_print_type.
11536 Remove enum code.
11537 (rust_print_type): Call rust_internal_print_type.
11538 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11539 Update enum handling.
11540 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11541 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11542 (rust_union_quirks): New functions.
11543 (process_full_comp_unit, process_full_type_unit): Call
11544 rust_union_quirks.
11545 (process_structure_scope): Update rust_unions if necessary.
11546
11547 2018-02-26 Tom Tromey <tom@tromey.com>
11548
11549 * value.h (value_union_variant): Declare.
11550 * valops.c (value_union_variant): New function.
11551 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11552 (struct discriminant_info): New.
11553 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11554 enumerator.
11555 (struct main_type) <flag_discriminated_union>: New field.
11556
11557 2018-02-26 Tom Tromey <tom@tromey.com>
11558
11559 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11560 unittests/unpack-selftests.c.
11561 * unittests/unpack-selftests.c: New file.
11562 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11563
11564 2018-02-26 Yao Qi <yao.qi@linaro.org>
11565
11566 * dwarf2read.c (struct partial_die_info) <read>: New method.
11567 (read_partial_die): Remove the declaration.
11568 (load_partial_dies): Update.
11569 (partial_die_info::partial_die_info):
11570 (read_partial_die): Change it to partial_die_info::read.
11571
11572 2018-02-26 Yao Qi <yao.qi@linaro.org>
11573
11574 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11575 (fixup_partial_die): Remove declaration.
11576 (scan_partial_symbols): Update.
11577 (partial_die_parent_scope): Likewise.
11578 (partial_die_full_name): Likewise.
11579 (fixup_partial_die): Change it to partial_die_info::fixup.
11580
11581 2018-02-26 Yao Qi <yao.qi@linaro.org>
11582
11583 * dwarf2read.c (read_partial_die): Update the declaration.
11584 (load_partial_dies): Caller update.
11585 (read_partial_die): Remove one argument abbrev_len.
11586
11587 2018-02-26 Yao Qi <yao.qi@linaro.org>
11588
11589 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11590 assignment operator.
11591 (load_partial_dies): Use ctor and copy ctor.
11592 (read_partial_die): Update.
11593 (dwarf2_cu::find_partial_die): Use ctor.
11594
11595 2018-02-26 Yao Qi <yao.qi@linaro.org>
11596
11597 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11598 (find_partial_die_in_comp_unit): Change it to
11599 dwarf2_cu::find_partial_die.
11600 (find_partial_die): Update.
11601
11602 2018-02-26 Yao Qi <yao.qi@linaro.org>
11603
11604 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11605 is NULL.
11606
11607 2018-02-26 Yao Qi <yao.qi@linaro.org>
11608
11609 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11610
11611 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11612
11613 * arch/amd64.h: Use common/tdesc.h.
11614 * arch/i386.c: Likewise.
11615 * arch/i386.h: Likewise.
11616 * arch/tic6x.c: Likewise.
11617 * arch/tdesc.h: Move file from here...
11618 * common/tdesc.h: ...to here.
11619 * features/aarch64-core.c: Regenerate.
11620 * features/aarch64-fpu.c: Regenerate.
11621 * features/i386/32bit-avx.c: Regenerate.
11622 * features/i386/32bit-avx512.c: Regenerate.
11623 * features/i386/32bit-core.c: Regenerate.
11624 * features/i386/32bit-linux.c: Regenerate.
11625 * features/i386/32bit-mpx.c: Regenerate.
11626 * features/i386/32bit-pkeys.c: Regenerate.
11627 * features/i386/32bit-sse.c: Regenerate.
11628 * features/i386/64bit-avx.c: Regenerate.
11629 * features/i386/64bit-avx512.c: Regenerate.
11630 * features/i386/64bit-core.c: Regenerate.
11631 * features/i386/64bit-linux.c: Regenerate.
11632 * features/i386/64bit-mpx.c: Regenerate.
11633 * features/i386/64bit-pkeys.c: Regenerate.
11634 * features/i386/64bit-segments.c: Regenerate.
11635 * features/i386/64bit-sse.c: Regenerate.
11636 * features/i386/x32-core.c: Regenerate.
11637 * features/tic6x-c6xp.c: Regenerate.
11638 * features/tic6x-core.c: Regenerate.
11639 * features/tic6x-gp.c: Regenerate.
11640 * target-descriptions.c: Use common/tdesc.h.
11641 * target-descriptions.h: Likewise.
11642
11643 2018-02-24 Tom Tromey <tom@tromey.com>
11644
11645 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11646 (try_thread_db_load_from_dir, thread_db_load_search): Use
11647 std::string.
11648 (info_auto_load_libthread_db_compare): Return bool. Change
11649 argument types.
11650 (info_auto_load_libthread_db): Use std::vector, std::string.
11651 Remove cleanups.
11652
11653 2018-02-24 Tom Tromey <tom@tromey.com>
11654
11655 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11656 std::string.
11657 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11658 std::string*.
11659 * gdbarch.c: Rebuild.
11660 * gdbarch.h: Rebuild.
11661 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11662 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11663 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11664 std::string*.
11665
11666 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11667
11668 * gdbtypes.h (sect_offset): Change type to uint64_t.
11669 (sect_offset_str): New function.
11670 * dwarf2read.c (create_addrmap_from_aranges): Use
11671 sect_offset_str.
11672 (error_check_comp_unit_head): Likewise.
11673 (create_debug_type_hash_table): Likewise.
11674 (read_cutu_die_from_dwo): Likewise.
11675 (init_cutu_and_read_dies): Likewise.
11676 (init_cutu_and_read_dies_no_follow): Likewise.
11677 (process_psymtab_comp_unit_reader): Likewise.
11678 (partial_die_parent_scope): Likewise.
11679 (peek_die_abbrev): Likewise.
11680 (process_queue): Likewise.
11681 (dwarf2_physname): Likewise.
11682 (read_namespace_alias): Likewise.
11683 (read_import_statement): Likewise.
11684 (create_dwo_cu_reader): Likewise.
11685 (create_cus_hash_table): Likewise.
11686 (lookup_dwo_cutu): Likewise.
11687 (inherit_abstract_dies): Likewise.
11688 (read_func_scope): Likewise.
11689 (read_call_site_scope): Likewise.
11690 (dwarf2_add_member_fn): Likewise.
11691 (read_common_block): Likewise.
11692 (read_module_type): Likewise.
11693 (read_typedef): Likewise.
11694 (read_subrange_type): Likewise.
11695 (load_partial_dies): Likewise.
11696 (read_partial_die): Likewise.
11697 (find_partial_die): Likewise.
11698 (read_str_index): Likewise.
11699 (dwarf2_string_attr): Likewise.
11700 (build_error_marker_type): Likewise.
11701 (lookup_die_type): Likewise.
11702 (dump_die_shallow): Likewise.
11703 (follow_die_ref): Likewise.
11704 (dwarf2_fetch_die_loc_sect_off): Likewise.
11705 (dwarf2_fetch_constant_bytes): Likewise.
11706 (follow_die_sig): Likewise.
11707 (get_signatured_type): Likewise.
11708 (get_DW_AT_signature_type): Likewise.
11709 (dwarf2_find_containing_comp_unit): Likewise.
11710 (set_die_type): Likewise.
11711
11712 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11713
11714 * arch/aarch64.c: Include "common-defs.h".
11715 * arch/amd64.c: Likewise.
11716 * arch/i386.c: Likewise.
11717
11718 2018-02-21 Tom Tromey <tom@tromey.com>
11719
11720 * value.h: (extract_field_op): Update.
11721 * eval.c (extract_field_op): Return a const char *.
11722 * expression.h (parse_expression_for_completion): Update.
11723 * completer.c (complete_expression): Update.
11724 (add_struct_fields): Make fieldname const.
11725 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11726 (mark_completion_tag, parse_exp_in_context_1): Update.
11727 (parse_expression_for_completion): Change "name" to
11728 unique_xmalloc_ptr*.
11729
11730 2018-02-21 Tom Tromey <tom@tromey.com>
11731
11732 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11733
11734 2018-02-21 Yao Qi <yao.qi@linaro.org>
11735
11736 * avr-tdep.c (avr_read_pc): Change parameter type to
11737 readable_regcache.
11738 * gdbarch.sh (read_pc): Likewise.
11739 * gdbarch.c: Re-generated.
11740 * gdbarch.h: Re-generated.
11741 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11742 readable_regcache.
11743 * ia64-tdep.c (ia64_read_pc): Likewise.
11744 * mips-tdep.c (mips_read_pc): Likewise.
11745 * spu-tdep.c (spu_read_pc): Likewise.
11746
11747 2018-02-21 Yao Qi <yao.qi@linaro.org>
11748
11749 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11750 * regcache-dump.c: New file.
11751 * regcache.c: Move register_dump to regcache-dump.c.
11752 (maintenance_print_registers): Likewise.
11753 (maintenance_print_raw_registers): Likewise.
11754 (maintenance_print_cooked_registers): Likewise.
11755 (maintenance_print_register_groups): Likewise.
11756 (maintenance_print_remote_registers): Likewise.
11757 (_initialize_regcache): Likewise.
11758 * regcache.h (register_dump): Moved from regcache.c.
11759
11760 2018-02-21 Yao Qi <yao.qi@linaro.org>
11761
11762 * regcache.c (regcache::regcache): Update.
11763 (regcache::invalidate): Move it to detached_regcache::invalidate.
11764 (get_thread_arch_aspace_regcache): Update.
11765 (regcache::raw_update): Update.
11766 (regcache::cooked_read): Remove some code.
11767 (regcache::cooked_read_value): Likewise.
11768 (regcache::raw_write): Remove assert on m_readonly_p.
11769 (regcache::raw_supply_integer): Move it to
11770 detached_regcache::raw_supply_integer.
11771 (regcache::raw_supply_zeroed): Likewise.
11772 * regcache.h (detached_regcache) <raw_supply_integer>: New
11773 declaration.
11774 <raw_supply_zeroed, invalidate>: Likewise.
11775 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11776 <invalidate>: Likewise.
11777 <m_readonly_p>: Removed.
11778
11779 2018-02-21 Yao Qi <yao.qi@linaro.org>
11780
11781 * infcmd.c (get_return_value): Let stop_regs point to
11782 get_current_regcache.
11783 * regcache.c (regcache::regcache): Remove.
11784 (register_dump_reg_buffer): New class.
11785 (regcache_print): Adjust.
11786 * regcache.h (regcache): Remove constructors.
11787
11788 2018-02-21 Yao Qi <yao.qi@linaro.org>
11789
11790 * regcache.c (class register_dump): New class.
11791 (register_dump_regcache, register_dump_none): New class.
11792 (register_dump_remote, register_dump_groups): New class.
11793 (regcache_print): Update.
11794 * regcache.h (regcache_dump_what): Move it to regcache.c.
11795 (regcache) <dump>: Remove.
11796
11797 2018-02-21 Yao Qi <yao.qi@linaro.org>
11798
11799 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11800 reg_buffer_rw *.
11801 (jit_unwind_reg_set_impl): Call raw_supply.
11802 (jit_frame_sniffer): Use reg_buffer_rw.
11803 * record-full.c (record_full_core_regbuf): Change its type.
11804 (record_full_core_open_1): Use reg_buffer_rw.
11805 (record_full_close): Likewise.
11806 (record_full_core_fetch_registers): Use regcache->raw_supply.
11807 (record_full_core_store_registers): Likewise.
11808 * regcache.c (regcache::get_register_status): Move it to
11809 reg_buffer.
11810 (regcache_raw_set_cached_value): Remove.
11811 (regcache::raw_set_cached_value): Remove.
11812 (regcache::raw_write): Call raw_supply.
11813 (regcache::raw_supply): Move it to reg_buffer_rw.
11814 * regcache.h (regcache_raw_set_cached_value): Remove.
11815 (reg_buffer_rw): New class.
11816
11817 2018-02-21 Yao Qi <yao.qi@linaro.org>
11818
11819 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11820 readonly_detached_regcache.
11821 (dummy_frame_prev_register): Use regcache->cooked_read.
11822 * frame.c (frame_save_as_regcache): Change return type.
11823 (frame_pop): Update.
11824 * frame.h (frame_save_as_regcache): Update declaration.
11825 * inferior.h (get_infcall_suspend_state_regcache): Update
11826 declaration.
11827 * infrun.c (infcall_suspend_state) <registers>: use
11828 readonly_detached_regcache.
11829 (save_infcall_suspend_state): Don't use regcache_dup.
11830 (get_infcall_suspend_state_regcache): Change return type.
11831 * linux-fork.c (struct fork_info) <savedregs>: Change to
11832 readonly_detached_regcache.
11833 <pc>: New field.
11834 (fork_save_infrun_state): Don't use regcache_dup.
11835 (info_checkpoints_command): Adjust.
11836 * mi/mi-main.c (register_changed_p): Update declaration.
11837 (mi_cmd_data_list_changed_registers): Use
11838 readonly_detached_regcache.
11839 (register_changed_p): Change parameter type to
11840 readonly_detached_regcache.
11841 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11842 readonly_detached_regcache.
11843 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11844 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11845 New.
11846 (regcache::save): Move it to reg_buffer.
11847 (regcache::restore): Change parameter type.
11848 (regcache_dup): Remove.
11849 * regcache.h (reg_buffer) <save>: New method.
11850 (readonly_detached_regcache): New class.
11851 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11852 readonly_detached_regcache.
11853 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11854
11855 2018-02-21 Yao Qi <yao.qi@linaro.org>
11856
11857 * frame.c (frame_save_as_regcache): Use regcache method save.
11858 (frame_pop): Use regcache method restore.
11859 * infrun.c (restore_infcall_suspend_state): Likewise.
11860 * linux-fork.c (fork_load_infrun_state): Likewise.
11861 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11862 save.
11863 * regcache.c (regcache_save): Remove.
11864 (regcache::restore): More asserts.
11865 (regcache_cpy): Remove.
11866 * regcache.h (regcache_save): Remove the declaration.
11867 (regcache::restore): Move from private to public.
11868 Remove the friend declaration of regcache_cpy.
11869 (regcache_cpy): Remove declaration.
11870
11871 2018-02-21 Yao Qi <yao.qi@linaro.org>
11872
11873 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11874 parameter type to 'readable_regcache *'.
11875 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11876 * arm-tdep.c (arm_neon_quad_read): Likewise.
11877 (arm_pseudo_read): Likewise.
11878 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11879 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
11880 * frv-tdep.c (frv_pseudo_register_read): Likewise.
11881 * gdbarch.c: Re-generated.
11882 * gdbarch.h: Re-generated.
11883 * gdbarch.sh (pseudo_register_read): Change parameter type to
11884 'readable_regcache *'.
11885 (pseudo_register_read_value): Likewise.
11886 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
11887 (h8300_pseudo_register_read): Likewise.
11888 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
11889 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
11890 (i386_pseudo_register_read_into_value): Likewise.
11891 (i386_pseudo_register_read_value): Likewise.
11892 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
11893 declaration.
11894 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
11895 * m32c-tdep.c (m32c_raw_read): Likewise.
11896 (m32c_read_flg): Likewise.
11897 (m32c_banked_register): Likewise.
11898 (m32c_banked_read): Likewise.
11899 (m32c_sb_read): Likewise.
11900 (m32c_part_read): Likewise.
11901 (m32c_cat_read): Likewise.
11902 (m32c_r3r2r1r0_read): Likewise.
11903 (m32c_pseudo_register_read): Likewise.
11904 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
11905 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
11906 (mep_pseudo_cr64_read): Likewise.
11907 (mep_pseudo_register_read): Likewise.
11908 * mips-tdep.c (mips_pseudo_register_read): Likewise.
11909 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
11910 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
11911 * regcache.c (regcache::raw_read): Move it to readable_regcache.
11912 (regcache::cooked_read): Likewise.
11913 (regcache::cooked_read_value): Likewise.
11914 (regcache_cooked_read_signed):
11915 (regcache::cooked_read): Likewise.
11916 * regcache.h (readable_regcache): New class.
11917 (regcache): Inherit readable_regcache. Move some methods to
11918 readable_regcache.
11919 * rl78-tdep.c (rl78_pseudo_register_read): Change
11920 parameter type to 'readable_regcache *'.
11921 * rs6000-tdep.c (do_regcache_raw_read): Remove.
11922 (e500_pseudo_register_read): Change parameter type to
11923 'readable_regcache *'.
11924 (dfp_pseudo_register_read): Likewise.
11925 (vsx_pseudo_register_read): Likewise.
11926 (efpr_pseudo_register_read): Likewise.
11927 * s390-tdep.c (s390_pseudo_register_read): Likewise.
11928 * sh-tdep.c (sh_pseudo_register_read): Likewise.
11929 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
11930 (sh64_pseudo_register_read): Likewise.
11931 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
11932 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
11933 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
11934 (spu_pseudo_register_read): Likewise.
11935 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
11936 (xtensa_pseudo_register_read): Likewise.
11937
11938 2018-02-21 Yao Qi <yao.qi@linaro.org>
11939
11940 * regcache.c (regcache::regcache): Call reg_buffer ctor.
11941 (regcache::arch): Move it to reg_buffer::arch.
11942 (regcache::register_buffer): Likewise.
11943 (regcache::assert_regnum): Likewise.
11944 (regcache::num_raw_registers): Likewise.
11945 * regcache.h (reg_buffer): New class.
11946 (regcache): Inherit reg_buffer.
11947
11948 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
11949
11950 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
11951 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
11952
11953 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
11954
11955 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
11956
11957 2018-02-19 Alan Hayward <alan.hayward@arm.com>
11958
11959 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
11960 (SFILES): Remove common/*.c files.
11961 (COMMON_OBS): Remove some *.o files built from common/*.c files.
11962 * common/common.host: Add common reference.
11963 * configure.ac: Likewise.
11964 * configure: Regenerate.
11965
11966 2018-02-16 Yao Qi <yao.qi@linaro.org>
11967
11968 * block.c (block_namespace_info): Inherit allocate_on_obstack.
11969 (block_initialize_namespace): Use new.
11970 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
11971 (dwarf2_free_objfile): Use delete.
11972 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
11973 (copy_type_recursive): Use new.
11974 * gdb_obstack.h (allocate_on_obstack): New.
11975
11976 2018-02-15 Yao Qi <yao.qi@linaro.org>
11977
11978 PR gdb/22849
11979 * inferior.c (exit_inferior_1): Reset inf->control.
11980
11981 2018-02-15 Joel Brobecker <brobecker@adacore.com>
11982
11983 * ada-lang.c (ada_to_fixed_value_create): Delete advance
11984 declaration.
11985
11986 2018-02-14 Pedro Alves <palves@redhat.com>
11987
11988 * frame-unwind.c (frame_unwind_try_unwinder): Always call
11989 frame_cleanup_after_sniffer on exception.
11990
11991 2018-02-14 Tom Tromey <tom@tromey.com>
11992
11993 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
11994 const.
11995 (solib_bfd_open): Make pathname const.
11996 * solib.c (solib_bfd_open): Make pathname const.
11997 * solib-spu.c (spu_bfd_fopen): Make name const.
11998 (spu_bfd_open): Make pathname const.
11999 * solib-darwin.c (darwin_bfd_open): Make pathname const.
12000 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
12001
12002 2018-02-14 Tom Tromey <tom@tromey.com>
12003
12004 * symfile.c (symfile_bfd_open): Update.
12005 * source.h (openp, source_full_path_of, find_and_open_source):
12006 Change argument type to unique_xmalloc_ptr.
12007 * source.c (openp): Take a unique_xmalloc_ptr.
12008 (source_full_path_of, find_and_open_source): Likewise.
12009 (open_source_file, symtab_to_fullname): Update.
12010 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
12011 unique_xmalloc_ptr.
12012 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
12013 (exec_file_find): Update.
12014 * psymtab.c (psymtab_to_fullname): Update.
12015 * nto-tdep.h (nto_find_and_open_solib): Update.
12016 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
12017 unique_xmalloc_ptr.
12018 * exec.c (exec_file_attach): Update.
12019 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
12020 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
12021
12022 2018-02-14 Tom Tromey <tom@tromey.com>
12023
12024 * solib.c: Include source.h.
12025 * nto-tdep.c: Include source.h.
12026 * mi/mi-cmd-env.c: Include source.h.
12027 * infcmd.c: Include source.h.
12028 * exec.c: Include source.h.
12029 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
12030 (add_path, directory_switch, source_path, init_source_path): Move
12031 declarations...
12032 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
12033 (add_path, directory_switch, source_path, init_source_path):
12034 ...here.
12035
12036 2018-02-14 Tom Tromey <tom@tromey.com>
12037
12038 * solist.h (exec_file_find, solib_find): Return
12039 unique_xmalloc_ptr.
12040 (solib_bfd_fopen): Take a const char *.
12041 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
12042 (exec_file_find, solib_find): Likewise.
12043 (solib_bfd_fopen): Do not take ownership of "pathname".
12044 (solib_bfd_open): Use unique_xmalloc_ptr.
12045 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
12046 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
12047 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
12048 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
12049
12050 2018-02-14 Joel Brobecker <brobecker@adacore.com>
12051
12052 * ada-lang.c (name_match_type_from_name): Remove reference to
12053 ada_name_for_lookup in function's documentation.
12054 * ada-lang.h (ada_name_for_lookup): Delete declaration.
12055
12056 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12057
12058 * defs.h (enum openp_flags): New enum.
12059 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
12060 Move to enum openp_flags.
12061 (openp_flags): New enum flags.
12062 (openp): Change parameter type to openp_flags.
12063 * source.c (openp): Change parameter type to openp_flags.
12064 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
12065 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
12066
12067 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12068
12069 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
12070 per-command.
12071
12072 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
12073
12074 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
12075 into...
12076 (class dwarf2_queue_guard): ...the destructor of this new class.
12077 (dw2_do_instantiate_symtab): Create instance of the new class
12078 dwarf2_queue_guard, remove cleanup.
12079
12080 2018-02-09 Tom Tromey <tom@tromey.com>
12081
12082 * source.c (find_source_lines): Don't reference past the end of
12083 the vector.
12084
12085 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12086
12087 * remote.c (remote_btrace_maybe_reopen): Change error message.
12088 * btrace.c (btrace_enable): Likewise.
12089 (parse_xml_btrace): Likewise.
12090 (parse_xml_btrace_conf): Likewise.
12091
12092 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12093
12094 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
12095 (linux_enable_pt, linux_enable_bts): Call
12096 diagnose_perf_event_open_fail.
12097
12098 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12099
12100 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12101 Remove parameter and change return type. Update callers. Move it.
12102 (linux_enable_bts, linux_enable_pt): Improve error message.
12103 (linux_enable_pt): Remove zero buffer size check.
12104 (linux_enable_btrace): Improve error messages. Remove NULL return
12105 check.
12106
12107 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12108
12109 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12110 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12111 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12112 (linux_supports_pt, linux_supports_btrace): Remove.
12113 (linux_enable_bts): Call cpu_supports_bts.
12114 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12115 * remote.c (remote_supports_btrace): Remove.
12116 (init_remote_ops): Remove remote_supports_btrace.
12117 * target-delegates.c: Regenerated.
12118 * target.c (target_supports_btrace): Remove.
12119 * target.h (target_ops) <to_supports_btrace>: Remove
12120 (target_supports_btrace): Remove.
12121 * x86-linux-nat.c (x86_linux_create_target): Remove
12122 linux_supports_btrace.
12123
12124 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12125
12126 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12127 btrace failed.
12128 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12129 exception and use message in own exception.
12130
12131 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12132
12133 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
12134 (perf_event_pt_event_type): Use gdb_file_up.
12135 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
12136 scoped_fd, and scoped_mmap.
12137
12138 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12139
12140 * common/scoped_mmap.h: New.
12141 * unittests/scoped_mmap-selftest.c: New.
12142 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12143 unittests/scoped_mmap-selftest.c.
12144
12145 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12146
12147 * common/scoped_fd.h: New.
12148 * unittests/scoped_fd-selftest.c: New.
12149 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12150 unittests/scoped_fd-selftest.c.
12151
12152 2018-02-09 Tom Tromey <tom@tromey.com>
12153
12154 * auto-load.c (auto_load_section_scripts): Use
12155 gdb::unique_xmalloc_ptr.
12156
12157 2018-02-09 Tom Tromey <tom@tromey.com>
12158
12159 * auto-load.c (execute_script_contents): Use std::string.
12160
12161 2018-02-09 Joel Brobecker <brobecker@adacore.com>
12162
12163 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
12164 Python function, rather than a new command.
12165
12166 2018-02-08 Tom Tromey <tom@tromey.com>
12167
12168 * solib.c (solib_find_1): Use std::string.
12169 (solib_bfd_fopen): Use unique_xmalloc_ptr.
12170
12171 2018-02-08 Tom Tromey <tom@tromey.com>
12172
12173 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
12174
12175 2018-02-08 Tom Tromey <tom@tromey.com>
12176
12177 * source.c (find_source_lines): Use gdb::def_vector.
12178
12179 2018-02-08 Tom Tromey <tom@tromey.com>
12180
12181 * macrocmd.c (struct temporary_macro_definition): New.
12182 (macro_define_command): Use temporary_macro_definition. Remove
12183 cleanups.
12184 (free_macro_definition_ptr): Remove.
12185
12186 2018-02-08 Tom Tromey <tom@tromey.com>
12187
12188 * macroexp.c (maybe_expand): Use std::string.
12189
12190 2018-02-08 Tom Tromey <tom@tromey.com>
12191
12192 * macroexp.c (struct macro_buffer): Add initializers for some
12193 members.
12194 (init_buffer, init_shared_buffer, free_buffer)
12195 (free_buffer_return_text): Remove.
12196 (macro_buffer): New constructors.
12197 (~macro_buffer): New destructor.
12198 (macro_buffer::set_shared): New method.
12199 (macro_buffer::resize_buffer, macro_buffer::appendc)
12200 (macro_buffer::appendmem): Now methods, not free functions.
12201 (set_token, append_tokens_without_splicing, stringify)
12202 (macro_stringify): Update.
12203 (gather_arguments): Change return type. Remove argc_p argument,
12204 add args_ptr argument. Use std::vector.
12205 (substitute_args): Remove argc argument. Accept std::vector.
12206 (expand): Update. Use std::vector.
12207 (scan, macro_expand, macro_expand_next): Update.
12208
12209 2018-02-08 Tom Tromey <tom@tromey.com>
12210
12211 * symtab.c (default_collect_symbol_completion_matches_break_on):
12212 Use unique_xmalloc_ptr.
12213 * macroscope.h: (sal_macro_scope, user_macro_scope)
12214 (default_macro_scope): Return unique_xmalloc_ptr.
12215 * macroscope.c (sal_macro_scope, user_macro_scope)
12216 (default_macro_scope): Return unique_xmalloc_ptr.
12217 * macroexp.h (macro_expand, macro_expand_once): Return
12218 unique_xmalloc_ptr.
12219 * macroexp.c (macro_expand, macro_expand_once): Return
12220 unique_xmalloc_ptr.
12221 * macrocmd.c (macro_expand_command, macro_expand_once_command)
12222 (info_macro_command, info_macros_command): Use
12223 unique_xmalloc_ptr.
12224 * compile/compile-c-support.c (write_macro_definitions): Use
12225 unique_xmalloc_ptr.
12226 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
12227
12228 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
12229
12230 * value.c (value_static_field): Assign field type instead of
12231 containing type when returning an optimized out value.
12232
12233 2018-02-06 Yao Qi <yao.qi@linaro.org>
12234
12235 * ft32-tdep.c (ft32_read_pc): Remove.
12236 (ft32_write_pc): Remove.
12237 (ft32_gdbarch_init): Update.
12238 * m32r-tdep.c (m32r_read_pc): Remove.
12239 (m32r_gdbarch_init): Update.
12240 * mep-tdep.c (mep_read_pc): Remove.
12241 (mep_gdbarch_init): Update.
12242 * microblaze-tdep.c (microblaze_write_pc): Remove.
12243 (microblaze_gdbarch_init): Update.
12244 * mn10300-tdep.c (mn10300_read_pc): Remove.
12245 (mn10300_write_pc): Remove.
12246 (mn10300_gdbarch_init): Update.
12247 * moxie-tdep.c (moxie_read_pc): Remove.
12248 (moxie_write_pc): Remove.
12249 (moxie_gdbarch_init): Update.
12250
12251 2018-02-06 Yao Qi <yao.qi@linaro.org>
12252
12253 * expprint.c (print_subexp_standard): Handle
12254 OP_F77_UNDETERMINED_ARGLIST.
12255 (dump_subexp_body_standard): Likewise.
12256
12257 2018-02-05 Alan Hayward <alan.hayward@arm.com>
12258
12259 * target-descriptions.c (tdesc_element_visitor) Add empty
12260 implementations.
12261 (tdesc_type): Move make_gdb_type from here.
12262 (tdesc_type_builtin): Likewise.
12263 (tdesc_type_vector): Likewise.
12264 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
12265 (make_gdb_type_struct): Move from tdesc_type_with_fields.
12266 (make_gdb_type_union): Likewise.
12267 (make_gdb_type_flags): Likewise.
12268 (make_gdb_type_enum): Likewise.
12269 (make_gdb_type): New function.
12270 (tdesc_register_type): Use static make_gdb_type.
12271
12272 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
12273
12274 * infcmd.c (default_print_one_register_info): Align natural-format
12275 column values consistently one under another.
12276 (pad_to_column): New function.
12277
12278 2018-02-05 Joel Brobecker <brobecker@adacore.com>
12279
12280 * dwarf2read.c (dwarf2_physname): Move commment.
12281
12282 2018-02-01 Leszek Swirski <leszeks@google.com>
12283
12284 * varobj.c (varobj_formatted_print_options): Allow recursive
12285 pretty printing if pretty printing is enabled.
12286
12287 2018-02-01 Leszek Swirski <leszeks@google.com>
12288
12289 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12290 names after a structop as a filename.
12291
12292 2018-02-01 Yao Qi <yao.qi@linaro.org>
12293
12294 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12295 (arm_record_coproc_data_proc): Likewise.
12296
12297 2018-02-01 Yao Qi <yao.qi@linaro.org>
12298
12299 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12300
12301 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12302
12303 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12304 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12305
12306 2018-01-31 Pedro Alves <palves@redhat.com>
12307
12308 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12309 * inflow.c (child_terminal_save_inferior): Wrap reference to
12310 tcgetpgrp in HAVE_TERMIOS_H.
12311 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12312 _WIN32.
12313 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12314 always iterate over all inferiors.
12315 (gdbsim_cntrl_c): Adjust.
12316 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12317
12318 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12319
12320 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12321 index type is objfile-owned if the element type is as well.
12322
12323 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12324
12325 GDB 8.1 released.
12326
12327 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12328
12329 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12330 "features/s390x-linux64.c".
12331 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12332 s390_linux32 and s390x_linux64.
12333 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12334 default tdesc.
12335 * s390-tdep.c: Include "features/s390-linux32.c" and
12336 "features/s390x-linux64.c".
12337 (s390_tdesc_valid): Add check for tdesc_has_registers.
12338 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12339 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12340 tdesc_s390x_linux64.
12341 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12342 tdesc_s390x_linux64 to...
12343 * s390-tdep.h: ...here.
12344
12345 2018-01-30 Pedro Alves <palves@redhat.com>
12346
12347 PR gdb/13211
12348 * config.in, configure: Regenerate.
12349 * configure.ac: Check for getpgid.
12350 * go32-nat.c (go32_pass_ctrlc): New.
12351 (go32_target): Install it.
12352 * inf-child.c (inf_child_target): Install
12353 child_terminal_save_inferior, child_pass_ctrlc and
12354 child_interrupt.
12355 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12356 (inf_ptrace_target): No longer install it.
12357 * infcmd.c (interrupt_target_1): Adjust.
12358 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12359 (child_interrupt): Declare.
12360 (inferior::terminal_state): New.
12361 * inflow.c (struct terminal_info): Update comments.
12362 (inferior_process_group): Delete.
12363 (terminal_is_ours): Delete.
12364 (gdb_tty_state): New.
12365 (child_terminal_init): Adjust.
12366 (is_gdb_terminal, sharing_input_terminal_1)
12367 (sharing_input_terminal): New functions.
12368 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12369 Set the process's actual process group in the foreground if
12370 possible. Handle is_ours_for_output/is_ours distinction. Don't
12371 mark terminal as the inferior's if not sharing GDB's terminal.
12372 Don't check attach_flag.
12373 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12374 pass down a target_terminal_state.
12375 (child_terminal_save_inferior): New, factored out from ...
12376 (child_terminal_ours_1): ... this. Handle
12377 target_terminal_state::is_ours_for_output.
12378 (child_interrupt, child_pass_ctrlc): New.
12379 (inflow_inferior_exit): Clear the inferior's terminal_state.
12380 (copy_terminal_info): Copy the inferior's terminal state.
12381 (_initialize_inflow): Remove reference to terminal_is_ours.
12382 * inflow.h (inferior_process_group): Delete.
12383 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12384 * procfs.c (procfs_target): Don't install procfs_interrupt.
12385 (procfs_interrupt): Delete.
12386 * remote.c (remote_serial_quit_handler): Adjust.
12387 (remote_interrupt): Remove ptid parameter. Adjust.
12388 * target-delegates.c: Regenerate.
12389 * target.c: Include "terminal.h".
12390 (target_terminal::terminal_state): Rename to ...
12391 (target_terminal::m_terminal_state): ... this.
12392 (target_terminal::init): Adjust.
12393 (target_terminal::inferior): Adjust to per-inferior
12394 terminal_state.
12395 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12396 (target_terminal::ours, target_terminal::ours_for_output): Use
12397 target_terminal_is_ours_kind.
12398 (target_interrupt): Remove ptid parameter. Adjust.
12399 (default_target_pass_ctrlc): Adjust.
12400 * target.h (target_ops::to_terminal_save_inferior): New field.
12401 (target_ops::to_interrupt): Remove ptid_t parameter.
12402 (target_interrupt): Remove ptid_t parameter. Update comment.
12403 (target_pass_ctrlc): Update comment.
12404 * target/target.h (target_terminal_state): New scoped enum,
12405 factored out of ...
12406 (target_terminal::terminal_state): ... here.
12407 (target_terminal::inferior): Update comments.
12408 (target_terminal::restore_inferior): New.
12409 (target_terminal::is_inferior, target_terminal::is_ours)
12410 (target_terminal::is_ours_for_output): Adjust.
12411 (target_terminal::scoped_restore_terminal_state): Adjust to
12412 rename, and call restore_inferior() instead of inferior().
12413 (target_terminal::scoped_restore_terminal_state::m_state): Change
12414 type.
12415 (target_terminal::terminal_state): Rename to ...
12416 (target_terminal::m_terminal_state): ... this and change type.
12417
12418 2018-01-30 Pedro Alves <palves@redhat.com>
12419
12420 * linux-nat.c (wait_for_signal): New function.
12421 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12422 directly.
12423 (async_terminal_is_ours)
12424 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12425 (linux_nat_add_target): Don't override
12426 to_terminal_inferior/to_terminal_ours.
12427
12428 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12429
12430 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12431
12432 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12433
12434 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12435 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12436 dwarf2_per_objfile_free here.
12437 (dwarf2_per_objfile_free): Remove.
12438 (_initialize_dwarf2_read): Don't register
12439 dwarf2_per_objfile_free as a registry cleanup.
12440
12441 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12442
12443 Avoid compilation errors in MinGW native builds
12444
12445 The error is triggered by including python-internal.h, and the
12446 error message is:
12447
12448 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12449 from build-gnulib/import/math.h:27,
12450 from d:/usr/Python26/include/pyport.h:235,
12451 from d:/usr/Python26/include/Python.h:58,
12452 from python/python-internal.h:94,
12453 from python/py-arch.c:24:
12454 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12455 using ::hypot;
12456 ^~~~~
12457
12458 This happens because Python headers define 'hypot' to expand t
12459 '_hypot' in the Windows builds.
12460 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12461 'hypoth'. This avoids a compilation error.
12462
12463 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12464
12465 * MAINTAINERS (Write After Approval): Fix ordering.
12466
12467 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12468
12469 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12470
12471 2018-01-26 Alan Modra <amodra@gmail.com>
12472
12473 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12474 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12475 Remove nop. Make const. Comment.
12476 (powerpc32_plt_stub_so_2): New.
12477 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12478 Correct count. Update uses.
12479 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12480 Move common code reading PLT entry word. Correct
12481 powerpc32_plt_stub PLT address calculation.
12482 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12483 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12484 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12485 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12486 (ppc64_standard_linkage8): Likewise.
12487 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12488 Correct insns description.
12489 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12490
12491 2018-01-24 Pedro Alves <palves@redhat.com>
12492
12493 GCC PR libstdc++/83906
12494 * gdbtypes.c (operator==(const dynamic_prop &,
12495 const dynamic_prop &)): New.
12496 (operator==(const range_bounds &, const range_bounds &)): New.
12497 (check_types_equal): Use them instead of memcmp.
12498 * gdbtypes.h (operator==(const dynamic_prop &,
12499 const dynamic_prop &)): Declare.
12500 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12501 (operator==(const range_bounds &, const range_bounds &)): Declare.
12502 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12503
12504 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12505
12506 * s390-linux-tdep.c (s390_record_address_mask)
12507 (s390_record_calc_disp_common, s390_record_calc_disp)
12508 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12509 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12510 (s390_process_record): Move to s390-tdep.c.
12511 (s390_linux_init_abi_any): Adjust.
12512 * s390-tdep.c (s390_record_address_mask)
12513 (s390_record_calc_disp_common, s390_record_calc_disp)
12514 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12515 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12516 (s390_process_record): Moved from s390-linux-tdep.c
12517 (s390_gdbarch_init): Adjust.
12518
12519 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12520
12521 * s390-linux-nat.c (s390-tdep.h): New include.
12522 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12523 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12524 (ALLDEPFILES): Add s390-tdep.c.
12525 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12526 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12527 * s390-tdep.h: ...this. New file.
12528 * s390-linux-tdep.c (s390-tdep.h): New include.
12529 (_initialize_s390_tdep): Rename to...
12530 (_initialize_s390_linux_tdep): ...this and adjust.
12531 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12532 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12533 s390-tdep.h.
12534 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12535 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12536 (s390_is_partial_instruction, s390_software_single_step)
12537 (is_non_branch_ril, s390_displaced_step_copy_insn)
12538 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12539 (s390_prologue_data, s390_addr, s390_store, s390_load)
12540 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12541 (s390_register_call_saved, s390_guess_tracepoint_registers)
12542 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12543 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12544 (s390_pseudo_register_name, s390_pseudo_register_type)
12545 (s390_pseudo_register_read, s390_pseudo_register_write)
12546 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12547 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12548 (s390_addr_bits_remove, s390_address_class_type_flags)
12549 (s390_address_class_type_flags_to_name)
12550 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12551 (s390_function_arg_float, s390_function_arg_vector)
12552 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12553 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12554 (s390_frame_align, s390_register_return_value, s390_return_value)
12555 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12556 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12557 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12558 (s390_trad_frame_prev_register, s390_unwind_cache)
12559 (s390_prologue_frame_unwind_cache)
12560 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12561 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12562 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12563 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12564 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12565 (s390_frame_base_address, s390_local_base_address)
12566 (s390_frame_base, s390_gcc_target_options)
12567 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12568 (s390_validate_reg_range, s390_tdesc_valid)
12569 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12570 * s390-tdep.c: ...this. New file.
12571
12572 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12573
12574 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12575 (s390_process_record, s390_gdbarch_tdep_alloc)
12576 (s390_linux_init_abi_any): Use/set new hook.
12577
12578 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12579
12580 * s390-linux-tdep.c (osabi.h): New include.
12581 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12582 (s390_linux_init_abi_any): New functions.
12583 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12584
12585 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12586
12587 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12588 tdesc_has_registers check
12589
12590 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12591
12592 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12593 (s390_validate_reg_range): New macro.
12594 (s390_gdbarch_init): Adjust.
12595
12596 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12597
12598 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12599 (s390_gdbarch_tdep_alloc): Adjust.
12600 (s390_gdbarch_init): Adjust.
12601
12602 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12603
12604 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12605 <have_tdb>: Change type to bool.
12606 (s390_gdbarch_tdep_alloc): Adjust.
12607 (s390_gdbarch_init): Adjust.
12608
12609 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12610
12611 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12612 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12613 (s390_gdbarch_tdep_alloc): New function.
12614 (s390_gdbarch_init): Allocate tdep at start and use its fields
12615 instead of separate variables.
12616
12617 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12618
12619 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12620 when looking for cached gdbarch and add comment for remaining.
12621
12622 2018-01-22 Pedro Alves <palves@redhat.com>
12623 Sergio Durigan Junior <sergiodj@redhat.com>
12624
12625 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12626 case.
12627
12628 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12629
12630 * MAINTAINERS: Update my company e-mail address.
12631
12632 2018-01-22 Yao Qi <yao.qi@linaro.org>
12633
12634 * regcache.c (cooked_write_test): New function.
12635 (_initialize_regcache): Register the test.
12636
12637 2018-01-22 Yao Qi <yao.qi@linaro.org>
12638
12639 * ia64-tdep.c (ia64_pseudo_register_read): Call
12640 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12641 * m32c-tdep.c (m32c_cat_read): Likewise.
12642 (m32c_r3r2r1r0_read): Likewise.
12643 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12644 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12645
12646 2018-01-22 Yao Qi <yao.qi@linaro.org>
12647
12648 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12649 method raw_read instead of regcache_raw_read.
12650 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12651 * arm-tdep.c (arm_neon_quad_read): Likewise.
12652 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12653 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12654 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12655 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12656 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12657 (i386_pseudo_register_read_into_value): Likewise.
12658 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12659 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12660 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12661 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12662 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12663 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12664 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12665 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12666 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12667
12668 2018-01-22 Yao Qi <yao.qi@linaro.org>
12669
12670 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12671 * configure.tgt: Remove target mt.
12672 * mt-tdep.c: Remove.
12673 * regcache.c (cooked_read_test): Remove the check for mt.
12674
12675 2018-01-22 Yao Qi <yao.qi@linaro.org>
12676
12677 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12678 instead of gdbarch_pseudo_register_read_value.
12679
12680 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12681
12682 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12683 language is Ada.
12684
12685 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12686
12687 * linespec.c (create_sals_line_offset): Remove code that preserved
12688 the symtab_and_line's line number.
12689
12690 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12691
12692 * varobj.c (varobj_create): Don't set valid_block when creating a
12693 floating varobj.
12694
12695 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12696
12697 * varobj.c (varobj_create): Remove out of date comment.
12698
12699 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12700
12701 PR mi/20395
12702 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12703 updating innermost block.
12704 * parse.c (innermost_block_tracker::update): Take extra type
12705 parameter, and check types match before updating innermost block.
12706 (write_dollar_variable): Update innermost block for registers.
12707 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12708 (innermost_block_tracker::innermost_block_tracker): Initialise
12709 m_types member.
12710 (innermost_block_tracker::reset): Take type parameter.
12711 (innermost_block_tracker::update): Take type parameter, and pass
12712 type through as needed.
12713 (innermost_block_tracker::m_types): New member.
12714 * varobj.c (varobj_create): Pass type when reseting innermost
12715 block.
12716
12717 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12718
12719 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12720 * ada-lang.c (resolve_subexp): Likewise.
12721 * breakpoint.c (set_breakpoint_condition) Likewise.
12722 (watch_command_1) Likewise.
12723 * c-exp.y (variable): Likewise.
12724 * d-exp.y (PrimaryExpression): Likewise.
12725 * f-exp.y (variable): Likewise.
12726 * go-exp.y (variable): Likewise.
12727 * m2-exp.y (variable): Likewise.
12728 * objfiles.c (objfile::~objfile): Likewise.
12729 * p-exp.y (variable): Likewise.
12730 * parse.c (innermost_block): Change type.
12731 * parser-defs.h (class innermost_block_tracker): New.
12732 (innermost_block): Change to innermost_block_tracker.
12733 * printcmd.c (display_command): Switch to innermost_block API.
12734 (do_one_display): Likewise.
12735 * rust-exp.y (do_one_display): Likewise.
12736 * symfile.c (clear_symtab_users): Likewise.
12737 * varobj.c (varobj_create): Switch to innermost_block API, replace
12738 use of innermost_block with block stored on varobj object.
12739
12740 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12741
12742 * expression.h (innermost_block): Remove declaration.
12743 * varobj.c: Add 'parser-defs.h' include.
12744
12745 2018-01-19 Tom Tromey <tom@tromey.com>
12746
12747 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12748 symbols in the static and global blocks.
12749
12750 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12751
12752 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12753 gdb_ptrace.h, and move including gdb_wait.h ...
12754 * nat/linux-ptrace.h: ... to here.
12755
12756 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12757
12758 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12759 inf_ptrace_detach_success.
12760 (inf_ptrace_detach_success): Add inferior parameter, use it
12761 instead of inferior_ptid, pass it to detach_inferior.
12762 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12763 parameter.
12764 * inferior.c (detach_inferior): Add overload that takes an
12765 inferior object.
12766 * inferior.h (detach_inferior): Likewise.
12767 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12768 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12769 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12770
12771 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12772
12773 * target.h (struct target_ops) <to_detach>: Add inferior
12774 parameter.
12775 (target_detach): Likewise.
12776 * target.c (dispose_inferior): Pass inferior down.
12777 (target_detach): Pass inferior down. Assert that it is equal to
12778 the current inferior.
12779 * aix-thread.c (aix_thread_detach): Pass inferior down.
12780 * corefile.c (core_file_command): Pass current_inferior() down.
12781 * corelow.c (core_detach): Add inferior parameter.
12782 * darwin-nat.c (darwin_detach): Likewise.
12783 * gnu-nat.c (gnu_detach): Likewise.
12784 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12785 * infcmd.c (detach_command): Pass current_inferior() down to
12786 target_detach.
12787 * infrun.c (follow_fork_inferior): Pass parent_inf to
12788 target_detach.
12789 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12790 target_detach.
12791 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12792 * linux-thread-db.c (thread_db_detach): Likewise.
12793 * nto-procfs.c (procfs_detach): Likewise.
12794 * procfs.c (procfs_detach): Likewise.
12795 * record.c (record_detach): Likewise.
12796 * record.h (struct inferior): Forward-declare.
12797 (record_detach): Add inferior parameter.
12798 * remote-sim.c (gdbsim_detach): Likewise.
12799 * remote.c (remote_detach_1): Likewise.
12800 (remote_detach): Likewise.
12801 (extended_remote_detach): Likewise.
12802 * sol-thread.c (sol_thread_detach): Likewise.
12803 * target-debug.h (target_debug_print_inferior_p): New macro.
12804 * target-delegates.c: Re-generate.
12805 * top.c (kill_or_detach): Pass inferior down to target_detach.
12806 * windows-nat.c (windows_detach): Add inferior parameter.
12807
12808 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12809
12810 * target.h (struct target_ops) <to_detach>: Remove args
12811 parameter.
12812 (target_detach): Likewise.
12813 * target.c (dispose_inferior): Adjust.
12814 (target_detach): Remove args parameter, adjust.
12815 * aix-thread.c (aix_thread_detach): Adjust.
12816 * corefile.c (core_file_command): Adjust.
12817 * corelow.c (core_detach): Adjust.
12818 * darwin-nat.c (darwin_detach): Adjust.
12819 * gnu-nat.c (gnu_detach): Adjust.
12820 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12821 * infcmd.c (detach_command): Adjust
12822 * infrun.c (follow_fork_inferior): Adjust.
12823 (handle_vfork_child_exec_or_exit): Adjust.
12824 * linux-fork.c (linux_fork_detach): Remove args parameter.
12825 * linux-fork.h (linux_fork_detach): Likewise.
12826 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12827 * linux-thread-db.c (thread_db_detach): Likewise.
12828 * nto-procfs.c (procfs_detach): Likewise.
12829 * procfs.c (procfs_detach): Likewise.
12830 (do_detach): Remove signo parameter.
12831 * record.c (record_detach): Remove args parameter.
12832 * record.h (record_detach): Likewise.
12833 * remote-sim.c (gdbsim_detach): Likewise.
12834 * remote.c (remote_detach_1): Likewise.
12835 (remote_detach): Likewise.
12836 (extended_remote_detach): Likewise.
12837 * sol-thread.c (sol_thread_detach): Likewise.
12838 * target-delegates.c: Re-generate.
12839 * top.c (struct qt_args) <args>: Remove field.
12840 (kill_or_detach): Don't pass args.
12841 (quit_force): Don't set args.
12842 * windows-nat.c (windows_detach): Remove args parameter.
12843
12844 2018-01-19 Yao Qi <yao.qi@linaro.org>
12845
12846 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12847 (arm_linux_init_abi): Install it.
12848
12849 2018-01-19 Yao Qi <yao.qi@linaro.org>
12850
12851 * osabi.c (gdb_osabi_names): Extend the regexp for
12852 arm-linux-gnueabihf.
12853
12854 2018-01-18 Yao Qi <yao.qi@linaro.org>
12855
12856 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12857 m_abbrevs.
12858 (abbrev_table::add_abbrev): Update.
12859 (abbrev_table::lookup_abbrev): Update.
12860
12861 2018-01-18 Yao Qi <yao.qi@linaro.org>
12862
12863 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12864
12865 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12866
12867 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12868 to "std::string".
12869
12870 2018-01-17 Tom Tromey <tom@tromey.com>
12871
12872 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12873
12874 2018-01-17 Tom Tromey <tom@tromey.com>
12875
12876 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12877 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12878 (create_array_type_with_stride): Update.
12879 * dwarf2read.c (set_die_type): Update.
12880
12881 2018-01-17 Tom Tromey <tom@tromey.com>
12882
12883 * dwarf2read.c (delayed_method_info): Remove typedef.
12884 (dwarf2_cu::method_info): Now a std::vector.
12885 (add_to_method_list): Update.
12886 (free_delayed_list): Remove.
12887 (compute_delayed_physnames): Update.
12888 (process_full_comp_unit, process_full_type_unit): Clear the method
12889 list. Remove cleanups.
12890 (psymtab_include_file_name): Add name_holder parameter. Use
12891 unique_xmalloc_ptr.
12892 (dwarf_decode_lines): Update.
12893
12894 2018-01-17 Tom Tromey <tom@tromey.com>
12895 Simon Marchi <simon.marchi@ericsson.com>
12896
12897 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
12898 (dwarf2_per_objfile::free_cached_comp_units)
12899 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12900 (init_cutu_and_read_dies_no_follow): Update.
12901 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
12902 (dwarf2_cu::~dwarf2_cu): New.
12903 (free_heap_comp_unit, free_stack_comp_unit): Remove.
12904 (age_cached_comp_units, free_one_cached_comp_unit): Update.
12905
12906 2018-01-17 Tom Tromey <tom@tromey.com>
12907 Simon Marchi <simon.marchi@ericsson.com>
12908
12909 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
12910 (struct die_reader_specs) <abbrev_table>: New member.
12911 (struct abbrev_table): Add constructor.
12912 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
12913 <abbrev_obstack>: Now an auto_obstack.
12914 (abbrev_table_up): New typedef.
12915 (init_cu_die_reader): Add abbrev_table parameter.
12916 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
12917 Add result_dwo_abbrev_table.
12918 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
12919 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
12920 Update.
12921 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
12922 parameter.
12923 (skip_children): Update.
12924 (abbrev_table::alloc_abbrev): Rename from
12925 abbrev_table_alloc_abbrev.
12926 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
12927 (abbrev_table::lookup_abbrev): Rename from
12928 abbrev_table_lookup_abbrev.
12929 (abbrev_table_read_table): Return abbrev_table_up.
12930 (abbrev_table_free, abbrev_table_free_cleanup)
12931 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
12932 (load_partial_dies): Update.
12933
12934 2018-01-17 Tom Tromey <tom@tromey.com>
12935
12936 * dwarf2read.c (dwarf2_compute_name): Update comment.
12937 (read_func_scope, read_variable): Update.
12938 (new_symbol): Remove.
12939 (new_symbol_full): Rename to new_symbol.
12940
12941 2018-01-17 Mike Gulick <mgulick@mathworks.com>
12942
12943 PR gdb/16577
12944 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
12945 a warning instead of throwing an error, set section size to 0 and return
12946 NULL.
12947 * gdb_bfd.h (gdb_bfd_map_section): Update description.
12948
12949 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12950
12951 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
12952 std::string.
12953 (linux_ptrace_attach_fail_reason_string): Likewise.
12954 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
12955 Likewise.
12956 (linux_ptrace_attach_fail_reason_string): Likewise.
12957 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
12958
12959 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
12960
12961 * linux-nat.c (linux_nat_attach): Remove xstrdup.
12962
12963 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
12964
12965 PR gdb/21559
12966 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
12967 checking for fs_base/gs_base fields in struct user_regs_struct.
12968 * configure: Regenerate.
12969
12970 2018-01-17 Yao Qi <yao.qi@linaro.org>
12971
12972 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
12973 function.
12974 (aarch64_linux_init_abi): Install it to gdbarch hook
12975 gcc_target_options.
12976
12977 2018-01-15 Pedro Alves <palves@redhat.com>
12978
12979 * common/signals-state-save-restore.c
12980 (save_original_signals_state): Fix typos.
12981
12982 2017-01-12 Tom Tromey <tom@tromey.com>
12983 Sergio Durigan Junior <sergiodj@redhat.com>
12984
12985 * Makefile.in (install-only): Install gdb-add-index.
12986
12987 2018-01-12 John Baldwin <jhb@FreeBSD.org>
12988
12989 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
12990
12991 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
12992
12993 * infrun.c (keep_going_pass_signal): Clear step-over info when
12994 insert_breakpoints fails.
12995
12996 2018-01-11 Pedro Alves <palves@redhat.com>
12997
12998 PR gdb/22583
12999 * infrun.c (resume): Rename to ...
13000 (resume_1): ... this.
13001 (resume): Reimplement as wrapper around resume_1.
13002
13003 2018-01-11 Pedro Alves <palves@redhat.com>
13004
13005 PR remote/22597
13006 * remote.c (remote_parse_stop_reply): Default to the last-set
13007 general thread instead of to 'magic_null_ptid'.
13008
13009 2018-01-10 Pedro Alves <palves@redhat.com>
13010
13011 * language.h (language_get_symbol_name_matcher): Rename ...
13012 (get_symbol_name_matcher): ... this.
13013 * language.c (language_get_symbol_name_matcher): Ditto.
13014 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
13015 callers adjusted.
13016
13017 2018-01-10 Pedro Alves <palves@redhat.com>
13018
13019 PR gdb/22670
13020 * dwarf2read.c
13021 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
13022 Adjust to use language_get_symbol_name_matcher instead of
13023 language_defn::la_get_symbol_name_matcher.
13024 * language.c (language_get_symbol_name_matcher): If in Ada mode
13025 and the lookup name is a verbatim match, return Ada's matcher.
13026 * language.h (language_get_symbol_name_matcher): Adjust comment.
13027 (ada_lookup_name_info::verbatim_p):: New method.
13028
13029 2018-01-10 Pedro Alves <palves@redhat.com>
13030
13031 PR gdb/22670
13032 * ada-lang.c (ada_collect_symbol_completion_matches): If the
13033 minsym's language is language_auto or language_cplus, pass down
13034 language_ada instead.
13035 * symtab.c (compare_symbol_name): Don't frob symbol language here.
13036
13037 2018-01-10 Pedro Alves <palves@redhat.com>
13038
13039 PR gdb/22670
13040 * minsyms.c (linkage_name_str): New function.
13041 (iterate_over_minimal_symbols): Use it.
13042
13043 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13044
13045 * NEWS: Document that 'info proc' now works on FreeBSD.
13046
13047 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13048
13049 * configure.ac: Check for kinfo_getfile in libutil.
13050 * configure: Regenerate.
13051 * config.in: Regenerate.
13052 * fbsd-nat.c: Include "fbsd-tdep.h".
13053 (fbsd_fetch_cmdline): New.
13054 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
13055 rather than calling error.
13056 (fbsd_info_proc): New.
13057 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
13058 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
13059 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
13060
13061 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13062
13063 * fbsd-nat.c (struct free_deleter): Remove.
13064 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
13065
13066 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13067
13068 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
13069 NULL for an empty pathname.
13070
13071 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13072
13073 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
13074 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
13075 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
13076 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
13077 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
13078 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
13079 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
13080 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
13081 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
13082 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
13083 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
13084 (fbsd_core_fetch_timeval, fbsd_print_sigset)
13085 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
13086 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
13087 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
13088
13089 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
13090
13091 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
13092 (gnu_xfer_auxv): New function.
13093 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
13094 TARGET_OBJECT_AUXV.
13095
13096 2018-01-08 Yao Qi <yao.qi@linaro.org>
13097 Simon Marchi <simon.marchi@ericsson.com>
13098
13099 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13100 common/selftest.c.
13101 (COMMON_OBS): Remove selftest.o.
13102 * configure.ac: Append selftest-arch.c and common/selftest.c to
13103 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13104 * configure: Re-generated.
13105 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13106 GDB_SELF_TEST.
13107 (maintenance_info_selftests): Likewise.
13108
13109 2018-01-08 Xavier Roirand <roirand@adacore.com>
13110
13111 * ada-valprint.c (val_print_packed_array_elements): Use
13112 proper number of elements when printing an array indexed
13113 by an enumeration type.
13114
13115 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13116
13117 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13118 (dw2_get_file_names_reader): Adjust.
13119 (lookup_dwo_signatured_type): Adjust.
13120 (lookup_dwp_signatured_type): Adjust.
13121 (lookup_signatured_type): Adjust.
13122 (create_type_unit_group): Adjust.
13123 (get_type_unit_group): Adjust.
13124 (process_psymtab_comp_unit_reader): Adjust.
13125 (build_type_psymtabs_reader): Adjust.
13126 (scan_partial_symbols): Adjust.
13127 (add_partial_symbol): Adjust.
13128 (add_partial_subprogram): Adjust.
13129 (peek_die_abbrev): Adjust.
13130 (fixup_go_packaging): Adjust.
13131 (process_imported_unit_die): Adjust.
13132 (dwarf2_compute_name): Adjust.
13133 (dwarf2_physname): Adjust.
13134 (read_import_statement): Adjust.
13135 (handle_DW_AT_stmt_list): Adjust.
13136 (read_file_scope): Adjust.
13137 (read_func_scope): Adjust.
13138 (read_lexical_block_scope): Adjust.
13139 (read_call_site_scope): Adjust.
13140 (read_variable): Adjust.
13141 (dwarf2_rnglists_process): Adjust.
13142 (dwarf2_ranges_process): Adjust.
13143 (dwarf2_ranges_read): Adjust.
13144 (dwarf2_get_pc_bounds): Adjust.
13145 (dwarf2_record_block_ranges): Adjust.
13146 (dwarf2_add_field): Adjust.
13147 (dwarf2_add_member_fn): Adjust.
13148 (read_structure_type): Adjust.
13149 (process_structure_scope): Adjust.
13150 (read_enumeration_type): Adjust.
13151 (read_array_type): Adjust.
13152 (mark_common_block_symbol_computed): Adjust.
13153 (read_common_block): Adjust.
13154 (read_namespace_type): Adjust.
13155 (read_namespace): Adjust.
13156 (read_module_type): Adjust.
13157 (read_tag_pointer_type): Adjust.
13158 (read_tag_ptr_to_member_type): Adjust.
13159 (read_tag_string_type): Adjust.
13160 (read_subroutine_type): Adjust.
13161 (read_typedef): Adjust.
13162 (read_base_type): Adjust.
13163 (attr_to_dynamic_prop): Adjust.
13164 (read_subrange_type): Adjust.
13165 (read_unspecified_type): Adjust.
13166 (dwarf2_read_abbrevs): Adjust.
13167 (load_partial_dies): Adjust.
13168 (read_partial_die): Adjust.
13169 (find_partial_die): Adjust.
13170 (guess_partial_die_structure_name): Adjust.
13171 (fixup_partial_die): Adjust.
13172 (read_attribute_value): Adjust.
13173 (read_addr_index): Adjust.
13174 (read_addr_index_from_leb128): Adjust.
13175 (read_str_index): Adjust.
13176 (dwarf2_string_attr): Adjust.
13177 (get_debug_line_section): Adjust.
13178 (dwarf_decode_line_header): Adjust.
13179 (lnp_state_machine::check_line_address): Adjust.
13180 (dwarf_decode_lines_1): Adjust.
13181 (dwarf_decode_lines): Adjust.
13182 (dwarf2_start_symtab): Adjust.
13183 (var_decode_location): Adjust.
13184 (new_symbol_full): Adjust.
13185 (dwarf2_const_value_data): Adjust.
13186 (dwarf2_const_value_attr): Adjust.
13187 (dwarf2_const_value): Adjust.
13188 (die_type): Adjust.
13189 (die_containing_type): Adjust.
13190 (build_error_marker_type): Adjust.
13191 (lookup_die_type): Adjust.
13192 (guess_full_die_structure_name): Adjust.
13193 (anonymous_struct_prefix): Adjust.
13194 (determine_prefix): Adjust.
13195 (dwarf2_name): Adjust.
13196 (follow_die_ref_or_sig): Adjust.
13197 (follow_die_offset): Adjust.
13198 (follow_die_ref): Adjust.
13199 (follow_die_sig_1): Adjust.
13200 (follow_die_sig): Adjust.
13201 (get_signatured_type): Adjust.
13202 (get_DW_AT_signature_type): Adjust.
13203 (decode_locdesc): Adjust.
13204 (dwarf_decode_macros): Adjust.
13205 (cu_debug_loc_section): Adjust.
13206 (fill_in_loclist_baton): Adjust.
13207 (dwarf2_symbol_mark_computed): Adjust.
13208 (init_one_comp_unit): Don't assign
13209 dwarf2_cu::dwarf2_per_objfile.
13210 (set_die_type): Adjust.
13211
13212 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13213
13214 * dwarf2read.c (struct mapped_debug_names): Add constructor.
13215 <dwarf2_per_objfile>: New field.
13216 (dwarf2_per_objfile): Remove global.
13217 (get_dwarf2_per_objfile): New function.
13218 (set_dwarf2_per_objfile): New function.
13219 (dwarf2_build_psymtabs_hard): Change objfile parameter to
13220 dwarf2_per_objfile.
13221 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13222 (read_abbrev_offset): Likewise.
13223 (read_indirect_string): Likewise.
13224 (read_indirect_line_string): Likewise.
13225 (read_indirect_string_at_offset): Likewise.
13226 (read_indirect_string_from_dwz): Likewise.
13227 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13228 dwarf2_per_objfile.
13229 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13230 (create_all_comp_units): Change objfile parameter to
13231 dwarf2_per_objfile.
13232 (create_all_type_units): Likewise.
13233 (process_queue): Add dwarf2_per_objfile parameter.
13234 (read_and_check_comp_unit_head): Likewise.
13235 (lookup_dwo_unit_in_dwp): Likewise.
13236 (get_dwp_file): Likewise.
13237 (process_cu_includes): Likewise.
13238 (struct free_dwo_file_cleanup_data): New struct.
13239 (dwarf2_has_info): Use get_dwarf2_per_objfile and
13240 set_dwarf2_per_objfile.
13241 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
13242 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
13243 context, adjust calls.
13244 (dw2_instantiate_symtab): Likewise.
13245 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
13246 (dw2_get_cu): Likewise.
13247 (create_cu_from_index_list): Change objfile parameter to
13248 dwarf2_per_objfile.
13249 (create_cus_from_index_list): Get dwarf2_per_objfile from
13250 context, adjust calls.
13251 (create_cus_from_index): Likewise.
13252 (create_signatured_type_table_from_index): Change objfile
13253 parameter to dwarf2_per_objfile.
13254 (create_signatured_type_table_from_debug_names): Change objfile
13255 parameter to dwarf2_per_objfile.
13256 (create_addrmap_from_index): Likewise.
13257 (create_addrmap_from_aranges): Likewise.
13258 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
13259 (dw2_setup): Remove.
13260 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
13261 context.
13262 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
13263 get_dwarf2_per_objfile.
13264 (dw2_forget_cached_source_info): Likewise.
13265 (dw2_map_symtabs_matching_filename): Likewise.
13266 (struct dw2_symtab_iterator) <index>: Remove.
13267 <dwarf2_per_objfile>: New field.
13268 (dw2_symtab_iter_init): Replace index parameter with
13269 dwarf2_per_objfile.
13270 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
13271 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
13272 (dw2_print_stats): Likewise.
13273 (dw2_dump): Likewise.
13274 (dw2_expand_symtabs_for_function): Likewise.
13275 (dw2_expand_all_symtabs): Likewise.
13276 (dw2_expand_symtabs_with_fullname): Likewise.
13277 (dw2_expand_marked_cus): Replace index and objfile parameters
13278 with dwarf2_per_objfile.
13279 (dw_expand_symtabs_matching_file_matcher): Add
13280 dwarf2_per_objfile parameter and adjust calls.
13281 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13282 adjust calls.
13283 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13284 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13285 adjust calls.
13286 (create_cus_from_debug_names_list): Replace objfile parameter
13287 with dwarf2_per_objfile and adjust calls.
13288 (create_cus_from_debug_names): Likewise.
13289 (dwarf2_read_debug_names): Likewise.
13290 (mapped_debug_names::namei_to_name): Adjust call.
13291 (dw2_debug_names_iterator::next): Likewise.
13292 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13293 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13294 (dw2_debug_names_dump): Likewise.
13295 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13296 (dw2_debug_names_expand_symtabs_matching): Likewise.
13297 (dwarf2_initialize_objfile): Likewise.
13298 (dwarf2_build_psymtabs): Likewise.
13299 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13300 this_cu.
13301 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13302 (read_and_check_comp_unit_head): Likewise.
13303 (read_abbrev_offset): Likewise.
13304 (create_debug_type_hash_table): Likewise.
13305 (create_debug_types_hash_table): Likewise.
13306 (create_all_type_units): Replace objfile parameter with
13307 dwarf2_per_objfile.
13308 (add_type_unit): Add dwarf2_per_objfile parameter.
13309 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13310 with dwarf2_per_objfile.
13311 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13312 (lookup_dwp_signatured_type): Likewise.
13313 (lookup_signatured_type): Likewise.
13314 (read_cutu_die_from_dwo): Likewise.
13315 (init_tu_and_read_dwo_dies): Likewise.
13316 (init_cutu_and_read_dies): Likewise.
13317 (init_cutu_and_read_dies_no_follow): Likewise.
13318 (allocate_type_unit_groups_table): Add objfile parameter.
13319 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13320 (get_type_unit_group): Likewise.
13321 (process_psymtab_comp_unit): Update call.
13322 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13323 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13324 (print_tu_stats): Likewise.
13325 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13326 in void* parameter.
13327 (build_type_psymtabs): Change objfile parameter to
13328 dwarf2_per_objfile.
13329 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13330 passed in void* parameter.
13331 (process_skeletonless_type_units): Change objfile parameter to
13332 dwarf2_per_objfile.
13333 (set_partial_user): Likewise.
13334 (dwarf2_build_psymtabs_hard): Likewise.
13335 (read_comp_units_from_section): Likewise.
13336 (create_all_comp_units): Likewise.
13337 (scan_partial_symbols): Update calls.
13338 (add_partial_symbol): Likewise.
13339 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13340 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13341 (process_queue): Add dwarf2_per_objfile parameter.
13342 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13343 (compute_compunit_symtab_includes): Likewise.
13344 (process_cu_includes): Add dwarf2_per_objfile parameter.
13345 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13346 (process_full_type_unit): Likewise.
13347 (process_imported_unit_die): Update call.
13348 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13349 (read_file_scope): Likewise.
13350 (allocate_dwo_file_hash_table): Add objfile parameter.
13351 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13352 (create_cus_hash_table): Likewise.
13353 (create_dwp_hash_table): Likewise.
13354 (create_dwo_unit_in_dwp_v1): Likewise.
13355 (create_dwp_v2_section): Likewise.
13356 (create_dwo_unit_in_dwp_v2): Likewise.
13357 (lookup_dwo_unit_in_dwp): Likewise.
13358 (try_open_dwop_file): Likewise.
13359 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13360 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13361 cleanup to include a reference to dwarf2_per_objfile.
13362 (open_dwp_file): Add dwarf2_per_objfile parameter.
13363 (open_and_init_dwp_file): Likewise.
13364 (get_dwp_file): Likewise.
13365 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13366 (queue_and_load_all_dwo_tus): Update call.
13367 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13368 data.
13369 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13370 (dwarf2_ranges_process): Likewise.
13371 (dwarf2_get_pc_bounds): Likewise.
13372 (mark_common_block_symbol_computed): Likewise.
13373 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13374 (dwarf2_read_abbrevs): Update call.
13375 (read_partial_die): Use dwarf2_per_objfile from cu.
13376 (find_partial_die): Likewise.
13377 (fixup_partial_die): Likewise.
13378 (read_attribute_value): Likewise.
13379 (read_indirect_string_at_offset_from): Add objfile parameter.
13380 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13381 parameter.
13382 (read_indirect_string_from_dwz): Add objfile parameter.
13383 (read_indirect_string): Add objfile parameter.
13384 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13385 (read_addr_index): Use dwarf2_per_objfile from cu.
13386 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13387 call dw2_setup.
13388 (read_str_index): Use dwarf2_per_objfile from cu.
13389 (get_debug_line_section): Likewise.
13390 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13391 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13392 (new_symbol_full): Use dwarf2_per_objfile from cu.
13393 (build_error_marker_type): Likewise.
13394 (lookup_die_type): Likewise.
13395 (determine_prefix): Likewise.
13396 (follow_die_offset): Likewise.
13397 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13398 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13399 (dwarf2_fetch_die_type_sect_off): Likewise.
13400 (dwarf2_get_die_type): Likewise.
13401 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13402 (get_signatured_type): Likewise.
13403 (get_DW_AT_signature_type): Likewise.
13404 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13405 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13406 (cu_debug_loc_section): Likewise.
13407 (fill_in_loclist_baton): Likewise.
13408 (dwarf2_symbol_mark_computed): Likewise.
13409 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13410 dwarf2_per_objfile.
13411 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13412 parameter.
13413 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13414 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13415 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13416 (set_die_type): Use dwarf2_free_objfile from cu.
13417 (get_die_type_at_offset): Likewise.
13418 (dwarf2_per_objfile_free): Don't assign global variable.
13419 (debug_names) <constructor>: Add dwarf2_per_objfile
13420 parameter, update m_debugstrlookup construction.
13421 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13422 parameter.
13423 <m_dwarf2_per_objfile>: New field.
13424 <lookup>: Use m_dwarf2_per_objfile.
13425 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13426 (psyms_seen_size): Likewise.
13427 (write_gdbindex): Replace objfile parameter with
13428 dwarf2_per_objfile.
13429 (write_debug_names): Likewise.
13430 (write_psymtabs_to_index): Likewise.
13431 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13432 calls.
13433
13434 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13435
13436 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13437 <dwarf2_per_objfile>: New field.
13438 (struct dwarf2_per_cu_data) <objfile>: Remove.
13439 <dwarf2_per_objfile>: New field.
13440 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13441 of objfile.
13442 (create_signatured_type_table_from_index): Likewise.
13443 (create_debug_type_hash_table): Likewise.
13444 (fill_in_sig_entry_from_dwo_entry): Likewise.
13445 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13446 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13447 objfile.
13448 (create_partial_symtab): Access objfile through
13449 dwarf2_per_objfile.
13450 (process_psymtab_comp_unit_reader): Likewise.
13451 (read_comp_units_from_section): Likewise.
13452 (scan_partial_symbols): Likewise.
13453 (add_partial_symbol): Likewise.
13454 (add_partial_subprogram): Likewise.
13455 (peek_die_abbrev): Likewise.
13456 (fixup_go_packaging): Likewise.
13457 (process_full_comp_unit): Likewise.
13458 (process_full_type_unit): Likewise.
13459 (process_imported_unit_die): Likewise.
13460 (dwarf2_compute_name): Likewise.
13461 (dwarf2_physname): Likewise.
13462 (read_import_statement): Likewise.
13463 (create_cus_hash_table): Assign dwarf2_physname instead of
13464 objfile.
13465 (read_func_scope): Access objfile through dwarf2_per_objfile.
13466 (read_lexical_block_scope): Likewise.
13467 (read_call_site_scope): Likewise.
13468 (read_variable): Likewise.
13469 (dwarf2_rnglists_process): Likewise.
13470 (dwarf2_ranges_process): Likewise.
13471 (dwarf2_ranges_read): Likewise.
13472 (dwarf2_record_block_ranges): Likewise.
13473 (dwarf2_add_field): Likewise.
13474 (dwarf2_add_member_fn): Likewise.
13475 (read_structure_type): Likewise.
13476 (process_structure_scope): Likewise.
13477 (read_enumeration_type): Likewise.
13478 (read_array_type): Likewise.
13479 (read_common_block): Likewise.
13480 (read_namespace_type): Likewise.
13481 (read_namespace): Likewise.
13482 (read_module_type): Likewise.
13483 (read_tag_pointer_type): Likewise.
13484 (read_tag_ptr_to_member_type): Likewise.
13485 (read_tag_string_type): Likewise.
13486 (read_subroutine_type): Likewise.
13487 (read_typedef): Likewise.
13488 (read_base_type): Likewise.
13489 (attr_to_dynamic_prop): Likewise.
13490 (read_subrange_type): Likewise.
13491 (read_unspecified_type): Likewise.
13492 (load_partial_dies): Likewise.
13493 (read_partial_die): Likewise.
13494 (find_partial_die): Likewise.
13495 (guess_partial_die_structure_name): Likewise.
13496 (fixup_partial_die): Likewise.
13497 (read_attribute_value): Likewise.
13498 (read_addr_index_from_leb128): Likewise.
13499 (dwarf2_read_addr_index): Likewise.
13500 (dwarf2_string_attr): Likewise.
13501 (lnp_state_machine::check_line_address): Likewise.
13502 (dwarf_decode_lines_1): Likewise.
13503 (dwarf_decode_lines): Likewise.
13504 (dwarf2_start_symtab): Likewise.
13505 (var_decode_location): Likewise.
13506 (new_symbol_full): Likewise.
13507 (dwarf2_const_value_data): Likewise.
13508 (dwarf2_const_value_attr): Likewise.
13509 (dwarf2_const_value): Likewise.
13510 (die_type): Likewise.
13511 (die_containing_type): Likewise.
13512 (lookup_die_type): Likewise.
13513 (guess_full_die_structure_name): Likewise.
13514 (anonymous_struct_prefix): Likewise.
13515 (dwarf2_name): Likewise.
13516 (follow_die_ref_or_sig): Likewise.
13517 (follow_die_offset): Likewise.
13518 (follow_die_ref): Likewise.
13519 (dwarf2_fetch_die_loc_sect_off): Likewise.
13520 (dwarf2_fetch_constant_bytes): Likewise.
13521 (dwarf2_fetch_die_type_sect_off): Likewise.
13522 (dwarf2_get_die_type): Likewise.
13523 (follow_die_sig): Likewise.
13524 (decode_locdesc): Likewise.
13525 (dwarf2_per_cu_objfile): Likewise.
13526 (dwarf2_per_cu_text_offset): Likewise.
13527 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13528 objfile.
13529 (set_die_type): Access objfile through
13530 dwarf2_per_objfile.
13531
13532 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13533
13534 * valprint.c (converted_character_d): Remove typedef.
13535 (DEF_VEC_O (converted_character_d)): Remove.
13536 (count_next_character): Use std::vector.
13537 (print_converted_chars_to_obstack): Likewise.
13538 (generic_printstr): Likewise.
13539
13540 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13541
13542 * xml-support.h (struct gdb_xml_value): Add constructor.
13543 <value>: Change type to unique_xmalloc_ptr.
13544 (gdb_xml_value_s): Remove typedef.
13545 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13546 (gdb_xml_element_start_handler): Change parameter type to
13547 std::vector.
13548 (xml_find_attribute): Likewise.
13549 * xml-support.c (xml_find_attribute): Change parameter type to
13550 std::vector and adjust.
13551 (gdb_xml_values_cleanup): Remove.
13552 (gdb_xml_parser::start_element): Adjust to std::vector.
13553 (xinclude_start_include): Change paraeter type to std::vector
13554 and adjust.
13555 * btrace.c (check_xml_btrace_version): Likewise.
13556 (parse_xml_btrace_block): Likewise.
13557 (parse_xml_btrace_pt_config_cpu): Likewise.
13558 (parse_xml_btrace_pt): Likewise.
13559 (parse_xml_btrace_conf_bts): Likewise.
13560 (parse_xml_btrace_conf_pt): Likewise.
13561 * memory-map.c (memory_map_start_memory): Likewise.
13562 (memory_map_start_property): Likewise.
13563 * osdata.c (osdata_start_osdata): Likewise.
13564 (osdata_start_item): Likewise.
13565 (osdata_start_column): Likewise.
13566 * remote.c (start_thread): Likewise.
13567 * solib-aix.c (library_list_start_library): Likewise.
13568 (library_list_start_list): Likewise.
13569 * solib-svr4.c (library_list_start_library): Likewise.
13570 (svr4_library_list_start_list): Likewise.
13571 * solib-target.c (library_list_start_segment): Likewise.
13572 (library_list_start_section): Likewise.
13573 (library_list_start_library): Likewise.
13574 (library_list_start_list): Likewise.
13575 * tracepoint.c (traceframe_info_start_memory): Likewise.
13576 (traceframe_info_start_tvar): Likewise.
13577 * xml-syscall.c (syscall_start_syscall): Likewise.
13578 * xml-tdesc.c (tdesc_start_target): Likewise.
13579 (tdesc_start_feature): Likewise.
13580 (tdesc_start_reg): Likewise.
13581 (tdesc_start_union): Likewise.
13582 (tdesc_start_struct): Likewise.
13583 (tdesc_start_flags): Likewise.
13584 (tdesc_start_enum): Likewise.
13585 (tdesc_start_field): Likewise.
13586 (tdesc_start_enum_value): Likewise.
13587 (tdesc_start_vector): Likewise.
13588
13589 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13590
13591 * extension.h (struct xmethod_worker) <clone>: Remove.
13592 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13593 Remove.
13594 (python_xmethod_worker::clone): Remove.
13595 * valops.c (find_overload_match): Use std::move instead of
13596 clone.
13597
13598 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13599
13600 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13601 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13602 <free_xmethod_worker_data>: Remove.
13603 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13604 <get_xmethod_arg_types>: Remove.
13605 <get_xmethod_result_type>: Remove.
13606 <invoke_xmethod>: Remove.
13607 * extension.c (new_xmethod_worker): Remove.
13608 (clone_xmethod_worker): Remove.
13609 (get_matching_xmethod_workers): Return void, pass std::vector by
13610 pointer.
13611 (get_xmethod_arg_types): Rename to...
13612 (xmethod_worker::get_arg_types): ... this, and adjust.
13613 (get_xmethod_result_type): Rename to...
13614 (xmethod_worker::get_result_type): ... this, and adjust.
13615 (invoke_xmethod): Remove.
13616 (free_xmethod_worker): Remove.
13617 (free_xmethod_worker_vec): Remove.
13618 * extension.h (enum ext_lang_rc): Move here from
13619 extension-priv.h.
13620 (struct xmethod_worker): Add constructor and destructor.
13621 <data>: Remove.
13622 <value>: Remove.
13623 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13624 virtual pure methods.
13625 <get_arg_types, get_result_type>: New methods.
13626 (xmethod_worker_ptr): Remove typedef.
13627 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13628 (xmethod_worker_vec): Remove typedef.
13629 (xmethod_worker_up): New typedef.
13630 (invoke_xmethod): Remove.
13631 (clone_xmethod_worker): Remove.
13632 (free_xmethod_worker): Remove.
13633 (free_xmethod_worker_vec): Remove.
13634 (get_xmethod_arg_types): Remove.
13635 (get_xmethod_result_type): Remove.
13636 * valops.c (find_method_list): Use std::vector, don't use
13637 intermediate vector.
13638 (value_find_oload_method_list): Use std::vector.
13639 (find_overload_match): Use std::vector.
13640 (find_oload_champ): Use std::vector.
13641 * value.c (value_free): Use operator delete.
13642 (value_of_xmethod): Rename to...
13643 (value_from_xmethod): ... this. Don't assign
13644 xmethod_worker::value, take rvalue-reference.
13645 (result_type_of_xmethod): Adjust.
13646 (call_xmethod): Adjust.
13647 * value.h: Include extension.h.
13648 (struct xmethod_worker): Don't forward-declare.
13649 (value_of_xmethod): Rename to...
13650 (value_from_xmethod): ... this, take rvalue-reference.
13651 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13652 (struct python_xmethod_worker): ... this, add constructor and
13653 destructor.
13654 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13655 (gdbpy_free_xmethod_worker_data): Rename to...
13656 (python_xmethod_worker::~python_xmethod_worker): ... this and
13657 adjust.
13658 (gdbpy_clone_xmethod_worker_data): Rename to...
13659 (python_xmethod_worker::clone): ... this and adjust.
13660 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13661 temporary vector.
13662 (gdbpy_get_xmethod_arg_types): Rename to...
13663 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13664 (gdbpy_get_xmethod_result_type): Rename to...
13665 (python_xmethod_worker::do_get_result_type): ... this and
13666 adjust.
13667 (gdbpy_invoke_xmethod): Rename to...
13668 (python_xmethod_worker::invoke): ... this and adjust.
13669 (new_python_xmethod_worker): Rename to...
13670 (python_xmethod_worker::python_xmethod_worker): ... this and
13671 adjust.
13672 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13673 Remove.
13674 (gdbpy_free_xmethod_worker_data): Remove.
13675 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13676 (gdbpy_get_xmethod_arg_types): Remove.
13677 (gdbpy_get_xmethod_result_type): Remove.
13678 (gdbpy_invoke_xmethod): Remove.
13679 * python/python.c (python_extension_ops): Remove obsolete
13680 callbacks.
13681
13682 2018-01-05 Pedro Alves <palves@redhat.com>
13683
13684 PR gdb/18653
13685 * common/signals-state-save-restore.c
13686 (save_original_signals_state): New parameter 'quiet'. Warn if we
13687 find a custom handler preinstalled, instead of internal erroring.
13688 But only warn if !quiet.
13689 * common/signals-state-save-restore.h
13690 (save_original_signals_state): New parameter 'quiet'.
13691 * main.c (captured_main_1): Move save_original_signals_state call
13692 after option handling, and pass QUIET.
13693
13694 2018-01-05 Pedro Alves <palves@redhat.com>
13695
13696 * spu-tdep.c (spu_catch_start): Pass
13697 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13698
13699 2018-01-05 Pedro Alves <palves@redhat.com>
13700
13701 PR gdb/22670
13702 * ada-lang.c (literal_symbol_name_matcher): New function.
13703 (ada_get_symbol_name_matcher): Use it for
13704 symbol_name_match_type::SEARCH_NAME.
13705 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13706 it down instead of assuming symbol_name_match_type::FULL.
13707 * block.h (block_lookup_symbol): New parameter 'match_type'.
13708 * c-valprint.c (print_unpacked_pointer): Use
13709 lookup_symbol_search_name instead of lookup_symbol.
13710 * compile/compile-object-load.c (get_out_value_type): Pass down
13711 symbol_name_match_type::SEARCH_NAME.
13712 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13713 symbol_name_match_type::FULL.
13714 * cp-support.c (cp_get_symbol_name_matcher): Handle
13715 symbol_name_match_type::SEARCH_NAME.
13716 * infrun.c (insert_exception_resume_breakpoint): Use
13717 lookup_symbol_search_name.
13718 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13719 * psymtab.c (maintenance_check_psymtabs): Use
13720 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13721 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13722 SYMBOL_SEARCH_NAME.
13723 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13724 if symbol_name_match_type::SEARCH_NAME.
13725 (lookup_symbol_in_language): Pass down
13726 symbol_name_match_type::FULL.
13727 (lookup_symbol_search_name): New.
13728 (lookup_language_this): Pass down
13729 symbol_name_match_type::SEARCH_NAME.
13730 (lookup_symbol_aux, lookup_local_symbol): New parameter
13731 'match_type'. Pass it down.
13732 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13733 (lookup_symbol_search_name): New declaration.
13734 (lookup_symbol_in_block): New 'match_type' parameter.
13735
13736 2018-01-05 Pedro Alves <palves@redhat.com>
13737
13738 PR gdb/22670
13739 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13740 ada_lookup_symbol.
13741 (ada_lookup_symbol): Reimplement in terms of
13742 ada_lookup_symbol_list, bits factored out from
13743 ada_lookup_encoded_symbol.
13744
13745 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13746
13747 * ada-exp.y (write_object_renaming): When subscripting an array
13748 using a symbol as the index, pass the block in call to
13749 ada_lookup_encoded_symbol when looking that symbol up.
13750
13751 2018-01-05 Jerome Guitton <guitton@adacore.com>
13752
13753 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13754 TYPE_INDEX_TYPE.
13755
13756 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13757
13758 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13759 the case where VALUE_LVAL (val0) is not lval_memory.
13760
13761 2018-01-05 Xavier Roirand <roirand@adacore.com>
13762
13763 * ada-valprint.c (print_optional_low_bound): Handle
13764 character-indexed array printing like boolean-indexed array
13765 printing.
13766
13767 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13768
13769 * NEWS: Create a new section for the next release branch.
13770 Rename the section of the current branch, now that it has
13771 been cut.
13772
13773 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13774
13775 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13776 * version.in: Bump version to 8.1.50.DATE-git.
13777
13778 2018-01-03 Xavier Roirand <roirand@adacore.com>
13779
13780 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13781 Add field.
13782 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13783 Add field.
13784 (default_exception_support_info) <catch_handlers_sym>: Add field.
13785 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13786 (ada_exception_name_addr_1): Add "catch handlers" handling.
13787 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13788 Update all callers.
13789 (create_excep_cond_exprs) <ex>: Add parameter.
13790 (re_set_exception): Update create_excep_cond_exprs call.
13791 (print_it_exception, print_one_exception, print_mention_exception)
13792 (print_recreate_exception): Add "catch handler" handling.
13793 (allocate_location_catch_handlers, re_set_catch_handlers)
13794 (check_status_catch_handlers, print_it_catch_handlers)
13795 (print_one_catch_handlers, print_mention_catch_handlers)
13796 (print_recreate_catch_handlers): New function.
13797 (catch_handlers_breakpoint_ops): New variable.
13798 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13799 Add parameter. Add "catch handler" handling.
13800 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13801 Add "catch handler" handling.
13802 (ada_exception_catchpoint_cond_string): Add "catch handler"
13803 handling.
13804 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13805 call.
13806 (catch_ada_handlers_command): New function.
13807 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13808 operations structure.
13809 (_initialize_ada_language): Add "catch handlers" command entry.
13810 * NEWS: Document "catch handlers" feature.
13811
13812 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13813
13814 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13815 account when creating the array type of the slice.
13816 (ada_value_slice): Likewise.
13817
13818 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13819
13820 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13821 New enum value.
13822 (create_array_type_with_stride): Add byte_stride_prop parameter.
13823 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13824 New parameter. Update all callers in this file.
13825 (array_type_has_dynamic_stride): New function.
13826 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13827 of arrays with dynamic byte strides.
13828 * dwarf2read.c (read_array_type): Add support for dynamic
13829 DW_AT_byte_stride attributes.
13830
13831 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13832
13833 * dwarf2read.c (read_unspecified_type): Treat
13834 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13835
13836 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13837
13838 Update copyright year range in all GDB files.
13839
13840 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13841
13842 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13843 and gdb/testsuite/gdb.base/step-line.c.
13844
13845 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13846
13847 * copyright.py (main): Dump the contents of
13848 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13849 even if BY_HAND is empty.
13850
13851 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13852
13853 * top.c (print_gdb_version): Update Copyright year in version
13854 message.
13855
13856 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13857
13858 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13859
13860 For older changes see ChangeLog-2017.
13861 \f
13862 Local Variables:
13863 mode: change-log
13864 left-margin: 8
13865 fill-column: 74
13866 version-control: never
13867 coding: utf-8
13868 End: