Allow conversion of pointers to Python int
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-09-23 Tom Tromey <tom@tromey.com>
2
3 PR python/18170:
4 * python/py-value.c (valpy_int): Allow conversion from pointer
5 type.
6
7 2018-09-23 Tom Tromey <tom@tromey.com>
8
9 PR python/20126:
10 * python/py-value.c (valpy_int): Respect type sign.
11
12 2018-09-23 Tom Tromey <tom@tromey.com>
13
14 PR python/18352;
15 * python/py-value.c (valpy_float): Allow conversions from int or
16 char.
17 (valpy_int, valpy_long): Allow conversions from float.
18
19 2018-09-23 Tom Tromey <tom@tromey.com>
20
21 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
22 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
23
24 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
25
26 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
27 __sighndlr.
28 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
29
30 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
31
32 * windows-nat.c (windows_nat_target::wait): Remove a spurious
33 target_terminal::ours().
34
35 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
36
37 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
38 of vl to ULONGEST.
39
40 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
41
42 * breakpoint.c (update_inserted_breakpoint_locations): Remove
43 redundant condition.
44
45 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
46
47 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
48
49 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
50 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
51 * sol-thread.c (ps_pdmodel): Don't guard definition.
52
53 * procfs.c: Fix formatting.
54
55 * procfs.c (sysset_t_alloc): Remove.
56 (create_procinfo): Use XNEW instead of sysset_t_alloc.
57 (procfs_debug_inferior): Likewise.
58 (procfs_set_exec_trap): Likewise.
59 (proc_set_traced_sysentry): Don't allocate argp dynamically.
60 (proc_set_traced_sysexit): Likewise.
61
62 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
63 (dead_procinfo): Likewise.
64 (proc_warn): Likewise.
65 (proc_error): Likewise.
66 (proc_get_LDT_entry): Likewise.
67 (do_attach): Likewise.
68 (procfs_target::pid_to_str): Likewise.
69 (iterate_over_mappings): Likewise.
70
71 * procfs.c (create_procinfo): Fix ARI warning.
72 (proc_get_status): Likewise.
73 (proc_stop_process): Likewise.
74 (proc_run_process): Likewise.
75 (proc_kill): Likewise.
76 (proc_get_LDT_entry): Likewise.
77 (procfs_find_LDT_entry): Likewise.
78 (proc_update_threads): Likewise.
79 (proc_iterate_over_threads): Likewise.
80 (do_attach): Likewise.
81 (procfs_xfer_memory): Likewise.
82 (invalidate_cache): Likewise.
83 (procfs_target::resume): Likewise.
84 (procfs_init_inferior): Likewise.
85 (procfs_set_exec_trap): Likewise.
86 (procfs_target::thread_alive): Likewise.
87 (procfs_target::pid_to_exec_file): Likewise.
88 (iterate_over_mappings): Likewise.
89 (procfs_target::make_corefile_notes): Likewise.
90 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
91
92 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
93 (procfs_find_LDT_entry): Likewise.
94 * sol-thread.c (ps_lgetLDT): Likewise.
95
96 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
97
98 PR tdep/17903
99 * procfs.c (procfs_target): Declare pid_to_exec_file.
100 (procfs_target::pid_to_exec_file): New.
101
102 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
103
104 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
105 renaming.
106 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
107 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
108
109 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
110
111 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
112 (supply_fpregset, fill_fpregset): Move ...
113 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
114 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
115 Remove references to ioctl-based procfs.
116 Include <sys/reg.h>.
117 Remove PR_MODEL_NATIVE guards.
118 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
119 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
120
121 2018-09-19 Xavier Roirand <roirand@adacore.com>
122
123 PR gdb/20981:
124 * solib-darwin.c (darwin_get_dyld_bfd): New function.
125 (darwin_solib_get_all_image_info_addr_at_init): Update call.
126 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
127
128 2018-09-19 John Baldwin <jhb@FreeBSD.org>
129
130 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
131 (fbsd_print_sockaddr_in6): Likewise.
132
133 2018-09-19 Richard Bunt <richard.bunt@arm.com>
134 Chris January <chris.january@arm.com>
135
136 * eval.c (skip_undetermined_arglist): Skip argument list helper.
137 (evaluate_subexp_standard): Return a dummy type when
138 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
139 OP_F77_UNDETERMINED_ARGLIST case.
140 * expression.h (enum noside): Update comment.
141
142 2018-09-19 George Vasick <george.vasick@oracle.com>
143
144 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
145
146 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
147 April Chin <april.chin@oracle.com>
148 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
149
150 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
151 uint_t lwpid_t.
152 (create_procinfo): Print pids in /proc without leading zeros.
153
154 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
155
156 * nios2-tdep.c (nios2_gcc_target_options): New.
157 (nios2_gdb_arch_init): Install new hook.
158
159 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
160
161 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
162 New file.
163 * update-gnulib.sh: Apply patch.
164 * configure: Re-generate.
165
166 2018-09-18 John Baldwin <jhb@FreeBSD.org>
167
168 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
169 description. Make "info proc" command descriptions more
170 consistent.
171
172 2018-09-18 John Baldwin <jhb@FreeBSD.org>
173
174 * NEWS: Mention 'info proc files' command.
175
176 2018-09-18 John Baldwin <jhb@FreeBSD.org>
177
178 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
179 descriptors for IP_FILES and IP_ALL.
180
181 2018-09-18 John Baldwin <jhb@FreeBSD.org>
182
183 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
184 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
185 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
186 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
187 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
188 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
189 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
190 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
191 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
192 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
193 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
194 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
195 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
196 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
197 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
198 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
199 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
200 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
201 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
202 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
203 (struct fbsd_sockaddr_un): New types.
204 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
205 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
206 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
207 (fbsd_core_info_proc_files): New functions.
208 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
209 IP_ALL.
210 * fbsd-tdep.h (fbsd_info_proc_files_header)
211 (fbsd_info_proc_files_entry): New.
212
213 2018-09-18 John Baldwin <jhb@FreeBSD.org>
214
215 * defs.h (enum info_proc_what) [IP_FILES]: New value.
216 * infcmd.c (info_proc_cmd_files): New function.
217 (_initialize_infcmd): Register 'info proc files' command.
218
219 2018-09-18 John Baldwin <jhb@FreeBSD.org>
220
221 * gnulib/aclocal-m4-deps.mk: Re-generate.
222 * gnulib/aclocal.m4: Re-generate.
223 * gnulib/config.in: Re-generate.
224 * gnulib/configure: Re-generate.
225 * gnulib/import/Makefile.am: Re-generate.
226 * gnulib/import/Makefile.in: Re-generate.
227 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
228 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
229 * gnulib/import/arpa_inet.in.h: New file.
230 * gnulib/import/inet_ntop.c: New file.
231 * gnulib/import/m4/arpa_inet_h.m4: New file.
232 * gnulib/import/m4/inet_ntop.m4: New file.
233 * gnulib/import/m4/netinet_in_h.m4: New file.
234 * gnulib/import/m4/socklen.m4: New file.
235 * gnulib/import/m4/sockpfaf.m4: New file.
236 * gnulib/import/m4/stdalign.m4: New file.
237 * gnulib/import/m4/sys_uio_h.m4: New file.
238 * gnulib/import/netinet_in.in.h: New file.
239 * gnulib/import/stdalign.in.h: New file.
240 * gnulib/import/sys_socket.c: New file.
241 * gnulib/import/sys_socket.in.h: New file.
242 * gnulib/import/sys_uio.in.h: New file.
243 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
244 module.
245
246 2018-09-18 John Baldwin <jhb@FreeBSD.org>
247
248 * gnulib/aclocal-m4-deps.mk: New file.
249 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
250 deterministically.
251
252 2018-09-18 John Baldwin <jhb@FreeBSD.org>
253
254 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
255 KVE_PATH.
256
257 2018-09-18 Tom Tromey <tom@tromey.com>
258
259 * compile/compile-object-load.c (struct
260 link_hash_table_cleanup_data): Add constructor and destructor.
261 Use DISABLE_COPY_AND_ASSIGN.
262 (~link_hash_table_cleanup_data): Rename from
263 link_hash_table_free. Now a destructor.
264 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
265
266 2018-09-18 Tom Tromey <tom@tromey.com>
267
268 * compile/compile-object-run.c (do_module_cleanup): Use delete.
269 * compile/compile-object-load.c (struct munmap_list): Move to
270 header file.
271 (munmap_list::add): Rename from munmap_list_add; rewrite.
272 (munmap_list::~munmap_list): Rename from munmap_list_free.
273 (munmap_listp_free_cleanup): Remove.
274 (compile_object_load): Update.
275 * compile/compile-object-load.h (struct munmap_list): Move from
276 compile-object-load.c. Rewrite.
277
278 2018-09-18 Alan Hayward <alan.hayward@arm.com>
279
280 * aarch64-tdep.c (pass_in_v): Use register size.
281 (aarch64_extract_return_value): Likewise.
282 (aarch64_store_return_value): Likewise.
283
284 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
285
286 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
287 rlim_t.
288
289 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
290
291 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
292 Fix short help line.
293
294 2018-09-17 Tom Tromey <tom@tromey.com>
295
296 PR python/20445:
297 * configure: Rebuild.
298 * configure.ac: Conditionally use -DNDEBUG for Python.
299
300 2018-09-17 Tom Tromey <tom@tromey.com>
301
302 * configure: Rebuild.
303 * configure.ac: Use gmp as a library dependency when checking for
304 mpfr.
305
306 2018-09-17 Pedro Alves <palves@redhat.com>
307
308 * python/py-inferior.c (find_inferior_object): Delete.
309
310 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
311
312 * compile/compile-cplus-types.c
313 (compile_cplus_instance::enter_scope): Don't use new_scope after
314 std::move.
315
316 2018-09-17 Tom Tromey <tom@tromey.com>
317
318 * common/pathstuff.c (get_standard_cache_dir): Use
319 ~/Library/Caches on macOS.
320 * common/pathstuff.h (get_standard_cache_dir): Update comment.
321
322 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
323
324 PR python/23669
325 * breakpoint.c (commands_cmd_element): New.
326 (_initialize_breakpoint): Assign commands_cmd_element.
327 * breakpoint.h (commands_cmd_element): New.
328 * cli/cli-script.c (while_cmd_element, if_command,
329 define_cmd_element): New.
330 (command_name_equals): Remove.
331 (process_next_line): Compare commands by pointer, not by name.
332 (_initialize_cli_script): Assign the various cmd_list_element
333 variables.
334 * compile/compile.c (compile_cmd_element): New.
335 (_initialize_compile): Assign compile_cmd_element.
336 * compile/compile.h (compile_cmd_element): New.
337 * guile/guile.c (guile_cmd_element): New.
338 (install_gdb_commands): Assign guile_cmd_element.
339 * guile/guile.h (guile_cmd_element): New.
340 * python/python.c (python_cmd_element): New.
341 (_initialize_python): Assign python_cmd_element.
342 * python/python.h (python_cmd_element): New.
343 * tracepoint.c (while_stepping_cmd_element): New.
344 (_initialize_tracepoint): Assign while_stepping_cmd_element.
345 * tracepoint.h (while_stepping_cmd_element): New.
346
347 2018-09-17 Tom Tromey <tom@tromey.com>
348
349 * infrun.c (save_infcall_suspend_state): Return
350 infcall_suspend_state_up.
351 (save_infcall_control_state): Return infcall_control_state_up.
352 * inferior.h (save_infcall_suspend_state)
353 (save_infcall_control_state): Declare later. Return unique
354 pointers.
355
356 2018-09-17 Tom Tromey <tom@tromey.com>
357
358 * infrun.c (struct stop_context): Declare constructor,
359 destructor, "changed" method.
360 (stop_context::stop_context): Rename from save_stop_context.
361 (stop_context::~stop_context): Rename from
362 release_stop_context_cleanup.
363 (normal_stop): Update.
364 (stop_context::changed): Rename from stop_context_changed. Return
365 bool.
366
367 2018-09-17 Tom Tromey <tom@tromey.com>
368
369 * inferior.h (struct infcall_suspend_state_deleter): New.
370 (infcall_suspend_state_up): New typedef.
371 (struct infcall_control_state_deleter): New.
372 (infcall_control_state_up): New typedef.
373 (make_cleanup_restore_infcall_suspend_state)
374 (make_cleanup_restore_infcall_control_state): Don't declare.
375 * infcall.c (call_function_by_hand_dummy): Update.
376 * infrun.c (do_restore_infcall_suspend_state_cleanup)
377 (make_cleanup_restore_infcall_suspend_state): Remove.
378 (do_restore_infcall_control_state_cleanup)
379 (make_cleanup_restore_infcall_control_state): Remove.
380
381 2018-09-17 Tom Tromey <tom@tromey.com>
382
383 * gdbthread.h (struct thread_control_state): Add initializer.
384 (class thread_info) <control>: Remove initializer.
385 * inferior.h (struct inferior_control_state): Add initializer.
386 (class inferior) <control>: Remove initializer.
387 (exit_inferior_1): Update.
388 * infrun.c (struct infcall_control_state): Add constructors.
389 (save_infcall_control_state): Use new.
390 (restore_infcall_control_state, discard_infcall_control_state):
391 Use delete.
392
393 2018-09-17 Tom Tromey <tom@tromey.com>
394
395 * infrun.c (struct infcall_suspend_state) <registers>: Now a
396 unique_ptr.
397 <siginfo_data>: Now a unique_xmalloc_ptr.
398 (save_infcall_suspend_state, restore_infcall_suspend_state)
399 (discard_infcall_suspend_state)
400 (get_infcall_suspend_state_regcache): Update.
401
402 2018-09-17 Tom Tromey <tom@tromey.com>
403
404 * gdbthread.h (struct thread_suspend_state): Add initializers.
405 (class thread_info) <suspend>: Remove initializer.
406 * infrun.c (struct infcall_suspend_state): Add initializers.
407 (save_infcall_suspend_state): Use new.
408 (discard_infcall_suspend_state): Use delete.
409
410 2018-09-16 Tom Tromey <tom@tromey.com>
411
412 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
413 Remove.
414 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
415 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
416 (py_varobj_iter_new): Likewise.
417 (py_varobj_get_iterator): Use gdbpy_ref.
418
419 2018-09-16 Tom Tromey <tom@tromey.com>
420
421 * python/py-threadevent.c (py_get_event_thread): Simplify.
422 * python/py-inferior.c (infpy_thread_from_thread_handle):
423 Return immediately after calling thread_to_thread_object. Use
424 Py_RETURN_NONE.
425 (thread_to_thread_object): Set the exception on a NULL return.
426
427 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
428
429 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
430
431 2018-09-16 Tom Tromey <tom@tromey.com>
432
433 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
434 Remove.
435
436 2018-09-16 Tom Tromey <tom@tromey.com>
437
438 * python/python-internal.h (thread_to_thread_object): Change
439 return type.
440 * python/py-inferior.c (thread_to_thread_object): Return a new
441 reference.
442 (infpy_thread_from_thread_handle): Update.
443 * python/py-infthread.c (gdbpy_selected_thread): Update.
444 * python/py-stopevent.c (create_stop_event_object): Update.
445 * python/py-threadevent.c (py_get_event_thread): Return a new
446 reference.
447 (py_get_event_thread): Update.
448 * python/py-event.h (py_get_event_thread): Change return type.
449 * python/py-continueevent.c (create_continue_event_object):
450 Update.
451
452 2018-09-16 Tom Tromey <tom@tromey.com>
453
454 * python/py-progspace.c (pspy_get_objfiles): Update.
455 * python/python-internal.h (objfile_to_objfile_object): Change
456 return type.
457 * python/py-newobjfileevent.c (create_new_objfile_event_object):
458 Update.
459 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
460 Update.
461 * python/python.c (gdbpy_get_current_objfile): Update.
462 (gdbpy_objfiles): Update.
463 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
464 Update.
465 (objfile_to_objfile_object): Return a new reference.
466 * python/py-symtab.c (stpy_get_objfile): Update.
467 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
468 Update.
469
470 2018-09-16 Tom Tromey <tom@tromey.com>
471
472 * python/py-inferior.c (infpy_get_progspace): Update.
473 * python/python-internal.h (pspace_to_pspace_object): Change
474 return type.
475 * python/py-newobjfileevent.c
476 (create_clear_objfiles_event_object): Update.
477 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
478 Update.
479 * python/python.c (gdbpy_get_current_progspace): Update.
480 (gdbpy_progspaces): Update.
481 * python/py-progspace.c (pspace_to_pspace_object): Return a new
482 reference.
483 * python/py-objfile.c (objfpy_get_progspace): Update.
484 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
485 Update.
486
487 2018-09-16 Tom Tromey <tom@tromey.com>
488
489 * python/lib/gdb/__init__.py (current_progspace, objfiles)
490 (solib_name, block_for_pc, find_pc_line): New functions.
491 (execute_unwinders): Update.
492 * python/py-block.c (gdbpy_block_for_pc): Remove.
493 * python/py-inferior.c (infpy_get_progspace): New function.
494 (inferior_object_getset) <progspace>: Add.
495 * python/py-progspace.c (pspy_objfiles): Rewrite.
496 (pspy_solib_name, pspy_block_for_pc)
497 (pspy_find_pc_line, pspy_is_valid): New functions.
498 (progspace_object_methods): Add entries for solib_name,
499 block_for_pc, find_pc_line, is_valid.
500 * python/python-internal.h (gdbpy_block_for_pc)
501 (build_objfiles_list): Don't declare.
502 * python/python.c: Don't include solib.h.
503 (gdbpy_solib_name, gdbpy_find_pc_line)
504 (gdbpy_get_current_progspace, build_objfiles_list)
505 (gdbpy_objfiles): Remove.
506 (GdbMethods) <current_progspace, objfiles, block_for_pc,
507 solib_name, find_pc_line>: Remove entries.
508
509 2018-09-16 Tom Tromey <tom@tromey.com>
510
511 * top.c (new_ui_command): Use GNU style for metasyntactic
512 variables.
513 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
514 variables.
515 * maint.c (maintenance_translate_address): Remove "<>" around
516 text.
517 * interps.c (interpreter_exec_cmd): Use GNU style for
518 metasyntactic variables.
519 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
520 metasyntactic variables.
521 * tracepoint.c (tfind_range_command): Use GNU style for
522 metasyntactic variables.
523 (tfind_outside_command): Likewise.
524 (_initialize_tracepoint): Likewise.
525 * remote.c (extended_remote_target::create_inferior): Use GNU
526 style for metasyntactic variables.
527 * sparc64-tdep.c (adi_examine_command): Use GNU style for
528 metasyntactic variables.
529 (adi_assign_command): Likewise.
530
531 2018-09-16 Tom Tromey <tom@tromey.com>
532
533 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
534 metasyntactic variables. Print message if no disassembler options
535 are available.
536
537 2018-09-15 Tom Tromey <tom@tromey.com>
538
539 * infcmd.c (get_inferior_args): Return const char *.
540 * inferior.h (get_inferior_args): Return type now const.
541 * linux-tdep.c (linux_fill_prpsinfo): Update.
542 * procfs.c (procfs_target::make_corefile_notes): Update.
543
544 2018-09-07 Tom Tromey <tom@tromey.com>
545
546 * python/python.c (execute_gdb_command): Call bpstat_do_actions
547 inside the TRY.
548
549 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
550
551 * nios2-tdep.c (nios2_type_align): New.
552 (nios2_gdb_arch_init): Install type_align hook.
553
554 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
555
556 * eval.c (fake_method::fake_method): Call xzalloc directly for a
557 type that is neither object file owned, nor gdbarch owned.
558 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
559 gdbarch is non-NULL.
560 (alloc_type_instance): Allocate non-objfile owned types on the
561 gdbarch obstack.
562 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
563 using TYPE_ALLOC to ensure memory is allocated on the correct
564 obstack.
565 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
566 obstack, or the gdbarch obstack.
567 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
568
569 2018-09-14 Tom Tromey <tom@tromey.com>
570
571 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
572 block.
573
574 2018-09-14 Tom Tromey <tom@tromey.com>
575
576 * nat/fork-inferior.c (get_startup_shell): Remove "static".
577
578 2018-09-13 Tom Tromey <tom@tromey.com>
579
580 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
581 static.
582
583 2018-09-13 Tom Tromey <tom@tromey.com>
584
585 * exec.c (try_open_exec_file): Use std::string.
586
587 2018-09-13 Tom Tromey <tom@tromey.com>
588
589 * utils.h (gdb_bfd_errmsg): Return std::string.
590 * exec.c (exec_file_attach): Update.
591 * compile/compile-object-load.c (compile_object_load): Update.
592 * utils.c (gdb_bfd_errmsg): Return std::string.
593
594 2018-09-13 Tom Tromey <tom@tromey.com>
595
596 * procfs.c (struct procinfo_deleter): New.
597 (procinfo_up): New typedef.
598 (do_destroy_procinfo_cleanup): Remove.
599 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
600
601 2018-09-13 Tom Tromey <tom@tromey.com>
602
603 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
604
605 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
606 2018-09-13 Tom Tromey <tom@tromey.com>
607
608 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
609 (pspy_get_objfiles): New function.
610 (progspace_object_methods): New.
611 (pspace_object_type): Add tp_methods callback.
612 * python/python-internal.h (build_objfiles_list): New
613 declaration.
614 * python/python.c (build_objfiles_list): New function.
615 (gdbpy_objfiles): Implement using build_objfiles_list.
616 * NEWS: Mention the Progspace.objfiles method.
617
618 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
619
620 * python/py-inferior.c (infpy_get_progspace): New function.
621 (inferior_object_getset): Add progspace property.
622 * NEWS: Mention the new property.
623
624 2018-09-13 Tom Tromey <tom@tromey.com>
625
626 PR rust/23650:
627 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
628
629 2018-09-13 Tom Tromey <tom@tromey.com>
630
631 PR rust/23626:
632 * rust-lang.c (rust_enum_variant): Now static.
633 (rust_empty_enum_p): New function.
634 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
635 Handle empty enum.
636
637 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
638
639 * python/py-inferior.c (infpy_repr): New.
640 (inferior_object_type): Register infpy_repr.
641 * python/py-objfile.c (objfpy_repr): New.
642 (objfile_object_type): Register objfpy_repr.
643
644 2018-09-12 John Baldwin <jhb@FreeBSD.org>
645
646 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
647
648 2018-09-12 John Baldwin <jhb@FreeBSD.org>
649
650 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
651 typo.
652
653 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
654
655 * common/common-utils.c: Don't include '<sys/stat.h>'.
656 (is_regular_file): Move to...
657 * common/filestuff.c (is_regular_file): ... here.
658 * common/common-utils.h (is_regular_file): Move to...
659 * common/filestuff.h (is_regular_file): ... here.
660
661 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
662
663 * skip.c (debug_skip): New variable.
664 (skiplist_entry::do_skip_file_p): Add debug output.
665 (skiplist_entry::do_skip_gfile_p): Likewise.
666 (skiplist_entry::skip_function_p): Likewise.
667 (_initialize_step_skip): Create debug command.
668 * NEWS: Mention set/show debug skip.
669
670 2018-09-11 Xavier Roirand <roirand@adacore.com>
671
672 * darwin-nat.c (should_disable_startup_with_shell):
673 New function.
674 (darwin_nat_target::create_inferior): Add call.
675
676 2018-09-11 Xavier Roirand <roirand@adacore.com>
677
678 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
679 inf_port, msg_state>: Initialize.
680 (struct darwin_thread_info) <signaled, single_step>: Change
681 type and initialize.
682 (struct darwin_thread_info) <event>: Initialize.
683
684 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
685
686 PR gdb/23555
687 PR gdb/23558
688 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
689 guesses.
690
691 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
692
693 Revert:
694 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
695
696 PR gdb/23555
697 PR gdb/23558
698 * gnulib/aclocal.m4: Regenerate.
699 * gnulib/config.in: Regenerate.
700 * gnulib/configure: Regenerate.
701 * gnulib/import/Makefile.am: Update.
702 * gnulib/import/Makefile.in: Update.
703 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
704 * gnulib/import/_Noreturn.h: ... this.
705 * gnulib/import/alloca.in.h: Update.
706 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
707 * gnulib/import/arg-nonnull.h: ... this.
708 * gnulib/import/assure.h: Update.
709 * gnulib/import/at-func.c: Update.
710 * gnulib/import/basename-lgpl.c: Update.
711 * gnulib/import/extra/snippet/c++defs.h: Rename to...
712 * gnulib/import/c++defs.h: ... this.
713 * gnulib/import/canonicalize-lgpl.c: Update.
714 * gnulib/import/cdefs.h: Update.
715 * gnulib/import/chdir-long.c: Update.
716 * gnulib/import/chdir-long.h: Update.
717 * gnulib/import/cloexec.c: Update.
718 * gnulib/import/cloexec.h: Update.
719 * gnulib/import/close.c: Update.
720 * gnulib/import/closedir.c: Update.
721 * gnulib/import/config.charset: Update.
722 * gnulib/import/dirent-private.h: Update.
723 * gnulib/import/dirent.in.h: Update.
724 * gnulib/import/dirfd.c: Update.
725 * gnulib/import/dirname-lgpl.c: Update.
726 * gnulib/import/dirname.h: Update.
727 * gnulib/import/dosname.h: Update.
728 * gnulib/import/dup-safer-flag.c: Update.
729 * gnulib/import/dup-safer.c: Update.
730 * gnulib/import/dup.c: Update.
731 * gnulib/import/dup2.c: Update.
732 * gnulib/import/errno.in.h: Update.
733 * gnulib/import/error.c: Update.
734 * gnulib/import/error.h: Update.
735 * gnulib/import/exitfail.c: Update.
736 * gnulib/import/exitfail.h: Update.
737 * gnulib/import/extra/update-copyright: Update.
738 * gnulib/import/fchdir.c: Update.
739 * gnulib/import/fcntl.c: Update.
740 * gnulib/import/fcntl.in.h: Update.
741 * gnulib/import/fd-hook.c: Update.
742 * gnulib/import/fd-hook.h: Update.
743 * gnulib/import/fd-safer-flag.c: Update.
744 * gnulib/import/fd-safer.c: Update.
745 * gnulib/import/fdopendir.c: Update.
746 * gnulib/import/filename.h: Update.
747 * gnulib/import/filenamecat-lgpl.c: Update.
748 * gnulib/import/filenamecat.h: Update.
749 * gnulib/import/flexmember.h: Update.
750 * gnulib/import/float+.h: Update.
751 * gnulib/import/float.c: Update.
752 * gnulib/import/float.in.h: Update.
753 * gnulib/import/fnmatch.c: Update.
754 * gnulib/import/fnmatch.in.h: Update.
755 * gnulib/import/fnmatch_loop.c: Update.
756 * gnulib/import/fpucw.h: Update.
757 * gnulib/import/frexp.c: Update.
758 * gnulib/import/frexpl.c: Update.
759 * gnulib/import/fstat.c: Update.
760 * gnulib/import/fstatat.c: Update.
761 * gnulib/import/getcwd-lgpl.c: Update.
762 * gnulib/import/getcwd.c: Update.
763 * gnulib/import/getdtablesize.c: Update.
764 * gnulib/import/getlogin_r.c: Update.
765 * gnulib/import/getprogname.c: Update.
766 * gnulib/import/getprogname.h: Update.
767 * gnulib/import/gettext.h: Update.
768 * gnulib/import/gettimeofday.c: Update.
769 * gnulib/import/glob-libc.h: Update.
770 * gnulib/import/glob.c: Update.
771 * gnulib/import/glob.in.h: Update.
772 * gnulib/import/glob_internal.h: Update.
773 * gnulib/import/glob_pattern_p.c: Update.
774 * gnulib/import/globfree.c: Update.
775 * gnulib/import/hard-locale.c: Update.
776 * gnulib/import/hard-locale.h: Update.
777 * gnulib/import/intprops.h: Update.
778 * gnulib/import/inttypes.in.h: Update.
779 * gnulib/import/isnan.c: Update.
780 * gnulib/import/isnand-nolibm.h: Update.
781 * gnulib/import/isnand.c: Update.
782 * gnulib/import/isnanl-nolibm.h: Update.
783 * gnulib/import/isnanl.c: Update.
784 * gnulib/import/itold.c: Update.
785 * gnulib/import/libc-config.h: Update.
786 * gnulib/import/limits.in.h: Update.
787 * gnulib/import/localcharset.c: Update.
788 * gnulib/import/localcharset.h: Update.
789 * gnulib/import/localtime-buffer.c: Update.
790 * gnulib/import/localtime-buffer.h: Update.
791 * gnulib/import/lstat.c: Update.
792 * gnulib/import/m4/00gnulib.m4: Update.
793 * gnulib/import/m4/__inline.m4: Update.
794 * gnulib/import/m4/absolute-header.m4: Update.
795 * gnulib/import/m4/alloca.m4: Update.
796 * gnulib/import/m4/builtin-expect.m4: Update.
797 * gnulib/import/m4/canonicalize.m4: Update.
798 * gnulib/import/m4/chdir-long.m4: Update.
799 * gnulib/import/m4/close.m4: Update.
800 * gnulib/import/m4/closedir.m4: Update.
801 * gnulib/import/m4/configmake.m4: Update.
802 * gnulib/import/m4/d-ino.m4: Update.
803 * gnulib/import/m4/d-type.m4: Update.
804 * gnulib/import/m4/dirent_h.m4: Update.
805 * gnulib/import/m4/dirfd.m4: Update.
806 * gnulib/import/m4/dirname.m4: Update.
807 * gnulib/import/m4/double-slash-root.m4: Update.
808 * gnulib/import/m4/dup.m4: Update.
809 * gnulib/import/m4/dup2.m4: Update.
810 * gnulib/import/m4/eealloc.m4: Update.
811 * gnulib/import/m4/environ.m4: Update.
812 * gnulib/import/m4/errno_h.m4: Update.
813 * gnulib/import/m4/error.m4: Update.
814 * gnulib/import/m4/exponentd.m4: Update.
815 * gnulib/import/m4/exponentl.m4: Update.
816 * gnulib/import/m4/extensions.m4: Update.
817 * gnulib/import/m4/extern-inline.m4: Update.
818 * gnulib/import/m4/fchdir.m4: Update.
819 * gnulib/import/m4/fcntl-o.m4: Update.
820 * gnulib/import/m4/fcntl.m4: Update.
821 * gnulib/import/m4/fcntl_h.m4: Update.
822 * gnulib/import/m4/fdopendir.m4: Update.
823 * gnulib/import/m4/filenamecat.m4: Update.
824 * gnulib/import/m4/flexmember.m4: Update.
825 * gnulib/import/m4/float_h.m4: Update.
826 * gnulib/import/m4/fnmatch.m4: Update.
827 * gnulib/import/m4/fnmatch_h.m4: Update.
828 * gnulib/import/m4/fpieee.m4: Update.
829 * gnulib/import/m4/frexp.m4: Update.
830 * gnulib/import/m4/frexpl.m4: Update.
831 * gnulib/import/m4/fstat.m4: Update.
832 * gnulib/import/m4/fstatat.m4: Update.
833 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
834 * gnulib/import/m4/getcwd-path-max.m4: Update.
835 * gnulib/import/m4/getcwd.m4: Update.
836 * gnulib/import/m4/getdtablesize.m4: Update.
837 * gnulib/import/m4/getlogin.m4: Update.
838 * gnulib/import/m4/getlogin_r.m4: Update.
839 * gnulib/import/m4/getpagesize.m4: Update.
840 * gnulib/import/m4/getprogname.m4: Update.
841 * gnulib/import/m4/gettimeofday.m4: Update.
842 * gnulib/import/m4/glibc21.m4: Update.
843 * gnulib/import/m4/glob.m4: Update.
844 * gnulib/import/m4/glob_h.m4: Update.
845 * gnulib/import/m4/gnulib-cache.m4: Update.
846 * gnulib/import/m4/gnulib-common.m4: Update.
847 * gnulib/import/m4/gnulib-comp.m4: Update.
848 * gnulib/import/m4/gnulib-tool.m4: Update.
849 * gnulib/import/m4/hard-locale.m4: Update.
850 * gnulib/import/m4/include_next.m4: Update.
851 * gnulib/import/m4/inttypes-pri.m4: Update.
852 * gnulib/import/m4/inttypes.m4: Update.
853 * gnulib/import/m4/isnand.m4: Update.
854 * gnulib/import/m4/isnanl.m4: Update.
855 * gnulib/import/m4/largefile.m4: Update.
856 * gnulib/import/m4/limits-h.m4: Update.
857 * gnulib/import/m4/localcharset.m4: Update.
858 * gnulib/import/m4/locale-fr.m4: Update.
859 * gnulib/import/m4/locale-ja.m4: Update.
860 * gnulib/import/m4/locale-zh.m4: Update.
861 * gnulib/import/m4/localtime-buffer.m4: Update.
862 * gnulib/import/m4/longlong.m4: Update.
863 * gnulib/import/m4/lstat.m4: Update.
864 * gnulib/import/m4/malloc.m4: Update.
865 * gnulib/import/m4/malloca.m4: Update.
866 * gnulib/import/m4/math_h.m4: Update.
867 * gnulib/import/m4/mbrtowc.m4: Update.
868 * gnulib/import/m4/mbsinit.m4: Update.
869 * gnulib/import/m4/mbsrtowcs.m4: Update.
870 * gnulib/import/m4/mbstate_t.m4: Update.
871 * gnulib/import/m4/memchr.m4: Update.
872 * gnulib/import/m4/memmem.m4: Update.
873 * gnulib/import/m4/mempcpy.m4: Update.
874 * gnulib/import/m4/memrchr.m4: Update.
875 * gnulib/import/m4/mkdir.m4: Update.
876 * gnulib/import/m4/mkstemp.m4: Update.
877 * gnulib/import/m4/mmap-anon.m4: Update.
878 * gnulib/import/m4/mode_t.m4: Update.
879 * gnulib/import/m4/msvc-inval.m4: Update.
880 * gnulib/import/m4/msvc-nothrow.m4: Update.
881 * gnulib/import/m4/multiarch.m4: Update.
882 * gnulib/import/m4/nocrash.m4: Update.
883 * gnulib/import/m4/off_t.m4: Update.
884 * gnulib/import/m4/onceonly.m4: Update.
885 * gnulib/import/m4/open-cloexec.m4: Update.
886 * gnulib/import/m4/open.m4: Update.
887 * gnulib/import/m4/openat.m4: Update.
888 * gnulib/import/m4/opendir.m4: Update.
889 * gnulib/import/m4/pathmax.m4: Update.
890 * gnulib/import/m4/rawmemchr.m4: Update.
891 * gnulib/import/m4/readdir.m4: Update.
892 * gnulib/import/m4/readlink.m4: Update.
893 * gnulib/import/m4/realloc.m4: Update.
894 * gnulib/import/m4/rename.m4: Update.
895 * gnulib/import/m4/rewinddir.m4: Update.
896 * gnulib/import/m4/rmdir.m4: Update.
897 * gnulib/import/m4/save-cwd.m4: Update.
898 * gnulib/import/m4/secure_getenv.m4: Update.
899 * gnulib/import/m4/setenv.m4: Update.
900 * gnulib/import/m4/signal_h.m4: Update.
901 * gnulib/import/m4/ssize_t.m4: Update.
902 * gnulib/import/m4/stat-time.m4: Update.
903 * gnulib/import/m4/stat.m4: Update.
904 * gnulib/import/m4/std-gnu11.m4: Update.
905 * gnulib/import/m4/stdbool.m4: Update.
906 * gnulib/import/m4/stddef_h.m4: Update.
907 * gnulib/import/m4/stdint.m4: Update.
908 * gnulib/import/m4/stdio_h.m4: Update.
909 * gnulib/import/m4/stdlib_h.m4: Update.
910 * gnulib/import/m4/strchrnul.m4: Update.
911 * gnulib/import/m4/strdup.m4: Update.
912 * gnulib/import/m4/strerror.m4: Update.
913 * gnulib/import/m4/string_h.m4: Update.
914 * gnulib/import/m4/strstr.m4: Update.
915 * gnulib/import/m4/strtok_r.m4: Update.
916 * gnulib/import/m4/sys_socket_h.m4: Update.
917 * gnulib/import/m4/sys_stat_h.m4: Update.
918 * gnulib/import/m4/sys_time_h.m4: Update.
919 * gnulib/import/m4/sys_types_h.m4: Update.
920 * gnulib/import/m4/tempname.m4: Update.
921 * gnulib/import/m4/time_h.m4: Update.
922 * gnulib/import/m4/unistd-safer.m4: Update.
923 * gnulib/import/m4/unistd_h.m4: Update.
924 * gnulib/import/m4/warn-on-use.m4: Update.
925 * gnulib/import/m4/wchar_h.m4: Update.
926 * gnulib/import/m4/wchar_t.m4: Update.
927 * gnulib/import/m4/wctype_h.m4: Update.
928 * gnulib/import/m4/wint_t.m4: Update.
929 * gnulib/import/malloc.c: Update.
930 * gnulib/import/malloc/scratch_buffer.h: Update.
931 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
932 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
933 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
934 * gnulib/import/malloca.c: Update.
935 * gnulib/import/malloca.h: Update.
936 * gnulib/import/malloca.valgrind: Update.
937 * gnulib/import/math.in.h: Update.
938 * gnulib/import/mbrtowc.c: Update.
939 * gnulib/import/mbsinit.c: Update.
940 * gnulib/import/mbsrtowcs-impl.h: Update.
941 * gnulib/import/mbsrtowcs-state.c: Update.
942 * gnulib/import/mbsrtowcs.c: Update.
943 * gnulib/import/memchr.c: Update.
944 * gnulib/import/memmem.c: Update.
945 * gnulib/import/mempcpy.c: Update.
946 * gnulib/import/memrchr.c: Update.
947 * gnulib/import/mkdir.c: Update.
948 * gnulib/import/mkstemp.c: Update.
949 * gnulib/import/msvc-inval.c: Update.
950 * gnulib/import/msvc-inval.h: Update.
951 * gnulib/import/msvc-nothrow.c: Update.
952 * gnulib/import/msvc-nothrow.h: Update.
953 * gnulib/import/open.c: Update.
954 * gnulib/import/openat-die.c: Update.
955 * gnulib/import/openat-priv.h: Update.
956 * gnulib/import/openat-proc.c: Update.
957 * gnulib/import/openat.c: Update.
958 * gnulib/import/openat.h: Update.
959 * gnulib/import/opendir.c: Update.
960 * gnulib/import/pathmax.h: Update.
961 * gnulib/import/pipe-safer.c: Update.
962 * gnulib/import/rawmemchr.c: Update.
963 * gnulib/import/readdir.c: Update.
964 * gnulib/import/readlink.c: Update.
965 * gnulib/import/realloc.c: Update.
966 * gnulib/import/ref-add.sin: Update.
967 * gnulib/import/ref-del.sin: Update.
968 * gnulib/import/rename.c: Update.
969 * gnulib/import/rewinddir.c: Update.
970 * gnulib/import/rmdir.c: Update.
971 * gnulib/import/same-inode.h: Update.
972 * gnulib/import/save-cwd.c: Update.
973 * gnulib/import/save-cwd.h: Update.
974 * gnulib/import/scratch_buffer.h: Update.
975 * gnulib/import/secure_getenv.c: Update.
976 * gnulib/import/setenv.c: Update.
977 * gnulib/import/signal.in.h: Update.
978 * gnulib/import/stat-time.c: Update.
979 * gnulib/import/stat-time.h: Update.
980 * gnulib/import/stat-w32.c: Update.
981 * gnulib/import/stat-w32.h: Update.
982 * gnulib/import/stat.c: Update.
983 * gnulib/import/stdbool.in.h: Update.
984 * gnulib/import/stddef.in.h: Update.
985 * gnulib/import/stdint.in.h: Update.
986 * gnulib/import/stdio.in.h: Update.
987 * gnulib/import/stdlib.in.h: Update.
988 * gnulib/import/str-two-way.h: Update.
989 * gnulib/import/strchrnul.c: Update.
990 * gnulib/import/strdup.c: Update.
991 * gnulib/import/streq.h: Update.
992 * gnulib/import/strerror-override.c: Update.
993 * gnulib/import/strerror-override.h: Update.
994 * gnulib/import/strerror.c: Update.
995 * gnulib/import/string.in.h: Update.
996 * gnulib/import/stripslash.c: Update.
997 * gnulib/import/strnlen1.c: Update.
998 * gnulib/import/strnlen1.h: Update.
999 * gnulib/import/strstr.c: Update.
1000 * gnulib/import/strtok_r.c: Update.
1001 * gnulib/import/sys_stat.in.h: Update.
1002 * gnulib/import/sys_time.in.h: Update.
1003 * gnulib/import/sys_types.in.h: Update.
1004 * gnulib/import/tempname.c: Update.
1005 * gnulib/import/tempname.h: Update.
1006 * gnulib/import/time.in.h: Update.
1007 * gnulib/import/unistd--.h: Update.
1008 * gnulib/import/unistd-safer.h: Update.
1009 * gnulib/import/unistd.in.h: Update.
1010 * gnulib/import/unsetenv.c: Update.
1011 * gnulib/import/verify.h: Update.
1012 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1013 * gnulib/import/wchar.in.h: Update.
1014 * gnulib/import/wctype.in.h: Update.
1015 * gnulib/import/xalloc-oversized.h: Update.
1016 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1017 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1018
1019 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
1020
1021 * record-btrace.c (get_thread_current_frame): Remove
1022 old_inferior_ptid.
1023
1024 2018-09-10 Jerome Guitton <guitton@adacore.com>
1025
1026 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
1027 with check_tag to 1 if and only if the type is tagged and the
1028 component being searched cannot been found in the current
1029 view. Otherwise, always call ada_to_fixed_type with
1030 check_tag to 0.
1031
1032 2018-09-10 Xavier Roirand <roirand@adacore.com>
1033
1034 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
1035 declaration.
1036 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
1037 * ada-varobj.c (ada_varobj_get_number_of_children,
1038 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
1039
1040 2018-09-10 Xavier Roirand <roirand@adacore.com>
1041
1042 * ada-valprint.c (ada_value_print): Use type instead of
1043 enclosing type.
1044
1045 2018-09-10 Xavier Roirand <roirand@adacore.com>
1046
1047 * ada-lang.c (ada_value_subscript): Handle case when parameter is
1048 an array of access to unconstrained array.
1049
1050 2018-09-10 Xavier Roirand <roirand@adacore.com>
1051
1052 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
1053 (ada_check_typedef): Use it.
1054
1055 2018-09-10 Xavier Roirand <roirand@adacore.com>
1056
1057 * ada-varobj.c (ada_varobj_describe_struct_child)
1058 (ada_varobj_describe_child): Handle union case like struct one.
1059
1060 2018-09-10 Tom Tromey <tom@tromey.com>
1061
1062 PR python/18380:
1063 * python/python.c (_initialize_python): Make example in "python"
1064 help work in Python 3.
1065
1066 2018-09-10 Eli Zaretskii <eliz@gnu.org>
1067
1068 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
1069 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
1070 $(EXEEXT) to the script, as it is not a program.
1071
1072 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
1073
1074 * python/py-prettyprint.c (pretty_print_one_value): Return
1075 gdbpy_ref<>.
1076 (print_string_repr): Adjust.
1077 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
1078 * python/python-internal.h (apply_varobj_pretty_printer): Return
1079 gdbpy_ref<>.
1080 * varobj.c (varobj_value_get_print_value): Adjust.
1081
1082 2018-09-08 Tom Tromey <tom@tromey.com>
1083
1084 PR python/16047:
1085 * python/py-prettyprint.c (pretty_print_one_value): Check for
1086 to_string method.
1087
1088 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1089
1090 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
1091 replace_operator_with_call.
1092
1093 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1094
1095 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
1096
1097 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1098
1099 * ada-typeprint.c (print_range): Print the bounds using TYPE
1100 rather than its TYPE_TARGET_TYPE.
1101
1102 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1103
1104 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
1105 call to ada_to_fixed_value_create.
1106
1107 2018-09-08 Jerome Guitton <guitton@adacore.com>
1108
1109 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
1110
1111 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1112
1113 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
1114 by calls to error.
1115
1116 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1117
1118 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
1119 Move update of loop variable "fi".
1120
1121 2018-09-08 Joel Brobecker <brobecker@adacore.com>
1122
1123 * ada-lang.c (value_assign_to_component): In the case of
1124 big-endian targets, extract the bits of the given VAL
1125 using an src_offset of zero if container is not a scalar.
1126
1127 2018-09-06 Simon Ser <contact@emersion.fr>
1128
1129 PR gdb/23105
1130 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
1131 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1132 * fbsd-tdep.c (fbsd_make_note_desc): New.
1133 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
1134 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
1135 * target.h (enum target_object) Add FreeBSD-specific
1136 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
1137
1138 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1139
1140 * compile/compile-c.h (generate_c_for_variable_locations):
1141 Change reference to pointer.
1142 * compile/compile-c-support.c (compile_program) <compute>:
1143 Likewise.
1144 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
1145 (generate_c_for_for_one_variable): Likewise
1146 (generate_c_for_variable_locations): Likewise
1147 * compile/compile-c-types.c (compile_c_instance::convert_type):
1148 Likewise
1149 * compile/compile-cplus-symbols.c (convert_one_symbol):
1150 std::move the scope passed to enter_scope.
1151 * compile/compile-cplus-types.c
1152 (compile_cplus_instance::enter_scope): Make parameter
1153 rvalue-reference.
1154 (compile_cplus_instance::new_scope): Change reference to
1155 pointer.
1156 (compile_cplus_instance::convert_type): Likewise
1157 (compile_cplus_convert_typedef): std::move the scope passed to
1158 enter_scope.
1159 (compile_cplus_convert_struct_or_union): Likewise.
1160 (compile_cplus_convert_enum): Likewise.
1161 (compile_cplus_convert_namespace): Likewise.
1162 * compile/compile-cplus.h (compile_cplus_instance)
1163 <enter_scope>: Make parameter rvalue-reference.
1164 * compile/compile-internal.h (compile_instance)
1165 <get_cached_type>: Likewise
1166 * compile/compile-loc2c.c (push): Likewise
1167 (pushf): Likewise
1168 (unary): Likewise
1169 (binary): Likewise
1170 (print_label): Likewise
1171 (pushf_register_address): Likewise
1172 (pushf_register): Likewise
1173 (do_compile_dwarf_expr_to_c): Likewise
1174 (compile_dwarf_expr_to_c): Likewise
1175 (compile_dwarf_bounds_to_c): Likewise
1176 * compile/compile.c (compile_instance::get_cached_type):
1177 Likewise
1178 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
1179 (compile_dwarf_bounds_to_c): Likewise
1180 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
1181 (dwarf2_compile_property_to_c): Likewise
1182 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
1183 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
1184 Likewise
1185
1186 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1187
1188 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
1189 * tui/tui-data.c (init_content_element): Don't initialize it.
1190
1191 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
1192
1193 * tui/tui-data.h (struct tui_win_info)
1194 <detail::opaque>: Remove.
1195 * tui/tui-data.c (init_win_info): Remove assignment.
1196
1197 2018-09-05 Tom Tromey <tom@tromey.com>
1198
1199 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
1200 -Wformat-nonliteral.
1201 * target-float.c (host_float_ops<T>::to_string)
1202 (host_float_ops<T>::from_string): Use
1203 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1204 * configure: Rebuild.
1205
1206 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
1207
1208 * printcmd.c (printf_c_string): Use
1209 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
1210 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
1211
1212 2018-09-05 Tom Tromey <tom@tromey.com>
1213
1214 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
1215
1216 2018-09-05 Tom de Vries <tdevries@suse.de>
1217
1218 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
1219 with resolve_abstract_p == true.
1220 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
1221 defaulting to false. Propagate resolve_abstract_p to
1222 dwarf2_fetch_die_loc_sect_off.
1223 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
1224 parameter, defaulting to false.
1225 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
1226 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
1227 parameter.
1228 * dwarf2read.h (struct die_info): Forward-declare.
1229 (die_info_ptr): New typedef.
1230 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
1231
1232 2018-09-05 Joel Brobecker <brobecker@adacore.com>
1233
1234 GDB 8.2 released.
1235
1236 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
1237 Pedro Alves <palves@redhat.com>
1238
1239 * gnulib/Makefile.in (aclocal_m4_deps): Move to
1240 "aclocal-m4-deps.mk". Include file here.
1241 $(srcdir)/aclocal.m4: Add "configure.ac".
1242 * gnulib/aclocal-m4-deps.mk: New file.
1243 * gnulib/update-gnulib.sh: Automatically update
1244 "aclocal-m4-deps.mk".
1245
1246 2018-09-04 Tom Tromey <tom@tromey.com>
1247
1248 * configure: Rebuild.
1249 * configure.ac: Remove multi-ice code.
1250
1251 2018-09-04 Tom Tromey <tom@tromey.com>
1252
1253 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
1254 (ada-exp.o): Update.
1255
1256 2018-09-04 Tom Tromey <tom@tromey.com>
1257
1258 * Makefile.in (printcmd.o, target-float.o): Remove.
1259 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
1260
1261 2018-09-04 Tom Tromey <tom@tromey.com>
1262
1263 * gnulib/Makefile.in: Remove obsolete comment.
1264 * Makefile.in: Remove obsolete comment.
1265
1266 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
1267
1268 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
1269 line with '+'.
1270
1271 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1272
1273 * riscv-tdep.c: Add 'prologue-value.h' include.
1274 (struct riscv_unwind_cache): New struct.
1275 (riscv_debug_unwinder): New global.
1276 (riscv_scan_prologue): Update arguments, capture register details
1277 from prologue scan.
1278 (riscv_skip_prologue): Reformat arguments line, move end of
1279 prologue calculation into riscv_scan_prologue.
1280 (riscv_frame_cache): Update return type, create
1281 riscv_unwind_cache, scan the prologue, and fill in remaining cache
1282 details.
1283 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
1284 (riscv_frame_prev_register): Use the trad_frame within the
1285 riscv_unwind_cache.
1286 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
1287 flag.
1288
1289 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
1290
1291 * trad-frame.h (trad_frame_set_realreg): Declare.
1292 (trad_frame_set_addr): Declare.
1293 * trad-frame.c (trad_frame_set_realreg): Define new function.
1294 (trad_frame_set_addr): Define new function.
1295 (trad_frame_set_reg_realreg): Use new function.
1296 (trad_frame_set_reg_addr): Use new function.
1297
1298 2018-09-01 Keith Seitz <keiths@redhat.com>
1299
1300 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
1301 pulongest instead of "%lld".
1302 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
1303 ATTRIBUTE_UNUSED.
1304
1305 2018-08-31 Tom Tromey <tom@tromey.com>
1306
1307 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
1308 variant part type.
1309
1310 2018-08-31 Pedro Alves <palves@redhat.com>
1311
1312 * gdbarch.h: Regenerate.
1313
1314 2018-08-31 Pedro Alves <palves@redhat.com>
1315
1316 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
1317 * target.h (Hardware watchpoint interfaces): Describe
1318 continuable/steppable/non-steppable watchpoints.
1319 * gdbarch.h, gdbarch.c: Regenerate.
1320
1321 2018-08-31 Pedro Alves <palves@redhat.com>
1322
1323 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
1324 Delete.
1325 * s390-linux-nat.c
1326 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
1327 * target.h (target_ops::have_continuable_watchpoint): Delete.
1328 (target_have_continuable_watchpoint): Delete.
1329 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
1330 * target-delegates.c: Regenerate.
1331
1332 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1333
1334 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
1335 the files present in "gnulib/import/m4/".
1336
1337 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1338
1339 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
1340 c.sw, c.swsp, and c.sdsp.
1341
1342 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
1343
1344 * riscv-tdep.c (struct riscv_inferior_data): Delete.
1345 (riscv_read_misa_reg): Don't cache value read into inferior data.
1346 (riscv_new_inferior_data): Delete.
1347 (riscv_inferior_data_cleanup): Delete.
1348 (riscv_inferior_data): Delete.
1349 (riscv_invalidate_inferior_data): Delete.
1350 (_initialize_riscv_tdep): Remove initialisation of inferior data.
1351
1352 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
1353
1354 * compile/compile-cplus-types.c
1355 (compile_cplus_instance::leave_scope): Take the address of scope
1356 object.
1357 (compile_cplus_instance::convert_qualified_base): Compare quals
1358 to 0.
1359
1360 2018-08-30 Keith Seitz <keiths@redhat.com>
1361
1362 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
1363 Use "%s" and host_address_to_string instead of "%p" in printf.
1364
1365 2018-08-29 Keith Seitz <keiths@redhat.com>
1366
1367 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
1368 and compile-cplus-types.c.
1369 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
1370 * c-lang.c (cplus_language_defn): Set C++ compile functions.
1371 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
1372 Declare.
1373 * compile/compile-c-support.c: Include compile-cplus.h.
1374 (load_libcompile): Templatize.
1375 (get_compile_context): "New" function.
1376 (c_get_compile_context): Use get_compile_context.
1377 (cplus_get_compile_context): New function.
1378 (cplus_push_user_expression, cplus_pop_user_expression)
1379 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
1380 (cplus_compute_program): Define new structs/functions.
1381 * compile/compile-cplus-symmbols.c: New file.
1382 * compile/compile-cplus-types.c: New file.
1383 * compile/compile-cplus.h: New file.
1384 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
1385 Declare.
1386 * compile/compile-object-load.c (get_out_value_type): Use
1387 strncmp_iw when comparing symbol names.
1388 (compile_object_load): Add mst_bss and mst_data.
1389 * compile/compile.c (_initialize_compile): Remove
1390 -Wno-implicit-function-declaration from `compile_args'.
1391 * compile/gcc-cp-plugin.h: New file.
1392 * NEWS: Mention C++ compile support and new debug options.
1393
1394 2018-08-29 Keith Seitz <keiths@redhat.com>
1395
1396 * linespec.c (collect_info::add_symbol): Make virtual.
1397 (struct symbol_searcher_collect_info): New struct.
1398 (symbol_searcher::find_all_symbols): New method.
1399 * symtab.h (class symbol_searcher): New class.
1400
1401 2018-08-29 Keith Seitz <keiths@redhat.com>
1402
1403 * linespec.c (struct linespec) <function_symbols, label_symbols>:
1404 Change to vector of block_symbol. Update all users.
1405 (struct collect_info) <symbols>: Likewise.
1406 (collect_info::add_symbol): Take block_symbol as argument.
1407 Update all callers.
1408 (decode_compound_collector) <m_symbols>: Change type to vector
1409 of block_symbol. Update all users.
1410 (decode_compound_collector::operator ()): Change parameter type
1411 to block_symbol.
1412 (find_method, find_function_symbols, find_linespec_symbols)
1413 (find_label_symbols_in_block, find_label_symbols): Change symbol
1414 vectors to block_symbol vectors.
1415 * symtab.h (symbol_found_callback_ftype): Change parameter type to
1416 block_symbol.
1417
1418 2018-08-29 Keith Seitz <keiths@redhat.com>
1419
1420 * linespec.c (symbolp): Remove typedef and VEC definitions.
1421 (bound_minimal_symbol_d): Likewise.
1422
1423 2018-08-29 Keith Seitz <keiths@redhat.com>
1424
1425 * linespec.c (decode_compound_collector::decode_compound_collector):
1426 Remove initialization for `m_symtabs'.
1427 (decode_compound_collector::release_symbols): Change return type
1428 to std::vector. Update all callers.
1429 (class decode_compound_collector) <m_symbols>: Change type to
1430 std::vector.
1431 (lookup_prefix_sym): Change return type to std::vector. Update all
1432 callers.
1433 (compare_symbols): Remove.
1434 (std_compare_symbols): Rename to `compare_symbols'.
1435 (find_method): Change `sym_classes' parameter to std::vector.
1436 Update all callers. Use std::sort to sort sym_classes.
1437 (find_linespec_symbols): Remove cleanup.
1438
1439 2018-08-29 Keith Seitz <keiths@redhat.com>
1440
1441 * linespec.c (struct linespec) <minimal_symbols>: Change type to
1442 std::vector. Update all users.
1443 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
1444 (struct collect_info) <minimal_symbols>: Likewise.
1445 (compare_msymbols): Return bool. Change parameters to const
1446 bound_minimal_symbol references.
1447 (find_method, find_function_symbols, find_linespec_symbols): Change
1448 `minsyms' parameter to std::vector. Update all callers.
1449
1450 2018-08-29 Keith Seitz <keiths@redhat.com>
1451
1452 * linespec.c (struct linespec) <label_symbols>: Change type to
1453 std::vector. Update all users.
1454 (find_label_symbols_in_block): Change `result' parameter to
1455 std::vector. Update all callers.
1456 (find_label_symbols): Return std::vector. Update all callers.
1457
1458 2018-08-29 Keith Seitz <keiths@redhat.com>
1459
1460 * linespec.c (struct linespec) <function_symbols>: Change type to
1461 std::vector. Update all users.
1462 (struct collect_info) <function_symbols>: Likewise.
1463 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
1464 (std_compare_symbols): New function.
1465 (find_method, find_function_symbols, find_linespec_symbols)
1466 (find_label_symbols_in_block): Change `symbols' parameter to
1467 std::vector. Update all callers.
1468 (find_label_symbols): Likewise for `function_symbols' and
1469 `label_funcs_ret'.
1470
1471 2018-08-29 Keith Seitz <keiths@redhat.com>
1472
1473 * linespec.c (symtab_vector_up): Define.
1474 (struct linespec) <file_symtabs>: Change type to std::vector *.
1475 Update all uses.
1476 (struct collect_info) <file_symtabs>: Likewise.
1477 (collect_symtabs_from_filename): Return symtab_vector_up.
1478 Update all callers.
1479 (decode_objc): Remove cleanup.
1480 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
1481 (symtab_collector::release_symtabs): Return symtab_vector_up.
1482 Update all callers.
1483 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
1484 Update all users.
1485 (collect_symtabs_from_filename, symtabs_from_filename): Return
1486 symtab_vector_up. Update all callers.
1487
1488 2018-08-29 Tom Tromey <tom@tromey.com>
1489
1490 * csky-tdep.c (csky_analyze_prologue): Use
1491 core_addr_to_string_nz.
1492
1493 2018-08-29 Tom Tromey <tom@tromey.com>
1494
1495 * windows-nat.c (struct xlate_exception) <them>: Change type to
1496 DWORD.
1497 (xlate): Fix formatting. Remove last entry.
1498 (struct xlate_exception, xlate): Comment out.
1499 (windows_nat_target::resume): Use ranged for.
1500
1501 2018-08-29 Jim Wilson <jimw@sifive.com>
1502
1503 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
1504 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
1505 of NT_PRFPREG.
1506 (riscv_linux_nat_target::store_registers): Likewise.
1507
1508 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1509
1510 PR gdb/23555
1511 PR gdb/23558
1512 * gnulib/aclocal.m4: Regenerate.
1513 * gnulib/config.in: Regenerate.
1514 * gnulib/configure: Regenerate.
1515 * gnulib/import/Makefile.am: Update.
1516 * gnulib/import/Makefile.in: Update.
1517 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1518 * gnulib/import/_Noreturn.h: ... this.
1519 * gnulib/import/alloca.in.h: Update.
1520 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1521 * gnulib/import/arg-nonnull.h: ... this.
1522 * gnulib/import/assure.h: Update.
1523 * gnulib/import/at-func.c: Update.
1524 * gnulib/import/basename-lgpl.c: Update.
1525 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1526 * gnulib/import/c++defs.h: ... this.
1527 * gnulib/import/canonicalize-lgpl.c: Update.
1528 * gnulib/import/cdefs.h: Update.
1529 * gnulib/import/chdir-long.c: Update.
1530 * gnulib/import/chdir-long.h: Update.
1531 * gnulib/import/cloexec.c: Update.
1532 * gnulib/import/cloexec.h: Update.
1533 * gnulib/import/close.c: Update.
1534 * gnulib/import/closedir.c: Update.
1535 * gnulib/import/config.charset: Update.
1536 * gnulib/import/dirent-private.h: Update.
1537 * gnulib/import/dirent.in.h: Update.
1538 * gnulib/import/dirfd.c: Update.
1539 * gnulib/import/dirname-lgpl.c: Update.
1540 * gnulib/import/dirname.h: Update.
1541 * gnulib/import/dosname.h: Update.
1542 * gnulib/import/dup-safer-flag.c: Update.
1543 * gnulib/import/dup-safer.c: Update.
1544 * gnulib/import/dup.c: Update.
1545 * gnulib/import/dup2.c: Update.
1546 * gnulib/import/errno.in.h: Update.
1547 * gnulib/import/error.c: Update.
1548 * gnulib/import/error.h: Update.
1549 * gnulib/import/exitfail.c: Update.
1550 * gnulib/import/exitfail.h: Update.
1551 * gnulib/import/extra/update-copyright: Update.
1552 * gnulib/import/fchdir.c: Update.
1553 * gnulib/import/fcntl.c: Update.
1554 * gnulib/import/fcntl.in.h: Update.
1555 * gnulib/import/fd-hook.c: Update.
1556 * gnulib/import/fd-hook.h: Update.
1557 * gnulib/import/fd-safer-flag.c: Update.
1558 * gnulib/import/fd-safer.c: Update.
1559 * gnulib/import/fdopendir.c: Update.
1560 * gnulib/import/filename.h: Update.
1561 * gnulib/import/filenamecat-lgpl.c: Update.
1562 * gnulib/import/filenamecat.h: Update.
1563 * gnulib/import/flexmember.h: Update.
1564 * gnulib/import/float+.h: Update.
1565 * gnulib/import/float.c: Update.
1566 * gnulib/import/float.in.h: Update.
1567 * gnulib/import/fnmatch.c: Update.
1568 * gnulib/import/fnmatch.in.h: Update.
1569 * gnulib/import/fnmatch_loop.c: Update.
1570 * gnulib/import/fpucw.h: Update.
1571 * gnulib/import/frexp.c: Update.
1572 * gnulib/import/frexpl.c: Update.
1573 * gnulib/import/fstat.c: Update.
1574 * gnulib/import/fstatat.c: Update.
1575 * gnulib/import/getcwd-lgpl.c: Update.
1576 * gnulib/import/getcwd.c: Update.
1577 * gnulib/import/getdtablesize.c: Update.
1578 * gnulib/import/getlogin_r.c: Update.
1579 * gnulib/import/getprogname.c: Update.
1580 * gnulib/import/getprogname.h: Update.
1581 * gnulib/import/gettext.h: Update.
1582 * gnulib/import/gettimeofday.c: Update.
1583 * gnulib/import/glob-libc.h: Update.
1584 * gnulib/import/glob.c: Update.
1585 * gnulib/import/glob.in.h: Update.
1586 * gnulib/import/glob_internal.h: Update.
1587 * gnulib/import/glob_pattern_p.c: Update.
1588 * gnulib/import/globfree.c: Update.
1589 * gnulib/import/hard-locale.c: Update.
1590 * gnulib/import/hard-locale.h: Update.
1591 * gnulib/import/intprops.h: Update.
1592 * gnulib/import/inttypes.in.h: Update.
1593 * gnulib/import/isnan.c: Update.
1594 * gnulib/import/isnand-nolibm.h: Update.
1595 * gnulib/import/isnand.c: Update.
1596 * gnulib/import/isnanl-nolibm.h: Update.
1597 * gnulib/import/isnanl.c: Update.
1598 * gnulib/import/itold.c: Update.
1599 * gnulib/import/libc-config.h: Update.
1600 * gnulib/import/limits.in.h: Update.
1601 * gnulib/import/localcharset.c: Update.
1602 * gnulib/import/localcharset.h: Update.
1603 * gnulib/import/localtime-buffer.c: Update.
1604 * gnulib/import/localtime-buffer.h: Update.
1605 * gnulib/import/lstat.c: Update.
1606 * gnulib/import/m4/00gnulib.m4: Update.
1607 * gnulib/import/m4/__inline.m4: Update.
1608 * gnulib/import/m4/absolute-header.m4: Update.
1609 * gnulib/import/m4/alloca.m4: Update.
1610 * gnulib/import/m4/builtin-expect.m4: Update.
1611 * gnulib/import/m4/canonicalize.m4: Update.
1612 * gnulib/import/m4/chdir-long.m4: Update.
1613 * gnulib/import/m4/close.m4: Update.
1614 * gnulib/import/m4/closedir.m4: Update.
1615 * gnulib/import/m4/configmake.m4: Update.
1616 * gnulib/import/m4/d-ino.m4: Update.
1617 * gnulib/import/m4/d-type.m4: Update.
1618 * gnulib/import/m4/dirent_h.m4: Update.
1619 * gnulib/import/m4/dirfd.m4: Update.
1620 * gnulib/import/m4/dirname.m4: Update.
1621 * gnulib/import/m4/double-slash-root.m4: Update.
1622 * gnulib/import/m4/dup.m4: Update.
1623 * gnulib/import/m4/dup2.m4: Update.
1624 * gnulib/import/m4/eealloc.m4: Update.
1625 * gnulib/import/m4/environ.m4: Update.
1626 * gnulib/import/m4/errno_h.m4: Update.
1627 * gnulib/import/m4/error.m4: Update.
1628 * gnulib/import/m4/exponentd.m4: Update.
1629 * gnulib/import/m4/exponentl.m4: Update.
1630 * gnulib/import/m4/extensions.m4: Update.
1631 * gnulib/import/m4/extern-inline.m4: Update.
1632 * gnulib/import/m4/fchdir.m4: Update.
1633 * gnulib/import/m4/fcntl-o.m4: Update.
1634 * gnulib/import/m4/fcntl.m4: Update.
1635 * gnulib/import/m4/fcntl_h.m4: Update.
1636 * gnulib/import/m4/fdopendir.m4: Update.
1637 * gnulib/import/m4/filenamecat.m4: Update.
1638 * gnulib/import/m4/flexmember.m4: Update.
1639 * gnulib/import/m4/float_h.m4: Update.
1640 * gnulib/import/m4/fnmatch.m4: Update.
1641 * gnulib/import/m4/fnmatch_h.m4: Update.
1642 * gnulib/import/m4/fpieee.m4: Update.
1643 * gnulib/import/m4/frexp.m4: Update.
1644 * gnulib/import/m4/frexpl.m4: Update.
1645 * gnulib/import/m4/fstat.m4: Update.
1646 * gnulib/import/m4/fstatat.m4: Update.
1647 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1648 * gnulib/import/m4/getcwd-path-max.m4: Update.
1649 * gnulib/import/m4/getcwd.m4: Update.
1650 * gnulib/import/m4/getdtablesize.m4: Update.
1651 * gnulib/import/m4/getlogin.m4: Update.
1652 * gnulib/import/m4/getlogin_r.m4: Update.
1653 * gnulib/import/m4/getpagesize.m4: Update.
1654 * gnulib/import/m4/getprogname.m4: Update.
1655 * gnulib/import/m4/gettimeofday.m4: Update.
1656 * gnulib/import/m4/glibc21.m4: Update.
1657 * gnulib/import/m4/glob.m4: Update.
1658 * gnulib/import/m4/glob_h.m4: Update.
1659 * gnulib/import/m4/gnulib-cache.m4: Update.
1660 * gnulib/import/m4/gnulib-common.m4: Update.
1661 * gnulib/import/m4/gnulib-comp.m4: Update.
1662 * gnulib/import/m4/gnulib-tool.m4: Update.
1663 * gnulib/import/m4/hard-locale.m4: Update.
1664 * gnulib/import/m4/include_next.m4: Update.
1665 * gnulib/import/m4/inttypes-pri.m4: Update.
1666 * gnulib/import/m4/inttypes.m4: Update.
1667 * gnulib/import/m4/isnand.m4: Update.
1668 * gnulib/import/m4/isnanl.m4: Update.
1669 * gnulib/import/m4/largefile.m4: Update.
1670 * gnulib/import/m4/limits-h.m4: Update.
1671 * gnulib/import/m4/localcharset.m4: Update.
1672 * gnulib/import/m4/locale-fr.m4: Update.
1673 * gnulib/import/m4/locale-ja.m4: Update.
1674 * gnulib/import/m4/locale-zh.m4: Update.
1675 * gnulib/import/m4/localtime-buffer.m4: Update.
1676 * gnulib/import/m4/longlong.m4: Update.
1677 * gnulib/import/m4/lstat.m4: Update.
1678 * gnulib/import/m4/malloc.m4: Update.
1679 * gnulib/import/m4/malloca.m4: Update.
1680 * gnulib/import/m4/math_h.m4: Update.
1681 * gnulib/import/m4/mbrtowc.m4: Update.
1682 * gnulib/import/m4/mbsinit.m4: Update.
1683 * gnulib/import/m4/mbsrtowcs.m4: Update.
1684 * gnulib/import/m4/mbstate_t.m4: Update.
1685 * gnulib/import/m4/memchr.m4: Update.
1686 * gnulib/import/m4/memmem.m4: Update.
1687 * gnulib/import/m4/mempcpy.m4: Update.
1688 * gnulib/import/m4/memrchr.m4: Update.
1689 * gnulib/import/m4/mkdir.m4: Update.
1690 * gnulib/import/m4/mkstemp.m4: Update.
1691 * gnulib/import/m4/mmap-anon.m4: Update.
1692 * gnulib/import/m4/mode_t.m4: Update.
1693 * gnulib/import/m4/msvc-inval.m4: Update.
1694 * gnulib/import/m4/msvc-nothrow.m4: Update.
1695 * gnulib/import/m4/multiarch.m4: Update.
1696 * gnulib/import/m4/nocrash.m4: Update.
1697 * gnulib/import/m4/off_t.m4: Update.
1698 * gnulib/import/m4/onceonly.m4: Update.
1699 * gnulib/import/m4/open-cloexec.m4: Update.
1700 * gnulib/import/m4/open.m4: Update.
1701 * gnulib/import/m4/openat.m4: Update.
1702 * gnulib/import/m4/opendir.m4: Update.
1703 * gnulib/import/m4/pathmax.m4: Update.
1704 * gnulib/import/m4/rawmemchr.m4: Update.
1705 * gnulib/import/m4/readdir.m4: Update.
1706 * gnulib/import/m4/readlink.m4: Update.
1707 * gnulib/import/m4/realloc.m4: Update.
1708 * gnulib/import/m4/rename.m4: Update.
1709 * gnulib/import/m4/rewinddir.m4: Update.
1710 * gnulib/import/m4/rmdir.m4: Update.
1711 * gnulib/import/m4/save-cwd.m4: Update.
1712 * gnulib/import/m4/secure_getenv.m4: Update.
1713 * gnulib/import/m4/setenv.m4: Update.
1714 * gnulib/import/m4/signal_h.m4: Update.
1715 * gnulib/import/m4/ssize_t.m4: Update.
1716 * gnulib/import/m4/stat-time.m4: Update.
1717 * gnulib/import/m4/stat.m4: Update.
1718 * gnulib/import/m4/std-gnu11.m4: Update.
1719 * gnulib/import/m4/stdbool.m4: Update.
1720 * gnulib/import/m4/stddef_h.m4: Update.
1721 * gnulib/import/m4/stdint.m4: Update.
1722 * gnulib/import/m4/stdio_h.m4: Update.
1723 * gnulib/import/m4/stdlib_h.m4: Update.
1724 * gnulib/import/m4/strchrnul.m4: Update.
1725 * gnulib/import/m4/strdup.m4: Update.
1726 * gnulib/import/m4/strerror.m4: Update.
1727 * gnulib/import/m4/string_h.m4: Update.
1728 * gnulib/import/m4/strstr.m4: Update.
1729 * gnulib/import/m4/strtok_r.m4: Update.
1730 * gnulib/import/m4/sys_socket_h.m4: Update.
1731 * gnulib/import/m4/sys_stat_h.m4: Update.
1732 * gnulib/import/m4/sys_time_h.m4: Update.
1733 * gnulib/import/m4/sys_types_h.m4: Update.
1734 * gnulib/import/m4/tempname.m4: Update.
1735 * gnulib/import/m4/time_h.m4: Update.
1736 * gnulib/import/m4/unistd-safer.m4: Update.
1737 * gnulib/import/m4/unistd_h.m4: Update.
1738 * gnulib/import/m4/warn-on-use.m4: Update.
1739 * gnulib/import/m4/wchar_h.m4: Update.
1740 * gnulib/import/m4/wchar_t.m4: Update.
1741 * gnulib/import/m4/wctype_h.m4: Update.
1742 * gnulib/import/m4/wint_t.m4: Update.
1743 * gnulib/import/malloc.c: Update.
1744 * gnulib/import/malloc/scratch_buffer.h: Update.
1745 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
1746 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
1747 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
1748 * gnulib/import/malloca.c: Update.
1749 * gnulib/import/malloca.h: Update.
1750 * gnulib/import/malloca.valgrind: Update.
1751 * gnulib/import/math.in.h: Update.
1752 * gnulib/import/mbrtowc.c: Update.
1753 * gnulib/import/mbsinit.c: Update.
1754 * gnulib/import/mbsrtowcs-impl.h: Update.
1755 * gnulib/import/mbsrtowcs-state.c: Update.
1756 * gnulib/import/mbsrtowcs.c: Update.
1757 * gnulib/import/memchr.c: Update.
1758 * gnulib/import/memmem.c: Update.
1759 * gnulib/import/mempcpy.c: Update.
1760 * gnulib/import/memrchr.c: Update.
1761 * gnulib/import/mkdir.c: Update.
1762 * gnulib/import/mkstemp.c: Update.
1763 * gnulib/import/msvc-inval.c: Update.
1764 * gnulib/import/msvc-inval.h: Update.
1765 * gnulib/import/msvc-nothrow.c: Update.
1766 * gnulib/import/msvc-nothrow.h: Update.
1767 * gnulib/import/open.c: Update.
1768 * gnulib/import/openat-die.c: Update.
1769 * gnulib/import/openat-priv.h: Update.
1770 * gnulib/import/openat-proc.c: Update.
1771 * gnulib/import/openat.c: Update.
1772 * gnulib/import/openat.h: Update.
1773 * gnulib/import/opendir.c: Update.
1774 * gnulib/import/pathmax.h: Update.
1775 * gnulib/import/pipe-safer.c: Update.
1776 * gnulib/import/rawmemchr.c: Update.
1777 * gnulib/import/readdir.c: Update.
1778 * gnulib/import/readlink.c: Update.
1779 * gnulib/import/realloc.c: Update.
1780 * gnulib/import/ref-add.sin: Update.
1781 * gnulib/import/ref-del.sin: Update.
1782 * gnulib/import/rename.c: Update.
1783 * gnulib/import/rewinddir.c: Update.
1784 * gnulib/import/rmdir.c: Update.
1785 * gnulib/import/same-inode.h: Update.
1786 * gnulib/import/save-cwd.c: Update.
1787 * gnulib/import/save-cwd.h: Update.
1788 * gnulib/import/scratch_buffer.h: Update.
1789 * gnulib/import/secure_getenv.c: Update.
1790 * gnulib/import/setenv.c: Update.
1791 * gnulib/import/signal.in.h: Update.
1792 * gnulib/import/stat-time.c: Update.
1793 * gnulib/import/stat-time.h: Update.
1794 * gnulib/import/stat-w32.c: Update.
1795 * gnulib/import/stat-w32.h: Update.
1796 * gnulib/import/stat.c: Update.
1797 * gnulib/import/stdbool.in.h: Update.
1798 * gnulib/import/stddef.in.h: Update.
1799 * gnulib/import/stdint.in.h: Update.
1800 * gnulib/import/stdio.in.h: Update.
1801 * gnulib/import/stdlib.in.h: Update.
1802 * gnulib/import/str-two-way.h: Update.
1803 * gnulib/import/strchrnul.c: Update.
1804 * gnulib/import/strdup.c: Update.
1805 * gnulib/import/streq.h: Update.
1806 * gnulib/import/strerror-override.c: Update.
1807 * gnulib/import/strerror-override.h: Update.
1808 * gnulib/import/strerror.c: Update.
1809 * gnulib/import/string.in.h: Update.
1810 * gnulib/import/stripslash.c: Update.
1811 * gnulib/import/strnlen1.c: Update.
1812 * gnulib/import/strnlen1.h: Update.
1813 * gnulib/import/strstr.c: Update.
1814 * gnulib/import/strtok_r.c: Update.
1815 * gnulib/import/sys_stat.in.h: Update.
1816 * gnulib/import/sys_time.in.h: Update.
1817 * gnulib/import/sys_types.in.h: Update.
1818 * gnulib/import/tempname.c: Update.
1819 * gnulib/import/tempname.h: Update.
1820 * gnulib/import/time.in.h: Update.
1821 * gnulib/import/unistd--.h: Update.
1822 * gnulib/import/unistd-safer.h: Update.
1823 * gnulib/import/unistd.in.h: Update.
1824 * gnulib/import/unsetenv.c: Update.
1825 * gnulib/import/verify.h: Update.
1826 * gnulib/import/extra/snippet/warn-on-use.h: Update.
1827 * gnulib/import/wchar.in.h: Update.
1828 * gnulib/import/wctype.in.h: Update.
1829 * gnulib/import/xalloc-oversized.h: Update.
1830 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
1831 "53e2c179f26a890fa6685af4b6c1397ee370433b".
1832
1833 2018-08-16 Gary Benson <gbenson@redhat.com>
1834
1835 PR gdb/13000:
1836 * gdb/main.c (captured_main_1): Exit with nonzero status
1837 in batch mode if the last command to be executed failed.
1838 * NEWS: Mention the above.
1839
1840 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
1841
1842 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
1843 end of warning message.
1844
1845 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1846
1847 PR gdb/22943:
1848 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
1849 (aarch64_extract_return_value): Use
1850 aapcs_is_vfp_call_or_return_candidate.
1851 (aarch64_return_in_memory): Likewise.
1852 (aarch64_store_return_value): Likewise.
1853
1854 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1855
1856 * aarch64-tdep.c
1857 (aapcs_is_vfp_call_or_return_candidate): Make static
1858 (pass_in_v_or_stack): Remove function.
1859 (pass_in_v_vfp_candidate): New function.
1860 (aarch64_push_dummy_call): Check for float register candidates.
1861
1862 2018-08-29 Alan Hayward <alan.hayward@arm.com>
1863
1864 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
1865 (aapcs_is_vfp_call_or_return_candidate_1): New function.
1866 (aapcs_is_vfp_call_or_return_candidate): Likewise.
1867
1868 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1869
1870 PR build/23399
1871 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
1872 (struct ipa_sym_addresses): Rename to...
1873 (struct ipa_sym_addresses_common): ... this.
1874 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
1875
1876 2018-08-28 Tom Tromey <tom@tromey.com>
1877
1878 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1879 (token_fifo): Now a std::vector.
1880 (yylex, c_parse): Update.
1881 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1882 (token_fifo): Now a std::vector.
1883 (yylex, d_parse): Update.
1884 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
1885 (token_fifo): Now a std::vector.
1886 (yylex, go_parse): Update.
1887
1888 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
1889
1890 * parser-defs.h (struct type_stack) <elements>: Change type to
1891 std::vector<union type_stack_elt>.
1892 <depth, size>: Remove.
1893 * parse.c (parse_exp_in_context_1): Adjust.
1894 (type_stack_reserve): Remove.
1895 (check_type_stack_depth): Remove.
1896 (insert_into_type_stack): Adjust to std::vector.
1897 (insert_type): Likewise.
1898 (push_type): Likewise.
1899 (push_type_int): Likewise.
1900 (insert_type_address_space): Likewise.
1901 (pop_type): Likewise.
1902 (pop_type_int): Likewise.
1903 (pop_typelist): Likewise.
1904 (pop_type_stack): Likewise.
1905 (append_type_stack): Likewise.
1906 (push_type_stack): Likewise.
1907 (get_type_stack): Likewise.
1908 (type_stack_cleanup): Likewise.
1909 (push_typelist): Likewise.
1910 (follow_types): Likewise.
1911 (_initialize_parse): Likewise.
1912
1913 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
1914
1915 * NEWS: Mention csky target.
1916
1917 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
1918 Hafiz Abid Qadeer <abidh@codesourcery.com>
1919 Don Breazeal <donb@codesourcery.com>
1920
1921 * csky-linux-tdep.c: New file.
1922 * csky-tdep.c: Likewise.
1923 * csky-tdep.h: Likewise.
1924 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
1925 csky-tdep.o.
1926 (HFILES_NO_SRCDIR): Add csky-tdep.h.
1927 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
1928 * configure.tgt: Add csky support.
1929
1930 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
1931
1932 * python/py-framefilter.c (py_print_frame): Print frame architecture
1933 when printing on an MI output.
1934
1935 2018-08-27 Tom Tromey <tom@tromey.com>
1936
1937 PR build/23087:
1938 * configure: Rebuild.
1939 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
1940
1941 2018-08-27 Tom Tromey <tom@tromey.com>
1942
1943 * aarch64-linux-tdep.c
1944 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
1945 casts to int.
1946
1947 2018-08-27 Tom Tromey <tom@tromey.com>
1948
1949 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
1950 unsigned.
1951 (ppc64_standard_linkage1, ppc64_standard_linkage2)
1952 (ppc64_standard_linkage3, ppc64_standard_linkage4)
1953 (ppc64_standard_linkage5, ppc64_standard_linkage6)
1954 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
1955 unsigned.
1956
1957 2018-08-27 Tom Tromey <tom@tromey.com>
1958
1959 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
1960 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
1961
1962 2018-08-27 Tom Tromey <tom@tromey.com>
1963
1964 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
1965 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
1966 ULONGEST_MAX.
1967 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
1968 ULONGEST_MAX.
1969 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
1970 ULONGEST_MAX.
1971 * sparc-linux-tdep.c (sparc32_linux_sigframe)
1972 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
1973 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
1974 ULONGEST_MAX.
1975 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
1976 (ppc64_linux_sigaction_tramp_frame)
1977 (ppc32_linux_sighandler_tramp_frame)
1978 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1979 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
1980 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
1981 * mn10300-linux-tdep.c (am33_linux_sigframe)
1982 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
1983 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
1984 * mips-linux-tdep.c (mips_linux_o32_sigframe)
1985 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
1986 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
1987 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
1988 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
1989 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
1990 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
1991 * microblaze-linux-tdep.c
1992 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
1993 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
1994 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
1995 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
1996 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
1997 * common/common-types.h (ULONGEST_MAX): New define.
1998 (CORE_ADDR_MAX): Fix formatting.
1999 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
2000 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
2001 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
2002 (arm_linux_rt_sigreturn_tramp_frame)
2003 (arm_eabi_linux_sigreturn_tramp_frame)
2004 (arm_eabi_linux_rt_sigreturn_tramp_frame)
2005 (thumb2_eabi_linux_sigreturn_tramp_frame)
2006 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
2007 (arm_linux_restart_syscall_tramp_frame)
2008 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
2009 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
2010 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
2011 ULONGEST_MAX.
2012 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
2013
2014 2018-08-27 Tom Tromey <tom@tromey.com>
2015
2016 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
2017 CORE_ADDR_MAX.
2018 * mips-tdep.c (mips_deal_with_atomic_sequence)
2019 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
2020 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
2021 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
2022 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
2023 CORE_ADDR_MAX.
2024 * aarch64-tdep.c (aarch64_software_single_step): Use
2025 CORE_ADDR_MAX.
2026
2027 2018-08-27 Tom Tromey <tom@tromey.com>
2028
2029 * linespec.c (complete_linespec_component): Add cast to "char".
2030 * completer.c (completion_tracker::build_completion_result): Add
2031 cast to "char".
2032
2033 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2034
2035 * solist.h (struct solist, struct target_so_ops): Fix
2036 indentation.
2037
2038 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2039
2040 * ada-tasks.c (ada_task_info_s): Remove typedef.
2041 (DEF_VEC_O(ada_task_info_s)): Remove.
2042 (struct ada_tasks_inferior_data): Initialize fields.
2043 <task_list>: Make an std::vector.
2044 (get_ada_tasks_inferior_data): Allocate with new.
2045 (ada_get_task_number): Adjust.
2046 (get_task_number_from_id): Likewise.
2047 (valid_task_id): Likewise.
2048 (ada_get_task_info_from_ptid): Likewise.
2049 (iterate_over_live_ada_tasks): Likewise.
2050 (add_ada_task): Likewise.
2051 (read_known_tasks): Likewise.
2052 (ada_build_task_list): Likewise.
2053 (print_ada_task_info): Likewise.
2054 (info_task): Likewise.
2055 (task_command_1): Likewise.
2056
2057 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
2058
2059 * ada-lang.c (add_angle_brackets): Return std::string.
2060
2061 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
2062
2063 * python/py-threadevent.c (py_get_event_thread): Initialize
2064 pythread.
2065
2066 2018-08-24 Pedro Alves <palves@redhat.com>
2067
2068 * python/py-bpevent.c (create_breakpoint_event_object): Use
2069 copy-initialization.
2070 * python/py-continueevent.c (emit_continue_event): Use
2071 copy-initialization.
2072 * python/py-exitedevent.c (create_exited_event_object): Return a
2073 gdbpy_ref<>.
2074 (emit_exited_event): Use copy-initialization.
2075 * python/py-inferior.c (python_new_inferior)
2076 (python_inferior_deleted, add_thread_object): Use
2077 copy-initialization.
2078 * python/py-infevents.c (create_inferior_call_event_object)
2079 (create_register_changed_event_object)
2080 (create_memory_changed_event_object): Return a gdbpy_ref<>.
2081 (emit_inferior_call_event, emit_memory_changed_event)
2082 (emit_register_changed_event): Use copy-initialization.
2083 * python/py-newobjfileevent.c (create_new_objfile_event_object):
2084 Return a gdbpy_ref<>.
2085 (emit_new_objfile_event): Use copy-initialization.
2086 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
2087 (emit_clear_objfiles_event): Use copy-initialization.
2088 * python/py-signalevent.c (create_signal_event_object): Use
2089 copy-initialization.
2090 * python/py-threadevent.c (create_thread_event_object): Use
2091 copy-initialization.
2092
2093 2018-08-24 Pedro Alves <palves@redhat.com>
2094 Simon Marchi <simon.marchi@ericsson.com>
2095
2096 PR gdb/23379
2097 * python/py-continueevent.c: Include "gdbthread.h".
2098 (create_continue_event_object): Add intro comment. Add 'ptid'
2099 parameter. Use it to find thread to pass to
2100 create_thread_event_object.
2101 (emit_continue_event): Pass PTID down to
2102 create_continue_event_object.
2103 * python/py-event.h (py_get_event_thread): Declare.
2104 (create_thread_event_object): Remove default from 'thread'
2105 parameter.
2106 * python/py-stopevent.c (create_stop_event_object): Use
2107 py_get_event_thread.
2108 * python/py-threadevent.c (get_event_thread): Rename to ...
2109 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
2110 and use it to find the thread.
2111 (create_thread_event_object): Assert that THREAD isn't null.
2112 Don't find the event thread here.
2113
2114 2018-08-23 Kevin Buettner <kevinb@redhat.com>
2115
2116 * block.h (blockrange, blockranges): New struct declarations.
2117 (struct block): Add new field named `ranges'.
2118 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
2119 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
2120 macros for accessing ranges in struct block.
2121 (make_blockranges): New declaration.
2122 block.c (make_blockranges): New function.
2123 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
2124 for block.
2125 * symtab.h (find_pc_partial_function): Add new parameter `block'.
2126 * blockframe.c (cache_pc_function_block): New static global.
2127 (clear_pc_function_cache): Clear cache_pc_function_block.
2128 (find_pc_partial_function): Move comment to symtab.h. Add
2129 support for non-contiguous blocks.
2130 * cli/cli-cmds.c (block.h): Include.
2131 (print_disassembly): Handle printing of non-contiguous blocks.
2132 (disassemble_current_function): Likewise.
2133 (disassemble_command): Likewise.
2134
2135 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
2136 BLOCK_START.
2137 * blockframe.c (get_pc_function_start): Likewise.
2138 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
2139 (gcc_symbol_address): Likewise.
2140 * compile/compile-object-run.c (compile_object_run): Likewise.
2141 * compile/compile.c (get_expr_block_and_pc): Likewise.
2142 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
2143 (func_addr_to_tail_call_list): Likewise.
2144 * findvar.c (default_read_var_value): Likewise.
2145 * inline-frame.c (inline_frame_this_id): Likewise.
2146 (skip-inline_frames): Likewise.
2147 * infcmd.c (until_next_command): Likewise.
2148 * linespec.c (convert_linespec_to_sals): Likewise.
2149 * parse.c (parse_exp_in_context_1): Likewise.
2150 * printcmd.c (build_address_symbolic): likewise.
2151 (info_address_command): Likewise.
2152 symtab.c (find_function_start_sal): Likewise.
2153 (skip_prologue_sal): Likewise.
2154 (find_function_alias_target): Likewise.
2155 (find_gnu_ifunc): Likewise.
2156 * stack.c (find_frame_funname): Likewise.
2157 * symtab.c (fixup_symbol_section): Likewise.
2158 (find_function_start_sal): Likewise.
2159 (skip_prologue_sal): Likewsie.
2160 (find_function_alias_target): Likewise.
2161 (find_gnu_ifunc): Likewise.
2162 * tracepoint.c (info_scope_command): Likewise.
2163 * value.c (value_fn_field): Likewise.
2164
2165 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
2166 in place of find_pc_partial_function.
2167 * blockframe.c (find_function_entry_range_from_pc): New function.
2168 * symtab.h (find_function_entry_range_from_pc): Declare and document.
2169 * objfiles.c (objfile_relocate1): Relocate start and end addresses
2170 for each range in a block.
2171
2172
2173 2018-08-23 Xavier Roirand <roirand@adacore.com>
2174
2175 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
2176 incrementation.
2177
2178 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2179
2180 * solib-svr4.c (read_program_headers_from_bfd): Return
2181 gdb::optional<gdb::byte_vector>.
2182 (svr4_exec_displacement): Adjust.
2183
2184 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2185
2186 * solib-svr4.c (read_program_header): Return
2187 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
2188 (find_program_interpreter): Return
2189 gdb::optional<gdb::byte_vector>.
2190 (scan_dyntag_auxv): Adjust.
2191 (enable_break): Adjust.
2192 (svr4_exec_displacement): Adjust.
2193
2194 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2195
2196 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
2197 * inf-child.c (inf_child_target::terminal_save_inferior): New.
2198
2199 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
2200
2201 * guile/scm-string.c (gdbscm_scm_from_printf): Use
2202 string_vprintf.
2203 * guile/scm-utils.c (gdbscm_printf): Likewise.
2204 * serial.c (serial_printf): Likewise.
2205 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
2206
2207 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
2208
2209 * stack.c (print_frame): Print frame architecture when printing on
2210 an MI output.
2211 * NEWS: Mention new "arch" attribute in frame output.
2212
2213 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2214
2215 * arch/aarch64.h (aarch64_regnum): Update comment.
2216
2217 2018-08-21 Alan Hayward <alan.hayward@arm.com>
2218
2219 * NEWS: Add SVE to 8.2 section.
2220
2221 2018-08-21 Pedro Alves <palves@redhat.com>
2222
2223 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
2224 out from gdbscm_parse_function_args.
2225 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
2226 gdbscm_parse_function_args_1.
2227
2228 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
2229
2230 PR gdb/17816
2231 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
2232 operator.
2233
2234 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
2235
2236 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
2237
2238 2018-08-19 Michael Spang <spang@google.com>
2239
2240 PR gdb/11786
2241 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
2242 for PT_TLS segments.
2243
2244 2018-08-18 Kevin Buettner <kevinb@redhat.com>
2245
2246 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
2247 dwarf_variable_value.
2248 * dwarf2-frame.c (class dwarf_expr_executor):
2249 Add override for dwarf_variable_value.
2250 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
2251 (class symbol_needs_eval_context): Likewise.
2252 (indirect_synthetic_pointer): Add forward declaration.
2253 (sect_variable_value): New function.
2254 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
2255 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
2256 for DW_OP_GNU_variable_value.
2257
2258 2018-08-16 Tom Tromey <tom@tromey.com>
2259
2260 * top.c (read_command_file): Update.
2261 (command_line_input): Remove "repeat" argument.
2262 * ada-lang.c (get_selections): Update.
2263 * linespec.c (decode_line_2): Update.
2264 * defs.h (command_line_input): Remove argument.
2265 * cli/cli-script.c (read_next_line): Update.
2266 * python/py-gdb-readline.c: Update.
2267
2268 2018-08-17 Tom Tromey <tom@tromey.com>
2269
2270 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
2271 command_line_input.
2272
2273 2018-08-15 Tom Tromey <tom@tromey.com>
2274
2275 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
2276
2277 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
2278
2279 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
2280 If used, use find_pc_partial_function to find address range
2281 to disassemble.
2282 * mi/mi-main.c (mi_cmd_list_features): Report
2283 "data-disassemble-a-option" feature.
2284 * NEWS: Mention new -data-disassemble option -a.
2285
2286 2018-08-13 Tom Tromey <tom@tromey.com>
2287
2288 * common/common-defs.h (_FORTIFY_SOURCE): Define.
2289
2290 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2291
2292 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
2293 (aarch64_linux_collect_sve_regset): Likewise.
2294 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
2295 * regcache.h (regcache_map_entry_size): New function.
2296
2297 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2298
2299 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
2300 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
2301 (SVE_HEADER_VL_LENGTH): Likewise.
2302 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
2303 (SVE_HEADER_FLAGS_LENGTH): Likewise.
2304 (SVE_HEADER_RESERVED_LENGTH): Likewise.
2305 (SVE_HEADER_SIZE_OFFSET): Likewise.
2306 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
2307 (SVE_HEADER_VL_OFFSET): Likewise.
2308 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
2309 (SVE_HEADER_FLAGS_OFFSET): Likewise.
2310 (SVE_HEADER_RESERVED_OFFSET): Likewise.
2311 (SVE_HEADER_SIZE): Likewise.
2312 (aarch64_linux_core_read_vq): Add function.
2313 (aarch64_linux_core_read_description): Check for SVE section.
2314
2315 2018-08-13 Alan Hayward <alan.hayward@arm.com>
2316
2317 * aarch64-fbsd-tdep.c
2318 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
2319 collect_size.
2320 * aarch64-linux-tdep.c
2321 (aarch64_linux_iterate_over_regset_sections): Likewise.
2322 * alpha-linux-tdep.c
2323 (alpha_linux_iterate_over_regset_sections):
2324 * alpha-nbsd-tdep.c
2325 (alphanbsd_iterate_over_regset_sections): Likewise.
2326 * amd64-fbsd-tdep.c
2327 (amd64fbsd_iterate_over_regset_sections): Likewise.
2328 * amd64-linux-tdep.c
2329 (amd64_linux_iterate_over_regset_sections): Likewise.
2330 * arm-bsd-tdep.c
2331 (armbsd_iterate_over_regset_sections): Likewise.
2332 * arm-fbsd-tdep.c
2333 (arm_fbsd_iterate_over_regset_sections): Likewise.
2334 * arm-linux-tdep.c
2335 (arm_linux_iterate_over_regset_sections): Likewise.
2336 * corelow.c (get_core_registers_cb): Likewise.
2337 (core_target::fetch_registers): Likewise.
2338 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
2339 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
2340 * gdbarch.h (void): Regenerate.
2341 * gdbarch.sh: Add supply_size and collect_size.
2342 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
2343 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
2344 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
2345 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
2346 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
2347 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
2348 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
2349 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
2350 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
2351 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
2352 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
2353 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
2354 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
2355 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
2356 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
2357 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
2358 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
2359 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
2360 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
2361 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
2362 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
2363 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
2364 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
2365 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
2366 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
2367 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
2368 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
2369 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
2370 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
2371 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
2372
2373 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
2374
2375 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
2376 with string_printf.
2377
2378 2018-08-10 Keith Seitz <keiths@redhat.com>
2379
2380 * compile/compile-c-support.c (add_code_header, add_code_footer):
2381 Move into policy class.
2382 (c_push_user_expression, pop_user_expression_nop)
2383 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
2384 (compile_program): New host class.
2385 (c_compile_program): New typedef.
2386 (c_compute_porgram): Use c_compile_program.
2387
2388 2018-08-10 Keith Seitz <keiths@redhat.com>
2389
2390 * compile/compile-internal.h (compile_instance::~compile_instance):
2391 Remove calls to htab_delete.
2392 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
2393 * compile.c (compile_instance::compile_instance): Initialize
2394 htab unique pointers.
2395 (compile_instance::get_cached_type, compile_instance::insert_type)
2396 (compile_instance::error_symbol_once): Update for unique_ptr.
2397
2398 2018-08-10 Keith Seitz <keiths@redhat.com>
2399
2400 * compile/compile-c-symbols.c (struct symbol_error)
2401 (hash_symbol_error, eq_symbol_error, del_symbol_error)
2402 (compile_instance::insert_symbol_error)
2403 (compile_instance::error_symbol_once): Move to ...
2404 * compile/compile.c: ... here.
2405
2406 2018-08-10 Keith Seitz <keiths@redhat.com>
2407
2408 * compile/compile-c-support.c (c_get_compile_context): Use `new'
2409 instead of `new_compile_instance'.
2410 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
2411 Update description.
2412 If the symbol error map is not initialized, create it.
2413 (generate_c_for_for_one_symbol): Do not check/initialize
2414 the symbol error map.
2415 * compile/compile-c-types.c (compile_c_instance): Make a class.
2416 Update all callers.
2417 (compile_instance::compile_instance): Initialize the type cache.
2418 (get_cached_type): New function.
2419 (insert_type): Update description.
2420 (compile_c_instance::m_default_cflags): Define.
2421 (convert_type): Update description. Use get_cached_type.
2422 (delete_instance): Moved to destructor.
2423 (new_compile_instance): Moved to constructor.
2424 * compile/compile-c.h (compile_c_instance): Make class inheriting
2425 from compile_instance.
2426 <base>: Remove field.
2427 <type_map, symbol_err_map>: Move to base class.
2428 <c_plugin>: Rename to `m_plugin' and remove pointer type.
2429 * compile/compile-internal.h (compile_instance): Make class.
2430 <type_map_t, symbol_err_map_t>: Define.
2431 <fe>: Rename to `m_gcc_fe'.
2432 <scope, block, gcc_target_options>: Add `m_' prefix.
2433 <m_type_map, m_symbol_err_map>: New fields, moved from
2434 compile_c_instance.
2435 <destroy>: Remove.
2436 (convert_type, new_compile_instance): Remove.
2437 * compile/compile.c (cleanup_compile_instance): Remove.
2438 (compile_to_object): Use unique_ptr to eliminate cleanups.
2439 (compile_instance::set_print_callback, compile_instance::version)
2440 (compile_instance::set_verbose)
2441 (compile_instance::set_driver_filename)
2442 (compile_instance::set_triplet_regexp)
2443 (compile_instance::set_arguments)
2444 (compile_instance::set_source_file)
2445 (compile_instance::compile): Define.
2446
2447 2018-08-10 Keith Seitz <keiths@redhat.com>
2448
2449 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
2450 * compile/compile-c-types.c: Define GCC_METHODN macros and include
2451 gcc-c-fe.def to define C plugin.
2452 (delete_instance): Delete `c_plugin'.
2453 (new_compile_instance): Initialize `c_plugin'.
2454 * compile/compile-c.h: Include gcc_c_plugin.h.
2455 (struct compile_c_instance) <c_plugin>: New member.
2456 * gcc-c-plugin.h: New file.
2457 Update all callers with API change.
2458
2459 2018-08-10 Keith Seitz <keiths@redhat.com>
2460
2461 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
2462 (HFILES_NO_SRCDIR): ... to here.
2463 Add compile-internal.h and compile-c.h.
2464 * compile/compile-c-support.c: Include compile-c.h.
2465 * compile/compile-c-symbols.c: Include compile-c.h.
2466 (generate_c_for_variable_locations): Update comment.
2467 * compile/compile-c-types.c: Include compile-c.h.
2468 * compile/compile-c.h: New file -- moved C language declarations
2469 from other files here.
2470 * compile/compile-internal.h: Do not include hashtab.h or
2471 common/enum-flags.h.
2472 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
2473 (gcc_convert_symbol, gcc_symbol_address)
2474 (generate_c_for_variable_locations, c_get_mode_for_size)
2475 (c_get_range_decl_name): Definitions moved to compile-c.h.
2476 * compile/compile-loc2c.c: Include compile-c.h.
2477
2478 2018-08-10 Keith Seitz <keiths@redhat.com>
2479
2480 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
2481 (c_symbol_substitution_name): ... this.
2482 Update all callers.
2483
2484 2018-08-10 Keith Seitz <keiths@redhat.com>
2485
2486 * compile/compile-c-support.c (c_compute_program): Use
2487 unique_xmalloc_ptr to eliminate cleanup.
2488 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
2489 Return a unique_xmalloc_ptr and eliminate cleanup.
2490 * compile/compile-internal.h (generate_c_for_variable_locations):
2491 Return unique_xmalloc_ptr and update description.
2492
2493 2018-08-10 Alan Hayward <alan.hayward@arm.com>
2494
2495 * corelow.c (core_target::get_core_register_section): Rename
2496 min_size to section_min_size.
2497
2498 2018-08-09 Jim Wilson <jimw@sifive.com>
2499
2500 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
2501 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
2502 * NEWS: Mention new GNU/Linux RISC-V target.
2503 * configure.host: Add riscv*-*-linux*.
2504 * configure.nat: Add riscv*.
2505 * configure.tgt: Add riscv*-*-linux*.
2506 * riscv-linux-nat.c: New file.
2507 * riscv-linux-tdep.c: New file.
2508
2509 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2510
2511 * infrun.c (resume): Make static, add forward declaration.
2512 (proceed): Update header comment.
2513 * infrun.h (resume): Delete declaration.
2514
2515 2018-08-09 Tom Tromey <tom@tromey.com>
2516
2517 * riscv-tdep.h: Minor formatting fixes.
2518
2519 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
2520
2521 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
2522 * dwarf-index-cache.c (create_dir_and_check): Likewise.
2523 (test_mkdir_recursive): Likewise.
2524 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
2525
2526 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
2527
2528 * valarith.c (value_subscripted_rvalue): If an array is not in
2529 memory, and we don't know the upper bound, then we can't know that
2530 the requested element exists or not.
2531
2532 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
2533
2534 * target.c (str_comma_list_concat_elem): Fix typo in comment.
2535 (target_options_to_string): Add comment.
2536
2537 2018-08-08 Tom Tromey <tom@tromey.com>
2538
2539 * unittests/scoped_mmap-selftests.c: Check result of "write".
2540
2541 2018-08-08 Jim Wilson <jimw@sifive.com>
2542
2543 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
2544 (decode_register_index_short): New.
2545 (decode_j_type_insn, decode_cj_type_insn): New.
2546 (decode_b_type_insn, decode_cb_type_insn): New.
2547 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
2548 local xlen. Check xlen when decoding ambiguous compressed insns. In
2549 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
2550 is_c_sw_insn instead of is_sw_insn.
2551 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
2552 (riscv_software_single_step): New.
2553 * riscv-tdep.h (riscv_software_single_step): Declare.
2554
2555 * riscv-tdep.c (riscv_isa_xlen): Drop static.
2556 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
2557
2558 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
2559
2560 PR gdb/18050:
2561 * target.c (dispose_inferior): Don't dispose of inferiors that are
2562 already killed.
2563
2564 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
2565
2566 * remote.c (remote_target::download_tracepoint): Change char* to
2567 const char*.
2568
2569 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
2570
2571 * target.h (target_options_to_string): Return an std::string.
2572 * target.c (str_comma_list_concat_elem): Return void, use
2573 std::string.
2574 (do_option): Likewise.
2575 (target_options_to_string): Return an std::string.
2576 * linux-nat.c (linux_nat_target::wait): Adjust.
2577 * target-debug.h (target_debug_print_options): Adjust.
2578
2579 2018-08-07 Tom Tromey <tom@tromey.com>
2580
2581 * Makefile.in (CPPFLAGS): New variable.
2582 (INTERNAL_CPPFLAGS): Use it.
2583
2584 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2585
2586 * NEWS: Mention the index cache.
2587
2588 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2589
2590 * common/pathstuff.h (get_standard_cache_dir): New.
2591 * common/pathstuff.c (get_standard_cache_dir): New.
2592 * build-id.h (build_id_to_string): New.
2593 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
2594 DEBUG_STR_SUFFIX): Move to here.
2595 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
2596 DEBUG_STR_SUFFIX): Move from there.
2597 (write_psymtabs_to_index): Make non-static, add basename
2598 parameter. Write to temporary files, rename when done.
2599 (save_gdb_index_command): Adjust call to
2600 write_psymtabs_to_index.
2601 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
2602 field.
2603 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
2604 (get_gdb_index_contents_from_cache): New.
2605 (get_gdb_index_contents_from_cache_dwz): New.
2606 (dwarf2_initialize_objfile): Read index from cache.
2607 (dwarf2_build_psymtabs): Save to index.
2608 * dwarf-index-cache.h: New file.
2609 * dwarf-index-cache.c: New file.
2610 * dwarf-index-write.h: New file.
2611
2612 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2613
2614 * gnulib/aclocal.m4: Re-generate.
2615 * gnulib/config.in: Re-generate.
2616 * gnulib/configure: Re-generate.
2617 * gnulib/import/Makefile.am: Re-generate.
2618 * gnulib/import/Makefile.in: Re-generate.
2619 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2620 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2621 * gnulib/import/m4/mkdir.m4: New file.
2622 * gnulib/import/mkdir.c: New file.
2623 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
2624 module.
2625
2626 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2627
2628 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
2629 * common/scoped_mmap.c: New file.
2630 * common/scoped_mmap.h (destroy): New method.
2631 (~scoped_mmap, reset): Use destroy.
2632 (scoped_mmap): New move constructor.
2633 (mmap_file): New declaration.
2634 * unittests/scoped_mmap-selftests.c (test_normal,
2635 test_invalid_filename, run_tests): New functions.
2636 (_initialize_scoped_mmap_selftests): Register selftest.
2637
2638 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2639
2640 * dwarf2read.c (read_gdb_index_from_section): Rename to...
2641 (read_gdb_index_from_buffer): ... this. Remove section
2642 parameter, add buffer parameter.
2643 (get_gdb_index_contents_ftype,
2644 get_gdb_index_contents_dwz_ftype): New typedefs.
2645 (dwarf2_read_gdb_index): Add callback parameters to get the
2646 index contents.
2647 (get_gdb_index_contents_from_section): New.
2648 (dwarf2_initialize_objfile): Update call to
2649 dwarf2_read_gdb_index.
2650
2651 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
2652
2653 * common/filestuff.h (gdb_fopen_cloexec): New overload.
2654 (gdb_open_cloexec): Likewise.
2655 * nat/linux-osdata.c (command_from_pid): Use string_printf.
2656 (commandline_from_pid): Likewise.
2657 (linux_xfer_osdata_threads): Likewise.
2658 (linux_xfer_osdata_fds): Likewise.
2659 * ada-lang.c (is_package_name): Likewise.
2660 * auxv.c (procfs_xfer_auxv): Likewise.
2661 * breakpoint.c (print_one_breakpoint_location): Use
2662 uiout::field_fmt.
2663 (print_one_catch_solib): Use string_printf.
2664 * coff-pe-read.c (add_pe_exported_sym): Likewise.
2665 (add_pe_forwarded_sym): Likewise.
2666 * dwarf2read.c (create_type_unit_group): Likewise.
2667 (build_error_marker_type): Likewise.
2668 * infcall.c (get_function_name): Likewise.
2669 * valprint.c (print_converted_chars_to_obstack): Likewise.
2670 * xtensa-tdep.c (xtensa_register_type): Likewise.
2671
2672 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
2673
2674 * remote.c (remote_target::download_tracepoint): Fix format
2675 string errors.
2676
2677 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2678
2679 * tracefile.c: Include common/byte-vector.h.
2680 (trace_save): Change type of buf to gdb::byte_vector. Initialize
2681 with trace_regblock_size if needed. Update uses of buf.
2682
2683 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2684
2685 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
2686 std::vector<unsigned char>.
2687 * tracepoint.c (collection_list::collection_list): Remove
2688 m_regs_mask initializer from initializer list. Resize
2689 m_regs_mask using the largest remote register number.
2690 (collection_list::add_remote_register): Remove size check on
2691 m_regs_mask. Use at to access element.
2692 (collection_list::stringify): Change type of temp_buf to
2693 gdb::char_vector. Update uses of temp_buf. Resize if needed to
2694 stringify the register mask. Use pack_hex_byte for the register
2695 mask.
2696
2697 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2698
2699 * tracepoint.h (class collection_list) <add_register>: Remove.
2700 <add_remote_register, add_ax_registers, add_local_register>:
2701 Declare.
2702 <add_memrange>: Add scope parameter.
2703 * tracepoint.c (encode_actions_1): Likewise.
2704 (collection_list::add_register): Rename to ...
2705 (collection_list::add_remote_register): ... this. Update
2706 comment.
2707 (collection_list::add_ax_registers, add_local_register): New
2708 methods.
2709 (collection_list::add_memrange): Add scope parameter. Call
2710 add_local_register instead of add_register.
2711 (finalize_tracepoint_aexpr): New function.
2712 (collection_list::collect_symbol): Update calls to add_memrange.
2713 Call add_local_register instead of add_register. Call
2714 add_ax_registers. Call finalize_tracepoint_aexpr.
2715 (encode_actions_1): Get remote regnos for $reg action. Call
2716 add_remote_register, add_ax_registers, and add_local_register.
2717 Update call to add_memrange. Call finalize_tracepoint_aexpr.
2718 (validate_actionline): Call finalize_tracepoint_aexpr.
2719
2720 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2721
2722 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
2723 Replace array buf with gdb::char_vector buf, of size
2724 get_remote_packet_size (). Replace references to buf and
2725 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
2726 and xsnprintf with snprintf. Raise errors if the buffer is too
2727 small.
2728
2729 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2730
2731 * remote.c (remote_target::download_tracepoint): Fix the has_more
2732 predicate in the QTDP action list iteration.
2733
2734 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2735
2736 * remote.c (remote_target::download_tracepoint): Fix indentation
2737 in for block.
2738
2739 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2740
2741 * proc-api.c (_initialize_proc_api): Remove c, unused.
2742 * procfs.c (procfs_init_inferior): Remove signals, unused.
2743 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
2744 unused.
2745
2746 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
2747 Andrew Burgess <andrew.burgess@embecosm.com>
2748
2749 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
2750 'W_STOPCODE (0)' as this could be ambiguous.
2751
2752 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
2753
2754 * ser-tcp.c (net_open): Fix thinko when deciding whether to
2755 disable TCP's Nagle algorithm (use "ai_protocol" instead of
2756 "ai_socktype").
2757
2758 2018-08-02 Tom Tromey <tom@tromey.com>
2759
2760 PR symtab/16842.
2761 * dwarf2read.c (read_func_scope): Set symtab on template parameter
2762 symbols.
2763 (process_structure_scope): Likewise.
2764
2765 2018-08-02 Xavier Roirand <roirand@adacore.com>
2766
2767 PR gdb/22629:
2768 * darwin-nat.c (darwin_kill_inferior): Fix handling of
2769 kill inferior.
2770
2771 2018-08-02 Tom Tromey <tom@tromey.com>
2772
2773 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
2774 (darwin_suspend_inferior, darwin_resume_inferior)
2775 (darwin_decode_notify_message, darwin_resume_inferior_threads)
2776 (darwin_check_new_threads): Check result of get_darwin_inferior.
2777
2778 2018-07-31 Joel Brobecker <brobecker@adacore.com>
2779
2780 GDB 8.1.1 released.
2781
2782 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
2783
2784 * varobj.c (varobj_get_path_expr_parent): Report an error if
2785 parent is a dynamic varobj.
2786
2787 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2788
2789 * gnulib/aclocal.m4: Re-generate.
2790 * gnulib/config.in: Re-generate.
2791 * gnulib/configure: Re-generate.
2792 * gnulib/import/Makefile.in: Re-generate.
2793 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2794 * gnulib/import/m4/onceonly.m4: Re-generate.
2795
2796 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
2797
2798 * target-descriptions.c (struct xml_test_tdesc): New.
2799 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
2800 (record_xml_tdesc): Update.
2801 (maintenance_check_xml_descriptions): Update.
2802 * target-descriptions.h (record_xml_tdesc): Update comment.
2803
2804 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
2805
2806 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
2807 checking array bounds are defined.
2808
2809 2018-07-30 Tom Tromey <tom@tromey.com>
2810
2811 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
2812 irreflexivity violation.
2813
2814 2018-07-30 Tom Tromey <tom@tromey.com>
2815
2816 * cli/cli-decode.c (lookup_cmd): Remove lint code.
2817 * value.c (unpack_long): Remove lint code.
2818 * valops.c (value_ind): Remove lint code.
2819 * valarith.c (value_x_binop, value_x_unop, value_equal)
2820 (value_pos): Remove lint code.
2821
2822 2018-07-28 Tom de Vries <tdevries@suse.de>
2823
2824 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
2825 with undefined upper bound as <optimized out>.
2826
2827 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
2828
2829 * gcore.in: Rename variable "name" to "prefix". Expand
2830 "usage" text.
2831
2832 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
2833
2834 * windows-nat.c (windows_nat_target::create_inferior): Update to
2835 call close() in global namespace.
2836
2837 2018-07-26 Tom Tromey <tom@tromey.com>
2838
2839 * dwarf-index-write.c (add_address_entry): Don't add objfile
2840 offsets.
2841 * dbxread.c (find_stab_function): Rename from
2842 find_stab_function_addr. Return a bound_minimal_symbol.
2843 (read_dbx_symtab): Use raw_text_low, raw_text_high.
2844 Don't add objfile offsets.
2845 (end_psymtab): Use raw_text_low, raw_text_high,
2846 MSYMBOL_VALUE_RAW_ADDRESS.
2847 (read_ofile_symtab): Update.
2848 (process_one_symbol): Update.
2849 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
2850 offsets.
2851 (dw2_relocate): Remove.
2852 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
2853 searching addrmap.
2854 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
2855 Update.
2856 (process_psymtab_comp_unit_reader, add_partial_symbol)
2857 (add_partial_subprogram, dwarf2_ranges_read): Update.
2858 (load_partial_dies): Update.
2859 (add_address_entry): Don't add objfile offsets.
2860 (dwarf2_build_include_psymtabs): Update.
2861 (create_addrmap_from_aranges): Don't add objfile offsets.
2862 (dw2_find_pc_sect_compunit_symtab): Update.
2863 * mdebugread.c (parse_symbol): Don't add objfile offsets.
2864 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
2865 Update.
2866 (parse_partial_symbols): Don't add objfile offsets. Use
2867 raw_text_low, raw_text_high. Update.
2868 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
2869 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
2870 or call 'relocate' quick function. Clear psymbol_map.
2871 * psympriv.h (struct partial_symbol) <address>: Add section
2872 offset.
2873 <set_unrelocated_address>: Rename from set_address.
2874 <raw_text_low, raw_text_high>: New methods.
2875 <text_low, text_high>: Add objfile parameter.
2876 (add_psymbol_to_bcache): Add 'section' parameter. Call
2877 set_unrelocated_address.
2878 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2879 (find_pc_psymbol): Update.
2880 (fixup_psymbol_section, relocate_psymtabs): Remove.
2881 (dump_psymtab, psym_functions): Update.
2882 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
2883 parameter.
2884 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
2885 (start_psymtab_common): Update.
2886 * symfile-debug.c (debug_qf_relocate): Remove.
2887 (debug_sym_quick_functions): Update.
2888 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
2889 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
2890 Update.
2891
2892 2018-07-26 Tom Tromey <tromey@redhat.com>
2893
2894 * dbxread.c (end_psymtab): Use text_high_valid and
2895 text_low_valid.
2896 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
2897 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
2898 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2899 Update comment.
2900 <text_low_valid, text_high_valid>: New fields.
2901 <set_text_low, set_text_high>: Update.
2902 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
2903
2904 2018-07-26 Tom Tromey <tom@tromey.com>
2905
2906 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
2907 Update.
2908 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
2909 textlow and texthigh fields.
2910 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
2911 Update.
2912 * mdebugread.c (parse_lines, parse_partial_symbols)
2913 (psymtab_to_symtab_1): Update.
2914 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
2915 Rename fields. Update comment. Now private.
2916 <text_low, text_high, set_text_low, set_text_high>: New methods.
2917 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2918 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
2919 (start_psymtab_common, maintenance_info_psymtabs)
2920 (maintenance_check_psymtabs): Update.
2921 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
2922 texthigh fields.
2923 (scan_xcoff_symtab): Update.
2924
2925 2018-07-26 Tom Tromey <tromey@redhat.com>
2926
2927 * psympriv.h (struct partial_symbol) <unrelocated_address,
2928 address, set_address>: New methods.
2929 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
2930 (fixup_psymbol_section, relocate_psymtabs): Update.
2931 (print_partial_symbols): Add 'objfile' parameter. Update.
2932 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
2933 Update.
2934
2935 2018-07-26 Tom Tromey <tom@tromey.com>
2936
2937 * dwarf-index-write.c (write_psymbols, debug_names::insert)
2938 (debug_names::write_psymbols): Update.
2939 * psympriv.h (struct partial_symbol): Derive from
2940 general_symbol_info.
2941 <obj_section>: New method.
2942 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
2943 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
2944 (find_pc_sect_psymbol, fixup_psymbol_section)
2945 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
2946 (print_partial_symbols, recursively_search_psymtabs)
2947 (compare_psymbols, psymbol_hash, psymbol_compare)
2948 (add_psymbol_to_bcache, maintenance_check_psymtabs)
2949 (psymbol_name_matches, psym_fill_psymbol_map): Update.
2950
2951 2018-07-26 Tom Tromey <tromey@redhat.com>
2952
2953 * dbxread.c (end_psymtab): Remove dead code.
2954
2955 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
2956
2957 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
2958 DWARF unwinders are disabled.
2959 * dwarf2-frame.c: Add dwarf2read.h include.
2960 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
2961 disabled.
2962 (dwarf2_frame_unwinders_enabled_p): Define.
2963 (show_dwarf_unwinders_enabled_p): New function.
2964 (_initialize_dwarf2_frame): Register switch to control DWARF
2965 unwinder use.
2966 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
2967 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
2968 (show_dwarf_cmdlist): Remove static keyword.
2969 * dwarf2read.h (set_dwarf_cmdlist): Declare.
2970 (show_dwarf_cmdlist): Declare.
2971 * NEWS: Document new feature.
2972
2973 2018-07-26 Tom de Vries <tdevries@suse.de>
2974
2975 PR breakpoints/23366
2976 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
2977
2978 2018-07-26 Tom de Vries <tdevries@suse.de>
2979
2980 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
2981 DW_AT_count can't be translated to a dynamic prop.
2982
2983 2018-07-25 Tom de Vries <tdevries@suse.de>
2984
2985 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
2986 try/catch.
2987
2988 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
2989
2990 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
2991
2992 2018-07-25 Joel Brobecker <brobecker@adacore.com>
2993
2994 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
2995
2996 2018-07-24 Keith Seitz <keiths@redhat.comt
2997
2998 PR symtab/23010
2999 * dwarf2read.c (dw2_add_symbol_to_list): New function.
3000 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
3001 instead of add_symbol_to_list.
3002 (read_file_scope): Call prepare_one_comp_unit before reading
3003 any other DIEs.
3004
3005 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
3006
3007 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
3008
3009 2018-07-24 Tom Tromey <tom@tromey.com>
3010
3011 * utils.c (malloc, realloc, free): Don't declare.
3012 * configure, config.in: Rebuild.
3013 * configure.ac: Don't check for declarations of free, malloc, or
3014 realloc.
3015
3016 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3017
3018 * aarch64-linux-nat.c
3019 (aarch64_linux_nat_target::stopped_data_address): Remove unused
3020 variable.
3021 * arm-linux-nat.c (fetch_regs): Likewise.
3022 (store_regs): Likewise.
3023 (fetch_vfp_regs): Likewise.
3024 (store_vfp_regs): Likewise.
3025 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
3026 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
3027 (arm_linux_nat_target::insert_watchpoint): Likewise.
3028 (arm_linux_nat_target::remove_watchpoint): Likewise.
3029 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
3030 Likewise.
3031 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
3032 Likewise.
3033 * ppc-linux-nat.c (fetch_register): Likewise.
3034 (fetch_all_gp_regs): Likewise.
3035 (fetch_ppc_registers): Likewise.
3036 (store_all_gp_regs): Likewise.
3037 (store_ppc_registers): Likewise.
3038 (hwdebug_insert_point): Likewise.
3039 (can_use_watchpoint_cond_accel): Likewise.
3040 * remote-sim.c (gdb_os_write_stdout): Likewise.
3041
3042 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
3043 Tom Tromey <tom@tromey.com>
3044
3045 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
3046 test for it.
3047 * configure: Rebuild.
3048
3049 2018-07-22 Tom Tromey <tom@tromey.com>
3050
3051 * regformats/regdat.sh: Define xmltarget_${name} inside
3052 #ifndef IN_PROCESS_AGENT.
3053
3054 2018-07-22 Tom Tromey <tom@tromey.com>
3055
3056 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
3057
3058 2018-07-22 Tom Tromey <tom@tromey.com>
3059
3060 * symfile.c (reread_symbols): Notify iter, not objfile.
3061
3062 2018-07-22 Tom Tromey <tom@tromey.com>
3063
3064 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
3065 Use arch_ops.
3066 (ravenscar_thread_target::prepare_to_store): Likewise.
3067
3068 2018-07-22 Tom Tromey <tom@tromey.com>
3069
3070 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
3071 unused variable. Call value_fetch_lazy when needed.
3072 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
3073 Remove unused variable. Call value_fetch_lazy when needed.
3074
3075 2018-07-22 Tom Tromey <tom@tromey.com>
3076
3077 * m32c-tdep.c (mark_dma): Return void.
3078 (make_regs): Remove unused declarations.
3079
3080 2018-07-22 Tom Tromey <tom@tromey.com>
3081
3082 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
3083 cmdscm_get_valid_command_smob_arg_unsafe for effect.
3084 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
3085 bkscm_get_valid_block_smob_arg_unsafe for effect.
3086
3087 2018-07-22 Tom Tromey <tom@tromey.com>
3088
3089 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
3090 value_type.
3091
3092 2018-07-22 Tom Tromey <tom@tromey.com>
3093
3094 * windows-nat.c (saved_context): Conditionally define.
3095 * remote.c (remote_target::remote_btrace_maybe_reopen):
3096 Conditionally declare "warned".
3097 * inflow.c (sigquit_ours): Conditionally define.
3098 (new_tty): Move "tty" declaration inside #if.
3099 * guile/guile.c (guile_datadir): Conditionally define.
3100 * charset.c (set_be_le_names): Move some declarations inside #if.
3101 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
3102 #if.
3103 (parse_xml_btrace_conf): Likewise.
3104
3105 2018-07-22 Tom Tromey <tom@tromey.com>
3106
3107 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
3108
3109 2018-07-22 Tom Tromey <tom@tromey.com>
3110
3111 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
3112 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
3113 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
3114 * buildsym-legacy.c (get_macro_table): Remove unused variable.
3115 * stack.c (frame_apply_level_command): Remove unused variable.
3116 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
3117 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
3118 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
3119 unused variable.
3120 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
3121 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
3122 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
3123 variable.
3124 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
3125 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
3126 variable.
3127 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
3128 Remove unused variable.
3129 * cli/cli-script.c (recurse_read_control_structure): Remove unused
3130 variable.
3131 * common/tdesc.c (print_xml_feature::visit): Remove unused
3132 variable.
3133 * compile/compile-object-load.c (store_regs): Remove unused
3134 variables.
3135 * complaints.c (clear_complaints): Remove unused variable.
3136 * corelow.c (core_target_open): Remove unused variable.
3137 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
3138 variable.
3139 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
3140 variable.
3141 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
3142 variable.
3143 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
3144 variable.
3145 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
3146 variable.
3147 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
3148 variable.
3149 * ia64-tdep.c (examine_prologue): Remove unused variable.
3150 * infcall.c (run_inferior_call): Remove unused variable.
3151 * inferior.c (exit_inferior): Remove unused variable.
3152 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
3153 * linespec.c (decode_line_2): Remove unused variable.
3154 * linux-nat.c (super_close): Remove.
3155 * linux-tdep.c (linux_info_proc): Remove unused variable.
3156 * mi/mi-main.c (mi_execute_command): Remove unused variable.
3157 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
3158 Remove unused variable.
3159 * parse.c (find_minsym_type_and_address): Remove unused variable.
3160 * printcmd.c (info_symbol_command, printf_floating): Remove unused
3161 variable.
3162 * python/py-breakpoint.c (bppy_set_commands): Remove unused
3163 variable.
3164 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
3165 variables.
3166 * record-btrace.c (record_btrace_target::store_registers): Remove
3167 unused variable.
3168 (cmd_show_record_btrace_cpu): Remove unused variable.
3169 * riscv-tdep.c (riscv_register_reggroup_p)
3170 (riscv_push_dummy_call, riscv_return_value): Remove unused
3171 variable.
3172 * rust-exp.y (literal): Remove unused variable.
3173 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
3174 unused variable.
3175 <STRUCTOP_ANONYMOUS>: Likewise.
3176 * s390-linux-tdep.c (s390_linux_init_abi_31)
3177 (s390_linux_init_abi_64): Remove unused variable.
3178 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
3179 (file_select_thread, net_windows_open, _initialize_ser_windows):
3180 Remove unused variables.
3181 * symtab.c (find_pc_sect_line): Remove unused variable.
3182 * target-memory.c (compute_garbled_blocks): Remove unused
3183 variable.
3184 (target_write_memory_blocks): Remove unused variable.
3185 * target.c (target_stack::unpush): Remove unused variables.
3186 * tracepoint.c (start_tracing, all_tracepoint_actions)
3187 (merge_uploaded_trace_state_variables)
3188 (print_one_static_tracepoint_marker): Remove unused variable.
3189 * unittests/basic_string_view/element_access/char/1.cc (test01):
3190 Remove unused variable.
3191 * windows-nat.c (windows_continue, windows_add_all_dlls)
3192 (do_initial_windows_stuff, windows_nat_target::create_inferior):
3193 Remove unused variables.
3194
3195 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
3196
3197 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
3198 attr_profile in HAVE_ELF.
3199 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
3200 HAVE_ELF.
3201
3202 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
3203
3204 * frame.c (frame_register_unwind): Change parameter name.
3205 (frame_unwind_register): Likewise.
3206 (frame_unwind_register_value): Likewise.
3207 (frame_unwind_register_signed): Likewise.
3208 (frame_unwind_register_unsigned): Likewise.
3209 * frame.h (frame_register_unwind): Likewise.
3210 (frame_unwind_register): Likewise.
3211 (frame_unwind_register_value): Likewise.
3212 (frame_unwind_register_signed): Likewise.
3213 (frame_unwind_register_unsigned): Likewise.
3214 (frame_unwind_arch): Likewise.
3215
3216 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3217
3218 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
3219 ISA maintenance.
3220
3221 2018-07-20 Maciej W. Rozycki <macro@mips.com>
3222
3223 * mips-linux-nat.c (mips_linux_nat_target::read_description):
3224 Call `get_ptrace_pid' rather than extracting the ptrace PID by
3225 hand.
3226
3227 2018-07-20 Keith Seitz <keiths@redhat.com>
3228
3229 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
3230 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
3231 m_compunit_symtab, m_language>: Add "m_" prefix.
3232 Update all uses.
3233 * buildsym.c: Update all uses.
3234
3235 2018-07-20 Tom Tromey <tom@tromey.com>
3236
3237 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
3238 * buildsym.h (record_line_ftype): Remove typedef.
3239
3240 2018-07-20 Tom Tromey <tom@tromey.com>
3241
3242 * buildsym-legacy.h (augment_type_symtab): Don't declare.
3243 (end_expandable_symtab): Likewise.
3244 (end_symtab_get_static_block): Likewise.
3245 (end_symtab_from_static_block): Likewise.
3246 * buildsym-legacy.c (augment_type_symtab): Remove.
3247 (end_expandable_symtab): Remove.
3248 (end_symtab_get_static_block): Remove.
3249 (end_symtab_from_static_block): Remove.
3250
3251 2018-07-20 Tom Tromey <tom@tromey.com>
3252
3253 * dwarf2read.c: Include buildsym.h.
3254 (struct dwarf2_cu) <builder>: New method.
3255 (fixup_go_packaging): Update.
3256 (process_full_comp_unit, process_full_type_unit): Update. Don't
3257 use scoped_free_pendings.
3258 (using_directives): Add "cu" parameter, remove "language".
3259 (read_import_statement, setup_type_unit_groups, )
3260 (read_func_scope, read_lexical_block_scope)
3261 (dwarf2_record_block_ranges, read_namespace): Update.
3262 (lnp_state_machine::lnp_state_machine): Add cu parameter.
3263 (lnp_state_machine::handle_end_sequence): Update.
3264 (class lnp_state_machine) <m_cu>: New member.
3265 <m_record_line_callback>: Remove.
3266 <m_currently_recording_lines>: New member.
3267 (lnp_state_machine::handle_set_file): Update.
3268 (noop_record_line): Remove.
3269 (dwarf_record_line_p): Add cu parameter.
3270 (dwarf_record_line_1, dwarf_finish_line): Likewise.
3271 (lnp_state_machine::record_line)
3272 (lnp_state_machine::lnp_state_machine)
3273 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3274 (dwarf_decode_lines): Update.
3275 (dwarf2_start_subfile): Add cu parameter.
3276 (dwarf2_start_symtab, new_symbol): Update.
3277 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
3278 Remove dwarf2_per_objfile parameter.
3279 (dwarf_decode_macros): Update.
3280
3281 2018-07-20 Tom Tromey <tom@tromey.com>
3282
3283 * stabsread.c (define_symbol): Update.
3284 * buildsym-legacy.h (get_buildsym_compunit): Declare.
3285 * dwarf2read.c (new_symbol): Update.
3286 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
3287 * cp-namespace.c: Include buildsym.h.
3288 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
3289 * buildsym-legacy.c (get_buildsym_compunit): New function.
3290
3291 2018-07-20 Tom Tromey <tom@tromey.com>
3292
3293 * xcoffread.c: Include buildsym-legacy.h.
3294 * windows-nat.c: Include buildsym-legacy.h.
3295 * stabsread.c: Include buildsym-legacy.h.
3296 * mdebugread.c: Include buildsym-legacy.h.
3297 * buildsym-legacy.h: New file.
3298 * buildsym-legacy.c: New file, from buildsym.c.
3299 * go32-nat.c: Include buildsym-legacy.h.
3300 * dwarf2read.c: Include buildsym-legacy.h.
3301 * dbxread.c: Include buildsym-legacy.h.
3302 * cp-namespace.c: Include buildsym-legacy.h.
3303 * coffread.c: Include buildsym-legacy.h.
3304 * buildsym.h: Move some contents to buildsym-legacy.h.
3305 * buildsym.c: Include buildsym-legacy.h. Move many functions to
3306 buildsym-legacy.c.
3307 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
3308
3309 2018-07-20 Tom Tromey <tom@tromey.com>
3310
3311 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
3312 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
3313 (buildsym_compunit::buildsym_compunit)
3314 (buildsym_compunit::~buildsym_compunit)
3315 (buildsym_compunit::get_macro_table): Define.
3316
3317 2018-07-20 Tom Tromey <tom@tromey.com>
3318
3319 * buildsym.c (reset_symtab_globals): Remove.
3320 (buildsym_compunit::end_symtab_from_static_block): Update.
3321 (buildsym_compunit::augment_type_symtab): Update.
3322 (end_symtab_from_static_block): Call free_buildsym_compunit.
3323 (augment_type_symtab, end_symtab, end_expandable_symtab):
3324 Likewise.
3325
3326 2018-07-20 Tom Tromey <tom@tromey.com>
3327
3328 * arch-utils.c: Do not include buildsym.h.
3329 * mipsread.c: Do not include buildsym.h.
3330 * machoread.c: Do not include buildsym.h.
3331 * elfread.c: Do not include buildsym.h.
3332
3333 2018-07-20 Tom Tromey <tom@tromey.com>
3334
3335 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
3336 initialization.
3337 (buildsym_compunit): Add new constructor.
3338 (struct buildsym_compunit) <get_last_source_file, finish_block,
3339 record_block_range, start_subfile, patch_subfile_names,
3340 push_subfile, pop_subfile, record_line, get_compunit_symtab,
3341 set_last_source_start_addr, get_last_source_start_addr,
3342 get_local_using_directives, set_local_using_directives,
3343 get_global_using_directives, outermost_context_p,
3344 get_current_context_stack, get_context_stack_depth,
3345 get_current_subfile, get_local_symbols, get_file_symbols,
3346 get_global_symbols, record_debugformat, record_producer,
3347 push_context, pop_context, end_symtab_get_static_block,
3348 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
3349 New public methods.
3350 <record_pending_block, finish_block_internal, make_blockvector,
3351 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
3352 private methods.
3353 Update all users.
3354
3355 2018-05-22 Tom Tromey <tom@tromey.com>
3356
3357 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3358 parameter.
3359 (finish_block_internal): Update.
3360
3361 2018-07-20 Tom Tromey <tom@tromey.com>
3362
3363 * buildsym.c (record_pending_block): Move earlier. Remove objfile
3364 parameter.
3365 (finish_block_internal): Update.
3366
3367 2018-07-20 Tom Tromey <tom@tromey.com>
3368
3369 * buildsym.h (EXTERN): Don't define or undef.
3370 * buildsym.c (EXTERN): Don't define.
3371
3372 2018-07-20 Tom Tromey <tom@tromey.com>
3373
3374 * buildsym.c: Remove TODO comment.
3375
3376 2018-07-20 Tom Tromey <tom@tromey.com>
3377
3378 * coffread.c (coff_symtab_read): Update.
3379 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
3380 (xcoff_new_init): Update.
3381 * mipsread.c (mipscoff_new_init): Update.
3382 * mdebugread.c (mdebug_build_psymtabs): Update.
3383 * elfread.c (elf_new_init): Update.
3384 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3385 Update.
3386 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
3387 (coffstab_build_psymtabs, elfstab_build_psymtabs)
3388 (stabsect_build_psymtabs): Update.
3389 * buildsym.h (buildsym_init): Don't declare.
3390 * buildsym.c: Update comment.
3391 (prepare_for_building): Remove.
3392 (start_symtab, restart_symtab): Update.
3393 (reset_symtab_globals): Update comment.
3394 (buildsym_init): Remove.
3395
3396 2018-07-20 Tom Tromey <tom@tromey.com>
3397
3398 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
3399 * stabsread.c (patch_block_stabs, define_symbol, read_type)
3400 (read_enum_type, common_block_start, common_block_end)
3401 (cleanup_undefined_types_1, finish_global_stabs): Update.
3402 * mdebugread.c (psymtab_to_symtab_1): Update.
3403 * dwarf2read.c (fixup_go_packaging, read_func_scope)
3404 (read_lexical_block_scope, new_symbol): Update.
3405 * dbxread.c (process_one_symbol): Update.
3406 * coffread.c (coff_symtab_read, process_coff_symbol)
3407 (coff_read_enum_type): Update.
3408 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
3409 declare.
3410 (get_local_symbols, get_file_symbols, get_global_symbols): New
3411 functions.
3412 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
3413 m_global_symbols.
3414 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
3415 (~scoped_free_pendings): Update.
3416 (finish_block, prepare_for_building, reset_symtab_globals)
3417 (end_symtab_get_static_block, end_symtab_with_blockvector)
3418 (augment_type_symtab, push_context): Update.
3419 (get_local_symbols, get_file_symbols, get_global_symbols): New
3420 functions.
3421 (buildsym_init): Update.
3422
3423 2018-07-20 Tom Tromey <tom@tromey.com>
3424
3425 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
3426 (process_full_type_unit): Likewise.
3427 (dwarf2_start_symtab): Set list_in_scope.
3428
3429 2018-07-20 Tom Tromey <tom@tromey.com>
3430
3431 * dwarf2read.c (process_psymtab_comp_unit_reader)
3432 (build_type_psymtabs_reader): Do not set list_in_scope.
3433
3434 2018-07-20 Tom Tromey <tom@tromey.com>
3435
3436 * buildsym.c (free_pendings): Remove.
3437 (add_symbol_to_list, scoped_free_pendings)
3438 (finish_block_internal, buildsym_init): Update.
3439
3440 2018-07-20 Tom Tromey <tom@tromey.com>
3441
3442 * xcoffread.c (read_xcoff_symtab): Update.
3443 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
3444 Update.
3445 * dbxread.c (process_one_symbol): Update.
3446 * coffread.c (coff_symtab_read): Update.
3447 * buildsym.h (finish_block): Update.
3448 * buildsym.c (finish_block): Remove "listhead" argument.
3449 (end_symtab_get_static_block): Update.
3450
3451 2018-07-20 Tom Tromey <tom@tromey.com>
3452
3453 * buildsym.h (class scoped_free_pendings): Remove constructor.
3454 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
3455 method.
3456 <m_pending_block_obstack, m_pending_blocks>: New members.
3457 (pending_block_obstack, pending_blocks): Remove.
3458 (scoped_free_pendings::scoped_free_pendings): Default.
3459 (~scoped_free_pendings): Update.
3460 (free_pending_blocks): Remove.
3461 (finish_block_internal, record_pending_block, make_blockvector)
3462 (end_symtab_get_static_block, augment_type_symtab, push_context)
3463 (buildsym_init): Update.
3464
3465 2018-07-20 Tom Tromey <tom@tromey.com>
3466
3467 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
3468 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
3469 members.
3470 (pending_addrmap, pending_addrmap_obstack)
3471 (pending_addrmap_interesting): Remove.
3472 (scoped_free_pendings, record_block_range, make_blockvector)
3473 (prepare_for_building, reset_symtab_globals, buildsym_init):
3474 Update.
3475
3476 2018-07-20 Tom Tromey <tom@tromey.com>
3477
3478 * xcoffread.c (process_linenos): Update.
3479 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
3480 * mdebugread.c (psymtab_to_symtab_1): Update.
3481 * dwarf2read.c (setup_type_unit_groups)
3482 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
3483 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
3484 * dbxread.c (process_one_symbol): Update.
3485 * coffread.c (coff_symtab_read, enter_linenos)
3486 (process_coff_symbol): Update.
3487 * buildsym.h (current_subfile): Don't declare.
3488 (get_current_subfile): Declare.
3489 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
3490 member.
3491 (start_subfile, free_buildsym_compunit, push_subfile)
3492 (prepare_for_building, start_symtab): Update.
3493 (get_current_subfile): New function.
3494
3495 2018-07-20 Tom Tromey <tom@tromey.com>
3496
3497 * coffread.c (coff_symtab_read): Update.
3498 * xcoffread.c (read_xcoff_symtab): Update.
3499 * dwarf2read.c (new_symbol): Update.
3500 (read_func_scope, read_lexical_block_scope): Update.
3501 * dbxread.c (process_one_symbol): Update.
3502 * buildsym.h (context_stack, context_stack_depth): Don't declare.
3503 (outermost_context_p): Remove macro.
3504 (outermost_context_p, get_current_context_stack)
3505 (get_context_stack_depth): Declare.
3506 (pop_context): Return struct context_stack.
3507 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
3508 member.
3509 (context_stack_size): Remove.
3510 (INITIAL_CONTEXT_STACK_SIZE): Remove.
3511 (prepare_for_building, end_symtab_get_static_block)
3512 (augment_type_symtab, push_context): Update.
3513 (pop_context): Return struct context_stack.
3514 (outermost_context_p, get_current_context_stack)
3515 (get_context_stack_depth): New functions.
3516 (buildsym_init): Update.
3517
3518 2018-07-20 Tom Tromey <tom@tromey.com>
3519
3520 * rust-exp.y: Now a pure parser. Update all rules.
3521 (%union): Move earlier.
3522 (current_parser, work_obstack): Remove globals.
3523 (rust_parser, ~rust_parser): Update.
3524 (class rust_parser) <copy_name, concat3, crate_name, super_name,
3525 lex_character, lex_number, lex_string, lex_identifier,
3526 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
3527 convert_name, convert_params_to_expression,
3528 convert_ast_to_expression, ast_basic_type, ast_operation,
3529 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
3530 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
3531 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
3532 ast_array_type, ast_slice_type, ast_reference_type,
3533 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
3534 (rust_parse): Update.
3535 (rustyyerror, rustyylex): Add parser parameter.
3536 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
3537 (rust_lex_stringish_test, rust_lex_test_sequence)
3538 (rust_lex_test_trailing_dot, rust_lex_test_completion)
3539 (rust_lex_test_push_back, rust_lex_tests): Update.
3540
3541 2018-07-19 Pedro Alves <palves@redhat.com>
3542
3543 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
3544 gdb::unique_xmalloc_ptr.
3545 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
3546 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
3547 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
3548 copy-initialization.
3549 * guile/scm-pretty-print.c (ppscm_print_children): Use
3550 gdb::unique_xmalloc_ptr instead of cleanups.
3551 (gdbscm_apply_val_pretty_printer): Remove cleanups.
3552 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
3553 gdb::unique_xmalloc_ptr.
3554 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3555 Adjust to use gdb::unique_xmalloc_ptr.
3556 * guile/scm-utils.c (extract_arg): Adjust.
3557 * guile/scm-value.c (gdbscm_value_field): Adjust to use
3558 gdb::unique_xmalloc_ptr instead of a cleanup.
3559
3560 2018-07-19 Tom Tromey <tom@tromey.com>
3561
3562 * utils.c (do_value_free_to_mark)
3563 (make_cleanup_value_free_to_mark): Remove.
3564 * utils.h (make_cleanup_value_free_to_mark): Remove.
3565
3566 2018-07-19 Pedro Alves <palves@redhat.com>
3567
3568 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
3569 forwarding reference.
3570
3571 2018-07-18 Pedro Alves <palves@redhat.com>
3572
3573 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
3574 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
3575 cleanup.
3576
3577 2018-07-18 Pedro Alves <palves@redhat.com>
3578
3579 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
3580 exceptions.
3581 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
3582 (gdbscm_wrap): New.
3583 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
3584 directly instead of a cleanup.
3585 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
3586 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
3587 (vlscm_binop_gdbthrow): New, factored out from ...
3588 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
3589 (vlscm_rich_compare): Use gdbscm_wrap.
3590 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
3591 instead of a cleanup.
3592 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
3593 cleanup.
3594 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
3595 Use xfree directly instead of a cleanup.
3596 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
3597 Adjust to use gdbscm_wrap and scoped_value_mark.
3598 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
3599 (gdbscm_value_address, gdbscm_value_dereference)
3600 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
3601 scoped_value_mark.
3602 (gdbscm_value_dynamic_type): Use scoped_value_mark.
3603 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
3604 scoped_value_mark.
3605 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
3606 gdbscm_wrap and scoped_value_mark.
3607 (gdbscm_value_to_string): Use xfree directly instead of a
3608 cleanup. Move 'buffer' unique_ptr to TRY scope.
3609 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
3610 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
3611 scoped_value_mark.
3612 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
3613 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
3614 scoped_value_mark.
3615 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
3616 gdbscm_wrap.
3617
3618 2018-07-18 Tom de Vries <tdevries@suse.de>
3619
3620 * findvar.c (default_read_var_value): Also resolve dynamic type for
3621 LOC_OPTIMIZED_OUT vars.
3622
3623 2018-07-18 Maciej W. Rozycki <macro@mips.com>
3624
3625 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
3626 decoding.
3627
3628 2018-07-17 Tom Tromey <tom@tromey.com>
3629
3630 * guile/scm-param.c (pascm_set_func, pascm_show_func)
3631 (compute_enum_list, pascm_set_param_value_x)
3632 (gdbscm_parameter_value): Update.
3633 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
3634 (gdbscm_scm_to_host_string): Update.
3635 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
3636 Update.
3637 * guile/scm-cmd.c (cmdscm_add_completion): Update.
3638 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
3639 * guile/scm-string.c (gdbscm_scm_to_string): Return
3640 unique_xmalloc_ptr.
3641 (gdbscm_scm_to_host_string): Likewise.
3642
3643 2018-07-17 Tom Tromey <tom@tromey.com>
3644
3645 * guile/guile.c (gdbscm_eval_from_control_command): Update.
3646 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
3647 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
3648 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
3649 unique_xmalloc_ptr.
3650
3651 2018-07-17 Tom Tromey <tom@tromey.com>
3652
3653 * guile/scm-param.c (pascm_signal_setshow_error): Update.
3654 * guile/guile-internal.h (gdbscm_exception_message_to_string):
3655 Update.
3656 * guile/scm-cmd.c (cmdscm_function): Update.
3657 * guile/scm-pretty-print.c
3658 (ppscm_print_exception_unless_memory_error): Update.
3659 * guile/scm-exception.c (gdbscm_exception_message_to_string):
3660 Return unique_xmalloc_ptr.
3661
3662 2018-07-17 Tom Tromey <tom@tromey.com>
3663
3664 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
3665 Use string_printf.
3666
3667 2018-07-17 Jim Wilson <jimw@sifive.com>
3668
3669 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
3670 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
3671 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
3672 unecessary braces after EF_RISCV_RVC test. Delete call to
3673 set_gdbarch_decr_pc_after_break.
3674
3675 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
3676 RISCV_LAST_FP_REGNUM + 1.
3677 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
3678
3679 2018-07-17 Tom Tromey <tom@tromey.com>
3680
3681 * configure.ac: Remove --disable-gdbcli.
3682 * configure: Rebuild.
3683 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
3684 (SUBDIR_CLI_CFLAGS): Remove.
3685 (SFILES): Use SUBDIR_CLI_SRCS.
3686 (COMMON_OBS): Use SUBDIR_CLI_OBS.
3687
3688 2018-07-17 Tom Tromey <tom@tromey.com>
3689
3690 PR gdb/18624:
3691 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
3692
3693 2018-07-16 Jim Wilson <jimw@sifive.com>
3694
3695 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
3696
3697 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3698
3699 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
3700 variable.
3701 (libunwind_frame_sniffer): Likewise.
3702 (libunwind_frame_prev_register): Likewise.
3703 (libunwind_sigtramp_frame_sniffer): Likewise.
3704 * ia64-tdep.c (ia64_access_reg): Likewise.
3705 (ia64_access_rse_reg): Likewise.
3706 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
3707 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
3708
3709 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3710
3711 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
3712
3713 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
3714
3715 * remote-sim.c (gdbsim_target::close,
3716 gdbsim_target::mourn_inferior): Remove unused variables.
3717
3718 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
3719
3720 * ia64-tdep.c (ktab_buf): New global.
3721 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
3722 (get_kernel_table): Adjust.
3723
3724 2018-07-16 Tom Tromey <tom@tromey.com>
3725
3726 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
3727 * dwarf2read.c (using_directives, new_symbol): Use
3728 outermost_context_p.
3729 * dbxread.c (process_one_symbol): Use outermost_context_p.
3730 * coffread.c (coff_symtab_read): Use outermost_context_p.
3731
3732 2018-07-16 Tom Tromey <tom@tromey.com>
3733
3734 * dwarf2read.c (using_directives, read_func_scope)
3735 (read_lexical_block_scope): Update.
3736 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3737 * buildsym.h (local_using_directives, global_using_directives):
3738 Don't declare.
3739 (get_local_using_directives, set_local_using_directives)
3740 (get_global_using_directives): Declare.
3741 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
3742 m_global_using_directives>: New members.
3743 (finish_block_internal, prepare_for_building)
3744 (reset_symtab_globals, end_symtab_get_static_block)
3745 (push_context): Update.
3746 (get_local_using_directives, set_local_using_directives)
3747 (get_global_using_directives): New functions.
3748 (buildsym_init): Update.
3749
3750 2018-07-16 Tom Tromey <tom@tromey.com>
3751
3752 * xcoffread.c (xcoff_initial_scan): Don't call
3753 free_pending_blocks.
3754 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
3755 * buildsym.h (class scoped_free_pendings): Add constructor.
3756 (free_pending_blocks): Don't declare.
3757 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
3758 (free_pending_blocks): Now static.
3759
3760 2018-07-16 Tom Tromey <tom@tromey.com>
3761
3762 * buildsym.h (push_subfile, pop_subfile): Update declarations.
3763 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
3764 member.
3765 (struct subfile_stack): Remove.
3766 (subfile_stack): Remove.
3767 (push_subfile, pop_subfile, buildsym_init): Update.
3768
3769 2018-07-16 Tom Tromey <tom@tromey.com>
3770
3771 * buildsym.c (push_subfile): Use gdb_assert.
3772 (pop_subfile): Use gdb_assert.
3773
3774 2018-07-16 Tom Tromey <tom@tromey.com>
3775
3776 * buildsym.h (merge_symbol_lists): Remove.
3777 * buildsym.c (merge_symbol_lists): Remove.
3778
3779 2018-07-16 Tom Tromey <tom@tromey.com>
3780
3781 * stabsread.c (scan_file_globals): Update comment.
3782 * stabsread.h (scan_file_globals): Move from buildsym.h.
3783 * buildsym.h (scan_file_globals): Move to stabsread.h.
3784
3785 2018-07-16 Tom Tromey <tom@tromey.com>
3786
3787 * xcoffread.c (xcoff_new_init): Update.
3788 * mipsread.c (mipscoff_new_init): Update.
3789 * mdebugread.c (mdebug_build_psymtabs): Update.
3790 * elfread.c (elf_new_init): Update.
3791 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
3792 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
3793 * buildsym.h (buildsym_new_init): Don't declare.
3794 * buildsym.c (buildsym_new_init): Remove.
3795
3796 2018-07-16 Tom Tromey <tom@tromey.com>
3797
3798 * stabsread.h (within_function): Move from buildsym.h.
3799 * stabsread.c (start_stabs): Clear within_function.
3800 * coffread.c (coff_start_symtab): Clear within_function.
3801 * buildsym.h (within_function): Move to stabsread.h.
3802 * buildsym.c (prepare_for_building): Update.
3803
3804 2018-07-16 Tom Tromey <tom@tromey.com>
3805
3806 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
3807 * dwarf2read.c (dwarf2_start_symtab): Don't set
3808 processing_gcc_compilation.
3809 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
3810
3811 2018-07-16 Tom Tromey <tom@tromey.com>
3812
3813 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
3814 (next_symbol_text_func): Move from buildsym.h.
3815 * stabsread.c (hashname): Move from buildsym.c.
3816 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
3817 (next_symbol_text_func, hashname): Move to stabsread.h.
3818 * buildsym.c: Don't include bcache.h
3819 (hashname): Move to stasbread.c.
3820
3821 2018-07-16 Tom Tromey <tom@tromey.com>
3822
3823 * buildsym.h (context_stack_size): Don't declare.
3824 * buildsym.c (context_stack_size): New global.
3825
3826 2018-07-16 Tom Tromey <tom@tromey.com>
3827
3828 * dbxread.c (processing_acc_compilation): New global.
3829 * buildsym.h (processing_acc_compilation): Don't declare.
3830
3831 2018-07-16 Tom Tromey <tom@tromey.com>
3832
3833 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
3834 * dbxread.c (read_ofile_symtab): Update.
3835 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
3836 * buildsym.h (last_source_start_addr): Remove.
3837 (set_last_source_start_addr, get_last_source_start_addr):
3838 Declare.
3839 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
3840 parameter.
3841 (struct buildsym_compunit) <m_last_source_start_addr>: New
3842 member.
3843 (prepare_for_building): Remove start_addr parameter.
3844 (start_symtab, restart_symtab, end_symtab_get_static_block)
3845 (end_symtab_with_blockvector): Update.
3846 (set_last_source_start_addr, get_last_source_start_addr): New
3847 functions.
3848
3849 2018-07-16 Tom Tromey <tom@tromey.com>
3850
3851 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
3852 member.
3853 (have_line_numbers): Remove.
3854 (record_line, prepare_for_building, end_symtab_get_static_block)
3855 (augment_type_symtab): Update.
3856
3857 2018-07-16 Tom Tromey <tom@tromey.com>
3858
3859 * buildsym.c (~buildsym_compunit): Free the macro table.
3860 (struct buildsym_compunit) <get_macro_table, release_macros>: New
3861 methods.
3862 <m_pending_macros>: New member.
3863 (pending_macros): Remove.
3864 (~scoped_free_pendings, get_macro_table, prepare_for_building)
3865 (reset_symtab_globals, end_symtab_get_static_block)
3866 (end_symtab_with_blockvector, augment_type_symtab)
3867 (buildsym_init): Update.
3868
3869 2018-07-16 Tom Tromey <tom@tromey.com>
3870
3871 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
3872 parameter.
3873 (buildsym_compunit::set_last_source_file): New method.
3874 <m_last_source_file>: New member.
3875 (prepare_for_building): Remove "name" parameter.
3876 (start_symtab, restart_symtab, reset_symtab_globals): Update.
3877 (last_source_file): Remove.
3878 (set_last_source_file, get_last_source_file): Update.
3879
3880 2018-07-16 Tom Tromey <tom@tromey.com>
3881
3882 * buildsym.c (prepare_for_building): Add assert.
3883
3884 2018-07-16 Tom Tromey <tom@tromey.com>
3885
3886 * buildsym.c (~buildsym_compunit): Update.
3887 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
3888 (start_subfile, patch_subfile_names)
3889 (end_symtab_with_blockvector): Update.
3890
3891 2018-07-16 Tom Tromey <tom@tromey.com>
3892
3893 * buildsym.c (struct buildsym_compunit): Add constructor,
3894 destructor, initializers.
3895 (start_buildsym_compunit): Remove.
3896 (free_buildsym_compunit): Use "delete".
3897 (start_symtab, restart_symtab): Use "new".
3898
3899 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
3900
3901 * symfile.c (set_objfile_default_section_offset): Remove struct
3902 keyword.
3903
3904 2018-07-14 Stafford Horne <shorne@gmail.com>
3905
3906 * (Responsible Maintainers): Add myself as or1k maintainer.
3907
3908 2018-07-13 Tom Tromey <tom@tromey.com>
3909
3910 * symfile.c (set_objfile_default_section_offset): Use extra braces
3911 around initializer.
3912
3913 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3914
3915 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
3916 non-branching basr.
3917
3918 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3919
3920 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3921 unittests/cli-utils-selftests.c
3922 * unittests/cli-utils-selftests.c: New file.
3923
3924 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3925
3926 * NEWS: Mention new commands. Mention change to 'thread apply'.
3927
3928 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3929
3930 * thread.c (thr_try_catch_cmd): New function.
3931 (thread_apply_all_command): Handle qcs flags.
3932 (thread_apply_command): Handle qcs flags.
3933 (taas_command): New function.
3934 (tfaas_command): New function.
3935 (_initialize_thread): Update to setup the new commands 'taas
3936 and 'tfaas'. Change doc string for 'thread apply'.
3937
3938 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3939
3940 * stack.c: (trailing_outermost_frame): New function, mostly
3941 extracted from backtrace_command_1.
3942 (leading_innermost_frame): New function.
3943 (backtrace_command_1): Update to call trailing_outermost_frame.
3944 (frame_apply_command_count): New function.
3945 (frame_apply_level_command): New function.
3946 (frame_apply_all_command): New function.
3947 (frame_apply_command): New function.
3948 (faas_command): New function.
3949 (frame_cmd_list): New variable.
3950 (_initialize_stack): Update to setup the new commands 'frame apply'
3951 and 'faas'.
3952
3953 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3954
3955 * cli-utils.c (number_or_range_parser::get_number): Only handle
3956 numbers or convenience var as numbers.
3957 (parse_flags): New function.
3958 (parse_flags_qcs): New function.
3959 (number_or_range_parser::finished): Ensure parsing end is detected
3960 before end of string.
3961 * cli-utils.h (parse_flags): New function.
3962 (parse_flags_qcs): New function.
3963 (number_or_range_parser): Remove m_finished bool.
3964 (number_or_range_parser::skip_range): Set m_in_range to false.
3965
3966 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
3967
3968 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
3969 on Windows.
3970
3971 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
3972 Jan Kratochvil <jan.kratochvil@redhat.com>
3973 Paul Fertser <fercerpav@gmail.com>
3974 Tsutomu Seki <sekiriki@gmail.com>
3975 Pedro Alves <palves@redhat.com>
3976
3977 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3978 'unittests/parse-connection-spec-selftests.c'.
3979 (COMMON_SFILES): Add 'common/netstuff.c'.
3980 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
3981 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
3982 * common/netstuff.c: New file.
3983 * common/netstuff.h: New file.
3984 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
3985 (wait_for_connect): Update comment. New parameter
3986 'gdb::optional<int> sock' instead of 'struct serial *scb'.
3987 Use 'sock' directly instead of 'scb->fd'.
3988 (try_connect): New function, with code from 'net_open'.
3989 (net_open): Rewrite main loop to deal with multiple
3990 sockets/addresses. Handle IPv6-style hostnames; implement
3991 support for IPv6 connections.
3992 * unittests/parse-connection-spec-selftests.c: New file.
3993
3994 2018-07-11 Pedro Alves <palves@redhat.com>
3995
3996 PR gdb/23377
3997 * remote.c (remote_target::remote_detach_pid): Call
3998 set_current_process.
3999
4000 2018-07-11 Pedro Alves <palves@redhat.com>
4001
4002 * h8300-tdep.c (h8300_gdbarch_init): Remove
4003 set_gdbarch_ecoff_reg_to_regnum calls.
4004
4005 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
4006
4007 PR c++/23373
4008 * c-typeprint.c (c_type_print_base_struct_union): Don't print
4009 offsets/sizes for static members of a class/struct.
4010
4011 2018-07-11 Alan Hayward <alan.hayward@arm.com>
4012
4013 * target-descriptions.c (tdesc_register_bitsize): Rename.
4014 * target-descriptions.h (tdesc_register_bitsize): Likewise.
4015 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
4016 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
4017
4018 2018-07-10 Tom Tromey <tom@tromey.com>
4019
4020 * breakpoint.c (moribund_locations): Now static and a
4021 std::vector.
4022 (breakpoint_init_inferior, moribund_breakpoint_here_p)
4023 (build_bpstat_chain, update_global_location_list)
4024 (breakpoint_retire_moribund): Update.
4025 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
4026 VEC.
4027
4028 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4029
4030 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
4031 (riscv_register_reggroup_p): Use new function, remove unneeded
4032 parenthesis.
4033 (riscv_push_dummy_call): Extend assert to compare against xlen or
4034 flen based on register type.
4035
4036 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
4037
4038 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
4039
4040 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
4041
4042 * remote.c (show_hardware_watchpoint_limit): New function.
4043 (show_hardware_watchpoint_length_limit): New function.
4044 (show_hardware_breakpoint_limit): New function.
4045 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
4046 where appropriate, update help text.
4047
4048 2018-07-09 Tom Tromey <tom@tromey.com>
4049
4050 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
4051 (CLIBS): Don't mention NAT_CLIBS.
4052
4053 2018-07-09 Tom Tromey <tom@tromey.com>
4054
4055 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
4056 (LIBGDB_OBS, clean mostlyclean): Update.
4057 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
4058
4059 2018-07-09 Tom Tromey <tom@tromey.com>
4060
4061 * Makefile.in (%.c: %.y): Use ECHO_YACC.
4062 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
4063 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
4064
4065 2018-07-09 Tom Tromey <tom@tromey.com>
4066
4067 * Makefile.in (ALLDEPFILES): Remove exec.c.
4068 (COMMON_OBS): Remove exec.o.
4069 (COMMON_SFILES): Add exec.c.
4070
4071 2018-07-09 Tom Tromey <tom@tromey.com>
4072
4073 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
4074
4075 2018-07-09 Tom Tromey <tom@tromey.com>
4076
4077 * Makefile.in (clean mostlyclean): Remove stamp-version.
4078 (version.c): Depend on stamp-version.
4079 (stamp-version): New rule, from version.c rule.
4080
4081 2018-07-09 Tom Tromey <tom@tromey.com>
4082
4083 * Makefile.in (init.c): Depend on stamp-init.
4084 (stamp-init): New rule, from init.c rule.
4085 (clean mostlyclean): Remove stamp-init.
4086
4087 2018-07-09 Tom Tromey <tom@tromey.com>
4088
4089 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
4090 SUBDIR_GCC_COMPILE_SRCS.
4091
4092 2018-07-09 Tom Tromey <tom@tromey.com>
4093
4094 * Makefile.in (init.c): Remove some unused sed rules.
4095
4096 2018-07-09 Tom Tromey <tom@tromey.com>
4097
4098 * Makefile.in (TSOBS): Remove.
4099 (INIT_FILES): Update.
4100 (LIBGDB_OBS): Update.
4101 (COMMON_SFILES): Add inflow.c.
4102 (SFILES): Remove inflow.c.
4103
4104 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
4105
4106 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
4107
4108 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
4109
4110 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
4111 get_saveloc_name, is_signal_frame_name, step_name,
4112 init_remote_name, create_addr_space_name,
4113 destroy_addr_space_name, search_unwind_table_name,
4114 find_dyn_list_name): Constify.
4115
4116 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
4117
4118 * darwin-nat.c (darwin_pthread_kill): New function.
4119 (darwin_resume_thread): Use darwin_pthread_kill.
4120
4121 2018-07-05 Tom de Vries <tdevries@suse.de>
4122
4123 * macroexp.c (macro_buffer) <operator=>: New member function.
4124
4125 2018-07-04 Tom Tromey <tom@tromey.com>
4126
4127 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
4128
4129 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
4130
4131 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
4132 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
4133 * maint.c: Likewise.
4134 * top.c: Likewise.
4135
4136 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4137
4138 * NEWS: Create a new section for the next release branch.
4139 Rename the section of the current branch, now that it has
4140 been cut.
4141
4142 2018-07-04 Joel Brobecker <brobecker@adacore.com>
4143
4144 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
4145 * version.in: Bump version to 8.2.50.DATE-git.
4146
4147 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
4148 Pedro Alves <palves@redhat.com>
4149
4150 * linux-nat.c (linux_init_ptrace): Rename to ...
4151 (linux_init_ptrace_procfs): ... this. Call
4152 linux_proc_init_warnings.
4153 (linux_nat_target::post_attach)
4154 (linux_nat_target::post_startup_inferior): Adjust.
4155 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
4156 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
4157
4158 2018-07-04 Tom de Vries <tdevries@suse.de>
4159
4160 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
4161 check ...
4162 (read_comp_unit_head): ... here.
4163
4164 2018-07-03 Tom Tromey <tom@tromey.com>
4165
4166 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
4167 (stop_tracing, tstatus_command)
4168 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
4169 (print_one_static_tracepoint_marker): Update.
4170 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
4171 std::vector.
4172 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
4173 VEC.
4174 (all_tracepoints, static_tracepoints_here): Return std::vector.
4175
4176 2018-07-03 Tom Tromey <tom@tromey.com>
4177
4178 * common/ptid.c (ptid_equal): Remove.
4179 * common/ptid.h (ptid_equal): Don't declare.
4180 * ada-tasks.c: Update.
4181 * breakpoint.c: Update.
4182 * common/agent.c: Update.
4183 * corelow.c: Update.
4184 * darwin-nat-info.c: Update.
4185 * darwin-nat.c: Update.
4186 * dcache.c: Update.
4187 * dtrace-probe.c: Update.
4188 * dummy-frame.c: Update.
4189 * fbsd-nat.c: Update.
4190 * frame.c: Update.
4191 * gdbthread.h: Update.
4192 * gnu-nat.c: Update.
4193 * go32-nat.c: Update.
4194 * inf-loop.c: Update.
4195 * inf-ptrace.c: Update.
4196 * infcall.c: Update.
4197 * infcmd.c: Update.
4198 * inflow.c: Update.
4199 * infrun.c: Update.
4200 * linux-fork.c: Update.
4201 * linux-nat.c: Update.
4202 * linux-thread-db.c: Update.
4203 * mi/mi-cmd-var.c: Update.
4204 * mi/mi-interp.c: Update.
4205 * mi/mi-main.c: Update.
4206 * nto-procfs.c: Update.
4207 * ppc-linux-tdep.c: Update.
4208 * procfs.c: Update.
4209 * python/py-inferior.c: Update.
4210 * python/py-record-btrace.c: Update.
4211 * python/py-record.c: Update.
4212 * ravenscar-thread.c: Update.
4213 * regcache.c: Update.
4214 * remote-sim.c: Update.
4215 * remote.c: Update.
4216 * sol-thread.c: Update.
4217 * solib.c: Update.
4218 * target.c: Update.
4219 * tui/tui-stack.c: Update.
4220 * varobj.c: Update.
4221 * windows-nat.c: Update.
4222 * windows-tdep.c: Update.
4223
4224 2018-07-03 Tom Tromey <tom@tromey.com>
4225
4226 * common/ptid.c (ptid_match): Remove.
4227 * common/ptid.h (ptid_match): Don't declare.
4228 * fbsd-nat.c: Update.
4229 * infcmd.c: Update.
4230 * infrun.c: Update.
4231 * linux-nat.c: Update.
4232 * record-btrace.c: Update.
4233 * regcache.c: Update.
4234 * remote.c: Update.
4235
4236 2018-07-03 Tom Tromey <tom@tromey.com>
4237
4238 * common/ptid.c (ptid_tid_p): Remove.
4239 * common/ptid.h (ptid_tid_p): Don't declare.
4240 * sol-thread.c: Update.
4241
4242 2018-07-03 Tom Tromey <tom@tromey.com>
4243
4244 * common/ptid.c (ptid_lwp_p): Remove.
4245 * common/ptid.h (ptid_lwp_p): Don't declare.
4246 * fbsd-nat.c: Update.
4247 * linux-nat.c: Update.
4248 * nat/linux-procfs.c: Update.
4249 * nat/x86-linux-dregs.c: Update.
4250 * sol-thread.c: Update.
4251
4252 2018-07-03 Tom Tromey <tom@tromey.com>
4253
4254 * common/ptid.c (ptid_is_pid): Remove.
4255 * common/ptid.h (ptid_is_pid): Don't declare.
4256 * infrun.c: Update.
4257 * linux-nat.c: Update.
4258 * mi/mi-interp.c: Update.
4259 * remote.c: Update.
4260 * thread.c: Update.
4261
4262 2018-07-03 Tom Tromey <tom@tromey.com>
4263
4264 * common/ptid.c (ptid_get_tid): Remove.
4265 * common/ptid.h (ptid_get_tid): Don't declare.
4266 * ada-tasks.c: Update.
4267 * aix-thread.c: Update.
4268 * bsd-uthread.c: Update.
4269 * darwin-nat.c: Update.
4270 * fbsd-nat.c: Update.
4271 * i386-darwin-nat.c: Update.
4272 * infrun.c: Update.
4273 * linux-tdep.c: Update.
4274 * nto-procfs.c: Update.
4275 * ppc-ravenscar-thread.c: Update.
4276 * python/py-infthread.c: Update.
4277 * ravenscar-thread.c: Update.
4278 * sol-thread.c: Update.
4279 * sparc-ravenscar-thread.c: Update.
4280 * windows-nat.c: Update.
4281
4282 2018-07-03 Tom Tromey <tom@tromey.com>
4283
4284 * common/ptid.c (ptid_get_lwp): Remove.
4285 * common/ptid.h (ptid_get_lwp): Don't declare.
4286 * aarch64-linux-nat.c: Update.
4287 * ada-tasks.c: Update.
4288 * aix-thread.c: Update.
4289 * amd64-linux-nat.c: Update.
4290 * arm-linux-nat.c: Update.
4291 * corelow.c: Update.
4292 * fbsd-nat.c: Update.
4293 * fbsd-tdep.c: Update.
4294 * gnu-nat.c: Update.
4295 * i386-cygwin-tdep.c: Update.
4296 * i386-gnu-nat.c: Update.
4297 * i386-linux-nat.c: Update.
4298 * ia64-linux-nat.c: Update.
4299 * inf-ptrace.c: Update.
4300 * infrun.c: Update.
4301 * linux-fork.c: Update.
4302 * linux-nat.c: Update.
4303 * linux-tdep.c: Update.
4304 * linux-thread-db.c: Update.
4305 * mips-linux-nat.c: Update.
4306 * nat/aarch64-linux-hw-point.c: Update.
4307 * nat/aarch64-linux.c: Update.
4308 * nat/linux-btrace.c: Update.
4309 * nat/linux-osdata.c: Update.
4310 * nat/linux-procfs.c: Update.
4311 * nat/x86-linux-dregs.c: Update.
4312 * obsd-nat.c: Update.
4313 * ppc-fbsd-nat.c: Update.
4314 * ppc-linux-nat.c: Update.
4315 * procfs.c: Update.
4316 * python/py-infthread.c: Update.
4317 * ravenscar-thread.c: Update.
4318 * remote.c: Update.
4319 * s390-linux-nat.c: Update.
4320 * sol-thread.c: Update.
4321 * sol2-tdep.c: Update.
4322 * spu-linux-nat.c: Update.
4323 * x86-linux-nat.c: Update.
4324 * xtensa-linux-nat.c: Update.
4325
4326 2018-07-03 Tom Tromey <tom@tromey.com>
4327
4328 * common/ptid.c (ptid_get_pid): Remove.
4329 * common/ptid.h (ptid_get_pid): Don't declare.
4330 * aarch64-linux-nat.c: Update.
4331 * ada-lang.c: Update.
4332 * aix-thread.c: Update.
4333 * alpha-bsd-nat.c: Update.
4334 * amd64-fbsd-nat.c: Update.
4335 * amd64-linux-nat.c: Update.
4336 * arm-linux-nat.c: Update.
4337 * arm-nbsd-nat.c: Update.
4338 * auxv.c: Update.
4339 * break-catch-syscall.c: Update.
4340 * breakpoint.c: Update.
4341 * bsd-uthread.c: Update.
4342 * corelow.c: Update.
4343 * ctf.c: Update.
4344 * darwin-nat.c: Update.
4345 * fbsd-nat.c: Update.
4346 * fbsd-tdep.c: Update.
4347 * gcore.c: Update.
4348 * gnu-nat.c: Update.
4349 * hppa-nbsd-nat.c: Update.
4350 * hppa-obsd-nat.c: Update.
4351 * i386-fbsd-nat.c: Update.
4352 * ia64-linux-nat.c: Update.
4353 * inf-ptrace.c: Update.
4354 * infcmd.c: Update.
4355 * inferior.c: Update.
4356 * inferior.h: Update.
4357 * inflow.c: Update.
4358 * infrun.c: Update.
4359 * linux-fork.c: Update.
4360 * linux-nat.c: Update.
4361 * linux-tdep.c: Update.
4362 * linux-thread-db.c: Update.
4363 * m68k-bsd-nat.c: Update.
4364 * mi/mi-interp.c: Update.
4365 * mi/mi-main.c: Update.
4366 * mips-linux-nat.c: Update.
4367 * mips-nbsd-nat.c: Update.
4368 * mips64-obsd-nat.c: Update.
4369 * nat/aarch64-linux-hw-point.c: Update.
4370 * nat/aarch64-linux.c: Update.
4371 * nat/linux-btrace.c: Update.
4372 * nat/linux-osdata.c: Update.
4373 * nat/linux-procfs.c: Update.
4374 * nat/x86-linux-dregs.c: Update.
4375 * nto-procfs.c: Update.
4376 * obsd-nat.c: Update.
4377 * ppc-linux-nat.c: Update.
4378 * ppc-nbsd-nat.c: Update.
4379 * ppc-obsd-nat.c: Update.
4380 * proc-service.c: Update.
4381 * procfs.c: Update.
4382 * python/py-inferior.c: Update.
4383 * python/py-infthread.c: Update.
4384 * ravenscar-thread.c: Update.
4385 * record.c: Update.
4386 * remote-sim.c: Update.
4387 * remote.c: Update.
4388 * rs6000-nat.c: Update.
4389 * s390-linux-nat.c: Update.
4390 * sh-nbsd-nat.c: Update.
4391 * sol-thread.c: Update.
4392 * sparc-nat.c: Update.
4393 * sparc64-tdep.c: Update.
4394 * spu-linux-nat.c: Update.
4395 * spu-tdep.c: Update.
4396 * target-debug.h: Update.
4397 * target.c: Update.
4398 * thread.c: Update.
4399 * tid-parse.c: Update.
4400 * tracefile-tfile.c: Update.
4401 * vax-bsd-nat.c: Update.
4402 * windows-nat.c: Update.
4403 * x86-linux-nat.c: Update.
4404 * x86-nat.c: Update.
4405
4406 2018-07-03 Tom Tromey <tom@tromey.com>
4407
4408 * common/ptid.c (pid_to_ptid): Remove.
4409 * common/ptid.h (pid_to_ptid): Don't declare.
4410 * aix-thread.c: Update.
4411 * arm-linux-nat.c: Update.
4412 * common/ptid.c: Update.
4413 * common/ptid.h: Update.
4414 * corelow.c: Update.
4415 * ctf.c: Update.
4416 * darwin-nat.c: Update.
4417 * fbsd-nat.c: Update.
4418 * fork-child.c: Update.
4419 * gnu-nat.c: Update.
4420 * go32-nat.c: Update.
4421 * inf-ptrace.c: Update.
4422 * infcmd.c: Update.
4423 * inferior.c: Update.
4424 * infrun.c: Update.
4425 * linux-fork.c: Update.
4426 * linux-nat.c: Update.
4427 * nat/aarch64-linux-hw-point.c: Update.
4428 * nat/fork-inferior.c: Update.
4429 * nat/x86-linux-dregs.c: Update.
4430 * nto-procfs.c: Update.
4431 * obsd-nat.c: Update.
4432 * procfs.c: Update.
4433 * progspace.c: Update.
4434 * remote.c: Update.
4435 * rs6000-nat.c: Update.
4436 * s390-linux-nat.c: Update.
4437 * sol-thread.c: Update.
4438 * spu-linux-nat.c: Update.
4439 * target.c: Update.
4440 * top.c: Update.
4441 * tracefile-tfile.c: Update.
4442 * windows-nat.c: Update.
4443
4444 2018-07-03 Tom Tromey <tom@tromey.com>
4445
4446 * common/ptid.h (ptid_build): Don't declare.
4447 * common/ptid.c (ptid_build): Remove.
4448 * aix-thread.c: Update.
4449 * bsd-kvm.c: Update.
4450 * bsd-uthread.c: Update.
4451 * common/agent.c: Update.
4452 * common/ptid.c: Update.
4453 * common/ptid.h: Update.
4454 * corelow.c: Update.
4455 * darwin-nat.c: Update.
4456 * fbsd-nat.c: Update.
4457 * gnu-nat.c: Update.
4458 * linux-fork.c: Update.
4459 * linux-nat.c: Update.
4460 * linux-thread-db.c: Update.
4461 * nat/linux-osdata.c: Update.
4462 * nat/linux-procfs.c: Update.
4463 * nto-procfs.c: Update.
4464 * obsd-nat.c: Update.
4465 * proc-service.c: Update.
4466 * procfs.c: Update.
4467 * ravenscar-thread.c: Update.
4468 * remote-sim.c: Update.
4469 * remote.c: Update.
4470 * sol-thread.c: Update.
4471 * target.c: Update.
4472 * windows-nat.c: Update.
4473
4474 2018-07-03 Tom Tromey <tom@tromey.com>
4475
4476 * infrun.c (follow_exec): Use exit_inferior_silent.
4477 * inferior.c (exit_inferior_num_silent): Remove.
4478 * inferior.h (exit_inferior_num_silent): Don't declare.
4479
4480 2018-07-03 Tom Tromey <tom@tromey.com>
4481
4482 PR cli/23340:
4483 * darwin-nat.c (darwin_attach_pid): Reset inferior and
4484 inferior_ptid on error.
4485
4486 2018-07-02 Maciej W. Rozycki <macro@mips.com>
4487 Simon Marchi <simon.marchi@polymtl.ca>
4488
4489 PR tdep/8282
4490 * disasm.h (gdb_disassembler): Add
4491 `m_disassembler_options_holder'. member
4492 * disasm.c (get_all_disassembler_options): New function.
4493 (gdb_disassembler::gdb_disassembler): Use it.
4494 (gdb_buffered_insn_length_init_dis): Likewise.
4495 (gdb_buffered_insn_length): Adjust accordingly.
4496 (set_disassembler_options): Handle options with arguments.
4497 (show_disassembler_options_sfunc): Likewise. Add a leading new
4498 line if showing options with descriptions.
4499 (disassembler_options_completer): Adapt to using the
4500 `disasm_options_and_args_t' structure.
4501 * mips-tdep.c (mips_disassembler_options): New variable.
4502 (mips_disassembler_options_o32): Likewise.
4503 (mips_disassembler_options_n32): Likewise.
4504 (mips_disassembler_options_n64): Likewise.
4505 (gdb_print_insn_mips): Don't set `disassembler_options'.
4506 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
4507 functions.
4508 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
4509 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
4510 `gdbarch_disassembler_options_implicit' and
4511 `gdbarch_valid_disassembler_options'.
4512 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
4513 `disasm_options_and_args_t' structure.
4514 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
4515 method.
4516 (valid_disassembler_options): Switch from `disasm_options_t' to
4517 the `disasm_options_and_args_t' structure.
4518 * NEWS: Document `set disassembler-options' support for the MIPS
4519 target.
4520 * gdbarch.h: Regenerate.
4521 * gdbarch.c: Regenerate.
4522
4523 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
4524
4525 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
4526
4527 2018-06-29 Joel Brobecker <brobecker@adacore.com>
4528
4529 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
4530 parameter in call to amd64_target_description.
4531 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
4532 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
4533 (amd64fbsd_init_abi): Likewise.
4534 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4535 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4536 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4537 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
4538
4539 2018-06-29 Pedro Alves <palves@redhat.com>
4540
4541 * gdb/amd64-tdep.h (amd64_create_target_description): Add
4542 "segments" parameter.
4543 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
4544 (_initialize_amd64_tdep): Update call to
4545 amd64_create_target_description.
4546 (amd64_target_description): Add "segments" parameter. Adjust
4547 the implementation to use it.
4548 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
4549 call to amd64_create_target_description.
4550 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
4551 * gdb/arch/amd64.h (amd64_create_target_description): Add
4552 "segments" register.
4553 * gdb/arch/amd64.c (amd64_create_target_description): Add
4554 "segments" parameter. Call create_feature_i386_64bit_segments
4555 only if SEGMENTS is true.
4556 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
4557 call to amd64_create_target_description.
4558
4559 2018-06-29 Pedro Alves <palves@redhat.com>
4560
4561 * thread.c (thread_target_id_str): New, factored out from ...
4562 (print_thread_info_1): ... here. Use it to compute the max
4563 "Target Id" column width.
4564
4565 2018-06-29 Pedro Alves <palves@redhat.com>
4566
4567 * remote.c (remote_target::extra_thread_info): Delete
4568 'display_buf' and 'n' locals. from the cache, regardless of
4569 packet mechanims is in use. Use cache for qThreadExtra and qP
4570 methods too.
4571
4572 2018-06-29 Pedro Alves <palves@redhat.com>
4573
4574 * blockframe.c (find_pc_sect_containing_function): New function.
4575 * breakpoint.c (print_breakpoint_location): Don't call
4576 find_pc_sect_function.
4577 * linespec.c (create_sals_line_offset): Record the location's
4578 symbol in the sal.
4579 * linespec.c (convert_address_location_to_sals): Fill in sal's
4580 symbol with find_pc_sect_containing_function.
4581 * symtab.c (find_function_start_sal): Rename to ...
4582 (find_function_start_sal_1): ... this.
4583 (find_function_start_sal): Reimplement as wrapper around
4584 find_function_start_sal_1, and use
4585 find_pc_sect_containing_function to fill in the sal's symbol.
4586 (find_function_start_sal(symbol*, bool)): Adjust.
4587 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
4588 comments.
4589 (find_pc_sect_containing_function): Declare.
4590
4591 2018-06-29 Pedro Alves <palves@redhat.com>
4592
4593 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
4594 true if the the location has no symbol.
4595
4596 2018-06-28 Tom Tromey <tom@tromey.com>
4597
4598 * NEWS: Mention --enable-codesign.
4599 * silent-rules.mk (ECHO_SIGN): New variable.
4600 * configure.ac: Add --enable-codesign.
4601 * configure: Rebuild.
4602 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
4603 (gdb$(EXEEXT)): Optionally invoke codesign.
4604
4605 2018-06-28 Pedro Alves <palves@redhat.com>
4606
4607 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
4608 comments.
4609 (switch_to_thread_no_regs): Adjust comment.
4610 * infcmd.c (stop_pc): Delete.
4611 (post_create_inferior, info_program_command): Replace references
4612 to stop_pc with references to thread_info->suspend.stop_pc.
4613 * inferior.h (stop_pc): Delete declaration.
4614 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
4615 (handle_inferior_event_1, handle_signal_stop)
4616 (process_event_stop_test, keep_going_stepped_thread)
4617 (handle_step_into_function, handle_step_into_function_backward)
4618 (print_stop_location): Replace references to stop_pc with
4619 references to thread_info->suspend.stop_pc.
4620 (struct infcall_suspend_state) <stop_pc>: Delete field.
4621 (save_infcall_suspend_state, restore_infcall_suspend_state):
4622 Remove references to inf_stat->stop_pc.
4623 * linux-fork.c (fork_load_infrun_state): Likewise.
4624 * record-btrace.c (record_btrace_set_replay): Likewise.
4625 * record-full.c (record_full_goto_entry): Likewise.
4626 * remote.c (print_one_stopped_thread): Likewise.
4627 * target.c (target_resume): Extend comment.
4628 * thread.c (set_executing_thread): New.
4629 (set_executing): Use it.
4630 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
4631 Remove references to stop_pc.
4632
4633 2018-06-28 Pedro Alves <palves@redhat.com>
4634
4635 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
4636 Moving fetching stop_pc until after ecs->event_thread is refreshed.
4637
4638 2018-06-28 Tom Tromey <tom@tromey.com>
4639
4640 * coffread.c (coff_symfile_finish): Update.
4641 * xcoffread.c (xcoff_symfile_finish): Update.
4642 * elfread.c (elf_symfile_finish): Update.
4643 * symfile.h (dwarf2_free_objfile): Don't declare.
4644 * dwarf2read.c (_initialize_dwarf2_read): Use
4645 register_objfile_data_with_cleanup.
4646 (dwarf2_free_objfile): Now static. Change signature.
4647
4648 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4649
4650 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
4651 option "-o" to add-symbol-file-load to add an offset to each
4652 section's load address.
4653 * symfile.c (set_objfile_default_section_offset): New function.
4654
4655 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4656
4657 * symfile.c (add_symbol_file_command): Make sure that sections
4658 with the same name are sorted in the same order.
4659
4660 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4661
4662 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
4663 require the second argument. If omitted, load sections at the
4664 addresses specified in the file.
4665
4666 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4667
4668 * symfile.c (symbol_file_command, symbol_file_add_main_1)
4669 (_initialize_symfile): Add option "-o" to symbol-file to add an
4670 offset to each section of the symbol file.
4671
4672 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
4673
4674 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
4675
4676 2018-06-27 Tom Tromey <tom@tromey.com>
4677
4678 * stack.c (_initialize_stack): Update "func" help text.
4679
4680 2018-06-27 Tom Tromey <tom@tromey.com>
4681
4682 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
4683 std::vector.
4684 (unwind_infopy_str, pyuw_create_unwind_info)
4685 (unwind_infopy_add_saved_register, pyuw_sniffer)
4686 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
4687 Update.
4688 (struct saved_reg): Add constructor.
4689 <value>: Now a gdbpy_ref<>.
4690
4691 2018-06-27 Tom Tromey <tom@tromey.com>
4692
4693 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
4694
4695 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4696
4697 * gdb-gdb.py.in: Format using autopep8.
4698
4699 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4700
4701 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
4702 (type_lookup_function): Recognize CORE_ADDR values.
4703
4704 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4705
4706 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
4707 print tag_name.
4708
4709 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4710
4711 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
4712 <__lt__>: Add.
4713
4714 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4715
4716 * gdb-gdb.py: Move to...
4717 * gdb-gdb.py.in: ... here.
4718 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
4719 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
4720 dependencies.
4721 (distclean): Remove gdb-gdb.py when cleaning.
4722 (gdb-gdb.py, gdb-gdb.gdb): New rules.
4723 * configure: Re-generate.
4724
4725 2018-06-27 Pedro Alves <palves@redhat.com>
4726
4727 * proc-service.c (get_ps_regcache): New.
4728 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
4729 (ps_lsetfpregs): Use it.
4730
4731 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
4732
4733 PR gdb/21695
4734 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
4735 (dwarf_decode_lines_1): Adjust.
4736
4737 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
4738
4739 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
4740 override.
4741 <info_proc>: Likewise.
4742
4743 2018-06-26 Joel Brobecker <brobecker@adacore.com>
4744
4745 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
4746 to windows_fetch_one_register, and only handle the case of
4747 fetching one register. Move the code that reloads the context
4748 and iterates over all registers if R is negative to...
4749 (windows_nat_target::fetch_registers): ... here.
4750 (do_windows_store_inferior_registers): Rename to
4751 windows_store_one_register, and only handle the case of storing
4752 one register. Move the code that handles the case where r is
4753 negative to...
4754 (windows_nat_target::store_registers) ... here.
4755
4756 2018-06-26 Tom Tromey <tom@tromey.com>
4757
4758 PR rust/22574:
4759 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
4760 * rust-lang.c (rust_print_struct_def): Add podata parameter.
4761 Update.
4762 (rust_internal_print_type): Add podata parameter.
4763 (rust_print_type): Update.
4764
4765 2018-06-26 Tom Tromey <tom@tromey.com>
4766
4767 * typeprint.h (struct print_offset_data) <update, finish,
4768 maybe_print_hole>: New methods.
4769 <indentation>: New constant.
4770 * typeprint.c (print_offset_data::indentation): Define.
4771 (print_offset_data::maybe_print_hole, print_offset_data::update)
4772 (print_offset_data::finish): Move from c-typeprint.c and rename.
4773 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
4774 (print_spaces_filtered_with_print_options): Update.
4775 (c_print_type_union_field_offset, maybe_print_hole)
4776 (c_print_type_struct_field_offset): Move to typeprint.c and
4777 rename.
4778 (c_type_print_base_struct_union): Update.
4779
4780 2018-06-25 Pedro Alves <palves@redhat.com>
4781
4782 * gdbthread.h (thread_info_ref, delete_thread)
4783 (delete_thread_silent, first_thread_of_inferior)
4784 (any_thread_of_inferior, switch_to_thread)
4785 (enable_thread_stack_temporaries)
4786 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4787 (get_last_thread_stack_temporary)
4788 (value_in_thread_stack_temporaries, can_access_registers_thread):
4789 Spell out "struct thread_info" instead of just "thread_info".
4790 * inferior.h (notice_new_inferior): Likewise.
4791
4792 2018-06-25 Pedro Alves <palves@redhat.com>
4793
4794 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4795 pass thread_info pointer to delete_thread.
4796 (windows_nat_target::detach): Pass inferior pointer to
4797 detach_inferior.
4798 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
4799 delete_thread.
4800 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
4801 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
4802 and pass a thread_info pointer to delete_thread.
4803 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
4804 pass thread_info pointer to delete_thread.
4805 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
4806 delete_thread_silent call.
4807 * procfs.c (procfs_target::detach): Pass inferior pointer to
4808 detach_inferior.
4809 (procfs_target::wait): Pass thread_info pointer to delete_thread.
4810 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
4811 delete_thread_silent call.
4812 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
4813 pass thread_info pointer to delete_thread.
4814 (windows_nat_target::detach): Pass inferior pointer to
4815 delete_inferior.
4816
4817 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4818
4819 * regcache.c (readable_regcache::read_part): Fix asserts.
4820 (reg_buffer::raw_collect_part): New function.
4821 (regcache::write_part): Fix asserts.
4822 (reg_buffer::raw_supply_part): New function.
4823 (regcache::transfer_regset_register): New helper function.
4824 (regcache::transfer_regset): Call new functions.
4825 (regcache_supply_regset): Use gdb_byte*.
4826 (regcache::supply_regset): Likewise.
4827 (regcache_collect_regset): Likewise.
4828 (regcache::collect_regset): Likewise.
4829 * regcache.h (reg_buffer::raw_collect_part): New declaration.
4830 (reg_buffer::raw_supply_part): Likewise.
4831 (regcache::transfer_regset_register): Likewise.
4832 (regcache::transfer_regset): Use gdb_byte*.
4833
4834 2018-06-22 Alan Hayward <alan.hayward@arm.com>
4835
4836 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
4837
4838 2018-06-21 Pedro Alves <palves@redhat.com>
4839
4840 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4841 instead of a ptid_t. All callers adjusted.
4842 * ada-tasks.c (ada_get_task_number): Likewise. All callers
4843 adjusted.
4844 (print_ada_task_info, display_current_task_id, task_command_1):
4845 Adjust.
4846 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
4847 inferior_thread.
4848 (breakpoint_kind): Adjust.
4849 (remove_breakpoints_pid): Rename to ...
4850 (remove_breakpoints_inf): ... this. Adjust to take an inferior
4851 pointer. All callers adjusted.
4852 (bpstat_clear_actions): Use inferior_thread.
4853 (get_bpstat_thread): New.
4854 (bpstat_do_actions): Use it.
4855 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
4856 to take a thread_info pointer. All callers adjusted.
4857 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
4858 (breakpoint_re_set_thread): Use inferior_thread.
4859 * breakpoint.h (struct inferior): Forward declare.
4860 (bpstat_stop_status): Update.
4861 (remove_breakpoints_pid): Delete.
4862 (remove_breakpoints_inf): New.
4863 * bsd-uthread.c (bsd_uthread_target::wait)
4864 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
4865 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
4866 (maint_btrace_packet_history_cmd)
4867 (maint_btrace_clear_packet_history_cmd): Adjust.
4868 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
4869 inferior_thread.
4870 * cli/cli-interp.c: Include "inferior.h".
4871 * common/refcounted-object.h (struct
4872 refcounted_object_ref_policy): New.
4873 * compile/compile-object-load.c: Include gdbthread.h.
4874 (store_regs): Use inferior_thread.
4875 * corelow.c (core_target::close): Use current_inferior.
4876 (core_target_open): Adjust to use first_thread_of_inferior and use
4877 the current inferior.
4878 * ctf.c (ctf_target::close): Adjust to use current_inferior.
4879 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
4880 <thread>: ... this new field. All references adjusted.
4881 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
4882 Take a thread_info pointer instead of a ptid_t.
4883 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
4884 (dummy_frame_discard, register_dummy_frame_dtor): Take a
4885 thread_info pointer instead of a ptid_t.
4886 * elfread.c: Include "inferior.h".
4887 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
4888 Use inferior_thread.
4889 * eval.c (evaluate_subexp): Likewise.
4890 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
4891 inferior_thread.
4892 * gdb_proc_service.h (struct thread_info): Forward declare.
4893 (struct ps_prochandle) <ptid>: Delete, replaced by ...
4894 <thread>: ... this new field. All references adjusted.
4895 * gdbarch.h, gdbarch.c: Regenerate.
4896 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
4897 'thread' parameter. All implementations and callers adjusted.
4898 * gdbthread.h (thread_info) <set_running>: New method.
4899 (delete_thread, delete_thread_silent): Take a thread_info pointer
4900 instead of a ptid.
4901 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
4902 (first_thread_of_process): Delete, replaced by ...
4903 (first_thread_of_inferior): ... this new function. All callers
4904 adjusted.
4905 (any_live_thread_of_process): Delete, replaced by ...
4906 (any_live_thread_of_inferior): ... this new function. All callers
4907 adjusted.
4908 (switch_to_thread, switch_to_no_thread): Declare.
4909 (is_executing): Delete.
4910 (enable_thread_stack_temporaries): Update comment.
4911 <enable_thread_stack_temporaries>: Take a thread_info pointer
4912 instead of a ptid_t. Incref the thread.
4913 <~enable_thread_stack_temporaries>: Decref the thread.
4914 <m_ptid>: Delete
4915 <m_thr>: New.
4916 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
4917 (get_last_thread_stack_temporary)
4918 (value_in_thread_stack_temporaries, can_access_registers_thread):
4919 Take a thread_info pointer instead of a ptid_t. All callers
4920 adjusted.
4921 * infcall.c (get_call_return_value): Use inferior_thread.
4922 (run_inferior_call): Work with thread pointers instead of ptid_t.
4923 (call_function_by_hand_dummy): Work with thread pointers instead
4924 of ptid_t. Use thread_info_ref.
4925 * infcmd.c (proceed_thread_callback): Access thread's state
4926 directly.
4927 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
4928 access thread's state directly.
4929 (continue_command): Use inferior_thread.
4930 (info_program_command): Use find_thread_ptid and access thread
4931 state directly.
4932 (proceed_after_attach_callback): Use thread state directly.
4933 (notice_new_inferior): Take a thread_info pointer instead of a
4934 ptid_t. All callers adjusted.
4935 (exit_inferior): Take an inferior pointer instead of a pid. All
4936 callers adjusted.
4937 (exit_inferior_silent): New.
4938 (detach_inferior): Delete.
4939 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
4940 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
4941 (detach_inferior_command, kill_inferior_command): Use
4942 find_inferior_id instead of valid_gdb_inferior_id and
4943 gdb_inferior_id_to_pid.
4944 (inferior_command): Use inferior and thread pointers.
4945 * inferior.h (struct thread_info): Forward declare.
4946 (notice_new_inferior): Take a thread_info pointer instead of a
4947 ptid_t. All callers adjusted.
4948 (detach_inferior): Delete declaration.
4949 (exit_inferior, exit_inferior_silent): Take an inferior pointer
4950 instead of a pid. All callers adjusted.
4951 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
4952 (valid_gdb_inferior_id): Delete.
4953 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
4954 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
4955 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
4956 ...
4957 <inf>: ... this new field.
4958 <step_ptid>: Delete, replaced by ...
4959 <step_thread>: ... this new field.
4960 (get_displaced_stepping_state): Take an inferior pointer instead
4961 of a pid. All callers adjusted.
4962 (displaced_step_in_progress_any_inferior): Adjust.
4963 (displaced_step_in_progress_thread): Take a thread pointer instead
4964 of a ptid_t. All callers adjusted.
4965 (displaced_step_in_progress, add_displaced_stepping_state): Take
4966 an inferior pointer instead of a pid. All callers adjusted.
4967 (get_displaced_step_closure_by_addr): Adjust.
4968 (remove_displaced_stepping_state): Take an inferior pointer
4969 instead of a pid. All callers adjusted.
4970 (displaced_step_prepare_throw, displaced_step_prepare)
4971 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
4972 All callers adjusted.
4973 (start_step_over): Adjust.
4974 (infrun_thread_ptid_changed): Remove bit updating ptids in the
4975 displaced step queue.
4976 (do_target_resume): Adjust.
4977 (fetch_inferior_event): Use inferior_thread.
4978 (context_switch, get_inferior_stop_soon): Take an
4979 execution_control_state pointer instead of a ptid_t. All callers
4980 adjusted.
4981 (switch_to_thread_cleanup): Delete.
4982 (stop_all_threads): Use scoped_restore_current_thread.
4983 * inline-frame.c: Include "gdbthread.h".
4984 (inline_state) <inline_state>: Take a thread pointer instead of a
4985 ptid_t. All callers adjusted.
4986 <ptid>: Delete, replaced by ...
4987 <thread>: ... this new field.
4988 (find_inline_frame_state): Take a thread pointer instead of a
4989 ptid_t. All callers adjusted.
4990 (skip_inline_frames, step_into_inline_frame)
4991 (inline_skipped_frames, inline_skipped_symbol): Take a thread
4992 pointer instead of a ptid_t. All callers adjusted.
4993 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
4994 (inline_skipped_frames, inline_skipped_symbol): Likewise.
4995 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
4996 pointers directly.
4997 * linux-nat.c (get_detach_signal): Likewise.
4998 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
4999 (thread_db_notice_clone): Adjust.
5000 (thread_db_find_new_threads_silently)
5001 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
5002 a thread pointer instead of a ptid_t. All callers adjusted.
5003 * mi/mi-cmd-var.c: Include "inferior.h".
5004 (mi_cmd_var_update_iter): Update to use thread pointers.
5005 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
5006 inferior directly.
5007 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
5008 out to ...
5009 (mi_output_running): ... this new function.
5010 (mi_on_resume_1): Adjust to use it.
5011 (mi_user_selected_context_changed): Adjust to use inferior_thread.
5012 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
5013 directly.
5014 (interrupt_thread_callback): : Adjust to use thread and inferior
5015 pointers.
5016 * proc-service.c: Include "gdbthread.h".
5017 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
5018 * progspace-and-thread.c: Include "inferior.h".
5019 * progspace.c: Include "inferior.h".
5020 * python/py-exitedevent.c (create_exited_event_object): Adjust to
5021 hold a reference to an inferior_object.
5022 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
5023 inferior_thread.
5024 * python/py-inferior.c (struct inferior_object): Give the type a
5025 tag name instead of a typedef.
5026 (python_on_normal_stop): No need to check if the current thread is
5027 listed.
5028 (inferior_to_inferior_object): Change return type to
5029 inferior_object. All callers adjusted.
5030 (find_thread_object): Delete, bits factored out to ...
5031 (thread_to_thread_object): ... this new function.
5032 * python/py-infthread.c (create_thread_object): Use
5033 inferior_to_inferior_object.
5034 (thpy_is_stopped): Use thread pointer directly.
5035 (gdbpy_selected_thread): Use inferior_thread.
5036 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
5037 field, replaced with ...
5038 <thread>: ... this new field. All users adjusted.
5039 (btpy_insn_or_gap_new): Drop const.
5040 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
5041 callers adjusted.
5042 * python/py-record.c: Include "gdbthread.h".
5043 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5044 a ptid_t. All callers adjusted.
5045 (gdbpy_current_recording): Use inferior_thread.
5046 * python/py-record.h (recpy_record_object) <ptid>: Delete
5047 field, replaced with ...
5048 <thread>: ... this new field. All users adjusted.
5049 (recpy_element_object) <ptid>: Delete
5050 field, replaced with ...
5051 <thread>: ... this new field. All users adjusted.
5052 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
5053 a ptid_t. All callers adjusted.
5054 * python/py-threadevent.c: Include "gdbthread.h".
5055 (get_event_thread): Use thread_to_thread_object.
5056 * python/python-internal.h (struct inferior_object): Forward
5057 declare.
5058 (find_thread_object, find_inferior_object): Delete declarations.
5059 (thread_to_thread_object, inferior_to_inferior_object): New
5060 declarations.
5061 * record-btrace.c: Include "inferior.h".
5062 (require_btrace_thread): Use inferior_thread.
5063 (record_btrace_frame_sniffer)
5064 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
5065 (get_thread_current_frame): Use scoped_restore_current_thread and
5066 switch_to_thread.
5067 (get_thread_current_frame): Use thread pointer directly.
5068 (record_btrace_replay_at_breakpoint): Use thread's inferior
5069 pointer directly.
5070 * record-full.c: Include "inferior.h".
5071 * regcache.c: Include "gdbthread.h".
5072 (get_thread_arch_regcache): Use the inferior's address space
5073 directly.
5074 (get_thread_regcache, registers_changed_thread): New.
5075 * regcache.h (get_thread_regcache(thread_info *thread)): New
5076 overload.
5077 (registers_changed_thread): New.
5078 (remote_target) <remote_detach_1>: Swap order of parameters.
5079 (remote_add_thread): <remote_add_thread>: Return the new thread.
5080 (get_remote_thread_info(ptid_t)): New overload.
5081 (remote_target::remote_notice_new_inferior): Use thread pointers
5082 directly.
5083 (remote_target::process_initial_stop_replies): Use
5084 thread_info::set_running.
5085 (remote_target::remote_detach_1, remote_target::detach)
5086 (extended_remote_target::detach): Adjust.
5087 * stack.c (frame_show_address): Use inferior_thread.
5088 * target-debug.h (target_debug_print_thread_info_pp): New.
5089 * target-delegates.c: Regenerate.
5090 * target.c (default_thread_address_space): Delete.
5091 (memory_xfer_partial_1): Use current_inferior.
5092 (target_detach): Use current_inferior.
5093 (target_thread_address_space): Delete.
5094 (generic_mourn_inferior): Use current_inferior.
5095 * target.h (struct target_ops) <thread_address_space>: Delete.
5096 (target_thread_address_space): Delete.
5097 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
5098 pointers directly.
5099 (delete_thread_1, delete_thread, delete_thread_silent): Take a
5100 thread pointer instead of a ptid_t. Adjust all callers.
5101 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
5102 (first_thread_of_process): Delete, replaced by ...
5103 (first_thread_of_inferior): ... this new function. All callers
5104 adjusted.
5105 (any_thread_of_process): Rename to ...
5106 (any_thread_of_inferior): ... this, and take an inferior pointer.
5107 (any_live_thread_of_process): Rename to ...
5108 (any_live_thread_of_inferior): ... this, and take an inferior
5109 pointer.
5110 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5111 (value_in_thread_stack_temporaries)
5112 (get_last_thread_stack_temporary): Take a thread pointer instead
5113 of a ptid_t. Adjust all callers.
5114 (thread_info::set_running): New.
5115 (validate_registers_access): Use inferior_thread.
5116 (can_access_registers_ptid): Rename to ...
5117 (can_access_registers_thread): ... this, and take a thread
5118 pointer.
5119 (print_thread_info_1): Adjust to compare thread pointers instead
5120 of ptids.
5121 (switch_to_no_thread, switch_to_thread): Make extern.
5122 (scoped_restore_current_thread::~scoped_restore_current_thread):
5123 Use m_thread pointer directly.
5124 (scoped_restore_current_thread::scoped_restore_current_thread):
5125 Use inferior_thread.
5126 (thread_command): Use thread pointer directly.
5127 (thread_num_make_value_helper): Use inferior_thread.
5128 * top.c (execute_command): Use inferior_thread.
5129 * tui/tui-interp.c: Include "inferior.h".
5130 * varobj.c (varobj_create): Use inferior_thread.
5131 (value_of_root_1): Use find_thread_global_id instead of
5132 global_thread_id_to_ptid.
5133
5134 2018-06-21 Alan Hayward <alan.hayward@arm.com>
5135
5136 * regcache.c (readable_regcache::read_part): Avoid memcpy when
5137 possible.
5138 (regcache::write_part): Likewise.
5139 (readable_regcache::cooked_read_part): Update comment.
5140 (readable_regcache::cooked_write_part): Likewise.
5141 * regcache.h: (readable_regcache::read_part): Likewise.
5142 (regcache::write_part): Likewise.
5143
5144 2018-06-21 Richard Bunt <richard.bunt@arm.com>
5145 Dirk Schubert <dirk.schubert@arm.com>
5146
5147 * aarch64-linux-nat.c (post_attach): New.
5148 (aarch64_linux_nat_target::post_attach): Override post_attach to
5149 record the number of hardware debug registers.
5150
5151 2018-06-20 Tom Tromey <tom@tromey.com>
5152
5153 * python/py-param.c (add_setshow_generic): Make parameters const.
5154 (parmpy_init): Update.
5155
5156 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5157
5158 * regcache.h (regcache_cooked_read_ftype): Rename to...
5159 (register_read_ftype): ...this, change type to function_view.
5160 (class reg_buffer) <save>: Remove src parameter.
5161 (readonly_detached_regcache) <readonly_detached_regcache>: Make
5162 parameter non-const in first overload. Remove src parameter in
5163 second overload.
5164 * regcache.c (do_cooked_read): Remove.
5165 (readonly_detached_regcache::readonly_detached_regcache): Make
5166 parameter non-const, adjust call to other constructor.
5167 (reg_buffer::save): Remove src parameter.
5168 * frame.c (do_frame_register_read): Remove.
5169 (frame_save_as_regcache): Use lambda function.
5170 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
5171 parameter to ppu2spu_data *.
5172 (ppu2spu_sniffer): Use lambda function.
5173
5174 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
5175
5176 * record-full.c (record_full_target::insert_breakpoint): Remove
5177 "struct" keyword, add const.
5178
5179 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
5180
5181 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
5182 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
5183 * configure.ac: Remove AC_PREREQ, add missing quoting.
5184 * gnulib/configure.ac: Modernize usage of
5185 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
5186 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
5187 (AUTOMAKE_VERSION): Bump to 1.15.1.
5188 * configure: Re-generate.
5189 * config.in: Re-generate.
5190 * aclocal.m4: Re-generate.
5191 * gnulib/aclocal.m4: Re-generate.
5192 * gnulib/config.in: Re-generate.
5193 * gnulib/configure: Re-generate.
5194 * gnulib/import/Makefile.in: Re-generate.
5195
5196 2018-06-19 Pedro Alves <palves@redhat.com>
5197
5198 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
5199 (lookup_minimal_symbol_by_pc_section): ... here with
5200 gdb_assert_not_reached added.
5201
5202 2018-06-19 Pedro Alves <palves@redhat.com>
5203
5204 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
5205 parameter with a block parameter. Compare location's block symbol
5206 with the frame's block instead of addresses.
5207 (skip_inline_frames): Pass the current block instead of the
5208 frame's address. Break out as soon as we determine the frame
5209 should not be skipped.
5210
5211 2018-06-18 Tom Tromey <tom@tromey.com>
5212
5213 * solib-aix.c (solib_aix_get_section_offsets): Return
5214 unique_xmalloc_ptr.
5215 (solib_aix_solib_create_inferior_hook): Update.
5216
5217 2018-06-18 Tom Tromey <tom@tromey.com>
5218
5219 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
5220
5221 2018-06-18 Tom Tromey <tom@tromey.com>
5222
5223 * solib-frv.c (frv_relocate_main_executable): Use
5224 unique_xmalloc_ptr.
5225 * solib-dsbt.c (dsbt_relocate_main_executable): Use
5226 unique_xmalloc_ptr.
5227
5228 2018-06-18 Tom Tromey <tom@tromey.com>
5229
5230 * objfiles.h (inhibit_section_map_updates): Update.
5231 (resume_section_map_updates, resume_section_map_updates_cleanup):
5232 Remove.
5233 * solib-svr4.c (svr4_handle_solib_event): Update.
5234 * objfiles.c (inhibit_section_map_updates): Return
5235 scoped_restore_tmpl<int>.
5236 (resume_section_map_updates, resume_section_map_updates_cleanup):
5237 Remove.
5238
5239 2018-06-18 Tom Tromey <tom@tromey.com>
5240
5241 * valprint.h (read_string): Update.
5242 * valprint.c (read_string): Change type of "buffer".
5243 (val_print_string): Update.
5244 * python/py-value.c (valpy_string): Update.
5245 * language.h (struct language_defn) <la_get_string>: Change
5246 type of "buffer".
5247 (default_get_string, c_get_string): Update.
5248 * language.c (default_get_string): Change type of "buffer".
5249 * guile/scm-value.c (gdbscm_value_to_string): Update.
5250 * c-lang.c (c_get_string): Change type of "buffer".
5251
5252 2018-06-18 Tom Tromey <tom@tromey.com>
5253
5254 * ser-mingw.c (struct pipe_state_destroyer): New.
5255 (pipe_state_up): New typedef.
5256 (cleanup_pipe_state): Remove.
5257 (pipe_windows_open): Use pipe_state_up. Don't release argv.
5258
5259 2018-06-18 Tom Tromey <tom@tromey.com>
5260
5261 * rust-lang.h (rust_yyerror): Don't declare.
5262 * rust-lang.c (rust_language_defn): Update.
5263 * rust-exp.y (yyerror): Now static.
5264 * parse.c (parse_exp_in_context_1): Update.
5265 * p-lang.h (p_yyerror): Don't declare.
5266 * p-lang.c (p_language_defn): Update.
5267 * p-exp.y (yyerror): Now static.
5268 * opencl-lang.c (opencl_language_defn): Update.
5269 * objc-lang.c (objc_language_defn): Update.
5270 * m2-lang.h (m2_yyerror): Don't declare.
5271 * m2-lang.c (m2_language_defn): Update.
5272 * m2-exp.y (yyerror): Now static.
5273 * language.h (struct language_defn) <la_error>: Remove.
5274 * language.c (unk_lang_error): Remove.
5275 (unknown_language_defn, auto_language_defn): Remove.
5276 * go-lang.h (go_yyerror): Don't declare.
5277 * go-lang.c (go_language_defn): Update.
5278 * go-exp.y (yyerror): Now static.
5279 * f-lang.h (f_yyerror): Don't declare.
5280 * f-lang.c (f_language_defn): Update.
5281 * f-exp.y (yyerror): Now static.
5282 * d-lang.h (d_yyerror): Don't declare.
5283 * d-lang.c (d_language_defn): Update.
5284 * d-exp.y (yyerror): Now static.
5285 * c-lang.h (c_yyerror): Don't declare.
5286 * c-lang.c (c_language_defn, cplus_language_defn)
5287 (asm_language_defn, minimal_language_defn): Update.
5288 * c-exp.y (yyerror): Now static.
5289 * ada-lang.h (ada_yyerror): Don't declare.
5290 * ada-lang.c (ada_language_defn): Update.
5291 * ada-exp.y (yyerror): Now static.
5292
5293 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5294
5295 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
5296 (store_sveregs_to_thread): Likewise.
5297 (aarch64_linux_fetch_inferior_registers): Check for SVE.
5298 (aarch64_linux_store_inferior_registers): Likewise.
5299 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
5300 function.
5301 (aarch64_sve_regs_copy_to_regcache): Likewise.
5302 (aarch64_sve_regs_copy_from_regcache): Likewise.
5303 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
5304 declaration.
5305 (aarch64_sve_regs_copy_to_regcache): Likewise.
5306 (aarch64_sve_regs_copy_from_regcache): Likewise.
5307 (sve_context): Structure from Linux headers.
5308 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
5309 (SVE_SIG_ZREG_SIZE): Likewise.
5310 (SVE_SIG_PREG_SIZE): Likewise.
5311 (SVE_SIG_FFR_SIZE): Likewise.
5312 (SVE_SIG_REGS_OFFSET): Likewise.
5313 (SVE_SIG_ZREGS_OFFSET): Likewise.
5314 (SVE_SIG_ZREG_OFFSET): Likewise.
5315 (SVE_SIG_ZREGS_SIZE): Likewise.
5316 (SVE_SIG_PREGS_OFFSET): Likewise.
5317 (SVE_SIG_PREG_OFFSET): Likewise.
5318 (SVE_SIG_PREGS_SIZE): Likewise.
5319 (SVE_SIG_FFR_OFFSET): Likewise.
5320 (SVE_SIG_REGS_SIZE): Likewise.
5321 (SVE_SIG_CONTEXT_SIZE): Likewise.
5322 (SVE_PT_REGS_MASK): Likewise.
5323 (SVE_PT_REGS_FPSIMD): Likewise.
5324 (SVE_PT_REGS_SVE): Likewise.
5325 (SVE_PT_VL_INHERIT): Likewise.
5326 (SVE_PT_VL_ONEXEC): Likewise.
5327 (SVE_PT_REGS_OFFSET): Likewise.
5328 (SVE_PT_FPSIMD_OFFSET): Likewise.
5329 (SVE_PT_FPSIMD_SIZE): Likewise.
5330 (SVE_PT_SVE_ZREG_SIZE): Likewise.
5331 (SVE_PT_SVE_PREG_SIZE): Likewise.
5332 (SVE_PT_SVE_FFR_SIZE): Likewise.
5333 (SVE_PT_SVE_FPSR_SIZE): Likewise.
5334 (SVE_PT_SVE_FPCR_SIZE): Likewise.
5335 (__SVE_SIG_TO_PT): Likewise.
5336 (SVE_PT_SVE_OFFSET): Likewise.
5337 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
5338 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
5339 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
5340 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
5341 (SVE_PT_SVE_PREG_OFFSET): Likewise.
5342 (SVE_PT_SVE_PREGS_SIZE): Likewise.
5343 (SVE_PT_SVE_FFR_OFFSET): Likewise.
5344 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
5345 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
5346 (SVE_PT_SVE_SIZE): Likewise.
5347 (SVE_PT_SIZE): Likewise.
5348 (HAS_SVE_STATE): New define.
5349
5350 2018-06-18 Alan Hayward <alan.hayward@arm.com>
5351
5352 * nat/aarch64-sve-linux-sigcontext.h: New file.
5353 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
5354 new files.
5355 (SVE_VQ_MIN): Likewise.
5356 (SVE_VQ_MAX): Likewise.
5357 (SVE_VL_MIN): Likewise.
5358 (SVE_VL_MAX): Likewise.
5359 (SVE_NUM_ZREGS): Likewise.
5360 (SVE_NUM_PREGS): Likewise.
5361 (sve_vl_valid): Likewise.
5362 (struct user_sve_header): Likewise.
5363
5364 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
5365 Richard Bunt <Richard.Bunt@arm.com>
5366
5367 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
5368 was requested by GDB.
5369
5370 2018-06-15 Tom de Vries <tdevries@suse.de>
5371
5372 * MAINTAINERS (Write After Approval): Add Tom de Vries.
5373
5374 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
5375
5376 * gnulib/update-gnulib.sh: Print expected versions of
5377 autoconf/aclocal.
5378
5379 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
5380
5381 * arch-utils.c (default_type_align): Use type_length_units.
5382 * gdbtypes.c (type_align): Use type_length_units.
5383
5384 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5385
5386 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
5387 of 'define' command.
5388
5389 2018-06-14 Tom de Vries <tdevries@suse.de>
5390
5391 PR cli/22573
5392 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5393 get_no_prettyformat_print_options.
5394
5395 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
5396
5397 * sparc-nat.h: Include target.h.
5398 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
5399 <fetch_registers>: Remove this argument in function call.
5400 <store_registers>: Remove this argument in function call, remove
5401 extra semicolon.
5402 <low_forget_process>: Call sparc64_forget_process instead of
5403 sparc_forget_process.
5404
5405 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5406
5407 * procfs.c (_initialize_procfs): Use add_inf_child_target.
5408 (procfs_target::make_corefile_notes): Adjust to new
5409 target_read_alloc return type.
5410
5411 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5412 Stephen Roberts <stephen.roberts@arm.com>
5413
5414 PR gdb/22882
5415 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
5416 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
5417 Move should_notify_stop local into more inner scope.
5418
5419 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5420 Stephen Roberts <stephen.roberts@arm.com>
5421
5422 PR gdb/22882
5423 * infrun.c (resume_1): Add call to mark_async_event_handler.
5424
5425 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
5426
5427 * infrun.c (do_target_wait): Change old version of $pc printed.
5428
5429 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
5430
5431 * dwarf2read.c (read_index_from_section): Rename to...
5432 (read_gdb_index_from_section): ... this, update all callers.
5433 (dwarf2_read_index): Rename to...
5434 (dwarf2_read_gdb_index): ... this, update all callers.
5435
5436 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
5437
5438 * gdb/hppa-linux-nat.c
5439 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
5440 hppa_linux_nat_target::fetch_registers.
5441
5442 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5443
5444 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
5445 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
5446 (AARCH64_DWARF_SVE_FFR): Likewise.
5447 (AARCH64_DWARF_SVE_P0): Likewise.
5448 (AARCH64_DWARF_SVE_Z0): Likewise.
5449
5450 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5451
5452 * common/common-regcache.h (raw_compare): New function.
5453 * regcache.c (regcache::raw_compare): Likewise.
5454 * regcache.h (regcache::raw_compare): New declaration.
5455
5456 2018-06-11 Alan Hayward <alan.hayward@arm.com>
5457
5458 * common/common-regcache.h (reg_buffer_common): New structure.
5459 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
5460 (reg_buffer::raw_supply): Likewise.
5461 (reg_buffer::raw_supply_integer): Likewise.
5462 (reg_buffer::raw_supply_zeroed): Likewise.
5463 (reg_buffer::raw_collect): Likewise.
5464 (reg_buffer::raw_collect_integer): Likewise.
5465 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
5466 (reg_buffer::raw_supply): Likewise.
5467 (reg_buffer::raw_supply_integer): Likewise.
5468 (reg_buffer::raw_supply_zeroed): Likewise.
5469 (reg_buffer::raw_collect): Likewise.
5470 (reg_buffer::raw_collect_integer): Likewise.
5471
5472 2018-06-10 Tom Tromey <tom@tromey.com>
5473
5474 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
5475 (class remote_state) <stop_reply_queue>: Now std::vector.
5476 (remote_state::~remote_state)
5477 (remote_target::stop_reply_queue_length): Update.
5478 (struct queue_iter_param, remove_child_of_pending_fork)
5479 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
5480 (check_pending_event_prevents_wildcard_vcont_callback)
5481 (remove_stop_reply_for_inferior)
5482 (remove_stop_reply_of_remote_state)
5483 (remote_notif_remove_once_on_match)
5484 (stop_reply_match_ptid_and_ws)
5485 (remote_kill_child_of_pending_fork): Remove.
5486 (remote_target::remove_new_fork_children)
5487 (remote_target::check_pending_events_prevent_wildcard_vcont)
5488 (remote_target::discard_pending_stop_replies)
5489 (remote_target::discard_pending_stop_replies_in_queue)
5490 (remote_target::remote_notif_remove_queued_reply)
5491 (remote_target::queued_stop_reply)
5492 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
5493 (remote_target::wait, remote_target::kill_new_fork_children)
5494 (remote_target::async): Update.
5495
5496 2018-06-10 Tom Tromey <tom@tromey.com>
5497
5498 * record-full.c (record_full_arch_list_cleanups): Remove.
5499 (record_full_message): Use try/catch.
5500 (record_full_wait_cleanups): Remove.
5501 (record_full_wait_1): Use try/catch.
5502 (record_full_restore): Likewise.
5503
5504 2018-06-10 Tom Tromey <tom@tromey.com>
5505
5506 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
5507 declare VEC. Add constructor.
5508 <in_target_beneath>: Now bool.
5509 (record_full_breakpoints): Now a std::vector, static.
5510 (record_full_sync_record_breakpoints)
5511 (record_full_init_record_breakpoints)
5512 (record_full_target::insert_breakpoint)
5513 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
5514
5515 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5516
5517 * dwarf2read.c (process_cu_includes): Remove struct keyword.
5518 * serial.c (serial_interface_lookup): Remove struct keyword.
5519
5520 2018-06-10 Tom Tromey <tom@tromey.com>
5521
5522 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
5523 method.
5524 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
5525 a method.
5526 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
5527 method.
5528 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
5529 "beneath" as a method.
5530 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
5531 Use "beneath" as a method.
5532
5533 2018-06-10 Tom Tromey <tom@tromey.com>
5534
5535 * tracefile.c (struct trace_file_writer_deleter): New.
5536 <operator()>: Rename from trace_file_writer_xfree.
5537 (trace_file_writer_up): New typedef.
5538 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
5539
5540 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5541
5542 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
5543 <m_registers, m_register_status>: Change type to
5544 std::unique_ptr.
5545 * regcache.c (reg_buffer::reg_buffer): Use new instead of
5546 XCNEWVEC.
5547
5548 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
5549
5550 * common/common-regcache.h (enum register_status): Add
5551 underlying type "signed char".
5552 * regcache.h (reg_buffer) <m_register_status>: Change type to
5553 register_status *.
5554 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
5555 register_status instead of signed char.
5556 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
5557 (reg_buffer::get_register_status): Remove cast.
5558 (readable_regcache::raw_read): Remove cast.
5559 (readable_regcache::cooked_read): Remove cast.
5560
5561 2018-06-09 Tom Tromey <tom@tromey.com>
5562
5563 * source.c (reverse_search_command, forward_search_command): Use
5564 scoped_fd.
5565
5566 2018-06-09 Tom Tromey <tom@tromey.com>
5567
5568 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
5569 (serial_ops_list): Now static, std::vector.
5570 (serial_interface_lookup, serial_add_interface): Update.
5571
5572 2018-06-09 Tom Tromey <tom@tromey.com>
5573
5574 * dwarf2read.c (process_cu_includes): Update.
5575 (process_full_comp_unit): Update.
5576 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
5577 std::vector.
5578
5579 2018-06-08 Paul Koning <paul_koning@dell.com>
5580
5581 PR gdb/23252
5582
5583 * python/python.c (do_start_initialization):
5584 Avoid call to internal Python API.
5585 (init__gdb_module): New function.
5586
5587 2018-06-08 Gary Benson <gbenson@redhat.com>
5588
5589 * linux-thread-db.c (valprint.h): New include.
5590 (struct check_thread_db_info): New structure.
5591 (check_thread_db_on_load, tdb_testinfo): New static globals.
5592 (check_thread_db, check_thread_db_callback): New functions.
5593 (try_thread_db_load_1): Run integrity checks if requested.
5594 (maintenance_check_libthread_db): New function.
5595 (_initialize_thread_db): Register "maint check libthread-db"
5596 and "maint set/show check-libthread-db".
5597 * NEWS: Mention the above new commands.
5598
5599 2018-06-08 Tom Tromey <tom@tromey.com>
5600
5601 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
5602 now a method.
5603
5604 2018-06-08 Tom Tromey <tom@tromey.com>
5605
5606 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
5607
5608 2018-06-08 Tom Tromey <tom@tromey.com>
5609
5610 * common/btrace-common.h (struct btrace_data): Add constructor,
5611 destructor, move assignment operator.
5612 <empty, clear, fini>: New methods.
5613 <format>: Initialize.
5614 (btrace_data_init, btrace_data_fini, btrace_data_clear)
5615 (btrace_data_empty): Don't declare.
5616 * common/btrace-common.c (btrace_data_init): Remove.
5617 (btrace_data::fini): Rename from btrace_data_fini.
5618 (btrace_data::empty): Rename from btrace_data_empty.
5619 (btrace_data::clear): Rename from btrace_data_clear. Return
5620 bool.
5621 * btrace.h (make_cleanup_btrace_data): Don't declare.
5622 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
5623 (parse_xml_btrace): Update.
5624 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
5625 (maint_btrace_clear_packet_history_cmd): Update.
5626
5627 2018-06-07 Pedro Alves <palves@redhat.com>
5628
5629 * target.h (target_ops) <beneath>: Now a method. All references
5630 updated.
5631 (class target_stack): New.
5632 * target.c (g_target_stack): New.
5633 (g_current_top_target): Delete.
5634 (current_top_target): Get the top target out of g_target_stack.
5635 (target_stack::push, target_stack::unpush): New.
5636 (push_target, unpush_target): Reimplement.
5637 (target_is_pushed): Reimplement in terms of g_target_stack.
5638 (target_ops::beneath, target_stack::find_beneath): New.
5639
5640 2018-06-07 Pedro Alves <palves@redhat.com>
5641
5642 * target.h (find_target_beneath): Delete declaration.
5643 * target.c (find_target_beneath): Delete definition.
5644 * aix-thread.c: All callers of find_target_beneath adjusted to
5645 call target_ops::beneath instead.
5646 * bsd-uthread.c: Likewise.
5647 * linux-thread-db.c: Likewise.
5648 * ravenscar-thread.c: Likewise.
5649 * sol-thread.c: Likewise.
5650 * spu-multiarch.c: Likewise.
5651
5652 2018-06-07 Pedro Alves <palves@redhat.com>
5653
5654 * target.h (target_ops) <beneath>: Now a method. All references
5655 updated.
5656 (target_ops) <m_beneath>: New.
5657 * target.c (target_ops::beneath): New.
5658 * corelow.c: Adjust all references to target_ops::beneath.
5659 * linux-thread-db.c: Likewise.
5660 * make-target-delegates: Likewise.
5661 * record-btrace.c: Likewise.
5662 * record-full.c: Likewise.
5663 * remote.c: Likewise.
5664 * target.c: Likewise.
5665 * target-delegates.c: Regenerate.
5666
5667 2018-06-07 Pedro Alves <palves@redhat.com>
5668
5669 * target.h (target_stack): Delete.
5670 (current_top_target): Declare function.
5671 * target.c (target_stack): Delete.
5672 (g_current_top_target): New.
5673 (current_top_target): New function.
5674 * auxv.c: Use current_top_target instead of target_stack
5675 throughout.
5676 * avr-tdep.c: Likewise.
5677 * breakpoint.c: Likewise.
5678 * corefile.c: Likewise.
5679 * elfread.c: Likewise.
5680 * eval.c: Likewise.
5681 * exceptions.c: Likewise.
5682 * frame.c: Likewise.
5683 * gdbarch-selftests.c: Likewise.
5684 * gnu-v3-abi.c: Likewise.
5685 * ia64-tdep.c: Likewise.
5686 * ia64-vms-tdep.c: Likewise.
5687 * infcall.c: Likewise.
5688 * infcmd.c: Likewise.
5689 * infrun.c: Likewise.
5690 * linespec.c: Likewise.
5691 * linux-tdep.c: Likewise.
5692 * minsyms.c: Likewise.
5693 * ppc-linux-nat.c: Likewise.
5694 * ppc-linux-tdep.c: Likewise.
5695 * procfs.c: Likewise.
5696 * regcache.c: Likewise.
5697 * remote.c: Likewise.
5698 * rs6000-tdep.c: Likewise.
5699 * s390-linux-nat.c: Likewise.
5700 * s390-tdep.c: Likewise.
5701 * solib-aix.c: Likewise.
5702 * solib-darwin.c: Likewise.
5703 * solib-dsbt.c: Likewise.
5704 * solib-spu.c: Likewise.
5705 * solib-svr4.c: Likewise.
5706 * solib-target.c: Likewise.
5707 * sparc-tdep.c: Likewise.
5708 * sparc64-tdep.c: Likewise.
5709 * spu-tdep.c: Likewise.
5710 * symfile.c: Likewise.
5711 * symtab.c: Likewise.
5712 * target-descriptions.c: Likewise.
5713 * target-memory.c: Likewise.
5714 * target.c: Likewise.
5715 * target.h: Likewise.
5716 * tracefile-tfile.c: Likewise.
5717 * tracepoint.c: Likewise.
5718 * valops.c: Likewise.
5719 * valprint.c: Likewise.
5720 * value.c: Likewise.
5721 * windows-tdep.c: Likewise.
5722 * mi/mi-main.c: Likewise.
5723
5724 2018-06-07 Tom Tromey <tom@tromey.com>
5725
5726 * valprint.h (build_address_symbolic): Declare.
5727 * printcmd.c (print_address_symbolic): Update.
5728 (build_address_symbolic): Change "name" and "filename" to
5729 std::string.
5730 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
5731 Update.
5732 * defs.h (build_address_symbolic): Remove declaration.
5733
5734 2018-06-07 Alan Hayward <alan.hayward@arm.com>
5735
5736 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
5737 (aarch64_vnv_type): Add function.
5738 (aarch64_pseudo_register_name): Add V regs for SVE.
5739 (aarch64_pseudo_register_type): Likewise.
5740 (aarch64_pseudo_register_reggroup_p): Likewise.
5741 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
5742 (aarch64_pseudo_read_value): Add V regs for SVE.
5743 (aarch64_pseudo_write_2): Use V0 offset for SVE
5744 (aarch64_pseudo_write): Add V regs for SVE.
5745 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
5746
5747 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
5748
5749 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
5750 (sve_vl_from_vq): Likewise.
5751
5752 2018-06-05 Tom Tromey <tom@tromey.com>
5753
5754 * cli/cli-cmds.c (show_version): Update.
5755 * top.c (print_gdb_version): Add "interactive" parameter.
5756 Update.
5757 * main.c (captured_main_1): Update.
5758 * top.h (print_gdb_version): Add "interactive" parameter and a
5759 comment.
5760
5761 2018-06-05 David Malcolm <dmalcolm@redhat.com>
5762
5763 * common/enum-flags.h: Add trailing semicolon to example in
5764 comment.
5765
5766 2018-06-05 Tom Tromey <tom@tromey.com>
5767
5768 PR cli/12326:
5769 * NEWS: Add entry about pager.
5770 * utils.c (pagination_disabled_for_command): New global.
5771 (prompt_for_continue): Allow "c" response to prompt.
5772 (reinitialize_more_filter): Clear
5773 pagination_disabled_for_command.
5774 (fputs_maybe_filtered): Check pagination_disabled_for_command.
5775
5776 2018-06-04 Tom Tromey <tom@tromey.com>
5777
5778 * ada-lang.h (ada_lookup_symbol_list): Update.
5779 * ada-lang.c (resolve_subexp): Update.
5780 (symbols_are_identical_enums): Change type of syms. Remove nsyms
5781 parameter.
5782 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
5783 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
5784 results parameter to std::vector.
5785 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
5786 Update.
5787 * ada-exp.y (block_lookup): Update.
5788 (select_possible_type_sym): Change type of syms. Remove nsyms
5789 parameter.
5790 (write_var_or_type, write_name_assoc): Update.
5791
5792 2018-06-04 Joel Brobecker <brobecker@adacore.com>
5793
5794 * windows-nat.c (windows_nat_target::xfer_partial): Return
5795 TARGET_XFER_E_IO if we need to delegate to the target beneath
5796 but BENEATH is NULL.
5797
5798 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
5799
5800 * Makefile.in (config.status): Add configure.nat as a
5801 dependency.
5802
5803 2018-06-04 Tom Tromey <tom@tromey.com>
5804
5805 * cp-name-parser.y (cpname_state): Add method declarations.
5806 (HANDLE_QUAL): Update.
5807 (cpname_state::d_grab, cpname_state::fill_comp)
5808 (cpname_state::make_operator, cpname_state::make_dtor)
5809 (cpname_state::make_builtin_type, cpname_state::make_name)
5810 (cpname_state::d_qualify, cpname_state::d_int_type)
5811 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
5812 (%union): Move earlier.
5813
5814 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5815
5816 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
5817
5818 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5819
5820 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
5821 (aarch64_pseudo_write_1): Likewise.
5822 (aarch64_pseudo_read_value): Use helper.
5823 (aarch64_pseudo_write): Likewise.
5824
5825 2018-06-04 Pedro Alves <palves@redhat.com>
5826
5827 * darwin-nat.c (darwin_ops): Delete.
5828 (darwin_attach_pid): Use get_native_target.
5829
5830 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5831
5832 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
5833 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
5834
5835 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5836
5837 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
5838 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
5839 (aarch64_gdbarch_init): Check for SVE.
5840 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
5841
5842 2018-06-04 Alan Hayward <alan.hayward@arm.com>
5843
5844 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
5845 * aarch64-tdep.h (aarch64_read_description): Likewise.
5846 * arch/aarch64.c (aarch64_create_target_description): Likewise.
5847 * arch/aarch64.h (aarch64_create_target_description): Likewise.
5848 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
5849 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
5850 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
5851
5852 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
5853
5854 * value.c (value_fetch_lazy_bitfield): New.
5855 (value_fetch_lazy_memory): New.
5856 (value_fetch_lazy_register): New.
5857 (value_fetch_lazy): Factor out to smaller functions.
5858
5859 2018-06-01 Tom Tromey <tom@tromey.com>
5860
5861 * cp-name-parser.y (backslashable, represented): Now const.
5862
5863 2018-06-01 Tom Tromey <tom@tromey.com>
5864
5865 * cp-name-parser.y: Include parser-defs.h.
5866 (parser_fprintf): Remove declaration.
5867
5868 2018-06-01 Tom Tromey <tom@tromey.com>
5869
5870 * cp-name-parser.y: Use %pure-parser, %lex-param, and
5871 %parse-param.
5872 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
5873 (global_result): Remove globals.
5874 (struct cpname_state): New.
5875 (yyparse): Don't declare.
5876 (yylex, yyerror): Move declarations after %union.
5877 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
5878 (make_name): Add state parameter.
5879 Update all callers.
5880 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
5881 parameter.
5882 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
5883 Update.
5884 (yylex): Add lvalp, state parameters.
5885 (yyerror): Add state parameter.
5886 (cp_demangled_name_to_comp): Update.
5887
5888 2018-06-01 Tom Tromey <tom@tromey.com>
5889
5890 * cp-name-parser.y (parser_fprintf): Declare.
5891 (GDB_YY_REMAP_PREFIX): Define.
5892 Include yy-remap.h. Don't redefine yy* identifiers.
5893
5894 2018-06-01 Tom Tromey <tom@tromey.com>
5895
5896 * python/py-type.c (typy_legacy_template_argument): Update.
5897 * cp-support.h (cp_demangled_name_to_comp): Update.
5898 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
5899 parameter to be a "std::string *".
5900 (main): Update.
5901
5902 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
5903
5904 * ada-lex.l: Include "diagnostics.h" instead of
5905 "common/diagnostics.h".
5906 * unittests/environ-selftests.c: Likewise.
5907 * common/diagnostics.h: Moved to ../include.
5908
5909 2018-06-01 Joel Brobecker <brobecker@adacore.com>
5910
5911 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
5912 to language_mode_manual while calling breakpoint_re_set_one.
5913
5914 2018-06-01 Tom Tromey <tom@tromey.com>
5915
5916 * valops.c (value_cast_structs, destructor_name_p): Update.
5917 * symtab.c (gdb_mangle_name): Update.
5918 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
5919 Update.
5920 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
5921 (pascal_object_print_value_fields, pascal_object_print_value):
5922 Update.
5923 * p-typeprint.c (pascal_type_print_derivation_info): Update.
5924 * linespec.c (find_methods): Update.
5925 * gdbtypes.h (type_name_no_tag): Remove.
5926 (type_name_or_error): Rename from type_name_no_tag_or_error.
5927 * gdbtypes.c (type_name_no_tag): Remove.
5928 (type_name_or_error): Rename from type_name_no_tag_or_error.
5929 (lookup_struct_elt_type, check_typedef): Update.
5930 * expprint.c (print_subexp_standard): Update.
5931 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
5932 * d-namespace.c (d_lookup_nested_symbol): Update.
5933 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
5934 (cp_print_class_member): Update.
5935 * cp-namespace.c (cp_lookup_nested_symbol): Update.
5936 * completer.c (add_struct_fields): Update.
5937 * c-typeprint.c (cp_type_print_derivation_info)
5938 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
5939 Update.
5940 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
5941 (ada_prefer_type, ada_is_exception_sym): Update.
5942
5943 2018-06-01 Tom Tromey <tom@tromey.com>
5944
5945 * valops.c (enum_constant_from_type, value_namespace_elt)
5946 (value_maybe_namespace_elt): Update.
5947 * valarith.c (find_size_for_pointer_math): Update.
5948 * target-descriptions.c (make_gdb_type): Update.
5949 * symmisc.c (print_symbol): Update.
5950 * stabsread.c (define_symbol, read_type)
5951 (complain_about_struct_wipeout, add_undefined_type)
5952 (cleanup_undefined_types_1): Update.
5953 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
5954 (rust_range_type_p, val_print_struct, rust_print_struct_def)
5955 (rust_internal_print_type, rust_composite_type)
5956 (rust_evaluate_funcall, rust_evaluate_subexp)
5957 (rust_inclusive_range_type_p): Update.
5958 * python/py-type.c (typy_get_tag): Update.
5959 * p-typeprint.c (pascal_type_print_base): Update.
5960 * mdebugread.c (parse_symbol, parse_type): Update.
5961 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
5962 Update.
5963 * guile/scm-type.c (gdbscm_type_tag): Update.
5964 * go-lang.c (sixg_string_p): Update.
5965 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
5966 Update.
5967 * gdbtypes.h (struct main_type) <tag_name>: Remove.
5968 (TYPE_TAG_NAME): Remove.
5969 * gdbtypes.c (type_name_no_tag): Simplify.
5970 (check_typedef, check_types_equal, recursive_dump_type)
5971 (copy_type_recursive, arch_composite_type): Update.
5972 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
5973 in summary mode when needed.
5974 * eval.c (evaluate_funcall): Update.
5975 * dwarf2read.c (fixup_go_packaging, read_structure_type)
5976 (process_structure_scope, read_enumeration_type)
5977 (read_namespace_type, read_module_type, determine_prefix): Update.
5978 * cp-support.c (inspect_type): Update.
5979 * coffread.c (process_coff_symbol, decode_base_type): Update.
5980 * c-varobj.c (c_is_path_expr_parent): Update.
5981 * c-typeprint.c (c_type_print_base_struct_union): Update.
5982 (c_type_print_base_1): Update. Print struct/class/union/enum in
5983 summary when using C language.
5984 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
5985 (gen_maybe_namespace_elt): Update.
5986 * ada-lang.c (ada_type_name): Simplify.
5987 (empty_record, ada_template_to_fixed_record_type_1)
5988 (template_to_static_fixed_type)
5989 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
5990
5991 2018-06-01 Tom Tromey <tom@tromey.com>
5992
5993 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
5994 c_print_type.
5995 * c-typeprint.c (c_print_type_1): Add "language" parameter.
5996 (c_print_type): Update.
5997 (c_print_type): New overload.
5998 (c_type_print_varspec_prefix, c_type_print_args)
5999 (c_type_print_varspec_suffix, c_print_type_no_offsets)
6000 (c_type_print_base_struct_union, c_type_print_base_1)
6001 (cp_type_print_method_args): Add "language" parameter.
6002 (c_type_print_base): Update.
6003 * c-lang.h (c_print_type): Add new overload.
6004
6005 2018-06-01 Tom Tromey <tom@tromey.com>
6006
6007 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
6008 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
6009
6010 2018-06-01 Alan Hayward <alan.hayward@arm.com>
6011
6012 * aarch64-tdep.c (aarch64_sve_register_names): New const
6013 var.
6014 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
6015 (AARCH64_SVE_Z_REGS_NUM): New define.
6016 (AARCH64_SVE_P_REGS_NUM): Likewise.
6017 (AARCH64_SVE_NUM_REGS): Likewise.
6018
6019 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
6020
6021 * nat/linux-ptrace.h [__alpha__]
6022 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
6023 definitions.
6024
6025 2018-05-31 Maciej W. Rozycki <macro@mips.com>
6026
6027 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
6028 the endianness selected.
6029 * NEWS: Document `set endian auto' mode operation update.
6030
6031 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6032
6033 * Makefile.in: Add new header.
6034 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
6035 (sve_vl_from_vg): Likewise.
6036 (sve_vq_from_vl): Likewise.
6037 (sve_vl_from_vq): Likewise.
6038 (sve_vq_from_vg): Likewise.
6039 (sve_vg_from_vq): Likewise.
6040 * configure.nat: Add new c file.
6041 * nat/aarch64-sve-linux-ptrace.c: New file.
6042 * nat/aarch64-sve-linux-ptrace.h: New file.
6043
6044 2018-05-31 Alan Hayward <alan.hayward@arm.com>
6045
6046 * aarch64-linux-nat.c (aarch64_linux_read_description):
6047 Add parmeter zero.
6048 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
6049 Likewise.
6050 * aarch64-tdep.c (tdesc_aarch64_list): Add.
6051 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
6052 (aarch64_gdbarch_init): Add parmeter zero.
6053 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
6054 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
6055 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
6056 parmeter.
6057 * doc/gdb.texinfo: Describe SVE feature
6058 * features/aarch64-sve.c: New file.
6059
6060 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
6061
6062 PR gdb/23210
6063 * gdbarch.sh (significant_addr_bit): Default to zero when
6064 not set by target architecture.
6065 * gdbarch.c: Re-generated.
6066 * utils.c (address_significant): Update.
6067
6068 2018-05-30 Joel Brobecker <brobecker@adacore.com>
6069
6070 * stack.c (func_command): Remove trailing newline in call to error.
6071
6072 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6073
6074 * regcache.h (regcache_raw_collect): Remove, update callers to
6075 use regcache::raw_collect.
6076 * regcache.c (regcache_raw_collect): Remove.
6077
6078 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6079
6080 * regcache.h (regcache_raw_supply): Remove, update callers to
6081 use detached_regcache::raw_supply.
6082 * regcache.c (regcache_raw_supply): Remove.
6083
6084 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6085
6086 * regcache.h (regcache_cooked_write_part): Remove, update
6087 callers to use regcache::cooked_write_part.
6088 * regcache.c (regcache_cooked_write_part): Remove.
6089
6090 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6091
6092 * regcache.h (regcache_cooked_read_part): Remove, update callers
6093 to use readable_regcache::cooked_read_part.
6094 * regcache.c (regcache_cooked_read_part): Remove.
6095
6096 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6097
6098 * regcache.h (regcache_cooked_read_value): Remove, update
6099 callers to use readable_regcache::cooked_read_value.
6100 * regcache.c (regcache_cooked_read_value): Remove.
6101
6102 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6103
6104 * regcache.h (regcache_cooked_write): Remove, update callers to
6105 use regcache::cooked_write.
6106 * regcache.c (regcache_cooked_write): Remove.
6107
6108 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6109
6110 * regcache.h (regcache_invalidate): Remove, update callers to
6111 use detached_regcache::invalidate instead.
6112 * regcache.c (regcache_invalidate): Remove.
6113
6114 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6115
6116 * regcache.h (regcache_raw_write_part): Remove, update callers
6117 to use regcache::raw_write_part instead.
6118 * regcache.c (regcache_raw_write_part): Remove.
6119
6120 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6121
6122 * regcache.h (regcache_raw_read_part): Remove, update callers to
6123 use readable_regcache::raw_read_part instead.
6124 * regcache.c (regcache_raw_read_part): Remove.
6125
6126 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6127
6128 * regcache.h (regcache_cooked_read): Remove, update callers to
6129 use readable_regcache::cooked_read instead.
6130 * regcache.c (regcache_cooked_read): Remove.
6131
6132 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6133
6134 * regcache.h (regcache_raw_write): Remove, update callers to use
6135 regcache::raw_write instead.
6136 * regcache.c (regcache_raw_write): Remove.
6137
6138 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6139
6140 * regcache.h (regcache_raw_read): Remove, update callers to use
6141 readable_regcache::raw_read instead.
6142 * regcache.c (regcache_raw_read): Remove.
6143
6144 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6145
6146 * regcache.h (regcache_raw_update): Remove, update callers to
6147 use readable_regcache::raw_update instead.
6148 * regcache.c (regcache_raw_update): Remove.
6149
6150 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6151
6152 * regcache.h (regcache_register_status): Remove, update callers
6153 to use reg_buffer::get_register_status directly instead.
6154 * regcache.c (regcache_register_status): Remove.
6155
6156 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6157
6158 * regcache.h (regcache_get_ptid): Remove, update all callers to
6159 call regcache::ptid instead.
6160 * regcache.c (regcache_get_ptid): Remove.
6161
6162 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
6163
6164 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
6165
6166 2018-05-30 Pedro Alves <palves@redhat.com>
6167
6168 * common/common-exceptions.h (exception_rethrow): Use
6169 ATTRIBUTE_NORETURN.
6170
6171 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
6172
6173 * breakpoint.c (print_solib_event, check_status_catch_solib):
6174 Remove struct keyword in range-based for loops.
6175 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
6176 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
6177 Likewise.
6178 * linespec.c (find_superclass_methods, search_minsyms_for_name):
6179 Likewise.
6180 * symfile.c (addr_info_make_relative): Likewise.
6181 * thread.c (value_in_thread_stack_temporaries): Likewise.
6182
6183 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
6184
6185 PR gdb/16841
6186 * valops.c (value_struct_elt_for_reference): Call check_typedef on
6187 aggregate type to get its real type before accessing it.
6188
6189 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
6190
6191 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
6192 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
6193 * coff-pe-read.c (add_pe_forwarded_sym): Replace
6194 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
6195 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
6196 * jit.c (jit_breakpoint_re_set_internal): Likewise.
6197 * printcmd.c (info_address_command): Likewise.
6198
6199 2018-05-29 Tom Tromey <tom@tromey.com>
6200
6201 * windows-nat.c (handle_exception): Update fall-through comment.
6202
6203 2018-05-29 Tom Tromey <tom@tromey.com>
6204
6205 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
6206 (struct program_space) <added_solibs>: Now a std::vector.
6207 * breakpoint.c (print_solib_event): Update.
6208 (check_status_catch_solib): Update.
6209 * progspace.c (clear_program_space_solib_cache): Update.
6210 * solib.c (update_solib_list): Update.
6211
6212 2018-05-29 Tom Tromey <tom@tromey.com>
6213
6214 * python/py-type.c (typy_richcompare): Update.
6215 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
6216 * gdbtypes.h (types_deeply_equal): Return bool.
6217 (types_equal): Likewise.
6218 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
6219 declare VEC.
6220 (check_types_equal): Change worklist to std::vector. Return
6221 bool.
6222 (struct type_equality_entry): Add constructor.
6223 (compare_maybe_null_strings): Return bool.
6224 (check_types_worklist): Return bool. Change worklist to
6225 std::vector.
6226 (types_deeply_equal): Use std::vector.
6227 (types_equal): Return bool.
6228 (compare_maybe_null_strings): Simplify.
6229
6230 2018-05-29 Tom Tromey <tom@tromey.com>
6231
6232 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
6233
6234 2018-05-29 Tom Tromey <tom@tromey.com>
6235
6236 * objc-lang.h: Don't include cp-support.h.
6237 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
6238 declare VEC.
6239
6240 2018-05-27 Tom Tromey <tom@tromey.com>
6241
6242 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
6243
6244 2018-05-25 Tom Tromey <tom@tromey.com>
6245
6246 * value.c (value::location): Initialize.
6247
6248 2018-05-25 Tom Tromey <tom@tromey.com>
6249
6250 * dbxread.c (init_bincl_list): Remove.
6251 (bincl_list): Now a std::vector.
6252 (bincls_allocated, next_bincl): Remove.
6253 (free_bincl_list, do_free_bincl_list_cleanup)
6254 (make_cleanup_free_bincl_list): Remove.
6255 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
6256 unique_xmalloc_ptr.
6257 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
6258 (struct header_file_location): Add constructor.
6259 (add_bincl_to_list): Remove.
6260
6261 2018-05-25 Tom Tromey <tom@tromey.com>
6262
6263 * tui/tui.c (tui_enable): Update.
6264 * mi/mi-interp.c (mi_interp::init): Update.
6265 * interps.h (class interp) <name>: New method.
6266 <m_name>: Rename from name.
6267 (~scoped_restore_interp): Update.
6268 * interps.c (interp::interp): Update.
6269 (interp_add, interp_set, interp_lookup_existing)
6270 (current_interp_named_p): Update.
6271
6272 2018-05-25 Tom Tromey <tom@tromey.com>
6273
6274 * interps.c (interp_name): Remove.
6275 * mi/mi-interp.c (mi_interp::init): Update.
6276 * interps.h (interp_name): Remove.
6277 (~scoped_restore_interp): Update.
6278 * tui/tui.c (tui_enable): Update.
6279
6280 2018-05-25 Tom Tromey <tom@tromey.com>
6281
6282 * utils.c (fputs_maybe_filtered): Update.
6283 * linespec.c (decode_line_full): Update.
6284 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
6285 (mi_print_breakpoint_for_event, mi_solib_loaded)
6286 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6287 (mi_user_selected_context_changed): Update.
6288 * mi/mi-main.c (mi_execute_command): Update.
6289 * cli/cli-script.c (execute_control_command): Update.
6290 * python/python.c (execute_gdb_command): Update.
6291 * solib.c (info_sharedlibrary_command): Update.
6292 * interps.c (interp_ui_out): Remove.
6293 * interps.h (interp_ui_out): Remove.
6294
6295 2018-05-25 Tom Tromey <tom@tromey.com>
6296
6297 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
6298 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
6299 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
6300
6301 2018-05-25 Tom Tromey <tom@tromey.com>
6302
6303 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
6304 * interps.c (interp_exec): Use scoped_restore.
6305
6306 2018-05-25 Tom Tromey <tom@tromey.com>
6307
6308 * remote.c (remote_target::remote_file_get): Use
6309 gdb::byte_vector.
6310 (remote_target::remote_file_put): Likewise.
6311
6312 2018-05-25 Tom Tromey <tom@tromey.com>
6313
6314 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
6315 a std::string.
6316 (get_pe_section_index, add_pe_exported_sym): Update.
6317 (read_pe_exported_syms): Use gdb::def_vector.
6318
6319 2018-05-25 Tom Tromey <tom@tromey.com>
6320
6321 * frame.c (remove_prev_frame): Remove.
6322 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
6323
6324 2018-05-25 Maciej W. Rozycki <macro@mips.com>
6325
6326 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
6327 Remove prototypes.
6328 * mips-linux-nat.c (supply_fpregset): Always call
6329 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
6330 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
6331 `mips_fill_fpregset'.
6332 * mips-linux-tdep.c (mips_supply_fpregset)
6333 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
6334 (mips_fill_fpregset_wrapper): Remove functions.
6335 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
6336 (mips_linux_fpregset): Remove variable.
6337 (mips_linux_iterate_over_regset_sections): Use
6338 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
6339 (mips_linux_o32_sigframe_init): Remove comment.
6340
6341 2018-05-25 Pedro Alves <palves@redhat.com>
6342
6343 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
6344 (struct readahead_cache, struct packet_reg, struct
6345 remote_arch_state, class remote_state): Move higher up in the
6346 file.
6347 (remote_target::m_remote_state): Now an object instead of a pointer.
6348 (remote_target::get_remote_state): Adjust.
6349
6350 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6351
6352 * stack.c (select_and_print_frame): Delete.
6353 (struct function_bounds): Move struct within function.
6354 (func_command): Most content moved into new function
6355 find_frame_for_function, use new function, print result, add
6356 function comment.
6357 (find_frame_for_function): New function, now returns a result.
6358
6359 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6360
6361 * stack.c (iterate_over_block_arg_vars): Fix comment.
6362 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
6363
6364 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
6365
6366 PR gdb/23203
6367 * frame.c
6368 (scoped_restore_selected_frame::scoped_restore_selected_frame):
6369 Define.
6370 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
6371 Define.
6372 * frame.h (class scoped_restore_selected_frame): New class.
6373 * stack.c (print_frame_local_vars): Remove catching and rethrowing
6374 of any exception, use scoped_restore_selected_frame to restore the
6375 frame instead.
6376
6377 2018-05-24 Pedro Alves <palves@redhat.com>
6378
6379 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
6380 override.
6381
6382 2018-05-23 Tom Tromey <tom@tromey.com>
6383
6384 * complaints.c (struct complaints): Remove.
6385 (symfile_complaint_book): Remove.
6386 (series): New global.
6387 (complaint_internal): Update.
6388 (clear_complaints): Update.
6389
6390 2018-05-23 Tom Tromey <tom@tromey.com>
6391
6392 * complaints.c (counters): New global.
6393 (struct complain): Remove.
6394 (struct complaints) <root>: Remove.
6395 (complaint_sentinel): Remove.
6396 (symfile_complaint_book): Update.
6397 (find_complaint) Remove.
6398 (complaint_internal, clear_complaints): Update.
6399
6400 2018-05-23 Tom Tromey <tom@tromey.com>
6401
6402 * complaints.c (struct complain) <file, line>: Remove.
6403 (find_complaint): Remove file, line parameters.
6404 (complaint_internal): Update.
6405
6406 2018-05-23 Tom Tromey <tom@tromey.com>
6407
6408 * complaints.c (vcomplaint): Remove.
6409 (complaint_internal) Merge in contents of vcomplaint.
6410
6411 2018-05-23 Tom Tromey <tom@tromey.com>
6412
6413 * complaints.c (struct complaints) <explanation>: Remove.
6414 (symfile_explanations): Remove.
6415 (symfile_complaint_book): Update.
6416 (vcomplaint): Update.
6417 (struct explanation): Remove.
6418
6419 2018-05-23 Tom Tromey <tom@tromey.com>
6420
6421 * complaints.c (symfile_complaints): Remove.
6422 (complaint_internal): Remove "complaints" parameter.
6423 (clear_complaints, vcomplaint): Remove "c" parameter.
6424 (get_complaints): Remove.
6425 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
6426 (dwarf2_debug_line_missing_file_complaint)
6427 (dwarf2_debug_line_missing_end_sequence_complaint)
6428 (dwarf2_complex_location_expr_complaint)
6429 (dwarf2_const_value_length_mismatch_complaint)
6430 (dwarf2_section_buffer_overflow_complaint)
6431 (dwarf2_macro_malformed_definition_complaint)
6432 (dwarf2_invalid_attrib_class_complaint)
6433 (create_addrmap_from_index, dw2_symtab_iter_next)
6434 (dw2_expand_marked_cus)
6435 (dw2_debug_names_iterator::find_vec_in_debug_names)
6436 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
6437 (create_debug_type_hash_table, init_cutu_and_read_dies)
6438 (partial_die_parent_scope, add_partial_enumeration)
6439 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
6440 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
6441 (read_import_statement, read_file_scope, create_dwo_cu_reader)
6442 (create_cus_hash_table, create_dwp_hash_table)
6443 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
6444 (dwarf2_rnglists_process, dwarf2_ranges_process)
6445 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
6446 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
6447 (handle_struct_member_die, process_structure_scope)
6448 (read_array_type, read_common_block, read_module_type)
6449 (read_tag_pointer_type, read_typedef, read_base_type)
6450 (read_subrange_type, load_partial_dies, partial_die_info::read)
6451 (partial_die_info::read, partial_die_info::read)
6452 (partial_die_info::read, read_checked_initial_length_and_offset)
6453 (dwarf2_string_attr, read_formatted_entries)
6454 (dwarf_decode_line_header)
6455 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6456 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
6457 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
6458 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6459 (get_signatured_type, get_DW_AT_signature_type)
6460 (decode_locdesc, file_file_name, consume_improper_spaces)
6461 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
6462 (dwarf_decode_macro_bytes, dwarf_decode_macros)
6463 (dwarf2_symbol_mark_computed, set_die_type)
6464 (read_attribute_value): Update.
6465 * stap-probe.c (handle_stap_probe, get_stap_base_address):
6466 Update.
6467 * dbxread.c (unknown_symtype_complaint)
6468 (lbrac_mismatch_complaint, repeated_header_complaint)
6469 (set_namestring, function_outside_compilation_unit_complaint)
6470 (read_dbx_symtab, process_one_symbol): Update.
6471 * gdbtypes.c (stub_noname_complaint): Update.
6472 * windows-nat.c (handle_unload_dll): Update.
6473 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
6474 (decode_base_type): Update.
6475 * xcoffread.c (bf_notfound_complaint, ef_complaint)
6476 (eb_complaint, record_include_begin, record_include_end)
6477 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
6478 (process_xcoff_symbol, read_symbol)
6479 (function_outside_compilation_unit_complaint)
6480 (scan_xcoff_symtab): Update.
6481 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
6482 * buildsym.c (finish_block_internal, make_blockvector)
6483 (end_symtab_get_static_block, augment_type_symtab): Update.
6484 * dtrace-probe.c (dtrace_process_dof)
6485 (dtrace_static_probe_ops::get_probes): Update.
6486 * complaints.h (struct complaint): Don't declare.
6487 (symfile_complaints): Remove.
6488 (complaint_internal): Remove "complaints" parameter.
6489 (complaint): Likewise.
6490 (clear_complaints): Likewise.
6491 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6492 (reread_symbols): Update.
6493 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
6494 (dwarf2_frame_cache, decode_frame_entry): Update.
6495 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
6496 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6497 (info_selectors_command): Update.
6498 * macrotab.c (macro_include, check_for_redefinition)
6499 (macro_undef): Update.
6500 * objfiles.c (filter_overlapping_sections): Update.
6501 * stabsread.c (invalid_cpp_abbrev_complaint)
6502 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
6503 (define_symbol, error_type, read_type, rs6000_builtin_type)
6504 (stabs_method_name_from_physname, read_member_functions)
6505 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
6506 (attach_fields_to_type, complain_about_struct_wipeout)
6507 (read_range_type, read_args, common_block_start)
6508 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
6509 Update.
6510 * mdebugread.c (index_complaint, unknown_ext_complaint)
6511 (basic_type_complaint, bad_tag_guess_complaint)
6512 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
6513 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
6514 (parse_procedure, parse_lines)
6515 (function_outside_compilation_unit_complaint)
6516 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
6517 (bad_tag_guess_complaint, reg_value_complaint): Update.
6518 * cp-support.c (demangled_name_complaint): Update.
6519 * macroscope.c (sal_macro_scope): Update.
6520 * dwarf-index-write.c (class debug_names): Update.
6521
6522 2018-05-23 Tom Tromey <tom@tromey.com>
6523
6524 * complaints.c (clear_complaints): Remove "noisy" parameter.
6525 * complaints.h (clear_complaints): Update.
6526 * symfile.c (syms_from_objfile_1, finish_new_objfile)
6527 (reread_symbols): Update.
6528
6529 2018-05-23 Tom Tromey <tom@tromey.com>
6530
6531 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
6532 SUBSEQUENT_MESSAGE.
6533 (vcomplaint, clear_complaints): Update.
6534 (symfile_explanations): Remove some messages.
6535
6536 2018-05-23 Tom Tromey <tom@tromey.com>
6537
6538 * complaints.c (internal_complaint): Remove.
6539 * complaints.h (internal_complaint): Remove.
6540
6541 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6542
6543 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
6544
6545 2018-05-22 Pedro Alves <palves@redhat.com>
6546
6547 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
6548 (remote_fileio_badfd, remote_fileio_return_errno)
6549 (remote_fileio_return_success, remote_fileio_func_open)
6550 (remote_fileio_func_open, remote_fileio_func_close)
6551 (remote_fileio_func_read, remote_fileio_func_write)
6552 (remote_fileio_func_lseek, remote_fileio_func_rename)
6553 (remote_fileio_func_unlink, remote_fileio_func_stat)
6554 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
6555 (remote_fileio_func_isatty, remote_fileio_func_system): Add
6556 remote_target parameter.
6557 (remote_fio_func_map) <func>: Add remote_target parameter.
6558 (do_remote_fileio_request, remote_fileio_request):
6559 * remote-fileio.h (remote_fileio_request):
6560 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
6561 remote_target parameter.
6562 (remote_notif_process, handle_notification): Adjust to pass down
6563 the remote.
6564 (remote_notif_state_allocate): Add remote_target parameter. Save
6565 it.
6566 * remote-notif.h (struct remote_target): Forward declare.
6567 (struct notif_client) <parse, ack, can_get_pending_events>: Add
6568 remote_target parameter.
6569 (struct remote_notif_state) <remote>: New field.
6570 (remote_notif_ack, remote_notif_parse): Add remote_target
6571 parameter.
6572 (remote_notif_state_allocate, remote_notif_state_allocate): Add
6573 remote_target parameter.
6574 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
6575 (threads_listing_context, rmt_thread_action, protocol_feature)
6576 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
6577 (packet_result, struct threads_listing_context, remote_state):
6578 Move definitions and declarations higher up.
6579 (remote_target) <~remote_target>: Declare.
6580 (remote_download_command_source, remote_file_put, remote_file_get)
6581 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
6582 (remote_hostio_pread_vFile, remote_hostio_send_command)
6583 (remote_hostio_set_filesystem, remote_hostio_open)
6584 (remote_hostio_close, remote_hostio_unlink, remote_state)
6585 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
6586 (get_memory_write_packet_size, get_memory_read_packet_size)
6587 (append_pending_thread_resumptions, remote_detach_1)
6588 (append_resumption, remote_resume_with_vcont)
6589 (add_current_inferior_and_thread, wait_ns, wait_as)
6590 (process_stop_reply, remote_notice_new_inferior)
6591 (process_initial_stop_replies, remote_add_thread)
6592 (btrace_sync_conf, remote_btrace_maybe_reopen)
6593 (remove_new_fork_children, kill_new_fork_children)
6594 (discard_pending_stop_replies, stop_reply_queue_length)
6595 (check_pending_events_prevent_wildcard_vcont)
6596 (discard_pending_stop_replies_in_queue, stop_reply)
6597 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
6598 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
6599 (remote_interrupt_as, remote_interrupt_ns)
6600 (remote_get_noisy_reply, remote_query_attached)
6601 (remote_add_inferior, remote_current_thread, get_current_thread)
6602 (set_thread, set_general_thread, set_continue_thread)
6603 (set_general_process, write_ptid)
6604 (remote_unpack_thread_info_response, remote_get_threadinfo)
6605 (parse_threadlist_response, remote_get_threadlist)
6606 (remote_threadlist_iterator, remote_get_threads_with_ql)
6607 (remote_get_threads_with_qxfer)
6608 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
6609 (get_offsets, remote_check_symbols, remote_supported_packet)
6610 (remote_query_supported, remote_packet_size)
6611 (remote_serial_quit_handler, remote_detach_pid)
6612 (remote_vcont_probe, remote_resume_with_hc)
6613 (send_interrupt_sequence, interrupt_query)
6614 (remote_notif_get_pending_events, fetch_register_using_p)
6615 (send_g_packet, process_g_packet, fetch_registers_using_g)
6616 (store_register_using_P, store_registers_using_G)
6617 (set_remote_traceframe, check_binary_download)
6618 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
6619 (remote_xfer_live_readonly_partial, remote_read_bytes)
6620 (remote_send_printf, remote_flash_write, readchar)
6621 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
6622 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
6623 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
6624 (extended_remote_disable_randomization, extended_remote_run)
6625 (send_environment_packet, extended_remote_environment_support)
6626 (extended_remote_set_inferior_cwd, remote_write_qxfer)
6627 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
6628 (packet_command): Now methods of ...
6629 (remote_target): ... this class.
6630 (m_remote_state) <remote_target>: New field.
6631 (struct remote_state) <stop_reply_queue,
6632 remote_async_inferior_event_token, wait_forever_enabled_p>: New
6633 fields.
6634 (remote_state::remote_state): Allocate stop_reply_queue.
6635 (remote_state): Delete global.
6636 (get_remote_state_raw): Delete.
6637 (remote_target::get_remote_state): Allocate m_remote_state on
6638 demand.
6639 (get_current_remote_target): New.
6640 (remote_ops, extended_remote_ops): Delete.
6641 (wait_forever_enabled_p, remote_async_inferior_event_token):
6642 Delete, moved to struct remote_state.
6643 (remote_target::close): Delete self. Destruction bits split to
6644 ...
6645 (remote_target::~remote_target): ... this.
6646 (show_memory_packet_size): Adjust to use
6647 get_current_remote_target.
6648 (struct protocol_feature) <func>: Add remote_target parameter.
6649 All callers adjusted.
6650 (curr_quit_handler_target): New.
6651 (remote_serial_quit_handler): Reimplement.
6652 (remote_target::open_1): Adjust to use get_current_remote_target.
6653 Heap-allocate remote_target/extended_remote_target instances.
6654 (vcont_builder::vcont_builder): Add remote_target parameter, and
6655 save it in m_remote. All callers adjusted.
6656 (vcont_builder::m_remote): New field.
6657 (vcont_builder::restart, vcont_builder::flush)
6658 (vcont_builder::push_action): Use it.
6659 (remote_target::commit_resume): Use it.
6660 (struct queue_iter_param) <remote>: New field.
6661 (remote_target::remove_new_fork_children): Fill in 'remote' field.
6662 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
6663 (check_pending_event_prevents_wildcard_vcont_callback)
6664 (remote_target::check_pending_events_prevent_wildcard_vcont)
6665 (remote_target::discard_pending_stop_replies)
6666 (remote_target::discard_pending_stop_replies_in_queue)
6667 (remote_target::remote_notif_remove_queued_reply): Fill in
6668 'remote' field.
6669 (remote_notif_get_pending_events): New.
6670 (remote_target::readchar, remote_target::remote_serial_write):
6671 Save/restore curr_quit_handler_target.
6672 (putpkt): New.
6673 (kill_new_fork_children): Fill in 'remote' field.
6674 (packet_command): Use get_current_remote_target, defer to
6675 remote_target method of same name.
6676 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
6677 parameter, and save it in m_remote. All callers adjusted.
6678 (scoped_remote_fd::release): Use m_remote.
6679 (scoped_remote_fd::m_remote): New field.
6680 (remote_file_put, remote_file_get, remote_file_delete): Use
6681 get_current_remote_target, defer to remote_target method of same
6682 name.
6683 (remote_btrace_reset): Add remote_state paremeter. Update all
6684 callers.
6685 (remote_async_inferior_event_handler). Pass down 'data'.
6686 (remote_new_objfile): Use get_current_remote_target.
6687 (remote_target::vcont_r_supported): New.
6688 (set_range_stepping): Use get_current_remote_target and
6689 remote_target::vcont_r_supported.
6690 (_initialize_remote): Don't allocate 'remote_state' and
6691 'stop_reply_queue' globals.
6692 * remote.h (struct remote_target): Forward declare.
6693 (getpkt, putpkt, remote_notif_get_pending_events): Add
6694 'remote_target' parameter.
6695
6696 2018-05-22 Pedro Alves <palves@redhat.com>
6697
6698 * remote.c (vcont_builder): Now a class. Make all data members
6699 private.
6700 (vcont_builder) <vcont_builder, restart, flush, push_action>:
6701 Declare methods.
6702 (vcont_builder_restart): Rename to ...
6703 (vcont_builder::restart): ... this.
6704 (vcont_builder_flush): Rename to ...
6705 (vcont_builder::flush): ... this.
6706 (vcont_builder_push_action): Rename to ...
6707 (vcont_builder::push_action): ... this.
6708 (remote_target::commit_resume): Adjust.
6709
6710 2018-05-22 Pedro Alves <palves@redhat.com>
6711
6712 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
6713 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
6714 (get_fixed_memory_packet_size): New.
6715 (get_memory_packet_size): Use it.
6716 (set_memory_packet_size): Don't override the config size with
6717 DEFAULT_MAX_MEMORY_PACKET_SIZE.
6718 (show_memory_packet_size): Use get_fixed_memory_packet_size.
6719 Don't refer to get_memory_packet_size if not connected to a remote
6720 target. Show "(default)" if configured size is 0.
6721
6722 2018-05-22 Pedro Alves <palves@redhat.com>
6723
6724 * remote.c (remote_target::mourn_inferior): Move
6725 discard_pending_stop_replies call here from ...
6726 (_initialize_remote): ... here.
6727
6728 2018-05-22 Pedro Alves <palves@redhat.com>
6729
6730 * remote.c (compare_section_command): Remove set_general_process
6731 call.
6732
6733 2018-05-22 Pedro Alves <palves@redhat.com>
6734
6735 * remote.c (struct packet_reg, struct remote_arch_state):
6736 Move higher up in the file.
6737 (remote_state) <m_arch_states>: Store remote_arch_state values
6738 instead of remote_arch_state pointers.
6739 (remote_state::get_remote_arch_state): Adjust.
6740
6741 2018-05-22 Pedro Alves <palves@redhat.com>
6742
6743 * remote.c: Include <unordered_map>.
6744 (remote_state): Now a class.
6745 (remote_state) <get_remote_arch_state>: Declare method.
6746 <get_remote_arch_state>: New field.
6747 (remote_arch_state) <remote_arch_state>: Declare ctor.
6748 <regs>: Now a unique_ptr.
6749 (remote_gdbarch_data_handle): Delete.
6750 (get_remote_arch_state): Delete.
6751 (remote_state::get_remote_arch_state): New.
6752 (get_remote_state): Adjust to call remote_state's
6753 get_remote_arch_state method.
6754 (init_remote_state): Delete, bits factored out to ...
6755 (remote_arch_state::remote_arch_state): ... this new method.
6756 (get_remote_packet_size, get_memory_packet_size)
6757 (process_g_packet, remote_target::fetch_registers)
6758 (remote_target::prepare_to_store, store_registers_using_G)
6759 (remote_target::store_registers, remote_target::get_trace_status):
6760 Adjust to call remote_state's method.
6761 (_initialize_remote): Remove reference to
6762 remote_gdbarch_data_handle.
6763
6764 2018-05-22 Pedro Alves <palves@redhat.com>
6765
6766 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
6767 pread>: New method declarations.
6768 (remote_target::open_1): Adjust.
6769 (readahead_cache_invalidate): Rename to ...
6770 (readahead_cache::invalidate): ... this, and adjust to be a class
6771 method.
6772 (readahead_cache_invalidate_fd): Rename to ...
6773 (readahead_cache::invalidate_fd): ... this, and adjust to be a
6774 class method.
6775 (remote_hostio_pwrite): Adjust.
6776 (remote_hostio_pread_from_cache): Rename to ...
6777 (readahead_cache::pread): ... this, and adjust to be a class
6778 method.
6779 (remote_hostio_close): Adjust.
6780
6781 2018-05-22 Pedro Alves <palves@redhat.com>
6782
6783 * remote.c (remote_hostio_close_cleanup): Delete.
6784 (class scoped_remote_fd): New.
6785 (remote_file_put, remote_file_get): Use it.
6786
6787 2018-05-22 Pedro Alves <palves@redhat.com>
6788
6789 (struct vCont_action_support): Use bool and initialize all fields.
6790 (struct readahead_cache): Initialize all fields.
6791 (remote_state): Use bool and initialize all fields.
6792 (remote_state::remote_state, remote_state::~remote_state): New.
6793 (new_remote_state): Delete.
6794 (_initialize_remote): Use new to allocate remote_state.
6795
6796 2018-05-22 Pedro Alves <palves@redhat.com>
6797 張俊芝 <zjz@zjz.name>
6798
6799 PR gdb/22973
6800 * c-exp.y: Include "c-support.h".
6801 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
6802 of tolower. Use c_ident_is_alpha to scan names.
6803 * c-lang.c: Include "c-support.h".
6804 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
6805 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
6806 * c-support.h: New file, with bits factored out from ...
6807 * cp-name-parser.y: ... this file.
6808 Include "c-support.h".
6809 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
6810 c-support.h and renamed.
6811 (symbol_end, yylex): Adjust.
6812
6813 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6814
6815 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
6816 parameter type to CORE_ADDR.
6817 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
6818 parameter type in declaration to CORE_ADDR.
6819 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
6820 target_auxv_search to get AT_HWCAP and use the result to get the
6821 target description.
6822 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
6823 to CORE_ADDR. Remove the cast of the return value to unsigned
6824 long. Fix error predicate of target_auxv_search.
6825 (ppc_linux_nat_target::read_description): Change the type of the
6826 hwcap variable to CORE_ADDR.
6827
6828 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6829
6830 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
6831 if the size of fpscr is larger than 32 bits.
6832
6833 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6834
6835 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
6836 (ppc32_linux_vsxregmap): New global.
6837 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
6838 regcache_supply_regset, and regcache_collect_regset.
6839 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
6840 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
6841 (fetch_vsx_register, store_vsx_register): Remove.
6842 (fetch_vsx_registers): Add regno parameter. Get regset using
6843 ppc_linux_vsxregset. Use regset to supply registers.
6844 (store_vsx_registers): Add regno parameter. Get regset using
6845 ppc_linux_vsxregset. Use regset to collect registers.
6846 (fetch_register): Call fetch_vsx_registers instead of
6847 fetch_vsx_register.
6848 (store_register): Call store_vsx_registers instead of
6849 store_vsx_register.
6850 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
6851 new regno parameter.
6852 (store_ppc_registers): Call store_vsx_registers with -1 for the
6853 new regno parameter.
6854 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
6855 (ppc_collect_vsxregset): Remove.
6856
6857 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6858
6859 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
6860 offset fields.
6861 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
6862 for vector register offset fields.
6863 (ppc64_fbsd_reg_offsets): Likewise.
6864 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6865 to vector register offset fields.
6866 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
6867 to vector register offset fields.
6868 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
6869 vector register offset fields.
6870 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
6871 initializers for vector register offset fields.
6872 (rs6000_aix64_reg_offsets): Likewise.
6873 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
6874 (ppc_supply_vrregset): Remove.
6875 (ppc_collect_vrregset): Remove.
6876 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
6877 (ppc_linux_vrregset) : New function.
6878 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
6879 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
6880 (ppc32_linux_vrregset): Remove.
6881 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
6882 and use result instead of ppc32_linux_vrregset.
6883 (ppc32_linux_reg_offsets): Remove initializers for vector register
6884 offset fields.
6885 (ppc64_linux_reg_offsets): Likewise.
6886 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
6887 * ppc-linux-nat.c: Include regset.h.
6888 (gdb_vrregset_t): Adjust comment to account for little-endian
6889 mode.
6890 (supply_vrregset, fill_vrregset): Remove.
6891 (fetch_altivec_register, store_altivec_register): Remove.
6892 (fetch_altivec_registers): Add regno parameter. Get regset using
6893 ppc_linux_vrregset. Use regset to supply registers.
6894 (store_altivec_registers): Add regno parameter. Get regset using
6895 ppc_linux_vrregset. Use regset to collect registers.
6896 (fetch_register): Call fetch_altivec_registers instead of
6897 fetch_altivec_register.
6898 (store_register): Call store_altivec_registers instead of
6899 store_altivec_register.
6900 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
6901 the new regno parameter.
6902 (store_ppc_registers): Call store_altivec_registers with -1 for
6903 the new regno parameter.
6904
6905 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6906
6907 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
6908 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
6909 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6910 (gdb_vrregset_t): Change array type size to
6911 PPC_LINUX_SIZEOF_VRREGSET.
6912 (gdb_vsxregset_t): Change array type size to
6913 PPC_LINUX_SIZEOF_VSXREGSET.
6914 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
6915 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
6916 PPC_LINUX_SIZEOF_VSXREGSET.
6917
6918 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6919
6920 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
6921 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
6922 nat/ppc-linux.c.
6923 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
6924 ppc_linux_target_wordsize with tid.
6925 (ppc_linux_nat_target::read_description): Call ppc_linux_target
6926 wordsize with tid.
6927 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
6928 (ppc64_64bit_inferior_p): Add static and inline specifiers.
6929 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
6930 tid parameter. Remove static specifier.
6931 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
6932 (ppc_linux_target_wordsize): New declaration.
6933
6934 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6935
6936 * arch/ppc-linux-common.c: New file.
6937 * arch/ppc-linux-common.h: New file.
6938 * arch/ppc-linux-tdesc.h: New file.
6939 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
6940 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
6941 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
6942 arch/ppc-linux-tdesc.h.
6943 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
6944 arch/ppc-linux-tdesc.h.
6945 (ppc_linux_nat_target::read_description): Remove target
6946 description matching code. Fill a ppc_linux_features struct and
6947 call ppc_linux_match_description with it. Move comment about ISA
6948 2.05 to ppc-linux-common.c.
6949 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
6950 arch/ppc-linux-tdesc.h.
6951 (ppc_linux_core_read_description): Remove target description
6952 matching code. Fill a ppc_linux_features struct and call
6953 ppc_linux_match_description with it.
6954 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6955 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6956 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6957 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6958 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6959 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6960 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6961 (tdesc_powerpc_e500l): Remove.
6962
6963 2018-05-22 Joel Brobecker <brobecker@adacore.com>
6964
6965 * ada-lang.c (catch_assert_command): Pass empty string instead
6966 of NULL for excep_string argument.
6967
6968 2018-05-22 Maciej W. Rozycki <macro@mips.com>
6969
6970 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
6971 the width of the requested register exceeds the width of the
6972 `ptrace' data type.
6973
6974 2018-05-21 Tom Tromey <tom@tromey.com>
6975
6976 * printcmd.c (output_command): Remove.
6977 (output_command_const): Rename to output_command.
6978 * valprint.h (output_command): Rename from output_command_const.
6979 * tracepoint.c (trace_dump_actions): Call output_command.
6980
6981 2018-05-21 Tom Tromey <tom@tromey.com>
6982
6983 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6984 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
6985 * ada-lang.h (create_ada_exception_catchpoint): Update.
6986 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
6987 std::string.
6988 (create_excep_cond_exprs, ~ada_catchpoint)
6989 (should_stop_exception, print_one_exception)
6990 (print_mention_exception, print_recreate_exception): Update.
6991 (ada_get_next_arg): Remove.
6992 (catch_ada_exception_command_split): Use std::string. Change type
6993 of "excep_string", "cond_string".
6994 (catch_ada_exception_command): Update.
6995 (create_ada_exception_catchpoint): Change type of excep_string.
6996 (ada_exception_sal): Remove excep_string parameter.
6997 (~ada_catchpoint): Remove.
6998
6999 2018-05-21 Tom Tromey <tom@tromey.com>
7000
7001 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
7002 cleanup.
7003
7004 2018-05-21 Tom Tromey <tom@tromey.com>
7005
7006 * ada-lang.c (ada_exception_message_1, ada_exception_message):
7007 Return unique_xmalloc_ptr.
7008 (print_it_exception): Update.
7009
7010 2018-05-21 Tom Tromey <tom@tromey.com>
7011
7012 * tracepoint.c (trace_dump_actions): Use std::string.
7013
7014 2018-05-21 Tom Tromey <tom@tromey.com>
7015
7016 * symfile.c (reread_symbols): Use std::string for original_name.
7017
7018 2018-05-21 Tom Tromey <tom@tromey.com>
7019
7020 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
7021 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
7022 constructor.
7023
7024 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
7025
7026 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
7027 instance to...
7028 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
7029 * objfiles.c (get_objfile_bfd_data): Allocate
7030 objfile_per_bfd_storage with obstack_new when allocating on
7031 obstack.
7032
7033 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7034
7035 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
7036 OBSTACK_ZALLOC.
7037 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
7038 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
7039 * mdebugread.c (mdebug_build_psymtabs): Likewise.
7040 (add_pending): Likewise.
7041 (parse_symbol): Likewise.
7042 (parse_partial_symbols): Likewise.
7043 (psymtab_to_symtab_1): Likewise.
7044 (new_psymtab): Likewise.
7045 (elfmdebug_build_psymtabs): Likewise.
7046 * minsyms.c (terminate_minimal_symbol_table): Likewise.
7047 * objfiles.c (get_objfile_bfd_data): Likewise.
7048 (objfile_register_static_link): Likewise.
7049 * psymtab.c (allocate_psymtab): Likewise.
7050 * stabsread.c (read_member_functions): Likewise.
7051 * xcoffread.c (xcoff_end_psymtab): Likewise.
7052
7053 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
7054
7055 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
7056 compiler supports std::is_trivially_constructible.
7057 * common/poison.h: Include obstack.h.
7058 (IsMallocable): Define to is_trivially_constructible if the
7059 compiler supports it, define to true_type otherwise.
7060 (xobnew): New.
7061 (XOBNEW): Redefine.
7062 (xobnewvec): New.
7063 (XOBNEWVEC): Redefine.
7064 * gdb_obstack.h (obstack_zalloc): New.
7065 (OBSTACK_ZALLOC): Redefine.
7066 (obstack_calloc): New.
7067 (OBSTACK_CALLOC): Redefine.
7068 (obstack_new): New.
7069 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
7070 (gdbarch_obstack): New declaration in gdbarch.h, definition in
7071 gdbarch.c.
7072 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
7073 obstack_calloc/obstack_zalloc.
7074 (gdbarch_obstack_zalloc): Remove.
7075 * target-descriptions.c (tdesc_data_init): Use obstack_new.
7076
7077 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7078
7079 * stack.c (backtrace_command_1): Remove useless variable int i.
7080
7081 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7082
7083 * stack.c (print_frame_info): Fix comment.
7084
7085 2018-05-18 Tom Tromey <tom@tromey.com>
7086
7087 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
7088 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
7089 (~dwarf2_per_objfile): Update
7090 (dwarf2_get_dwz_file): Use new.
7091 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
7092 unique_ptr.
7093
7094 2018-05-18 Tom Tromey <tom@tromey.com>
7095
7096 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
7097 unique_ptr.
7098 * dwarf2read.c (struct dwp_file): Add constructor and
7099 initializers.
7100 (open_and_init_dwp_file): Return a unique_ptr.
7101 (dwarf2_per_objfile, create_dwp_hash_table)
7102 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
7103 (lookup_dwo_unit_in_dwp): Update.
7104 (open_and_init_dwp_file, get_dwp_file): Update.
7105
7106 2018-05-18 Tom Tromey <tom@tromey.com>
7107
7108 * dwarf2read.c (dwarf2_per_objfile): Update.
7109 (struct mapped_index): Add initializers.
7110 (dwarf2_read_index): Use new.
7111 (dw2_symtab_iter_init): Update.
7112 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
7113 unique_ptr.
7114
7115 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7116
7117 * dwarf2read.c (mapped_index) <total_size>: Remove.
7118
7119 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
7120
7121 * unittests/format_pieces-selftests.c (test_format_specifier):
7122 Add ARI comments.
7123
7124 2018-05-18 Tom Tromey <tom@tromey.com>
7125
7126 * c-typeprint.c (maybe_print_hole): New function.
7127 (c_print_type_struct_field_offset): Update.
7128 (c_type_print_base_struct_union): Call maybe_print_hole.
7129
7130 2018-05-17 Keith Seitz <keiths@redhat.com>
7131
7132 * breakpoint.c (build_bpstat_chain): New function, moved from
7133 bpstat_stop_status.
7134 (bpstat_stop_status): Add optional parameter, `stop_chain'.
7135 If no stop chain is passed, call build_bpstat_chain to build it.
7136 * breakpoint.h (build_bpstat_chain): Declare.
7137 (bpstat_stop_status): Move documentation here from breakpoint.c.
7138 * infrun.c (handle_signal_stop): Before eliding inlined frames,
7139 build the stop chain and pass it to skip_inline_frames.
7140 Pass this stop chain to bpstat_stop_status.
7141 * inline-frame.c: Include breakpoint.h.
7142 (stopped_by_user_bp_inline_frame): New function.
7143 (skip_inline_frames): Add parameter `stop_chain'.
7144 Move documention to inline-frame.h.
7145 If non-NULL, use stopped_by_user_bp_inline_frame to determine
7146 whether the frame should be elided.
7147 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
7148 Add moved documentation and update for new parameter.
7149
7150 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7151
7152 PR cli/14975
7153 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7154 unittests/format_pieces-selftests.c.
7155 * common/format.h (format_piece) <operator==>: New.
7156 (format_pieces) <operator[]>: Remove.
7157 * common/format.c (format_pieces::format_pieces): Handle \e.
7158 * unittests/format_pieces-selftests.c: New.
7159
7160 2018-05-17 Tom Tromey <tom@tromey.com>
7161
7162 PR symtab/23010:
7163 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
7164 (dw2_instantiate_symtab): Add skip_partial parameter.
7165 (dw2_find_last_source_symtab, dw2_map_expand_apply)
7166 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
7167 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
7168 (dw2_expand_symtabs_matching_one)
7169 (dw2_find_pc_sect_compunit_symtab)
7170 (dw2_debug_names_lookup_symbol)
7171 (dw2_debug_names_expand_symtabs_for_function): Update.
7172 (init_cutu_and_read_dies): Add skip_partial parameter.
7173 (process_psymtab_comp_unit, build_type_psymtabs_1)
7174 (process_skeletonless_type_unit, load_partial_comp_unit)
7175 (psymtab_to_symtab_1): Update.
7176 (load_full_comp_unit): Add skip_partial parameter.
7177 (process_imported_unit_die, dwarf2_read_addr_index)
7178 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
7179 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
7180 (read_signatured_type): Update.
7181
7182 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
7183
7184 * value.c (release_value): Remove unused variable.
7185 (record_latest_value): Likewise.
7186 (access_value_history): Likewise.
7187 (preserve_values): Likewise.
7188
7189 2018-05-17 Tom Tromey <tom@tromey.com>
7190
7191 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
7192 Initialize.
7193
7194 2018-05-16 Maciej W. Rozycki <macro@mips.com>
7195
7196 PR gdb/22286
7197 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
7198 Also handle registers whose width is not a multiple of
7199 PTRACE_TYPE_RET.
7200 (linux_nat_trad_target::store_register): Likewise.
7201
7202 2018-05-16 Tom Tromey <tom@tromey.com>
7203
7204 * gdbcore.h (core_bfd): Redefine.
7205 * corelow.c (core_target::close): Update.
7206 (core_target_open): Update.
7207 * progspace.h (struct program_space) <cbfd>: Now a
7208 gdb_bfd_ref_ptr.
7209
7210 2018-05-16 Tom Tromey <tom@tromey.com>
7211
7212 PR cli/19551:
7213 * symfile-add-flags.h (enum symfile_add_flags)
7214 <SYMFILE_NOT_FILENAME>: New constant.
7215 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
7216 objfile name from BFD.
7217 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
7218 * minidebug.c (find_separate_debug_file_in_section): Put
7219 ".gnu_debugdata" into BFD's file name.
7220
7221 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
7222
7223 * regcache.c (regcache_read_ftype, regcache_write_ftype):
7224 Remove.
7225
7226 2018-05-15 Tamar Christina <tamar.christina@arm.com>
7227
7228 PR binutils/21446
7229 * aarch64-tdep.c (aarch64_analyze_prologue,
7230 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
7231 Indicate not interested in errors.
7232
7233 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7234
7235 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
7236 Supply the MIPS_ZERO_REGNUM register.
7237
7238 2018-05-15 Maciej W. Rozycki <macro@mips.com>
7239
7240 * mips-tdep.c (mask_address_var): Make variable static.
7241
7242 2018-05-14 Tom Tromey <tom@tromey.com>
7243
7244 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
7245
7246 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
7247
7248 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
7249 FXSAVE_ADDR for the mxcsr register.
7250
7251 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
7252
7253 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
7254
7255 2018-05-11 Pedro Alves <palves@redhat.com>
7256
7257 * corelow.c (core_target) <core_target>: No longer inline.
7258 Initialize m_core_gdbarch, m_core_vec and build the section table
7259 here.
7260 <~core_target>: New.
7261 <core_gdbarch, get_core_register_section>: New methods.
7262 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
7263 factored out from ...
7264 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
7265 (core_ops): Delete.
7266 (sniff_core_bfd): Add gdbarch parameter.
7267 (core_close): Delete, merged into ...
7268 (core_target::close): ... here. Delete self.
7269 (core_close_cleanup): Delete.
7270 (core_target_open): Allocate a core_target on the heap. Use a
7271 unique_ptr instead of a cleanup. Bits moved into the core_target
7272 ctor. Adjust to use core_target methods instead of globals.
7273 (get_core_register_section): Rename to ...
7274 (core_target::get_core_register_section): ... this and adjust.
7275 (struct get_core_registers_cb_data): New.
7276 (get_core_registers_cb): Use it. Use bool.
7277 (core_target::fetch_registers, core_target::files_info)
7278 (core_target::xfer_partial, core_target::read_description)
7279 (core_target::pid_to, core_target::thread_name): Adjust to
7280 reference class fields instead of globals.
7281 * target.h (struct target_ops_deleter, target_ops_up): New.
7282
7283 2018-05-11 Pedro Alves <palves@redhat.com>
7284
7285 * corefile.c (core_file_command): Move to corelow.c.
7286 * corelow.c (the_core_target): Delete.
7287 (core_file_command): Moved from corefile.c. Check exec_bfd
7288 instead of the_core_target. Use target_detach instead of calling
7289 into the_core_target directly.
7290 (maybe_say_no_core_file_now): New.
7291 (core_target::detach): Use it.
7292 (_initialize_corelow): Remove references to the_core_target.
7293 * gdbcore.h (the_core_target): Delete.
7294
7295 2018-05-11 Tom Tromey <tromey@redhat.com>
7296 Pedro Alves <palves@redhat.com>
7297
7298 * corefile.c (core_bfd): Remove.
7299 * gdbcore.h (core_bfd): Now a macro.
7300 * progspace.h (struct program_space) <cbfd>: New field.
7301
7302 2018-05-11 Tom Tromey <tom@tromey.com>
7303
7304 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
7305 gdb::def_vector.
7306
7307 2018-05-10 Tom Tromey <tom@tromey.com>
7308
7309 * configure: Rebuild.
7310 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
7311
7312 2018-05-10 Joel Brobecker <brobecker@adacore.com>
7313
7314 PR server/23158:
7315 * regformats/regdat.sh: Adjust script, following the addition
7316 of the new expedite_regs parameter to init_target_desc.
7317
7318 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
7319
7320 PR gdb/23127
7321 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
7322 set_gdbarch_significant_addr_bit.
7323 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
7324 set_gdbarch_significant_addr_bit.
7325 * utils.c (address_significant): Update to sign extend addr.
7326
7327 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
7328
7329 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
7330 (xtensa_linux_init_abi): Limit tdep->num_regs by
7331 tdep->num_nopriv_regs.
7332 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
7333 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
7334 not initialized.
7335
7336 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
7337
7338 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
7339
7340 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
7341
7342 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
7343 (I387_MXCSR_INIT_VAL): New constant.
7344 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
7345 buffer if it was supplied by the inferior.
7346 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
7347 (i387_xsave_get_clear_bv): New function.
7348 (i387_supply_xsave): Only read x87 control registers from the
7349 xsave buffer if the feature is enabled, and the state will have
7350 been written, otherwise, provide a suitable default.
7351 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
7352 including x87 control registers. Update control registers if they
7353 have changed from the default value, and mark features as enabled
7354 as required.
7355 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
7356
7357 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
7358
7359 * spu-tdep.c (info_spu_event_command): Fix output formatting.
7360
7361 2018-05-07 Tom Tromey <tom@tromey.com>
7362
7363 * configure: Rebuild.
7364 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
7365
7366 2018-05-07 Tom Tromey <tom@tromey.com>
7367
7368 PR tdep/20362:
7369 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
7370 bit. Use correct value for VDIV.
7371
7372 2018-05-04 Tom Tromey <tom@tromey.com>
7373
7374 * configure: Rebuild.
7375 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
7376
7377 2018-05-04 Tom Tromey <tom@tromey.com>
7378
7379 * linux-record.c (record_linux_system_call) <case
7380 RECORD_SYS_RECVFROM>: Add "break".
7381
7382 2018-05-04 Tom Tromey <tom@tromey.com>
7383
7384 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
7385 Add missing "break".
7386 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
7387 Add missing "break".
7388
7389 2018-05-04 Tom Tromey <tom@tromey.com>
7390
7391 * rs6000-tdep.c (ppc_process_record_op4)
7392 (ppc_process_record_op63): Add fall-through comment.
7393
7394 2018-05-04 Tom Tromey <tom@tromey.com>
7395
7396 * i386-tdep.c (i386_process_record): Add fall-through comment.
7397
7398 2018-05-04 Tom Tromey <tom@tromey.com>
7399
7400 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
7401 comment.
7402
7403 2018-05-04 Tom Tromey <tom@tromey.com>
7404
7405 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
7406 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
7407 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
7408 comment.
7409 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
7410 comment.
7411 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
7412 comment.
7413
7414 2018-05-04 Tom Tromey <tom@tromey.com>
7415
7416 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
7417
7418 2018-05-04 Tom Tromey <tom@tromey.com>
7419
7420 * s390-tdep.c (s390_process_record): Fix fall-through comments.
7421 * xcoffread.c (scan_xcoff_symtab): Move comment later.
7422 * symfile.c (section_is_mapped): Fix fall-through comment.
7423 * stabsread.c (define_symbol, read_member_functions): Fix
7424 fall-through comment.
7425 * s390-linux-tdep.c (s390_process_record): Fix fall-through
7426 comment.
7427 * remote.c (remote_wait_as): Fix fall-through comment.
7428 * p-exp.y (yylex): Fix fall-through comment.
7429 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
7430 comment.
7431 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
7432 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
7433 * jv-exp.y (yylex): Fix fall-through comment.
7434 * go-exp.y (lex_one_token): Fix fall-through comment.
7435 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
7436 fall-through comment.
7437 * f-exp.y (yylex): Fix fall-through comment.
7438 * dwarf2read.c (process_die): Fix fall-through comments.
7439 * dbxread.c (process_one_symbol): Fix fall-through comment.
7440 * d-exp.y (lex_one_token): Fix fall-through comment.
7441 * cp-name-parser.y (yylex): Fix fall-through comment.
7442 * coffread.c (coff_symtab_read): Fix fall-through comment.
7443 * c-exp.y (lex_one_token): Fix fall-through comment.
7444 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
7445 comment.
7446 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
7447 comment.
7448
7449 2018-05-04 Tom Tromey <tom@tromey.com>
7450
7451 PR python/22730:
7452 * NEWS: Mention gdb.execute change.
7453 * gdbcmd.h (execute_control_command): Don't declare.
7454 * python/python.c (execute_gdb_command): Use read_command_lines_1,
7455 execute_control_commands, execute_control_commands_to_string.
7456 * cli/cli-script.h (execute_control_commands)
7457 (execute_control_commands_to_string): Declare.
7458 (execute_control_command): Add from_tty parameter.
7459 * cli/cli-script.c (execute_control_commands)
7460 (execute_control_commands_to_string): New functions.
7461 (execute_user_command): Use execute_control_commands.
7462 (execute_control_command_1): Add "from_tty" parameter. Update.
7463 (execute_control_command): Likewise.
7464
7465 2018-05-04 Tom Tromey <tom@tromey.com>
7466
7467 PR python/22731:
7468 * NEWS: Mention that breakpoint commands are writable.
7469 * python/py-breakpoint.c (bppy_set_commands): New function.
7470 (breakpoint_object_getset) <"commands">: Use it.
7471
7472 2018-05-04 Tom Tromey <tom@tromey.com>
7473
7474 * tracepoint.c (actions_command): Update.
7475 * mi/mi-cmd-break.c (mi_command_line_array)
7476 (mi_command_line_array_cnt, mi_command_line_array_ptr)
7477 (mi_read_next_line): Remove.
7478 (mi_cmd_break_commands): Update.
7479 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
7480 function_view.
7481 * cli/cli-script.c (get_command_line): Update.
7482 (process_next_line): Use function_view. Constify.
7483 (recurse_read_control_structure, read_command_lines)
7484 (read_command_lines_1): Change argument types to function_view.
7485 (do_define_command, document_command): Update.
7486 * breakpoint.h (check_tracepoint_command): Don't declare.
7487 * breakpoint.c (check_tracepoint_command): Remove.
7488 (commands_command_1, create_tracepoint_from_upload): Update.
7489
7490 2018-05-04 Tom Tromey <tom@tromey.com>
7491
7492 PR gdb/11750:
7493 * cli/cli-script.h (enum command_control_type) <define_control>:
7494 New constant.
7495 * cli/cli-script.c (multi_line_command_p): Handle define_control.
7496 (build_command_line, execute_control_command_1)
7497 (process_next_line): Likewise.
7498 (do_define_command): New function, extracted from define_command.
7499 (define_command): Use it.
7500
7501 2018-05-04 Tom Tromey <tom@tromey.com>
7502
7503 * tracepoint.c (actions_command): Update.
7504 * cli/cli-script.h (read_command_lines): Update.
7505 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
7506 (MAX_TMPBUF): Remove define.
7507 (define_command): Use string_printf.
7508 (document_command): Likewise.
7509 * breakpoint.c (commands_command_1): Update.
7510
7511 2018-05-04 Tom Tromey <tom@tromey.com>
7512
7513 * top.c (execute_command): Update.
7514 * cli/cli-script.h (print_command_lines): Now varargs.
7515 * cli/cli-script.c (print_command_lines): Now varargs.
7516 (execute_control_command_1) <case while_control, case if_control>:
7517 Update.
7518
7519 2018-05-04 Tom Tromey <tom@tromey.com>
7520
7521 * tracepoint.c (all_tracepoint_actions): Rename from
7522 all_tracepoint_actions_and_cleanup. Change return type.
7523 (actions_command, encode_actions_1, encode_actions)
7524 (trace_dump_actions, tdump_command): Update.
7525 * remote.c (remote_download_command_source): Update.
7526 * python/python.c (gdbpy_eval_from_control_command)
7527 (python_command, python_interactive_command): Update.
7528 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7529 * guile/guile.c (guile_command)
7530 (gdbscm_eval_from_control_command, guile_command): Update.
7531 * compile/compile.c (compile_code_command)
7532 (compile_print_command, compile_to_object): Update.
7533 * cli/cli-script.h (struct command_lines_deleter): New.
7534 (counted_command_line): New typedef.
7535 (struct command_line): Add constructor, destructor.
7536 <body_list>: Remove.
7537 <body_list_0, body_list_1>: New members.
7538 (command_line_up): Remove typedef.
7539 (read_command_lines, read_command_lines_1, get_command_line):
7540 Update.
7541 (copy_command_lines): Don't declare.
7542 * cli/cli-script.c (build_command_line): Use "new".
7543 (get_command_line): Return counted_command_line.
7544 (print_command_lines, execute_user_command)
7545 (execute_control_command_1, while_command, if_command): Update.
7546 (realloc_body_list): Remove.
7547 (process_next_line, recurse_read_control_structure): Update.
7548 (read_command_lines, read_command_lines_1): Return counted_command_line.
7549 (free_command_lines): Use "delete".
7550 (copy_command_lines): Remove.
7551 (define_command, document_command, show_user_1): Update.
7552 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
7553 a counted_command_line.
7554 * breakpoint.h (counted_command_line): Remove typedef.
7555 (breakpoint_set_commands): Update.
7556 * breakpoint.c (check_no_tracepoint_commands)
7557 (validate_commands_for_breakpoint): Update.
7558 (breakpoint_set_commands): Change commands to be a
7559 counted_command_line.
7560 (commands_command_1, update_dprintf_command_list)
7561 (create_tracepoint_from_upload): Update.
7562
7563 2018-05-04 Tom Tromey <tom@tromey.com>
7564
7565 * cli/cli-decode.h (cmd_list_element): New constructor.
7566 (~cmd_list_element): New destructor.
7567 (struct cmd_list_element): Add initializers.
7568 * cli/cli-decode.c (do_add_cmd): Use "new".
7569 (delete_cmd): Use "delete".
7570
7571 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
7572 Pedro Alves <palves@redhat.com>
7573
7574 PR breakpoints/19806 and support for PR external/20207.
7575 * NEWS: Mention Aarch64 watchpoint improvements.
7576 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
7577 watchpoints and PR external/20207 watchpoints.
7578 * nat/aarch64-linux-hw-point.c
7579 (kernel_supports_any_contiguous_range): New.
7580 (aarch64_watchpoint_offset): New.
7581 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
7582 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
7583 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
7584 (aarch64_align_watchpoint): New parameters aligned_offset_p and
7585 next_addr_orig_p. Support PR external/20207 watchpoints.
7586 (aarch64_downgrade_regs): New.
7587 (aarch64_dr_state_insert_one_point): New parameters offset and
7588 addr_orig.
7589 (aarch64_dr_state_remove_one_point): Likewise.
7590 (aarch64_handle_breakpoint): Update caller.
7591 (aarch64_handle_aligned_watchpoint): Likewise.
7592 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
7593 aligned_offset.
7594 (aarch64_linux_set_debug_regs): Remove const from state. Call
7595 aarch64_downgrade_regs.
7596 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
7597 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
7598 (DR_CONTROL_MASK): ... this.
7599 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
7600 (unsigned int aarch64_watchpoint_offset): New prototype.
7601 (aarch64_linux_set_debug_regs): Remove const from state.
7602 * utils.c (align_up, align_down): Move to ...
7603 * common/common-utils.c (align_up, align_down): ... here.
7604 * utils.h (align_up, align_down): Move to ...
7605 * common/common-utils.h (align_up, align_down): ... here.
7606
7607 2018-05-04 Joel Brobecker <brobecker@adacore.com>
7608
7609 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
7610 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
7611 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
7612 Re-implement to match the ABI as summarized in GCC's
7613 gcc/config/sparc/sparc.c. All callers updated.
7614 (sparc32_store_arguments): Remove assertion.
7615
7616 2018-05-04 Tom Tromey <tom@tromey.com>
7617
7618 * printcmd.c: Don't include tui.h.
7619 (decode_format): Use skip_spaces.
7620
7621 2018-05-04 Tom Tromey <tom@tromey.com>
7622
7623 PR gdb/22619:
7624 * printcmd.c (last_count): New global.
7625 (x_command): Use saved count when repeating.
7626
7627 2018-05-04 Tom Tromey <tom@tromey.com>
7628
7629 * nto-procfs.c (do_closedir_cleanup): Remove.
7630 (procfs_pidlist): Use gdb_dir_up.
7631 * procfs.c (do_closedir_cleanup): Remove.
7632 (proc_update_threads): Use gdb_dir_up.
7633 * common/filestuff.h (struct gdb_dir_deleter): New.
7634 (gdb_dir_up): New typedef.
7635
7636 2018-05-04 Tom Tromey <tom@tromey.com>
7637
7638 * ada-lang.c (print_mention_exception): Use std::string.
7639
7640 2018-05-04 Tom Tromey <tom@tromey.com>
7641
7642 * ada-lang.c (create_excep_cond_exprs): Update.
7643 (ada_exception_catchpoint_cond_string): Use std::string.
7644
7645 2018-05-04 Tom Tromey <tom@tromey.com>
7646
7647 * ada-lang.c (xget_renaming_scope): Return std::string.
7648 (old_renaming_is_invisible): Update.
7649
7650 2018-05-04 Tom Tromey <tom@tromey.com>
7651
7652 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
7653 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
7654
7655 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
7656
7657 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
7658
7659 2018-05-04 Tom Tromey <tom@tromey.com>
7660
7661 * remote.c (remote_query_supported_append): Change type.
7662 (remote_check_symbols): Update.
7663
7664 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
7665
7666 PR gdb/11420
7667 * configure.ac: Prepend libpython.
7668 * python/python-config.py: Likewise.
7669 * configure: Regenerate.
7670
7671 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
7672
7673 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
7674
7675 2018-05-03 Pedro Alves <palves@redhat.com>
7676
7677 * s390-linux-nat.c
7678 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
7679 override. Write 'true' instead of '1'.
7680 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
7681 declaration.
7682
7683 2018-05-02 Pedro Alves <palves@redhat.com>
7684
7685 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
7686 add_inf_child_target.
7687 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
7688 add_inf_child_target.
7689 * aix-thread.c (aix_thread_target_info): New.
7690 (aix_thread_target) <shortname, longname, doc>: Delete.
7691 <info>: New.
7692 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
7693 add_inf_child_target.
7694 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
7695 add_inf_child_target.
7696 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
7697 add_inf_child_target.
7698 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
7699 add_inf_child_target.
7700 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
7701 add_inf_child_target.
7702 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
7703 add_inf_child_target.
7704 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
7705 add_inf_child_target.
7706 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
7707 add_inf_child_target.
7708 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
7709 add_inf_child_target.
7710 * bfd-target.c (target_bfd_target_info): New.
7711 (target_bfd) <shortname, longname, doc>: Delete.
7712 <info>: New.
7713 * bsd-kvm.c (bsd_kvm_target_info): New.
7714 (bsd_kvm_target) <shortname, longname, doc>: Delete.
7715 <info>: New.
7716 (bsd_kvm_target::open): Rename to ...
7717 (bsd_kvm_target_open): ... this. Adjust.
7718 * bsd-uthread.c (bsd_uthread_target_info): New.
7719 (bsd_uthread_target) <shortname, longname, doc>: Delete.
7720 <info>: New.
7721 * corefile.c (core_file_command): Adjust.
7722 * corelow.c (core_target_info): New.
7723 (core_target) <shortname, longname, doc>: Delete.
7724 <info>: New.
7725 (core_target::open): Rename to ...
7726 (core_target_open): ... this. Adjust.
7727 * ctf.c (ctf_target_info): New.
7728 (ctf_target) <shortname, longname, doc>: Delete.
7729 <info>: New.
7730 (ctf_target::open): Rename to ...
7731 (ctf_target_open): ... this.
7732 (_initialize_ctf): Adjust.
7733 * exec.c (exec_target_info): New.
7734 (exec_target) <shortname, longname, doc>: Delete.
7735 <info>: New.
7736 (exec_target::open): Rename to ...
7737 (exec_target_open): ... this.
7738 * gdbcore.h (core_target_open): Declare.
7739 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
7740 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
7741 add_inf_child_target.
7742 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
7743 add_inf_child_target.
7744 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
7745 add_inf_child_target.
7746 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
7747 add_inf_child_target.
7748 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
7749 add_inf_child_target.
7750 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
7751 add_inf_child_target.
7752 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
7753 add_inf_child_target.
7754 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
7755 add_inf_child_target.
7756 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
7757 add_inf_child_target.
7758 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
7759 add_inf_child_target.
7760 * inf-child.c (inf_child_target_info): New.
7761 (inf_child_target::info): New.
7762 (inf_child_open_target): Remove 'target' parameter. Use
7763 get_native_target instead.
7764 (inf_child_target::open): Delete.
7765 (add_inf_child_target): New.
7766 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
7767 Delete.
7768 <info>: New.
7769 (add_inf_child_target): Declare.
7770 (inf_child_open_target): Declare.
7771 * linux-thread-db.c (thread_db_target_info): New.
7772 (thread_db_target) <shortname, longname, doc>: Delete.
7773 <info>: New.
7774 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
7775 add_inf_child_target.
7776 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
7777 add_inf_child_target.
7778 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
7779 add_inf_child_target.
7780 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
7781 add_inf_child_target.
7782 * make-target-delegates (print_class): Adjust.
7783 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
7784 add_inf_child_target.
7785 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
7786 add_inf_child_target.
7787 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
7788 add_inf_child_target.
7789 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
7790 add_inf_child_target.
7791 * nto-procfs.c (nto_native_target_info): New.
7792 (nto_procfs_target_native) <shortname, longname, doc>:
7793 Delete.
7794 <info>: New.
7795 (nto_procfs_target_info): New.
7796 (nto_procfs_target_procfs) <shortname, longname, doc>:
7797 Delete.
7798 <info>: New.
7799 (init_procfs_targets): Adjust.
7800 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
7801 add_inf_child_target.
7802 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
7803 add_inf_child_target.
7804 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
7805 add_inf_child_target.
7806 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
7807 add_inf_child_target.
7808 * ravenscar-thread.c (ravenscar_target_info): New.
7809 (ravenscar_thread_target) <shortname, longname, doc>:
7810 Delete.
7811 <info>: New.
7812 * record-btrace.c (record_btrace_target_info):
7813 (record_btrace_target) <shortname, longname, doc>: Delete.
7814 <info>: New.
7815 (record_btrace_target::open): Rename to ...
7816 (record_btrace_target_open): ... this. Adjust.
7817 * record-full.c (record_longname, record_doc): New.
7818 (record_full_base_target) <shortname, longname, doc>: Delete.
7819 <info>: New.
7820 (record_full_target_info): New.
7821 (record_full_target): <shortname>: Delete.
7822 <info>: New.
7823 (record_full_core_open_1, record_full_open_1): Update comments.
7824 (record_full_base_target::open): Rename to ...
7825 (record_full_open): ... this.
7826 (cmd_record_full_restore): Update.
7827 (_initialize_record_full): Update.
7828 * remote-sim.c (remote_sim_target_info): New.
7829 (gdbsim_target) <shortname, longname, doc>: Delete.
7830 <info>: New.
7831 (gdbsim_target::open): Rename to ...
7832 (gdbsim_target_open): ... this.
7833 (_initialize_remote_sim): Adjust.
7834 * remote.c (remote_doc): New.
7835 (remote_target_info): New.
7836 (remote_target) <shortname, longname, doc>: Delete.
7837 <info>: New.
7838 (extended_remote_target_info): New.
7839 (extended_remote_target) <shortname, longname, doc>: Delete.
7840 <info>: New.
7841 (remote_target::open_1): Make static. Adjust.
7842 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
7843 * s390-linux-nat.c (_initialize_s390_nat): Use
7844 add_inf_child_target.
7845 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
7846 add_inf_child_target.
7847 * sol-thread.c (thread_db_target_info): New.
7848 (sol_thread_target) <shortname, longname, doc>: Delete.
7849 <info>: New.
7850 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
7851 add_inf_child_target.
7852 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
7853 add_inf_child_target.
7854 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
7855 add_inf_child_target.
7856 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
7857 add_inf_child_target.
7858 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
7859 add_inf_child_target.
7860 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
7861 add_inf_child_target.
7862 * spu-linux-nat.c (_initialize_spu_nat): Use
7863 add_inf_child_target.
7864 * spu-multiarch.c (spu_multiarch_target_info): New.
7865 (spu_multiarch_target) <shortname, longname, doc>: Delete.
7866 <info>: New.
7867 * target-delegates.c: Regenerate.
7868 * target.c: Include <unordered_map>.
7869 (target_ops_p): Delete.
7870 (DEF_VEC_P(target_ops_p)): Delete.
7871 (target_factories): New.
7872 (test_target_info): New.
7873 (test_target_ops::info): New.
7874 (open_target): Adjust to use target_factories.
7875 (add_target_with_completer): Rename to ...
7876 (add_target): ... this. Change prototype. Register target_info
7877 and open callback in target_factories. Register target_info in
7878 command context instead of target_ops.
7879 (add_target): Delete old implementation.
7880 (add_deprecated_target_alias): Change prototype. Adjust.
7881 (the_native_target): New.
7882 (set_native_target, get_native_target): New.
7883 (find_default_run_target): Use the_native_target.
7884 (find_attach_target, find_run_target): Simplify.
7885 (target_ops::open): Delete.
7886 (dummy_target_info): New.
7887 (dummy_target::shortname, dummy_target::longname)
7888 (dummy_target::doc): Delete.
7889 (dummy_target::info): New.
7890 (debug_target::shortname, debug_target::longname)
7891 (debug_target::doc): Delete.
7892 (debug_target::info): New.
7893 * target.h (struct target_info): New.
7894 (target_ops::~target_ops): Add comment.
7895 (target_ops::info): New.
7896 (target_ops::shortname, target_ops::longname, target_ops::doc): No
7897 longer virtual. Implement in terms of target_info.
7898 (set_native_target, get_native_target): Declare.
7899 (target_open_ftype): New.
7900 (add_target, add_target_with_completer)
7901 (add_deprecated_target_alias): Change prototype.
7902 (test_target) <shortname, longname, doc>: Delete.
7903 <info>: New.
7904 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
7905 add_inf_child_target.
7906 * tracefile-tfile.c (tfile_target_info): New.
7907 (tfile_target) <shortname, longname, doc>: Delete.
7908 <info>: New.
7909 (tfile_target::open): Rename to ...
7910 (tfile_target_open): ... this.
7911 (_initialize_tracefile_tfile): Adjust.
7912 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
7913 add_inf_child_target.
7914 * windows-nat.c (_initialize_windows_nat): Use
7915 add_inf_child_target.
7916 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
7917 add_inf_child_target.
7918
7919 2018-05-02 Pedro Alves <palves@redhat.com>
7920
7921 * linux-nat.h (linux_nat_target) <low_new_thread,
7922 low_delete_thread, low_new_fork, low_forget_process,
7923 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
7924 New virtual methods.
7925 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7926 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
7927 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
7928 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7929 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
7930 Delete.
7931 * linux-fork.c (delete_fork): Adjust to call low method.
7932 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
7933 (linux_nat_new_fork, linux_nat_forget_process_hook)
7934 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
7935 (linux_nat_status_is_event):
7936 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
7937 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
7938 to call low method.
7939 (sigtrap_is_event): Rename to ...
7940 (linux_nat_target::low_status_is_event): ... this.
7941 (linux_nat_set_status_is_event): Delete.
7942 (save_stop_reason, linux_nat_wait_1)
7943 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
7944 low methods.
7945 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
7946 (linux_nat_set_new_fork, linux_nat_set_forget_process)
7947 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
7948 (linux_nat_set_prepare_to_resume): Delete.
7949 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
7950 low virtual methods.
7951 * amd64-linux-nat.c: Likewise.
7952 * arm-linux-nat.c: Likewise.
7953 * i386-linux-nat.c: Likewise.
7954 * ia64-linux-nat.c: Likewise.
7955 * mips-linux-nat.c: Likewise.
7956 * ppc-linux-nat.c: Likewise.
7957 * s390-linux-nat.c: Likewise.
7958 * sparc64-linux-nat.c: Likewise.
7959 * x86-linux-nat.c: Likewise.
7960 * x86-linux-nat.h: Include "nat/x86-linux.h".
7961 (x86_linux_nat_target) <low_new_fork, low_forget_process,
7962 low_prepare_to_resume, low_new_thread, low_delete_thread>:
7963 Override methods.
7964
7965 2018-05-02 Pedro Alves <palves@redhat.com>
7966
7967 * target.h (target_ops)
7968 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7969 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
7970 stopped_by_watchpoint, have_continuable_watchpoint,
7971 stopped_data_address, watchpoint_addr_within_range,
7972 can_accel_watchpoint_condition, can_run, thread_alive,
7973 has_all_memory, has_memory, has_stack, has_registers,
7974 has_execution, can_async_p, is_async_p, supports_non_stop,
7975 always_non_stop_p, can_execute_reverse, supports_multi_process,
7976 supports_enable_disable_tracepoint,
7977 supports_disable_randomization, supports_string_tracing,
7978 supports_evaluation_of_breakpoint_conditions,
7979 can_run_breakpoint_commands, filesystem_is_local,
7980 can_download_tracepoint, get_trace_state_variable_value,
7981 set_trace_notes, get_tib_address, use_agent, can_use_agent,
7982 record_is_replaying, record_will_replay,
7983 augmented_libraries_svr4_read>: Adjust to return bool.
7984 * aarch64-linux-nat.c: All implementations adjusted.
7985 * aix-thread.c: All implementations adjusted.
7986 * arm-linux-nat.c: All implementations adjusted.
7987 * breakpoint.c: All implementations adjusted.
7988 * bsd-kvm.c: All implementations adjusted.
7989 * bsd-uthread.c: All implementations adjusted.
7990 * corelow.c: All implementations adjusted.
7991 * ctf.c: All implementations adjusted.
7992 * darwin-nat.c: All implementations adjusted.
7993 * darwin-nat.h: All implementations adjusted.
7994 * exec.c: All implementations adjusted.
7995 * fbsd-nat.c: All implementations adjusted.
7996 * fbsd-nat.h: All implementations adjusted.
7997 * gnu-nat.c: All implementations adjusted.
7998 * gnu-nat.h: All implementations adjusted.
7999 * go32-nat.c: All implementations adjusted.
8000 * ia64-linux-nat.c: All implementations adjusted.
8001 * inf-child.c: All implementations adjusted.
8002 * inf-child.h: All implementations adjusted.
8003 * inf-ptrace.c: All implementations adjusted.
8004 * inf-ptrace.h: All implementations adjusted.
8005 * linux-nat.c: All implementations adjusted.
8006 * linux-nat.h: All implementations adjusted.
8007 * mips-linux-nat.c: All implementations adjusted.
8008 * nto-procfs.c: All implementations adjusted.
8009 * ppc-linux-nat.c: All implementations adjusted.
8010 * procfs.c: All implementations adjusted.
8011 * ravenscar-thread.c: All implementations adjusted.
8012 * record-btrace.c: All implementations adjusted.
8013 * record-full.c: All implementations adjusted.
8014 * remote-sim.c: All implementations adjusted.
8015 * remote.c: All implementations adjusted.
8016 * s390-linux-nat.c: All implementations adjusted.
8017 * sol-thread.c: All implementations adjusted.
8018 * spu-multiarch.c: All implementations adjusted.
8019 * target-delegates.c: All implementations adjusted.
8020 * target.c: All implementations adjusted.
8021 * target.h: All implementations adjusted.
8022 * tracefile-tfile.c: All implementations adjusted.
8023 * tracefile.c: All implementations adjusted.
8024 * tracefile.h: All implementations adjusted.
8025 * windows-nat.c: All implementations adjusted.
8026 * x86-linux-nat.h: All implementations adjusted.
8027 * x86-nat.h: All implementations adjusted.
8028
8029 2018-05-02 Pedro Alves <palves@redhat.com>
8030
8031 * make-target-delegates (scan_target_h): Don't trim lines here.
8032 Replace sequences of tabs and/or whitespace with a single
8033 whitespace.
8034 (top level, parsing methods): Trim each line before processing it
8035 here.
8036
8037 2018-05-02 Pedro Alves <palves@redhat.com>
8038 John Baldwin <jhb@freebsd.org>
8039
8040 * target.h (enum strata) <debug_stratum>: New.
8041 (struct target_ops) <all delegation methods>: Replace by C++
8042 virtual methods, and drop "to_" prefix. All references updated
8043 throughout.
8044 <to_shortname, to_longname, to_doc, to_data,
8045 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
8046 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
8047 virtual methods. All references updated throughout.
8048 <can_attach, supports_terminal_ours, can_create_inferior,
8049 get_thread_control_capabilities, attach_no_wait>: New
8050 virtual methods.
8051 <insert_breakpoint, remove_breakpoint>: Now
8052 TARGET_DEFAULT_NORETURN methods.
8053 <info_proc>: Now returns bool.
8054 <to_magic>: Delete.
8055 (OPS_MAGIC): Delete.
8056 (current_target): Delete. All references replaced by references
8057 to ...
8058 (target_stack): ... this. New.
8059 (target_shortname, target_longname): Adjust.
8060 (target_can_run): Now a function declaration.
8061 (default_child_has_all_memory, default_child_has_memory)
8062 (default_child_has_stack, default_child_has_registers)
8063 (default_child_has_execution): Remove target_ops parameter.
8064 (complete_target_initialization): Delete.
8065 (memory_breakpoint_target): New template class.
8066 (test_target_ops): Refactor as a C++ class with virtual methods.
8067 * make-target-delegates (NAME_PART): Tighten.
8068 (POINTER_PART, CP_SYMBOL): New.
8069 (SIMPLE_RETURN_PART): Reimplement.
8070 (VEC_RETURN_PART): Expect less.
8071 (RETURN_PART, VIRTUAL_PART): New.
8072 (METHOD): Adjust to C++ virtual methods.
8073 (scan_target_h): Remove reference to C99.
8074 (dname): Output "target_ops::" prefix.
8075 (write_function_header): Adjust to output a C++ class method.
8076 (write_declaration): New.
8077 (write_delegator): Adjust to output a C++ class method.
8078 (tdname): Output "dummy_target::" prefix.
8079 (write_tdefault, write_debugmethod): Adjust to output a C++ class
8080 method.
8081 (tdefault_names, debug_names): Delete.
8082 (return_types, tdefaults, styles, argtypes_array): New.
8083 (top level): All methods are delegators.
8084 (print_class): New.
8085 (top level): Print dummy_target and debug_target classes.
8086 * target-delegates.c: Regenerate.
8087 * target-debug.h (target_debug_print_enum_info_proc_what)
8088 (target_debug_print_thread_control_capabilities)
8089 (target_debug_print_thread_info_p): New.
8090 * target.c (dummy_target): Delete.
8091 (the_dummy_target, the_debug_target): New.
8092 (target_stack): Now extern.
8093 (set_targetdebug): Push/unpush debug target.
8094 (default_child_has_all_memory, default_child_has_memory)
8095 (default_child_has_stack, default_child_has_registers)
8096 (default_child_has_execution): Remove target_ops parameter.
8097 (complete_target_initialization): Delete.
8098 (add_target_with_completer): No longer call
8099 complete_target_initialization.
8100 (target_supports_terminal_ours): Use regular delegation.
8101 (update_current_target): Delete.
8102 (push_target): No longer check magic number. Don't call
8103 update_current_target.
8104 (unpush_target): Don't call update_current_target.
8105 (target_is_pushed): No longer check magic number.
8106 (target_require_runnable): Skip for all stratums over
8107 process_stratum.
8108 (target_ops::info_proc): New.
8109 (target_info_proc): Use find_target_at and
8110 find_default_run_target.
8111 (target_supports_disable_randomization): Use regular delegation.
8112 (target_get_osdata): Use find_target_at.
8113 (target_ops::open, target_ops::close, target_ops::can_attach)
8114 (target_ops::attach, target_ops::can_create_inferior)
8115 (target_ops::create_inferior, target_ops::can_run)
8116 (target_can_run): New.
8117 (default_fileio_target): Use regular delegation.
8118 (target_ops::fileio_open, target_ops::fileio_pwrite)
8119 (target_ops::fileio_pread, target_ops::fileio_fstat)
8120 (target_ops::fileio_close, target_ops::fileio_unlink)
8121 (target_ops::fileio_readlink): New.
8122 (target_fileio_open_1, target_fileio_unlink)
8123 (target_fileio_readlink): Always call the target method. Handle
8124 FILEIO_ENOSYS.
8125 (return_zero, return_zero_has_execution): Delete.
8126 (init_dummy_target): Delete.
8127 (dummy_target::dummy_target, dummy_target::shortname)
8128 (dummy_target::longname, dummy_target::doc)
8129 (debug_target::debug_target, debug_target::shortname)
8130 (debug_target::longname, debug_target::doc): New.
8131 (target_supports_delete_record): Use regular delegation.
8132 (setup_target_debug): Delete.
8133 (maintenance_print_target_stack): Skip debug_stratum.
8134 (initialize_targets): Instantiate the_dummy_target and
8135 the_debug_target.
8136 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
8137 use target_stack.
8138 (target_auxv_search, fprint_target_auxv): Adjust.
8139 (info_auxv_command): Adjust to use target_stack.
8140 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
8141 * exceptions.c (print_flush): Handle a NULL target_stack.
8142 * regcache.c (target_ops_no_register): Refactor as class with
8143 virtual methods.
8144
8145 * exec.c (exec_target): New class.
8146 (exec_ops): Now an exec_target.
8147 (exec_open, exec_close_1, exec_get_section_table)
8148 (exec_xfer_partial, exec_files_info, exec_has_memory)
8149 (exec_make_note_section): Refactor as exec_target methods.
8150 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
8151 Delete.
8152 (exec_target::find_memory_regions): New.
8153 (_initialize_exec): Don't call init_exec_ops.
8154 * gdbcore.h (exec_file_clear): Delete.
8155
8156 * corefile.c (core_target): Delete.
8157 (core_file_command): Adjust.
8158 * corelow.c (core_target): New class.
8159 (the_core_target): New.
8160 (core_close): Remove target_ops parameter.
8161 (core_close_cleanup): Adjust.
8162 (core_target::close): New.
8163 (core_open, core_detach, get_core_registers, core_files_info)
8164 (core_xfer_partial, core_thread_alive, core_read_description)
8165 (core_pid_to_str, core_thread_name, core_has_memory)
8166 (core_has_stack, core_has_registers, core_info_proc): Rework as
8167 core_target methods.
8168 (ignore, core_remove_breakpoint, init_core_ops): Delete.
8169 (_initialize_corelow): Initialize the_core_target.
8170 * gdbcore.h (core_target): Delete.
8171 (the_core_target): New.
8172
8173 * ctf.c: (ctf_target): New class.
8174 (ctf_ops): Now a ctf_target.
8175 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
8176 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
8177 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
8178 methods.
8179 (init_ctf_ops): Delete.
8180 (_initialize_ctf): Don't call it.
8181 * tracefile-tfile.c (tfile_target): New class.
8182 (tfile_ops): Now a tfile_target.
8183 (tfile_open, tfile_close, tfile_files_info)
8184 (tfile_get_tracepoint_status, tfile_trace_find)
8185 (tfile_fetch_registers, tfile_xfer_partial)
8186 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
8187 Refactor as tfile_target methods.
8188 (tfile_xfer_partial_features): Remove target_ops parameter.
8189 (init_tfile_ops): Delete.
8190 (_initialize_tracefile_tfile): Don't call it.
8191 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
8192 (tracefile_has_stack, tracefile_has_registers)
8193 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
8194 tracefile_target methods.
8195 (init_tracefile_ops): Delete.
8196 (tracefile_target::tracefile_target): New.
8197 * tracefile.h: Include "target.h".
8198 (tracefile_target): New class.
8199 (init_tracefile_ops): Delete.
8200
8201 * spu-multiarch.c (spu_multiarch_target): New class.
8202 (spu_ops): Now a spu_multiarch_target.
8203 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
8204 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
8205 (spu_search_memory, spu_mourn_inferior): Refactor as
8206 spu_multiarch_target methods.
8207 (init_spu_ops): Delete.
8208 (_initialize_spu_multiarch): Remove references to init_spu_ops,
8209 complete_target_initialization.
8210
8211 * ravenscar-thread.c (ravenscar_thread_target): New class.
8212 (ravenscar_ops): Now a ravenscar_thread_target.
8213 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
8214 (ravenscar_thread_alive, ravenscar_pid_to_str)
8215 (ravenscar_fetch_registers, ravenscar_store_registers)
8216 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
8217 (ravenscar_stopped_by_hw_breakpoint)
8218 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
8219 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
8220 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
8221 methods.
8222 (init_ravenscar_thread_ops): Delete.
8223 (_initialize_ravenscar): Remove references to
8224 init_ravenscar_thread_ops and complete_target_initialization.
8225
8226 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
8227 (bsd_uthread_target): New class.
8228 (bsd_uthread_ops): Now a bsd_uthread_target.
8229 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
8230 (bsd_uthread_close, bsd_uthread_mourn_inferior)
8231 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
8232 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
8233 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
8234 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
8235 (bsd_uthread_target): Delete function.
8236 (_initialize_bsd_uthread): Remove reference to
8237 complete_target_initialization.
8238
8239 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
8240 (target_bfd): ... this new class.
8241 (target_bfd_xfer_partial, target_bfd_get_section_table)
8242 (target_bfd_close): Refactor as target_bfd methods.
8243 (target_bfd::~target_bfd): New.
8244 (target_bfd_reopen): Adjust.
8245 (target_bfd::close): New.
8246
8247 * record-btrace.c (record_btrace_target): New class.
8248 (record_btrace_ops): Now a record_btrace_target.
8249 (record_btrace_open, record_btrace_stop_recording)
8250 (record_btrace_disconnect, record_btrace_close)
8251 (record_btrace_async, record_btrace_info)
8252 (record_btrace_insn_history, record_btrace_insn_history_range)
8253 (record_btrace_insn_history_from, record_btrace_call_history)
8254 (record_btrace_call_history_range)
8255 (record_btrace_call_history_from, record_btrace_record_method)
8256 (record_btrace_is_replaying, record_btrace_will_replay)
8257 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
8258 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
8259 (record_btrace_store_registers, record_btrace_prepare_to_store)
8260 (record_btrace_to_get_unwinder)
8261 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
8262 (record_btrace_commit_resume, record_btrace_wait)
8263 (record_btrace_stop, record_btrace_can_execute_reverse)
8264 (record_btrace_stopped_by_sw_breakpoint)
8265 (record_btrace_supports_stopped_by_sw_breakpoint)
8266 (record_btrace_stopped_by_hw_breakpoint)
8267 (record_btrace_supports_stopped_by_hw_breakpoint)
8268 (record_btrace_update_thread_list, record_btrace_thread_alive)
8269 (record_btrace_goto_begin, record_btrace_goto_end)
8270 (record_btrace_goto, record_btrace_stop_replaying_all)
8271 (record_btrace_execution_direction)
8272 (record_btrace_prepare_to_generate_core)
8273 (record_btrace_done_generating_core): Refactor as
8274 record_btrace_target methods.
8275 (init_record_btrace_ops): Delete.
8276 (_initialize_record_btrace): Remove reference to
8277 init_record_btrace_ops.
8278 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
8279 the execution_direction global.
8280 (record_full_base_target, record_full_target)
8281 (record_full_core_target): New classes.
8282 (record_full_ops): Now a record_full_target.
8283 (record_full_core_ops): Now a record_full_core_target.
8284 (record_full_target::detach, record_full_target::disconnect)
8285 (record_full_core_target::disconnect)
8286 (record_full_target::mourn_inferior, record_full_target::kill):
8287 New.
8288 (record_full_open, record_full_close, record_full_async): Refactor
8289 as methods of the record_full_base_target class.
8290 (record_full_resume, record_full_commit_resume): Refactor
8291 as methods of the record_full_target class.
8292 (record_full_wait, record_full_stopped_by_watchpoint)
8293 (record_full_stopped_data_address)
8294 (record_full_stopped_by_sw_breakpoint)
8295 (record_full_supports_stopped_by_sw_breakpoint)
8296 (record_full_stopped_by_hw_breakpoint)
8297 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
8298 methods of the record_full_base_target class.
8299 (record_full_store_registers, record_full_xfer_partial)
8300 (record_full_insert_breakpoint, record_full_remove_breakpoint):
8301 Refactor as methods of the record_full_target class.
8302 (record_full_can_execute_reverse, record_full_get_bookmark)
8303 (record_full_goto_bookmark, record_full_execution_direction)
8304 (record_full_record_method, record_full_info, record_full_delete)
8305 (record_full_is_replaying, record_full_will_replay)
8306 (record_full_goto_begin, record_full_goto_end, record_full_goto)
8307 (record_full_stop_replaying): Refactor as methods of the
8308 record_full_base_target class.
8309 (record_full_core_resume, record_full_core_kill)
8310 (record_full_core_fetch_registers)
8311 (record_full_core_prepare_to_store)
8312 (record_full_core_store_registers, record_full_core_xfer_partial)
8313 (record_full_core_insert_breakpoint)
8314 (record_full_core_remove_breakpoint)
8315 (record_full_core_has_execution): Refactor
8316 as methods of the record_full_core_target class.
8317 (record_full_base_target::supports_delete_record): New.
8318 (init_record_full_ops): Delete.
8319 (init_record_full_core_ops): Delete.
8320 (record_full_save): Refactor as method of the
8321 record_full_base_target class.
8322 (_initialize_record_full): Remove references to
8323 init_record_full_ops and init_record_full_core_ops.
8324
8325 * remote.c (remote_target, extended_remote_target): New classes.
8326 (remote_ops): Now a remote_target.
8327 (extended_remote_ops): Now an extended_remote_target.
8328 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
8329 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
8330 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
8331 (remote_pass_signals, remote_set_syscall_catchpoint)
8332 (remote_program_signals, )
8333 (remote_thread_always_alive): Remove target_ops parameter.
8334 (remote_thread_alive, remote_thread_name)
8335 (remote_update_thread_list, remote_threads_extra_info)
8336 (remote_static_tracepoint_marker_at)
8337 (remote_static_tracepoint_markers_by_strid)
8338 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
8339 (remote_open): Refactor as methods of remote_target.
8340 (extended_remote_open, extended_remote_detach)
8341 (extended_remote_attach, extended_remote_post_attach):
8342 (extended_remote_supports_disable_randomization)
8343 (extended_remote_create_inferior): : Refactor as method of
8344 extended_remote_target.
8345 (remote_set_permissions, remote_open_1, remote_detach)
8346 (remote_follow_fork, remote_follow_exec, remote_disconnect)
8347 (remote_resume, remote_commit_resume, remote_stop)
8348 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
8349 (remote_terminal_ours, remote_wait, remote_fetch_registers)
8350 (remote_prepare_to_store, remote_store_registers)
8351 (remote_flash_erase, remote_flash_done, remote_files_info)
8352 (remote_kill, remote_mourn, remote_insert_breakpoint)
8353 (remote_remove_breakpoint, remote_insert_watchpoint)
8354 (remote_watchpoint_addr_within_range)
8355 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
8356 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
8357 (remote_supports_stopped_by_sw_breakpoint)
8358 (remote_stopped_by_hw_breakpoint)
8359 (remote_supports_stopped_by_hw_breakpoint)
8360 (remote_stopped_by_watchpoint, remote_stopped_data_address)
8361 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
8362 (remote_verify_memory): Refactor as methods of remote_target.
8363 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
8364 parameter.
8365 (remote_xfer_partial, remote_get_memory_xfer_limit)
8366 (remote_search_memory, remote_rcmd, remote_memory_map)
8367 (remote_pid_to_str, remote_get_thread_local_address)
8368 (remote_get_tib_address, remote_read_description): Refactor as
8369 methods of remote_target.
8370 (remote_target::fileio_open, remote_target::fileio_pwrite)
8371 (remote_target::fileio_pread, remote_target::fileio_close): New.
8372 (remote_hostio_readlink, remote_hostio_fstat)
8373 (remote_filesystem_is_local, remote_can_execute_reverse)
8374 (remote_supports_non_stop, remote_supports_disable_randomization)
8375 (remote_supports_multi_process, remote_supports_cond_breakpoints)
8376 (remote_supports_enable_disable_tracepoint)
8377 (remote_supports_string_tracing)
8378 (remote_can_run_breakpoint_commands, remote_trace_init)
8379 (remote_download_tracepoint, remote_can_download_tracepoint)
8380 (remote_download_trace_state_variable, remote_enable_tracepoint)
8381 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
8382 (remote_trace_start, remote_get_trace_status)
8383 (remote_get_tracepoint_status, remote_trace_stop)
8384 (remote_trace_find, remote_get_trace_state_variable_value)
8385 (remote_save_trace_data, remote_get_raw_trace_data)
8386 (remote_set_disconnected_tracing, remote_core_of_thread)
8387 (remote_set_circular_trace_buffer, remote_traceframe_info)
8388 (remote_get_min_fast_tracepoint_insn_len)
8389 (remote_set_trace_buffer_size, remote_set_trace_notes)
8390 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
8391 (remote_disable_btrace, remote_teardown_btrace)
8392 (remote_read_btrace, remote_btrace_conf)
8393 (remote_augmented_libraries_svr4_read, remote_load)
8394 (remote_pid_to_exec_file, remote_can_do_single_step)
8395 (remote_execution_direction, remote_thread_handle_to_thread_info):
8396 Refactor as methods of remote_target.
8397 (init_remote_ops, init_extended_remote_ops): Delete.
8398 (remote_can_async_p, remote_is_async_p, remote_async)
8399 (remote_thread_events, remote_upload_tracepoints)
8400 (remote_upload_trace_state_variables): Refactor as methods of
8401 remote_target.
8402 (_initialize_remote): Remove references to init_remote_ops and
8403 init_extended_remote_ops.
8404
8405 * remote-sim.c (gdbsim_target): New class.
8406 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
8407 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
8408 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
8409 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
8410 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
8411 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
8412 Refactor as methods of gdbsim_target.
8413 (gdbsim_ops): Now a gdbsim_target.
8414 (init_gdbsim_ops): Delete.
8415 (gdbsim_cntrl_c): Adjust.
8416 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
8417
8418 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
8419 (the_amd64_linux_nat_target): New.
8420 (amd64_linux_fetch_inferior_registers)
8421 (amd64_linux_store_inferior_registers): Refactor as methods of
8422 amd64_linux_nat_target.
8423 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
8424 * i386-linux-nat.c: Don't include "linux-nat.h".
8425 (i386_linux_nat_target): New class.
8426 (the_i386_linux_nat_target): New.
8427 (i386_linux_fetch_inferior_registers)
8428 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
8429 as methods of i386_linux_nat_target.
8430 (_initialize_i386_linux_nat): Adjust. Set linux_target.
8431 * inf-child.c (inf_child_ops): Delete.
8432 (inf_child_fetch_inferior_registers)
8433 (inf_child_store_inferior_registers): Delete.
8434 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
8435 methods of inf_child_target.
8436 (inf_child_target::supports_terminal_ours)
8437 (inf_child_target::terminal_init)
8438 (inf_child_target::terminal_inferior)
8439 (inf_child_target::terminal_ours_for_output)
8440 (inf_child_target::terminal_ours, inf_child_target::interrupt)
8441 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
8442 New.
8443 (inf_child_open, inf_child_disconnect, inf_child_close)
8444 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
8445 (inf_child_post_startup_inferior, inf_child_can_run)
8446 (inf_child_pid_to_exec_file): Refactor as methods of
8447 inf_child_target.
8448 (inf_child_follow_fork): Delete.
8449 (inf_child_target::can_create_inferior)
8450 (inf_child_target::can_attach): New.
8451 (inf_child_target::has_all_memory, inf_child_target::has_memory)
8452 (inf_child_target::has_stack, inf_child_target::has_registers)
8453 (inf_child_target::has_execution): New.
8454 (inf_child_fileio_open, inf_child_fileio_pwrite)
8455 (inf_child_fileio_pread, inf_child_fileio_fstat)
8456 (inf_child_fileio_close, inf_child_fileio_unlink)
8457 (inf_child_fileio_readlink, inf_child_use_agent)
8458 (inf_child_can_use_agent): Refactor as methods of
8459 inf_child_target.
8460 (return_zero, inf_child_target): Delete.
8461 (inf_child_target::inf_child_target): New.
8462 * inf-child.h: Include "target.h".
8463 (inf_child_target): Delete function prototype.
8464 (inf_child_target): New class.
8465 (inf_child_open_target, inf_child_mourn_inferior)
8466 (inf_child_maybe_unpush_target): Delete.
8467 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
8468 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
8469 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
8470 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
8471 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
8472 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
8473 (inf_ptrace_wait, inf_ptrace_xfer_partial)
8474 (inf_ptrace_thread_alive, inf_ptrace_files_info)
8475 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
8476 methods of inf_ptrace_target.
8477 (inf_ptrace_target): Delete function.
8478 * inf-ptrace.h: Include "inf-child.h".
8479 (inf_ptrace_target): Delete function declaration.
8480 (inf_ptrace_target): New class.
8481 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
8482 * linux-nat.c (linux_target): New.
8483 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
8484 (linux_nat_target::~linux_nat_target): New.
8485 (linux_child_post_attach, linux_child_post_startup_inferior)
8486 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
8487 (linux_child_remove_fork_catchpoint)
8488 (linux_child_insert_vfork_catchpoint)
8489 (linux_child_remove_vfork_catchpoint)
8490 (linux_child_insert_exec_catchpoint)
8491 (linux_child_remove_exec_catchpoint)
8492 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
8493 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
8494 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
8495 (linux_nat_stopped_data_address)
8496 (linux_nat_stopped_by_sw_breakpoint)
8497 (linux_nat_supports_stopped_by_sw_breakpoint)
8498 (linux_nat_stopped_by_hw_breakpoint)
8499 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
8500 (linux_nat_kill, linux_nat_mourn_inferior)
8501 (linux_nat_xfer_partial, linux_nat_thread_alive)
8502 (linux_nat_update_thread_list, linux_nat_pid_to_str)
8503 (linux_nat_thread_name, linux_child_pid_to_exec_file)
8504 (linux_child_static_tracepoint_markers_by_strid)
8505 (linux_nat_is_async_p, linux_nat_can_async_p)
8506 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
8507 (linux_nat_supports_multi_process)
8508 (linux_nat_supports_disable_randomization, linux_nat_async)
8509 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
8510 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
8511 (linux_nat_fileio_open, linux_nat_fileio_readlink)
8512 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
8513 methods of linux_nat_target.
8514 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
8515 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
8516 parameter.
8517 (check_stopped_by_watchpoint): Adjust.
8518 (linux_xfer_partial): Delete.
8519 (linux_target_install_ops, linux_target, linux_nat_add_target):
8520 Delete.
8521 (linux_nat_target::linux_nat_target): New.
8522 * linux-nat.h: Include "inf-ptrace.h".
8523 (linux_nat_target): New.
8524 (linux_target, linux_target_install_ops, linux_nat_add_target):
8525 Delete function declarations.
8526 (linux_target): Declare global.
8527 * linux-thread-db.c (thread_db_target): New.
8528 (thread_db_target::thread_db_target): New.
8529 (thread_db_ops): Delete.
8530 (the_thread_db_target): New.
8531 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
8532 (thread_db_update_thread_list, thread_db_pid_to_str)
8533 (thread_db_extra_thread_info)
8534 (thread_db_thread_handle_to_thread_info)
8535 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
8536 (thread_db_resume): Refactor as methods of thread_db_target.
8537 (init_thread_db_ops): Delete.
8538 (_initialize_thread_db): Remove reference to init_thread_db_ops.
8539 * x86-linux-nat.c: Don't include "linux-nat.h".
8540 (super_post_startup_inferior): Delete.
8541 (x86_linux_nat_target::~x86_linux_nat_target): New.
8542 (x86_linux_child_post_startup_inferior)
8543 (x86_linux_read_description, x86_linux_enable_btrace)
8544 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
8545 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
8546 methods of x86_linux_nat_target.
8547 (x86_linux_create_target): Delete. Bits folded ...
8548 (x86_linux_add_target): ... here. Now takes a linux_nat_target
8549 pointer.
8550 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
8551 (x86_linux_nat_target): New class.
8552 (x86_linux_create_target): Delete.
8553 (x86_linux_add_target): Now takes a linux_nat_target pointer.
8554 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
8555 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
8556 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
8557 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
8558 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
8559 make extern.
8560 (x86_use_watchpoints): Delete.
8561 * x86-nat.h: Include "breakpoint.h" and "target.h".
8562 (x86_use_watchpoints): Delete.
8563 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
8564 (x86_stopped_by_watchpoint, x86_stopped_data_address)
8565 (x86_insert_watchpoint, x86_remove_watchpoint)
8566 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
8567 (x86_stopped_by_hw_breakpoint): New declarations.
8568 (x86_nat_target): New template class.
8569
8570 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
8571 (the_ppc_linux_nat_target): New.
8572 (ppc_linux_fetch_inferior_registers)
8573 (ppc_linux_can_use_hw_breakpoint)
8574 (ppc_linux_region_ok_for_hw_watchpoint)
8575 (ppc_linux_ranged_break_num_registers)
8576 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
8577 (ppc_linux_insert_mask_watchpoint)
8578 (ppc_linux_remove_mask_watchpoint)
8579 (ppc_linux_can_accel_watchpoint_condition)
8580 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
8581 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
8582 (ppc_linux_watchpoint_addr_within_range)
8583 (ppc_linux_masked_watch_num_registers)
8584 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
8585 (ppc_linux_read_description): Refactor as methods of
8586 ppc_linux_nat_target.
8587 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
8588
8589 * procfs.c (procfs_xfer_partial): Delete forward declaration.
8590 (procfs_target): New class.
8591 (the_procfs_target): New.
8592 (procfs_target): Delete function.
8593 (procfs_auxv_parse, procfs_attach, procfs_detach)
8594 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
8595 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
8596 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
8597 (procfs_create_inferior, procfs_update_thread_list)
8598 (procfs_thread_alive, procfs_pid_to_str)
8599 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
8600 (procfs_stopped_data_address, procfs_insert_watchpoint)
8601 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
8602 (proc_find_memory_regions, procfs_info_proc)
8603 (procfs_make_note_section): Refactor as methods of procfs_target.
8604 (_initialize_procfs): Adjust.
8605 * sol-thread.c (sol_thread_target): New class.
8606 (sol_thread_ops): Now a sol_thread_target.
8607 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
8608 (sol_thread_fetch_registers, sol_thread_store_registers)
8609 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
8610 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
8611 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
8612 (init_sol_thread_ops): Delete.
8613 (_initialize_sol_thread): Adjust. Remove references to
8614 init_sol_thread_ops and complete_target_initialization.
8615
8616 * windows-nat.c (windows_nat_target): New class.
8617 (windows_fetch_inferior_registers)
8618 (windows_store_inferior_registers, windows_resume, windows_wait)
8619 (windows_attach, windows_detach, windows_pid_to_exec_file)
8620 (windows_files_info, windows_create_inferior)
8621 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
8622 (windows_close, windows_pid_to_str, windows_xfer_partial)
8623 (windows_get_tib_address, windows_get_ada_task_ptid)
8624 (windows_thread_name, windows_thread_alive): Refactor as
8625 windows_nat_target methods.
8626 (do_initial_windows_stuff): Adjust.
8627 (windows_target): Delete function.
8628 (_initialize_windows_nat): Adjust.
8629
8630 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
8631 (darwin_mourn_inferior, darwin_kill_inferior)
8632 (darwin_create_inferior, darwin_attach, darwin_detach)
8633 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
8634 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
8635 (darwin_supports_multi_process): Refactor as darwin_nat_target
8636 methods.
8637 (darwin_resume_to, darwin_files_info): Delete.
8638 (_initialize_darwin_inferior): Rename to ...
8639 (_initialize_darwin_nat): ... this. Adjust to C++ification.
8640 * darwin-nat.h: Include "inf-child.h".
8641 (darwin_nat_target): New class.
8642 (darwin_complete_target): Delete.
8643 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
8644 (darwin_target): New.
8645 (i386_darwin_fetch_inferior_registers)
8646 (i386_darwin_store_inferior_registers): Refactor as methods of
8647 darwin_nat_target.
8648 (darwin_complete_target): Delete, with ...
8649 (_initialize_i386_darwin_nat): ... bits factored out here.
8650
8651 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
8652 (the_alpha_linux_nat_target): New.
8653 (alpha_linux_register_u_offset): Refactor as
8654 alpha_linux_nat_target method.
8655 (_initialize_alpha_linux_nat): Adjust.
8656 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
8657 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
8658 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
8659 methods of linux_nat_trad_target.
8660 (linux_trad_target): Delete.
8661 * linux-nat-trad.h (linux_trad_target): Delete function.
8662 (linux_nat_trad_target): New class.
8663 * mips-linux-nat.c (mips_linux_nat_target): New class.
8664 (super_fetch_registers, super_store_registers, super_close):
8665 Delete.
8666 (the_mips_linux_nat_target): New.
8667 (mips64_linux_regsets_fetch_registers)
8668 (mips64_linux_regsets_store_registers)
8669 (mips64_linux_fetch_registers, mips64_linux_store_registers)
8670 (mips_linux_register_u_offset, mips_linux_read_description)
8671 (mips_linux_can_use_hw_breakpoint)
8672 (mips_linux_stopped_by_watchpoint)
8673 (mips_linux_stopped_data_address)
8674 (mips_linux_region_ok_for_hw_watchpoint)
8675 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
8676 (mips_linux_close): Refactor as methods of mips_linux_nat.
8677 (_initialize_mips_linux_nat): Adjust to C++ification.
8678
8679 * aix-thread.c (aix_thread_target): New class.
8680 (aix_thread_ops): Now an aix_thread_target.
8681 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
8682 (aix_thread_fetch_registers, aix_thread_store_registers)
8683 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
8684 (aix_thread_thread_alive, aix_thread_pid_to_str)
8685 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
8686 Refactor as methods of aix_thread_target.
8687 (init_aix_thread_ops): Delete.
8688 (_initialize_aix_thread): Remove references to init_aix_thread_ops
8689 and complete_target_initialization.
8690 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
8691 (rs6000_nat_target): New class.
8692 (the_rs6000_nat_target): New.
8693 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
8694 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
8695 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
8696 (super_create_inferior): Delete.
8697 (_initialize_rs6000_nat): Adjust to C++ification.
8698
8699 * arm-linux-nat.c (arm_linux_nat_target): New class.
8700 (the_arm_linux_nat_target): New.
8701 (arm_linux_fetch_inferior_registers)
8702 (arm_linux_store_inferior_registers, arm_linux_read_description)
8703 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
8704 (arm_linux_remove_hw_breakpoint)
8705 (arm_linux_region_ok_for_hw_watchpoint)
8706 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
8707 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
8708 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
8709 arm_linux_nat_target.
8710 (_initialize_arm_linux_nat): Adjust to C++ification.
8711
8712 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
8713 (the_aarch64_linux_nat_target): New.
8714 (aarch64_linux_fetch_inferior_registers)
8715 (aarch64_linux_store_inferior_registers)
8716 (aarch64_linux_child_post_startup_inferior)
8717 (aarch64_linux_read_description)
8718 (aarch64_linux_can_use_hw_breakpoint)
8719 (aarch64_linux_insert_hw_breakpoint)
8720 (aarch64_linux_remove_hw_breakpoint)
8721 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
8722 (aarch64_linux_region_ok_for_hw_watchpoint)
8723 (aarch64_linux_stopped_data_address)
8724 (aarch64_linux_stopped_by_watchpoint)
8725 (aarch64_linux_watchpoint_addr_within_range)
8726 (aarch64_linux_can_do_single_step): Refactor as methods of
8727 aarch64_linux_nat_target.
8728 (super_post_startup_inferior): Delete.
8729 (_initialize_aarch64_linux_nat): Adjust to C++ification.
8730
8731 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
8732 (the_hppa_linux_nat_target): New.
8733 (hppa_linux_fetch_inferior_registers)
8734 (hppa_linux_store_inferior_registers): Refactor as methods of
8735 hppa_linux_nat_target.
8736 (_initialize_hppa_linux_nat): Adjust to C++ification.
8737
8738 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
8739 (the_ia64_linux_nat_target): New.
8740 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
8741 (ia64_linux_stopped_data_address)
8742 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
8743 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
8744 ia64_linux_nat_target methods.
8745 (super_xfer_partial): Delete.
8746 (_initialize_ia64_linux_nat): Adjust to C++ification.
8747
8748 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
8749 (the_m32r_linux_nat_target): New.
8750 (m32r_linux_fetch_inferior_registers)
8751 (m32r_linux_store_inferior_registers): Refactor as
8752 m32r_linux_nat_target methods.
8753 (_initialize_m32r_linux_nat): Adjust to C++ification.
8754
8755 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
8756 (the_m68k_linux_nat_target): New.
8757 (m68k_linux_fetch_inferior_registers)
8758 (m68k_linux_store_inferior_registers): Refactor as
8759 m68k_linux_nat_target methods.
8760 (_initialize_m68k_linux_nat): Adjust to C++ification.
8761
8762 * s390-linux-nat.c (s390_linux_nat_target): New class.
8763 (the_s390_linux_nat_target): New.
8764 (s390_linux_fetch_inferior_registers)
8765 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
8766 (s390_insert_watchpoint, s390_remove_watchpoint)
8767 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
8768 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
8769 (s390_auxv_parse, s390_read_description): Refactor as methods of
8770 s390_linux_nat_target.
8771 (_initialize_s390_nat): Adjust to C++ification.
8772
8773 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
8774 (the_sparc_linux_nat_target): New.
8775 (_initialize_sparc_linux_nat): Adjust to C++ification.
8776 * sparc-nat.c (sparc_fetch_inferior_registers)
8777 (sparc_store_inferior_registers): Remove target_ops parameter.
8778 * sparc-nat.h (sparc_fetch_inferior_registers)
8779 (sparc_store_inferior_registers): Remove target_ops parameter.
8780 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
8781 (the_sparc64_linux_nat_target): New.
8782 (_initialize_sparc64_linux_nat): Adjust to C++ification.
8783
8784 * spu-linux-nat.c (spu_linux_nat_target): New class.
8785 (the_spu_linux_nat_target): New.
8786 (spu_child_post_startup_inferior, spu_child_post_attach)
8787 (spu_child_wait, spu_fetch_inferior_registers)
8788 (spu_store_inferior_registers, spu_xfer_partial)
8789 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
8790 methods.
8791 (_initialize_spu_nat): Adjust to C++ification.
8792
8793 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
8794 (the_tilegx_linux_nat_target): New.
8795 (fetch_inferior_registers, store_inferior_registers):
8796 Refactor as methods.
8797 (_initialize_tile_linux_nat): Adjust to C++ification.
8798
8799 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
8800 (the_xtensa_linux_nat_target): New.
8801 (xtensa_linux_fetch_inferior_registers)
8802 (xtensa_linux_store_inferior_registers): Refactor as
8803 xtensa_linux_nat_target methods.
8804 (_initialize_xtensa_linux_nat): Adjust to C++ification.
8805
8806 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
8807 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
8808 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
8809 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
8810 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
8811 (fbsd_stopped_by_sw_breakpoint)
8812 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
8813 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
8814 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
8815 (fbsd_post_startup_inferior, fbsd_post_attach)
8816 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
8817 (fbsd_set_syscall_catchpoint)
8818 (super_xfer_partial, super_resume, super_wait)
8819 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
8820 (fbsd_handle_debug_trap): Remove target_ops parameter.
8821 (fbsd_nat_add_target): Delete.
8822 * fbsd-nat.h: Include "inf-ptrace.h".
8823 (fbsd_nat_add_target): Delete.
8824 (USE_SIGTRAP_SIGINFO): Define.
8825 (fbsd_nat_target): New class.
8826
8827 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
8828 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
8829 (amd64bsd_target): Delete.
8830 * amd64-bsd-nat.h: New file.
8831 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
8832 "x86-bsd-nat.h".
8833 (amd64_fbsd_nat_target): New class.
8834 (the_amd64_fbsd_nat_target): New.
8835 (amd64fbsd_read_description): Refactor as method of
8836 amd64_fbsd_nat_target.
8837 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8838 (_initialize_amd64fbsd_nat): Adjust to C++ification.
8839 * amd64-nat.h (amd64bsd_target): Delete function declaration.
8840 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
8841 (i386bsd_store_inferior_registers): Remove target_ops parameter.
8842 (i386bsd_target): Delete.
8843 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
8844 (i386bsd_fetch_inferior_registers)
8845 (i386bsd_store_inferior_registers): Declare.
8846 (i386_bsd_nat_target): New class.
8847 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
8848 (the_i386_fbsd_nat_target): New.
8849 (i386fbsd_resume, i386fbsd_read_description): Refactor as
8850 i386_fbsd_nat_target methods.
8851 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
8852 (_initialize_i386fbsd_nat): Adjust to C++ification.
8853 * x86-bsd-nat.c (super_mourn_inferior): Delete.
8854 (x86bsd_mourn_inferior, x86bsd_target): Delete.
8855 (_initialize_x86_bsd_nat): Adjust to C++ification.
8856 * x86-bsd-nat.h: Include "x86-nat.h".
8857 (x86bsd_target): Delete declaration.
8858 (x86bsd_nat_target): New class.
8859
8860 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
8861 (the_aarch64_fbsd_nat_target): New.
8862 (aarch64_fbsd_fetch_inferior_registers)
8863 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
8864 aarch64_fbsd_nat_target.
8865 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
8866 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
8867 (the_alpha_bsd_nat_target): New.
8868 (alphabsd_fetch_inferior_registers)
8869 (alphabsd_store_inferior_registers): Refactor as
8870 alpha_bsd_nat_target methods.
8871 (_initialize_alphabsd_nat): Refactor as methods of
8872 alpha_bsd_nat_target.
8873 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
8874 (the_amd64_nbsd_nat_target): New.
8875 (_initialize_amd64nbsd_nat): Adjust to C++ification.
8876 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
8877 (the_amd64_obsd_nat_target): New.
8878 (_initialize_amd64obsd_nat): Adjust to C++ification.
8879 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
8880 (the_arm_fbsd_nat_target): New.
8881 (arm_fbsd_fetch_inferior_registers)
8882 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
8883 (_initialize_arm_fbsd_nat): Refactor as methods of
8884 arm_fbsd_nat_target.
8885 (_initialize_arm_fbsd_nat): Adjust to C++ification.
8886 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
8887 (the_arm_netbsd_nat_target): New.
8888 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
8889 arm_netbsd_nat_target.
8890 (_initialize_arm_netbsd_nat): Adjust to C++ification.
8891 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
8892 (the_hppa_nbsd_nat_target): New.
8893 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
8894 hppa_nbsd_nat_target methods.
8895 (_initialize_hppanbsd_nat): Adjust to C++ification.
8896 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
8897 (the_hppa_obsd_nat_target): New.
8898 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
8899 methods of hppa_obsd_nat_target.
8900 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
8901 add_target.
8902 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
8903 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
8904 add_target.
8905 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
8906 (_initialize_i386obsd_nat): Use add_target.
8907 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
8908 (the_m68k_bsd_nat_target): New.
8909 (m68kbsd_fetch_inferior_registers)
8910 (m68kbsd_store_inferior_registers): Refactor as methods of
8911 m68k_bsd_nat_target.
8912 (_initialize_m68kbsd_nat): Adjust to C++ification.
8913 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
8914 (the_mips_fbsd_nat_target): New.
8915 (mips_fbsd_fetch_inferior_registers)
8916 (mips_fbsd_store_inferior_registers): Refactor as methods of
8917 mips_fbsd_nat_target.
8918 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
8919 add_target.
8920 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
8921 (the_mips_nbsd_nat_target): New.
8922 (mipsnbsd_fetch_inferior_registers)
8923 (mipsnbsd_store_inferior_registers): Refactor as methods of
8924 mips_nbsd_nat_target.
8925 (_initialize_mipsnbsd_nat): Adjust to C++ification.
8926 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
8927 (the_mips64_obsd_nat_target): New.
8928 (mips64obsd_fetch_inferior_registers)
8929 (mips64obsd_store_inferior_registers): Refactor as methods of
8930 mips64_obsd_nat_target.
8931 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
8932 add_target.
8933 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
8934 nbsd_nat_target.
8935 * nbsd-nat.h: Include "inf-ptrace.h".
8936 (nbsd_nat_target): New class.
8937 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
8938 (obsd_wait): Refactor as methods of obsd_nat_target.
8939 (obsd_add_target): Delete.
8940 * obsd-nat.h: Include "inf-ptrace.h".
8941 (obsd_nat_target): New class.
8942 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
8943 (the_ppc_fbsd_nat_target): New.
8944 (ppcfbsd_fetch_inferior_registers)
8945 (ppcfbsd_store_inferior_registers): Refactor as methods of
8946 ppc_fbsd_nat_target.
8947 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
8948 add_target.
8949 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
8950 (the_ppc_nbsd_nat_target): New.
8951 (ppcnbsd_fetch_inferior_registers)
8952 (ppcnbsd_store_inferior_registers): Refactor as methods of
8953 ppc_nbsd_nat_target.
8954 (_initialize_ppcnbsd_nat): Adjust to C++ification.
8955 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
8956 (the_ppc_obsd_nat_target): New.
8957 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
8958 methods of ppc_obsd_nat_target.
8959 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
8960 add_target.
8961 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
8962 (the_sh_nbsd_nat_target): New.
8963 (shnbsd_fetch_inferior_registers)
8964 (shnbsd_store_inferior_registers): Refactor as methods of
8965 sh_nbsd_nat_target.
8966 (_initialize_shnbsd_nat): Adjust to C++ification.
8967 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
8968 (inf_ptrace_xfer_partial): Delete.
8969 (sparc_xfer_partial, sparc_target): Delete.
8970 * sparc-nat.h (sparc_fetch_inferior_registers)
8971 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
8972 (sparc_target): Delete function declaration.
8973 (sparc_target): New template class.
8974 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
8975 (_initialize_sparcnbsd_nat): Adjust to C++ification.
8976 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
8977 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
8978 add_target.
8979 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
8980 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
8981 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
8982 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
8983 add_target.
8984 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
8985 (the_vax_bsd_nat_target): New.
8986 (vaxbsd_fetch_inferior_registers)
8987 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
8988 methods.
8989 (_initialize_vaxbsd_nat): Adjust to C++ification.
8990
8991 * bsd-kvm.c (bsd_kvm_target): New class.
8992 (bsd_kvm_ops): Now a bsd_kvm_target.
8993 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
8994 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
8995 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
8996 bsd_kvm_target.
8997 (bsd_kvm_return_one): Delete.
8998 (bsd_kvm_add_target): Adjust to C++ification.
8999
9000 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
9001 (nto_procfs_target_procfs): New classes.
9002 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
9003 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
9004 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
9005 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
9006 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
9007 (procfs_remove_hw_breakpoint, procfs_resume)
9008 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
9009 (procfs_kill_inferior, procfs_store_registers)
9010 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
9011 as methods of nto_procfs_target.
9012 (nto_procfs_ops): Now an nto_procfs_target_procfs.
9013 (nto_native_ops): Delete.
9014 (procfs_open, procfs_native_open): Delete.
9015 (nto_native_ops): Now an nto_procfs_target_native.
9016 (init_procfs_targets): Adjust to C++ification.
9017 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
9018 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
9019 Refactor as methods of nto_procfs_target.
9020
9021 * go32-nat.c (go32_nat_target): New class.
9022 (the_go32_nat_target): New.
9023 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
9024 (go32_store_registers, go32_xfer_partial, go32_files_info)
9025 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
9026 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
9027 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
9028 (go32_pid_to_str): Refactor as methods of go32_nat_target.
9029 (go32_target): Delete.
9030 (_initialize_go32_nat): Adjust to C++ification.
9031
9032 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
9033 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
9034 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
9035 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
9036 gnu_nat_target.
9037 (gnu_target): Delete.
9038 * gnu-nat.h (gnu_target): Delete.
9039 (gnu_nat_target): New class.
9040 * i386-gnu-nat.c (gnu_base_target): New.
9041 (i386_gnu_nat_target): New class.
9042 (the_i386_gnu_nat_target): New.
9043 (_initialize_i386gnu_nat): Adjust to C++ification.
9044
9045 2018-05-02 Pedro Alves <palves@redhat.com>
9046
9047 * bfd-target.c (target_bfd_xclose): Rename to ...
9048 (target_bfd_close): ... this.
9049 (target_bfd_reopen): Adjust.
9050 * target.c (target_close): Remove references to to_xclose.
9051 * target.h (target_ops::to_xclose): Delete.
9052 (target_ops::to_close): Update comments.
9053
9054 2018-05-02 Pedro Alves <palves@redhat.com>
9055
9056 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
9057 "linux-nat.h".
9058 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
9059 * inf-ptrace.c (inf_ptrace_register_u_offset)
9060 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9061 (inf_ptrace_store_register, inf_ptrace_store_registers)
9062 (inf_ptrace_trad_target): Move to ...
9063 * linux-nat-trad.c: ... this new file.
9064 * linux-nat-trad.h: New file.
9065 * linux-nat.c (linux_target_install_ops): Make extern.
9066 (linux_trad_target): Delete.
9067 * linux-nat.h (linux_trad_target): Delete declaration.
9068 (linux_target_install_ops): Declare.
9069 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
9070 "linux-nat.h".
9071
9072 2018-05-02 Pedro Alves <palves@redhat.com>
9073
9074 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9075 procfs_target/add_target here.
9076 * procfs.c (procfs_target): Make static.
9077 (_initialize_procfs): Call add_target here.
9078 * procfs.h (struct target_ops): Remove forward declaration.
9079 (procfs_target): Remove declaration.
9080 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
9081
9082 2018-05-02 Pedro Alves <palves@redhat.com>
9083
9084 * procfs.c (procfs_stopped_by_watchpoint)
9085 (procfs_insert_watchpoint, procfs_remove_watchpoint)
9086 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
9087 Forward declare.
9088 (procfs_use_watchpoints): Delete, move contents...
9089 (procfs_target): ... here.
9090 * procfs.h (procfs_use_watchpoints): Delete declaration.
9091 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
9092 procfs_use_watchpoints.
9093 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
9094 procfs_use_watchpoints.
9095
9096 2018-05-02 Tom Tromey <tom@tromey.com>
9097
9098 PR python/20084:
9099 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
9100 and var_zuinteger_unlimited.
9101 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
9102 and PARAM_ZUINTEGER_UNLIMITED.
9103 (set_parameter_value): Handle var_zuinteger and
9104 var_zuinteger_unlimited.
9105 (add_setshow_generic): Likewise.
9106 (parmpy_init): Likewise.
9107
9108 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
9109
9110 PR rust/23124
9111 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
9112 pointer is not null before dereferencing it.
9113
9114 2018-04-30 Tom Tromey <tom@tromey.com>
9115
9116 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
9117 is_mi_like_p.
9118
9119 2018-04-30 Tom Tromey <tom@tromey.com>
9120
9121 * breakpoint.c (mention): Remove use of is_mi_like_p.
9122 (print_mention_ranged_breakpoint): Likewise.
9123 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
9124 of is_mi_like_p.
9125
9126 2018-04-30 Tom Tromey <tom@tromey.com>
9127
9128 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
9129
9130 2018-04-30 Tom Tromey <tom@tromey.com>
9131
9132 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
9133 (info_spu_event_command): Remove some uses of is_mi_like_p.
9134
9135 2018-04-30 Tom Tromey <tom@tromey.com>
9136
9137 * python/py-framefilter.c (py_print_single_arg)
9138 (enumerate_locals, py_print_args, py_print_frame): Remove some
9139 uses of is_mi_like_p.
9140
9141 2018-04-30 Tom Tromey <tom@tromey.com>
9142
9143 * ui-out.c: Update.
9144 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
9145 * ui-out.h (ui_out::is_mi_like_p): Now const.
9146 (ui_out::do_is_mi_like_p): Now const.
9147 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
9148
9149 2018-04-30 Tom Tromey <tom@tromey.com>
9150
9151 * varobj.c (varobj_set_visualizer): Use new_reference.
9152 * python/python.c (gdbpy_decode_line): Use new_reference.
9153 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
9154 new_reference.
9155
9156 2018-04-30 Tom Tromey <tom@tromey.com>
9157
9158 * varobj.c (install_new_value): Use new_reference.
9159 * value.h (value_incref): Return void. Swap intro comment with
9160 value_decref.
9161 * value.c (set_value_parent): Use new_reference.
9162 (value_incref): Return void. Update intro comment.
9163 (release_value): Use new_reference.
9164 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
9165
9166 2018-04-30 Tom Tromey <tom@tromey.com>
9167
9168 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
9169 * gdb_bfd.h (new_bfd_ref): Remove.
9170 (gdb_bfd_open): Update comment.
9171 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
9172 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
9173 (gdb_bfd_fdopenr): Use new_reference.
9174 * exec.c (exec_file_attach): Use new_reference.
9175
9176 2018-04-30 Tom Tromey <tom@tromey.com>
9177
9178 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
9179 method.
9180
9181 2018-04-30 Tom Tromey <tom@tromey.com>
9182
9183 * jit.c (jit_read_code_entry): Use type_align.
9184 * i386-tdep.c (i386_gdbarch_init): Don't call
9185 set_gdbarch_long_long_align_bit.
9186 * gdbarch.sh: Remove long_long_align_bit.
9187 * gdbarch.c, gdbarch.h: Rebuild.
9188 * arc-tdep.c (arc_type_align): New function.
9189 (arc_gdbarch_init): Use arc_type_align. Don't call
9190 set_gdbarch_long_long_align_bit.
9191
9192 2018-04-30 Tom Tromey <tom@tromey.com>
9193
9194 * rust-lang.c (rust_type_alignment): Remove.
9195 (rust_composite_type): Use type_align.
9196
9197 2018-04-30 Tom Tromey <tom@tromey.com>
9198
9199 * NEWS: Mention Type.align.
9200 * python/py-type.c (typy_get_alignof): New function.
9201 (type_object_getset): Add "alignof".
9202
9203 2018-04-30 Tom Tromey <tom@tromey.com>
9204
9205 PR exp/17095:
9206 * NEWS: Update.
9207 * std-operator.def (UNOP_ALIGNOF): New operator.
9208 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
9209 New.
9210 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
9211 * c-lang.c (c_op_print_tab): Add alignof.
9212 * c-exp.y (ALIGNOF): New token.
9213 (exp): Add "ALIGNOF" production.
9214 (ident_tokens): Add _Alignof and alignof.
9215
9216 2018-04-30 Tom Tromey <tom@tromey.com>
9217
9218 * i386-tdep.c (i386_type_align): New function.
9219 (i386_gdbarch_init): Update.
9220 * gdbarch.sh (type_align): New method.
9221 * gdbarch.c, gdbarch.h: Rebuild.
9222 * arch-utils.h (default_type_align): Declare.
9223 * arch-utils.c (default_type_align): New function.
9224 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
9225 (struct type) <align_log2>: New field.
9226 <instance_flags>: Now a bitfield.
9227 (TYPE_RAW_ALIGN): New macro.
9228 (type_align, type_raw_align, set_type_align): Declare.
9229 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
9230 functions.
9231 * dwarf2read.c (quirk_rust_enum): Set type alignment.
9232 (get_alignment, maybe_set_alignment): New functions.
9233 (read_structure_type, read_enumeration_type, read_array_type)
9234 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
9235 (read_subrange_type, read_base_type): Set type alignment.
9236
9237 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
9238
9239 * dwarf2read.c (read_index_from_section): Use bool.
9240
9241 2018-04-29 Fabian Groffen <grobian@gentoo.org>
9242
9243 PR gdb/22950
9244 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
9245 with #ifdef.
9246
9247 2018-04-29 John Reiser <jreiser@BitWagon.com>
9248
9249 PR build/22873
9250 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
9251 last step, and do it atomically.
9252
9253 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
9254
9255 * compile/compile-c-types.c (convert_int, convert_float):
9256 Update for C FE v1.
9257
9258 2018-04-27 Tom Tromey <tom@tromey.com>
9259
9260 PR rust/22545:
9261 * rust-lang.c (rust_inclusive_range_type_p): New function.
9262 (rust_range): Handle inclusive ranges.
9263 (rust_compute_range): Likewise.
9264 * rust-exp.y (struct rust_op) <inclusive>: New field.
9265 (DOTDOTEQ): New constant.
9266 (range_expr): Add "..=" productions.
9267 (operator_tokens): Add "..=" token.
9268 (ast_range): Add "inclusive" parameter.
9269 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
9270 ranges.
9271 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
9272 bounds values.
9273 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
9274 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
9275 Update comments.
9276 * expprint.c (print_subexp_standard): Handle new bounds values.
9277 (dump_subexp_body_standard): Likewise.
9278
9279 2018-04-27 Tom Tromey <tom@tromey.com>
9280
9281 * configure: Rebuild.
9282 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
9283 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
9284 "OVERRIDE".
9285 (class symbol_needs_eval_context): Likewise.
9286 * dwarf2read.c (mock_mapped_index::symbol_name_count)
9287 (mock_mapped_index::symbol_name_at): Use "override". Remove
9288 "virtual".
9289 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
9290 "override".
9291 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
9292 * aarch64-tdep.c (instruction_reader::read): Use "override".
9293 (instruction_reader_test::read): Likewise.
9294 * arm-tdep.c (instruction_reader::read): Use "override".
9295 (instruction_reader_thumb::read): Likewise.
9296
9297 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
9298
9299 PR remote/9665
9300 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
9301 instead of remote_send.
9302 (remote_send): Remove.
9303
9304 2018-04-26 Pedro Alves <palves@redhat.com>
9305
9306 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
9307 find_function_start_sal instead of find_pc_line.
9308
9309 2018-04-26 Pedro Alves <palves@redhat.com>
9310
9311 * breakpoint.c (set_breakpoint_location_function): Handle
9312 mst_data_gnu_ifunc.
9313 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
9314 * elfread.c (elf_symtab_read): Give data symbols with
9315 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
9316 (elf_rel_plt_read): Update comment.
9317 * linespec.c (convert_linespec_to_sals): Handle
9318 mst_data_gnu_ifunc.
9319 (minsym_found): Handle mst_data_gnu_ifunc.
9320 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
9321 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
9322 * parse.c (find_minsym_type_and_address): Handle
9323 mst_data_gnu_ifunc.
9324 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
9325 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
9326 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
9327 comment.
9328 <mst_data_gnu_ifunc>: New enumerator.
9329
9330 2018-04-26 Pedro Alves <palves@redhat.com>
9331
9332 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
9333 (lookup_minimal_symbol_by_pc_section): ... this. Replace
9334 'want_trampoline' parameter by a lookup_msym_prefer parameter.
9335 Handle it.
9336 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
9337 (lookup_minimal_symbol_by_pc): Adjust.
9338 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
9339 (lookup_solib_trampoline_symbol_by_pc): Adjust.
9340 * minsyms.h (lookup_msym_prefer): New enum.
9341 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9342 parameter by a lookup_msym_prefer parameter.
9343
9344 2018-04-26 Pedro Alves <palves@redhat.com>
9345
9346 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
9347 ends in "@plt" instead of looking at the symbol's section.
9348
9349 2018-04-26 Pedro Alves <palves@redhat.com>
9350
9351 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
9352 all references.
9353 (find_pc_partial_function_gnu_ifunc): Rename to ...
9354 (find_pc_partial_function): ... this, and remove references to
9355 'is_gnu_ifunc_p'.
9356 (find_pc_partial_function): Delete old implementation.
9357 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
9358
9359 2018-04-26 Pedro Alves <palves@redhat.com>
9360
9361 * linespec.c (struct bound_minimal_symbol_search_key): New.
9362 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
9363 skip first line if we found a GNU ifunc minimal symbol by name.
9364 (compare_msymbols): Change parameters to work with a destructured
9365 lhs minsym.
9366 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
9367 functions.
9368
9369 2018-04-26 Pedro Alves <palves@redhat.com>
9370
9371 * breakpoint.c (set_breakpoint_location_function): Don't resolve
9372 ifunc targets here. Instead, if we have an ifunc minsym, use its
9373 address/name.
9374 (add_location_to_breakpoint): Store the minsym and the objfile in
9375 the breakpoint location.
9376 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
9377 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
9378 Record the minsym in the sal.
9379 * symtab.h (symtab_and_line) <msymbol>: New field.
9380
9381 2018-04-26 Pedro Alves <palves@redhat.com>
9382
9383 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
9384 unless we actually resolved the ifunc.
9385
9386 2018-04-26 Pedro Alves <palves@redhat.com>
9387
9388 * c-exp.y (variable production): Prefer ifunc minsyms over
9389 regular function symbols.
9390 * symtab.c (find_gnu_ifunc): New function.
9391 * minsyms.h (lookup_msym_prefer): New enum.
9392 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
9393 parameter by a lookup_msym_prefer parameter.
9394 * symtab.h (find_gnu_ifunc): New declaration.
9395
9396 2018-04-26 Pedro Alves <palves@redhat.com>
9397
9398 * blockframe.c (find_gnu_ifunc_target_type): New function.
9399 (find_function_type): New.
9400 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
9401 return a value with a memory address.
9402 (eval_call): For calls to GNU ifunc functions, try to find the
9403 type of the target function from the type that the resolver
9404 returns.
9405 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
9406 symbols.
9407 * infcall.c (find_function_return_type): Delete.
9408 (find_function_addr): Add 'function_type' parameter. For calls to
9409 GNU ifunc functions, try to find the type of the target function
9410 from the type that the resolver returns, and return it via
9411 FUNCTION_TYPE.
9412 (call_function_by_hand_dummy): Adjust to use the function type
9413 returned by find_function_addr.
9414 (find_function_addr): Add 'function_type' parameter and move
9415 description here.
9416 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
9417 declarations.
9418
9419 2018-04-26 Pedro Alves <palves@redhat.com>
9420
9421 * c-exp.y (variable production): Skip finding an alias for ifunc
9422 symbols.
9423
9424 2018-04-26 Pedro Alves <palves@redhat.com>
9425
9426 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
9427
9428 2018-04-25 Pedro Alves <palves@redhat.com>
9429
9430 * infcmd.c (kill_command): Print the pid as string, not the whole
9431 thread's ptid. Add comment. s/has been killed/killed/ in output
9432 message.
9433 * remote.c (remote_detach_1): Print the pid as string, not the
9434 whole thread's ptid.
9435
9436 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9437 Sergio Durigan Junior <sergiodj@redhat.com>
9438 Pedro Alves <palves@redhat.com>
9439
9440 * infcmd.c (kill_command): Print message when inferior has
9441 been killed.
9442 * inferior.c (print_inferior_events): Remove 'static'. Set as
9443 '1'.
9444 (add_inferior): Improve message printed when
9445 'print_inferior_events' is on.
9446 (exit_inferior): Remove message printed when
9447 'print_inferior_events' is on.
9448 (detach_inferior): Improve message printed when
9449 'print_inferior_events' is on.
9450 (initialize_inferiors): Use 'add_inferior_silent' to set
9451 'current_inferior_'.
9452 * inferior.h (print_inferior_events): Declare here as
9453 'extern'.
9454 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
9455 '[Detaching...]' messages when 'print_inferior_events' is on.
9456 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
9457 as prefix/suffix for messages. Remove periods. Fix erroneous
9458 'Detaching after fork from child...', replace it by '... from
9459 parent...'.
9460 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
9461 prefix/suffix when printing 'Detaching...' messages. Print
9462 them when 'print_inferior_events' is on.
9463 * remote.c (remote_detach_1): Print message when detaching
9464 from inferior and '!is_fork_parent'.
9465
9466 2018-04-24 Tom Tromey <tom@tromey.com>
9467
9468 * cli-out.h: Reindent.
9469
9470 2018-04-24 Tom Tromey <tom@tromey.com>
9471
9472 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
9473 (cli_ui_out::do_field_string): Use fputs_filtered.
9474 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
9475
9476 2018-04-23 Tom Tromey <tom@tromey.com>
9477
9478 * guile/scm-frame.c (gdbscm_frame_read_var): Use
9479 gdb::unique_xmalloc_ptr.
9480
9481 2018-04-23 Tom Tromey <tom@tromey.com>
9482
9483 * configure: Rebuild.
9484
9485 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
9486
9487 PR gdb/23095
9488 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
9489 prepare_for_testing. Set normal_bp to r_debug_state if target
9490 is bsd.
9491
9492 2018-04-21 Pedro Alves <palves@redhat.com>
9493 Rajendra SY <rajendra.sy@gmail.com>
9494
9495 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
9496 * remote.c (extended_remote_attach): In all-stop mode, mark the
9497 thread as executing.
9498
9499 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9500
9501 * thread.c (thread_apply_all_command): Fix comment.
9502 (thread_command): Fix comment.
9503
9504 2018-04-10 Alan Hayward <alan.hayward@arm.com>
9505
9506 * common/tdesc.h (tdesc_create_feature): Remove xml filename
9507 parameter.
9508 * features/aarch64-core.c (create_feature_aarch64_core):
9509 Regenerate.
9510 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
9511 Likewise.
9512 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
9513 Likewise.
9514 * features/i386/32bit-avx512.c
9515 (create_feature_i386_32bit_avx512): Likewise.
9516 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
9517 Likewise.
9518 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
9519 Likewise.
9520 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
9521 Likewise.
9522 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
9523 Likewise.
9524 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
9525 Likewise.
9526 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
9527 Likewise.
9528 * features/i386/64bit-avx512.c
9529 (create_feature_i386_64bit_avx512): Likewise.
9530 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
9531 Likewise.
9532 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
9533 Likewise.
9534 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
9535 Likewise.
9536 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
9537 Likewise.
9538 * features/i386/64bit-segments.c
9539 (create_feature_i386_64bit_segments): Likewise.
9540 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
9541 Likewise.
9542 * features/i386/x32-core.c
9543 (create_feature_i386_x32_core): Likewise.
9544 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
9545 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
9546 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
9547 * target-descriptions.c: In generated code, don't pass xml
9548 filename.
9549
9550 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9551
9552 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
9553 (print_xml_feature::visit_post): Likewise.
9554 (print_xml_feature::visit): Likewise.
9555 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
9556 (print_xml_feature): Add new class.
9557 * regformats/regdat.sh: Null xmltarget on feature targets.
9558 * target-descriptions.c (struct target_desc): Add xmltarget.
9559 (maintenance_check_tdesc_xml_convert): Add unittest function.
9560 (tdesc_get_features_xml): Add function to get xml.
9561 (maintenance_check_xml_descriptions): Test xml generation.
9562 * xml-tdesc.c (string_read_description_xml): Add function.
9563 * xml-tdesc.h (string_read_description_xml): Add declaration.
9564
9565 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9566
9567 * features/Makefile: Add feature marker to targets with new style
9568 target descriptions.
9569 * regformats/aarch64.dat: Regenerate.
9570 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
9571 * regformats/i386/amd64-avx-linux.dat: Likewise.
9572 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
9573 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
9574 * regformats/i386/amd64-linux.dat: Likewise.
9575 * regformats/i386/amd64-mpx-linux.dat: Likewise.
9576 * regformats/i386/amd64.dat: Likewise.
9577 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
9578 * regformats/i386/i386-avx-linux.dat: Likewise.
9579 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
9580 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
9581 * regformats/i386/i386-linux.dat: Likewise.
9582 * regformats/i386/i386-mmx-linux.dat: Likewise.
9583 * regformats/i386/i386-mpx-linux.dat: Likewise.
9584 * regformats/i386/i386.dat: Likewise.
9585 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
9586 * regformats/i386/x32-avx-linux.dat: Likewise.
9587 * regformats/i386/x32-linux.dat: Likewise.
9588 * regformats/tic6x-c62x-linux.dat: Likewise.
9589 * regformats/tic6x-c64x-linux.dat: Likewise.
9590 * regformats/tic6x-c64xp-linux.dat: Likewise.
9591 * regformats/regdat.sh: Parse feature marker.
9592
9593 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9594
9595 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
9596 (tdesc_osabi_name): Likewise.
9597 * target-descriptions.c (tdesc_architecture_name): Add new
9598 function.
9599 (tdesc_osabi_name): Likewise.
9600
9601 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9602
9603 * common/tdesc.c (tdesc_predefined_type): Move to here.
9604 (tdesc_named_type): Likewise.
9605 (tdesc_create_vector): Likewise.
9606 (tdesc_create_struct): Likewise.
9607 (tdesc_set_struct_size): Likewise.
9608 (tdesc_create_union): Likewise.
9609 (tdesc_create_flags): Likewise.
9610 (tdesc_create_enum): Likewise.
9611 (tdesc_add_field): Likewise.
9612 (tdesc_add_typed_bitfield): Likewise.
9613 (tdesc_add_bitfield): Likewise.
9614 (tdesc_add_flag): Likewise.
9615 (tdesc_add_enum_value): Likewise.
9616 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
9617 (struct tdesc_type_vector): Likewise.
9618 (struct tdesc_type_field): Likewise.
9619 (struct tdesc_type_with_fields): Likewise.
9620 (tdesc_create_enum): Add declaration.
9621 (tdesc_add_typed_bitfield): Likewise.
9622 (tdesc_add_enum_value): Likewise.
9623 * target-descriptions.c (tdesc_type_field): Move from here.
9624 (tdesc_type_builtin): Likewise.
9625 (tdesc_type_vector): Likewise.
9626 (tdesc_type_with_fields): Likewise.
9627 (tdesc_predefined_types): Likewise.
9628 (tdesc_named_type): Likewise.
9629 (tdesc_create_vector): Likewise.
9630 (tdesc_create_struct): Likewise.
9631 (tdesc_set_struct_size): Likewise.
9632 (tdesc_create_union): Likewise.
9633 (tdesc_create_flags): Likewise.
9634 (tdesc_create_enum): Likewise.
9635 (tdesc_add_field): Likewise.
9636 (tdesc_add_typed_bitfield): Likewise.
9637 (tdesc_add_bitfield): Likewise.
9638 (tdesc_add_flag): Likewise.
9639 (tdesc_add_enum_value): Likewise.
9640 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
9641 (tdesc_add_typed_bitfield): Likewise.
9642 (tdesc_add_enum_value): Likewise.
9643
9644 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9645
9646 * common/tdesc.c (tdesc_feature::accept): Move to here.
9647 (tdesc_feature::operator==): Likewise.
9648 (tdesc_create_reg): Likewise.
9649 * common/tdesc.h (tdesc_type_kind): Likewise.
9650 (struct tdesc_type): Likewise.
9651 (struct tdesc_feature): Likewise.
9652 * regformats/regdat.sh: Create a feature.
9653 * target-descriptions.c (tdesc_type_kind): Move from here.
9654 (tdesc_type): Likewise.
9655 (tdesc_type_up): Likewise.
9656 (tdesc_feature): Likewise.
9657 (tdesc_create_reg): Likewise.
9658
9659 2018-04-18 Alan Hayward <alan.hayward@arm.com>
9660
9661 * Makefile.in: Add arch/tdesc.c
9662 * common/tdesc.c: New file.
9663 * common/tdesc.h (tdesc_element_visitor): Move to here.
9664 (tdesc_element): Likewise.
9665 (tdesc_reg): Likewise.
9666 (tdesc_reg_up): Likewise.
9667 * regformats/regdef.h (reg): Add offset to constructors.
9668 * target-descriptions.c (tdesc_element_visitor): Move from here.
9669 (tdesc_element): Likewise.
9670 (tdesc_reg): Likewise.
9671 (tdesc_reg_up): Likewise.
9672
9673 2018-04-17 Tom Tromey <tom@tromey.com>
9674
9675 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
9676 discriminant field.
9677
9678 2018-04-17 Tom Tromey <tom@tromey.com>
9679
9680 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
9681
9682 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
9683
9684 * symtab.c (print_symbol_info): Skip printing filename and line
9685 number when `last' is NULL.
9686 (symtab_symbol_info): Use empty string instead of NULL for first
9687 invocation of print_symbol_info.
9688 (rbreak_command): Pass NULL to `last' parameter of
9689 print_symbol_info.
9690
9691 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
9692
9693 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
9694 instead of nullptr.
9695
9696 2018-04-16 Pedro Alves <palves@redhat.com>
9697
9698 * MAINTAINERS (sh): Remove.
9699 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
9700 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
9701 (ALLDEPFILES): Remove sh64-tdep.c.
9702 * NEWS: Mentions that support for SH-5/SH64 is removed.
9703 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
9704 (sh*-*-openbsd*): Ditto.
9705 (sh64-*-elf*): Remove.
9706 (sh*): Remove.
9707 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
9708 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
9709 * sh-tdep.c: No longer include "sh64-tdep.h".
9710 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
9711 * sh64-tdep.c, sh64-tdep.h: Remove files.
9712
9713 2018-04-16 Pedro Alves <palves@redhat.com>
9714
9715 * MAINTAINERS: Remove m88k.
9716 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
9717 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
9718 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
9719 * NEWS: Mention that support for m88k was removed.
9720 * configure.host (m88*-*-*): Remove support.
9721 * configure.nat (m88k-*-*): Remove support.
9722 * configure.tgt (m88*-*-openbsd*): Remove.
9723 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
9724
9725 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
9726
9727 * configure.tgt (x86_tobjs): New variable.
9728 (amd64_tobjs, i386_tobjs): Use it.
9729
9730 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9731
9732 * symtab.c (print_symbol_info): Precede the symbol definition by
9733 the line number when available.
9734 * NEWS: Advertise this enhancement.
9735
9736 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9737
9738 * NEWS (New options): announce set/show record btrace cpu.
9739 * btrace.c: Include record-btrace.h.
9740 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
9741 the vendor is unknown.
9742 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
9743 Maybe overwrite the btrace configuration's cpu.
9744 (btrace_compute_ftrace): Add cpu parameter. Update callers.
9745 (btrace_fetch): Add cpu parameter. Update callers.
9746 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
9747 Maybe overwrite the btrace configuration's cpu. Skip enabling
9748 errata workarounds if the vendor is unknown.
9749 * python/py-record-btrace.c: Include record-btrace.h.
9750 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
9751 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
9752 * record-btrace.c (record_btrace_cpu_state_kind): New.
9753 (record_btrace_cpu): New.
9754 (set_record_btrace_cpu_cmdlist): New.
9755 (record_btrace_get_cpu): New.
9756 (require_btrace_thread, record_btrace_info)
9757 (record_btrace_resume_thread): Call record_btrace_get_cpu.
9758 (cmd_set_record_btrace_cpu_none): New.
9759 (cmd_set_record_btrace_cpu_auto): New.
9760 (cmd_set_record_btrace_cpu): New.
9761 (cmd_show_record_btrace_cpu): New.
9762 (_initialize_record_btrace): Initialize set/show record btrace cpu
9763 commands.
9764 * record-btrace.h (record_btrace_get_cpu): New.
9765
9766 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9767
9768 * record.c (set_record_command): Fix typo in message.
9769
9770 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9771
9772 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
9773
9774 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
9775
9776 * infrun.c (process_event_stop_test): Call
9777 gdbarch_in_indirect_branch_thunk.
9778 * gdbarch.sh (in_indirect_branch_thunk): New.
9779 * gdbarch.c: Regenerated.
9780 * gdbarch.h: Regenerated.
9781 * x86-tdep.h: New.
9782 * x86-tdep.c: New.
9783 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
9784 (HFILES_NO_SRCDIR): Add x86-tdep.h.
9785 (ALLDEPFILES): Add x86-tdep.c.
9786 * arch-utils.h (default_in_indirect_branch_thunk): New.
9787 * arch-utils.c (default_in_indirect_branch_thunk): New.
9788 * i386-tdep: Include x86-tdep.h.
9789 (i386_in_indirect_branch_thunk): New.
9790 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
9791 function.
9792 * amd64-tdep: Include x86-tdep.h.
9793 (amd64_in_indirect_branch_thunk): New.
9794 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
9795
9796 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9797
9798 PR gdb/23053
9799 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
9800 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
9801 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
9802 regression.
9803
9804 2018-04-12 Tom Tromey <tom@tromey.com>
9805
9806 * rust-lang.c (rust_print_struct_def): Remove univariant code.
9807 (rust_evaluate_subexp): Likewise.
9808
9809 2018-04-12 Pedro Alves <palves@redhat.com>
9810
9811 * procfs.c (procfs_detach): Make forward declaration's prototype
9812 match definition's protototype.
9813 (proc_get_LDT_entry): Remove stale do_cleanups call.
9814
9815 2018-04-12 Pedro Alves <palves@redhat.com>
9816
9817 * target.h (target_ops::to_has_exited): Delete.
9818 (target_has_exited): Delete.
9819 * target-delegates.c: Regenerate.
9820
9821 2018-04-11 Pedro Alves <palves@redhat.com>
9822
9823 * target.c (fileio_fh_t::t): Add comment.
9824 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9825 (target_fileio_close): Handle a NULL target.
9826 (invalidate_fileio_fh): New.
9827 (target_close): Call it.
9828 * remote.c (remote_hostio_send_command): No longer check whether
9829 remote_desc is open.
9830
9831 2018-04-11 Pedro Alves <palves@redhat.com>
9832
9833 * target.c (fileio_fh_t): Make it a named struct instead of a
9834 typedef.
9835 (fileio_fh_t::is_closed): New method.
9836 (DEF_VEC_O (fileio_fh_t)): Remove.
9837 (fileio_fhandles): Now a std::vector.
9838 (is_closed_fileio_fh): Delete.
9839 (acquire_fileio_fd): Adjust. Rename parameters.
9840 (release_fileio_fd): Adjust.
9841 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
9842 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
9843 (target_fileio_close): Adjust.
9844
9845 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
9846
9847 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
9848 index.
9849
9850 2018-04-10 Pedro Alves <palves@redhat.com>
9851
9852 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
9853 (scoped_finish_thread_state): New class.
9854 * infcmd.c (run_command_1): Use it instead of finish_thread_state
9855 cleanup.
9856 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
9857 (fetch_inferior_event, normal_stop): Likewise.
9858 * thread.c (finish_thread_state_cleanup): Delete.
9859
9860 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9861 Pedro Alves <palves@redhat.com>
9862
9863 * value.c: Include "selftest.h" and "common/array-view.h".
9864 (struct range) <operator ==>: New.
9865 (test_ranges_contain): New.
9866 (check_ranges_vector): New.
9867 (test_insert_into_bit_range_vector): New.
9868 (_initialize_values): Register selftests.
9869 * common/array-view.h (operator==, operator!=): New.
9870
9871 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9872
9873 * common/gdb_vecs.h (unordered_remove): Add overload that takes
9874 an iterator.
9875 * inline-frame.c: Include <algorithm>.
9876 (struct inline_state): Add constructor.
9877 (inline_state_s): Remove.
9878 (DEF_VEC_O(inline_state_s)): Remove.
9879 (inline_states): Change type to std::vector.
9880 (find_inline_frame_state): Adjust to std::vector.
9881 (allocate_inline_frame_state): Remove.
9882 (clear_inline_frame_state): Adjust to std::vector.
9883 (skip_inline_frames): Adjust to std::vector.
9884
9885 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9886
9887 * tracepoint.h (struct trace_state_variable): Add constructor.
9888 <name>: Change type to std::string.
9889 * tracepoint.c (tsv_s): Remove.
9890 (DEF_VEC_O(tsv_s)): Remove.
9891 (tvariables): Change to std::vector.
9892 (create_trace_state_variable): Adjust to std::vector.
9893 (find_trace_state_variable): Likewise.
9894 (find_trace_state_variable_by_number): Likewise.
9895 (delete_trace_state_variable): Likewise.
9896 (trace_variable_command): Adjust to std::string.
9897 (delete_trace_variable_command): Likewise.
9898 (tvariables_info_1): Adjust to std::vector.
9899 (save_trace_state_variables): Likewise.
9900 (start_tracing): Likewise.
9901 (merge_uploaded_trace_state_variables): Adjust to std::vector
9902 and std::string.
9903 * target.h (struct target_ops)
9904 <to_download_trace_state_variable>: Pass reference to
9905 trace_state_variable.
9906 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
9907 * target-delegates.c: Re-generate.
9908 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
9909 (mi_tsv_deleted): Likewise.
9910 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
9911 * remote.c (remote_download_trace_state_variable): Change
9912 pointer to reference and adjust.
9913 * make-target-delegates (parse_argtypes): Handle references.
9914 (write_function_header): Likewise.
9915 (munge_type): Likewise.
9916
9917 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9918
9919 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9920 string_view-selftests.c.
9921 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
9922 testsuite.
9923 * unittests/basic_string_view/cons/char/1.cc: Likewise.
9924 * unittests/basic_string_view/cons/char/2.cc: Likewise.
9925 * unittests/basic_string_view/cons/char/3.cc: Likewise.
9926 * unittests/basic_string_view/element_access/char/1.cc:
9927 Likewise.
9928 * unittests/basic_string_view/element_access/char/empty.cc:
9929 Likewise.
9930 * unittests/basic_string_view/element_access/char/front_back.cc:
9931 Likewise.
9932 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
9933 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
9934 Likewise.
9935 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
9936 Likewise.
9937 * unittests/basic_string_view/modifiers/swap/char/1.cc:
9938 Likewise.
9939 * unittests/basic_string_view/operations/compare/char/1.cc:
9940 Likewise.
9941 * unittests/basic_string_view/operations/compare/char/13650.cc:
9942 Likewise.
9943 * unittests/basic_string_view/operations/copy/char/1.cc:
9944 Likewise.
9945 * unittests/basic_string_view/operations/data/char/1.cc:
9946 Likewise.
9947 * unittests/basic_string_view/operations/find/char/1.cc:
9948 Likewise.
9949 * unittests/basic_string_view/operations/find/char/2.cc:
9950 Likewise.
9951 * unittests/basic_string_view/operations/find/char/3.cc:
9952 Likewise.
9953 * unittests/basic_string_view/operations/find/char/4.cc:
9954 Likewise.
9955 * unittests/basic_string_view/operations/rfind/char/1.cc:
9956 Likewise.
9957 * unittests/basic_string_view/operations/rfind/char/2.cc:
9958 Likewise.
9959 * unittests/basic_string_view/operations/rfind/char/3.cc:
9960 Likewise.
9961 * unittests/basic_string_view/operations/substr/char/1.cc:
9962 Likewise.
9963 * unittests/basic_string_view/operators/char/2.cc: Likewise.
9964 * unittests/string_view-selftests.c: New file.
9965
9966 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9967
9968 * unittests/basic_string_view/capacity/1.cc: New file.
9969 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
9970 * unittests/basic_string_view/cons/char/1.cc: New file.
9971 * unittests/basic_string_view/cons/char/2.cc: New file.
9972 * unittests/basic_string_view/cons/char/3.cc: New file.
9973 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
9974 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
9975 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
9976 * unittests/basic_string_view/element_access/char/1.cc: New file.
9977 * unittests/basic_string_view/element_access/char/2.cc: New file.
9978 * unittests/basic_string_view/element_access/char/empty.cc: New file.
9979 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
9980 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
9981 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
9982 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
9983 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
9984 * unittests/basic_string_view/include.cc: New file.
9985 * unittests/basic_string_view/inserters/char/1.cc: New file.
9986 * unittests/basic_string_view/inserters/char/2.cc: New file.
9987 * unittests/basic_string_view/inserters/char/3.cc: New file.
9988 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
9989 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
9990 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
9991 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
9992 * unittests/basic_string_view/literals/types.cc: New file.
9993 * unittests/basic_string_view/literals/values.cc: New file.
9994 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
9995 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
9996 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
9997 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
9998 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
9999 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
10000 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
10001 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
10002 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
10003 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
10004 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
10005 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
10006 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
10007 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
10008 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
10009 * unittests/basic_string_view/operations/data/char/1.cc: New file.
10010 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
10011 * unittests/basic_string_view/operations/find/char/1.cc: New file.
10012 * unittests/basic_string_view/operations/find/char/2.cc: New file.
10013 * unittests/basic_string_view/operations/find/char/3.cc: New file.
10014 * unittests/basic_string_view/operations/find/char/4.cc: New file.
10015 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
10016 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
10017 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
10018 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
10019 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
10020 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
10021 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
10022 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
10023 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
10024 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
10025 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
10026 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
10027 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
10028 * unittests/basic_string_view/operators/char/2.cc: New file.
10029 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
10030 * unittests/basic_string_view/range_access/char/1.cc: New file.
10031 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
10032 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
10033 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
10034 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
10035 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
10036 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
10037 * unittests/basic_string_view/requirements/typedefs.cc: New file.
10038 * unittests/basic_string_view/typedefs.cc: New file.
10039 * unittests/basic_string_view/types/1.cc: New file.
10040
10041 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10042
10043 * common/gdb_string_view.h: Remove libstdc++ implementation
10044 details, adjust to gdb reality.
10045 * common/gdb_string_view.tcc: Likewise.
10046 * cli/cli-script.c (struct string_view): Remove.
10047 (user_args) <m_args>: Change element type to gdb::string_view.
10048 (user_args::insert_args): Adjust.
10049
10050 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10051
10052 * common/gdb_string_view.h: New file.
10053 * common/gdb_string_view.tcc: New file.
10054
10055 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10056
10057 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
10058 * configure: Re-generate.
10059
10060 2018-04-09 Pedro Alves <palves@redhat.com>
10061
10062 * gdbarch.sh: Include "observable.h" instead of "observer.h".
10063 (set_target_gdbarch): Call
10064 gdb::observers::architecture_changed.notify instead of
10065 observer_notify_architecture_changed.
10066
10067 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10068
10069 * tracepoint.c (struct current_traceframe_cleanup): Remove.
10070 (do_restore_current_traceframe_cleanup): Remove.
10071 (restore_current_traceframe_cleanup_dtor): Remove.
10072 (make_cleanup_restore_current_traceframe): Remove.
10073 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
10074 New.
10075 * tracepoint.h (struct scoped_restore_current_traceframe): New.
10076 * infrun.c (fetch_inferior_event): Use
10077 scoped_restore_current_traceframe.
10078
10079 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10080
10081 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
10082 Remove.
10083 <n_allocated_type_units>: Remove.
10084 <all_type_units>: Change to std::vector.
10085 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10086 to std::vector change.
10087 (dwarf2_per_objfile::get_cutu): Likewise.
10088 (dwarf2_per_objfile::get_tu): Likewise.
10089 (create_signatured_type_table_from_index): Likewise.
10090 (create_signatured_type_table_from_debug_names): Likewise.
10091 (dw2_symtab_iter_next): Likewise.
10092 (dw2_print_stats): Likewise.
10093 (dw2_expand_all_symtabs): Likewise.
10094 (dw2_expand_marked_cus): Likewise.
10095 (dw2_debug_names_iterator::next): Likewise.
10096 (dwarf2_initialize_objfile): Likewise.
10097 (add_signatured_type_cu_to_table): Likewise.
10098 (create_all_type_units): Likewise.
10099 (add_type_unit): Likewise.
10100 (struct tu_abbrev_offset): Add constructor.
10101 (build_type_psymtabs_1): Adjust to std::vector change.
10102 (print_tu_stats): Likewise.
10103 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10104 (write_debug_names): Likewise.
10105
10106 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10107
10108 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
10109 Make an std::vector.
10110 <n_comp_units>: Remove.
10111 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
10112 to std::vector change.
10113 (dwarf2_per_objfile::get_cutu): Likewise.
10114 (dwarf2_per_objfile::get_cu): Likewise.
10115 (create_cus_from_index): Likewise.
10116 (create_addrmap_from_index): Likewise.
10117 (create_addrmap_from_aranges): Likewise.
10118 (dwarf2_read_index): Likewise.
10119 (dw2_find_last_source_symtab): Likewise.
10120 (dw2_map_symtabs_matching_filename): Likewise.
10121 (dw2_symtab_iter_next): Likewise.
10122 (dw2_print_stats): Likewise.
10123 (dw2_expand_all_symtabs): Likewise.
10124 (dw2_expand_symtabs_with_fullname): Likewise.
10125 (dw2_expand_marked_cus): Likewise.
10126 (dw2_map_symbol_filenames): Likewise.
10127 (create_cus_from_debug_names): Likewise.
10128 (dwarf2_read_debug_names): Likewise.
10129 (dw2_debug_names_iterator::next): Likewise.
10130 (dwarf2_initialize_objfile): Likewise.
10131 (set_partial_user): Likewise.
10132 (dwarf2_build_psymtabs_hard): Likewise.
10133 (read_comp_units_from_section): Remove arguments, adjust to
10134 std::vector change.
10135 (create_all_comp_units): Adjust to std::vector and
10136 read_comp_units_from_section changes.
10137 (dwarf2_find_containing_comp_unit): Adjust to std::vector
10138 change.
10139 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
10140 (psyms_seen_size): Likewise.
10141 (write_gdbindex): Likewise.
10142 (write_debug_names): Likewise.
10143
10144 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10145
10146 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
10147 with dwarf2_per_objfile.
10148 (create_cus_from_index): Likewise.
10149 (create_signatured_type_table_from_index): Likewise.
10150 (dwarf2_read_index): Likewise.
10151 (dwarf2_initialize_objfile): Likewise.
10152 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
10153 per_cu rather than get_dwarf2_per_objfile.
10154
10155 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10156
10157 * dwarf2read.h (struct signatured_type): Forward declare.
10158 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
10159 New methods.
10160 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
10161 (dw2_get_cutu): ...this.
10162 (dwarf2_per_objfile::get_cu): Rename from...
10163 (dw2_get_cu): ...this.
10164 (dwarf2_per_objfile::get_tu): New.
10165 (create_addrmap_from_index): Adjust.
10166 (create_addrmap_from_aranges): Adjust.
10167 (dw2_find_last_source_symtab): Adjust.
10168 (dw2_map_symtabs_matching_filename): Adjust.
10169 (dw2_symtab_iter_next): Adjust.
10170 (dw2_print_stats): Adjust.
10171 (dw2_expand_all_symtabs): Adjust.
10172 (dw2_expand_symtabs_with_fullname): Adjust.
10173 (dw2_expand_marked_cus): Adjust.
10174 (dw_expand_symtabs_matching_file_matcher): Adjust.
10175 (dw2_map_symbol_filenames): Adjust.
10176 (dw2_debug_names_iterator::next): Adjust.
10177 (dwarf2_initialize_objfile): Adjust.
10178 (set_partial_user): Adjust.
10179 (dwarf2_build_psymtabs_hard): Adjust.
10180
10181 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10182
10183 * dwarf2read.c (create_signatured_type_table_from_debug_names):
10184 Remove unused variables.
10185 (dw2_map_symtabs_matching_filename): Likewise.
10186 (dwarf2_record_block_ranges): Likewise.
10187 (dwarf2_read_addr_index): Likewise.
10188 (follow_die_offset): Likewise.
10189
10190 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10191
10192 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
10193 to symbol_file_add_main.
10194
10195 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10196
10197 PR mi/22299
10198 * mi/mi-console.c (do_fputc_async_safe): New.
10199 (mi_console_file::write_async_safe): New.
10200 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
10201 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
10202 New.
10203 * ui-file.c (ui_file::putstrn): Adjust call to
10204 fputstrn_unfiltered.
10205 * utils.c (printchar): Replace do_fputs and do_fprintf
10206 parameters by do_fputc.
10207 (fputstr_filtered): Adjust call to printchar.
10208 (fputstr_unfiltered): Likewise.
10209 (fputstrn_filtered): Likewise.
10210 (fputstrn_unfiltered): Add do_fputc parameter, pass to
10211 printchar.
10212 * utils.h (do_fputc_ftype): New typedef.
10213 (fputstrn_unfiltered): Add do_fputc parameter.
10214
10215 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
10216
10217 * regformats/i386/i386-avx.dat: Remove.
10218
10219 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10220
10221 PR gdb/22979
10222 * amd64-tdep.c (amd64_none_init_abi): New function.
10223 (amd64_x32_none_init_abi): New function.
10224 (_initialize_amd64_tdep): Register handlers for x86-64 and
10225 x64_32 with GDB_OSABI_NONE.
10226 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
10227 GDB_OSABI_NONE osabi.
10228
10229 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10230
10231 PR gdb/22980
10232 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
10233 GDB_OSABI_NONE.
10234 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
10235 * osabi.c (gdb_osabi_names): Add "unknown" entry.
10236
10237 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
10238
10239 * common/byte-vector.h (char_vector): New type.
10240 * target.h (target_read_alloc): Return
10241 gdb::optional<byte_vector>.
10242 (target_read_stralloc): Return gdb::optional<char_vector>.
10243 (target_get_osdata): Return gdb::optional<char_vector>.
10244 * target.c (target_read_alloc_1): Templatize. Replacement
10245 manual memory management with vector.
10246 (target_read_alloc): Change return type, adjust.
10247 (target_read_stralloc): Change return type, adjust.
10248 (target_get_osdata): Change return type, adjust.
10249 * auxv.c (struct auxv_info) <length>: Remove.
10250 <data>: Change type to gdb::optional<byte_vector>.
10251 (auxv_inferior_data_cleanup): Free auxv_info with delete.
10252 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
10253 (target_auxv_search): Adjust.
10254 (fprint_target_auxv): Adjust.
10255 * avr-tdep.c (avr_io_reg_read_command): Adjust.
10256 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
10257 (linux_make_corefile_notes): Adjust.
10258 * osdata.c (get_osdata): Adjust.
10259 * remote.c (remote_get_threads_with_qxfer): Adjust.
10260 (remote_memory_map): Adjust.
10261 (remote_traceframe_info): Adjust.
10262 (btrace_read_config): Adjust.
10263 (remote_read_btrace): Adjust.
10264 (remote_pid_to_exec_file): Adjust.
10265 * solib-aix.c (solib_aix_get_library_list): Adjust.
10266 * solib-dsbt.c (decode_loadmap): Don't free buf.
10267 (dsbt_get_initial_loadmaps): Adjust.
10268 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
10269 * solib-target.c (solib_target_current_sos): Adjust.
10270 * tracepoint.c (sdata_make_value): Adjust.
10271 * xml-support.c (xinclude_start_include): Adjust.
10272 (xml_fetch_content_from_file): Adjust.
10273 * xml-support.h (xml_fetch_another): Change return type.
10274 (xml_fetch_content_from_file): Change return type.
10275 * xml-syscall.c (xml_init_syscalls_info): Adjust.
10276 * xml-tdesc.c (file_read_description_xml): Adjust.
10277 (fetch_available_features_from_target): Change return type.
10278 (target_fetch_description_xml): Adjust.
10279 (target_read_description_xml): Adjust.
10280
10281 2018-04-06 Tom Tromey <tom@tromey.com>
10282
10283 * value.c (~value): Update.
10284 (struct value) <contents>: Now unique_xmalloc_ptr.
10285 (value_contents_bits_eq, allocate_value_contents)
10286 (value_contents_raw, value_contents_all_raw)
10287 (value_contents_for_printing, value_contents_for_printing_const)
10288 (set_value_enclosing_type): Update.
10289
10290 2018-04-06 Tom Tromey <tom@tromey.com>
10291
10292 * value.c (range_s): Remove typedef, VEC.
10293 (struct range): Add operator<.
10294 (range_lessthan): Remove.
10295 (ranges_contain): Change type.
10296 (~value): Update.
10297 (struct value) <unavailable, optimized_out>: Now std::vector.
10298 (value_entirely_available)
10299 (value_entirely_covered_by_range_vector)
10300 (value_entirely_unavailable, value_entirely_optimized_out):
10301 Update.
10302 (insert_into_bit_range_vector): Change argument type.
10303 (find_first_range_overlap): Likewise.
10304 (struct ranges_and_idx, value_contents_bits_eq)
10305 (require_not_optimized_out, require_available): Update.
10306 (ranges_copy_adjusted): Change argument types.
10307 (value_optimized_out, value_copy, value_fetch_lazy): Update.
10308
10309 2018-04-06 Tom Tromey <tom@tromey.com>
10310
10311 * value.c (~value): Update.
10312 (struct value) <parent>: Now a value_ref_ptr.
10313 (value_parent, set_value_parent, value_address, value_copy):
10314 Update.
10315
10316 2018-04-06 Tom Tromey <tom@tromey.com>
10317
10318 * value.c (struct value): Add constructor, destructor, and member
10319 initializers.
10320 (allocate_value_lazy, value_decref): Update.
10321
10322 2018-04-06 Tom Tromey <tom@tromey.com>
10323
10324 * value.c (struct value) <released, next>: Remove.
10325 (all_values): Now a std::vector.
10326 (allocate_value_lazy): Update.
10327 (value_next): Remove.
10328 (value_mark, value_free_to_mark, release_value)
10329 (value_release_to_mark): Update.
10330
10331 2018-04-06 Tom Tromey <tom@tromey.com>
10332
10333 * value.h (fetch_subexp_value, value_release_to_mark): Update.
10334 (free_value_chain): Remove.
10335 * value.c (free_value_chain): Remove.
10336 (value_release_to_mark): Return a std::vector.
10337 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
10338 std::vector.
10339 (check_condition): Update.
10340 * eval.c (fetch_subexp_value): Change "val_chain" to a
10341 std::vector.
10342 * breakpoint.c (update_watchpoint): Update.
10343 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
10344
10345 2018-04-06 Tom Tromey <tom@tromey.com>
10346
10347 * value.h (free_all_values): Remove.
10348 * value.c (free_all_values): Remove.
10349
10350 2018-04-06 Tom Tromey <tom@tromey.com>
10351
10352 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
10353 (value_history_chain, value_history_count): Remove.
10354 (value_history): New global.
10355 (record_latest_value, access_value_history, show_values)
10356 (preserve_values): Update.
10357
10358 2018-04-06 Tom Tromey <tom@tromey.com>
10359
10360 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
10361 * varobj.c (varobj_set_display_format, varobj_set_value)
10362 (install_default_visualizer, construct_visualizer)
10363 (install_new_value, ~varobj, varobj_get_value_type)
10364 (my_value_of_variable, varobj_editable_p): Update.
10365 * c-varobj.c (c_describe_child, c_value_of_variable)
10366 (cplus_number_of_children, cplus_describe_child): Update.
10367 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
10368 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
10369 (ada_value_of_variable, ada_value_is_changeable_p): Update.
10370
10371 2018-04-06 Tom Tromey <tom@tromey.com>
10372
10373 * printcmd.c (last_examine_address): Change type to
10374 value_ref_ptr.
10375 (do_examine, x_command): Update.
10376
10377 2018-04-06 Tom Tromey <tom@tromey.com>
10378
10379 * value.c (release_value): Update.
10380 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
10381 (struct bpstats) <val>: Now a value_ref_ptr.
10382 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10383 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10384 (~watchpoint, print_it_watchpoint, watch_command_1)
10385 (invalidate_bp_value_on_memory_change): Update.
10386
10387 2018-04-06 Tom Tromey <tom@tromey.com>
10388
10389 * varobj.c (varobj_clear_saved_item)
10390 (update_dynamic_varobj_children, install_new_value, ~varobj):
10391 Update.
10392 * value.h (value_incref): Move declaration earlier.
10393 (value_decref): Rename from value_free.
10394 (struct value_ref_policy): New.
10395 (value_ref_ptr): New typedef.
10396 (struct value_deleter): Remove.
10397 (gdb_value_up): Remove typedef.
10398 (release_value): Change return type.
10399 (release_value_or_incref): Remove.
10400 * value.c (set_value_parent): Update.
10401 (value_incref): Change return type.
10402 (value_decref): Rename from value_free.
10403 (value_free_to_mark, free_all_values, free_value_chain): Update.
10404 (release_value): Return value_ref_ptr.
10405 (release_value_or_incref): Remove.
10406 (record_latest_value, set_internalvar, clear_internalvar):
10407 Update.
10408 * stack.c (info_frame_command): Don't call value_free.
10409 * python/py-value.c (valpy_dealloc, valpy_new)
10410 (value_to_value_object): Update.
10411 * printcmd.c (do_examine): Update.
10412 * opencl-lang.c (lval_func_free_closure): Update.
10413 * mi/mi-main.c (register_changed_p): Don't call value_free.
10414 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
10415 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
10416 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
10417 value_free.
10418 * guile/scm-value.c (vlscm_free_value_smob)
10419 (vlscm_scm_from_value): Update.
10420 * frame.c (frame_register_unwind, frame_unwind_register_signed)
10421 (frame_unwind_register_unsigned, get_frame_register_bytes)
10422 (put_frame_register_bytes): Don't call value_free.
10423 * findvar.c (address_from_register): Don't call value_free.
10424 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
10425 * dwarf2loc.c (entry_data_value_free_closure)
10426 (value_of_dwarf_reg_entry, free_pieced_value_closure)
10427 (dwarf2_evaluate_loc_desc_full): Update.
10428 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
10429 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
10430 (~watchpoint, watch_command_1)
10431 (invalidate_bp_value_on_memory_change): Update.
10432 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
10433
10434 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
10435
10436 PR gdb/23022
10437 * warning.m4: Add -Wno-error=deprecated-register.
10438 * configure: Re-generate.
10439
10440 2018-04-05 Tom Tromey <tom@tromey.com>
10441
10442 * linespec.h: Remove include of "vec.h".
10443
10444 2018-04-05 Tom Tromey <tom@tromey.com>
10445
10446 * linespec.c (typep): Remove typedef.
10447 (find_methods, find_superclass_methods): Take a std::vector.
10448 (find_method): Use std::vector.
10449
10450 2018-04-05 Tom Tromey <tom@tromey.com>
10451
10452 * utils.c (compare_strings): Remove.
10453 * utils.h (compare_strings): Remove.
10454 * objc-lang.h (find_imps): Update.
10455 * objc-lang.c (find_methods): Take a std::vector.
10456 (uniquify_strings, find_imps): Likewise.
10457 * linespec.c (find_methods): Take a std::vector.
10458 (decode_objc): Use std::vector.
10459 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
10460 a std::vector.
10461 (find_method, find_function_symbols): Use std::vector.
10462
10463 2018-04-05 Tom Tromey <tom@tromey.com>
10464
10465 * completer.c (completion_tracker::completion_tracker): Remove
10466 cast.
10467 (completion_tracker::discard_completions): Likewise.
10468 * breakpoint.c (ambiguous_names_p): Remove cast.
10469 * ada-lang.c (_initialize_ada_language): Remove cast.
10470 * utils.h (streq): Update.
10471 (streq_hash): Add new declaration.
10472 * utils.c (streq): Return bool.
10473 (streq_hash): New function.
10474
10475 2018-04-05 Tom Tromey <tom@tromey.com>
10476
10477 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
10478 Remove a string copy.
10479
10480 2018-04-05 Tom Tromey <tom@tromey.com>
10481
10482 * linespec.c (filter_results): Use std::vector.
10483 (decode_line_2, decode_line_full): Update.
10484
10485 2018-04-05 Tom Tromey <tom@tromey.com>
10486
10487 * linespec.c (canonical_to_fullform): Return std::string.
10488 (filter_results): Update.
10489 (struct decode_line_2_item): Add constructor.
10490 <fullform, displayform>: Now std::string.
10491 (decode_line_2_compare_items): Now a std::sort comparator.
10492 (decode_line_2): Update.
10493
10494 2018-04-05 Tom Tromey <tom@tromey.com>
10495
10496 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
10497 (unexpected_linespec_error): Update.
10498 (linespec_parse_basic, parse_linespec): Update.
10499
10500 2018-04-05 Tom Tromey <tom@tromey.com>
10501
10502 * linespec.c (linespec_parse_basic): Reindent.
10503
10504 2018-04-05 Tom Tromey <tom@tromey.com>
10505
10506 * minsyms.h (iterate_over_minimal_symbols): Update.
10507 * minsyms.c (iterate_over_minimal_symbols): Take a
10508 gdb::function_view.
10509 * linespec.c (struct collect_minsyms): Remove.
10510 (compare_msyms): Now a std::sort comparator.
10511 (add_minsym): Add parameters.
10512 (search_minsyms_for_name): Update. Use std::vector.
10513
10514 2018-04-03 Tom Tromey <tom@tromey.com>
10515
10516 * mipsread.c (read_alphacoff_dynamic_symtab): Use
10517 gdb::byte_vector.
10518
10519 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10520
10521 * MAINTAINERS (Write After Approval): Add Weimin Pan.
10522
10523 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
10524
10525 PR gdb/16959
10526 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
10527 printing static type.
10528
10529 2018-04-01 Tom Tromey <tom@tromey.com>
10530
10531 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
10532 (rs6000_xfer_shared_libraries): Update.
10533
10534 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
10535
10536 * common/gdb_vecs.h (char_ptr): Remove.
10537 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
10538
10539 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10540
10541 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
10542 with std::vector.
10543 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
10544
10545 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
10546
10547 * tracepoint.h (struct uploaded_tp): Initialize fields.
10548 <actions, step_actions, cmd_strings>: Change type to
10549 std::vector<char *>.
10550 * tracepoint.c (get_uploaded_tp): Allocate with new.
10551 (free_uploaded_tps): Free with delete.
10552 (parse_tracepoint_definition): Adjust to std::vector change.
10553 * breakpoint.c (read_uploaded_action): Likewise.
10554 (create_tracepoint_from_upload): Likewise.
10555 * ctf.c (ctf_write_uploaded_tp): Likewise.
10556 (SET_ARRAY_FIELD): Likewise.
10557 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
10558
10559 2018-03-30 Tom Tromey <tom@tromey.com>
10560
10561 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
10562 std::unique_ptr.
10563 (svr4_keep_data_in_core): Update.
10564 (svr4_read_so_list): Update.
10565
10566 2018-03-30 Tom Tromey <tom@tromey.com>
10567
10568 * windows-nat.c (handle_output_debug_string, handle_exception):
10569 Update.
10570 * target.h (target_read_string): Update.
10571 * target.c (target_read_string): Change "string" to
10572 unique_xmalloc_ptr.
10573 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
10574 Update.
10575 * solib-frv.c (frv_current_sos): Update.
10576 * solib-dsbt.c (dsbt_current_sos): Update.
10577 * solib-darwin.c (darwin_current_sos): Update.
10578 * linux-thread-db.c (inferior_has_bug): Update.
10579 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
10580 Update. Remove alloca.
10581 * ada-lang.c (ada_main_name): Update.
10582
10583 2018-03-30 Tom Tromey <tom@tromey.com>
10584
10585 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
10586 (struct dwo_file_deleter): New.
10587 (dwo_file_up): New typedef.
10588 (open_and_init_dwo_file): Use dwo_file_up.
10589 (free_dwo_file_cleanup): Remove.
10590
10591 2018-03-30 Tom Tromey <tom@tromey.com>
10592
10593 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
10594 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
10595
10596 2018-03-30 Tom Tromey <tom@tromey.com>
10597
10598 * dwarf2read.c (class free_cached_comp_units): New class.
10599 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
10600 (free_cached_comp_units): Remove function.
10601
10602 2018-03-30 Tom Tromey <tom@tromey.com>
10603
10604 * utils.h (make_cleanup_unpush_target): Remove.
10605 * inf-ptrace.c (struct target_unpusher): New.
10606 (target_unpush_up) New typedef.
10607 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
10608 target_unpush_up.
10609 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
10610
10611 2018-03-27 Tom Tromey <tom@tromey.com>
10612
10613 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
10614
10615 2018-03-27 Pedro Alves <palves@redhat.com>
10616 Tom Tromey <tom@tromey.com>
10617
10618 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
10619 destructor. Now a class.
10620 (gdb_readline_wrapper_cleanup): Remove function.
10621 (gdb_readline_wrapper): Remove cleanups.
10622
10623 2018-03-27 Tom Tromey <tom@tromey.com>
10624
10625 * typeprint.h (struct type_print_options) <local_typedefs,
10626 global_typedefs>: Remove "struct" keyword.
10627 (class typedef_hash_table): New class.
10628 (recursively_update_typedef_hash, add_template_parameters)
10629 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
10630 (find_typedef_in_hash): Don't declare.
10631 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
10632 (typedef_hash_table::recursively_update): Rename from
10633 recursively_update_typedef_hash. Now a member.
10634 (typedef_hash_table::add_template_parameters): Rename from
10635 add_template_parameters. Now a member.
10636 (typedef_hash_table::typedef_hash_table): Now a constructor;
10637 rename from create_typedef_hash.
10638 (typedef_hash_table::~typedef_hash_table): Now a destructor;
10639 rename from free_typedef_hash.
10640 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
10641 (do_free_global_table): Remove.
10642 (typedef_hash_table::typedef_hash_table): New constructor; renamed
10643 from copy_type_recursive.
10644 (create_global_typedef_table): Remove.
10645 (typedef_hash_table::find_global_typedef): Now a member of
10646 typedef_hash_table.
10647 (typedef_hash_table::find_typedef): Rename from
10648 find_typedef_in_hash; now a member.
10649 (whatis_exp): Update.
10650 * extension.h (struct ext_lang_type_printers): Add constructor and
10651 destructor.
10652 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
10653 declare.
10654 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
10655 Now a constructor; rename from start_ext_lang_type_printers.
10656 (ext_lang_type_printers): Now a destructor; rename from
10657 free_ext_lang_type_printers.
10658 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
10659 Update.
10660 (c_type_print_base_struct_union): Update. Remove cleanups.
10661
10662 2018-03-27 Tom Tromey <tom@tromey.com>
10663
10664 * dwarf-index-write.c: Include <cmath>.
10665
10666 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10667
10668 * NEWS: Add entry describing new "set|show varsize-limit" command.
10669 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
10670 command.
10671 * printcmd.c (_initialize_printcmd): Add "set var" alias of
10672 "set variable".
10673
10674 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
10675
10676 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
10677 dwarf-index-write.c
10678 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
10679 * dwarf-index-common.c: New file.
10680 * dwarf-index-common.h: New file.
10681 * dwarf-index-write.c: New file.
10682 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
10683 (struct dwarf2_section_info): Move from here.
10684 (dwarf2_section_info_def): Likewise.
10685 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
10686 (offset_type): Likewise.
10687 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
10688 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
10689 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
10690 (byte_swap): Likewise.
10691 (MAYBE_SWAP): Likewise.
10692 (dwarf2_per_cu_ptr): Likewise.
10693 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
10694 (struct tu_stats): Likewise.
10695 (struct dwarf2_per_objfile): Likewise.
10696 (struct dwarf2_per_cu_data): Likewise.
10697 (struct signatured_type): Likewise.
10698 (sig_type_ptr): Likewise.
10699 (DEF_VEC_P (sig_type_ptr)): Likewise.
10700 (INDEX4_SUFFIX): Likewise.
10701 (INDEX5_SUFFIX): Likewise.
10702 (DEBUG_STR_SUFFIX): Likewise.
10703 (dwarf2_read_section): Make non-static.
10704 (mapped_index_string_hash): Move from here.
10705 (dwarf5_djb_hash): Likewise.
10706 (file_write): Likewise.
10707 (class data_buf): Likewise.
10708 (struct symtab_index_entry): Likewise.
10709 (struct mapped_symtab): Likewise.
10710 (find_slot): Likewise.
10711 (hash_expand): Likewise.
10712 (add_index_entry): Likewise.
10713 (uniquify_cu_indices): Likewise.
10714 (class c_str_view): Likewise.
10715 (class c_str_view_hasher): Likewise.
10716 (class vector_hasher): Likewise.
10717 (write_hash_table): Likewise.
10718 (psym_index_map): Likewise.
10719 (struct addrmap_index_data): Likewise.
10720 (add_address_entry): Likewise.
10721 (add_address_entry_worker): Likewise.
10722 (write_address_map): Likewise.
10723 (symbol_kind): Likewise.
10724 (write_psymbols): Likewise.
10725 (struct signatured_type_index_data): Likewise.
10726 (write_one_signatured_type): Likewise.
10727 (recursively_count_psymbols): Likewise.
10728 (recursively_write_psymbols): Likewise.
10729 (class debug_names): Likewise.
10730 (check_dwarf64_offsets): Likewise.
10731 (psyms_seen_size): Likewise.
10732 (write_gdbindex): Likewise.
10733 (write_debug_names): Likewise.
10734 (assert_file_size): Likewise.
10735 (write_psymtabs_to_index): Likewise.
10736 (save_gdb_index_command): Likewise.
10737 (_initialize_dwarf2_read): Don't register the "save gdb-index"
10738 command.
10739 * dwarf2read.h: New file.
10740
10741 2018-03-27 Joel Brobecker <brobecker@adacore.com>
10742
10743 PR gdb/22670
10744 * dwarf2read.c (dwarf2_physname): Do not return the demangled
10745 symbol name if the CU's language stores symbol names in linkage
10746 format.
10747 * language.h (struct language_defn)
10748 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
10749 all instances of this struct.
10750
10751 2018-03-26 Tom Tromey <tom@tromey.com>
10752
10753 * stack.c (backtrace_command_1): Remove verbose code.
10754
10755 2018-03-26 Tom Tromey <tom@tromey.com>
10756
10757 * python/py-framefilter.c (py_print_type): Don't catch
10758 exceptions. Return void.
10759 (py_print_value): Likewise.
10760 (py_print_single_arg): Likewise.
10761 (enumerate_args): Don't catch exceptions.
10762 (py_print_args): Likewise.
10763 (py_print_frame): Likewise.
10764 (gdbpy_apply_frame_filter): Catch exceptions here.
10765
10766 2018-03-26 Tom Tromey <tom@tromey.com>
10767
10768 * stack.c (_initialize_stack): Remove trailing newlines from help
10769 text. Add "Usage" line to "backtrace" help.
10770
10771 2018-03-26 Tom Tromey <tom@tromey.com>
10772
10773 PR python/16486:
10774 * python/py-framefilter.c (py_print_args): Call wrap_hint.
10775
10776 2018-03-26 Tom Tromey <tom@tromey.com>
10777
10778 * python/py-framefilter.c (py_print_single_arg): Return
10779 EXT_LANG_BT_ERROR from catch.
10780
10781 2018-03-26 Tom Tromey <tom@tromey.com>
10782
10783 PR backtrace/15584:
10784 * stack.c (backtrace_command_1): Move some code into no-filters
10785 "if".
10786
10787 2018-03-26 Tom Tromey <tom@tromey.com>
10788
10789 * python/py-framefilter.c (throw_quit_or_print_exception): New
10790 function.
10791 (gdbpy_apply_frame_filter): Use it.
10792
10793 2018-03-26 Tom Tromey <tom@tromey.com>
10794
10795 PR cli/17716:
10796 * python/py-framefilter.c (py_print_type, py_print_value)
10797 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
10798 RETURN_MASK_ERROR.
10799
10800 2018-03-26 Tom Tromey <tom@tromey.com>
10801
10802 * python/py-framefilter.c (enumerate_args): Use
10803 gdb::unique_xmalloc_ptr.
10804
10805 2018-03-26 Tom Tromey <tom@tromey.com>
10806
10807 * python/py-framefilter.c (py_print_frame): Return
10808 EXT_LANG_BT_OK.
10809 (gdbpy_apply_frame_filter): Update comment.
10810 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
10811 Remove.
10812 <EXT_LANG_BT_NO_FILTERS>: Change value.
10813
10814 2018-03-26 Tom Tromey <tom@tromey.com>
10815
10816 PR backtrace/15582:
10817 * stack.c (backtrace_command): Parse "hide" argument.
10818 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
10819 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
10820 constant.
10821
10822 2018-03-26 Tom Tromey <tom@tromey.com>
10823
10824 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
10825 add "flags".
10826 (backtrace_command): Remove "fulltrace", add "flags".
10827
10828 2018-03-26 Tom Tromey <tom@tromey.com>
10829
10830 * stack.c (backtrace_command): Rewrite command line parsing.
10831
10832 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10833
10834 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
10835
10836 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
10837
10838 * filename-seen-cache.h: Add include guard.
10839
10840 2018-03-26 Keith Seitz <keiths@redhat.com>
10841
10842 * symfile.c (place_section): Remove "struct" from section_addr_info
10843 in comment.
10844 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
10845 "struct" keyword from section_addr_info.
10846
10847 2018-03-26 Alan Hayward <alan.hayward@arm.com>
10848
10849 * regformats/regdef.h (reg): Add constructors.
10850
10851 2018-03-25 Pedro Alves <palves@redhat.com>
10852
10853 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
10854 if then/else bodies in var_func_name extraction.
10855
10856 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
10857
10858 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
10859 lookup_minimal_symbol() to find symbol entry.
10860 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
10861
10862 2018-03-23 Keith Seitz <keiths@redhat.com>
10863
10864 PR c++/22968
10865 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
10866 nested type definitions for C++, too.
10867
10868 2018-03-23 Tom Tromey <tom@tromey.com>
10869
10870 * machoread.c (struct oso_el): Add a constructor. Don't define as
10871 a typedef.
10872 (macho_register_oso): Remove.
10873 (macho_symtab_read): Take a std::vector.
10874 (oso_el_compare_name): Now a std::sort comparator.
10875 (macho_symfile_read_all_oso): Take a std::vector.
10876 (macho_symfile_read): Use std::vector. Remove cleanups.
10877
10878 2018-03-22 Tom Tromey <tom@tromey.com>
10879
10880 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
10881 (record_full_goto_bookmark): Use std::string.
10882
10883 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10884
10885 PR tdep/18295
10886 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
10887 a single mask.
10888
10889 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10890
10891 * rs6000-tdep.c (store_insn_p): New function.
10892 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
10893 and cr_reg to their unshifted values. Use store_insn_p to
10894 match LR saves using either R1 or fdata->alloca_reg. Use
10895 store_insn_p to match CR saves. Set alloca_reg_offset
10896 when alloca_reg and framep are set. Remove lr_reg shift
10897 when assigning to fdata->lr_register.
10898
10899 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
10900
10901 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
10902 command line args instead of emitting a warning.
10903
10904 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10905
10906 * tracepoint.h (struct static_tracepoint_marker): Initialize
10907 fields, define default constructor, move constructor and move
10908 assignment, disable the rest.
10909 <str_id, extra>: Make std::string.
10910 (release_static_tracepoint_marker): Remove.
10911 (free_current_marker): Remove.
10912 * tracepoint.c (free_current_marker): Remove.
10913 (parse_static_tracepoint_marker_definition): Adjust to
10914 std::string, use new hex2str overload.
10915 (release_static_tracepoint_marker): Remove.
10916 (print_one_static_tracepoint_marker): Get marker by reference
10917 and adjust to std::string.
10918 (info_static_tracepoint_markers_command): Adjust to std::vector
10919 changes
10920 * target.h (static_tracepoint_marker_p): Remove typedef.
10921 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
10922 (struct target_ops) <to_static_tracepoint_marker_at>: Return
10923 bool.
10924 <to_static_tracepoint_markers_by_strid>: Return std::vector.
10925 * target-debug.h
10926 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
10927 (target_debug_print_std_vector_static_tracepoint_marker): New.
10928 (target_debug_print_struct_static_tracepoint_marker_p): Rename
10929 to...
10930 (target_debug_print_static_tracepoint_marker_p): ... this.
10931 * target-delegates.c: Re-generate.
10932 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
10933 Make std::string.
10934 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
10935 (decode_static_tracepoint_spec): Adjust to std::vector.
10936 (tracepoint_print_one_detail): Adjust to std::string.
10937 (strace_marker_decode_location): Adjust to std::string.
10938 (update_static_tracepoint): Adjust to std::string, remove call
10939 to release_static_tracepoint_marker.
10940 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
10941 Adjust to std::vector.
10942 * remote.c (remote_static_tracepoint_marker_at): Return bool.
10943 (remote_static_tracepoint_markers_by_strid): Adjust to
10944 std::vector.
10945 * common/rsp-low.h (hex2str): New overload with explicit count
10946 of bytes.
10947 * common/rsp-low.c (hex2str): New overload with explicit count
10948 of bytes.
10949 * unittests/rsp-low-selftests.c (test_hex2str): New function.
10950 (_initialize_rsp_low_selftests): Add test_hex2str test.
10951 * unittests/tracepoint-selftests.c
10952 (test_parse_static_tracepoint_marker_definition): Adjust to
10953 std::string.
10954
10955 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10956
10957 * tracepoint.c (parse_static_tracepoint_marker_definition):
10958 Consider case where the definition is followed by more
10959 definitions.
10960 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10961 tracepoint-selftests.c.
10962 * unittests/tracepoint-selftests.c: New.
10963
10964 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
10965
10966 * MAINTAINERS (Write After Approval): Add Pedro Franco de
10967 Carvalho.
10968
10969 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10970
10971 * symtab.c (find_pc_sect_line): fixed indentation.
10972
10973 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
10974
10975 * symtab.c (find_pc_sect_line): now uses binary search.
10976
10977 2018-03-19 Tom Tromey <tom@tromey.com>
10978
10979 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
10980 "IDENT" production.
10981
10982 2018-03-19 Pedro Alves <palves@redhat.com>
10983 Tom Tromey <tom@tromey.com>
10984
10985 * unittests/observable-selftests.c: New file.
10986 * common/observable.h: New file.
10987 * observable.h: New file.
10988 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
10989 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
10990 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
10991 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
10992 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
10993 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
10994 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
10995 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
10996 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
10997 python/py-breakpoint.c, python/py-finishbreakpoint.c,
10998 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
10999 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
11000 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
11001 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
11002 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
11003 tui/tui-interp.c, valops.c: Update all users.
11004 * tui/tui-hooks.c (tui_bp_created_observer)
11005 (tui_bp_deleted_observer, tui_bp_modified_observer)
11006 (tui_inferior_exit_observer, tui_before_prompt_observer)
11007 (tui_normal_stop_observer, tui_register_changed_observer):
11008 Remove.
11009 (tui_observers_token): New global.
11010 (attach_or_detach, tui_attach_detach_observers): New functions.
11011 (tui_install_hooks, tui_remove_hooks): Use
11012 tui_attach_detach_observers.
11013 * record-btrace.c (record_btrace_thread_observer): Remove.
11014 (record_btrace_thread_observer_token): New global.
11015 * observer.sh: Remove.
11016 * observer.c: Rename to observable.c.
11017 * observable.c (namespace gdb_observers): Define new objects.
11018 (observer_debug): Move into gdb_observers namespace.
11019 (struct observer, struct observer_list, xalloc_observer_list_node)
11020 (xfree_observer_list_node, generic_observer_attach)
11021 (generic_observer_detach, generic_observer_notify): Remove.
11022 (_initialize_observer): Update.
11023 Don't include observer.inc.
11024 * Makefile.in (generated_files): Remove observer.h, observer.inc.
11025 (clean mostlyclean): Likewise.
11026 (observer.h, observer.inc): Remove targets.
11027 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
11028 (COMMON_SFILES): Use observable.c, not observer.c.
11029 * .gitignore: Remove observer.h.
11030
11031 2018-03-18 Tom Tromey <tom@tromey.com>
11032
11033 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
11034 gdb::def_vector.
11035 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
11036
11037 2018-03-17 Tom Tromey <tom@tromey.com>
11038
11039 * auto-load.c (auto_load_objfile_script_1): Use std::string.
11040
11041 2018-03-17 Tom Tromey <tom@tromey.com>
11042
11043 * target.c (class scoped_target_fd): New.
11044 (target_fileio_close_cleanup): Remove.
11045 (target_fileio_read_alloc_1): Use scoped_target_fd.
11046
11047 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
11048
11049 * silent-rules.mk: New.
11050 * Makefile.in: Include silent-rules.mk
11051 (srcdir, VPATH, top_srcdir): Move up.
11052 (COMPILE): Add ECHO_CXX.
11053 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
11054 (init.c): Add ECHO_INIT_C.
11055 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
11056 (version.c): Add ECHO_GEN.
11057 (printcmd.o): Add ECHO_CXX.
11058 (target-float.o): Add ECHO_CXX.
11059 (ada-exp.o): Add ECHO_CXX.
11060 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
11061 (insight$(EXEEXT)): Add ECHO_CXXLD.
11062 * gnulib/configure.ac: Add AM_SILENT_RULES.
11063 * gnulib/aclocal.m4: Re-generate.
11064 * gnulib/configure: Re-generate.
11065 * gnulib/import/Makefile.in: Re-generate.
11066
11067 2018-03-16 Tom Tromey <tom@tromey.com>
11068
11069 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
11070 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
11071 * utils.c (do_free_section_addr_info)
11072 (make_cleanup_free_section_addr_info): Remove.
11073 * symfile.h (struct other_sections): Add constructor.
11074 (struct section_addr_info): Remove.
11075 (section_addr_info): New typedef.
11076 (struct sym_fns) <sym_offsets>: Change type of parameter.
11077 (build_section_addr_info_from_objfile)
11078 (relative_addr_info_to_section_offsets, addr_info_make_relative)
11079 (default_symfile_offsets, symbol_file_add)
11080 (symbol_file_add_from_bfd)
11081 (build_section_addr_info_from_section_table): Update.
11082 (alloc_section_addr_info, free_section_addr_info): Don't declare.
11083 * symfile.c (alloc_section_addr_info): Remove.
11084 (build_section_addr_info_from_section_table): Change return type.
11085 Update.
11086 (build_section_addr_info_from_bfd)
11087 (build_section_addr_info_from_objfile): Likewise.
11088 (free_section_addr_info): Remove.
11089 (relative_addr_info_to_section_offsets): Change type of "addrs".
11090 (addrs_section_compar): Now a std::sort comparator.
11091 (addrs_section_sort): Change return type.
11092 (addr_info_make_relative): Change type of "addrs". Update.
11093 (default_symfile_offsets, syms_from_objfile_1)
11094 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
11095 (symbol_file_add_separate): Update.
11096 (symbol_file_add): Change type of "addrs". Update.
11097 (add_symbol_file_command): Update. Remove cleanups.
11098 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
11099 cleanups.
11100 * symfile-debug.c (debug_sym_offsets): Change type of "info".
11101 * solib.c (solib_read_symbols): Update.
11102 * objfiles.c (objfile_relocate): Update. Remove cleanups.
11103 * machoread.c (macho_symfile_offsets): Update.
11104 * jit.c (jit_bfd_try_read_symtab): Update.
11105
11106 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
11107
11108 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11109 unittests/utils-selftests.c.
11110 * unittests/utils-selftests.c: New file.
11111
11112 2018-03-14 Tom Tromey <tom@tromey.com>
11113
11114 PR cli/14977:
11115 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
11116 for NULL.
11117
11118 2018-03-14 Tom Tromey <tom@tromey.com>
11119
11120 PR cli/19918:
11121 * printcmd.c (printf_pointer): Allow "-" in format.
11122
11123 2018-03-14 Tom Tromey <tom@tromey.com>
11124
11125 * printcmd.c (_initialize_printcmd): Add usage to printf.
11126
11127 2018-03-14 Yao Qi <qiyao@sourceware.org>
11128
11129 * MAINTAINERS: Update my email address.
11130
11131 2018-03-13 Tom Tromey <tom@tromey.com>
11132
11133 * machoread.c (macho_check_dsym): Change filenamep to a
11134 std::string*.
11135 (macho_symfile_read): Update.
11136 * symfile.c (load_command): Use std::string.
11137
11138 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
11139
11140 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
11141 to error message string.
11142 (riscv_register_name): Use xsnprintf instead of sprintf.
11143 (riscv_insn::fetch_instruction): Use gdb_assert instead of
11144 internal_error.
11145 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
11146 error.
11147 (riscv_push_dummy_call): Likewise.
11148
11149 2018-03-12 Tom Tromey <tom@tromey.com>
11150
11151 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
11152 Use gdb::byte_vector.
11153 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
11154
11155 2018-03-12 Yao Qi <yao.qi@linaro.org>
11156
11157 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
11158 parameter type to readable_regcache.
11159 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
11160 the declaration.
11161
11162 2018-03-11 Tom Tromey <tom@tromey.com>
11163
11164 * dwarf2read.c (struct nextfield): Add initializers.
11165 (struct nextfnfield): Remove.
11166 (struct fnfieldlist): Add initializers. Remove "length" and
11167 "head", use std::vector.
11168 (struct decl_field_list): Remove.
11169 (struct field_info): Add initializers.
11170 <fields, baseclasses>: Now std::vector.
11171 <nbaseclasses, nfnfields, typedef_field_list_count,
11172 nested_types_list_count>: Remove.
11173 (dwarf2_add_field, dwarf2_add_type_defn)
11174 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
11175 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
11176 (process_structure_scope): Update.
11177
11178 2018-03-11 Tom Tromey <tom@tromey.com>
11179
11180 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
11181 for use by std::sort.
11182 (build_type_psymtabs_1): Use std::vector.
11183
11184 2018-03-09 Eli Zaretskii <eliz@gnu.org>
11185
11186 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
11187 and LIBMPFR in the printed configuration.
11188
11189 2018-03-08 Tom Tromey <tom@tromey.com>
11190
11191 * source.c (get_filename_and_charpos): Use scoped_fd.
11192 * nto-procfs.c (procfs_open_1): Use scoped_fd.
11193 (procfs_pidlist): Likewise.
11194 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
11195 (iterate_over_mappings): Likewise.
11196
11197 2018-03-08 Tom Tromey <tom@tromey.com>
11198
11199 * infcall.c (struct call_return_meta_info)
11200 <stack_temporaries_enabled>: Remove.
11201 (get_call_return_value, call_function_by_hand_dummy): Update.
11202 * thread.c (disable_thread_stack_temporaries): Remove.
11203 (enable_thread_stack_temporaries): Remove.
11204 (thread_stack_temporaries_enabled_p): Return bool.
11205 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
11206 (get_last_thread_stack_temporary): Update.
11207 * eval.c (evaluate_subexp): Update.
11208 * gdbthread.h (class enable_thread_stack_temporaries): Now a
11209 class, not a function.
11210 (value_ptr, value_vec): Remove typedefs.
11211 (class thread_info) <stack_temporaries_enabled>: Now bool.
11212 <stack_temporaries>: Now a std::vector.
11213 (thread_stack_temporaries_enabled_p)
11214 (value_in_thread_stack_temporaries): Return bool.
11215
11216 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
11217
11218 * remote.c (putpkt_binary): Fix omitted bytes reporting.
11219 (getpkt_or_notif_sane_1): Likewise.
11220
11221 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11222
11223 * build-id.c (build_id_to_debug_bfd): Use std::string.
11224
11225 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11226
11227 * build-id.c (find_separate_debug_file_by_buildid): Return
11228 std::string.
11229 * build-id.h (find_separate_debug_file_by_buildid): Return
11230 std::string.
11231 * coffread.c (coff_symfile_read): Adjust to std::string.
11232 * elfread.c (elf_symfile_read): Adjust to std::string.
11233 * symfile.c (separate_debug_file_exists): Change parameter to
11234 std::string.
11235 (find_separate_debug_file): Return std::string.
11236 (find_separate_debug_file_by_debuglink): Return std::string.
11237 * symfile.h (find_separate_debug_file_by_debuglink): Return
11238 std::string.
11239
11240 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
11241
11242 * common/xml-utils.c (xml_escape_text): Move code to...
11243 (xml_escape_text_append): ... this new function.
11244 * common/xml-utils.h (xml_escape_text_append): New declaration.
11245 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
11246 New function.
11247 (_initialize_xml_utils): register test_xml_escape_text_append as
11248 a selftest.
11249
11250 2018-03-07 Alan Hayward <alan.hayward@arm.com>
11251
11252 * defs.h: Remove MAX_REGISTER_SIZE.
11253 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
11254 asserts.
11255 * python/py-unwind.c (pyuw_sniffer): Likewise.
11256
11257 2018-03-07 Tom Tromey <tom@tromey.com>
11258
11259 * linux-tdep.c (linux_info_proc): Update.
11260 * target.h (struct target_ops) <to_fileio_readlink>: Return
11261 optional<string>.
11262 (target_fileio_readlink): Return optional<string>.
11263 * remote.c (remote_hostio_readlink): Return optional<string>.
11264 * inf-child.c (inf_child_fileio_readlink): Return
11265 optional<string>.
11266 * target.c (target_fileio_readlink): Return optional<string>.
11267
11268 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
11269
11270 * regcache.c (cooked_read_test): Add riscv to the list of
11271 architectures that have a save_reggroup.
11272
11273 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
11274
11275 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
11276 value is not a dynamic class object.
11277
11278 2018-03-06 Tom Tromey <tom@tromey.com>
11279
11280 * rust-exp.y: Formatting fixes.
11281
11282 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11283
11284 * riscv-tdep.c (riscv_register_name): Remove target description
11285 support.
11286 (riscv_gdbarch_init): Remove target description check.
11287
11288 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11289
11290 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
11291 comment.
11292 * riscv-tdep.h: Likewise.
11293
11294 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11295
11296 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
11297 (riscv_pseudo_register_write): Delete.
11298 (riscv_gdbarch_init): Remove all use of pseudo registers.
11299
11300 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11301
11302 * record-btrace.c (btrace_print_lines): Replace cleanup
11303 parameter with RAII equivalents.
11304 (btrace_insn_history): Replace cleanup with RAII equivalents.
11305 * ui-out.h (make_cleanup_ui_out_list_begin_end,
11306 make_cleanup_ui_out_tuple_begin_end): Remove.
11307 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
11308 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
11309 make_cleanup_ui_out_list_begin_end): Remove.
11310
11311 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11312
11313 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
11314 parameter types to std::vector. Use bool.
11315 (record_btrace_wait): Replace VEC(tp_t) with
11316 std::vector<thread_info *>.
11317 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
11318
11319 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
11320
11321 * record-btrace.c (record_btrace_disable_callback): Remove.
11322 (struct scoped_btrace_disable): New.
11323 (record_btrace_open): Use scoped_btrace_disable.
11324
11325 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11326
11327 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
11328 reading values from registers.
11329
11330 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11331
11332 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
11333 where appropriate.
11334
11335 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11336
11337 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
11338 change parameter type. Use GDB's print functions, and use
11339 core_addr_to_string where appropriate.
11340 (riscv_push_dummy_call): Use core_addr_to_string where
11341 appropriate, update call to riscv_print_arg_location, and reindent
11342 a few lines.
11343 (riscv_return_value): Update call to riscv_print_arg_location.
11344
11345 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11346 Tim Newsome <tim@sifive.com>
11347 Albert Ou <a0u@eecs.berkeley.edu>
11348 Darius Rad <darius@bluespec.com>
11349
11350 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
11351 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
11352 (ALLDEPFILES): Add riscv-tdep.c
11353 * configure.tgt: Add riscv support.
11354 * riscv-tdep.c: New file.
11355 * riscv-tdep.h: New file.
11356 * NEWS: Mention new target.
11357 * MAINTAINERS: Add entry for riscv.
11358
11359 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
11360
11361 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
11362 fields within aggregates.
11363
11364 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
11365
11366 * record-btrace.c (btrace_print_lines): Change type of flags to
11367 gdb_disassembly_flags.
11368
11369 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11370
11371 * fbsd-nat.c: Include "inf-ptrace.h".
11372 (USE_SIGTRAP_SIGINFO): Conditionally define.
11373 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
11374 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
11375 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
11376 function.
11377 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
11378 Likewise.
11379 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
11380 Likewise.
11381 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
11382 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
11383 "supports_stopped_by_hw_breakpoint" target methods.
11384
11385 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11386
11387 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
11388 * fbsd-nat.c (debug_fbsd_nat): New variable.
11389 (show_fbsd_nat_debug): New function.
11390 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
11391 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
11392
11393 2018-03-04 John Baldwin <jhb@FreeBSD.org>
11394
11395 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
11396 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
11397 prototype.
11398 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
11399 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
11400 method.
11401
11402 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11403
11404 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
11405 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
11406
11407 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11408
11409 * charset.c (struct charset_vector): New.
11410 (charsets): Change type to charset_vector.
11411 (find_charset_names): Adjust.
11412 (add_one): Adjust.
11413 (_initialize_charset): Adjust.
11414
11415 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11416
11417 * progspace.h (struct program_space) <deleted_solibs>: Change
11418 type to std::vector<std::string>.
11419 * progspace.c (clear_program_space_solib_cache): Adjust.
11420 * breakpoint.c (print_solib_event): Adjust.
11421 (check_status_catch_solib): Adjust.
11422 * solib.c (update_solib_list): Adjust.
11423 * ui-out.h (class ui_out) <field_string>: New overload.
11424 * ui-out.c (ui_out::field_string): New overload.
11425
11426 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11427
11428 * progspace.h (struct program_space): Add constructor and
11429 destructor, initialize fields.
11430 (add_program_space): Remove.
11431 * progspace.c (add_program_space): Rename to...
11432 (program_space::program_space): ... this.
11433 (release_program_space): Rename to...
11434 (program_space::~program_space): ... this.
11435 (delete_program_space): Use delete to delete program_space.
11436 (initialize_progspace): Use new to allocate program_space.
11437 * inferior.c (add_inferior_with_spaces): Likewise.
11438 (clone_inferior_command): Likewise.
11439 * infrun.c (follow_fork_inferior): Likewise.
11440 (handle_vfork_child_exec_or_exit): Likewise.
11441
11442 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
11443
11444 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
11445 (delim_string_to_char_ptr_vec): Return std::vector of
11446 gdb::unique_xmalloc_ptr.
11447 (dirnames_to_char_ptr_vec_append): Take std::vector of
11448 gdb::unique_xmalloc_ptr.
11449 (dirnames_to_char_ptr_vec): Return std::vector of
11450 gdb::unique_xmalloc_ptr.
11451 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
11452 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
11453 (delim_string_to_char_ptr_vec): Return an std::vector of
11454 gdb::unique_xmalloc_ptr, adjust the code.
11455 (dirnames_to_char_ptr_vec_append): Take an std::vector of
11456 gdb::unique_xmalloc_ptr, adjust the code.
11457 (dirnames_to_char_ptr_vec): Return an std::vector of
11458 gdb::unique_xmalloc_ptr, adjust the code.
11459 * auto-load.c (auto_load_safe_path_vec): Change type to
11460 std::vector of gdb::unique_xmalloc_ptr.
11461 (auto_load_expand_dir_vars): Return an std::vector of
11462 gdb::unique_xmalloc_ptr, adjust the code.
11463 (auto_load_safe_path_vec_update): Adjust.
11464 (filename_is_in_auto_load_safe_path_vec): Adjust.
11465 (auto_load_objfile_script_1): Adjust.
11466 * build-id.c (build_id_to_debug_bfd): Adjust.
11467 * linux-thread-db.c (thread_db_load_search): Adjust.
11468 * source.c (add_path): Adjust.
11469 (openp): Adjust.
11470 * symfile.c (find_separate_debug_file): Adjust.
11471 * utils.c (do_free_char_ptr_vec): Remove.
11472 (make_cleanup_free_char_ptr_vec): Remove.
11473
11474 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
11475
11476 PR gdb/22907
11477 * common/pathstuff.c: Conditionally include "<windows.h>".
11478
11479 2018-03-01 Georg Sauthoff <mail@georg.so>
11480
11481 PR gdb/22888
11482 * gcore.in: Quote variables and switch interpreter to bash.
11483
11484 2018-03-01 Tom Tromey <tom@tromey.com>
11485
11486 * dwarf2read.c (alloc_discriminant_info): Fix default_index
11487 assertion. Add assertion for discriminant_index.
11488 (quirk_rust_enum): Use correct base type name in univariant case.
11489
11490 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
11491
11492 * record.c (get_call_history_modifiers): Return a
11493 record_print_flags.
11494 (cmd_record_call_history): Adjust.
11495 * record-btrace.c (record_btrace_call_history): Adjust.
11496 (record_btrace_call_history_range): Adjust.
11497 (record_btrace_call_history_from): Adjust.
11498 * target-debug.h (target_debug_print_record_print_flags): New.
11499 * target-delegates.c: Re-generate.
11500 * target.c (target_call_history): Change flags type.
11501 (target_call_history_from): Likewise.
11502 (target_call_history_range): Likewise.
11503 * target.h (struct target_ops) <target_call_history>: Likewise.
11504 (target_call_history_from): Likewise.
11505 (target_call_history_range): Likewise.
11506
11507 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11508 Simon Marchi <simon.marchi@polymtl.ca>
11509
11510 * common/common-utils.c: Include "sys/stat.h".
11511 (is_regular_file): Move here from "source.c"; change return
11512 type to "bool".
11513 * common/common-utils.h (is_regular_file): New prototype.
11514 * common/pathstuff.c (contains_dir_separator): New function.
11515 * common/pathstuff.h (contains_dir_separator): New prototype.
11516 * source.c: Don't include "sys/stat.h".
11517 (is_regular_file): Move to "common/common-utils.c".
11518
11519 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
11520
11521 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
11522 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
11523 * auto-load.c: Include "common/pathstuff.h".
11524 * common/common-def.h (current_directory): Move here.
11525 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
11526 function.
11527 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
11528 prototype.
11529 * common/pathstuff.c: New file.
11530 * common/pathstuff.h: New file.
11531 * compile/compile.c: Include "common/pathstuff.h".
11532 * defs.h (current_directory): Move to "common/common-defs.h".
11533 * dwarf2read.c: Include "common/pathstuff.h".
11534 * exec.c: Likewise.
11535 * guile/scm-safe-call.c: Likewise.
11536 * linux-thread-db.c: Likewise.
11537 * main.c: Likewise.
11538 * nto-tdep.c: Likewise.
11539 * objfiles.c: Likewise.
11540 * source.c: Likewise.
11541 * symtab.c: Likewise.
11542 * utils.c: Include "common/pathstuff.h".
11543 (gdb_realpath): Move to "common/pathstuff.c".
11544 (gdb_realpath_keepfile): Likewise.
11545 (gdb_abspath): Likewise.
11546 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
11547 (gdb_realpath_keepfile): Likewise.
11548 (gdb_abspath): Likewise.
11549
11550 2018-02-28 John Baldwin <jhb@FreeBSD.org>
11551
11552 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
11553 wildcard process pid for super_resume for kernels with a
11554 specific bug.
11555
11556 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
11557
11558 * compile/compile.c (get_args): Add additional comments
11559 explaining function.
11560
11561 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
11562 Tom Tromey <tom@tromey.com>
11563
11564 * target.h (memory_write_request_s): Remove typedef. Don't define
11565 VEC.
11566 (target_write_memory_blocks): Change argument to std::vector.
11567 (struct memory_write_request): Add constructor.
11568 * target-memory.c (compare_block_starting_address): Return bool.
11569 Change argument types.
11570 (claim_memory): Change arguments to use std::vector.
11571 (split_regular_and_flash_blocks, blocks_to_erase)
11572 (compute_garbled_blocks): Likewise.
11573 (cleanup_request_data, cleanup_write_requests_vector): Remove.
11574 (target_write_memory_blocks): Change argument to std::vector.
11575 * symfile.c (struct load_section_data): Add constructor and
11576 destructor. Use std::vector for "requests".
11577 (struct load_progress_data): Add initializers.
11578 (load_section_callback): Update. Use "new".
11579 (clear_memory_write_data): Remove.
11580 (generic_load): Update.
11581
11582 2018-02-27 Alan Hayward <alan.hayward@arm.com>
11583
11584 * arch/aarch64.h: Use common/tdesc.h.
11585
11586 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11587
11588 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
11589 architecture with a 64-bit ABI.
11590
11591 2018-02-26 Maciej W. Rozycki <macro@mips.com>
11592
11593 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
11594 ahead of target description loading.
11595
11596 2018-02-26 Tom Tromey <tom@tromey.com>
11597
11598 * stack.c (backtrace_command_1): Update.
11599 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
11600 of "flags".
11601 * python/py-framefilter.c (py_print_frame)
11602 (gdbpy_apply_frame_filter): Change type of "flags".
11603 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
11604 of "flags".
11605 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
11606 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
11607 * extension.h (enum frame_filter_flag): Rename from
11608 frame_filter_flags.
11609 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
11610 (apply_ext_lang_frame_filter): Change type of "flags".
11611 * extension.c (apply_ext_lang_frame_filter): Change type of
11612 "flags".
11613 * extension-priv.h (struct extension_language_ops)
11614 <apply_frame_filter>: Change type of "flags".
11615
11616 2018-02-26 Tom Tromey <tom@tromey.com>
11617
11618 PR python/16497:
11619 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
11620 off-by-one in py_end computation.
11621 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
11622 PRINT_MORE_FRAMES.
11623 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
11624 constant.
11625
11626 2018-02-26 Tom Tromey <tom@tromey.com>
11627
11628 * dwarf2read.c (struct variant_field): New.
11629 (struct nextfield) <variant>: New field.
11630 (dwarf2_add_field): Handle DW_TAG_variant_part.
11631 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
11632 discriminated union.
11633 (read_structure_type): Handle DW_TAG_variant_part.
11634 (handle_struct_member_die): New function, extracted from
11635 process_structure_scope. Handle DW_TAG_variant.
11636 (process_structure_scope): Handle discriminated unions. Call
11637 handle_struct_member_die.
11638
11639 2018-02-26 Tom Tromey <tom@tromey.com>
11640
11641 * rust-lang.h (rust_last_path_segment): Declare.
11642 * rust-lang.c (rust_last_path_segment): Now public. Change
11643 contract.
11644 (struct disr_info): Remove.
11645 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
11646 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
11647 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
11648 (rust_enum_p, rust_enum_variant): New function.
11649 (rust_underscore_fields): Remove "offset" parameter.
11650 (rust_print_enum): New function.
11651 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
11652 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
11653 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
11654 enums.
11655 (rust_internal_print_type): New function, from rust_print_type.
11656 Remove enum code.
11657 (rust_print_type): Call rust_internal_print_type.
11658 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
11659 Update enum handling.
11660 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
11661 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
11662 (rust_union_quirks): New functions.
11663 (process_full_comp_unit, process_full_type_unit): Call
11664 rust_union_quirks.
11665 (process_structure_scope): Update rust_unions if necessary.
11666
11667 2018-02-26 Tom Tromey <tom@tromey.com>
11668
11669 * value.h (value_union_variant): Declare.
11670 * valops.c (value_union_variant): New function.
11671 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
11672 (struct discriminant_info): New.
11673 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
11674 enumerator.
11675 (struct main_type) <flag_discriminated_union>: New field.
11676
11677 2018-02-26 Tom Tromey <tom@tromey.com>
11678
11679 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11680 unittests/unpack-selftests.c.
11681 * unittests/unpack-selftests.c: New file.
11682 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
11683
11684 2018-02-26 Yao Qi <yao.qi@linaro.org>
11685
11686 * dwarf2read.c (struct partial_die_info) <read>: New method.
11687 (read_partial_die): Remove the declaration.
11688 (load_partial_dies): Update.
11689 (partial_die_info::partial_die_info):
11690 (read_partial_die): Change it to partial_die_info::read.
11691
11692 2018-02-26 Yao Qi <yao.qi@linaro.org>
11693
11694 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
11695 (fixup_partial_die): Remove declaration.
11696 (scan_partial_symbols): Update.
11697 (partial_die_parent_scope): Likewise.
11698 (partial_die_full_name): Likewise.
11699 (fixup_partial_die): Change it to partial_die_info::fixup.
11700
11701 2018-02-26 Yao Qi <yao.qi@linaro.org>
11702
11703 * dwarf2read.c (read_partial_die): Update the declaration.
11704 (load_partial_dies): Caller update.
11705 (read_partial_die): Remove one argument abbrev_len.
11706
11707 2018-02-26 Yao Qi <yao.qi@linaro.org>
11708
11709 * dwarf2read.c (struct partial_die_info): Add ctor, delete
11710 assignment operator.
11711 (load_partial_dies): Use ctor and copy ctor.
11712 (read_partial_die): Update.
11713 (dwarf2_cu::find_partial_die): Use ctor.
11714
11715 2018-02-26 Yao Qi <yao.qi@linaro.org>
11716
11717 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
11718 (find_partial_die_in_comp_unit): Change it to
11719 dwarf2_cu::find_partial_die.
11720 (find_partial_die): Update.
11721
11722 2018-02-26 Yao Qi <yao.qi@linaro.org>
11723
11724 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
11725 is NULL.
11726
11727 2018-02-26 Yao Qi <yao.qi@linaro.org>
11728
11729 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
11730
11731 2018-02-26 Alan Hayward <alan.hayward@arm.com>
11732
11733 * arch/amd64.h: Use common/tdesc.h.
11734 * arch/i386.c: Likewise.
11735 * arch/i386.h: Likewise.
11736 * arch/tic6x.c: Likewise.
11737 * arch/tdesc.h: Move file from here...
11738 * common/tdesc.h: ...to here.
11739 * features/aarch64-core.c: Regenerate.
11740 * features/aarch64-fpu.c: Regenerate.
11741 * features/i386/32bit-avx.c: Regenerate.
11742 * features/i386/32bit-avx512.c: Regenerate.
11743 * features/i386/32bit-core.c: Regenerate.
11744 * features/i386/32bit-linux.c: Regenerate.
11745 * features/i386/32bit-mpx.c: Regenerate.
11746 * features/i386/32bit-pkeys.c: Regenerate.
11747 * features/i386/32bit-sse.c: Regenerate.
11748 * features/i386/64bit-avx.c: Regenerate.
11749 * features/i386/64bit-avx512.c: Regenerate.
11750 * features/i386/64bit-core.c: Regenerate.
11751 * features/i386/64bit-linux.c: Regenerate.
11752 * features/i386/64bit-mpx.c: Regenerate.
11753 * features/i386/64bit-pkeys.c: Regenerate.
11754 * features/i386/64bit-segments.c: Regenerate.
11755 * features/i386/64bit-sse.c: Regenerate.
11756 * features/i386/x32-core.c: Regenerate.
11757 * features/tic6x-c6xp.c: Regenerate.
11758 * features/tic6x-core.c: Regenerate.
11759 * features/tic6x-gp.c: Regenerate.
11760 * target-descriptions.c: Use common/tdesc.h.
11761 * target-descriptions.h: Likewise.
11762
11763 2018-02-24 Tom Tromey <tom@tromey.com>
11764
11765 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
11766 (try_thread_db_load_from_dir, thread_db_load_search): Use
11767 std::string.
11768 (info_auto_load_libthread_db_compare): Return bool. Change
11769 argument types.
11770 (info_auto_load_libthread_db): Use std::vector, std::string.
11771 Remove cleanups.
11772
11773 2018-02-24 Tom Tromey <tom@tromey.com>
11774
11775 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
11776 std::string.
11777 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
11778 std::string*.
11779 * gdbarch.c: Rebuild.
11780 * gdbarch.h: Rebuild.
11781 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
11782 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
11783 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
11784 std::string*.
11785
11786 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
11787
11788 * gdbtypes.h (sect_offset): Change type to uint64_t.
11789 (sect_offset_str): New function.
11790 * dwarf2read.c (create_addrmap_from_aranges): Use
11791 sect_offset_str.
11792 (error_check_comp_unit_head): Likewise.
11793 (create_debug_type_hash_table): Likewise.
11794 (read_cutu_die_from_dwo): Likewise.
11795 (init_cutu_and_read_dies): Likewise.
11796 (init_cutu_and_read_dies_no_follow): Likewise.
11797 (process_psymtab_comp_unit_reader): Likewise.
11798 (partial_die_parent_scope): Likewise.
11799 (peek_die_abbrev): Likewise.
11800 (process_queue): Likewise.
11801 (dwarf2_physname): Likewise.
11802 (read_namespace_alias): Likewise.
11803 (read_import_statement): Likewise.
11804 (create_dwo_cu_reader): Likewise.
11805 (create_cus_hash_table): Likewise.
11806 (lookup_dwo_cutu): Likewise.
11807 (inherit_abstract_dies): Likewise.
11808 (read_func_scope): Likewise.
11809 (read_call_site_scope): Likewise.
11810 (dwarf2_add_member_fn): Likewise.
11811 (read_common_block): Likewise.
11812 (read_module_type): Likewise.
11813 (read_typedef): Likewise.
11814 (read_subrange_type): Likewise.
11815 (load_partial_dies): Likewise.
11816 (read_partial_die): Likewise.
11817 (find_partial_die): Likewise.
11818 (read_str_index): Likewise.
11819 (dwarf2_string_attr): Likewise.
11820 (build_error_marker_type): Likewise.
11821 (lookup_die_type): Likewise.
11822 (dump_die_shallow): Likewise.
11823 (follow_die_ref): Likewise.
11824 (dwarf2_fetch_die_loc_sect_off): Likewise.
11825 (dwarf2_fetch_constant_bytes): Likewise.
11826 (follow_die_sig): Likewise.
11827 (get_signatured_type): Likewise.
11828 (get_DW_AT_signature_type): Likewise.
11829 (dwarf2_find_containing_comp_unit): Likewise.
11830 (set_die_type): Likewise.
11831
11832 2018-02-21 John Baldwin <jhb@FreeBSD.org>
11833
11834 * arch/aarch64.c: Include "common-defs.h".
11835 * arch/amd64.c: Likewise.
11836 * arch/i386.c: Likewise.
11837
11838 2018-02-21 Tom Tromey <tom@tromey.com>
11839
11840 * value.h: (extract_field_op): Update.
11841 * eval.c (extract_field_op): Return a const char *.
11842 * expression.h (parse_expression_for_completion): Update.
11843 * completer.c (complete_expression): Update.
11844 (add_struct_fields): Make fieldname const.
11845 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
11846 (mark_completion_tag, parse_exp_in_context_1): Update.
11847 (parse_expression_for_completion): Change "name" to
11848 unique_xmalloc_ptr*.
11849
11850 2018-02-21 Tom Tromey <tom@tromey.com>
11851
11852 * infcall.c (call_function_by_hand_dummy): Use std::vector.
11853
11854 2018-02-21 Yao Qi <yao.qi@linaro.org>
11855
11856 * avr-tdep.c (avr_read_pc): Change parameter type to
11857 readable_regcache.
11858 * gdbarch.sh (read_pc): Likewise.
11859 * gdbarch.c: Re-generated.
11860 * gdbarch.h: Re-generated.
11861 * hppa-tdep.c (hppa_read_pc): Change parameter type to
11862 readable_regcache.
11863 * ia64-tdep.c (ia64_read_pc): Likewise.
11864 * mips-tdep.c (mips_read_pc): Likewise.
11865 * spu-tdep.c (spu_read_pc): Likewise.
11866
11867 2018-02-21 Yao Qi <yao.qi@linaro.org>
11868
11869 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
11870 * regcache-dump.c: New file.
11871 * regcache.c: Move register_dump to regcache-dump.c.
11872 (maintenance_print_registers): Likewise.
11873 (maintenance_print_raw_registers): Likewise.
11874 (maintenance_print_cooked_registers): Likewise.
11875 (maintenance_print_register_groups): Likewise.
11876 (maintenance_print_remote_registers): Likewise.
11877 (_initialize_regcache): Likewise.
11878 * regcache.h (register_dump): Moved from regcache.c.
11879
11880 2018-02-21 Yao Qi <yao.qi@linaro.org>
11881
11882 * regcache.c (regcache::regcache): Update.
11883 (regcache::invalidate): Move it to detached_regcache::invalidate.
11884 (get_thread_arch_aspace_regcache): Update.
11885 (regcache::raw_update): Update.
11886 (regcache::cooked_read): Remove some code.
11887 (regcache::cooked_read_value): Likewise.
11888 (regcache::raw_write): Remove assert on m_readonly_p.
11889 (regcache::raw_supply_integer): Move it to
11890 detached_regcache::raw_supply_integer.
11891 (regcache::raw_supply_zeroed): Likewise.
11892 * regcache.h (detached_regcache) <raw_supply_integer>: New
11893 declaration.
11894 <raw_supply_zeroed, invalidate>: Likewise.
11895 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
11896 <invalidate>: Likewise.
11897 <m_readonly_p>: Removed.
11898
11899 2018-02-21 Yao Qi <yao.qi@linaro.org>
11900
11901 * infcmd.c (get_return_value): Let stop_regs point to
11902 get_current_regcache.
11903 * regcache.c (regcache::regcache): Remove.
11904 (register_dump_reg_buffer): New class.
11905 (regcache_print): Adjust.
11906 * regcache.h (regcache): Remove constructors.
11907
11908 2018-02-21 Yao Qi <yao.qi@linaro.org>
11909
11910 * regcache.c (class register_dump): New class.
11911 (register_dump_regcache, register_dump_none): New class.
11912 (register_dump_remote, register_dump_groups): New class.
11913 (regcache_print): Update.
11914 * regcache.h (regcache_dump_what): Move it to regcache.c.
11915 (regcache) <dump>: Remove.
11916
11917 2018-02-21 Yao Qi <yao.qi@linaro.org>
11918
11919 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
11920 reg_buffer_rw *.
11921 (jit_unwind_reg_set_impl): Call raw_supply.
11922 (jit_frame_sniffer): Use reg_buffer_rw.
11923 * record-full.c (record_full_core_regbuf): Change its type.
11924 (record_full_core_open_1): Use reg_buffer_rw.
11925 (record_full_close): Likewise.
11926 (record_full_core_fetch_registers): Use regcache->raw_supply.
11927 (record_full_core_store_registers): Likewise.
11928 * regcache.c (regcache::get_register_status): Move it to
11929 reg_buffer.
11930 (regcache_raw_set_cached_value): Remove.
11931 (regcache::raw_set_cached_value): Remove.
11932 (regcache::raw_write): Call raw_supply.
11933 (regcache::raw_supply): Move it to reg_buffer_rw.
11934 * regcache.h (regcache_raw_set_cached_value): Remove.
11935 (reg_buffer_rw): New class.
11936
11937 2018-02-21 Yao Qi <yao.qi@linaro.org>
11938
11939 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
11940 readonly_detached_regcache.
11941 (dummy_frame_prev_register): Use regcache->cooked_read.
11942 * frame.c (frame_save_as_regcache): Change return type.
11943 (frame_pop): Update.
11944 * frame.h (frame_save_as_regcache): Update declaration.
11945 * inferior.h (get_infcall_suspend_state_regcache): Update
11946 declaration.
11947 * infrun.c (infcall_suspend_state) <registers>: use
11948 readonly_detached_regcache.
11949 (save_infcall_suspend_state): Don't use regcache_dup.
11950 (get_infcall_suspend_state_regcache): Change return type.
11951 * linux-fork.c (struct fork_info) <savedregs>: Change to
11952 readonly_detached_regcache.
11953 <pc>: New field.
11954 (fork_save_infrun_state): Don't use regcache_dup.
11955 (info_checkpoints_command): Adjust.
11956 * mi/mi-main.c (register_changed_p): Update declaration.
11957 (mi_cmd_data_list_changed_registers): Use
11958 readonly_detached_regcache.
11959 (register_changed_p): Change parameter type to
11960 readonly_detached_regcache.
11961 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
11962 readonly_detached_regcache.
11963 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
11964 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
11965 New.
11966 (regcache::save): Move it to reg_buffer.
11967 (regcache::restore): Change parameter type.
11968 (regcache_dup): Remove.
11969 * regcache.h (reg_buffer) <save>: New method.
11970 (readonly_detached_regcache): New class.
11971 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
11972 readonly_detached_regcache.
11973 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
11974
11975 2018-02-21 Yao Qi <yao.qi@linaro.org>
11976
11977 * frame.c (frame_save_as_regcache): Use regcache method save.
11978 (frame_pop): Use regcache method restore.
11979 * infrun.c (restore_infcall_suspend_state): Likewise.
11980 * linux-fork.c (fork_load_infrun_state): Likewise.
11981 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
11982 save.
11983 * regcache.c (regcache_save): Remove.
11984 (regcache::restore): More asserts.
11985 (regcache_cpy): Remove.
11986 * regcache.h (regcache_save): Remove the declaration.
11987 (regcache::restore): Move from private to public.
11988 Remove the friend declaration of regcache_cpy.
11989 (regcache_cpy): Remove declaration.
11990
11991 2018-02-21 Yao Qi <yao.qi@linaro.org>
11992
11993 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
11994 parameter type to 'readable_regcache *'.
11995 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
11996 * arm-tdep.c (arm_neon_quad_read): Likewise.
11997 (arm_pseudo_read): Likewise.
11998 * avr-tdep.c (avr_pseudo_register_read): Likewise.
11999 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12000 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12001 * gdbarch.c: Re-generated.
12002 * gdbarch.h: Re-generated.
12003 * gdbarch.sh (pseudo_register_read): Change parameter type to
12004 'readable_regcache *'.
12005 (pseudo_register_read_value): Likewise.
12006 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
12007 (h8300_pseudo_register_read): Likewise.
12008 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
12009 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12010 (i386_pseudo_register_read_into_value): Likewise.
12011 (i386_pseudo_register_read_value): Likewise.
12012 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
12013 declaration.
12014 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
12015 * m32c-tdep.c (m32c_raw_read): Likewise.
12016 (m32c_read_flg): Likewise.
12017 (m32c_banked_register): Likewise.
12018 (m32c_banked_read): Likewise.
12019 (m32c_sb_read): Likewise.
12020 (m32c_part_read): Likewise.
12021 (m32c_cat_read): Likewise.
12022 (m32c_r3r2r1r0_read): Likewise.
12023 (m32c_pseudo_register_read): Likewise.
12024 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12025 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12026 (mep_pseudo_cr64_read): Likewise.
12027 (mep_pseudo_register_read): Likewise.
12028 * mips-tdep.c (mips_pseudo_register_read): Likewise.
12029 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12030 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12031 * regcache.c (regcache::raw_read): Move it to readable_regcache.
12032 (regcache::cooked_read): Likewise.
12033 (regcache::cooked_read_value): Likewise.
12034 (regcache_cooked_read_signed):
12035 (regcache::cooked_read): Likewise.
12036 * regcache.h (readable_regcache): New class.
12037 (regcache): Inherit readable_regcache. Move some methods to
12038 readable_regcache.
12039 * rl78-tdep.c (rl78_pseudo_register_read): Change
12040 parameter type to 'readable_regcache *'.
12041 * rs6000-tdep.c (do_regcache_raw_read): Remove.
12042 (e500_pseudo_register_read): Change parameter type to
12043 'readable_regcache *'.
12044 (dfp_pseudo_register_read): Likewise.
12045 (vsx_pseudo_register_read): Likewise.
12046 (efpr_pseudo_register_read): Likewise.
12047 * s390-tdep.c (s390_pseudo_register_read): Likewise.
12048 * sh-tdep.c (sh_pseudo_register_read): Likewise.
12049 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
12050 (sh64_pseudo_register_read): Likewise.
12051 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12052 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12053 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12054 (spu_pseudo_register_read): Likewise.
12055 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12056 (xtensa_pseudo_register_read): Likewise.
12057
12058 2018-02-21 Yao Qi <yao.qi@linaro.org>
12059
12060 * regcache.c (regcache::regcache): Call reg_buffer ctor.
12061 (regcache::arch): Move it to reg_buffer::arch.
12062 (regcache::register_buffer): Likewise.
12063 (regcache::assert_regnum): Likewise.
12064 (regcache::num_raw_registers): Likewise.
12065 * regcache.h (reg_buffer): New class.
12066 (regcache): Inherit reg_buffer.
12067
12068 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
12069
12070 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
12071 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
12072
12073 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
12074
12075 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
12076
12077 2018-02-19 Alan Hayward <alan.hayward@arm.com>
12078
12079 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
12080 (SFILES): Remove common/*.c files.
12081 (COMMON_OBS): Remove some *.o files built from common/*.c files.
12082 * common/common.host: Add common reference.
12083 * configure.ac: Likewise.
12084 * configure: Regenerate.
12085
12086 2018-02-16 Yao Qi <yao.qi@linaro.org>
12087
12088 * block.c (block_namespace_info): Inherit allocate_on_obstack.
12089 (block_initialize_namespace): Use new.
12090 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
12091 (dwarf2_free_objfile): Use delete.
12092 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
12093 (copy_type_recursive): Use new.
12094 * gdb_obstack.h (allocate_on_obstack): New.
12095
12096 2018-02-15 Yao Qi <yao.qi@linaro.org>
12097
12098 PR gdb/22849
12099 * inferior.c (exit_inferior_1): Reset inf->control.
12100
12101 2018-02-15 Joel Brobecker <brobecker@adacore.com>
12102
12103 * ada-lang.c (ada_to_fixed_value_create): Delete advance
12104 declaration.
12105
12106 2018-02-14 Pedro Alves <palves@redhat.com>
12107
12108 * frame-unwind.c (frame_unwind_try_unwinder): Always call
12109 frame_cleanup_after_sniffer on exception.
12110
12111 2018-02-14 Tom Tromey <tom@tromey.com>
12112
12113 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
12114 const.
12115 (solib_bfd_open): Make pathname const.
12116 * solib.c (solib_bfd_open): Make pathname const.
12117 * solib-spu.c (spu_bfd_fopen): Make name const.
12118 (spu_bfd_open): Make pathname const.
12119 * solib-darwin.c (darwin_bfd_open): Make pathname const.
12120 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
12121
12122 2018-02-14 Tom Tromey <tom@tromey.com>
12123
12124 * symfile.c (symfile_bfd_open): Update.
12125 * source.h (openp, source_full_path_of, find_and_open_source):
12126 Change argument type to unique_xmalloc_ptr.
12127 * source.c (openp): Take a unique_xmalloc_ptr.
12128 (source_full_path_of, find_and_open_source): Likewise.
12129 (open_source_file, symtab_to_fullname): Update.
12130 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
12131 unique_xmalloc_ptr.
12132 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
12133 (exec_file_find): Update.
12134 * psymtab.c (psymtab_to_fullname): Update.
12135 * nto-tdep.h (nto_find_and_open_solib): Update.
12136 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
12137 unique_xmalloc_ptr.
12138 * exec.c (exec_file_attach): Update.
12139 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
12140 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
12141
12142 2018-02-14 Tom Tromey <tom@tromey.com>
12143
12144 * solib.c: Include source.h.
12145 * nto-tdep.c: Include source.h.
12146 * mi/mi-cmd-env.c: Include source.h.
12147 * infcmd.c: Include source.h.
12148 * exec.c: Include source.h.
12149 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
12150 (add_path, directory_switch, source_path, init_source_path): Move
12151 declarations...
12152 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
12153 (add_path, directory_switch, source_path, init_source_path):
12154 ...here.
12155
12156 2018-02-14 Tom Tromey <tom@tromey.com>
12157
12158 * solist.h (exec_file_find, solib_find): Return
12159 unique_xmalloc_ptr.
12160 (solib_bfd_fopen): Take a const char *.
12161 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
12162 (exec_file_find, solib_find): Likewise.
12163 (solib_bfd_fopen): Do not take ownership of "pathname".
12164 (solib_bfd_open): Use unique_xmalloc_ptr.
12165 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
12166 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
12167 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
12168 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
12169
12170 2018-02-14 Joel Brobecker <brobecker@adacore.com>
12171
12172 * ada-lang.c (name_match_type_from_name): Remove reference to
12173 ada_name_for_lookup in function's documentation.
12174 * ada-lang.h (ada_name_for_lookup): Delete declaration.
12175
12176 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12177
12178 * defs.h (enum openp_flags): New enum.
12179 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
12180 Move to enum openp_flags.
12181 (openp_flags): New enum flags.
12182 (openp): Change parameter type to openp_flags.
12183 * source.c (openp): Change parameter type to openp_flags.
12184 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
12185 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
12186
12187 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
12188
12189 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
12190 per-command.
12191
12192 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
12193
12194 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
12195 into...
12196 (class dwarf2_queue_guard): ...the destructor of this new class.
12197 (dw2_do_instantiate_symtab): Create instance of the new class
12198 dwarf2_queue_guard, remove cleanup.
12199
12200 2018-02-09 Tom Tromey <tom@tromey.com>
12201
12202 * source.c (find_source_lines): Don't reference past the end of
12203 the vector.
12204
12205 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12206
12207 * remote.c (remote_btrace_maybe_reopen): Change error message.
12208 * btrace.c (btrace_enable): Likewise.
12209 (parse_xml_btrace): Likewise.
12210 (parse_xml_btrace_conf): Likewise.
12211
12212 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12213
12214 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
12215 (linux_enable_pt, linux_enable_bts): Call
12216 diagnose_perf_event_open_fail.
12217
12218 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12219
12220 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
12221 Remove parameter and change return type. Update callers. Move it.
12222 (linux_enable_bts, linux_enable_pt): Improve error message.
12223 (linux_enable_pt): Remove zero buffer size check.
12224 (linux_enable_btrace): Improve error messages. Remove NULL return
12225 check.
12226
12227 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12228
12229 * btrace.c (btrace_enable): Remove target_supports_btrace call.
12230 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
12231 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
12232 (linux_supports_pt, linux_supports_btrace): Remove.
12233 (linux_enable_bts): Call cpu_supports_bts.
12234 * nat/linux-btrace.h (linux_supports_btrace): Remove.
12235 * remote.c (remote_supports_btrace): Remove.
12236 (init_remote_ops): Remove remote_supports_btrace.
12237 * target-delegates.c: Regenerated.
12238 * target.c (target_supports_btrace): Remove.
12239 * target.h (target_ops) <to_supports_btrace>: Remove
12240 (target_supports_btrace): Remove.
12241 * x86-linux-nat.c (x86_linux_create_target): Remove
12242 linux_supports_btrace.
12243
12244 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12245
12246 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
12247 btrace failed.
12248 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
12249 exception and use message in own exception.
12250
12251 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12252
12253 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
12254 (perf_event_pt_event_type): Use gdb_file_up.
12255 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
12256 scoped_fd, and scoped_mmap.
12257
12258 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12259
12260 * common/scoped_mmap.h: New.
12261 * unittests/scoped_mmap-selftest.c: New.
12262 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12263 unittests/scoped_mmap-selftest.c.
12264
12265 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
12266
12267 * common/scoped_fd.h: New.
12268 * unittests/scoped_fd-selftest.c: New.
12269 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12270 unittests/scoped_fd-selftest.c.
12271
12272 2018-02-09 Tom Tromey <tom@tromey.com>
12273
12274 * auto-load.c (auto_load_section_scripts): Use
12275 gdb::unique_xmalloc_ptr.
12276
12277 2018-02-09 Tom Tromey <tom@tromey.com>
12278
12279 * auto-load.c (execute_script_contents): Use std::string.
12280
12281 2018-02-09 Joel Brobecker <brobecker@adacore.com>
12282
12283 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
12284 Python function, rather than a new command.
12285
12286 2018-02-08 Tom Tromey <tom@tromey.com>
12287
12288 * solib.c (solib_find_1): Use std::string.
12289 (solib_bfd_fopen): Use unique_xmalloc_ptr.
12290
12291 2018-02-08 Tom Tromey <tom@tromey.com>
12292
12293 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
12294
12295 2018-02-08 Tom Tromey <tom@tromey.com>
12296
12297 * source.c (find_source_lines): Use gdb::def_vector.
12298
12299 2018-02-08 Tom Tromey <tom@tromey.com>
12300
12301 * macrocmd.c (struct temporary_macro_definition): New.
12302 (macro_define_command): Use temporary_macro_definition. Remove
12303 cleanups.
12304 (free_macro_definition_ptr): Remove.
12305
12306 2018-02-08 Tom Tromey <tom@tromey.com>
12307
12308 * macroexp.c (maybe_expand): Use std::string.
12309
12310 2018-02-08 Tom Tromey <tom@tromey.com>
12311
12312 * macroexp.c (struct macro_buffer): Add initializers for some
12313 members.
12314 (init_buffer, init_shared_buffer, free_buffer)
12315 (free_buffer_return_text): Remove.
12316 (macro_buffer): New constructors.
12317 (~macro_buffer): New destructor.
12318 (macro_buffer::set_shared): New method.
12319 (macro_buffer::resize_buffer, macro_buffer::appendc)
12320 (macro_buffer::appendmem): Now methods, not free functions.
12321 (set_token, append_tokens_without_splicing, stringify)
12322 (macro_stringify): Update.
12323 (gather_arguments): Change return type. Remove argc_p argument,
12324 add args_ptr argument. Use std::vector.
12325 (substitute_args): Remove argc argument. Accept std::vector.
12326 (expand): Update. Use std::vector.
12327 (scan, macro_expand, macro_expand_next): Update.
12328
12329 2018-02-08 Tom Tromey <tom@tromey.com>
12330
12331 * symtab.c (default_collect_symbol_completion_matches_break_on):
12332 Use unique_xmalloc_ptr.
12333 * macroscope.h: (sal_macro_scope, user_macro_scope)
12334 (default_macro_scope): Return unique_xmalloc_ptr.
12335 * macroscope.c (sal_macro_scope, user_macro_scope)
12336 (default_macro_scope): Return unique_xmalloc_ptr.
12337 * macroexp.h (macro_expand, macro_expand_once): Return
12338 unique_xmalloc_ptr.
12339 * macroexp.c (macro_expand, macro_expand_once): Return
12340 unique_xmalloc_ptr.
12341 * macrocmd.c (macro_expand_command, macro_expand_once_command)
12342 (info_macro_command, info_macros_command): Use
12343 unique_xmalloc_ptr.
12344 * compile/compile-c-support.c (write_macro_definitions): Use
12345 unique_xmalloc_ptr.
12346 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
12347
12348 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
12349
12350 * value.c (value_static_field): Assign field type instead of
12351 containing type when returning an optimized out value.
12352
12353 2018-02-06 Yao Qi <yao.qi@linaro.org>
12354
12355 * ft32-tdep.c (ft32_read_pc): Remove.
12356 (ft32_write_pc): Remove.
12357 (ft32_gdbarch_init): Update.
12358 * m32r-tdep.c (m32r_read_pc): Remove.
12359 (m32r_gdbarch_init): Update.
12360 * mep-tdep.c (mep_read_pc): Remove.
12361 (mep_gdbarch_init): Update.
12362 * microblaze-tdep.c (microblaze_write_pc): Remove.
12363 (microblaze_gdbarch_init): Update.
12364 * mn10300-tdep.c (mn10300_read_pc): Remove.
12365 (mn10300_write_pc): Remove.
12366 (mn10300_gdbarch_init): Update.
12367 * moxie-tdep.c (moxie_read_pc): Remove.
12368 (moxie_write_pc): Remove.
12369 (moxie_gdbarch_init): Update.
12370
12371 2018-02-06 Yao Qi <yao.qi@linaro.org>
12372
12373 * expprint.c (print_subexp_standard): Handle
12374 OP_F77_UNDETERMINED_ARGLIST.
12375 (dump_subexp_body_standard): Likewise.
12376
12377 2018-02-05 Alan Hayward <alan.hayward@arm.com>
12378
12379 * target-descriptions.c (tdesc_element_visitor) Add empty
12380 implementations.
12381 (tdesc_type): Move make_gdb_type from here.
12382 (tdesc_type_builtin): Likewise.
12383 (tdesc_type_vector): Likewise.
12384 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
12385 (make_gdb_type_struct): Move from tdesc_type_with_fields.
12386 (make_gdb_type_union): Likewise.
12387 (make_gdb_type_flags): Likewise.
12388 (make_gdb_type_enum): Likewise.
12389 (make_gdb_type): New function.
12390 (tdesc_register_type): Use static make_gdb_type.
12391
12392 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
12393
12394 * infcmd.c (default_print_one_register_info): Align natural-format
12395 column values consistently one under another.
12396 (pad_to_column): New function.
12397
12398 2018-02-05 Joel Brobecker <brobecker@adacore.com>
12399
12400 * dwarf2read.c (dwarf2_physname): Move commment.
12401
12402 2018-02-01 Leszek Swirski <leszeks@google.com>
12403
12404 * varobj.c (varobj_formatted_print_options): Allow recursive
12405 pretty printing if pretty printing is enabled.
12406
12407 2018-02-01 Leszek Swirski <leszeks@google.com>
12408
12409 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
12410 names after a structop as a filename.
12411
12412 2018-02-01 Yao Qi <yao.qi@linaro.org>
12413
12414 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
12415 (arm_record_coproc_data_proc): Likewise.
12416
12417 2018-02-01 Yao Qi <yao.qi@linaro.org>
12418
12419 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
12420
12421 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
12422
12423 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
12424 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
12425
12426 2018-01-31 Pedro Alves <palves@redhat.com>
12427
12428 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
12429 * inflow.c (child_terminal_save_inferior): Wrap reference to
12430 tcgetpgrp in HAVE_TERMIOS_H.
12431 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
12432 _WIN32.
12433 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
12434 always iterate over all inferiors.
12435 (gdbsim_cntrl_c): Adjust.
12436 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
12437
12438 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12439
12440 * gdbtypes.c (lookup_array_range_type): Make sure the array's
12441 index type is objfile-owned if the element type is as well.
12442
12443 2018-01-31 Joel Brobecker <brobecker@adacore.com>
12444
12445 GDB 8.1 released.
12446
12447 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
12448
12449 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
12450 "features/s390x-linux64.c".
12451 (_initialize_s390_linux_tdep): Remove initialization of tdescs
12452 s390_linux32 and s390x_linux64.
12453 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
12454 default tdesc.
12455 * s390-tdep.c: Include "features/s390-linux32.c" and
12456 "features/s390x-linux64.c".
12457 (s390_tdesc_valid): Add check for tdesc_has_registers.
12458 (s390_gdbarch_init): Make sure there is always a valid tdesc.
12459 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
12460 tdesc_s390x_linux64.
12461 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
12462 tdesc_s390x_linux64 to...
12463 * s390-tdep.h: ...here.
12464
12465 2018-01-30 Pedro Alves <palves@redhat.com>
12466
12467 PR gdb/13211
12468 * config.in, configure: Regenerate.
12469 * configure.ac: Check for getpgid.
12470 * go32-nat.c (go32_pass_ctrlc): New.
12471 (go32_target): Install it.
12472 * inf-child.c (inf_child_target): Install
12473 child_terminal_save_inferior, child_pass_ctrlc and
12474 child_interrupt.
12475 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
12476 (inf_ptrace_target): No longer install it.
12477 * infcmd.c (interrupt_target_1): Adjust.
12478 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
12479 (child_interrupt): Declare.
12480 (inferior::terminal_state): New.
12481 * inflow.c (struct terminal_info): Update comments.
12482 (inferior_process_group): Delete.
12483 (terminal_is_ours): Delete.
12484 (gdb_tty_state): New.
12485 (child_terminal_init): Adjust.
12486 (is_gdb_terminal, sharing_input_terminal_1)
12487 (sharing_input_terminal): New functions.
12488 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
12489 Set the process's actual process group in the foreground if
12490 possible. Handle is_ours_for_output/is_ours distinction. Don't
12491 mark terminal as the inferior's if not sharing GDB's terminal.
12492 Don't check attach_flag.
12493 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
12494 pass down a target_terminal_state.
12495 (child_terminal_save_inferior): New, factored out from ...
12496 (child_terminal_ours_1): ... this. Handle
12497 target_terminal_state::is_ours_for_output.
12498 (child_interrupt, child_pass_ctrlc): New.
12499 (inflow_inferior_exit): Clear the inferior's terminal_state.
12500 (copy_terminal_info): Copy the inferior's terminal state.
12501 (_initialize_inflow): Remove reference to terminal_is_ours.
12502 * inflow.h (inferior_process_group): Delete.
12503 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
12504 * procfs.c (procfs_target): Don't install procfs_interrupt.
12505 (procfs_interrupt): Delete.
12506 * remote.c (remote_serial_quit_handler): Adjust.
12507 (remote_interrupt): Remove ptid parameter. Adjust.
12508 * target-delegates.c: Regenerate.
12509 * target.c: Include "terminal.h".
12510 (target_terminal::terminal_state): Rename to ...
12511 (target_terminal::m_terminal_state): ... this.
12512 (target_terminal::init): Adjust.
12513 (target_terminal::inferior): Adjust to per-inferior
12514 terminal_state.
12515 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
12516 (target_terminal::ours, target_terminal::ours_for_output): Use
12517 target_terminal_is_ours_kind.
12518 (target_interrupt): Remove ptid parameter. Adjust.
12519 (default_target_pass_ctrlc): Adjust.
12520 * target.h (target_ops::to_terminal_save_inferior): New field.
12521 (target_ops::to_interrupt): Remove ptid_t parameter.
12522 (target_interrupt): Remove ptid_t parameter. Update comment.
12523 (target_pass_ctrlc): Update comment.
12524 * target/target.h (target_terminal_state): New scoped enum,
12525 factored out of ...
12526 (target_terminal::terminal_state): ... here.
12527 (target_terminal::inferior): Update comments.
12528 (target_terminal::restore_inferior): New.
12529 (target_terminal::is_inferior, target_terminal::is_ours)
12530 (target_terminal::is_ours_for_output): Adjust.
12531 (target_terminal::scoped_restore_terminal_state): Adjust to
12532 rename, and call restore_inferior() instead of inferior().
12533 (target_terminal::scoped_restore_terminal_state::m_state): Change
12534 type.
12535 (target_terminal::terminal_state): Rename to ...
12536 (target_terminal::m_terminal_state): ... this and change type.
12537
12538 2018-01-30 Pedro Alves <palves@redhat.com>
12539
12540 * linux-nat.c (wait_for_signal): New function.
12541 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
12542 directly.
12543 (async_terminal_is_ours)
12544 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
12545 (linux_nat_add_target): Don't override
12546 to_terminal_inferior/to_terminal_ours.
12547
12548 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
12549
12550 * remote.c (remote_follow_fork): Don't call "detach_inferior".
12551
12552 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
12553
12554 * dwarf2read.c (free_dwo_files): Add forward-declaration.
12555 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
12556 dwarf2_per_objfile_free here.
12557 (dwarf2_per_objfile_free): Remove.
12558 (_initialize_dwarf2_read): Don't register
12559 dwarf2_per_objfile_free as a registry cleanup.
12560
12561 2018-01-27 Eli Zaretskii <eliz@gnu.org>
12562
12563 Avoid compilation errors in MinGW native builds
12564
12565 The error is triggered by including python-internal.h, and the
12566 error message is:
12567
12568 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
12569 from build-gnulib/import/math.h:27,
12570 from d:/usr/Python26/include/pyport.h:235,
12571 from d:/usr/Python26/include/Python.h:58,
12572 from python/python-internal.h:94,
12573 from python/py-arch.c:24:
12574 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
12575 using ::hypot;
12576 ^~~~~
12577
12578 This happens because Python headers define 'hypot' to expand t
12579 '_hypot' in the Windows builds.
12580 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
12581 'hypoth'. This avoids a compilation error.
12582
12583 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12584
12585 * MAINTAINERS (Write After Approval): Fix ordering.
12586
12587 2018-01-26 Alan Hayward <alan.hayward@arm.com>
12588
12589 * MAINTAINERS (Write After Approval): Add Alan Hayward.
12590
12591 2018-01-26 Alan Modra <amodra@gmail.com>
12592
12593 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
12594 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
12595 Remove nop. Make const. Comment.
12596 (powerpc32_plt_stub_so_2): New.
12597 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
12598 Correct count. Update uses.
12599 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
12600 Move common code reading PLT entry word. Correct
12601 powerpc32_plt_stub PLT address calculation.
12602 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
12603 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
12604 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
12605 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
12606 (ppc64_standard_linkage8): Likewise.
12607 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
12608 Correct insns description.
12609 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
12610
12611 2018-01-24 Pedro Alves <palves@redhat.com>
12612
12613 GCC PR libstdc++/83906
12614 * gdbtypes.c (operator==(const dynamic_prop &,
12615 const dynamic_prop &)): New.
12616 (operator==(const range_bounds &, const range_bounds &)): New.
12617 (check_types_equal): Use them instead of memcmp.
12618 * gdbtypes.h (operator==(const dynamic_prop &,
12619 const dynamic_prop &)): Declare.
12620 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
12621 (operator==(const range_bounds &, const range_bounds &)): Declare.
12622 (operator!=(const range_bounds &, const range_bounds &)): Declare.
12623
12624 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12625
12626 * s390-linux-tdep.c (s390_record_address_mask)
12627 (s390_record_calc_disp_common, s390_record_calc_disp)
12628 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12629 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12630 (s390_process_record): Move to s390-tdep.c.
12631 (s390_linux_init_abi_any): Adjust.
12632 * s390-tdep.c (s390_record_address_mask)
12633 (s390_record_calc_disp_common, s390_record_calc_disp)
12634 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
12635 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
12636 (s390_process_record): Moved from s390-linux-tdep.c
12637 (s390_gdbarch_init): Adjust.
12638
12639 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12640
12641 * s390-linux-nat.c (s390-tdep.h): New include.
12642 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
12643 (HFILES_NO_SRCDIR): Add s390-tdep.h.
12644 (ALLDEPFILES): Add s390-tdep.c.
12645 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
12646 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
12647 * s390-tdep.h: ...this. New file.
12648 * s390-linux-tdep.c (s390-tdep.h): New include.
12649 (_initialize_s390_tdep): Rename to...
12650 (_initialize_s390_linux_tdep): ...this and adjust.
12651 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
12652 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
12653 s390-tdep.h.
12654 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
12655 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
12656 (s390_is_partial_instruction, s390_software_single_step)
12657 (is_non_branch_ril, s390_displaced_step_copy_insn)
12658 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
12659 (s390_prologue_data, s390_addr, s390_store, s390_load)
12660 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
12661 (s390_register_call_saved, s390_guess_tracepoint_registers)
12662 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
12663 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
12664 (s390_pseudo_register_name, s390_pseudo_register_type)
12665 (s390_pseudo_register_read, s390_pseudo_register_write)
12666 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
12667 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
12668 (s390_addr_bits_remove, s390_address_class_type_flags)
12669 (s390_address_class_type_flags_to_name)
12670 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
12671 (s390_function_arg_float, s390_function_arg_vector)
12672 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
12673 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
12674 (s390_frame_align, s390_register_return_value, s390_return_value)
12675 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
12676 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
12677 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
12678 (s390_trad_frame_prev_register, s390_unwind_cache)
12679 (s390_prologue_frame_unwind_cache)
12680 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
12681 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
12682 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
12683 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
12684 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
12685 (s390_frame_base_address, s390_local_base_address)
12686 (s390_frame_base, s390_gcc_target_options)
12687 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
12688 (s390_validate_reg_range, s390_tdesc_valid)
12689 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
12690 * s390-tdep.c: ...this. New file.
12691
12692 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12693
12694 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
12695 (s390_process_record, s390_gdbarch_tdep_alloc)
12696 (s390_linux_init_abi_any): Use/set new hook.
12697
12698 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12699
12700 * s390-linux-tdep.c (osabi.h): New include.
12701 (s390_linux_init_abi_31, s390_linux_init_abi_64)
12702 (s390_linux_init_abi_any): New functions.
12703 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
12704
12705 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12706
12707 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
12708 tdesc_has_registers check
12709
12710 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12711
12712 * s390-linux-tdep.c (s390_tdesc_valid): New function.
12713 (s390_validate_reg_range): New macro.
12714 (s390_gdbarch_init): Adjust.
12715
12716 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12717
12718 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
12719 (s390_gdbarch_tdep_alloc): Adjust.
12720 (s390_gdbarch_init): Adjust.
12721
12722 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12723
12724 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
12725 <have_tdb>: Change type to bool.
12726 (s390_gdbarch_tdep_alloc): Adjust.
12727 (s390_gdbarch_init): Adjust.
12728
12729 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12730
12731 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
12732 (gdbarch_tdep) <have_upper, have_vx>: New fields.
12733 (s390_gdbarch_tdep_alloc): New function.
12734 (s390_gdbarch_init): Allocate tdep at start and use its fields
12735 instead of separate variables.
12736
12737 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12738
12739 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
12740 when looking for cached gdbarch and add comment for remaining.
12741
12742 2018-01-22 Pedro Alves <palves@redhat.com>
12743 Sergio Durigan Junior <sergiodj@redhat.com>
12744
12745 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
12746 case.
12747
12748 2018-01-22 Maciej W. Rozycki <macro@mips.com>
12749
12750 * MAINTAINERS: Update my company e-mail address.
12751
12752 2018-01-22 Yao Qi <yao.qi@linaro.org>
12753
12754 * regcache.c (cooked_write_test): New function.
12755 (_initialize_regcache): Register the test.
12756
12757 2018-01-22 Yao Qi <yao.qi@linaro.org>
12758
12759 * ia64-tdep.c (ia64_pseudo_register_read): Call
12760 regcache->cooked_read instead of regcache_cooked_read_unsigned.
12761 * m32c-tdep.c (m32c_cat_read): Likewise.
12762 (m32c_r3r2r1r0_read): Likewise.
12763 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
12764 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
12765
12766 2018-01-22 Yao Qi <yao.qi@linaro.org>
12767
12768 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
12769 method raw_read instead of regcache_raw_read.
12770 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
12771 * arm-tdep.c (arm_neon_quad_read): Likewise.
12772 * avr-tdep.c (avr_pseudo_register_read): Likewise.
12773 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
12774 * frv-tdep.c (frv_pseudo_register_read): Likewise.
12775 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
12776 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
12777 (i386_pseudo_register_read_into_value): Likewise.
12778 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
12779 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
12780 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
12781 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
12782 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
12783 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
12784 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
12785 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
12786 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
12787
12788 2018-01-22 Yao Qi <yao.qi@linaro.org>
12789
12790 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
12791 * configure.tgt: Remove target mt.
12792 * mt-tdep.c: Remove.
12793 * regcache.c (cooked_read_test): Remove the check for mt.
12794
12795 2018-01-22 Yao Qi <yao.qi@linaro.org>
12796
12797 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
12798 instead of gdbarch_pseudo_register_read_value.
12799
12800 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12801
12802 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
12803 language is Ada.
12804
12805 2018-01-22 Joel Brobecker <brobecker@adacore.com>
12806
12807 * linespec.c (create_sals_line_offset): Remove code that preserved
12808 the symtab_and_line's line number.
12809
12810 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12811
12812 * varobj.c (varobj_create): Don't set valid_block when creating a
12813 floating varobj.
12814
12815 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12816
12817 * varobj.c (varobj_create): Remove out of date comment.
12818
12819 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12820
12821 PR mi/20395
12822 * ada-exp.y (write_var_from_sym): Pass extra parameter when
12823 updating innermost block.
12824 * parse.c (innermost_block_tracker::update): Take extra type
12825 parameter, and check types match before updating innermost block.
12826 (write_dollar_variable): Update innermost block for registers.
12827 * parser-defs.h (enum innermost_block_tracker_type): New enum.
12828 (innermost_block_tracker::innermost_block_tracker): Initialise
12829 m_types member.
12830 (innermost_block_tracker::reset): Take type parameter.
12831 (innermost_block_tracker::update): Take type parameter, and pass
12832 type through as needed.
12833 (innermost_block_tracker::m_types): New member.
12834 * varobj.c (varobj_create): Pass type when reseting innermost
12835 block.
12836
12837 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12838
12839 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
12840 * ada-lang.c (resolve_subexp): Likewise.
12841 * breakpoint.c (set_breakpoint_condition) Likewise.
12842 (watch_command_1) Likewise.
12843 * c-exp.y (variable): Likewise.
12844 * d-exp.y (PrimaryExpression): Likewise.
12845 * f-exp.y (variable): Likewise.
12846 * go-exp.y (variable): Likewise.
12847 * m2-exp.y (variable): Likewise.
12848 * objfiles.c (objfile::~objfile): Likewise.
12849 * p-exp.y (variable): Likewise.
12850 * parse.c (innermost_block): Change type.
12851 * parser-defs.h (class innermost_block_tracker): New.
12852 (innermost_block): Change to innermost_block_tracker.
12853 * printcmd.c (display_command): Switch to innermost_block API.
12854 (do_one_display): Likewise.
12855 * rust-exp.y (do_one_display): Likewise.
12856 * symfile.c (clear_symtab_users): Likewise.
12857 * varobj.c (varobj_create): Switch to innermost_block API, replace
12858 use of innermost_block with block stored on varobj object.
12859
12860 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
12861
12862 * expression.h (innermost_block): Remove declaration.
12863 * varobj.c: Add 'parser-defs.h' include.
12864
12865 2018-01-19 Tom Tromey <tom@tromey.com>
12866
12867 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
12868 symbols in the static and global blocks.
12869
12870 2018-01-19 James Clarke <jrtc27@jrtc27.com>
12871
12872 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
12873 gdb_ptrace.h, and move including gdb_wait.h ...
12874 * nat/linux-ptrace.h: ... to here.
12875
12876 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12877
12878 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
12879 inf_ptrace_detach_success.
12880 (inf_ptrace_detach_success): Add inferior parameter, use it
12881 instead of inferior_ptid, pass it to detach_inferior.
12882 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
12883 parameter.
12884 * inferior.c (detach_inferior): Add overload that takes an
12885 inferior object.
12886 * inferior.h (detach_inferior): Likewise.
12887 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
12888 use inferior_ptid, adjust call to inf_ptrace_detach_success.
12889 * linux-thread-db.c (thread_db_detach): Use inf parameter.
12890
12891 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12892
12893 * target.h (struct target_ops) <to_detach>: Add inferior
12894 parameter.
12895 (target_detach): Likewise.
12896 * target.c (dispose_inferior): Pass inferior down.
12897 (target_detach): Pass inferior down. Assert that it is equal to
12898 the current inferior.
12899 * aix-thread.c (aix_thread_detach): Pass inferior down.
12900 * corefile.c (core_file_command): Pass current_inferior() down.
12901 * corelow.c (core_detach): Add inferior parameter.
12902 * darwin-nat.c (darwin_detach): Likewise.
12903 * gnu-nat.c (gnu_detach): Likewise.
12904 * inf-ptrace.c (inf_ptrace_detach): Likewise.
12905 * infcmd.c (detach_command): Pass current_inferior() down to
12906 target_detach.
12907 * infrun.c (follow_fork_inferior): Pass parent_inf to
12908 target_detach.
12909 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
12910 target_detach.
12911 * linux-nat.c (linux_nat_detach): Add inferior parameter.
12912 * linux-thread-db.c (thread_db_detach): Likewise.
12913 * nto-procfs.c (procfs_detach): Likewise.
12914 * procfs.c (procfs_detach): Likewise.
12915 * record.c (record_detach): Likewise.
12916 * record.h (struct inferior): Forward-declare.
12917 (record_detach): Add inferior parameter.
12918 * remote-sim.c (gdbsim_detach): Likewise.
12919 * remote.c (remote_detach_1): Likewise.
12920 (remote_detach): Likewise.
12921 (extended_remote_detach): Likewise.
12922 * sol-thread.c (sol_thread_detach): Likewise.
12923 * target-debug.h (target_debug_print_inferior_p): New macro.
12924 * target-delegates.c: Re-generate.
12925 * top.c (kill_or_detach): Pass inferior down to target_detach.
12926 * windows-nat.c (windows_detach): Add inferior parameter.
12927
12928 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
12929
12930 * target.h (struct target_ops) <to_detach>: Remove args
12931 parameter.
12932 (target_detach): Likewise.
12933 * target.c (dispose_inferior): Adjust.
12934 (target_detach): Remove args parameter, adjust.
12935 * aix-thread.c (aix_thread_detach): Adjust.
12936 * corefile.c (core_file_command): Adjust.
12937 * corelow.c (core_detach): Adjust.
12938 * darwin-nat.c (darwin_detach): Adjust.
12939 * gnu-nat.c (gnu_detach): Adjust.
12940 * inf-ptrace.c (inf_ptrace_detach): Adjust.
12941 * infcmd.c (detach_command): Adjust
12942 * infrun.c (follow_fork_inferior): Adjust.
12943 (handle_vfork_child_exec_or_exit): Adjust.
12944 * linux-fork.c (linux_fork_detach): Remove args parameter.
12945 * linux-fork.h (linux_fork_detach): Likewise.
12946 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
12947 * linux-thread-db.c (thread_db_detach): Likewise.
12948 * nto-procfs.c (procfs_detach): Likewise.
12949 * procfs.c (procfs_detach): Likewise.
12950 (do_detach): Remove signo parameter.
12951 * record.c (record_detach): Remove args parameter.
12952 * record.h (record_detach): Likewise.
12953 * remote-sim.c (gdbsim_detach): Likewise.
12954 * remote.c (remote_detach_1): Likewise.
12955 (remote_detach): Likewise.
12956 (extended_remote_detach): Likewise.
12957 * sol-thread.c (sol_thread_detach): Likewise.
12958 * target-delegates.c: Re-generate.
12959 * top.c (struct qt_args) <args>: Remove field.
12960 (kill_or_detach): Don't pass args.
12961 (quit_force): Don't set args.
12962 * windows-nat.c (windows_detach): Remove args parameter.
12963
12964 2018-01-19 Yao Qi <yao.qi@linaro.org>
12965
12966 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
12967 (arm_linux_init_abi): Install it.
12968
12969 2018-01-19 Yao Qi <yao.qi@linaro.org>
12970
12971 * osabi.c (gdb_osabi_names): Extend the regexp for
12972 arm-linux-gnueabihf.
12973
12974 2018-01-18 Yao Qi <yao.qi@linaro.org>
12975
12976 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
12977 m_abbrevs.
12978 (abbrev_table::add_abbrev): Update.
12979 (abbrev_table::lookup_abbrev): Update.
12980
12981 2018-01-18 Yao Qi <yao.qi@linaro.org>
12982
12983 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
12984
12985 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
12986
12987 * compile/compile.c (compile_to_object): Convert "triplet_rx"
12988 to "std::string".
12989
12990 2018-01-17 Tom Tromey <tom@tromey.com>
12991
12992 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
12993
12994 2018-01-17 Tom Tromey <tom@tromey.com>
12995
12996 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
12997 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
12998 (create_array_type_with_stride): Update.
12999 * dwarf2read.c (set_die_type): Update.
13000
13001 2018-01-17 Tom Tromey <tom@tromey.com>
13002
13003 * dwarf2read.c (delayed_method_info): Remove typedef.
13004 (dwarf2_cu::method_info): Now a std::vector.
13005 (add_to_method_list): Update.
13006 (free_delayed_list): Remove.
13007 (compute_delayed_physnames): Update.
13008 (process_full_comp_unit, process_full_type_unit): Clear the method
13009 list. Remove cleanups.
13010 (psymtab_include_file_name): Add name_holder parameter. Use
13011 unique_xmalloc_ptr.
13012 (dwarf_decode_lines): Update.
13013
13014 2018-01-17 Tom Tromey <tom@tromey.com>
13015 Simon Marchi <simon.marchi@ericsson.com>
13016
13017 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
13018 (dwarf2_per_objfile::free_cached_comp_units)
13019 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13020 (init_cutu_and_read_dies_no_follow): Update.
13021 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
13022 (dwarf2_cu::~dwarf2_cu): New.
13023 (free_heap_comp_unit, free_stack_comp_unit): Remove.
13024 (age_cached_comp_units, free_one_cached_comp_unit): Update.
13025
13026 2018-01-17 Tom Tromey <tom@tromey.com>
13027 Simon Marchi <simon.marchi@ericsson.com>
13028
13029 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
13030 (struct die_reader_specs) <abbrev_table>: New member.
13031 (struct abbrev_table): Add constructor.
13032 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
13033 <abbrev_obstack>: Now an auto_obstack.
13034 (abbrev_table_up): New typedef.
13035 (init_cu_die_reader): Add abbrev_table parameter.
13036 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
13037 Add result_dwo_abbrev_table.
13038 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
13039 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
13040 Update.
13041 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
13042 parameter.
13043 (skip_children): Update.
13044 (abbrev_table::alloc_abbrev): Rename from
13045 abbrev_table_alloc_abbrev.
13046 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
13047 (abbrev_table::lookup_abbrev): Rename from
13048 abbrev_table_lookup_abbrev.
13049 (abbrev_table_read_table): Return abbrev_table_up.
13050 (abbrev_table_free, abbrev_table_free_cleanup)
13051 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
13052 (load_partial_dies): Update.
13053
13054 2018-01-17 Tom Tromey <tom@tromey.com>
13055
13056 * dwarf2read.c (dwarf2_compute_name): Update comment.
13057 (read_func_scope, read_variable): Update.
13058 (new_symbol): Remove.
13059 (new_symbol_full): Rename to new_symbol.
13060
13061 2018-01-17 Mike Gulick <mgulick@mathworks.com>
13062
13063 PR gdb/16577
13064 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
13065 a warning instead of throwing an error, set section size to 0 and return
13066 NULL.
13067 * gdb_bfd.h (gdb_bfd_map_section): Update description.
13068
13069 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13070
13071 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
13072 std::string.
13073 (linux_ptrace_attach_fail_reason_string): Likewise.
13074 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
13075 Likewise.
13076 (linux_ptrace_attach_fail_reason_string): Likewise.
13077 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
13078
13079 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
13080
13081 * linux-nat.c (linux_nat_attach): Remove xstrdup.
13082
13083 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
13084
13085 PR gdb/21559
13086 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
13087 checking for fs_base/gs_base fields in struct user_regs_struct.
13088 * configure: Regenerate.
13089
13090 2018-01-17 Yao Qi <yao.qi@linaro.org>
13091
13092 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
13093 function.
13094 (aarch64_linux_init_abi): Install it to gdbarch hook
13095 gcc_target_options.
13096
13097 2018-01-15 Pedro Alves <palves@redhat.com>
13098
13099 * common/signals-state-save-restore.c
13100 (save_original_signals_state): Fix typos.
13101
13102 2017-01-12 Tom Tromey <tom@tromey.com>
13103 Sergio Durigan Junior <sergiodj@redhat.com>
13104
13105 * Makefile.in (install-only): Install gdb-add-index.
13106
13107 2018-01-12 John Baldwin <jhb@FreeBSD.org>
13108
13109 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
13110
13111 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
13112
13113 * infrun.c (keep_going_pass_signal): Clear step-over info when
13114 insert_breakpoints fails.
13115
13116 2018-01-11 Pedro Alves <palves@redhat.com>
13117
13118 PR gdb/22583
13119 * infrun.c (resume): Rename to ...
13120 (resume_1): ... this.
13121 (resume): Reimplement as wrapper around resume_1.
13122
13123 2018-01-11 Pedro Alves <palves@redhat.com>
13124
13125 PR remote/22597
13126 * remote.c (remote_parse_stop_reply): Default to the last-set
13127 general thread instead of to 'magic_null_ptid'.
13128
13129 2018-01-10 Pedro Alves <palves@redhat.com>
13130
13131 * language.h (language_get_symbol_name_matcher): Rename ...
13132 (get_symbol_name_matcher): ... this.
13133 * language.c (language_get_symbol_name_matcher): Ditto.
13134 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
13135 callers adjusted.
13136
13137 2018-01-10 Pedro Alves <palves@redhat.com>
13138
13139 PR gdb/22670
13140 * dwarf2read.c
13141 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
13142 Adjust to use language_get_symbol_name_matcher instead of
13143 language_defn::la_get_symbol_name_matcher.
13144 * language.c (language_get_symbol_name_matcher): If in Ada mode
13145 and the lookup name is a verbatim match, return Ada's matcher.
13146 * language.h (language_get_symbol_name_matcher): Adjust comment.
13147 (ada_lookup_name_info::verbatim_p):: New method.
13148
13149 2018-01-10 Pedro Alves <palves@redhat.com>
13150
13151 PR gdb/22670
13152 * ada-lang.c (ada_collect_symbol_completion_matches): If the
13153 minsym's language is language_auto or language_cplus, pass down
13154 language_ada instead.
13155 * symtab.c (compare_symbol_name): Don't frob symbol language here.
13156
13157 2018-01-10 Pedro Alves <palves@redhat.com>
13158
13159 PR gdb/22670
13160 * minsyms.c (linkage_name_str): New function.
13161 (iterate_over_minimal_symbols): Use it.
13162
13163 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13164
13165 * NEWS: Document that 'info proc' now works on FreeBSD.
13166
13167 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13168
13169 * configure.ac: Check for kinfo_getfile in libutil.
13170 * configure: Regenerate.
13171 * config.in: Regenerate.
13172 * fbsd-nat.c: Include "fbsd-tdep.h".
13173 (fbsd_fetch_cmdline): New.
13174 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
13175 rather than calling error.
13176 (fbsd_info_proc): New.
13177 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
13178 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
13179 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
13180
13181 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13182
13183 * fbsd-nat.c (struct free_deleter): Remove.
13184 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
13185
13186 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13187
13188 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
13189 NULL for an empty pathname.
13190
13191 2018-01-09 John Baldwin <jhb@FreeBSD.org>
13192
13193 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
13194 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
13195 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
13196 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
13197 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
13198 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
13199 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
13200 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
13201 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
13202 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
13203 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
13204 (fbsd_core_fetch_timeval, fbsd_print_sigset)
13205 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
13206 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
13207 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
13208
13209 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
13210
13211 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
13212 (gnu_xfer_auxv): New function.
13213 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
13214 TARGET_OBJECT_AUXV.
13215
13216 2018-01-08 Yao Qi <yao.qi@linaro.org>
13217 Simon Marchi <simon.marchi@ericsson.com>
13218
13219 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
13220 common/selftest.c.
13221 (COMMON_OBS): Remove selftest.o.
13222 * configure.ac: Append selftest-arch.c and common/selftest.c to
13223 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
13224 * configure: Re-generated.
13225 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
13226 GDB_SELF_TEST.
13227 (maintenance_info_selftests): Likewise.
13228
13229 2018-01-08 Xavier Roirand <roirand@adacore.com>
13230
13231 * ada-valprint.c (val_print_packed_array_elements): Use
13232 proper number of elements when printing an array indexed
13233 by an enumeration type.
13234
13235 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13236
13237 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
13238 (dw2_get_file_names_reader): Adjust.
13239 (lookup_dwo_signatured_type): Adjust.
13240 (lookup_dwp_signatured_type): Adjust.
13241 (lookup_signatured_type): Adjust.
13242 (create_type_unit_group): Adjust.
13243 (get_type_unit_group): Adjust.
13244 (process_psymtab_comp_unit_reader): Adjust.
13245 (build_type_psymtabs_reader): Adjust.
13246 (scan_partial_symbols): Adjust.
13247 (add_partial_symbol): Adjust.
13248 (add_partial_subprogram): Adjust.
13249 (peek_die_abbrev): Adjust.
13250 (fixup_go_packaging): Adjust.
13251 (process_imported_unit_die): Adjust.
13252 (dwarf2_compute_name): Adjust.
13253 (dwarf2_physname): Adjust.
13254 (read_import_statement): Adjust.
13255 (handle_DW_AT_stmt_list): Adjust.
13256 (read_file_scope): Adjust.
13257 (read_func_scope): Adjust.
13258 (read_lexical_block_scope): Adjust.
13259 (read_call_site_scope): Adjust.
13260 (read_variable): Adjust.
13261 (dwarf2_rnglists_process): Adjust.
13262 (dwarf2_ranges_process): Adjust.
13263 (dwarf2_ranges_read): Adjust.
13264 (dwarf2_get_pc_bounds): Adjust.
13265 (dwarf2_record_block_ranges): Adjust.
13266 (dwarf2_add_field): Adjust.
13267 (dwarf2_add_member_fn): Adjust.
13268 (read_structure_type): Adjust.
13269 (process_structure_scope): Adjust.
13270 (read_enumeration_type): Adjust.
13271 (read_array_type): Adjust.
13272 (mark_common_block_symbol_computed): Adjust.
13273 (read_common_block): Adjust.
13274 (read_namespace_type): Adjust.
13275 (read_namespace): Adjust.
13276 (read_module_type): Adjust.
13277 (read_tag_pointer_type): Adjust.
13278 (read_tag_ptr_to_member_type): Adjust.
13279 (read_tag_string_type): Adjust.
13280 (read_subroutine_type): Adjust.
13281 (read_typedef): Adjust.
13282 (read_base_type): Adjust.
13283 (attr_to_dynamic_prop): Adjust.
13284 (read_subrange_type): Adjust.
13285 (read_unspecified_type): Adjust.
13286 (dwarf2_read_abbrevs): Adjust.
13287 (load_partial_dies): Adjust.
13288 (read_partial_die): Adjust.
13289 (find_partial_die): Adjust.
13290 (guess_partial_die_structure_name): Adjust.
13291 (fixup_partial_die): Adjust.
13292 (read_attribute_value): Adjust.
13293 (read_addr_index): Adjust.
13294 (read_addr_index_from_leb128): Adjust.
13295 (read_str_index): Adjust.
13296 (dwarf2_string_attr): Adjust.
13297 (get_debug_line_section): Adjust.
13298 (dwarf_decode_line_header): Adjust.
13299 (lnp_state_machine::check_line_address): Adjust.
13300 (dwarf_decode_lines_1): Adjust.
13301 (dwarf_decode_lines): Adjust.
13302 (dwarf2_start_symtab): Adjust.
13303 (var_decode_location): Adjust.
13304 (new_symbol_full): Adjust.
13305 (dwarf2_const_value_data): Adjust.
13306 (dwarf2_const_value_attr): Adjust.
13307 (dwarf2_const_value): Adjust.
13308 (die_type): Adjust.
13309 (die_containing_type): Adjust.
13310 (build_error_marker_type): Adjust.
13311 (lookup_die_type): Adjust.
13312 (guess_full_die_structure_name): Adjust.
13313 (anonymous_struct_prefix): Adjust.
13314 (determine_prefix): Adjust.
13315 (dwarf2_name): Adjust.
13316 (follow_die_ref_or_sig): Adjust.
13317 (follow_die_offset): Adjust.
13318 (follow_die_ref): Adjust.
13319 (follow_die_sig_1): Adjust.
13320 (follow_die_sig): Adjust.
13321 (get_signatured_type): Adjust.
13322 (get_DW_AT_signature_type): Adjust.
13323 (decode_locdesc): Adjust.
13324 (dwarf_decode_macros): Adjust.
13325 (cu_debug_loc_section): Adjust.
13326 (fill_in_loclist_baton): Adjust.
13327 (dwarf2_symbol_mark_computed): Adjust.
13328 (init_one_comp_unit): Don't assign
13329 dwarf2_cu::dwarf2_per_objfile.
13330 (set_die_type): Adjust.
13331
13332 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13333
13334 * dwarf2read.c (struct mapped_debug_names): Add constructor.
13335 <dwarf2_per_objfile>: New field.
13336 (dwarf2_per_objfile): Remove global.
13337 (get_dwarf2_per_objfile): New function.
13338 (set_dwarf2_per_objfile): New function.
13339 (dwarf2_build_psymtabs_hard): Change objfile parameter to
13340 dwarf2_per_objfile.
13341 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13342 (read_abbrev_offset): Likewise.
13343 (read_indirect_string): Likewise.
13344 (read_indirect_line_string): Likewise.
13345 (read_indirect_string_at_offset): Likewise.
13346 (read_indirect_string_from_dwz): Likewise.
13347 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13348 dwarf2_per_objfile.
13349 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13350 (create_all_comp_units): Change objfile parameter to
13351 dwarf2_per_objfile.
13352 (create_all_type_units): Likewise.
13353 (process_queue): Add dwarf2_per_objfile parameter.
13354 (read_and_check_comp_unit_head): Likewise.
13355 (lookup_dwo_unit_in_dwp): Likewise.
13356 (get_dwp_file): Likewise.
13357 (process_cu_includes): Likewise.
13358 (struct free_dwo_file_cleanup_data): New struct.
13359 (dwarf2_has_info): Use get_dwarf2_per_objfile and
13360 set_dwarf2_per_objfile.
13361 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
13362 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
13363 context, adjust calls.
13364 (dw2_instantiate_symtab): Likewise.
13365 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
13366 (dw2_get_cu): Likewise.
13367 (create_cu_from_index_list): Change objfile parameter to
13368 dwarf2_per_objfile.
13369 (create_cus_from_index_list): Get dwarf2_per_objfile from
13370 context, adjust calls.
13371 (create_cus_from_index): Likewise.
13372 (create_signatured_type_table_from_index): Change objfile
13373 parameter to dwarf2_per_objfile.
13374 (create_signatured_type_table_from_debug_names): Change objfile
13375 parameter to dwarf2_per_objfile.
13376 (create_addrmap_from_index): Likewise.
13377 (create_addrmap_from_aranges): Likewise.
13378 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
13379 (dw2_setup): Remove.
13380 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
13381 context.
13382 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
13383 get_dwarf2_per_objfile.
13384 (dw2_forget_cached_source_info): Likewise.
13385 (dw2_map_symtabs_matching_filename): Likewise.
13386 (struct dw2_symtab_iterator) <index>: Remove.
13387 <dwarf2_per_objfile>: New field.
13388 (dw2_symtab_iter_init): Replace index parameter with
13389 dwarf2_per_objfile.
13390 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
13391 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
13392 (dw2_print_stats): Likewise.
13393 (dw2_dump): Likewise.
13394 (dw2_expand_symtabs_for_function): Likewise.
13395 (dw2_expand_all_symtabs): Likewise.
13396 (dw2_expand_symtabs_with_fullname): Likewise.
13397 (dw2_expand_marked_cus): Replace index and objfile parameters
13398 with dwarf2_per_objfile.
13399 (dw_expand_symtabs_matching_file_matcher): Add
13400 dwarf2_per_objfile parameter and adjust calls.
13401 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
13402 adjust calls.
13403 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
13404 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
13405 adjust calls.
13406 (create_cus_from_debug_names_list): Replace objfile parameter
13407 with dwarf2_per_objfile and adjust calls.
13408 (create_cus_from_debug_names): Likewise.
13409 (dwarf2_read_debug_names): Likewise.
13410 (mapped_debug_names::namei_to_name): Adjust call.
13411 (dw2_debug_names_iterator::next): Likewise.
13412 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
13413 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
13414 (dw2_debug_names_dump): Likewise.
13415 (dw2_debug_names_expand_symtabs_for_function): Likewise.
13416 (dw2_debug_names_expand_symtabs_matching): Likewise.
13417 (dwarf2_initialize_objfile): Likewise.
13418 (dwarf2_build_psymtabs): Likewise.
13419 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
13420 this_cu.
13421 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
13422 (read_and_check_comp_unit_head): Likewise.
13423 (read_abbrev_offset): Likewise.
13424 (create_debug_type_hash_table): Likewise.
13425 (create_debug_types_hash_table): Likewise.
13426 (create_all_type_units): Replace objfile parameter with
13427 dwarf2_per_objfile.
13428 (add_type_unit): Add dwarf2_per_objfile parameter.
13429 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
13430 with dwarf2_per_objfile.
13431 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
13432 (lookup_dwp_signatured_type): Likewise.
13433 (lookup_signatured_type): Likewise.
13434 (read_cutu_die_from_dwo): Likewise.
13435 (init_tu_and_read_dwo_dies): Likewise.
13436 (init_cutu_and_read_dies): Likewise.
13437 (init_cutu_and_read_dies_no_follow): Likewise.
13438 (allocate_type_unit_groups_table): Add objfile parameter.
13439 (create_type_unit_group): Use dwarf2_per_objfile from cu.
13440 (get_type_unit_group): Likewise.
13441 (process_psymtab_comp_unit): Update call.
13442 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
13443 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
13444 (print_tu_stats): Likewise.
13445 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
13446 in void* parameter.
13447 (build_type_psymtabs): Change objfile parameter to
13448 dwarf2_per_objfile.
13449 (process_skeletonless_type_unit): Use dwarf2_per_objfile
13450 passed in void* parameter.
13451 (process_skeletonless_type_units): Change objfile parameter to
13452 dwarf2_per_objfile.
13453 (set_partial_user): Likewise.
13454 (dwarf2_build_psymtabs_hard): Likewise.
13455 (read_comp_units_from_section): Likewise.
13456 (create_all_comp_units): Likewise.
13457 (scan_partial_symbols): Update calls.
13458 (add_partial_symbol): Likewise.
13459 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
13460 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
13461 (process_queue): Add dwarf2_per_objfile parameter.
13462 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
13463 (compute_compunit_symtab_includes): Likewise.
13464 (process_cu_includes): Add dwarf2_per_objfile parameter.
13465 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
13466 (process_full_type_unit): Likewise.
13467 (process_imported_unit_die): Update call.
13468 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
13469 (read_file_scope): Likewise.
13470 (allocate_dwo_file_hash_table): Add objfile parameter.
13471 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
13472 (create_cus_hash_table): Likewise.
13473 (create_dwp_hash_table): Likewise.
13474 (create_dwo_unit_in_dwp_v1): Likewise.
13475 (create_dwp_v2_section): Likewise.
13476 (create_dwo_unit_in_dwp_v2): Likewise.
13477 (lookup_dwo_unit_in_dwp): Likewise.
13478 (try_open_dwop_file): Likewise.
13479 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
13480 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
13481 cleanup to include a reference to dwarf2_per_objfile.
13482 (open_dwp_file): Add dwarf2_per_objfile parameter.
13483 (open_and_init_dwp_file): Likewise.
13484 (get_dwp_file): Likewise.
13485 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
13486 (queue_and_load_all_dwo_tus): Update call.
13487 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
13488 data.
13489 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
13490 (dwarf2_ranges_process): Likewise.
13491 (dwarf2_get_pc_bounds): Likewise.
13492 (mark_common_block_symbol_computed): Likewise.
13493 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
13494 (dwarf2_read_abbrevs): Update call.
13495 (read_partial_die): Use dwarf2_per_objfile from cu.
13496 (find_partial_die): Likewise.
13497 (fixup_partial_die): Likewise.
13498 (read_attribute_value): Likewise.
13499 (read_indirect_string_at_offset_from): Add objfile parameter.
13500 (read_indirect_string_at_offset): Add dwarf2_per_objfile
13501 parameter.
13502 (read_indirect_string_from_dwz): Add objfile parameter.
13503 (read_indirect_string): Add objfile parameter.
13504 (read_addr_index_1): Add dwarf2_per_objfile parameter.
13505 (read_addr_index): Use dwarf2_per_objfile from cu.
13506 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
13507 call dw2_setup.
13508 (read_str_index): Use dwarf2_per_objfile from cu.
13509 (get_debug_line_section): Likewise.
13510 (read_formatted_entries): Add dwarf2_per_objfile parameter.
13511 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
13512 (new_symbol_full): Use dwarf2_per_objfile from cu.
13513 (build_error_marker_type): Likewise.
13514 (lookup_die_type): Likewise.
13515 (determine_prefix): Likewise.
13516 (follow_die_offset): Likewise.
13517 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
13518 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
13519 (dwarf2_fetch_die_type_sect_off): Likewise.
13520 (dwarf2_get_die_type): Likewise.
13521 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
13522 (get_signatured_type): Likewise.
13523 (get_DW_AT_signature_type): Likewise.
13524 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
13525 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
13526 (cu_debug_loc_section): Likewise.
13527 (fill_in_loclist_baton): Likewise.
13528 (dwarf2_symbol_mark_computed): Likewise.
13529 (dwarf2_find_containing_comp_unit): Change objfile parameter to
13530 dwarf2_per_objfile.
13531 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
13532 parameter.
13533 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
13534 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
13535 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
13536 (set_die_type): Use dwarf2_free_objfile from cu.
13537 (get_die_type_at_offset): Likewise.
13538 (dwarf2_per_objfile_free): Don't assign global variable.
13539 (debug_names) <constructor>: Add dwarf2_per_objfile
13540 parameter, update m_debugstrlookup construction.
13541 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
13542 parameter.
13543 <m_dwarf2_per_objfile>: New field.
13544 <lookup>: Use m_dwarf2_per_objfile.
13545 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
13546 (psyms_seen_size): Likewise.
13547 (write_gdbindex): Replace objfile parameter with
13548 dwarf2_per_objfile.
13549 (write_debug_names): Likewise.
13550 (write_psymtabs_to_index): Likewise.
13551 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
13552 calls.
13553
13554 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13555
13556 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
13557 <dwarf2_per_objfile>: New field.
13558 (struct dwarf2_per_cu_data) <objfile>: Remove.
13559 <dwarf2_per_objfile>: New field.
13560 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
13561 of objfile.
13562 (create_signatured_type_table_from_index): Likewise.
13563 (create_debug_type_hash_table): Likewise.
13564 (fill_in_sig_entry_from_dwo_entry): Likewise.
13565 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
13566 (create_type_unit_group): Assign dwarf2_per_objfile instead of
13567 objfile.
13568 (create_partial_symtab): Access objfile through
13569 dwarf2_per_objfile.
13570 (process_psymtab_comp_unit_reader): Likewise.
13571 (read_comp_units_from_section): Likewise.
13572 (scan_partial_symbols): Likewise.
13573 (add_partial_symbol): Likewise.
13574 (add_partial_subprogram): Likewise.
13575 (peek_die_abbrev): Likewise.
13576 (fixup_go_packaging): Likewise.
13577 (process_full_comp_unit): Likewise.
13578 (process_full_type_unit): Likewise.
13579 (process_imported_unit_die): Likewise.
13580 (dwarf2_compute_name): Likewise.
13581 (dwarf2_physname): Likewise.
13582 (read_import_statement): Likewise.
13583 (create_cus_hash_table): Assign dwarf2_physname instead of
13584 objfile.
13585 (read_func_scope): Access objfile through dwarf2_per_objfile.
13586 (read_lexical_block_scope): Likewise.
13587 (read_call_site_scope): Likewise.
13588 (read_variable): Likewise.
13589 (dwarf2_rnglists_process): Likewise.
13590 (dwarf2_ranges_process): Likewise.
13591 (dwarf2_ranges_read): Likewise.
13592 (dwarf2_record_block_ranges): Likewise.
13593 (dwarf2_add_field): Likewise.
13594 (dwarf2_add_member_fn): Likewise.
13595 (read_structure_type): Likewise.
13596 (process_structure_scope): Likewise.
13597 (read_enumeration_type): Likewise.
13598 (read_array_type): Likewise.
13599 (read_common_block): Likewise.
13600 (read_namespace_type): Likewise.
13601 (read_namespace): Likewise.
13602 (read_module_type): Likewise.
13603 (read_tag_pointer_type): Likewise.
13604 (read_tag_ptr_to_member_type): Likewise.
13605 (read_tag_string_type): Likewise.
13606 (read_subroutine_type): Likewise.
13607 (read_typedef): Likewise.
13608 (read_base_type): Likewise.
13609 (attr_to_dynamic_prop): Likewise.
13610 (read_subrange_type): Likewise.
13611 (read_unspecified_type): Likewise.
13612 (load_partial_dies): Likewise.
13613 (read_partial_die): Likewise.
13614 (find_partial_die): Likewise.
13615 (guess_partial_die_structure_name): Likewise.
13616 (fixup_partial_die): Likewise.
13617 (read_attribute_value): Likewise.
13618 (read_addr_index_from_leb128): Likewise.
13619 (dwarf2_read_addr_index): Likewise.
13620 (dwarf2_string_attr): Likewise.
13621 (lnp_state_machine::check_line_address): Likewise.
13622 (dwarf_decode_lines_1): Likewise.
13623 (dwarf_decode_lines): Likewise.
13624 (dwarf2_start_symtab): Likewise.
13625 (var_decode_location): Likewise.
13626 (new_symbol_full): Likewise.
13627 (dwarf2_const_value_data): Likewise.
13628 (dwarf2_const_value_attr): Likewise.
13629 (dwarf2_const_value): Likewise.
13630 (die_type): Likewise.
13631 (die_containing_type): Likewise.
13632 (lookup_die_type): Likewise.
13633 (guess_full_die_structure_name): Likewise.
13634 (anonymous_struct_prefix): Likewise.
13635 (dwarf2_name): Likewise.
13636 (follow_die_ref_or_sig): Likewise.
13637 (follow_die_offset): Likewise.
13638 (follow_die_ref): Likewise.
13639 (dwarf2_fetch_die_loc_sect_off): Likewise.
13640 (dwarf2_fetch_constant_bytes): Likewise.
13641 (dwarf2_fetch_die_type_sect_off): Likewise.
13642 (dwarf2_get_die_type): Likewise.
13643 (follow_die_sig): Likewise.
13644 (decode_locdesc): Likewise.
13645 (dwarf2_per_cu_objfile): Likewise.
13646 (dwarf2_per_cu_text_offset): Likewise.
13647 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
13648 objfile.
13649 (set_die_type): Access objfile through
13650 dwarf2_per_objfile.
13651
13652 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
13653
13654 * valprint.c (converted_character_d): Remove typedef.
13655 (DEF_VEC_O (converted_character_d)): Remove.
13656 (count_next_character): Use std::vector.
13657 (print_converted_chars_to_obstack): Likewise.
13658 (generic_printstr): Likewise.
13659
13660 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13661
13662 * xml-support.h (struct gdb_xml_value): Add constructor.
13663 <value>: Change type to unique_xmalloc_ptr.
13664 (gdb_xml_value_s): Remove typedef.
13665 (DEF_VEC_O (gdb_xml_value_s)): Remove.
13666 (gdb_xml_element_start_handler): Change parameter type to
13667 std::vector.
13668 (xml_find_attribute): Likewise.
13669 * xml-support.c (xml_find_attribute): Change parameter type to
13670 std::vector and adjust.
13671 (gdb_xml_values_cleanup): Remove.
13672 (gdb_xml_parser::start_element): Adjust to std::vector.
13673 (xinclude_start_include): Change paraeter type to std::vector
13674 and adjust.
13675 * btrace.c (check_xml_btrace_version): Likewise.
13676 (parse_xml_btrace_block): Likewise.
13677 (parse_xml_btrace_pt_config_cpu): Likewise.
13678 (parse_xml_btrace_pt): Likewise.
13679 (parse_xml_btrace_conf_bts): Likewise.
13680 (parse_xml_btrace_conf_pt): Likewise.
13681 * memory-map.c (memory_map_start_memory): Likewise.
13682 (memory_map_start_property): Likewise.
13683 * osdata.c (osdata_start_osdata): Likewise.
13684 (osdata_start_item): Likewise.
13685 (osdata_start_column): Likewise.
13686 * remote.c (start_thread): Likewise.
13687 * solib-aix.c (library_list_start_library): Likewise.
13688 (library_list_start_list): Likewise.
13689 * solib-svr4.c (library_list_start_library): Likewise.
13690 (svr4_library_list_start_list): Likewise.
13691 * solib-target.c (library_list_start_segment): Likewise.
13692 (library_list_start_section): Likewise.
13693 (library_list_start_library): Likewise.
13694 (library_list_start_list): Likewise.
13695 * tracepoint.c (traceframe_info_start_memory): Likewise.
13696 (traceframe_info_start_tvar): Likewise.
13697 * xml-syscall.c (syscall_start_syscall): Likewise.
13698 * xml-tdesc.c (tdesc_start_target): Likewise.
13699 (tdesc_start_feature): Likewise.
13700 (tdesc_start_reg): Likewise.
13701 (tdesc_start_union): Likewise.
13702 (tdesc_start_struct): Likewise.
13703 (tdesc_start_flags): Likewise.
13704 (tdesc_start_enum): Likewise.
13705 (tdesc_start_field): Likewise.
13706 (tdesc_start_enum_value): Likewise.
13707 (tdesc_start_vector): Likewise.
13708
13709 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13710
13711 * extension.h (struct xmethod_worker) <clone>: Remove.
13712 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
13713 Remove.
13714 (python_xmethod_worker::clone): Remove.
13715 * valops.c (find_overload_match): Use std::move instead of
13716 clone.
13717
13718 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
13719
13720 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
13721 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
13722 <free_xmethod_worker_data>: Remove.
13723 <get_matching_xmethod_workers>: Chance VEC to std::vector.
13724 <get_xmethod_arg_types>: Remove.
13725 <get_xmethod_result_type>: Remove.
13726 <invoke_xmethod>: Remove.
13727 * extension.c (new_xmethod_worker): Remove.
13728 (clone_xmethod_worker): Remove.
13729 (get_matching_xmethod_workers): Return void, pass std::vector by
13730 pointer.
13731 (get_xmethod_arg_types): Rename to...
13732 (xmethod_worker::get_arg_types): ... this, and adjust.
13733 (get_xmethod_result_type): Rename to...
13734 (xmethod_worker::get_result_type): ... this, and adjust.
13735 (invoke_xmethod): Remove.
13736 (free_xmethod_worker): Remove.
13737 (free_xmethod_worker_vec): Remove.
13738 * extension.h (enum ext_lang_rc): Move here from
13739 extension-priv.h.
13740 (struct xmethod_worker): Add constructor and destructor.
13741 <data>: Remove.
13742 <value>: Remove.
13743 <invoke, clone, do_get_result_type, do_get_arg_types>: New
13744 virtual pure methods.
13745 <get_arg_types, get_result_type>: New methods.
13746 (xmethod_worker_ptr): Remove typedef.
13747 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
13748 (xmethod_worker_vec): Remove typedef.
13749 (xmethod_worker_up): New typedef.
13750 (invoke_xmethod): Remove.
13751 (clone_xmethod_worker): Remove.
13752 (free_xmethod_worker): Remove.
13753 (free_xmethod_worker_vec): Remove.
13754 (get_xmethod_arg_types): Remove.
13755 (get_xmethod_result_type): Remove.
13756 * valops.c (find_method_list): Use std::vector, don't use
13757 intermediate vector.
13758 (value_find_oload_method_list): Use std::vector.
13759 (find_overload_match): Use std::vector.
13760 (find_oload_champ): Use std::vector.
13761 * value.c (value_free): Use operator delete.
13762 (value_of_xmethod): Rename to...
13763 (value_from_xmethod): ... this. Don't assign
13764 xmethod_worker::value, take rvalue-reference.
13765 (result_type_of_xmethod): Adjust.
13766 (call_xmethod): Adjust.
13767 * value.h: Include extension.h.
13768 (struct xmethod_worker): Don't forward-declare.
13769 (value_of_xmethod): Rename to...
13770 (value_from_xmethod): ... this, take rvalue-reference.
13771 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
13772 (struct python_xmethod_worker): ... this, add constructor and
13773 destructor.
13774 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
13775 (gdbpy_free_xmethod_worker_data): Rename to...
13776 (python_xmethod_worker::~python_xmethod_worker): ... this and
13777 adjust.
13778 (gdbpy_clone_xmethod_worker_data): Rename to...
13779 (python_xmethod_worker::clone): ... this and adjust.
13780 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
13781 temporary vector.
13782 (gdbpy_get_xmethod_arg_types): Rename to...
13783 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
13784 (gdbpy_get_xmethod_result_type): Rename to...
13785 (python_xmethod_worker::do_get_result_type): ... this and
13786 adjust.
13787 (gdbpy_invoke_xmethod): Rename to...
13788 (python_xmethod_worker::invoke): ... this and adjust.
13789 (new_python_xmethod_worker): Rename to...
13790 (python_xmethod_worker::python_xmethod_worker): ... this and
13791 adjust.
13792 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
13793 Remove.
13794 (gdbpy_free_xmethod_worker_data): Remove.
13795 (gdbpy_get_matching_xmethod_workers): Use std::vector.
13796 (gdbpy_get_xmethod_arg_types): Remove.
13797 (gdbpy_get_xmethod_result_type): Remove.
13798 (gdbpy_invoke_xmethod): Remove.
13799 * python/python.c (python_extension_ops): Remove obsolete
13800 callbacks.
13801
13802 2018-01-05 Pedro Alves <palves@redhat.com>
13803
13804 PR gdb/18653
13805 * common/signals-state-save-restore.c
13806 (save_original_signals_state): New parameter 'quiet'. Warn if we
13807 find a custom handler preinstalled, instead of internal erroring.
13808 But only warn if !quiet.
13809 * common/signals-state-save-restore.h
13810 (save_original_signals_state): New parameter 'quiet'.
13811 * main.c (captured_main_1): Move save_original_signals_state call
13812 after option handling, and pass QUIET.
13813
13814 2018-01-05 Pedro Alves <palves@redhat.com>
13815
13816 * spu-tdep.c (spu_catch_start): Pass
13817 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
13818
13819 2018-01-05 Pedro Alves <palves@redhat.com>
13820
13821 PR gdb/22670
13822 * ada-lang.c (literal_symbol_name_matcher): New function.
13823 (ada_get_symbol_name_matcher): Use it for
13824 symbol_name_match_type::SEARCH_NAME.
13825 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
13826 it down instead of assuming symbol_name_match_type::FULL.
13827 * block.h (block_lookup_symbol): New parameter 'match_type'.
13828 * c-valprint.c (print_unpacked_pointer): Use
13829 lookup_symbol_search_name instead of lookup_symbol.
13830 * compile/compile-object-load.c (get_out_value_type): Pass down
13831 symbol_name_match_type::SEARCH_NAME.
13832 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
13833 symbol_name_match_type::FULL.
13834 * cp-support.c (cp_get_symbol_name_matcher): Handle
13835 symbol_name_match_type::SEARCH_NAME.
13836 * infrun.c (insert_exception_resume_breakpoint): Use
13837 lookup_symbol_search_name.
13838 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
13839 * psymtab.c (maintenance_check_psymtabs): Use
13840 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
13841 * stack.c (print_frame_args): Use lookup_symbol_search_name and
13842 SYMBOL_SEARCH_NAME.
13843 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
13844 if symbol_name_match_type::SEARCH_NAME.
13845 (lookup_symbol_in_language): Pass down
13846 symbol_name_match_type::FULL.
13847 (lookup_symbol_search_name): New.
13848 (lookup_language_this): Pass down
13849 symbol_name_match_type::SEARCH_NAME.
13850 (lookup_symbol_aux, lookup_local_symbol): New parameter
13851 'match_type'. Pass it down.
13852 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
13853 (lookup_symbol_search_name): New declaration.
13854 (lookup_symbol_in_block): New 'match_type' parameter.
13855
13856 2018-01-05 Pedro Alves <palves@redhat.com>
13857
13858 PR gdb/22670
13859 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
13860 ada_lookup_symbol.
13861 (ada_lookup_symbol): Reimplement in terms of
13862 ada_lookup_symbol_list, bits factored out from
13863 ada_lookup_encoded_symbol.
13864
13865 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13866
13867 * ada-exp.y (write_object_renaming): When subscripting an array
13868 using a symbol as the index, pass the block in call to
13869 ada_lookup_encoded_symbol when looking that symbol up.
13870
13871 2018-01-05 Jerome Guitton <guitton@adacore.com>
13872
13873 * ada-lang.c (ada_array_length): Use ada_index_type instead of
13874 TYPE_INDEX_TYPE.
13875
13876 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13877
13878 * ada-lang.c (ada_to_fixed_value_create): Add handling of
13879 the case where VALUE_LVAL (val0) is not lval_memory.
13880
13881 2018-01-05 Xavier Roirand <roirand@adacore.com>
13882
13883 * ada-valprint.c (print_optional_low_bound): Handle
13884 character-indexed array printing like boolean-indexed array
13885 printing.
13886
13887 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13888
13889 * NEWS: Create a new section for the next release branch.
13890 Rename the section of the current branch, now that it has
13891 been cut.
13892
13893 2018-01-05 Joel Brobecker <brobecker@adacore.com>
13894
13895 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
13896 * version.in: Bump version to 8.1.50.DATE-git.
13897
13898 2018-01-03 Xavier Roirand <roirand@adacore.com>
13899
13900 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
13901 Add field.
13902 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
13903 Add field.
13904 (default_exception_support_info) <catch_handlers_sym>: Add field.
13905 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
13906 (ada_exception_name_addr_1): Add "catch handlers" handling.
13907 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
13908 Update all callers.
13909 (create_excep_cond_exprs) <ex>: Add parameter.
13910 (re_set_exception): Update create_excep_cond_exprs call.
13911 (print_it_exception, print_one_exception, print_mention_exception)
13912 (print_recreate_exception): Add "catch handler" handling.
13913 (allocate_location_catch_handlers, re_set_catch_handlers)
13914 (check_status_catch_handlers, print_it_catch_handlers)
13915 (print_one_catch_handlers, print_mention_catch_handlers)
13916 (print_recreate_catch_handlers): New function.
13917 (catch_handlers_breakpoint_ops): New variable.
13918 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
13919 Add parameter. Add "catch handler" handling.
13920 (ada_exception_sym_name, ada_exception_breakpoint_ops):
13921 Add "catch handler" handling.
13922 (ada_exception_catchpoint_cond_string): Add "catch handler"
13923 handling.
13924 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
13925 call.
13926 (catch_ada_handlers_command): New function.
13927 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
13928 operations structure.
13929 (_initialize_ada_language): Add "catch handlers" command entry.
13930 * NEWS: Document "catch handlers" feature.
13931
13932 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13933
13934 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
13935 account when creating the array type of the slice.
13936 (ada_value_slice): Likewise.
13937
13938 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13939
13940 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
13941 New enum value.
13942 (create_array_type_with_stride): Add byte_stride_prop parameter.
13943 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
13944 New parameter. Update all callers in this file.
13945 (array_type_has_dynamic_stride): New function.
13946 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
13947 of arrays with dynamic byte strides.
13948 * dwarf2read.c (read_array_type): Add support for dynamic
13949 DW_AT_byte_stride attributes.
13950
13951 2018-01-02 Joel Brobecker <brobecker@adacore.com>
13952
13953 * dwarf2read.c (read_unspecified_type): Treat
13954 DW_TAG_enumeration_type DIEs from Ada units as stubs.
13955
13956 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13957
13958 Update copyright year range in all GDB files.
13959
13960 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13961
13962 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
13963 and gdb/testsuite/gdb.base/step-line.c.
13964
13965 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13966
13967 * copyright.py (main): Dump the contents of
13968 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
13969 even if BY_HAND is empty.
13970
13971 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13972
13973 * top.c (print_gdb_version): Update Copyright year in version
13974 message.
13975
13976 2018-01-01 Joel Brobecker <brobecker@adacore.com>
13977
13978 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
13979
13980 For older changes see ChangeLog-2017.
13981 \f
13982 Local Variables:
13983 mode: change-log
13984 left-margin: 8
13985 fill-column: 74
13986 version-control: never
13987 coding: utf-8
13988 End:
This page took 0.297563 seconds and 5 git commands to generate.